rajvasani / pubsubhubbub

Automatically exported from code.google.com/p/pubsubhubbub
Other
0 stars 0 forks source link

Exception on pubhubsubbub hub when running on local gae server #56

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. checkout pubsubhubbub revision 221
2. checkout google app engine sdk version 1.2.4
3. run pubsubhubbub with the dev server
4. try to subscribe a callback

What is the expected output? 

the callback is subscribed

What do you see instead?

an internal error failing to import _multiprocessing

What version of the product are you using? On what operating system?

revision 221, ubuntu 9.04 python 2.6.2, gae sdk 1.2.4

Please provide any additional information below.

traceback of the exception:

INFO     2009-08-23 02:47:51,964 dev_appserver_main.py:465] Running
application pubsubhubbub on port 8080: http://localhost:8080
/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appen
gine/tools/dev_appserver.py:1659:
DeprecationWarning: the md5 module is deprecated; use hashlib instead
  description)
DEBUG    2009-08-23 02:47:57,712 dev_appserver.py:1569] Could not import
"_multiprocessing": Disallowed C-extension or built-in module
DEBUG    2009-08-23 02:47:57,729 dev_appserver.py:1569] Could not import
"_multiprocessing": Disallowed C-extension or built-in module
Traceback (most recent call last):
  File "/usr/lib/python2.6/wsgiref/handlers.py", line 93, in run
    self.result = application(self.environ, self.start_response)
  File
"/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appe
ngine/ext/webapp/__init__.py",
line 523, in __call__
    handler.handle_exception(e, self.__debug)
  File
"/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appe
ngine/ext/webapp/__init__.py",
line 388, in handle_exception
    logging.exception(exception)
  File "/usr/lib/python2.6/logging/__init__.py", line 1433, in exception
    error(*((msg,)+args), **{'exc_info': 1})
  File "/usr/lib/python2.6/logging/__init__.py", line 1426, in error
    root.error(*((msg,)+args), **kwargs)
  File "/usr/lib/python2.6/logging/__init__.py", line 1056, in error
    self._log(ERROR, msg, args, **kwargs)
  File "/usr/lib/python2.6/logging/__init__.py", line 1142, in _log
    record = self.makeRecord(self.name, level, fn, lno, msg, args,
exc_info, func, extra)
  File "/usr/lib/python2.6/logging/__init__.py", line 1117, in makeRecord
    rv = LogRecord(name, level, fn, lno, msg, args, exc_info, func)
  File "/usr/lib/python2.6/logging/__init__.py", line 272, in __init__
    from multiprocessing import current_process
  File
"/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appe
ngine/tools/dev_appserver.py",
line 1158, in Decorate
    return func(self, *args, **kwargs)
  File
"/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appe
ngine/tools/dev_appserver.py",
line 1806, in load_module
    return self.FindAndLoadModule(submodule, fullname, search_path)
  File
"/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appe
ngine/tools/dev_appserver.py",
line 1158, in Decorate
    return func(self, *args, **kwargs)
  File
"/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appe
ngine/tools/dev_appserver.py",
line 1708, in FindAndLoadModule
    description)
  File
"/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appe
ngine/tools/dev_appserver.py",
line 1158, in Decorate
    return func(self, *args, **kwargs)
  File
"/home/mariano/Proyectos/pubsubhubbub-read-only/hub/google_appengine/google/appe
ngine/tools/dev_appserver.py",
line 1659, in LoadModuleRestricted
    description)
  File "/usr/lib/python2.6/multiprocessing/__init__.py", line 83, in <module>
    import _multiprocessing
ImportError: No module named _multiprocessing
INFO     2009-08-23 02:47:57,776 dev_appserver.py:3029] "POST /subscribe
HTTP/1.1" 500 -

Original issue reported on code.google.com by luismarianoguerra@gmail.com on 23 Aug 2009 at 2:49

GoogleCodeExporter commented 9 years ago
I found the fix:

Index: main.py
===================================================================
--- main.py     (revisión: 221)
+++ main.py     (copia de trabajo)
@@ -87,6 +87,7 @@
 import hashlib
 import hmac
 import logging
+logging.logMultiprocessing = 0
 import os
 import random
 import sgmllib

Original comment by luismarianoguerra@gmail.com on 23 Aug 2009 at 3:00

GoogleCodeExporter commented 9 years ago
App Engine only works with Python 2.5.

->   File "/usr/lib/python2.6/multiprocessing/__init__.py", line 83, in <module>

Python 2.6 is primarily a compatibility release to get people ready for Python 
3.0

Original comment by bslatkin on 24 Aug 2009 at 6:15