Skip to content

Commit

Permalink
Testrelease 3.3.3.4, temp pypi publish fix, add debug lines
Browse files Browse the repository at this point in the history
  • Loading branch information
tammy-baylis-swi committed Jan 23, 2025
1 parent 2e979e6 commit 25c1a84
Show file tree
Hide file tree
Showing 7 changed files with 45 additions and 12 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/publish_aarch64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ jobs:
name: ${{ inputs.artifact-name }}
- name: Unzip artifact with dist
run: unzip ${{ inputs.artifact-name }}
- name: Upgrade pip
run: pip install --upgrade pip
- name: Upgrade packaging
run: pip install --upgrade packaging
- name: Install Twine
run: pip install --upgrade --no-cache-dir --prefer-binary twine
- name: Check distribution artifacts
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/publish_x86_64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ jobs:
name: ${{ inputs.artifact-name }}
- name: Unzip artifact with dist
run: unzip ${{ inputs.artifact-name }}
- name: Upgrade pip
run: pip install --upgrade pip
- name: Upgrade packaging
run: pip install --upgrade packaging
- name: Install Twine
run: pip install --upgrade --no-cache-dir --prefer-binary twine
- name: Check distribution artifacts
Expand Down
20 changes: 10 additions & 10 deletions image/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,32 +17,32 @@ FROM python:3.8 AS build-38
WORKDIR /operator-build
ADD requirements-nodeps.txt .
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt

FROM python:3.9 AS build-39
WORKDIR /operator-build
ADD requirements-nodeps.txt .
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt

FROM python:3.10 AS build-310
WORKDIR /operator-build
ADD requirements-nodeps.txt .
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt

FROM python:3.11 AS build-311
WORKDIR /operator-build
ADD requirements-nodeps.txt .
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt

FROM python:3.12 AS build-312
WORKDIR /operator-build
ADD requirements-nodeps.txt .
ADD requirements.txt .
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt
RUN pip install --target workspace -r requirements.txt


Expand All @@ -51,36 +51,36 @@ WORKDIR /operator-build
ADD requirements-nodeps.txt .
RUN apk add g++ gcc python3-dev musl-dev linux-headers
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt

FROM python:3.9-alpine AS build-musl-39
WORKDIR /operator-build
ADD requirements-nodeps.txt .
RUN apk add g++ gcc python3-dev musl-dev linux-headers
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt

FROM python:3.10-alpine AS build-musl-310
WORKDIR /operator-build
ADD requirements-nodeps.txt .
RUN apk add g++ gcc python3-dev musl-dev linux-headers
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt

FROM python:3.11-alpine AS build-musl-311
WORKDIR /operator-build
ADD requirements-nodeps.txt .
RUN apk add g++ gcc python3-dev musl-dev linux-headers
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt

FROM python:3.12-alpine AS build-musl-312
WORKDIR /operator-build
ADD requirements-nodeps.txt .
ADD requirements.txt .
RUN apk add g++ gcc python3-dev musl-dev linux-headers
RUN mkdir workspace
RUN pip install --no-deps --target workspace -r requirements-nodeps.txt
RUN pip install --no-deps --target workspace --extra-index-url https://test.pypi.org/simple/ -r requirements-nodeps.txt
RUN pip install --target workspace -r requirements.txt

FROM busybox
Expand Down
2 changes: 1 addition & 1 deletion image/requirements-nodeps.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
solarwinds_apm==3.3.2
solarwinds_apm==3.3.3.4
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ solarwinds_exporter = "solarwinds_apm.exporter:SolarWindsSpanExporter"
solarwinds_sampler = "solarwinds_apm.sampler:ParentBasedSwSampler"

[tool.setuptools]
license-files = ["LICENSE"]
include-package-data = false
packages = [
"solarwinds_apm",
Expand Down
24 changes: 24 additions & 0 deletions solarwinds_apm/configurator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
import time
from typing import TYPE_CHECKING, Any

from packaging.requirements import Requirement

from opentelemetry import trace
from opentelemetry._logs import set_logger_provider
from opentelemetry.environment_variables import (
Expand Down Expand Up @@ -687,6 +689,25 @@ def _add_all_instrumented_python_framework_versions(
)
continue

logger.debug("framework_versions for")
logger.debug("entry_point.name: %s", entry_point.name)
logger.debug("entry_point.dist: %s", entry_point.dist)
logger.debug(
"entry_point.dist.requires: %s, type %s",
entry_point.dist.requires,
type(entry_point.dist.requires),
)
if type(entry_point.dist.requires) == Requirement:
extra = "extra"
instruments = "instruments"
instruments_marker = {extra: instruments}
logger.debug(
"entry_point.dist.requires.marker.evaluate to: %s",
entry_point.dist.requires.marker.evaluate(
instruments_marker
),
)

try:
conflict = get_dist_dependency_conflicts(entry_point.dist)
if conflict:
Expand Down Expand Up @@ -714,6 +735,9 @@ def _add_all_instrumented_python_framework_versions(
entry_point.name,
ex,
)
logging.warning(
"exc_info: %s", type(ex).__name__, exc_info=True
)
continue

# Set up Instrumented Library Versions KVs with several special cases
Expand Down
2 changes: 1 addition & 1 deletion solarwinds_apm/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "3.3.2"
__version__ = "3.3.3.4"

0 comments on commit 25c1a84

Please sign in to comment.