-
Notifications
You must be signed in to change notification settings - Fork 1.3k
App Crashing when changing theme when an uploaded image is already viewed #3352
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
Comments
I would like to work on this @nicolas-raoul @maskaravivek |
@animeshk08 It is yours, feel free to post updates on this thread :) |
After looking a lot through the source code. I understand that the problem persists because we try to access a view element before the view is actually created. This happens in ContributionsFragment. One possible solution I found was to finish and start the activity again instead of recreating. However, in this case, the state of the application is not maintained. So I don't know we would actually want that. One more thing I don't understand the ability to open a nav drawer when you open an image to view because the left-most button indicates the functionality that we can go back at this stage. Maybe another solution would be to not show the navdrawer at all. Can anyone help me with a better approach? @ashishkumar0207 |
Also, while exploring the bug I found that it was very prominent as it replicates itself even in the Bookmark section and Explore section. |
@animeshk08 Another simple (possible) solution should be to change the lifecycle callbacks where the presenter is attached/detached, instead of doing those in onCreateView & onDestroyView, we could do that in onResume & onStop (or if you think another better place). Ideally, the showProgress should not be called after the fragment is not longer active |
Can I work on this issue? |
@animeshk08 How is your progress? :-) |
I want to work on this, |
@4D17Y4 I think you already have another issue assigned? :-) Since Animeshk08 has not replied, @gouri-panda can have this one if not already working on any other issue. |
Summary:
The application is crashing.
If one clicks on an uploaded picture from the home screen then tries to change the theme of the application(dark/light) then returning to the previous activity the application will crash.
Steps to reproduce:
System logs:
Device and Android version:
Device Model: Redmi Note 7 Pro
Version: Android 9
Is it the stock version from the manufacturer or a custom ROM ? Yes
Commons app version:
version: 2.12.2-debug
branch: master
Screen-shots:
Would you like to work on the issue?
Yes. I would like to work on the issue.
The text was updated successfully, but these errors were encountered: