Opened 9 years ago

Closed 8 years ago

#15988 closed enhancement (fixed)

Python 3 preparation: Add missing parentheses in list comprension

Reported by: Wilfried Luebbe Owned by:
Priority: major Milestone: sage-6.2
Component: distribution Keywords: python3
Cc: Merged in:
Authors: Wilfried Luebbe Reviewers: Travis Scrimshaw
Report Upstream: N/A Work issues:
Branch: 9e13542 (Commits, GitHub, GitLab) Commit: 9e13542f08d1ced28e74a80fe8152f5485a22b4a
Dependencies: Stopgaps:

Status badges


Python 3 has stricter requirements for parentheses around tuples in list comprehension.

Changes according to lib2to3/fixes/

e.g. converts ``[x for x in 1, 2]`` to ``[x for x in (1, 2)]``

This ticket is tracked as a dependency of meta-ticket ticket:15980.

Change History (3)

comment:1 Changed 9 years ago by Wilfried Luebbe

Branch: u/wluebbe/ticket/15988
Commit: 9e13542f08d1ced28e74a80fe8152f5485a22b4a
Status: newneeds_review
./sage -t -p --all --long --logfile=logs/ptestlong-15988.log
All tests passed!

New commits:

9e13542add missing parenthesis in 2 modules for Python 3 compatibility

comment:2 Changed 8 years ago by Travis Scrimshaw

Authors: Wilfried Luebbe
Reviewers: Travis Scrimshaw
Status: needs_reviewpositive_review


comment:3 Changed 8 years ago by Volker Braun

Branch: u/wluebbe/ticket/159889e13542f08d1ced28e74a80fe8152f5485a22b4a
Resolution: fixed
Status: positive_reviewclosed
Note: See TracTickets for help on using tickets.