Hi,
I’m testing plugin. Quite easy to implement at the beginning.
Just creating a folder in .config/tryton/x.x/plugins/ and then adding an init.py file like this:
You could use the same machinery as in tryton/plugins/__init__.py but I would not recommend it because it is too complex.
But I would not recommend neither your solution because you may let tryton client load any “unsafe” module from this user directory. I think the best is to keep plugin into a single file.
I find this really weird … importing standard libraries is working, but not importing files in the same folder.
What I did for Windows is using a subprocess to do things. Otherwise you have to build the client yourself. I needed for example win32com.client. Because Python was installed with Anaconda, the library was already there.
The plugin execute a report in Tryton, stored the data and used a subprocess to call an external windows application (label program), put the report data into that application and print a label.