Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

check-adr-repo should not fail for newly created ADRs without a number in the proposed state #120

Open
vinman1 opened this issue Aug 17, 2023 · 1 comment

Comments

@vinman1
Copy link

vinman1 commented Aug 17, 2023

  • ADR Process Tool version: 0.20.0

  • Python version: 3.11.4

  • Operating System:

    executed from a debian container:

    PRETTY_NAME="Debian GNU/Linux 11 (bullseye)"
    NAME="Debian GNU/Linux"
    VERSION_ID="11"
    VERSION="11 (bullseye)"
    VERSION_CODENAME=bullseye
    ID=debian
    HOME_URL="https://www.debian.org/"
    SUPPORT_URL="https://www.debian.org/support"
    BUG_REPORT_URL="https://bugs.debian.org/"

    host:

    NAME="Fedora Linux"
    VERSION="37 (KDE Plasma)"
    ID=fedora
    VERSION_ID=37
    VERSION_CODENAME=""
    PLATFORM_ID="platform:f37"
    PRETTY_NAME="Fedora Linux 37 (KDE Plasma)"
    ANSI_COLOR="0;38;2;60;110;180"
    LOGO=fedora-logo-icon
    CPE_NAME="cpe:/o:fedoraproject:fedora:37"
    DEFAULT_HOSTNAME="fedora"
    HOME_URL="https://fedoraproject.org/"
    DOCUMENTATION_URL="https://docs.fedoraproject.org/en-US/fedora/f37/system-administrators-guide/"
    SUPPORT_URL="https://ask.fedoraproject.org/"
    BUG_REPORT_URL="https://bugzilla.redhat.com/"
    REDHAT_BUGZILLA_PRODUCT="Fedora"
    REDHAT_BUGZILLA_PRODUCT_VERSION=37
    REDHAT_SUPPORT_PRODUCT="Fedora"
    REDHAT_SUPPORT_PRODUCT_VERSION=37
    SUPPORT_END=2023-11-14
    VARIANT="KDE Plasma"
    VARIANT_ID=kde

Description

When trying to follow the workflow:

  1. Ask pyadr to create a new ADR from a template
  2. write the proposed text to my ADR
  3. commit and push my changes
  4. Ask pyadr to check my repo integrity as part of a ci pipeline job

The ci pipeline job fails with error.

I expect a newly generated ADR file, which is in the proposed state, to pass the repo integrity check even if it doesn't yet have a number assigned to it.

What I Did

  1. run pyadr new My New ADR locally on my machine to generate a new ADR in the proposed state
  2. update the text of my ADR.
  3. run pyadr check-adr-repo locally (or as part of my CI pipeline) to check my ADR repo integrity, and it fails:
(status to verify against: '<any status with an id>')
ADR(s)'s filename follow the format '[0-9][0-9][0-9][0-9]-<adr-title-in-slug-format>.md', but:
  => 'docs/decisions/XXXX-my-new-adr.md' does not start with '[0-9][0-9][0-9][0-9]-'.
@vinman1
Copy link
Author

vinman1 commented Aug 17, 2023

In our group, our general workflow will be:

  1. create new ADRs in the proposed state, and commit and push them for discussion, review with the larger community.
  2. We'd like to run the pyadr check-adr-repo command as a ci pipeline lint check whenever changes are made.
  3. At some later time, once a review and discussion has been had, to update the ADR and run pyadr accept <filename>.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant