Hi,

I face off an issue about updating the module.
The BO of Drupal(admin/reports/updates/update) said I need to update the module like this:
Viewfield 8.x-3.0-alpha3 8.x-3.0-beta4 (Notes de version)

But Composer find nothing to update. And Drush 9 return this information:
Field types Viewfield (viewfield) Enabled 8.x-3.0-alpha3

So how to update the module ?

Thanks

Comments

aiphes created an issue. See original summary.

aiphes’s picture

Issue summary: View changes
xSDx’s picture

@aiphes can you share your composer.json file. Probably issue is there. I've just updated via composer on my project and it works fine.

aiphes’s picture

This is the line into my composer.json:
"drupal/viewfield": "^3.0@beta",
composer.lock:

{
            "name": "drupal/viewfield",
            "version": "3.0.0-beta4",
            "source": {
                "type": "git",
                "url": "https://git.drupalcode.org/project/viewfield.git",
                "reference": "8.x-3.0-beta4"
            },
jerdavis’s picture

Status: Active » Needs work

Your composer.lock suggests you have the correct beta version installed. You can verify this by navigating to your composer installed modules directory and checking for the following in viewfield.info.yml

# Information added by Drupal.org packaging script on 2019-09-05
version: '8.x-3.0-beta4'
project: 'viewfield'
datestamp: 1567713487

If update status is still reporting an older version of Viewfield, you should double check that you don't have another copy installed somewhere in your file system that is overriding the version installed via composer. This could be in /modules/custom, sites/all/modules, or sites/example.com/modules.

Let us know if you continue to have issues.

aiphes’s picture

This is the content of modules/contrib/viewfield/viewfield.info.yml:

# Information added by Drupal.org packaging script on 2019-03-29
version: '8.x-3.0-alpha3'
core: '8.x'
project: 'viewfield'
datestamp: 1553884989

So I try to reinstall the module:

$ composer require drupal/viewfield
Using version ^3.0@beta for drupal/viewfield
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Nothing to install or update

Perhaps manually removing the module folder then reinstall it ?

jerdavis’s picture

Composer is really what's in charge. You can delete the module folder and run composer install, but that may not sort it out. If you do that, verify that your composer.lock still says beta4.

You could also try composer update drupal/viewfield

aiphes’s picture

Seem to be fixed:

composer update drupal/viewfield
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 0 installs, 1 update, 0 removals
  - Updating drupal/viewfield (3.0.0-beta4 => 3.0.0-beta5): Downloading (100%)
Writing lock file
Generating autoload files
sited8$ drush pml | grep viewfield
  Field types                       Viewfield (viewfield)                Enabled    8.x-3.0-beta5

Still be a mystery.

jerdavis’s picture

Status: Needs work » Fixed

Glad that got you going! Let us know if you have issues with the next update.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.