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

reset_database only drops trulens tables #1676

Merged
merged 4 commits into from
Dec 4, 2024
Merged

Conversation

sfc-gh-chu
Copy link
Contributor

@sfc-gh-chu sfc-gh-chu commented Dec 4, 2024

Description

reset_database() would previously drop all tables in a given database/schema. This fix would only drop trulens-related tables

Other details good to know for developers

Please include any other details of this change useful for TruLens developers.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to
    not work as expected)
  • New Tests
  • This change includes re-generated golden test results
  • This change requires a documentation update

Important

reset_database() in sqlalchemy.py now drops only trulens-related tables, enhancing data safety.

  • Behavior:
    • reset_database() in sqlalchemy.py now drops only trulens-related tables instead of all tables in the database.
    • Collects tables from self.orm.registry and drops them using meta.drop_all.
  • Misc:
    • Removed commented-out code in reset_database() method.

This description was created by Ellipsis for e770f15. It will automatically update as commits are pushed.

@dosubot dosubot bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Dec 4, 2024
@sfc-gh-chu sfc-gh-chu merged commit 27d55cf into main Dec 4, 2024
9 of 10 checks passed
@sfc-gh-chu sfc-gh-chu deleted the corey/drop-select-tables branch December 4, 2024 02:31
@sfc-gh-chu sfc-gh-chu mentioned this pull request Dec 5, 2024
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants