RobertCraigie / RobertCraigie/pyright-python

Add ability to silence node install logs

Open
#358 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
277
Forks
31
Avg merge
4h 22m
Merged PRs (30d)
3

Description

First time you install pyright it dumps logs in the console that you can't seem to get rid off.

{'x86': False, 'risc': False, 'lts': False}                                                                                                                                                                                                                                        
 * Install prebuilt node (25.5.0) ../root/.local/share/uv/tools/pyright/lib/python3.13/site-packages/nodeenv.py:639: DeprecationWarning: Python 3.14 will, by default, filter extracted tar archives and reject files or modify their metadata. Use the filter argument to control 
this behavior.                                                                                                                                                                                                                                                                     
  archive.extractall(src_dir, extract_list)                                                                                                                                                                                                                                        
... done. 

Since pyright only allows outputting json to the console and not a file, this means that pyright --outputjson > file.json contains broken json.

{'x86': False, 'risc': False, 'lts': False}
{
    "version": "1.1.408",
    "time": "1769610014442",
    "generalDiagnostics": [],
    "summary": {
        "filesAnalyzed": 86,
        "errorCount": 0,
        "warningCount": 0,
        "informationCount": 0,
        "timeInSec": 5.462
    }
}

Either allow us to disable all node related logs, or output to an actual json file.

Real world use case in CI pipelines:

uvx pyright --outputjson > pyright-raw-report.json

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the first-install path triggered by uvx pyright and the pyright --outputjson entry point; inspect how node installation output reaches stdout. Reproduce the CI command from the issue and consider the work done when the generated JSON file contains only valid JSON without node-install logs, or when those logs can be disabled.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, python
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.