How do I install OS in Andriod phone without using fastboot and TWRP?

I’ve tried to upgrade the rom in MOTO G4 Plus using TWRP version of and during installation process I wiped out the existing android 7.0.1 without backup(understood the cost of backups now). As I faced error while installing android 9.0.1 with error 255 code because of TWRP some upgrade issue couldn’t complete the installation process successfully.

I tried multiple ways to upgrade TWRP which was not successful and even fastboot commands aren’t working now. Whenever I try fastboot + combinational command like devices and etc it goes into an infinite loop with an error code iterator not found. After a good amount of search found about ADB and happily can connect to my device using ADB now. Then started trying with multiple options like adb side load after reading multiple forum answers and posts I did pushed a rom to scared/data/media after reading this forum NEED HELP: Accidentally deleted OS in TWRP/Cant install Rom which was successfully pushed but didn’t do any thing nor I couldn’t understand what to do after pushing it.

Then started search again to install stock rom in any different ways before coming here and stumbled at this question which is similar did read the question and included forum post in it to go start the process when I did download stock rom stock rom download couldn’t find any file to start the process

Now I’m stuck and couldn’t find better place to find a working solution for this situation. Can somebody help me? What can I do while my phone is in this state?

Does Andriod have an event viewer and how do I access it?

I have a new Samsung S7 for 3 months now – My phone crashes in a big way around once a month, I mean I can’t even do the factory reset because I cannot get to the recovery screen, no buttons are responsive so holding them to get to the recovery menu is useless, I have to wait till the battery dies before I can recharge it and switch it back on so I can carry out a factory reset before it will crash again (usually 20 minute time frame before it will crash again).

I barley have anything installed (as this is my 3rd time of factory resetting my phone it gets boring re-adding apps etc so only the essential apps are installed whatsapp, bbc news, stock apps)

I work in IT, if this happened on a server I would go view the event viewer to find out what exactly was the root cause, or at least a clue towards why, my question is do android phones have an event viewer hidden away or is there something that I can install that will capture information?

The phone is on the latest firmware & android version and has not been modified or tampered with in any way shape or form.

Kind Regards

react native on andriod shows white page

I am trying to run react native application and building and running an Andriod application from my mac to a real android device.

The problem is it shows white page only.

This is what I am doing.

react-native init AwesomeProject react-native run-android --port 1234 

Every time I reload the app, I can see API calls being received in the console.

 DELTA  [android, dev] ../../index.js ░░░░░░░░░░░░░░░░ 0.0% (0/1)::ffff: - - [05/Mar/2019:19:17:13 +0000] "GET / HTTP/1.1" 200 72 "-" "okhttp/3.12.1"  DELTA  [android, dev] ../../index.js ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ 100.0% (1/1), done. 

However, Nothing gets displayed on my android phone but a white page.