Skip to content

Updating dependencies #615

Updating dependencies

Updating dependencies #615

Workflow file for this run

name: main
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
check:
# runs-on: ubuntu-20.04 # means github.com
runs-on: [self-hosted, linux, X64] # means matterhorn
steps:
- uses: actions/checkout@v3
# must be skipped on self-hosted build slaves (eg matterhorn)
#
# - name: Install OS package dependencies
# run: |
# sudo apt update
# sudo apt install libenchant-dev
# sudo apt install libbz2-dev
# sudo apt install libsnappy-dev
# sudo apt install libunwind-dev
- name: Set up Python 3.11
uses: actions/setup-python@v3
with:
python-version: '3.11'
architecture: 'x64'
- name: Install Python package dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements-dev.txt
- name: Run Flake8
run: tox -c tox.ini -e flake8
- name: Run Yapf
run: tox -c tox.ini -e yapf
- name: Run MyPy
run: tox -c tox.ini -e mypy
- name: Run Bandit
run: tox -c tox.ini -e bandit
analyze:
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language: [ 'python' ]
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
docs:
# runs-on: ubuntu-20.04 # means github.com
runs-on: [self-hosted, linux, X64] # means matterhorn
steps:
- uses: actions/checkout@v3
# must be skipped on self-hosted build slaves (eg matterhorn)
#
# - name: Install OS package dependencies
# run: |
# sudo apt update
# sudo apt install libenchant-dev
# sudo apt install libbz2-dev
# sudo apt install libsnappy-dev
# sudo apt install libunwind-dev
- name: Set up Python 3.11
uses: actions/setup-python@v3
with:
python-version: '3.11'
architecture: 'x64'
- name: Install Python package dependencies
run: |
pip install -r requirements-dev.txt
pip install -U pip setuptools
- name: Install Crossbar.io packages
run: |
pip install -U --force-reinstall -r requirements-latest.txt
pip install .
- name: Run Sphinx
run: tox -c tox.ini -e sphinx
unit-test-amd64:
# runs-on: ubuntu-20.04 # means github.com
runs-on: [self-hosted, linux, X64] # means matterhorn
env:
CB_FULLTESTS: 1
# Test on specific CPython & PyPy versions
strategy:
matrix:
# https://github.com/actions/setup-python#specifying-a-pypy-version
python-version: ['3.11', 'pypy-3.9']
# https://github.blog/changelog/2020-04-15-github-actions-new-workflow-features/
# https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-syntax-for-github-actions#jobsjob_idstepscontinue-on-error
continue-on-error: false
steps:
# Checkout sources
- uses: actions/checkout@v3
# must be skipped on self-hosted build slaves (eg matterhorn)
#
# Install OS packages, as we install Python packages from source:
# libenchant-dev: needed for pyenchant, needed for sphinx-spellcheck
# libbz2-dev, libsnappy-dev: needed for compression
# libunwind-dev: needed for vmprof
# - name: Install OS package dependencies
# run: |
# sudo apt update
# sudo apt install build-essential libssl-dev libffi-dev libunwind-dev \
# libreadline-dev zlib1g-dev libbz2-dev libsqlite3-dev libncurses5-dev \
# libsnappy-dev
# Use this Python
# https://github.com/actions/setup-python/blob/main/README.md
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install Python package dependencies
run: |
pip install -r requirements-dev.txt
pip install -U pip setuptools
- name: Install Crossbar.io packages
run: |
pip install -U --force-reinstall -r requirements-latest.txt
pip install .
- name: Display Crossbar.io version
run: |
crossbar version
- name: Run Python import tests
run: |
python ./test/test_imports.py
- name: Run unit tests (trial)
run: |
python -m twisted.trial crossbar
- name: Run unit tests (pytest)
run: |
pytest -sv crossbar
functional-test-amd64:
runs-on: [self-hosted, linux, X64] # means matterhorn
strategy:
matrix:
python-version: ['3.11']
continue-on-error: false
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install Python package dependencies
run: |
pip install -r requirements-dev.txt
pip install -U pip setuptools
- name: Install Crossbar.io packages
run: |
pip install -U --force-reinstall -r requirements-latest.txt
pip install .
- name: Display Crossbar.io version
run: |
crossbar version
- name: Run integration tests (Autobahn|Python Client)
run: |
./test/test_ab_examples.sh
- name: Run functional tests - cbtests
run: |
pytest -sv --no-install ./test/functests/cbtests
# FIXME
# - name: Run functional tests - cfctests
# run: |
# pytest -sv --no-install ./test/functests/cfctests
# - name: Run command line tests (Crossbar.io CLI) 0
# run: |
# ./test/test_cli_0.sh
# - name: Run command line tests (Crossbar.io CLI) 0
# run: |
# ./test/test_cli_1.sh
# - name: Run command line tests (Crossbar.io CLI) 0
# run: |
# ./test/test_cli_2.sh
# - name: Run command line tests (Crossbar.io CLI) 0
# run: |
# ./test/test_cli_3.sh
# FIXME: https://github.com/crossbario/crossbar/issues/1842
#
# test-arm64:
# env:
# CB_FULLTESTS: 1
# # https://github.blog/changelog/2019-12-03-github-actions-self-hosted-runners-on-arm-architectures/
# # https://medium.com/@nabil.servais/using-github-actions-to-test-your-go-code-on-arm64-ce581e646cb
# runs-on: [self-hosted, linux, ARM64]
# strategy:
# matrix:
# # https://github.com/actions/setup-python#specifying-a-pypy-version
# # https://downloads.python.org/pypy/versions.json
# python-version: ['3.x', 'pypy-3.7-nightly']
# # https://github.blog/changelog/2020-04-15-github-actions-new-workflow-features/
# # https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-syntax-for-github-actions#jobsjob_idstepscontinue-on-error
# continue-on-error: false
# steps:
# # Checkout sources
# - uses: actions/checkout@v3
# # Use this Python
# # https://github.com/marketplace/actions/setup-python
# # https://github.com/actions/setup-python/blob/main/README.md
# # https://docs.github.com/en/free-pro-team@latest/actions/guides/building-and-testing-python#specifying-a-python-version
# # https://github.com/actions/setup-python/issues/45
# # https://github.com/sqlalchemy/sqlalchemy/blob/master/.github/workflows/create-wheels.yaml
# - name: Set up Python ${{ matrix.python-version }}
# uses: actions/setup-python@v3
# with:
# python-version: ${{ matrix.python-version }}
# architecture: aarch64
# - name: Install Python package dependencies
# run: |
# python -V
# python -m ensurepip
# python -m pip install -r requirements-dev.txt
# - name: Install Crossbar.io package dependencies & Crossbar.io
# run: |
# python -m pip install -r requirements-latest.txt
# python -m pip install .
# - name: Display Crossbar.io version
# run: |
# python -c "from autobahn import xbr; print(xbr.HAS_XBR)"
# python -c "import crossbar; print(crossbar.__version__)"
# - name: Run unit tests (Twisted Trial)
# run: |
# python -m twisted.trial crossbar
# - name: Run integration tests (Autobahn|Python Client)
# run: |
# ./test/test_ab_examples.sh