Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix error validation code in attr parsing #2353

Merged
merged 1 commit into from
Aug 11, 2022
Merged

Conversation

jefferai
Copy link
Member

@jefferai jefferai commented Aug 11, 2022

For a flag type used for attributes/secrets, values have always been
able to be used with env:// or file:// format, but the error check to
see whether the value was successfully parsed was doing a simple string
equality rather than errors.Is. As a result a value containing a colon
would trip up this check and cause an error, rather than allowing it to
be used as a bare value.

Fixes ICU-5629

@github-actions github-actions bot added the core label Aug 11, 2022
Copy link
Collaborator

@johanbrandhorst johanbrandhorst left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice

@jefferai jefferai force-pushed the jefferai-fix-attr-parsing branch from f114265 to 3fd828e Compare August 11, 2022 17:52
For a flag type used for attributes/secrets, values have always been
able to be used with env:// or file:// format, but the error check to
see whether the value was successfully parsed was doing a simple string
equality rather than `errors.Is`. As a result a value containing a colon
would trip up this check and cause an error, rather than allowing it to
be used as a bare value.
@jefferai jefferai force-pushed the jefferai-fix-attr-parsing branch from 3fd828e to 1a10e66 Compare August 11, 2022 17:59
@jefferai jefferai added this to the 0.10.1 milestone Aug 11, 2022
@jefferai jefferai merged commit f1b737c into main Aug 11, 2022
@jefferai jefferai deleted the jefferai-fix-attr-parsing branch August 11, 2022 18:39
jefferai added a commit that referenced this pull request Aug 11, 2022
For a flag type used for attributes/secrets, values have always been
able to be used with env:// or file:// format, but the error check to
see whether the value was successfully parsed was doing a simple string
equality rather than `errors.Is`. As a result a value containing a colon
would trip up this check and cause an error, rather than allowing it to
be used as a bare value.
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants