Visitar URL original
Remove unnecessary pyrightconfig excludes by Akuli · Pull Request #6271 · python/typeshed · GitHub
The Wayback Machine - https://web.archive.org/web/20260329024455/https://github.com/python/typeshed/pull/6271
Skip to content

Remove unnecessary pyrightconfig excludes#6271

Merged
Akuli merged 2 commits intopython:masterfrom
Akuli:pyright-cleanup
Nov 9, 2021
Merged

Remove unnecessary pyrightconfig excludes#6271
Akuli merged 2 commits intopython:masterfrom
Akuli:pyright-cleanup

Conversation

@Akuli
Copy link
Copy Markdown
Collaborator

@Akuli Akuli commented Nov 9, 2021 •

Done with quick and dirty script, with manual cleanup afterwards:

#!/bin/bash
set -e

git checkout pyrightconfig.json
grep '        ".*/.*",' pyrightconfig.json | while read -r line; do
    cp pyrightconfig.json old.json
    python3 -c 'import sys; s=open("pyrightconfig.json").read(); open("pyrightconfig.json","w").write(s.replace(sys.argv[1],""))' "$line"
    if npx -p pyright@1.1.184 pyright -p pyrightconfig.json &>/dev/null; then
        echo "ok without:  $line"
        rm old.json
    else
        echo "need:        $line"
        mv old.json pyrightconfig.json
    fi
done

@Akuli Akuli marked this pull request as draft November 9, 2021 17:34
@Akuli Akuli marked this pull request as ready for review November 9, 2021 17:36
Copy link
Copy Markdown
Collaborator

@srittau srittau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CI still fails, but please merge when CI passes.

@Akuli Akuli merged commit 230f149 into python:master Nov 9, 2021
@Akuli Akuli deleted the pyright-cleanup branch November 9, 2021 18:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants