Skip to content
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

Bump vimeo/psalm from 4.8.1 to 4.9.2 #28338

Closed
wants to merge 1 commit into from

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Aug 7, 2021

Bumps vimeo/psalm from 4.8.1 to 4.9.2.

Release notes

Sourced from vimeo/psalm's releases.

Improve preloading and fix template bounds checks

Fixes an issue introduced in 4.9.0: #6212

Also improves Psalm's knowledge when some stub files are loaded (#5126, #5626)

Fixed TIntRange bounds types

TIntRange changes

The types for int range bounds were sub-optimal. This release fixes this. Formally this is a BC break, for plugins. However, given the short time that passed since TIntRange introduction we believe it should be OK to release it as a patch release.

Fixes

First community release

Features

  • (#5974, #5980) Ability to turn off inferPropertyTypesFromConstructor (thanks @​weirdan)
  • (#6008, #6010) LSP server now runs analysis on open and save (thanks @​tm1000)
  • (#6013, #6014, #6055) LSP server now understands didChangeWatchedFiles notification (thanks @​tm1000)
  • (#6058, #6059) Support for xml:base attribute (useful for modular configs) (thanks @​turnabout)
  • (#6060) FunctionReturnTypeProviderEvent and MethodReturnTypeProviderEvent now provide access to the statement via getStmt() method (thanks @​VincentLanglet)
  • (#6106) Added support for interface-string<FooInterface> (currently as an alias to class-string<FooInterface>) (thanks @​muglug)
  • (#5512) Added option to enable Shepherd reporting with environment variables (PSALM_SHEPHERD and PSALM_SHEPHERD_HOST) (thanks @​ngmy)
  • (#6117, #6130) Psalm now flags static access to non-static property (and vice versa) (thanks @​weirdan)
  • (#6155) Added support for PHP 8.1 native readonly flag on properties (thanks @​muglug)
  • (#6110, #6142) Now you may configure trigger_error() behavior (thanks @​orklah)
  • (#6152, #6181) Psalm now understands that the only descendants of DateTimeInterface are DateTime and DateTimeImmutable (thanks @​Jack97)
  • (#6207) Preliminary support for int ranges (e.g. int<min, 25>, int<2, 8> etc) (thanks @​orklah)

Fixes

... (truncated)

Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Copy link
Contributor

@nextcloud-command nextcloud-command left a comment

Choose a reason for hiding this comment

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

@dependabot merge

@MichaIng MichaIng added this to the Nextcloud 23 milestone Aug 7, 2021
Bumps [vimeo/psalm](https://github.com/vimeo/psalm) from 4.8.1 to 4.9.2.
- [Release notes](https://github.com/vimeo/psalm/releases)
- [Commits](vimeo/psalm@4.8.1...4.9.2)

---
updated-dependencies:
- dependency-name: vimeo/psalm
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
@MichaIng MichaIng force-pushed the dependabot/composer/vimeo/psalm-4.9.2 branch from 39ba876 to a4f3371 Compare August 15, 2021 23:03
@MichaIng MichaIng added 2. developing Work in progress and removed 3. to review Waiting for reviews labels Aug 15, 2021
@ChristophWurst
Copy link
Member

InvalidArgument: Incompatible types found for T

for the event listener registration. This smells like a bug but I can't reproduce this in the Psalm repl: https://psalm.dev/r/e64f3a9d3d

@juliusknorr
Copy link
Member

I think the issue is that the template is not taken into account on the implementing class.

Non-working example: https://psalm.dev/r/ecd0c19708

Working example with additional annotation: https://psalm.dev/r/ddcc007769

Not sure if there may be a different way to annotate this without hinting every event listener properly.

@ChristophWurst
Copy link
Member

Working example with additional annotation: https://psalm.dev/r/ddcc007769

Wait … so Psalm actually got more clever. It now finally verifies that the listener you register is one for the specified type. This was a limitation in the past: vimeo/psalm#4339

@ChristophWurst
Copy link
Member

Wait … so Psalm actually got more clever. It now finally verifies that the listener you register is one for the specified type. This was a limitation in the past: vimeo/psalm#4339

Maybe what we need is a typehint for the listener to say it's either a listener for T or one without a type at all. let me try that

@ChristophWurst
Copy link
Member

I'm getting closer yet it doesn't work https://psalm.dev/r/511e39f9b2

@juliusknorr
Copy link
Member

juliusknorr commented Aug 17, 2021

I think that the naming for T might conflict there, using a different identifier seems to work: https://psalm.dev/r/39bacb4d3b

Edit: Ah it seems the @template annotation only applies to the class that has the docblock.

@ChristophWurst
Copy link
Member

Then we still can't use a typed event for an untyped listener: https://psalm.dev/r/065f604762 :/

@juliusknorr
Copy link
Member

juliusknorr commented Aug 19, 2021

Another try with @template-covariant, seems to work https://psalm.dev/r/39ca294a6d

Never mind that basically allows any event to be passed to the typed listener then

@ChristophWurst
Copy link
Member

If we can't figure it out I would suggest to drop the generics from the listener registration. I've found listeners in Mail where we listen to more than one specialized event and there seems no way to express this with generics.

@szaimen

This comment has been minimized.

@ChristophWurst
Copy link
Member

This PR is obsolete with #28507. I'll try to submit a clear fix. Right now I'm running into Uncaught Exception: Interface "Psr\EventDispatcher\StoppableEventInterface" not found as had previously until #28700

@skjnldsv skjnldsv mentioned this pull request Oct 13, 2021
@MichaIng MichaIng removed this from the Nextcloud 23 milestone Oct 17, 2021
@MichaIng MichaIng removed the 2. developing Work in progress label Oct 17, 2021
@MichaIng
Copy link
Member

@dependabot recreate

@MichaIng
Copy link
Member

I'll close this, as it is completely obsolete and also dependabot does not react on it anymore.

@MichaIng MichaIng closed this Oct 19, 2021
@MichaIng MichaIng deleted the dependabot/composer/vimeo/psalm-4.9.2 branch October 19, 2021 13:38
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.

5 participants