satoshipay / solar

🌞 Stellar wallet. Secure and user-friendly.
https://solarwallet.io
MIT License
192 stars 57 forks source link

net::ERR_FILE_NOT_FOUND (filr:///android_assert/www/index.prod-android.html ) #1275

Open amitmisratas opened 3 years ago

amitmisratas commented 3 years ago

getting this error after installing the build .apk in my hand set:-

Application Error net::ERR_FILE_NOT_FOUND (filr:///android_assert/www/index.prod-android.html )

i am working on windows 10

suryanshsangwan commented 3 years ago

I am working on it

amitmisratas commented 3 years ago

Captureaa

As you see from above, all building well in dist folder, but not able to figure out wat is missing.

Please let me know if you need any more info from my side.

amitmisratas commented 3 years ago

Capturebb

And i forgot to mention, the index.html in not copied to asserts/www folder

May be resolving this will make things work.

suryanshsangwan commented 3 years ago

I am getting error on running "npm run dev:android" command

suryanshsangwan commented 3 years ago

image

ebma commented 3 years ago

Hey there. At least for the issue of @suryanshsangwan I can tell that the problem is that the rm command does not exist on windows. That's why we use the rimraf dependency in the root project (see here) but it seems like we forgot to also use it in the scripts of the cordova/package.json.

So please try installing rimraf as dev dependency to the cordova directory, i.e. run npm i rimraf --save-dev in the cordova directory and replace rm -rf with rimraf in the scripts in cordova/package.json. Let me know if this solves this issue and if it does feel free to open a pull request for it. :)

suryanshsangwan commented 3 years ago

I solved the issue by changing package.json

"install:android": "rimraf plugins && .\scripts\create-config-from-template.sh prod android && cordova platform add android"

suryanshsangwan commented 3 years ago

Now i am getting this error

image

suryanshsangwan commented 3 years ago

I have also changed line 74 but no luck

image

ebma commented 3 years ago

The new error is because specifying environment variables with PLATFORM=android .... does not work on windows. One would have to use set PLATFORM=android or another tool like cross-env. @suryanshsangwan please try using cross-env, i.e. follow the steps on its GitHub page to install and use it for the npm scripts you need and let me know if it works afterward.

AnsarMadiniBaba commented 3 years ago

getting this error after installing the build .apk in my hand set:-

Application Error net::ERR_FILE_NOT_FOUND (filr:///android_assert/www/index.prod-android.html )

i am working on windows 10