Restore PATH_SCHEMA to be AnyString #248
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes issue #: theupdateframework/python-tuf#1059
Description of the changes being introduced by the pull request:
In one of the latest commits AnyNonemptyString was introduced
and with it, PATH_SCHEMA was changed to AnyNonemptyString from
AnyString. This led to unit tests failures in TUF.
One could argue what is the right approach: to consider
that PATH_SCHEMA is every non-empty string or every string.
I think this is not of much importance, but for TUF and
possibly for other securesystemslib adopters, this leads to tests
failures. The reason is that there are multiple functions
with arguments which should conformant against the PATH_SCHEMA
but have default values of
''
See :
both of which are in tuf/developer_tool.py: https://github.com/theupdateframework/tuf/blob/49031b424b65e852194c911f85bc29c14ad97432/tuf/developer_tool.py#L519
https://github.com/theupdateframework/tuf/blob/49031b424b65e852194c911f85bc29c14ad97432/tuf/developer_tool.py#L758
Signed-off-by: Martin Vrachev [email protected]
Please verify and check that the pull request fulfils the following
requirements: