Hi, I figured out the problem. I was relying on __file__ to get the root
directory so that I could create things like log files or exported csv
files. Apparently, this is not compatible with python eggs. After replacing
it with pkg_resources.resource_filename, I didn't face any issue with
scrapyd deployment.

On Fri, Oct 30, 2015 at 2:25 PM, Nikolaos-Digenis Karagiannis <
digenish...@gmail.com> wrote:

> What is your FEED_URI?
>
>
> On Thursday, 29 October 2015 16:27:06 UTC+2, Karthikeyan wrote:
>>
>> Hi,
>>
>> OS - Windows 7
>> scrapyd-1.1.0
>>
>> My spider creates a directory to store csv files with the
>> CsvItemExporter. It works fine on my local box.
>>
>> Although I'm able to deploy with scrapyd, my spider fails when I run it,
>> I see the following stack trace -
>>
>> 2015-10-29 19:32:51+0530 [Launcher,7564/stderr] Unhandled error in
>> Deferred:
>>
>>         Traceback (most recent call last):
>>           File "C:\Python\Python27\lib\site-packages\scrapy\cmdline.py",
>> line 150, in _run_command
>>             cmd.run(args, opts)
>>           File
>> "C:\Python\Python27\lib\site-packages\scrapy\commands\crawl.py", line 57,
>> in run
>>             self.crawler_process.crawl(spname, **opts.spargs)
>>           File "C:\Python\Python27\lib\site-packages\scrapy\crawler.py",
>> line 153, in crawl
>>             d = crawler.crawl(*args, **kwargs)
>>           File
>> "C:\Python\Python27\lib\site-packages\twisted\internet\defer.py", line
>> 1274, in unwindGenerator
>>             return _inlineCallbacks(None, gen, Deferred())
>>         --- <exception caught here> ---
>>           File
>> "C:\Python\Python27\lib\site-packages\twisted\internet\defer.py", line
>> 1128, in _inlineCallbacks
>>             result = g.send(result)
>>           File "C:\Python\Python27\lib\site-packages\scrapy\crawler.py",
>> line 70, in crawl
>>             self.spider = self._create_spider(*args, **kwargs)
>>           File "C:\Python\Python27\lib\site-packages\scrapy\crawler.py",
>> line 80, in _create_spider
>>             return self.spidercls.from_crawler(self, *args, **kwargs)
>>           File
>> "C:\Python\Python27\lib\site-packages\scrapy\spiders\__init__.py", line 50,
>> in from_crawler
>>             spider = cls(*args, **kwargs)
>>           File "build\bdist.win32\egg\tg\spiders\myspider.py", line 36,
>> in __init__
>>
>>           File "build\bdist.win32\egg\tg\spiders\myspider.py", line 39,
>> in initialize
>>
>>           File "build\bdist.win32\egg\tg\spiders\myspider.py", line 44,
>> in create_output_dirs
>>
>>           File "C:\Python\Python27\lib\os.py", line 150, in makedirs
>>             makedirs(head, mode)
>>           File "C:\Python\Python27\lib\os.py", line 157, in makedirs
>>             mkdir(name, mode)
>>         exceptions.WindowsError: [Error 3] The system cannot find the
>> path specified:
>> 'c:\\users\\axisro~1\\appdata\\local\\temp\\tg-1446127352-szqdqn.egg\\output'
>>
>> Any ideas on how to fix this?
>>
> --
> You received this message because you are subscribed to the Google Groups
> "scrapy-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to scrapy-users+unsubscr...@googlegroups.com.
> To post to this group, send email to scrapy-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/scrapy-users.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Regards,
Karthikeyan

-- 
You received this message because you are subscribed to the Google Groups 
"scrapy-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to scrapy-users+unsubscr...@googlegroups.com.
To post to this group, send email to scrapy-users@googlegroups.com.
Visit this group at http://groups.google.com/group/scrapy-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to