Skip to content

Spec change: Update rule for "extra" slash characters for the scheme component #881

Description

@mjherzog

ECMA-472 1st edition contains text related to "extra" slash '/' characters that causes confusion between the canonical form of a PURL string or PURL component and recommended normalization to handle "extra" slashes. This text was carried over from the original specification documentation that did not always have a clear delineation between requirements (shall) and recommendations (should) for how to normalize input PURL strings to canonical form.

Based on feedback in this issue the current proposal is to update the following scheme rule to change "shall" to "should" as follows:
From: URL parsers shall accept URLs where the scheme and colon ':' are followed by one or more slash '/' characters, such as 'pkg://', and shall ignore and remove all such '/' characters.
To: PURL parsers should accept URLs where the scheme and colon ':' are followed by one or more slash '/' characters, such as 'pkg://', and should ignore and remove all such '/' characters.

This change will make the rules for extra slashes consistent across PURL components such that the normalization is recommended, but not required for conformance. It also means that:

  • A test case for the normalization of extra slashes for the *scheme component will be in the 'required' test group for ECMA-427 1st edition, but will be moved to the 'recommended' test group for ECMA-427 2nd edition after this change is approved.
  • Test cases for normalization of extra slashes for the namespace, name or subpath components should be in the 'recommended' test group for both editions of ECMA-427.

NB - Updated July 14, 2026 to reset the issue title and limit the scope change to the use of "shall" for the scheme component.

The proposed change is to delete the following bullet items from the Rules for each PURL component: section of the Core Specification (ECMA-427 Clause 5):
- Scheme
- PURL parsers shall accept URLs where the scheme and colon ':' are followed by one or more slash '/' characters, such as 'pkg://', and shall ignore and remove all such '/' characters.
- Namespace
- All leading and trailing slashes '/' are not significant and should be stripped in the canonical form. They are not part of the namespace.
- Name
- All leading and trailing slashes '/' are not significant and should be stripped in the canonical form. They are not part of the name.
- Subpath
- Leading and trailing slashes '/' are not significant and should be stripped in the canonical form.

The information about how to handle "extra" slashes should be covered in How-to documentation which may be included in ECMA-427 Annexes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Ecma standardPart of the Ecma standard for PURL

    Type

    No type

    Projects

    Status
    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions