Modify

Ticket #29 (closed defect: fixed)

Opened 11 months ago

Last modified 11 months ago

Logging fails under Python 2.4

Reported by: colin@… Owned by: seb
Priority: blocker Keywords:
Cc: Launchpad Bug:

Description

In UnicodeLogRecord? the call to logging.LogRecord?.init uses the extra func parameter only available in the logging package of Python 2.5:
 http://docs.python.org/library/logging.html#logrecord-objects

Thus when using Python 2.4 it fails:

 1 2009-10-18 15:47:02,292 ERROR [                       fsserver.FSServer] (MainThread) System requirements not met:
 2 Traceback (most recent call last):
 3   File "lib/python/fsServer.py", line 43, in run
 4     import fsMonitorServer
 5   File "/home/jboss/OMERO.server-Beta-4.1.0-DEV-r5517-S1628/lib/python/fsMonitorServer.py", line 23, in ?
 6     from fsMonitor import MonitorFactory
 7   File "/home/jboss/OMERO.server-Beta-4.1.0-DEV-r5517-S1628/lib/python/fsMonitor.py", line 21, in ?
 8     PlatformMonitor = __import__(fsUtil.monitorPackage())
 9   File "/home/jboss/OMERO.server-Beta-4.1.0-DEV-r5517-S1628/lib/python/fsPyinotifyMonitor.py", line 27, in ?
10     importlog.info("Imported pyinotify version %s", str(pyinotify.__version__))
11   File "/usr/lib/python2.4/logging/__init__.py", line 969, in info
12     apply(self._log, (INFO, msg, args), kwargs)
13   File "/usr/lib/python2.4/logging/__init__.py", line 1078, in _log
14     record = self.makeRecord(self.name, level, fn, lno, msg, args, exc_info)
15   File "/usr/lib64/python2.4/site-packages/pyinotify-0.8.7-py2.4.egg/pyinotify.py", line 122, in makeRecord
16     rv = UnicodeLogRecord(name, level, fn, lno, msg, args, exc_info, func)
17   File "/usr/lib64/python2.4/site-packages/pyinotify-0.8.7-py2.4.egg/pyinotify.py", line 135, in __init__
18     msg, args, exc_info, func)
19 TypeError: __init__() takes exactly 8 arguments (9 given)
20 2009-10-18 15:47:02,306 INFO  [                       fsserver.FSServer] (MainThread) Exiting with exit code: -1

Attachments

Change History

comment:1 Changed 11 months ago by seb

  • Owner set to seb
  • Status changed from new to assigned

comment:2 Changed 11 months ago by seb

  • Status changed from assigned to closed
  • Resolution set to fixed

Hi Colin,

Thanks for your report I think  this commit should fix the issue.

Cordially,

sébastien

View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
The resolution will be deleted. Next status will be 'reopened'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.