Skip to content

chore(apps): remove unused variables, imports, functions and classes#1554

Merged
ArtieReus merged 3 commits intomainfrom
artie-fixUnused-variable-import-function-class
Mar 23, 2026
Merged

chore(apps): remove unused variables, imports, functions and classes#1554
ArtieReus merged 3 commits intomainfrom
artie-fixUnused-variable-import-function-class

Conversation

@ArtieReus
Copy link
Collaborator

@ArtieReus ArtieReus commented Mar 20, 2026

Summary

Removes unused variables, imports, functions, and classes identified by static code analysis to improve code quality and maintainability.

Changes

  • Apps (supernova, doop, greenhouse): Removed unused imports and variables from React components
  • Greenhouse components: Cleaned up unused UI component imports, removed unused helper functions and variables
  • Store modules: Removed unused updateSecrets helper function that was never called
  • Test files: Removed unused test utilities and constants

Files Changed

  • apps/supernova/src/App.tsx - removed unused isObjectWithKeys import
  • apps/supernova/src/components/StoreProvider.tsx - removed unused devtools import
  • apps/doop/src/App.tsx - removed unused ContentHeading import
  • apps/doop/src/routes/violations.tsx - removed unused retainSearchParams import
  • apps/greenhouse/src/components/core-apps/org-admin/components/plugins/plugin-edit/PluginEdit.tsx - removed unused variables and onPanelClose function
  • apps/greenhouse/src/components/core-apps/org-admin/components/secrets/store.ts - removed unused updateSecrets function
  • Multiple component files - removed unused UI component imports (Stack, Panel, PanelBody, etc.)
  • Test files - removed unused test utilities

Testing Instructions

  1. pnpm i
  2. pnpm TASK

Checklist

  • I have performed a self-review of my code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have added tests that prove my fix is effective or that my feature works.
  • New and existing unit tests pass locally with my changes.
  • I have made corresponding changes to the documentation (if applicable).
  • My changes generate no new warnings or errors.
  • I have created a changeset for my changes.

PR Manifesto

Review the PR Manifesto for best practises.

@ArtieReus ArtieReus requested a review from a team as a code owner March 20, 2026 10:40
@ArtieReus ArtieReus self-assigned this Mar 20, 2026
@changeset-bot
Copy link

changeset-bot bot commented Mar 20, 2026

🦋 Changeset detected

Latest commit: bc88458

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 5 packages
Name Type
@cloudoperators/juno-messages-provider Patch
@cloudoperators/juno-app-greenhouse Patch
@cloudoperators/juno-app-supernova Patch
@cloudoperators/juno-app-doop Patch
@cloudoperators/juno-app-example Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

@guoda-puidokaite guoda-puidokaite left a comment

Choose a reason for hiding this comment

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

Thank You for the fixes!

(Suggestion)

As discussed... For future improvement, in this or another PR we should update the lint check to fail on unused vars, as in ui-components. Should be a matter of comparing config files.

I created a test PR with unused vars in doop and ui-components to show that:

  • doop (and other apps) still passes in this case
  • ui-components catches unused vars and fails the pipeline

@ArtieReus
Copy link
Collaborator Author

Thank You for the fixes!

(Suggestion)

As discussed... For future improvement, in this or another PR we should update the lint check to fail on unused vars, as in ui-components. Should be a matter of comparing config files.

I created a test PR with unused vars in doop and ui-components to show that:

  • doop (and other apps) still passes in this case
  • ui-components catches unused vars and fails the pipeline

agree. Lets improve the lint checker.

Copy link
Contributor

@guoda-puidokaite guoda-puidokaite left a comment

Choose a reason for hiding this comment

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

Thank You! Can improve anytime.

@ArtieReus ArtieReus merged commit c8a6676 into main Mar 23, 2026
15 checks passed
@ArtieReus ArtieReus deleted the artie-fixUnused-variable-import-function-class branch March 23, 2026 08: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