Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

disable_split_list_with_comment not recognized #1240

Open
kschutter opened this issue Sep 28, 2024 · 2 comments
Open

disable_split_list_with_comment not recognized #1240

kschutter opened this issue Sep 28, 2024 · 2 comments

Comments

@kschutter
Copy link

When I try to add the new flag, yapf output contains this:
2024-09-28 10:23:26.576 [info] yapf: Unknown style option "DISABLE_SPLIT_LIST_WITH_COMMENT"
I'm using the vscode extension set to auto-update

@kschutter
Copy link
Author

kschutter commented Sep 28, 2024

Here is my args list:

"yapf.args": [
        "--style",
        "{column_limit: 88, 
BLANK_LINE_BEFORE_NESTED_CLASS_OR_DEF: False, 
INDENT_BLANK_LINES: True, 
SPACES_BEFORE_COMMENT: 2, 
SPLIT_BEFORE_DICT_SET_GENERATOR: True, 
SPLIT_BEFORE_DOT: True, 
SPLIT_ALL_COMMA_SEPARATED_VALUES: False,  EACH_DICT_ENTRY_ON_SEPARATE_LINE: False, ALLOW_SPLIT_BEFORE_DICT_VALUE: False, 
INDENT_DICTIONARY_VALUE: True, 
INDENT_BLANK_LINES: True, 
JOIN_MULTIPLE_LINES: True, SPACE_BETWEEN_ENDING_COMMA_AND_CLOSING_BRACKET: True, SPLIT_BEFORE_BITWISE_OPERATOR: False, DISABLE_SPLIT_LIST_WITH_COMMENT: False}"
    ]```

@Bobo8
Copy link

Bobo8 commented Dec 17, 2024

Same problem, Visual studio code updated with eeyore yapf extension and yapf installed (as library).
This option blocked your formatter completely

[style]
based_on_style = pep8
column_limit = 100
USE_TABS = false
coalesce_brackets = true
INDENT_CLOSING_BRACKETS = true
split_before_logical_operator = true
DISABLE_SPLIT_LIST_WITH_COMMENT = true
JOIN_MULTIPLE_LINES = true
allow_multiline_lambdas = true
blank_line_before_nested_class_or_def = false
BLANK_LINES_AROUND_TOP_LEVEL_DEFINITION = 1
BLANK_LINES_BETWEEN_TOP_LEVEL_IMPORTS_AND_VARIABLES = 0

user settings
"[python]": {
"editor.defaultFormatter": "eeyore.yapf",
"editor.formatOnSave": true,
"editor.formatOnSaveMode": "file",
"editor.formatOnType": false
},

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

No branches or pull requests

2 participants