You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2009-05-01.06:31:53.187>created_at=<Date2009-05-01.04:51:57.351>labels= ['invalid']
title='strange list.sort() behavior on import, del and inport again'updated_at=<Date2009-05-01.06:31:53.158>user='https://bugs.python.org/dstemmer'
Given two modules, I've seen the following kind of strange behavior with
list sorting on import and delete; a list that has been imported, sorted
and deleted remains sorted on a second import:
That is not a bug in Python. The import statement merely adds a
reference to the list into your module, so both variables point to the
very same list (my_module.some_list is other_module.some_list).
Therefore, any changes made to the list through my_module will also
affect the list as seen from other_module.
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: