Skip to content

Fix #529 1 "This Session's transaction has been rolled back"#530

Merged
mistercrunch merged 2 commits into
apache:masterfrom
shopkick:fix529-1
Jun 1, 2016
Merged

Fix #529 1 "This Session's transaction has been rolled back"#530
mistercrunch merged 2 commits into
apache:masterfrom
shopkick:fix529-1

Conversation

@LAlbertalli

Copy link
Copy Markdown
Contributor

Fix one of the issues found in #529

Background:

  • When an object is modified by SQLAlchemy, it is invalidated so need to be fetched again from the DB
  • If there's an exception during a transaction, SQLAlchemy performs a rollback and mark the connection as dirty.

Bug:

  • When handling exceptions, the exception handler tries to access the name of the cluster in the main object. Since the name has been invalidated due to a write, SQLAlchemy tries to fetch it on a 'dirty' connection and spits out an error.
    Solution:
  • Fetch the information for handling the exception before starting the process.

@landscape-bot

Copy link
Copy Markdown

Code Health
Repository health decreased by 0.03% when pulling 072a09e on LAlbertalli:fix529-1 into 7d27692 on airbnb:master.

@coveralls

coveralls commented May 27, 2016

Copy link
Copy Markdown

Coverage Status

Coverage decreased (-0.06%) to 82.108% when pulling 072a09ec88ce7991de228d75a80f191f07ca16c3 on LAlbertalli:fix529-1 into 7d27692 on airbnb:master.

@xrmx

xrmx commented May 28, 2016

Copy link
Copy Markdown
Contributor

@LAlbertalli it would be cool to have all the description you write in pull requests in the git commit messages too :)

Background:
- When an object is modified by SQLAlchemy, it is invalidated so need to be fetched again from the DB
- If there's an exception during a transaction, SQLAlchemy performs a rollback and mark the connection as dirty.

Bug:
- When handling exceptions, the exception handler tries to access the name of the cluster in the main object. Since the name has been invalidated due to a write, SQLAlchemy tries to fetch it on a 'dirty' connection and spits out an error. Solution:
- Fetch the information for handling the exception before starting the process.
@LAlbertalli

Copy link
Copy Markdown
Contributor Author

@xrmx Git Amended the commit message to insert the description of the error

@coveralls

coveralls commented May 29, 2016

Copy link
Copy Markdown

Coverage Status

Coverage decreased (-0.06%) to 82.108% when pulling 4e98617 on LAlbertalli:fix529-1 into 7d27692 on airbnb:master.

@mistercrunch mistercrunch changed the title Fix529 1 Fix #529 1 "This Session's transaction has been rolled back" Jun 1, 2016
@mistercrunch

Copy link
Copy Markdown
Member

img

@mistercrunch mistercrunch merged commit 087c47a into apache:master Jun 1, 2016
mistercrunch pushed a commit that referenced this pull request Jun 2, 2016
* Created migration to fix the bug

* Working also on MySQL

* Added support for Vertica Grains (#515)

* Fix #529 1 "This Session's transaction has been rolled back" (#530)

* Fixing the specific issue

* Added an additional fix for a similar error in #529

Background:
- When an object is modified by SQLAlchemy, it is invalidated so need to be fetched again from the DB
- If there's an exception during a transaction, SQLAlchemy performs a rollback and mark the connection as dirty.

Bug:
- When handling exceptions, the exception handler tries to access the name of the cluster in the main object. Since the name has been invalidated due to a write, SQLAlchemy tries to fetch it on a 'dirty' connection and spits out an error. Solution:
- Fetch the information for handling the exception before starting the process.

* Modified the migration function to to automatically detect the the foreign keys based on the signature.
It supports also sqlite using batch migrations

* i18n: Fix typo in Druid cluster broker port label (#512)

* Update models.py (#541)

removing duplicated `user_id` def
zhaoyongjie pushed a commit to zhaoyongjie/incubator-superset that referenced this pull request Nov 17, 2021
…#530)

Bumps [@storybook/addon-info](https://github.com/storybookjs/storybook/tree/HEAD/addons/info) from 5.3.18 to 5.3.19.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v5.3.19/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v5.3.19/addons/info)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
zhaoyongjie pushed a commit to zhaoyongjie/incubator-superset that referenced this pull request Nov 24, 2021
…#530)

Bumps [@storybook/addon-info](https://github.com/storybookjs/storybook/tree/HEAD/addons/info) from 5.3.18 to 5.3.19.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v5.3.19/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v5.3.19/addons/info)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
zhaoyongjie pushed a commit to zhaoyongjie/incubator-superset that referenced this pull request Nov 25, 2021
…#530)

Bumps [@storybook/addon-info](https://github.com/storybookjs/storybook/tree/HEAD/addons/info) from 5.3.18 to 5.3.19.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v5.3.19/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v5.3.19/addons/info)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
zhaoyongjie pushed a commit to zhaoyongjie/incubator-superset that referenced this pull request Nov 26, 2021
…#530)

Bumps [@storybook/addon-info](https://github.com/storybookjs/storybook/tree/HEAD/addons/info) from 5.3.18 to 5.3.19.
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/v5.3.19/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v5.3.19/addons/info)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.5.0 First shipped in 1.5.0 labels Feb 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.5.0 First shipped in 1.5.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants