Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DeprecationWarning: generator 'RevisionMap._iterate_revisions' raised StopIteration (PEP 479) #458

Closed
sqlalchemy-bot opened this issue Oct 11, 2017 · 3 comments
Labels
bug Something isn't working low priority

Comments

@sqlalchemy-bot
Copy link

Migrated issue, originally created by Christopher Sang (@csang)

Run a downgrade on an initially empty db, using a command like:

python -Wall `which alembic` downgrade base

The following DeprecationWarning occurs:

/usr/local/lib/python3.6/site-packages/alembic/script/base.py:348: DeprecationWarning: generator 'RevisionMap._iterate_revisions' raised StopIteration
    migration.MigrationStep.downgrade_from_script(

Environment:

  • alembic 0.9.5
  • python 3.6.2
  • postgresql 9.6.5 (probably does not make a difference)
  • psycopg2 2.7.3.1

See https://www.python.org/dev/peps/pep-0479/

@sqlalchemy-bot
Copy link
Author

Michael Bayer (@zzzeek) wrote:

https://gerrit.sqlalchemy.org/573

@sqlalchemy-bot
Copy link
Author

Michael Bayer (@zzzeek) wrote:

Clean up all Python 3.6 warnings

Fixed a few Python3.6 deprecation warnings by replacing StopIteration
with return, as well as using getfullargspec() instead of
getargspec() under Python 3.

Additionally fixed docstrings with backslashes needing r'', filehandles
not explicitly closed, accommodate for .pyc files not necessarily present.

Change-Id: Id9791c5fa8b4b1f3e4e36f237a8a8ebcef4aaaba
Fixes: #458

6c29346

@sqlalchemy-bot
Copy link
Author

Changes by Michael Bayer (@zzzeek):

  • changed status to closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working low priority
Projects
None yet
Development

No branches or pull requests

1 participant