Skip to content
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

chore: suppress a Node.js deprecation warning #16398

Merged
merged 1 commit into from Oct 10, 2022

Commits on Oct 10, 2022

  1. chore: suppress a Node.js deprecation warning

    Follow up nodejs/node#37302.
    
    This PR suppress the following Node.js warning.
    
    ```console
    % node -v
    v18.10.0
    % cd path/to/eslint
    % node Makefile mocha
    Running unit tests
    (snip)
    
    (node:63796) [DEP0147] DeprecationWarning: In future versions of Node.js,
    fs.rmdir(path, { recursive: true }) will be removed. Use fs.rm(path, { recursive: true }) instead
    (Use `node --trace-deprecation ...` to show where the warning was created)
    ```
    
    And added compatibility condition to prevent the following error when using Node.js 14.13.1 or lower.
    
    ```console
    % node -v
    v14.13.1
    % npx mocha tests/lib/eslint/flat-eslint.js
    (snip)
    
    1) FlatESLint
         lintFiles()
           multiple processors
             "after each" hook for "should lint only JavaScript blocks.":
         TypeError: fsp.rm is not a function
    ```
    koic committed Oct 10, 2022
    Copy the full SHA
    6eae511 View commit details
    Browse the repository at this point in the history