drupal-composer / drupal-packagist

:package: Drupal Packagist server to automatically build package information from projects on drupal.org
http://packagist.drupal-composer.org
28 stars 4 forks source link

registry_rebuild (and potentially) other projects missing some releases #42

Closed echernyavskiy closed 8 years ago

echernyavskiy commented 8 years ago

Was running a routine composer update and noticed that _registryrebuild fails the dependency resolving process as Drupal packagist does not have any information about the latest recommended version of the project that was requested. drupal.org says 2.2 is recommended while packagist only has up to 1.4.

This has happened before with another project and IIRC the releases parser was at fault at that time.

webflo commented 8 years ago

The dependency parsing on drupal packagist does not work in any case. Things are easier with a composer.json in the repo itself. I filled a issue in the registry_rebuild issue queue.

https://www.drupal.org/node/2622718#comment-10604008

echernyavskiy commented 8 years ago

:thumbsup:

Just curious: how does adding composer.json facilitate release info update?

webflo commented 8 years ago

We have this info-file parser library (https://github.com/drupal-composer/drupal-parse-composer/blob/master/src/Project.php#L50) and the parser stops if there is no valid info file. Drupal Packagist uses the composer.json in favour of the parser.

webflo commented 8 years ago

Package is up to date. https://packagist.drupal-composer.org/packages/drupal/registry_rebuild

echernyavskiy commented 8 years ago

Gotchya, and appreciate such a quick turnaround.

echernyavskiy commented 8 years ago

I just ran composer update with registry_rebuild pinned at 2.2 and it succeeded, however composer install then installs it under vendor/drupal/ instead of drush/. In my case this is configured via composer/installers install paths - vendor/drupal for type drupal-core, drush/{$name} for type drupal-drush:

"extra": {
  "installer-paths": {
    "vendor/drupal": [
      "type:drupal-core"
    ],

    // ...

    "drush/{$name}": [
      "type:drupal-drush"
    ],
  }
},

I checked your patch in the module's issue queue and project type seems to be correct there (drupal-drush), but any chance there's a discrepancy between that and the type value that the registry maintains?

webflo commented 8 years ago

Took me a while to understand the issue. The older releases of registry_rebuild are list on drupal packagist but as type library because these releases have no composer.json (https://packagist.drupal-composer.org/packages/drupal/registry_rebuild.json)

Please use the dev release (composer require drupal/registry_rebuild:7.2.x-dev) instead, this contains the committed composer.json from today.