Hide navigation sidebar
Hide table of contents sidebar
Skip to content
Back to top
View this page
Toggle table of contents sidebar

# semantic_release.commit_parser.scipy module

Parses commit messages using scipy tags of the form:

    <tag>(<scope>): <subject>

    <body>

The elements <tag>, <scope> and <body> are optional. If no tag is present, the commit will be added to the changelog section “None” and no version increment will be performed.

While <scope> is supported here it isn’t actually part of the scipy style. If it is missing, parentheses around it are too. The commit should then be of the form:

    <tag>: <subject>

    <body>

To communicate a breaking change add “BREAKING CHANGE” into the body at the beginning of a paragraph. Fill this paragraph with information how to migrate from the broken behavior to the new behavior. It will be added to the “Breaking” section of the changelog.

Supported Tags:

    (
        API,
        DEP,
        ENH,
        REV,
        BUG,
        MAINT,
        BENCH,
        BLD,
    )
    DEV, DOC, STY, TST, REL, FEAT, TEST

Supported Changelog Sections:

    breaking, feature, fix, Other, None

class semantic_release.commit_parser.scipy.ScipyCommitParser(options: ScipyParserOptions | None = None)

  Bases: `AngularCommitParser`

  Parser for scipy-style commit messages

  static get_default_options() → ScipyParserOptions
  parse_message(message: str) → ParsedMessageResult | None
  parser_options

    alias of `ScipyParserOptions`

class semantic_release.commit_parser.scipy.ScipyParserOptions(minor_tags: Tuple[str, ...] = ('DEP', 'DEV', 'ENH', 'REV', 'FEAT'), patch_tags: Tuple[str, ...] = ('BLD', 'BUG', 'MAINT'), other_allowed_tags: Tuple[str, ...] = ('build', 'chore', 'ci', 'docs', 'style', 'refactor', 'test'), allowed_tags: Tuple[str, ...] = ('API', 'DEP', 'DEV', 'ENH', 'REV', 'FEAT', 'BLD', 'BUG', 'MAINT', 'BENCH', 'DOC', 'STY', 'TST', 'REL', 'TEST'), default_bump_level: LevelBump = LevelBump.NO_RELEASE, parse_squash_commits: bool = False, ignore_merge_commits: bool = False, major_tags: Tuple[str, ...] = ('API',), default_level_bump: LevelBump = LevelBump.NO_RELEASE)

  Bases: `AngularParserOptions`

  Options dataclass for ScipyCommitParser

  Scipy-style commit messages follow the same format as Angular-style commit just with different tag names.

  allowed_tags: Tuple[str, ...] = ('API', 'DEP', 'DEV', 'ENH', 'REV', 'FEAT', 'BLD', 'BUG', 'MAINT', 'BENCH', 'DOC', 'STY', 'TST', 'REL', 'TEST')

    All commit-type prefixes that are allowed.

    These are used to identify a valid commit message. If a commit message does not start with one of these prefixes, it will not be considered a valid commit message.

  default_level_bump: LevelBump = 0

    The minimum bump level to apply to valid commit message.

  major_tags: Tuple[str, ...] = ('API',)

    Commit-type prefixes that should result in a major release bump.

  minor_tags: Tuple[str, ...] = ('DEP', 'DEV', 'ENH', 'REV', 'FEAT')

    Commit-type prefixes that should result in a minor release bump.

  patch_tags: Tuple[str, ...] = ('BLD', 'BUG', 'MAINT')

    Commit-type prefixes that should result in a patch release bump.