Make WordPress Core

Opened 16 months ago

Last modified 16 months ago

#57489 new defect (bug)

Media items, which have already been uploaded, disappear when the upload dialog box is closed and then opened again.

Reported by: shamayel007's profile shamayel007 Owned by:
Milestone: Awaiting Review Priority: normal
Severity: major Version: 6.1.1
Component: Media Keywords: has-screenshots needs-testing has-testing-info
Focuses: javascript Cc:

Description

I followed the following steps and got this error:

1) Freshly created a new WordPress site.

https://i.paste.pics/L1SUI.png

2) Created a new page and opened it in the block editor

https://i.paste.pics/L1SW2.png

3) Added a new gallery block

https://i.paste.pics/L1SY2.png

4) Clicked "Media Library"

https://i.paste.pics/L1SYB.png

5) Uploaded new images

https://i.paste.pics/L1SYG.png

6) Uploaded 20 images

https://i.paste.pics/L1SYQ.png

7) Closed the dialogue box and opened it back up.

https://i.paste.pics/L1T7T.png

8) Selected a few images and clicked "Create a new gallery"

https://i.paste.pics/L1T81.png

9) After it went to the "Edit Gallery" window, I closed it by clicking the cross button

https://i.paste.pics/L1T8W.png

10) Clicked "Media Library" again to create the Gallery block

https://i.paste.pics/L1TAA.png

11) Selected photos again and clicked "Create a new gallery"

https://i.paste.pics/L1TBI.png

12) When it again went to the Edit Gallery window, I clicked "Add to gallery"

https://i.paste.pics/L1TCL.png

13) Shows "No media items found", even though I have a lot of images uploaded.

https://i.paste.pics/L1TDG.png

Here are my setup details:
i) OS: Ubuntu 20.04.5 LTS
ii) Using Local by Flywheel
iii) Web server: Nginx
iv) PHP Version: 8.1.9
v) MySQL: 8.0.16
vi) WordPress: 6.1.1
vii) Browser: Opera

Attachments (1)

13_Shows %22No items found%22 even though there are a lot of items already uploaded.png (40.6 KB) - added by shamayel007 16 months ago.
Shows "No media items found" even when a lot of images are already uploaded.

Download all attachments as: .zip

Change History (4)

@shamayel007
16 months ago

Shows "No media items found" even when a lot of images are already uploaded.

This ticket was mentioned in Slack in #core-test by ironprogrammer. View the logs.


16 months ago

#2 @ironprogrammer
16 months ago

  • Keywords needs-testing has-testing-info added; needs-patch removed

Thank you for the detailed report, @shamayel007! I'm marking this ticket for reproduction testing.

#3 @dariak
16 months ago

Reproduction Report

I have been trying to reproduce the issue, and probably we need to clarify the expected result and behaviour. The behaviour, which I got, is also not clear to me.

Environment

  • OS: macOS 13.1
  • Web Server: Nginx
  • PHP: 7.4.1
  • WordPress: 6.1.1
  • Browser: Chrome 109
  • Theme: Twenty Twenty-Two

Active Plugins: none
(I used Local to build a clean WordPress environment).

Actual Results

  • Go to create new page.
  • Insert Gallery block.
  • Click Media Library.
  • Upload 3 JPEG images.
  • Choose 1 image and click "Create a new gallery".
  • Close the popup by clicking X.
  • Click Media Library in the Gallery block -> you are in "Edit gallery", which is empty (I would expect it to be empty).
  • Click "Add to gallery" in the left side menu -> you see Media library with 3 uploaded images.
  • Choose 1 image and click "Create a new gallery".
  • Close the popup by clicking X.
  • Click Media Library in the Gallery block -> you are in "Edit gallery", which is empty (I would expect it to be empty).
  • Click "Add to gallery" in the left side menu -> you see Media library with only 2 uploaded images.
  • Choose 2 images and click "Create a new gallery".
  • Close the popup by clicking X.
  • Click Media Library in the Gallery block -> you are in "Edit gallery", which is empty (I would expect it to be empty).
  • Click "Add to gallery" in the left side menu -> you see Media library which is empty.

I suppose this is the problem.

  • However, now close the popup by clicking X.
  • Click Media Library in the Gallery block -> you are in "Edit gallery", which is empty (I would expect it to be empty).
  • Click "Add to gallery" in the left side menu -> you see Media library with 3 images.
Last edited 16 months ago by dariak (previous) (diff)
Note: See TracTickets for help on using tickets.