Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add target in case there is no host in target #2224

Closed
wants to merge 4 commits into from

Conversation

ajaygupta2790
Copy link
Contributor

The current grpc instrumentation expects host value with a port that may not always be true. In our project, we usean internal host without a port value

target = kwargs.get("target") or args[0]
if ":" in target:
    host, port = target.split(":")
    try:
        port = int(port)
    except ValueError:
        port = None
else:
    host, port = None, None

This results in span showing None value and we cannot track the external host value. All grpc hosts are clubbed together under https://none value

The proposal is to keep the target value as is in case there is no ':' in the host and keep the port as None

Copy link

cla-checker-service bot commented Feb 28, 2025

❌ Author of the following commits did not sign a Contributor Agreement:
8310b74, , ,

Please, read and sign the above mentioned agreement if you want to contribute to this project

@github-actions github-actions bot added agent-python community Issues opened by the community triage Issues awaiting triage labels Feb 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
agent-python community Issues opened by the community triage Issues awaiting triage
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants