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

[Essentials] Longitude Validation #27784

Merged
merged 1 commit into from
Feb 16, 2025
Merged

[Essentials] Longitude Validation #27784

merged 1 commit into from
Feb 16, 2025

Conversation

kubaflo
Copy link
Contributor

@kubaflo kubaflo commented Feb 13, 2025

Issues Fixed

Fixes #27774

@kubaflo kubaflo requested a review from a team as a code owner February 13, 2025 18:37
@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Feb 13, 2025
@kubaflo kubaflo added area-essentials Essentials: Device, Display, Connectivity, Secure Storage, Sensors, App Info and removed community ✨ Community Contribution labels Feb 13, 2025
@jfversluis jfversluis self-assigned this Feb 13, 2025
@jfversluis
Copy link
Member

/azp run

Copy link

Azure Pipelines successfully started running 3 pipeline(s).

Copy link
Member

@jfversluis jfversluis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Failing tests unrelated

@jfversluis jfversluis merged commit 89c0eb8 into dotnet:main Feb 16, 2025
120 of 123 checks passed
@jfversluis jfversluis added this to the .NET 9 SR5 milestone Feb 16, 2025
Copy link
Contributor

🚨 API change(s) detected @davidbritch FYI

@jfversluis
Copy link
Member

Not sure if anything about this is described in the docs. Technically a behavioral breaking change although I think it’s for the better.

@kubaflo
Copy link
Contributor Author

kubaflo commented Feb 16, 2025

Agreed! Devs can easily implement the previous logic and it was confusing that latitude didn't work as longitude

while (Longitude <= -180)
Longitude += 360;
// check if longitude is in (-180, 180]
if (Math.Abs(latitude) > 180)
Copy link
Contributor

@dartasen dartasen Feb 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kubaflo @jfversluis I feel like it's a wrong copy paste here, it should be longitude inside the Math.abs...
I guess it does describe that this area is lacking of unit tests

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're absolutely right. I'm sorry about that. Here's the fix: #27834
@jfversluis could you please /azp

@github-actions github-actions bot locked and limited conversation to collaborators Mar 19, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-essentials Essentials: Device, Display, Connectivity, Secure Storage, Sensors, App Info t/breaking 💥
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Excessive Looping Due to Missing Longitude Validation in Location.shared.cs
3 participants