Skip to content

Transfer: multiple source-target modes#460

Merged
reh-sfl merged 2 commits into
savoirfairelinux:stagingfrom
reh-sfl:transfer-multiple-modes
Jul 22, 2026
Merged

Transfer: multiple source-target modes#460
reh-sfl merged 2 commits into
savoirfairelinux:stagingfrom
reh-sfl:transfer-multiple-modes

Conversation

@reh-sfl

@reh-sfl reh-sfl commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Fixes # by...

Changes proposed in this pull request:

  1. Adding a reflexive option to copy within the same variant, we will have:
  • Copy to a different variant
  • Copy within the same variant
  1. Fix the bug where it showed the source variant in the target list

Status

  • READY
  • HOLD
  • WIP (Work-In-Progress)

How to verify this change

Open the web dashboard, go to the Transfer tab then use the new "I want to copy…" selector

Pull Request Checklist

Please review and check all that apply before submitting your PR:

  • The code compiles and passes all tests
  • All new and existing tests are passing
  • Documentation has been updated (if applicable)
  • Code follows project style guidelines
  • No sensitive information is included
  • Linked relevant issues (if any)
  • Added necessary reviewers

@ValentinBoudevin ValentinBoudevin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

  1. "Copy assessments to other matching findings in one variant.¨ seems a bit difficult to understand as we don´t use findings anywhere else.

Should be something closer to "Copy assessments from previous packages versions in a variant".

Image

Detected 0 assessments but this is wrong.

Example linux-yocto@6.6.129 (the current version) doesn´t have any custom assessments yet:

Image

@ValentinBoudevinSFL ValentinBoudevinSFL left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

The same-variant flow is generally well integrated, but overlapping source/target selections can corrupt copy results depending on operation order and must be addressed before merge.

Comment thread src/routes/settings.py
@@ -893,6 +894,7 @@ def copy_variant_assessments() -> ResponseReturnValue:
src_finding = assessment.finding

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Within one variant, a selected target can also be the source assessment of another selection. In overwrite mode, processing A→B before B→A mutates B before its values are copied, making results order-dependent and potentially collapsing both assessments to A's values. Snapshot all source assessment fields before applying any writes, or reject cyclic/conflicting selections; add a reciprocal-copy test.

@reh-sfl
reh-sfl requested a review from ValentinBoudevin July 20, 2026 17:28
@reh-sfl
reh-sfl force-pushed the transfer-multiple-modes branch from 8c0c453 to d4e2eda Compare July 20, 2026 19:28
reh-sfl added 2 commits July 21, 2026 16:11
Add a route selector for copying assessments within one variant or between two variants. Allow same-variant backend operations while excluding the source finding from preview and copy targets.
@reh-sfl
reh-sfl force-pushed the transfer-multiple-modes branch from d4e2eda to 0444fe5 Compare July 21, 2026 20:11
@reh-sfl
reh-sfl merged commit e53beda into savoirfairelinux:staging Jul 22, 2026
5 checks passed
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.

4 participants