Sonata User Bundle + Symfony 3.x - sonata-admin

I use Symfony 3.0.6, Sontata Admin Bundle 3.0.0 and the Doctrine ORM Admin Bundle on dev-master. The user bundle doesnt work even with dev-master. Is there a solution for Symfony 3.x yet?
Your requirements could not be resolved to an installable set of
packages.
Problem 1
- Conclusion: remove symfony/symfony v3.0.6
- Conclusion: don't install symfony/symfony v3.0.6
- Conclusion: don't install symfony/symfony v3.0.5
- Conclusion: don't install symfony/symfony v3.0.4
- Conclusion: don't install symfony/symfony v3.0.3
- Installation request for sonata-project/user-bundle dev-master ->
satisfiable by sonata-project/user-bundle[dev-master].
- Conclusion: don't install symfony/symfony v3.0.2
- Conclusion: don't install symfony/symfony v3.0.1
- sonata-project/user-bundle dev-master requires symfony/form ^2.3 ->
satisfiable by symfony/form[.....

The SonataUserBundle just released a 3.0.0 version 3 days ago, but does not seem to be compatible with SF3 yet, given the composer.json file:
{
"name": "sonata-project/user-bundle",
"require": {
"php": "^5.3 || ^7.0",
"symfony/http-foundation": "^2.3",
"symfony/form": "^2.3",
"symfony/security": "^2.3",
"symfony/console": "^2.3",
},
[...]
}
I am afraid we will have to wait a little bit longer.
Some issues were posted about it on the official repository:
https://github.com/sonata-project/SonataUserBundle/issues/724
The author's answer:
SF 3.0 is not supported because FOSUser 1.x does not support it.
FOSUser 2.x is not stable and is not supported by our bundle right now.
For the complete story, there were plans to release a SF3 compatible version of the FOSUserBundle on december 2015, but no news about that one has came since...
https://github.com/FriendsOfSymfony/FOSUserBundle/pull/1990
Let's wait & see!

Related

i try to upgrade my project in cakephp 3.8 to 4.0 but i stuck in this line "composer require --update-with-dependencies "cakephp/cakephp:4.0.*"

when i run "composer require --update-with-dependencies "cakephp/cakephp:4.0.*"
it responds :
./composer.json has been updated
Running composer update cakephp/cakephp --with-dependencies
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Root composer.json requires cakephp/cakephp 4.0., found cakephp/cakephp[4.0.0-alpha1, ..., 4.0.10] but these were not loaded, likely because it conflicts with another require.
Problem 2
- cakephp/migrations is locked to version 1.5.7 and an update of this package was not requested.
- cakephp/migrations 1.5.7 requires cakephp/cakephp ~3.1 -> found cakephp/cakephp[3.1.0-beta, ..., 3.x-dev] but it conflicts with your root composer.json require (4.0.).
Problem 3
- cakephp/debug_kit is locked to version 3.2.7 and an update of this package was not requested.
- cakephp/debug_kit 3.2.7 requires cakephp/cakephp >=3.1.0 <4.0 -> found cakephp/cakephp[3.1.0-beta, ..., 3.x-dev] but it conflicts with your root composer.json require (4.0.*).
Problem 4
- cakephp/bake is locked to version 1.2.3 and an update of this package was not requested.
- cakephp/bake 1.2.3 requires cakephp/cakephp >=3.2.0 -> found cakephp/cakephp[3.2.0-RC1, ..., 3.x-dev, 4.0.0-alpha1, ..., 4.x-dev, 5.x-dev] but these were not loaded, likely because it conflicts with another require.
Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.
Installation failed, reverting ./composer.json and ./composer.lock to their original content.

CakePHP 3.x - Installing Phinx Error

I am currently studying cakePHP 3.x and I ran into some trouble installing phinx.
composer require robmorgan/phinx
I keep getting the ff error:
Problem 1
- cakephp/migrations 1.8.1 requires robmorgan/phinx 0.8.1 -> satisfiable by robmorgan/phinx[v0.8.1] but these conflict with your requirements or minimum-stability.
- cakephp/migrations 1.8.1 requires robmorgan/phinx 0.8.1 -> satisfiable by robmorgan/phinx[v0.8.1] but these conflict with your requirements or minimum-stability.
- cakephp/migrations 1.8.1 requires robmorgan/phinx 0.8.1 -> satisfiable by robmorgan/phinx[v0.8.1] but these conflict with your requirements or minimum-stability.
- Installation request for cakephp/migrations (locked at 1.8.1, required as ^1.8.0) -> satisfiable by cakephp/migrations[1.8.1].
I checked my composer.json file, and changed my cakephp/cakephp require from "3.6.*" to "^3.6" just incase, but I'm still getting this error. I'm trying to install phinx because I'm currently studying cakePHP seeds. Any advice is greatly appreciated. Thank you in advance :)
It is related with cakephp/migrations version, try to update it in composer.json.
In my case, I changed it to "cakephp/migrations": "^2.0.0", and it worked fine for me.

Installing CakePHP gives an error about intl missing, but it's installed

When I try to install CakePHP, I get an error that intl is missing:
$ composer self-update && composer create-project --prefer-dist cakephp/app blog
You are already using composer version 1.5.2 (stable channel).
Installing cakephp/app (3.5.0)
- Installing cakephp/app (3.5.0): Loading from cache
Created project in blog
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- cakephp/cakephp 3.5.5 requires ext-intl * -> the requested PHP extension intl is missing from your system.
- cakephp/cakephp 3.5.4 requires ext-intl * -> the requested PHP extension intl is missing from your system.
- cakephp/cakephp 3.5.3 requires ext-intl * -> the requested PHP extension intl is missing from your system.
- cakephp/cakephp 3.5.2 requires ext-intl * -> the requested PHP extension intl is missing from your system.
- cakephp/cakephp 3.5.1 requires ext-intl * -> the requested PHP extension intl is missing from your system.
- cakephp/cakephp 3.5.0 requires ext-intl * -> the requested PHP extension intl is missing from your system.
- Installation request for cakephp/cakephp 3.5.* -> satisfiable by cakephp/cakephp[3.5.0, 3.5.1, 3.5.2, 3.5.3, 3.5.4, 3.5.5].
When I try to install php56-intl, I get a message that it's already installed:
$ brew install php56-intl
Updating Homebrew...
==> Auto-updated Homebrew!
Updated 2 taps (homebrew/core, homebrew/php).
==> New Formulae
bchunk dps8m e2tools heartbeat kaitai-struct-compiler simg2img
==> Updated Formulae
abcmidi debianutils getdns homebrew/php/php55-molten inspircd mdds ompl scalaenv terragrunt
asciidoc dssim geth homebrew/php/php56-molten itstool mikutter ortp scalastyle tintin
bazel erlang gofabric8 homebrew/php/php70-molten kerl mupdf pandoc scm-manager vapoursynth
bit exploitdb grafana homebrew/php/php71-molten libgsf mupdf-tools poco sjk wireguard-tools
cmake faas-cli grakn i2p libmaxminddb mypy poppler sourcekitten yara
convox firebase-cli gsmartcontrol imagemagick libpqxx nativefier prometheus swiftformat
cppad gegl homebrew/php/php54-molten imagemagick#6 libuv node-build resty swiftlint
==> Renamed Formulae
newsbeuter -> newsboat
Warning: homebrew/php/php56-intl 5.6.32_10 is already installed
Why is this happening? What can I do to fix it?
Edit: I'm on Mac OS X. Running which php returns PHP 5.6.28 ...

Upgrading Sonata from 2.3 to 3.0

I have an existing Symfony + SonataAdmin project which we've been running for a few years. I'd like to upgrade it to SonataAdmin 3.x. 3.0 would be a good start, then moving up to 3.x afterwards once we check it's all working.
However, I can't seem to get a viable set of composer dependencies to upgrade. The current settings include:
"sonata-project/admin-bundle": "~2.3",
"sonata-project/core-bundle": "~2.3",
"sonata-project/doctrine-orm-admin-bundle": "~2.3",
"sonata-project/user-bundle": "~2.3#dev",
"sonata-project/datagrid-bundle": "~2.2#dev",
"friendsofsymfony/user-bundle": "~1.3",
I've tried changing the first three to 3.0.* but I get the following error:
$ composer update --dry-run
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- sonata-project/user-bundle 2.x-dev requires sonata-project/core-bundle ~2.2 -> satisfiable by sonata-project/core-bundle[2.2.0-2.2.7, 2.3.0-2.3.11, 2.x-dev] but these conflict with your requirements or minimum-stability.
- sonata-project/user-bundle 2.3.x-dev requires sonata-project/admin-bundle ~2.3|~2.4#dev -> satisfiable by sonata-project/admin-bundle[2.3.0-2.3.10, 2.x-dev] but these conflict with your requirements or minimum-stability.
- Installation request for sonata-project/user-bundle ~2.3#dev -> satisfiable by sonata-project/user-bundle[2.x-dev, 2.3.x-dev].
Chaging the dependency for user-bundle to:
"sonata-project/user-bundle": "3.0.*#dev",
or 3.0.*#dev, or 3.0.0 or 3.0.0#dev:
Just gives a different error:
$ composer update --dry-run
Loading composer repositories with package information
Updating dependencies (including require-dev)
[Composer\DependencyResolver\SolverProblemsException]
Problem 1
- The requested package sonata-project/user-bundle 3.0.* exists as sonata-project/user-bundle[2.3.x-dev, dev-master] but these are rejected by your constraint.
And, finally, trying "sonata-project/user-bundle": "dev-master", gives this error:
$ composer update --dry-run
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- sonata-project/user-bundle dev-master requires sonata-project/admin-bundle ^3.1 -> satisfiable by sonata-project/admin-bundle[3.1.0, 3.2.0, 3.3.0, 3.3.1, 3.3.2, 3.4.0, 3.x-dev] but these conflict with your requirements or minimum-stability.
- sonata-project/user-bundle dev-master requires sonata-project/admin-bundle ^3.1 -> satisfiable by sonata-project/admin-bundle[3.1.0, 3.2.0, 3.3.0, 3.3.1, 3.3.2, 3.4.0, 3.x-dev] but these conflict with your requirements or minimum-stability.
- Installation request for sonata-project/user-bundle dev-master -> satisfiable by sonata-project/user-bundle[dev-master].
So... is there any version of sonata-project/user-bundle which is compatible with the 3.0.* versions of the other Sonata packages? Packagist seems to suggest that there's a 3.0.0 version of sonata-project/user-bundle, but haveI done something wrong in my composer syntax when trying to reference it?
Rules to achieve your goal with ease :
use stable versions and only that
don't constraint yourself too much, you can do it later.
Here is an excerpt of a composer.json of mine :
"sonata-project/admin-bundle": "^3.0",
"sonata-project/core-bundle": "^3.0",
"sonata-project/doctrine-orm-admin-bundle": "^3.0",
"sonata-project/notification-bundle": "^3.0",
"sonata-project/user-bundle": "^3.0",
Simple and beautiful.

Installing cakedc/users on CakePHP 3.1 version conflict

I'm trying to install Cake dc users on a Cakephp 3.1
That's a part of my composer.json that I'm almost sure that is properly setup mantain the cake version to 3.1:
"require": {
"php": ">=5.4.16",
"cakephp/cakephp": "~3.1",
I used the following command to setup cake:
composer create-project cakephp/app ar2016-2 3.1.*
and that's the result I get when I try to install DCUsers with the composer:
composer require cakedc/users:~3.1.0
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Conclusion: remove cakephp/cakephp 3.2.1
- Conclusion: don't install cakephp/cakephp 3.2.1
- cakedc/users 3.1.0 requires cakephp/cakephp ~3.1.0 -> satisfiable by cakephp/cakephp[3.1.0, 3.1.0-RC1, 3.1.0-beta, 3.1.0-beta2, 3.1.1, 3.1.10, 3.1.2, 3.1.3, 3.1.4, 3.1.5, 3.1.6, 3.1.7, 3.1.8, 3.1.9].
...
It looks that it detects CakePHP 3.2.1 but everywhere I check show me that I'm using the proper 3.1. version. Any Idea?
Thanks in advance,
David
I'd doubt that it shows that you've installed 3.1 anywhere at all, because the latest release is 3.2.1 and, ~3.1 means >= 3.1 and < 4.0.0, and therefore I'm pretty sure that you have the latest version installed, ie 3.2.1, a quick bin/cake will probably confirm that.
https://getcomposer.org/doc/articles/versions.md#tilde
The cakedc/users version that you have requested, requires cakephp/cakephp:3.1.*, which means >= 3.1 and < 3.2, hence the error.
https://getcomposer.org/doc/articles/versions.md#wildcard
So either use the master branch of the plugin (it requires cakephp/cakephp:~3.1) until a proper release is issued, or use a more specific version constraint for the CakePHP framework, like 3.1.*
Thanks for the answer but it's just fixed, it was a problem of the plugin itself and cakedc fixed.

Resources