MarcusWolschon / osmeditor4android

Vespucci is a OpenStreetMap editor for Android
http://vespucci.io
Other
376 stars 83 forks source link

Too persistent uploading pop-up #1443

Closed vespucci-reporter closed 2 years ago

vespucci-reporter commented 3 years ago

Description:

Uploading pop-up sometimes stays for several minutes and cannot be dismissed, functionally locking the app

AFAIK it is supposed to disappear and start uploading in the background if I click somewhere

Though I am unsure what is the benefit of such big pop-up. Why not have something smaller in corner or to side? In the beginning I was unaware that this box can be dismissed to background.

I have recording (sadly, with Polish translation enabled) that I can upload of the situation.

It happened on a terribly poor mobile data connection (other editing apps also had bugs in such environment)

Curiously, I was able to select elements in the downloaded area - though editing was functionally impossible

Pinging myself @matkoniecz

Device info:

App version15.2.3.0
App version code1705
Android build versionV11.0.5.0.QDLMIXM
Android release version10
Android SDK version29
Android build IDQKQ1.191002.002.V11.0.5.0.QDLMIXM
Device brandxiaomi
Device manufacturerXiaomi
Device namedaisy_sprout
Device modelMi A2 Lite
Device product namedaisy
Device hardware nameqcom
ABIs[arm64-v8a, armeabi-v7a, armeabi]
ABIs (32bit)[armeabi-v7a, armeabi]
ABIs (64bit)[arm64-v8a]

Extra info:

OSM display nameMateusz Konieczny
simonpoole commented 3 years ago

The upload process is always in a non-ui "background" thread and never in the foreground, as Android doesn't allow network access in the UI thread, and will, intentionally, immediately crash if you try to do so.

There is also no reason why you shouldn't be able to dismiss the dialog, as it literally doesn't do anything outside of waiting to be dismissed. Did you try pressing the back button? On some devices there isn't that much space around the dialog that will react to a touch.

matkoniecz commented 3 years ago

Did you try pressing the back button?

No, I will try it the next time

On some devices there isn't that much space around the dialog that will react to a touch.

In my case there was plenty of space and I managed to even select some elements (was getting toast message about validator warnings).

matkoniecz commented 3 years ago

I can attach a recording that I made if that would help. Or close it as "xiaomi-specific bug, unfixable".

simonpoole commented 3 years ago

I can attach a recording that I made if that would help. Or close it as "xiaomi-specific bug, unfixable".

Please attach, can't hurt. When was it recorded?

PS: that the dialog can be dismissed, doesn't mean that doing so is a good idea and obviously changing data before the upload has either completely failed or succeeded is fraught with danger. There is however currently no way around such issues, see also https://github.com/openstreetmap/openstreetmap-website/issues/2201

matkoniecz commented 3 years ago

This white dot is register of tapping on the screen

https://user-images.githubusercontent.com/899988/131412933-6a98b0f1-dfc5-4ca9-bb69-44260d7ad7b9.mp4

simonpoole commented 3 years ago

Hmm that actually looks like an issue with Android on the device though it really seems unlikely .... I'll investigate a bit further.

simonpoole commented 3 years ago

https://github.com/MarcusWolschon/osmeditor4android/commit/32b04d82fe482fddb552649cbb3802567018627b just to be on the safe side sets canceable true (that is the default) for the enclosing DialogFragment but it shouldn't make a difference.

Other angle: did you rotate the screen or use a different app and then returned to Vespucci when this occurred?

matkoniecz commented 3 years ago

did you rotate the screen or use a different app and then returned to Vespucci when this occurred

No to the first one, probably no to the second one. Maybe I checked something or interacted with notifications but I do not remember it.

chau-intl commented 2 years ago

I think I had the same issue a couple of days ago. I think it worked pressing the back button, but seen from my point of view (as a user) I was worried that my upload was then cancelled when the dialog closed (I also had an extremely bad internet connection and wouldn't dare stop the upload).

Instead of a modal dialog maybe a toast or something would be better to notify the user, that an upload process has been started and is continuing in the background? And maybe a button somewhere so I can check the status and progress of the upload?

simonpoole commented 2 years ago

That is a different issue though, the weird issue is that @matkoniecz couldn't cancel the modal. ' Outside of that, all network activities run asynchronously until they eventually succeed or fail (which may take a long time) regardless of if you cancel the modal or not. Unluckily there is currently no way to really improve the user experience as there is no facility to cancel and repeat an upload in a consistent fashion with the OSM API 0.6.

simonpoole commented 2 years ago

Stale, closing.