Skip to content

Commit

Permalink
notebook show version; pre-commit in tox workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
haochenpan committed Jun 2, 2024
1 parent a1e6591 commit 5257ab4
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
4 changes: 3 additions & 1 deletion DiasporaDemo.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@
"from pprint import pprint\n",
"\n",
"from diaspora_event_sdk import Client as GlobusClient\n",
"from diaspora_event_sdk import KafkaConsumer, KafkaProducer, block_until_ready"
"from diaspora_event_sdk import KafkaConsumer, KafkaProducer, block_until_ready\n",
"from diaspora_event_sdk.version import __version__"
]
},
{
Expand All @@ -102,6 +103,7 @@
"outputs": [],
"source": [
"c = GlobusClient()\n",
"print(\"SDK version:\", __version__)\n",
"print(\"User's OpenID:\", c.subject_openid)"
]
},
Expand Down
8 changes: 7 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py{37, 38, 39, 310, 311, 312}, mypy
envlist = py{37, 38, 39, 310, 311, 312}, pre-commit, mypy

[testenv]
deps =
Expand All @@ -20,6 +20,12 @@ commands =
coverage run -m pytest {posargs}
coverage report

[testenv:pre-commit]
skip_install = true
deps = pre-commit
commands = pre-commit run --all-files --show-diff-on-failure


[testenv:mypy]
deps =
mypy
Expand Down

0 comments on commit 5257ab4

Please sign in to comment.