Skip to content

Commit

Permalink
Upgrade dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
grossmj committed Aug 11, 2023
1 parent cefa459 commit b0657b3
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 16 deletions.
26 changes: 13 additions & 13 deletions gns3server/db/repositories/users.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def __init__(self, db_session: AsyncSession) -> None:

async def get_user(self, user_id: UUID) -> Optional[models.User]:
"""
Get an user by its ID.
Get a user by its ID.
"""

query = select(models.User).where(models.User.user_id == user_id)
Expand All @@ -50,7 +50,7 @@ async def get_user(self, user_id: UUID) -> Optional[models.User]:

async def get_user_by_username(self, username: str) -> Optional[models.User]:
"""
Get an user by its name.
Get a user by its name.
"""

query = select(models.User).where(models.User.username == username)
Expand All @@ -59,7 +59,7 @@ async def get_user_by_username(self, username: str) -> Optional[models.User]:

async def get_user_by_email(self, email: str) -> Optional[models.User]:
"""
Get an user by its email.
Get a user by its email.
"""

query = select(models.User).where(models.User.email == email)
Expand Down Expand Up @@ -94,7 +94,7 @@ async def create_user(self, user: schemas.UserCreate) -> models.User:

async def update_user(self, user_id: UUID, user_update: schemas.UserUpdate) -> Optional[models.User]:
"""
Update an user.
Update a user.
"""

update_values = user_update.model_dump(exclude_unset=True)
Expand All @@ -115,7 +115,7 @@ async def update_user(self, user_id: UUID, user_update: schemas.UserUpdate) -> O

async def delete_user(self, user_id: UUID) -> bool:
"""
Delete an user.
Delete a user.
"""

query = delete(models.User).where(models.User.user_id == user_id)
Expand Down Expand Up @@ -165,7 +165,7 @@ async def get_user_memberships(self, user_id: UUID) -> List[models.UserGroup]:

async def get_user_group(self, user_group_id: UUID) -> Optional[models.UserGroup]:
"""
Get an user group by its ID.
Get a user group by its ID.
"""

query = select(models.UserGroup).where(models.UserGroup.user_group_id == user_group_id)
Expand All @@ -174,7 +174,7 @@ async def get_user_group(self, user_group_id: UUID) -> Optional[models.UserGroup

async def get_user_group_by_name(self, name: str) -> Optional[models.UserGroup]:
"""
Get an user group by its name.
Get a user group by its name.
"""

query = select(models.UserGroup).where(models.UserGroup.name == name)
Expand Down Expand Up @@ -238,7 +238,7 @@ async def add_member_to_user_group(
user: models.User
) -> Union[None, models.UserGroup]:
"""
Add a member to an user group.
Add a member to a user group.
"""

query = select(models.UserGroup).\
Expand All @@ -260,7 +260,7 @@ async def remove_member_from_user_group(
user: models.User
) -> Union[None, models.UserGroup]:
"""
Remove a member from an user group.
Remove a member from a user group.
"""

query = select(models.UserGroup).\
Expand All @@ -278,7 +278,7 @@ async def remove_member_from_user_group(

async def get_user_group_members(self, user_group_id: UUID) -> List[models.User]:
"""
Get all members from an user group.
Get all members from a user group.
"""

query = select(models.User).\
Expand All @@ -294,7 +294,7 @@ async def add_role_to_user_group(
role: models.Role
) -> Union[None, models.UserGroup]:
"""
Add a role to an user group.
Add a role to a user group.
"""

query = select(models.UserGroup).\
Expand All @@ -316,7 +316,7 @@ async def remove_role_from_user_group(
role: models.Role
) -> Union[None, models.UserGroup]:
"""
Remove a role from an user group.
Remove a role from a user group.
"""

query = select(models.UserGroup).\
Expand All @@ -334,7 +334,7 @@ async def remove_role_from_user_group(

async def get_user_group_roles(self, user_group_id: UUID) -> List[models.Role]:
"""
Get all roles from an user group.
Get all roles from a user group.
"""

query = select(models.Role). \
Expand Down
6 changes: 3 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@ fastapi==0.101.0
python-multipart==0.0.6
websockets==11.0.3
aiohttp>=3.8.5,<3.9
async-timeout==4.0.2
aiofiles==23.1.0
async-timeout==4.0.3
aiofiles==23.2.1
Jinja2>=3.1.2,<3.2
sentry-sdk==1.29.2,<1.30
psutil==5.9.5
distro>=1.8.0
py-cpuinfo==9.0.0
sqlalchemy==2.0.17
aiosqlite==0.19.0
alembic==1.11.1
alembic==1.11.2
passlib[bcrypt]==1.7.4
python-jose==3.3.0
email-validator==2.0.0.post2
Expand Down

0 comments on commit b0657b3

Please sign in to comment.