Skip to content

The "list[2]" argument must be an instance of Buffer or Uint8Array. Received type string ('fileName #60559

@mcz-adhamsabry

Description

@mcz-adhamsabry

Version

v22.21.0

Platform

rmSync and removeSync fail to delete directories and I get the error below:

The "list[2]" argument must be an instance of Buffer or Uint8Array. Received type string ('fileName

You can reproduce it by deleting `node_modules` directory using either method.

Subsystem

macos

What steps will reproduce the bug?

Use the method to delete node_modules directory that would contain .bin folder as an example. and the function will fail with the given error above.

How often does it reproduce? Is there a required condition?

All the time

What is the expected behavior? Why is that the expected behavior?

delete should be successful, the error is misleading

What do you see instead?

The "list[2]" argument must be an instance of Buffer or Uint8Array. Received type string ('fileName

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions