Skip to content

Commit

Permalink
Merge pull request #120 from stuartcampbell/update-deps
Browse files Browse the repository at this point in the history
Update Dependencies and Code Reformatting and Linting
  • Loading branch information
danielballan authored Nov 13, 2024
2 parents 52be099 + 6376e00 commit 168cd7c
Show file tree
Hide file tree
Showing 30 changed files with 383 additions and 173 deletions.
10 changes: 6 additions & 4 deletions performance-tests/locustfile.py
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
import locust


class ApiTest(locust.FastHttpUser):
host = "http://127.0.0.1:8080"

# The time a user 'waits' between requests
wait_time = locust.between(5,30)
wait_time = locust.between(5, 30)

@locust.task(weight=1)
def home_page(self):
self.client.get('/')
self.client.get("/")

@locust.task(weight=5)
def stats(self):
self.client.get('/stats')
self.client.get("/stats")

@locust.task(weight=15)
def recent(self):
self.client.get('/proposals/recent/5')
self.client.get("/proposals/recent/5")
7 changes: 6 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,11 @@ hooks.vcs.version-file = "src/nsls2api/_version.py"
[tool.hatch.build.targets.sdist]
exclude = [
"/.github",
"/.gitignore",
"/.git",
"/.vscode",
"/.pytest_cache",
"/.venv",
]

#[tool.hatch.metadata.hooks.requirements_txt.optional-dependencies]
Expand All @@ -56,5 +61,5 @@ asyncio_default_fixture_loop_scope = "function"
asyncio_mode = "auto"

[tool.ruff]
target-version = "py311"
target-version = "py312"

5 changes: 5 additions & 0 deletions requirements-dev.in
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,15 @@ asyncer
black
bunnet
coverage
hatch
hatchling
hatch-requirements-txt
hatch-vcs
ipython
locust
pyright
pytest
pytest-asyncio
ruff
textual-dev
uv
111 changes: 95 additions & 16 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ aiosignal==1.3.1
annotated-types==0.7.0
# via pydantic
anyio==4.6.2.post1
# via asyncer
# via
# asyncer
# httpx
asgi-lifespan==2.1.0
# via -r requirements-dev.in
asttokens==2.4.1
Expand All @@ -25,7 +27,7 @@ attrs==24.2.0
# via aiohttp
black==24.10.0
# via -r requirements-dev.in
blinker==1.8.2
blinker==1.9.0
# via flask
brotli==1.1.0
# via geventhttpclient
Expand All @@ -34,6 +36,8 @@ bunnet==1.3.0
certifi==2024.8.30
# via
# geventhttpclient
# httpcore
# httpx
# requests
charset-normalizer==3.4.0
# via requests
Expand All @@ -42,17 +46,23 @@ click==8.1.7
# black
# bunnet
# flask
# hatch
# textual-dev
# userpath
configargparse==1.7
# via locust
coverage==7.6.4
# via -r requirements-dev.in
decorator==5.1.1
# via ipython
distlib==0.3.9
# via virtualenv
dnspython==2.7.0
# via pymongo
executing==2.1.0
# via stack-data
filelock==3.16.1
# via virtualenv
flask==3.0.3
# via
# flask-cors
Expand All @@ -66,15 +76,37 @@ frozenlist==1.5.0
# via
# aiohttp
# aiosignal
gevent==24.10.3
gevent==24.11.1
# via geventhttpclient
geventhttpclient==2.3.1
# via locust
greenlet==3.1.1
# via gevent
h11==0.14.0
# via httpcore
hatch==1.13.0
# via -r requirements-dev.in
hatch-requirements-txt==0.4.1
# via -r requirements-dev.in
hatch-vcs==0.4.0
# via -r requirements-dev.in
hatchling==1.26.3
# via
# -r requirements-dev.in
# hatch
# hatch-requirements-txt
# hatch-vcs
httpcore==1.0.6
# via httpx
httpx==0.27.2
# via hatch
hyperlink==21.0.0
# via hatch
idna==3.10
# via
# anyio
# httpx
# hyperlink
# requests
# yarl
iniconfig==2.0.0
Expand All @@ -83,18 +115,26 @@ ipython==8.29.0
# via -r requirements-dev.in
itsdangerous==2.2.0
# via flask
jedi==0.19.1
jaraco-classes==3.4.0
# via keyring
jaraco-context==6.0.1
# via keyring
jaraco-functools==4.1.0
# via keyring
jedi==0.19.2
# via ipython
jinja2==3.1.4
# via
# aiohttp-jinja2
# flask
# textual-serve
keyring==25.5.0
# via hatch
lazy-model==0.2.0
# via bunnet
linkify-it-py==2.0.3
# via markdown-it-py
locust==2.32.0
locust==2.32.2
# via -r requirements-dev.in
markdown-it-py==3.0.0
# via
Expand All @@ -111,6 +151,10 @@ mdit-py-plugins==0.4.2
# via markdown-it-py
mdurl==0.1.2
# via markdown-it-py
more-itertools==10.5.0
# via
# jaraco-classes
# jaraco-functools
msgpack==1.1.0
# via
# locust
Expand All @@ -123,22 +167,34 @@ mypy-extensions==1.0.0
# via black
nodeenv==1.9.1
# via pyright
packaging==24.1
packaging==24.2
# via
# black
# hatch
# hatch-requirements-txt
# hatchling
# pytest
# setuptools-scm
parso==0.8.4
# via jedi
pathspec==0.12.1
# via black
# via
# black
# hatchling
pexpect==4.9.0
# via ipython
# via
# hatch
# ipython
platformdirs==4.3.6
# via
# black
# hatch
# textual
# virtualenv
pluggy==1.5.0
# via pytest
# via
# hatchling
# pytest
prompt-toolkit==3.0.48
# via ipython
propcache==0.2.0
Expand All @@ -161,7 +217,7 @@ pygments==2.18.0
# rich
pymongo==4.10.1
# via bunnet
pyright==1.1.386
pyright==1.1.388
# via -r requirements-dev.in
pytest==8.3.3
# via
Expand All @@ -173,25 +229,32 @@ pyzmq==26.2.0
# via locust
requests==2.32.3
# via locust
rich==13.9.3
rich==13.9.4
# via
# hatch
# textual
# textual-serve
ruff==0.7.1
ruff==0.7.3
# via -r requirements-dev.in
setuptools==75.2.0
setuptools==75.5.0
# via
# setuptools-scm
# zope-event
# zope-interface
setuptools-scm==8.1.0
# via hatch-vcs
shellingham==1.5.4
# via hatch
six==1.16.0
# via asttokens
sniffio==1.3.1
# via
# anyio
# asgi-lifespan
# httpx
stack-data==0.6.3
# via ipython
textual==0.85.0
textual==0.85.2
# via
# textual-dev
# textual-serve
Expand All @@ -201,10 +264,16 @@ textual-serve==1.1.1
# via textual-dev
toml==0.10.2
# via bunnet
tomli-w==1.1.0
# via hatch
tomlkit==0.13.2
# via hatch
traitlets==5.14.3
# via
# ipython
# matplotlib-inline
trove-classifiers==2024.10.21.16
# via hatchling
typing-extensions==4.12.2
# via
# pydantic
Expand All @@ -218,16 +287,26 @@ urllib3==2.2.3
# via
# geventhttpclient
# requests
userpath==1.9.2
# via hatch
uv==0.5.1
# via
# -r requirements-dev.in
# hatch
virtualenv==20.27.1
# via hatch
wcwidth==0.2.13
# via prompt-toolkit
werkzeug==3.0.6
werkzeug==3.1.3
# via
# flask
# flask-login
# locust
yarl==1.16.0
yarl==1.17.1
# via aiohttp
zope-event==5.0
# via gevent
zope-interface==7.1.1
# via gevent
zstandard==0.23.0
# via hatch
Loading

0 comments on commit 168cd7c

Please sign in to comment.