add Linux_i686
This commit is contained in:
parent
75f9a2fcbc
commit
95cd9b11f2
1644 changed files with 564260 additions and 0 deletions
|
|
@ -0,0 +1,58 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: Flask
|
||||
Version: 0.10.1
|
||||
Summary: A microframework based on Werkzeug, Jinja2 and good intentions
|
||||
Home-page: http://github.com/mitsuhiko/flask/
|
||||
Author: Armin Ronacher
|
||||
Author-email: armin.ronacher@active-4.com
|
||||
License: BSD
|
||||
Description:
|
||||
Flask
|
||||
-----
|
||||
|
||||
Flask is a microframework for Python based on Werkzeug, Jinja 2 and good
|
||||
intentions. And before you ask: It's BSD licensed!
|
||||
|
||||
Flask is Fun
|
||||
````````````
|
||||
|
||||
.. code:: python
|
||||
|
||||
from flask import Flask
|
||||
app = Flask(__name__)
|
||||
|
||||
@app.route("/")
|
||||
def hello():
|
||||
return "Hello World!"
|
||||
|
||||
if __name__ == "__main__":
|
||||
app.run()
|
||||
|
||||
And Easy to Setup
|
||||
`````````````````
|
||||
|
||||
.. code:: bash
|
||||
|
||||
$ pip install Flask
|
||||
$ python hello.py
|
||||
* Running on http://localhost:5000/
|
||||
|
||||
Links
|
||||
`````
|
||||
|
||||
* `website <http://flask.pocoo.org/>`_
|
||||
* `documentation <http://flask.pocoo.org/docs/>`_
|
||||
* `development version
|
||||
<http://github.com/mitsuhiko/flask/zipball/master#egg=Flask-dev>`_
|
||||
|
||||
|
||||
Platform: any
|
||||
Classifier: Development Status :: 4 - Beta
|
||||
Classifier: Environment :: Web Environment
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: License :: OSI Approved :: BSD License
|
||||
Classifier: Operating System :: OS Independent
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
||||
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
||||
|
|
@ -0,0 +1,238 @@
|
|||
AUTHORS
|
||||
CHANGES
|
||||
LICENSE
|
||||
MANIFEST.in
|
||||
Makefile
|
||||
README
|
||||
run-tests.py
|
||||
setup.cfg
|
||||
setup.py
|
||||
Flask.egg-info/PKG-INFO
|
||||
Flask.egg-info/SOURCES.txt
|
||||
Flask.egg-info/dependency_links.txt
|
||||
Flask.egg-info/not-zip-safe
|
||||
Flask.egg-info/requires.txt
|
||||
Flask.egg-info/top_level.txt
|
||||
artwork/.DS_Store
|
||||
artwork/LICENSE
|
||||
artwork/logo-full.svg
|
||||
docs/.gitignore
|
||||
docs/Makefile
|
||||
docs/advanced_foreword.rst
|
||||
docs/api.rst
|
||||
docs/appcontext.rst
|
||||
docs/becomingbig.rst
|
||||
docs/blueprints.rst
|
||||
docs/changelog.rst
|
||||
docs/conf.py
|
||||
docs/config.rst
|
||||
docs/contents.rst.inc
|
||||
docs/design.rst
|
||||
docs/errorhandling.rst
|
||||
docs/extensiondev.rst
|
||||
docs/extensions.rst
|
||||
docs/flaskdocext.py
|
||||
docs/flaskext.py
|
||||
docs/flaskstyle.sty
|
||||
docs/foreword.rst
|
||||
docs/htmlfaq.rst
|
||||
docs/index.rst
|
||||
docs/installation.rst
|
||||
docs/latexindex.rst
|
||||
docs/license.rst
|
||||
docs/logo.pdf
|
||||
docs/make.bat
|
||||
docs/python3.rst
|
||||
docs/quickstart.rst
|
||||
docs/reqcontext.rst
|
||||
docs/security.rst
|
||||
docs/shell.rst
|
||||
docs/signals.rst
|
||||
docs/styleguide.rst
|
||||
docs/templating.rst
|
||||
docs/testing.rst
|
||||
docs/unicode.rst
|
||||
docs/upgrading.rst
|
||||
docs/views.rst
|
||||
docs/_static/debugger.png
|
||||
docs/_static/flask.png
|
||||
docs/_static/flaskr.png
|
||||
docs/_static/logo-full.png
|
||||
docs/_static/no.png
|
||||
docs/_static/touch-icon.png
|
||||
docs/_static/yes.png
|
||||
docs/_templates/sidebarintro.html
|
||||
docs/_templates/sidebarlogo.html
|
||||
docs/_themes/.git
|
||||
docs/_themes/.gitignore
|
||||
docs/_themes/LICENSE
|
||||
docs/_themes/README
|
||||
docs/_themes/flask_theme_support.py
|
||||
docs/_themes/flask/layout.html
|
||||
docs/_themes/flask/relations.html
|
||||
docs/_themes/flask/theme.conf
|
||||
docs/_themes/flask/static/flasky.css_t
|
||||
docs/_themes/flask/static/small_flask.css
|
||||
docs/_themes/flask_small/layout.html
|
||||
docs/_themes/flask_small/theme.conf
|
||||
docs/_themes/flask_small/static/flasky.css_t
|
||||
docs/deploying/cgi.rst
|
||||
docs/deploying/fastcgi.rst
|
||||
docs/deploying/index.rst
|
||||
docs/deploying/mod_wsgi.rst
|
||||
docs/deploying/uwsgi.rst
|
||||
docs/deploying/wsgi-standalone.rst
|
||||
docs/patterns/apierrors.rst
|
||||
docs/patterns/appdispatch.rst
|
||||
docs/patterns/appfactories.rst
|
||||
docs/patterns/caching.rst
|
||||
docs/patterns/celery.rst
|
||||
docs/patterns/deferredcallbacks.rst
|
||||
docs/patterns/distribute.rst
|
||||
docs/patterns/errorpages.rst
|
||||
docs/patterns/fabric.rst
|
||||
docs/patterns/favicon.rst
|
||||
docs/patterns/fileuploads.rst
|
||||
docs/patterns/flashing.rst
|
||||
docs/patterns/index.rst
|
||||
docs/patterns/jquery.rst
|
||||
docs/patterns/lazyloading.rst
|
||||
docs/patterns/methodoverrides.rst
|
||||
docs/patterns/mongokit.rst
|
||||
docs/patterns/packages.rst
|
||||
docs/patterns/requestchecksum.rst
|
||||
docs/patterns/sqlalchemy.rst
|
||||
docs/patterns/sqlite3.rst
|
||||
docs/patterns/streaming.rst
|
||||
docs/patterns/templateinheritance.rst
|
||||
docs/patterns/urlprocessors.rst
|
||||
docs/patterns/viewdecorators.rst
|
||||
docs/patterns/wtforms.rst
|
||||
docs/tutorial/css.rst
|
||||
docs/tutorial/dbcon.rst
|
||||
docs/tutorial/dbinit.rst
|
||||
docs/tutorial/folders.rst
|
||||
docs/tutorial/index.rst
|
||||
docs/tutorial/introduction.rst
|
||||
docs/tutorial/schema.rst
|
||||
docs/tutorial/setup.rst
|
||||
docs/tutorial/templates.rst
|
||||
docs/tutorial/testing.rst
|
||||
docs/tutorial/views.rst
|
||||
examples/.DS_Store
|
||||
examples/blueprintexample/blueprintexample.py
|
||||
examples/blueprintexample/blueprintexample_test.py
|
||||
examples/blueprintexample/simple_page/__init__.py
|
||||
examples/blueprintexample/simple_page/simple_page.py
|
||||
examples/blueprintexample/simple_page/templates/pages/hello.html
|
||||
examples/blueprintexample/simple_page/templates/pages/index.html
|
||||
examples/blueprintexample/simple_page/templates/pages/layout.html
|
||||
examples/blueprintexample/simple_page/templates/pages/world.html
|
||||
examples/flaskr/README
|
||||
examples/flaskr/flaskr.py
|
||||
examples/flaskr/flaskr_tests.py
|
||||
examples/flaskr/schema.sql
|
||||
examples/flaskr/static/style.css
|
||||
examples/flaskr/templates/layout.html
|
||||
examples/flaskr/templates/login.html
|
||||
examples/flaskr/templates/show_entries.html
|
||||
examples/jqueryexample/jqueryexample.py
|
||||
examples/jqueryexample/templates/index.html
|
||||
examples/jqueryexample/templates/layout.html
|
||||
examples/minitwit/README
|
||||
examples/minitwit/minitwit.py
|
||||
examples/minitwit/minitwit_tests.py
|
||||
examples/minitwit/schema.sql
|
||||
examples/minitwit/static/style.css
|
||||
examples/minitwit/templates/layout.html
|
||||
examples/minitwit/templates/login.html
|
||||
examples/minitwit/templates/register.html
|
||||
examples/minitwit/templates/timeline.html
|
||||
examples/persona/.DS_Store
|
||||
examples/persona/persona.py
|
||||
examples/persona/static/.DS_Store
|
||||
examples/persona/static/persona.js
|
||||
examples/persona/static/spinner.png
|
||||
examples/persona/static/style.css
|
||||
examples/persona/templates/index.html
|
||||
examples/persona/templates/layout.html
|
||||
flask/__init__.py
|
||||
flask/_compat.py
|
||||
flask/app.py
|
||||
flask/blueprints.py
|
||||
flask/config.py
|
||||
flask/ctx.py
|
||||
flask/debughelpers.py
|
||||
flask/exthook.py
|
||||
flask/globals.py
|
||||
flask/helpers.py
|
||||
flask/json.py
|
||||
flask/logging.py
|
||||
flask/module.py
|
||||
flask/sessions.py
|
||||
flask/signals.py
|
||||
flask/templating.py
|
||||
flask/testing.py
|
||||
flask/views.py
|
||||
flask/wrappers.py
|
||||
flask/ext/__init__.py
|
||||
flask/testsuite/__init__.py
|
||||
flask/testsuite/appctx.py
|
||||
flask/testsuite/basic.py
|
||||
flask/testsuite/blueprints.py
|
||||
flask/testsuite/config.py
|
||||
flask/testsuite/deprecations.py
|
||||
flask/testsuite/examples.py
|
||||
flask/testsuite/ext.py
|
||||
flask/testsuite/helpers.py
|
||||
flask/testsuite/regression.py
|
||||
flask/testsuite/reqctx.py
|
||||
flask/testsuite/signals.py
|
||||
flask/testsuite/subclassing.py
|
||||
flask/testsuite/templating.py
|
||||
flask/testsuite/testing.py
|
||||
flask/testsuite/views.py
|
||||
flask/testsuite/static/index.html
|
||||
flask/testsuite/templates/_macro.html
|
||||
flask/testsuite/templates/context_template.html
|
||||
flask/testsuite/templates/escaping_template.html
|
||||
flask/testsuite/templates/mail.txt
|
||||
flask/testsuite/templates/simple_template.html
|
||||
flask/testsuite/templates/template_filter.html
|
||||
flask/testsuite/templates/template_test.html
|
||||
flask/testsuite/templates/nested/nested.txt
|
||||
flask/testsuite/test_apps/config_module_app.py
|
||||
flask/testsuite/test_apps/flask_newext_simple.py
|
||||
flask/testsuite/test_apps/importerror.py
|
||||
flask/testsuite/test_apps/main_app.py
|
||||
flask/testsuite/test_apps/blueprintapp/__init__.py
|
||||
flask/testsuite/test_apps/blueprintapp/apps/__init__.py
|
||||
flask/testsuite/test_apps/blueprintapp/apps/admin/__init__.py
|
||||
flask/testsuite/test_apps/blueprintapp/apps/admin/static/test.txt
|
||||
flask/testsuite/test_apps/blueprintapp/apps/admin/static/css/test.css
|
||||
flask/testsuite/test_apps/blueprintapp/apps/admin/templates/admin/index.html
|
||||
flask/testsuite/test_apps/blueprintapp/apps/frontend/__init__.py
|
||||
flask/testsuite/test_apps/blueprintapp/apps/frontend/templates/frontend/index.html
|
||||
flask/testsuite/test_apps/config_package_app/__init__.py
|
||||
flask/testsuite/test_apps/flask_broken/__init__.py
|
||||
flask/testsuite/test_apps/flask_broken/b.py
|
||||
flask/testsuite/test_apps/flask_newext_package/__init__.py
|
||||
flask/testsuite/test_apps/flask_newext_package/submodule.py
|
||||
flask/testsuite/test_apps/flaskext/__init__.py
|
||||
flask/testsuite/test_apps/flaskext/oldext_simple.py
|
||||
flask/testsuite/test_apps/flaskext/oldext_package/__init__.py
|
||||
flask/testsuite/test_apps/flaskext/oldext_package/submodule.py
|
||||
flask/testsuite/test_apps/lib/python2.5/site-packages/SiteEgg.egg
|
||||
flask/testsuite/test_apps/lib/python2.5/site-packages/site_app.py
|
||||
flask/testsuite/test_apps/lib/python2.5/site-packages/site_package/__init__.py
|
||||
flask/testsuite/test_apps/moduleapp/__init__.py
|
||||
flask/testsuite/test_apps/moduleapp/apps/__init__.py
|
||||
flask/testsuite/test_apps/moduleapp/apps/admin/__init__.py
|
||||
flask/testsuite/test_apps/moduleapp/apps/admin/static/test.txt
|
||||
flask/testsuite/test_apps/moduleapp/apps/admin/static/css/test.css
|
||||
flask/testsuite/test_apps/moduleapp/apps/admin/templates/index.html
|
||||
flask/testsuite/test_apps/moduleapp/apps/frontend/__init__.py
|
||||
flask/testsuite/test_apps/moduleapp/apps/frontend/templates/index.html
|
||||
flask/testsuite/test_apps/path/installed_package/__init__.py
|
||||
flask/testsuite/test_apps/subdomaintestmodule/__init__.py
|
||||
flask/testsuite/test_apps/subdomaintestmodule/static/hello.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,148 @@
|
|||
../flask/wrappers.py
|
||||
../flask/_compat.py
|
||||
../flask/templating.py
|
||||
../flask/helpers.py
|
||||
../flask/ctx.py
|
||||
../flask/views.py
|
||||
../flask/sessions.py
|
||||
../flask/blueprints.py
|
||||
../flask/json.py
|
||||
../flask/module.py
|
||||
../flask/signals.py
|
||||
../flask/logging.py
|
||||
../flask/globals.py
|
||||
../flask/__init__.py
|
||||
../flask/debughelpers.py
|
||||
../flask/testing.py
|
||||
../flask/config.py
|
||||
../flask/app.py
|
||||
../flask/exthook.py
|
||||
../flask/ext/__init__.py
|
||||
../flask/testsuite/deprecations.py
|
||||
../flask/testsuite/regression.py
|
||||
../flask/testsuite/ext.py
|
||||
../flask/testsuite/templating.py
|
||||
../flask/testsuite/helpers.py
|
||||
../flask/testsuite/views.py
|
||||
../flask/testsuite/blueprints.py
|
||||
../flask/testsuite/subclassing.py
|
||||
../flask/testsuite/signals.py
|
||||
../flask/testsuite/examples.py
|
||||
../flask/testsuite/reqctx.py
|
||||
../flask/testsuite/__init__.py
|
||||
../flask/testsuite/basic.py
|
||||
../flask/testsuite/testing.py
|
||||
../flask/testsuite/config.py
|
||||
../flask/testsuite/appctx.py
|
||||
../flask/testsuite/static/index.html
|
||||
../flask/testsuite/templates/_macro.html
|
||||
../flask/testsuite/templates/context_template.html
|
||||
../flask/testsuite/templates/escaping_template.html
|
||||
../flask/testsuite/templates/mail.txt
|
||||
../flask/testsuite/templates/simple_template.html
|
||||
../flask/testsuite/templates/template_filter.html
|
||||
../flask/testsuite/templates/template_test.html
|
||||
../flask/testsuite/templates/nested/nested.txt
|
||||
../flask/testsuite/test_apps/config_module_app.py
|
||||
../flask/testsuite/test_apps/flask_newext_simple.py
|
||||
../flask/testsuite/test_apps/importerror.py
|
||||
../flask/testsuite/test_apps/main_app.py
|
||||
../flask/testsuite/test_apps/blueprintapp/__init__.py
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/__init__.py
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/admin/__init__.py
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/admin/static/test.txt
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/admin/static/css/test.css
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/admin/templates/admin/index.html
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/frontend/__init__.py
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/frontend/templates/frontend/index.html
|
||||
../flask/testsuite/test_apps/config_package_app/__init__.py
|
||||
../flask/testsuite/test_apps/flask_broken/__init__.py
|
||||
../flask/testsuite/test_apps/flask_broken/b.py
|
||||
../flask/testsuite/test_apps/flask_newext_package/__init__.py
|
||||
../flask/testsuite/test_apps/flask_newext_package/submodule.py
|
||||
../flask/testsuite/test_apps/flaskext/__init__.py
|
||||
../flask/testsuite/test_apps/flaskext/oldext_simple.py
|
||||
../flask/testsuite/test_apps/flaskext/oldext_package/__init__.py
|
||||
../flask/testsuite/test_apps/flaskext/oldext_package/submodule.py
|
||||
../flask/testsuite/test_apps/lib/python2.5/site-packages/SiteEgg.egg
|
||||
../flask/testsuite/test_apps/lib/python2.5/site-packages/site_app.py
|
||||
../flask/testsuite/test_apps/lib/python2.5/site-packages/site_package/__init__.py
|
||||
../flask/testsuite/test_apps/moduleapp/__init__.py
|
||||
../flask/testsuite/test_apps/moduleapp/apps/__init__.py
|
||||
../flask/testsuite/test_apps/moduleapp/apps/admin/__init__.py
|
||||
../flask/testsuite/test_apps/moduleapp/apps/admin/static/test.txt
|
||||
../flask/testsuite/test_apps/moduleapp/apps/admin/static/css/test.css
|
||||
../flask/testsuite/test_apps/moduleapp/apps/admin/templates/index.html
|
||||
../flask/testsuite/test_apps/moduleapp/apps/frontend/__init__.py
|
||||
../flask/testsuite/test_apps/moduleapp/apps/frontend/templates/index.html
|
||||
../flask/testsuite/test_apps/path/installed_package/__init__.py
|
||||
../flask/testsuite/test_apps/subdomaintestmodule/__init__.py
|
||||
../flask/testsuite/test_apps/subdomaintestmodule/static/hello.txt
|
||||
../flask/wrappers.pyc
|
||||
../flask/_compat.pyc
|
||||
../flask/templating.pyc
|
||||
../flask/helpers.pyc
|
||||
../flask/ctx.pyc
|
||||
../flask/views.pyc
|
||||
../flask/sessions.pyc
|
||||
../flask/blueprints.pyc
|
||||
../flask/json.pyc
|
||||
../flask/module.pyc
|
||||
../flask/signals.pyc
|
||||
../flask/logging.pyc
|
||||
../flask/globals.pyc
|
||||
../flask/__init__.pyc
|
||||
../flask/debughelpers.pyc
|
||||
../flask/testing.pyc
|
||||
../flask/config.pyc
|
||||
../flask/app.pyc
|
||||
../flask/exthook.pyc
|
||||
../flask/ext/__init__.pyc
|
||||
../flask/testsuite/deprecations.pyc
|
||||
../flask/testsuite/regression.pyc
|
||||
../flask/testsuite/ext.pyc
|
||||
../flask/testsuite/templating.pyc
|
||||
../flask/testsuite/helpers.pyc
|
||||
../flask/testsuite/views.pyc
|
||||
../flask/testsuite/blueprints.pyc
|
||||
../flask/testsuite/subclassing.pyc
|
||||
../flask/testsuite/signals.pyc
|
||||
../flask/testsuite/examples.pyc
|
||||
../flask/testsuite/reqctx.pyc
|
||||
../flask/testsuite/__init__.pyc
|
||||
../flask/testsuite/basic.pyc
|
||||
../flask/testsuite/testing.pyc
|
||||
../flask/testsuite/config.pyc
|
||||
../flask/testsuite/appctx.pyc
|
||||
../flask/testsuite/test_apps/config_module_app.pyc
|
||||
../flask/testsuite/test_apps/flask_newext_simple.pyc
|
||||
../flask/testsuite/test_apps/importerror.pyc
|
||||
../flask/testsuite/test_apps/main_app.pyc
|
||||
../flask/testsuite/test_apps/blueprintapp/__init__.pyc
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/__init__.pyc
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/admin/__init__.pyc
|
||||
../flask/testsuite/test_apps/blueprintapp/apps/frontend/__init__.pyc
|
||||
../flask/testsuite/test_apps/config_package_app/__init__.pyc
|
||||
../flask/testsuite/test_apps/flask_broken/__init__.pyc
|
||||
../flask/testsuite/test_apps/flask_broken/b.pyc
|
||||
../flask/testsuite/test_apps/flask_newext_package/__init__.pyc
|
||||
../flask/testsuite/test_apps/flask_newext_package/submodule.pyc
|
||||
../flask/testsuite/test_apps/flaskext/__init__.pyc
|
||||
../flask/testsuite/test_apps/flaskext/oldext_simple.pyc
|
||||
../flask/testsuite/test_apps/flaskext/oldext_package/__init__.pyc
|
||||
../flask/testsuite/test_apps/flaskext/oldext_package/submodule.pyc
|
||||
../flask/testsuite/test_apps/lib/python2.5/site-packages/site_app.pyc
|
||||
../flask/testsuite/test_apps/lib/python2.5/site-packages/site_package/__init__.pyc
|
||||
../flask/testsuite/test_apps/moduleapp/__init__.pyc
|
||||
../flask/testsuite/test_apps/moduleapp/apps/__init__.pyc
|
||||
../flask/testsuite/test_apps/moduleapp/apps/admin/__init__.pyc
|
||||
../flask/testsuite/test_apps/moduleapp/apps/frontend/__init__.pyc
|
||||
../flask/testsuite/test_apps/path/installed_package/__init__.pyc
|
||||
../flask/testsuite/test_apps/subdomaintestmodule/__init__.pyc
|
||||
./
|
||||
requires.txt
|
||||
SOURCES.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
Werkzeug>=0.7
|
||||
Jinja2>=2.4
|
||||
itsdangerous>=0.21
|
||||
|
|
@ -0,0 +1 @@
|
|||
flask
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: Flask-Migrate
|
||||
Version: 1.2.0
|
||||
Summary: SQLAlchemy database migrations for Flask applications using Alembic
|
||||
Home-page: http://github.com/miguelgrinberg/flask-migrate/
|
||||
Author: Miguel Grinberg
|
||||
Author-email: miguelgrinberg50@gmail.com
|
||||
License: MIT
|
||||
Description:
|
||||
Flask-Migrate
|
||||
--------------
|
||||
|
||||
SQLAlchemy database migrations for Flask applications using Alembic.
|
||||
|
||||
Platform: any
|
||||
Classifier: Environment :: Web Environment
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: License :: OSI Approved :: MIT License
|
||||
Classifier: Operating System :: OS Independent
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
||||
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
LICENSE
|
||||
MANIFEST.in
|
||||
README.md
|
||||
setup.cfg
|
||||
setup.py
|
||||
Flask_Migrate.egg-info/PKG-INFO
|
||||
Flask_Migrate.egg-info/SOURCES.txt
|
||||
Flask_Migrate.egg-info/dependency_links.txt
|
||||
Flask_Migrate.egg-info/not-zip-safe
|
||||
Flask_Migrate.egg-info/requires.txt
|
||||
Flask_Migrate.egg-info/top_level.txt
|
||||
flask_migrate/__init__.py
|
||||
flask_migrate/templates/flask/README
|
||||
flask_migrate/templates/flask/alembic.ini.mako
|
||||
flask_migrate/templates/flask/env.py
|
||||
flask_migrate/templates/flask/script.py.mako
|
||||
tests/__init__.py
|
||||
tests/__init__.pyc
|
||||
tests/app.py
|
||||
tests/app.pyc
|
||||
tests/app2.py
|
||||
tests/test_migrate.py
|
||||
tests/test_migrate.pyc
|
||||
tests/test_migrate_custom_directory.py
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
../flask_migrate/__init__.py
|
||||
../flask_migrate/templates/flask/README
|
||||
../flask_migrate/templates/flask/alembic.ini.mako
|
||||
../flask_migrate/templates/flask/env.py
|
||||
../flask_migrate/templates/flask/script.py.mako
|
||||
../flask_migrate/__init__.pyc
|
||||
../flask_migrate/templates/flask/env.pyc
|
||||
./
|
||||
requires.txt
|
||||
SOURCES.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
Flask>=0.9
|
||||
Flask-SQLAlchemy>=1.0
|
||||
alembic>=0.6
|
||||
Flask-Script>=0.6
|
||||
|
|
@ -0,0 +1 @@
|
|||
flask_migrate
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: Flask-SQLAlchemy
|
||||
Version: 1.0
|
||||
Summary: Adds SQLAlchemy support to your Flask application
|
||||
Home-page: http://github.com/mitsuhiko/flask-sqlalchemy
|
||||
Author: Armin Ronacher
|
||||
Author-email: armin.ronacher@active-4.com
|
||||
License: BSD
|
||||
Description:
|
||||
Flask-SQLAlchemy
|
||||
----------------
|
||||
|
||||
Adds SQLAlchemy support to your Flask application.
|
||||
|
||||
Links
|
||||
`````
|
||||
|
||||
* `documentation <http://packages.python.org/Flask-SQLAlchemy>`_
|
||||
* `development version
|
||||
<http://github.com/mitsuhiko/flask-sqlalchemy/zipball/master#egg=Flask-SQLAlchemy-dev>`_
|
||||
|
||||
|
||||
Platform: any
|
||||
Classifier: Environment :: Web Environment
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: License :: OSI Approved :: BSD License
|
||||
Classifier: Operating System :: OS Independent
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
||||
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
||||
|
|
@ -0,0 +1,35 @@
|
|||
CHANGES
|
||||
LICENSE
|
||||
MANIFEST.in
|
||||
README
|
||||
setup.cfg
|
||||
setup.py
|
||||
test_sqlalchemy.py
|
||||
Flask_SQLAlchemy.egg-info/PKG-INFO
|
||||
Flask_SQLAlchemy.egg-info/SOURCES.txt
|
||||
Flask_SQLAlchemy.egg-info/dependency_links.txt
|
||||
Flask_SQLAlchemy.egg-info/not-zip-safe
|
||||
Flask_SQLAlchemy.egg-info/requires.txt
|
||||
Flask_SQLAlchemy.egg-info/top_level.txt
|
||||
docs/Makefile
|
||||
docs/api.rst
|
||||
docs/binds.rst
|
||||
docs/changelog.rst
|
||||
docs/conf.py
|
||||
docs/config.rst
|
||||
docs/contents.rst.inc
|
||||
docs/contexts.rst
|
||||
docs/flaskstyle.sty
|
||||
docs/index.rst
|
||||
docs/logo.pdf
|
||||
docs/make.bat
|
||||
docs/models.rst
|
||||
docs/queries.rst
|
||||
docs/quickstart.rst
|
||||
docs/signals.rst
|
||||
docs/_static/flask-sqlalchemy-small.png
|
||||
docs/_static/flask-sqlalchemy.png
|
||||
docs/_templates/sidebarintro.html
|
||||
docs/_templates/sidebarlogo.html
|
||||
flask_sqlalchemy/__init__.py
|
||||
flask_sqlalchemy/_compat.py
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
../flask_sqlalchemy/_compat.py
|
||||
../flask_sqlalchemy/__init__.py
|
||||
../flask_sqlalchemy/_compat.pyc
|
||||
../flask_sqlalchemy/__init__.pyc
|
||||
./
|
||||
requires.txt
|
||||
SOURCES.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
setuptools
|
||||
Flask>=0.10
|
||||
SQLAlchemy
|
||||
|
|
@ -0,0 +1 @@
|
|||
flask_sqlalchemy
|
||||
|
|
@ -0,0 +1,35 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: Flask-Script
|
||||
Version: 2.0.3
|
||||
Summary: Scripting support for Flask
|
||||
Home-page: http://github.com/smurfix/flask-script
|
||||
Author: Matthias Urlichs
|
||||
Author-email: matthias@urlichs.de
|
||||
License: BSD
|
||||
Download-URL: https://github.com/smurfix/flask-script/tarball/v2.0.3
|
||||
Description:
|
||||
Flask-Script
|
||||
--------------
|
||||
|
||||
Flask support for writing external scripts.
|
||||
|
||||
Links
|
||||
`````
|
||||
|
||||
* `documentation <http://flask-script.readthedocs.org>`_
|
||||
|
||||
|
||||
|
||||
Platform: any
|
||||
Classifier: Development Status :: 5 - Production/Stable
|
||||
Classifier: Environment :: Web Environment
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: License :: OSI Approved :: BSD License
|
||||
Classifier: Operating System :: OS Independent
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Programming Language :: Python :: 2
|
||||
Classifier: Programming Language :: Python :: 2.7
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Programming Language :: Python :: 3.3
|
||||
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
||||
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
LICENSE
|
||||
MANIFEST.in
|
||||
README.rst
|
||||
setup.cfg
|
||||
setup.py
|
||||
tests.py
|
||||
Flask_Script.egg-info/PKG-INFO
|
||||
Flask_Script.egg-info/SOURCES.txt
|
||||
Flask_Script.egg-info/dependency_links.txt
|
||||
Flask_Script.egg-info/not-zip-safe
|
||||
Flask_Script.egg-info/requires.txt
|
||||
Flask_Script.egg-info/top_level.txt
|
||||
docs/Makefile
|
||||
docs/conf.py
|
||||
docs/index.rst
|
||||
docs/make.bat
|
||||
docs/_static/flask-script.png
|
||||
docs/_static/index.html
|
||||
docs/_themes/README
|
||||
docs/_themes/flask_theme_support.py
|
||||
docs/_themes/flask/theme.conf
|
||||
docs/_themes/flask/static/flasky.css_t
|
||||
docs/_themes/flask_small/layout.html
|
||||
docs/_themes/flask_small/theme.conf
|
||||
docs/_themes/flask_small/static/flasky.css_t
|
||||
flask_script/__init__.py
|
||||
flask_script/_compat.py
|
||||
flask_script/cli.py
|
||||
flask_script/commands.py
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
../flask_script/cli.py
|
||||
../flask_script/_compat.py
|
||||
../flask_script/commands.py
|
||||
../flask_script/__init__.py
|
||||
../flask_script/cli.pyc
|
||||
../flask_script/_compat.pyc
|
||||
../flask_script/commands.pyc
|
||||
../flask_script/__init__.pyc
|
||||
./
|
||||
requires.txt
|
||||
SOURCES.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1 @@
|
|||
Flask
|
||||
|
|
@ -0,0 +1 @@
|
|||
flask_script
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: Jinja2
|
||||
Version: 2.7.2
|
||||
Summary: A small but fast and easy to use stand-alone template engine written in pure python.
|
||||
Home-page: http://jinja.pocoo.org/
|
||||
Author: Armin Ronacher
|
||||
Author-email: armin.ronacher@active-4.com
|
||||
License: BSD
|
||||
Description:
|
||||
Jinja2
|
||||
~~~~~~
|
||||
|
||||
Jinja2 is a template engine written in pure Python. It provides a
|
||||
`Django`_ inspired non-XML syntax but supports inline expressions and
|
||||
an optional `sandboxed`_ environment.
|
||||
|
||||
Nutshell
|
||||
--------
|
||||
|
||||
Here a small example of a Jinja template::
|
||||
|
||||
{% extends 'base.html' %}
|
||||
{% block title %}Memberlist{% endblock %}
|
||||
{% block content %}
|
||||
<ul>
|
||||
{% for user in users %}
|
||||
<li><a href="{{ user.url }}">{{ user.username }}</a></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endblock %}
|
||||
|
||||
Philosophy
|
||||
----------
|
||||
|
||||
Application logic is for the controller but don't try to make the life
|
||||
for the template designer too hard by giving him too few functionality.
|
||||
|
||||
For more informations visit the new `Jinja2 webpage`_ and `documentation`_.
|
||||
|
||||
.. _sandboxed: http://en.wikipedia.org/wiki/Sandbox_(computer_security)
|
||||
.. _Django: http://www.djangoproject.com/
|
||||
.. _Jinja2 webpage: http://jinja.pocoo.org/
|
||||
.. _documentation: http://jinja.pocoo.org/2/documentation/
|
||||
|
||||
Platform: UNKNOWN
|
||||
Classifier: Development Status :: 5 - Production/Stable
|
||||
Classifier: Environment :: Web Environment
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: License :: OSI Approved :: BSD License
|
||||
Classifier: Operating System :: OS Independent
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
||||
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
||||
Classifier: Topic :: Text Processing :: Markup :: HTML
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
AUTHORS
|
||||
CHANGES
|
||||
LICENSE
|
||||
MANIFEST.in
|
||||
Makefile
|
||||
README.rst
|
||||
run-tests.py
|
||||
setup.cfg
|
||||
setup.py
|
||||
Jinja2.egg-info/PKG-INFO
|
||||
Jinja2.egg-info/SOURCES.txt
|
||||
Jinja2.egg-info/dependency_links.txt
|
||||
Jinja2.egg-info/entry_points.txt
|
||||
Jinja2.egg-info/not-zip-safe
|
||||
Jinja2.egg-info/requires.txt
|
||||
Jinja2.egg-info/top_level.txt
|
||||
artwork/jinjalogo.svg
|
||||
docs/Makefile
|
||||
docs/api.rst
|
||||
docs/cache_extension.py
|
||||
docs/changelog.rst
|
||||
docs/conf.py
|
||||
docs/contents.rst.inc
|
||||
docs/extensions.rst
|
||||
docs/faq.rst
|
||||
docs/index.rst
|
||||
docs/integration.rst
|
||||
docs/intro.rst
|
||||
docs/jinjaext.py
|
||||
docs/jinjastyle.sty
|
||||
docs/latexindex.rst
|
||||
docs/logo.pdf
|
||||
docs/sandbox.rst
|
||||
docs/switching.rst
|
||||
docs/templates.rst
|
||||
docs/tricks.rst
|
||||
docs/_static/.ignore
|
||||
docs/_static/jinja-small.png
|
||||
docs/_templates/sidebarintro.html
|
||||
docs/_templates/sidebarlogo.html
|
||||
docs/_themes/LICENSE
|
||||
docs/_themes/README
|
||||
docs/_themes/jinja/layout.html
|
||||
docs/_themes/jinja/relations.html
|
||||
docs/_themes/jinja/theme.conf
|
||||
docs/_themes/jinja/static/jinja.css_t
|
||||
examples/bench.py
|
||||
examples/profile.py
|
||||
examples/basic/cycle.py
|
||||
examples/basic/debugger.py
|
||||
examples/basic/inheritance.py
|
||||
examples/basic/test.py
|
||||
examples/basic/test_filter_and_linestatements.py
|
||||
examples/basic/test_loop_filter.py
|
||||
examples/basic/translate.py
|
||||
examples/basic/templates/broken.html
|
||||
examples/basic/templates/subbroken.html
|
||||
examples/rwbench/djangoext.py
|
||||
examples/rwbench/rwbench.py
|
||||
examples/rwbench/django/_form.html
|
||||
examples/rwbench/django/_input_field.html
|
||||
examples/rwbench/django/_textarea.html
|
||||
examples/rwbench/django/index.html
|
||||
examples/rwbench/django/layout.html
|
||||
examples/rwbench/genshi/helpers.html
|
||||
examples/rwbench/genshi/index.html
|
||||
examples/rwbench/genshi/layout.html
|
||||
examples/rwbench/jinja/helpers.html
|
||||
examples/rwbench/jinja/index.html
|
||||
examples/rwbench/jinja/layout.html
|
||||
examples/rwbench/mako/helpers.html
|
||||
examples/rwbench/mako/index.html
|
||||
examples/rwbench/mako/layout.html
|
||||
ext/djangojinja2.py
|
||||
ext/inlinegettext.py
|
||||
ext/jinja.el
|
||||
ext/Vim/jinja.vim
|
||||
ext/django2jinja/django2jinja.py
|
||||
ext/django2jinja/example.py
|
||||
ext/django2jinja/templates/index.html
|
||||
ext/django2jinja/templates/layout.html
|
||||
ext/django2jinja/templates/subtemplate.html
|
||||
jinja2/__init__.py
|
||||
jinja2/_compat.py
|
||||
jinja2/_stringdefs.py
|
||||
jinja2/bccache.py
|
||||
jinja2/compiler.py
|
||||
jinja2/constants.py
|
||||
jinja2/debug.py
|
||||
jinja2/defaults.py
|
||||
jinja2/environment.py
|
||||
jinja2/exceptions.py
|
||||
jinja2/ext.py
|
||||
jinja2/filters.py
|
||||
jinja2/lexer.py
|
||||
jinja2/loaders.py
|
||||
jinja2/meta.py
|
||||
jinja2/nodes.py
|
||||
jinja2/optimizer.py
|
||||
jinja2/parser.py
|
||||
jinja2/runtime.py
|
||||
jinja2/sandbox.py
|
||||
jinja2/tests.py
|
||||
jinja2/utils.py
|
||||
jinja2/visitor.py
|
||||
jinja2/testsuite/__init__.py
|
||||
jinja2/testsuite/api.py
|
||||
jinja2/testsuite/bytecode_cache.py
|
||||
jinja2/testsuite/core_tags.py
|
||||
jinja2/testsuite/debug.py
|
||||
jinja2/testsuite/doctests.py
|
||||
jinja2/testsuite/ext.py
|
||||
jinja2/testsuite/filters.py
|
||||
jinja2/testsuite/imports.py
|
||||
jinja2/testsuite/inheritance.py
|
||||
jinja2/testsuite/lexnparse.py
|
||||
jinja2/testsuite/loader.py
|
||||
jinja2/testsuite/regression.py
|
||||
jinja2/testsuite/security.py
|
||||
jinja2/testsuite/tests.py
|
||||
jinja2/testsuite/utils.py
|
||||
jinja2/testsuite/res/__init__.py
|
||||
jinja2/testsuite/res/templates/broken.html
|
||||
jinja2/testsuite/res/templates/syntaxerror.html
|
||||
jinja2/testsuite/res/templates/test.html
|
||||
jinja2/testsuite/res/templates/foo/test.html
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
|
||||
[babel.extractors]
|
||||
jinja2 = jinja2.ext:babel_extract[i18n]
|
||||
|
||||
|
|
@ -0,0 +1,92 @@
|
|||
../jinja2/bccache.py
|
||||
../jinja2/_compat.py
|
||||
../jinja2/ext.py
|
||||
../jinja2/defaults.py
|
||||
../jinja2/meta.py
|
||||
../jinja2/_stringdefs.py
|
||||
../jinja2/nodes.py
|
||||
../jinja2/runtime.py
|
||||
../jinja2/exceptions.py
|
||||
../jinja2/lexer.py
|
||||
../jinja2/__init__.py
|
||||
../jinja2/visitor.py
|
||||
../jinja2/optimizer.py
|
||||
../jinja2/sandbox.py
|
||||
../jinja2/debug.py
|
||||
../jinja2/filters.py
|
||||
../jinja2/constants.py
|
||||
../jinja2/tests.py
|
||||
../jinja2/utils.py
|
||||
../jinja2/compiler.py
|
||||
../jinja2/parser.py
|
||||
../jinja2/loaders.py
|
||||
../jinja2/environment.py
|
||||
../jinja2/testsuite/api.py
|
||||
../jinja2/testsuite/regression.py
|
||||
../jinja2/testsuite/core_tags.py
|
||||
../jinja2/testsuite/inheritance.py
|
||||
../jinja2/testsuite/ext.py
|
||||
../jinja2/testsuite/security.py
|
||||
../jinja2/testsuite/doctests.py
|
||||
../jinja2/testsuite/bytecode_cache.py
|
||||
../jinja2/testsuite/imports.py
|
||||
../jinja2/testsuite/lexnparse.py
|
||||
../jinja2/testsuite/__init__.py
|
||||
../jinja2/testsuite/debug.py
|
||||
../jinja2/testsuite/filters.py
|
||||
../jinja2/testsuite/tests.py
|
||||
../jinja2/testsuite/loader.py
|
||||
../jinja2/testsuite/utils.py
|
||||
../jinja2/testsuite/res/__init__.py
|
||||
../jinja2/testsuite/res/templates/broken.html
|
||||
../jinja2/testsuite/res/templates/syntaxerror.html
|
||||
../jinja2/testsuite/res/templates/test.html
|
||||
../jinja2/testsuite/res/templates/foo/test.html
|
||||
../jinja2/bccache.pyc
|
||||
../jinja2/_compat.pyc
|
||||
../jinja2/ext.pyc
|
||||
../jinja2/defaults.pyc
|
||||
../jinja2/meta.pyc
|
||||
../jinja2/_stringdefs.pyc
|
||||
../jinja2/nodes.pyc
|
||||
../jinja2/runtime.pyc
|
||||
../jinja2/exceptions.pyc
|
||||
../jinja2/lexer.pyc
|
||||
../jinja2/__init__.pyc
|
||||
../jinja2/visitor.pyc
|
||||
../jinja2/optimizer.pyc
|
||||
../jinja2/sandbox.pyc
|
||||
../jinja2/debug.pyc
|
||||
../jinja2/filters.pyc
|
||||
../jinja2/constants.pyc
|
||||
../jinja2/tests.pyc
|
||||
../jinja2/utils.pyc
|
||||
../jinja2/compiler.pyc
|
||||
../jinja2/parser.pyc
|
||||
../jinja2/loaders.pyc
|
||||
../jinja2/environment.pyc
|
||||
../jinja2/testsuite/api.pyc
|
||||
../jinja2/testsuite/regression.pyc
|
||||
../jinja2/testsuite/core_tags.pyc
|
||||
../jinja2/testsuite/inheritance.pyc
|
||||
../jinja2/testsuite/ext.pyc
|
||||
../jinja2/testsuite/security.pyc
|
||||
../jinja2/testsuite/doctests.pyc
|
||||
../jinja2/testsuite/bytecode_cache.pyc
|
||||
../jinja2/testsuite/imports.pyc
|
||||
../jinja2/testsuite/lexnparse.pyc
|
||||
../jinja2/testsuite/__init__.pyc
|
||||
../jinja2/testsuite/debug.pyc
|
||||
../jinja2/testsuite/filters.pyc
|
||||
../jinja2/testsuite/tests.pyc
|
||||
../jinja2/testsuite/loader.pyc
|
||||
../jinja2/testsuite/utils.pyc
|
||||
../jinja2/testsuite/res/__init__.pyc
|
||||
./
|
||||
requires.txt
|
||||
SOURCES.txt
|
||||
entry_points.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
markupsafe
|
||||
|
||||
[i18n]
|
||||
Babel>=0.8
|
||||
|
|
@ -0,0 +1 @@
|
|||
jinja2
|
||||
|
|
@ -0,0 +1,71 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: Mako
|
||||
Version: 0.9.1
|
||||
Summary: A super-fast templating language that borrows the best ideas from the existing templating languages.
|
||||
Home-page: http://www.makotemplates.org/
|
||||
Author: Mike Bayer
|
||||
Author-email: mike@zzzcomputing.com
|
||||
License: MIT
|
||||
Description: =========================
|
||||
Mako Templates for Python
|
||||
=========================
|
||||
|
||||
Mako is a template library written in Python. It provides a familiar, non-XML
|
||||
syntax which compiles into Python modules for maximum performance. Mako's
|
||||
syntax and API borrows from the best ideas of many others, including Django
|
||||
templates, Cheetah, Myghty, and Genshi. Conceptually, Mako is an embedded
|
||||
Python (i.e. Python Server Page) language, which refines the familiar ideas
|
||||
of componentized layout and inheritance to produce one of the most
|
||||
straightforward and flexible models available, while also maintaining close
|
||||
ties to Python calling and scoping semantics.
|
||||
|
||||
Nutshell
|
||||
========
|
||||
|
||||
::
|
||||
|
||||
<%inherit file="base.html"/>
|
||||
<%
|
||||
rows = [[v for v in range(0,10)] for row in range(0,10)]
|
||||
%>
|
||||
<table>
|
||||
% for row in rows:
|
||||
${makerow(row)}
|
||||
% endfor
|
||||
</table>
|
||||
|
||||
<%def name="makerow(row)">
|
||||
<tr>
|
||||
% for name in row:
|
||||
<td>${name}</td>\
|
||||
% endfor
|
||||
</tr>
|
||||
</%def>
|
||||
|
||||
Philosophy
|
||||
===========
|
||||
|
||||
Python is a great scripting language. Don't reinvent the wheel...your templates can handle it !
|
||||
|
||||
Documentation
|
||||
==============
|
||||
|
||||
See documentation for Mako at http://www.makotemplates.org/docs/
|
||||
|
||||
License
|
||||
========
|
||||
|
||||
Mako is licensed under an MIT-style license (see LICENSE).
|
||||
Other incorporated projects may be licensed under different licenses.
|
||||
All licenses allow for non-commercial and commercial use.
|
||||
|
||||
Keywords: templates
|
||||
Platform: UNKNOWN
|
||||
Classifier: Development Status :: 5 - Production/Stable
|
||||
Classifier: Environment :: Web Environment
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Programming Language :: Python :: Implementation :: CPython
|
||||
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
||||
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
||||
|
|
@ -0,0 +1,173 @@
|
|||
CHANGES
|
||||
LICENSE
|
||||
MANIFEST.in
|
||||
README.rst
|
||||
distribute_setup.py
|
||||
setup.cfg
|
||||
setup.py
|
||||
Mako.egg-info/PKG-INFO
|
||||
Mako.egg-info/SOURCES.txt
|
||||
Mako.egg-info/dependency_links.txt
|
||||
Mako.egg-info/entry_points.txt
|
||||
Mako.egg-info/not-zip-safe
|
||||
Mako.egg-info/requires.txt
|
||||
Mako.egg-info/top_level.txt
|
||||
doc/caching.html
|
||||
doc/defs.html
|
||||
doc/filtering.html
|
||||
doc/genindex.html
|
||||
doc/index.html
|
||||
doc/inheritance.html
|
||||
doc/namespaces.html
|
||||
doc/runtime.html
|
||||
doc/search.html
|
||||
doc/searchindex.js
|
||||
doc/syntax.html
|
||||
doc/unicode.html
|
||||
doc/usage.html
|
||||
doc/_sources/caching.txt
|
||||
doc/_sources/defs.txt
|
||||
doc/_sources/filtering.txt
|
||||
doc/_sources/index.txt
|
||||
doc/_sources/inheritance.txt
|
||||
doc/_sources/namespaces.txt
|
||||
doc/_sources/runtime.txt
|
||||
doc/_sources/syntax.txt
|
||||
doc/_sources/unicode.txt
|
||||
doc/_sources/usage.txt
|
||||
doc/_static/basic.css
|
||||
doc/_static/comment-bright.png
|
||||
doc/_static/comment-close.png
|
||||
doc/_static/comment.png
|
||||
doc/_static/default.css
|
||||
doc/_static/docs.css
|
||||
doc/_static/doctools.js
|
||||
doc/_static/down-pressed.png
|
||||
doc/_static/down.png
|
||||
doc/_static/file.png
|
||||
doc/_static/jquery.js
|
||||
doc/_static/makoLogo.png
|
||||
doc/_static/minus.png
|
||||
doc/_static/plus.png
|
||||
doc/_static/pygments.css
|
||||
doc/_static/searchtools.js
|
||||
doc/_static/sidebar.js
|
||||
doc/_static/site.css
|
||||
doc/_static/underscore.js
|
||||
doc/_static/up-pressed.png
|
||||
doc/_static/up.png
|
||||
doc/_static/websupport.js
|
||||
doc/build/Makefile
|
||||
doc/build/caching.rst
|
||||
doc/build/conf.py
|
||||
doc/build/defs.rst
|
||||
doc/build/filtering.rst
|
||||
doc/build/index.rst
|
||||
doc/build/inheritance.rst
|
||||
doc/build/namespaces.rst
|
||||
doc/build/runtime.rst
|
||||
doc/build/syntax.rst
|
||||
doc/build/unicode.rst
|
||||
doc/build/usage.rst
|
||||
doc/build/builder/__init__.py
|
||||
doc/build/builder/builders.py
|
||||
doc/build/builder/util.py
|
||||
doc/build/static/docs.css
|
||||
doc/build/static/makoLogo.png
|
||||
doc/build/static/site.css
|
||||
doc/build/templates/base.mako
|
||||
doc/build/templates/genindex.mako
|
||||
doc/build/templates/layout.mako
|
||||
doc/build/templates/page.mako
|
||||
doc/build/templates/rtd_layout.mako
|
||||
doc/build/templates/search.mako
|
||||
examples/bench/basic.py
|
||||
examples/bench/cheetah/footer.tmpl
|
||||
examples/bench/cheetah/header.tmpl
|
||||
examples/bench/cheetah/template.tmpl
|
||||
examples/bench/django/templatetags/__init__.py
|
||||
examples/bench/django/templatetags/bench.py
|
||||
examples/bench/kid/base.kid
|
||||
examples/bench/kid/template.kid
|
||||
examples/bench/myghty/base.myt
|
||||
examples/bench/myghty/template.myt
|
||||
examples/wsgi/run_wsgi.py
|
||||
mako/__init__.py
|
||||
mako/_ast_util.py
|
||||
mako/ast.py
|
||||
mako/cache.py
|
||||
mako/codegen.py
|
||||
mako/compat.py
|
||||
mako/exceptions.py
|
||||
mako/filters.py
|
||||
mako/lexer.py
|
||||
mako/lookup.py
|
||||
mako/parsetree.py
|
||||
mako/pygen.py
|
||||
mako/pyparser.py
|
||||
mako/runtime.py
|
||||
mako/template.py
|
||||
mako/util.py
|
||||
mako/ext/__init__.py
|
||||
mako/ext/autohandler.py
|
||||
mako/ext/babelplugin.py
|
||||
mako/ext/beaker_cache.py
|
||||
mako/ext/preprocessors.py
|
||||
mako/ext/pygmentplugin.py
|
||||
mako/ext/turbogears.py
|
||||
scripts/mako-render
|
||||
test/__init__.py
|
||||
test/sample_module_namespace.py
|
||||
test/test_ast.py
|
||||
test/test_babelplugin.py
|
||||
test/test_block.py
|
||||
test/test_cache.py
|
||||
test/test_call.py
|
||||
test/test_decorators.py
|
||||
test/test_def.py
|
||||
test/test_exceptions.py
|
||||
test/test_filters.py
|
||||
test/test_inheritance.py
|
||||
test/test_lexer.py
|
||||
test/test_lookup.py
|
||||
test/test_loop.py
|
||||
test/test_lru.py
|
||||
test/test_namespace.py
|
||||
test/test_pygen.py
|
||||
test/test_runtime.py
|
||||
test/test_template.py
|
||||
test/test_tgplugin.py
|
||||
test/test_util.py
|
||||
test/util.py
|
||||
test/foo/__init__.py
|
||||
test/foo/test_ns.py
|
||||
test/templates/badbom.html
|
||||
test/templates/bom.html
|
||||
test/templates/bommagic.html
|
||||
test/templates/chs_unicode.html
|
||||
test/templates/chs_unicode_py3k.html
|
||||
test/templates/chs_utf8.html
|
||||
test/templates/crlf.html
|
||||
test/templates/gettext.mako
|
||||
test/templates/index.html
|
||||
test/templates/internationalization.html
|
||||
test/templates/modtest.html
|
||||
test/templates/read_unicode.html
|
||||
test/templates/read_unicode_py3k.html
|
||||
test/templates/runtimeerr.html
|
||||
test/templates/runtimeerr_py3k.html
|
||||
test/templates/unicode.html
|
||||
test/templates/unicode_arguments.html
|
||||
test/templates/unicode_arguments_py3k.html
|
||||
test/templates/unicode_code.html
|
||||
test/templates/unicode_code_py3k.html
|
||||
test/templates/unicode_expr.html
|
||||
test/templates/unicode_expr_py3k.html
|
||||
test/templates/unicode_runtime_error.html
|
||||
test/templates/unicode_syntax_error.html
|
||||
test/templates/foo/modtest.html.py
|
||||
test/templates/othersubdir/foo.html
|
||||
test/templates/subdir/incl.html
|
||||
test/templates/subdir/index.html
|
||||
test/templates/subdir/modtest.html
|
||||
test/templates/subdir/foo/modtest.html.py
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
|
||||
[python.templating.engines]
|
||||
mako = mako.ext.turbogears:TGPlugin
|
||||
|
||||
[pygments.lexers]
|
||||
mako = mako.ext.pygmentplugin:MakoLexer
|
||||
html+mako = mako.ext.pygmentplugin:MakoHtmlLexer
|
||||
xml+mako = mako.ext.pygmentplugin:MakoXmlLexer
|
||||
js+mako = mako.ext.pygmentplugin:MakoJavascriptLexer
|
||||
css+mako = mako.ext.pygmentplugin:MakoCssLexer
|
||||
|
||||
[babel.extractors]
|
||||
mako = mako.ext.babelplugin:extract
|
||||
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
../mako/compat.py
|
||||
../mako/ast.py
|
||||
../mako/codegen.py
|
||||
../mako/util.py
|
||||
../mako/pygen.py
|
||||
../mako/runtime.py
|
||||
../mako/exceptions.py
|
||||
../mako/lexer.py
|
||||
../mako/lookup.py
|
||||
../mako/template.py
|
||||
../mako/__init__.py
|
||||
../mako/_ast_util.py
|
||||
../mako/pyparser.py
|
||||
../mako/filters.py
|
||||
../mako/parsetree.py
|
||||
../mako/cache.py
|
||||
../mako/ext/babelplugin.py
|
||||
../mako/ext/turbogears.py
|
||||
../mako/ext/preprocessors.py
|
||||
../mako/ext/autohandler.py
|
||||
../mako/ext/beaker_cache.py
|
||||
../mako/ext/__init__.py
|
||||
../mako/ext/pygmentplugin.py
|
||||
../mako/compat.pyc
|
||||
../mako/ast.pyc
|
||||
../mako/codegen.pyc
|
||||
../mako/util.pyc
|
||||
../mako/pygen.pyc
|
||||
../mako/runtime.pyc
|
||||
../mako/exceptions.pyc
|
||||
../mako/lexer.pyc
|
||||
../mako/lookup.pyc
|
||||
../mako/template.pyc
|
||||
../mako/__init__.pyc
|
||||
../mako/_ast_util.pyc
|
||||
../mako/pyparser.pyc
|
||||
../mako/filters.pyc
|
||||
../mako/parsetree.pyc
|
||||
../mako/cache.pyc
|
||||
../mako/ext/babelplugin.pyc
|
||||
../mako/ext/turbogears.pyc
|
||||
../mako/ext/preprocessors.pyc
|
||||
../mako/ext/autohandler.pyc
|
||||
../mako/ext/beaker_cache.pyc
|
||||
../mako/ext/__init__.pyc
|
||||
../mako/ext/pygmentplugin.pyc
|
||||
./
|
||||
requires.txt
|
||||
SOURCES.txt
|
||||
entry_points.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
../../../../bin/mako-render
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
MarkupSafe>=0.9.2
|
||||
|
||||
[beaker]
|
||||
Beaker>=1.1
|
||||
|
|
@ -0,0 +1 @@
|
|||
mako
|
||||
|
|
@ -0,0 +1,119 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: MarkupSafe
|
||||
Version: 0.23
|
||||
Summary: Implements a XML/HTML/XHTML Markup safe string for Python
|
||||
Home-page: http://github.com/mitsuhiko/markupsafe
|
||||
Author: Armin Ronacher
|
||||
Author-email: armin.ronacher@active-4.com
|
||||
License: BSD
|
||||
Description: MarkupSafe
|
||||
==========
|
||||
|
||||
Implements a unicode subclass that supports HTML strings:
|
||||
|
||||
>>> from markupsafe import Markup, escape
|
||||
>>> escape("<script>alert(document.cookie);</script>")
|
||||
Markup(u'<script>alert(document.cookie);</script>')
|
||||
>>> tmpl = Markup("<em>%s</em>")
|
||||
>>> tmpl % "Peter > Lustig"
|
||||
Markup(u'<em>Peter > Lustig</em>')
|
||||
|
||||
If you want to make an object unicode that is not yet unicode
|
||||
but don't want to lose the taint information, you can use the
|
||||
`soft_unicode` function. (On Python 3 you can also use `soft_str` which
|
||||
is a different name for the same function).
|
||||
|
||||
>>> from markupsafe import soft_unicode
|
||||
>>> soft_unicode(42)
|
||||
u'42'
|
||||
>>> soft_unicode(Markup('foo'))
|
||||
Markup(u'foo')
|
||||
|
||||
HTML Representations
|
||||
--------------------
|
||||
|
||||
Objects can customize their HTML markup equivalent by overriding
|
||||
the `__html__` function:
|
||||
|
||||
>>> class Foo(object):
|
||||
... def __html__(self):
|
||||
... return '<strong>Nice</strong>'
|
||||
...
|
||||
>>> escape(Foo())
|
||||
Markup(u'<strong>Nice</strong>')
|
||||
>>> Markup(Foo())
|
||||
Markup(u'<strong>Nice</strong>')
|
||||
|
||||
Silent Escapes
|
||||
--------------
|
||||
|
||||
Since MarkupSafe 0.10 there is now also a separate escape function
|
||||
called `escape_silent` that returns an empty string for `None` for
|
||||
consistency with other systems that return empty strings for `None`
|
||||
when escaping (for instance Pylons' webhelpers).
|
||||
|
||||
If you also want to use this for the escape method of the Markup
|
||||
object, you can create your own subclass that does that::
|
||||
|
||||
from markupsafe import Markup, escape_silent as escape
|
||||
|
||||
class SilentMarkup(Markup):
|
||||
__slots__ = ()
|
||||
|
||||
@classmethod
|
||||
def escape(cls, s):
|
||||
return cls(escape(s))
|
||||
|
||||
New-Style String Formatting
|
||||
---------------------------
|
||||
|
||||
Starting with MarkupSafe 0.21 new style string formats from Python 2.6 and
|
||||
3.x are now fully supported. Previously the escape behavior of those
|
||||
functions was spotty at best. The new implementations operates under the
|
||||
following algorithm:
|
||||
|
||||
1. if an object has an ``__html_format__`` method it is called as
|
||||
replacement for ``__format__`` with the format specifier. It either
|
||||
has to return a string or markup object.
|
||||
2. if an object has an ``__html__`` method it is called.
|
||||
3. otherwise the default format system of Python kicks in and the result
|
||||
is HTML escaped.
|
||||
|
||||
Here is how you can implement your own formatting::
|
||||
|
||||
class User(object):
|
||||
|
||||
def __init__(self, id, username):
|
||||
self.id = id
|
||||
self.username = username
|
||||
|
||||
def __html_format__(self, format_spec):
|
||||
if format_spec == 'link':
|
||||
return Markup('<a href="/user/{0}">{1}</a>').format(
|
||||
self.id,
|
||||
self.__html__(),
|
||||
)
|
||||
elif format_spec:
|
||||
raise ValueError('Invalid format spec')
|
||||
return self.__html__()
|
||||
|
||||
def __html__(self):
|
||||
return Markup('<span class=user>{0}</span>').format(self.username)
|
||||
|
||||
And to format that user:
|
||||
|
||||
>>> user = User(1, 'foo')
|
||||
>>> Markup('<p>User: {0:link}').format(user)
|
||||
Markup(u'<p>User: <a href="/user/1"><span class=user>foo</span></a>')
|
||||
|
||||
Platform: UNKNOWN
|
||||
Classifier: Development Status :: 5 - Production/Stable
|
||||
Classifier: Environment :: Web Environment
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: License :: OSI Approved :: BSD License
|
||||
Classifier: Operating System :: OS Independent
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
||||
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
||||
Classifier: Topic :: Text Processing :: Markup :: HTML
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
AUTHORS
|
||||
LICENSE
|
||||
MANIFEST.in
|
||||
README.rst
|
||||
setup.cfg
|
||||
setup.py
|
||||
MarkupSafe.egg-info/PKG-INFO
|
||||
MarkupSafe.egg-info/SOURCES.txt
|
||||
MarkupSafe.egg-info/dependency_links.txt
|
||||
MarkupSafe.egg-info/not-zip-safe
|
||||
MarkupSafe.egg-info/top_level.txt
|
||||
markupsafe/__init__.py
|
||||
markupsafe/_compat.py
|
||||
markupsafe/_constants.py
|
||||
markupsafe/_native.py
|
||||
markupsafe/_speedups.c
|
||||
markupsafe/tests.py
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
../markupsafe/_compat.py
|
||||
../markupsafe/_native.py
|
||||
../markupsafe/__init__.py
|
||||
../markupsafe/_constants.py
|
||||
../markupsafe/tests.py
|
||||
../markupsafe/_speedups.c
|
||||
../markupsafe/_compat.pyc
|
||||
../markupsafe/_native.pyc
|
||||
../markupsafe/__init__.pyc
|
||||
../markupsafe/_constants.pyc
|
||||
../markupsafe/tests.pyc
|
||||
../markupsafe/_speedups.so
|
||||
./
|
||||
SOURCES.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1 @@
|
|||
markupsafe
|
||||
1423
Linux_i686/lib/python2.7/site-packages/OpenSSL/SSL.py
Normal file
1423
Linux_i686/lib/python2.7/site-packages/OpenSSL/SSL.py
Normal file
File diff suppressed because it is too large
Load diff
12
Linux_i686/lib/python2.7/site-packages/OpenSSL/__init__.py
Normal file
12
Linux_i686/lib/python2.7/site-packages/OpenSSL/__init__.py
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
# Copyright (C) AB Strakt
|
||||
# See LICENSE for details.
|
||||
|
||||
"""
|
||||
pyOpenSSL - A simple wrapper around the OpenSSL library
|
||||
"""
|
||||
|
||||
from OpenSSL import rand, crypto, SSL
|
||||
from OpenSSL.version import __version__
|
||||
|
||||
__all__ = [
|
||||
'rand', 'crypto', 'SSL', 'tsafe', '__version__']
|
||||
53
Linux_i686/lib/python2.7/site-packages/OpenSSL/_util.py
Normal file
53
Linux_i686/lib/python2.7/site-packages/OpenSSL/_util.py
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
from six import PY3, binary_type, text_type
|
||||
|
||||
from cryptography.hazmat.bindings.openssl.binding import Binding
|
||||
binding = Binding()
|
||||
ffi = binding.ffi
|
||||
lib = binding.lib
|
||||
|
||||
def exception_from_error_queue(exceptionType):
|
||||
def text(charp):
|
||||
return native(ffi.string(charp))
|
||||
|
||||
errors = []
|
||||
while True:
|
||||
error = lib.ERR_get_error()
|
||||
if error == 0:
|
||||
break
|
||||
errors.append((
|
||||
text(lib.ERR_lib_error_string(error)),
|
||||
text(lib.ERR_func_error_string(error)),
|
||||
text(lib.ERR_reason_error_string(error))))
|
||||
|
||||
raise exceptionType(errors)
|
||||
|
||||
|
||||
|
||||
def native(s):
|
||||
"""
|
||||
Convert :py:class:`bytes` or :py:class:`unicode` to the native
|
||||
:py:class:`str` type, using UTF-8 encoding if conversion is necessary.
|
||||
|
||||
:raise UnicodeError: The input string is not UTF-8 decodeable.
|
||||
|
||||
:raise TypeError: The input is neither :py:class:`bytes` nor
|
||||
:py:class:`unicode`.
|
||||
"""
|
||||
if not isinstance(s, (binary_type, text_type)):
|
||||
raise TypeError("%r is neither bytes nor unicode" % s)
|
||||
if PY3:
|
||||
if isinstance(s, binary_type):
|
||||
return s.decode("utf-8")
|
||||
else:
|
||||
if isinstance(s, text_type):
|
||||
return s.encode("utf-8")
|
||||
return s
|
||||
|
||||
|
||||
|
||||
if PY3:
|
||||
def byte_string(s):
|
||||
return s.encode("charmap")
|
||||
else:
|
||||
def byte_string(s):
|
||||
return s
|
||||
2314
Linux_i686/lib/python2.7/site-packages/OpenSSL/crypto.py
Normal file
2314
Linux_i686/lib/python2.7/site-packages/OpenSSL/crypto.py
Normal file
File diff suppressed because it is too large
Load diff
180
Linux_i686/lib/python2.7/site-packages/OpenSSL/rand.py
Normal file
180
Linux_i686/lib/python2.7/site-packages/OpenSSL/rand.py
Normal file
|
|
@ -0,0 +1,180 @@
|
|||
"""
|
||||
PRNG management routines, thin wrappers.
|
||||
|
||||
See the file RATIONALE for a short explanation of why this module was written.
|
||||
"""
|
||||
|
||||
from functools import partial
|
||||
|
||||
from six import integer_types as _integer_types
|
||||
|
||||
from OpenSSL._util import (
|
||||
ffi as _ffi,
|
||||
lib as _lib,
|
||||
exception_from_error_queue as _exception_from_error_queue)
|
||||
|
||||
|
||||
class Error(Exception):
|
||||
"""
|
||||
An error occurred in an `OpenSSL.rand` API.
|
||||
"""
|
||||
|
||||
_raise_current_error = partial(_exception_from_error_queue, Error)
|
||||
|
||||
_unspecified = object()
|
||||
|
||||
_builtin_bytes = bytes
|
||||
|
||||
def bytes(num_bytes):
|
||||
"""
|
||||
Get some random bytes as a string.
|
||||
|
||||
:param num_bytes: The number of bytes to fetch
|
||||
:return: A string of random bytes
|
||||
"""
|
||||
if not isinstance(num_bytes, _integer_types):
|
||||
raise TypeError("num_bytes must be an integer")
|
||||
|
||||
if num_bytes < 0:
|
||||
raise ValueError("num_bytes must not be negative")
|
||||
|
||||
result_buffer = _ffi.new("char[]", num_bytes)
|
||||
result_code = _lib.RAND_bytes(result_buffer, num_bytes)
|
||||
if result_code == -1:
|
||||
# TODO: No tests for this code path. Triggering a RAND_bytes failure
|
||||
# might involve supplying a custom ENGINE? That's hard.
|
||||
_raise_current_error()
|
||||
|
||||
return _ffi.buffer(result_buffer)[:]
|
||||
|
||||
|
||||
|
||||
def add(buffer, entropy):
|
||||
"""
|
||||
Add data with a given entropy to the PRNG
|
||||
|
||||
:param buffer: Buffer with random data
|
||||
:param entropy: The entropy (in bytes) measurement of the buffer
|
||||
:return: None
|
||||
"""
|
||||
if not isinstance(buffer, _builtin_bytes):
|
||||
raise TypeError("buffer must be a byte string")
|
||||
|
||||
if not isinstance(entropy, int):
|
||||
raise TypeError("entropy must be an integer")
|
||||
|
||||
# TODO Nothing tests this call actually being made, or made properly.
|
||||
_lib.RAND_add(buffer, len(buffer), entropy)
|
||||
|
||||
|
||||
|
||||
def seed(buffer):
|
||||
"""
|
||||
Alias for rand_add, with entropy equal to length
|
||||
|
||||
:param buffer: Buffer with random data
|
||||
:return: None
|
||||
"""
|
||||
if not isinstance(buffer, _builtin_bytes):
|
||||
raise TypeError("buffer must be a byte string")
|
||||
|
||||
# TODO Nothing tests this call actually being made, or made properly.
|
||||
_lib.RAND_seed(buffer, len(buffer))
|
||||
|
||||
|
||||
|
||||
def status():
|
||||
"""
|
||||
Retrieve the status of the PRNG
|
||||
|
||||
:return: True if the PRNG is seeded enough, false otherwise
|
||||
"""
|
||||
return _lib.RAND_status()
|
||||
|
||||
|
||||
|
||||
def egd(path, bytes=_unspecified):
|
||||
"""
|
||||
Query an entropy gathering daemon (EGD) for random data and add it to the
|
||||
PRNG. I haven't found any problems when the socket is missing, the function
|
||||
just returns 0.
|
||||
|
||||
:param path: The path to the EGD socket
|
||||
:param bytes: (optional) The number of bytes to read, default is 255
|
||||
:returns: The number of bytes read (NB: a value of 0 isn't necessarily an
|
||||
error, check rand.status())
|
||||
"""
|
||||
if not isinstance(path, _builtin_bytes):
|
||||
raise TypeError("path must be a byte string")
|
||||
|
||||
if bytes is _unspecified:
|
||||
bytes = 255
|
||||
elif not isinstance(bytes, int):
|
||||
raise TypeError("bytes must be an integer")
|
||||
|
||||
return _lib.RAND_egd_bytes(path, bytes)
|
||||
|
||||
|
||||
|
||||
def cleanup():
|
||||
"""
|
||||
Erase the memory used by the PRNG.
|
||||
|
||||
:return: None
|
||||
"""
|
||||
# TODO Nothing tests this call actually being made, or made properly.
|
||||
_lib.RAND_cleanup()
|
||||
|
||||
|
||||
|
||||
def load_file(filename, maxbytes=_unspecified):
|
||||
"""
|
||||
Seed the PRNG with data from a file
|
||||
|
||||
:param filename: The file to read data from
|
||||
:param maxbytes: (optional) The number of bytes to read, default is
|
||||
to read the entire file
|
||||
:return: The number of bytes read
|
||||
"""
|
||||
if not isinstance(filename, _builtin_bytes):
|
||||
raise TypeError("filename must be a string")
|
||||
|
||||
if maxbytes is _unspecified:
|
||||
maxbytes = -1
|
||||
elif not isinstance(maxbytes, int):
|
||||
raise TypeError("maxbytes must be an integer")
|
||||
|
||||
return _lib.RAND_load_file(filename, maxbytes)
|
||||
|
||||
|
||||
|
||||
def write_file(filename):
|
||||
"""
|
||||
Save PRNG state to a file
|
||||
|
||||
:param filename: The file to write data to
|
||||
:return: The number of bytes written
|
||||
"""
|
||||
if not isinstance(filename, _builtin_bytes):
|
||||
raise TypeError("filename must be a string")
|
||||
|
||||
return _lib.RAND_write_file(filename)
|
||||
|
||||
|
||||
# TODO There are no tests for screen at all
|
||||
def screen():
|
||||
"""
|
||||
Add the current contents of the screen to the PRNG state. Availability:
|
||||
Windows.
|
||||
|
||||
:return: None
|
||||
"""
|
||||
_lib.RAND_screen()
|
||||
|
||||
if getattr(_lib, 'RAND_screen', None) is None:
|
||||
del screen
|
||||
|
||||
|
||||
# TODO There are no tests for the RAND strings being loaded, whatever that
|
||||
# means.
|
||||
_lib.ERR_load_RAND_strings()
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
# Copyright (C) Jean-Paul Calderone
|
||||
# See LICENSE for details.
|
||||
|
||||
"""
|
||||
Package containing unit tests for :py:mod:`OpenSSL`.
|
||||
"""
|
||||
3037
Linux_i686/lib/python2.7/site-packages/OpenSSL/test/test_crypto.py
Normal file
3037
Linux_i686/lib/python2.7/site-packages/OpenSSL/test/test_crypto.py
Normal file
File diff suppressed because it is too large
Load diff
203
Linux_i686/lib/python2.7/site-packages/OpenSSL/test/test_rand.py
Normal file
203
Linux_i686/lib/python2.7/site-packages/OpenSSL/test/test_rand.py
Normal file
|
|
@ -0,0 +1,203 @@
|
|||
# Copyright (c) Frederick Dean
|
||||
# See LICENSE for details.
|
||||
|
||||
"""
|
||||
Unit tests for :py:obj:`OpenSSL.rand`.
|
||||
"""
|
||||
|
||||
from unittest import main
|
||||
import os
|
||||
import stat
|
||||
import sys
|
||||
|
||||
from OpenSSL.test.util import TestCase, b
|
||||
from OpenSSL import rand
|
||||
|
||||
|
||||
class RandTests(TestCase):
|
||||
def test_bytes_wrong_args(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.bytes` raises :py:obj:`TypeError` if called with the wrong
|
||||
number of arguments or with a non-:py:obj:`int` argument.
|
||||
"""
|
||||
self.assertRaises(TypeError, rand.bytes)
|
||||
self.assertRaises(TypeError, rand.bytes, None)
|
||||
self.assertRaises(TypeError, rand.bytes, 3, None)
|
||||
|
||||
|
||||
def test_insufficientMemory(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.bytes` raises :py:obj:`MemoryError` if more bytes
|
||||
are requested than will fit in memory.
|
||||
"""
|
||||
self.assertRaises(MemoryError, rand.bytes, sys.maxsize)
|
||||
|
||||
|
||||
def test_bytes(self):
|
||||
"""
|
||||
Verify that we can obtain bytes from rand_bytes() and
|
||||
that they are different each time. Test the parameter
|
||||
of rand_bytes() for bad values.
|
||||
"""
|
||||
b1 = rand.bytes(50)
|
||||
self.assertEqual(len(b1), 50)
|
||||
b2 = rand.bytes(num_bytes=50) # parameter by name
|
||||
self.assertNotEqual(b1, b2) # Hip, Hip, Horay! FIPS complaince
|
||||
b3 = rand.bytes(num_bytes=0)
|
||||
self.assertEqual(len(b3), 0)
|
||||
exc = self.assertRaises(ValueError, rand.bytes, -1)
|
||||
self.assertEqual(str(exc), "num_bytes must not be negative")
|
||||
|
||||
|
||||
def test_add_wrong_args(self):
|
||||
"""
|
||||
When called with the wrong number of arguments, or with arguments not of
|
||||
type :py:obj:`str` and :py:obj:`int`, :py:obj:`OpenSSL.rand.add` raises :py:obj:`TypeError`.
|
||||
"""
|
||||
self.assertRaises(TypeError, rand.add)
|
||||
self.assertRaises(TypeError, rand.add, b("foo"), None)
|
||||
self.assertRaises(TypeError, rand.add, None, 3)
|
||||
self.assertRaises(TypeError, rand.add, b("foo"), 3, None)
|
||||
|
||||
|
||||
def test_add(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.add` adds entropy to the PRNG.
|
||||
"""
|
||||
rand.add(b('hamburger'), 3)
|
||||
|
||||
|
||||
def test_seed_wrong_args(self):
|
||||
"""
|
||||
When called with the wrong number of arguments, or with a non-:py:obj:`str`
|
||||
argument, :py:obj:`OpenSSL.rand.seed` raises :py:obj:`TypeError`.
|
||||
"""
|
||||
self.assertRaises(TypeError, rand.seed)
|
||||
self.assertRaises(TypeError, rand.seed, None)
|
||||
self.assertRaises(TypeError, rand.seed, b("foo"), None)
|
||||
|
||||
|
||||
def test_seed(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.seed` adds entropy to the PRNG.
|
||||
"""
|
||||
rand.seed(b('milk shake'))
|
||||
|
||||
|
||||
def test_status_wrong_args(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.status` raises :py:obj:`TypeError` when called with any
|
||||
arguments.
|
||||
"""
|
||||
self.assertRaises(TypeError, rand.status, None)
|
||||
|
||||
|
||||
def test_status(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.status` returns :py:obj:`True` if the PRNG has sufficient
|
||||
entropy, :py:obj:`False` otherwise.
|
||||
"""
|
||||
# It's hard to know what it is actually going to return. Different
|
||||
# OpenSSL random engines decide differently whether they have enough
|
||||
# entropy or not.
|
||||
self.assertTrue(rand.status() in (1, 2))
|
||||
|
||||
|
||||
def test_egd_wrong_args(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.egd` raises :py:obj:`TypeError` when called with the wrong
|
||||
number of arguments or with arguments not of type :py:obj:`str` and :py:obj:`int`.
|
||||
"""
|
||||
self.assertRaises(TypeError, rand.egd)
|
||||
self.assertRaises(TypeError, rand.egd, None)
|
||||
self.assertRaises(TypeError, rand.egd, "foo", None)
|
||||
self.assertRaises(TypeError, rand.egd, None, 3)
|
||||
self.assertRaises(TypeError, rand.egd, "foo", 3, None)
|
||||
|
||||
|
||||
def test_egd_missing(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.egd` returns :py:obj:`0` or :py:obj:`-1` if the
|
||||
EGD socket passed to it does not exist.
|
||||
"""
|
||||
result = rand.egd(self.mktemp())
|
||||
expected = (-1, 0)
|
||||
self.assertTrue(
|
||||
result in expected,
|
||||
"%r not in %r" % (result, expected))
|
||||
|
||||
|
||||
def test_egd_missing_and_bytes(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.egd` returns :py:obj:`0` or :py:obj:`-1` if the
|
||||
EGD socket passed to it does not exist even if a size argument is
|
||||
explicitly passed.
|
||||
"""
|
||||
result = rand.egd(self.mktemp(), 1024)
|
||||
expected = (-1, 0)
|
||||
self.assertTrue(
|
||||
result in expected,
|
||||
"%r not in %r" % (result, expected))
|
||||
|
||||
|
||||
def test_cleanup_wrong_args(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.cleanup` raises :py:obj:`TypeError` when called with any
|
||||
arguments.
|
||||
"""
|
||||
self.assertRaises(TypeError, rand.cleanup, None)
|
||||
|
||||
|
||||
def test_cleanup(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.cleanup` releases the memory used by the PRNG and returns
|
||||
:py:obj:`None`.
|
||||
"""
|
||||
self.assertIdentical(rand.cleanup(), None)
|
||||
|
||||
|
||||
def test_load_file_wrong_args(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.load_file` raises :py:obj:`TypeError` when called the wrong
|
||||
number of arguments or arguments not of type :py:obj:`str` and :py:obj:`int`.
|
||||
"""
|
||||
self.assertRaises(TypeError, rand.load_file)
|
||||
self.assertRaises(TypeError, rand.load_file, "foo", None)
|
||||
self.assertRaises(TypeError, rand.load_file, None, 1)
|
||||
self.assertRaises(TypeError, rand.load_file, "foo", 1, None)
|
||||
|
||||
|
||||
def test_write_file_wrong_args(self):
|
||||
"""
|
||||
:py:obj:`OpenSSL.rand.write_file` raises :py:obj:`TypeError` when called with the
|
||||
wrong number of arguments or a non-:py:obj:`str` argument.
|
||||
"""
|
||||
self.assertRaises(TypeError, rand.write_file)
|
||||
self.assertRaises(TypeError, rand.write_file, None)
|
||||
self.assertRaises(TypeError, rand.write_file, "foo", None)
|
||||
|
||||
|
||||
def test_files(self):
|
||||
"""
|
||||
Test reading and writing of files via rand functions.
|
||||
"""
|
||||
# Write random bytes to a file
|
||||
tmpfile = self.mktemp()
|
||||
# Make sure it exists (so cleanup definitely succeeds)
|
||||
fObj = open(tmpfile, 'w')
|
||||
fObj.close()
|
||||
try:
|
||||
rand.write_file(tmpfile)
|
||||
# Verify length of written file
|
||||
size = os.stat(tmpfile)[stat.ST_SIZE]
|
||||
self.assertEqual(1024, size)
|
||||
# Read random bytes from file
|
||||
rand.load_file(tmpfile)
|
||||
rand.load_file(tmpfile, 4) # specify a length
|
||||
finally:
|
||||
# Cleanup
|
||||
os.unlink(tmpfile)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
2736
Linux_i686/lib/python2.7/site-packages/OpenSSL/test/test_ssl.py
Normal file
2736
Linux_i686/lib/python2.7/site-packages/OpenSSL/test/test_ssl.py
Normal file
File diff suppressed because it is too large
Load diff
302
Linux_i686/lib/python2.7/site-packages/OpenSSL/test/util.py
Normal file
302
Linux_i686/lib/python2.7/site-packages/OpenSSL/test/util.py
Normal file
|
|
@ -0,0 +1,302 @@
|
|||
# Copyright (C) Jean-Paul Calderone
|
||||
# Copyright (C) Twisted Matrix Laboratories.
|
||||
# See LICENSE for details.
|
||||
|
||||
"""
|
||||
Helpers for the OpenSSL test suite, largely copied from
|
||||
U{Twisted<http://twistedmatrix.com/>}.
|
||||
"""
|
||||
|
||||
import shutil
|
||||
import traceback
|
||||
import os, os.path
|
||||
from tempfile import mktemp
|
||||
from unittest import TestCase
|
||||
import sys
|
||||
|
||||
from OpenSSL._util import exception_from_error_queue
|
||||
from OpenSSL.crypto import Error
|
||||
|
||||
try:
|
||||
import memdbg
|
||||
except Exception:
|
||||
class _memdbg(object): heap = None
|
||||
memdbg = _memdbg()
|
||||
|
||||
from OpenSSL._util import ffi, lib, byte_string as b
|
||||
|
||||
class TestCase(TestCase):
|
||||
"""
|
||||
:py:class:`TestCase` adds useful testing functionality beyond what is available
|
||||
from the standard library :py:class:`unittest.TestCase`.
|
||||
"""
|
||||
def run(self, result):
|
||||
run = super(TestCase, self).run
|
||||
if memdbg.heap is None:
|
||||
return run(result)
|
||||
|
||||
# Run the test as usual
|
||||
before = set(memdbg.heap)
|
||||
run(result)
|
||||
|
||||
# Clean up some long-lived allocations so they won't be reported as
|
||||
# memory leaks.
|
||||
lib.CRYPTO_cleanup_all_ex_data()
|
||||
lib.ERR_remove_thread_state(ffi.NULL)
|
||||
after = set(memdbg.heap)
|
||||
|
||||
if not after - before:
|
||||
# No leaks, fast succeed
|
||||
return
|
||||
|
||||
if result.wasSuccessful():
|
||||
# If it passed, run it again with memory debugging
|
||||
before = set(memdbg.heap)
|
||||
run(result)
|
||||
|
||||
# Clean up some long-lived allocations so they won't be reported as
|
||||
# memory leaks.
|
||||
lib.CRYPTO_cleanup_all_ex_data()
|
||||
lib.ERR_remove_thread_state(ffi.NULL)
|
||||
|
||||
after = set(memdbg.heap)
|
||||
|
||||
self._reportLeaks(after - before, result)
|
||||
|
||||
|
||||
def _reportLeaks(self, leaks, result):
|
||||
def format_leak(p):
|
||||
stacks = memdbg.heap[p]
|
||||
# Eventually look at multiple stacks for the realloc() case. For
|
||||
# now just look at the original allocation location.
|
||||
(size, python_stack, c_stack) = stacks[0]
|
||||
|
||||
stack = traceback.format_list(python_stack)[:-1]
|
||||
|
||||
# c_stack looks something like this (interesting parts indicated
|
||||
# with inserted arrows not part of the data):
|
||||
#
|
||||
# /home/exarkun/Projects/pyOpenSSL/branches/use-opentls/__pycache__/_cffi__x89095113xb9185b9b.so(+0x12cf) [0x7fe2e20582cf]
|
||||
# /home/exarkun/Projects/cpython/2.7/python(PyCFunction_Call+0x8b) [0x56265a]
|
||||
# /home/exarkun/Projects/cpython/2.7/python() [0x4d5f52]
|
||||
# /home/exarkun/Projects/cpython/2.7/python(PyEval_EvalFrameEx+0x753b) [0x4d0e1e]
|
||||
# /home/exarkun/Projects/cpython/2.7/python() [0x4d6419]
|
||||
# /home/exarkun/Projects/cpython/2.7/python() [0x4d6129]
|
||||
# /home/exarkun/Projects/cpython/2.7/python(PyEval_EvalFrameEx+0x753b) [0x4d0e1e]
|
||||
# /home/exarkun/Projects/cpython/2.7/python(PyEval_EvalCodeEx+0x1043) [0x4d3726]
|
||||
# /home/exarkun/Projects/cpython/2.7/python() [0x55fd51]
|
||||
# /home/exarkun/Projects/cpython/2.7/python(PyObject_Call+0x7e) [0x420ee6]
|
||||
# /home/exarkun/Projects/cpython/2.7/python(PyEval_CallObjectWithKeywords+0x158) [0x4d56ec]
|
||||
# /home/exarkun/.local/lib/python2.7/site-packages/cffi-0.5-py2.7-linux-x86_64.egg/_cffi_backend.so(+0xe96e) [0x7fe2e38be96e]
|
||||
# /usr/lib/x86_64-linux-gnu/libffi.so.6(ffi_closure_unix64_inner+0x1b9) [0x7fe2e36ad819]
|
||||
# /usr/lib/x86_64-linux-gnu/libffi.so.6(ffi_closure_unix64+0x46) [0x7fe2e36adb7c]
|
||||
# /lib/x86_64-linux-gnu/libcrypto.so.1.0.0(CRYPTO_malloc+0x64) [0x7fe2e1cef784] <------ end interesting
|
||||
# /lib/x86_64-linux-gnu/libcrypto.so.1.0.0(lh_insert+0x16b) [0x7fe2e1d6a24b] .
|
||||
# /lib/x86_64-linux-gnu/libcrypto.so.1.0.0(+0x61c18) [0x7fe2e1cf0c18] .
|
||||
# /lib/x86_64-linux-gnu/libcrypto.so.1.0.0(+0x625ec) [0x7fe2e1cf15ec] .
|
||||
# /lib/x86_64-linux-gnu/libcrypto.so.1.0.0(DSA_new_method+0xe6) [0x7fe2e1d524d6] .
|
||||
# /lib/x86_64-linux-gnu/libcrypto.so.1.0.0(DSA_generate_parameters+0x3a) [0x7fe2e1d5364a] <------ begin interesting
|
||||
# /home/exarkun/Projects/opentls/trunk/tls/c/__pycache__/_cffi__x305d4698xb539baaa.so(+0x1f397) [0x7fe2df84d397]
|
||||
# /home/exarkun/Projects/cpython/2.7/python(PyCFunction_Call+0x8b) [0x56265a]
|
||||
# /home/exarkun/Projects/cpython/2.7/python() [0x4d5f52]
|
||||
# /home/exarkun/Projects/cpython/2.7/python(PyEval_EvalFrameEx+0x753b) [0x4d0e1e]
|
||||
# /home/exarkun/Projects/cpython/2.7/python() [0x4d6419]
|
||||
# ...
|
||||
#
|
||||
# Notice the stack is upside down compared to a Python traceback.
|
||||
# Identify the start and end of interesting bits and stuff it into the stack we report.
|
||||
|
||||
saved = list(c_stack)
|
||||
|
||||
# Figure the first interesting frame will be after a the cffi-compiled module
|
||||
while c_stack and '/__pycache__/_cffi__' not in c_stack[-1]:
|
||||
c_stack.pop()
|
||||
|
||||
# Figure the last interesting frame will always be CRYPTO_malloc,
|
||||
# since that's where we hooked in to things.
|
||||
while c_stack and 'CRYPTO_malloc' not in c_stack[0] and 'CRYPTO_realloc' not in c_stack[0]:
|
||||
c_stack.pop(0)
|
||||
|
||||
if c_stack:
|
||||
c_stack.reverse()
|
||||
else:
|
||||
c_stack = saved[::-1]
|
||||
stack.extend([frame + "\n" for frame in c_stack])
|
||||
|
||||
stack.insert(0, "Leaked (%s) at:\n")
|
||||
return "".join(stack)
|
||||
|
||||
if leaks:
|
||||
unique_leaks = {}
|
||||
for p in leaks:
|
||||
size = memdbg.heap[p][-1][0]
|
||||
new_leak = format_leak(p)
|
||||
if new_leak not in unique_leaks:
|
||||
unique_leaks[new_leak] = [(size, p)]
|
||||
else:
|
||||
unique_leaks[new_leak].append((size, p))
|
||||
memdbg.free(p)
|
||||
|
||||
for (stack, allocs) in unique_leaks.iteritems():
|
||||
allocs_accum = []
|
||||
for (size, pointer) in allocs:
|
||||
|
||||
addr = int(ffi.cast('uintptr_t', pointer))
|
||||
allocs_accum.append("%d@0x%x" % (size, addr))
|
||||
allocs_report = ", ".join(sorted(allocs_accum))
|
||||
|
||||
result.addError(
|
||||
self,
|
||||
(None, Exception(stack % (allocs_report,)), None))
|
||||
|
||||
|
||||
def tearDown(self):
|
||||
"""
|
||||
Clean up any files or directories created using :py:meth:`TestCase.mktemp`.
|
||||
Subclasses must invoke this method if they override it or the
|
||||
cleanup will not occur.
|
||||
"""
|
||||
if False and self._temporaryFiles is not None:
|
||||
for temp in self._temporaryFiles:
|
||||
if os.path.isdir(temp):
|
||||
shutil.rmtree(temp)
|
||||
elif os.path.exists(temp):
|
||||
os.unlink(temp)
|
||||
try:
|
||||
exception_from_error_queue(Error)
|
||||
except Error:
|
||||
e = sys.exc_info()[1]
|
||||
if e.args != ([],):
|
||||
self.fail("Left over errors in OpenSSL error queue: " + repr(e))
|
||||
|
||||
|
||||
def assertIsInstance(self, instance, classOrTuple, message=None):
|
||||
"""
|
||||
Fail if C{instance} is not an instance of the given class or of
|
||||
one of the given classes.
|
||||
|
||||
@param instance: the object to test the type (first argument of the
|
||||
C{isinstance} call).
|
||||
@type instance: any.
|
||||
@param classOrTuple: the class or classes to test against (second
|
||||
argument of the C{isinstance} call).
|
||||
@type classOrTuple: class, type, or tuple.
|
||||
|
||||
@param message: Custom text to include in the exception text if the
|
||||
assertion fails.
|
||||
"""
|
||||
if not isinstance(instance, classOrTuple):
|
||||
if message is None:
|
||||
suffix = ""
|
||||
else:
|
||||
suffix = ": " + message
|
||||
self.fail("%r is not an instance of %s%s" % (
|
||||
instance, classOrTuple, suffix))
|
||||
|
||||
|
||||
def failUnlessIn(self, containee, container, msg=None):
|
||||
"""
|
||||
Fail the test if :py:data:`containee` is not found in :py:data:`container`.
|
||||
|
||||
:param containee: the value that should be in :py:class:`container`
|
||||
:param container: a sequence type, or in the case of a mapping type,
|
||||
will follow semantics of 'if key in dict.keys()'
|
||||
:param msg: if msg is None, then the failure message will be
|
||||
'%r not in %r' % (first, second)
|
||||
"""
|
||||
if containee not in container:
|
||||
raise self.failureException(msg or "%r not in %r"
|
||||
% (containee, container))
|
||||
return containee
|
||||
assertIn = failUnlessIn
|
||||
|
||||
def failUnlessIdentical(self, first, second, msg=None):
|
||||
"""
|
||||
Fail the test if :py:data:`first` is not :py:data:`second`. This is an
|
||||
obect-identity-equality test, not an object equality
|
||||
(i.e. :py:func:`__eq__`) test.
|
||||
|
||||
:param msg: if msg is None, then the failure message will be
|
||||
'%r is not %r' % (first, second)
|
||||
"""
|
||||
if first is not second:
|
||||
raise self.failureException(msg or '%r is not %r' % (first, second))
|
||||
return first
|
||||
assertIdentical = failUnlessIdentical
|
||||
|
||||
|
||||
def failIfIdentical(self, first, second, msg=None):
|
||||
"""
|
||||
Fail the test if :py:data:`first` is :py:data:`second`. This is an
|
||||
obect-identity-equality test, not an object equality
|
||||
(i.e. :py:func:`__eq__`) test.
|
||||
|
||||
:param msg: if msg is None, then the failure message will be
|
||||
'%r is %r' % (first, second)
|
||||
"""
|
||||
if first is second:
|
||||
raise self.failureException(msg or '%r is %r' % (first, second))
|
||||
return first
|
||||
assertNotIdentical = failIfIdentical
|
||||
|
||||
|
||||
def failUnlessRaises(self, exception, f, *args, **kwargs):
|
||||
"""
|
||||
Fail the test unless calling the function :py:data:`f` with the given
|
||||
:py:data:`args` and :py:data:`kwargs` raises :py:data:`exception`. The
|
||||
failure will report the traceback and call stack of the unexpected
|
||||
exception.
|
||||
|
||||
:param exception: exception type that is to be expected
|
||||
:param f: the function to call
|
||||
|
||||
:return: The raised exception instance, if it is of the given type.
|
||||
:raise self.failureException: Raised if the function call does
|
||||
not raise an exception or if it raises an exception of a
|
||||
different type.
|
||||
"""
|
||||
try:
|
||||
result = f(*args, **kwargs)
|
||||
except exception:
|
||||
inst = sys.exc_info()[1]
|
||||
return inst
|
||||
except:
|
||||
raise self.failureException('%s raised instead of %s'
|
||||
% (sys.exc_info()[0],
|
||||
exception.__name__,
|
||||
))
|
||||
else:
|
||||
raise self.failureException('%s not raised (%r returned)'
|
||||
% (exception.__name__, result))
|
||||
assertRaises = failUnlessRaises
|
||||
|
||||
|
||||
_temporaryFiles = None
|
||||
def mktemp(self):
|
||||
"""
|
||||
Pathetic substitute for twisted.trial.unittest.TestCase.mktemp.
|
||||
"""
|
||||
if self._temporaryFiles is None:
|
||||
self._temporaryFiles = []
|
||||
temp = b(mktemp(dir="."))
|
||||
self._temporaryFiles.append(temp)
|
||||
return temp
|
||||
|
||||
|
||||
# Other stuff
|
||||
def assertConsistentType(self, theType, name, *constructionArgs):
|
||||
"""
|
||||
Perform various assertions about :py:data:`theType` to ensure that it is a
|
||||
well-defined type. This is useful for extension types, where it's
|
||||
pretty easy to do something wacky. If something about the type is
|
||||
unusual, an exception will be raised.
|
||||
|
||||
:param theType: The type object about which to make assertions.
|
||||
:param name: A string giving the name of the type.
|
||||
:param constructionArgs: Positional arguments to use with :py:data:`theType` to
|
||||
create an instance of it.
|
||||
"""
|
||||
self.assertEqual(theType.__name__, name)
|
||||
self.assertTrue(isinstance(theType, type))
|
||||
instance = theType(*constructionArgs)
|
||||
self.assertIdentical(type(instance), theType)
|
||||
28
Linux_i686/lib/python2.7/site-packages/OpenSSL/tsafe.py
Normal file
28
Linux_i686/lib/python2.7/site-packages/OpenSSL/tsafe.py
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
from OpenSSL import SSL
|
||||
_ssl = SSL
|
||||
del SSL
|
||||
|
||||
import threading
|
||||
_RLock = threading.RLock
|
||||
del threading
|
||||
|
||||
class Connection:
|
||||
def __init__(self, *args):
|
||||
self._ssl_conn = apply(_ssl.Connection, args)
|
||||
self._lock = _RLock()
|
||||
|
||||
for f in ('get_context', 'pending', 'send', 'write', 'recv', 'read',
|
||||
'renegotiate', 'bind', 'listen', 'connect', 'accept',
|
||||
'setblocking', 'fileno', 'shutdown', 'close', 'get_cipher_list',
|
||||
'getpeername', 'getsockname', 'getsockopt', 'setsockopt',
|
||||
'makefile', 'get_app_data', 'set_app_data', 'state_string',
|
||||
'sock_shutdown', 'get_peer_certificate', 'get_peer_cert_chain', 'want_read',
|
||||
'want_write', 'set_connect_state', 'set_accept_state',
|
||||
'connect_ex', 'sendall'):
|
||||
exec("""def %s(self, *args):
|
||||
self._lock.acquire()
|
||||
try:
|
||||
return self._ssl_conn.%s(*args)
|
||||
finally:
|
||||
self._lock.release()\n""" % (f, f))
|
||||
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
# Copyright (C) AB Strakt
|
||||
# Copyright (C) Jean-Paul Calderone
|
||||
# See LICENSE for details.
|
||||
|
||||
"""
|
||||
pyOpenSSL - A simple wrapper around the OpenSSL library
|
||||
"""
|
||||
|
||||
__version__ = '0.14'
|
||||
|
|
@ -0,0 +1,155 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: SQLAlchemy
|
||||
Version: 0.9.4
|
||||
Summary: Database Abstraction Library
|
||||
Home-page: http://www.sqlalchemy.org
|
||||
Author: Mike Bayer
|
||||
Author-email: mike_mp@zzzcomputing.com
|
||||
License: MIT License
|
||||
Description: SQLAlchemy
|
||||
==========
|
||||
|
||||
The Python SQL Toolkit and Object Relational Mapper
|
||||
|
||||
Introduction
|
||||
-------------
|
||||
|
||||
SQLAlchemy is the Python SQL toolkit and Object Relational Mapper
|
||||
that gives application developers the full power and
|
||||
flexibility of SQL. SQLAlchemy provides a full suite
|
||||
of well known enterprise-level persistence patterns,
|
||||
designed for efficient and high-performing database
|
||||
access, adapted into a simple and Pythonic domain
|
||||
language.
|
||||
|
||||
Major SQLAlchemy features include:
|
||||
|
||||
* An industrial strength ORM, built
|
||||
from the core on the identity map, unit of work,
|
||||
and data mapper patterns. These patterns
|
||||
allow transparent persistence of objects
|
||||
using a declarative configuration system.
|
||||
Domain models
|
||||
can be constructed and manipulated naturally,
|
||||
and changes are synchronized with the
|
||||
current transaction automatically.
|
||||
* A relationally-oriented query system, exposing
|
||||
the full range of SQL's capabilities
|
||||
explicitly, including joins, subqueries,
|
||||
correlation, and most everything else,
|
||||
in terms of the object model.
|
||||
Writing queries with the ORM uses the same
|
||||
techniques of relational composition you use
|
||||
when writing SQL. While you can drop into
|
||||
literal SQL at any time, it's virtually never
|
||||
needed.
|
||||
* A comprehensive and flexible system
|
||||
of eager loading for related collections and objects.
|
||||
Collections are cached within a session,
|
||||
and can be loaded on individual access, all
|
||||
at once using joins, or by query per collection
|
||||
across the full result set.
|
||||
* A Core SQL construction system and DBAPI
|
||||
interaction layer. The SQLAlchemy Core is
|
||||
separate from the ORM and is a full database
|
||||
abstraction layer in its own right, and includes
|
||||
an extensible Python-based SQL expression
|
||||
language, schema metadata, connection pooling,
|
||||
type coercion, and custom types.
|
||||
* All primary and foreign key constraints are
|
||||
assumed to be composite and natural. Surrogate
|
||||
integer primary keys are of course still the
|
||||
norm, but SQLAlchemy never assumes or hardcodes
|
||||
to this model.
|
||||
* Database introspection and generation. Database
|
||||
schemas can be "reflected" in one step into
|
||||
Python structures representing database metadata;
|
||||
those same structures can then generate
|
||||
CREATE statements right back out - all within
|
||||
the Core, independent of the ORM.
|
||||
|
||||
SQLAlchemy's philosophy:
|
||||
|
||||
* SQL databases behave less and less like object
|
||||
collections the more size and performance start to
|
||||
matter; object collections behave less and less like
|
||||
tables and rows the more abstraction starts to matter.
|
||||
SQLAlchemy aims to accommodate both of these
|
||||
principles.
|
||||
* An ORM doesn't need to hide the "R". A relational
|
||||
database provides rich, set-based functionality
|
||||
that should be fully exposed. SQLAlchemy's
|
||||
ORM provides an open-ended set of patterns
|
||||
that allow a developer to construct a custom
|
||||
mediation layer between a domain model and
|
||||
a relational schema, turning the so-called
|
||||
"object relational impedance" issue into
|
||||
a distant memory.
|
||||
* The developer, in all cases, makes all decisions
|
||||
regarding the design, structure, and naming conventions
|
||||
of both the object model as well as the relational
|
||||
schema. SQLAlchemy only provides the means
|
||||
to automate the execution of these decisions.
|
||||
* With SQLAlchemy, there's no such thing as
|
||||
"the ORM generated a bad query" - you
|
||||
retain full control over the structure of
|
||||
queries, including how joins are organized,
|
||||
how subqueries and correlation is used, what
|
||||
columns are requested. Everything SQLAlchemy
|
||||
does is ultimately the result of a developer-
|
||||
initiated decision.
|
||||
* Don't use an ORM if the problem doesn't need one.
|
||||
SQLAlchemy consists of a Core and separate ORM
|
||||
component. The Core offers a full SQL expression
|
||||
language that allows Pythonic construction
|
||||
of SQL constructs that render directly to SQL
|
||||
strings for a target database, returning
|
||||
result sets that are essentially enhanced DBAPI
|
||||
cursors.
|
||||
* Transactions should be the norm. With SQLAlchemy's
|
||||
ORM, nothing goes to permanent storage until
|
||||
commit() is called. SQLAlchemy encourages applications
|
||||
to create a consistent means of delineating
|
||||
the start and end of a series of operations.
|
||||
* Never render a literal value in a SQL statement.
|
||||
Bound parameters are used to the greatest degree
|
||||
possible, allowing query optimizers to cache
|
||||
query plans effectively and making SQL injection
|
||||
attacks a non-issue.
|
||||
|
||||
Documentation
|
||||
-------------
|
||||
|
||||
Latest documentation is at:
|
||||
|
||||
http://www.sqlalchemy.org/docs/
|
||||
|
||||
Installation / Requirements
|
||||
---------------------------
|
||||
|
||||
Full documentation for installation is at
|
||||
`Installation <http://www.sqlalchemy.org/docs/intro.html#installation>`_.
|
||||
|
||||
Getting Help / Development / Bug reporting
|
||||
------------------------------------------
|
||||
|
||||
Please refer to the `SQLAlchemy Community Guide <http://www.sqlalchemy.org/support.html>`_.
|
||||
|
||||
License
|
||||
-------
|
||||
|
||||
SQLAlchemy is distributed under the `MIT license
|
||||
<http://www.opensource.org/licenses/mit-license.php>`_.
|
||||
|
||||
|
||||
Platform: UNKNOWN
|
||||
Classifier: Development Status :: 5 - Production/Stable
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: License :: OSI Approved :: MIT License
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Programming Language :: Python :: Implementation :: CPython
|
||||
Classifier: Programming Language :: Python :: Implementation :: Jython
|
||||
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
||||
Classifier: Topic :: Database :: Front-Ends
|
||||
Classifier: Operating System :: OS Independent
|
||||
|
|
@ -0,0 +1,754 @@
|
|||
AUTHORS
|
||||
CHANGES
|
||||
LICENSE
|
||||
MANIFEST.in
|
||||
README.dialects.rst
|
||||
README.rst
|
||||
README.unittests.rst
|
||||
setup.cfg
|
||||
setup.py
|
||||
sqla_nose.py
|
||||
doc/contents.html
|
||||
doc/copyright.html
|
||||
doc/faq.html
|
||||
doc/genindex.html
|
||||
doc/glossary.html
|
||||
doc/index.html
|
||||
doc/intro.html
|
||||
doc/search.html
|
||||
doc/searchindex.js
|
||||
doc/_images/sqla_arch_small.png
|
||||
doc/_images/sqla_engine_arch.png
|
||||
doc/_modules/index.html
|
||||
doc/_modules/examples/adjacency_list/adjacency_list.html
|
||||
doc/_modules/examples/association/basic_association.html
|
||||
doc/_modules/examples/association/dict_of_sets_with_default.html
|
||||
doc/_modules/examples/association/proxied_association.html
|
||||
doc/_modules/examples/custom_attributes/custom_management.html
|
||||
doc/_modules/examples/custom_attributes/listen_for_events.html
|
||||
doc/_modules/examples/dogpile_caching/advanced.html
|
||||
doc/_modules/examples/dogpile_caching/caching_query.html
|
||||
doc/_modules/examples/dogpile_caching/environment.html
|
||||
doc/_modules/examples/dogpile_caching/fixture_data.html
|
||||
doc/_modules/examples/dogpile_caching/helloworld.html
|
||||
doc/_modules/examples/dogpile_caching/local_session_caching.html
|
||||
doc/_modules/examples/dogpile_caching/model.html
|
||||
doc/_modules/examples/dogpile_caching/relationship_caching.html
|
||||
doc/_modules/examples/dynamic_dict/dynamic_dict.html
|
||||
doc/_modules/examples/elementtree/adjacency_list.html
|
||||
doc/_modules/examples/elementtree/optimized_al.html
|
||||
doc/_modules/examples/elementtree/pickle.html
|
||||
doc/_modules/examples/generic_associations/discriminator_on_association.html
|
||||
doc/_modules/examples/generic_associations/generic_fk.html
|
||||
doc/_modules/examples/generic_associations/table_per_association.html
|
||||
doc/_modules/examples/generic_associations/table_per_related.html
|
||||
doc/_modules/examples/graphs/directed_graph.html
|
||||
doc/_modules/examples/inheritance/concrete.html
|
||||
doc/_modules/examples/inheritance/joined.html
|
||||
doc/_modules/examples/inheritance/single.html
|
||||
doc/_modules/examples/join_conditions/cast.html
|
||||
doc/_modules/examples/join_conditions/threeway.html
|
||||
doc/_modules/examples/large_collection/large_collection.html
|
||||
doc/_modules/examples/nested_sets/nested_sets.html
|
||||
doc/_modules/examples/postgis/postgis.html
|
||||
doc/_modules/examples/sharding/attribute_shard.html
|
||||
doc/_modules/examples/versioned_history/history_meta.html
|
||||
doc/_modules/examples/versioned_history/test_versioning.html
|
||||
doc/_modules/examples/versioned_rows/versioned_map.html
|
||||
doc/_modules/examples/versioned_rows/versioned_rows.html
|
||||
doc/_modules/examples/vertical/dictlike-polymorphic.html
|
||||
doc/_modules/examples/vertical/dictlike.html
|
||||
doc/_sources/contents.txt
|
||||
doc/_sources/copyright.txt
|
||||
doc/_sources/faq.txt
|
||||
doc/_sources/glossary.txt
|
||||
doc/_sources/index.txt
|
||||
doc/_sources/intro.txt
|
||||
doc/_sources/changelog/changelog_01.txt
|
||||
doc/_sources/changelog/changelog_02.txt
|
||||
doc/_sources/changelog/changelog_03.txt
|
||||
doc/_sources/changelog/changelog_04.txt
|
||||
doc/_sources/changelog/changelog_05.txt
|
||||
doc/_sources/changelog/changelog_06.txt
|
||||
doc/_sources/changelog/changelog_07.txt
|
||||
doc/_sources/changelog/changelog_08.txt
|
||||
doc/_sources/changelog/changelog_09.txt
|
||||
doc/_sources/changelog/index.txt
|
||||
doc/_sources/changelog/migration_04.txt
|
||||
doc/_sources/changelog/migration_05.txt
|
||||
doc/_sources/changelog/migration_06.txt
|
||||
doc/_sources/changelog/migration_07.txt
|
||||
doc/_sources/changelog/migration_08.txt
|
||||
doc/_sources/changelog/migration_09.txt
|
||||
doc/_sources/core/compiler.txt
|
||||
doc/_sources/core/connections.txt
|
||||
doc/_sources/core/constraints.txt
|
||||
doc/_sources/core/ddl.txt
|
||||
doc/_sources/core/defaults.txt
|
||||
doc/_sources/core/dml.txt
|
||||
doc/_sources/core/engines.txt
|
||||
doc/_sources/core/event.txt
|
||||
doc/_sources/core/events.txt
|
||||
doc/_sources/core/exceptions.txt
|
||||
doc/_sources/core/expression_api.txt
|
||||
doc/_sources/core/functions.txt
|
||||
doc/_sources/core/index.txt
|
||||
doc/_sources/core/inspection.txt
|
||||
doc/_sources/core/interfaces.txt
|
||||
doc/_sources/core/internals.txt
|
||||
doc/_sources/core/metadata.txt
|
||||
doc/_sources/core/pooling.txt
|
||||
doc/_sources/core/reflection.txt
|
||||
doc/_sources/core/schema.txt
|
||||
doc/_sources/core/selectable.txt
|
||||
doc/_sources/core/serializer.txt
|
||||
doc/_sources/core/sqlelement.txt
|
||||
doc/_sources/core/tutorial.txt
|
||||
doc/_sources/core/types.txt
|
||||
doc/_sources/dialects/drizzle.txt
|
||||
doc/_sources/dialects/firebird.txt
|
||||
doc/_sources/dialects/index.txt
|
||||
doc/_sources/dialects/mssql.txt
|
||||
doc/_sources/dialects/mysql.txt
|
||||
doc/_sources/dialects/oracle.txt
|
||||
doc/_sources/dialects/postgresql.txt
|
||||
doc/_sources/dialects/sqlite.txt
|
||||
doc/_sources/dialects/sybase.txt
|
||||
doc/_sources/orm/collections.txt
|
||||
doc/_sources/orm/deprecated.txt
|
||||
doc/_sources/orm/events.txt
|
||||
doc/_sources/orm/examples.txt
|
||||
doc/_sources/orm/exceptions.txt
|
||||
doc/_sources/orm/index.txt
|
||||
doc/_sources/orm/inheritance.txt
|
||||
doc/_sources/orm/internals.txt
|
||||
doc/_sources/orm/loading.txt
|
||||
doc/_sources/orm/mapper_config.txt
|
||||
doc/_sources/orm/query.txt
|
||||
doc/_sources/orm/relationships.txt
|
||||
doc/_sources/orm/session.txt
|
||||
doc/_sources/orm/tutorial.txt
|
||||
doc/_sources/orm/extensions/associationproxy.txt
|
||||
doc/_sources/orm/extensions/automap.txt
|
||||
doc/_sources/orm/extensions/declarative.txt
|
||||
doc/_sources/orm/extensions/horizontal_shard.txt
|
||||
doc/_sources/orm/extensions/hybrid.txt
|
||||
doc/_sources/orm/extensions/index.txt
|
||||
doc/_sources/orm/extensions/instrumentation.txt
|
||||
doc/_sources/orm/extensions/mutable.txt
|
||||
doc/_sources/orm/extensions/orderinglist.txt
|
||||
doc/_static/basic.css
|
||||
doc/_static/changelog.css
|
||||
doc/_static/comment-bright.png
|
||||
doc/_static/comment-close.png
|
||||
doc/_static/comment.png
|
||||
doc/_static/default.css
|
||||
doc/_static/docs.css
|
||||
doc/_static/doctools.js
|
||||
doc/_static/down-pressed.png
|
||||
doc/_static/down.png
|
||||
doc/_static/file.png
|
||||
doc/_static/init.js
|
||||
doc/_static/jquery.js
|
||||
doc/_static/minus.png
|
||||
doc/_static/plus.png
|
||||
doc/_static/pygments.css
|
||||
doc/_static/searchtools.js
|
||||
doc/_static/sidebar.js
|
||||
doc/_static/sphinx_paramlinks.css
|
||||
doc/_static/underscore.js
|
||||
doc/_static/up-pressed.png
|
||||
doc/_static/up.png
|
||||
doc/_static/websupport.js
|
||||
doc/build/Makefile
|
||||
doc/build/conf.py
|
||||
doc/build/contents.rst
|
||||
doc/build/copyright.rst
|
||||
doc/build/faq.rst
|
||||
doc/build/glossary.rst
|
||||
doc/build/index.rst
|
||||
doc/build/intro.rst
|
||||
doc/build/requirements.txt
|
||||
doc/build/sqla_arch_small.png
|
||||
doc/build/testdocs.py
|
||||
doc/build/builder/__init__.py
|
||||
doc/build/builder/autodoc_mods.py
|
||||
doc/build/builder/dialect_info.py
|
||||
doc/build/builder/mako.py
|
||||
doc/build/builder/sqlformatter.py
|
||||
doc/build/builder/util.py
|
||||
doc/build/builder/viewsource.py
|
||||
doc/build/changelog/changelog_01.rst
|
||||
doc/build/changelog/changelog_02.rst
|
||||
doc/build/changelog/changelog_03.rst
|
||||
doc/build/changelog/changelog_04.rst
|
||||
doc/build/changelog/changelog_05.rst
|
||||
doc/build/changelog/changelog_06.rst
|
||||
doc/build/changelog/changelog_07.rst
|
||||
doc/build/changelog/changelog_08.rst
|
||||
doc/build/changelog/changelog_09.rst
|
||||
doc/build/changelog/index.rst
|
||||
doc/build/changelog/migration_04.rst
|
||||
doc/build/changelog/migration_05.rst
|
||||
doc/build/changelog/migration_06.rst
|
||||
doc/build/changelog/migration_07.rst
|
||||
doc/build/changelog/migration_08.rst
|
||||
doc/build/changelog/migration_09.rst
|
||||
doc/build/core/compiler.rst
|
||||
doc/build/core/connections.rst
|
||||
doc/build/core/constraints.rst
|
||||
doc/build/core/ddl.rst
|
||||
doc/build/core/defaults.rst
|
||||
doc/build/core/dml.rst
|
||||
doc/build/core/engines.rst
|
||||
doc/build/core/event.rst
|
||||
doc/build/core/events.rst
|
||||
doc/build/core/exceptions.rst
|
||||
doc/build/core/expression_api.rst
|
||||
doc/build/core/functions.rst
|
||||
doc/build/core/index.rst
|
||||
doc/build/core/inspection.rst
|
||||
doc/build/core/interfaces.rst
|
||||
doc/build/core/internals.rst
|
||||
doc/build/core/metadata.rst
|
||||
doc/build/core/pooling.rst
|
||||
doc/build/core/reflection.rst
|
||||
doc/build/core/schema.rst
|
||||
doc/build/core/selectable.rst
|
||||
doc/build/core/serializer.rst
|
||||
doc/build/core/sqla_engine_arch.png
|
||||
doc/build/core/sqlelement.rst
|
||||
doc/build/core/tutorial.rst
|
||||
doc/build/core/types.rst
|
||||
doc/build/dialects/drizzle.rst
|
||||
doc/build/dialects/firebird.rst
|
||||
doc/build/dialects/index.rst
|
||||
doc/build/dialects/mssql.rst
|
||||
doc/build/dialects/mysql.rst
|
||||
doc/build/dialects/oracle.rst
|
||||
doc/build/dialects/postgresql.rst
|
||||
doc/build/dialects/sqlite.rst
|
||||
doc/build/dialects/sybase.rst
|
||||
doc/build/orm/collections.rst
|
||||
doc/build/orm/deprecated.rst
|
||||
doc/build/orm/events.rst
|
||||
doc/build/orm/examples.rst
|
||||
doc/build/orm/exceptions.rst
|
||||
doc/build/orm/index.rst
|
||||
doc/build/orm/inheritance.rst
|
||||
doc/build/orm/internals.rst
|
||||
doc/build/orm/loading.rst
|
||||
doc/build/orm/mapper_config.rst
|
||||
doc/build/orm/query.rst
|
||||
doc/build/orm/relationships.rst
|
||||
doc/build/orm/session.rst
|
||||
doc/build/orm/tutorial.rst
|
||||
doc/build/orm/extensions/associationproxy.rst
|
||||
doc/build/orm/extensions/automap.rst
|
||||
doc/build/orm/extensions/declarative.rst
|
||||
doc/build/orm/extensions/horizontal_shard.rst
|
||||
doc/build/orm/extensions/hybrid.rst
|
||||
doc/build/orm/extensions/index.rst
|
||||
doc/build/orm/extensions/instrumentation.rst
|
||||
doc/build/orm/extensions/mutable.rst
|
||||
doc/build/orm/extensions/orderinglist.rst
|
||||
doc/build/static/docs.css
|
||||
doc/build/static/init.js
|
||||
doc/build/templates/genindex.mako
|
||||
doc/build/templates/layout.mako
|
||||
doc/build/templates/page.mako
|
||||
doc/build/templates/search.mako
|
||||
doc/build/templates/static_base.mako
|
||||
doc/build/texinputs/Makefile
|
||||
doc/build/texinputs/sphinx.sty
|
||||
doc/changelog/changelog_01.html
|
||||
doc/changelog/changelog_02.html
|
||||
doc/changelog/changelog_03.html
|
||||
doc/changelog/changelog_04.html
|
||||
doc/changelog/changelog_05.html
|
||||
doc/changelog/changelog_06.html
|
||||
doc/changelog/changelog_07.html
|
||||
doc/changelog/changelog_08.html
|
||||
doc/changelog/changelog_09.html
|
||||
doc/changelog/index.html
|
||||
doc/changelog/migration_04.html
|
||||
doc/changelog/migration_05.html
|
||||
doc/changelog/migration_06.html
|
||||
doc/changelog/migration_07.html
|
||||
doc/changelog/migration_08.html
|
||||
doc/changelog/migration_09.html
|
||||
doc/core/compiler.html
|
||||
doc/core/connections.html
|
||||
doc/core/constraints.html
|
||||
doc/core/ddl.html
|
||||
doc/core/defaults.html
|
||||
doc/core/dml.html
|
||||
doc/core/engines.html
|
||||
doc/core/event.html
|
||||
doc/core/events.html
|
||||
doc/core/exceptions.html
|
||||
doc/core/expression_api.html
|
||||
doc/core/functions.html
|
||||
doc/core/index.html
|
||||
doc/core/inspection.html
|
||||
doc/core/interfaces.html
|
||||
doc/core/internals.html
|
||||
doc/core/metadata.html
|
||||
doc/core/pooling.html
|
||||
doc/core/reflection.html
|
||||
doc/core/schema.html
|
||||
doc/core/selectable.html
|
||||
doc/core/serializer.html
|
||||
doc/core/sqlelement.html
|
||||
doc/core/tutorial.html
|
||||
doc/core/types.html
|
||||
doc/dialects/drizzle.html
|
||||
doc/dialects/firebird.html
|
||||
doc/dialects/index.html
|
||||
doc/dialects/mssql.html
|
||||
doc/dialects/mysql.html
|
||||
doc/dialects/oracle.html
|
||||
doc/dialects/postgresql.html
|
||||
doc/dialects/sqlite.html
|
||||
doc/dialects/sybase.html
|
||||
doc/orm/collections.html
|
||||
doc/orm/deprecated.html
|
||||
doc/orm/events.html
|
||||
doc/orm/examples.html
|
||||
doc/orm/exceptions.html
|
||||
doc/orm/index.html
|
||||
doc/orm/inheritance.html
|
||||
doc/orm/internals.html
|
||||
doc/orm/loading.html
|
||||
doc/orm/mapper_config.html
|
||||
doc/orm/query.html
|
||||
doc/orm/relationships.html
|
||||
doc/orm/session.html
|
||||
doc/orm/tutorial.html
|
||||
doc/orm/extensions/associationproxy.html
|
||||
doc/orm/extensions/automap.html
|
||||
doc/orm/extensions/declarative.html
|
||||
doc/orm/extensions/horizontal_shard.html
|
||||
doc/orm/extensions/hybrid.html
|
||||
doc/orm/extensions/index.html
|
||||
doc/orm/extensions/instrumentation.html
|
||||
doc/orm/extensions/mutable.html
|
||||
doc/orm/extensions/orderinglist.html
|
||||
examples/__init__.py
|
||||
examples/adjacency_list/__init__.py
|
||||
examples/adjacency_list/adjacency_list.py
|
||||
examples/association/__init__.py
|
||||
examples/association/basic_association.py
|
||||
examples/association/dict_of_sets_with_default.py
|
||||
examples/association/proxied_association.py
|
||||
examples/custom_attributes/__init__.py
|
||||
examples/custom_attributes/custom_management.py
|
||||
examples/custom_attributes/listen_for_events.py
|
||||
examples/dogpile_caching/__init__.py
|
||||
examples/dogpile_caching/advanced.py
|
||||
examples/dogpile_caching/caching_query.py
|
||||
examples/dogpile_caching/environment.py
|
||||
examples/dogpile_caching/fixture_data.py
|
||||
examples/dogpile_caching/helloworld.py
|
||||
examples/dogpile_caching/local_session_caching.py
|
||||
examples/dogpile_caching/model.py
|
||||
examples/dogpile_caching/relationship_caching.py
|
||||
examples/dynamic_dict/__init__.py
|
||||
examples/dynamic_dict/dynamic_dict.py
|
||||
examples/elementtree/__init__.py
|
||||
examples/elementtree/adjacency_list.py
|
||||
examples/elementtree/optimized_al.py
|
||||
examples/elementtree/pickle.py
|
||||
examples/elementtree/test.xml
|
||||
examples/elementtree/test2.xml
|
||||
examples/elementtree/test3.xml
|
||||
examples/generic_associations/__init__.py
|
||||
examples/generic_associations/discriminator_on_association.py
|
||||
examples/generic_associations/generic_fk.py
|
||||
examples/generic_associations/table_per_association.py
|
||||
examples/generic_associations/table_per_related.py
|
||||
examples/graphs/__init__.py
|
||||
examples/graphs/directed_graph.py
|
||||
examples/inheritance/__init__.py
|
||||
examples/inheritance/concrete.py
|
||||
examples/inheritance/joined.py
|
||||
examples/inheritance/single.py
|
||||
examples/join_conditions/__init__.py
|
||||
examples/join_conditions/cast.py
|
||||
examples/join_conditions/threeway.py
|
||||
examples/large_collection/__init__.py
|
||||
examples/large_collection/large_collection.py
|
||||
examples/nested_sets/__init__.py
|
||||
examples/nested_sets/nested_sets.py
|
||||
examples/postgis/__init__.py
|
||||
examples/postgis/postgis.py
|
||||
examples/sharding/__init__.py
|
||||
examples/sharding/attribute_shard.py
|
||||
examples/versioned_history/__init__.py
|
||||
examples/versioned_history/history_meta.py
|
||||
examples/versioned_history/test_versioning.py
|
||||
examples/versioned_rows/__init__.py
|
||||
examples/versioned_rows/versioned_map.py
|
||||
examples/versioned_rows/versioned_rows.py
|
||||
examples/vertical/__init__.py
|
||||
examples/vertical/dictlike-polymorphic.py
|
||||
examples/vertical/dictlike.py
|
||||
lib/SQLAlchemy.egg-info/PKG-INFO
|
||||
lib/SQLAlchemy.egg-info/SOURCES.txt
|
||||
lib/SQLAlchemy.egg-info/dependency_links.txt
|
||||
lib/SQLAlchemy.egg-info/top_level.txt
|
||||
lib/sqlalchemy/__init__.py
|
||||
lib/sqlalchemy/events.py
|
||||
lib/sqlalchemy/exc.py
|
||||
lib/sqlalchemy/inspection.py
|
||||
lib/sqlalchemy/interfaces.py
|
||||
lib/sqlalchemy/log.py
|
||||
lib/sqlalchemy/pool.py
|
||||
lib/sqlalchemy/processors.py
|
||||
lib/sqlalchemy/schema.py
|
||||
lib/sqlalchemy/types.py
|
||||
lib/sqlalchemy/cextension/processors.c
|
||||
lib/sqlalchemy/cextension/resultproxy.c
|
||||
lib/sqlalchemy/cextension/utils.c
|
||||
lib/sqlalchemy/connectors/__init__.py
|
||||
lib/sqlalchemy/connectors/mxodbc.py
|
||||
lib/sqlalchemy/connectors/mysqldb.py
|
||||
lib/sqlalchemy/connectors/pyodbc.py
|
||||
lib/sqlalchemy/connectors/zxJDBC.py
|
||||
lib/sqlalchemy/databases/__init__.py
|
||||
lib/sqlalchemy/dialects/__init__.py
|
||||
lib/sqlalchemy/dialects/postgres.py
|
||||
lib/sqlalchemy/dialects/type_migration_guidelines.txt
|
||||
lib/sqlalchemy/dialects/drizzle/__init__.py
|
||||
lib/sqlalchemy/dialects/drizzle/base.py
|
||||
lib/sqlalchemy/dialects/drizzle/mysqldb.py
|
||||
lib/sqlalchemy/dialects/firebird/__init__.py
|
||||
lib/sqlalchemy/dialects/firebird/base.py
|
||||
lib/sqlalchemy/dialects/firebird/fdb.py
|
||||
lib/sqlalchemy/dialects/firebird/kinterbasdb.py
|
||||
lib/sqlalchemy/dialects/mssql/__init__.py
|
||||
lib/sqlalchemy/dialects/mssql/adodbapi.py
|
||||
lib/sqlalchemy/dialects/mssql/base.py
|
||||
lib/sqlalchemy/dialects/mssql/information_schema.py
|
||||
lib/sqlalchemy/dialects/mssql/mxodbc.py
|
||||
lib/sqlalchemy/dialects/mssql/pymssql.py
|
||||
lib/sqlalchemy/dialects/mssql/pyodbc.py
|
||||
lib/sqlalchemy/dialects/mssql/zxjdbc.py
|
||||
lib/sqlalchemy/dialects/mysql/__init__.py
|
||||
lib/sqlalchemy/dialects/mysql/base.py
|
||||
lib/sqlalchemy/dialects/mysql/cymysql.py
|
||||
lib/sqlalchemy/dialects/mysql/gaerdbms.py
|
||||
lib/sqlalchemy/dialects/mysql/mysqlconnector.py
|
||||
lib/sqlalchemy/dialects/mysql/mysqldb.py
|
||||
lib/sqlalchemy/dialects/mysql/oursql.py
|
||||
lib/sqlalchemy/dialects/mysql/pymysql.py
|
||||
lib/sqlalchemy/dialects/mysql/pyodbc.py
|
||||
lib/sqlalchemy/dialects/mysql/zxjdbc.py
|
||||
lib/sqlalchemy/dialects/oracle/__init__.py
|
||||
lib/sqlalchemy/dialects/oracle/base.py
|
||||
lib/sqlalchemy/dialects/oracle/cx_oracle.py
|
||||
lib/sqlalchemy/dialects/oracle/zxjdbc.py
|
||||
lib/sqlalchemy/dialects/postgresql/__init__.py
|
||||
lib/sqlalchemy/dialects/postgresql/base.py
|
||||
lib/sqlalchemy/dialects/postgresql/constraints.py
|
||||
lib/sqlalchemy/dialects/postgresql/hstore.py
|
||||
lib/sqlalchemy/dialects/postgresql/json.py
|
||||
lib/sqlalchemy/dialects/postgresql/pg8000.py
|
||||
lib/sqlalchemy/dialects/postgresql/psycopg2.py
|
||||
lib/sqlalchemy/dialects/postgresql/pypostgresql.py
|
||||
lib/sqlalchemy/dialects/postgresql/ranges.py
|
||||
lib/sqlalchemy/dialects/postgresql/zxjdbc.py
|
||||
lib/sqlalchemy/dialects/sqlite/__init__.py
|
||||
lib/sqlalchemy/dialects/sqlite/base.py
|
||||
lib/sqlalchemy/dialects/sqlite/pysqlite.py
|
||||
lib/sqlalchemy/dialects/sybase/__init__.py
|
||||
lib/sqlalchemy/dialects/sybase/base.py
|
||||
lib/sqlalchemy/dialects/sybase/mxodbc.py
|
||||
lib/sqlalchemy/dialects/sybase/pyodbc.py
|
||||
lib/sqlalchemy/dialects/sybase/pysybase.py
|
||||
lib/sqlalchemy/engine/__init__.py
|
||||
lib/sqlalchemy/engine/base.py
|
||||
lib/sqlalchemy/engine/default.py
|
||||
lib/sqlalchemy/engine/interfaces.py
|
||||
lib/sqlalchemy/engine/reflection.py
|
||||
lib/sqlalchemy/engine/result.py
|
||||
lib/sqlalchemy/engine/strategies.py
|
||||
lib/sqlalchemy/engine/threadlocal.py
|
||||
lib/sqlalchemy/engine/url.py
|
||||
lib/sqlalchemy/engine/util.py
|
||||
lib/sqlalchemy/event/__init__.py
|
||||
lib/sqlalchemy/event/api.py
|
||||
lib/sqlalchemy/event/attr.py
|
||||
lib/sqlalchemy/event/base.py
|
||||
lib/sqlalchemy/event/legacy.py
|
||||
lib/sqlalchemy/event/registry.py
|
||||
lib/sqlalchemy/ext/__init__.py
|
||||
lib/sqlalchemy/ext/associationproxy.py
|
||||
lib/sqlalchemy/ext/automap.py
|
||||
lib/sqlalchemy/ext/compiler.py
|
||||
lib/sqlalchemy/ext/horizontal_shard.py
|
||||
lib/sqlalchemy/ext/hybrid.py
|
||||
lib/sqlalchemy/ext/instrumentation.py
|
||||
lib/sqlalchemy/ext/mutable.py
|
||||
lib/sqlalchemy/ext/orderinglist.py
|
||||
lib/sqlalchemy/ext/serializer.py
|
||||
lib/sqlalchemy/ext/declarative/__init__.py
|
||||
lib/sqlalchemy/ext/declarative/api.py
|
||||
lib/sqlalchemy/ext/declarative/base.py
|
||||
lib/sqlalchemy/ext/declarative/clsregistry.py
|
||||
lib/sqlalchemy/orm/__init__.py
|
||||
lib/sqlalchemy/orm/attributes.py
|
||||
lib/sqlalchemy/orm/base.py
|
||||
lib/sqlalchemy/orm/collections.py
|
||||
lib/sqlalchemy/orm/dependency.py
|
||||
lib/sqlalchemy/orm/deprecated_interfaces.py
|
||||
lib/sqlalchemy/orm/descriptor_props.py
|
||||
lib/sqlalchemy/orm/dynamic.py
|
||||
lib/sqlalchemy/orm/evaluator.py
|
||||
lib/sqlalchemy/orm/events.py
|
||||
lib/sqlalchemy/orm/exc.py
|
||||
lib/sqlalchemy/orm/identity.py
|
||||
lib/sqlalchemy/orm/instrumentation.py
|
||||
lib/sqlalchemy/orm/interfaces.py
|
||||
lib/sqlalchemy/orm/loading.py
|
||||
lib/sqlalchemy/orm/mapper.py
|
||||
lib/sqlalchemy/orm/path_registry.py
|
||||
lib/sqlalchemy/orm/persistence.py
|
||||
lib/sqlalchemy/orm/properties.py
|
||||
lib/sqlalchemy/orm/query.py
|
||||
lib/sqlalchemy/orm/relationships.py
|
||||
lib/sqlalchemy/orm/scoping.py
|
||||
lib/sqlalchemy/orm/session.py
|
||||
lib/sqlalchemy/orm/state.py
|
||||
lib/sqlalchemy/orm/strategies.py
|
||||
lib/sqlalchemy/orm/strategy_options.py
|
||||
lib/sqlalchemy/orm/sync.py
|
||||
lib/sqlalchemy/orm/unitofwork.py
|
||||
lib/sqlalchemy/orm/util.py
|
||||
lib/sqlalchemy/sql/__init__.py
|
||||
lib/sqlalchemy/sql/annotation.py
|
||||
lib/sqlalchemy/sql/base.py
|
||||
lib/sqlalchemy/sql/compiler.py
|
||||
lib/sqlalchemy/sql/ddl.py
|
||||
lib/sqlalchemy/sql/default_comparator.py
|
||||
lib/sqlalchemy/sql/dml.py
|
||||
lib/sqlalchemy/sql/elements.py
|
||||
lib/sqlalchemy/sql/expression.py
|
||||
lib/sqlalchemy/sql/functions.py
|
||||
lib/sqlalchemy/sql/naming.py
|
||||
lib/sqlalchemy/sql/operators.py
|
||||
lib/sqlalchemy/sql/schema.py
|
||||
lib/sqlalchemy/sql/selectable.py
|
||||
lib/sqlalchemy/sql/sqltypes.py
|
||||
lib/sqlalchemy/sql/type_api.py
|
||||
lib/sqlalchemy/sql/util.py
|
||||
lib/sqlalchemy/sql/visitors.py
|
||||
lib/sqlalchemy/testing/__init__.py
|
||||
lib/sqlalchemy/testing/assertions.py
|
||||
lib/sqlalchemy/testing/assertsql.py
|
||||
lib/sqlalchemy/testing/config.py
|
||||
lib/sqlalchemy/testing/engines.py
|
||||
lib/sqlalchemy/testing/entities.py
|
||||
lib/sqlalchemy/testing/exclusions.py
|
||||
lib/sqlalchemy/testing/fixtures.py
|
||||
lib/sqlalchemy/testing/mock.py
|
||||
lib/sqlalchemy/testing/pickleable.py
|
||||
lib/sqlalchemy/testing/profiling.py
|
||||
lib/sqlalchemy/testing/requirements.py
|
||||
lib/sqlalchemy/testing/runner.py
|
||||
lib/sqlalchemy/testing/schema.py
|
||||
lib/sqlalchemy/testing/util.py
|
||||
lib/sqlalchemy/testing/warnings.py
|
||||
lib/sqlalchemy/testing/plugin/__init__.py
|
||||
lib/sqlalchemy/testing/plugin/noseplugin.py
|
||||
lib/sqlalchemy/testing/plugin/plugin_base.py
|
||||
lib/sqlalchemy/testing/plugin/pytestplugin.py
|
||||
lib/sqlalchemy/testing/suite/__init__.py
|
||||
lib/sqlalchemy/testing/suite/test_ddl.py
|
||||
lib/sqlalchemy/testing/suite/test_insert.py
|
||||
lib/sqlalchemy/testing/suite/test_reflection.py
|
||||
lib/sqlalchemy/testing/suite/test_results.py
|
||||
lib/sqlalchemy/testing/suite/test_select.py
|
||||
lib/sqlalchemy/testing/suite/test_sequence.py
|
||||
lib/sqlalchemy/testing/suite/test_types.py
|
||||
lib/sqlalchemy/testing/suite/test_update_delete.py
|
||||
lib/sqlalchemy/util/__init__.py
|
||||
lib/sqlalchemy/util/_collections.py
|
||||
lib/sqlalchemy/util/compat.py
|
||||
lib/sqlalchemy/util/deprecations.py
|
||||
lib/sqlalchemy/util/langhelpers.py
|
||||
lib/sqlalchemy/util/queue.py
|
||||
lib/sqlalchemy/util/topological.py
|
||||
test/__init__.py
|
||||
test/binary_data_one.dat
|
||||
test/binary_data_two.dat
|
||||
test/conftest.py
|
||||
test/requirements.py
|
||||
test/aaa_profiling/__init__.py
|
||||
test/aaa_profiling/test_compiler.py
|
||||
test/aaa_profiling/test_memusage.py
|
||||
test/aaa_profiling/test_orm.py
|
||||
test/aaa_profiling/test_pool.py
|
||||
test/aaa_profiling/test_resultset.py
|
||||
test/aaa_profiling/test_zoomark.py
|
||||
test/aaa_profiling/test_zoomark_orm.py
|
||||
test/base/__init__.py
|
||||
test/base/test_dependency.py
|
||||
test/base/test_events.py
|
||||
test/base/test_except.py
|
||||
test/base/test_inspect.py
|
||||
test/base/test_utils.py
|
||||
test/dialect/__init__.py
|
||||
test/dialect/test_firebird.py
|
||||
test/dialect/test_mxodbc.py
|
||||
test/dialect/test_oracle.py
|
||||
test/dialect/test_pyodbc.py
|
||||
test/dialect/test_sqlite.py
|
||||
test/dialect/test_suite.py
|
||||
test/dialect/test_sybase.py
|
||||
test/dialect/mssql/__init__.py
|
||||
test/dialect/mssql/test_compiler.py
|
||||
test/dialect/mssql/test_engine.py
|
||||
test/dialect/mssql/test_query.py
|
||||
test/dialect/mssql/test_reflection.py
|
||||
test/dialect/mssql/test_types.py
|
||||
test/dialect/mysql/__init__.py
|
||||
test/dialect/mysql/test_compiler.py
|
||||
test/dialect/mysql/test_dialect.py
|
||||
test/dialect/mysql/test_query.py
|
||||
test/dialect/mysql/test_reflection.py
|
||||
test/dialect/mysql/test_types.py
|
||||
test/dialect/postgresql/__init__.py
|
||||
test/dialect/postgresql/test_compiler.py
|
||||
test/dialect/postgresql/test_dialect.py
|
||||
test/dialect/postgresql/test_query.py
|
||||
test/dialect/postgresql/test_reflection.py
|
||||
test/dialect/postgresql/test_types.py
|
||||
test/engine/__init__.py
|
||||
test/engine/test_bind.py
|
||||
test/engine/test_ddlevents.py
|
||||
test/engine/test_execute.py
|
||||
test/engine/test_logging.py
|
||||
test/engine/test_parseconnect.py
|
||||
test/engine/test_pool.py
|
||||
test/engine/test_processors.py
|
||||
test/engine/test_reconnect.py
|
||||
test/engine/test_reflection.py
|
||||
test/engine/test_transaction.py
|
||||
test/ext/__init__.py
|
||||
test/ext/test_associationproxy.py
|
||||
test/ext/test_automap.py
|
||||
test/ext/test_compiler.py
|
||||
test/ext/test_extendedattr.py
|
||||
test/ext/test_horizontal_shard.py
|
||||
test/ext/test_hybrid.py
|
||||
test/ext/test_mutable.py
|
||||
test/ext/test_orderinglist.py
|
||||
test/ext/test_serializer.py
|
||||
test/ext/declarative/__init__.py
|
||||
test/ext/declarative/test_basic.py
|
||||
test/ext/declarative/test_clsregistry.py
|
||||
test/ext/declarative/test_inheritance.py
|
||||
test/ext/declarative/test_mixin.py
|
||||
test/ext/declarative/test_reflection.py
|
||||
test/orm/__init__.py
|
||||
test/orm/_fixtures.py
|
||||
test/orm/test_association.py
|
||||
test/orm/test_assorted_eager.py
|
||||
test/orm/test_attributes.py
|
||||
test/orm/test_backref_mutations.py
|
||||
test/orm/test_bind.py
|
||||
test/orm/test_bundle.py
|
||||
test/orm/test_cascade.py
|
||||
test/orm/test_collection.py
|
||||
test/orm/test_compile.py
|
||||
test/orm/test_composites.py
|
||||
test/orm/test_cycles.py
|
||||
test/orm/test_default_strategies.py
|
||||
test/orm/test_defaults.py
|
||||
test/orm/test_deferred.py
|
||||
test/orm/test_deprecations.py
|
||||
test/orm/test_descriptor.py
|
||||
test/orm/test_dynamic.py
|
||||
test/orm/test_eager_relations.py
|
||||
test/orm/test_evaluator.py
|
||||
test/orm/test_events.py
|
||||
test/orm/test_expire.py
|
||||
test/orm/test_froms.py
|
||||
test/orm/test_generative.py
|
||||
test/orm/test_hasparent.py
|
||||
test/orm/test_immediate_load.py
|
||||
test/orm/test_inspect.py
|
||||
test/orm/test_instrumentation.py
|
||||
test/orm/test_joins.py
|
||||
test/orm/test_lazy_relations.py
|
||||
test/orm/test_load_on_fks.py
|
||||
test/orm/test_loading.py
|
||||
test/orm/test_lockmode.py
|
||||
test/orm/test_manytomany.py
|
||||
test/orm/test_mapper.py
|
||||
test/orm/test_merge.py
|
||||
test/orm/test_naturalpks.py
|
||||
test/orm/test_of_type.py
|
||||
test/orm/test_onetoone.py
|
||||
test/orm/test_options.py
|
||||
test/orm/test_pickled.py
|
||||
test/orm/test_query.py
|
||||
test/orm/test_rel_fn.py
|
||||
test/orm/test_relationships.py
|
||||
test/orm/test_scoping.py
|
||||
test/orm/test_selectable.py
|
||||
test/orm/test_session.py
|
||||
test/orm/test_subquery_relations.py
|
||||
test/orm/test_sync.py
|
||||
test/orm/test_transaction.py
|
||||
test/orm/test_unitofwork.py
|
||||
test/orm/test_unitofworkv2.py
|
||||
test/orm/test_update_delete.py
|
||||
test/orm/test_utils.py
|
||||
test/orm/test_validators.py
|
||||
test/orm/test_versioning.py
|
||||
test/orm/inheritance/__init__.py
|
||||
test/orm/inheritance/_poly_fixtures.py
|
||||
test/orm/inheritance/test_abc_inheritance.py
|
||||
test/orm/inheritance/test_abc_polymorphic.py
|
||||
test/orm/inheritance/test_assorted_poly.py
|
||||
test/orm/inheritance/test_basic.py
|
||||
test/orm/inheritance/test_concrete.py
|
||||
test/orm/inheritance/test_magazine.py
|
||||
test/orm/inheritance/test_manytomany.py
|
||||
test/orm/inheritance/test_poly_linked_list.py
|
||||
test/orm/inheritance/test_poly_persistence.py
|
||||
test/orm/inheritance/test_polymorphic_rel.py
|
||||
test/orm/inheritance/test_productspec.py
|
||||
test/orm/inheritance/test_relationship.py
|
||||
test/orm/inheritance/test_selects.py
|
||||
test/orm/inheritance/test_single.py
|
||||
test/orm/inheritance/test_with_poly.py
|
||||
test/perf/orm2010.py
|
||||
test/sql/__init__.py
|
||||
test/sql/test_case_statement.py
|
||||
test/sql/test_compiler.py
|
||||
test/sql/test_constraints.py
|
||||
test/sql/test_cte.py
|
||||
test/sql/test_ddlemit.py
|
||||
test/sql/test_defaults.py
|
||||
test/sql/test_delete.py
|
||||
test/sql/test_functions.py
|
||||
test/sql/test_generative.py
|
||||
test/sql/test_insert.py
|
||||
test/sql/test_inspect.py
|
||||
test/sql/test_join_rewriting.py
|
||||
test/sql/test_labels.py
|
||||
test/sql/test_metadata.py
|
||||
test/sql/test_operators.py
|
||||
test/sql/test_query.py
|
||||
test/sql/test_quote.py
|
||||
test/sql/test_returning.py
|
||||
test/sql/test_rowcount.py
|
||||
test/sql/test_selectable.py
|
||||
test/sql/test_text.py
|
||||
test/sql/test_type_expressions.py
|
||||
test/sql/test_types.py
|
||||
test/sql/test_unicode.py
|
||||
test/sql/test_update.py
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,364 @@
|
|||
../sqlalchemy/log.py
|
||||
../sqlalchemy/inspection.py
|
||||
../sqlalchemy/interfaces.py
|
||||
../sqlalchemy/types.py
|
||||
../sqlalchemy/pool.py
|
||||
../sqlalchemy/__init__.py
|
||||
../sqlalchemy/schema.py
|
||||
../sqlalchemy/exc.py
|
||||
../sqlalchemy/events.py
|
||||
../sqlalchemy/processors.py
|
||||
../sqlalchemy/util/compat.py
|
||||
../sqlalchemy/util/deprecations.py
|
||||
../sqlalchemy/util/_collections.py
|
||||
../sqlalchemy/util/topological.py
|
||||
../sqlalchemy/util/queue.py
|
||||
../sqlalchemy/util/__init__.py
|
||||
../sqlalchemy/util/langhelpers.py
|
||||
../sqlalchemy/ext/horizontal_shard.py
|
||||
../sqlalchemy/ext/serializer.py
|
||||
../sqlalchemy/ext/automap.py
|
||||
../sqlalchemy/ext/associationproxy.py
|
||||
../sqlalchemy/ext/__init__.py
|
||||
../sqlalchemy/ext/hybrid.py
|
||||
../sqlalchemy/ext/mutable.py
|
||||
../sqlalchemy/ext/orderinglist.py
|
||||
../sqlalchemy/ext/compiler.py
|
||||
../sqlalchemy/ext/instrumentation.py
|
||||
../sqlalchemy/ext/declarative/api.py
|
||||
../sqlalchemy/ext/declarative/__init__.py
|
||||
../sqlalchemy/ext/declarative/base.py
|
||||
../sqlalchemy/ext/declarative/clsregistry.py
|
||||
../sqlalchemy/event/api.py
|
||||
../sqlalchemy/event/registry.py
|
||||
../sqlalchemy/event/__init__.py
|
||||
../sqlalchemy/event/legacy.py
|
||||
../sqlalchemy/event/base.py
|
||||
../sqlalchemy/event/attr.py
|
||||
../sqlalchemy/sql/type_api.py
|
||||
../sqlalchemy/sql/ddl.py
|
||||
../sqlalchemy/sql/selectable.py
|
||||
../sqlalchemy/sql/util.py
|
||||
../sqlalchemy/sql/sqltypes.py
|
||||
../sqlalchemy/sql/functions.py
|
||||
../sqlalchemy/sql/operators.py
|
||||
../sqlalchemy/sql/dml.py
|
||||
../sqlalchemy/sql/naming.py
|
||||
../sqlalchemy/sql/expression.py
|
||||
../sqlalchemy/sql/__init__.py
|
||||
../sqlalchemy/sql/schema.py
|
||||
../sqlalchemy/sql/base.py
|
||||
../sqlalchemy/sql/default_comparator.py
|
||||
../sqlalchemy/sql/visitors.py
|
||||
../sqlalchemy/sql/compiler.py
|
||||
../sqlalchemy/sql/elements.py
|
||||
../sqlalchemy/sql/annotation.py
|
||||
../sqlalchemy/engine/default.py
|
||||
../sqlalchemy/engine/url.py
|
||||
../sqlalchemy/engine/util.py
|
||||
../sqlalchemy/engine/interfaces.py
|
||||
../sqlalchemy/engine/result.py
|
||||
../sqlalchemy/engine/__init__.py
|
||||
../sqlalchemy/engine/base.py
|
||||
../sqlalchemy/engine/threadlocal.py
|
||||
../sqlalchemy/engine/reflection.py
|
||||
../sqlalchemy/engine/strategies.py
|
||||
../sqlalchemy/dialects/postgres.py
|
||||
../sqlalchemy/dialects/__init__.py
|
||||
../sqlalchemy/dialects/mysql/mysqlconnector.py
|
||||
../sqlalchemy/dialects/mysql/pymysql.py
|
||||
../sqlalchemy/dialects/mysql/cymysql.py
|
||||
../sqlalchemy/dialects/mysql/oursql.py
|
||||
../sqlalchemy/dialects/mysql/pyodbc.py
|
||||
../sqlalchemy/dialects/mysql/__init__.py
|
||||
../sqlalchemy/dialects/mysql/zxjdbc.py
|
||||
../sqlalchemy/dialects/mysql/base.py
|
||||
../sqlalchemy/dialects/mysql/gaerdbms.py
|
||||
../sqlalchemy/dialects/mysql/mysqldb.py
|
||||
../sqlalchemy/dialects/postgresql/pg8000.py
|
||||
../sqlalchemy/dialects/postgresql/hstore.py
|
||||
../sqlalchemy/dialects/postgresql/pypostgresql.py
|
||||
../sqlalchemy/dialects/postgresql/psycopg2.py
|
||||
../sqlalchemy/dialects/postgresql/ranges.py
|
||||
../sqlalchemy/dialects/postgresql/json.py
|
||||
../sqlalchemy/dialects/postgresql/__init__.py
|
||||
../sqlalchemy/dialects/postgresql/zxjdbc.py
|
||||
../sqlalchemy/dialects/postgresql/base.py
|
||||
../sqlalchemy/dialects/postgresql/constraints.py
|
||||
../sqlalchemy/dialects/sybase/pyodbc.py
|
||||
../sqlalchemy/dialects/sybase/__init__.py
|
||||
../sqlalchemy/dialects/sybase/base.py
|
||||
../sqlalchemy/dialects/sybase/mxodbc.py
|
||||
../sqlalchemy/dialects/sybase/pysybase.py
|
||||
../sqlalchemy/dialects/firebird/fdb.py
|
||||
../sqlalchemy/dialects/firebird/__init__.py
|
||||
../sqlalchemy/dialects/firebird/kinterbasdb.py
|
||||
../sqlalchemy/dialects/firebird/base.py
|
||||
../sqlalchemy/dialects/sqlite/pysqlite.py
|
||||
../sqlalchemy/dialects/sqlite/__init__.py
|
||||
../sqlalchemy/dialects/sqlite/base.py
|
||||
../sqlalchemy/dialects/mssql/information_schema.py
|
||||
../sqlalchemy/dialects/mssql/pymssql.py
|
||||
../sqlalchemy/dialects/mssql/adodbapi.py
|
||||
../sqlalchemy/dialects/mssql/pyodbc.py
|
||||
../sqlalchemy/dialects/mssql/__init__.py
|
||||
../sqlalchemy/dialects/mssql/zxjdbc.py
|
||||
../sqlalchemy/dialects/mssql/base.py
|
||||
../sqlalchemy/dialects/mssql/mxodbc.py
|
||||
../sqlalchemy/dialects/drizzle/__init__.py
|
||||
../sqlalchemy/dialects/drizzle/base.py
|
||||
../sqlalchemy/dialects/drizzle/mysqldb.py
|
||||
../sqlalchemy/dialects/oracle/cx_oracle.py
|
||||
../sqlalchemy/dialects/oracle/__init__.py
|
||||
../sqlalchemy/dialects/oracle/zxjdbc.py
|
||||
../sqlalchemy/dialects/oracle/base.py
|
||||
../sqlalchemy/testing/profiling.py
|
||||
../sqlalchemy/testing/warnings.py
|
||||
../sqlalchemy/testing/engines.py
|
||||
../sqlalchemy/testing/util.py
|
||||
../sqlalchemy/testing/entities.py
|
||||
../sqlalchemy/testing/mock.py
|
||||
../sqlalchemy/testing/exclusions.py
|
||||
../sqlalchemy/testing/assertions.py
|
||||
../sqlalchemy/testing/fixtures.py
|
||||
../sqlalchemy/testing/pickleable.py
|
||||
../sqlalchemy/testing/__init__.py
|
||||
../sqlalchemy/testing/schema.py
|
||||
../sqlalchemy/testing/runner.py
|
||||
../sqlalchemy/testing/config.py
|
||||
../sqlalchemy/testing/requirements.py
|
||||
../sqlalchemy/testing/assertsql.py
|
||||
../sqlalchemy/testing/plugin/pytestplugin.py
|
||||
../sqlalchemy/testing/plugin/plugin_base.py
|
||||
../sqlalchemy/testing/plugin/noseplugin.py
|
||||
../sqlalchemy/testing/plugin/__init__.py
|
||||
../sqlalchemy/testing/suite/test_types.py
|
||||
../sqlalchemy/testing/suite/test_select.py
|
||||
../sqlalchemy/testing/suite/test_ddl.py
|
||||
../sqlalchemy/testing/suite/test_reflection.py
|
||||
../sqlalchemy/testing/suite/test_sequence.py
|
||||
../sqlalchemy/testing/suite/__init__.py
|
||||
../sqlalchemy/testing/suite/test_results.py
|
||||
../sqlalchemy/testing/suite/test_insert.py
|
||||
../sqlalchemy/testing/suite/test_update_delete.py
|
||||
../sqlalchemy/orm/state.py
|
||||
../sqlalchemy/orm/session.py
|
||||
../sqlalchemy/orm/unitofwork.py
|
||||
../sqlalchemy/orm/properties.py
|
||||
../sqlalchemy/orm/collections.py
|
||||
../sqlalchemy/orm/identity.py
|
||||
../sqlalchemy/orm/util.py
|
||||
../sqlalchemy/orm/sync.py
|
||||
../sqlalchemy/orm/interfaces.py
|
||||
../sqlalchemy/orm/path_registry.py
|
||||
../sqlalchemy/orm/evaluator.py
|
||||
../sqlalchemy/orm/deprecated_interfaces.py
|
||||
../sqlalchemy/orm/mapper.py
|
||||
../sqlalchemy/orm/persistence.py
|
||||
../sqlalchemy/orm/dynamic.py
|
||||
../sqlalchemy/orm/__init__.py
|
||||
../sqlalchemy/orm/scoping.py
|
||||
../sqlalchemy/orm/descriptor_props.py
|
||||
../sqlalchemy/orm/loading.py
|
||||
../sqlalchemy/orm/base.py
|
||||
../sqlalchemy/orm/exc.py
|
||||
../sqlalchemy/orm/events.py
|
||||
../sqlalchemy/orm/strategies.py
|
||||
../sqlalchemy/orm/query.py
|
||||
../sqlalchemy/orm/dependency.py
|
||||
../sqlalchemy/orm/attributes.py
|
||||
../sqlalchemy/orm/relationships.py
|
||||
../sqlalchemy/orm/strategy_options.py
|
||||
../sqlalchemy/orm/instrumentation.py
|
||||
../sqlalchemy/connectors/pyodbc.py
|
||||
../sqlalchemy/connectors/__init__.py
|
||||
../sqlalchemy/connectors/zxJDBC.py
|
||||
../sqlalchemy/connectors/mysqldb.py
|
||||
../sqlalchemy/connectors/mxodbc.py
|
||||
../sqlalchemy/databases/__init__.py
|
||||
../sqlalchemy/log.pyc
|
||||
../sqlalchemy/inspection.pyc
|
||||
../sqlalchemy/interfaces.pyc
|
||||
../sqlalchemy/types.pyc
|
||||
../sqlalchemy/pool.pyc
|
||||
../sqlalchemy/__init__.pyc
|
||||
../sqlalchemy/schema.pyc
|
||||
../sqlalchemy/exc.pyc
|
||||
../sqlalchemy/events.pyc
|
||||
../sqlalchemy/processors.pyc
|
||||
../sqlalchemy/util/compat.pyc
|
||||
../sqlalchemy/util/deprecations.pyc
|
||||
../sqlalchemy/util/_collections.pyc
|
||||
../sqlalchemy/util/topological.pyc
|
||||
../sqlalchemy/util/queue.pyc
|
||||
../sqlalchemy/util/__init__.pyc
|
||||
../sqlalchemy/util/langhelpers.pyc
|
||||
../sqlalchemy/ext/horizontal_shard.pyc
|
||||
../sqlalchemy/ext/serializer.pyc
|
||||
../sqlalchemy/ext/automap.pyc
|
||||
../sqlalchemy/ext/associationproxy.pyc
|
||||
../sqlalchemy/ext/__init__.pyc
|
||||
../sqlalchemy/ext/hybrid.pyc
|
||||
../sqlalchemy/ext/mutable.pyc
|
||||
../sqlalchemy/ext/orderinglist.pyc
|
||||
../sqlalchemy/ext/compiler.pyc
|
||||
../sqlalchemy/ext/instrumentation.pyc
|
||||
../sqlalchemy/ext/declarative/api.pyc
|
||||
../sqlalchemy/ext/declarative/__init__.pyc
|
||||
../sqlalchemy/ext/declarative/base.pyc
|
||||
../sqlalchemy/ext/declarative/clsregistry.pyc
|
||||
../sqlalchemy/event/api.pyc
|
||||
../sqlalchemy/event/registry.pyc
|
||||
../sqlalchemy/event/__init__.pyc
|
||||
../sqlalchemy/event/legacy.pyc
|
||||
../sqlalchemy/event/base.pyc
|
||||
../sqlalchemy/event/attr.pyc
|
||||
../sqlalchemy/sql/type_api.pyc
|
||||
../sqlalchemy/sql/ddl.pyc
|
||||
../sqlalchemy/sql/selectable.pyc
|
||||
../sqlalchemy/sql/util.pyc
|
||||
../sqlalchemy/sql/sqltypes.pyc
|
||||
../sqlalchemy/sql/functions.pyc
|
||||
../sqlalchemy/sql/operators.pyc
|
||||
../sqlalchemy/sql/dml.pyc
|
||||
../sqlalchemy/sql/naming.pyc
|
||||
../sqlalchemy/sql/expression.pyc
|
||||
../sqlalchemy/sql/__init__.pyc
|
||||
../sqlalchemy/sql/schema.pyc
|
||||
../sqlalchemy/sql/base.pyc
|
||||
../sqlalchemy/sql/default_comparator.pyc
|
||||
../sqlalchemy/sql/visitors.pyc
|
||||
../sqlalchemy/sql/compiler.pyc
|
||||
../sqlalchemy/sql/elements.pyc
|
||||
../sqlalchemy/sql/annotation.pyc
|
||||
../sqlalchemy/engine/default.pyc
|
||||
../sqlalchemy/engine/url.pyc
|
||||
../sqlalchemy/engine/util.pyc
|
||||
../sqlalchemy/engine/interfaces.pyc
|
||||
../sqlalchemy/engine/result.pyc
|
||||
../sqlalchemy/engine/__init__.pyc
|
||||
../sqlalchemy/engine/base.pyc
|
||||
../sqlalchemy/engine/threadlocal.pyc
|
||||
../sqlalchemy/engine/reflection.pyc
|
||||
../sqlalchemy/engine/strategies.pyc
|
||||
../sqlalchemy/dialects/postgres.pyc
|
||||
../sqlalchemy/dialects/__init__.pyc
|
||||
../sqlalchemy/dialects/mysql/mysqlconnector.pyc
|
||||
../sqlalchemy/dialects/mysql/pymysql.pyc
|
||||
../sqlalchemy/dialects/mysql/cymysql.pyc
|
||||
../sqlalchemy/dialects/mysql/oursql.pyc
|
||||
../sqlalchemy/dialects/mysql/pyodbc.pyc
|
||||
../sqlalchemy/dialects/mysql/__init__.pyc
|
||||
../sqlalchemy/dialects/mysql/zxjdbc.pyc
|
||||
../sqlalchemy/dialects/mysql/base.pyc
|
||||
../sqlalchemy/dialects/mysql/gaerdbms.pyc
|
||||
../sqlalchemy/dialects/mysql/mysqldb.pyc
|
||||
../sqlalchemy/dialects/postgresql/pg8000.pyc
|
||||
../sqlalchemy/dialects/postgresql/hstore.pyc
|
||||
../sqlalchemy/dialects/postgresql/pypostgresql.pyc
|
||||
../sqlalchemy/dialects/postgresql/psycopg2.pyc
|
||||
../sqlalchemy/dialects/postgresql/ranges.pyc
|
||||
../sqlalchemy/dialects/postgresql/json.pyc
|
||||
../sqlalchemy/dialects/postgresql/__init__.pyc
|
||||
../sqlalchemy/dialects/postgresql/zxjdbc.pyc
|
||||
../sqlalchemy/dialects/postgresql/base.pyc
|
||||
../sqlalchemy/dialects/postgresql/constraints.pyc
|
||||
../sqlalchemy/dialects/sybase/pyodbc.pyc
|
||||
../sqlalchemy/dialects/sybase/__init__.pyc
|
||||
../sqlalchemy/dialects/sybase/base.pyc
|
||||
../sqlalchemy/dialects/sybase/mxodbc.pyc
|
||||
../sqlalchemy/dialects/sybase/pysybase.pyc
|
||||
../sqlalchemy/dialects/firebird/fdb.pyc
|
||||
../sqlalchemy/dialects/firebird/__init__.pyc
|
||||
../sqlalchemy/dialects/firebird/kinterbasdb.pyc
|
||||
../sqlalchemy/dialects/firebird/base.pyc
|
||||
../sqlalchemy/dialects/sqlite/pysqlite.pyc
|
||||
../sqlalchemy/dialects/sqlite/__init__.pyc
|
||||
../sqlalchemy/dialects/sqlite/base.pyc
|
||||
../sqlalchemy/dialects/mssql/information_schema.pyc
|
||||
../sqlalchemy/dialects/mssql/pymssql.pyc
|
||||
../sqlalchemy/dialects/mssql/adodbapi.pyc
|
||||
../sqlalchemy/dialects/mssql/pyodbc.pyc
|
||||
../sqlalchemy/dialects/mssql/__init__.pyc
|
||||
../sqlalchemy/dialects/mssql/zxjdbc.pyc
|
||||
../sqlalchemy/dialects/mssql/base.pyc
|
||||
../sqlalchemy/dialects/mssql/mxodbc.pyc
|
||||
../sqlalchemy/dialects/drizzle/__init__.pyc
|
||||
../sqlalchemy/dialects/drizzle/base.pyc
|
||||
../sqlalchemy/dialects/drizzle/mysqldb.pyc
|
||||
../sqlalchemy/dialects/oracle/cx_oracle.pyc
|
||||
../sqlalchemy/dialects/oracle/__init__.pyc
|
||||
../sqlalchemy/dialects/oracle/zxjdbc.pyc
|
||||
../sqlalchemy/dialects/oracle/base.pyc
|
||||
../sqlalchemy/testing/profiling.pyc
|
||||
../sqlalchemy/testing/warnings.pyc
|
||||
../sqlalchemy/testing/engines.pyc
|
||||
../sqlalchemy/testing/util.pyc
|
||||
../sqlalchemy/testing/entities.pyc
|
||||
../sqlalchemy/testing/mock.pyc
|
||||
../sqlalchemy/testing/exclusions.pyc
|
||||
../sqlalchemy/testing/assertions.pyc
|
||||
../sqlalchemy/testing/fixtures.pyc
|
||||
../sqlalchemy/testing/pickleable.pyc
|
||||
../sqlalchemy/testing/__init__.pyc
|
||||
../sqlalchemy/testing/schema.pyc
|
||||
../sqlalchemy/testing/runner.pyc
|
||||
../sqlalchemy/testing/config.pyc
|
||||
../sqlalchemy/testing/requirements.pyc
|
||||
../sqlalchemy/testing/assertsql.pyc
|
||||
../sqlalchemy/testing/plugin/pytestplugin.pyc
|
||||
../sqlalchemy/testing/plugin/plugin_base.pyc
|
||||
../sqlalchemy/testing/plugin/noseplugin.pyc
|
||||
../sqlalchemy/testing/plugin/__init__.pyc
|
||||
../sqlalchemy/testing/suite/test_types.pyc
|
||||
../sqlalchemy/testing/suite/test_select.pyc
|
||||
../sqlalchemy/testing/suite/test_ddl.pyc
|
||||
../sqlalchemy/testing/suite/test_reflection.pyc
|
||||
../sqlalchemy/testing/suite/test_sequence.pyc
|
||||
../sqlalchemy/testing/suite/__init__.pyc
|
||||
../sqlalchemy/testing/suite/test_results.pyc
|
||||
../sqlalchemy/testing/suite/test_insert.pyc
|
||||
../sqlalchemy/testing/suite/test_update_delete.pyc
|
||||
../sqlalchemy/orm/state.pyc
|
||||
../sqlalchemy/orm/session.pyc
|
||||
../sqlalchemy/orm/unitofwork.pyc
|
||||
../sqlalchemy/orm/properties.pyc
|
||||
../sqlalchemy/orm/collections.pyc
|
||||
../sqlalchemy/orm/identity.pyc
|
||||
../sqlalchemy/orm/util.pyc
|
||||
../sqlalchemy/orm/sync.pyc
|
||||
../sqlalchemy/orm/interfaces.pyc
|
||||
../sqlalchemy/orm/path_registry.pyc
|
||||
../sqlalchemy/orm/evaluator.pyc
|
||||
../sqlalchemy/orm/deprecated_interfaces.pyc
|
||||
../sqlalchemy/orm/mapper.pyc
|
||||
../sqlalchemy/orm/persistence.pyc
|
||||
../sqlalchemy/orm/dynamic.pyc
|
||||
../sqlalchemy/orm/__init__.pyc
|
||||
../sqlalchemy/orm/scoping.pyc
|
||||
../sqlalchemy/orm/descriptor_props.pyc
|
||||
../sqlalchemy/orm/loading.pyc
|
||||
../sqlalchemy/orm/base.pyc
|
||||
../sqlalchemy/orm/exc.pyc
|
||||
../sqlalchemy/orm/events.pyc
|
||||
../sqlalchemy/orm/strategies.pyc
|
||||
../sqlalchemy/orm/query.pyc
|
||||
../sqlalchemy/orm/dependency.pyc
|
||||
../sqlalchemy/orm/attributes.pyc
|
||||
../sqlalchemy/orm/relationships.pyc
|
||||
../sqlalchemy/orm/strategy_options.pyc
|
||||
../sqlalchemy/orm/instrumentation.pyc
|
||||
../sqlalchemy/connectors/pyodbc.pyc
|
||||
../sqlalchemy/connectors/__init__.pyc
|
||||
../sqlalchemy/connectors/zxJDBC.pyc
|
||||
../sqlalchemy/connectors/mysqldb.pyc
|
||||
../sqlalchemy/connectors/mxodbc.pyc
|
||||
../sqlalchemy/databases/__init__.pyc
|
||||
../sqlalchemy/cprocessors.so
|
||||
../sqlalchemy/cresultproxy.so
|
||||
../sqlalchemy/cutils.so
|
||||
./
|
||||
SOURCES.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
top_level.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
sqlalchemy
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: Twisted
|
||||
Version: 14.0.0
|
||||
Summary: An asynchronous networking framework written in Python
|
||||
Home-page: http://twistedmatrix.com/
|
||||
Author: Glyph Lefkowitz
|
||||
Author-email: glyph@twistedmatrix.com
|
||||
License: MIT
|
||||
Description: An extensible framework for Python programming, with special focus
|
||||
on event-based network programming and multiprotocol integration.
|
||||
|
||||
Platform: UNKNOWN
|
||||
Classifier: Programming Language :: Python :: 2.6
|
||||
Classifier: Programming Language :: Python :: 2.7
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Programming Language :: Python :: 3.3
|
||||
|
|
@ -0,0 +1,846 @@
|
|||
README
|
||||
Twisted.egg-info/PKG-INFO
|
||||
Twisted.egg-info/SOURCES.txt
|
||||
Twisted.egg-info/dependency_links.txt
|
||||
Twisted.egg-info/not-zip-safe
|
||||
Twisted.egg-info/requires.txt
|
||||
Twisted.egg-info/top_level.txt
|
||||
bin/manhole
|
||||
bin/pyhtmlizer
|
||||
bin/tap2deb
|
||||
bin/tap2rpm
|
||||
bin/tapconvert
|
||||
bin/trial
|
||||
bin/twistd
|
||||
bin/conch/cftp
|
||||
bin/conch/ckeygen
|
||||
bin/conch/conch
|
||||
bin/conch/tkconch
|
||||
bin/lore/lore
|
||||
bin/mail/mailmail
|
||||
twisted/__init__.py
|
||||
twisted/_version.py
|
||||
twisted/copyright.py
|
||||
twisted/plugin.py
|
||||
twisted/application/__init__.py
|
||||
twisted/application/app.py
|
||||
twisted/application/internet.py
|
||||
twisted/application/reactors.py
|
||||
twisted/application/service.py
|
||||
twisted/application/strports.py
|
||||
twisted/application/test/__init__.py
|
||||
twisted/application/test/test_internet.py
|
||||
twisted/conch/__init__.py
|
||||
twisted/conch/_version.py
|
||||
twisted/conch/avatar.py
|
||||
twisted/conch/checkers.py
|
||||
twisted/conch/endpoints.py
|
||||
twisted/conch/error.py
|
||||
twisted/conch/interfaces.py
|
||||
twisted/conch/ls.py
|
||||
twisted/conch/manhole.py
|
||||
twisted/conch/manhole_ssh.py
|
||||
twisted/conch/manhole_tap.py
|
||||
twisted/conch/mixin.py
|
||||
twisted/conch/recvline.py
|
||||
twisted/conch/stdio.py
|
||||
twisted/conch/tap.py
|
||||
twisted/conch/telnet.py
|
||||
twisted/conch/ttymodes.py
|
||||
twisted/conch/unix.py
|
||||
twisted/conch/client/__init__.py
|
||||
twisted/conch/client/agent.py
|
||||
twisted/conch/client/connect.py
|
||||
twisted/conch/client/default.py
|
||||
twisted/conch/client/direct.py
|
||||
twisted/conch/client/knownhosts.py
|
||||
twisted/conch/client/options.py
|
||||
twisted/conch/insults/__init__.py
|
||||
twisted/conch/insults/client.py
|
||||
twisted/conch/insults/colors.py
|
||||
twisted/conch/insults/helper.py
|
||||
twisted/conch/insults/insults.py
|
||||
twisted/conch/insults/text.py
|
||||
twisted/conch/insults/window.py
|
||||
twisted/conch/openssh_compat/__init__.py
|
||||
twisted/conch/openssh_compat/factory.py
|
||||
twisted/conch/openssh_compat/primes.py
|
||||
twisted/conch/scripts/__init__.py
|
||||
twisted/conch/scripts/cftp.py
|
||||
twisted/conch/scripts/ckeygen.py
|
||||
twisted/conch/scripts/conch.py
|
||||
twisted/conch/scripts/tkconch.py
|
||||
twisted/conch/ssh/__init__.py
|
||||
twisted/conch/ssh/address.py
|
||||
twisted/conch/ssh/agent.py
|
||||
twisted/conch/ssh/channel.py
|
||||
twisted/conch/ssh/common.py
|
||||
twisted/conch/ssh/connection.py
|
||||
twisted/conch/ssh/factory.py
|
||||
twisted/conch/ssh/filetransfer.py
|
||||
twisted/conch/ssh/forwarding.py
|
||||
twisted/conch/ssh/keys.py
|
||||
twisted/conch/ssh/service.py
|
||||
twisted/conch/ssh/session.py
|
||||
twisted/conch/ssh/sexpy.py
|
||||
twisted/conch/ssh/transport.py
|
||||
twisted/conch/ssh/userauth.py
|
||||
twisted/conch/test/__init__.py
|
||||
twisted/conch/test/keydata.py
|
||||
twisted/conch/test/test_address.py
|
||||
twisted/conch/test/test_agent.py
|
||||
twisted/conch/test/test_cftp.py
|
||||
twisted/conch/test/test_channel.py
|
||||
twisted/conch/test/test_checkers.py
|
||||
twisted/conch/test/test_ckeygen.py
|
||||
twisted/conch/test/test_conch.py
|
||||
twisted/conch/test/test_connection.py
|
||||
twisted/conch/test/test_default.py
|
||||
twisted/conch/test/test_endpoints.py
|
||||
twisted/conch/test/test_filetransfer.py
|
||||
twisted/conch/test/test_helper.py
|
||||
twisted/conch/test/test_insults.py
|
||||
twisted/conch/test/test_keys.py
|
||||
twisted/conch/test/test_knownhosts.py
|
||||
twisted/conch/test/test_manhole.py
|
||||
twisted/conch/test/test_mixin.py
|
||||
twisted/conch/test/test_openssh_compat.py
|
||||
twisted/conch/test/test_recvline.py
|
||||
twisted/conch/test/test_scripts.py
|
||||
twisted/conch/test/test_session.py
|
||||
twisted/conch/test/test_ssh.py
|
||||
twisted/conch/test/test_tap.py
|
||||
twisted/conch/test/test_telnet.py
|
||||
twisted/conch/test/test_text.py
|
||||
twisted/conch/test/test_transport.py
|
||||
twisted/conch/test/test_userauth.py
|
||||
twisted/conch/test/test_window.py
|
||||
twisted/conch/ui/__init__.py
|
||||
twisted/conch/ui/ansi.py
|
||||
twisted/conch/ui/tkvt100.py
|
||||
twisted/cred/__init__.py
|
||||
twisted/cred/_digest.py
|
||||
twisted/cred/checkers.py
|
||||
twisted/cred/credentials.py
|
||||
twisted/cred/error.py
|
||||
twisted/cred/pamauth.py
|
||||
twisted/cred/portal.py
|
||||
twisted/cred/strcred.py
|
||||
twisted/enterprise/__init__.py
|
||||
twisted/enterprise/adbapi.py
|
||||
twisted/internet/__init__.py
|
||||
twisted/internet/_baseprocess.py
|
||||
twisted/internet/_dumbwin32proc.py
|
||||
twisted/internet/_glibbase.py
|
||||
twisted/internet/_newtls.py
|
||||
twisted/internet/_pollingfile.py
|
||||
twisted/internet/_posixserialport.py
|
||||
twisted/internet/_posixstdio.py
|
||||
twisted/internet/_signals.py
|
||||
twisted/internet/_ssl.py
|
||||
twisted/internet/_sslverify.py
|
||||
twisted/internet/_threadedselect.py
|
||||
twisted/internet/_win32serialport.py
|
||||
twisted/internet/_win32stdio.py
|
||||
twisted/internet/abstract.py
|
||||
twisted/internet/address.py
|
||||
twisted/internet/base.py
|
||||
twisted/internet/cfreactor.py
|
||||
twisted/internet/default.py
|
||||
twisted/internet/defer.py
|
||||
twisted/internet/endpoints.py
|
||||
twisted/internet/epollreactor.py
|
||||
twisted/internet/error.py
|
||||
twisted/internet/fdesc.py
|
||||
twisted/internet/gireactor.py
|
||||
twisted/internet/glib2reactor.py
|
||||
twisted/internet/gtk2reactor.py
|
||||
twisted/internet/gtk3reactor.py
|
||||
twisted/internet/gtkreactor.py
|
||||
twisted/internet/inotify.py
|
||||
twisted/internet/interfaces.py
|
||||
twisted/internet/kqreactor.py
|
||||
twisted/internet/main.py
|
||||
twisted/internet/pollreactor.py
|
||||
twisted/internet/posixbase.py
|
||||
twisted/internet/process.py
|
||||
twisted/internet/protocol.py
|
||||
twisted/internet/pyuisupport.py
|
||||
twisted/internet/qtreactor.py
|
||||
twisted/internet/reactor.py
|
||||
twisted/internet/selectreactor.py
|
||||
twisted/internet/serialport.py
|
||||
twisted/internet/ssl.py
|
||||
twisted/internet/stdio.py
|
||||
twisted/internet/task.py
|
||||
twisted/internet/tcp.py
|
||||
twisted/internet/threads.py
|
||||
twisted/internet/tksupport.py
|
||||
twisted/internet/udp.py
|
||||
twisted/internet/unix.py
|
||||
twisted/internet/utils.py
|
||||
twisted/internet/win32eventreactor.py
|
||||
twisted/internet/wxreactor.py
|
||||
twisted/internet/wxsupport.py
|
||||
twisted/internet/iocpreactor/__init__.py
|
||||
twisted/internet/iocpreactor/abstract.py
|
||||
twisted/internet/iocpreactor/const.py
|
||||
twisted/internet/iocpreactor/interfaces.py
|
||||
twisted/internet/iocpreactor/reactor.py
|
||||
twisted/internet/iocpreactor/setup.py
|
||||
twisted/internet/iocpreactor/tcp.py
|
||||
twisted/internet/iocpreactor/udp.py
|
||||
twisted/internet/iocpreactor/iocpsupport/iocpsupport.c
|
||||
twisted/internet/iocpreactor/iocpsupport/winsock_pointers.c
|
||||
twisted/internet/test/__init__.py
|
||||
twisted/internet/test/_posixifaces.py
|
||||
twisted/internet/test/_win32ifaces.py
|
||||
twisted/internet/test/connectionmixins.py
|
||||
twisted/internet/test/fakeendpoint.py
|
||||
twisted/internet/test/modulehelpers.py
|
||||
twisted/internet/test/process_gireactornocompat.py
|
||||
twisted/internet/test/process_helper.py
|
||||
twisted/internet/test/reactormixins.py
|
||||
twisted/internet/test/test_abstract.py
|
||||
twisted/internet/test/test_address.py
|
||||
twisted/internet/test/test_base.py
|
||||
twisted/internet/test/test_baseprocess.py
|
||||
twisted/internet/test/test_core.py
|
||||
twisted/internet/test/test_default.py
|
||||
twisted/internet/test/test_endpoints.py
|
||||
twisted/internet/test/test_epollreactor.py
|
||||
twisted/internet/test/test_fdset.py
|
||||
twisted/internet/test/test_filedescriptor.py
|
||||
twisted/internet/test/test_gireactor.py
|
||||
twisted/internet/test/test_glibbase.py
|
||||
twisted/internet/test/test_gtkreactor.py
|
||||
twisted/internet/test/test_inlinecb.py
|
||||
twisted/internet/test/test_inotify.py
|
||||
twisted/internet/test/test_iocp.py
|
||||
twisted/internet/test/test_main.py
|
||||
twisted/internet/test/test_newtls.py
|
||||
twisted/internet/test/test_pollingfile.py
|
||||
twisted/internet/test/test_posixbase.py
|
||||
twisted/internet/test/test_posixprocess.py
|
||||
twisted/internet/test/test_process.py
|
||||
twisted/internet/test/test_protocol.py
|
||||
twisted/internet/test/test_qtreactor.py
|
||||
twisted/internet/test/test_serialport.py
|
||||
twisted/internet/test/test_sigchld.py
|
||||
twisted/internet/test/test_socket.py
|
||||
twisted/internet/test/test_stdio.py
|
||||
twisted/internet/test/test_tcp.py
|
||||
twisted/internet/test/test_threads.py
|
||||
twisted/internet/test/test_time.py
|
||||
twisted/internet/test/test_tls.py
|
||||
twisted/internet/test/test_udp.py
|
||||
twisted/internet/test/test_udp_internals.py
|
||||
twisted/internet/test/test_unix.py
|
||||
twisted/internet/test/test_win32events.py
|
||||
twisted/lore/__init__.py
|
||||
twisted/lore/_version.py
|
||||
twisted/lore/default.py
|
||||
twisted/lore/docbook.py
|
||||
twisted/lore/htmlbook.py
|
||||
twisted/lore/indexer.py
|
||||
twisted/lore/latex.py
|
||||
twisted/lore/lint.py
|
||||
twisted/lore/lmath.py
|
||||
twisted/lore/man2lore.py
|
||||
twisted/lore/numberer.py
|
||||
twisted/lore/process.py
|
||||
twisted/lore/slides.py
|
||||
twisted/lore/texi.py
|
||||
twisted/lore/tree.py
|
||||
twisted/lore/scripts/__init__.py
|
||||
twisted/lore/scripts/lore.py
|
||||
twisted/lore/test/__init__.py
|
||||
twisted/lore/test/test_docbook.py
|
||||
twisted/lore/test/test_latex.py
|
||||
twisted/lore/test/test_lint.py
|
||||
twisted/lore/test/test_lmath.py
|
||||
twisted/lore/test/test_lore.py
|
||||
twisted/lore/test/test_man2lore.py
|
||||
twisted/lore/test/test_scripts.py
|
||||
twisted/lore/test/test_slides.py
|
||||
twisted/lore/test/test_texi.py
|
||||
twisted/mail/__init__.py
|
||||
twisted/mail/_version.py
|
||||
twisted/mail/alias.py
|
||||
twisted/mail/bounce.py
|
||||
twisted/mail/imap4.py
|
||||
twisted/mail/mail.py
|
||||
twisted/mail/maildir.py
|
||||
twisted/mail/pb.py
|
||||
twisted/mail/pop3.py
|
||||
twisted/mail/pop3client.py
|
||||
twisted/mail/protocols.py
|
||||
twisted/mail/relay.py
|
||||
twisted/mail/relaymanager.py
|
||||
twisted/mail/smtp.py
|
||||
twisted/mail/tap.py
|
||||
twisted/mail/scripts/__init__.py
|
||||
twisted/mail/scripts/mailmail.py
|
||||
twisted/mail/test/__init__.py
|
||||
twisted/mail/test/pop3testserver.py
|
||||
twisted/mail/test/test_bounce.py
|
||||
twisted/mail/test/test_imap.py
|
||||
twisted/mail/test/test_mail.py
|
||||
twisted/mail/test/test_mailmail.py
|
||||
twisted/mail/test/test_options.py
|
||||
twisted/mail/test/test_pop3.py
|
||||
twisted/mail/test/test_pop3client.py
|
||||
twisted/mail/test/test_scripts.py
|
||||
twisted/mail/test/test_smtp.py
|
||||
twisted/manhole/__init__.py
|
||||
twisted/manhole/_inspectro.py
|
||||
twisted/manhole/explorer.py
|
||||
twisted/manhole/gladereactor.py
|
||||
twisted/manhole/service.py
|
||||
twisted/manhole/telnet.py
|
||||
twisted/manhole/test/__init__.py
|
||||
twisted/manhole/test/test_explorer.py
|
||||
twisted/manhole/ui/__init__.py
|
||||
twisted/manhole/ui/gtk2manhole.py
|
||||
twisted/manhole/ui/test/__init__.py
|
||||
twisted/manhole/ui/test/test_gtk2manhole.py
|
||||
twisted/names/__init__.py
|
||||
twisted/names/_rfc1982.py
|
||||
twisted/names/_version.py
|
||||
twisted/names/authority.py
|
||||
twisted/names/cache.py
|
||||
twisted/names/client.py
|
||||
twisted/names/common.py
|
||||
twisted/names/dns.py
|
||||
twisted/names/error.py
|
||||
twisted/names/hosts.py
|
||||
twisted/names/resolve.py
|
||||
twisted/names/root.py
|
||||
twisted/names/secondary.py
|
||||
twisted/names/server.py
|
||||
twisted/names/srvconnect.py
|
||||
twisted/names/tap.py
|
||||
twisted/names/test/__init__.py
|
||||
twisted/names/test/test_cache.py
|
||||
twisted/names/test/test_client.py
|
||||
twisted/names/test/test_common.py
|
||||
twisted/names/test/test_dns.py
|
||||
twisted/names/test/test_examples.py
|
||||
twisted/names/test/test_hosts.py
|
||||
twisted/names/test/test_names.py
|
||||
twisted/names/test/test_resolve.py
|
||||
twisted/names/test/test_rfc1982.py
|
||||
twisted/names/test/test_rootresolve.py
|
||||
twisted/names/test/test_server.py
|
||||
twisted/names/test/test_srvconnect.py
|
||||
twisted/names/test/test_tap.py
|
||||
twisted/news/__init__.py
|
||||
twisted/news/_version.py
|
||||
twisted/news/database.py
|
||||
twisted/news/news.py
|
||||
twisted/news/nntp.py
|
||||
twisted/news/tap.py
|
||||
twisted/news/test/__init__.py
|
||||
twisted/news/test/test_database.py
|
||||
twisted/news/test/test_news.py
|
||||
twisted/news/test/test_nntp.py
|
||||
twisted/pair/__init__.py
|
||||
twisted/pair/_version.py
|
||||
twisted/pair/ethernet.py
|
||||
twisted/pair/ip.py
|
||||
twisted/pair/raw.py
|
||||
twisted/pair/rawudp.py
|
||||
twisted/pair/testing.py
|
||||
twisted/pair/tuntap.py
|
||||
twisted/pair/test/__init__.py
|
||||
twisted/pair/test/test_ethernet.py
|
||||
twisted/pair/test/test_ip.py
|
||||
twisted/pair/test/test_rawudp.py
|
||||
twisted/pair/test/test_tuntap.py
|
||||
twisted/persisted/__init__.py
|
||||
twisted/persisted/aot.py
|
||||
twisted/persisted/crefutil.py
|
||||
twisted/persisted/dirdbm.py
|
||||
twisted/persisted/sob.py
|
||||
twisted/persisted/styles.py
|
||||
twisted/persisted/test/__init__.py
|
||||
twisted/persisted/test/test_styles.py
|
||||
twisted/plugins/__init__.py
|
||||
twisted/plugins/cred_anonymous.py
|
||||
twisted/plugins/cred_file.py
|
||||
twisted/plugins/cred_memory.py
|
||||
twisted/plugins/cred_sshkeys.py
|
||||
twisted/plugins/cred_unix.py
|
||||
twisted/plugins/twisted_conch.py
|
||||
twisted/plugins/twisted_core.py
|
||||
twisted/plugins/twisted_ftp.py
|
||||
twisted/plugins/twisted_inet.py
|
||||
twisted/plugins/twisted_lore.py
|
||||
twisted/plugins/twisted_mail.py
|
||||
twisted/plugins/twisted_manhole.py
|
||||
twisted/plugins/twisted_names.py
|
||||
twisted/plugins/twisted_news.py
|
||||
twisted/plugins/twisted_portforward.py
|
||||
twisted/plugins/twisted_qtstub.py
|
||||
twisted/plugins/twisted_reactors.py
|
||||
twisted/plugins/twisted_runner.py
|
||||
twisted/plugins/twisted_socks.py
|
||||
twisted/plugins/twisted_telnet.py
|
||||
twisted/plugins/twisted_trial.py
|
||||
twisted/plugins/twisted_web.py
|
||||
twisted/plugins/twisted_words.py
|
||||
twisted/positioning/__init__.py
|
||||
twisted/positioning/_sentence.py
|
||||
twisted/positioning/base.py
|
||||
twisted/positioning/ipositioning.py
|
||||
twisted/positioning/nmea.py
|
||||
twisted/positioning/test/__init__.py
|
||||
twisted/positioning/test/receiver.py
|
||||
twisted/positioning/test/test_base.py
|
||||
twisted/positioning/test/test_nmea.py
|
||||
twisted/positioning/test/test_sentence.py
|
||||
twisted/protocols/__init__.py
|
||||
twisted/protocols/amp.py
|
||||
twisted/protocols/basic.py
|
||||
twisted/protocols/dict.py
|
||||
twisted/protocols/finger.py
|
||||
twisted/protocols/ftp.py
|
||||
twisted/protocols/htb.py
|
||||
twisted/protocols/ident.py
|
||||
twisted/protocols/loopback.py
|
||||
twisted/protocols/memcache.py
|
||||
twisted/protocols/pcp.py
|
||||
twisted/protocols/policies.py
|
||||
twisted/protocols/portforward.py
|
||||
twisted/protocols/postfix.py
|
||||
twisted/protocols/shoutcast.py
|
||||
twisted/protocols/sip.py
|
||||
twisted/protocols/socks.py
|
||||
twisted/protocols/stateful.py
|
||||
twisted/protocols/telnet.py
|
||||
twisted/protocols/tls.py
|
||||
twisted/protocols/wire.py
|
||||
twisted/protocols/gps/__init__.py
|
||||
twisted/protocols/gps/nmea.py
|
||||
twisted/protocols/gps/rockwell.py
|
||||
twisted/protocols/mice/__init__.py
|
||||
twisted/protocols/mice/mouseman.py
|
||||
twisted/protocols/test/__init__.py
|
||||
twisted/protocols/test/test_basic.py
|
||||
twisted/protocols/test/test_tls.py
|
||||
twisted/python/__init__.py
|
||||
twisted/python/_inotify.py
|
||||
twisted/python/_release.py
|
||||
twisted/python/_shellcomp.py
|
||||
twisted/python/_textattributes.py
|
||||
twisted/python/compat.py
|
||||
twisted/python/components.py
|
||||
twisted/python/constants.py
|
||||
twisted/python/context.py
|
||||
twisted/python/deprecate.py
|
||||
twisted/python/dist.py
|
||||
twisted/python/dist3.py
|
||||
twisted/python/failure.py
|
||||
twisted/python/fakepwd.py
|
||||
twisted/python/filepath.py
|
||||
twisted/python/finalize.py
|
||||
twisted/python/formmethod.py
|
||||
twisted/python/hashlib.py
|
||||
twisted/python/hook.py
|
||||
twisted/python/htmlizer.py
|
||||
twisted/python/lockfile.py
|
||||
twisted/python/log.py
|
||||
twisted/python/logfile.py
|
||||
twisted/python/modules.py
|
||||
twisted/python/monkey.py
|
||||
twisted/python/procutils.py
|
||||
twisted/python/randbytes.py
|
||||
twisted/python/rebuild.py
|
||||
twisted/python/reflect.py
|
||||
twisted/python/release.py
|
||||
twisted/python/roots.py
|
||||
twisted/python/runtime.py
|
||||
twisted/python/sendmsg.c
|
||||
twisted/python/shortcut.py
|
||||
twisted/python/syslog.py
|
||||
twisted/python/systemd.py
|
||||
twisted/python/text.py
|
||||
twisted/python/threadable.py
|
||||
twisted/python/threadpool.py
|
||||
twisted/python/urlpath.py
|
||||
twisted/python/usage.py
|
||||
twisted/python/util.py
|
||||
twisted/python/versions.py
|
||||
twisted/python/win32.py
|
||||
twisted/python/zippath.py
|
||||
twisted/python/zipstream.py
|
||||
twisted/python/test/__init__.py
|
||||
twisted/python/test/deprecatedattributes.py
|
||||
twisted/python/test/modules_helpers.py
|
||||
twisted/python/test/pullpipe.py
|
||||
twisted/python/test/test_components.py
|
||||
twisted/python/test/test_constants.py
|
||||
twisted/python/test/test_deprecate.py
|
||||
twisted/python/test/test_dist.py
|
||||
twisted/python/test/test_dist3.py
|
||||
twisted/python/test/test_fakepwd.py
|
||||
twisted/python/test/test_hashlib.py
|
||||
twisted/python/test/test_htmlizer.py
|
||||
twisted/python/test/test_inotify.py
|
||||
twisted/python/test/test_release.py
|
||||
twisted/python/test/test_runtime.py
|
||||
twisted/python/test/test_sendmsg.py
|
||||
twisted/python/test/test_shellcomp.py
|
||||
twisted/python/test/test_syslog.py
|
||||
twisted/python/test/test_systemd.py
|
||||
twisted/python/test/test_textattributes.py
|
||||
twisted/python/test/test_urlpath.py
|
||||
twisted/python/test/test_util.py
|
||||
twisted/python/test/test_versions.py
|
||||
twisted/python/test/test_win32.py
|
||||
twisted/python/test/test_zippath.py
|
||||
twisted/python/test/test_zipstream.py
|
||||
twisted/runner/__init__.py
|
||||
twisted/runner/_version.py
|
||||
twisted/runner/inetd.py
|
||||
twisted/runner/inetdconf.py
|
||||
twisted/runner/inetdtap.py
|
||||
twisted/runner/portmap.c
|
||||
twisted/runner/procmon.py
|
||||
twisted/runner/procmontap.py
|
||||
twisted/runner/test/__init__.py
|
||||
twisted/runner/test/test_procmon.py
|
||||
twisted/runner/test/test_procmontap.py
|
||||
twisted/scripts/__init__.py
|
||||
twisted/scripts/_twistd_unix.py
|
||||
twisted/scripts/_twistw.py
|
||||
twisted/scripts/htmlizer.py
|
||||
twisted/scripts/manhole.py
|
||||
twisted/scripts/tap2deb.py
|
||||
twisted/scripts/tap2rpm.py
|
||||
twisted/scripts/tapconvert.py
|
||||
twisted/scripts/tkunzip.py
|
||||
twisted/scripts/trial.py
|
||||
twisted/scripts/twistd.py
|
||||
twisted/scripts/test/__init__.py
|
||||
twisted/scripts/test/test_scripts.py
|
||||
twisted/scripts/test/test_tap2deb.py
|
||||
twisted/scripts/test/test_tap2rpm.py
|
||||
twisted/spread/__init__.py
|
||||
twisted/spread/banana.py
|
||||
twisted/spread/flavors.py
|
||||
twisted/spread/interfaces.py
|
||||
twisted/spread/jelly.py
|
||||
twisted/spread/pb.py
|
||||
twisted/spread/publish.py
|
||||
twisted/spread/util.py
|
||||
twisted/spread/ui/__init__.py
|
||||
twisted/spread/ui/gtk2util.py
|
||||
twisted/spread/ui/tktree.py
|
||||
twisted/spread/ui/tkutil.py
|
||||
twisted/tap/__init__.py
|
||||
twisted/tap/ftp.py
|
||||
twisted/tap/manhole.py
|
||||
twisted/tap/portforward.py
|
||||
twisted/tap/socks.py
|
||||
twisted/tap/telnet.py
|
||||
twisted/test/__init__.py
|
||||
twisted/test/_preamble.py
|
||||
twisted/test/crash_test_dummy.py
|
||||
twisted/test/iosim.py
|
||||
twisted/test/mock_win32process.py
|
||||
twisted/test/myrebuilder1.py
|
||||
twisted/test/myrebuilder2.py
|
||||
twisted/test/plugin_basic.py
|
||||
twisted/test/plugin_extra1.py
|
||||
twisted/test/plugin_extra2.py
|
||||
twisted/test/process_cmdline.py
|
||||
twisted/test/process_echoer.py
|
||||
twisted/test/process_fds.py
|
||||
twisted/test/process_linger.py
|
||||
twisted/test/process_reader.py
|
||||
twisted/test/process_signal.py
|
||||
twisted/test/process_stdinreader.py
|
||||
twisted/test/process_tester.py
|
||||
twisted/test/process_tty.py
|
||||
twisted/test/process_twisted.py
|
||||
twisted/test/proto_helpers.py
|
||||
twisted/test/raiser.c
|
||||
twisted/test/reflect_helper_IE.py
|
||||
twisted/test/reflect_helper_VE.py
|
||||
twisted/test/reflect_helper_ZDE.py
|
||||
twisted/test/ssl_helpers.py
|
||||
twisted/test/stdio_test_consumer.py
|
||||
twisted/test/stdio_test_halfclose.py
|
||||
twisted/test/stdio_test_hostpeer.py
|
||||
twisted/test/stdio_test_lastwrite.py
|
||||
twisted/test/stdio_test_loseconn.py
|
||||
twisted/test/stdio_test_producer.py
|
||||
twisted/test/stdio_test_write.py
|
||||
twisted/test/stdio_test_writeseq.py
|
||||
twisted/test/test_abstract.py
|
||||
twisted/test/test_adbapi.py
|
||||
twisted/test/test_amp.py
|
||||
twisted/test/test_application.py
|
||||
twisted/test/test_banana.py
|
||||
twisted/test/test_compat.py
|
||||
twisted/test/test_context.py
|
||||
twisted/test/test_cooperator.py
|
||||
twisted/test/test_defer.py
|
||||
twisted/test/test_defgen.py
|
||||
twisted/test/test_dict.py
|
||||
twisted/test/test_digestauth.py
|
||||
twisted/test/test_dirdbm.py
|
||||
twisted/test/test_doc.py
|
||||
twisted/test/test_error.py
|
||||
twisted/test/test_explorer.py
|
||||
twisted/test/test_factories.py
|
||||
twisted/test/test_failure.py
|
||||
twisted/test/test_fdesc.py
|
||||
twisted/test/test_finger.py
|
||||
twisted/test/test_formmethod.py
|
||||
twisted/test/test_ftp.py
|
||||
twisted/test/test_ftp_options.py
|
||||
twisted/test/test_hook.py
|
||||
twisted/test/test_htb.py
|
||||
twisted/test/test_ident.py
|
||||
twisted/test/test_internet.py
|
||||
twisted/test/test_iosim.py
|
||||
twisted/test/test_iutils.py
|
||||
twisted/test/test_jelly.py
|
||||
twisted/test/test_lockfile.py
|
||||
twisted/test/test_log.py
|
||||
twisted/test/test_logfile.py
|
||||
twisted/test/test_loopback.py
|
||||
twisted/test/test_manhole.py
|
||||
twisted/test/test_memcache.py
|
||||
twisted/test/test_modules.py
|
||||
twisted/test/test_monkey.py
|
||||
twisted/test/test_newcred.py
|
||||
twisted/test/test_nmea.py
|
||||
twisted/test/test_paths.py
|
||||
twisted/test/test_pb.py
|
||||
twisted/test/test_pbfailure.py
|
||||
twisted/test/test_pcp.py
|
||||
twisted/test/test_persisted.py
|
||||
twisted/test/test_plugin.py
|
||||
twisted/test/test_policies.py
|
||||
twisted/test/test_postfix.py
|
||||
twisted/test/test_process.py
|
||||
twisted/test/test_protocols.py
|
||||
twisted/test/test_randbytes.py
|
||||
twisted/test/test_rebuild.py
|
||||
twisted/test/test_reflect.py
|
||||
twisted/test/test_roots.py
|
||||
twisted/test/test_setup.py
|
||||
twisted/test/test_shortcut.py
|
||||
twisted/test/test_sip.py
|
||||
twisted/test/test_sob.py
|
||||
twisted/test/test_socks.py
|
||||
twisted/test/test_ssl.py
|
||||
twisted/test/test_sslverify.py
|
||||
twisted/test/test_stateful.py
|
||||
twisted/test/test_stdio.py
|
||||
twisted/test/test_strcred.py
|
||||
twisted/test/test_strerror.py
|
||||
twisted/test/test_stringtransport.py
|
||||
twisted/test/test_strports.py
|
||||
twisted/test/test_task.py
|
||||
twisted/test/test_tcp.py
|
||||
twisted/test/test_tcp_internals.py
|
||||
twisted/test/test_text.py
|
||||
twisted/test/test_threadable.py
|
||||
twisted/test/test_threadpool.py
|
||||
twisted/test/test_threads.py
|
||||
twisted/test/test_tpfile.py
|
||||
twisted/test/test_twistd.py
|
||||
twisted/test/test_twisted.py
|
||||
twisted/test/test_udp.py
|
||||
twisted/test/test_unix.py
|
||||
twisted/test/test_usage.py
|
||||
twisted/test/testutils.py
|
||||
twisted/trial/__init__.py
|
||||
twisted/trial/_asyncrunner.py
|
||||
twisted/trial/_asynctest.py
|
||||
twisted/trial/_synctest.py
|
||||
twisted/trial/itrial.py
|
||||
twisted/trial/reporter.py
|
||||
twisted/trial/runner.py
|
||||
twisted/trial/unittest.py
|
||||
twisted/trial/util.py
|
||||
twisted/trial/_dist/__init__.py
|
||||
twisted/trial/_dist/distreporter.py
|
||||
twisted/trial/_dist/disttrial.py
|
||||
twisted/trial/_dist/managercommands.py
|
||||
twisted/trial/_dist/options.py
|
||||
twisted/trial/_dist/worker.py
|
||||
twisted/trial/_dist/workercommands.py
|
||||
twisted/trial/_dist/workerreporter.py
|
||||
twisted/trial/_dist/workertrial.py
|
||||
twisted/trial/_dist/test/__init__.py
|
||||
twisted/trial/_dist/test/test_distreporter.py
|
||||
twisted/trial/_dist/test/test_disttrial.py
|
||||
twisted/trial/_dist/test/test_options.py
|
||||
twisted/trial/_dist/test/test_worker.py
|
||||
twisted/trial/_dist/test/test_workerreporter.py
|
||||
twisted/trial/_dist/test/test_workertrial.py
|
||||
twisted/trial/test/__init__.py
|
||||
twisted/trial/test/detests.py
|
||||
twisted/trial/test/erroneous.py
|
||||
twisted/trial/test/mockcustomsuite.py
|
||||
twisted/trial/test/mockcustomsuite2.py
|
||||
twisted/trial/test/mockcustomsuite3.py
|
||||
twisted/trial/test/mockdoctest.py
|
||||
twisted/trial/test/moduleself.py
|
||||
twisted/trial/test/moduletest.py
|
||||
twisted/trial/test/novars.py
|
||||
twisted/trial/test/ordertests.py
|
||||
twisted/trial/test/packages.py
|
||||
twisted/trial/test/sample.py
|
||||
twisted/trial/test/scripttest.py
|
||||
twisted/trial/test/skipping.py
|
||||
twisted/trial/test/suppression.py
|
||||
twisted/trial/test/test_assertions.py
|
||||
twisted/trial/test/test_asyncassertions.py
|
||||
twisted/trial/test/test_deferred.py
|
||||
twisted/trial/test/test_doctest.py
|
||||
twisted/trial/test/test_keyboard.py
|
||||
twisted/trial/test/test_loader.py
|
||||
twisted/trial/test/test_log.py
|
||||
twisted/trial/test/test_output.py
|
||||
twisted/trial/test/test_plugins.py
|
||||
twisted/trial/test/test_pyunitcompat.py
|
||||
twisted/trial/test/test_reporter.py
|
||||
twisted/trial/test/test_runner.py
|
||||
twisted/trial/test/test_script.py
|
||||
twisted/trial/test/test_suppression.py
|
||||
twisted/trial/test/test_testcase.py
|
||||
twisted/trial/test/test_tests.py
|
||||
twisted/trial/test/test_util.py
|
||||
twisted/trial/test/test_warning.py
|
||||
twisted/trial/test/weird.py
|
||||
twisted/web/__init__.py
|
||||
twisted/web/_element.py
|
||||
twisted/web/_flatten.py
|
||||
twisted/web/_newclient.py
|
||||
twisted/web/_responses.py
|
||||
twisted/web/_stan.py
|
||||
twisted/web/_version.py
|
||||
twisted/web/client.py
|
||||
twisted/web/demo.py
|
||||
twisted/web/distrib.py
|
||||
twisted/web/domhelpers.py
|
||||
twisted/web/error.py
|
||||
twisted/web/guard.py
|
||||
twisted/web/html.py
|
||||
twisted/web/http.py
|
||||
twisted/web/http_headers.py
|
||||
twisted/web/iweb.py
|
||||
twisted/web/microdom.py
|
||||
twisted/web/proxy.py
|
||||
twisted/web/resource.py
|
||||
twisted/web/rewrite.py
|
||||
twisted/web/script.py
|
||||
twisted/web/server.py
|
||||
twisted/web/soap.py
|
||||
twisted/web/static.py
|
||||
twisted/web/sux.py
|
||||
twisted/web/tap.py
|
||||
twisted/web/template.py
|
||||
twisted/web/twcgi.py
|
||||
twisted/web/util.py
|
||||
twisted/web/vhost.py
|
||||
twisted/web/wsgi.py
|
||||
twisted/web/xmlrpc.py
|
||||
twisted/web/_auth/__init__.py
|
||||
twisted/web/_auth/basic.py
|
||||
twisted/web/_auth/digest.py
|
||||
twisted/web/_auth/wrapper.py
|
||||
twisted/web/test/__init__.py
|
||||
twisted/web/test/_util.py
|
||||
twisted/web/test/requesthelper.py
|
||||
twisted/web/test/test_agent.py
|
||||
twisted/web/test/test_cgi.py
|
||||
twisted/web/test/test_distrib.py
|
||||
twisted/web/test/test_domhelpers.py
|
||||
twisted/web/test/test_error.py
|
||||
twisted/web/test/test_flatten.py
|
||||
twisted/web/test/test_http.py
|
||||
twisted/web/test/test_http_headers.py
|
||||
twisted/web/test/test_httpauth.py
|
||||
twisted/web/test/test_newclient.py
|
||||
twisted/web/test/test_proxy.py
|
||||
twisted/web/test/test_resource.py
|
||||
twisted/web/test/test_script.py
|
||||
twisted/web/test/test_soap.py
|
||||
twisted/web/test/test_stan.py
|
||||
twisted/web/test/test_static.py
|
||||
twisted/web/test/test_tap.py
|
||||
twisted/web/test/test_template.py
|
||||
twisted/web/test/test_util.py
|
||||
twisted/web/test/test_vhost.py
|
||||
twisted/web/test/test_web.py
|
||||
twisted/web/test/test_webclient.py
|
||||
twisted/web/test/test_wsgi.py
|
||||
twisted/web/test/test_xml.py
|
||||
twisted/web/test/test_xmlrpc.py
|
||||
twisted/words/__init__.py
|
||||
twisted/words/_version.py
|
||||
twisted/words/ewords.py
|
||||
twisted/words/iwords.py
|
||||
twisted/words/service.py
|
||||
twisted/words/tap.py
|
||||
twisted/words/xmpproutertap.py
|
||||
twisted/words/im/__init__.py
|
||||
twisted/words/im/baseaccount.py
|
||||
twisted/words/im/basechat.py
|
||||
twisted/words/im/basesupport.py
|
||||
twisted/words/im/interfaces.py
|
||||
twisted/words/im/ircsupport.py
|
||||
twisted/words/im/locals.py
|
||||
twisted/words/im/pbsupport.py
|
||||
twisted/words/protocols/__init__.py
|
||||
twisted/words/protocols/irc.py
|
||||
twisted/words/protocols/msn.py
|
||||
twisted/words/protocols/oscar.py
|
||||
twisted/words/protocols/jabber/__init__.py
|
||||
twisted/words/protocols/jabber/client.py
|
||||
twisted/words/protocols/jabber/component.py
|
||||
twisted/words/protocols/jabber/error.py
|
||||
twisted/words/protocols/jabber/ijabber.py
|
||||
twisted/words/protocols/jabber/jid.py
|
||||
twisted/words/protocols/jabber/jstrports.py
|
||||
twisted/words/protocols/jabber/sasl.py
|
||||
twisted/words/protocols/jabber/sasl_mechanisms.py
|
||||
twisted/words/protocols/jabber/xmlstream.py
|
||||
twisted/words/protocols/jabber/xmpp_stringprep.py
|
||||
twisted/words/test/__init__.py
|
||||
twisted/words/test/test_basechat.py
|
||||
twisted/words/test/test_basesupport.py
|
||||
twisted/words/test/test_domish.py
|
||||
twisted/words/test/test_irc.py
|
||||
twisted/words/test/test_irc_service.py
|
||||
twisted/words/test/test_ircsupport.py
|
||||
twisted/words/test/test_jabberclient.py
|
||||
twisted/words/test/test_jabbercomponent.py
|
||||
twisted/words/test/test_jabbererror.py
|
||||
twisted/words/test/test_jabberjid.py
|
||||
twisted/words/test/test_jabberjstrports.py
|
||||
twisted/words/test/test_jabbersasl.py
|
||||
twisted/words/test/test_jabbersaslmechanisms.py
|
||||
twisted/words/test/test_jabberxmlstream.py
|
||||
twisted/words/test/test_jabberxmppstringprep.py
|
||||
twisted/words/test/test_msn.py
|
||||
twisted/words/test/test_oscar.py
|
||||
twisted/words/test/test_service.py
|
||||
twisted/words/test/test_tap.py
|
||||
twisted/words/test/test_xishutil.py
|
||||
twisted/words/test/test_xmlstream.py
|
||||
twisted/words/test/test_xmpproutertap.py
|
||||
twisted/words/test/test_xpath.py
|
||||
twisted/words/xish/__init__.py
|
||||
twisted/words/xish/domish.py
|
||||
twisted/words/xish/utility.py
|
||||
twisted/words/xish/xmlstream.py
|
||||
twisted/words/xish/xpath.py
|
||||
twisted/words/xish/xpathparser.py
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1 @@
|
|||
zope.interface >= 3.6.0
|
||||
|
|
@ -0,0 +1 @@
|
|||
twisted
|
||||
|
|
@ -0,0 +1,72 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: Werkzeug
|
||||
Version: 0.9.4
|
||||
Summary: The Swiss Army knife of Python web development
|
||||
Home-page: http://werkzeug.pocoo.org/
|
||||
Author: Armin Ronacher
|
||||
Author-email: armin.ronacher@active-4.com
|
||||
License: BSD
|
||||
Description:
|
||||
Werkzeug
|
||||
========
|
||||
|
||||
Werkzeug started as simple collection of various utilities for WSGI
|
||||
applications and has become one of the most advanced WSGI utility
|
||||
modules. It includes a powerful debugger, full featured request and
|
||||
response objects, HTTP utilities to handle entity tags, cache control
|
||||
headers, HTTP dates, cookie handling, file uploads, a powerful URL
|
||||
routing system and a bunch of community contributed addon modules.
|
||||
|
||||
Werkzeug is unicode aware and doesn't enforce a specific template
|
||||
engine, database adapter or anything else. It doesn't even enforce
|
||||
a specific way of handling requests and leaves all that up to the
|
||||
developer. It's most useful for end user applications which should work
|
||||
on as many server environments as possible (such as blogs, wikis,
|
||||
bulletin boards, etc.).
|
||||
|
||||
Details and example applications are available on the
|
||||
`Werkzeug website <http://werkzeug.pocoo.org/>`_.
|
||||
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
- unicode awareness
|
||||
|
||||
- request and response objects
|
||||
|
||||
- various utility functions for dealing with HTTP headers such as
|
||||
`Accept` and `Cache-Control` headers.
|
||||
|
||||
- thread local objects with proper cleanup at request end
|
||||
|
||||
- an interactive debugger
|
||||
|
||||
- A simple WSGI server with support for threading and forking
|
||||
with an automatic reloader.
|
||||
|
||||
- a flexible URL routing system with REST support.
|
||||
|
||||
- fully WSGI compatible
|
||||
|
||||
|
||||
Development Version
|
||||
-------------------
|
||||
|
||||
The Werkzeug development version can be installed by cloning the git
|
||||
repository from `github`_::
|
||||
|
||||
git clone git@github.com:mitsuhiko/werkzeug.git
|
||||
|
||||
.. _github: http://github.com/mitsuhiko/werkzeug
|
||||
|
||||
Platform: any
|
||||
Classifier: Development Status :: 5 - Production/Stable
|
||||
Classifier: Environment :: Web Environment
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: License :: OSI Approved :: BSD License
|
||||
Classifier: Operating System :: OS Independent
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
||||
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
||||
|
|
@ -0,0 +1,289 @@
|
|||
AUTHORS
|
||||
CHANGES
|
||||
LICENSE
|
||||
MANIFEST.in
|
||||
Makefile
|
||||
setup.cfg
|
||||
setup.py
|
||||
Werkzeug.egg-info/PKG-INFO
|
||||
Werkzeug.egg-info/SOURCES.txt
|
||||
Werkzeug.egg-info/dependency_links.txt
|
||||
Werkzeug.egg-info/not-zip-safe
|
||||
Werkzeug.egg-info/top_level.txt
|
||||
artwork/logo.png
|
||||
artwork/logo.svg
|
||||
docs/Makefile
|
||||
docs/changes.rst
|
||||
docs/conf.py
|
||||
docs/contents.rst.inc
|
||||
docs/datastructures.rst
|
||||
docs/debug.rst
|
||||
docs/exceptions.rst
|
||||
docs/http.rst
|
||||
docs/index.rst
|
||||
docs/installation.rst
|
||||
docs/latexindex.rst
|
||||
docs/levels.rst
|
||||
docs/local.rst
|
||||
docs/logo.pdf
|
||||
docs/make.bat
|
||||
docs/makearchive.py
|
||||
docs/middlewares.rst
|
||||
docs/python3.rst
|
||||
docs/quickstart.rst
|
||||
docs/request_data.rst
|
||||
docs/routing.rst
|
||||
docs/serving.rst
|
||||
docs/terms.rst
|
||||
docs/test.rst
|
||||
docs/transition.rst
|
||||
docs/tutorial.rst
|
||||
docs/unicode.rst
|
||||
docs/utils.rst
|
||||
docs/werkzeugext.py
|
||||
docs/werkzeugstyle.sty
|
||||
docs/wrappers.rst
|
||||
docs/wsgi.rst
|
||||
docs/_static/background.png
|
||||
docs/_static/codebackground.png
|
||||
docs/_static/contents.png
|
||||
docs/_static/debug-screenshot.png
|
||||
docs/_static/favicon.ico
|
||||
docs/_static/header.png
|
||||
docs/_static/navigation.png
|
||||
docs/_static/navigation_active.png
|
||||
docs/_static/shortly.png
|
||||
docs/_static/shorty-screenshot.png
|
||||
docs/_static/style.css
|
||||
docs/_static/werkzeug.js
|
||||
docs/_static/werkzeug.png
|
||||
docs/_templates/sidebarintro.html
|
||||
docs/_templates/sidebarlogo.html
|
||||
docs/_themes/LICENSE
|
||||
docs/_themes/README
|
||||
docs/_themes/werkzeug_theme_support.py
|
||||
docs/_themes/werkzeug/layout.html
|
||||
docs/_themes/werkzeug/relations.html
|
||||
docs/_themes/werkzeug/theme.conf
|
||||
docs/_themes/werkzeug/static/werkzeug.css_t
|
||||
docs/contrib/atom.rst
|
||||
docs/contrib/cache.rst
|
||||
docs/contrib/fixers.rst
|
||||
docs/contrib/index.rst
|
||||
docs/contrib/iterio.rst
|
||||
docs/contrib/lint.rst
|
||||
docs/contrib/profiler.rst
|
||||
docs/contrib/securecookie.rst
|
||||
docs/contrib/sessions.rst
|
||||
docs/contrib/wrappers.rst
|
||||
docs/deployment/cgi.rst
|
||||
docs/deployment/fastcgi.rst
|
||||
docs/deployment/index.rst
|
||||
docs/deployment/mod_wsgi.rst
|
||||
docs/deployment/proxying.rst
|
||||
examples/README
|
||||
examples/cookieauth.py
|
||||
examples/httpbasicauth.py
|
||||
examples/manage-coolmagic.py
|
||||
examples/manage-couchy.py
|
||||
examples/manage-cupoftee.py
|
||||
examples/manage-i18nurls.py
|
||||
examples/manage-plnt.py
|
||||
examples/manage-shorty.py
|
||||
examples/manage-simplewiki.py
|
||||
examples/manage-webpylike.py
|
||||
examples/upload.py
|
||||
examples/contrib/README
|
||||
examples/contrib/securecookie.py
|
||||
examples/contrib/sessions.py
|
||||
examples/coolmagic/__init__.py
|
||||
examples/coolmagic/application.py
|
||||
examples/coolmagic/helpers.py
|
||||
examples/coolmagic/utils.py
|
||||
examples/coolmagic/public/style.css
|
||||
examples/coolmagic/templates/layout.html
|
||||
examples/coolmagic/templates/static/about.html
|
||||
examples/coolmagic/templates/static/index.html
|
||||
examples/coolmagic/templates/static/not_found.html
|
||||
examples/coolmagic/views/__init__.py
|
||||
examples/coolmagic/views/static.py
|
||||
examples/couchy/README
|
||||
examples/couchy/__init__.py
|
||||
examples/couchy/application.py
|
||||
examples/couchy/models.py
|
||||
examples/couchy/utils.py
|
||||
examples/couchy/views.py
|
||||
examples/couchy/static/style.css
|
||||
examples/couchy/templates/display.html
|
||||
examples/couchy/templates/layout.html
|
||||
examples/couchy/templates/list.html
|
||||
examples/couchy/templates/new.html
|
||||
examples/couchy/templates/not_found.html
|
||||
examples/cupoftee/__init__.py
|
||||
examples/cupoftee/application.py
|
||||
examples/cupoftee/db.py
|
||||
examples/cupoftee/network.py
|
||||
examples/cupoftee/pages.py
|
||||
examples/cupoftee/utils.py
|
||||
examples/cupoftee/shared/content.png
|
||||
examples/cupoftee/shared/down.png
|
||||
examples/cupoftee/shared/favicon.ico
|
||||
examples/cupoftee/shared/header.png
|
||||
examples/cupoftee/shared/logo.png
|
||||
examples/cupoftee/shared/style.css
|
||||
examples/cupoftee/shared/up.png
|
||||
examples/cupoftee/templates/layout.html
|
||||
examples/cupoftee/templates/missingpage.html
|
||||
examples/cupoftee/templates/search.html
|
||||
examples/cupoftee/templates/server.html
|
||||
examples/cupoftee/templates/serverlist.html
|
||||
examples/i18nurls/__init__.py
|
||||
examples/i18nurls/application.py
|
||||
examples/i18nurls/urls.py
|
||||
examples/i18nurls/views.py
|
||||
examples/i18nurls/templates/about.html
|
||||
examples/i18nurls/templates/blog.html
|
||||
examples/i18nurls/templates/index.html
|
||||
examples/i18nurls/templates/layout.html
|
||||
examples/partial/README
|
||||
examples/partial/complex_routing.py
|
||||
examples/plnt/__init__.py
|
||||
examples/plnt/database.py
|
||||
examples/plnt/sync.py
|
||||
examples/plnt/utils.py
|
||||
examples/plnt/views.py
|
||||
examples/plnt/webapp.py
|
||||
examples/plnt/shared/style.css
|
||||
examples/plnt/templates/about.html
|
||||
examples/plnt/templates/index.html
|
||||
examples/plnt/templates/layout.html
|
||||
examples/shortly/shortly.py
|
||||
examples/shortly/static/style.css
|
||||
examples/shortly/templates/404.html
|
||||
examples/shortly/templates/layout.html
|
||||
examples/shortly/templates/new_url.html
|
||||
examples/shortly/templates/short_link_details.html
|
||||
examples/shorty/__init__.py
|
||||
examples/shorty/application.py
|
||||
examples/shorty/models.py
|
||||
examples/shorty/utils.py
|
||||
examples/shorty/views.py
|
||||
examples/shorty/static/style.css
|
||||
examples/shorty/templates/display.html
|
||||
examples/shorty/templates/layout.html
|
||||
examples/shorty/templates/list.html
|
||||
examples/shorty/templates/new.html
|
||||
examples/shorty/templates/not_found.html
|
||||
examples/simplewiki/__init__.py
|
||||
examples/simplewiki/actions.py
|
||||
examples/simplewiki/application.py
|
||||
examples/simplewiki/database.py
|
||||
examples/simplewiki/specialpages.py
|
||||
examples/simplewiki/utils.py
|
||||
examples/simplewiki/shared/style.css
|
||||
examples/simplewiki/templates/action_diff.html
|
||||
examples/simplewiki/templates/action_edit.html
|
||||
examples/simplewiki/templates/action_log.html
|
||||
examples/simplewiki/templates/action_revert.html
|
||||
examples/simplewiki/templates/action_show.html
|
||||
examples/simplewiki/templates/layout.html
|
||||
examples/simplewiki/templates/macros.xml
|
||||
examples/simplewiki/templates/missing_action.html
|
||||
examples/simplewiki/templates/page_index.html
|
||||
examples/simplewiki/templates/page_missing.html
|
||||
examples/simplewiki/templates/recent_changes.html
|
||||
examples/webpylike/example.py
|
||||
examples/webpylike/webpylike.py
|
||||
werkzeug/__init__.py
|
||||
werkzeug/_compat.py
|
||||
werkzeug/_internal.py
|
||||
werkzeug/datastructures.py
|
||||
werkzeug/exceptions.py
|
||||
werkzeug/formparser.py
|
||||
werkzeug/http.py
|
||||
werkzeug/local.py
|
||||
werkzeug/posixemulation.py
|
||||
werkzeug/routing.py
|
||||
werkzeug/script.py
|
||||
werkzeug/security.py
|
||||
werkzeug/serving.py
|
||||
werkzeug/test.py
|
||||
werkzeug/testapp.py
|
||||
werkzeug/urls.py
|
||||
werkzeug/useragents.py
|
||||
werkzeug/utils.py
|
||||
werkzeug/wrappers.py
|
||||
werkzeug/wsgi.py
|
||||
werkzeug/contrib/__init__.py
|
||||
werkzeug/contrib/atom.py
|
||||
werkzeug/contrib/cache.py
|
||||
werkzeug/contrib/fixers.py
|
||||
werkzeug/contrib/iterio.py
|
||||
werkzeug/contrib/jsrouting.py
|
||||
werkzeug/contrib/limiter.py
|
||||
werkzeug/contrib/lint.py
|
||||
werkzeug/contrib/profiler.py
|
||||
werkzeug/contrib/securecookie.py
|
||||
werkzeug/contrib/sessions.py
|
||||
werkzeug/contrib/testtools.py
|
||||
werkzeug/contrib/wrappers.py
|
||||
werkzeug/debug/__init__.py
|
||||
werkzeug/debug/console.py
|
||||
werkzeug/debug/repr.py
|
||||
werkzeug/debug/tbtools.py
|
||||
werkzeug/debug/shared/FONT_LICENSE
|
||||
werkzeug/debug/shared/console.png
|
||||
werkzeug/debug/shared/debugger.js
|
||||
werkzeug/debug/shared/jquery.js
|
||||
werkzeug/debug/shared/less.png
|
||||
werkzeug/debug/shared/more.png
|
||||
werkzeug/debug/shared/source.png
|
||||
werkzeug/debug/shared/style.css
|
||||
werkzeug/debug/shared/ubuntu.ttf
|
||||
werkzeug/testsuite/__init__.py
|
||||
werkzeug/testsuite/compat.py
|
||||
werkzeug/testsuite/datastructures.py
|
||||
werkzeug/testsuite/debug.py
|
||||
werkzeug/testsuite/exceptions.py
|
||||
werkzeug/testsuite/formparser.py
|
||||
werkzeug/testsuite/http.py
|
||||
werkzeug/testsuite/internal.py
|
||||
werkzeug/testsuite/local.py
|
||||
werkzeug/testsuite/routing.py
|
||||
werkzeug/testsuite/security.py
|
||||
werkzeug/testsuite/serving.py
|
||||
werkzeug/testsuite/test.py
|
||||
werkzeug/testsuite/urls.py
|
||||
werkzeug/testsuite/utils.py
|
||||
werkzeug/testsuite/wrappers.py
|
||||
werkzeug/testsuite/wsgi.py
|
||||
werkzeug/testsuite/contrib/__init__.py
|
||||
werkzeug/testsuite/contrib/cache.py
|
||||
werkzeug/testsuite/contrib/fixers.py
|
||||
werkzeug/testsuite/contrib/iterio.py
|
||||
werkzeug/testsuite/contrib/securecookie.py
|
||||
werkzeug/testsuite/contrib/sessions.py
|
||||
werkzeug/testsuite/contrib/wrappers.py
|
||||
werkzeug/testsuite/multipart/collect.py
|
||||
werkzeug/testsuite/multipart/ie7_full_path_request.txt
|
||||
werkzeug/testsuite/multipart/firefox3-2png1txt/file1.png
|
||||
werkzeug/testsuite/multipart/firefox3-2png1txt/file2.png
|
||||
werkzeug/testsuite/multipart/firefox3-2png1txt/request.txt
|
||||
werkzeug/testsuite/multipart/firefox3-2png1txt/text.txt
|
||||
werkzeug/testsuite/multipart/firefox3-2pnglongtext/file1.png
|
||||
werkzeug/testsuite/multipart/firefox3-2pnglongtext/file2.png
|
||||
werkzeug/testsuite/multipart/firefox3-2pnglongtext/request.txt
|
||||
werkzeug/testsuite/multipart/firefox3-2pnglongtext/text.txt
|
||||
werkzeug/testsuite/multipart/ie6-2png1txt/file1.png
|
||||
werkzeug/testsuite/multipart/ie6-2png1txt/file2.png
|
||||
werkzeug/testsuite/multipart/ie6-2png1txt/request.txt
|
||||
werkzeug/testsuite/multipart/ie6-2png1txt/text.txt
|
||||
werkzeug/testsuite/multipart/opera8-2png1txt/file1.png
|
||||
werkzeug/testsuite/multipart/opera8-2png1txt/file2.png
|
||||
werkzeug/testsuite/multipart/opera8-2png1txt/request.txt
|
||||
werkzeug/testsuite/multipart/opera8-2png1txt/text.txt
|
||||
werkzeug/testsuite/multipart/webkit3-2png1txt/file1.png
|
||||
werkzeug/testsuite/multipart/webkit3-2png1txt/file2.png
|
||||
werkzeug/testsuite/multipart/webkit3-2png1txt/request.txt
|
||||
werkzeug/testsuite/multipart/webkit3-2png1txt/text.txt
|
||||
werkzeug/testsuite/res/test.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,161 @@
|
|||
../werkzeug/wrappers.py
|
||||
../werkzeug/_compat.py
|
||||
../werkzeug/security.py
|
||||
../werkzeug/http.py
|
||||
../werkzeug/wsgi.py
|
||||
../werkzeug/useragents.py
|
||||
../werkzeug/script.py
|
||||
../werkzeug/exceptions.py
|
||||
../werkzeug/datastructures.py
|
||||
../werkzeug/posixemulation.py
|
||||
../werkzeug/testapp.py
|
||||
../werkzeug/urls.py
|
||||
../werkzeug/local.py
|
||||
../werkzeug/__init__.py
|
||||
../werkzeug/serving.py
|
||||
../werkzeug/formparser.py
|
||||
../werkzeug/_internal.py
|
||||
../werkzeug/test.py
|
||||
../werkzeug/utils.py
|
||||
../werkzeug/routing.py
|
||||
../werkzeug/debug/repr.py
|
||||
../werkzeug/debug/console.py
|
||||
../werkzeug/debug/tbtools.py
|
||||
../werkzeug/debug/__init__.py
|
||||
../werkzeug/contrib/wrappers.py
|
||||
../werkzeug/contrib/lint.py
|
||||
../werkzeug/contrib/profiler.py
|
||||
../werkzeug/contrib/iterio.py
|
||||
../werkzeug/contrib/fixers.py
|
||||
../werkzeug/contrib/sessions.py
|
||||
../werkzeug/contrib/securecookie.py
|
||||
../werkzeug/contrib/testtools.py
|
||||
../werkzeug/contrib/__init__.py
|
||||
../werkzeug/contrib/limiter.py
|
||||
../werkzeug/contrib/jsrouting.py
|
||||
../werkzeug/contrib/cache.py
|
||||
../werkzeug/contrib/atom.py
|
||||
../werkzeug/testsuite/wrappers.py
|
||||
../werkzeug/testsuite/compat.py
|
||||
../werkzeug/testsuite/internal.py
|
||||
../werkzeug/testsuite/security.py
|
||||
../werkzeug/testsuite/http.py
|
||||
../werkzeug/testsuite/wsgi.py
|
||||
../werkzeug/testsuite/exceptions.py
|
||||
../werkzeug/testsuite/datastructures.py
|
||||
../werkzeug/testsuite/urls.py
|
||||
../werkzeug/testsuite/local.py
|
||||
../werkzeug/testsuite/__init__.py
|
||||
../werkzeug/testsuite/serving.py
|
||||
../werkzeug/testsuite/formparser.py
|
||||
../werkzeug/testsuite/test.py
|
||||
../werkzeug/testsuite/debug.py
|
||||
../werkzeug/testsuite/utils.py
|
||||
../werkzeug/testsuite/routing.py
|
||||
../werkzeug/testsuite/contrib/wrappers.py
|
||||
../werkzeug/testsuite/contrib/iterio.py
|
||||
../werkzeug/testsuite/contrib/fixers.py
|
||||
../werkzeug/testsuite/contrib/sessions.py
|
||||
../werkzeug/testsuite/contrib/securecookie.py
|
||||
../werkzeug/testsuite/contrib/__init__.py
|
||||
../werkzeug/testsuite/contrib/cache.py
|
||||
../werkzeug/debug/shared/FONT_LICENSE
|
||||
../werkzeug/debug/shared/console.png
|
||||
../werkzeug/debug/shared/debugger.js
|
||||
../werkzeug/debug/shared/jquery.js
|
||||
../werkzeug/debug/shared/less.png
|
||||
../werkzeug/debug/shared/more.png
|
||||
../werkzeug/debug/shared/source.png
|
||||
../werkzeug/debug/shared/style.css
|
||||
../werkzeug/debug/shared/ubuntu.ttf
|
||||
../werkzeug/testsuite/multipart/collect.py
|
||||
../werkzeug/testsuite/multipart/ie7_full_path_request.txt
|
||||
../werkzeug/testsuite/multipart/firefox3-2png1txt/file1.png
|
||||
../werkzeug/testsuite/multipart/firefox3-2png1txt/file2.png
|
||||
../werkzeug/testsuite/multipart/firefox3-2png1txt/request.txt
|
||||
../werkzeug/testsuite/multipart/firefox3-2png1txt/text.txt
|
||||
../werkzeug/testsuite/multipart/firefox3-2pnglongtext/file1.png
|
||||
../werkzeug/testsuite/multipart/firefox3-2pnglongtext/file2.png
|
||||
../werkzeug/testsuite/multipart/firefox3-2pnglongtext/request.txt
|
||||
../werkzeug/testsuite/multipart/firefox3-2pnglongtext/text.txt
|
||||
../werkzeug/testsuite/multipart/ie6-2png1txt/file1.png
|
||||
../werkzeug/testsuite/multipart/ie6-2png1txt/file2.png
|
||||
../werkzeug/testsuite/multipart/ie6-2png1txt/request.txt
|
||||
../werkzeug/testsuite/multipart/ie6-2png1txt/text.txt
|
||||
../werkzeug/testsuite/multipart/opera8-2png1txt/file1.png
|
||||
../werkzeug/testsuite/multipart/opera8-2png1txt/file2.png
|
||||
../werkzeug/testsuite/multipart/opera8-2png1txt/request.txt
|
||||
../werkzeug/testsuite/multipart/opera8-2png1txt/text.txt
|
||||
../werkzeug/testsuite/multipart/webkit3-2png1txt/file1.png
|
||||
../werkzeug/testsuite/multipart/webkit3-2png1txt/file2.png
|
||||
../werkzeug/testsuite/multipart/webkit3-2png1txt/request.txt
|
||||
../werkzeug/testsuite/multipart/webkit3-2png1txt/text.txt
|
||||
../werkzeug/testsuite/res/test.txt
|
||||
../werkzeug/wrappers.pyc
|
||||
../werkzeug/_compat.pyc
|
||||
../werkzeug/security.pyc
|
||||
../werkzeug/http.pyc
|
||||
../werkzeug/wsgi.pyc
|
||||
../werkzeug/useragents.pyc
|
||||
../werkzeug/script.pyc
|
||||
../werkzeug/exceptions.pyc
|
||||
../werkzeug/datastructures.pyc
|
||||
../werkzeug/posixemulation.pyc
|
||||
../werkzeug/testapp.pyc
|
||||
../werkzeug/urls.pyc
|
||||
../werkzeug/local.pyc
|
||||
../werkzeug/__init__.pyc
|
||||
../werkzeug/serving.pyc
|
||||
../werkzeug/formparser.pyc
|
||||
../werkzeug/_internal.pyc
|
||||
../werkzeug/test.pyc
|
||||
../werkzeug/utils.pyc
|
||||
../werkzeug/routing.pyc
|
||||
../werkzeug/debug/repr.pyc
|
||||
../werkzeug/debug/console.pyc
|
||||
../werkzeug/debug/tbtools.pyc
|
||||
../werkzeug/debug/__init__.pyc
|
||||
../werkzeug/contrib/wrappers.pyc
|
||||
../werkzeug/contrib/lint.pyc
|
||||
../werkzeug/contrib/profiler.pyc
|
||||
../werkzeug/contrib/iterio.pyc
|
||||
../werkzeug/contrib/fixers.pyc
|
||||
../werkzeug/contrib/sessions.pyc
|
||||
../werkzeug/contrib/securecookie.pyc
|
||||
../werkzeug/contrib/testtools.pyc
|
||||
../werkzeug/contrib/__init__.pyc
|
||||
../werkzeug/contrib/limiter.pyc
|
||||
../werkzeug/contrib/jsrouting.pyc
|
||||
../werkzeug/contrib/cache.pyc
|
||||
../werkzeug/contrib/atom.pyc
|
||||
../werkzeug/testsuite/wrappers.pyc
|
||||
../werkzeug/testsuite/compat.pyc
|
||||
../werkzeug/testsuite/internal.pyc
|
||||
../werkzeug/testsuite/security.pyc
|
||||
../werkzeug/testsuite/http.pyc
|
||||
../werkzeug/testsuite/wsgi.pyc
|
||||
../werkzeug/testsuite/exceptions.pyc
|
||||
../werkzeug/testsuite/datastructures.pyc
|
||||
../werkzeug/testsuite/urls.pyc
|
||||
../werkzeug/testsuite/local.pyc
|
||||
../werkzeug/testsuite/__init__.pyc
|
||||
../werkzeug/testsuite/serving.pyc
|
||||
../werkzeug/testsuite/formparser.pyc
|
||||
../werkzeug/testsuite/test.pyc
|
||||
../werkzeug/testsuite/debug.pyc
|
||||
../werkzeug/testsuite/utils.pyc
|
||||
../werkzeug/testsuite/routing.pyc
|
||||
../werkzeug/testsuite/contrib/wrappers.pyc
|
||||
../werkzeug/testsuite/contrib/iterio.pyc
|
||||
../werkzeug/testsuite/contrib/fixers.pyc
|
||||
../werkzeug/testsuite/contrib/sessions.pyc
|
||||
../werkzeug/testsuite/contrib/securecookie.pyc
|
||||
../werkzeug/testsuite/contrib/__init__.pyc
|
||||
../werkzeug/testsuite/contrib/cache.pyc
|
||||
../werkzeug/testsuite/multipart/collect.pyc
|
||||
./
|
||||
SOURCES.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1 @@
|
|||
werkzeug
|
||||
BIN
Linux_i686/lib/python2.7/site-packages/_cffi_backend.so
Executable file
BIN
Linux_i686/lib/python2.7/site-packages/_cffi_backend.so
Executable file
Binary file not shown.
|
|
@ -0,0 +1,96 @@
|
|||
Metadata-Version: 1.1
|
||||
Name: alembic
|
||||
Version: 0.6.5
|
||||
Summary: A database migration tool for SQLAlchemy.
|
||||
Home-page: http://bitbucket.org/zzzeek/alembic
|
||||
Author: Mike Bayer
|
||||
Author-email: mike@zzzcomputing.com
|
||||
License: MIT
|
||||
Description: Alembic is a new database migrations tool, written by the author
|
||||
of `SQLAlchemy <http://www.sqlalchemy.org>`_. A migrations tool
|
||||
offers the following functionality:
|
||||
|
||||
* Can emit ALTER statements to a database in order to change
|
||||
the structure of tables and other constructs
|
||||
* Provides a system whereby "migration scripts" may be constructed;
|
||||
each script indicates a particular series of steps that can "upgrade" a
|
||||
target database to a new version, and optionally a series of steps that can
|
||||
"downgrade" similarly, doing the same steps in reverse.
|
||||
* Allows the scripts to execute in some sequential manner.
|
||||
|
||||
The goals of Alembic are:
|
||||
|
||||
* Very open ended and transparent configuration and operation. A new
|
||||
Alembic environment is generated from a set of templates which is selected
|
||||
among a set of options when setup first occurs. The templates then deposit a
|
||||
series of scripts that define fully how database connectivity is established
|
||||
and how migration scripts are invoked; the migration scripts themselves are
|
||||
generated from a template within that series of scripts. The scripts can
|
||||
then be further customized to define exactly how databases will be
|
||||
interacted with and what structure new migration files should take.
|
||||
* Full support for transactional DDL. The default scripts ensure that all
|
||||
migrations occur within a transaction - for those databases which support
|
||||
this (Postgresql, Microsoft SQL Server), migrations can be tested with no
|
||||
need to manually undo changes upon failure.
|
||||
* Minimalist script construction. Basic operations like renaming
|
||||
tables/columns, adding/removing columns, changing column attributes can be
|
||||
performed through one line commands like alter_column(), rename_table(),
|
||||
add_constraint(). There is no need to recreate full SQLAlchemy Table
|
||||
structures for simple operations like these - the functions themselves
|
||||
generate minimalist schema structures behind the scenes to achieve the given
|
||||
DDL sequence.
|
||||
* "auto generation" of migrations. While real world migrations are far more
|
||||
complex than what can be automatically determined, Alembic can still
|
||||
eliminate the initial grunt work in generating new migration directives
|
||||
from an altered schema. The ``--autogenerate`` feature will inspect the
|
||||
current status of a database using SQLAlchemy's schema inspection
|
||||
capabilities, compare it to the current state of the database model as
|
||||
specified in Python, and generate a series of "candidate" migrations,
|
||||
rendering them into a new migration script as Python directives. The
|
||||
developer then edits the new file, adding additional directives and data
|
||||
migrations as needed, to produce a finished migration. Table and column
|
||||
level changes can be detected, with constraints and indexes to follow as
|
||||
well.
|
||||
* Full support for migrations generated as SQL scripts. Those of us who
|
||||
work in corporate environments know that direct access to DDL commands on a
|
||||
production database is a rare privilege, and DBAs want textual SQL scripts.
|
||||
Alembic's usage model and commands are oriented towards being able to run a
|
||||
series of migrations into a textual output file as easily as it runs them
|
||||
directly to a database. Care must be taken in this mode to not invoke other
|
||||
operations that rely upon in-memory SELECTs of rows - Alembic tries to
|
||||
provide helper constructs like bulk_insert() to help with data-oriented
|
||||
operations that are compatible with script-based DDL.
|
||||
* Non-linear versioning. Scripts are given UUID identifiers similarly
|
||||
to a DVCS, and the linkage of one script to the next is achieved via markers
|
||||
within the scripts themselves. Through this open-ended mechanism, branches
|
||||
containing other migration scripts can be merged - the linkages can be
|
||||
manually edited within the script files to create the new sequence.
|
||||
* Provide a library of ALTER constructs that can be used by any SQLAlchemy
|
||||
application. The DDL constructs build upon SQLAlchemy's own DDLElement base
|
||||
and can be used standalone by any application or script.
|
||||
* Don't break our necks over SQLite's inability to ALTER things. SQLite
|
||||
has almost no support for table or column alteration, and this is likely
|
||||
intentional. Alembic's design
|
||||
is kept simple by not contorting its core API around these limitations,
|
||||
understanding that SQLite is simply not intended to support schema
|
||||
changes. While Alembic's architecture can support SQLite's workarounds, and
|
||||
we will support these features provided someone takes the initiative
|
||||
to implement and test, until the SQLite developers decide
|
||||
to provide a fully working version of ALTER, it's still vastly preferable
|
||||
to use Alembic, or any migrations tool, with databases that
|
||||
are designed to work under the assumption of in-place schema migrations
|
||||
taking place.
|
||||
|
||||
Documentation and status of Alembic is at http://readthedocs.org/docs/alembic/.
|
||||
|
||||
|
||||
Keywords: SQLAlchemy migrations
|
||||
Platform: UNKNOWN
|
||||
Classifier: Development Status :: 4 - Beta
|
||||
Classifier: Environment :: Console
|
||||
Classifier: Intended Audience :: Developers
|
||||
Classifier: Programming Language :: Python
|
||||
Classifier: Programming Language :: Python :: 3
|
||||
Classifier: Programming Language :: Python :: Implementation :: CPython
|
||||
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
||||
Classifier: Topic :: Database :: Front-Ends
|
||||
|
|
@ -0,0 +1,123 @@
|
|||
CHANGES
|
||||
LICENSE
|
||||
MANIFEST.in
|
||||
README.rst
|
||||
README.unittests
|
||||
setup.cfg
|
||||
setup.py
|
||||
test.cfg
|
||||
alembic/__init__.py
|
||||
alembic/command.py
|
||||
alembic/compat.py
|
||||
alembic/config.py
|
||||
alembic/context.py
|
||||
alembic/environment.py
|
||||
alembic/migration.py
|
||||
alembic/op.py
|
||||
alembic/operations.py
|
||||
alembic/script.py
|
||||
alembic/util.py
|
||||
alembic.egg-info/PKG-INFO
|
||||
alembic.egg-info/SOURCES.txt
|
||||
alembic.egg-info/dependency_links.txt
|
||||
alembic.egg-info/entry_points.txt
|
||||
alembic.egg-info/not-zip-safe
|
||||
alembic.egg-info/requires.txt
|
||||
alembic.egg-info/top_level.txt
|
||||
alembic/autogenerate/__init__.py
|
||||
alembic/autogenerate/api.py
|
||||
alembic/autogenerate/compare.py
|
||||
alembic/autogenerate/render.py
|
||||
alembic/ddl/__init__.py
|
||||
alembic/ddl/base.py
|
||||
alembic/ddl/impl.py
|
||||
alembic/ddl/mssql.py
|
||||
alembic/ddl/mysql.py
|
||||
alembic/ddl/oracle.py
|
||||
alembic/ddl/postgresql.py
|
||||
alembic/ddl/sqlite.py
|
||||
alembic/templates/generic/README
|
||||
alembic/templates/generic/alembic.ini.mako
|
||||
alembic/templates/generic/env.py
|
||||
alembic/templates/generic/script.py.mako
|
||||
alembic/templates/multidb/README
|
||||
alembic/templates/multidb/alembic.ini.mako
|
||||
alembic/templates/multidb/env.py
|
||||
alembic/templates/multidb/script.py.mako
|
||||
alembic/templates/pylons/README
|
||||
alembic/templates/pylons/alembic.ini.mako
|
||||
alembic/templates/pylons/env.py
|
||||
alembic/templates/pylons/script.py.mako
|
||||
docs/api.html
|
||||
docs/changelog.html
|
||||
docs/cookbook.html
|
||||
docs/front.html
|
||||
docs/genindex.html
|
||||
docs/index.html
|
||||
docs/ops.html
|
||||
docs/py-modindex.html
|
||||
docs/search.html
|
||||
docs/searchindex.js
|
||||
docs/tutorial.html
|
||||
docs/_images/api_overview.png
|
||||
docs/_sources/api.txt
|
||||
docs/_sources/changelog.txt
|
||||
docs/_sources/cookbook.txt
|
||||
docs/_sources/front.txt
|
||||
docs/_sources/index.txt
|
||||
docs/_sources/ops.txt
|
||||
docs/_sources/tutorial.txt
|
||||
docs/_static/basic.css
|
||||
docs/_static/changelog.css
|
||||
docs/_static/comment-bright.png
|
||||
docs/_static/comment-close.png
|
||||
docs/_static/comment.png
|
||||
docs/_static/doctools.js
|
||||
docs/_static/down-pressed.png
|
||||
docs/_static/down.png
|
||||
docs/_static/file.png
|
||||
docs/_static/jquery.js
|
||||
docs/_static/minus.png
|
||||
docs/_static/nature.css
|
||||
docs/_static/nature_override.css
|
||||
docs/_static/plus.png
|
||||
docs/_static/pygments.css
|
||||
docs/_static/searchtools.js
|
||||
docs/_static/sphinx_paramlinks.css
|
||||
docs/_static/underscore.js
|
||||
docs/_static/up-pressed.png
|
||||
docs/_static/up.png
|
||||
docs/_static/websupport.js
|
||||
docs/build/Makefile
|
||||
docs/build/api.rst
|
||||
docs/build/api_overview.png
|
||||
docs/build/changelog.rst
|
||||
docs/build/conf.py
|
||||
docs/build/cookbook.rst
|
||||
docs/build/front.rst
|
||||
docs/build/index.rst
|
||||
docs/build/ops.rst
|
||||
docs/build/requirements.txt
|
||||
docs/build/tutorial.rst
|
||||
docs/build/_static/nature_override.css
|
||||
tests/__init__.py
|
||||
tests/test_autogen_indexes.py
|
||||
tests/test_autogen_render.py
|
||||
tests/test_autogenerate.py
|
||||
tests/test_bulk_insert.py
|
||||
tests/test_command.py
|
||||
tests/test_config.py
|
||||
tests/test_environment.py
|
||||
tests/test_mssql.py
|
||||
tests/test_mysql.py
|
||||
tests/test_offline_environment.py
|
||||
tests/test_op.py
|
||||
tests/test_op_naming_convention.py
|
||||
tests/test_oracle.py
|
||||
tests/test_postgresql.py
|
||||
tests/test_revision_create.py
|
||||
tests/test_revision_paths.py
|
||||
tests/test_sql_script.py
|
||||
tests/test_sqlite.py
|
||||
tests/test_version_table.py
|
||||
tests/test_versioning.py
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
[console_scripts]
|
||||
alembic = alembic.config:main
|
||||
|
||||
|
|
@ -0,0 +1,70 @@
|
|||
../alembic/compat.py
|
||||
../alembic/util.py
|
||||
../alembic/script.py
|
||||
../alembic/op.py
|
||||
../alembic/context.py
|
||||
../alembic/command.py
|
||||
../alembic/__init__.py
|
||||
../alembic/operations.py
|
||||
../alembic/config.py
|
||||
../alembic/migration.py
|
||||
../alembic/environment.py
|
||||
../alembic/ddl/impl.py
|
||||
../alembic/ddl/mysql.py
|
||||
../alembic/ddl/mssql.py
|
||||
../alembic/ddl/__init__.py
|
||||
../alembic/ddl/oracle.py
|
||||
../alembic/ddl/sqlite.py
|
||||
../alembic/ddl/base.py
|
||||
../alembic/ddl/postgresql.py
|
||||
../alembic/autogenerate/api.py
|
||||
../alembic/autogenerate/compare.py
|
||||
../alembic/autogenerate/render.py
|
||||
../alembic/autogenerate/__init__.py
|
||||
../alembic/templates/generic/README
|
||||
../alembic/templates/generic/alembic.ini.mako
|
||||
../alembic/templates/generic/env.py
|
||||
../alembic/templates/generic/script.py.mako
|
||||
../alembic/templates/multidb/README
|
||||
../alembic/templates/multidb/alembic.ini.mako
|
||||
../alembic/templates/multidb/env.py
|
||||
../alembic/templates/multidb/script.py.mako
|
||||
../alembic/templates/pylons/README
|
||||
../alembic/templates/pylons/alembic.ini.mako
|
||||
../alembic/templates/pylons/env.py
|
||||
../alembic/templates/pylons/script.py.mako
|
||||
../alembic/compat.pyc
|
||||
../alembic/util.pyc
|
||||
../alembic/script.pyc
|
||||
../alembic/op.pyc
|
||||
../alembic/context.pyc
|
||||
../alembic/command.pyc
|
||||
../alembic/__init__.pyc
|
||||
../alembic/operations.pyc
|
||||
../alembic/config.pyc
|
||||
../alembic/migration.pyc
|
||||
../alembic/environment.pyc
|
||||
../alembic/ddl/impl.pyc
|
||||
../alembic/ddl/mysql.pyc
|
||||
../alembic/ddl/mssql.pyc
|
||||
../alembic/ddl/__init__.pyc
|
||||
../alembic/ddl/oracle.pyc
|
||||
../alembic/ddl/sqlite.pyc
|
||||
../alembic/ddl/base.pyc
|
||||
../alembic/ddl/postgresql.pyc
|
||||
../alembic/autogenerate/api.pyc
|
||||
../alembic/autogenerate/compare.pyc
|
||||
../alembic/autogenerate/render.pyc
|
||||
../alembic/autogenerate/__init__.pyc
|
||||
../alembic/templates/generic/env.pyc
|
||||
../alembic/templates/multidb/env.pyc
|
||||
../alembic/templates/pylons/env.pyc
|
||||
./
|
||||
requires.txt
|
||||
SOURCES.txt
|
||||
entry_points.txt
|
||||
dependency_links.txt
|
||||
PKG-INFO
|
||||
not-zip-safe
|
||||
top_level.txt
|
||||
../../../../bin/alembic
|
||||
|
|
@ -0,0 +1 @@
|
|||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
SQLAlchemy>=0.7.3
|
||||
Mako
|
||||
|
|
@ -0,0 +1 @@
|
|||
alembic
|
||||
11
Linux_i686/lib/python2.7/site-packages/alembic/__init__.py
Normal file
11
Linux_i686/lib/python2.7/site-packages/alembic/__init__.py
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
from os import path
|
||||
|
||||
__version__ = '0.6.5'
|
||||
|
||||
package_dir = path.abspath(path.dirname(__file__))
|
||||
|
||||
|
||||
from . import op
|
||||
from . import context
|
||||
|
||||
|
||||
|
|
@ -0,0 +1 @@
|
|||
from .api import compare_metadata, _produce_migration_diffs, _produce_net_changes
|
||||
|
|
@ -0,0 +1,301 @@
|
|||
"""Provide the 'autogenerate' feature which can produce migration operations
|
||||
automatically."""
|
||||
|
||||
import logging
|
||||
import re
|
||||
|
||||
from sqlalchemy.engine.reflection import Inspector
|
||||
from sqlalchemy.util import OrderedSet
|
||||
from .compare import _compare_tables
|
||||
from .render import _drop_table, _drop_column, _drop_index, _drop_constraint, \
|
||||
_add_table, _add_column, _add_index, _add_constraint, _modify_col
|
||||
from .. import util
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
###################################################
|
||||
# public
|
||||
def compare_metadata(context, metadata):
|
||||
"""Compare a database schema to that given in a
|
||||
:class:`~sqlalchemy.schema.MetaData` instance.
|
||||
|
||||
The database connection is presented in the context
|
||||
of a :class:`.MigrationContext` object, which
|
||||
provides database connectivity as well as optional
|
||||
comparison functions to use for datatypes and
|
||||
server defaults - see the "autogenerate" arguments
|
||||
at :meth:`.EnvironmentContext.configure`
|
||||
for details on these.
|
||||
|
||||
The return format is a list of "diff" directives,
|
||||
each representing individual differences::
|
||||
|
||||
from alembic.migration import MigrationContext
|
||||
from alembic.autogenerate import compare_metadata
|
||||
from sqlalchemy.schema import SchemaItem
|
||||
from sqlalchemy.types import TypeEngine
|
||||
from sqlalchemy import (create_engine, MetaData, Column,
|
||||
Integer, String, Table)
|
||||
import pprint
|
||||
|
||||
engine = create_engine("sqlite://")
|
||||
|
||||
engine.execute('''
|
||||
create table foo (
|
||||
id integer not null primary key,
|
||||
old_data varchar,
|
||||
x integer
|
||||
)''')
|
||||
|
||||
engine.execute('''
|
||||
create table bar (
|
||||
data varchar
|
||||
)''')
|
||||
|
||||
metadata = MetaData()
|
||||
Table('foo', metadata,
|
||||
Column('id', Integer, primary_key=True),
|
||||
Column('data', Integer),
|
||||
Column('x', Integer, nullable=False)
|
||||
)
|
||||
Table('bat', metadata,
|
||||
Column('info', String)
|
||||
)
|
||||
|
||||
mc = MigrationContext.configure(engine.connect())
|
||||
|
||||
diff = compare_metadata(mc, metadata)
|
||||
pprint.pprint(diff, indent=2, width=20)
|
||||
|
||||
Output::
|
||||
|
||||
[ ( 'add_table',
|
||||
Table('bat', MetaData(bind=None),
|
||||
Column('info', String(), table=<bat>), schema=None)),
|
||||
( 'remove_table',
|
||||
Table(u'bar', MetaData(bind=None),
|
||||
Column(u'data', VARCHAR(), table=<bar>), schema=None)),
|
||||
( 'add_column',
|
||||
None,
|
||||
'foo',
|
||||
Column('data', Integer(), table=<foo>)),
|
||||
( 'remove_column',
|
||||
None,
|
||||
'foo',
|
||||
Column(u'old_data', VARCHAR(), table=None)),
|
||||
[ ( 'modify_nullable',
|
||||
None,
|
||||
'foo',
|
||||
u'x',
|
||||
{ 'existing_server_default': None,
|
||||
'existing_type': INTEGER()},
|
||||
True,
|
||||
False)]]
|
||||
|
||||
|
||||
:param context: a :class:`.MigrationContext`
|
||||
instance.
|
||||
:param metadata: a :class:`~sqlalchemy.schema.MetaData`
|
||||
instance.
|
||||
|
||||
"""
|
||||
autogen_context, connection = _autogen_context(context, None)
|
||||
diffs = []
|
||||
|
||||
object_filters = _get_object_filters(context.opts)
|
||||
include_schemas = context.opts.get('include_schemas', False)
|
||||
|
||||
_produce_net_changes(connection, metadata, diffs, autogen_context,
|
||||
object_filters, include_schemas)
|
||||
|
||||
return diffs
|
||||
|
||||
###################################################
|
||||
# top level
|
||||
|
||||
def _produce_migration_diffs(context, template_args,
|
||||
imports, include_symbol=None,
|
||||
include_object=None,
|
||||
include_schemas=False):
|
||||
opts = context.opts
|
||||
metadata = opts['target_metadata']
|
||||
include_schemas = opts.get('include_schemas', include_schemas)
|
||||
|
||||
object_filters = _get_object_filters(opts, include_symbol, include_object)
|
||||
|
||||
if metadata is None:
|
||||
raise util.CommandError(
|
||||
"Can't proceed with --autogenerate option; environment "
|
||||
"script %s does not provide "
|
||||
"a MetaData object to the context." % (
|
||||
context.script.env_py_location
|
||||
))
|
||||
autogen_context, connection = _autogen_context(context, imports)
|
||||
|
||||
diffs = []
|
||||
_produce_net_changes(connection, metadata, diffs,
|
||||
autogen_context, object_filters, include_schemas)
|
||||
template_args[opts['upgrade_token']] = \
|
||||
_indent(_produce_upgrade_commands(diffs, autogen_context))
|
||||
template_args[opts['downgrade_token']] = \
|
||||
_indent(_produce_downgrade_commands(diffs, autogen_context))
|
||||
template_args['imports'] = "\n".join(sorted(imports))
|
||||
|
||||
|
||||
def _get_object_filters(context_opts, include_symbol=None, include_object=None):
|
||||
include_symbol = context_opts.get('include_symbol', include_symbol)
|
||||
include_object = context_opts.get('include_object', include_object)
|
||||
|
||||
object_filters = []
|
||||
if include_symbol:
|
||||
def include_symbol_filter(object, name, type_, reflected, compare_to):
|
||||
if type_ == "table":
|
||||
return include_symbol(name, object.schema)
|
||||
else:
|
||||
return True
|
||||
object_filters.append(include_symbol_filter)
|
||||
if include_object:
|
||||
object_filters.append(include_object)
|
||||
|
||||
return object_filters
|
||||
|
||||
|
||||
def _autogen_context(context, imports):
|
||||
opts = context.opts
|
||||
connection = context.bind
|
||||
return {
|
||||
'imports': imports,
|
||||
'connection': connection,
|
||||
'dialect': connection.dialect,
|
||||
'context': context,
|
||||
'opts': opts
|
||||
}, connection
|
||||
|
||||
def _indent(text):
|
||||
text = "### commands auto generated by Alembic - "\
|
||||
"please adjust! ###\n" + text
|
||||
text += "\n### end Alembic commands ###"
|
||||
text = re.compile(r'^', re.M).sub(" ", text).strip()
|
||||
return text
|
||||
|
||||
###################################################
|
||||
# walk structures
|
||||
|
||||
|
||||
def _produce_net_changes(connection, metadata, diffs, autogen_context,
|
||||
object_filters=(),
|
||||
include_schemas=False):
|
||||
inspector = Inspector.from_engine(connection)
|
||||
# TODO: not hardcode alembic_version here ?
|
||||
conn_table_names = set()
|
||||
|
||||
default_schema = connection.dialect.default_schema_name
|
||||
if include_schemas:
|
||||
schemas = set(inspector.get_schema_names())
|
||||
# replace default schema name with None
|
||||
schemas.discard("information_schema")
|
||||
# replace the "default" schema with None
|
||||
schemas.add(None)
|
||||
schemas.discard(default_schema)
|
||||
else:
|
||||
schemas = [None]
|
||||
|
||||
for s in schemas:
|
||||
tables = set(inspector.get_table_names(schema=s)).\
|
||||
difference(['alembic_version'])
|
||||
conn_table_names.update(zip([s] * len(tables), tables))
|
||||
|
||||
metadata_table_names = OrderedSet([(table.schema, table.name)
|
||||
for table in metadata.sorted_tables])
|
||||
|
||||
_compare_tables(conn_table_names, metadata_table_names,
|
||||
object_filters,
|
||||
inspector, metadata, diffs, autogen_context)
|
||||
|
||||
|
||||
###################################################
|
||||
# element comparison
|
||||
|
||||
|
||||
###################################################
|
||||
# render python
|
||||
|
||||
|
||||
###################################################
|
||||
# produce command structure
|
||||
|
||||
def _produce_upgrade_commands(diffs, autogen_context):
|
||||
buf = []
|
||||
for diff in diffs:
|
||||
buf.append(_invoke_command("upgrade", diff, autogen_context))
|
||||
if not buf:
|
||||
buf = ["pass"]
|
||||
return "\n".join(buf)
|
||||
|
||||
def _produce_downgrade_commands(diffs, autogen_context):
|
||||
buf = []
|
||||
for diff in reversed(diffs):
|
||||
buf.append(_invoke_command("downgrade", diff, autogen_context))
|
||||
if not buf:
|
||||
buf = ["pass"]
|
||||
return "\n".join(buf)
|
||||
|
||||
def _invoke_command(updown, args, autogen_context):
|
||||
if isinstance(args, tuple):
|
||||
return _invoke_adddrop_command(updown, args, autogen_context)
|
||||
else:
|
||||
return _invoke_modify_command(updown, args, autogen_context)
|
||||
|
||||
def _invoke_adddrop_command(updown, args, autogen_context):
|
||||
cmd_type = args[0]
|
||||
adddrop, cmd_type = cmd_type.split("_")
|
||||
|
||||
cmd_args = args[1:] + (autogen_context,)
|
||||
|
||||
_commands = {
|
||||
"table": (_drop_table, _add_table),
|
||||
"column": (_drop_column, _add_column),
|
||||
"index": (_drop_index, _add_index),
|
||||
"constraint": (_drop_constraint, _add_constraint),
|
||||
}
|
||||
|
||||
cmd_callables = _commands[cmd_type]
|
||||
|
||||
if (
|
||||
updown == "upgrade" and adddrop == "add"
|
||||
) or (
|
||||
updown == "downgrade" and adddrop == "remove"
|
||||
):
|
||||
return cmd_callables[1](*cmd_args)
|
||||
else:
|
||||
return cmd_callables[0](*cmd_args)
|
||||
|
||||
def _invoke_modify_command(updown, args, autogen_context):
|
||||
sname, tname, cname = args[0][1:4]
|
||||
kw = {}
|
||||
|
||||
_arg_struct = {
|
||||
"modify_type": ("existing_type", "type_"),
|
||||
"modify_nullable": ("existing_nullable", "nullable"),
|
||||
"modify_default": ("existing_server_default", "server_default"),
|
||||
}
|
||||
for diff in args:
|
||||
diff_kw = diff[4]
|
||||
for arg in ("existing_type", \
|
||||
"existing_nullable", \
|
||||
"existing_server_default"):
|
||||
if arg in diff_kw:
|
||||
kw.setdefault(arg, diff_kw[arg])
|
||||
old_kw, new_kw = _arg_struct[diff[0]]
|
||||
if updown == "upgrade":
|
||||
kw[new_kw] = diff[-1]
|
||||
kw[old_kw] = diff[-2]
|
||||
else:
|
||||
kw[new_kw] = diff[-2]
|
||||
kw[old_kw] = diff[-1]
|
||||
|
||||
if "nullable" in kw:
|
||||
kw.pop("existing_nullable", None)
|
||||
if "server_default" in kw:
|
||||
kw.pop("existing_server_default", None)
|
||||
return _modify_col(tname, cname, autogen_context, schema=sname, **kw)
|
||||
|
|
@ -0,0 +1,490 @@
|
|||
from sqlalchemy.exc import NoSuchTableError
|
||||
from sqlalchemy import schema as sa_schema, types as sqltypes
|
||||
import logging
|
||||
from .. import compat
|
||||
from .render import _render_server_default
|
||||
from sqlalchemy.util import OrderedSet
|
||||
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
def _run_filters(object_, name, type_, reflected, compare_to, object_filters):
|
||||
for fn in object_filters:
|
||||
if not fn(object_, name, type_, reflected, compare_to):
|
||||
return False
|
||||
else:
|
||||
return True
|
||||
|
||||
def _compare_tables(conn_table_names, metadata_table_names,
|
||||
object_filters,
|
||||
inspector, metadata, diffs, autogen_context):
|
||||
|
||||
default_schema = inspector.bind.dialect.default_schema_name
|
||||
|
||||
# tables coming from the connection will not have "schema"
|
||||
# set if it matches default_schema_name; so we need a list
|
||||
# of table names from local metadata that also have "None" if schema
|
||||
# == default_schema_name. Most setups will be like this anyway but
|
||||
# some are not (see #170)
|
||||
metadata_table_names_no_dflt_schema = OrderedSet([
|
||||
(schema if schema != default_schema else None, tname)
|
||||
for schema, tname in metadata_table_names
|
||||
])
|
||||
|
||||
# to adjust for the MetaData collection storing the tables either
|
||||
# as "schemaname.tablename" or just "tablename", create a new lookup
|
||||
# which will match the "non-default-schema" keys to the Table object.
|
||||
tname_to_table = dict(
|
||||
(
|
||||
no_dflt_schema,
|
||||
metadata.tables[sa_schema._get_table_key(tname, schema)]
|
||||
)
|
||||
for no_dflt_schema, (schema, tname) in zip(
|
||||
metadata_table_names_no_dflt_schema,
|
||||
metadata_table_names)
|
||||
)
|
||||
metadata_table_names = metadata_table_names_no_dflt_schema
|
||||
|
||||
for s, tname in metadata_table_names.difference(conn_table_names):
|
||||
name = '%s.%s' % (s, tname) if s else tname
|
||||
metadata_table = tname_to_table[(s, tname)]
|
||||
if _run_filters(metadata_table, tname, "table", False, None, object_filters):
|
||||
diffs.append(("add_table", metadata_table))
|
||||
log.info("Detected added table %r", name)
|
||||
_compare_indexes_and_uniques(s, tname, object_filters,
|
||||
None,
|
||||
metadata_table,
|
||||
diffs, autogen_context, inspector)
|
||||
|
||||
removal_metadata = sa_schema.MetaData()
|
||||
for s, tname in conn_table_names.difference(metadata_table_names):
|
||||
name = sa_schema._get_table_key(tname, s)
|
||||
exists = name in removal_metadata.tables
|
||||
t = sa_schema.Table(tname, removal_metadata, schema=s)
|
||||
if not exists:
|
||||
inspector.reflecttable(t, None)
|
||||
if _run_filters(t, tname, "table", True, None, object_filters):
|
||||
diffs.append(("remove_table", t))
|
||||
log.info("Detected removed table %r", name)
|
||||
|
||||
existing_tables = conn_table_names.intersection(metadata_table_names)
|
||||
|
||||
existing_metadata = sa_schema.MetaData()
|
||||
conn_column_info = {}
|
||||
for s, tname in existing_tables:
|
||||
name = sa_schema._get_table_key(tname, s)
|
||||
exists = name in existing_metadata.tables
|
||||
t = sa_schema.Table(tname, existing_metadata, schema=s)
|
||||
if not exists:
|
||||
inspector.reflecttable(t, None)
|
||||
conn_column_info[(s, tname)] = t
|
||||
|
||||
for s, tname in sorted(existing_tables):
|
||||
name = '%s.%s' % (s, tname) if s else tname
|
||||
metadata_table = tname_to_table[(s, tname)]
|
||||
conn_table = existing_metadata.tables[name]
|
||||
|
||||
if _run_filters(metadata_table, tname, "table", False, conn_table, object_filters):
|
||||
_compare_columns(s, tname, object_filters,
|
||||
conn_table,
|
||||
metadata_table,
|
||||
diffs, autogen_context, inspector)
|
||||
_compare_indexes_and_uniques(s, tname, object_filters,
|
||||
conn_table,
|
||||
metadata_table,
|
||||
diffs, autogen_context, inspector)
|
||||
|
||||
# TODO:
|
||||
# table constraints
|
||||
# sequences
|
||||
|
||||
def _make_index(params, conn_table):
|
||||
return sa_schema.Index(
|
||||
params['name'],
|
||||
*[conn_table.c[cname] for cname in params['column_names']],
|
||||
unique=params['unique']
|
||||
)
|
||||
|
||||
def _make_unique_constraint(params, conn_table):
|
||||
return sa_schema.UniqueConstraint(
|
||||
*[conn_table.c[cname] for cname in params['column_names']],
|
||||
name=params['name']
|
||||
)
|
||||
|
||||
def _compare_columns(schema, tname, object_filters, conn_table, metadata_table,
|
||||
diffs, autogen_context, inspector):
|
||||
name = '%s.%s' % (schema, tname) if schema else tname
|
||||
metadata_cols_by_name = dict((c.name, c) for c in metadata_table.c)
|
||||
conn_col_names = dict((c.name, c) for c in conn_table.c)
|
||||
metadata_col_names = OrderedSet(sorted(metadata_cols_by_name))
|
||||
|
||||
for cname in metadata_col_names.difference(conn_col_names):
|
||||
if _run_filters(metadata_cols_by_name[cname], cname,
|
||||
"column", False, None, object_filters):
|
||||
diffs.append(
|
||||
("add_column", schema, tname, metadata_cols_by_name[cname])
|
||||
)
|
||||
log.info("Detected added column '%s.%s'", name, cname)
|
||||
|
||||
for cname in set(conn_col_names).difference(metadata_col_names):
|
||||
if _run_filters(conn_table.c[cname], cname,
|
||||
"column", True, None, object_filters):
|
||||
diffs.append(
|
||||
("remove_column", schema, tname, conn_table.c[cname])
|
||||
)
|
||||
log.info("Detected removed column '%s.%s'", name, cname)
|
||||
|
||||
for colname in metadata_col_names.intersection(conn_col_names):
|
||||
metadata_col = metadata_cols_by_name[colname]
|
||||
conn_col = conn_table.c[colname]
|
||||
if not _run_filters(
|
||||
metadata_col, colname, "column", False, conn_col, object_filters):
|
||||
continue
|
||||
col_diff = []
|
||||
_compare_type(schema, tname, colname,
|
||||
conn_col,
|
||||
metadata_col,
|
||||
col_diff, autogen_context
|
||||
)
|
||||
_compare_nullable(schema, tname, colname,
|
||||
conn_col,
|
||||
metadata_col.nullable,
|
||||
col_diff, autogen_context
|
||||
)
|
||||
_compare_server_default(schema, tname, colname,
|
||||
conn_col,
|
||||
metadata_col,
|
||||
col_diff, autogen_context
|
||||
)
|
||||
if col_diff:
|
||||
diffs.append(col_diff)
|
||||
|
||||
class _constraint_sig(object):
|
||||
def __eq__(self, other):
|
||||
return self.const == other.const
|
||||
|
||||
def __ne__(self, other):
|
||||
return self.const != other.const
|
||||
|
||||
def __hash__(self):
|
||||
return hash(self.const)
|
||||
|
||||
class _uq_constraint_sig(_constraint_sig):
|
||||
is_index = False
|
||||
is_unique = True
|
||||
|
||||
def __init__(self, const):
|
||||
self.const = const
|
||||
self.name = const.name
|
||||
self.sig = tuple(sorted([col.name for col in const.columns]))
|
||||
|
||||
@property
|
||||
def column_names(self):
|
||||
return [col.name for col in self.const.columns]
|
||||
|
||||
class _ix_constraint_sig(_constraint_sig):
|
||||
is_index = True
|
||||
|
||||
def __init__(self, const):
|
||||
self.const = const
|
||||
self.name = const.name
|
||||
self.sig = tuple(sorted([col.name for col in const.columns]))
|
||||
self.is_unique = bool(const.unique)
|
||||
|
||||
@property
|
||||
def column_names(self):
|
||||
return _get_index_column_names(self.const)
|
||||
|
||||
def _get_index_column_names(idx):
|
||||
if compat.sqla_08:
|
||||
return [getattr(exp, "name", None) for exp in idx.expressions]
|
||||
else:
|
||||
return [getattr(col, "name", None) for col in idx.columns]
|
||||
|
||||
def _compare_indexes_and_uniques(schema, tname, object_filters, conn_table,
|
||||
metadata_table, diffs, autogen_context, inspector):
|
||||
|
||||
is_create_table = conn_table is None
|
||||
|
||||
# 1a. get raw indexes and unique constraints from metadata ...
|
||||
metadata_unique_constraints = set(uq for uq in metadata_table.constraints
|
||||
if isinstance(uq, sa_schema.UniqueConstraint)
|
||||
)
|
||||
metadata_indexes = set(metadata_table.indexes)
|
||||
|
||||
conn_uniques = conn_indexes = frozenset()
|
||||
|
||||
supports_unique_constraints = False
|
||||
|
||||
if conn_table is not None:
|
||||
# 1b. ... and from connection, if the table exists
|
||||
if hasattr(inspector, "get_unique_constraints"):
|
||||
try:
|
||||
conn_uniques = inspector.get_unique_constraints(
|
||||
tname, schema=schema)
|
||||
supports_unique_constraints = True
|
||||
except NotImplementedError:
|
||||
pass
|
||||
try:
|
||||
conn_indexes = inspector.get_indexes(tname, schema=schema)
|
||||
except NotImplementedError:
|
||||
pass
|
||||
|
||||
# 2. convert conn-level objects from raw inspector records
|
||||
# into schema objects
|
||||
conn_uniques = set(_make_unique_constraint(uq_def, conn_table)
|
||||
for uq_def in conn_uniques)
|
||||
conn_indexes = set(_make_index(ix, conn_table) for ix in conn_indexes)
|
||||
|
||||
# 3. give the dialect a chance to omit indexes and constraints that
|
||||
# we know are either added implicitly by the DB or that the DB
|
||||
# can't accurately report on
|
||||
autogen_context['context'].impl.\
|
||||
correct_for_autogen_constraints(
|
||||
conn_uniques, conn_indexes,
|
||||
metadata_unique_constraints,
|
||||
metadata_indexes
|
||||
)
|
||||
|
||||
# 4. organize the constraints into "signature" collections, the
|
||||
# _constraint_sig() objects provide a consistent facade over both
|
||||
# Index and UniqueConstraint so we can easily work with them
|
||||
# interchangeably
|
||||
metadata_unique_constraints = set(_uq_constraint_sig(uq)
|
||||
for uq in metadata_unique_constraints
|
||||
)
|
||||
|
||||
metadata_indexes = set(_ix_constraint_sig(ix) for ix in metadata_indexes)
|
||||
|
||||
conn_unique_constraints = set(_uq_constraint_sig(uq) for uq in conn_uniques)
|
||||
|
||||
conn_indexes = set(_ix_constraint_sig(ix) for ix in conn_indexes)
|
||||
|
||||
# 5. index things by name, for those objects that have names
|
||||
metadata_names = dict(
|
||||
(c.name, c) for c in
|
||||
metadata_unique_constraints.union(metadata_indexes)
|
||||
if c.name is not None)
|
||||
|
||||
conn_uniques_by_name = dict((c.name, c) for c in conn_unique_constraints)
|
||||
conn_indexes_by_name = dict((c.name, c) for c in conn_indexes)
|
||||
|
||||
conn_names = dict((c.name, c) for c in
|
||||
conn_unique_constraints.union(conn_indexes)
|
||||
if c.name is not None)
|
||||
|
||||
doubled_constraints = dict(
|
||||
(name, (conn_uniques_by_name[name], conn_indexes_by_name[name]))
|
||||
for name in set(conn_uniques_by_name).intersection(conn_indexes_by_name)
|
||||
)
|
||||
|
||||
# 6. index things by "column signature", to help with unnamed unique
|
||||
# constraints.
|
||||
conn_uniques_by_sig = dict((uq.sig, uq) for uq in conn_unique_constraints)
|
||||
metadata_uniques_by_sig = dict(
|
||||
(uq.sig, uq) for uq in metadata_unique_constraints)
|
||||
metadata_indexes_by_sig = dict(
|
||||
(ix.sig, ix) for ix in metadata_indexes)
|
||||
unnamed_metadata_uniques = dict((uq.sig, uq) for uq in
|
||||
metadata_unique_constraints if uq.name is None)
|
||||
|
||||
# assumptions:
|
||||
# 1. a unique constraint or an index from the connection *always*
|
||||
# has a name.
|
||||
# 2. an index on the metadata side *always* has a name.
|
||||
# 3. a unique constraint on the metadata side *might* have a name.
|
||||
# 4. The backend may double up indexes as unique constraints and
|
||||
# vice versa (e.g. MySQL, Postgresql)
|
||||
|
||||
def obj_added(obj):
|
||||
if obj.is_index:
|
||||
diffs.append(("add_index", obj.const))
|
||||
log.info("Detected added index '%s' on %s",
|
||||
obj.name, ', '.join([
|
||||
"'%s'" % obj.column_names
|
||||
])
|
||||
)
|
||||
else:
|
||||
if not supports_unique_constraints:
|
||||
# can't report unique indexes as added if we don't
|
||||
# detect them
|
||||
return
|
||||
if is_create_table:
|
||||
# unique constraints are created inline with table defs
|
||||
return
|
||||
diffs.append(("add_constraint", obj.const))
|
||||
log.info("Detected added unique constraint '%s' on %s",
|
||||
obj.name, ', '.join([
|
||||
"'%s'" % obj.column_names
|
||||
])
|
||||
)
|
||||
|
||||
def obj_removed(obj):
|
||||
if obj.is_index:
|
||||
if obj.is_unique and not supports_unique_constraints:
|
||||
# many databases double up unique constraints
|
||||
# as unique indexes. without that list we can't
|
||||
# be sure what we're doing here
|
||||
return
|
||||
|
||||
diffs.append(("remove_index", obj.const))
|
||||
log.info("Detected removed index '%s' on '%s'", obj.name, tname)
|
||||
else:
|
||||
diffs.append(("remove_constraint", obj.const))
|
||||
log.info("Detected removed unique constraint '%s' on '%s'",
|
||||
obj.name, tname
|
||||
)
|
||||
|
||||
def obj_changed(old, new, msg):
|
||||
if old.is_index:
|
||||
log.info("Detected changed index '%s' on '%s':%s",
|
||||
old.name, tname, ', '.join(msg)
|
||||
)
|
||||
diffs.append(("remove_index", old.const))
|
||||
diffs.append(("add_index", new.const))
|
||||
else:
|
||||
log.info("Detected changed unique constraint '%s' on '%s':%s",
|
||||
old.name, tname, ', '.join(msg)
|
||||
)
|
||||
diffs.append(("remove_constraint", old.const))
|
||||
diffs.append(("add_constraint", new.const))
|
||||
|
||||
for added_name in sorted(set(metadata_names).difference(conn_names)):
|
||||
obj = metadata_names[added_name]
|
||||
obj_added(obj)
|
||||
|
||||
|
||||
for existing_name in sorted(set(metadata_names).intersection(conn_names)):
|
||||
metadata_obj = metadata_names[existing_name]
|
||||
|
||||
if existing_name in doubled_constraints:
|
||||
conn_uq, conn_idx = doubled_constraints[existing_name]
|
||||
if metadata_obj.is_index:
|
||||
conn_obj = conn_idx
|
||||
else:
|
||||
conn_obj = conn_uq
|
||||
else:
|
||||
conn_obj = conn_names[existing_name]
|
||||
|
||||
if conn_obj.is_index != metadata_obj.is_index:
|
||||
obj_removed(conn_obj)
|
||||
obj_added(metadata_obj)
|
||||
else:
|
||||
msg = []
|
||||
if conn_obj.is_unique != metadata_obj.is_unique:
|
||||
msg.append(' unique=%r to unique=%r' % (
|
||||
conn_obj.is_unique, metadata_obj.is_unique
|
||||
))
|
||||
if conn_obj.sig != metadata_obj.sig:
|
||||
msg.append(' columns %r to %r' % (
|
||||
conn_obj.sig, metadata_obj.sig
|
||||
))
|
||||
|
||||
if msg:
|
||||
obj_changed(conn_obj, metadata_obj, msg)
|
||||
|
||||
|
||||
for removed_name in sorted(set(conn_names).difference(metadata_names)):
|
||||
conn_obj = conn_names[removed_name]
|
||||
if not conn_obj.is_index and conn_obj.sig in unnamed_metadata_uniques:
|
||||
continue
|
||||
elif removed_name in doubled_constraints:
|
||||
if conn_obj.sig not in metadata_indexes_by_sig and \
|
||||
conn_obj.sig not in metadata_uniques_by_sig:
|
||||
conn_uq, conn_idx = doubled_constraints[removed_name]
|
||||
obj_removed(conn_uq)
|
||||
obj_removed(conn_idx)
|
||||
else:
|
||||
obj_removed(conn_obj)
|
||||
|
||||
for uq_sig in unnamed_metadata_uniques:
|
||||
if uq_sig not in conn_uniques_by_sig:
|
||||
obj_added(unnamed_metadata_uniques[uq_sig])
|
||||
|
||||
|
||||
def _compare_nullable(schema, tname, cname, conn_col,
|
||||
metadata_col_nullable, diffs,
|
||||
autogen_context):
|
||||
conn_col_nullable = conn_col.nullable
|
||||
if conn_col_nullable is not metadata_col_nullable:
|
||||
diffs.append(
|
||||
("modify_nullable", schema, tname, cname,
|
||||
{
|
||||
"existing_type": conn_col.type,
|
||||
"existing_server_default": conn_col.server_default,
|
||||
},
|
||||
conn_col_nullable,
|
||||
metadata_col_nullable),
|
||||
)
|
||||
log.info("Detected %s on column '%s.%s'",
|
||||
"NULL" if metadata_col_nullable else "NOT NULL",
|
||||
tname,
|
||||
cname
|
||||
)
|
||||
|
||||
def _compare_type(schema, tname, cname, conn_col,
|
||||
metadata_col, diffs,
|
||||
autogen_context):
|
||||
|
||||
conn_type = conn_col.type
|
||||
metadata_type = metadata_col.type
|
||||
if conn_type._type_affinity is sqltypes.NullType:
|
||||
log.info("Couldn't determine database type "
|
||||
"for column '%s.%s'", tname, cname)
|
||||
return
|
||||
if metadata_type._type_affinity is sqltypes.NullType:
|
||||
log.info("Column '%s.%s' has no type within "
|
||||
"the model; can't compare", tname, cname)
|
||||
return
|
||||
|
||||
isdiff = autogen_context['context']._compare_type(conn_col, metadata_col)
|
||||
|
||||
if isdiff:
|
||||
|
||||
diffs.append(
|
||||
("modify_type", schema, tname, cname,
|
||||
{
|
||||
"existing_nullable": conn_col.nullable,
|
||||
"existing_server_default": conn_col.server_default,
|
||||
},
|
||||
conn_type,
|
||||
metadata_type),
|
||||
)
|
||||
log.info("Detected type change from %r to %r on '%s.%s'",
|
||||
conn_type, metadata_type, tname, cname
|
||||
)
|
||||
|
||||
def _compare_server_default(schema, tname, cname, conn_col, metadata_col,
|
||||
diffs, autogen_context):
|
||||
|
||||
metadata_default = metadata_col.server_default
|
||||
conn_col_default = conn_col.server_default
|
||||
if conn_col_default is None and metadata_default is None:
|
||||
return False
|
||||
rendered_metadata_default = _render_server_default(
|
||||
metadata_default, autogen_context)
|
||||
rendered_conn_default = conn_col.server_default.arg.text \
|
||||
if conn_col.server_default else None
|
||||
isdiff = autogen_context['context']._compare_server_default(
|
||||
conn_col, metadata_col,
|
||||
rendered_metadata_default,
|
||||
rendered_conn_default
|
||||
)
|
||||
if isdiff:
|
||||
conn_col_default = rendered_conn_default
|
||||
diffs.append(
|
||||
("modify_default", schema, tname, cname,
|
||||
{
|
||||
"existing_nullable": conn_col.nullable,
|
||||
"existing_type": conn_col.type,
|
||||
},
|
||||
conn_col_default,
|
||||
metadata_default),
|
||||
)
|
||||
log.info("Detected server default on column '%s.%s'",
|
||||
tname,
|
||||
cname
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,457 @@
|
|||
from sqlalchemy import schema as sa_schema, types as sqltypes, sql
|
||||
import logging
|
||||
from .. import compat
|
||||
import re
|
||||
from ..compat import string_types
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
try:
|
||||
from sqlalchemy.sql.naming import conv
|
||||
def _render_gen_name(autogen_context, name):
|
||||
if isinstance(name, conv):
|
||||
return _f_name(_alembic_autogenerate_prefix(autogen_context), name)
|
||||
else:
|
||||
return name
|
||||
except ImportError:
|
||||
def _render_gen_name(autogen_context, name):
|
||||
return name
|
||||
|
||||
class _f_name(object):
|
||||
def __init__(self, prefix, name):
|
||||
self.prefix = prefix
|
||||
self.name = name
|
||||
|
||||
def __repr__(self):
|
||||
return "%sf(%r)" % (self.prefix, self.name)
|
||||
|
||||
def _render_potential_expr(value, autogen_context):
|
||||
if isinstance(value, sql.ClauseElement):
|
||||
if compat.sqla_08:
|
||||
compile_kw = dict(compile_kwargs={'literal_binds': True})
|
||||
else:
|
||||
compile_kw = {}
|
||||
|
||||
return "%(prefix)stext(%(sql)r)" % {
|
||||
"prefix": _sqlalchemy_autogenerate_prefix(autogen_context),
|
||||
"sql": str(
|
||||
value.compile(dialect=autogen_context['dialect'],
|
||||
**compile_kw)
|
||||
)
|
||||
}
|
||||
|
||||
else:
|
||||
return repr(value)
|
||||
|
||||
def _add_table(table, autogen_context):
|
||||
text = "%(prefix)screate_table(%(tablename)r,\n%(args)s" % {
|
||||
'tablename': table.name,
|
||||
'prefix': _alembic_autogenerate_prefix(autogen_context),
|
||||
'args': ',\n'.join(
|
||||
[col for col in
|
||||
[_render_column(col, autogen_context) for col in table.c]
|
||||
if col] +
|
||||
sorted([rcons for rcons in
|
||||
[_render_constraint(cons, autogen_context) for cons in
|
||||
table.constraints]
|
||||
if rcons is not None
|
||||
])
|
||||
)
|
||||
}
|
||||
if table.schema:
|
||||
text += ",\nschema=%r" % table.schema
|
||||
for k in sorted(table.kwargs):
|
||||
text += ",\n%s=%r" % (k.replace(" ", "_"), table.kwargs[k])
|
||||
text += "\n)"
|
||||
return text
|
||||
|
||||
def _drop_table(table, autogen_context):
|
||||
text = "%(prefix)sdrop_table(%(tname)r" % {
|
||||
"prefix": _alembic_autogenerate_prefix(autogen_context),
|
||||
"tname": table.name
|
||||
}
|
||||
if table.schema:
|
||||
text += ", schema=%r" % table.schema
|
||||
text += ")"
|
||||
return text
|
||||
|
||||
def _add_index(index, autogen_context):
|
||||
"""
|
||||
Generate Alembic operations for the CREATE INDEX of an
|
||||
:class:`~sqlalchemy.schema.Index` instance.
|
||||
"""
|
||||
from .compare import _get_index_column_names
|
||||
|
||||
text = "%(prefix)screate_index(%(name)r, '%(table)s', %(columns)s, "\
|
||||
"unique=%(unique)r%(schema)s%(kwargs)s)" % {
|
||||
'prefix': _alembic_autogenerate_prefix(autogen_context),
|
||||
'name': _render_gen_name(autogen_context, index.name),
|
||||
'table': index.table.name,
|
||||
'columns': _get_index_column_names(index),
|
||||
'unique': index.unique or False,
|
||||
'schema': (", schema='%s'" % index.table.schema) if index.table.schema else '',
|
||||
'kwargs': (', '+', '.join(
|
||||
["%s=%s" % (key, _render_potential_expr(val, autogen_context))
|
||||
for key, val in index.kwargs.items()]))\
|
||||
if len(index.kwargs) else ''
|
||||
}
|
||||
return text
|
||||
|
||||
def _drop_index(index, autogen_context):
|
||||
"""
|
||||
Generate Alembic operations for the DROP INDEX of an
|
||||
:class:`~sqlalchemy.schema.Index` instance.
|
||||
"""
|
||||
text = "%(prefix)sdrop_index(%(name)r, "\
|
||||
"table_name='%(table_name)s'%(schema)s)" % {
|
||||
'prefix': _alembic_autogenerate_prefix(autogen_context),
|
||||
'name': _render_gen_name(autogen_context, index.name),
|
||||
'table_name': index.table.name,
|
||||
'schema': ((", schema='%s'" % index.table.schema)
|
||||
if index.table.schema else '')
|
||||
}
|
||||
return text
|
||||
|
||||
|
||||
def _render_unique_constraint(constraint, autogen_context):
|
||||
rendered = _user_defined_render("unique", constraint, autogen_context)
|
||||
if rendered is not False:
|
||||
return rendered
|
||||
|
||||
return _uq_constraint(constraint, autogen_context, False)
|
||||
|
||||
|
||||
def _add_unique_constraint(constraint, autogen_context):
|
||||
"""
|
||||
Generate Alembic operations for the ALTER TABLE .. ADD CONSTRAINT ...
|
||||
UNIQUE of a :class:`~sqlalchemy.schema.UniqueConstraint` instance.
|
||||
"""
|
||||
return _uq_constraint(constraint, autogen_context, True)
|
||||
|
||||
def _uq_constraint(constraint, autogen_context, alter):
|
||||
opts = []
|
||||
if constraint.deferrable:
|
||||
opts.append(("deferrable", str(constraint.deferrable)))
|
||||
if constraint.initially:
|
||||
opts.append(("initially", str(constraint.initially)))
|
||||
if alter and constraint.table.schema:
|
||||
opts.append(("schema", str(constraint.table.schema)))
|
||||
if not alter and constraint.name:
|
||||
opts.append(("name", _render_gen_name(autogen_context, constraint.name)))
|
||||
|
||||
if alter:
|
||||
args = [repr(_render_gen_name(autogen_context, constraint.name)),
|
||||
repr(constraint.table.name)]
|
||||
args.append(repr([col.name for col in constraint.columns]))
|
||||
args.extend(["%s=%r" % (k, v) for k, v in opts])
|
||||
return "%(prefix)screate_unique_constraint(%(args)s)" % {
|
||||
'prefix': _alembic_autogenerate_prefix(autogen_context),
|
||||
'args': ", ".join(args)
|
||||
}
|
||||
else:
|
||||
args = [repr(col.name) for col in constraint.columns]
|
||||
args.extend(["%s=%r" % (k, v) for k, v in opts])
|
||||
return "%(prefix)sUniqueConstraint(%(args)s)" % {
|
||||
"prefix": _sqlalchemy_autogenerate_prefix(autogen_context),
|
||||
"args": ", ".join(args)
|
||||
}
|
||||
|
||||
|
||||
def _add_fk_constraint(constraint, autogen_context):
|
||||
raise NotImplementedError()
|
||||
|
||||
def _add_pk_constraint(constraint, autogen_context):
|
||||
raise NotImplementedError()
|
||||
|
||||
def _add_check_constraint(constraint, autogen_context):
|
||||
raise NotImplementedError()
|
||||
|
||||
def _add_constraint(constraint, autogen_context):
|
||||
"""
|
||||
Dispatcher for the different types of constraints.
|
||||
"""
|
||||
funcs = {
|
||||
"unique_constraint": _add_unique_constraint,
|
||||
"foreign_key_constraint": _add_fk_constraint,
|
||||
"primary_key_constraint": _add_pk_constraint,
|
||||
"check_constraint": _add_check_constraint,
|
||||
"column_check_constraint": _add_check_constraint,
|
||||
}
|
||||
return funcs[constraint.__visit_name__](constraint, autogen_context)
|
||||
|
||||
def _drop_constraint(constraint, autogen_context):
|
||||
"""
|
||||
Generate Alembic operations for the ALTER TABLE ... DROP CONSTRAINT
|
||||
of a :class:`~sqlalchemy.schema.UniqueConstraint` instance.
|
||||
"""
|
||||
text = "%(prefix)sdrop_constraint(%(name)r, '%(table_name)s'%(schema)s)" % {
|
||||
'prefix': _alembic_autogenerate_prefix(autogen_context),
|
||||
'name': _render_gen_name(autogen_context, constraint.name),
|
||||
'table_name': constraint.table.name,
|
||||
'schema': (", schema='%s'" % constraint.table.schema)
|
||||
if constraint.table.schema else '',
|
||||
}
|
||||
return text
|
||||
|
||||
def _add_column(schema, tname, column, autogen_context):
|
||||
text = "%(prefix)sadd_column(%(tname)r, %(column)s" % {
|
||||
"prefix": _alembic_autogenerate_prefix(autogen_context),
|
||||
"tname": tname,
|
||||
"column": _render_column(column, autogen_context)
|
||||
}
|
||||
if schema:
|
||||
text += ", schema=%r" % schema
|
||||
text += ")"
|
||||
return text
|
||||
|
||||
def _drop_column(schema, tname, column, autogen_context):
|
||||
text = "%(prefix)sdrop_column(%(tname)r, %(cname)r" % {
|
||||
"prefix": _alembic_autogenerate_prefix(autogen_context),
|
||||
"tname": tname,
|
||||
"cname": column.name
|
||||
}
|
||||
if schema:
|
||||
text += ", schema=%r" % schema
|
||||
text += ")"
|
||||
return text
|
||||
|
||||
def _modify_col(tname, cname,
|
||||
autogen_context,
|
||||
server_default=False,
|
||||
type_=None,
|
||||
nullable=None,
|
||||
existing_type=None,
|
||||
existing_nullable=None,
|
||||
existing_server_default=False,
|
||||
schema=None):
|
||||
indent = " " * 11
|
||||
text = "%(prefix)salter_column(%(tname)r, %(cname)r" % {
|
||||
'prefix': _alembic_autogenerate_prefix(
|
||||
autogen_context),
|
||||
'tname': tname,
|
||||
'cname': cname}
|
||||
text += ",\n%sexisting_type=%s" % (indent,
|
||||
_repr_type(existing_type, autogen_context))
|
||||
if server_default is not False:
|
||||
rendered = _render_server_default(
|
||||
server_default, autogen_context)
|
||||
text += ",\n%sserver_default=%s" % (indent, rendered)
|
||||
|
||||
if type_ is not None:
|
||||
text += ",\n%stype_=%s" % (indent,
|
||||
_repr_type(type_, autogen_context))
|
||||
if nullable is not None:
|
||||
text += ",\n%snullable=%r" % (
|
||||
indent, nullable,)
|
||||
if existing_nullable is not None:
|
||||
text += ",\n%sexisting_nullable=%r" % (
|
||||
indent, existing_nullable)
|
||||
if existing_server_default:
|
||||
rendered = _render_server_default(
|
||||
existing_server_default,
|
||||
autogen_context)
|
||||
text += ",\n%sexisting_server_default=%s" % (
|
||||
indent, rendered)
|
||||
if schema:
|
||||
text += ",\n%sschema=%r" % (indent, schema)
|
||||
text += ")"
|
||||
return text
|
||||
|
||||
def _user_autogenerate_prefix(autogen_context):
|
||||
prefix = autogen_context['opts']['user_module_prefix']
|
||||
if prefix is None:
|
||||
return _sqlalchemy_autogenerate_prefix(autogen_context)
|
||||
else:
|
||||
return prefix
|
||||
|
||||
def _sqlalchemy_autogenerate_prefix(autogen_context):
|
||||
return autogen_context['opts']['sqlalchemy_module_prefix'] or ''
|
||||
|
||||
def _alembic_autogenerate_prefix(autogen_context):
|
||||
return autogen_context['opts']['alembic_module_prefix'] or ''
|
||||
|
||||
def _user_defined_render(type_, object_, autogen_context):
|
||||
if 'opts' in autogen_context and \
|
||||
'render_item' in autogen_context['opts']:
|
||||
render = autogen_context['opts']['render_item']
|
||||
if render:
|
||||
rendered = render(type_, object_, autogen_context)
|
||||
if rendered is not False:
|
||||
return rendered
|
||||
return False
|
||||
|
||||
def _render_column(column, autogen_context):
|
||||
rendered = _user_defined_render("column", column, autogen_context)
|
||||
if rendered is not False:
|
||||
return rendered
|
||||
|
||||
opts = []
|
||||
if column.server_default:
|
||||
rendered = _render_server_default(
|
||||
column.server_default, autogen_context
|
||||
)
|
||||
if rendered:
|
||||
opts.append(("server_default", rendered))
|
||||
|
||||
if not column.autoincrement:
|
||||
opts.append(("autoincrement", column.autoincrement))
|
||||
|
||||
if column.nullable is not None:
|
||||
opts.append(("nullable", column.nullable))
|
||||
|
||||
# TODO: for non-ascii colname, assign a "key"
|
||||
return "%(prefix)sColumn(%(name)r, %(type)s, %(kw)s)" % {
|
||||
'prefix': _sqlalchemy_autogenerate_prefix(autogen_context),
|
||||
'name': column.name,
|
||||
'type': _repr_type(column.type, autogen_context),
|
||||
'kw': ", ".join(["%s=%s" % (kwname, val) for kwname, val in opts])
|
||||
}
|
||||
|
||||
def _render_server_default(default, autogen_context):
|
||||
rendered = _user_defined_render("server_default", default, autogen_context)
|
||||
if rendered is not False:
|
||||
return rendered
|
||||
|
||||
if isinstance(default, sa_schema.DefaultClause):
|
||||
if isinstance(default.arg, string_types):
|
||||
default = default.arg
|
||||
else:
|
||||
default = str(default.arg.compile(
|
||||
dialect=autogen_context['dialect']))
|
||||
if isinstance(default, string_types):
|
||||
# TODO: this is just a hack to get
|
||||
# tests to pass until we figure out
|
||||
# WTF sqlite is doing
|
||||
default = re.sub(r"^'|'$", "", default)
|
||||
return repr(default)
|
||||
else:
|
||||
return None
|
||||
|
||||
def _repr_type(type_, autogen_context):
|
||||
rendered = _user_defined_render("type", type_, autogen_context)
|
||||
if rendered is not False:
|
||||
return rendered
|
||||
|
||||
mod = type(type_).__module__
|
||||
imports = autogen_context.get('imports', None)
|
||||
if mod.startswith("sqlalchemy.dialects"):
|
||||
dname = re.match(r"sqlalchemy\.dialects\.(\w+)", mod).group(1)
|
||||
if imports is not None:
|
||||
imports.add("from sqlalchemy.dialects import %s" % dname)
|
||||
return "%s.%r" % (dname, type_)
|
||||
elif mod.startswith("sqlalchemy"):
|
||||
prefix = _sqlalchemy_autogenerate_prefix(autogen_context)
|
||||
return "%s%r" % (prefix, type_)
|
||||
else:
|
||||
prefix = _user_autogenerate_prefix(autogen_context)
|
||||
return "%s%r" % (prefix, type_)
|
||||
|
||||
def _render_constraint(constraint, autogen_context):
|
||||
renderer = _constraint_renderers.get(type(constraint), None)
|
||||
if renderer:
|
||||
return renderer(constraint, autogen_context)
|
||||
else:
|
||||
return None
|
||||
|
||||
def _render_primary_key(constraint, autogen_context):
|
||||
rendered = _user_defined_render("primary_key", constraint, autogen_context)
|
||||
if rendered is not False:
|
||||
return rendered
|
||||
|
||||
if not constraint.columns:
|
||||
return None
|
||||
|
||||
opts = []
|
||||
if constraint.name:
|
||||
opts.append(("name", repr(_render_gen_name(autogen_context, constraint.name))))
|
||||
return "%(prefix)sPrimaryKeyConstraint(%(args)s)" % {
|
||||
"prefix": _sqlalchemy_autogenerate_prefix(autogen_context),
|
||||
"args": ", ".join(
|
||||
[repr(c.key) for c in constraint.columns] +
|
||||
["%s=%s" % (kwname, val) for kwname, val in opts]
|
||||
),
|
||||
}
|
||||
|
||||
def _fk_colspec(fk, metadata_schema):
|
||||
"""Implement a 'safe' version of ForeignKey._get_colspec() that
|
||||
never tries to resolve the remote table.
|
||||
|
||||
"""
|
||||
if metadata_schema is None:
|
||||
return fk._get_colspec()
|
||||
else:
|
||||
# need to render schema breaking up tokens by hand, since the
|
||||
# ForeignKeyConstraint here may not actually have a remote
|
||||
# Table present
|
||||
tokens = fk._colspec.split(".")
|
||||
# no schema in the colspec, render it
|
||||
if len(tokens) == 2:
|
||||
return "%s.%s" % (metadata_schema, fk._colspec)
|
||||
else:
|
||||
return fk._colspec
|
||||
|
||||
def _render_foreign_key(constraint, autogen_context):
|
||||
rendered = _user_defined_render("foreign_key", constraint, autogen_context)
|
||||
if rendered is not False:
|
||||
return rendered
|
||||
|
||||
opts = []
|
||||
if constraint.name:
|
||||
opts.append(("name", repr(_render_gen_name(autogen_context, constraint.name))))
|
||||
if constraint.onupdate:
|
||||
opts.append(("onupdate", repr(constraint.onupdate)))
|
||||
if constraint.ondelete:
|
||||
opts.append(("ondelete", repr(constraint.ondelete)))
|
||||
if constraint.initially:
|
||||
opts.append(("initially", repr(constraint.initially)))
|
||||
if constraint.deferrable:
|
||||
opts.append(("deferrable", repr(constraint.deferrable)))
|
||||
if constraint.use_alter:
|
||||
opts.append(("use_alter", repr(constraint.use_alter)))
|
||||
|
||||
apply_metadata_schema = constraint.parent.metadata.schema
|
||||
return "%(prefix)sForeignKeyConstraint([%(cols)s], "\
|
||||
"[%(refcols)s], %(args)s)" % {
|
||||
"prefix": _sqlalchemy_autogenerate_prefix(autogen_context),
|
||||
"cols": ", ".join("'%s'" % f.parent.key for f in constraint.elements),
|
||||
"refcols": ", ".join(repr(_fk_colspec(f, apply_metadata_schema))
|
||||
for f in constraint.elements),
|
||||
"args": ", ".join(
|
||||
["%s=%s" % (kwname, val) for kwname, val in opts]
|
||||
),
|
||||
}
|
||||
|
||||
def _render_check_constraint(constraint, autogen_context):
|
||||
rendered = _user_defined_render("check", constraint, autogen_context)
|
||||
if rendered is not False:
|
||||
return rendered
|
||||
|
||||
# detect the constraint being part of
|
||||
# a parent type which is probably in the Table already.
|
||||
# ideally SQLAlchemy would give us more of a first class
|
||||
# way to detect this.
|
||||
if constraint._create_rule and \
|
||||
hasattr(constraint._create_rule, 'target') and \
|
||||
isinstance(constraint._create_rule.target,
|
||||
sqltypes.TypeEngine):
|
||||
return None
|
||||
opts = []
|
||||
if constraint.name:
|
||||
opts.append(("name", repr(_render_gen_name(autogen_context, constraint.name))))
|
||||
return "%(prefix)sCheckConstraint(%(sqltext)r%(opts)s)" % {
|
||||
"prefix": _sqlalchemy_autogenerate_prefix(autogen_context),
|
||||
"opts": ", " + (", ".join("%s=%s" % (k, v)
|
||||
for k, v in opts)) if opts else "",
|
||||
"sqltext": str(
|
||||
constraint.sqltext.compile(
|
||||
dialect=autogen_context['dialect']
|
||||
)
|
||||
)
|
||||
}
|
||||
|
||||
_constraint_renderers = {
|
||||
sa_schema.PrimaryKeyConstraint: _render_primary_key,
|
||||
sa_schema.ForeignKeyConstraint: _render_foreign_key,
|
||||
sa_schema.UniqueConstraint: _render_unique_constraint,
|
||||
sa_schema.CheckConstraint: _render_check_constraint
|
||||
}
|
||||
266
Linux_i686/lib/python2.7/site-packages/alembic/command.py
Normal file
266
Linux_i686/lib/python2.7/site-packages/alembic/command.py
Normal file
|
|
@ -0,0 +1,266 @@
|
|||
import os
|
||||
|
||||
from .script import ScriptDirectory
|
||||
from .environment import EnvironmentContext
|
||||
from . import util, autogenerate as autogen
|
||||
|
||||
def list_templates(config):
|
||||
"""List available templates"""
|
||||
|
||||
config.print_stdout("Available templates:\n")
|
||||
for tempname in os.listdir(config.get_template_directory()):
|
||||
with open(os.path.join(
|
||||
config.get_template_directory(),
|
||||
tempname,
|
||||
'README')) as readme:
|
||||
synopsis = next(readme)
|
||||
config.print_stdout("%s - %s", tempname, synopsis)
|
||||
|
||||
config.print_stdout("\nTemplates are used via the 'init' command, e.g.:")
|
||||
config.print_stdout("\n alembic init --template pylons ./scripts")
|
||||
|
||||
def init(config, directory, template='generic'):
|
||||
"""Initialize a new scripts directory."""
|
||||
|
||||
if os.access(directory, os.F_OK):
|
||||
raise util.CommandError("Directory %s already exists" % directory)
|
||||
|
||||
template_dir = os.path.join(config.get_template_directory(),
|
||||
template)
|
||||
if not os.access(template_dir, os.F_OK):
|
||||
raise util.CommandError("No such template %r" % template)
|
||||
|
||||
util.status("Creating directory %s" % os.path.abspath(directory),
|
||||
os.makedirs, directory)
|
||||
|
||||
versions = os.path.join(directory, 'versions')
|
||||
util.status("Creating directory %s" % os.path.abspath(versions),
|
||||
os.makedirs, versions)
|
||||
|
||||
script = ScriptDirectory(directory)
|
||||
|
||||
for file_ in os.listdir(template_dir):
|
||||
file_path = os.path.join(template_dir, file_)
|
||||
if file_ == 'alembic.ini.mako':
|
||||
config_file = os.path.abspath(config.config_file_name)
|
||||
if os.access(config_file, os.F_OK):
|
||||
util.msg("File %s already exists, skipping" % config_file)
|
||||
else:
|
||||
script._generate_template(
|
||||
file_path,
|
||||
config_file,
|
||||
script_location=directory
|
||||
)
|
||||
elif os.path.isfile(file_path):
|
||||
output_file = os.path.join(directory, file_)
|
||||
script._copy_file(
|
||||
file_path,
|
||||
output_file
|
||||
)
|
||||
|
||||
util.msg("Please edit configuration/connection/logging "\
|
||||
"settings in %r before proceeding." % config_file)
|
||||
|
||||
def revision(config, message=None, autogenerate=False, sql=False):
|
||||
"""Create a new revision file."""
|
||||
|
||||
script = ScriptDirectory.from_config(config)
|
||||
template_args = {
|
||||
'config': config # Let templates use config for
|
||||
# e.g. multiple databases
|
||||
}
|
||||
imports = set()
|
||||
|
||||
environment = util.asbool(
|
||||
config.get_main_option("revision_environment")
|
||||
)
|
||||
|
||||
if autogenerate:
|
||||
environment = True
|
||||
def retrieve_migrations(rev, context):
|
||||
if script.get_revision(rev) is not script.get_revision("head"):
|
||||
raise util.CommandError("Target database is not up to date.")
|
||||
autogen._produce_migration_diffs(context, template_args, imports)
|
||||
return []
|
||||
elif environment:
|
||||
def retrieve_migrations(rev, context):
|
||||
return []
|
||||
|
||||
if environment:
|
||||
with EnvironmentContext(
|
||||
config,
|
||||
script,
|
||||
fn=retrieve_migrations,
|
||||
as_sql=sql,
|
||||
template_args=template_args,
|
||||
):
|
||||
script.run_env()
|
||||
return script.generate_revision(util.rev_id(), message, refresh=True,
|
||||
**template_args)
|
||||
|
||||
|
||||
def upgrade(config, revision, sql=False, tag=None):
|
||||
"""Upgrade to a later version."""
|
||||
|
||||
script = ScriptDirectory.from_config(config)
|
||||
|
||||
starting_rev = None
|
||||
if ":" in revision:
|
||||
if not sql:
|
||||
raise util.CommandError("Range revision not allowed")
|
||||
starting_rev, revision = revision.split(':', 2)
|
||||
|
||||
def upgrade(rev, context):
|
||||
return script._upgrade_revs(revision, rev)
|
||||
|
||||
with EnvironmentContext(
|
||||
config,
|
||||
script,
|
||||
fn=upgrade,
|
||||
as_sql=sql,
|
||||
starting_rev=starting_rev,
|
||||
destination_rev=revision,
|
||||
tag=tag
|
||||
):
|
||||
script.run_env()
|
||||
|
||||
def downgrade(config, revision, sql=False, tag=None):
|
||||
"""Revert to a previous version."""
|
||||
|
||||
script = ScriptDirectory.from_config(config)
|
||||
starting_rev = None
|
||||
if ":" in revision:
|
||||
if not sql:
|
||||
raise util.CommandError("Range revision not allowed")
|
||||
starting_rev, revision = revision.split(':', 2)
|
||||
elif sql:
|
||||
raise util.CommandError("downgrade with --sql requires <fromrev>:<torev>")
|
||||
|
||||
def downgrade(rev, context):
|
||||
return script._downgrade_revs(revision, rev)
|
||||
|
||||
with EnvironmentContext(
|
||||
config,
|
||||
script,
|
||||
fn=downgrade,
|
||||
as_sql=sql,
|
||||
starting_rev=starting_rev,
|
||||
destination_rev=revision,
|
||||
tag=tag
|
||||
):
|
||||
script.run_env()
|
||||
|
||||
def history(config, rev_range=None):
|
||||
"""List changeset scripts in chronological order."""
|
||||
|
||||
script = ScriptDirectory.from_config(config)
|
||||
if rev_range is not None:
|
||||
if ":" not in rev_range:
|
||||
raise util.CommandError(
|
||||
"History range requires [start]:[end], "
|
||||
"[start]:, or :[end]")
|
||||
base, head = rev_range.strip().split(":")
|
||||
else:
|
||||
base = head = None
|
||||
|
||||
def _display_history(config, script, base, head):
|
||||
for sc in script.walk_revisions(
|
||||
base=base or "base",
|
||||
head=head or "head"):
|
||||
if sc.is_head:
|
||||
config.print_stdout("")
|
||||
config.print_stdout(sc.log_entry)
|
||||
|
||||
def _display_history_w_current(config, script, base=None, head=None):
|
||||
def _display_current_history(rev, context):
|
||||
if head is None:
|
||||
_display_history(config, script, base, rev)
|
||||
elif base is None:
|
||||
_display_history(config, script, rev, head)
|
||||
return []
|
||||
|
||||
with EnvironmentContext(
|
||||
config,
|
||||
script,
|
||||
fn=_display_current_history
|
||||
):
|
||||
script.run_env()
|
||||
|
||||
if base == "current":
|
||||
_display_history_w_current(config, script, head=head)
|
||||
elif head == "current":
|
||||
_display_history_w_current(config, script, base=base)
|
||||
else:
|
||||
_display_history(config, script, base, head)
|
||||
|
||||
|
||||
def branches(config):
|
||||
"""Show current un-spliced branch points"""
|
||||
script = ScriptDirectory.from_config(config)
|
||||
for sc in script.walk_revisions():
|
||||
if sc.is_branch_point:
|
||||
config.print_stdout(sc)
|
||||
for rev in sc.nextrev:
|
||||
config.print_stdout("%s -> %s",
|
||||
" " * len(str(sc.down_revision)),
|
||||
script.get_revision(rev)
|
||||
)
|
||||
|
||||
def current(config, head_only=False):
|
||||
"""Display the current revision for each database."""
|
||||
|
||||
script = ScriptDirectory.from_config(config)
|
||||
def display_version(rev, context):
|
||||
rev = script.get_revision(rev)
|
||||
|
||||
if head_only:
|
||||
config.print_stdout("%s%s" % (
|
||||
rev.revision if rev else None,
|
||||
" (head)" if rev and rev.is_head else ""))
|
||||
|
||||
else:
|
||||
config.print_stdout("Current revision for %s: %s",
|
||||
util.obfuscate_url_pw(
|
||||
context.connection.engine.url),
|
||||
rev)
|
||||
return []
|
||||
|
||||
with EnvironmentContext(
|
||||
config,
|
||||
script,
|
||||
fn=display_version
|
||||
):
|
||||
script.run_env()
|
||||
|
||||
def stamp(config, revision, sql=False, tag=None):
|
||||
"""'stamp' the revision table with the given revision; don't
|
||||
run any migrations."""
|
||||
|
||||
script = ScriptDirectory.from_config(config)
|
||||
def do_stamp(rev, context):
|
||||
if sql:
|
||||
current = False
|
||||
else:
|
||||
current = context._current_rev()
|
||||
dest = script.get_revision(revision)
|
||||
if dest is not None:
|
||||
dest = dest.revision
|
||||
context._update_current_rev(current, dest)
|
||||
return []
|
||||
with EnvironmentContext(
|
||||
config,
|
||||
script,
|
||||
fn=do_stamp,
|
||||
as_sql=sql,
|
||||
destination_rev=revision,
|
||||
tag=tag
|
||||
):
|
||||
script.run_env()
|
||||
|
||||
def splice(config, parent, child):
|
||||
"""'splice' two branches, creating a new revision file.
|
||||
|
||||
this command isn't implemented right now.
|
||||
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
130
Linux_i686/lib/python2.7/site-packages/alembic/compat.py
Normal file
130
Linux_i686/lib/python2.7/site-packages/alembic/compat.py
Normal file
|
|
@ -0,0 +1,130 @@
|
|||
import io
|
||||
import sys
|
||||
from sqlalchemy import __version__ as sa_version
|
||||
|
||||
if sys.version_info < (2, 6):
|
||||
raise NotImplementedError("Python 2.6 or greater is required.")
|
||||
|
||||
sqla_08 = sa_version >= '0.8.0'
|
||||
sqla_09 = sa_version >= '0.9.0'
|
||||
|
||||
py2k = sys.version_info < (3, 0)
|
||||
py3k = sys.version_info >= (3, 0)
|
||||
py33 = sys.version_info >= (3, 3)
|
||||
|
||||
if py3k:
|
||||
import builtins as compat_builtins
|
||||
string_types = str,
|
||||
binary_type = bytes
|
||||
text_type = str
|
||||
def callable(fn):
|
||||
return hasattr(fn, '__call__')
|
||||
|
||||
def u(s):
|
||||
return s
|
||||
|
||||
else:
|
||||
import __builtin__ as compat_builtins
|
||||
string_types = basestring,
|
||||
binary_type = str
|
||||
text_type = unicode
|
||||
callable = callable
|
||||
|
||||
def u(s):
|
||||
return unicode(s, "utf-8")
|
||||
|
||||
if py3k:
|
||||
from configparser import ConfigParser as SafeConfigParser
|
||||
import configparser
|
||||
else:
|
||||
from ConfigParser import SafeConfigParser
|
||||
import ConfigParser as configparser
|
||||
|
||||
if py2k:
|
||||
from mako.util import parse_encoding
|
||||
|
||||
if py33:
|
||||
from importlib import machinery
|
||||
def load_module_py(module_id, path):
|
||||
return machinery.SourceFileLoader(module_id, path).load_module(module_id)
|
||||
|
||||
def load_module_pyc(module_id, path):
|
||||
return machinery.SourcelessFileLoader(module_id, path).load_module(module_id)
|
||||
|
||||
else:
|
||||
import imp
|
||||
def load_module_py(module_id, path):
|
||||
with open(path, 'rb') as fp:
|
||||
mod = imp.load_source(module_id, path, fp)
|
||||
if py2k:
|
||||
source_encoding = parse_encoding(fp)
|
||||
if source_encoding:
|
||||
mod._alembic_source_encoding = source_encoding
|
||||
return mod
|
||||
|
||||
def load_module_pyc(module_id, path):
|
||||
with open(path, 'rb') as fp:
|
||||
mod = imp.load_compiled(module_id, path, fp)
|
||||
# no source encoding here
|
||||
return mod
|
||||
|
||||
try:
|
||||
exec_ = getattr(compat_builtins, 'exec')
|
||||
except AttributeError:
|
||||
# Python 2
|
||||
def exec_(func_text, globals_, lcl):
|
||||
exec('exec func_text in globals_, lcl')
|
||||
|
||||
################################################
|
||||
# cross-compatible metaclass implementation
|
||||
# Copyright (c) 2010-2012 Benjamin Peterson
|
||||
def with_metaclass(meta, base=object):
|
||||
"""Create a base class with a metaclass."""
|
||||
return meta("%sBase" % meta.__name__, (base,), {})
|
||||
################################################
|
||||
|
||||
|
||||
# produce a wrapper that allows encoded text to stream
|
||||
# into a given buffer, but doesn't close it.
|
||||
# not sure of a more idiomatic approach to this.
|
||||
class EncodedIO(io.TextIOWrapper):
|
||||
def close(self):
|
||||
pass
|
||||
|
||||
if py2k:
|
||||
# in Py2K, the io.* package is awkward because it does not
|
||||
# easily wrap the file type (e.g. sys.stdout) and I can't
|
||||
# figure out at all how to wrap StringIO.StringIO (used by nosetests)
|
||||
# and also might be user specified too. So create a full
|
||||
# adapter.
|
||||
|
||||
class ActLikePy3kIO(object):
|
||||
"""Produce an object capable of wrapping either
|
||||
sys.stdout (e.g. file) *or* StringIO.StringIO().
|
||||
|
||||
"""
|
||||
def _false(self):
|
||||
return False
|
||||
|
||||
def _true(self):
|
||||
return True
|
||||
|
||||
readable = seekable = _false
|
||||
writable = _true
|
||||
closed = False
|
||||
|
||||
def __init__(self, file_):
|
||||
self.file_ = file_
|
||||
|
||||
def write(self, text):
|
||||
return self.file_.write(text)
|
||||
|
||||
def flush(self):
|
||||
return self.file_.flush()
|
||||
|
||||
class EncodedIO(EncodedIO):
|
||||
def __init__(self, file_, encoding):
|
||||
super(EncodedIO, self).__init__(
|
||||
ActLikePy3kIO(file_), encoding=encoding)
|
||||
|
||||
|
||||
301
Linux_i686/lib/python2.7/site-packages/alembic/config.py
Normal file
301
Linux_i686/lib/python2.7/site-packages/alembic/config.py
Normal file
|
|
@ -0,0 +1,301 @@
|
|||
from argparse import ArgumentParser
|
||||
from .compat import SafeConfigParser
|
||||
import inspect
|
||||
import os
|
||||
import sys
|
||||
|
||||
from . import command, util, package_dir, compat
|
||||
|
||||
class Config(object):
|
||||
"""Represent an Alembic configuration.
|
||||
|
||||
Within an ``env.py`` script, this is available
|
||||
via the :attr:`.EnvironmentContext.config` attribute,
|
||||
which in turn is available at ``alembic.context``::
|
||||
|
||||
from alembic import context
|
||||
|
||||
some_param = context.config.get_main_option("my option")
|
||||
|
||||
When invoking Alembic programatically, a new
|
||||
:class:`.Config` can be created by passing
|
||||
the name of an .ini file to the constructor::
|
||||
|
||||
from alembic.config import Config
|
||||
alembic_cfg = Config("/path/to/yourapp/alembic.ini")
|
||||
|
||||
With a :class:`.Config` object, you can then
|
||||
run Alembic commands programmatically using the directives
|
||||
in :mod:`alembic.command`.
|
||||
|
||||
The :class:`.Config` object can also be constructed without
|
||||
a filename. Values can be set programmatically, and
|
||||
new sections will be created as needed::
|
||||
|
||||
from alembic.config import Config
|
||||
alembic_cfg = Config()
|
||||
alembic_cfg.set_main_option("script_location", "myapp:migrations")
|
||||
alembic_cfg.set_main_option("url", "postgresql://foo/bar")
|
||||
alembic_cfg.set_section_option("mysection", "foo", "bar")
|
||||
|
||||
:param file_: name of the .ini file to open.
|
||||
:param ini_section: name of the main Alembic section within the
|
||||
.ini file
|
||||
:param output_buffer: optional file-like input buffer which
|
||||
will be passed to the :class:`.MigrationContext` - used to redirect
|
||||
the output of "offline generation" when using Alembic programmatically.
|
||||
:param stdout: buffer where the "print" output of commands will be sent.
|
||||
Defaults to ``sys.stdout``.
|
||||
|
||||
..versionadded:: 0.4
|
||||
|
||||
"""
|
||||
def __init__(self, file_=None, ini_section='alembic', output_buffer=None,
|
||||
stdout=sys.stdout, cmd_opts=None):
|
||||
"""Construct a new :class:`.Config`
|
||||
|
||||
"""
|
||||
self.config_file_name = file_
|
||||
self.config_ini_section = ini_section
|
||||
self.output_buffer = output_buffer
|
||||
self.stdout = stdout
|
||||
self.cmd_opts = cmd_opts
|
||||
|
||||
cmd_opts = None
|
||||
"""The command-line options passed to the ``alembic`` script.
|
||||
|
||||
Within an ``env.py`` script this can be accessed via the
|
||||
:attr:`.EnvironmentContext.config` attribute.
|
||||
|
||||
.. versionadded:: 0.6.0
|
||||
|
||||
.. seealso::
|
||||
|
||||
:meth:`.EnvironmentContext.get_x_argument`
|
||||
|
||||
"""
|
||||
|
||||
config_file_name = None
|
||||
"""Filesystem path to the .ini file in use."""
|
||||
|
||||
config_ini_section = None
|
||||
"""Name of the config file section to read basic configuration
|
||||
from. Defaults to ``alembic``, that is the ``[alembic]`` section
|
||||
of the .ini file. This value is modified using the ``-n/--name``
|
||||
option to the Alembic runnier.
|
||||
|
||||
"""
|
||||
|
||||
def print_stdout(self, text, *arg):
|
||||
"""Render a message to standard out."""
|
||||
|
||||
util.write_outstream(
|
||||
self.stdout,
|
||||
(compat.text_type(text) % arg),
|
||||
"\n"
|
||||
)
|
||||
|
||||
@util.memoized_property
|
||||
def file_config(self):
|
||||
"""Return the underlying :class:`ConfigParser` object.
|
||||
|
||||
Direct access to the .ini file is available here,
|
||||
though the :meth:`.Config.get_section` and
|
||||
:meth:`.Config.get_main_option`
|
||||
methods provide a possibly simpler interface.
|
||||
|
||||
"""
|
||||
|
||||
if self.config_file_name:
|
||||
here = os.path.abspath(os.path.dirname(self.config_file_name))
|
||||
else:
|
||||
here = ""
|
||||
file_config = SafeConfigParser({'here': here})
|
||||
if self.config_file_name:
|
||||
file_config.read([self.config_file_name])
|
||||
else:
|
||||
file_config.add_section(self.config_ini_section)
|
||||
return file_config
|
||||
|
||||
def get_template_directory(self):
|
||||
"""Return the directory where Alembic setup templates are found.
|
||||
|
||||
This method is used by the alembic ``init`` and ``list_templates``
|
||||
commands.
|
||||
|
||||
"""
|
||||
return os.path.join(package_dir, 'templates')
|
||||
|
||||
def get_section(self, name):
|
||||
"""Return all the configuration options from a given .ini file section
|
||||
as a dictionary.
|
||||
|
||||
"""
|
||||
return dict(self.file_config.items(name))
|
||||
|
||||
def set_main_option(self, name, value):
|
||||
"""Set an option programmatically within the 'main' section.
|
||||
|
||||
This overrides whatever was in the .ini file.
|
||||
|
||||
"""
|
||||
self.file_config.set(self.config_ini_section, name, value)
|
||||
|
||||
def remove_main_option(self, name):
|
||||
self.file_config.remove_option(self.config_ini_section, name)
|
||||
|
||||
def set_section_option(self, section, name, value):
|
||||
"""Set an option programmatically within the given section.
|
||||
|
||||
The section is created if it doesn't exist already.
|
||||
The value here will override whatever was in the .ini
|
||||
file.
|
||||
|
||||
"""
|
||||
if not self.file_config.has_section(section):
|
||||
self.file_config.add_section(section)
|
||||
self.file_config.set(section, name, value)
|
||||
|
||||
def get_section_option(self, section, name, default=None):
|
||||
"""Return an option from the given section of the .ini file.
|
||||
|
||||
"""
|
||||
if not self.file_config.has_section(section):
|
||||
raise util.CommandError("No config file %r found, or file has no "
|
||||
"'[%s]' section" %
|
||||
(self.config_file_name, section))
|
||||
if self.file_config.has_option(section, name):
|
||||
return self.file_config.get(section, name)
|
||||
else:
|
||||
return default
|
||||
|
||||
def get_main_option(self, name, default=None):
|
||||
"""Return an option from the 'main' section of the .ini file.
|
||||
|
||||
This defaults to being a key from the ``[alembic]``
|
||||
section, unless the ``-n/--name`` flag were used to
|
||||
indicate a different section.
|
||||
|
||||
"""
|
||||
return self.get_section_option(self.config_ini_section, name, default)
|
||||
|
||||
|
||||
class CommandLine(object):
|
||||
def __init__(self, prog=None):
|
||||
self._generate_args(prog)
|
||||
|
||||
|
||||
def _generate_args(self, prog):
|
||||
def add_options(parser, positional, kwargs):
|
||||
if 'template' in kwargs:
|
||||
parser.add_argument("-t", "--template",
|
||||
default='generic',
|
||||
type=str,
|
||||
help="Setup template for use with 'init'")
|
||||
if 'message' in kwargs:
|
||||
parser.add_argument("-m", "--message",
|
||||
type=str,
|
||||
help="Message string to use with 'revision'")
|
||||
if 'sql' in kwargs:
|
||||
parser.add_argument("--sql",
|
||||
action="store_true",
|
||||
help="Don't emit SQL to database - dump to "
|
||||
"standard output/file instead")
|
||||
if 'tag' in kwargs:
|
||||
parser.add_argument("--tag",
|
||||
type=str,
|
||||
help="Arbitrary 'tag' name - can be used by "
|
||||
"custom env.py scripts.")
|
||||
if 'autogenerate' in kwargs:
|
||||
parser.add_argument("--autogenerate",
|
||||
action="store_true",
|
||||
help="Populate revision script with candidate "
|
||||
"migration operations, based on comparison "
|
||||
"of database to model.")
|
||||
# "current" command
|
||||
if 'head_only' in kwargs:
|
||||
parser.add_argument("--head-only",
|
||||
action="store_true",
|
||||
help="Only show current version and "
|
||||
"whether or not this is the head revision.")
|
||||
|
||||
if 'rev_range' in kwargs:
|
||||
parser.add_argument("-r", "--rev-range",
|
||||
action="store",
|
||||
help="Specify a revision range; "
|
||||
"format is [start]:[end]")
|
||||
|
||||
|
||||
positional_help = {
|
||||
'directory': "location of scripts directory",
|
||||
'revision': "revision identifier"
|
||||
}
|
||||
for arg in positional:
|
||||
subparser.add_argument(arg, help=positional_help.get(arg))
|
||||
|
||||
parser = ArgumentParser(prog=prog)
|
||||
parser.add_argument("-c", "--config",
|
||||
type=str,
|
||||
default="alembic.ini",
|
||||
help="Alternate config file")
|
||||
parser.add_argument("-n", "--name",
|
||||
type=str,
|
||||
default="alembic",
|
||||
help="Name of section in .ini file to "
|
||||
"use for Alembic config")
|
||||
parser.add_argument("-x", action="append",
|
||||
help="Additional arguments consumed by "
|
||||
"custom env.py scripts, e.g. -x "
|
||||
"setting1=somesetting -x setting2=somesetting")
|
||||
|
||||
subparsers = parser.add_subparsers()
|
||||
|
||||
for fn in [getattr(command, n) for n in dir(command)]:
|
||||
if inspect.isfunction(fn) and \
|
||||
fn.__name__[0] != '_' and \
|
||||
fn.__module__ == 'alembic.command':
|
||||
|
||||
spec = inspect.getargspec(fn)
|
||||
if spec[3]:
|
||||
positional = spec[0][1:-len(spec[3])]
|
||||
kwarg = spec[0][-len(spec[3]):]
|
||||
else:
|
||||
positional = spec[0][1:]
|
||||
kwarg = []
|
||||
|
||||
subparser = subparsers.add_parser(
|
||||
fn.__name__,
|
||||
help=fn.__doc__)
|
||||
add_options(subparser, positional, kwarg)
|
||||
subparser.set_defaults(cmd=(fn, positional, kwarg))
|
||||
self.parser = parser
|
||||
|
||||
def run_cmd(self, config, options):
|
||||
fn, positional, kwarg = options.cmd
|
||||
|
||||
try:
|
||||
fn(config,
|
||||
*[getattr(options, k) for k in positional],
|
||||
**dict((k, getattr(options, k)) for k in kwarg)
|
||||
)
|
||||
except util.CommandError as e:
|
||||
util.err(str(e))
|
||||
|
||||
def main(self, argv=None):
|
||||
options = self.parser.parse_args(argv)
|
||||
if not hasattr(options, "cmd"):
|
||||
# see http://bugs.python.org/issue9253, argparse
|
||||
# behavior changed incompatibly in py3.3
|
||||
self.parser.error("too few arguments")
|
||||
else:
|
||||
cfg = Config(file_=options.config,
|
||||
ini_section=options.name, cmd_opts=options)
|
||||
self.run_cmd(cfg, options)
|
||||
|
||||
def main(argv=None, prog=None, **kwargs):
|
||||
"""The console runner function for Alembic."""
|
||||
|
||||
CommandLine(prog=prog).main(argv=argv)
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
from .environment import EnvironmentContext
|
||||
from . import util
|
||||
|
||||
# create proxy functions for
|
||||
# each method on the EnvironmentContext class.
|
||||
util.create_module_class_proxy(EnvironmentContext, globals(), locals())
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
from . import postgresql, mysql, sqlite, mssql, oracle
|
||||
from .impl import DefaultImpl
|
||||
161
Linux_i686/lib/python2.7/site-packages/alembic/ddl/base.py
Normal file
161
Linux_i686/lib/python2.7/site-packages/alembic/ddl/base.py
Normal file
|
|
@ -0,0 +1,161 @@
|
|||
import functools
|
||||
|
||||
from sqlalchemy.ext.compiler import compiles
|
||||
from sqlalchemy.schema import DDLElement, Column
|
||||
from sqlalchemy import Integer
|
||||
from sqlalchemy import types as sqltypes
|
||||
|
||||
class AlterTable(DDLElement):
|
||||
"""Represent an ALTER TABLE statement.
|
||||
|
||||
Only the string name and optional schema name of the table
|
||||
is required, not a full Table object.
|
||||
|
||||
"""
|
||||
def __init__(self, table_name, schema=None):
|
||||
self.table_name = table_name
|
||||
self.schema = schema
|
||||
|
||||
class RenameTable(AlterTable):
|
||||
def __init__(self, old_table_name, new_table_name, schema=None):
|
||||
super(RenameTable, self).__init__(old_table_name, schema=schema)
|
||||
self.new_table_name = new_table_name
|
||||
|
||||
class AlterColumn(AlterTable):
|
||||
def __init__(self, name, column_name, schema=None,
|
||||
existing_type=None,
|
||||
existing_nullable=None,
|
||||
existing_server_default=None):
|
||||
super(AlterColumn, self).__init__(name, schema=schema)
|
||||
self.column_name = column_name
|
||||
self.existing_type=sqltypes.to_instance(existing_type) \
|
||||
if existing_type is not None else None
|
||||
self.existing_nullable=existing_nullable
|
||||
self.existing_server_default=existing_server_default
|
||||
|
||||
class ColumnNullable(AlterColumn):
|
||||
def __init__(self, name, column_name, nullable, **kw):
|
||||
super(ColumnNullable, self).__init__(name, column_name,
|
||||
**kw)
|
||||
self.nullable = nullable
|
||||
|
||||
class ColumnType(AlterColumn):
|
||||
def __init__(self, name, column_name, type_, **kw):
|
||||
super(ColumnType, self).__init__(name, column_name,
|
||||
**kw)
|
||||
self.type_ = sqltypes.to_instance(type_)
|
||||
|
||||
class ColumnName(AlterColumn):
|
||||
def __init__(self, name, column_name, newname, **kw):
|
||||
super(ColumnName, self).__init__(name, column_name, **kw)
|
||||
self.newname = newname
|
||||
|
||||
class ColumnDefault(AlterColumn):
|
||||
def __init__(self, name, column_name, default, **kw):
|
||||
super(ColumnDefault, self).__init__(name, column_name, **kw)
|
||||
self.default = default
|
||||
|
||||
class AddColumn(AlterTable):
|
||||
def __init__(self, name, column, schema=None):
|
||||
super(AddColumn, self).__init__(name, schema=schema)
|
||||
self.column = column
|
||||
|
||||
class DropColumn(AlterTable):
|
||||
def __init__(self, name, column, schema=None):
|
||||
super(DropColumn, self).__init__(name, schema=schema)
|
||||
self.column = column
|
||||
|
||||
|
||||
@compiles(RenameTable)
|
||||
def visit_rename_table(element, compiler, **kw):
|
||||
return "%s RENAME TO %s" % (
|
||||
alter_table(compiler, element.table_name, element.schema),
|
||||
format_table_name(compiler, element.new_table_name, element.schema)
|
||||
)
|
||||
|
||||
@compiles(AddColumn)
|
||||
def visit_add_column(element, compiler, **kw):
|
||||
return "%s %s" % (
|
||||
alter_table(compiler, element.table_name, element.schema),
|
||||
add_column(compiler, element.column, **kw)
|
||||
)
|
||||
|
||||
@compiles(DropColumn)
|
||||
def visit_drop_column(element, compiler, **kw):
|
||||
return "%s %s" % (
|
||||
alter_table(compiler, element.table_name, element.schema),
|
||||
drop_column(compiler, element.column.name, **kw)
|
||||
)
|
||||
|
||||
@compiles(ColumnNullable)
|
||||
def visit_column_nullable(element, compiler, **kw):
|
||||
return "%s %s %s" % (
|
||||
alter_table(compiler, element.table_name, element.schema),
|
||||
alter_column(compiler, element.column_name),
|
||||
"DROP NOT NULL" if element.nullable else "SET NOT NULL"
|
||||
)
|
||||
|
||||
@compiles(ColumnType)
|
||||
def visit_column_type(element, compiler, **kw):
|
||||
return "%s %s %s" % (
|
||||
alter_table(compiler, element.table_name, element.schema),
|
||||
alter_column(compiler, element.column_name),
|
||||
"TYPE %s" % format_type(compiler, element.type_)
|
||||
)
|
||||
|
||||
@compiles(ColumnName)
|
||||
def visit_column_name(element, compiler, **kw):
|
||||
return "%s RENAME %s TO %s" % (
|
||||
alter_table(compiler, element.table_name, element.schema),
|
||||
format_column_name(compiler, element.column_name),
|
||||
format_column_name(compiler, element.newname)
|
||||
)
|
||||
|
||||
@compiles(ColumnDefault)
|
||||
def visit_column_default(element, compiler, **kw):
|
||||
return "%s %s %s" % (
|
||||
alter_table(compiler, element.table_name, element.schema),
|
||||
alter_column(compiler, element.column_name),
|
||||
"SET DEFAULT %s" %
|
||||
format_server_default(compiler, element.default)
|
||||
if element.default is not None
|
||||
else "DROP DEFAULT"
|
||||
)
|
||||
|
||||
def quote_dotted(name, quote):
|
||||
"""quote the elements of a dotted name"""
|
||||
|
||||
result = '.'.join([quote(x) for x in name.split('.')])
|
||||
return result
|
||||
|
||||
def format_table_name(compiler, name, schema):
|
||||
quote = functools.partial(compiler.preparer.quote, force=None)
|
||||
if schema:
|
||||
return quote_dotted(schema, quote) + "." + quote(name)
|
||||
else:
|
||||
return quote(name)
|
||||
|
||||
def format_column_name(compiler, name):
|
||||
return compiler.preparer.quote(name, None)
|
||||
|
||||
def format_server_default(compiler, default):
|
||||
return compiler.get_column_default_string(
|
||||
Column("x", Integer, server_default=default)
|
||||
)
|
||||
|
||||
def format_type(compiler, type_):
|
||||
return compiler.dialect.type_compiler.process(type_)
|
||||
|
||||
def alter_table(compiler, name, schema):
|
||||
return "ALTER TABLE %s" % format_table_name(compiler, name, schema)
|
||||
|
||||
def drop_column(compiler, name):
|
||||
return 'DROP COLUMN %s' % format_column_name(compiler, name)
|
||||
|
||||
def alter_column(compiler, name):
|
||||
return 'ALTER COLUMN %s' % format_column_name(compiler, name)
|
||||
|
||||
def add_column(compiler, column, **kw):
|
||||
return "ADD COLUMN %s" % compiler.get_column_specification(column, **kw)
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue