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

unique-name-generator generates incorrect names, which can cause broken queries #40994

Closed
camsaul opened this issue Apr 3, 2024 · 0 comments · Fixed by #40752
Closed

unique-name-generator generates incorrect names, which can cause broken queries #40994

camsaul opened this issue Apr 3, 2024 · 0 comments · Fixed by #40752
Assignees
Labels
.Backend Priority:P3 Cosmetic bugs, minor bugs with a clear workaround Querying/Processor .Team/QueryProcessor :hammer_and_wrench: Type:Bug Product defects
Milestone

Comments

@camsaul
Copy link
Member

camsaul commented Apr 3, 2024

(let [unique-name (mbql.u/unique-name-generator)]
  [(unique-name :x "A")
   (unique-name :x "B")
   (unique-name :x "A")
   (unique-name :y "A")
   (unique-name :y "A")])
;; => ["A" "B" "A" "A_2" "A_3"]

but it should generate

(let [unique-name (mbql.u/unique-name-generator)]
  [(unique-name :x "A")
   (unique-name :x "B")
   (unique-name :x "A")
   (unique-name :y "A")
   (unique-name :y "A")])
;; => ["A" "B" "A" "A_2" "A_2"]
@camsaul camsaul added Type:Bug Product defects Priority:P3 Cosmetic bugs, minor bugs with a clear workaround Querying/Processor .Backend .Team/QueryProcessor :hammer_and_wrench: labels Apr 3, 2024
@camsaul camsaul self-assigned this Apr 3, 2024
@camsaul camsaul added this to the 0.50 milestone Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
.Backend Priority:P3 Cosmetic bugs, minor bugs with a clear workaround Querying/Processor .Team/QueryProcessor :hammer_and_wrench: Type:Bug Product defects
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant