Opened 17 years ago
Closed 17 years ago
#1610 closed enhancement (invalid)
Can't install TocMacro plugin
Reported by: | Owned by: | Noah Kantrowitz | |
---|---|---|---|
Priority: | normal | Component: | TocMacro |
Severity: | normal | Keywords: | |
Cc: | Trac Release: | 0.10 |
Description
When trying to load the TocMacro plugin, Trac fails with the following error (from the log file):
ImportError: cannot import name parse_args
Below I've detailed my steps to install and run the plugin.
First I've downloaded and build the TocMacro egg the following way:
[~]# fetch -o tocmacro.zip "http://trac-hacks.org/changeset/latest/tocmacro?old_path=/&filename=tocmacro&format=zip" [~]# tar -xzf tocmacro.zip [~]# cd tocmacro/0.11/ [~/tocmacro/0.11/]# python setup.py bdist_egg
Then I ran easy_install
to make the plugin available from all Trac projects:
[~/tocmacro/0.11/]# cd dist [~/tocmacro/0.11/dist]# easy_install TracTocMacro-11.0.0.2-py2.4.egg /usr/local/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py:1386: UserWarning: Unbuilt egg for tocmacro [unknown version] (/usr/local/lib/python2.4/site-packages/tocmacro.egg) Environment.add(self,dist) /usr/local/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/package_index.py:155: UserWarning: Unbuilt egg for tocmacro [unknown version] (/usr/local/lib/python2.4/site-packages/tocmacro.egg) Environment.__init__(self,*args,**kw) /usr/local/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/setuptools/command/easy_install.py:173: UserWarning: Unbuilt egg for tocmacro [unknown version] (/usr/local/lib/python2.4/site-packages/tocmacro.egg) self.local_index = Environment(self.shadow_path+sys.path) Processing TracTocMacro-11.0.0.2-py2.4.egg Removing /usr/local/lib/python2.4/site-packages/TracTocMacro-11.0.0.2-py2.4.egg Copying TracTocMacro-11.0.0.2-py2.4.egg to /usr/local/lib/python2.4/site-packages TracTocMacro 11.0.0.2 is already the active version in easy-install.pth Installed /usr/local/lib/python2.4/site-packages/TracTocMacro-11.0.0.2-py2.4.egg Processing dependencies for TracTocMacro==11.0.0.2
To be on the safe side I also restarted Apache.
When I now looked in my trac.log file (which is set to DEBUG) I saw that it complained about not having the Genshi Python toolkit. I downloaded and installed version 0.4.1 from their Subversion repository, but now I instead got the following error in my trac.log file:
2007-06-05 15:08:37,679 Trac[loader] DEBUG: Loading egg plugin tractoc.macro from /usr/local/lib/python2.4/site-packages/TracTocMacro-11.0.0.2-py2.4.egg 2007-06-05 15:08:37,693 Trac[loader] ERROR: Failed to load plugin tractoc.macro from /usr/local/lib/python2.4/site-packages/TracTocMacro-11.0.0.2-py2.4.egg Traceback (most recent call last): File "/usr/local/lib/python2.4/site-packages/trac/loader.py", line 101, in load_components entry_point.load() File "/usr/local/lib/python2.4/site-packages/setuptools-0.6c5-py2.4.egg/pkg_resources.py", line 1830, in load entry = __import__(self.module_name, globals(),globals(), ['__name__']) File "build/bdist.freebsd-6.2-RELEASE-i386/egg/tractoc/macro.py", line 10, in ? ImportError: cannot import name parse_args
As far as I can see, parse_args
is a method on the Python optparse command line parser. And as far as I can see I've also got it installed:
[~]# locate optparse /usr/local/lib/python2.4/optparse.py /usr/local/lib/python2.4/optparse.pyc /usr/local/lib/python2.4/optparse.pyo
Attachments (0)
Change History (3)
comment:1 Changed 17 years ago by
comment:2 Changed 17 years ago by
Owner: | changed from Alec Thomas to Noah Kantrowitz |
---|
comment:3 Changed 17 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
Type: | defect → enhancement |
k, i have take the wrong version :/ i used trac v0.10.x and i have take 0.11
dear all,
i have exactly the same problem ... what is wrong ?
best regards from berlin, Yadnom