Skip to content

Comments

Add support shipmonk/composer-dependency-analyser#358

Merged
gsteel merged 1 commit intolaminas:1.32.xfrom
sasezaki:dependency-analyser
Nov 27, 2025
Merged

Add support shipmonk/composer-dependency-analyser#358
gsteel merged 1 commit intolaminas:1.32.xfrom
sasezaki:dependency-analyser

Conversation

@sasezaki
Copy link
Contributor

@sasezaki sasezaki commented Nov 23, 2025

Q A
New Feature yes

Description

I propose to add `shipmonk/composer-dependency-analyser
https://github.com/shipmonk-rnd/composer-dependency-analyser

  • It has already been added to CI in the v5 branch of laminas-hydrator

  • I'm also using it personally (in work projects), and I think it's functioning excellently

Signed-off-by: sasezaki <sasezaki@gmail.com>
@sasezaki sasezaki force-pushed the dependency-analyser branch from 9bd168f to c024651 Compare November 23, 2025 13:06
@gsteel gsteel requested a review from a team November 25, 2025 22:19
Copy link
Member

@gsteel gsteel left a comment

Choose a reason for hiding this comment

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

This looks good to me @sasezaki Thank you :)

I'll wait for others to check it over too however as I'm not 100% on this codebase 😬

@gsteel gsteel requested review from Ocramius and boesing November 25, 2025 22:22
Copy link
Member

@Ocramius Ocramius left a comment

Choose a reason for hiding this comment

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

As a maintainer of maglnet/composer-require-checker, I'm vary of this.

The reason is that I know that the shipmonk dependency cuts corners aggressively there, skipping the AST world, and diving directly into the "let's parse code with regexes". EDIT: historic reference

I'd rather see improvements in tooling that does things formally, than introducing this specific tool 🤔

EDIT: I stand corrected - it uses reflection. I'm not 100% sure about this then, will need to check again.

@sasezaki
Copy link
Contributor Author

Hi @Ocramius

I believe your concern is whether we should adopt this as the de facto standard for composer dependency checking in the Laminas project.

I don't intend this PR to replace composer-require-checker.
I think it would be good if this could be used as a secondary checker for the time being, while keeping composer-require-checker as the primary tool. As mentioned in the hydrator issue, detecting "unused" dependencies can also serve as a clue for reviewing dependencies.

Copy link
Member

@Ocramius Ocramius left a comment

Choose a reason for hiding this comment

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

Sounds good to me: I did a new check over this package, and I believe it changed substantially since last time I investigated it.

Can agree with @sasezaki's point 👍

@gsteel gsteel self-assigned this Nov 27, 2025
@gsteel gsteel merged commit 974d867 into laminas:1.32.x Nov 27, 2025
49 checks passed
@gsteel gsteel added this to the 1.32.0 milestone Nov 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants