php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #80227 RecursiveDirectoryIterator returns incorrect results for Docker Desktop on WSL2
Submitted: 2020-10-13 02:02 UTC Modified: 2020-10-13 02:40 UTC
From: themizzi at me dot com Assigned:
Status: Not a bug Package: *Directory/Filesystem functions
PHP Version: 7.3.23 OS: alpine
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
36 - 1 = ?
Subscribe to this entry?

 
 [2020-10-13 02:02 UTC] themizzi at me dot com
Description:
------------
The RecursiveDirectoryIterator returns an incomplete list of files after some limit when running under Docker Desktop on WSL2. It works fine when using Hyper V.

Test script:
---------------
This repository reproduces this issue: https://github.com/themizzi/wsl2-php-recursive-directory-iterator-bug

Expected result:
----------------
file counts should never diverge and program should exit after $stop

Actual result:
--------------
file counts diverge from scandir after 65 files.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-10-13 02:40 UTC] requinix@php.net
-Status: Open +Status: Not a bug
 [2020-10-13 02:40 UTC] requinix@php.net
This is a WSL bug.

Keep an eye on https://github.com/microsoft/WSL/issues/5074.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 09:01:27 2024 UTC