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

Parsing / re-parsing issue for single string as extractor key input for UI form #1580

Open
lcjohnso opened this issue Oct 16, 2023 · 0 comments
Labels

Comments

@lcjohnso
Copy link
Member

lcjohnso commented Oct 16, 2023

The following issue was discovered while helping M. Denslow in #notes-from-nature Slack channel (private link to Slack thread).

Although the default placeholder example suggests that the input for the extractor_keys filter parameter be an array of strings (e.g., ["extractor_1", "extractor_2", "extractor_3"]), the reducer form allows a single string to be input as well (e.g., "extractor_1"). However, when that single string is read back in to the form for reducer config editing, it appears without quotes and when the form is submitted, the submission returns an error.

The Sentry error clearly explains this is a JSON parsing issue, however the user only receives a vague, generic error: "We're sorry, but something went wrong."

If a single string value is going to be allowed, what change needs to be made such that when it is read back into the form during reducer editing that resubmission of the existing value will be allowed? Is this issue somehow related to how existing parameter settings are ready back into the form, as added in #1389?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant