Skip to content

Fix Error Message Related to ISO 8601 format for creationInfo created field #529

@jspeed-meyers

Description

@jspeed-meyers

When a user provides a SPDX document with a time created field that has a fractional second component of an ISO 8601 datetime, tools-python returns an error message similar to this:

Invalid created value '2023-03-17T19:44:10.259Z' must be date in ISO 8601 format.

After discussion in issue #527 and spdx/ntia-conformance-checker#95, I believe that tools-python does not in fact strictly follow ISO 8601, which allows fractional seconds, and instead follows the SPDX spec, which does not allow fractional seconds.

To help users follow the format expected by the SPDX spec, @zvr suggested this error message instead:

Invalid created value '2023-03-17T19:44:10.259Z' is not in "YYYY-MM-DDThh:mm:ssZ" format.

I'm glad to put in a PR if the maintainers are amenable to this change.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions