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

Upgraded flask package and dependencies #68

Merged
merged 25 commits into from
Jan 12, 2024

Conversation

Sachinbisht27
Copy link
Member

#65

Please complete the following steps and check these boxes before filing your PR:

Types of changes

  • Bug fix (a change which fixes an issue)
  • New feature (a change which adds functionality)

Short description of what this resolves:

We are currently using Flask 1.1.2, which is getting older, and the latest version Flask 3.0.0 was upgraded on Sep 30, 2023.
In this PR we have upgraded the Flask package to 3.0.0 and its dependencies' latest compatible versions.

Checklist:

  • I have performed a self-review of my own code.
  • The code follows the style guidelines of this project.
  • The code changes are passing the CI checks
  • I have documented my code wherever required.
  • The changes requires a change to the documentation.
  • I have updated the documentation based on the my changes.

Comment on lines 12 to 16
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: '3.9'
- uses: pre-commit/[email protected]
Copy link
Member Author

Choose a reason for hiding this comment

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

This change is the fix for the pre-commit failure issue.

@@ -34,7 +34,6 @@
% POSTGRES
)

SQLALCHEMY_TRACK_MODIFICATIONS = True
Copy link
Member Author

Choose a reason for hiding this comment

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

Removed the SQLALCHEMY_TRACK_MODIFICATIONS because getting an error for the use of this after upgrading flask-SQLalchemy.

@@ -1,6 +1,6 @@
from api.mixins import TimestampMixin
from api import db
from flask_sqlalchemy import BaseQuery
from flask_sqlalchemy.query import Query as BaseQuery
Copy link
Member Author

Choose a reason for hiding this comment

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

The BaseQuery class has been renamed as query now and is situated within the query module.

requirements.txt Outdated
Comment on lines 3 to 19
click==8.1.3
Flask==3.0.0
requests==2.25.1
python-dotenv==0.15.0
Flask-SQLAlchemy==2.1
Flask-SQLAlchemy==3.1.1
greenlet==3.0.3
idna==2.10
itsdangerous==1.1.0
Jinja2==2.11.3
MarkupSafe==1.1.1
psycopg2==2.8.6
itsdangerous==2.1.2
Jinja2==3.1.2
MarkupSafe==2.1.1
psycopg2==2.9.9
python-dotenv==0.15.0
requests==2.25.1
SQLAlchemy==1.3.23
SQLAlchemy==2.0.23
urllib3==1.26.3
Werkzeug==1.0.1
Werkzeug==3.0.0
watchdog==3.0.0
Copy link
Member Author

Choose a reason for hiding this comment

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

These packages are interdependent with each other and upgraded to ensure compatibility with one another up to the latest supported versions.

Copy link
Contributor

@vivek-kumar-pandey vivek-kumar-pandey left a comment

Choose a reason for hiding this comment

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

Looks fine

@Sachinbisht27 Sachinbisht27 merged commit 28f9fc7 into develop Jan 12, 2024
1 check passed
@Sachinbisht27 Sachinbisht27 deleted the feature/65-upgrade-flask-package branch January 12, 2024 14:10
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.

2 participants