Skip to content

Commit d4e84fd

Browse files
feat: delete dead code (remove old deps) (#1147)
Co-authored-by: jayhack <[email protected]> Co-authored-by: codegen-team <[email protected]>
1 parent bf5f7a0 commit d4e84fd

File tree

1,386 files changed

+1634
-199056
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,386 files changed

+1634
-199056
lines changed

.codegen/.gitignore

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

.codegen/codemods/no_link_backticks/no_link_backticks.py

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

.codegen/codemods/test_language/test_language.py

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

.codegen/codemods/update_loggers/update_loggers.py

Lines changed: 0 additions & 18 deletions
This file was deleted.
Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,8 @@
1-
# yaml-language-server: $schema=https://json.schemastore.org/github-action.json
2-
name: "Setup OSS repos"
3-
description: "Setup OSS repos"
4-
# TODO: add size filter
1+
name: "Setup OSS repos (disabled)"
2+
description: "OSS repos setup has been disabled"
53
runs:
64
using: "composite"
75
steps:
8-
- name: Cache oss-repos
9-
id: cache-oss-repos
10-
uses: actions/cache@v4
11-
with:
12-
path: oss_repos
13-
key: ${{ runner.os }}-repo-cache-2-${{hashFiles('codegen-backend/codegen_tests/graph_sitter/codemod/repos/open_source/*.json')}}
14-
- name: Populate oss-repos if the cache is empty
15-
if: steps.cache-oss-repos.outputs.cache-hit != 'true'
6+
- name: Skip OSS repos setup
167
shell: bash
17-
run: |
18-
uv run --frozen python -m tests.shared.codemod.commands clone-repos --clean-cache
19-
env:
20-
GITHUB_WORKSPACE: $GITHUB_WORKSPACE
21-
- name: Verify cache contents
22-
shell: bash
23-
run: ls -la $GITHUB_WORKSPACE/oss_repos/
8+
run: echo "OSS repos setup is disabled"

.github/workflows/pre-commit.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,9 @@ jobs:
3737
- run: uv run --frozen pre-commit run --show-diff-on-failure --color=always --all-files --source ${{ github.event.pull_request.base.sha || github.event.before }} --origin ${{ github.event.pull_request.head.sha || github.event.after }}
3838
shell: bash
3939

40-
- uses: stefanzweifel/git-auto-commit-action@v5
41-
if: ${{ always() && env.REPO_SCOPED_TOKEN && github.event_name == 'pull_request' }}
42-
with:
43-
commit_message: "Automated pre-commit update"
44-
push_options: "--no-verify"
40+
# Temporarily disabled to prevent infinite loop with version updates
41+
# - uses: stefanzweifel/git-auto-commit-action@v5
42+
# if: ${{ always() && env.REPO_SCOPED_TOKEN && github.event_name == 'pull_request' }}
43+
# with:
44+
# commit_message: "Automated pre-commit update"
45+
# push_options: "--no-verify"

.github/workflows/release.yml

Lines changed: 8 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -26,22 +26,8 @@ permissions:
2626

2727
jobs:
2828
build:
29-
name: Build 3.${{ matrix.python }} ${{ matrix.os }}
30-
runs-on: ${{ matrix.os }}
31-
strategy:
32-
fail-fast: false
33-
matrix:
34-
os: [
35-
ubuntu-latest,
36-
ubuntu-22.04-arm, # https://github.com/actions/partner-runner-images/issues/37 https://github.com/orgs/community/discussions/148648#discussioncomment-12099554
37-
macos-latest,
38-
macos-14-large
39-
]
40-
python: [
41-
12,
42-
13,
43-
]
44-
29+
name: Build Pure Python Wheel
30+
runs-on: ubuntu-latest
4531
steps:
4632
- name: Github context
4733
env:
@@ -58,28 +44,25 @@ jobs:
5844
uses: astral-sh/[email protected]
5945
id: setup-uv
6046
with:
61-
enable-cache: false
47+
enable-cache: true
6248
prune-cache: false
63-
python-version: 3.${{ matrix.python }}
49+
python-version: "3.12" # Use single Python version for building
6450
version: '0.5.24'
65-
cache-suffix: 3.${{ matrix.python }}
6651

6752
- name: Fetch tags
6853
if: ${{ inputs.release-tag || startsWith(github.ref, 'refs/tags/') }}
6954
run: |
7055
git branch
7156
git fetch --depth=1 origin +refs/tags/*:refs/tags/*
7257
73-
# TODO: add cbuildwheel cache
7458
- name: Build wheel
75-
uses: pypa/[email protected]
76-
env:
77-
CIBW_BUILD: "*cp3${{ matrix.python }}*"
59+
run: |
60+
uv build --wheel --out-dir dist/
7861
7962
- uses: actions/upload-artifact@v4
8063
with:
81-
name: wheels-${{ matrix.os }}-3.${{ matrix.python }}
82-
path: ./wheelhouse/*.whl
64+
name: wheels
65+
path: ./dist/*.whl
8366

8467
release:
8568
if: ${{ inputs.release-tag || startsWith(github.ref, 'refs/tags/') }}

.github/workflows/test.yml

Lines changed: 0 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -99,76 +99,7 @@ jobs:
9999
env:
100100
GITHUB_WORKSPACE: $GITHUB_WORKSPACE
101101

102-
parse-tests:
103-
needs: access-check
104-
if: contains(github.event.pull_request.labels.*.name, 'parse-tests') || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
105-
runs-on: ubuntu-latest-32
106-
steps:
107-
- uses: actions/checkout@v4
108-
with:
109-
ref: ${{ github.event.pull_request.head.sha }}
110-
111-
- name: Setup environment
112-
uses: ./.github/actions/setup-environment
113-
114-
- name: Cache oss-repos
115-
uses: ./.github/actions/setup-oss-repos
116-
117-
- name: Install yarn and pnpm
118-
run: |
119-
npm install -g yarn &
120-
npm install -g pnpm
121102

122-
- name: Test with pytest
123-
timeout-minutes: 15
124-
env:
125-
GITHUB_WORKSPACE: $GITHUB_WORKSPACE
126-
run: |
127-
uv run pytest \
128-
-n auto \
129-
-o junit_suite_name="${{github.job}}" \
130-
tests/integration/codemod/test_parse.py
131-
132-
- uses: ./.github/actions/report
133-
with:
134-
flag: no-flag
135-
codecov_token: ${{ secrets.CODECOV_TOKEN }}
136-
137-
- name: Notify parse tests failure
138-
uses: slackapi/[email protected]
139-
if: failure() && github.event_name == 'push' && false
140-
with:
141-
webhook: ${{ secrets.SLACK_WEBHOOK_URL }}
142-
webhook-type: incoming-webhook
143-
payload: |
144-
{
145-
"blocks": [
146-
{
147-
"type": "header",
148-
"text": {
149-
"type": "plain_text",
150-
"text": "❌ Parse Tests Failed",
151-
"emoji": true
152-
}
153-
},
154-
{
155-
"type": "section",
156-
"text": {
157-
"type": "mrkdwn",
158-
"text": "*Branch:* ${{ github.ref_name }}\n*Triggered by:* <${{ github.server_url }}/${{ github.actor }}|@${{ github.actor }}>\n\n*Details:*\n• <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View workflow run>"
159-
}
160-
},
161-
{
162-
"type": "context",
163-
"elements": [
164-
{
165-
"type": "mrkdwn",
166-
"text": "Failed at <!date^${{ github.event.head_commit.timestamp }}^{date_num} {time}|just now>"
167-
}
168-
]
169-
}
170-
]
171-
}
172103

173104
integration-tests:
174105
needs: access-check

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ alembic_versions_backup
5757
/.nvmrc
5858
**/build/test-results/test/TEST*.xml
5959
src/codegen/sdk/__init__.py
60+
src/codegen/_version.py
6061
src/**/*.html
6162
.ccache/
6263
uv-*.tar.gz

.pre-commit-config.yaml

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
default_language_version:
22
python: python3.13
33
repos:
4-
54
- repo: https://github.com/ComPWA/taplo-pre-commit
65
rev: v0.9.3
76
hooks:
@@ -24,12 +23,7 @@ repos:
2423
- id: biome-check
2524
language: node
2625
additional_dependencies: ["@biomejs/[email protected]"]
27-
exclude: (src/codemods/eval)|(tests/unit/skills/snapshots)|(tests/unit/codegen/sdk/output)|(tests/integration/verified_codemods)|(docs/samples)
28-
- repo: https://github.com/MarcoGorelli/cython-lint
29-
rev: v0.16.6
30-
hooks:
31-
- id: cython-lint
32-
- id: double-quote-cython-strings
26+
exclude: (src/codemods/eval)|(tests/unit/skills/snapshots)|(tests/unit/codegen/sdk/output)|(tests/integration/verified_codemods)|(docs/)
3327

3428
- repo: https://github.com/kynan/nbstripout
3529
rev: 0.8.1
@@ -88,13 +82,13 @@ repos:
8882
args: ["--frozen", "--all-packages", "--all-extras"]
8983

9084
- repo: https://github.com/hukkin/mdformat
91-
rev: 0.7.22 # Use the ref you want to point at
85+
rev: 0.7.22 # Use the ref you want to point at
9286
hooks:
93-
- id: mdformat
94-
language: python
95-
# Optionally add plugins
96-
additional_dependencies:
97-
- mdformat-gfm
98-
- mdformat-ruff
99-
- mdformat-config
100-
- mdformat-pyproject
87+
- id: mdformat
88+
language: python
89+
# Optionally add plugins
90+
additional_dependencies:
91+
- mdformat-gfm
92+
- mdformat-ruff
93+
- mdformat-config
94+
- mdformat-pyproject

Dockerfile

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

architecture/1. plumbing/file-discovery.md

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

0 commit comments

Comments
 (0)