Skip to content

Commit

Permalink
Issue #48 - Collect Python dependencies in requirements-dev.txt (#403)
Browse files Browse the repository at this point in the history
  • Loading branch information
jiridanek authored May 2, 2022
1 parent be90ae4 commit 5a66820
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 13 deletions.
20 changes: 7 additions & 13 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ jobs:
run: python -m pip install setuptools wheel tox

- name: Install Linux build dependencies
if: ${{ runner.os == 'Linux' }}
run: |
sudo apt update; sudo apt install -y swig libpython3-dev libsasl2-dev libjsoncpp-dev libwebsockets-dev libnghttp2-dev ccache ninja-build pixz libbenchmark-dev
Expand Down Expand Up @@ -210,17 +209,16 @@ jobs:
python-version: 3.6
architecture: x64

- name: Install Python runtime/test dependencies
run: python -m pip install tox quart selectors h2 grpcio protobuf websockets pytest

- name: Install Linux runtime/test dependencies
if: ${{ runner.os == 'Linux' }}
run: |
sudo apt update; sudo apt install -y libsasl2-2 libsasl2-modules sasl2-bin libjsoncpp1 libwebsockets15 libbenchmark1 pixz bubblewrap curl ncat gdb elfutils findutils file python3-dbg
- name: Unpack archive
run: tar -I pixz -xf archive.tar.xz

- name: Install Python runtime/test dependencies
run: python -m pip install -r ${{github.workspace}}/skupper-router/requirements-dev.txt

- name: install qpid-proton python wheel
run: python -m pip install ${ProtonBuildDir}/python/pkgs/python_qpid_proton*.whl

Expand Down Expand Up @@ -376,7 +374,6 @@ jobs:
dnf config-manager --set-enabled powertools
- name: Install Linux build dependencies
if: ${{ runner.os == 'Linux' }}
run: |
dnf install -y gcc gcc-c++ cmake libuuid-devel openssl-devel cyrus-sasl-devel cyrus-sasl-plain swig python3-devel python3-pip make libwebsockets-devel libnghttp2-devel ccache libasan libubsan libtsan
Expand Down Expand Up @@ -447,15 +444,13 @@ jobs:
if: ${{ always() && runner.os == 'Linux' }}
run: env -0 | sort -z | tr '\0' '\n'

- name: Install Python runtime/test dependencies
run: python3 -m pip install tox quart selectors h2 protobuf websockets pytest
- name: Upgrade pip
run: python3 -m pip install --upgrade pip

- name: Install Python runtime/test dependencies (Fedora)
if: ${{ matrix.container == 'fedora' }}
run: python3 -m pip install grpcio
- name: Install Python runtime/test dependencies
run: python3 -m pip install -r ${{github.workspace}}/skupper-router/requirements-dev.txt

- name: Install Linux runtime/test dependencies
if: ${{ runner.os == 'Linux' }}
run: |
dnf install -y curl nmap-ncat gdb binutils elfutils elfutils-debuginfod-client findutils file
dnf debuginfo-install -y python3
Expand Down Expand Up @@ -533,7 +528,6 @@ jobs:
path: 'qpid-proton'

- name: Install Linux build dependencies
if: ${{ runner.os == 'Linux' }}
run: |
sudo apt update; sudo apt install -y python3-qpid-proton libpython3-dev ninja-build
Expand Down
15 changes: 15 additions & 0 deletions README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,21 @@ $ ./run.py

=== Test-only dependencies

.Install package dependencies (Fedora)
[source, shell script]
----
dnf install curl nmap-ncat
----

.Install Python test dependencies from `requirements-dev.txt`
[source, shell script]
----
python3 -m pip install --user --upgrade pip
python3 -m pip install --user -r ./requirements-dev.txt
----

==== Description of the individual dependencies

The HTTP2 system tests (`tests/system_tests_http2.py`) use the Python Quart and hyper-h2 frameworks to start a HTTP2 server.
The HTTP2 system tests only runs if

Expand Down
36 changes: 36 additions & 0 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License
#

# https://pip.pypa.io/en/stable/reference/requirements-file-format

--prefer-binary

setuptools
virtualenv
wheel
tox

pytest

grpcio
h2
protobuf
quart
selectors
websockets

0 comments on commit 5a66820

Please sign in to comment.