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

feat: Apply multiple @PrimaryKey annotations to Transfers #1220

Conversation

KClough
Copy link
Collaborator

@KClough KClough commented Jul 28, 2022

Summary:

Summarize the changes in the pull request including how it relates to any issues (include the #number, or link them).

Resolves #1113

This PR expands @bdferris-v2 's efforts and applies the multiple @PrimaryKey functionality to the remaining schema's defined in #1113.

Expected behavior:

Explain and/or show screenshots for how you expect the pull request to work in your testing (in case other devices exhibit different behavior).

Please make sure these boxes are checked before submitting your pull request - thanks!

  • Run the unit tests with gradle test to make sure you didn't break anything
  • Format the title like "feat: [new feature short description]". Title must follow the Conventional Commit Specification(https://www.conventionalcommits.org/en/v1.0.0/).
  • Linked all relevant issues
  • Include screenshot(s) showing how this pull request works and fixes the issue(s)

Marking as draft until #1190 is merged.

I've tested this functionality with a hand edited GTFS data set that can be shared if helpful.

@KClough KClough marked this pull request as draft July 28, 2022 16:22
@KClough KClough marked this pull request as ready for review August 4, 2022 20:45
@bdferris-v2
Copy link
Collaborator

I already updated Translations in #1190. And for transfers, you'll need to add translationRecordIdType fields to the @PrimaryKey, marking from_stop_id and to_stop_id as the RECORD_ID and RECORD_SUB_ID, respectively. All other columns need to be marked as UNSUPPORTED.

@KClough KClough changed the title feat: Apply multiple @PrimaryKey annotations to Translations + Transfers feat: Apply multiple @PrimaryKey annotations to Transfers Aug 4, 2022
@KClough
Copy link
Collaborator Author

KClough commented Aug 4, 2022

I already updated Translations in #1190. And for transfers, you'll need to add translationRecordIdType fields to the @PrimaryKey, marking from_stop_id and to_stop_id as the RECORD_ID and RECORD_SUB_ID, respectively. All other columns need to be marked as UNSUPPORTED.

Thanks @bdferris-v2 , I should've caught that. I would have assumed cherry picking my commit would have had a merge conflict with yours. I've addressed the additional requested changes for transfers.

Copy link
Collaborator

@bdferris-v2 bdferris-v2 left a comment

Choose a reason for hiding this comment

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

LGTM

@isabelle-dr
Copy link
Contributor

isabelle-dr commented Aug 5, 2022

I tested the 4 conditions displayed in #1113 with a test dataset, and everything is working, thank you @KClough for this PR, and @bdferris-v2 for the updates in #1190! Merging, since the code review has been performed.

Screen Shot 2022-08-05 at 11 58 01 AM

I used with the jar file from this action run

@isabelle-dr isabelle-dr merged commit d5679f2 into MobilityData:master Aug 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update validator after the addition of primary and foreign keys in the specification
3 participants