Bug: Address circular dependency #68

Closed
opened 2021-01-02 18:35:05 +00:00 by niggl · 1 comment
Owner

With the implementation of the donor api endpoints a new bug surfaced.
Due to the way address entities and their relations are currently implemented they cause a circular depdendency.

To be more exact - this part causes the problem:

  /**
   * Used to link the address to participants.
   */
  @OneToMany(() => Participant, participant => participant.address, { nullable: true })
  participants: Participant[];

  /**
   * Used to link the address to runner groups.
   */
  @OneToMany(() => RunnerOrganisation, group => group.address, { nullable: true })
  groups: RunnerOrganisation[];

Due to this bug addresses for organisations are currently disabled in all branches following #65 (or in which #65 has been merged into).

TODO:

  • Find a solution to fix the circular dependency
  • Add addresses back into all actions
  • Add addresses back into all tests
With the implementation of the donor api endpoints a new bug surfaced. Due to the way address entities and their relations are currently implemented they cause a circular depdendency. To be more exact - this part causes the problem: ```typescript /** * Used to link the address to participants. */ @OneToMany(() => Participant, participant => participant.address, { nullable: true }) participants: Participant[]; /** * Used to link the address to runner groups. */ @OneToMany(() => RunnerOrganisation, group => group.address, { nullable: true }) groups: RunnerOrganisation[]; ``` Due to this bug addresses for organisations are currently disabled in all branches following #65 (or in which #65 has been merged into). TODO: * [ ] Find a solution to fix the circular dependency * [ ] Add addresses back into all actions * [ ] Add addresses back into all tests
niggl added this to the Donations&Scans milestone 2021-01-02 18:35:05 +00:00
niggl added the
status:doing
priority:high
bug
labels 2021-01-02 18:35:05 +00:00
Author
Owner

To work on the issue i merged the branch for #65 into this issue's branch.

To work on the issue i merged the branch for #65 into this issue's branch.
niggl referenced this issue from a commit 2021-01-02 18:56:06 +00:00
niggl closed this issue 2021-01-02 21:13:51 +00:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: lfk/backend#68
No description provided.