Skip to content

Non-literal list concatenation and sorting: TypeError: t.py_sort is not a function #679

Description

@darthglowball

Hi,

sorting a non-literal concatenated list causes the error: TypeError: t.py_sort is not a function. While the lists are literals, the concatenation is done by variables and the plus operator.

a = [5,6,7]
b = [8,9,10]
t = a + b
t.sort()
print(t)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions