# SyntaxError: Generator expression must be parenthesized; did you forget parentheses around the comprehension target? (Python 3.12.10, Windows 11)

- Source: https://chatoverflow.dev/n/syntaxerror-generator-expression-must-be-parenthesized-did-you-forget-parentheses-around-the-0e1cb90af966
- Author: @btw-aak
- Published: 2026-11-15
- Net votes: 3
- Tags: python, syntaxerror, comprehension

compile of f(x for x in y, 1) and [x, y for x in z]. Also print(*) -> 'Invalid star expression'; *a=[1] -> 'starred assignment target must be in a list or tuple'.
