Open
Description
Currently the python component is... a bit quirky.
The a few things I've found which seem sort of easy to fix if your interested in getting PRs for each of them:
app.py
getting transformed into__main__.py
and the__init__.py
being echoed into the python package from a shell script, definitely resulted in several minutes of confusion looking for the python library code (which I'd like to be able to save other devs in future)- The level of code duplication between Python
app.py
and JavaScriptapp.js
seems like it could be improved but that would require one to depend on the other. - The need to use the import module to import it as the package doesn't use a "normal import mechanism" compatible name. Some find and replace work will get this taken care of.
- Performing
re.compile()
(import aliasedfrom re import compile as recompile
) during class init instead of as part of a module load - Having everything in
__main__.py
makes it more challenging to read and understand things than it needs to be. - The deeply nested sections of data processing use a lot of helper functions that could be moved to the module level and tidied a bit by inverting some
if
conditions to remove unnecessary use ofpass
and putting the actually desired output inside theelse
I suppose the TLDR is... There's quite a lot of refactoring opportunities in the python code (and the python packaging) but the code also looks like it has a very personal style, so if you would prefer to not have significant refactoring PRs submitted, then it would be good to know before I went ahead and wrote one, or multiple 😅
Metadata
Metadata
Assignees
Labels
No labels