Skip to content

Commit 5e4ff7d

Browse files
committed
cleanup after installing pre-commit
1 parent be93012 commit 5e4ff7d

2 files changed

Lines changed: 12 additions & 13 deletions

File tree

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
# SQLModel-CRUD-Utilities
2-
A set of CRUD utilities to expedite operations with SQLModel.
2+
A set of CRUD utilities to expedite operations with SQLModel.
33

44
## Instructions
55

6-
- Run `pip install sqlmodel_crud_utils` or add `sqlmodel_crud_utils` to your
6+
- Run `pip install sqlmodel_crud_utils` or add `sqlmodel_crud_utils` to your
77
requirements files
8-
- Declare the value for the `SQL_DIALECT` environmental variable. It can either
9-
be actively loaded within the environment or added to a `.env` file, courtesy
8+
- Declare the value for the `SQL_DIALECT` environmental variable. It can either
9+
be actively loaded within the environment or added to a `.env` file, courtesy
1010
of `dotenv`.
1111
- For a list of available native and 3rd party dialects, please see here: https://docs.sqlalchemy.org/en/20/dialects/#included-dialects
1212

1313
## Inspiration
14-
The reason behind creating this package was to streamline the CRUD operations
15-
across multiple personal and team-based projects that rely on SQLModel for its
16-
ORM operations.
14+
The reason behind creating this package was to streamline the CRUD operations
15+
across multiple personal and team-based projects that rely on SQLModel for its
16+
ORM operations.
1717

18-
Because of existing commitments to SQLModel within the tech stack of multiple
19-
projects, this package will be continuously supported and developed. A close eye
20-
will be kept on the SQLModel's ongoing roadmap and eventual uplift to SQLAlchemy
18+
Because of existing commitments to SQLModel within the tech stack of multiple
19+
projects, this package will be continuously supported and developed. A close eye
20+
will be kept on the SQLModel's ongoing roadmap and eventual uplift to SQLAlchemy
2121
2.0 and Pydantic 2.0.
2222
## Development Roadmap
2323
- [ ] Release working Alpha version

crud/crud.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,11 +82,10 @@ async def get_one_or_create(
8282
:param kwargs: keyword args
8383
:return: Tuple[Row, bool]
8484
"""
85+
8586
async def _get_entry(sqlmodel, **key_args):
8687
stmnt = select(sqlmodel).filter_by(**key_args)
87-
results = await get_result_from_query(
88-
query=stmnt, session=session_inst
89-
)
88+
results = await get_result_from_query(query=stmnt, session=session_inst)
9089

9190
if results:
9291
if selectin and select_in_key:

0 commit comments

Comments
 (0)