Skip to content
This repository has been archived by the owner on Oct 23, 2024. It is now read-only.

Only allow numbers in streetNumber string #169

Merged
merged 2 commits into from
Jul 30, 2024

Conversation

odynvolk
Copy link
Contributor

Checklist

  • Was the code tested in lab?
  • Have you reviewed the code yourself?
  • Are the configs updated?
  • Does the readme need an update?

Write the description and the reason for this PR below ↓

Currently we're allowing streetNumber to have values as "1A", which should be streetNumber 1, stairCase A. This causes problems at distribution innovation later on.

This a one part of the fixes needed here.

https://favro.com/organization/a75be0396fe39314c7ac300f/fdaea1f08a3e304708565fd5?card=Bon-166377

@odynvolk odynvolk requested a review from a team as a code owner July 26, 2024 14:17
Copy link
Contributor

@MattiasOlla MattiasOlla left a comment

Choose a reason for hiding this comment

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

Ska vi inte tillåta Testgatan 1A? Känns som en ganska vanlig grej i adresser?

@varney
Copy link
Contributor

varney commented Jul 29, 2024

Ska vi inte tillåta Testgatan 1A? Känns som en ganska vanlig grej i adresser?

Det ska egentligen vara streetName: Testgatan, streetNumber: 1, stairCase: A - så nej, streetNumber: 1A ska inte tillåtas.

Copy link
Contributor

@varney varney left a comment

Choose a reason for hiding this comment

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

The problem is that not all streetNumbers are just numbers. There are some addresses out in the country that have an alphabetic streetNumber, and others that have e.g. -39 which is also legitimate.

Perhaps restricting to:

  • only numeric, OR
  • only numeric with leading -, OR
  • only alphabetic

would be better.

@odynvolk
Copy link
Contributor Author

The problem is that not all streetNumbers are just numbers. There are some addresses out in the country that have an alphabetic streetNumber, and others that have e.g. -39 which is also legitimate.

Perhaps restricting to:

  • only numeric, OR
  • only numeric with leading -, OR
  • only alphabetic

would be better.

Ah OK! Will fix! Update coming later today.

Copy link
Contributor

@varney varney left a comment

Choose a reason for hiding this comment

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

👍

Oh how I dislike weird addresses.

@odynvolk odynvolk merged commit 3dd7783 into master Jul 30, 2024
2 checks passed
@odynvolk odynvolk deleted the fix/street-number-only-numbers-as-string branch July 30, 2024 07:28
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants