Skip to content

Commit 7d51b57

Browse files
minor symfony#28526 [Contracts] fine tune composer.json declarations for suggest/provide (nicolas-grekas)
This PR was merged into the 4.2-dev branch. Discussion ---------- [Contracts] fine tune composer.json declarations for suggest/provide | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | - | License | MIT | Doc PR | - Commits ------- 8a11e76 [Contracts] fine tune composer.json declarations for suggest/provide
2 parents bf4d011 + 8a11e76 commit 7d51b57

File tree

6 files changed

+10
-6
lines changed

6 files changed

+10
-6
lines changed

src/Symfony/Component/Cache/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"provide": {
1919
"psr/cache-implementation": "1.0",
2020
"psr/simple-cache-implementation": "1.0",
21-
"symfony/cache-contracts": "1.0"
21+
"symfony/cache-contracts-implementation": "1.0"
2222
},
2323
"require": {
2424
"php": "^7.1.3",

src/Symfony/Component/DependencyInjection/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
},
4141
"provide": {
4242
"psr/container-implementation": "1.0",
43-
"symfony/service-contracts": "1.0"
43+
"symfony/service-contracts-implementation": "1.0"
4444
},
4545
"autoload": {
4646
"psr-4": { "Symfony\\Component\\DependencyInjection\\": "" },

src/Symfony/Component/Translation/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"symfony/yaml": "<3.4"
3636
},
3737
"provide": {
38-
"symfony/translation-contracts": "1.0"
38+
"symfony/translation-contracts-implementation": "1.0"
3939
},
4040
"suggest": {
4141
"symfony/config": "",

src/Symfony/Contracts/Cache/CacheInterface.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
interface CacheInterface
2626
{
2727
/**
28+
* @param string $key The key of the item to retrieve from the cache
2829
* @param callable(ItemInterface):mixed $callback Should return the computed value for the given key/item
2930
* @param float|null $beta A float that, as it grows, controls the likeliness of triggering
3031
* early expiration. 0 disables it, INF forces immediate expiration.

src/Symfony/Contracts/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ Design Principles
1616
* they must be backward compatible with existing Symfony components.
1717

1818
Packages that implement specific contracts should list them in the "provide"
19-
section of their "composer.json" file, using the `symfony/*-contracts`
20-
convention (e.g. `"provide": { "symfony/cache-contracts": "1.0" }`).
19+
section of their "composer.json" file, using the `symfony/*-contracts-implementation`
20+
convention (e.g. `"provide": { "symfony/cache-contracts-implementation": "1.0" }`).
2121

2222
FAQ
2323
---

src/Symfony/Contracts/composer.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,10 @@
2424
},
2525
"suggest": {
2626
"psr/cache": "When using the Cache contracts",
27-
"psr/container": "When using the Service contracts"
27+
"psr/container": "When using the Service contracts",
28+
"symfony/cache-contracts-implementation": "",
29+
"symfony/service-contracts-implementation": "",
30+
"symfony/translation-contracts-implementation": ""
2831
},
2932
"autoload": {
3033
"psr-4": { "Symfony\\Contracts\\": "" },

0 commit comments

Comments
 (0)