diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 499f48f0ec..608304ed06 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -97,9 +97,7 @@ jobs: - name: Install dependencies working-directory: ./python run: | - source .env/bin/activate - python -m pip install --upgrade pip - pip install mypy-protobuf + apt install -y mypy-protobuf - name: Build Python wrapper uses: ./.github/workflows/build-python-wrapper @@ -123,7 +121,6 @@ jobs: - name: Test with pytest working-directory: ./python run: | - source .env/bin/activate cd python/tests/ pytest --asyncio-mode=auto --html=pytest_report.html --self-contained-html @@ -189,7 +186,6 @@ jobs: - name: Test pubsub with pytest working-directory: ./python run: | - source .env/bin/activate cd python/tests/ pytest --asyncio-mode=auto -k test_pubsub --html=pytest_report.html --self-contained-html @@ -219,23 +215,18 @@ jobs: if: always() working-directory: ./python run: | - python3 -m venv .env - source .env/bin/activate - python -m pip install --upgrade pip - pip install flake8 isort black + sudo apt install -y flake8 isort black - name: Lint python with isort if: always() working-directory: ./python run: | - source .env/bin/activate isort . --profile black --check --diff - name: Lint python with flake8 if: always() working-directory: ./python run: | - source .env/bin/activate # stop the build if there are Python syntax errors or undefined names flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics --extend-ignore=E230 --exclude=python/glide/protobuf,.env/* # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide @@ -245,7 +236,6 @@ jobs: if: always() working-directory: ./python run: | - source .env/bin/activate black --check --diff . build-amazonlinux-latest: @@ -283,7 +273,6 @@ jobs: - name: Test compatibility with pytest working-directory: ./python run: | - source .env/bin/activate pytest --asyncio-mode=auto -m smoke_test --html=pytest_report.html --self-contained-html - name: Upload test reports @@ -355,7 +344,6 @@ jobs: - name: Test with pytest working-directory: ./python run: | - source .env/bin/activate cd python/tests/ pytest --asyncio-mode=auto --tls --cluster-endpoints=${{ secrets.MEMDB_MODULES_ENDPOINT }} -k server_modules --html=pytest_report.html --self-contained-html