GDQuest / GDQuest/GDScript-formatter

Godot addon: Linter: The background color of linted lines disappear if the script is edited

Ouverte
#202 3 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
help wanted
Langage dominant
Rust
Étoiles
455
Forks
39
Merge moyen
1 j 15 h
PR mergées (30 j)
4

Description

## Description
- Using GDScript formatter 0.18.2 with Godot 4.6 on Windows
- On linting a file, problematic lines are colored in red or yellow to indicate a linter error or warning. These colors disappear within 1-2 seconds of editing the script in Godot script editor (even without saving the file).

## Reproduce
- Write a script with a linter issue :
```gdscript
func _init() -> void:
print("hello")
pass # <- this produces a linter warning (unnecessary-pass)
```
- Lint it (Ctrl+S or Format > Lint Current Script). The `pass` line is now colored in yellow.
- Edit it (you can just add a new line, or edit the comment).

## Expected behaviour
- The `pass` line coloration do not change.

## Observed behaviour
- The `pass` line coloration disappear after 1-2 seconds.

## Additional informations
This behaviour can be indirectly triggered by saving the script, because saving the script can trigger the formatting and edit the script.

Also: Godot seems to redraw the script editor if the script is edited, then left unedited for 1-2 seconds. I believe this is the cause of this behaviour.

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Piste de recherche

Reproduisez le problème dans Godot 4.6 avec GDScript formatter 0.18.2 en faisant le linting d’un script dans l’éditeur de scripts de Godot, en le modifiant, puis en attendant le redessin. Suivez le comportement de la mise en évidence du lint autour du point d’entrée Format > Lint Current Script ; c’est terminé lorsque les couleurs de lint rouge et jaune restent visibles après la modification et le redessin différé.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
godot, rust
Domaine
tooling
Type d'issue
Bug
Difficulté
4/5
Temps estimé
3-5 jours
Activité
À l'abandon
Clarté
Plutôt claire
Accessibilité débutants
42/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.