Skip to content

Commit 7a713d8

Browse files
author
Hakan Bogan
committed
developed baseline
1 parent 283fdad commit 7a713d8

66 files changed

Lines changed: 10804 additions & 1 deletion

Some content is hidden

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

.github/workflows/ci.yml

Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
"""GitHub Actions CI/CD configuration."""
2+
3+
name: CI
4+
5+
on:
6+
push:
7+
branches: [main, develop]
8+
pull_request:
9+
branches: [main, develop]
10+
11+
jobs:
12+
lint:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v3
16+
17+
- name: Set up Python
18+
uses: actions/setup-python@v4
19+
with:
20+
python-version: "3.11"
21+
22+
- name: Install Poetry
23+
uses: snok/install-poetry@v1
24+
with:
25+
version: 1.7.0
26+
27+
- name: Install dependencies
28+
run: |
29+
poetry install --no-interaction
30+
31+
- name: Run ruff
32+
run: |
33+
poetry run ruff check .
34+
35+
- name: Run mypy
36+
run: |
37+
poetry run mypy . --ignore-missing-imports
38+
39+
test:
40+
runs-on: ubuntu-latest
41+
strategy:
42+
matrix:
43+
python-version: ["3.11", "3.12"]
44+
45+
steps:
46+
- uses: actions/checkout@v3
47+
48+
- name: Set up Python ${{ matrix.python-version }}
49+
uses: actions/setup-python@v4
50+
with:
51+
python-version: ${{ matrix.python-version }}
52+
53+
- name: Install Poetry
54+
uses: snok/install-poetry@v1
55+
with:
56+
version: 1.7.0
57+
58+
- name: Install dependencies
59+
run: |
60+
poetry install --no-interaction
61+
62+
- name: Run tests
63+
run: |
64+
poetry run pytest -v --cov=. --cov-report=xml
65+
env:
66+
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
67+
68+
- name: Upload coverage
69+
uses: codecov/codecov-action@v3
70+
with:
71+
file: ./coverage.xml
72+
fail_ci_if_error: false
73+
74+
integration:
75+
runs-on: ubuntu-latest
76+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
77+
78+
steps:
79+
- uses: actions/checkout@v3
80+
81+
- name: Set up Python
82+
uses: actions/setup-python@v4
83+
with:
84+
python-version: "3.11"
85+
86+
- name: Install Poetry
87+
uses: snok/install-poetry@v1
88+
with:
89+
version: 1.7.0
90+
91+
- name: Install dependencies
92+
run: |
93+
poetry install --no-interaction --with tools
94+
95+
- name: Install analysis tools
96+
run: |
97+
pip install semgrep bandit
98+
99+
- name: Run integration tests
100+
run: |
101+
poetry run pytest tests/e2e/ -v
102+
env:
103+
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
104+

.gitignore

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# Python
2+
__pycache__/
3+
*.py[cod]
4+
*$py.class
5+
*.so
6+
.Python
7+
build/
8+
develop-eggs/
9+
dist/
10+
downloads/
11+
eggs/
12+
.eggs/
13+
lib/
14+
lib64/
15+
parts/
16+
sdist/
17+
var/
18+
wheels/
19+
*.egg-info/
20+
.installed.cfg
21+
*.egg
22+
23+
# Virtual environments
24+
venv/
25+
env/
26+
ENV/
27+
.venv
28+
29+
# IDE
30+
.vscode/
31+
.idea/
32+
*.swp
33+
*.swo
34+
*~
35+
.DS_Store
36+
37+
# Testing
38+
.coverage
39+
.coverage.*
40+
htmlcov/
41+
.pytest_cache/
42+
.mypy_cache/
43+
.ruff_cache/
44+
45+
# Logs
46+
*.log
47+
logs/
48+
49+
# Environment
50+
.env
51+
.env.local
52+
53+
# Artifacts & Data
54+
artifacts/
55+
eval/dataset/prs/
56+
eval/results/
57+
*.db
58+
59+
# Temporary files
60+
tmp/
61+
temp/
62+
*.tmp
63+

0 commit comments

Comments
 (0)