Skip to content

Commit bfcffa4

Browse files
author
Irving Popovetsky
committed
update README
Signed-off-by: Irving Popovetsky <irving@honeycomb.io>
1 parent 454ef41 commit bfcffa4

4 files changed

Lines changed: 42 additions & 131 deletions

File tree

.circleci/config.yml

Lines changed: 0 additions & 101 deletions
This file was deleted.

README.md

Lines changed: 37 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@
99
<br />
1010
<br />
1111

12-
# 🎃 Hacktoberfest 🎃
13-
14-
[All the details you need](https://github.com/OperationCode/START_HERE/blob/master/README.md#-hacktoberfest-) before participating with us during Hacktoberfest.
1512

1613
<br />
1714

@@ -31,6 +28,21 @@ extending [Pyslacker's](https://pyslackers.com/)
3128
[sir-bot-a-lot](https://github.com/pyslackers/sir-bot-a-lot-2)
3229
framework.
3330

31+
## Vendored Dependencies
32+
33+
This project includes vendored copies of the following abandoned libraries,
34+
modified for Python 3.12+ compatibility:
35+
36+
- **sirbot** (from [pyslackers/sir-bot-a-lot-2](https://github.com/pyslackers/sir-bot-a-lot-2)) - MIT License
37+
- **slack-sansio** (from [pyslackers/slack-sansio](https://github.com/pyslackers/slack-sansio)) - MIT License
38+
39+
These libraries are located in `pybot/_vendor/` and are maintained as part of this repository.
40+
The vendored code has been modernized with:
41+
- Removed deprecated `asyncio.coroutine()` usage
42+
- Fixed deprecated `loop=` parameter patterns
43+
- Replaced removed `cgi` module with `email.message`
44+
- Added Python 3.12 type hints
45+
3446
## Resources
3547
* [Slack Bot Tutorial](https://www.digitalocean.com/community/tutorials/how-to-build-a-slackbot-in-python-on-ubuntu-20-04)
3648
* [Slack Events API Framework](https://github.com/slackapi/python-slack-events-api)
@@ -42,13 +54,12 @@ Bug reports and pull requests are welcome on [Github](https://github.com/Operati
4254

4355
## Quick Start
4456
Recommended versions of tools used within the repo:
45-
- `python@3.7` or greater (in some environments, you may need to specify version of python i.e. `python test.py` vs `python3 test.py`))
57+
- `python@3.12` or greater (Python 3.13+ also supported)
4658
- `git@2.17.1` or greater
47-
- `poetry@0.12.11` or greater
48-
- [Poetry](https://poetry.eustace.io/) is a packaging and dependency manager, similar to pip or pipenv
49-
- Poetry provides a custom installer that can be ran via `curl -sSL https://raw.githubusercontent.com/sdispater/poetry/master/get-poetry.py | python`
50-
- Alternatively, poetry can be installed via pip/pip3 with `pip install --user poetry` or `pip3 install --user poetry`
51-
- See https://poetry.eustace.io/docs/
59+
- `poetry@1.0` or greater
60+
- [Poetry](https://python-poetry.org/) is a packaging and dependency manager, similar to pip or pipenv
61+
- Install via: `curl -sSL https://install.python-poetry.org | python3 -`
62+
- See https://python-poetry.org/docs/
5263

5364

5465
```bash
@@ -62,10 +73,8 @@ poetry run python -m pybot
6273
poetry run pytest
6374

6475
# Run formatting and linting
65-
poetry run black .
66-
# the next line shouldn't output anything to the terminal if it passes
67-
poetry run flake8
68-
poetry run isort -rc .
76+
poetry run black pybot/ tests/
77+
poetry run ruff check pybot/ tests/
6978
```
7079

7180
## How to Test Integration With Slack
@@ -166,16 +175,16 @@ Here's an example output from the command:
166175

167176
```bash
168177
ngrok by @inconshreveable (Ctrl+C to quit)
169-
Session Status online
170-
Session Expires 7 hours, 56 minutes
171-
Version 2.3.35
172-
Region United States (us)
173-
Web Interface http://127.0.0.1:4040
174-
Forwarding http://9d73595a7aac.ngrok.io -> http://localhost:5000
175-
Forwarding https://9d73595a7aac.ngrok.io -> http://localhost:5000
176-
Connections ttl opn rt1 rt5 p50 p90
177-
0 1 0.00 0.00 0.00 0.00
178-
HTTP Requests
178+
Session Status online
179+
Session Expires 7 hours, 56 minutes
180+
Version 2.3.35
181+
Region United States (us)
182+
Web Interface http://127.0.0.1:4040
183+
Forwarding http://9d73595a7aac.ngrok.io -> http://localhost:5000
184+
Forwarding https://9d73595a7aac.ngrok.io -> http://localhost:5000
185+
Connections ttl opn rt1 rt5 p50 p90
186+
0 1 0.00 0.00 0.00 0.00
187+
HTTP Requests
179188
```
180189

181190
With this done, ngrok will now expose the instance of pybot running locally
@@ -213,8 +222,8 @@ example:
213222

214223
https://123_random_code_321.ngrok.io/slack/events
215224

216-
Additional setup may needed depending on the type of events pybot is subscribing to.
217-
For example, in order to work on the app's functionality on a `team_join` event, you need to:
225+
Additional setup may needed depending on the type of events pybot is subscribing to.
226+
For example, in order to work on the app's functionality on a `team_join` event, you need to:
218227

219228
* Add `team_join` to workspace event
220229
* Make sure `greetings` channel exists and ensure the app is invited to the channel
@@ -229,7 +238,7 @@ make sure you configure the request URL to match the Base-URI that pybot is
229238
listening on followed by the text _/slack/commands_. For example:
230239

231240
https://123_random_code_321.ngrok.io/slack/commands
232-
241+
233242
You'll use the same URI for each command. Here's a table listing of currently
234243
supported commands along with some suggested configuration text:
235244

@@ -246,12 +255,12 @@ Command | Description | Usage Hint
246255

247256
**👋 IMPORTANT!**
248257

249-
The `/lunch` command requires a valid Yelp API token stored in the `YELP_TOKEN`
258+
The `/lunch` command requires a valid Yelp API token stored in the `YELP_TOKEN`
250259
environment variable. See https://www.yelp.com/developers/faq
251260

252261
Similarly, the `/mentor` and `/mentor-volunteer` commands require access to an Airtable
253262
environment with a specific configuration. If you're planning on working with the mentor
254-
functionality please reach out to the `#oc-python-projects` channel for help getting set up.
263+
functionality please reach out to the `#oc-python-projects` channel for help getting set up.
255264

256265
#### Interactive Components
257266

docker/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ WORKDIR /app
2020
RUN pip install --no-cache-dir poetry
2121

2222
# Copy dependency files
23-
COPY pyproject.toml poetry.lock README.md ./
23+
COPY pyproject.toml poetry.lock README.md logging.yml ./
2424
COPY pybot ./pybot
2525

2626
# Install dependencies into .venv in project

docs/UPGRADE_PLAN.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1402,7 +1402,10 @@ curl http://localhost:5000/sirbot/plugins
14021402

14031403
---
14041404

1405-
## Phase 11: Cleanup and Documentation (Day 8-9)
1405+
## Phase 11: Cleanup and Documentation (Day 8-9) ✅ COMPLETE
1406+
1407+
> **Status**: Completed January 4, 2026
1408+
> **Result**: README.md updated with Python 3.12 requirements and vendored dependencies documentation
14061409
14071410
### 11.1 Remove Old Lock File
14081411

0 commit comments

Comments
 (0)