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

Get table name directly #35724

Merged
merged 1 commit into from
Feb 21, 2025
Merged

Get table name directly #35724

merged 1 commit into from
Feb 21, 2025

Conversation

mkangia
Copy link
Contributor

@mkangia mkangia commented Feb 1, 2025

Product Description

No visible change to users

Technical Summary

Fetching the table to get its name is more work than needed and can cause issues if the table configuration isn't valid

resolves COMMCAREHQ-DREX & COMMCAREHQ-DRFG

Feature Flag

USER_CONFIGURABLE_REPORTS

Safety Assurance

Safety story

Tested locally

Automated test coverage

QA Plan

Rollback instructions

  • This PR can be reverted after deploy with no further considerations

Labels & Review

  • Risk label is set correctly
  • The set of people pinged as reviewers is appropriate for the level of risk of the change

fetching the table to get its name is more work than needed and can
cause issues if the table configuration isn't valid

resolves COMMCAREHQ-DREX COMMCAREHQ-DRFG
@@ -65,7 +65,8 @@ def get_existing_table_from_db(self):

@property
def table_exists(self):
return self.engine.has_table(self.get_table().name)
table_name = _get_table_name_for_adapter(self.override_table_name, self.config)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@mkangia mkangia marked this pull request as ready for review February 3, 2025 15:34
@mkangia mkangia requested a review from calellowitz as a code owner February 3, 2025 15:34
@mkangia mkangia added the Open for review: do not merge A work in progress label Feb 3, 2025
@mkangia
Copy link
Contributor Author

mkangia commented Feb 21, 2025

Going to put this on staging and let it be there for a while before I consider merging this.
(I already added it 3 weeks ago and has not caused any issues anywhere but I will wait some more)

@mkangia mkangia added product/feature-flag Change will only affect users who have a specific feature flag enabled and removed Open for review: do not merge A work in progress labels Feb 21, 2025
@mkangia mkangia merged commit 31e8b54 into master Feb 21, 2025
14 checks passed
@mkangia mkangia deleted the mk/better-table-exists branch February 21, 2025 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
product/feature-flag Change will only affect users who have a specific feature flag enabled
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants