GoodbyeSQL 0.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- goodbyesql-0.5/GoodbyeSQL.egg-info/PKG-INFO +5 -0
- goodbyesql-0.5/GoodbyeSQL.egg-info/SOURCES.txt +10 -0
- goodbyesql-0.5/GoodbyeSQL.egg-info/dependency_links.txt +1 -0
- goodbyesql-0.5/GoodbyeSQL.egg-info/entry_points.txt +2 -0
- goodbyesql-0.5/GoodbyeSQL.egg-info/requires.txt +1 -0
- goodbyesql-0.5/GoodbyeSQL.egg-info/top_level.txt +1 -0
- goodbyesql-0.5/PKG-INFO +5 -0
- goodbyesql-0.5/goodbyesql/__init__.py +3 -0
- goodbyesql-0.5/goodbyesql/config.py +11 -0
- goodbyesql-0.5/goodbyesql/main.py +22 -0
- goodbyesql-0.5/setup.cfg +4 -0
- goodbyesql-0.5/setup.py +15 -0
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
setup.py
|
|
2
|
+
GoodbyeSQL.egg-info/PKG-INFO
|
|
3
|
+
GoodbyeSQL.egg-info/SOURCES.txt
|
|
4
|
+
GoodbyeSQL.egg-info/dependency_links.txt
|
|
5
|
+
GoodbyeSQL.egg-info/entry_points.txt
|
|
6
|
+
GoodbyeSQL.egg-info/requires.txt
|
|
7
|
+
GoodbyeSQL.egg-info/top_level.txt
|
|
8
|
+
goodbyesql/__init__.py
|
|
9
|
+
goodbyesql/config.py
|
|
10
|
+
goodbyesql/main.py
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
sqlalchemy==2.0.43
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
goodbyesql
|
goodbyesql-0.5/PKG-INFO
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
from sqlalchemy.ext.asyncio import AsyncSession
|
|
2
|
+
from sqlalchemy import select
|
|
3
|
+
from config import GoodbyeSQLConfig
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class GoodbyeSQL:
|
|
7
|
+
def __init__(self, config: GoodbyeSQLConfig):
|
|
8
|
+
self.config = config
|
|
9
|
+
|
|
10
|
+
async def get_info_by_username(self, *, session: AsyncSession, username: str):
|
|
11
|
+
|
|
12
|
+
model = self.config.user_model
|
|
13
|
+
field = getattr(model,self.config.username_field)
|
|
14
|
+
|
|
15
|
+
query = select(model).where(field == username)
|
|
16
|
+
result = await session.execute(query)
|
|
17
|
+
user: None = result.scalar_one_or_none()
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def check_my_library():
|
|
22
|
+
print("It is working right now!")
|
goodbyesql-0.5/setup.cfg
ADDED
goodbyesql-0.5/setup.py
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
from setuptools import setup, find_packages
|
|
2
|
+
|
|
3
|
+
setup(
|
|
4
|
+
name='GoodbyeSQL',
|
|
5
|
+
version='0.5',
|
|
6
|
+
packages=find_packages(),
|
|
7
|
+
install_requires=[
|
|
8
|
+
'sqlalchemy==2.0.43',
|
|
9
|
+
],
|
|
10
|
+
entry_points={
|
|
11
|
+
"console_scripts":[
|
|
12
|
+
"goodbyesql=goodbyesql.main:main"
|
|
13
|
+
]
|
|
14
|
+
}
|
|
15
|
+
)
|