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
Copy file name to clipboardExpand all lines: content/posts/language-summit-2026-free-threading-post-era/index.md
+39-1Lines changed: 39 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,8 +61,46 @@ Providing a scheduler with a program written with the above constraints gets you
61
61
62
62
Some examples of programs written using locks and threads were then transformed into programs using the BOC model, such as two bank accounts transferring money between them and printing the results:
63
63
64
-
There are [many more examples available on GitHub](https://github.com/microsoft/bocpy/tree/main/examples). This proof of concept, implemented using subinterpreters, is available for anyone to try: [bocpy](https://microsoft.github.io/bocpy), available on the [Python Package Index](https://pypi.org/project/bocpy):
64
+
```python
65
+
from bocpy import Cown, wait, when
66
+
67
+
classAccount:
68
+
def__init__(self, name: str, balance: float):
69
+
"""Initialize an account with a starting balance."""
70
+
self.name = name
71
+
self.balance = balance
72
+
73
+
def__repr__(self) -> str:
74
+
"""Return a readable representation for debugging."""
There are [many more examples available on GitHub](https://github.com/microsoft/bocpy/tree/main/examples). This proof of concept, implemented using subinterpreters, is available for anyone to try: [bocpy](https://microsoft.github.io/bocpy), available on the [Python Package Index](https://pypi.org/project/bocpy):
66
104
67
105
Checking bocpy against their own criteria of simplicity, safety, and performance: bocpy is simple, as can be seen in the above examples. On the safety front, bocpy today runs in “stable Python”, and for this reason only isolation has been implemented so far. “We don’t yet have ownership, you can’t implement [ownership] as a third-party library”, as this would require changes to the runtime. Performance is “good for programs that aren’t communication dominated” due to “communication being expensive for subinterpreters”.
Copy file name to clipboardExpand all lines: content/posts/language-summit-2026-namespaces/index.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,6 +19,7 @@ Steering Council member and Release Manager Pablo Galindo Salgado opened the Lan
19
19
20
20
The issue manifests as seemingly random `AttributeError` exceptions from modules like `json`, `math`, or `http` for names you know are correct. Why is the standard library suddenly raising errors?
21
21
22
+
```console
22
23
$ cat game.py
23
24
import random
24
25
if int(input("Pick a number 1-10")) == random.randint(1, 10):
@@ -32,6 +33,7 @@ AttributeError: module 'random' has no attribute 'randint' (???)
32
33
33
34
The issue is usually that a module is “shadowing” the standard library module from a higher-precedence location in `sys.path`, such as your current working directory or a directory on `PYTHONPATH`. There is probably a file named `json.py` or `math.py` in your project, and that module takes precedence over the standard library module of the same name, which is only noticed once you start using the module elsewhere in your project.
0 commit comments