Skip to content

Commit eb03518

Browse files
author
Shikha Mishra
authored
Merge branch '2.4-develop' into Refactoring-StorefrontProductNameWithHTMLEntitiesTest
2 parents 5a6e82b + 9728fe3 commit eb03518

File tree

839 files changed

+43156
-17942
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

839 files changed

+43156
-17942
lines changed

.github/CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ This will allow you to collaborate with the Magento 2 development team, fork the
3333
1. Search current [listed issues](https://github.com/magento/magento2/issues) (open or closed) for similar proposals of intended contribution before starting work on a new contribution.
3434
2. Review the [Contributor License Agreement](https://opensource.adobe.com/cla.html) if this is your first time contributing.
3535
3. Create and test your work.
36-
4. Fork the Magento 2 repository according to the [Fork A Repository instructions](https://devdocs.magento.com/guides/v2.4/contributor-guide/contributing.html#fork) and when you are ready to send us a pull request – follow the [Create A Pull Request instructions](https://devdocs.magento.com/guides/v2.4/contributor-guide/contributing.html#pull_request).
36+
4. Follow the [Forks And Pull Requests Instructions](https://devdocs.magento.com/contributor-guide/contributing.html#forks-and-pull-requests) to fork the Magento 2 repository and send us a pull request.
3737
5. Once your contribution is received the Magento 2 development team will review the contribution and collaborate with you as needed.
3838

3939
## Code of Conduct
@@ -43,6 +43,6 @@ The full text is available in the repository [Wiki](https://github.com/magento/m
4343

4444
## Connecting with Community!
4545

46-
If you have any questions, join us in [#beginners](https://magentocommeng.slack.com/messages/CH8BGFX9D) Slack chat. If you are not on our slack, [click here](http://tinyurl.com/engcom-slack) to join.
46+
If you have any questions, join us in [#beginners](https://magentocommeng.slack.com/archives/CH8BGFX9D) Slack chat. If you are not on our slack, [click here](http://tinyurl.com/engcom-slack) to join.
4747

4848
Need to find a project? Check out the [Slack Channels](https://github.com/magento/magento2/wiki/Slack-Channels) (with listed project info) and the [Magento Community Portal](https://opensource.magento.com/).

.github/stale.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Configuration for probot-stale - https://github.com/probot/stale
22

33
# Number of days of inactivity before an Issue or Pull Request becomes stale
4-
daysUntilStale: 76
4+
daysUntilStale: 152
55

66
# Number of days of inactivity before an Issue or Pull Request with the stale label is closed.
77
# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale.
8-
daysUntilClose: 14
8+
daysUntilClose: 28
99

1010
# Only issues or pull requests with all of these labels are check if stale. Defaults to `[]` (disabled)
1111
onlyLabels: []
@@ -15,6 +15,8 @@ exemptLabels:
1515
- "Priority: P0"
1616
- "Priority: P1"
1717
- "Priority: P2"
18+
- "Severity: S0"
19+
- "Severity: S1"
1820
- "Progress: dev in progress"
1921
- "Progress: PR in progress"
2022
- "Progress: done"
@@ -39,7 +41,7 @@ staleLabel: "stale issue"
3941
# Comment to post when marking as stale. Set to `false` to disable
4042
markComment: >
4143
This issue has been automatically marked as stale because it has not had
42-
recent activity. It will be closed after 14 days if no further activity occurs.
44+
recent activity. It will be closed after 28 days if no further activity occurs.
4345
Is this issue still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?
4446
Thank you for your contributions!
4547
# Comment to post when removing the stale label.

README.md

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@ Welcome to Magento 2 installation! We're glad you chose to install Magento 2, a
2121

2222
## Magento System Requirements
2323

24-
[Magento System Requirements](https://devdocs.magento.com/guides/v2.4/install-gde/system-requirements.html).
24+
* [Magento System Requirements](https://devdocs.magento.com/guides/v2.4/install-gde/system-requirements.html)
2525

2626
## Install Magento
2727

28-
* [Installation Guide](https://devdocs.magento.com/guides/v2.4/install-gde/bk-install-guide.html).
28+
* [Installation Guide](https://devdocs.magento.com/guides/v2.4/install-gde/bk-install-guide.html)
2929

30-
## Learn More About GraphQL in Magento 2
30+
## Learn About GraphQL in Magento 2
3131

3232
* [GraphQL Developer Guide](https://devdocs.magento.com/guides/v2.4/graphql/index.html)
3333

@@ -37,12 +37,14 @@ Contributions can take the form of new components or features, changes to existi
3737

3838
To learn about how to contribute, click [here][1].
3939

40-
To learn about issues, click [here][2]. To open an issue, click [here][3].
40+
To learn about issues, click [here][2].
41+
42+
To open an issue, click [here][3].
4143

4244
To suggest documentation improvements, click [here][4].
4345

44-
[1]: https://devdocs.magento.com/guides/v2.4/contributor-guide/contributing.html
45-
[2]: https://devdocs.magento.com/guides/v2.4/contributor-guide/contributing.html#report
46+
[1]: https://devdocs.magento.com/contributor-guide/contributing.html
47+
[2]: https://devdocs.magento.com/contributor-guide/contributing.html#report
4648
[3]: https://github.com/magento/magento2/issues
4749
[4]: https://devdocs.magento.com
4850

@@ -61,7 +63,7 @@ Magento is thankful for any contribution that can improve our codebase, document
6163
### Labels Applied by the Magento Team
6264

6365
We apply labels to public Pull Requests and Issues to help other participants retrieve additional information about current progress, component assignments, Magento release lines, and much more.
64-
Please review the [Code Contributions guide](https://devdocs.magento.com/guides/v2.4/contributor-guide/contributing.html#labels) for detailed information on labels used in Magento 2 repositories.
66+
Please review the [Code Contributions guide](https://devdocs.magento.com/contributor-guide/contributing.html#labels) for detailed information on labels used in Magento 2 repositories.
6567

6668
## Reporting Security Issues
6769

@@ -85,6 +87,6 @@ To connect with Magento and the Community, join us on the [Magento Community Eng
8587

8688
We have channels for each project. These channels are recommended for new members:
8789

88-
* [general](https://magentocommeng.slack.com/messages/C4YS78WE6): Open chat for introductions and Magento 2 questions
89-
* [github](https://magentocommeng.slack.com/messages/C7KB93M32): Support for GitHub issues, pull requests, and processes
90-
* [public-backlog](https://magentocommeng.slack.com/messages/CCV3J3RV5): Discussions of the Magento 2 backlog
90+
* [general](https://magentocommeng.slack.com/archives/C4YS78WE6): Open chat for introductions and Magento 2 questions
91+
* [github](https://magentocommeng.slack.com/archives/C7KB93M32): Support for GitHub issues, pull requests, and processes
92+
* [public-backlog](https://magentocommeng.slack.com/archives/CCV3J3RV5): Discussions of the Magento 2 backlog
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
"Allow Adobe to collect usage data to improve user experience and offer in-product guidance", "Allow Adobe to collect usage data to improve user experience and offer in-product guidance"
2+
"<p>By clicking on <b>Allow</b>, you agree that we may collect anonymous usage data from you to:</p> <ol class=""modal-list""> <li>Help us improve the Magento Admin user experience</li> <li>Provide interactive in-product guidance, such as technical support and tips to improve utilization of the product from within the Admin UI. This may include notifications of new features, product support/guidance, onboarding information, tooltips, and more.</li> </ol> <p>All usage data that we collect for this purpose cannot be used to individually identify you and is used only to improve the Magento Admin UI and related products and services.</p> <p>You can learn more and opt-out at any time by following the instructions in <a href=""https://docs.magento.com/user-guide/configuration/advanced/admin.html#admin-usage"">merchant documentation</a>.</p>", "<p>By clicking on <b>Allow</b>, you agree that we may collect anonymous usage data from you to:</p> <ol class=""modal-list""> <li>Help us improve the Magento Admin user experience</li> <li>Provide interactive in-product guidance, such as technical support and tips to improve utilization of the product from within the Admin UI. This may include notifications of new features, product support/guidance, onboarding information, tooltips, and more.</li> </ol> <p>All usage data that we collect for this purpose cannot be used to individually identify you and is used only to improve the Magento Admin UI and related products and services.</p> <p>You can learn more and opt-out at any time by following the instructions in <a href=""https://docs.magento.com/user-guide/configuration/advanced/admin.html#admin-usage"">merchant documentation</a>.</p>"
3+

app/code/Magento/AdminAnalytics/view/adminhtml/layout/adminhtml_dashboard_index.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@
1919
</block>
2020
</referenceContainer>
2121
</body>
22-
</page>
22+
</page>

app/code/Magento/AdminAnalytics/view/adminhtml/ui_component/admin_usage_notification.xml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
<state>true</state>
5050
<options>
5151
<option name="modalClass" xsi:type="string">admin-usage-notification</option>
52-
<option name="title" xsi:type="string" translate="true">Allow admin usage data collection</option>
52+
<option name="title" xsi:type="string" translate="true">Allow Adobe to collect usage data to improve user experience and offer in-product guidance</option>
5353
<option name="autoOpen" xsi:type="boolean">true</option>
5454
<option name="type" xsi:type="string">popup</option>
5555
<option name="clickableOverlay" xsi:type="boolean">false</option>
@@ -82,11 +82,7 @@
8282
<item name="config" xsi:type="array">
8383
<item name="label" xsi:type="string"/>
8484
<item name="additionalClasses" xsi:type="string">release-notification-text</item>
85-
<item name="text" xsi:type="string" translate="true"><![CDATA[
86-
<p>Help us improve Magento Admin by allowing us to collect usage data.</p>
87-
<p>All usage data that we collect for this purpose cannot be used to individually identify you and is used only to improve the Magento Admin and related products and services.</p>
88-
<p>You can learn more and opt out at any time by following the instructions in <a href="https://docs.magento.com/user-guide/stores/admin.html" target="_blank" tabindex="0">merchant documentation</a>.</p>
89-
]]></item>
85+
<item name="text" xsi:type="string" translate="true"><![CDATA[<p>By clicking on <b>Allow</b>, you agree that we may collect anonymous usage data from you to:</p> <ol class="modal-list"> <li>Help us improve the Magento Admin user experience</li> <li>Provide interactive in-product guidance, such as technical support and tips to improve utilization of the product from within the Admin UI. This may include notifications of new features, product support/guidance, onboarding information, tooltips, and more.</li> </ol> <p>All usage data that we collect for this purpose cannot be used to individually identify you and is used only to improve the Magento Admin UI and related products and services.</p> <p>You can learn more and opt-out at any time by following the instructions in <a href="https://docs.magento.com/user-guide/configuration/advanced/admin.html#admin-usage">merchant documentation</a>.</p>]]></item>
9086
</item>
9187
</argument>
9288
</container>

app/code/Magento/AdminNotification/view/adminhtml/web/system/notification.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ define([
5252
tmpl = $(tmpl);
5353

5454
this.element.html(
55-
$('<ul />', {
55+
$('<ul></ul>', {
5656
'class': 'message-system-list'
5757
}).append(tmpl)
5858
).trigger('contentUpdated');

app/code/Magento/AsynchronousOperations/Model/BulkManagement.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,13 +119,14 @@ public function scheduleBulk($bulkUuid, array $operations, $description, $userId
119119
$bulkSummary->setOperationCount((int)$bulkSummary->getOperationCount() + count($operations));
120120
$this->entityManager->save($bulkSummary);
121121

122+
$this->publishOperations($operations);
123+
122124
$connection->commit();
123125
} catch (\Exception $exception) {
124126
$connection->rollBack();
125127
$this->logger->critical($exception->getMessage());
126128
return false;
127129
}
128-
$this->publishOperations($operations);
129130

130131
return true;
131132
}

app/code/Magento/AsynchronousOperations/Model/MassSchedule.php

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -166,12 +166,17 @@ public function publishMass($topicName, array $entitiesArray, $groupId = null, $
166166
}
167167
}
168168

169-
$this->saveMultipleOperations->execute($operations);
170169
if (!$this->bulkManagement->scheduleBulk($groupId, $operations, $bulkDescription, $userId)) {
171-
throw new LocalizedException(
172-
__('Something went wrong while processing the request.')
173-
);
170+
try {
171+
$this->bulkManagement->deleteBulk($groupId);
172+
} finally {
173+
throw new LocalizedException(
174+
__('Something went wrong while processing the request.')
175+
);
176+
}
174177
}
178+
$this->saveMultipleOperations->execute($operations);
179+
175180
/** @var AsyncResponseInterface $asyncResponse */
176181
$asyncResponse = $this->asyncResponseFactory->create();
177182
$asyncResponse->setBulkUuid($groupId);

app/code/Magento/AsynchronousOperations/Test/Unit/Model/BulkManagementTest.php

Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,85 @@ public function testScheduleBulkWithException()
186186
$this->assertFalse($this->bulkManagement->scheduleBulk($bulkUuid, [$operation], $description, $userId));
187187
}
188188

189+
/**
190+
* Test for scheduleBulk method with exception during publishing.
191+
*
192+
* @return void
193+
*/
194+
public function testScheduleBulkWithExceptionDuringPublishing()
195+
{
196+
$bulkUuid = 'bulk-001';
197+
$description = 'Bulk summary description...';
198+
$userId = 1;
199+
$userType = UserContextInterface::USER_TYPE_ADMIN;
200+
$connectionName = 'default';
201+
$exceptionMessage = 'Exception message';
202+
$operation = $this->createMock(OperationInterface::class);
203+
$metadata = $this->createMock(EntityMetadataInterface::class);
204+
$this->metadataPool->expects($this->once())
205+
->method('getMetadata')
206+
->with(BulkSummaryInterface::class)
207+
->willReturn($metadata);
208+
$metadata->expects($this->once())
209+
->method('getEntityConnectionName')
210+
->willReturn($connectionName);
211+
$connection = $this->createMock(AdapterInterface::class);
212+
$this->resourceConnection->expects($this->once())
213+
->method('getConnectionByName')
214+
->with($connectionName)
215+
->willReturn($connection);
216+
$connection->expects($this->once())
217+
->method('beginTransaction')
218+
->willReturnSelf();
219+
$bulkSummary = $this->createMock(BulkSummaryInterface::class);
220+
$this->bulkSummaryFactory->expects($this->once())
221+
->method('create')
222+
->willReturn($bulkSummary);
223+
$this->entityManager->expects($this->once())
224+
->method('load')
225+
->with($bulkSummary, $bulkUuid)
226+
->willReturn($bulkSummary);
227+
$bulkSummary->expects($this->once())
228+
->method('setBulkId')
229+
->with($bulkUuid)
230+
->willReturnSelf();
231+
$bulkSummary->expects($this->once())
232+
->method('setDescription')
233+
->with($description)
234+
->willReturnSelf();
235+
$bulkSummary->expects($this->once())
236+
->method('setUserId')
237+
->with($userId)
238+
->willReturnSelf();
239+
$bulkSummary->expects($this->once())
240+
->method('setUserType')
241+
->with($userType)
242+
->willReturnSelf();
243+
$bulkSummary->expects($this->once())
244+
->method('getOperationCount')
245+
->willReturn(1);
246+
$bulkSummary->expects($this->once())
247+
->method('setOperationCount')
248+
->with(2)
249+
->willReturnSelf();
250+
$this->entityManager->expects($this->once())
251+
->method('save')
252+
->with($bulkSummary)
253+
->willReturn($bulkSummary);
254+
$this->publisher->expects($this->once())
255+
->method('publish')
256+
->willThrowException(new \Exception($exceptionMessage));
257+
$connection->expects($this->never())
258+
->method('commit');
259+
$connection->expects($this->once())
260+
->method('rollBack')
261+
->willReturnSelf();
262+
$this->logger->expects($this->once())
263+
->method('critical')
264+
->with($exceptionMessage);
265+
$this->assertFalse($this->bulkManagement->scheduleBulk($bulkUuid, [$operation], $description, $userId));
266+
}
267+
189268
/**
190269
* Test for retryBulk method.
191270
*
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
<suites xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Suite/etc/suiteSchema.xsd">
9+
<suite name="RemoteStorageAwsS3EnabledSuite">
10+
<before>
11+
<!-- Enable AWS S3 Remote Storage -->
12+
<magentoCLI command="setup:config:set {{RemoteStorageAwsS3ConfigData.enable_options}}" stepKey="enableRemoteStorage"/>
13+
</before>
14+
<after>
15+
<!-- Disable Remote Storage -->
16+
<magentoCLI command="setup:config:set {{RemoteStorageAwsS3ConfigData.disable_options}}" stepKey="disableRemoteStorage"/>
17+
</after>
18+
<include>
19+
<group name="remote_storage_aws_s3"/>
20+
</include>
21+
<exclude>
22+
<group name="remote_storage_disabled"/>
23+
<group name="remote_storage_aws_s3_pagebuilder"/>
24+
</exclude>
25+
</suite>
26+
</suites>
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
<suites xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Suite/etc/suiteSchema.xsd">
9+
<suite name="RemoteStorageDisabledSuite">
10+
<before>
11+
<!-- Disable Remote Storage -->
12+
<magentoCLI command="setup:config:set {{RemoteStorageAwsS3ConfigData.disable_options}}" stepKey="disableRemoteStorage"/>
13+
</before>
14+
<after>
15+
<!-- Disable Remote Storage -->
16+
<magentoCLI command="setup:config:set {{RemoteStorageAwsS3ConfigData.disable_options}}" stepKey="disableRemoteStorage"/>
17+
</after>
18+
<include>
19+
<group name="remote_storage_disabled"/>
20+
</include>
21+
</suite>
22+
</suites>

app/code/Magento/AwsS3/Test/Mftf/Test/AdminAwsS3ExportBundleProductTest.xml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,14 @@
2727
</annotations>
2828

2929
<before>
30-
<!-- Enable AWS S3 Remote Storage -->
31-
<magentoCLI command="setup:config:set {{RemoteStorageAwsS3ConfigData.enable_options}}" stepKey="enableRemoteStorage" before="firstSimpleProductForDynamic"/>
30+
<comment userInput="BIC workaround" stepKey="enableRemoteStorage"/>
3231
</before>
3332

3433
<after>
3534
<helper class="\Magento\AwsS3\Test\Mftf\Helper\S3FileAssertions" method="deleteDirectory" stepKey="deleteExportFileDirectory">
3635
<argument name="path">import_export/export</argument>
3736
</helper>
38-
39-
<!-- Disable AWS S3 Remote Storage -->
40-
<magentoCLI command="setup:config:set {{RemoteStorageAwsS3ConfigData.disable_options}}" stepKey="disableRemoteStorage" after="logout"/>
37+
<comment userInput="BIC workaround" stepKey="disableRemoteStorage"/>
4138
</after>
4239

4340
<!-- Validate Export File on File System: Dynamic Bundle Product -->

app/code/Magento/AwsS3/Test/Mftf/Test/AdminAwsS3ExportDownloadableProductWithFileLinksTest.xml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,17 +28,14 @@
2828
</annotations>
2929

3030
<before>
31-
<!-- Enable AWS S3 Remote Storage -->
32-
<magentoCLI command="setup:config:set {{RemoteStorageAwsS3ConfigData.enable_options}}" stepKey="enableRemoteStorage" before="createCategory"/>
31+
<comment userInput="BIC workaround" stepKey="enableRemoteStorage"/>
3332
</before>
3433

3534
<after>
3635
<helper class="\Magento\AwsS3\Test\Mftf\Helper\S3FileAssertions" method="deleteDirectory" stepKey="deleteExportFileDirectory">
3736
<argument name="path">import_export/export</argument>
3837
</helper>
39-
40-
<!-- Disable AWS S3 Remote Storage -->
41-
<magentoCLI command="setup:config:set {{RemoteStorageAwsS3ConfigData.disable_options}}" stepKey="disableRemoteStorage" after="logout"/>
38+
<comment userInput="BIC workaround" stepKey="disableRemoteStorage"/>
4239
</after>
4340

4441
<!-- Validate Export File on S3 -->

0 commit comments

Comments
 (0)