Suggest some dependencies in Zend\Mvc #4474

wants to merge 4 commits into


None yet

3 participants


Ping @weierophinney

  • Any other component should be moved to suggest?
  • You can help me with better descriptions for suggestions? I'm not sure what are the use cases for these components, only the cases explained in #4461 (comment)
  • This components should also be suggested in Zend\ModuleManager?

@Danizord Config, Console, Di, Http, ModuleManager, Uri, Text, and View are all technically optional as well. Really, the only required dependencies are EventManager, ServiceManager, and Stdlib.

@weierophinney weierophinney added a commit that referenced this pull request May 23, 2013
@weierophinney weierophinney Merge branch 'hotfix/4474' into develop
Forward port #4474
@weierophinney weierophinney added a commit that closed this pull request May 23, 2013
@weierophinney weierophinney Merge branch 'hotfix/4474'
Close #4474

With this change, out of the box:
a composer request with: require: zendframework/zend-mvc: 2.* solo will throw a fatal exception: "Fatal error: Class 'Zend\Serializer\AdapterPluginManager' not found in /var/www/ on line 33"
Due to Serializer never being ultimated required.
Definitely a poor initial experience, requiring a user to manually add zend-serializer even if their project never explicitly uses it, due to MVC internals using it.


@icywolfy The fact, though, is that the MVC does not actually require them. You can seed the service manager manually and use it with Zend\Mvc\Application, and not need them. This is why they are suggested (i.e., optional) dependencies. It makes sense to only require what absolutely must be present in order for it to work.

When building a full-stack application, you'll likely use the zendframework/zendframework package, which includes all of them; otherwise, you install what you need. For the default implementation, you'll likely want to install all the suggested dependencies.


@icywolfy And this "problem" you reported was already present before this commit, as you can see in #4460


@weierophinney Thanks for the clarification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment