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

configure() explodes #403

Closed
revmischa opened this issue Jun 14, 2016 · 6 comments
Closed

configure() explodes #403

revmischa opened this issue Jun 14, 2016 · 6 comments

Comments

@revmischa
Copy link

Calling db.session.configure(expire_on_commit=True) in the latest version in git blows up:

self = <sqlalchemy.orm.scoping.scoped_session object at 0x10c1c1190>
kwargs = {'expire_on_commit': True}

    def configure(self, **kwargs):
        """reconfigure the :class:`.sessionmaker` used by this
            :class:`.scoped_session`.

            See :meth:`.sessionmaker.configure`.

            """

        if self.registry.has():
            warn('At least one scoped session is already present. '
                 ' configure() can not affect sessions that have '
                 'already been created.')

>       self.session_factory.configure(**kwargs)
E       AttributeError: 'functools.partial' object has no attribute 'configure'

../../.virtualenvs/jb/lib/python2.7/site-packages/sqlalchemy/orm/scoping.py:110: AttributeError
@GregEremeev
Copy link

GregEremeev commented Oct 7, 2016

I've found this bug too.
I need ability to configure scoped_session after instantiated it.

Fix for this bug contains in master branch but package from pypi has 2015-10-23 date.

@GregEremeev
Copy link

Please, update PYPI and close this issue.

@rduplain
Copy link

I am looking into making a new release. The project is currently set to 3.0-dev, but this would be a 2.2 release, as the only changes I see are fixes and clarifications. @mitsuhiko +1?

@davidism
Copy link
Member

I haven't had time to review the current state of the repo in a while, but as long as all the tests are passing and the changelog is updated then we should be fine.

@rduplain
Copy link

All tests are passing.
https://travis-ci.org/mitsuhiko/flask-sqlalchemy/builds/164926471

The plan is to review the CHANGES file, update references from 3.0 to 2.2, then cut a 2.2 release against what is currently in master.

@rsyring
Copy link
Contributor

rsyring commented Mar 8, 2019

Release 2.3 is out. I'm assuming, since the fix was in master, that this issue has therefore been resolved. If not, feel free to correct me and I'll re-open this issue.

@rsyring rsyring closed this as completed Mar 8, 2019
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 5, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

5 participants