【问题标题】:Is it normal that zendframework/zend-http package requires 49 components?zendframework/zend-http 包需要49个组件正常吗?
【发布时间】:2013-03-11 22:31:19
【问题描述】:

这是composer.json

{
    "repositories": [
        {
            "type": "composer",
            "url": "https://packages.zendframework.com/"
        }
    ],
    "require": {
        "zendframework/zend-http": "2.*"
    }
}

...以及详尽的清单:

Authentication  Code     Db     Escaper       Filter  InputFilter  Log     Mime           Paginator    Server          Stdlib  Uri        XmlRpc
Barcode         Config   Debug  EventManager  Form    Json         Mail    ModuleManager  Permissions  ServiceManager  Tag     Validator
Cache           Console  Di     Feed          Http    Ldap         Math    Mvc            ProgressBar  Session         Test    Version
Captcha         Crypt    Dom    File          I18n    Loader       Memory  Navigation     Serializer   Soap            Text    View

其中一些实际上是有道理的。但是例如Barcode,Captcha,Navigation 甚至Db呢?

编辑

$ rm -rf vendor
$ rm -rf ~/.composer/
$ rm composer.lock 
$ more composer.json 
{
    "require": {
        "zendframework/zend-http": "2.*"
    }
}
$ composer self-update
You are using the latest composer version.
$ composer install
Loading composer repositories with package information
Installing dependencies
  - Installing zendframework/zendframework (2.1.3)
    Downloading: 100%

zendframework/zendframework suggests installing doctrine/common (Doctrine\Common >=2.1 for annotation features)
zendframework/zendframework suggests installing ext-intl (ext/intl for i18n features)
zendframework/zendframework suggests installing pecl-weakref (Implementation of weak references for Zend\Stdlib\CallbackHandler)
zendframework/zendframework suggests installing zendframework/zendpdf (ZendPdf for creating PDF representations of barcodes)
zendframework/zendframework suggests installing zendframework/zendservice-recaptcha (ZendService\ReCaptcha for rendering ReCaptchas in Zend\Captcha and/or Zend\Form)
Writing lock file
Generating autoload files

PS:很高兴有些人认为我的问题很容易结束......我真的很感谢其他人试图回答。

【问题讨论】:

  • 这不正常,但在我的系统作曲家还安装了整个 zendframework/zendframework 包。这似乎是一些人正在经历的问题。请参阅 hereherehere。我还通过搜索找到了更多有此问题的人,但还没有找到解决方案。有人说安装国际扩展修复了它,但我没有尝试

标签: package zend-framework2 composer-php


【解决方案1】:

没有。

使用 composer.json 文件,我得到了这个:

$ composer.phar install
Loading composer repositories with package information
Installing dependencies
  - Installing zendframework/zend-stdlib (2.1.3)
    Downloading: 100%         

  - Installing zendframework/zend-servicemanager (2.1.3)
    Downloading: 100%         

  - Installing zendframework/zend-filter (2.1.3)
    Downloading: 100%         

  - Installing zendframework/zend-i18n (2.1.3)
    Downloading: 100%         

  - Installing zendframework/zend-validator (2.1.3)
    Downloading: 100%         

  - Installing zendframework/zend-escaper (2.1.3)
    Downloading: 100%         

  - Installing zendframework/zend-uri (2.1.3)
    Downloading: 100%         

  - Installing zendframework/zend-loader (2.1.3)
    Downloading: 100%         

  - Installing zendframework/zend-http (2.1.3)
    Downloading: 100%         

zendframework/zend-stdlib suggests installing pecl-weakref (Implementation of weak references for Stdlib\CallbackHandler)
zendframework/zend-servicemanager suggests installing zendframework/zend-di (Zend\Di component)
zendframework/zend-filter suggests installing zendframework/zend-crypt (Zend\Crypt component)
zendframework/zend-validator suggests installing zendframework/zend-db (Zend\Db component)
zendframework/zend-validator suggests installing zendframework/zend-math (Zend\Math component)
Writing lock file
Generating autoload files

zend-http 拥有的依赖项的完整列表是:

  • 逃脱者
  • 过滤器
  • i18n
  • 加载器
  • 服务管理器
  • 标准库
  • 乌里
  • 验证器

【讨论】:

  • @davidloubere 还需要注意的是,您不需要将 packages.zendframework.com 添加到存储库:)
  • @Ocramius 我知道,但阅读packages.zendframework.com 上的说明,我认为最好遵循它们,即添加 ZF 作曲家存储库。顺便提一下,如果我从 composer.json 中删除对它的引用(我在 Ubuntu 11.04 上),仍然会出现同样的问题。
  • @davidloubere 你在使用最新的作曲家版本吗?
猜你喜欢
  • 2021-07-08
  • 2014-07-18
  • 2019-08-14
  • 1970-01-01
  • 2021-11-18
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多