Skip to content

Regression/breakage on 24.7.0 - check for invalid files #632

@aviramha

Description

@aviramha

Hi,
thanks for great project!
When we upgraded to towncrier 24.7.0, we started getting this error in CI:

Looking at these files:
----
1. /home/runner/work/operator/operator/Cargo.lock
2. /home/runner/work/operator/operator/changelog.d/+url-safe-fingerprint.internal.md
3. /home/runner/work/operator/operator/changelog.d/544.changed.md
4. /home/runner/work/operator/operator/THIRDPARTY.yml
5. /home/runner/work/operator/operator/Cargo.toml
6. /home/runner/work/operator/operator/CHANGELOG.md
----
Error: Invalid news fragment name: changelog_template.jinja
If this filename is deliberate, add it to 'ignore' in your configuration.

We have changelog_template.jinja set as template in the towncrier.toml config file. I realize we can add it to ignore, but I checked other repositories and realized we've probably followed a pattern seen in other projects, where the template is inside the changes directory - as can be seen here:

I assume it's a common pattern, and will break for them. Obviously each repo can fix it by adding ignore but I think it'd be better to handle it on towncrier side, potentially by either deprecating the feature (showing warning saying it will fail in next versions) or releasing in major version, another option is to make towncrier ignore the file used in template automatically.

Would be happy to send a PR implementing one of the options.

Related:
#622
#619

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