-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Fix #5213 app is excluded from recent/current apps #5218
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
APK file: https://www.kaminsky.me/nc-dev/android-artifacts/12311.apk |
Codacy340Lint
SpotBugs (new)
SpotBugs (master)
|
Codecov Report
@@ Coverage Diff @@
## master #5218 +/- ##
============================================
+ Coverage 17.69% 17.71% +0.02%
Complexity 3 3
============================================
Files 392 392
Lines 33140 33138 -2
Branches 4656 4655 -1
============================================
+ Hits 5864 5872 +8
+ Misses 26319 26308 -11
- Partials 957 958 +1
|
|
I tested account creation and login and I see no problem described in #5031 (comment). This is good, but it could as well be a race condition. Please test the following scenarios:
In both cases application should not display empty file list. |
|
This is actually how it is for every permission request - the thing is that when you request permissions via requestPermissions the activity is paused. After answering, onResume gets called (again). |
|
So, to summarize: I'd suggest setting up all the views and everything and then ask for permissions. |
|
I encountered the problem without the finish. I had the request for authorization to write toi storage file on the login activity. So the activity that lists the files is launched while we are on that of login. Here is the problem. I'm watching this next week. |
|
That doesn't seem right given that:
|
|
Hm.
It is only needed, if you want to upload a file from external storage, eg. external sdcard. |
Just to let you know it can happen when the app is launched. @tobiasKaminsky @ezaquarii And that's why the file list is not refreshed after the first login. |
|
@ezaquarii I think that adding this finish is not necessary (especially because it generates a bug). It is better to fix the problem at source, as described in this issue #4993 |
|
@ezaquarii this bug prevents user from switching during login to another app, e.g. for generating one-time password. As the only drawback right now might be that we get an empty list on first start, I am fine with this. @JorisBodin can you then remove the accountHandling boolean es we this then do not need it. How to proceed, we should discuss in #4993 |
|
@tobiasKaminsky if remove enableAccountHandling in baseActivity, accountManager.getCurrentAccount() is called. But it will have to be removed during the big correction of #4993 |
|
ah true. |
|
@tobiasKaminsky So, do we merge it or do we close this MR? |
|
/backport to stable-3.10 |
|
backport to stable-3.10 in #5324 |
55c1a89 Merge pull request #5321 from nextcloud/dependabot/gradle/org.powermock-powermock-core-2.0.5 6fbf451 Merge pull request #5320 from nextcloud/dependabot/gradle/org.powermock-powermock-api-mockito2-2.0.5 c0991da Bump powermock-core from 2.0.4 to 2.0.5 a1f489a Bump powermock-api-mockito2 from 2.0.4 to 2.0.5 dd5c604 Merge pull request #5322 from nextcloud/dependabot/gradle/org.powermock-powermock-module-junit4-2.0.5 b53c96c Merge pull request #5218 from nextcloud/fix_multitask fc68892 [tx-robot] updated from transifex b0003f0 Bump powermock-module-junit4 from 2.0.4 to 2.0.5 a5acbbf [tx-robot] updated from transifex 01ba3be daily dev 20200125
55c1a89 Merge pull request #5321 from nextcloud/dependabot/gradle/org.powermock-powermock-core-2.0.5 6fbf451 Merge pull request #5320 from nextcloud/dependabot/gradle/org.powermock-powermock-api-mockito2-2.0.5 c0991da Bump powermock-core from 2.0.4 to 2.0.5 a1f489a Bump powermock-api-mockito2 from 2.0.4 to 2.0.5 dd5c604 Merge pull request #5322 from nextcloud/dependabot/gradle/org.powermock-powermock-module-junit4-2.0.5 b53c96c Merge pull request #5218 from nextcloud/fix_multitask fc68892 [tx-robot] updated from transifex b0003f0 Bump powermock-module-junit4 from 2.0.4 to 2.0.5 a5acbbf [tx-robot] updated from transifex 01ba3be daily dev 20200125





After talking with @tobiasKaminsky, we've decided to remove this finish()
Because "onResume" is called after requestPermissionsResult for PERMISSIONS_WRITE_EXTERNAL_STORAGE
#5213