Description of problem: python-slimit recently switched to using python 3 for the main executable /usr/bin/slimit. But it doesn't seem to work with python 3 yet, so it should either fix the incompatibility or switch back to python 2 until the incompatibility is fixed. Version-Release number of selected component (if applicable): python3-slimit-0.8.1-1.fc23.noarch How reproducible: always Steps to Reproduce: 1. slimit --mangle < foo.js > foo-min.js Actual results: Traceback (most recent call last): File "/usr/bin/slimit", line 9, in <module> load_entry_point('slimit==0.8.1', 'console_scripts', 'slimit')() File "/usr/lib/python3.4/site-packages/slimit/minifier.py", line 69, in main text, mangle=options.mangle, mangle_toplevel=options.mangle_toplevel) File "/usr/lib/python3.4/site-packages/slimit/minifier.py", line 38, in minify tree = parser.parse(text) File "/usr/lib/python3.4/site-packages/slimit/parser.py", line 93, in parse return self.parser.parse(text, lexer=self.lexer, debug=debug) File "/usr/lib/python3.4/site-packages/ply/yacc.py", line 265, in parse return self.parseopt_notrack(input,lexer,debug,tracking,tokenfunc) File "/usr/lib/python3.4/site-packages/ply/yacc.py", line 971, in parseopt_notrack p.callable(pslice) File "/usr/lib/python3.4/site-packages/slimit/parser.py", line 1101, in p_case_block p[0] = p[2:-1] File "/usr/lib/python3.4/site-packages/ply/yacc.py", line 198, in __getitem__ if n >= 0: return self.slice[n].value TypeError: unorderable types: slice() >= int() Expected results: No error
This bug appears to have been reported against 'rawhide' during the Fedora 23 development cycle. Changing version to '23'. (As we did not run this process for some time, it could affect also pre-Fedora 23 development cycle bugs. We are very sorry. It will help us with cleanup during Fedora 23 End Of Life. Thank you.) More information and reason for this action is here: https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora23
It turns out that this is actually a bug in python-ply, not slimit: https://github.com/dabeaz/ply/issues/63
python-ply-3.6-2.fc23 has been submitted as an update for Fedora 23. https://admin.fedoraproject.org/updates/python-ply-3.6-2.fc23
Now it works, but spits out a bunch of warnings: WARNING: Couldn't write lextab module <module 'slimit.lextab' from '/usr/lib/python3.4/site-packages/slimit/lextab.py'>. Won't overwrite existing lextab module WARNING: yacc table file version is out of date WARNING: Token 'SUPER' defined, but not used WARNING: Token 'IMPORT' defined, but not used WARNING: Token 'ENUM' defined, but not used WARNING: Token 'EXTENDS' defined, but not used WARNING: Token 'LINE_COMMENT' defined, but not used WARNING: Token 'CONST' defined, but not used WARNING: Token 'BLOCK_COMMENT' defined, but not used WARNING: Token 'LINE_TERMINATOR' defined, but not used WARNING: Token 'EXPORT' defined, but not used WARNING: Token 'CLASS' defined, but not used WARNING: There are 10 unused tokens WARNING: Couldn't create <module 'slimit.yacctab' from '/usr/lib/python3.4/site-packages/slimit/yacctab.py'>. Won't overwrite existing tabmodule I don't know whether it can cause any real problems.
(In reply to Michael Simacek from comment #4) > Now it works, but spits out a bunch of warnings: > WARNING: Couldn't write lextab module <module 'slimit.lextab' from > '/usr/lib/python3.4/site-packages/slimit/lextab.py'>. Won't overwrite > existing lextab module > WARNING: yacc table file version is out of date > WARNING: Token 'SUPER' defined, but not used > WARNING: Token 'IMPORT' defined, but not used > WARNING: Token 'ENUM' defined, but not used > WARNING: Token 'EXTENDS' defined, but not used > WARNING: Token 'LINE_COMMENT' defined, but not used > WARNING: Token 'CONST' defined, but not used > WARNING: Token 'BLOCK_COMMENT' defined, but not used > WARNING: Token 'LINE_TERMINATOR' defined, but not used > WARNING: Token 'EXPORT' defined, but not used > WARNING: Token 'CLASS' defined, but not used > WARNING: There are 10 unused tokens > WARNING: Couldn't create <module 'slimit.yacctab' from > '/usr/lib/python3.4/site-packages/slimit/yacctab.py'>. Won't overwrite > existing tabmodule > > I don't know whether it can cause any real problems. Yes, I've seen the warnings but it appears to run to completion and produce sensible output, so I ran with it.
Package python-ply-3.6-2.fc23: * should fix your issue, * was pushed to the Fedora 23 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing python-ply-3.6-2.fc23' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2015-13668/python-ply-3.6-2.fc23 then log in and leave karma (feedback).
python-ply-3.6-2.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.