plyj
plyj copied to clipboard
May I know whether there is rpm built for this module?
I am trying to distribute some tool developed by using this module and now I need the rpm file to have this module installed in a distributed environment. Thanks!
As of yet there is no package built, neither rpm or deb nor anything else. If you or someone else know something about packaging Python packages, that would be great. I could probably hack something together but I don't know if that's going to be useful. Maybe I can find another project as an example...
Thanks for getting back to me. I actually tried to package it myself but using standard pythong package tool pex gave me error when using this module. It shows warning that parser.out is not there then in the program all parsed information is not available to use so it displays the error at the end. Can you please share some insights? Thanks a lot!
WARNING: Couldn't write lextab module 'lextab'. [Errno 20] Not a directory: '/x/home03/juahu/bom_auto_creation/build/dist/createbom/.deps/plyj-0.1-py2.7.egg/plyj/lextab.py'
WARNING: Couldn't open 'parser.out'. [Errno 20] Not a directory: '/x/home03/juahu/bom_auto_creation/build/dist/createbom/.deps/plyj-0.1-py2.7.egg/plyj/parser.out'
WARNING: Token 'BLOCK_COMMENT' defined, but not used
WARNING: Token 'LINE_COMMENT' defined, but not used
WARNING: There are 2 unused tokens
Generating LALR tables
WARNING: Couldn't create 'parsetab'. [Errno 20] Not a directory: '/x/home03/juahu/bom_auto_creation/build/dist/createbom/.deps/plyj-0.1-py2.7.egg/plyj/parsetab.py'
Traceback (most recent call last):
File "/x/home03/juahu/bom_auto_creation/build/dist/createbom/.bootstrap/_pex/pex.py", line 271, in execute
File "/x/home03/juahu/bom_auto_creation/build/dist/createbom/.bootstrap/_pex/pex.py", line 320, in execute_entry
File "/x/home03/juahu/bom_auto_creation/build/dist/createbom/.bootstrap/_pex/pex.py", line 337, in execute_module
File "/x/opt/pp/lib/python2.7/runpy.py", line 180, in run_module
fname, loader, pkg_name)
File "/x/opt/pp/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/x/home03/juahu/bom_auto_creation/build/dist/createbom/.deps/bom_auto_creation-0.0.1-py2.7.egg/bom_auto_creation/createBOM.py", line 71, in
I have the same issue as @yelleave have. Can anyone provide some solution ?
I am having a similar issue which is coming from a line "parser = ply.Parser()" that I use after importing ply.parse as plyj. Was anyone able to understand where the error was coming from or able to fix it?
The logic for how and where the lextab is written is here. From what I can tell it defaults to the current directory, whatever that means in the context of a library. It would definitely make sense to compile the tables (an analogous thing happens for the parsetab) when packaging and not when using the library for the first time. I guess the destination for the file needs to be exposed in plyj's API in a useful manner, right? What do you reckon?