Carbon fails to process data

Bug #467405 reported by Ian Meyer
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Graphite
Fix Released
Undecided
chrismd

Bug Description

OS: Fedora Core 11
Python version: Python 2.6 (stock FC11 version)

Traceback:
31/10/2009 19:12:01 :: Log opened.
31/10/2009 19:12:01 :: Dropping privileges to become the user apache
31/10/2009 19:12:01 :: twisted.internet.protocol.Factory starting on 2003
31/10/2009 19:12:01 :: Starting factory <twisted.internet.protocol.Factory instance at 0x22bad88>
31/10/2009 19:12:01 :: twisted.internet.protocol.Factory starting on 2004
31/10/2009 19:12:01 :: Starting factory <twisted.internet.protocol.Factory instance at 0x25521b8>
31/10/2009 19:12:01 :: twisted.internet.protocol.Factory starting on 7002
31/10/2009 19:12:01 :: Starting factory <twisted.internet.protocol.Factory instance at 0x25523f8>
31/10/2009 19:12:01 :: carbon-cache.py running
31/10/2009 19:12:44 :: Unhandled Error
Traceback (most recent call last):
  File "/usr/lib64/python2.6/threading.py", line 477, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/usr/lib64/python2.6/site-packages/twisted/python/threadpool.py", line 210, in _worker
    result = context.call(ctx, function, *args, **kwargs)
  File "/usr/lib64/python2.6/site-packages/twisted/python/context.py", line 59, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/usr/lib64/python2.6/site-packages/twisted/python/context.py", line 37, in callWithContext
    return func(*args,**kw)
--- <exception caught here> ---
  File "/opt/graphite/lib/carbon/writer.py", line 127, in writeForever
    writeCachedDataPoints()
  File "/opt/graphite/lib/carbon/writer.py", line 71, in writeCachedDataPoints
    if schema.matches(metric):
exceptions.TypeError: <lambda>() takes exactly 2 arguments (1 given)

I fiddled around with the code and figured out how to make it work.

Two things...
1. I made the matches lambda a function, mainly because I'm not good with lambda and I didn't see what the difference was from the spec vs the code in storage.py.
2. I added archives as an argument to createMetaFile() in writer.py because after the fix in #1, that was complaining.

I've attached a patch, it should apply cleanly.

Side question: Is there plans to support python < 2.6 ?

- Ian

Revision history for this message
Ian Meyer (ianmmeyer) wrote :
Revision history for this message
chrismd (chrismd) wrote :

This got fixed in the 0.9.5 release

Changed in graphite:
assignee: nobody → chrismd (chrismd)
milestone: none → 0.9.5
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.