Repository navigation
Conversation
Equal ids on a fresh install were taken as joins, and a value one write happened to store was pinned: - a row's own primary key is never a key to another table, and a new row's own key never links it to its record, without a declared foreign key; - a value is never placed in the column a path arrived by; - a list item's link must hold the record's key in every item row, and two that always agree are refused unless a declared foreign key picks one; - a place through a key only equal values support, with a supported rival that fits every demonstration, becomes a locations question; - a pin needs two rows that agree; one row is listed in the bookkeeping question, left out of the proposal, and a field set that leaves such a column open gets no contract; - child rows see the acting user, and a row beside an update may link to the target instead of pinning a demonstration's id.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Item 4 of #1677: the generator took ids that happened to be equal for joins, and pinned values one demonstration happened to store. Setup on the held-out apps fixed these by hand.
What changed
Joins (
generate/demo_analysis.py,generate/verify_contract.py):locations.<kind>) instead of picking. Elimination by a claimed column no longer drops a longer path through it, which had left only the coincidental place.Pins:
uncheckedor records another demonstration.Unpinned, listed underrejected). Before, the column was silently unchecked for that set.Docs:
GENERATE_CONTRACTS.md, CAPABILITIES.md.Tests
tests/test_generate_coincidences.py(new, real PostgreSQL, no declared foreign keys, seeded so ids coincide in every demonstration):ext_idequalled its customer's id twice, beside the project's customer. The generator asks, with both places as options. The person's pick gives a CONFIRMED correct write.order_id, so a correct order with two lines is CONFIRMED.timesheets.id -> customers.name, the ticket's customer was picked with no question, the currency was pinned, and the order fixture couldn't be answered. All 4 tests fail.tests/test_generate_verify_contract.py: the tracker test's custom field id was 1, the bot's id. With the actor now seen on child rows, that equality was a real ambiguity, so the fixture uses 4 and adds a second demonstration with a custom field.Real-app evidence
Running on held-out apps (instance 1) once the shared VM has room; this section will hold the commands and outputs.