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

[BUILD] Build warning in http_operation_curl.cc on Windows #3253

Open
marcalff opened this issue Jan 24, 2025 · 3 comments
Open

[BUILD] Build warning in http_operation_curl.cc on Windows #3253

marcalff opened this issue Jan 24, 2025 · 3 comments
Assignees
Labels
bug Something isn't working triage/accepted Indicates an issue or PR is ready to be actively worked on.

Comments

@marcalff
Copy link
Member

When building on Windows, in file http_operation_curl.cc, the following line causes warnings:

  static std::uniform_real_distribution<float> dis(0.8, 1.2);
**redacted**\opentelemetry-cpp-1.19.0\ext\src\http\client\curl\http_operation_curl.cc(468,57):
 warning C4305: 'argument': truncation from 'double' to '_Ty'
[**redacted**\opentelemetry-cpp-1.19.0\ext\src\http\client\curl\opentelemetry_http_client_curl.vcxproj]
@marcalff marcalff added the bug Something isn't working label Jan 24, 2025
@marcalff marcalff self-assigned this Jan 24, 2025
@github-actions github-actions bot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Jan 24, 2025
@malkia
Copy link

malkia commented Jan 24, 2025

I guess it should be

dis(0.8f, 1.2f)

to avoid conversion from double to float

@marcalff marcalff added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Jan 27, 2025
@marcalff
Copy link
Member Author

We need to:

  • fix this warning
  • make sure the maintainer CI on windows catches warnings like this (include the OTLP GRPC exporter)

@chusitoo
Copy link
Contributor

chusitoo commented Feb 4, 2025

We need to:

  • fix this warning
  • make sure the maintainer CI on windows catches warnings like this (include the OTLP GRPC exporter)

I can look into this. Maintainer CI on Windows could be a little bit of a challenge, though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
Development

No branches or pull requests

3 participants