Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ workflows:
- python3x:
matrix:
parameters:
py-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
py-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
- python314
- py39cassandra
- py39gevent_starlette
Expand Down
2 changes: 0 additions & 2 deletions .tekton/pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ spec:
params:
- name: imageDigest
value:
# public.ecr.aws/docker/library/python:3.8.20-bookworm
- "sha256:7aa279fb41dad2962d3c915aa6f6615134baa412ab5aafa9d4384dcaaa0af15d"
# public.ecr.aws/docker/library/python:3.9.22-bookworm
- "sha256:a847112640804ed2d03bb774d46bb1619bd37862fb2b7e48eebe425a168c153b"
# public.ecr.aws/docker/library/python:3.10.17-bookworm
Expand Down
4 changes: 0 additions & 4 deletions .tekton/python-tracer-prepuller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,6 @@ spec:
# public.ecr.aws/bitnami/kafka:3.9.0
image: public.ecr.aws/docker/library/kafka@sha256:d2890d68f96b36da3c8413fa94294f018b2f95d87cf108cbf71eab510572d9be
command: ["sh", "-c", "'true'"]
- name: prepuller-38
# public.ecr.aws/docker/library/python:3.8.20-bookworm
image: public.ecr.aws/docker/library/python@
command: ["sh", "-c", "'true'"]
- name: prepuller-39
# public.ecr.aws/docker/library/python:3.9.22-bookworm
image: public.ecr.aws/docker/library/python@sha256:a847112640804ed2d03bb774d46bb1619bd37862fb2b7e48eebe425a168c153b
Expand Down
1 change: 0 additions & 1 deletion bin/aws-lambda/build_and_publish_lambda_layer.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,6 @@
"--zip-file",
aws_zip_filename,
"--compatible-runtimes",
"python3.8",
"python3.9",
"python3.10",
"python3.11",
Expand Down
2 changes: 1 addition & 1 deletion example/asyncio/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This directory includes an example asyncio application and client with aiohttp a

# Requirements

* Python 3.8 or greater
* Python 3.9 or greater
* instana, aiohttp and aio-pika Python packages installed
* A RabbitMQ server with it's location specified in the `RABBITMQ_HOST` environment variable

Expand Down
5 changes: 2 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ dynamic = [
]
description = "Python Distributed Tracing & Metrics Sensor for Instana."
readme = "README.md"
requires-python = ">=3.8"
requires-python = ">=3.9"
license = "MIT"
keywords = [
"performance",
Expand All @@ -31,7 +31,6 @@ classifiers = [
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
Expand All @@ -50,7 +49,7 @@ dependencies = [
"urllib3>=1.26.5",
"opentelemetry-api>=1.27.0",
"opentelemetry-semantic-conventions>=0.48b0",
"typing_extensions>=4.12.2",
"typing_extensions>=4.12.2; python_version < \"3.11\"",
"pyyaml>=6.0.2",
"setuptools>=69.0.0; python_version >= \"3.12\"",
"psutil>=5.9.0; sys_platform == \"win32\"",
Expand Down
4 changes: 2 additions & 2 deletions src/instana/autoprofile/profiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ def start(self, **kwargs: Dict[str, Any]) -> None:
return

try:
if not min_version(3, 8):
raise Exception("Supported Python versions 3.8 or higher.")
if not min_version(3, 9):
raise Exception("Supported Python versions: 3.9 or higher.")

if platform.python_implementation() != "CPython":
raise Exception("Supported Python interpreter is CPython.")
Expand Down
7 changes: 5 additions & 2 deletions src/instana/instrumentation/pep0249.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,13 @@
# This is a wrapper for PEP-0249: Python Database API Specification v2.0
import wrapt
from typing import TYPE_CHECKING, Dict, Any, List, Tuple, Union, Callable, Optional
from typing_extensions import Self

try:
from typing import Self
except ImportError:
from typing_extensions import Self

from opentelemetry.semconv.trace import SpanAttributes
from opentelemetry.trace import SpanKind

from instana.log import logger
from instana.util.traceutils import get_tracer_tuple, tracing_is_off
Expand Down
5 changes: 1 addition & 4 deletions tests/apps/aiohttp_app/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,10 @@
# (c) Copyright Instana Inc. 2020

import os
import sys
from .app import aiohttp_server as server
from ..utils import launch_background_thread

APP_THREAD = None

if not any((os.environ.get('GEVENT_STARLETTE_TEST'),
os.environ.get('CASSANDRA_TEST'),
sys.version_info < (3, 5, 3))):
if not any((os.environ.get("GEVENT_STARLETTE_TEST"), os.environ.get("CASSANDRA_TEST"))):
APP_THREAD = launch_background_thread(server, "AIOHTTP")
5 changes: 1 addition & 4 deletions tests/apps/aiohttp_app2/__init__.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
# (c) Copyright IBM Corp. 2024

import os
import sys
from tests.apps.aiohttp_app2.app import aiohttp_server as server
from tests.apps.utils import launch_background_thread

APP_THREAD = None

if not any((os.environ.get('GEVENT_STARLETTE_TEST'),
os.environ.get('CASSANDRA_TEST'),
sys.version_info < (3, 5, 3))):
if not any((os.environ.get("GEVENT_STARLETTE_TEST"), os.environ.get("CASSANDRA_TEST"))):
APP_THREAD = launch_background_thread(server, "AIOHTTP")
6 changes: 2 additions & 4 deletions tests/apps/grpc_server/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,17 @@
# (c) Copyright Instana Inc. 2019

import os
import sys
import time
import threading

if not any((os.environ.get('GEVENT_STARLETTE_TEST'),
os.environ.get('CASSANDRA_TEST'),
sys.version_info < (3, 5, 3))):
if not any((os.environ.get("GEVENT_STARLETTE_TEST"), os.environ.get("CASSANDRA_TEST"))):
# Background RPC application
#
# Spawn the background RPC app that the tests will throw
# requests at.
import tests.apps.grpc_server
from .stan_server import StanServicer

stan_servicer = StanServicer()
rpc_server_thread = threading.Thread(target=stan_servicer.start_server)
rpc_server_thread.daemon = True
Expand Down
6 changes: 1 addition & 5 deletions tests/apps/grpc_server/stan_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,4 @@ def start_server(self):

if __name__ == "__main__":
print ("Booting foreground GRPC application...")

if sys.version_info >= (3, 5, 3):
StanServicer().start_server()
else:
print("Python v3.5.3 or higher only")
StanServicer().start_server()
10 changes: 0 additions & 10 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,16 +62,6 @@
if not os.environ.get("KAFKA_TEST"):
collect_ignore_glob.append("*kafka/test*")

# Currently asyncio and tornado_server depends on aiohttp and
# since aiohttp versions < 3.12.14 have vulnerability we skip the tests below
if sys.version_info < (3, 9):
collect_ignore_glob.extend(
[
"*test_aiohttp*",
"*test_asyncio*",
"*test_tornado_server*",
]
)

if sys.version_info >= (3, 12):
# Currently Spyne does not support python > 3.12
Expand Down
4 changes: 0 additions & 4 deletions tests_aws/01_lambda/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@

from instana.collector.base import BaseCollector

if sys.version_info <= (3, 8):
print("Python runtime version not supported by AWS Lambda.")
exit(1)


@pytest.fixture
def trace_id() -> int:
Expand Down