-
-
Notifications
You must be signed in to change notification settings - Fork 325
Sharing state across plugins #1029
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Can you please paste your build hook code showing an attempted access? I can then give you the proper path to get the object. |
@ofek I haven't attempted access or written any code for the build hook yet, as I didn't see a way to get the behavior I'd want from the documentation. The build hook would just inherit |
|
@ofek That works, thanks! It seems hook classes have a number of undocumented attributes that could use some documenting. |
I open an issue w.r.t. the undocumented metadata attribute. #1932 |
I'm the author of the setuptools plugin versioningit, and I'm currently adding support for hatch to it. At the moment, I'm having trouble converting versioningit's "onbuild" step, which embeds the project version and other details in sdists & wheels by modifying the files in the artifacts as they're being built. The text thus inserted can be templated using a number of variables containing VCS data, which is fetched by versioningit when computing the project version earlier in the build. Unfortunately, it appears that hatch's current API does not provide a facility for a build hook to access non-version data returned by a version source, which means that I would have to run a bunch of git commands twice, which I'd rather not do, as it feels redundant and would slow things down (and I've previously gotten issues about speed).
Is there a way for a build hook to access extra version source details that I'm missing? If not, could one be added?
The text was updated successfully, but these errors were encountered: