[wp-trac] [WordPress Trac] #64559: Build: copyBlockAssets fails when core block types directories contain subdirectories

WordPress Trac noreply at wordpress.org
Tue Jan 27 21:35:16 UTC 2026


#64559: Build: copyBlockAssets fails when core block types directories contain
subdirectories
--------------------------+-----------------------------
 Reporter:  mcsf          |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 Issue first described at
 https://github.com/WordPress/gutenberg/pull/74805#issuecomment-3800272544

 **Steps to reproduce:**

 - In `package.json`, change `.gutenberg.ref` to a recent Gutenberg hash
 (e.g. `2654e7d13086e483855cedf089ba6f4e86c967d7`)
 - Run `npm run build:dev`
 - See the "Copying blocks..." step fail as it tries to copy a directory
 using `fs.copySync`:


 {{{
 Unexpected error: Error: ENOTSUP: operation not supported on socket,
 copyfile 'wordpress-develop/gutenberg/build/scripts/block-library
 /navigation-link/shared' -> 'wordpress-develop/src/wp-includes/blocks
 /navigation-link/shared'
     at Object.copyFileSync (node:fs:3085:11)
     at copyBlockAssets (wordpress-develop/tools/gutenberg/copy-gutenberg-
 build.js:231:9)
 }}}

 **Fix:**

 Let `fs.cpSync` handle the entire recursive copy.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/64559>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list