Skip to content

Commit

Permalink
ignore options from v6 config files
Browse files Browse the repository at this point in the history
  • Loading branch information
totaam committed Mar 9, 2024
1 parent c476030 commit 1ec821e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions xpra/scripts/config.py
Expand Up @@ -1177,6 +1177,9 @@ def get_defaults():
NO_FILE_OPTIONS = ("daemon", )


IGNORE_COMPAT_OPTIONS = ("audio", "video", )


TRUE_OPTIONS : Tuple[Any, ...] = ("yes", "true", "1", "on", True)
FALSE_OPTIONS : Tuple[Any, ...] = ("no", "false", "0", "off", False)
ALL_BOOLEAN_OPTIONS : Tuple[Any, ...] = tuple(list(TRUE_OPTIONS)+list(FALSE_OPTIONS))
Expand Down Expand Up @@ -1290,6 +1293,8 @@ def do_validate_config(d:Dict, discard, extras_types:Dict, extras_validation:Dic
continue
vt = option_types.get(k)
if vt is None:
if vt in IGNORE_COMPAT_OPTIONS:
continue
warn(f"Warning: invalid option: {k!r}")
continue
if vt==str:
Expand Down

0 comments on commit 1ec821e

Please sign in to comment.