crazyfactory / crazyfactory/php-sniffs

fix: linting should not remove imports used in annotations

Open
#58 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

technical
Dominant language
PHP
Stars
0
Forks
0
PR merge metrics
No merged PRs in 30d

Description

Lint fixing removes imports where the class's only use is in an @var annotation.

This breaks nav and code completion.

  • do not remove these imports

image.png

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No files or tests are named. Start by reproducing the lint-fixing behavior with a class used only in an @var annotation, then locate the fixer logic and existing coverage. Done means imports referenced by annotations are retained and navigation and code completion no longer break.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.