-
-
Notifications
You must be signed in to change notification settings - Fork 48
Collect dependencies defined in @throws docblock tags #513
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #513 +/- ##
============================================
+ Coverage 97.75% 97.79% +0.03%
- Complexity 615 626 +11
============================================
Files 80 80
Lines 1778 1810 +32
============================================
+ Hits 1738 1770 +32
Misses 40 40 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
|
fixes #514 |
|
to complete this we should fix the row number, that now is the first line of the comment instead of the line of the throws. |
Add two integration tests to verify that dependencies defined in @throws docblock tags are properly collected: - test_it_collects_throws_tag_as_dependencies: Tests collection of relative and fully qualified exception names in @throws tags - test_it_collects_throws_tag_with_fully_qualified_names: Tests handling of different naming conventions (backslash-prefixed, relative to namespace) These tests validate that the @throws tag parsing feature works end-to-end and that exceptions are properly resolved to their fully qualified names. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
…correct line numbers - Merge PR #513 branch (collect_throws_types) into working branch - Resolve conflicts in FileVisitor.php (keep both handlePropertyHookNode and handleThrowsTags) - Fix @throws line number: previously used method start line, now computes the actual file line of each @throws tag using PHPStan's startLine attribute combined with the docblock's start line in the file - Modify Docblock::getThrowTagsTypes() to return [{type, line}] pairs instead of plain strings, exposing per-tag line info from PHPStan parser - Update tests to reflect that PHP core classes (e.g. \Exception) are filtered out by the existing isPhpCoreClass() check in ClassDescriptionBuilder Fixes #514 https://claude.ai/code/session_01H3NqdUfGArp9bzf1WiXMos



No description provided.