collective / zestreleaser.towncrier

GNU General Public License v2.0
1 stars 1 forks source link

prerelease and postrelease called separate #20

Closed jensens closed 4 years ago

jensens commented 4 years ago

Using the plugin in a way that first prerelease is called, release done outside, then postrelease, postrelease tries to execute towncrier again.

We tried this here in before_deploy https://github.com/authomatic/authomatic/blob/b359af492cb2c971cc6f84f338e0ef50e2c45667/.travis.yml#L24

But its executed in after_deploy because the marker is not there from the first run. https://github.com/collective/zestreleaser.towncrier/blob/2480c8a2b4cd6137d2064faac001762356475a6c/src/zestreleaser/towncrier/__init__.py#L146

jensens commented 4 years ago

Btw, we use zestreleaser.towncrier 1.2.0 https://travis-ci.org/authomatic/authomatic/builds/617256400#L402

mauritsvanrees commented 4 years ago

Version 1.2.0 already contains PR #18, which should avoid running towncrier. It basically only sets a key in the data to tell the rest of postrelease to not update the history. It does check if towncrier is available, but it does not call it.

The only time that towncrier is really called, in non-drafts mode, is in the middle of the prerelease phase.

So I don't see what the problem would be. What are you seeing that is wrong? On your Travis link I only see a problem during prerelease because you are on a tag or have local changes. That can be a problem with the .gitignore file.

jensens commented 4 years ago

Hmm, we had the problem, but now we used a different approach. I can not tell what exactly was wrong here now - or if it was a different problem.