Publish to device from Android Studio no longer working - testing

So iv spent the last couple of weeks building my first app in Android Studio and all has gone well. Successfully launched on device through whole testing / Dev phase.
I got to a point where I was happy and proceeded to build a signed APK using Build->Generate Signed APK.
This was successful and now I have a published APK.
I have since noticed a spelling mistake (Rookie error!).
I have corrected the spelling but now when I click the "play" button to launch a test version it appears to be building the app on outputs a big stack trace ending with the following...
BUILD SUCCESSFUL
Total time: 1 mins 21.581 secs 13:15:46: External task execution
finished 'build'.
But then that is it, no offer to view on device like during the initial build stage. (no device popup)
What am I missing to get this to publish onto a test device again?
Any help or pointers are appreciated, I'm new to this Gradle thing, I have a feeling its something to do with that but I don't know where to start and Google doesn't seem to find anything useful to me :/

Related

Expo React Native building apk

I have been trying to build my apk today but I always face this problem. After completing the build, i download it to my phone and i cannot open it. However, this was not the case 2-3 days ago. I had no difficulties or errors in Run expo doctor. I was able to download the apk to my device and test my app.
I am not really sure what to do and any help would be appreciated.
This is what I got after running npx expo doctor:
I managed to solve my problem. I used Android Studio's logcat feature and when I ran the app on the emulator I found the issue - it was related to admob. At this point, I dont need admob, so I deleted its folder from my project and everything was fine after this.
Running expo doctor usually ends up in flagging what dependency needs to be upgraded if the jump to automatically update it goes into the majors like in your case from 4 to 5.
Maybe try upgrading #expo/config-plugins by using expo upgrade or commands from your preferred package manager.
If that’s impossible due to other packages depending on the specific version, maybe consider adding overrides in your package.json. Here is a helpful article about that.
In my experience this may not be the only reason for the crash of the app. Try running the app consecutively about 3 or 4 times even if it crashes and I believe Android will prompt you to submit a bug report and maybe show you the call stack it failed at.
Let us know how it goes.

Unable to load script. Make sure you're either running a Metro server (run 'react-native start') or that your bundle index.android.bundle is packaged

So this has been asked before but I'm asking it again because nothing has worked, I've read through all of the similar posts I could find and all but one has semi fixed the problem.
https://medium.com/#adityasingh_32512/solved-unable-to-load-script-from-assets-index-android-bundle-bdc5e3a3d5ff
This medium article is the only solution that i can find that will get debug builds running again but that is only because it is pre packaging the javascript bundle and not really fixing the problem of the app not connecting to the metro server, once the debug build is running via this method I'm unable to shake the device and get the debug menu to show up.
I've been developing this app for probably 10 months, live for 3-4 months, and can usually trudge through these errors that pop up but this one is tricky.
I've been using cleartextTrafficPermitted="true", tried implementing a custom network security config android:networkSecurityConfig="#xml/network_security_config", tried a different physical device, cleared the metro cache, deleted .gradle/ build folders, cleaned, rebuilt.. All with the same end result of the app crashing on boot and the same error in logcat Unable to load script. Make sure you're either running a Metro server (run 'react-native start') or that your bundle 'index.android.bundle' is packaged correctly for release.
Release builds work but that's because its not trying to connect to the metro server, pretty stumped on this one.
Answering this for others that might find it useful. Still not sure what I did wrong but in the process of setting up a CI/CD pipeline for the app I re cloned the project and magically android debug builds started working again. No changes to the code, the android project must have gotten corrupted somehow so recloning allowed android studio to start from square one. Weird one.

React Native Expo building standalone app

I use Expo for development. I don't know how to build .apk for Android. I checked out Building Standalone Apps documentation. It says:
This will take a few minutes, you can check up on it by running exp
build:status. When it’s done, you’ll see the url of a .apk (Android)
or .ipa (iOS) file — this is your app.
exp build:android
I tried a few times. It's been a while. No errors, no links. Nothing on the web portal. Am I doing something wrong?
expo has it's integrated system if you are using their building structure.
The building takes a while as stated. (Around 5-10mins) your build process starts with the command;
exp build:android
After a while, check the status of your build with command;
exp build:status
If your build it done, this comman will give you your .apk file url. If not, it will say your build is still in progress and try in a little bit later again.
Expo build take some time (6-15min). You can see build progress log using link
https://expo.io/builds
Web link show all builds of your accounts. You can download old build or see log
or in short you can
exp build:status
Your options are
wait, until your build is completed
Note! If you get the following error:
Cannot start a new build, as there is already an in-progress build.
error Command failed with exit code 1.
then your Expo.io build is stuck. Please go to https://expo.io -> Builds and look for the latest (IOS/Android) build. If it's in "Queued" state (after 17 days as in my case), open the details and click Cancel Build.
Subscribe to the paid Expo.io account so you get priority in build queue.
Install turtle-cli and build the app locally, see https://docs.expo.io/distribution/turtle-cli/
If it normally takes from 15-30minutes for Expo.io to build the app, turtle-cli can do it in 2-3mins.

Application stuck at "Powered by Titanium screen"

I'm trying to run an app made on Titanium in my cellphone. At first it was working fine, until i decided to debug my code. After that whenever i try to run it on my cellphone, it gets stuck # the powered by titanium screen (that red one).
I tried to delete my build folder as some people said after a bit o research but it won't work.
How can i solve this?
What I would try to do is:
clean the project (it also deletes the build folder, but I think it also cleans some more stuff in there).
when the app starts try to set an alert in app.js as the first thing - see if this alert shows, and if it does - move it to the next step until you find a place where it is no longer shown which might indicate that this is where you problem is.
Look at the device logs - if it's an android device open ddms and look at the logs while you run the app - see if anything pops up. If it's an iPhone on xCode you have some sort of console viewer for the phone (sorry - can't remember the name right now).
make sure you are not still running under debug mode.
BTW - you didn't mention if it happens on iPhone or Android? does it happens on the simulator as well?
I was having the same issue. From digging through Appcelerator's Jira I found we weren't alone, and also got a workaround that allows us to get past the splash screen. Check to see if there is a deploy.json file located in your application's directory on the device. If so delete it!
Here is more info on the issue https://jira.appcelerator.org/browse/TIMOB-16086.
It's rated as a high priority to be corrected for the 3.3.0 SDK release.

Appcelerator Titanium does not run with sample application KitchenSink

I've installed Appcelerator Titanium Studio on a PC and I was not able to run the android simulator on it, so I was saying to myself "it should work on Mac at least"... and I installed a new Mac with Titanium on it, downloaded the SDK, then I imported the Kitchen Sink example and configured the run configuration with the default settings... and I'm getting exactly the same problem which is an infinite loop with the 'audio_flinged died' problem! So the best I can do is to view the Android simulator with the black window and "Android..." written on it.
What can I do to finally launch that example that is supposed to run? The best I did with my Windows 7 setup was to get the screen of an android cellphone WITHOUT any app on it (default apps), so it's pretty unuseful.
I'd really like to see what Titanium is capable to do.
The Mac ends (after a few mins) with "Launching New_configuration" has encountered a problem. Session initialization failed. "Session initialization failed Failed to get version"
The problem of the infinite loop with "AudioFlinger" still persist in the two cases (PC/Mac).
Any help would be greatly appreciated.
I helped someone with a similar question. He was getting a error which you don't seem to be but my answer walked him through checking the configuration was ok etc.
might help you:
Error running Android emulator from Titanium Studio