Whole file
kayak/pypika
The author described this change as “Fix tuple table replacement”. It counts as a record because the check below fails on the code as it stood at baef001dd and passes on ceb470f44, with nothing else changed between the two runs.
Projectkayak/pypika
Fix saved2020-04-24
Sharing licenceApache-2.0 · LICENSE.txt
Change size+1 −3
What the code was meant to do, written into the code itself as a save note
Fix tuple table replacement
The change
| 539 | 539 | return "*" | |
| 540 | 540 | ||
| 541 | 541 | ||
| 542 | - | ||
| 543 | 542 | class Tuple(Criterion): | |
| 544 | 543 | def __init__(self, *values: Any) -> None: | |
| 545 | 544 | super().__init__() | |
| ⋯ | |||
| 571 | 570 | A copy of the field with the tables replaced. | |
| 572 | 571 | """ | |
| 573 | 572 | self.values = [ | |
| 574 | - | [value.replace_table(current_table, new_table) for value in value_list] | |
| 575 | - | for value_list in self.values | |
| 573 | + | value.replace_table(current_table, new_table) for value in self.values | |
| 576 | 574 | ] | |
| 577 | 575 | ||
| 578 | 576 | ||
The check that tells the two apart
fail→pass·pypika/tests/test_query.py::QueryTablesTests::test_replace_tuple_table
Check file pypika/tests/test_query.py, taken without changes from the fix and copied onto the older code, so the exact same check runs against both versions.
Origin and history
The code before itbaef001dd2362661311b6e2f949d2be4de5c23c8
Broken version dated2020-04-21
Modulepypika.terms
Units changedTuple
Fingerprintcf26f60110093830
Checked2026-08-18 by goldset/0.1
Every field above is generated by our program. None of it is written by hand.
Other bugs found in kayak/pypika
- 2024-04-17fix `Field.__init__` (#742)
- 2023-09-26Fix: Allow the usage of `frozenset` in the `isin(...)` and `notin(...)` functions (#744)
- 2023-09-22fix(terms): fixed EmptyCriterion bug with ComplexCriterion (#732)
- 2021-08-26MySQLQuery
- 2021-01-11Fix empty Postgres array syntax (#539)
- 2021-01-04Fix PostgreSQLQueryBuilder returning clause code causing Py3.9 test failures