Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork295
fix(commands/bump): prevent using incremental changelog when it is set to false in config#996
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:master
Are you sure you want to change the base?
Uh oh!
There was an error while loading.Please reload this page.
Conversation
661a140
tod4894e5
Comparecodecovbot commentedFeb 29, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@## master #996 +/- ##==========================================+ Coverage 97.33% 97.45% +0.11%========================================== Files 42 55 +13 Lines 2104 2398 +294 ==========================================+ Hits 2048 2337 +289- Misses 56 61 +5
Flags with carried forward coverage won't be shown.Click here to find out more. ☔ View full report in Codecov by Sentry. |
…t to false in config
d4894e5
to45b9352
CompareUh oh!
There was an error while loading.Please reload this page.
Just opening the debate: wouldn't it be easier and more consistent to fix/align the default By adding a fourth settings source of trust (defaults, user settings, cli flags and now mutated settings, fifth if you add the fact that plugins can override some settings), I feel that we are fixing a symptom but making the problem more complex. |
josix commentedMar 11, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Yeah, I think that would be a better way to address the issue if possible. The implementation would be easier and also could prevent overriding the behaviors from multiple sources when running the |
Could you make a proposal for this? It sounds interesting, would be nice if we can simplify the settings |
I'm a bit confused here. I thought we could solve it by reading the value from config? |
I think there are total three combinations of configurations here:
The 1st & 3rd cases would cause ambiguity when we're reading the value from |
Lee-W commentedApr 2, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
I thought the one from the config should overwrite the default. Or did I miss anything? |
Hello, Do you guys have any news on this fix ? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
I probably won't say I love this idea, but it is an acceptable workaround before we introduce a better config system.@josix, could you please rebase it and add some tests to verify it?
Uh oh!
There was an error while loading.Please reload this page.
Fix#883
Description
Since the default behavior of
cz bump --changelog
is to write incremental changelog, which is different from the default value ofchangelog_incremental
, it is hard to know the value is set from user or the default setting, To address it, I created one more member inBaseConfig
to record which property is defined from users so that we could distinguish the value is from default setting or users.Checklist
./scripts/format
and./scripts/test
locally to ensure this change passes linter check and testExpected behavior
cz bump --changelog
should work asfalse
when user configurechangelog_incremental
tofalse
.Steps to Test This Pull Request
Modify the CHANGELOG file

Configure
pyproject.toml
withchangelog_incremental = false
Run
cz bump --changelog
Check the CHANGELOG, which the new added content should be replaced

Additional context
ditto.