---
source: crates/ruff_linter/src/rules/pycodestyle/mod.rs
---
E211 [*] Whitespace before '('
 --> E21.py:2:5
  |
1 | #: E211
2 | spam (1)
  |     ^
3 | #: E211 E211
4 | dict ['key'] = list [index]
  |
help: Removed whitespace before '('
  |
1 | #: E211
  - spam (1)
2 + spam(1)
3 | #: E211 E211
  |

E211 [*] Whitespace before '['
 --> E21.py:4:5
  |
2 | spam (1)
3 | #: E211 E211
4 | dict ['key'] = list [index]
  |     ^
5 | #: E211
6 | dict['key'] ['subkey'] = list[index]
  |
help: Removed whitespace before '['
  |
3 | #: E211 E211
  - dict ['key'] = list [index]
4 + dict['key'] = list [index]
5 | #: E211
  |

E211 [*] Whitespace before '['
 --> E21.py:4:20
  |
2 | spam (1)
3 | #: E211 E211
4 | dict ['key'] = list [index]
  |                    ^
5 | #: E211
6 | dict['key'] ['subkey'] = list[index]
  |
help: Removed whitespace before '['
  |
3 | #: E211 E211
  - dict ['key'] = list [index]
4 + dict ['key'] = list[index]
5 | #: E211
  |

E211 [*] Whitespace before '['
 --> E21.py:6:12
  |
4 | dict ['key'] = list [index]
5 | #: E211
6 | dict['key'] ['subkey'] = list[index]
  |            ^
7 | #: Okay
8 | spam(1)
  |
help: Removed whitespace before '['
  |
5 | #: E211
  - dict['key'] ['subkey'] = list[index]
6 + dict['key']['subkey'] = list[index]
7 | #: Okay
  |

E211 [*] Whitespace before '('
  --> E21.py:17:15
   |
17 | def fetch_name () -> Union[str, None]:
   |               ^
18 |     """Fetch name from --person-name in sys.argv.
   |
help: Removed whitespace before '('
   |
16 |
   - def fetch_name () -> Union[str, None]:
17 + def fetch_name() -> Union[str, None]:
18 |     """Fetch name from --person-name in sys.argv.
   |

E211 [*] Whitespace before '('
  --> E21.py:27:19
   |
25 |     # test commented code
26 |     # Logger.info("test code")
27 |     for i in range (0, len (sys.argv)) :
   |                   ^
28 |         if sys.argv[i] == "--name" :
29 |             return sys.argv[i + 1]
   |
help: Removed whitespace before '('
   |
26 |     # Logger.info("test code")
   -     for i in range (0, len (sys.argv)) :
27 +     for i in range(0, len (sys.argv)) :
28 |         if sys.argv[i] == "--name" :
   |

E211 [*] Whitespace before '('
  --> E21.py:27:27
   |
25 |     # test commented code
26 |     # Logger.info("test code")
27 |     for i in range (0, len (sys.argv)) :
   |                           ^
28 |         if sys.argv[i] == "--name" :
29 |             return sys.argv[i + 1]
   |
help: Removed whitespace before '('
   |
26 |     # Logger.info("test code")
   -     for i in range (0, len (sys.argv)) :
27 +     for i in range (0, len(sys.argv)) :
28 |         if sys.argv[i] == "--name" :
   |
