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

Consider allowing internal >1 whitespaces in strictish-string #532

Open
sdruskat opened this issue Feb 20, 2024 · 1 comment
Open

Consider allowing internal >1 whitespaces in strictish-string #532

sdruskat opened this issue Feb 20, 2024 · 1 comment
Assignees
Labels
enhancement Enhancement ideas for the format/schema itself
Milestone

Comments

@sdruskat
Copy link
Member

sdruskat commented Feb 20, 2024

Reported by @hainesr via email:

I think it makes us backwards incompatible because in some cases, such as say the abstract field, someone may have used double spaces after a period (e.g. “This tool is great. Please use it.”) if they’ve copied from a manuscript or something. It may catch people out and we may be being too strict(ish). I see the value of “strictish-string” for things like postcodes though so perhaps we can only use it in those cases. In any case, I think if we’re going with Semantic Versioning then I think that means we have to go to 2.0.0.

A solution to this would be to define the pattern as ^(\S)(.*\S)?$ (^(\\S)(.*\\S)?$ in the schema):

  • A string starting with a non-space character followed by an optional group of characters that ends on at least a single non-space character.
@sdruskat sdruskat added the enhancement Enhancement ideas for the format/schema itself label Feb 20, 2024
@sdruskat sdruskat added this to the 1.3.0 milestone Feb 20, 2024
@sdruskat sdruskat assigned sdruskat and unassigned sdruskat Feb 20, 2024
@sdruskat sdruskat changed the title Allow internal >1 whitespaces in strictish-string Consider allowing internal >1 whitespaces in strictish-string Feb 20, 2024
@sdruskat sdruskat self-assigned this Feb 20, 2024
@hainesr
Copy link
Member

hainesr commented Feb 21, 2024

I'd be more tempted to keep strict-ish string as it is, but not use it everywhere. Keep free-text fields as just strings?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Enhancement ideas for the format/schema itself
Projects
None yet
Development

No branches or pull requests

2 participants