Skip to content
This repository was archived by the owner on Jan 8, 2026. It is now read-only.
This repository was archived by the owner on Jan 8, 2026. It is now read-only.

Data model - Integer as map key #341

Description

@JonasKruckenberg

While working on the DAG-COSE specification, this issue came up, because in COSE the header is a cbor map that is keyed with integers, not strings.
So I'm at this crossroad where I have to decide wether to break with the COSE spec (meaning that DAG-COSE object won't be valid COSE objects and cannot be decoded by existing tools) or to introduce a violation of the IPLD data model.
How should I approach this? Should DAG-COSE implementations be required to convert integers to strings ( basically aliasing the integers with strings? )?
I understand that there are languages that don't support maps that are indexed by integers but maybe we can figure something out!

For context:
COSE allows the header to be keyed with strings, but all default fields ( those that every implementation has to understand & that are registered with IANA ) are keyed by integer, where positive AND negative integers are allowed.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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