modern macro systems hook into python's import machinery to handle / expand macros, instead of hooking codes or executing code inside .pth files
Take a look at https://github.com/Technologicat/mcpyrate for example
Take a look at https://github.com/Technologicat/mcpyrate for example
I ended up writing a custom package that expands on the one "macro" (really a small DSL) that does it very quickly, and uses the `.pth` import so it automatically loads, via entrypoint especially, rather than being a constant import in the files that uses the DSL.
`mcpyrate` looks very cool.