New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update WordPress packages #4408
Conversation
Just like in #4247, the following test is failing:
And I have no idea why. Any help appreciated. |
This is code that @pierlon has worked on, so he probably has an idea what the culprit might be. |
A quick guess would be one of the JS dependencies being missing on WP 4.9. I'll take a look into it. |
The @wordpress/wp-url package now requires lodash as a dependency. The lodash package is not available in WP 4.9 so we will have to register it ourselves.
All (the pull request submitter and all commit authors) CLAs are signed, but one or more commits were authored or co-authored by someone other than the pull request submitter. We need to confirm that all authors are ok with their commits being contributed to this project. Please have them confirm that by leaving a comment that contains only Note to project maintainer: There may be cases where the author cannot leave a comment, or the comment is not properly detected as consent. In those cases, you can manually confirm consent of the commit author(s), and set the ℹ️ Googlers: Go here for more info. |
@googlebot I consent. |
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
Turns out |
E2E tests keep failing with:
|
Turns out its a puppeteer issue (see WordPress/gutenberg#20268 and puppeteer/puppeteer#5420). We could wait for it to be fixed upstream, or use this patch to overcome the issue now: Index: tests/e2e/utils/upload-media.js
<+>UTF-8
===================================================================
--- tests/e2e/utils/upload-media.js (revision c2fbf090a63065d5b8f5490d2d188c32b39701b6)
+++ tests/e2e/utils/upload-media.js (date 1584742106698)
@@ -24,8 +24,9 @@
const fileExtension = fileExtensionMatches[ 0 ];
// Wait for media modal to appear and upload video.
- await page.waitForSelector( '.media-modal input[type=file]' );
- const inputElement = await page.$( '.media-modal input[type=file]' );
+ const inputSelector = '.media-modal input[type=file]';
+ await page.waitForSelector( inputSelector );
+ const inputElement = await page.$( inputSelector );
const testMediaPath = path.join( __dirname, '..', 'assets', file );
const filename = uuidv4();
@@ -34,6 +35,10 @@
fs.copyFileSync( testMediaPath, tmpFileName );
await inputElement.uploadFile( tmpFileName );
+ await page.evaluate( ( input ) => {
+ document.querySelector( input ).dispatchEvent( new Event( 'change', { bubbles: true } ) );
+ }, inputSelector );
+
// Wait for upload.
await page.waitForSelector( `.media-modal li[aria-label="${ filename }"]` );
|
I suppose it depends on WordPress 5.4… do these updates improve compatibility with 5.4 or are they more targeted for 5.5-alpha (aka current Gutenberg)? If the former, then let's do the patch. If the latter, then it can wait for 1.5.1. |
I'm not sure how these changes will improve compatibility with WordPress in anyway actually; I'm only aware of them affecting the DX and and build process. |
OK, then this can wait for v1.5.1, unless @swissspidy sees differently. The puppeteer issue has been open for more than a month, so it doesn't look like it is getting resolved before 1.5. |
It seems there are only lint errors here to resolve. Would you want me to resolve them @swissspidy? |
@pierlon sure, feel free! |
# Conflicts: # package-lock.json # package.json
Summary
Fixes #4247
Fixes #4249
Fixes #4274
Checklist