So in sanitizers/chronographer-github-app#44, @praiskup reported $sbj as follows:
I opened this, because we hit a real-life issue with towncrier:
$ towncrier create foo.bar.baz.config
Created news fragment at /home/praiskup/rh/projects/mock/mock/releng/release-notes-next/foo.bar.baz.config
At least we were allowed to create such file, I assumed that it "is a correct snippet" then, and I'd expect that the action accepts it as well. But is this a bug of towncrier create?
This created a false sense of implied correctness, but I'm sure that towncrier build will get confused trying to identify this file and assign identifier+category.
https://towncrier.readthedocs.io/en/stable/tutorial.html#creating-news-fragments and https://towncrier.readthedocs.io/en/stable/cli.html#towncrier-create only roughly mentions what the shape of the filename is expected to look like.
From my earlier experience and reading the source code in the past, I know that what works is <number-ref>.<category>, <number-ref>.<category>.<discardable-suffix>, <number-ref>.<category>.<number>, <number-ref>.<category>.<number>.<discardable-suffix>, +<discardable-ref>.<category>, +<discardable-ref>.<category>.<discardable-suffix>, +<discardable-ref>.<category>.<number>, +<discardable-ref>.<category>.<number>.<discardable-suffix>.
But it doesn't look clear to a casual reader that neither <number-ref>, nor <discardable-ref> is allowed to contain a period.
So I imagine this could be turned into two issues:
- Make the
create and build subcommands coherent, interpreting the file names consistently (with proper input validation).
- Ensure the expectations are spelled out in the docs.
So in sanitizers/chronographer-github-app#44, @praiskup reported $sbj as follows:
This created a false sense of implied correctness, but I'm sure that
towncrier buildwill get confused trying to identify this file and assign identifier+category.https://towncrier.readthedocs.io/en/stable/tutorial.html#creating-news-fragments and https://towncrier.readthedocs.io/en/stable/cli.html#towncrier-create only roughly mentions what the shape of the filename is expected to look like.
From my earlier experience and reading the source code in the past, I know that what works is
<number-ref>.<category>,<number-ref>.<category>.<discardable-suffix>,<number-ref>.<category>.<number>,<number-ref>.<category>.<number>.<discardable-suffix>,+<discardable-ref>.<category>,+<discardable-ref>.<category>.<discardable-suffix>,+<discardable-ref>.<category>.<number>,+<discardable-ref>.<category>.<number>.<discardable-suffix>.But it doesn't look clear to a casual reader that neither
<number-ref>, nor<discardable-ref>is allowed to contain a period.So I imagine this could be turned into two issues:
createandbuildsubcommands coherent, interpreting the file names consistently (with proper input validation).