Skip to content

Conversation

@d-ryzhykau
Copy link
Contributor

Delay construction of version and release patterns until runtime.
This will allow to use non-default prerelease tag.

Delay construction of version and release patterns until runtime.
This will allow to use non-default prerelease tag.
Copy link
Member

@danth danth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the benefit of this vs what we had previously?

@saseith
Copy link
Contributor

saseith commented Jul 14, 2022

What is the benefit of this vs what we had previously?

We actually had this exact issue in one of our uses. As the code currently stands, it is not possible to override the pre-release tag using cli flags and only works through changing it in the config files. The commit here appears to fix that issue since it does the check after init

@d-ryzhykau
Copy link
Contributor Author

@saseith is right. Without this change, the "release_version_regex" and "version_regex" are assigned during the module import. Thus the "prerelease_tag" value used in the patterns will be the one available during the import time, which is before the runtime and before overwriting the config with values from the CLI.

@danth
Copy link
Member

danth commented Jul 15, 2022

I see; will merge this now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants