***

Yeeeah, and so, having finished Deus Ex 3 late yesterday, I’m back to normal life and work.

Those guards sure got confused when I was sprinting through them with invisibility cloak on. Likewise, dynamic languages sure can confuse hell out of poor unsuspecting programmer: quick recap of last 3 hours of adventures:

  • Let’s set up development environment for my Pylons app on Fedora 15, Python2.7! Deployment of this app is managed by SilverLining, which has strong ties with Ubuntu and Py2.6–so I’m in unexplored teritory, exciting!
  • Replace Py 2.6 references in SilverLining to 2.7
  • Install my app: some weird errors mentioning sys.prefix but app seems to work overall
  • Let’s run tests: nose complains that there’s no such thing as “--with-pylons” flag
  • That’s because I cannot do “import pylons
  • That’s because I cannot do “import paste.registry
  • That’s because for some reason Paste didn’t get installed in lib/python but in lib/python2.7/site-packages
  • Research virtualenv
  • Research sitecustomize.py
  • Where does sys.prefix come from?
  • Dig through easy_install, setuptools
  • Dig through distutils, discover distutils.cfg, discover Distribution.parse_config_files(). Smell magic
  • Discover setuptools.dist.Distribution but no magic there
  • Discover code in distutils/__init__.py that patches Distribution class at runtime (this is the confusing dynamic bit)
  • Discover code in SilverLining that patches distutils/__init__.py
  • Finally understand what’s going on and can fix the sys.prefix issue
  • Try tests again?
Advertisements