[MacPorts] #23009: rst plugin doesn't work
#23009: rst plugin doesn't work -------------------------------+-------------------------------------------- Reporter: weakish@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: | Port: ikiwiki -------------------------------+-------------------------------------------- rst plugin doesn't work on Mac OS X 10.4.11 Error log: File "/opt/local/lib/ikiwiki/plugins/rst", line 33 return dict((k, v) for k, v in zip(*[iter(args)]*2)) ^ SyntaxError: invalid syntax I guess this is because the rst plugin uses hard-coded shebang line (#!/usr/bin/python) but Mac OS X 10.4 ships Python 2.3.5 which doesn't understand Python's iterator comprehension syntax. -- Ticket URL: <http://trac.macports.org/ticket/23009> MacPorts <http://www.macports.org/> Ports system for Mac OS
#23009: rst plugin doesn't work -------------------------------+-------------------------------------------- Reporter: weakish@… | Owner: tommyd@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: haspatch | Port: ikiwiki -------------------------------+-------------------------------------------- Changes (by jmr@…): * keywords: => haspatch * owner: macports-tickets@… => tommyd@… -- Ticket URL: <http://trac.macports.org/ticket/23009#comment:1> MacPorts <http://www.macports.org/> Ports system for Mac OS
#23009: rst plugin doesn't work -------------------------------+-------------------------------------------- Reporter: weakish@… | Owner: tommyd@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: haspatch | Port: ikiwiki -------------------------------+-------------------------------------------- Comment(by jmr@…): Please don't patch the Id line. This patch won't work, because ${prefix}/bin/python may not even exist, and it may just be a link to the system python anyway. It looks like you actually need to add a dep on one of the python ports and change the shebang to use the pythonX.Y binary it provides. -- Ticket URL: <http://trac.macports.org/ticket/23009#comment:2> MacPorts <http://www.macports.org/> Ports system for Mac OS
#23009: rst plugin doesn't work -------------------------------+-------------------------------------------- Reporter: weakish@… | Owner: tommyd@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: haspatch | Port: ikiwiki -------------------------------+-------------------------------------------- Changes (by tommyd@…): * status: new => assigned Comment: Replying to [comment:2 jmr@…]:
Please don't patch the Id line. This patch won't work, because ${prefix}/bin/python may not even exist, and it may just be a link to the system python anyway. It looks like you actually need to add a dep on one of the python ports and change the shebang to use the pythonX.Y binary it provides.
I never used the rst plugin (I don't even know what it does), but adding a dependency on python on a perl port seems awkward to me. I'd rather add a variant which pulls in the python dependency if the user requests the usage of rst, or remove rst from the distro, or give him the hint that rst is probably not working or something else. Comments? -- Ticket URL: <http://trac.macports.org/ticket/23009#comment:3> MacPorts <http://www.macports.org/> Ports system for Mac OS
#23009: rst plugin doesn't work -------------------------------+-------------------------------------------- Reporter: weakish@… | Owner: tommyd@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: haspatch | Port: ikiwiki -------------------------------+-------------------------------------------- Comment(by tommyd@…): rst is short for reStructuredText, a special wiki syntax which ikiwiki apparently supports through this plugin. The thing with the plugins is that there are dozens of them for various purposes and adding support for them all would pull in just too many dependencies (f.e. it has a plugin for just every version control system, which would probably require a variant to work correctly with). Adding variants for them all would be counter-productive, since I'm pretty sure I'm unable to maintain all of these. So I see two other options here: Patch rst(.py) so that it works with the Python it finds somewhere in the path or leave it as is (WONTFIX), because I'd open pandoras box if I enable support for each and every plugin. -- Ticket URL: <http://trac.macports.org/ticket/23009#comment:4> MacPorts <http://www.macports.org/> Ports system for Mac OS
#23009: rst plugin doesn't work -------------------------------+-------------------------------------------- Reporter: weakish@… | Owner: tommyd@… Type: defect | Status: assigned Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Keywords: haspatch | Port: ikiwiki -------------------------------+-------------------------------------------- Comment(by weakish@…): I suggest use the shebang line: (simple and not counter-productive) #!/usr/bin/env python Maybe it's a good idea to request the upstream to make this change instead of patching in Macports? I filed the bug at ikiwiki.info: http://ikiwiki.info/bugs/rst_plugin_has_python_hardcode_in_shebang_line/ -- Ticket URL: <http://trac.macports.org/ticket/23009#comment:5> MacPorts <http://www.macports.org/> Ports system for Mac OS
#23009: rst plugin doesn't work --------------------------------+------------------------------------------- Reporter: weakish@… | Owner: tommyd@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 1.8.1 Resolution: wontfix | Keywords: haspatch Port: ikiwiki | --------------------------------+------------------------------------------- Changes (by tommyd@…): * status: assigned => closed * resolution: => wontfix Comment: Ok, I guess this is indeed the best way to go. Since new versions of ikiwiki pop up every few days, MP should have it soon. -- Ticket URL: <http://trac.macports.org/ticket/23009#comment:6> MacPorts <http://www.macports.org/> Ports system for Mac OS
participants (1)
-
MacPorts