2amigos / yii2-usuario

Highly customizable and extensible user management, authentication, and authorization Yii2 extension
https://github.com/2amigos/yii2-usuario
Other
294 stars 142 forks source link

Composer doesn't update to 1.5 #368

Closed drSun closed 4 years ago

drSun commented 4 years ago

I have an issue with updating the extension to version 1.5. I already made all things like composer clearcache, removed vendor directory, and when I make composer update I see this:

...

But in fact it installs version 1.1.5, I have an old code in vendor. All other extensions (and yii2 itself) are updated to the latest versions. Can it be something wrong with packagist settings?

I use PHP 7.1 and my composer.json is:

{
    "name": "yiisoft/yii2-app-advanced",
    "description": "Yii 2 Advanced Project Template",
    "keywords": ["yii2", "framework", "advanced", "project template"],
    "homepage": "http://www.yiiframework.com/",
    "type": "project",
    "license": "BSD-3-Clause",
    "support": {
        "issues": "https://github.com/yiisoft/yii2/issues?state=open",
        "forum": "http://www.yiiframework.com/forum/",
        "wiki": "http://www.yiiframework.com/wiki/",
        "irc": "irc://irc.freenode.net/yii",
        "source": "https://github.com/yiisoft/yii2"
    },
    "minimum-stability": "stable",
    "require": {
        "php": ">=5.4.0",
        "yiisoft/yii2": "~2.0.6",
        "yiisoft/yii2-bootstrap4": "~2.0.6",
        "yiisoft/yii2-swiftmailer": "~2.0.0",
        "2amigos/yii2-ckeditor-widget": "^2.1",
        "omnilight/yii2-shopping-cart": "*",
        "bower-asset/js-cookie": "*",
        "2amigos/yii2-file-upload-widget": "~1.0",
        "2amigos/yii2-gallery-widget": "~1.0",
        "claviska/simpleimage": "^3.3",
        "2amigos/yii2-usuario": "~1.0",
        "kartik-v/yii2-widget-select2": "dev-master",
        "kartik-v/yii2-widget-depdrop": "dev-master",
        "kartik-v/yii2-widget-touchspin": "dev-master",
        "npm-asset/popper.js": "~1.14",
        "rmrevin/yii2-fontawesome": "~3.1",
        "devanych/yii2-cart": "*",
        "yii2mod/yii2-enum": "*",
        "acerix/yii2-readmore": "*",
        "drnixx/yii2-unveil-asset": "*",
        "kartik-v/yii2-grid": "dev-master",
        "kartik-v/yii2-editable": "dev-master",
        "yiisoft/yii2-authclient": "~2.2.0",
        "kartik-v/yii2-export": "dev-master"
    },
    "require-dev": {
        "yiisoft/yii2-debug": "~2.0.0",
        "yiisoft/yii2-gii": "~2.0.0",
        "yiisoft/yii2-faker": "~2.0.0",
        "codeception/base": "^2.2.3",
        "codeception/verify": "~0.3.1"
    },
    "config": {
        "process-timeout": 1800,
        "fxp-asset": {
            "enabled": false
        }
    },
    "repositories": [
        {
            "type": "composer",
            "url": "https://asset-packagist.org"
        },
        {
            "type": "vcs",
            "url": "https://github.com/drSun/AmazonProductAPI"
        }
    ]
}
maxxer commented 4 years ago

Actually Packagist takes all the information about version from Github and git in general. When a version is tagged in Git, Packagist will automatically create a new version. Did you try with a clean directory?

drSun commented 4 years ago

Just to make sure, I tried to install it in empty dir, but no changes. I even removed everything from composer.json except Yii2 and usuario - nothing. Also tried different php versions up to 7.3.

I see this in composer.lock:

        {
            "name": "2amigos/yii2-usuario",
            "version": "1.5.0",
            "source": {
                "type": "git",
                "url": "https://github.com/2amigos/yii2-usuario.git",
                "reference": "ec428ab46dbd7ba23579ae00685ca324880ad83b"
            },
            "dist": {
                "type": "zip",
                "url": "https://api.github.com/repos/2amigos/yii2-usuario/zipball/ec428ab46dbd7ba23579ae00685ca324880ad83b",
                "reference": "ec428ab46dbd7ba23579ae00685ca324880ad83b",
                "shasum": ""
            },
            "require": {
                "2amigos/yii2-selectize-widget": "^1.1",
                "php": ">=5.5",
                "yiisoft/yii2-authclient": "^2.1",
                "yiisoft/yii2-bootstrap": "^2.0",
                "yiisoft/yii2-httpclient": "^2.0",
                "yiisoft/yii2-swiftmailer": "^2.0"
            },
            "conflict": {
                "dektrium/yii2-rbac": "*",
                "dektrium/yii2-user": "*"
            },
            "require-dev": {
                "codeception/codeception": "*",
                "codeception/specify": "^0.4.3",
                "codeception/verify": "^0.3.1",
                "friendsofphp/php-cs-fixer": "^2.3",
                "phpmd/phpmd": "@stable",
                "squizlabs/php_codesniffer": "*"
            },
            "suggest": {
                "2amigos/2fa-library": "Needed if you want to enable 2 Factor Authentication. Require version ^1.0",
                "2amigos/qrcode-library": "Needed if you want to enable 2FA with QR Code generation. Require version ^1.1"
            }
........

As you can see the version - it is "version": "1.5.0", but then download a zipball from github by provided link https://api.github.com/repos/2amigos/yii2-usuario/zipball/ec428ab46dbd7ba23579ae00685ca324880ad83b

It contains an outdated code (version 1.1.5). How could that be? And I found the same in all my projects which are using Usuario.

drSun commented 4 years ago

Ok, finally I understand that stable release is not the same as what is in master branch, that's why I don't see some features. Anyway, those features are described in docs, so it it amazing why they don't exist in release code.

maxxer commented 4 years ago

Indeed that's misleading, but docs are based on master.