Skip to content

Conversation

@langsmith
Copy link
Contributor

@langsmith langsmith commented Mar 19, 2020

Resolves #908 by adjusting the Places Plugin's BottomSheetBehavior.

cc @orlikraf, who had a helpful comment at #908 (comment)

@langsmith langsmith added bug A bug is found inside the code base and should be immediately brought to attention ASAP places-plugin Issues that deal with the places plugin module labels Mar 19, 2020
@langsmith langsmith self-assigned this Mar 19, 2020
@langsmith langsmith requested a review from LukasPaczos March 19, 2020 15:26
@langsmith langsmith added the ready for review When your PR has been personally reviewed, its time for an external contributors to approve label Mar 19, 2020
@langsmith
Copy link
Contributor Author

The crash that was happening

2020-03-19 00:16:06.986 9832-9832/? E/AndroidRuntime: FATAL EXCEPTION: main
    Process: com.mapbox.mapboxandroiddemo.debug, PID: 9832
    java.lang.IllegalArgumentException: Illegal state argument: 5
        at com.google.android.material.bottomsheet.BottomSheetBehavior.startSettlingAnimation(BottomSheetBehavior.java:1099)

Discussions about java.lang.IllegalArgumentException: Illegal state argument: 5:

@langsmith
Copy link
Contributor Author

ezgif com-resize

@orlikraf
Copy link

Resolves #908 by adjusting the Places Plugin's BottomSheetBehavior setHideable() value. I don't believe there's any downside to hardcoding the fact that the sheet can be hideable.

cc @orlikraf, who had a helpful comment at #908 (comment)

@langsmith
If I recall correctly a hideable BottomSheet can be dismissed out of screen with a swipe down without a way to swipe it into view again. I'm 90% sure about this so please check it yourself.

I would suggest to call isShowing only once before setting hideable and use the result in both later calls.

@langsmith langsmith removed the ready for review When your PR has been personally reviewed, its time for an external contributors to approve label Mar 22, 2020
@langsmith langsmith removed the request for review from LukasPaczos March 22, 2020 00:07
@langsmith langsmith added the ready for review When your PR has been personally reviewed, its time for an external contributors to approve label Mar 22, 2020
@langsmith langsmith requested a review from LukasPaczos March 22, 2020 21:07
@langsmith
Copy link
Contributor Author

I would suggest to call isShowing only once before setting hideable and use the result in both later calls.

Thanks @orlikraf , that's what I'm now doing in this pr. Getting a weird CI 🐛 now.

@langsmith
Copy link
Contributor Author

CircleCI 💥 is from a Mapbox infrastructure 🐛 , rather than something with this pr's code changes.

@langsmith langsmith force-pushed the ls-place-plugin-bottomsheet-crash-fix branch from 5961f1c to 4c2c8fd Compare March 30, 2020 20:04
@langsmith langsmith merged commit 579abd8 into master Mar 30, 2020
@langsmith langsmith deleted the ls-place-plugin-bottomsheet-crash-fix branch March 30, 2020 20:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug A bug is found inside the code base and should be immediately brought to attention ASAP places-plugin Issues that deal with the places plugin module ready for review When your PR has been personally reviewed, its time for an external contributors to approve

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Place Picker crashes on Android X

3 participants