JetBrains-Research / snakecharm

Plugin for PyCharm / IntelliJ IDEA Platform IDEs which adds support for Snakemake language.
MIT License
61 stars 7 forks source link

Fix token debug name in PyUnresolvedReferencesInspection warning: Cannot find reference 'input' in 'Py:USE_KEYWORD mod1_*' #544

Open iromeo opened 1 month ago

iromeo commented 1 month ago
image
module mod1:
    snakefile:
        "module1/Snakefile"
    prefix:
        "test/"

use rule * from mod1 as mod1_*

rule all:
    input:
        rules.mod1_all.input,
    default_target: True

and module1

def txt_output(wildcards):
    return ["results/C.txt"]

rule all:
    input:
        txt_output

rule txt:
    output:
        "results/C.txt"
    shell:
        "echo 'C' "
        ">{output} "

See usages of PyPsiBundle: INSP.unresolved.refs.cannot.find.reference.in.type

iromeo commented 1 month ago

And similar here: def in_func1(w): file = checkpoints.b2.get().output[0] return open(file, "r").read().strip()

image

P.S: in both cases unresolved error also should not be shown