Open psampaz opened 8 years ago
You are using symfony 3?
I think atm this bundle is far from compatible with sf3, I fixed these form errors but there are more things incompatible.
Yes I use Symfony 3 with FOSOAuthServerBundle 1.5.0
The Form factory doesn't support nasty type argument anymore, to fix your error, you can define a parameter to override the authorize form type:
# dirty fixes:
parameters:
fos_oauth_server.authorize.form.type: YourBundle\Form\Type\AuthorizeFormType
Copy the AuthorizeFormType.php from fos oauth server bundle to your bundle and change all the
'hidden' in builder to "HiddenType::class" (don't forget add use
statement)
But then you will find you can't get client_id from request because this:
And they are still use it here
is removed from sf3.
I'll create a fork to fix..... but hmmm home time.
Or you can try to implement your own controller.
Thanks for the fast reply.
Do you suggest not to use this bundle with sf3 on production?
If you can wait i'll fix them next week but I'm not near a computer for now...
Hi @Ener-Getick ,
Take a look at the LegacyFormHelper on FosUserBundle. I fixed this problem on my projects using the same helper. Really smart.
Yeah @Spomky I already used it too, that's a really smart fix :-) I just won't be near a computer this week so I can merge a PR but I can't create it myself.
I have tried a fix for this issue in my pull request. https://github.com/FriendsOfSymfony/FOSOAuthServerBundle/pull/383
While trying to access fos_oauth_server_authorize (oauth/v2/auth) route
I get the following error:
Could not load type "fos_oauth_server_authorize"
This is my config
This is the output from "php bin/console debug:config fos_oauth_server"
Any ideas what could go wrong?