Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

running portia on macosx #7

Closed
diegoceccarelli opened this issue Apr 2, 2014 · 4 comments
Closed

running portia on macosx #7

diegoceccarelli opened this issue Apr 2, 2014 · 4 comments
Labels

Comments

@diegoceccarelli
Copy link

diego@syrah:/tmp/portia/slyd (master)$ twistd -n slyd
/private/tmp/portia/slyd/slyd/bot.py:40: ScrapyDeprecationWarning: scrapy.spider.BaseSpider is deprecated, instantiate scrapy.spider.Spider instead.
  spider = BaseSpider('slyd')
Traceback (most recent call last):
  File "/usr/bin/twistd", line 14, in <module>
    run()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/twisted/scripts/twistd.py", line 27, in run
    app.run(runApp, ServerOptions)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/twisted/application/app.py", line 652, in run
    runApp(config)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/twisted/scripts/twistd.py", line 23, in runApp
    _SomeApplicationRunner(config).run()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/twisted/application/app.py", line 386, in run
    self.application = self.createOrGetApplication()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/twisted/application/app.py", line 446, in createOrGetApplication
    ser = plg.makeService(self.config.subOptions)
  File "/private/tmp/portia/slyd/slyd/tap.py", line 55, in makeService
    root = create_root(config)
  File "/private/tmp/portia/slyd/slyd/tap.py", line 46, in create_root
    projects.putChild("bot", create_bot_resource(spec_manager))
  File "/private/tmp/portia/slyd/slyd/bot.py", line 34, in create_bot_resource
    bot = Bot(spec_manager.settings, spec_manager)
  File "/private/tmp/portia/slyd/slyd/bot.py", line 48, in __init__
    crawler.configure()
  File "/Library/Python/2.7/site-packages/scrapy/crawler.py", line 47, in configure
    self.engine = ExecutionEngine(self, self._spider_closed)
  File "/Library/Python/2.7/site-packages/scrapy/core/engine.py", line 63, in __init__
    self.downloader = Downloader(crawler)
  File "/Library/Python/2.7/site-packages/scrapy/core/downloader/__init__.py", line 73, in __init__
    self.handlers = DownloadHandlers(crawler)
  File "/Library/Python/2.7/site-packages/scrapy/core/downloader/handlers/__init__.py", line 18, in __init__
    cls = load_object(clspath)
  File "/Library/Python/2.7/site-packages/scrapy/utils/misc.py", line 40, in load_object
    mod = import_module(module)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/importlib/__init__.py", line 37, in import_module
    __import__(name)
  File "/Library/Python/2.7/site-packages/scrapy/core/downloader/handlers/s3.py", line 4, in <module>
    from .http import HTTPDownloadHandler
  File "/Library/Python/2.7/site-packages/scrapy/core/downloader/handlers/http.py", line 5, in <module>
    from .http11 import HTTP11DownloadHandler as HTTPDownloadHandler
  File "/Library/Python/2.7/site-packages/scrapy/core/downloader/handlers/http11.py", line 15, in <module>
    from scrapy.xlib.tx import Agent, ProxyAgent, ResponseDone, \
  File "/Library/Python/2.7/site-packages/scrapy/xlib/tx/__init__.py", line 6, in <module>
    from . import client, endpoints
  File "/Library/Python/2.7/site-packages/scrapy/xlib/tx/client.py", line 37, in <module>
    from .endpoints import TCP4ClientEndpoint, SSL4ClientEndpoint
  File "/Library/Python/2.7/site-packages/scrapy/xlib/tx/endpoints.py", line 222, in <module>
    interfaces.IProcessTransport, '_process')):
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/zope/interface/declarations.py", line 495, in __call__
    raise TypeError("Can't use implementer with classes.  Use one of "
TypeError: Can't use implementer with classes.  Use one of the class-declaration functions instead.
@duendex
Copy link
Contributor

duendex commented Apr 2, 2014

Diego, are you using virtualenv to install/run the project?

@diegoceccarelli
Copy link
Author

nope, but I've a linux server and I run it there, it's not a big issue.

On Wed, Apr 2, 2014 at 3:21 PM, duendex notifications@github.com wrote:

Diego, are you using virtualenv to install/run the project?

Reply to this email directly or view it on GitHubhttps://github.com//issues/7#issuecomment-39328831
.

Computers are useless. They can only give you answers.
(Pablo Picasso)


Diego Ceccarelli
High Performance Computing Laboratory
Information Science and Technologies Institute (ISTI)
Italian National Research Council (CNR)
Via Moruzzi, 1
56124 - Pisa - Italy

Phone: +39 050 315 2984
Fax: +39 050 315 2040


@duendex
Copy link
Contributor

duendex commented Apr 2, 2014

Ok, but if you end up needing to run it on OSX, please try with virtualenv. That should solve your issue.

@halbtuerke
Copy link

In addition to using virtualenv I had to install the requirements in the following way:

CFLAGS= pip install -r requirements.txt

It seems like Xcode 5.1 under Mac OS X 10.9 broke compilation of a lot of modules.
Additionaly running twistd without sudo wasn't working.

@tpeng tpeng closed this as completed Oct 22, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants