-
Notifications
You must be signed in to change notification settings - Fork 53
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
Dynamic metadata: entry-points possible? #296
Comments
We don't read |
(Unless you are using the experimental setuptools backend, in which case the above should work, we don't touch entry points if setuptools is handling it) |
Thanks for the plugin pointers! Indeed, a local plugin is easy to implement, e.g. for from __future__ import annotations
__all__ = ["dynamic_metadata"]
def __dir__() -> list[str]:
return __all__
def dynamic_metadata(
fields: frozenset[str],
settings: dict[str, object] | None = None,
) -> dict[str, str | dict[str, str | None]]:
if fields != {"scripts"}:
msg = "Only the 'scripts' field is supported"
raise ValueError(msg)
if settings:
msg = "No inline configuration is supported"
raise ValueError(msg)
scripts = {"mycmd": "mycmd:main"}
return {"scripts": scripts} I will develop this further for our specific use case and will provide a generalized plugin soon... |
Just curious if there is a timeline to make the API stable, or have a temporary API but keep compatibility with it. It's not good to always use the experimental API. |
scikit-build/dynamic-metadata#21 is the next step. |
Are other dynamic metadata than version and readme possible with scikit-build-core?
The following did not work for me (no error but also no console entry point generated):
Or do we need to implement this as a plugin similar to version and readme?
Thanks!
The text was updated successfully, but these errors were encountered: