Nicorr
Nicorr

Reputation: 734

FOSrestBundle : Invalid configuration for path "fos_rest.param_fetcher_listener"

My previous configuration of FOSrestBundle was working properly. I added HWIOAuthBundle, and now FOSrestBundle is throwing an error, even though I didn't modify its configuration.

This is the error I get:

Invalid configuration for path "fos_rest.param_fetcher_listener": The param_fetcher_listener option does not support {"enabled":true,"service":null}. Please choose one of [false,true,"force"]

This is part of my config.yml:

fos_rest:
routing_loader:
    default_format: json
param_fetcher_listener: true
body_listener: true
body_converter:
    enabled: true
format_listener:
    rules:
        - { priorities: ['json'], fallback_format: json, prefer_extension: false }
view:
    view_response_listener: force

Could composer update be source of the problem?

Upvotes: 0

Views: 1128

Answers (1)

Evgeniy Kuzmin
Evgeniy Kuzmin

Reputation: 2462

Yes, FosRestBundle was recently updated (6 days ago), so if you have "dev-master" at your composer.json, then you got this commit that changed configuration of

https://github.com/FriendsOfSymfony/FOSRestBundle/commit/a3ee6d7c4427d569d577e717ab8dccc1a857abbd#diff-850942b3ba24ab03a40aaa81b6152852R66

So you can see that new parameters was added "service"

If you have not any points to use "1.6.0-RC1" version (dev-master), that actually is "release candidate" yet, I will advice you to switch to stable "1.5.3" version

"friendsofsymfony/rest-bundle": "1.5.3"

or at least to @dev

"friendsofsymfony/rest-bundle": "1.5.*@dev"

Upvotes: 1

Related Questions