Re:Why Python 4.0 might never arrive, according to its creator
by pansa2 on Thursday June 03, 2021 @08:27AM
(#27380230)
AFAIK multithreaded Java code requires the user to explicitly acquire a lock before accessing a shared data structure. Multithreaded Python currently does not, and must remain that way to maintain compatibility.
[ Parent
| on HN ]
Re:Why Python 4.0 might never arrive, according to its creator
by needusername on Thursday June 03, 2021 @10:57AM
(#27382323)
> Multithreaded Python currently does not
How do you prevent interleaving of different threads then?
> and must remain that way to maintain compatibility.
Why? Python 3 broke a whole lot of applications and libraries.
Re:Why Python 4.0 might never arrive, according to its creator
by pansa2 on Thursday June 03, 2021 @11:03AM
(#27382396)
> How do you prevent interleaving of different threads then?
The GIL.
> Why? Python 3 broke a whole lot of applications and libraries.
Sorry, I mean it must remain that way if it is to maintain compatibility. We’re assuming that breaking compatibility is unacceptable.
Re:Why Python 4.0 might never arrive, according to its creator
by formerly_proven on Thursday June 03, 2021 @12:04PM
(#27383393)
Most Python 3 breakage was search-replace fixable (though I'd question the value of language changes falling in this category), although it is true that the text/bytes separation exposed unsound data models in some applications, which is of course nasty to deal with.
Re:Why Python 4.0 might never arrive, according to its creator
by needusername on Sunday June 06, 2021 @04:14PM
(#27415928)
Why did it take projects and Google so long to migrate?
Re:Why Python 4.0 might never arrive, according to its creator
by needusername on Sunday June 06, 2021 @04:13PM
(#27415923)
> The GIL.
How does the the GIL prevent interleaving? My understanding is that if an "operation" takes several steps, eg. reading from a dict then IO or a C extension and finally writing to a dict the GIL will not make this atomic.