Problem/Motivation

The stub release of 10.1.x without any real code in it breaks several/most/all installer tests in 10.0.x

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

Issue fork drupal-3291893

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Spokje created an issue. See original summary.

spokje’s picture

Ah, only after creating this issue I've noticed #3291877: Fix \Drupal\FunctionalTests\Installer\InstallerTestBase tests to not test drupal.org where @alexpott found the same problem and tries to resolve it in a much more elaborate way. :/

Happy for Bigger Brains to decide what approach to take.

alexpott’s picture

Priority: Normal » Critical

I think we do both approaches. This will fix the problem everywhere but #3291877: Fix \Drupal\FunctionalTests\Installer\InstallerTestBase tests to not test drupal.org will result in less unexpected update module installs.

spokje’s picture

Assigned: spokje » Unassigned
Status: Active » Needs review
alexpott’s picture

Status: Needs review » Needs work

I think the change here should be a little more conservative. I think we should do something like

    // Ignore dev releases with no date. These are either broken releases or
    // stub releases to allow them to be selected on drupal.org project issues.
    elseif ($release->getDate() === NULL && $release_module_version->getVersionExtra() === 'dev') {
      continue;
    }

We currently failing here:

  // If we're running a dev snapshot, compare the date of the dev snapshot
  // with the latest official version, and record the absolute latest in
  // 'latest_dev' so we can correctly decide if there's a newer release
  // than our current snapshot.
  if ($project_data['install_type'] == 'dev') {
    if (isset($project_data['dev_version']) && $available['releases'][$project_data['dev_version']]['date'] > $available['releases'][$project_data['latest_version']]['date']) {
      $project_data['latest_dev'] = $project_data['dev_version'];
    }
    else {
      $project_data['latest_dev'] = $project_data['latest_version'];
    }
  }

As this only concerns dev snapshots I think only ignoring dev releases is way safer.

spokje’s picture

Status: Needs work » Needs review

Made changes.

spokje’s picture

alexpott’s picture

Status: Needs review » Reviewed & tested by the community

Thanks @Spokje - as we can see from #2 this fixes the broken tests on 10.0.x which is great. It also stops the update module from recommend 10.1.x to anyone which feels good too. And I think the latest changes in #7 make this as safe a change as we can make.

This issue addresses the broken tests, improves the UI, and does so in as limited a way possible => RTBC.

An alternative fix would be to update the 10.1.x branch to 6d457761e2 - i.e the first commit for Drupal 10... that would allow packaging to create a release. That's something for the release managers to decide.

  • catch committed 566a168 on 10.0.x
    Issue #3291893 by Spokje, alexpott: Stub release for 10.1.x breaks 10.0....
catch’s picture

Status: Reviewed & tested by the community » Fixed

Committed/pushed to 10.0.x, thanks!

Status: Fixed » Closed (fixed)

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