CodeIgniter / phpstan-codeigniter

CodeIgniter extensions and rules for PHPStan
https://codeigniter.com/
MIT License
15 stars 0 forks source link

bug: locks version when installing without version #10

Closed kenjis closed 10 months ago

kenjis commented 1 year ago

PHP Version

8.1

PHPStan CodeIgniter Version

v1.4.2.70400

PHPStan Version

1.10.39

What happened?

$ composer require --dev codeigniter/phpstan-codeigniter
--- a/composer.json
+++ b/composer.json
@@ -19,6 +19,7 @@
     "s9e/text-formatter": "^2.13"
   },
   "require-dev": {
+    "codeigniter/phpstan-codeigniter": "v1.4.2.70400",
     "codeigniter4/devkit": "^1.1",
     "mockery/mockery": "^1.6",
     "phpstan/phpstan-mockery": "^1.1",

Minimum Reproduction Script

$ composer require --dev codeigniter/phpstan-codeigniter

Expected Output

"codeigniter/phpstan-codeigniter": "^1.4",

paulbalandan commented 1 year ago

I sent a bug report to composer: https://github.com/composer/composer/issues/11716

MGatner commented 1 year ago

Wow, a Composer bug in the wild! Kinda cool.

kenjis commented 1 year ago

1.4.2.70400 does not follow Semantic Versioning. https://semver.org/#backusnaur-form-grammar-for-valid-semver-versions So not a bug?

paulbalandan commented 1 year ago

Composer accepts 4 parts in tags. Semver does not accept 4 parts.

paulbalandan commented 10 months ago

I sent a bug report to composer: composer/composer#11716

Fix was made 15 minutes ago and will be part of composer v2.6