Skip to content

Conversation

@sg-gs
Copy link
Member

@sg-gs sg-gs commented Jan 21, 2026

Description

Related Issues

Related Pull Requests

Checklist

  • Changes have been tested locally.
  • Unit tests have been written or updated as necessary.
  • The code adheres to the repository's coding standards.
  • Relevant documentation has been added or updated.
  • No new warnings or errors have been introduced.
  • SonarCloud issues have been reviewed and addressed.
  • QA Passed

Testing Process

Additional Notes

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jan 21, 2026

Deploying drive-web with  Cloudflare Pages  Cloudflare Pages

Latest commit: 2ebde1f
Status: ✅  Deploy successful!
Preview URL: https://dde9e286.drive-web.pages.dev
Branch Preview URL: https://refactor-remove-dead-code.drive-web.pages.dev

View logs

@sg-gs
Copy link
Member Author

sg-gs commented Jan 22, 2026

WDYT @CandelR ?

Copy link
Collaborator

@CandelR CandelR left a comment

Choose a reason for hiding this comment

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

@sg-gs I understand that it is a tool or AI that you have tried out to see how well it works for cleaning code, is that right?
It seems to do a good job of removing unused code. The only thing missing is some context about certain components. For example, in the Workspaces (B2B) section, there are some that are not used, but they were created at the time because there is a design, and I think that if B2B is continued, they will be used.
It also seems that it does not take into account orphaned translations.
But it does take into account tests of code that is not used, and deletes the code and the corresponding tests.
So it's not bad 👌

onSavingAvatarError: (error: unknown) => void;
}

const UploadWorkspaceAvatarModal = ({
Copy link
Collaborator

Choose a reason for hiding this comment

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

@larry-internxt Do you remember why this component is not used?

Copy link
Contributor

Choose a reason for hiding this comment

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

@larry-internxt Do you remember why this component is not used?

No I dont remember why

ps: that is not my current account hahaha that account doesnt ping me

{!isUserTeams && isTeams && (
<section className="flex h-40 w-full flex-col items-center justify-center rounded-xl border border-gray-10 bg-gray-1 py-10">
<p className="font-regular text-center text-base text-gray-50">
{t('preferences.workspace.members.tabs.teams.emptyTeams.title')}
Copy link
Collaborator

Choose a reason for hiding this comment

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

nit: that translation seems unused after this component remove

@sg-gs
Copy link
Member Author

sg-gs commented Jan 23, 2026

As long as it is not currently needed, I will just wipe out that code. Once the moment arrives, we can rescue it from the corresponding PR, meanwhile, it is noise and contributes negatively to the coverage and maintenance of this project, I think @CandelR

@sg-gs
Copy link
Member Author

sg-gs commented Jan 23, 2026

I am pretty sure I can wipe out another thousand lines, but I did not want to create a massive PR :)

@sg-gs sg-gs marked this pull request as ready for review January 26, 2026 13:44
@sg-gs sg-gs requested review from a team, larryrider and xabg2 as code owners January 26, 2026 13:44
@sg-gs
Copy link
Member Author

sg-gs commented Jan 26, 2026

Waiting for the rest of the reviewers @xabg2 @TamaraFinogina @larry-internxt @jaaaaavier

export type Views = 'general' | 'invite' | 'requests';
export type RequestStatus = 'pending' | 'accepted' | 'denied';

export const REQUEST_STATUS = {
Copy link
Contributor

Choose a reason for hiding this comment

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

It seems to be still expected in tests:

Image

Copy link
Contributor

@TamaraFinogina TamaraFinogina left a comment

Choose a reason for hiding this comment

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

Tests are failing. Some are missing REQUEST_STATUS, so returning it should fix at least some of the tests.

@TamaraFinogina
Copy link
Contributor

P.S. Sonar complains about 6 unused imports, we can clean them up too

@sg-gs
Copy link
Member Author

sg-gs commented Jan 26, 2026

Let's close this first @TamaraFinogina. Waiting your review @jaaaaavier

@sonarqubecloud
Copy link

@sg-gs sg-gs merged commit 754bfaa into master Jan 26, 2026
9 of 10 checks passed
@sg-gs sg-gs deleted the refactor/remove-dead-code branch January 26, 2026 15:06
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.

6 participants