What does your requirements.txt file look like?

On Dec 7, 2016 12:16 AM, "Raymond Lau" <[email protected]> wrote:

> Hey, I'm trying to get my Pyramid app deployed on Elastic Beanstalk.  But
> I'm getting the error:
>
>
>
> [Wed Dec 07 05:42:22.567889 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 55221] ImportError: No module named 'zope.deprecation'
> [Wed Dec 07 05:42:23.572279 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573] mod_wsgi (pid=3438): Target WSGI script '/opt/python/current/app/
> application.py' cannot be loaded as Python module.
> [Wed Dec 07 05:42:23.572326 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573] mod_wsgi (pid=3438): Exception occurred processing WSGI script
> '/opt/python/current/app/application.py'.
> [Wed Dec 07 05:42:23.572355 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573] Traceback (most recent call last):
> [Wed Dec 07 05:42:23.572396 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]   File "/opt/python/current/app/application.py", line 1, in
> <module>
> [Wed Dec 07 05:42:23.572402 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]     from pyramid.paster import get_app, setup_logging
> [Wed Dec 07 05:42:23.572424 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]   File "/opt/python/run/venv/lib/python3.4/site-packages/
> pyramid/paster.py", line 10, in <module>
> [Wed Dec 07 05:42:23.572428 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]     from pyramid.scripting import prepare
> [Wed Dec 07 05:42:23.572447 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]   File "/opt/python/run/venv/lib/python3.4/site-packages/
> pyramid/scripting.py", line 1, in <module>
> [Wed Dec 07 05:42:23.572450 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]     from pyramid.config import global_registries
> [Wed Dec 07 05:42:23.572469 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]   File "/opt/python/run/venv/lib/python3.4/site-packages/
> pyramid/config/__init__.py", line 12, in <module>
> [Wed Dec 07 05:42:23.572473 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]     from pyramid.interfaces import (
> [Wed Dec 07 05:42:23.572490 2016] [:error] [pid 3438] [remote 127.0.0.1:
> 59573]   File "/opt/python/run/venv/lib/python3.4/site-packages/
> pyramid/interfaces.py", line 1, in <module>
>
> I tried using the application.py setup that you are using.  Did you
> encounter anything like this?  I followed everything that has been
> mentioned in this thread (ex. regarding the requirements.txt and pip
> install -e .)
>
> On Sunday, July 17, 2016 at 4:07:56 PM UTC-7, Andrew Burnett wrote:
>>
>> Does anyone have experience installing a Pyramid application via Elastic
>> Beanstalk? My application deploys but I cannot configure the
>> application's application.py (or pyramid.wsgi) file to work properly.
>> Within get_app the following error occurs:
>>
>>
>> File 
>> "/opt/python/run/venv/lib/python2.7/site-packages/pkg_resources/__init__.py",
>>  line 829, in resolve[Sun Jul 17 21:24:15.482379 2016] [:error] [pid 736] 
>> [remote 127.0.0.1:9522]     raise DistributionNotFound(req, requirers)[Sun 
>> Jul 17 21:24:15.482427 2016] [:error] [pid 736] [remote 127.0.0.1:9522] 
>> DistributionNotFound: The 'MyApp' distribution was not found and is required 
>> by the application
>>
>>
>> Where MyApp is the application I am trying to run.
>>
>>
>> Here is my application.py:
>>
>>
>> from pyramid.paster import get_app, setup_loggingimport os, site, sys
>> ini_path = os.path.join(os.path.dirname(__file__), 'production.ini')
>> setup_logging(ini_path)
>> application = get_app(ini_path, 'main')
>>
>> It seems as though the error occurs because its looking for MyApp within
>> /opt/python/run/venv/lib/python2.7/site-packages/ rather than
>> /opt/current/python/app/. What am I missing? Do I need to add something
>> to my path? Does anyone have experience with this?
>>
> --
> You received this message because you are subscribed to the Google Groups
> "pylons-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/pylons-discuss/fb78a2c5-5073-4fe3-8887-720791b26700%
> 40googlegroups.com
> <https://groups.google.com/d/msgid/pylons-discuss/fb78a2c5-5073-4fe3-8887-720791b26700%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pylons-discuss/CAEhnOswcYzfZpMjkn9ecHsCY4bq%2BqgcNQRc_%3D5kuz-XrU1159g%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to