All patches and comments are welcome. Please squash your changes to logical
commits before using git-format-patch and git-send-email to
patches@git.madduck.net.
If you'd read over the Git project's submission guidelines and adhered to them,
I'd be especially grateful.
2 +++ <stdin> (formatted)
18 ~int and not v1 ^ 123 + v2 | True
19 (~int) and (not ((v1 ^ (123 + v2)) | True))
20 -flags & ~ select.EPOLLIN and waiters.write_task is not None
21 +flags & ~select.EPOLLIN and waiters.write_task is not None
24 lambda a, b, c=True: a
25 -lambda a, b, c=True, *, d=(1 << v2), e='str': a
26 -lambda a, b, c=True, *vararg, d=(v1 << 2), e='str', **kwargs: a + b
27 +lambda a, b, c=True, *, d=(1 << v2), e="str": a
28 +lambda a, b, c=True, *vararg, d=(v1 << 2), e="str", **kwargs: a + b
30 str or None if True else str or bytes or None
31 (str or None) if True else (str or bytes or None)
32 str or None if (1 if True else 2) else str or bytes or None
33 (str or None) if (1 if True else 2) else (str or bytes or None)
34 -{'2.7': dead, '3.7': (long_live or die_hard)}
35 -{'2.7': dead, '3.7': (long_live or die_hard), **{'3.6': verygood}}
36 +{"2.7": dead, "3.7": (long_live or die_hard)}
37 +{"2.7": dead, "3.7": (long_live or die_hard), **{"3.6": verygood}}
39 -{'2.7', '3.6', '3.7', '3.8', '3.9', ('4.0' if gilectomy else '3.10')}
40 -({'a': 'b'}, (True or False), (+value), 'string', b'bytes') or None
41 +{"2.7", "3.6", "3.7", "3.8", "3.9", ("4.0" if gilectomy else "3.10")}
42 +({"a": "b"}, (True or False), (+value), "string", b"bytes") or None
48 [1, 2, 3, 4, 5, 6, 7, 8, 9, (10 or A), (11 or B), (12 or C)]
55 -[this_is_a_very_long_variable_which_will_force_a_delimiter_split, element, another, *more]
59 + this_is_a_very_long_variable_which_will_force_a_delimiter_split,
64 {i for i in (1, 2, 3)}
65 {(i ** 2) for i in (1, 2, 3)}
66 -{(i ** 2) for i, _ in ((1, 'a'), (2, 'b'), (3, 'c'))}
67 +{(i ** 2) for i, _ in ((1, "a"), (2, "b"), (3, "c"))}
68 {((i ** 2) + j) for i in (1, 2, 3) for j in (1, 2, 3)}
69 [i for i in (1, 2, 3)]
70 [(i ** 2) for i in (1, 2, 3)]
71 -[(i ** 2) for i, _ in ((1, 'a'), (2, 'b'), (3, 'c'))]
72 +[(i ** 2) for i, _ in ((1, "a"), (2, "b"), (3, "c"))]
73 [((i ** 2) + j) for i in (1, 2, 3) for j in (1, 2, 3)]
74 {i: 0 for i in (1, 2, 3)}
75 -{i: j for i, j in ((1, 'a'), (2, 'b'), (3, 'c'))}
76 +{i: j for i, j in ((1, "a"), (2, "b"), (3, "c"))}
77 {a: b * 2 for a, b in dictionary.items()}
78 {a: b * -2 for a, b in dictionary.items()}
79 -{k: v for k, v in this_is_a_very_long_variable_which_will_cause_a_trailing_comma_which_breaks_the_comprehension}
82 + for k, v in this_is_a_very_long_variable_which_will_cause_a_trailing_comma_which_breaks_the_comprehension
84 Python3 > Python2 > COBOL
89 -call(arg, kwarg='hey')
90 -call(arg, another, kwarg='hey', **kwargs)
91 -call(this_is_a_very_long_variable_which_will_force_a_delimiter_split, arg, another, kwarg='hey', **kwargs) # note: no trailing comma pre-3.6
93 +call(arg, kwarg="hey")
94 +call(arg, another, kwarg="hey", **kwargs)
96 + this_is_a_very_long_variable_which_will_force_a_delimiter_split,
101 +) # note: no trailing comma pre-3.6
103 call(a, *gidgets[:2])
104 call(**self.screen_kwargs)
105 call(b, **self.screen_kwargs)
113 -tuple[str, int, float, dict[str, int],]
114 +tuple[str, int, float, dict[str, int]]
115 very_long_variable_name_filters: t.List[
116 t.Tuple[str, t.Union[str, t.List[t.Optional[str]]]],
120 @@ -121,85 +135,119 @@
125 (str or None) if (sys.version_info[0] > (3,)) else (str or bytes or None)
126 -{'2.7': dead, '3.7': long_live or die_hard}
127 -{'2.7', '3.6', '3.7', '3.8', '3.9', '4.0' if gilectomy else '3.10'}
128 +{"2.7": dead, "3.7": long_live or die_hard}
129 +{"2.7", "3.6", "3.7", "3.8", "3.9", "4.0" if gilectomy else "3.10"}
130 [1, 2, 3, 4, 5, 6, 7, 8, 9, 10 or A, 11 or B, 12 or C]
134 (i for i in (1, 2, 3))
135 ((i ** 2) for i in (1, 2, 3))
136 -((i ** 2) for i, _ in ((1, 'a'), (2, 'b'), (3, 'c')))
137 +((i ** 2) for i, _ in ((1, "a"), (2, "b"), (3, "c")))
138 (((i ** 2) + j) for i in (1, 2, 3) for j in (1, 2, 3))
140 -{"id": "1","type": "type","started_at": now(),"ended_at": now() + timedelta(days=10),"priority": 1,"import_session_id": 1,**kwargs}
144 + "started_at": now(),
145 + "ended_at": now() + timedelta(days=10),
147 + "import_session_id": 1,
155 -what_is_up_with_those_new_coord_names = (coord_names + set(vars_to_create)) + set(vars_to_remove)
156 -what_is_up_with_those_new_coord_names = (coord_names | set(vars_to_create)) - set(vars_to_remove)
157 -result = session.query(models.Customer.id).filter(models.Customer.account_id == account_id, models.Customer.email == email_address).order_by(models.Customer.id.asc(),).all()
158 +what_is_up_with_those_new_coord_names = (coord_names + set(vars_to_create)) + set(
161 +what_is_up_with_those_new_coord_names = (coord_names | set(vars_to_create)) - set(
164 +result = session.query(models.Customer.id).filter(
165 + models.Customer.account_id == account_id, models.Customer.email == email_address
167 + models.Customer.id.asc()
170 authors.łukasz.say_thanks()
172 A: 0.25 * (10.0 / 12),
173 B: 0.1 * (10.0 / 12),
174 C: 0.1 * (10.0 / 12),
175 D: 0.1 * (10.0 / 12),
180 yield from outside_of_generator
186 await some.complicated[0].call(with_args=(True or (1 is not 1)))
187 -for x, in (1,), (2,), (3,): ...
189 -for z in (i for i in (1, 2, 3)): ...
190 -for i in (call()): ...
191 -for j in (1 + (2 + 3)): ...
192 -while(this and that): ...
194 - threading.current_thread() != threading.main_thread() and
195 - threading.current_thread() != threading.main_thread() or
196 - signal.getsignal(signal.SIGINT) != signal.default_int_handler
200 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa |
201 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
205 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa &
206 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
210 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa +
211 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
215 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa -
216 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
220 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa *
221 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
225 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa /
226 - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
231 +for (x,) in (1,), (2,), (3,):
235 +for z in (i for i in (1, 2, 3)):
239 +for j in 1 + (2 + 3):
241 +while this and that:
244 + threading.current_thread() != threading.main_thread()
245 + and threading.current_thread() != threading.main_thread()
246 + or signal.getsignal(signal.SIGINT) != signal.default_int_handler
251 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
252 + | aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
257 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
258 + & aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
263 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
264 + + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
269 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
270 + - aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
275 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
276 + * aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
281 + aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
282 + / aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
287 # standalone comment at ENDMARKER