composer更新yii报错 yiisoft/yii2 2.0.29 requires bower-asset/inputmask ~3.2.2 | ~3.3.5 -

在尝试使用composer升级yii2到最新版本时遇到错误。报错信息涉及到yiisoft/yii2 2.0.29对bower-asset/inputmask版本的要求。解决办法包括尝试使用国内镜像和查看新版更新说明。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

报错信息

composer 升级yii2到最新版本,报错信息

yiisoft/yii2 2.0.29 requires bower-asset/inputmask ~3.2.2 | ~3.3.5 -> no matching package found.

解决办法

"repositories": {
   
    "bower-asset/jquery.inputmask": {
   
        "type": "bower-github",
        "url": "https://github.com/petrabarus/jquery.inputmask"
    }
}
composer self-update 1.9.0
composer global require "fxp/composer-asset-plugin:1.4.3"
composer clear-cache
composer update -vvv

国内镜像

# 全局阿里云镜像
composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/

# 取消全局配置
composer config -g --unset repos.packagist

新版更新

Reading /htdocs/website/basic/vendor/composer/installed.json
Writing lock file
Generating autoload files

  Seems you have upgraded Yii Framework from version 2.0.29 to 2.0.42.1.

  Please check the upgrade notes for possible incompatible changes
  and adjust your application code accordingly.

  Upgrade from Yii 2.0.41
  -----------------------
  
  * `NumberValidator` (`number`, `double`, `integer`) does not allow values with leading or terminating (non-trimmed) 
    white spaces anymore. If your application expects non-trimmed values provided to this validator make sure to trim 
    them first (i.e. by using `trim` / `filter` "validators").
  
  Upgrade from Yii 2.0.40
  -----------------------
  
  * The methods `getAuthKey()` and `validateAuthKey()` of `yii\web\IdentityInterface` are now also used to validate active
    sessions (previously these methods were only used for cookie-based login). If your identity class does not properly
    implement these methods yet, you should update it accordingly (an example can be found in the guide under
    `Security` -> `Authentication`). Alternatively, you can simply return `null` in the `getAuthKey()` method to keep
    the old behavior (that is, no validation of active sessions). Applications that change the underlying `authKey` of
    an authenticated identity, should now call `yii\web\User::switchIdentity()`, `yii\web\User::login()`
    or `yii\web\User::logout()` to recreate the active session with the new `authKey`.
  
  Upgrade from Yii 2.0.39.3
  -------------------------
  
  * Priority of processing 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值