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

Restore job with --prefer-lowest #10971

Merged
merged 1 commit into from
Oct 8, 2023

Conversation

greg0ire
Copy link
Member

@greg0ire greg0ire commented Oct 7, 2023

It is useful to catch misconfigured dependency constraints. It was removed in #9069.

@greg0ire greg0ire force-pushed the restore-prefer-lowest branch 5 times, most recently from 4743f53 to 0e34fcf Compare October 7, 2023 20:18
composer.json Outdated
@@ -32,18 +32,18 @@
"doctrine/instantiator": "^1.3 || ^2",
"doctrine/lexer": "^2.1 || ^3",
"doctrine/persistence": "^3.1.1",
"psr/cache": "^1 || ^2 || ^3",
"psr/cache": "^3",
Copy link
Member Author

@greg0ire greg0ire Oct 7, 2023

Choose a reason for hiding this comment

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

We require the fluent interface provided by 3.0.0:

$queryCache->save($cacheItem->set($this->parserResult)->expiresAfter($this->queryCacheTTL));

Copy link
Member

Choose a reason for hiding this comment

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

The fluent interface is part of the standard since v1.

Copy link
Member Author

Choose a reason for hiding this comment

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

🤔 I guess the issue must be with a wrong implementation then.

Copy link
Member Author

@greg0ire greg0ire Oct 8, 2023

Choose a reason for hiding this comment

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

MockObject_CacheItemInterface_9583ebe3

Ah yes, that makes sense. The mocking framework won't enforce a phpdoc-provided return type.

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed properly.

@greg0ire greg0ire marked this pull request as ready for review October 7, 2023 20:22
@greg0ire greg0ire force-pushed the restore-prefer-lowest branch from 0e34fcf to b43759f Compare October 7, 2023 20:39
@derrabus derrabus added this to the 3.0.0 milestone Oct 8, 2023
@derrabus derrabus added the CI label Oct 8, 2023
@greg0ire greg0ire force-pushed the restore-prefer-lowest branch 6 times, most recently from aca515e to eae50e6 Compare October 8, 2023 11:06
It is useful to catch misconfigured dependency constraints. It was
removed in 413c332.
This implies configuring mocks so as to support psr/cache 1
psr/cache 1 does not use native return types, and phpdoc is not enough
to obtain a mock that has typed methods.
@greg0ire greg0ire force-pushed the restore-prefer-lowest branch from eae50e6 to 2700998 Compare October 8, 2023 11:08
@greg0ire greg0ire merged commit 343afda into doctrine:3.0.x Oct 8, 2023
38 checks passed
@greg0ire greg0ire deleted the restore-prefer-lowest branch October 8, 2023 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants