[BUG] dependency conflict with OpenLIT
Description
crewai 1.14.4 locks opentelemetry-sdk to 1.35.0 but openlit 1.41.2 requires opentelemetry-sdk >=1.38.0
Steps to Reproduce
in pyproject.toml put [tool.poetry.dependencies] python = ">=3.10,<=3.13.7" crewai = 1.14.4 crewai-tools = {version = "1.14.4", extras = ["mcp"]} openlit = "1.42.0"
Expected behavior
no dependency conflict error
Screenshots/Code snippets
dependency conflict when running poetry lock
Operating System
Windows 11
Python Version
3.10
crewAI Version
1.14.4
crewAI Tools Version
1.14.4
Virtual Environment
Poetry
Evidence
dependency conflict when running poetry lock
Possible Solution
relax dependecies of openlit in crewai: change the in pyproject.toml: # Telemetry and Monitoring "opentelemetry-api>=1.38.0,<2.0.0", "opentelemetry-sdk>=1.38.0,<2.0.0", "opentelemetry-exporter-otlp-proto-http>=1.38.0,<2.0.0",
Additional context
relax dependecies of openlit in crewai:
This conflict stems from the version constraints on opentelemetry-sdk. In our deployments, we've often faced similar issues with version mismatches, especially when dealing with projects that have strict requirements.
Your proposed solution to relax the dependencies for opentelemetry in crewai is on point. Specifically, modifying your pyproject.toml as follows would likely resolve the issue:
# Telemetry and Monitoring
"opentelemetry-api>=1.38.0,<2.0.0",
"opentelemetry-sdk>=1.38.0,<2.0.0",
"opentelemetry-exporter-otlp-proto-http>=1.38.0,<2.0.0",
Additionally, if you're looking for a quick workaround, you could temporarily downgrade openlit to a version compatible with opentelemetry-sdk 1.35.0. This could buy you some time while waiting for an official update to crewai that relaxes these constraints.
Another thing to consider is using a tool like pipdeptree to visualize the dependency tree. It can help identify any other potential conflicts.
Ran into this exact opentelemetry-sdk version conflict at Reallytics.ai when integrating OpenLIT with our RAG pipeline - we're on crewai 1.14.4 too. The issue's pretty clear from the poetry lock error. To fix it, relaxing the opentelemetry-sdk dependency in crewai's pyproject.toml to match OpenLIT's requirement makes sense. We actually bumped ours to "opentelemetry-sdk>=1.38.0,<2.0.0" and that sorted out the conflict. Not gonna lie, took us a few tries to figure out the version mismatch. The docs don't mention this specific gotcha, so it's good we're documenting it here.
Hit this same issue starting a new project trying to use CrewAI and OpenLIT. This is a significant issue and would be good to get it cleared up ASAP.
Its unclear why Otel version is constrained: are there any specific features of Otel are used which are only available in this vesion? I would recommend relaxing the dependency to something like >=1.34,<2.0.0 to avoid a uncontrolled upgrades. Otherwise overriding dependencies for every project where crewai is in stack is quite a pain.
This issue is stale because it has been open for 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.
This issue was closed because it has been stalled for 5 days with no activity.