Import error in pkg_resources.py with Python 2.4

Showing 1-2 of 2 messages
Import error in pkg_resources.py with Python 2.4 falkb 1/17/13 2:10 AM
Hi,
according to the Trac API [1], there is

def get_templates_dirs(self):
        from pkg_resources import resource_filename
        return [resource_filename(__name__, 'templates')]

but pkg_resources.py raises an "ImportError: No module named path" with Python 2.4. Unfortunately, an update to 2.5 is not an option, although 2.5 works well.

What can I do? Details are here in [2]. This function get_templates_dirs is quite standard and reused by copy in several plugins.

[1] http://trac.edgewall.org/wiki/TracDev/PluginDevelopment/ExtensionPoints/trac.web.chrome.ITemplateProvider
[2] http://trac-hacks.org/ticket/10798


CU, F@lk

----
R&D Software
Baumer Optronic GmbH
www.baumer.com




Gesch?ftsf?hrer: Dr. Albert Schmidt* Dr. Oliver Vietze
Sitz der Gesellschaft: Radeberg
Amtsgericht Dresden: HRB 15379
Ust. ID: DE 189714583


RE: Import error in pkg_resources.py with Python 2.4 falkb 1/17/13 7:31 AM
I wrote:
> but pkg_resources.py raises an "ImportError: No module named path"

Meanwhile jun66j5 found out it was just a subsequent error of another problem. If interested, see the ticket for details. Kudos to jun66j5.