Skip to content
Snippets Groups Projects
Closed Document.version field should be optional with default=[last_document_version]
  • View options
  • Document.version field should be optional with default=[last_document_version]

  • View options
  • Closed Issue created by Vincent Texier

    Break backward compatibility.

    Document class set the protocol version as the first mandatory constructor field.

    It is not easy for a new user to find the last version of the protocol.

    To ease the creation of a document, this field should be set by default to the last protocol version.

    So we need to set the field in last position, with the last protocol version of Duniter (12 at the time of writing) as default value.

    Before:

        def __init__(self, version: int, currency: str) -> None:
            ...

    After:

        def __init__(self, currency: str, version: int = 12) -> None:
            ...
    Edited by Moul

    Activity

    • All activity
    • Comments only
    • History only
    • Newest first
    • Oldest first