Laravel Shift and Barry vd. Heuvel
e9b62b6ee0
Laravel 13.x Compatibility ( #1763 )
...
* Bump dependencies for Laravel 13
* Update GitHub Actions for Laravel 13
* Update workflow to remove cron schedule
Removed cron schedule and adjusted pull request branches.
* Fix syntax, modify Laravel version in run-tests.yml
Updated Laravel version from '13.0' to '13.x' in CI configuration.
* Update test-ci command in composer.json
* Fix test-ci command in composer.json
---------
Co-authored-by: Barry vd. Heuvel <[email protected] >
2026-02-21 09:54:37 +01:00
Pieter Willekens
37dfcf9e14
chore: update test snapshots after dependency upgrade ( #1762 )
2026-02-20 14:51:32 +01:00
Pieter Willekens
573c9f3f57
ci: add PHP 8.5 to integration test matrix ( #1760 )
...
The unit test matrix already includes PHP 8.5 but it was missing
from the integration tests.
2026-02-11 11:45:28 +01:00
Pieter Willekens and laravel-ide-helper
fd3cfbe09d
feat(ModelsCommand): add configuration option to disable model query methods ( #1692 )
...
* feat(ModelsCommand): add configuration option to disable model query methods
* composer fix-style
* update comment
* revert whitespace changes
* composer fix-style
* composer fix-style
---------
Co-authored-by: laravel-ide-helper <[email protected] >
2026-02-11 11:45:10 +01:00
Pieter Willekens
3bd70eafd0
fix: wrap bare intersection types in parentheses when adding nullable ( #1756 )
...
When a MorphTo relation's docblock uses a bare intersection type in the
generic parameter (e.g. `MorphTo<BaseModel&CanBeAssigned, $this>`), the
generated property type incorrectly becomes `BaseModel&CanBeAssigned|null`
instead of the correct `(BaseModel&CanBeAssigned)|null`.
This adds `wrapIntersectionType()` which ensures bare intersection types
are wrapped in parentheses before `|null` is appended, producing valid
DNF type syntax. Applied in both `setProperty()` and `applyNullability()`.
2026-02-10 15:19:29 +01:00
Pieter Willekens
5aca186d92
perf: reduce redundant lookups and file I/O in generation hot paths ( #1757 )
...
- Convert usedMethods from list to hash map for O(1) dedup lookups
- Cache getRelationTypes() and getRelationReturnTypes() per command run
- Reuse SplFileObject instances by filename instead of re-opening per method
- Cache ContextFactory results per declaring class across docblock helpers
Benchmarked with hyperfine (10 runs, 2 warmup): 1.37x faster (~27%).
2026-02-10 15:18:58 +01:00
barryvdh
148f956272
normalize composer.json
2026-02-07 13:33:03 +00:00
Barry vd. Heuvel
cff155b0d3
Replace psalm with larastan ( #1755 )
...
* Use larastan instead of psalm
* Fix cs
* Fix baseline
2026-02-07 14:32:53 +01:00
Sava and Sava Markovic
d87ec5835d
Support all DNF types from PHP RFC ( #1751 )
...
* Support all DNF types from PHP RFC
* Update failing test
---------
Co-authored-by: Sava Markovic <[email protected] >
2026-01-26 14:24:36 +01:00
Evan Burrell
b0dcd7c62f
Make Soft Deleted Relationships Nullable ( #1749 )
2026-01-11 14:34:18 +01:00
Jaspur and Barry vd. Heuvel
2ac73f2953
Skip calling fake() when required parameters exist (Socialite compatibility) ( #1746 )
...
* Skip calling fake() on facades that require parameters (fix Socialite error)
The ide-helper attempted to invoke Facade::fake() unconditionally, which
breaks when a facade (such as Laravel Socialite) requires a mandatory
parameter in its fake() method signature. This resulted in an
ArgumentCountError during `php artisan ide-helper:generate`.
This patch adds a ReflectionMethod check and skips calling fake() when
required parameters are present, ensuring compatibility with Socialite
and preserving expected behavior for facades that support parameterless
faking.
* Update Alias.php
---------
Co-authored-by: Barry vd. Heuvel <[email protected] >
2025-12-10 10:31:15 +01:00
Barry vd. Heuvel
c95825a745
Fix test
2025-12-10 10:16:51 +01:00
barryvdh
db606f30d1
Update CHANGELOG
2025-12-10 09:12:44 +00:00
Yannick Schinko
b106f7ee85
Add support for decimal column type ( #1739 )
...
* Add support for `decimal` column type
Previously `decimal` columns were represented with a cast. This now is no longer the case and instead the column type itself is `decimal`. This change takes that into account.
* The column type may also be `numeric`
* Update tests
v3.6.1
2025-12-10 10:11:07 +01:00
dependabot[bot] and dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
d61d20357e
Bump the deps group across 1 directory with 2 updates ( #1743 )
...
Bumps the deps group with 2 updates in the / directory: [actions/checkout](https://github.com/actions/checkout ) and [stefanzweifel/git-auto-commit-action](https://github.com/stefanzweifel/git-auto-commit-action ).
Updates `actions/checkout` from 5 to 6
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](https://github.com/actions/checkout/compare/v5...v6 )
Updates `stefanzweifel/git-auto-commit-action` from 6 to 7
- [Release notes](https://github.com/stefanzweifel/git-auto-commit-action/releases )
- [Changelog](https://github.com/stefanzweifel/git-auto-commit-action/blob/master/CHANGELOG.md )
- [Commits](https://github.com/stefanzweifel/git-auto-commit-action/compare/v6...v7 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
dependency-group: deps
- dependency-name: stefanzweifel/git-auto-commit-action
dependency-version: '7'
dependency-type: direct:production
update-type: version-update:semver-major
dependency-group: deps
...
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-10 10:10:25 +01:00
Jesper Noordsij
e9283c40a2
Remove calls to PHP 8.5-deprecated setAccessible ( #1744 )
...
These are no-op as of PHP 8.1 and thus no longer needed
See also https://wiki.php.net/rfc/make-reflection-setaccessible-no-op
2025-12-10 10:10:09 +01:00
WentTheFox
12a0d7d54c
Fix alias fake error ( #1745 )
...
* Add catch block in Alias::detectFake
* Update Alias unit tests
2025-12-10 10:09:42 +01:00
Serhii Petrov
9ef25f60e7
Add php 8.5 support ( #1735 )
2025-10-01 15:12:26 +02:00
Keita Shima
8dff6bb5ff
Fix typos in documentation and code comments ( #1733 )
...
- Fixed 'seperate' to 'separate' in README.md (2 occurrences)
- Fixed 'columname' to 'columnname' in README.md (2 occurrences)
- Fixed 'Wether' to 'Whether' in src/Method.php PHPDoc comments (2 occurrences)
2025-09-15 14:14:26 +02:00
dependabot[bot] and dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
53854ea7d9
Bump actions/checkout from 4 to 5 in the deps group ( #1731 )
...
Bumps the deps group with 1 update: [actions/checkout](https://github.com/actions/checkout ).
Updates `actions/checkout` from 4 to 5
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](https://github.com/actions/checkout/compare/v4...v5 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: '5'
dependency-type: direct:production
update-type: version-update:semver-major
dependency-group: deps
...
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-02 16:32:00 +02:00
Peter Jørgensen
1fa84a3b65
fix methodsto typo ( #1723 )
2025-08-04 15:07:10 +02:00
barryvdh
5e973967a7
Update CHANGELOG
2025-07-18 14:10:29 +00:00
erikn69 and Joel Stein
8d00250cba
Add magic *_exists properties ( #1712 )
...
* Added magic `*_exists` properties.
* fix return datatype
* disabled by default
---------
Co-authored-by: Joel Stein <[email protected] >
v3.6.0
2025-07-17 22:11:57 +02:00
Barry vd. Heuvel
877f5ed0a7
Trim strings and bump reflection docblock ( #1721 )
...
* Update version restraint
* UPdate snapshots
* update strings
2025-07-17 08:20:10 +02:00
Pieter Willekens
fafe264b3c
fix(ModelsCommand): use 'string' as realType for 'encrypted' casts ( #1698 )
2025-07-17 08:06:36 +02:00
erikn69
108f6269c1
Update .gitattributes - avoid all .php-cs-fixer files on vendor ( #1708 )
2025-07-17 08:02:50 +02:00
dependabot[bot] and dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
c488262f97
Bump stefanzweifel/git-auto-commit-action from 5 to 6 in the deps group ( #1719 )
...
Bumps the deps group with 1 update: [stefanzweifel/git-auto-commit-action](https://github.com/stefanzweifel/git-auto-commit-action ).
Updates `stefanzweifel/git-auto-commit-action` from 5 to 6
- [Release notes](https://github.com/stefanzweifel/git-auto-commit-action/releases )
- [Changelog](https://github.com/stefanzweifel/git-auto-commit-action/blob/master/CHANGELOG.md )
- [Commits](https://github.com/stefanzweifel/git-auto-commit-action/compare/v5...v6 )
---
updated-dependencies:
- dependency-name: stefanzweifel/git-auto-commit-action
dependency-version: '6'
dependency-type: direct:production
update-type: version-update:semver-major
dependency-group: deps
...
Signed-off-by: dependabot[bot] <[email protected] >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-17 08:02:35 +02:00
Barry vd. Heuvel
83e3f39b39
Fix tests on windows ( #1720 )
...
* Update run-tests.yml
* Update snapshot
* Simplify matrix
2025-07-17 08:02:25 +02:00
laravel-ide-helper
31979ed485
composer fix-style
2025-07-17 05:52:57 +00:00
erikn69
6d96f0bd1a
Support other OS on tests ( #1715 )
2025-07-17 07:52:32 +02:00
Kristijan
cff244b9b5
fix: Fixed wrong doc for softDeletes withTrashed method ( #1688 )
2025-07-17 07:50:16 +02:00
laravel-ide-helper
4dfc08a854
composer fix-style
2025-07-17 05:24:13 +00:00
erikn69
6c4ba2ad38
Support AsCollection::of($map), AsCollection::using($class, $map) ( #1714 )
...
* Support `AsCollection::of($map)`, `AsCollection::using($class, $map)`
* test compatibility(`of($map)`,`using($class, $map)` compiled), only laravel `>=12.10`
2025-07-17 07:23:52 +02:00
Robin Rosiers
1815a6140a
Add multi-level directory support for translation files ( #1718 )
2025-06-30 13:27:12 +02:00
Santos Vilanculos and Markus Podar
7c469e4073
docs(readme): add Laravel 12 support information ( #1717 )
...
* docs(readme): add Laravel 12 support information
* docs(readme): update Laravel support information
Co-authored-by: Markus Podar <[email protected] >
---------
Co-authored-by: Markus Podar <[email protected] >
2025-06-30 13:09:32 +02:00
laravel-ide-helper
ae0a06d406
composer fix-style
2025-05-15 07:57:32 +00:00
erikn69
e0b2f86326
Configurable macro return type defaults ( #1711 )
2025-05-15 09:56:31 +02:00
laravel-ide-helper
cdefaeed42
composer fix-style
2025-05-14 18:21:46 +00:00
erikn69
c775aec1bb
Revert #1629 - _Allow adding custom Macroable classes_ ( #1707 )
...
* Revert #1629 - Allow adding custom Macroable classes
* Add Macros test
2025-05-14 20:21:17 +02:00
Marvin Naumann
0fa96e572d
detect default parameter from type float and adding tests for scopes with typed parameters ( #1697 )
2025-04-22 15:31:43 +02:00
8eec4f1ff5
feat(ModelsCommand): add support for the new Scope attribute ( #1694 )
...
* composer fix-style
* feat(model): add support for new Scope attribute
* composer fix-style
* snapshot
* check if class_exists for psalm
* check if class_exists for psalm
* resolve psalm issue
* remove prefix slash
* revert whitespace changes
* composer fix-style
* Update composer.json
---------
Co-authored-by: laravel-ide-helper <[email protected] >
Co-authored-by: Barry vd. Heuvel <[email protected] >
2025-04-04 16:14:00 +02:00
Pieter Willekens
d567978ebe
chore(meta): ignore abstracts in the autoloader ( Fixes #1671 ) ( #1686 )
2025-02-27 20:19:11 +01:00
KentarouTakeda
09623f216c
Add extends declaration for Macroable classes to fix missing inherited methods ( #1674 )
2025-02-22 16:59:08 +01:00
Tom Westrick
3d4e37798e
Fix AsArrayObject cast to be Laravel's ArrayObject ( #1675 )
2025-02-22 15:16:07 +01:00
barryvdh
713a4758f9
Update CHANGELOG
2025-02-21 15:09:51 +00:00
barryvdh
8d441ec99f
normalize composer.json
v3.5.5
2025-02-11 13:59:46 +00:00
dba153f1e0
Laravel 12 support ( #1672 )
...
* Laravel 12 support
* Update run-integration-tests.yml to include Laravel 12
* Update run-tests.yml to include Laravel 12
* allow testbench ^10
* Update run-integration-tests.yml
* Update run-tests.yml
* Update composer.json
Co-authored-by: KentarouTakeda <[email protected] >
* Update run-integration-tests.yml
* Update run-tests.yml
---------
Co-authored-by: KentarouTakeda <[email protected] >
Co-authored-by: Barry vd. Heuvel <[email protected] >
2025-02-11 14:59:28 +01:00
yparitcher
40485e7350
Fix MorphTo Model Doc Generation ( #1668 )
...
fix:
```php
/**
* @return MorphTo<contravariant ModelA|ModelB, $this>
*/
public function reminderable(): MorphTo {
return $this->morphTo(__FUNCTION__, 'entity', 'entity_id');
}
```
From:
```php
* @property-read contravariant ModelA|ModelB $reminderable
```
To:
```php
* @property-read ModelA|ModelB $reminderable
```
Fixes : #1667
2025-02-04 17:49:42 +01:00
skyler544 and Skyler Mayfield
ead24b10f6
prevent generation of incorrect property annotation ( #1665 )
...
Co-authored-by: Skyler Mayfield <[email protected] >
2025-01-29 22:43:43 +01:00
Kristijan
187ce9beeb
Update configs.php ( #1662 )
...
Fixes config items incorectlly set as `string` due to `'array(...)'` value passed to `gettype` instead of real array
2025-01-23 18:56:10 +01:00