Skip to content

Commit 7b6df4e

Browse files
authored
Merge pull request #15 from JustAGhosT/chore/continue-consolidation-plan
Chore/continue-consolidation-plan
2 parents 9b4dfa1 + 939e711 commit 7b6df4e

127 files changed

Lines changed: 3770 additions & 1403 deletions

File tree

Some content is hidden

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

.github/workflows/README.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,18 @@ The monorepo uses a combination of engine-specific workflows, path-aware compone
88

99
### Workflow Overview
1010

11-
| Workflow | Purpose | Triggers |
12-
| --- | --- | --- |
13-
| `ci.yml` | Engine test and build validation | Push, PR, manual |
14-
| `lint.yml` | Engine lint and type checks | Push, PR |
15-
| `security.yml` | Engine dependency and filesystem security checks | Push, PR, schedule |
16-
| `monorepo-ci.yml` | Path-aware builds for engine, desktop, website, orchestration utils, and VS Code extension | Push, PR, manual |
17-
| `release.yml` | Engine package release | Tags, manual |
18-
| `release-desktop.yml` | Desktop release build | Tags, manual |
19-
| `release-website.yml` | Website release build | Tags, manual |
20-
| `release-vscode-extension.yml` | VS Code extension release packaging | Tags, manual |
21-
| `release-orchestration-utils.yml` | Shared utility package release build | Tags, manual |
22-
| `deploy-autopr-engine.yml` | Engine container build and Azure deployment | Push to `master`, PR, manual |
11+
| Workflow | Purpose | Triggers |
12+
| --------------------------------- | ------------------------------------------------------------------------------------------ | ---------------------------- |
13+
| `ci.yml` | Engine test and build validation | Push, PR, manual |
14+
| `lint.yml` | Engine lint and type checks | Push, PR |
15+
| `security.yml` | Engine dependency and filesystem security checks | Push, PR, schedule |
16+
| `monorepo-ci.yml` | Path-aware builds for engine, desktop, website, orchestration utils, and VS Code extension | Push, PR, manual |
17+
| `release.yml` | Engine package release | Tags, manual |
18+
| `release-desktop.yml` | Desktop release build | Tags, manual |
19+
| `release-website.yml` | Website release build | Tags, manual |
20+
| `release-vscode-extension.yml` | VS Code extension release packaging | Tags, manual |
21+
| `release-orchestration-utils.yml` | Shared utility package release build | Tags, manual |
22+
| `deploy-autopr-engine.yml` | Engine container build and Azure deployment | Push to `master`, PR, manual |
2323

2424
## Workflow Details
2525

@@ -143,17 +143,17 @@ env:
143143

144144
Set these in GitHub repository settings:
145145

146-
| Variable | Description | Default |
147-
| ----------------------- | ------------------------ | ------- |
146+
| Variable | Description | Default |
147+
| ------------------------- | ------------------------ | ------- |
148148
| `CODEFLOW_VOLUME_PR` | Volume for pull requests | 100 |
149149
| `CODEFLOW_VOLUME_CHECKIN` | Volume for pushes | 50 |
150150
| `CODEFLOW_VOLUME_DEV` | Volume for development | 200 |
151151

152152
### Environment Variables
153153

154-
| Variable | Description | Default |
155-
| ------------------------- | ------------------------- | ------- |
156-
| `PYTHON_VERSION` | Python version to use | 3.13 |
154+
| Variable | Description | Default |
155+
| --------------------------- | ------------------------- | ------- |
156+
| `PYTHON_VERSION` | Python version to use | 3.13 |
157157
| `CODEFLOW_PRECOMMIT_VOLUME` | Pre-commit volume | 100 |
158158
| `CODEFLOW_BG_BATCH` | Background fix batch size | 30 |
159159

.github/workflows/ci.yml

Lines changed: 84 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ name: CI
33
on:
44
workflow_dispatch:
55
push:
6-
branches: [ master, develop ]
6+
branches: [master, develop]
77
paths:
8-
- 'engine/**'
9-
- '.github/workflows/ci.yml'
8+
- "engine/**"
9+
- ".github/workflows/ci.yml"
1010
pull_request:
11-
branches: [ master, develop ]
11+
branches: [master, develop]
1212
paths:
13-
- 'engine/**'
14-
- '.github/workflows/ci.yml'
13+
- "engine/**"
14+
- ".github/workflows/ci.yml"
1515

1616
jobs:
1717
test:
@@ -21,92 +21,91 @@ jobs:
2121
working-directory: engine
2222
strategy:
2323
matrix:
24-
python-version: ['3.12', '3.13']
25-
24+
python-version: ["3.12", "3.13"]
25+
2626
steps:
27-
- uses: actions/checkout@v4
28-
29-
- name: Set up Python ${{ matrix.python-version }}
30-
uses: actions/setup-python@v5
31-
with:
32-
python-version: ${{ matrix.python-version }}
33-
cache: 'pip'
34-
35-
- name: Install Poetry
36-
uses: snok/install-poetry@v1
37-
with:
38-
version: latest
39-
virtualenvs-create: true
40-
virtualenvs-in-project: true
41-
42-
- name: Install dependencies
43-
run: |
44-
poetry install --with dev --no-root
45-
46-
- name: Install package
47-
run: poetry install --no-dev
48-
49-
- name: Run tests with coverage
50-
run: |
51-
poetry run pytest --cov=codeflow_engine --cov-report=xml --cov-report=term --cov-report=html
52-
53-
- name: Upload coverage to Codecov
54-
uses: codecov/codecov-action@v4
55-
with:
56-
file: ./engine/coverage.xml
57-
flags: unittests
58-
name: codecov-umbrella
59-
fail_ci_if_error: false
60-
token: ${{ secrets.CODECOV_TOKEN }}
61-
62-
- name: Check coverage threshold
63-
run: |
64-
poetry run coverage report --fail-under=70 || echo "Coverage below 70% - this is a warning, not a failure"
65-
66-
- name: Upload coverage HTML report
67-
uses: actions/upload-artifact@v4
68-
if: always()
69-
with:
70-
name: coverage-report-${{ matrix.python-version }}
71-
path: engine/htmlcov/
72-
73-
- name: Run linting
74-
run: |
75-
poetry run ruff check .
76-
poetry run mypy codeflow_engine
27+
- uses: actions/checkout@v4
28+
29+
- name: Set up Python ${{ matrix.python-version }}
30+
uses: actions/setup-python@v5
31+
with:
32+
python-version: ${{ matrix.python-version }}
33+
cache: "pip"
34+
35+
- name: Install Poetry
36+
uses: snok/install-poetry@v1
37+
with:
38+
version: latest
39+
virtualenvs-create: true
40+
virtualenvs-in-project: true
41+
42+
- name: Install dependencies
43+
run: |
44+
poetry install --with dev --no-root
45+
46+
- name: Install package
47+
run: poetry install --no-dev
48+
49+
- name: Run tests with coverage
50+
run: |
51+
poetry run pytest --cov=codeflow_engine --cov-report=xml --cov-report=term --cov-report=html
52+
53+
- name: Upload coverage to Codecov
54+
uses: codecov/codecov-action@v4
55+
with:
56+
file: ./engine/coverage.xml
57+
flags: unittests
58+
name: codecov-umbrella
59+
fail_ci_if_error: false
60+
token: ${{ secrets.CODECOV_TOKEN }}
61+
62+
- name: Check coverage threshold
63+
run: |
64+
poetry run coverage report --fail-under=70 || echo "Coverage below 70% - this is a warning, not a failure"
65+
66+
- name: Upload coverage HTML report
67+
uses: actions/upload-artifact@v4
68+
if: always()
69+
with:
70+
name: coverage-report-${{ matrix.python-version }}
71+
path: engine/htmlcov/
72+
73+
- name: Run linting
74+
run: |
75+
poetry run ruff check .
76+
poetry run mypy codeflow_engine
7777
7878
build:
7979
runs-on: ubuntu-latest
8080
needs: test
8181
defaults:
8282
run:
8383
working-directory: engine
84-
84+
8585
steps:
86-
- uses: actions/checkout@v4
87-
88-
- name: Set up Python
89-
uses: actions/setup-python@v5
90-
with:
91-
python-version: '3.12'
92-
cache: 'pip'
93-
94-
- name: Install Poetry
95-
uses: snok/install-poetry@v1
96-
with:
97-
version: latest
98-
virtualenvs-create: true
99-
virtualenvs-in-project: true
100-
101-
- name: Build package
102-
run: poetry build
103-
104-
- name: Check package
105-
run: poetry check
106-
107-
- name: Upload artifacts
108-
uses: actions/upload-artifact@v4
109-
with:
110-
name: engine-dist
111-
path: engine/dist/*
86+
- uses: actions/checkout@v4
87+
88+
- name: Set up Python
89+
uses: actions/setup-python@v5
90+
with:
91+
python-version: "3.12"
92+
cache: "pip"
93+
94+
- name: Install Poetry
95+
uses: snok/install-poetry@v1
96+
with:
97+
version: latest
98+
virtualenvs-create: true
99+
virtualenvs-in-project: true
100+
101+
- name: Build package
102+
run: poetry build
103+
104+
- name: Check package
105+
run: poetry check
112106

107+
- name: Upload artifacts
108+
uses: actions/upload-artifact@v4
109+
with:
110+
name: engine-dist
111+
path: engine/dist/*

.github/workflows/deploy-autopr-engine.yml

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ on:
55
branches:
66
- master
77
paths:
8-
- 'engine/**'
9-
- '.github/workflows/deploy-autopr-engine.yml'
10-
- '.github/app-manifest.yml'
8+
- "engine/**"
9+
- ".github/workflows/deploy-autopr-engine.yml"
10+
- ".github/app-manifest.yml"
1111
pull_request:
1212
paths:
13-
- 'engine/**'
14-
- '.github/workflows/deploy-autopr-engine.yml'
15-
- '.github/app-manifest.yml'
16-
- '.codeflow.yml'
13+
- "engine/**"
14+
- ".github/workflows/deploy-autopr-engine.yml"
15+
- ".github/app-manifest.yml"
16+
- ".codeflow.yml"
1717
workflow_dispatch:
1818

1919
env:
@@ -189,9 +189,9 @@ jobs:
189189
RESOURCE_GROUP="prod-rg-san-codeflow"
190190
ENV_NAME="prod-codeflow-san-env"
191191
CUSTOM_DOMAIN="app.codeflow.io"
192-
192+
193193
echo "[*] Checking for existing managed certificates for domain: $CUSTOM_DOMAIN"
194-
194+
195195
# Check if environment exists
196196
if az containerapp env show -n $ENV_NAME -g $RESOURCE_GROUP &>/dev/null; then
197197
echo "Environment exists, checking for duplicate certificates..."
@@ -259,7 +259,7 @@ jobs:
259259
--name codeflow-engine \
260260
--query properties.outputs \
261261
--output json)
262-
262+
263263
echo "container_app_url=$(echo $OUTPUTS | jq -r '.containerAppUrl.value')" >> $GITHUB_OUTPUT
264264
echo "custom_domain=$(echo $OUTPUTS | jq -r '.customDomain.value')" >> $GITHUB_OUTPUT
265265
echo "postgres_fqdn=$(echo $OUTPUTS | jq -r '.postgresFqdn.value')" >> $GITHUB_OUTPUT
@@ -281,4 +281,3 @@ jobs:
281281
echo "3. Azure will automatically provision and bind the SSL certificate (5-15 minutes)"
282282
echo ""
283283
echo "[*] For troubleshooting, see: infrastructure/bicep/FAQ.md"
284-

.github/workflows/lint.yml

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@ name: Lint
22

33
on:
44
push:
5-
branches: [ master, develop ]
5+
branches: [master, develop]
66
paths:
7-
- 'engine/**'
8-
- '.github/workflows/lint.yml'
7+
- "engine/**"
8+
- ".github/workflows/lint.yml"
99
pull_request:
10-
branches: [ master, develop ]
10+
branches: [master, develop]
1111
paths:
12-
- 'engine/**'
13-
- '.github/workflows/lint.yml'
12+
- "engine/**"
13+
- ".github/workflows/lint.yml"
1414

1515
jobs:
1616
ruff:
@@ -21,26 +21,26 @@ jobs:
2121
working-directory: engine
2222
steps:
2323
- uses: actions/checkout@v4
24-
24+
2525
- name: Set up Python
2626
uses: actions/setup-python@v5
2727
with:
28-
python-version: '3.12'
29-
cache: 'pip'
30-
28+
python-version: "3.12"
29+
cache: "pip"
30+
3131
- name: Install Poetry
3232
uses: snok/install-poetry@v1
3333
with:
3434
version: latest
3535
virtualenvs-create: true
3636
virtualenvs-in-project: true
37-
37+
3838
- name: Install dependencies
3939
run: poetry install --with dev --no-root
40-
40+
4141
- name: Run Ruff
4242
run: poetry run ruff check .
43-
43+
4444
- name: Run Ruff format check
4545
run: poetry run ruff format --check .
4646

@@ -52,23 +52,22 @@ jobs:
5252
working-directory: engine
5353
steps:
5454
- uses: actions/checkout@v4
55-
55+
5656
- name: Set up Python
5757
uses: actions/setup-python@v5
5858
with:
59-
python-version: '3.12'
60-
cache: 'pip'
61-
59+
python-version: "3.12"
60+
cache: "pip"
61+
6262
- name: Install Poetry
6363
uses: snok/install-poetry@v1
6464
with:
6565
version: latest
6666
virtualenvs-create: true
6767
virtualenvs-in-project: true
68-
68+
6969
- name: Install dependencies
7070
run: poetry install --with dev --no-root
71-
71+
7272
- name: Run MyPy
7373
run: poetry run mypy codeflow_engine --ignore-missing-imports
74-

0 commit comments

Comments
 (0)