Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
automatic_updates
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
automatic_updates
Merge requests
!227
Issue
#3265874
: Do not allow apply if active and staged composer locks are identical.
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Issue
#3265874
: Do not allow apply if active and staged composer locks are identical.
issue/automatic_updates-3265874:3265874-do-not-allow
into
8.x-2.x
Overview
18
Commits
12
Pipelines
0
Changes
2
Merged
Kunal Sachdev
requested to merge
issue/automatic_updates-3265874:3265874-do-not-allow
into
8.x-2.x
3 years ago
Overview
18
Commits
12
Pipelines
0
Changes
2
Expand
0
0
Merge request reports
Viewing commit
be1578dd
Prev
Next
Show latest version
2 files
+
7
−
4
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
Search (e.g. *.vue) (Ctrl+P)
be1578dd
Improve comment
· be1578dd
Adam G-H
authored
3 years ago
package_manager/src/Validator/LockFileValidator.php
+
4
−
1
Options
@@ -116,12 +116,15 @@ class LockFileValidator implements PreOperationStageValidatorInterface {
$error
=
$this
->
t
(
'Stored lock file hash does not match the active lock file.'
);
}
// Don't allow staged changes to be applied if the staged lock file has no
// apparent changes.
if
(
empty
(
$error
)
&&
$event
instanceof
PreApplyEvent
)
{
$stage_hash
=
$this
->
getLockFileHash
(
$event
->
getStage
()
->
getStageDirectory
());
if
(
$active_hash
===
$stage_hash
)
{
if
(
hash_equals
(
$active_hash
,
$stage_hash
)
)
{
$error
=
$this
->
t
(
'There are no pending Composer operations.'
);
}
}
// @todo Let the validation result carry all the relevant messages in
// https://www.drupal.org/i/3247479.
if
(
isset
(
$error
))
{
Loading