Date: Sat, 31 May 2014 21:50:31 +0200 From: Marcus von Appen <mva@FreeBSD.org> To: Alfred Perlstein <alfred@freebsd.org> Cc: python@freebsd.org Subject: Re: Question on virtualenv (python) and FreeBSD Message-ID: <20140531195031.GA854@medusa.sysfault.org> In-Reply-To: <538A2A5F.2000601@freebsd.org> References: <538A2A5F.2000601@freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--5mCyUwZo2JvN/JJP Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On, Sat May 31, 2014, Alfred Perlstein wrote: [...] > Specifically it seems like FreeBSD is shipping a relatively stripped > down version of Python that makes using virtualenv not work. Please be precise here. It does not work for your specific use case. > > ~/gitbridge/app % python db_repo/manage.py version_control sqlite:///db.db db_repo > > Traceback (most recent call last): > > File "db_repo/manage.py", line 5, in <module> > > main(debug='False') > > File "/home/alfred/gitbridge/lib/python2.7/site-packages/migrate/versioning/shell.py", line 207, in main > > ret = command_func(**kwargs) > > File "<string>", line 2, in version_control > > File "/home/alfred/gitbridge/lib/python2.7/site-packages/migrate/versioning/util/__init__.py", line 155, in with_engine > > engine = construct_engine(url, **kw) > > File "/home/alfred/gitbridge/lib/python2.7/site-packages/migrate/versioning/util/__init__.py", line 140, in construct_engine > > return create_engine(engine, **kwargs) > > File "/home/alfred/gitbridge/lib/python2.7/site-packages/sqlalchemy/engine/__init__.py", line 344, in create_engine > > return strategy.create(*args, **kwargs) > > File "/home/alfred/gitbridge/lib/python2.7/site-packages/sqlalchemy/engine/strategies.py", line 73, in create > > dbapi =dialect_cls.dbapi(**dbapi_args) > > File "/home/alfred/gitbridge/lib/python2.7/site-packages/sqlalchemy/dialects/sqlite/pysqlite.py", line 297, in dbapi > > raise e > > ImportError: No module named pysqlite2 > > > > I have details and a workaround on my blog here (less messy than pasting > the entire 200+ lines of info into this message): > http://splbio.wordpress.com/2014/04/19/using-djangosqlalchemy-and-virtualenv-on-freebsd/ > > Basically it seems that because we don't by default ship sqlite with > Python we wind up with this odd situation where the virtualenv'd Python > can't be used for the apps that I tend to use. > > I'm wondering can something be done to make virtualenv work better out > of the box for people? Shouldn't that be rephrased to "make virtualenv work better out of the box with my applications requiring package X?" Sorry for nit-picking here. We strip certain parts of a Python default installation, which others might or might not do. One could create a FAQ, what to watch or which additional packages are recommended for installation. Right now, I do not see a huge issue here, though. If this is a problem that someone sees as more critical for users, we should rethink the customized Python installation process, which however also means that users would have to install more dependencies, when they just want a simple Python interpreter. Cheers Marcus --5mCyUwZo2JvN/JJP Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (FreeBSD) iEYEARECAAYFAlOKMoYACgkQi68/ErJnpkc8HQCfV/10p7/dyawMLGxq+dFavO9k X4AAoIPfEuplwaNUtB8s0DxPAPHS/VoM =n1Va -----END PGP SIGNATURE----- --5mCyUwZo2JvN/JJP--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20140531195031.GA854>