Follow-up from "adding a create module argument (-cm) to use a model template for model..."
The following discussion from !217 (merged) should be addressed:
-
@frederic.lemmel started a discussion: (+1 comment) A possible improvement (for a future branch) would be to use standard library
importlib.resources
to safely retrieve the path for./pyxel/models
and./pyxel/templates
.For example (see here):
>>> from importlib import resources >>> import pyxel >>> with resources.path(package=pyxel, resource='models') as pth: ... print(f"Path for 'pyxel.models' is: {pth}")