Comments (10)
I haven't dug deep, but would it be possible to wire things up, to make these adapters optional? Requiring only needed adapters would seem to make sense, perhaps listing them in "suggest" block, instead of forcing the kitchen sink.
On PHP8 right now, doctrine-module requires laminas-cache, laminas-cache requires various adapters that do not support PHP8 (in their composer.json).
from laminas-cache.
Requiring only needed adapters would seem to make sense, perhaps listing them in "suggest" block, instead of forcing the kitchen sink.
Please check the documentation on this topic. There will you find a solution for the current version 2.10 and higher, also how it works in version 3:
https://docs.laminas.dev/laminas-cache/installation/
from laminas-cache.
Just a side-note here.
I am pretty sure that there wont be support for PHP 8.0 on:
- laminas-cache-storage-adapter-wincache
- laminas-cache-storage-adapter-xcache
- laminas-cache-storage-adapter-mongodb
- laminas-cache-storage-adapter-apc
I am not that sure about:
- laminas-cache-storage-adapter-zend-server
- laminas-cache-storage-adapter-dba
from laminas-cache.
Thank you. I had tried including 3.0.x-dev, which is what motivated my question above. Under 3.0.x, the issue perdures:
- laminas/laminas-cache 3.0.x-dev requires laminas/laminas-cache-storage-adapter-apc ^1.0 -> satisfiable by laminas/laminas-cache-storage-adapter-apc[1.0.0, 1.0.1, 1.0.x-dev, 1.1.x-dev].
I can appreciate that it could just be, that the work is not complete. I'll say thank you in this case. Will be good to avoid having to add all of these replace directives.
from laminas-cache.
v3.0 is still in development and thus you should not use it.
v2.11.0 was released with support for PHP 8.0 along with plenty of cache adapters which can be seen in the initial post.
from laminas-cache.
Closing this as v2 is mostly PHP 8.0 compatible.
- Those adapters which can support PHP 8.0 do support PHP 8.0.
- Those adapters which have no support for PHP 8.0 and wont ever have support for it, were abandoned
- Only adapter which is still pending is
laminas/laminas-cache-storage-adapter-memcached
which can be tracked here laminas/laminas-cache-storage-adapter-memcached#2
from laminas-cache.
Mostly compatible, but not usable. Installing this library on PHP 8 will not work because of the underlying requirements.
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- laminas/laminas-cache-storage-adapter-apc[1.0.0, ..., 1.0.1] require php ^5.6 || ^7.0 -> your php version (8.0.11) does not satisfy that requirement.
- laminas/laminas-cache 2.13.0 requires laminas/laminas-cache-storage-adapter-apc ^1.0 -> satisfiable by laminas/laminas-cache-storage-adapter-apc[1.0.0, 1.0.1].
- Root composer.json requires laminas/laminas-cache ^2.13.0 -> satisfiable by laminas/laminas-cache[2.13.0].
So should this issue not stay open until these dependencies are supporting PHP 8.0 or the dependencies are no longer required?
from laminas-cache.
Installing this library on PHP 8 will not work because of the underlying requirements.
Everything is correct here. I think you missed the instructions for installation.
from laminas-cache.
The instruction worked for most of our projects.
But there was one project, which depended on multiple projects in which the replacement was done.
Adding replaces in the main project composer will throw the following error:
[root@ffc765ad176a html]# php -d memory_limit=8G composer.phar -W update
Loading composer repositories with package information
In Laminas\DependencyPlugin\DependencyRewriterV2::onPrePoolCreate
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- vendor/main-project is present at version dev-master and cannot be modified by Composer
- Root composer.json requires vendor/sub-project-1 ^1.5 -> satisfiable by vendor/sub-project-1[v1.5.0].
- vendor/sub-project-2[v1.4.0], vendor/sub-project-1[v1.5.0] cannot be installed as that would require removing vendor/main-project[dev-master]. They all replace laminas/laminas-cache-storage-adapter-apc and thus cannot coexist.
- Root composer.json requires vendor/sub-project-2 ^1.4 -> satisfiable by vendor/sub-project-2[v1.4.0].
Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.
Without the replaces in the main project the following errors are thrown:
[root@ffc765ad176a html]# php -d memory_limit=8G composer.phar -W update
Loading composer repositories with package information
In Laminas\DependencyPlugin\DependencyRewriterV2::onPrePoolCreate
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Root composer.json requires vendor/sub-project-1 ^1.5 -> satisfiable by vendor/sub-project-1[v1.5.0].
- Only one of these can be installed: laminas/laminas-cache-storage-adapter-zend-server[1.0.0, 1.0.1], vendor/sub-project-2[v1.4.0], vendor/sub-project-1[v1.5.0]. [vendor/sub-project-2, vendor/sub-project-1] replace laminas/laminas-cache-storage-adapter-zend-server and thus cannot coexist with it.
- Root composer.json requires vendor/sub-project-2 ^1.4 -> satisfiable by vendor/sub-project-2[v1.4.0].
Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.
Do you have any hints/ideas how we could circumnavigate this issue?
Would an "archived-projects" composer package which replaces all archived repos and require this in all the subprojects do the trick?
Are there any easier methods?
from laminas-cache.
@plorenz-etes I've created a dedicated "issue" for your question. Lets continue there.
from laminas-cache.
Related Issues (20)
- [RFC]: PSR compatibility via dedicated satellites HOT 1
- [RFC]: remove conflict with symfony/console HOT 5
- Cannot add laminas cache to my project. HOT 3
- PHP 8.1.1 support HOT 6
- A cache storage implementation is required, while the CaptureCache pattern does not require one HOT 2
- CacheItemPoolDecorator does not properly handle multiple unsaved deferred items HOT 3
- RFC: Configure AdapterPluginManager from the config HOT 9
- Use `Clock`-Interface (PSR-20) in `PSR-6` `CacheItem`
- Dependency Dashboard
- psr/cache V3 and psr/simple-cache V3 compatibilities HOT 1
- laminas-cache is still using Laminas\Cache\StorageFactory::factory() which no longer exists HOT 6
- Provide native support for PSR-20 HOT 1
- [RFC]: Detach serializer plugin from `laminas-serializer` HOT 4
- Add `cache` configuration key documentation HOT 3
- Update `vimeo/psalm` to v5.16 once available HOT 1
- Remove virtual package requirement `laminas/laminas-cache-storage-implementation` HOT 1
- laminas-feed still relevant for this component? HOT 4
- ServiceManager::get results in endless loop since 3.11.0 HOT 10
- Standalone example in `README.md` does not work HOT 1
- Incompatibility of laminas-cache and newer psr/cache versions HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from laminas-cache.