Skip to content

fix(#5154): prevent alert message from showing while loading SBOMs#5157

Merged
SteKoe merged 3 commits intomasterfrom
fix/5154-do-not-show-alert-message-while-loading
Mar 13, 2026
Merged

fix(#5154): prevent alert message from showing while loading SBOMs#5157
SteKoe merged 3 commits intomasterfrom
fix/5154-do-not-show-alert-message-while-loading

Conversation

@SteKoe
Copy link
Copy Markdown
Contributor

@SteKoe SteKoe commented Mar 13, 2026

fixes #5154

@SteKoe SteKoe requested a review from a team as a code owner March 13, 2026 07:56
@SteKoe SteKoe requested a review from Copilot March 13, 2026 08:11
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the SBOM dependency trees instance view to avoid showing the “no data provided” warning while SBOM IDs are still being fetched.

Changes:

  • Gate the “no data provided” warning behind hasLoaded to prevent it from appearing during initial load.
  • Reset hasLoaded at the start of fetchSboms() to re-enable the loading state on refetch.
  • Introduce a new isLoading data property (currently unused).
Comments suppressed due to low confidence (1)

spring-boot-admin-server-ui/src/main/frontend/views/instances/sbomdependencytrees/index.vue:38

  • The "no data provided" warning will still render when the SBOM fetch fails (because hasLoaded becomes true and sboms stays empty), leading to a misleading second alert alongside the fetch error. Consider guarding this block with !error (or similar) so it only shows when the request succeeded but returned no IDs.
    <template v-if="hasLoaded && sboms.length === 0">
      <sba-alert
        severity="WARN"
        :error="$t('instances.dependencies.no_data_provided')"
      />

You can also share your feedback on Copilot code review. Take the survey.

Copilot AI review requested due to automatic review settings March 13, 2026 08:53
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the SBOM dependency trees instance view to avoid showing the “no data provided” warning while SBOM IDs are still loading, and adds a regression test for the empty-state loading behavior.

Changes:

  • Gate the empty-state warning in the SBOM dependency trees view behind a hasLoaded flag.
  • Reset hasLoaded to false when starting an SBOM ID fetch.
  • Add a new UI test that asserts the warning is hidden while the fetch is pending and appears after an empty result resolves.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
spring-boot-admin-server-ui/src/main/frontend/views/instances/sbomdependencytrees/index.vue Prevents the empty-state warning from rendering during the initial/pending load by requiring hasLoaded.
spring-boot-admin-server-ui/src/main/frontend/views/instances/sbomdependencytrees/index.spec.ts Adds a regression test covering the pending-load vs. resolved-empty behavior.
Comments suppressed due to low confidence (1)

spring-boot-admin-server-ui/src/main/frontend/views/instances/sbomdependencytrees/index.vue:38

  • The “no data provided” warning will also render when fetchSbomIds() fails (because hasLoaded becomes true and sboms stays empty), leading to a misleading warning alongside the section’s error alert. Consider gating the empty-state warning on !error (e.g., include !error in the v-if) so it only shows for a successful load with an empty result.
    <template v-if="hasLoaded && sboms.length === 0">
      <sba-alert
        severity="WARN"
        :error="$t('instances.dependencies.no_data_provided')"
      />

You can also share your feedback on Copilot code review. Take the survey.

@SteKoe SteKoe merged commit 6bde263 into master Mar 13, 2026
6 checks passed
@SteKoe SteKoe deleted the fix/5154-do-not-show-alert-message-while-loading branch March 13, 2026 09:07
@SteKoe SteKoe added this to the 4.0.3 milestone Mar 28, 2026
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.

Bug: Error alert is shown while navigating the Dependencies view

2 participants