- @yashrode opened merge request.
- ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Discussed with @phenaproxima, @yash.rode, @tedbow โ outcomes:
- Implement a
PreRequireEvent
subscriber, which validates this (by comparing the version constraint with the root-levelminimum-stability
and provides a nice message, unlike whatcomposer
would generate (and specifically detect the presence of an@stability-flag
part in the version constraint and never complains when that is present) - Need follow-up for
project_browser
, because after this issue lands, that validator will prevent the user's choices made in Project Browser to actually result in a module getting installed, if that module is e.g. only available inbeta
, and the user wants this module, Project Browser should prompt the user to explicitly ask the user that they understand the risks of installing a non-stable module. If the user confirms/acknowledges, Project Browser should specify notdrupal/modulename 1.0.0-beta1
but1.0.0-beta1@beta
โ i.e. it should specify a stability flag.
- Implement a
- Assigned to wim leers
- Status changed to Needs review
almost 2 years ago 2:30pm 31 January 2023 - Assigned to yash.rode
- Status changed to Needs work
almost 2 years ago 3:44pm 31 January 2023 - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
On the right track! Looking elegant already, but would like to see more thorough test coverage ๐
- Assigned to wim leers
- Status changed to Needs review
almost 2 years ago 11:58am 1 February 2023 - ๐ฎ๐ณIndia yash.rode pune
I have one question on the MR so assigning it to you.
- Assigned to yash.rode
- Status changed to Needs work
almost 2 years ago 12:07pm 1 February 2023 - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Answered your question, and also did a new round of review โ I have follow-up remarks to both of my previous remarks you addressed ๐ค
- Assigned to wim leers
- Status changed to Needs review
almost 2 years ago 2:15pm 1 February 2023 - ๐ฎ๐ณIndia yash.rode pune
Tried addressing the addition to the validator!
- Assigned to yash.rode
- Status changed to Needs work
almost 2 years ago 12:52pm 2 February 2023 - Assigned to wim leers
- Status changed to Needs review
almost 2 years ago 2:05pm 2 February 2023 - Assigned to yash.rode
- Status changed to Needs work
almost 2 years ago 4:12pm 3 February 2023 - Assigned to wim leers
- Status changed to Needs review
almost 2 years ago 8:20am 6 February 2023 - Assigned to yash.rode
- Status changed to Needs work
almost 2 years ago 11:12am 6 February 2023 - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Discussed that small doubt in a meeting earlier today. That is addressed now ๐
But โฆ there are still quite a few small oversights in this merge request, plus a major problem in a test, plus a critical bug. So not quite there yet. Fortunately, none of these bugs are particularly difficult to solve ๐
Please do a thorough self-review of every line before asking for a review next time.
- Assigned to wim leers
- Status changed to Needs review
almost 2 years ago 2:37pm 6 February 2023 - Assigned to yash.rode
- Status changed to Needs work
almost 2 years ago 5:27pm 6 February 2023 - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
I really wanted to RTBC this (and already deferred one subjective thing to @tedbow) but โฆ in his review of my merge request at ๐ Limit trusted Composer plugins to a known list, allow user to add more Fixed , @tedbow asked to stop using
$active_composer = $event->getStage()->getActiveComposer(); $active_composer->getComposer()->THINGS();
โฆ because that is using
composer/composer
.Since ๐ ComposerSettingsValidator should run `composer config` to determine if HTTPS is enabled Fixed , we should use
ComposerInspector
. I just tried it locally, and that should be possible here too. So โฆ back to . - Assigned to wim leers
- Status changed to Needs review
almost 2 years ago 12:31pm 7 February 2023 - ๐ฎ๐ณIndia yash.rode pune
I need some help:
Just checkingif(str_contains($key, 'extra'))
in\Drupal\package_manager\ComposerInspector::getConfig
is not enough the test fails. So I added a third parameter togetConfig
to differentiate between jsonCallback and new callback we added, I am not sure about this approach? - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Mind = blown by the stupidly terrible documentation for
composer config
, which caused @yash.rode to get stuck multiple times, my suggested work-around to be wrong, the code that @tedbow and I to be fooled in ๐ ComposerSettingsValidator should run `composer config` to determine if HTTPS is enabled Fixed too: the--json
flag exists ONLY forextra.*
key-value pairs, and- for decoding the given string into JSON when setting the value
So itโs supposed to only be used when setting values, not when getting them ๐คฏ๐ Observe this by trying
composer config extra.property true
vscomposer config extra.property true --json
โฆ and thatcomposer config allow-plugins
also returns JSON!Fix pushed in https://git.drupalcode.org/project/automatic_updates/-/merge_requests/68....
- Assigned to tedbow
- Status changed to RTBC
almost 2 years ago 6:01pm 7 February 2023 - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Whew this is one hell of a beast of an issue suddenly. Not only challenges with
ComposerInspector
, but also withcomposer/composer
itself!After a detailed discussion with @tedbow and @TravisCarden (crediting both), created this upstream issue: https://github.com/composer/composer/issues/11302.
Also addressed all of my own feedback, because this IMHO should land ASAP โ it implements exactly what we discussed during scrum, and helps other issues not having to deal with the same stuff that @yash.rode was forced to fight!
- ๐บ๐ธUnited States traviscarden
Wim Leers โ credited TravisCarden โ .
- Status changed to Needs work
almost 2 years ago 6:37pm 7 February 2023 - ๐บ๐ธUnited States tedbow Ithaca, NY, USA
Tests failing will take a look
-
tedbow โ
committed 1864f56b on 8.x-2.x authored by
yash.rode โ
Issue #3311229 by Wim Leers, yash.rode, tedbow, TravisCarden: Validate...
-
tedbow โ
committed 1864f56b on 8.x-2.x authored by
yash.rode โ
- Status changed to Fixed
almost 2 years ago 3:18am 8 February 2023 - ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
Thanks for teaching @yash.rode and I about
Semver::satisfies()
! Automatically closed - issue fixed for 2 weeks with no activity.