Skip to content
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

Crash on new context when expanding search service options #9014

Closed
1 task done
MV88 opened this issue Mar 14, 2023 · 2 comments · Fixed by #9027 or #9038
Closed
1 task done

Crash on new context when expanding search service options #9014

MV88 opened this issue Mar 14, 2023 · 2 comments · Fixed by #9027 or #9038

Comments

@MV88
Copy link
Contributor

MV88 commented Mar 14, 2023

Description

This issue has been generated from here

How to reproduce

Expected Result

the services panel opens

Current Result

crash
image

  • Not browser related
Browser info (use this site: https://www.whatsmybrowser.org/ for non expert users)
Browser Affected Version
Internet Explorer
Edge
Chrome
Firefox
Safari

Other useful information

@dsuren1
Copy link
Contributor

dsuren1 commented Mar 15, 2023

Investigation:
The issue happens when adding loading a context with SearchServicesConfig plugin added

However, it doesn't happen when navigation from context manager because upon mount a reset control is dispatched which adds some default state to searchconfig reducer. But loading search plugin SearchServicesConfig enabled context by refreshing the page (while in the context) will result in a null state. And trying to read a property from a null state results in page crash exception.

Fix should be simple as checking null and returning a default here (best done on all props), should resolve it

@tdipisa
Copy link
Member

tdipisa commented Mar 15, 2023

@dsuren1 thank you, you can proceed with the fix.

dsuren1 added a commit to dsuren1/MapStore2 that referenced this issue Mar 16, 2023
@dsuren1 dsuren1 linked a pull request Mar 16, 2023 that will close this issue
5 tasks
MV88 pushed a commit that referenced this issue Mar 16, 2023
#9027)

* #9014: Fix - Crash on new context when expanding search service options

* Copyright updated
@ElenaGallo ElenaGallo self-assigned this Mar 16, 2023
dsuren1 added a commit to dsuren1/MapStore2 that referenced this issue Mar 17, 2023
… service options (geosolutions-it#9027)

* geosolutions-it#9014: Fix - Crash on new context when expanding search service options

* Copyright updated

(cherry picked from commit ad7333e)
tdipisa pushed a commit that referenced this issue Mar 22, 2023
#9027) (#9038)

* #9014: Fix - Crash on new context when expanding search service options

* Copyright updated

(cherry picked from commit ad7333e)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment