Skip to content

Commit 0154f0f

Browse files
committed
feat: selective merge from main
- Keep our CI/CD workflows and uv-based setup - Adopt only specific Dockerfile improvements: prisma-aware cleanup - Remove poetry.lock (we use uv) - Add renovate.json5 for automated dependency updates - Update other minor improvements from main branch
1 parent 6502e1e commit 0154f0f

File tree

6 files changed

+50
-14
lines changed

6 files changed

+50
-14
lines changed

.github/renovate.json

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

.github/renovate.json5

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
{
2+
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
3+
"extends": [
4+
"config:best-practices"
5+
],
6+
"schedule": [
7+
"* */12 * * *"
8+
],
9+
"ignoreDeps": [
10+
"basedpyright" // see pyproject.toml
11+
],
12+
"lockFileMaintenance": {
13+
"enabled": true,
14+
"automerge": true
15+
},
16+
"packageRules": [
17+
{
18+
// these will fail tests if they are broken
19+
// idk if this works with python, either way it doesnt matter
20+
//"matchDepTypes": [
21+
// "devDependencies"
22+
//],
23+
"matchPackageNames": [
24+
"pre-commit",
25+
"ruff",
26+
"poetry",
27+
"pytest"
28+
],
29+
"automerge": true
30+
},
31+
{
32+
// no breaking changes
33+
"matchUpdateTypes": [
34+
"minor",
35+
"patch"
36+
],
37+
"matchCurrentVersion": "!/^0/",
38+
"automerge": true
39+
}
40+
]
41+
}

.mise.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
[tools]
2-
python = "3.13.5"
2+
python = "3.13.7"

.python-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.13.5
1+
3.13.7

Dockerfile

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -367,18 +367,19 @@ RUN set -eux; \
367367
# Remove Python bytecode files (will be regenerated as needed)
368368
find /app/.venv -name "*.pyc" -delete; \
369369
find /app/.venv -name "__pycache__" -type d -exec rm -rf {} + 2>/dev/null || true; \
370-
# Remove test directories from installed packages
370+
# Remove test directories from installed packages (but preserve prisma binaries)
371371
# These directories contain test files that are not needed in production
372-
for test_dir in tests testing "*test*"; do \
373-
find /app/.venv -name "$test_dir" -type d -exec rm -rf {} + 2>/dev/null || true; \
372+
for test_dir in tests testing "test*"; do \
373+
find /app/.venv -name "$test_dir" -type d -not -path "*/prisma*" -exec rm -rf {} + 2>/dev/null || true; \
374374
done; \
375-
# Remove documentation files from installed packages
375+
# Remove documentation files from installed packages (but preserve prisma docs)
376376
# These files take up significant space and are not needed in production
377377
for doc_pattern in "*.md" "*.txt" "*.rst" "LICENSE*" "NOTICE*" "COPYING*" "CHANGELOG*" "README*" "HISTORY*" "AUTHORS*" "CONTRIBUTORS*"; do \
378-
find /app/.venv -name "$doc_pattern" -delete 2>/dev/null || true; \
378+
find /app/.venv -name "$doc_pattern" -not -path "*/prisma*" -delete 2>/dev/null || true; \
379379
done; \
380380
# Remove large development packages that are not needed in production
381381
# These packages (pip, setuptools, wheel) are only needed for installing packages
382+
# NOTE: Preserving packages that Prisma might need
382383
for pkg in setuptools wheel pkg_resources; do \
383384
rm -rf /app/.venv/lib/python3.13/site-packages/${pkg}* 2>/dev/null || true; \
384385
rm -rf /app/.venv/bin/${pkg}* 2>/dev/null || true; \

src/tux/services/handlers/event.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ async def handle_harmful_message(message: discord.Message) -> None:
3535
None
3636
"""
3737

38-
if message.author.bot:
38+
if message.author.bot and message.webhook_id not in CONFIG.BRIDGE_WEBHOOK_IDS:
3939
return
4040

4141
stripped_content = strip_formatting(message.content)

0 commit comments

Comments
 (0)