Skip to content

Commit fb49421

Browse files
committed
Merge remote-tracking branch 'origin/main' into tkp/ct
2 parents a81de8f + 7822f21 commit fb49421

9 files changed

Lines changed: 87 additions & 68 deletions

File tree

.copier-answers.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Changes here will be overwritten by Copier
2-
_commit: b74d698
2+
_commit: 9be318c
33
_src_path: https://github.com/python-project-templates/base.git
44
add_docs: false
55
add_extension: python

.github/workflows/build.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ jobs:
5555
run: make coverage
5656

5757
- name: Upload test results (Python)
58-
uses: actions/upload-artifact@v6
58+
uses: actions/upload-artifact@v7
5959
with:
6060
name: test-results-${{ matrix.os }}-${{ matrix.python-version }}
6161
path: junit.xml
@@ -74,7 +74,7 @@ jobs:
7474
- name: Make dist
7575
run: make dist
7676

77-
- uses: actions/upload-artifact@v6
77+
- uses: actions/upload-artifact@v7
7878
with:
7979
name: dist-${{matrix.os}}
8080
path: dist

.gitignore

Lines changed: 17 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ __pycache__/
1111
*.exp
1212
*.lib
1313

14+
# Rust
15+
target
16+
1417
# Distribution / packaging
1518
.Python
1619
build/
@@ -55,26 +58,12 @@ junit.xml
5558
.hypothesis/
5659
.pytest_cache/
5760

58-
# Translations
59-
*.mo
60-
*.pot
61-
62-
# Django stuff:
61+
# Django
6362
*.log
6463
local_settings.py
6564
db.sqlite3
6665
db.sqlite3-journal
6766

68-
# Flask stuff:
69-
instance/
70-
.webassets-cache
71-
72-
# Scrapy stuff:
73-
.scrapy
74-
75-
# PyBuilder
76-
target/
77-
7867
# IPython
7968
profile_default/
8069
ipython_config.py
@@ -85,15 +74,12 @@ ipython_config.py
8574
# pipenv
8675
Pipfile.lock
8776

88-
# PEP 582; used by e.g. github.com/David-OConnor/pyflow
89-
__pypackages__/
90-
91-
# Celery stuff
77+
# Celery
9278
celerybeat-schedule
9379
celerybeat.pid
9480

95-
# SageMath parsed files
96-
*.sage.py
81+
# Airspeed Velocity
82+
.asv
9783

9884
# Environments
9985
.env
@@ -141,14 +127,12 @@ js/node_modules
141127
js/test-results
142128
js/playwright-report
143129
js/*.tgz
144-
csp_bot/extension
145130

146131
# Jupyter
147132
.ipynb_checkpoints
148133
.autoversion
149134
Untitled*.ipynb
150-
!csp_bot/extension/csp_bot.json
151-
!csp_bot/extension/install.json
135+
csp_bot/extension
152136
csp_bot/nbextension
153137
csp_bot/labextension
154138

@@ -158,12 +142,18 @@ csp_bot/labextension
158142
# Rust
159143
target
160144

145+
# Hydra
146+
outputs/
147+
multirun/
148+
149+
# AI
150+
ROADMAP.md
151+
AGENTS.md
152+
.github/hooks/sdlc.json
153+
161154
# Secrets
162155
.discord_token
163156
.slack_app_token
164157
.slack_bot_token
165158
.symphony_cert
166159
.symphony_key
167-
168-
# Outputs
169-
outputs

Makefile

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,15 @@ format: fix
4646
################
4747
# Other Checks #
4848
################
49-
.PHONY: check-manifest checks check
49+
.PHONY: check-dist check-types checks check
5050

51-
check-manifest: ## check python sdist manifest with check-manifest
52-
check-manifest -v
51+
check-dist: ## check python sdist and wheel with check-dist
52+
check-dist -v
5353

54-
checks: check-manifest
54+
check-types: ## check python types with ty
55+
ty check --python $$(which python)
56+
57+
checks: check-dist
5558

5659
# Alias
5760
check: checks

csp_bot/backends/slack.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
SlackPresenceStatus,
1919
SlackUser,
2020
)
21-
from csp_adapter_slack import SlackAdapter
21+
from csp_adapter_slack.v1 import SlackAdapter
2222
except ImportError:
2323
from chatom import Message as ChatomMessage, User as ChatomUser
2424
from pydantic import BaseModel

csp_bot/backends/symphony.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
SymphonyPresenceStatus,
1919
SymphonyUser,
2020
)
21-
from csp_adapter_symphony import SymphonyAdapter
21+
from csp_adapter_symphony.v1 import SymphonyAdapter
2222
except ImportError:
2323
from chatom import Message as ChatomMessage, User as ChatomUser
2424
from pydantic import BaseModel

csp_bot/commands/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
from abc import ABC, abstractmethod
88
from typing import List, Type, Union
99

10+
from ccflow import BaseModel
1011
from chatom import Message
1112

12-
from ccflow import BaseModel
1313
from csp_bot.structs import Backend, BotCommand, BotMessage, CommandVariant
1414

1515

csp_bot/config/conf.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ start:
1212
rest: true
1313
ui: false
1414

15-
authenticate: False
1615
port: 8000
1716

1817
gateway:
@@ -31,7 +30,6 @@ gateway:
3130
- /commands/status
3231
settings:
3332
PORT: ${port}
34-
AUTHENTICATE: ${authenticate}
3533

3634
hydra:
3735
run:

pyproject.toml

Lines changed: 57 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
[build-system]
2-
requires = ["hatchling"]
3-
build-backend="hatchling.build"
2+
requires = [
3+
"hatchling",
4+
]
5+
build-backend = "hatchling.build"
46

57
[project]
68
name = "csp-bot"
7-
authors = [{name = "Point72, L.P.", email = "OpenSource@point72.com"}]
9+
authors = [
10+
{name = "Point72, L.P.", email = "OpenSource@point72.com"},
11+
]
812
description = "Reactive chat bot framework"
913
readme = "README.md"
1014
license = { text = "Apache-2.0" }
@@ -35,9 +39,10 @@ classifiers = [
3539
dependencies = [
3640
"beautifulsoup4",
3741
"ccflow>=0.5.2",
42+
"chatom",
3843
"croniter",
3944
"csp>=0.9,<1",
40-
"csp-gateway>=2,<3",
45+
"csp-gateway>=2.5,<2.6",
4146
"dateparser",
4247
"hydra-core",
4348
"pandas",
@@ -48,18 +53,19 @@ dependencies = [
4853
develop = [
4954
"build",
5055
"bump-my-version",
51-
"check-manifest",
52-
"codespell>=2.4,<2.5",
53-
"csp-adapter-discord>=0.1,<0.2",
54-
"csp-adapter-slack>=0.3,<0.4",
55-
"csp-adapter-symphony>=0.3,<0.4",
56+
"check-dist",
57+
"codespell",
58+
"csp-adapter-discord>=0.2,<0.3",
59+
"csp-adapter-slack>=0.4,<0.5",
60+
"csp-adapter-symphony>=0.4,<0.5",
5661
"hatchling",
57-
"mdformat>=0.7.22,<1.1",
62+
"mdformat",
5863
"mdformat-tables>=1",
5964
"pytest",
6065
"pytest-cov",
61-
"ruff>=0.9,<0.15",
66+
"ruff",
6267
"twine",
68+
"ty",
6369
"uv",
6470
"wheel",
6571
# tests
@@ -89,19 +95,12 @@ filename = "pyproject.toml"
8995
search = 'version = "{current_version}"'
9096
replace = 'version = "{new_version}"'
9197

92-
[tool.check-manifest]
93-
ignore = [
94-
".copier-answers.yaml",
95-
"Makefile",
96-
"docs/**/*",
97-
"example/**/*",
98-
]
99-
10098
[tool.coverage.run]
10199
branch = true
102100
omit = [
103101
"csp_bot/tests/integration/",
104102
]
103+
105104
[tool.coverage.report]
106105
exclude_also = [
107106
"raise NotImplementedError",
@@ -118,31 +117,60 @@ artifacts = []
118117
src = "/"
119118

120119
[tool.hatch.build.targets.sdist]
121-
packages = ["csp_bot"]
122-
exclude = ["/docs", "/example"]
120+
packages = [
121+
"csp_bot",
122+
]
123+
exclude = [
124+
"docs",
125+
"example",
126+
]
123127

124128
[tool.hatch.build.targets.wheel]
125-
packages = ["csp_bot"]
126-
exclude = ["/docs", "/example"]
129+
packages = [
130+
"csp_bot",
131+
]
132+
exclude = [
133+
"docs",
134+
"example",
135+
]
127136

128137
[tool.hatch.build.targets.wheel.shared-data]
129138

130139
[tool.pytest.ini_options]
131-
addopts = ["-vvv", "--junitxml=junit.xml"]
140+
addopts = [
141+
"-vvv",
142+
"--junitxml=junit.xml",
143+
]
132144
testpaths = "csp_bot/tests"
133145

134146
[tool.ruff]
135147
line-length = 150
136148

137149
[tool.ruff.lint]
138-
extend-select = ["I"]
150+
extend-select = [
151+
"I",
152+
]
139153

140154
[tool.ruff.lint.isort]
141155
combine-as-imports = true
142156
default-section = "third-party"
143-
known-first-party = ["csp_bot"]
144-
section-order = ["future", "standard-library", "third-party", "first-party", "local-folder"]
157+
known-first-party = [
158+
"csp_bot",
159+
]
160+
section-order = [
161+
"future",
162+
"standard-library",
163+
"third-party",
164+
"first-party",
165+
"local-folder",
166+
]
145167

146168
[tool.ruff.lint.per-file-ignores]
147-
"__init__.py" = ["F401", "F403"]
148-
"csp_bot/backends" = ["F401", "F403"]
169+
"__init__.py" = [
170+
"F401",
171+
"F403",
172+
]
173+
"csp_bot/backends" = [
174+
"F401",
175+
"F403",
176+
]

0 commit comments

Comments
 (0)