Design of internal channel handling can lead to strange effects

Aperta
#854 3 commenti 1 reazione 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
15/100
Tipo di issue
Refactoring
Chiarezza
Da chiarire
Stato di attività
Ferma
Stack tecnologico
python
Ambito
cli

Direzione di ricerca

The payload names no files, only the --info output, the deleteChannel function and the enable/disable channel commands. Start by reading how disabled and absent channels are stored and listed, then reproduce the case where adding a channel fails because a disabled one with that name exists. Done means a maintainer has settled whether to remove enable/disable or add an absent state, and the chosen behaviour is implemented.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Channels can be either disabled, primary or secondary. Both deleting or disabling a channel lead to the same role entry. But the latter one keeps its settings for the case the channel is reenabled.

On the other hand, --info does not show any disabled channels. This might lead to the situation (especially during testing), that the system refuses adding a channel because there is still a disabled one with this name located anywhere in the list.

It seems, that disable/enable has now been replaced by add/delete, so these command options are not very consistent any more. However, I don't know if disable/enable is still used by someone.

At least I suggest these improvements:

  1. Clarify the role of an deleted/not present channel with "absent" instead of disabled.
  2. let --info show disabled channels so we can get aware of them
  3. let deleteChannel output an additional message in case the channel to be deleted is absent. Deleting a channel then also will delete disabled channels.

The best would be to remove the enable/disable commands.
What do you think about it?

Lingua principale
Python
Stelle
855
Fork
355
Merge medio
3g 3h
PR unite (30g)
12

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di meshtastic/python

Tutte le issue di meshtastic/python

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.