Steve, Thanks for helping here and sharing your steps to get a working Ringo application! Good to see that people give it a try and actually get it running:)
I have revised the documentation. Please note that the documentation was missing an important step: After creating a new module the generated migrations script needs to be applied to prepare the database and create tables and some entries in various tables. I see room for much more improvement and I am currently working on further improvements and bugfixes. To stay in touch with the current ringo development you can follow the RingoFramework Twitter account on https://twitter.com/RingoFramework. Torsten 2015-01-03 10:51 GMT+01:00 Steve Piercy <[email protected]>: > I completely agree. Most problems come from just getting started, and > getting it right is not easy or simple. For example, the "Installing > Pyramid" documentation page has 16 contributors and 70 commits over 4 years > to reach its current state. That's a lot of time and effort. > https://github.com/Pylons/pyramid/blob/master/docs/narr/install.rst > > Every "getting started" guide should always include system requirements > with references for how to fulfill those requirements. System requirements > include: > > * Operating system > * Python version > * Python interpreter > * package manager (setuptools or pip, but do not use both) > * virtualenv or pyvenv > * setting an environment variable to the path of the virtual environment > * whether or not to activate the virtual environment (Pyramid > documentation currently prefers NOT to activate the virtual environment, > and instead use the aforementioned environment variable) > * clone repo, if necessary > > Once you have explained all those things in your "getting started" guide, > making sure every bit is flipped into perfect alignment with each other > (also known as cosmic and planetary alignment), then and only then should > you install the package and its dependencies, e.g. `$VENV/bin/easy_install > "pyramid==1.5.2"`. > > ------------ > > Here are instructions that worked for me. I usually follow the "Pyramid > way for newbies", if there is such a thing, when installing stuff. > > I already have installed Python 2.7 (and several other versions, too) on > Mac OS X from python.org, as well as setuptools installed system wide. > > I first forked the original repo of ringo to my own repo, so that I could > push commits and send pull requests to the author. It's a good way to give > them feedback, too, by suggesting improvements. I started with the "quick > start" guide at the URL: > http://ringo-dev.intevation.de/ > ...and heavily modified it so that it would work. > > cd ~/projects > # clone my fork > hg clone ssh://[email protected]/stevepiercy/ringo > cd ringo > # set an environment variable to the virtual environment to be created > export e=~/projects/ringo/env > # create a virtual environment using the system python version 2.7 at > location $e > virtualenv -p /usr/local/bin/python $e > # do NOT activate the virtual env, instead invoking all commands by their > explicit path > # install ringo and its dependencies > $e/bin/python setup.py develop > # create a ringo app using a scaffold > $e/bin/pcreate -t ringo myfoo > cd myfoo > # install myfoo and its dependencies > $e/bin/python setup.py develop > # initialize and create the db for myfoo-admin > $e/bin/myfoo-admin db init > # add a module (note the English misspelling in the command) > $e/bin/myfoo-admin modul add bar > # start the server > $e/bin/pserve --reload development.ini > > And I now have a working ringo. > > Aside from the "getting started" documentation issues, I'm very happy to > see a new SQL-based GUI admin to build web applications on top of Pyramid. > > Finally, the patient folks on IRC in #pyramid are very helpful in pointing > folks in the right direction. They've helped me tremendously to understand > the essentials of all that system requirements stuff. > > --steve > > > On 1/2/15 at 4:25 PM, [email protected] pronounced: > > > Hi, this looks very nice, but I am not able to get it running - the >> instructions in the 'get started' section of the website do not get me >> started, unfortunately. >> First, I get >> error: invalid command 'development' >> >> remembering several other pyramid tutorials I tried to use >> python setup.py develop >> >> this seems to work, following the instructions I do >> pcreate -t ringo foo >> >> I then cd into foo, not foobar (this seems to be wrong in the >> instructions). However, there is no foo-admin. >> Hinted by the django similarity of your approach and from looking into >> ~/.pyenv/versions/2.7.9/bin I got the idea this should be >> >> ringo-admin >> but this gives me an error (see full traceback below): >> ImportError: /home/xxx/.local/lib/python2.7/site-packages/lxml/etree.so: >> undefined symbol: PyUnicodeUCS4_DecodeLatin1 >> >> Argh, an unicode error, no, please not that kind of problems... I am >> giving up here for today. >> >> I think I have to write about my experiences with several other pyramid >> based projects here. I have had similar problems with kotti and ptah in the >> recent past. I hope writing about it here will not be seen as ranting, but >> may give you an insight about the newcomer perspective. >> I looked at pyramid and was extremely satisfied, this really looks like >> the best way to build websites (for me) after some years of experience with >> several other (non-python) frameworks. I am really deeply impressed about >> the approaches taken with pyramid and the extensive documentation, >> everything I see sets a really very high quality standard. However, after >> some playing around of course I came to the point of not wanting to >> reinvent all the wheels, not only because I am a lazy dog, but because of >> the fear of doing things wrong. Especially all things security, like >> permissions, user signup and forms I really would like to build on >> something battletested, so I was starting to look into the several things >> that are out there and build up on pyramid, like kotti and ptah, and now >> ringo. >> The most significant experiences with these have been that I was not able >> to get them running. >> What is frustrating: I read a little bit into the sources, but I was not >> able to solve the problems. And what was even more frustrating was the >> knowledge, that this all is not some deeply involved hardcore hacker stuff >> that I am not understanding, it is all packaging and version isolation >> problems on the surface, so I feel like some little thing is keeping me >> away from usig all that great stuff because, of course, I can not build a >> real website with anything that throws errors I can not solve. >> So after reading lots of pyramid docs, studying sqlalchemy and several >> form libraries and trying to find the best way to handle user registrations >> and password issues I am now hitting the wall with "stupid little things" >> that all have to do with the setup process and the python environment. >> Yes, I know, I have to study every detail the python setup end deployment >> environment and understand the effects it produces in different python >> versions or what it means to use pyenv vs. vritualenvs and how this could >> hit me on setting up different webserver environments - I still did not do >> it, as it looked like "some periphal knowledge about the setup process that >> will not be so problematic" - it turnes out that it is the main problem I >> have now and I feel like I can not use all these great tools at my hands >> because of not knowing about this basic setup things. >> Ok, I know this is all my fault not studying all the details about the >> python setup process (BORING!) - but to make it a little bit more >> constructive I would like to ask all you great developers out there: please >> test your setup instructions, especially the ones on page one, manually and >> test them in a "fresh" python environment, test them with pyenv and several >> python versions, test them on a stock debian and ubuntu with system python, >> and please always link to the relevant knowledge about the setup process - >> please avoid magic that does not work. >> BTW unfortunately the wild history of python packaging leads to many >> irrelevant and misleading information on the web, so it is totally ok to >> link to the really needed information. >> I am now trying to dig into http://pythonhosted.org// >> setuptools/setuptools.html to better understand all that problems, but >> this is a real torture. I would rather just like to use this stuff and have >> it working, sigh... >> >> Thanks for your attention, >> Tam >> >> [1] Full traceback of ringo-admin: >> >> Traceback (most recent call last): >> File "/home/xxx/.pyenv/versions/2.7.9/bin/ringo-admin", line 9, in >> <module> >> load_entry_point('ringo==0.17.0', 'console_scripts', 'ringo-admin')() >> File "/home/xxx/Dev/Python/pyramid-ringo/ringo-hg/ringo/scripts/admin.py", >> line 221, in main >> args.func(args) >> File "/home/xxx/Dev/Python/pyramid-ringo/ringo-hg/ringo/scripts/db.py", >> line 140, in handle_db_init_command >> handle_db_upgrade_command(args) >> File "/home/xxx/Dev/Python/pyramid-ringo/ringo-hg/ringo/scripts/db.py", >> line 144, in handle_db_upgrade_command >> cfg = get_alembic_config(args) >> File "/home/xxx/Dev/Python/pyramid-ringo/ringo-hg/ringo/scripts/db.py", >> line 132, in get_alembic_config >> app_config = get_appsettings(args.config) >> File "/home/xxx/.local/lib/python2.7/site-packages/pyramid/paster.py", >> line 53, in get_appsettings >> global_conf=options) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 261, in appconfig >> global_conf=global_conf) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 296, in loadcontext >> global_conf=global_conf) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 320, in _loadconfig >> return loader.get_context(object_type, name, global_conf) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 454, in get_context >> section) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 476, in _context_from_use >> object_type, name=use, global_conf=global_conf) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 406, in get_context >> global_conf=global_conf) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 296, in loadcontext >> global_conf=global_conf) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 328, in _loadegg >> return loader.get_context(object_type, name, global_conf) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 620, in get_context >> object_type, name=name) >> File "/home/xxx/.local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", >> line 646, in find_egg_entry_point >> possible.append((entry.load(), protocol, entry.name)) >> File "build/bdist.linux-x86_64/egg/pkg_resources.py", line 2184, in load >> ['__name__']) >> File "/home/xxx/Dev/Python/pyramid-ringo/foo/foo/__init__.py", line 6, >> in <module> >> from ringo.config import setup_modules >> File "/home/xxx/Dev/Python/pyramid-ringo/ringo-hg/ringo/config.py", line >> 14, in <module> >> from ringo.views.base import ( >> File >> "/home/xxx/Dev/Python/pyramid-ringo/ringo-hg/ringo/views/base/__init__.py", >> line 28, in <module> >> from ringo.views.base.print_ import ( >> File >> "/home/xxx/Dev/Python/pyramid-ringo/ringo-hg/ringo/views/base/print_.py", >> line 3, in <module> >> from py3o.template import Template >> File "build/bdist.linux-x86_64/egg/py3o/template/__init__.py", line 6, >> in <module> >> File "build/bdist.linux-x86_64/egg/py3o/template/main.py", line 6, in >> <module> >> ImportError: /home/xxx/.local/lib/python2.7/site-packages/lxml/etree.so: >> undefined symbol: PyUnicodeUCS4_DecodeLatin1 >> >> >> > ------------------------ > Steve Piercy, Soquel, CA > > > -- > You received this message because you are subscribed to a topic in the > Google Groups "pylons-discuss" group. > To unsubscribe from this topic, visit https://groups.google.com/d/ > topic/pylons-discuss/v1JosQgO9OQ/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/pylons-discuss. > 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]. Visit this group at http://groups.google.com/group/pylons-discuss. For more options, visit https://groups.google.com/d/optout.
