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

Refactor sqlite3 to SQLAlchemy #159

Merged
merged 3 commits into from
Dec 17, 2024
Merged

Refactor sqlite3 to SQLAlchemy #159

merged 3 commits into from
Dec 17, 2024

Conversation

LuiggiTenorioK
Copy link
Member

@LuiggiTenorioK LuiggiTenorioK commented Dec 12, 2024

The purpose of this PR is to remove the usage of the sqlite3 and use SQLAlchemy instead. We will exclude the refactor of the history module to another branch.

  • autosubmit_api/database/db_structure.py
  • autosubmit_api/experiment/common_db_requests.py
  • Remove some dead code

@LuiggiTenorioK LuiggiTenorioK changed the title Remove sqlite3 Refactor sqlite3 to SQLAlchemy Dec 12, 2024
@codecov-commenter
Copy link

codecov-commenter commented Dec 12, 2024

Codecov Report

Attention: Patch coverage is 97.72727% with 1 line in your changes missing coverage. Please review.

Project coverage is 74.59%. Comparing base (f465b31) to head (35486fb).

Files with missing lines Patch % Lines
autosubmit_api/experiment/common_requests.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #159      +/-   ##
==========================================
+ Coverage   73.01%   74.59%   +1.57%     
==========================================
  Files          89       89              
  Lines        7872     7653     -219     
==========================================
- Hits         5748     5709      -39     
+ Misses       2124     1944     -180     
Flag Coverage Δ
fast-tests 74.59% <97.72%> (+1.57%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@LuiggiTenorioK LuiggiTenorioK self-assigned this Dec 16, 2024
@LuiggiTenorioK LuiggiTenorioK marked this pull request as ready for review December 17, 2024 09:14
Copy link
Member

@kinow kinow left a comment

Choose a reason for hiding this comment

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

Read the code but didn't find anything that looked odd or out of its place. Nice simplification and it's impressive how much code was deleted here (minus 463 lines of code, adding only 71). I assume some of those functions removed were never used?

@LuiggiTenorioK
Copy link
Member Author

Read the code but didn't find anything that looked odd or out of its place. Nice simplification and it's impressive how much code was deleted here (minus 463 lines of code, adding only 71). I assume some of those functions removed were never used?

Yes, many methods of the history db manager were never used. I'll continue that history module refactor on another since this one seems pretty clean.

@LuiggiTenorioK LuiggiTenorioK merged commit 1eade31 into main Dec 17, 2024
9 checks passed
@LuiggiTenorioK LuiggiTenorioK deleted the gh-142-rm-sqlite3 branch December 17, 2024 09:24
@LuiggiTenorioK LuiggiTenorioK restored the gh-142-rm-sqlite3 branch December 17, 2024 09:24
@kinow kinow deleted the gh-142-rm-sqlite3 branch December 17, 2024 09:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants