Is there an equivalent for setup.py's MODULE2PREFIX in pyproject.toml?

I am working with custom module prefix for custom tryton modules, say ‘my_prefix’ instead of default ‘trytond’.
I have custom modules that depend on other custom modules.

Before the transition to pyproject.toml, in setup.py, there has been a dict

MODULE2PREFIX = {'modulename': 'my_prefix'}

to give the correct prefix for custom modules dependancy.

Is it possible to give this prefix information in pyproject.toml?

Thanks for any hint.

Yes, hatch-tryton has an option [tool.hatch.metadata.hooks.tryton] prefixes which may be used to change the default trytond prefix for another one for package dependency.

You can also use this style:

[tool.hatch.metadata.hooks.tryton.prefixes]
account_1 = "vendor-prefix1"
account_extension3 = "vendor-prefix2"
party_extension1 = "vendor-prefix1"

Thank you, tried both, and both works. :+1:

There is a typo in the cookiecutter-module template.

I submitted a change to fix it.