Skip to content

Fix displaying errors when importing of a report fails#5406

Merged
greenbonebot merged 3 commits into
mainfrom
report-import-error-handling
Jul 10, 2026
Merged

Fix displaying errors when importing of a report fails#5406
greenbonebot merged 3 commits into
mainfrom
report-import-error-handling

Conversation

@bjoernricks

Copy link
Copy Markdown
Contributor

What

Fix displaying errors when importing of a report fails

Why

Don't use the onError handler and let the dialog handle the error cases
instead to show possible errors of the request in the dialog.

References

https://jira.greenbone.net/browse/GEA-1751

@bjoernricks bjoernricks requested a review from a team as a code owner July 10, 2026 11:12
@greenbonebot greenbonebot enabled auto-merge (rebase) July 10, 2026 11:12
@github-actions

github-actions Bot commented Jul 10, 2026

Copy link
Copy Markdown

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Snapshot Warnings

⚠️: No snapshots were found for the head SHA 931cc6e.
Ensure that dependencies are being submitted on PR branches and consider enabling retry-on-snapshot-warnings. See the documentation for more information and troubleshooting advice.

Scanned Files

None

Add data type shape for the handleImportReport function and change
xml_file to a File for the ReportCommand import method. This ensures the
props are passed correctly when importing a report.
Don't use the onError handler and let the dialog handle the error cases
instead to show possible errors of the request in the dialog.
@bjoernricks bjoernricks force-pushed the report-import-error-handling branch from 86b0971 to 7095842 Compare July 10, 2026 11:12
…two tasks

If there is only one or even no task available disable the task
selection in the report import dialog because the user can't change it.
Comment thread src/web/pages/tasks/TaskComponent.tsx
@codecov

codecov Bot commented Jul 10, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 80.95%. Comparing base (cb286c6) to head (931cc6e).

Files with missing lines Patch % Lines
src/web/pages/tasks/TaskComponent.tsx 0.00% 2 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5406   +/-   ##
=======================================
  Coverage   80.95%   80.95%           
=======================================
  Files        1269     1269           
  Lines       33070    33070           
  Branches     9941     9941           
=======================================
  Hits        26771    26771           
  Misses       5617     5617           
  Partials      682      682           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@greenbonebot greenbonebot merged commit 09ec59b into main Jul 10, 2026
26 of 27 checks passed
@greenbonebot greenbonebot deleted the report-import-error-handling branch July 10, 2026 11:33
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