diff --git a/.github/workflows/core_contrib_test_0.yml b/.github/workflows/core_contrib_test_0.yml index aa5ca12b5e..6c0616e0a6 100644 --- a/.github/workflows/core_contrib_test_0.yml +++ b/.github/workflows/core_contrib_test_0.yml @@ -657,6 +657,28 @@ jobs: - name: Run tests run: tox -e py38-test-instrumentation-falcon-2 -- -ra + py38-test-instrumentation-falcon-3: + name: instrumentation-falcon-3 + runs-on: ubuntu-latest + steps: + - name: Checkout contrib repo @ SHA - ${{ env.CONTRIB_REPO_SHA }} + uses: actions/checkout@v4 + with: + repository: open-telemetry/opentelemetry-python-contrib + ref: ${{ env.CONTRIB_REPO_SHA }} + + - name: Set up Python 3.8 + uses: actions/setup-python@v5 + with: + python-version: "3.8" + architecture: "x64" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py38-test-instrumentation-falcon-3 -- -ra + py38-test-instrumentation-fastapi: name: instrumentation-fastapi runs-on: ubuntu-latest diff --git a/.github/workflows/test_0.yml b/.github/workflows/test_0.yml index 92352959e5..a0f561010e 100644 --- a/.github/workflows/test_0.yml +++ b/.github/workflows/test_0.yml @@ -2698,6 +2698,24 @@ jobs: - name: Run tests run: tox -e py38-test-instrumentation-falcon-2 -- -ra + py38-test-instrumentation-falcon-3_ubuntu-latest: + name: instrumentation-falcon-3 3.8 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.8 + uses: actions/setup-python@v5 + with: + python-version: "3.8" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py38-test-instrumentation-falcon-3 -- -ra + py39-test-instrumentation-falcon-0_ubuntu-latest: name: instrumentation-falcon-0 3.9 Ubuntu runs-on: ubuntu-latest @@ -2752,6 +2770,24 @@ jobs: - name: Run tests run: tox -e py39-test-instrumentation-falcon-2 -- -ra + py39-test-instrumentation-falcon-3_ubuntu-latest: + name: instrumentation-falcon-3 3.9 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.9 + uses: actions/setup-python@v5 + with: + python-version: "3.9" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py39-test-instrumentation-falcon-3 -- -ra + py310-test-instrumentation-falcon-1_ubuntu-latest: name: instrumentation-falcon-1 3.10 Ubuntu runs-on: ubuntu-latest @@ -2788,6 +2824,42 @@ jobs: - name: Run tests run: tox -e py310-test-instrumentation-falcon-2 -- -ra + py310-test-instrumentation-falcon-3_ubuntu-latest: + name: instrumentation-falcon-3 3.10 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.10 + uses: actions/setup-python@v5 + with: + python-version: "3.10" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py310-test-instrumentation-falcon-3 -- -ra + + py310-test-instrumentation-falcon-4_ubuntu-latest: + name: instrumentation-falcon-4 3.10 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.10 + uses: actions/setup-python@v5 + with: + python-version: "3.10" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py310-test-instrumentation-falcon-4 -- -ra + py311-test-instrumentation-falcon-1_ubuntu-latest: name: instrumentation-falcon-1 3.11 Ubuntu runs-on: ubuntu-latest @@ -2824,6 +2896,42 @@ jobs: - name: Run tests run: tox -e py311-test-instrumentation-falcon-2 -- -ra + py311-test-instrumentation-falcon-3_ubuntu-latest: + name: instrumentation-falcon-3 3.11 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.11 + uses: actions/setup-python@v5 + with: + python-version: "3.11" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py311-test-instrumentation-falcon-3 -- -ra + + py311-test-instrumentation-falcon-4_ubuntu-latest: + name: instrumentation-falcon-4 3.11 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.11 + uses: actions/setup-python@v5 + with: + python-version: "3.11" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py311-test-instrumentation-falcon-4 -- -ra + py312-test-instrumentation-falcon-1_ubuntu-latest: name: instrumentation-falcon-1 3.12 Ubuntu runs-on: ubuntu-latest @@ -2860,6 +2968,42 @@ jobs: - name: Run tests run: tox -e py312-test-instrumentation-falcon-2 -- -ra + py312-test-instrumentation-falcon-3_ubuntu-latest: + name: instrumentation-falcon-3 3.12 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.12 + uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py312-test-instrumentation-falcon-3 -- -ra + + py312-test-instrumentation-falcon-4_ubuntu-latest: + name: instrumentation-falcon-4 3.12 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.12 + uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py312-test-instrumentation-falcon-4 -- -ra + pypy3-test-instrumentation-falcon-0_ubuntu-latest: name: instrumentation-falcon-0 pypy-3.8 Ubuntu runs-on: ubuntu-latest @@ -2914,6 +3058,42 @@ jobs: - name: Run tests run: tox -e pypy3-test-instrumentation-falcon-2 -- -ra + pypy3-test-instrumentation-falcon-3_ubuntu-latest: + name: instrumentation-falcon-3 pypy-3.8 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python pypy-3.8 + uses: actions/setup-python@v5 + with: + python-version: "pypy-3.8" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e pypy3-test-instrumentation-falcon-3 -- -ra + + pypy3-test-instrumentation-falcon-4_ubuntu-latest: + name: instrumentation-falcon-4 pypy-3.8 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python pypy-3.8 + uses: actions/setup-python@v5 + with: + python-version: "pypy-3.8" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e pypy3-test-instrumentation-falcon-4 -- -ra + py38-test-instrumentation-fastapi_ubuntu-latest: name: instrumentation-fastapi 3.8 Ubuntu runs-on: ubuntu-latest @@ -4335,183 +4515,3 @@ jobs: - name: Run tests run: tox -e py39-test-instrumentation-mysql-0 -- -ra - - py39-test-instrumentation-mysql-1_ubuntu-latest: - name: instrumentation-mysql-1 3.9 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.9 - uses: actions/setup-python@v5 - with: - python-version: "3.9" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py39-test-instrumentation-mysql-1 -- -ra - - py310-test-instrumentation-mysql-0_ubuntu-latest: - name: instrumentation-mysql-0 3.10 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.10 - uses: actions/setup-python@v5 - with: - python-version: "3.10" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py310-test-instrumentation-mysql-0 -- -ra - - py310-test-instrumentation-mysql-1_ubuntu-latest: - name: instrumentation-mysql-1 3.10 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.10 - uses: actions/setup-python@v5 - with: - python-version: "3.10" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py310-test-instrumentation-mysql-1 -- -ra - - py311-test-instrumentation-mysql-0_ubuntu-latest: - name: instrumentation-mysql-0 3.11 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.11 - uses: actions/setup-python@v5 - with: - python-version: "3.11" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py311-test-instrumentation-mysql-0 -- -ra - - py311-test-instrumentation-mysql-1_ubuntu-latest: - name: instrumentation-mysql-1 3.11 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.11 - uses: actions/setup-python@v5 - with: - python-version: "3.11" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py311-test-instrumentation-mysql-1 -- -ra - - py312-test-instrumentation-mysql-0_ubuntu-latest: - name: instrumentation-mysql-0 3.12 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.12 - uses: actions/setup-python@v5 - with: - python-version: "3.12" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py312-test-instrumentation-mysql-0 -- -ra - - py312-test-instrumentation-mysql-1_ubuntu-latest: - name: instrumentation-mysql-1 3.12 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.12 - uses: actions/setup-python@v5 - with: - python-version: "3.12" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py312-test-instrumentation-mysql-1 -- -ra - - pypy3-test-instrumentation-mysql-0_ubuntu-latest: - name: instrumentation-mysql-0 pypy-3.8 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python pypy-3.8 - uses: actions/setup-python@v5 - with: - python-version: "pypy-3.8" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e pypy3-test-instrumentation-mysql-0 -- -ra - - pypy3-test-instrumentation-mysql-1_ubuntu-latest: - name: instrumentation-mysql-1 pypy-3.8 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python pypy-3.8 - uses: actions/setup-python@v5 - with: - python-version: "pypy-3.8" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e pypy3-test-instrumentation-mysql-1 -- -ra - - py38-test-instrumentation-mysqlclient_ubuntu-latest: - name: instrumentation-mysqlclient 3.8 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.8 - uses: actions/setup-python@v5 - with: - python-version: "3.8" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py38-test-instrumentation-mysqlclient -- -ra diff --git a/.github/workflows/test_1.yml b/.github/workflows/test_1.yml index e6aa293f9d..2fce71b031 100644 --- a/.github/workflows/test_1.yml +++ b/.github/workflows/test_1.yml @@ -16,6 +16,186 @@ env: jobs: + py39-test-instrumentation-mysql-1_ubuntu-latest: + name: instrumentation-mysql-1 3.9 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.9 + uses: actions/setup-python@v5 + with: + python-version: "3.9" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py39-test-instrumentation-mysql-1 -- -ra + + py310-test-instrumentation-mysql-0_ubuntu-latest: + name: instrumentation-mysql-0 3.10 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.10 + uses: actions/setup-python@v5 + with: + python-version: "3.10" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py310-test-instrumentation-mysql-0 -- -ra + + py310-test-instrumentation-mysql-1_ubuntu-latest: + name: instrumentation-mysql-1 3.10 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.10 + uses: actions/setup-python@v5 + with: + python-version: "3.10" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py310-test-instrumentation-mysql-1 -- -ra + + py311-test-instrumentation-mysql-0_ubuntu-latest: + name: instrumentation-mysql-0 3.11 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.11 + uses: actions/setup-python@v5 + with: + python-version: "3.11" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py311-test-instrumentation-mysql-0 -- -ra + + py311-test-instrumentation-mysql-1_ubuntu-latest: + name: instrumentation-mysql-1 3.11 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.11 + uses: actions/setup-python@v5 + with: + python-version: "3.11" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py311-test-instrumentation-mysql-1 -- -ra + + py312-test-instrumentation-mysql-0_ubuntu-latest: + name: instrumentation-mysql-0 3.12 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.12 + uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py312-test-instrumentation-mysql-0 -- -ra + + py312-test-instrumentation-mysql-1_ubuntu-latest: + name: instrumentation-mysql-1 3.12 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.12 + uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py312-test-instrumentation-mysql-1 -- -ra + + pypy3-test-instrumentation-mysql-0_ubuntu-latest: + name: instrumentation-mysql-0 pypy-3.8 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python pypy-3.8 + uses: actions/setup-python@v5 + with: + python-version: "pypy-3.8" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e pypy3-test-instrumentation-mysql-0 -- -ra + + pypy3-test-instrumentation-mysql-1_ubuntu-latest: + name: instrumentation-mysql-1 pypy-3.8 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python pypy-3.8 + uses: actions/setup-python@v5 + with: + python-version: "pypy-3.8" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e pypy3-test-instrumentation-mysql-1 -- -ra + + py38-test-instrumentation-mysqlclient_ubuntu-latest: + name: instrumentation-mysqlclient 3.8 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.8 + uses: actions/setup-python@v5 + with: + python-version: "3.8" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py38-test-instrumentation-mysqlclient -- -ra + py39-test-instrumentation-mysqlclient_ubuntu-latest: name: instrumentation-mysqlclient 3.9 Ubuntu runs-on: ubuntu-latest @@ -4335,183 +4515,3 @@ jobs: - name: Run tests run: tox -e pypy3-test-instrumentation-kafka-pythonng -- -ra - - py38-test-instrumentation-confluent-kafka_ubuntu-latest: - name: instrumentation-confluent-kafka 3.8 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.8 - uses: actions/setup-python@v5 - with: - python-version: "3.8" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py38-test-instrumentation-confluent-kafka -- -ra - - py39-test-instrumentation-confluent-kafka_ubuntu-latest: - name: instrumentation-confluent-kafka 3.9 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.9 - uses: actions/setup-python@v5 - with: - python-version: "3.9" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py39-test-instrumentation-confluent-kafka -- -ra - - py310-test-instrumentation-confluent-kafka_ubuntu-latest: - name: instrumentation-confluent-kafka 3.10 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.10 - uses: actions/setup-python@v5 - with: - python-version: "3.10" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py310-test-instrumentation-confluent-kafka -- -ra - - py311-test-instrumentation-confluent-kafka_ubuntu-latest: - name: instrumentation-confluent-kafka 3.11 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.11 - uses: actions/setup-python@v5 - with: - python-version: "3.11" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py311-test-instrumentation-confluent-kafka -- -ra - - py312-test-instrumentation-confluent-kafka_ubuntu-latest: - name: instrumentation-confluent-kafka 3.12 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.12 - uses: actions/setup-python@v5 - with: - python-version: "3.12" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py312-test-instrumentation-confluent-kafka -- -ra - - py38-test-instrumentation-asyncio_ubuntu-latest: - name: instrumentation-asyncio 3.8 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.8 - uses: actions/setup-python@v5 - with: - python-version: "3.8" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py38-test-instrumentation-asyncio -- -ra - - py39-test-instrumentation-asyncio_ubuntu-latest: - name: instrumentation-asyncio 3.9 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.9 - uses: actions/setup-python@v5 - with: - python-version: "3.9" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py39-test-instrumentation-asyncio -- -ra - - py310-test-instrumentation-asyncio_ubuntu-latest: - name: instrumentation-asyncio 3.10 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.10 - uses: actions/setup-python@v5 - with: - python-version: "3.10" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py310-test-instrumentation-asyncio -- -ra - - py311-test-instrumentation-asyncio_ubuntu-latest: - name: instrumentation-asyncio 3.11 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.11 - uses: actions/setup-python@v5 - with: - python-version: "3.11" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py311-test-instrumentation-asyncio -- -ra - - py312-test-instrumentation-asyncio_ubuntu-latest: - name: instrumentation-asyncio 3.12 Ubuntu - runs-on: ubuntu-latest - steps: - - name: Checkout repo @ SHA - ${{ github.sha }} - uses: actions/checkout@v4 - - - name: Set up Python 3.12 - uses: actions/setup-python@v5 - with: - python-version: "3.12" - - - name: Install tox - run: pip install tox - - - name: Run tests - run: tox -e py312-test-instrumentation-asyncio -- -ra diff --git a/.github/workflows/test_2.yml b/.github/workflows/test_2.yml index 7614c8988f..b165817249 100644 --- a/.github/workflows/test_2.yml +++ b/.github/workflows/test_2.yml @@ -16,6 +16,186 @@ env: jobs: + py38-test-instrumentation-confluent-kafka_ubuntu-latest: + name: instrumentation-confluent-kafka 3.8 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.8 + uses: actions/setup-python@v5 + with: + python-version: "3.8" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py38-test-instrumentation-confluent-kafka -- -ra + + py39-test-instrumentation-confluent-kafka_ubuntu-latest: + name: instrumentation-confluent-kafka 3.9 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.9 + uses: actions/setup-python@v5 + with: + python-version: "3.9" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py39-test-instrumentation-confluent-kafka -- -ra + + py310-test-instrumentation-confluent-kafka_ubuntu-latest: + name: instrumentation-confluent-kafka 3.10 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.10 + uses: actions/setup-python@v5 + with: + python-version: "3.10" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py310-test-instrumentation-confluent-kafka -- -ra + + py311-test-instrumentation-confluent-kafka_ubuntu-latest: + name: instrumentation-confluent-kafka 3.11 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.11 + uses: actions/setup-python@v5 + with: + python-version: "3.11" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py311-test-instrumentation-confluent-kafka -- -ra + + py312-test-instrumentation-confluent-kafka_ubuntu-latest: + name: instrumentation-confluent-kafka 3.12 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.12 + uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py312-test-instrumentation-confluent-kafka -- -ra + + py38-test-instrumentation-asyncio_ubuntu-latest: + name: instrumentation-asyncio 3.8 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.8 + uses: actions/setup-python@v5 + with: + python-version: "3.8" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py38-test-instrumentation-asyncio -- -ra + + py39-test-instrumentation-asyncio_ubuntu-latest: + name: instrumentation-asyncio 3.9 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.9 + uses: actions/setup-python@v5 + with: + python-version: "3.9" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py39-test-instrumentation-asyncio -- -ra + + py310-test-instrumentation-asyncio_ubuntu-latest: + name: instrumentation-asyncio 3.10 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.10 + uses: actions/setup-python@v5 + with: + python-version: "3.10" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py310-test-instrumentation-asyncio -- -ra + + py311-test-instrumentation-asyncio_ubuntu-latest: + name: instrumentation-asyncio 3.11 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.11 + uses: actions/setup-python@v5 + with: + python-version: "3.11" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py311-test-instrumentation-asyncio -- -ra + + py312-test-instrumentation-asyncio_ubuntu-latest: + name: instrumentation-asyncio 3.12 Ubuntu + runs-on: ubuntu-latest + steps: + - name: Checkout repo @ SHA - ${{ github.sha }} + uses: actions/checkout@v4 + + - name: Set up Python 3.12 + uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Install tox + run: pip install tox + + - name: Run tests + run: tox -e py312-test-instrumentation-asyncio -- -ra + py38-test-instrumentation-cassandra_ubuntu-latest: name: instrumentation-cassandra 3.8 Ubuntu runs-on: ubuntu-latest diff --git a/CHANGELOG.md b/CHANGELOG.md index a243091b1d..d17c18687c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ([#3100](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/3100)) - Add support to database stability opt-in in `_semconv` utilities and add tests ([#3111](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/3111)) +- `opentelemetry-instrumentation-falcon` add support version to v4 + ([#3086](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/3086)) + ### Fixed diff --git a/instrumentation/README.md b/instrumentation/README.md index b12ac1aa21..d1b383d5a6 100644 --- a/instrumentation/README.md +++ b/instrumentation/README.md @@ -20,7 +20,7 @@ | [opentelemetry-instrumentation-dbapi](./opentelemetry-instrumentation-dbapi) | dbapi | No | experimental | [opentelemetry-instrumentation-django](./opentelemetry-instrumentation-django) | django >= 1.10 | Yes | experimental | [opentelemetry-instrumentation-elasticsearch](./opentelemetry-instrumentation-elasticsearch) | elasticsearch >= 6.0 | No | experimental -| [opentelemetry-instrumentation-falcon](./opentelemetry-instrumentation-falcon) | falcon >= 1.4.1, < 4.0.0 | Yes | experimental +| [opentelemetry-instrumentation-falcon](./opentelemetry-instrumentation-falcon) | falcon >= 1.4.1, < 5.0.0 | Yes | experimental | [opentelemetry-instrumentation-fastapi](./opentelemetry-instrumentation-fastapi) | fastapi ~= 0.58 | Yes | migration | [opentelemetry-instrumentation-flask](./opentelemetry-instrumentation-flask) | flask >= 1.0 | Yes | migration | [opentelemetry-instrumentation-grpc](./opentelemetry-instrumentation-grpc) | grpcio >= 1.42.0 | No | experimental diff --git a/instrumentation/opentelemetry-instrumentation-falcon/pyproject.toml b/instrumentation/opentelemetry-instrumentation-falcon/pyproject.toml index 883c76a9fd..a2ccb77998 100644 --- a/instrumentation/opentelemetry-instrumentation-falcon/pyproject.toml +++ b/instrumentation/opentelemetry-instrumentation-falcon/pyproject.toml @@ -35,7 +35,7 @@ dependencies = [ [project.optional-dependencies] instruments = [ - "falcon >= 1.4.1, < 3.1.2", + "falcon >= 1.4.1, < 5.0.0", ] [project.entry-points.opentelemetry_instrumentor] diff --git a/instrumentation/opentelemetry-instrumentation-falcon/src/opentelemetry/instrumentation/falcon/__init__.py b/instrumentation/opentelemetry-instrumentation-falcon/src/opentelemetry/instrumentation/falcon/__init__.py index 28b394eaf0..1037f98f5f 100644 --- a/instrumentation/opentelemetry-instrumentation-falcon/src/opentelemetry/instrumentation/falcon/__init__.py +++ b/instrumentation/opentelemetry-instrumentation-falcon/src/opentelemetry/instrumentation/falcon/__init__.py @@ -542,7 +542,7 @@ def _remove_instrumented_middleware(self, app): for x in app._middlewares_list if not isinstance(x, _TraceMiddleware) ] - # pylint: disable=c-extension-no-member + # pylint: disable=no-member app._middleware = falcon.api_helpers.prepare_middleware( app._middlewares_list, independent_middleware=app._independent_middleware, diff --git a/instrumentation/opentelemetry-instrumentation-falcon/src/opentelemetry/instrumentation/falcon/package.py b/instrumentation/opentelemetry-instrumentation-falcon/src/opentelemetry/instrumentation/falcon/package.py index 2fd463739c..440a6e25f2 100644 --- a/instrumentation/opentelemetry-instrumentation-falcon/src/opentelemetry/instrumentation/falcon/package.py +++ b/instrumentation/opentelemetry-instrumentation-falcon/src/opentelemetry/instrumentation/falcon/package.py @@ -13,6 +13,6 @@ # limitations under the License. -_instruments = ("falcon >= 1.4.1, < 4.0.0",) +_instruments = ("falcon >= 1.4.1, < 5.0.0",) _supports_metrics = True diff --git a/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-3.txt b/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-3.txt new file mode 100644 index 0000000000..392a1ce385 --- /dev/null +++ b/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-3.txt @@ -0,0 +1,16 @@ +asgiref==3.8.1 +Deprecated==1.2.14 +falcon==3.1.3 +iniconfig==2.0.0 +packaging==24.0 +pluggy==1.5.0 +py-cpuinfo==9.0.0 +pytest==7.4.4 +tomli==2.0.1 +typing_extensions==4.12.2 +wrapt==1.16.0 +zipp==3.19.2 +-e opentelemetry-instrumentation +-e instrumentation/opentelemetry-instrumentation-wsgi +-e util/opentelemetry-util-http +-e instrumentation/opentelemetry-instrumentation-falcon diff --git a/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-4.txt b/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-4.txt new file mode 100644 index 0000000000..0fd061b29a --- /dev/null +++ b/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-4.txt @@ -0,0 +1,16 @@ +asgiref==3.8.1 +Deprecated==1.2.14 +falcon==4.0.2 +iniconfig==2.0.0 +packaging==24.0 +pluggy==1.5.0 +py-cpuinfo==9.0.0 +pytest==7.4.4 +tomli==2.0.1 +typing_extensions==4.12.2 +wrapt==1.16.0 +zipp==3.19.2 +-e opentelemetry-instrumentation +-e instrumentation/opentelemetry-instrumentation-wsgi +-e util/opentelemetry-util-http +-e instrumentation/opentelemetry-instrumentation-falcon diff --git a/instrumentation/opentelemetry-instrumentation-falcon/tests/app.py b/instrumentation/opentelemetry-instrumentation-falcon/tests/app.py index a4d279149d..416ac80dff 100644 --- a/instrumentation/opentelemetry-instrumentation-falcon/tests/app.py +++ b/instrumentation/opentelemetry-instrumentation-falcon/tests/app.py @@ -4,12 +4,14 @@ # pylint:disable=R0201,W0613,E0602 +_parsed_falcon_version = package_version.parse(falcon.__version__) + + class HelloWorldResource: def _handle_request(self, _, resp): # pylint: disable=no-member resp.status = falcon.HTTP_201 - _parsed_falcon_version = package_version.parse(falcon.__version__) if _parsed_falcon_version < package_version.parse("3.0.0"): # Falcon 1 and Falcon 2 resp.body = "Hello World" @@ -65,11 +67,15 @@ class UserResource: def on_get(self, req, resp, user_id): # pylint: disable=no-member resp.status = falcon.HTTP_200 - resp.body = f"Hello user {user_id}" + + if _parsed_falcon_version < package_version.parse("3.0.0"): + # Falcon 1 and Falcon 2 + resp.body = f"Hello user {user_id}" + else: + resp.text = f"Hello user {user_id}" def make_app(): - _parsed_falcon_version = package_version.parse(falcon.__version__) if _parsed_falcon_version < package_version.parse("3.0.0"): # Falcon 1 and Falcon 2 app = falcon.API() diff --git a/instrumentation/opentelemetry-instrumentation-falcon/tests/test_falcon.py b/instrumentation/opentelemetry-instrumentation-falcon/tests/test_falcon.py index dbc2512ca0..f940deb34e 100644 --- a/instrumentation/opentelemetry-instrumentation-falcon/tests/test_falcon.py +++ b/instrumentation/opentelemetry-instrumentation-falcon/tests/test_falcon.py @@ -57,6 +57,8 @@ "http.server.duration": _server_duration_attrs_old, } +_parsed_falcon_version = package_version.parse(_falcon_version) + class TestFalconBase(TestBase): def setUp(self): @@ -76,6 +78,13 @@ def setUp(self): ) self.app = make_app() + @property + def _has_fixed_http_target(self): + # In falcon<3.1.2, HTTP_TARGET is always set to / in TestClient + # In falcon>=3.1.2, HTTP_TARGET is set to unencoded path by default + # https://github.com/falconry/falcon/blob/69cdcd6edd2ee33f4ac9f7793e1cc3c4f99da692/falcon/testing/helpers.py#L1153-1156 # noqa + return _parsed_falcon_version < package_version.parse("3.1.2") + def client(self): return testing.TestClient(self.app) @@ -124,7 +133,9 @@ def _test_method(self, method): SpanAttributes.HTTP_SCHEME: "http", SpanAttributes.NET_HOST_PORT: 80, SpanAttributes.HTTP_HOST: "falconframework.org", - SpanAttributes.HTTP_TARGET: "/", + SpanAttributes.HTTP_TARGET: "/" + if self._has_fixed_http_target + else "/hello", SpanAttributes.NET_PEER_PORT: 65133, SpanAttributes.HTTP_FLAVOR: "1.1", "falcon.resource": "HelloWorldResource", @@ -132,7 +143,7 @@ def _test_method(self, method): }, ) # In falcon<3, NET_PEER_IP is always set by default to 127.0.0.1 - # In falcon>3, NET_PEER_IP is not set to anything by default to + # In falcon>=3, NET_PEER_IP is not set to anything by default # https://github.com/falconry/falcon/blob/5233d0abed977d9dab78ebadf305f5abe2eef07c/falcon/testing/helpers.py#L1168-L1172 # noqa if SpanAttributes.NET_PEER_IP in span.attributes: self.assertEqual( @@ -155,14 +166,16 @@ def test_404(self): SpanAttributes.HTTP_SCHEME: "http", SpanAttributes.NET_HOST_PORT: 80, SpanAttributes.HTTP_HOST: "falconframework.org", - SpanAttributes.HTTP_TARGET: "/", + SpanAttributes.HTTP_TARGET: "/" + if self._has_fixed_http_target + else "/does-not-exist", SpanAttributes.NET_PEER_PORT: 65133, SpanAttributes.HTTP_FLAVOR: "1.1", SpanAttributes.HTTP_STATUS_CODE: 404, }, ) # In falcon<3, NET_PEER_IP is always set by default to 127.0.0.1 - # In falcon>3, NET_PEER_IP is not set to anything by default to + # In falcon>=3, NET_PEER_IP is not set to anything by default # https://github.com/falconry/falcon/blob/5233d0abed977d9dab78ebadf305f5abe2eef07c/falcon/testing/helpers.py#L1168-L1172 # noqa if SpanAttributes.NET_PEER_IP in span.attributes: self.assertEqual( @@ -192,14 +205,16 @@ def test_500(self): SpanAttributes.HTTP_SCHEME: "http", SpanAttributes.NET_HOST_PORT: 80, SpanAttributes.HTTP_HOST: "falconframework.org", - SpanAttributes.HTTP_TARGET: "/", + SpanAttributes.HTTP_TARGET: "/" + if self._has_fixed_http_target + else "/error", SpanAttributes.NET_PEER_PORT: 65133, SpanAttributes.HTTP_FLAVOR: "1.1", SpanAttributes.HTTP_STATUS_CODE: 500, }, ) # In falcon<3, NET_PEER_IP is always set by default to 127.0.0.1 - # In falcon>3, NET_PEER_IP is not set to anything by default to + # In falcon>=3, NET_PEER_IP is not set to anything by default # https://github.com/falconry/falcon/blob/5233d0abed977d9dab78ebadf305f5abe2eef07c/falcon/testing/helpers.py#L1168-L1172 # noqa if SpanAttributes.NET_PEER_IP in span.attributes: self.assertEqual( @@ -225,7 +240,9 @@ def test_url_template(self): SpanAttributes.HTTP_SCHEME: "http", SpanAttributes.NET_HOST_PORT: 80, SpanAttributes.HTTP_HOST: "falconframework.org", - SpanAttributes.HTTP_TARGET: "/", + SpanAttributes.HTTP_TARGET: "/" + if self._has_fixed_http_target + else "/user/123", SpanAttributes.NET_PEER_PORT: 65133, SpanAttributes.HTTP_FLAVOR: "1.1", "falcon.resource": "UserResource", @@ -524,8 +541,7 @@ def test_custom_request_header_not_added_in_internal_span(self): self.assertNotIn(key, span.attributes) @pytest.mark.skipif( - condition=package_version.parse(_falcon_version) - < package_version.parse("2.0.0"), + condition=_parsed_falcon_version < package_version.parse("2.0.0"), reason="falcon<2 does not implement custom response headers", ) def test_custom_response_header_added_in_server_span(self): @@ -559,8 +575,7 @@ def test_custom_response_header_added_in_server_span(self): self.assertNotIn(key, span.attributes) @pytest.mark.skipif( - condition=package_version.parse(_falcon_version) - < package_version.parse("2.0.0"), + condition=_parsed_falcon_version < package_version.parse("2.0.0"), reason="falcon<2 does not implement custom response headers", ) def test_custom_response_header_not_added_in_internal_span(self): diff --git a/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py b/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py index 5825e8f7b8..a55f0ccd8e 100644 --- a/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py +++ b/opentelemetry-instrumentation/src/opentelemetry/instrumentation/bootstrap_gen.py @@ -93,7 +93,7 @@ "instrumentation": "opentelemetry-instrumentation-elasticsearch==0.51b0.dev", }, { - "library": "falcon >= 1.4.1, < 3.1.2", + "library": "falcon >= 1.4.1, < 5.0.0", "instrumentation": "opentelemetry-instrumentation-falcon==0.51b0.dev", }, { diff --git a/tox.ini b/tox.ini index 9d79a11f8b..6c6abe3d42 100644 --- a/tox.ini +++ b/tox.ini @@ -117,14 +117,17 @@ envlist = ; opentelemetry-instrumentation-falcon ; py310 does not work with falcon 1 + ; py3{8,9} will be dropped for falcon 4 ; The numbers at the end of the environment names ; below mean these dependencies are being used: ; 0: falcon ==1.4.1 ; 1: falcon >=2.0.0,<3.0.0 - ; 2: falcon >=3.0.0,<4.0.0 - py3{8,9}-test-instrumentation-falcon-{0,1,2} - py3{10,11,12}-test-instrumentation-falcon-{1,2} - pypy3-test-instrumentation-falcon-{0,1,2} + ; 2: falcon >=3.0.0,<3.1.2 + ; 3: falcon >=3.1.2,<4.0.0 + ; 4: falcon >=4.0.0,<5.0.0 + py3{8,9}-test-instrumentation-falcon-{0,1,2,3} + py3{10,11,12}-test-instrumentation-falcon-{1,2,3,4} + pypy3-test-instrumentation-falcon-{0,1,2,3,4} lint-instrumentation-falcon ; opentelemetry-instrumentation-fastapi @@ -489,7 +492,9 @@ deps = falcon-0: -r {toxinidir}/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-0.txt falcon-1: -r {toxinidir}/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-1.txt falcon-2: -r {toxinidir}/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-2.txt - lint-instrumentation-falcon: -r {toxinidir}/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-2.txt + falcon-3: -r {toxinidir}/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-3.txt + falcon-4: -r {toxinidir}/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-4.txt + lint-instrumentation-falcon: -r {toxinidir}/instrumentation/opentelemetry-instrumentation-falcon/test-requirements-4.txt flask: {[testenv]test_deps} flask-0: -r {toxinidir}/instrumentation/opentelemetry-instrumentation-flask/test-requirements-0.txt