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

Create new phase for bug trimming #1308

Merged

Conversation

NorbertLoh
Copy link
Contributor

@NorbertLoh NorbertLoh commented Feb 3, 2025

Summary:

Fixes #1306

Changes Made:

  • Added a new component called bug-trimming
  • Added new phase into phase.model.ts
  • Added new phase into session.model.ts
  • Added new phase into permission.service.ts
  • Updated issue.service.ts to handle new bug trimming phase

Proposed Commit Message:

Add new phase called bug trimming to CATcher

This new implementation is needed to support the new phase of
CATcher.

Multiple phases have to be updated to support the phase. These files
are phase.model.ts, session.model.ts, permission.service.ts and
issue.service.ts.

The new implementation of the phase is similar to how previous
phases are implemented.

The new public_data setting for the new phase can be found in
PR #1308.

Additional info

Since we are still enabling students to update during this phase, The following section in phase-bug-trimming-routing.module.ts should be updated to the correct IssueComponent.

  // Insert new route here to view an issue to change label during bug trimming phase
  // {
  //   path: 'phaseBugTrimming/issues/:issue_id',
  //   component: IssueComponent,
  //   canActivate: [AuthGuard],
  //   canDeactivate: [CanDeactivateIssueGuard]
  // }

The new public_data setting should be similar to this new configuration

{
  "openPhases" : ["phaseBugReporting", "phaseBugTrimming", "phaseTeamResponse", "phaseTesterResponse", "phaseModeration"],
  "phaseBugReporting": "bugreporting",
  "phaseBugTrimming": "bugreporting",
  "phaseTeamResponse": "pe-results",
  "phaseTesterResponse": "bugreporting",
  "phaseModeration": "pe-evaluation"
}

@NorbertLoh NorbertLoh marked this pull request as ready for review February 4, 2025 05:01
Copy link
Contributor

@Eclipse-Dominator Eclipse-Dominator left a comment

Choose a reason for hiding this comment

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

Besides the formatted function,
LGTM!

Comment on lines 90 to 97
map((response) => {
const issue = this.createIssueModel(response);
this.updateLocalStore(issue);
return issue;
}),
catchError((err) => this.getIssue(issueId))
);
})
Copy link
Contributor

Choose a reason for hiding this comment

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

There is no change to this part of the file, a formatting change is not relevant to this PR. Let's remove this change from the PR.

if your ide is automatically formatting this, there should be an option to make it only format parts you modify.

@Eclipse-Dominator
Copy link
Contributor

Another note. This PR should close #1306, not #1301

Copy link
Contributor

@nknguyenhc nknguyenhc left a comment

Choose a reason for hiding this comment

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

You may want to find all usages of phase :)

image

image

image

This one should include phase bug trimming as well? Tho it only affects tutors and admins.

image

Should include phase trimming as well.

The list is not exhaustive tho, those are what I managed to find.

Copy link
Contributor

@nknguyenhc nknguyenhc left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Contributor

@Eclipse-Dominator Eclipse-Dominator left a comment

Choose a reason for hiding this comment

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

LGTM!

@Eclipse-Dominator Eclipse-Dominator merged commit 64fc24b into CATcher-org:feature-bug-trimming Feb 8, 2025
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.

3 participants