Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: testing workflow #34515

Closed
wants to merge 25 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions .github/workflows/check_dependencies.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Check Python Dependencies

on:
pull_request:

defaults:
run:
shell: bash # strict bash

jobs:
check_dependencies:
runs-on: ubuntu-latest

steps:
- name: Checkout Repository
uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.8'

- name: Create repo_work directory
run: |
WORK_DIR="/tmp/unpack_reqs"
repo_name="${{ github.repository }}"
repo_work="$WORK_DIR/$repo_name"
mkdir -p "$repo_work"
echo "$repo_work"

- name: Copy Python requirements file
run: |
for req_file in "requirements/edx/kernel.in"; do
if [ -f "$req_file" ]; then
cp "$req_file" /tmp/unpack_reqs/openedx/edx-platform/base.txt
echo "Python requirements file found: $req_file"
echo "Content of base.txt:"
cat "$req_file"
break
fi
done

- name: Install requests module
run: pip install requests

- name: Install requests module
run: pip install rich

- name: Make the script files executable
run: chmod +x find_dependencies.py
working-directory: ./scripts

- name: Run Python script
run: python find_dependencies.py edx-platform --org edx
working-directory: ./scripts

9 changes: 9 additions & 0 deletions requirements/common_constraints.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,12 @@ Django<5.0
elasticsearch<7.14.0

# django-simple-history>3.0.0 adds indexing and causes a lot of migrations to be affected

# opentelemetry requires version 6.x at the moment:
# https://github.com/open-telemetry/opentelemetry-python/issues/3570
# Normally this could be added as a constraint in edx-django-utils, where we're
# adding the opentelemetry dependency. However, when we compile pip-tools.txt,
# that uses version 7.x, and then there's no undoing that when compiling base.txt.
# So we need to pin it globally, for now.
# Ticket for unpinning: https://github.com/openedx/edx-lint/issues/407
importlib-metadata<7
22 changes: 11 additions & 11 deletions requirements/edx-sandbox/py38.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ cryptography==38.0.4
# -r requirements/edx-sandbox/py38.in
cycler==0.12.1
# via matplotlib
fonttools==4.49.0
fonttools==4.51.0
# via matplotlib
importlib-resources==6.1.1
importlib-resources==6.4.0
# via matplotlib
joblib==1.3.2
joblib==1.4.0
# via nltk
kiwisolver==1.4.5
# via matplotlib
Expand Down Expand Up @@ -56,25 +56,25 @@ numpy==1.22.4
# matplotlib
# openedx-calc
# scipy
openedx-calc==3.0.1
openedx-calc==3.1.0
# via -r requirements/edx-sandbox/py38.in
packaging==23.2
packaging==24.0
# via matplotlib
pillow==10.2.0
pillow==10.3.0
# via matplotlib
pycparser==2.21
pycparser==2.22
# via cffi
pyparsing==3.1.1
pyparsing==3.1.2
# via
# -r requirements/edx-sandbox/py38.in
# chem
# matplotlib
# openedx-calc
python-dateutil==2.8.2
python-dateutil==2.9.0.post0
# via matplotlib
random2==1.0.2
# via -r requirements/edx-sandbox/py38.in
regex==2023.12.25
regex==2024.4.16
# via nltk
scipy==1.7.3
# via
Expand All @@ -93,5 +93,5 @@ sympy==1.12
# openedx-calc
tqdm==4.66.2
# via nltk
zipp==3.17.0
zipp==3.18.1
# via importlib-resources
Loading