These are chat archives for angular/angular-2-ionic-2

14th
Jun 2017
abubkr84
@abubkr84
Jun 14 2017 06:09

Hi, I am facing a problem when running my ionic project with ionic serve

F:\Hybrid Apps\ManPower>ionic serve
[INFO] Starting app-scripts server: --port 8100 --p 8100 --livereload-port 35729 --r 35729 --address 0.0.0.0 - Ctrl+C to
cancel
[23:03:34] watch started ...
[23:03:34] build dev started ...
[23:03:34] clean started ...
[23:03:34] copy started ...
[23:03:34] transpile started ...
[23:03:38] transpile finished in 4.15 s
[23:03:38] preprocess started ...
[23:03:38] deeplinks started ...
[23:03:38] deeplinks finished in 36 ms
[23:03:38] preprocess finished in 37 ms
[23:03:38] webpack started ...
{ Error: Failed to clean directory F:\Hybrid Apps\ManPower\www\build - EPERM: operation not permitted, lstat 'F:\Hybrid Apps\ManPower\www\build\main.css'
at BuildError.Error (native)
at new BuildError (F:\Hybrid Apps\ManPower\node_modules\@ionic\app-scripts\dist\util\errors.js:16:28)
at F:\Hybrid Apps\ManPower\node_modules\@ionic\app-scripts\dist\clean.js:15:32
at Object.clean (F:\Hybrid Apps\ManPower\node_modules\@ionic\app-scripts\dist\clean.js:7:12)
at buildProject (F:\Hybrid Apps\ManPower\node_modules\@ionic\app-scripts\dist\build.js:94:13)
at F:\Hybrid Apps\ManPower\node_modules\@ionic\app-scripts\dist\build.js:47:16 hasBeenLogged: false, isFatal: false }
[23:03:38] copy finished in 4.52 s
[23:03:51] webpack finished in 13.11 s
[23:03:51] sass started ...
[23:03:52] dev server running: http://localhost:8100/

UncertaintyP
@UncertaintyP
Jun 14 2017 06:21
@abubkr84 Try deactivating your antivirus while doing ionic serve
abubkr84
@abubkr84
Jun 14 2017 06:23
@UncertaintyP I did but still not working
@UncertaintyP
webpack starting but no CSS Files are being loaded
UncertaintyP
@UncertaintyP
Jun 14 2017 06:27
if you delete the css file manually?
abubkr84
@abubkr84
Jun 14 2017 06:32
I deleted the CSS file manually still no success. I tried copying CSS files from another working copy of current project(older one) and it says 'permission not allowed' i changed permissions in properties but its not making any difference. Still getting same error.
UncertaintyP
@UncertaintyP
Jun 14 2017 06:33
If you execute as Administrator?
Im running out of ideas here =D good ol windows :)
abubkr84
@abubkr84
Jun 14 2017 06:37
I did but still there. it was working fine last day, today i got an update of cordova plugin and ionic angular cli plugin. After updating i ran into the problem. I tried to downgrade the versions but it didn't work
UncertaintyP
@UncertaintyP
Jun 14 2017 06:41
ouch thats cruel
You may open an issue for that on github
abubkr84
@abubkr84
Jun 14 2017 08:19
@UncertaintyP Fixed. It was related to OS. Thanks by the way
UncertaintyP
@UncertaintyP
Jun 14 2017 16:35
Of course its related to OS, its windows xD
Thomas Havlik
@thavlik
Jun 14 2017 18:45
Hi everyone
Does ionic have an imminent plugin for the twitter REST and/or streaming API?
Thomas Havlik
@thavlik
Jun 14 2017 20:59
Is CORS broken in the iOS simulator?
I don't have access control to even the proxy
[Error] Origin http://10.0.0.5:8100 is not allowed by Access-Control-Allow-Origin.
[Error] Failed to load resource: Origin http://10.0.0.5:8100 is not allowed by Access-Control-Allow-Origin. (settings, line 0)
[Error] XMLHttpRequest cannot load https://mobile.twitter.com/account/settings due to access control checks.
[Error] ERROR – Response {_body: XMLHttpRequestProgressEvent, status: 0, ok: false, …}
Response {_body: XMLHttpRequestProgressEvent, status: 0, ok: false, statusText: "", headers: Headers, …}Response_body: XMLHttpRequestProgressEvent {isTrusted: true, position: 0, totalSize: 0, lengthComputable: false, loaded: 0, …}XMLHttpRequestProgressEventheaders: Headers {_headers: Map, _normalizedNames: Map, append: function, delete: function, forEach: function, …}Headersok: falsestatus: 0statusText: ""type: 3url: nullResponse Prototype
    defaultErrorLogger (main.js:1362)
    handleError (main.js:1422)
    handleError (main.js:113048)
    next (main.js:5035:98)
    (anonymous function) (main.js:4108)
    __tryOrUnsub (main.js:35578)
    next (main.js:35527)
    _next (main.js:35469)
    next (main.js:35433)
    next (main.js:55571)
    emit (main.js:4094)
    triggerError (main.js:4466)
    onHandleError (main.js:4427)
    runTask (polyfills.js:3:4897)
    invoke (polyfills.js:3:10641)
From the Safari Inspector on an instance of ionic running in the simulator.
Thomas Havlik
@thavlik
Jun 14 2017 21:14
Yeah, it's a live reload CORS issue. I can query twitter directly if I omit --livereload
Thomas Havlik
@thavlik
Jun 14 2017 21:42
ahhhh I have to write the proxy server
Wait, what? How does this work? Is this not valid: "proxies": [{ "path": "/api/twitter", "proxyUrl": "http://mobile.twitter.com" }]
I get the access control error as shown above when I do that. The requests work fine if I make proxyUrl another port on localhost.