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

Port from codec-argonaut to codec-json #1227

Merged
merged 2 commits into from
Jun 9, 2024
Merged

Port from codec-argonaut to codec-json #1227

merged 2 commits into from
Jun 9, 2024

Conversation

f-f
Copy link
Member

@f-f f-f commented Jun 9, 2024

Followup to purescript/registry-dev#690 - in this PR we port the JSON decoding from codec-argonaut to the new codec-json, in order to improve error messages.

This fixes #1057, as now the error message for missing license is much more readable:

Reading Spago workspace configuration...

❌ Couldn't parse Spago config, error:


  $.package.publish.license: No value found

And this fixes #1090, as we are now able to get errors through when parsing strings. E.g. an invalid PackageName now reports the reason:

Reading Spago workspace configuration...

❌ Couldn't parse Spago config, error:


  $.package.name: Package name cannot be longer than 150 characters

@f-f f-f merged commit d4e7dbb into master Jun 9, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve JSON/YAML parsing errors spago.yaml json errors could be a bit smaller
1 participant