<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="../assets/xml/rss.xsl" media="all"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>PyPy (Posts by mattip)</title><link>https://www.pypy.org/</link><description></description><atom:link href="https://www.pypy.org/authors/mattip.xml" rel="self" type="application/rss+xml"></atom:link><language>en</language><copyright>Contents © 2026 &lt;a href="mailto:pypy-dev@pypy.org"&gt;The PyPy Team&lt;/a&gt; </copyright><lastBuildDate>Wed, 27 May 2026 07:20:48 GMT</lastBuildDate><generator>Nikola (getnikola.com)</generator><docs>http://blogs.law.harvard.edu/tech/rss</docs><item><title>PyPy v7.3.23 release</title><link>https://www.pypy.org/posts/2026/05/pypy-v7322-release.html</link><dc:creator>mattip</dc:creator><description>&lt;section id="pypy-v7-3-23-release-of-python-2-7-3-11"&gt;
&lt;h2&gt;PyPy v7.3.23: release of python 2.7, 3.11&lt;/h2&gt;
&lt;p&gt;The PyPy team is proud to release version 7.3.23 of PyPy after the previous
release on April 26, 2026. This is a bug-fix release that fixes an overeager
warning about unused coroutines, and some problems around multiple inheritance
in c-extensions.&lt;/p&gt;
&lt;p&gt;This version includes a change to the bytecode interpreter to use &lt;a class="reference external" href="https://github.com/python/cpython/blob/main/InternalDocs/exception_handling.md"&gt;exception tables&lt;/a&gt;
instead of dedicated opcodes. Now the PyPy disassembly will be closer to
CPython format. So far it does not impact performance.&lt;/p&gt;
&lt;p&gt;The release includes two different interpreters:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;PyPy2.7, which is an interpreter supporting the syntax and the features of
Python 2.7 including the stdlib for CPython 2.7.18+ (the &lt;code class="docutils literal"&gt;+&lt;/code&gt; is for
backported security updates)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.11, which is an interpreter supporting the syntax and the features of
Python 3.11, including the stdlib for CPython 3.11.15.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The interpreters are based on much the same codebase, thus the double
release. This is a micro release, all APIs are compatible with the other 7.3
releases.&lt;/p&gt;
&lt;p&gt;We recommend updating. You can find links to download the releases here:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a class="reference external" href="https://pypy.org/download.html"&gt;https://pypy.org/download.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We would like to thank our donors for the continued support of the PyPy
project. If PyPy is not quite good enough for your needs, we are available for
&lt;a class="reference external" href="https://www.pypy.org/pypy-sponsors.html"&gt;direct consulting&lt;/a&gt; work. If PyPy is helping you out, we would love to hear
about it and encourage submissions to our &lt;a class="reference external" href="https://pypy.org/blog"&gt;blog&lt;/a&gt; via a pull request
to &lt;a class="reference external" href="https://github.com/pypy/pypy.org"&gt;https://github.com/pypy/pypy.org&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We would also like to thank our contributors and encourage new people to join
the project. PyPy has many layers and we need help with all of them: bug fixes,
&lt;a class="reference external" href="https://doc.pypy.org/"&gt;PyPy&lt;/a&gt; and &lt;a class="reference external" href="https://rpython.readthedocs.org"&gt;RPython&lt;/a&gt; documentation improvements, or general &lt;a class="reference external" href="https://doc.pypy.org/project-ideas.html"&gt;help&lt;/a&gt; with
making RPython's JIT even better.&lt;/p&gt;
&lt;p&gt;If you are a python library maintainer and use C-extensions, please consider
making a &lt;a class="reference external" href="https://hpyproject.org/"&gt;HPy&lt;/a&gt; / &lt;a class="reference external" href="https://cffi.readthedocs.io"&gt;CFFI&lt;/a&gt; / &lt;a class="reference external" href="https://cppyy.readthedocs.io"&gt;cppyy&lt;/a&gt; version of your library that would be performant
on PyPy. In any case, &lt;a class="reference external" href="https://github.com/joerick/cibuildwheel"&gt;cibuildwheel&lt;/a&gt; supports building wheels for PyPy.&lt;/p&gt;
&lt;section id="what-is-pypy"&gt;
&lt;h3&gt;What is PyPy?&lt;/h3&gt;
&lt;p&gt;PyPy is a Python interpreter, a drop-in replacement for CPython.
It's fast (&lt;a class="reference external" href="https://speed.pypy.org"&gt;PyPy and CPython&lt;/a&gt; performance
comparison) due to its integrated tracing JIT compiler.&lt;/p&gt;
&lt;p&gt;We also welcome developers of other &lt;a class="reference external" href="https://rpython.readthedocs.io/en/latest/examples.html"&gt;dynamic languages&lt;/a&gt; to see what RPython
can do for them.&lt;/p&gt;
&lt;p&gt;We provide binary builds for:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;x86&lt;/strong&gt; machines on most common operating systems
(Linux 32/64 bits, Mac OS 64 bits, Windows 64 bits)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;64-bit &lt;strong&gt;ARM&lt;/strong&gt; machines running Linux (&lt;code class="docutils literal"&gt;aarch64&lt;/code&gt;) and macos (&lt;code class="docutils literal"&gt;macos_arm64&lt;/code&gt;).&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;PyPy supports Windows 32-bit, Linux PPC64 big- and little-endian, Linux ARM
32 bit, RISC-V RV64IMAFD Linux, and s390x Linux but does not release binaries.
Please reach out to us if you wish to sponsor binary releases for those
platforms. Downstream packagers provide binary builds for debian, Fedora,
conda, OpenBSD, FreeBSD, Gentoo, and more.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="what-else-is-new"&gt;
&lt;h3&gt;What else is new?&lt;/h3&gt;
&lt;p&gt;For more information about the 7.3.23 release, see the &lt;a class="reference external" href="https://doc.pypy.org/en/latest/release-v7.3.23.html#changelog"&gt;full changelog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Please update, and continue to help us make pypy better.&lt;/p&gt;
&lt;p&gt;Cheers,
The PyPy Team&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;</description><category>release</category><guid>https://www.pypy.org/posts/2026/05/pypy-v7322-release.html</guid><pubDate>Wed, 27 May 2026 10:00:00 GMT</pubDate></item><item><title>PyPy v7.3.22 release</title><link>https://www.pypy.org/posts/2026/04/pypy-v7322-release.html</link><dc:creator>mattip</dc:creator><description>&lt;section id="pypy-v7-3-22-release-of-python-2-7-3-11"&gt;
&lt;h2&gt;PyPy v7.3.22: release of python 2.7, 3.11&lt;/h2&gt;
&lt;p&gt;The PyPy team is proud to release version 7.3.22 of PyPy after the previous
release on March 13, 2026. This is a bug-fix release that fixes several issues
in the JIT. Among them, a long-standing JIT bug that started appearing when
some instance optimizations exposed it. We also cleaned
up many of the remaining stdlib test suite failures, which improves CPython
compatibility around line numbers in dis.dis, signatures and objclass
attributes for builtins, and other quality of life features.&lt;/p&gt;
&lt;p&gt;There is now an RPython &lt;code class="docutils literal"&gt;_pickle&lt;/code&gt; module that mirrors
the CPython one, greatly speeding up pickling operations. Where before PyPy was
5.7x slower than CPython on the pickle benchmark from the pyperformance
benchmark suite, now it is only 1.6x slower &lt;a class="brackets" href="https://www.pypy.org/posts/2026/04/pypy-v7322-release.html#footnote-1" id="footnote-reference-1" role="doc-noteref"&gt;&lt;span class="fn-bracket"&gt;[&lt;/span&gt;0&lt;span class="fn-bracket"&gt;]&lt;/span&gt;&lt;/a&gt;. We also added pypy
pickler extensions to dump and load lists using list strategies, and enabled
them in the &lt;code class="docutils literal"&gt;ForkingPickler&lt;/code&gt; used by multiprocessing, speeding up cases where
such objects are passed between PyPy multiprocessing instances.&lt;/p&gt;
&lt;p&gt;We also added an RPython json encoder, speeding up json_bench from being 2.6x
slower than CPython to being 0.7x (meaning faster).&lt;/p&gt;
&lt;p&gt;The release includes two different interpreters:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;PyPy2.7, which is an interpreter supporting the syntax and the features of
Python 2.7 including the stdlib for CPython 2.7.18+ (the &lt;code class="docutils literal"&gt;+&lt;/code&gt; is for
backported security updates)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.11, which is an interpreter supporting the syntax and the features of
Python 3.11, including the stdlib for CPython 3.11.15.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The interpreters are based on much the same codebase, thus the double
release. This is a micro release, all APIs are compatible with the other 7.3
releases.&lt;/p&gt;
&lt;p&gt;We recommend updating. You can find links to download the releases here:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a class="reference external" href="https://pypy.org/download.html"&gt;https://pypy.org/download.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We would like to thank our donors for the continued support of the PyPy
project. If PyPy is not quite good enough for your needs, we are available for
&lt;a class="reference external" href="https://www.pypy.org/pypy-sponsors.html"&gt;direct consulting&lt;/a&gt; work. If PyPy is helping you out, we would love to hear
about it and encourage submissions to our &lt;a class="reference external" href="https://pypy.org/blog"&gt;blog&lt;/a&gt; via a pull request
to &lt;a class="reference external" href="https://github.com/pypy/pypy.org"&gt;https://github.com/pypy/pypy.org&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We would also like to thank our contributors and encourage new people to join
the project. PyPy has many layers and we need help with all of them: bug fixes,
&lt;a class="reference external" href="https://doc.pypy.org/"&gt;PyPy&lt;/a&gt; and &lt;a class="reference external" href="https://rpython.readthedocs.org"&gt;RPython&lt;/a&gt; documentation improvements, or general &lt;a class="reference external" href="https://doc.pypy.org/en/latest/project-ideas.html"&gt;help&lt;/a&gt; with
making RPython's JIT even better.&lt;/p&gt;
&lt;p&gt;If you are a python library maintainer and use C-extensions, please consider
making a &lt;a class="reference external" href="https://hpyproject.org/"&gt;HPy&lt;/a&gt; / &lt;a class="reference external" href="https://cffi.readthedocs.io"&gt;CFFI&lt;/a&gt; / &lt;a class="reference external" href="https://cppyy.readthedocs.io"&gt;cppyy&lt;/a&gt; version of your library that would be performant
on PyPy. In any case, &lt;a class="reference external" href="https://github.com/joerick/cibuildwheel"&gt;cibuildwheel&lt;/a&gt; supports building wheels for PyPy.&lt;/p&gt;
&lt;p class="rubric"&gt;Footnotes&lt;/p&gt;
&lt;aside class="footnote-list brackets"&gt;
&lt;aside class="footnote brackets" id="footnote-1" role="doc-footnote"&gt;
&lt;span class="label"&gt;&lt;span class="fn-bracket"&gt;[&lt;/span&gt;&lt;a role="doc-backlink" href="https://www.pypy.org/posts/2026/04/pypy-v7322-release.html#footnote-reference-1"&gt;0&lt;/a&gt;&lt;span class="fn-bracket"&gt;]&lt;/span&gt;&lt;/span&gt;
&lt;p&gt;Once &lt;a class="reference external" href="https://github.com/python/pyperformance/pull/461"&gt;a PR to pyperformance&lt;/a&gt; to use the _pickle module on PyPy is accepted&lt;/p&gt;
&lt;/aside&gt;
&lt;/aside&gt;
&lt;section id="what-is-pypy"&gt;
&lt;h3&gt;What is PyPy?&lt;/h3&gt;
&lt;p&gt;PyPy is a Python interpreter, a drop-in replacement for CPython
It's fast (&lt;a class="reference external" href="https://speed.pypy.org"&gt;PyPy and CPython&lt;/a&gt; performance
comparison) due to its integrated tracing JIT compiler.&lt;/p&gt;
&lt;p&gt;We also welcome developers of other &lt;a class="reference external" href="https://rpython.readthedocs.io/en/latest/examples.html"&gt;dynamic languages&lt;/a&gt; to see what RPython
can do for them.&lt;/p&gt;
&lt;p&gt;We provide binary builds for:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;x86&lt;/strong&gt; machines on most common operating systems
(Linux 32/64 bits, Mac OS 64 bits, Windows 64 bits)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;64-bit &lt;strong&gt;ARM&lt;/strong&gt; machines running Linux (&lt;code class="docutils literal"&gt;aarch64&lt;/code&gt;) and macos (&lt;code class="docutils literal"&gt;macos_arm64&lt;/code&gt;).&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;PyPy supports Windows 32-bit, Linux PPC64 big- and little-endian, Linux ARM
32 bit, RISC-V RV64IMAFD Linux, and s390x Linux but does not release binaries.
Please reach out to us if you wish to sponsor binary releases for those
platforms. Downstream packagers provide binary builds for debian, Fedora,
conda, OpenBSD, FreeBSD, Gentoo, and more.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="what-else-is-new"&gt;
&lt;h3&gt;What else is new?&lt;/h3&gt;
&lt;p&gt;For more information about the 7.3.22 release, see the &lt;a class="reference external" href="https://doc.pypy.org/en/latest/release-v7.3.22.html#changelog"&gt;full changelog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Please update, and continue to help us make pypy better.&lt;/p&gt;
&lt;p&gt;Cheers,
The PyPy Team&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;</description><category>release</category><guid>https://www.pypy.org/posts/2026/04/pypy-v7322-release.html</guid><pubDate>Tue, 28 Apr 2026 10:00:00 GMT</pubDate></item><item><title>Using Claude to fix PyPy3.11 test failures securely</title><link>https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html</link><dc:creator>mattip</dc:creator><description>&lt;p&gt;I got access to Claude Max for 6 months, as a promotional move Anthropic made
to Open Source Software contributors. My main OSS impact is as a maintainer for
NumPy, but I decided to see what claude-code could to for PyPy's failing 3.11
tests. Most of these failures are edge cases: error messages that differ from
CPython, or debugging tools that fail in certain cases. I was worried about
letting an AI agent loose on my development machine. I noticed &lt;a class="reference external" href="https://patrickmccanna.net/a-better-way-to-limit-claude-code-and-other-coding-agents-access-to-secrets/"&gt;a post&lt;/a&gt; by
Patrick McCanna (thanks Patrick!) that pointed to using bubblewrap to
sandbox the agent. So I set it all up and (hopefully securely) pointed
claude-code at some tests.&lt;/p&gt;
&lt;!-- TEASER_END: Read more to find out how it went --&gt;
&lt;section id="setting-up"&gt;
&lt;h2&gt;Setting up&lt;/h2&gt;
&lt;p&gt;There were a few steps to make sure I didn't open myself up to obvious gotchas.
There are stories about agents wiping out data bases, or deleting mail boxes.&lt;/p&gt;
&lt;section id="bubblewrap"&gt;
&lt;h3&gt;Bubblewrap&lt;/h3&gt;
&lt;p&gt;First I needed to see what bubblewrap does. I followed the instructions in the
blog post to set things up with some minor variations:&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code bash"&gt;&lt;a id="rest_code_9f7b257d2e1347e3a6f6bb4b1c6e6a87-1" name="rest_code_9f7b257d2e1347e3a6f6bb4b1c6e6a87-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_9f7b257d2e1347e3a6f6bb4b1c6e6a87-1"&gt;&lt;/a&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;apt&lt;span class="w"&gt; &lt;/span&gt;install&lt;span class="w"&gt; &lt;/span&gt;bubblewrap
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;I couldn't run &lt;code class="docutils literal"&gt;bwrap&lt;/code&gt;. After digging around a bit, I found I needed to add
an exception for appamor on Ubuntu 24.04:&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code bash"&gt;&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-1" name="rest_code_2897580850f6408fb4b4b399d3aab26f-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-1"&gt;&lt;/a&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;bash&lt;span class="w"&gt; &lt;/span&gt;-c&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s1"&gt;'cat &amp;gt; /etc/apparmor.d/bwrap &amp;lt;&amp;lt; EOF&lt;/span&gt;
&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-2" name="rest_code_2897580850f6408fb4b4b399d3aab26f-2" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-2"&gt;&lt;/a&gt;&lt;span class="s1"&gt;abi &amp;lt;abi/4.0&amp;gt;,&lt;/span&gt;
&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-3" name="rest_code_2897580850f6408fb4b4b399d3aab26f-3" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-3"&gt;&lt;/a&gt;&lt;span class="s1"&gt;include &amp;lt;tunables/global&amp;gt;&lt;/span&gt;
&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-4" name="rest_code_2897580850f6408fb4b4b399d3aab26f-4" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-4"&gt;&lt;/a&gt;
&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-5" name="rest_code_2897580850f6408fb4b4b399d3aab26f-5" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-5"&gt;&lt;/a&gt;&lt;span class="s1"&gt;profile bwrap /usr/bin/bwrap flags=(unconfined) {&lt;/span&gt;
&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-6" name="rest_code_2897580850f6408fb4b4b399d3aab26f-6" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-6"&gt;&lt;/a&gt;&lt;span class="s1"&gt;  userns,&lt;/span&gt;
&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-7" name="rest_code_2897580850f6408fb4b4b399d3aab26f-7" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-7"&gt;&lt;/a&gt;&lt;span class="s1"&gt;}&lt;/span&gt;
&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-8" name="rest_code_2897580850f6408fb4b4b399d3aab26f-8" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-8"&gt;&lt;/a&gt;&lt;span class="s1"&gt;EOF'&lt;/span&gt;
&lt;a id="rest_code_2897580850f6408fb4b4b399d3aab26f-9" name="rest_code_2897580850f6408fb4b4b399d3aab26f-9" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_2897580850f6408fb4b4b399d3aab26f-9"&gt;&lt;/a&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;apparmor_parser&lt;span class="w"&gt; &lt;/span&gt;-r&lt;span class="w"&gt; &lt;/span&gt;/etc/apparmor.d/bwrap
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Then &lt;code class="docutils literal"&gt;bwrap&lt;/code&gt; would run. It is all locked down by default, so I opened up some
exceptions. The arguments are pretty self-explanatory. Ubuntu spreads the
executables around the operating system, so I needed access to various
directories. I wanted a &lt;code class="docutils literal"&gt;/tmp&lt;/code&gt; for running pytest. I also wanted the prompt
to reflect the use of bubblewrap, so changed the &lt;code class="docutils literal"&gt;hostname&lt;/code&gt;:&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code bash"&gt;&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-1" name="rest_code_7355912d7284424bb2f96f24717d3cec-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-1"&gt;&lt;/a&gt;cat&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;lt;&amp;lt; 'EOL' &amp;gt;&amp;gt; ./run_bwrap.sh&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-2" name="rest_code_7355912d7284424bb2f96f24717d3cec-2" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-2"&gt;&lt;/a&gt;&lt;span class="s"&gt;  function call_bwrap() {&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-3" name="rest_code_7355912d7284424bb2f96f24717d3cec-3" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-3"&gt;&lt;/a&gt;&lt;span class="s"&gt;    bwrap \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-4" name="rest_code_7355912d7284424bb2f96f24717d3cec-4" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-4"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --ro-bind /usr /usr \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-5" name="rest_code_7355912d7284424bb2f96f24717d3cec-5" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-5"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --ro-bind /etc /etc \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-6" name="rest_code_7355912d7284424bb2f96f24717d3cec-6" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-6"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --ro-bind /run /run \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-7" name="rest_code_7355912d7284424bb2f96f24717d3cec-7" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-7"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --symlink usr/lib /lib \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-8" name="rest_code_7355912d7284424bb2f96f24717d3cec-8" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-8"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --symlink usr/lib64 /lib64 \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-9" name="rest_code_7355912d7284424bb2f96f24717d3cec-9" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-9"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --symlink usr/bin /bin \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-10" name="rest_code_7355912d7284424bb2f96f24717d3cec-10" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-10"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --proc /proc \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-11" name="rest_code_7355912d7284424bb2f96f24717d3cec-11" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-11"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --dev /dev \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-12" name="rest_code_7355912d7284424bb2f96f24717d3cec-12" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-12"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --bind $(pwd) $(pwd) \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-13" name="rest_code_7355912d7284424bb2f96f24717d3cec-13" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-13"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --chdir $(pwd) \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-14" name="rest_code_7355912d7284424bb2f96f24717d3cec-14" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-14"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --unshare-user --unshare-pid --unshare-ipc --unshare-uts --unshare-cgroup \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-15" name="rest_code_7355912d7284424bb2f96f24717d3cec-15" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-15"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --die-with-parent \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-16" name="rest_code_7355912d7284424bb2f96f24717d3cec-16" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-16"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --hostname bwrap \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-17" name="rest_code_7355912d7284424bb2f96f24717d3cec-17" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-17"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --tmpfs /tmp \&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-18" name="rest_code_7355912d7284424bb2f96f24717d3cec-18" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-18"&gt;&lt;/a&gt;&lt;span class="s"&gt;      /bin/bash "$@"&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-19" name="rest_code_7355912d7284424bb2f96f24717d3cec-19" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-19"&gt;&lt;/a&gt;&lt;span class="s"&gt;  }&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-20" name="rest_code_7355912d7284424bb2f96f24717d3cec-20" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-20"&gt;&lt;/a&gt;&lt;span class="s"&gt;EOL&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-21" name="rest_code_7355912d7284424bb2f96f24717d3cec-21" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-21"&gt;&lt;/a&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-22" name="rest_code_7355912d7284424bb2f96f24717d3cec-22" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-22"&gt;&lt;/a&gt;&lt;span class="nb"&gt;source&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;./run_bwrap.sh
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-23" name="rest_code_7355912d7284424bb2f96f24717d3cec-23" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-23"&gt;&lt;/a&gt;call_bwrap
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-24" name="rest_code_7355912d7284424bb2f96f24717d3cec-24" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-24"&gt;&lt;/a&gt;&lt;span class="c1"&gt;# now I am in a sandboxed bash shell&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-25" name="rest_code_7355912d7284424bb2f96f24717d3cec-25" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-25"&gt;&lt;/a&gt;&lt;span class="c1"&gt;# play around, try seeing other directories, getting sudo, or writing outside&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-26" name="rest_code_7355912d7284424bb2f96f24717d3cec-26" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-26"&gt;&lt;/a&gt;&lt;span class="c1"&gt;# the sandbox&lt;/span&gt;
&lt;a id="rest_code_7355912d7284424bb2f96f24717d3cec-27" name="rest_code_7355912d7284424bb2f96f24717d3cec-27" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_7355912d7284424bb2f96f24717d3cec-27"&gt;&lt;/a&gt;&lt;span class="nb"&gt;exit&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;I did not do &lt;code class="docutils literal"&gt;&lt;span class="pre"&gt;--unshare-network&lt;/span&gt;&lt;/code&gt; since, after all, I want to use claude and
that needs network access. I did add rw access to &lt;code class="docutils literal"&gt;$(pwd)&lt;/code&gt; since I want it to
edit code in the current directory, that is the whole point.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="basic-claude"&gt;
&lt;h3&gt;Basic claude&lt;/h3&gt;
&lt;p&gt;After trying out bubblewrap and convincing myself it does actually work, I
installed claude code&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code bash"&gt;&lt;a id="rest_code_e811a00875e34e678be042b06db5b9fe-1" name="rest_code_e811a00875e34e678be042b06db5b9fe-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_e811a00875e34e678be042b06db5b9fe-1"&gt;&lt;/a&gt;curl&lt;span class="w"&gt; &lt;/span&gt;-fsSL&lt;span class="w"&gt; &lt;/span&gt;https://claude.ai/install.sh&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;bash
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Really Anthropic, this is the best way to install claude? No dpkg?&lt;/p&gt;
&lt;p&gt;I ran claude once (unsafely) to get logged in. It opened a webpage, and saved
the login to the &lt;code class="docutils literal"&gt;oathAccount&lt;/code&gt; field in &lt;code class="docutils literal"&gt;&lt;span class="pre"&gt;~/.claude.json&lt;/span&gt;&lt;/code&gt;. Now I changed my
bash script to this to get claude to run inside the bubblewrap sandbox:&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code bash"&gt;&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-1" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-1"&gt;&lt;/a&gt;cat&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s"&gt;&amp;lt;&amp;lt; 'EOL' &amp;gt;&amp;gt; ./run_claude.sh&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-2" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-2" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-2"&gt;&lt;/a&gt;&lt;span class="s"&gt;  claude-safe() {&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-3" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-3" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-3"&gt;&lt;/a&gt;&lt;span class="s"&gt;    bwrap \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-4" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-4" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-4"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --ro-bind /usr /usr \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-5" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-5" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-5"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --ro-bind /etc /etc \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-6" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-6" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-6"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --ro-bind /run /run \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-7" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-7" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-7"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --ro-bind "$HOME/.local/share/claude" "$HOME/.local/share/claude" \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-8" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-8" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-8"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --symlink usr/lib /lib \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-9" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-9" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-9"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --symlink usr/lib64 /lib64 \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-10" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-10" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-10"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --symlink usr/bin /bin \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-11" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-11" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-11"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --symlink "$HOME/.local/share/claude/versions/2.1.81" "$HOME/.local/bin/claude" \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-12" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-12" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-12"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --proc /proc \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-13" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-13" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-13"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --dev /dev \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-14" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-14" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-14"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --bind $(pwd) $(pwd) \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-15" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-15" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-15"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --bind "$HOME/.claude" "$HOME/.claude" \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-16" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-16" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-16"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --bind "$HOME/.claude.json" "$HOME/.claude.json" \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-17" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-17" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-17"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --chdir $(pwd) \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-18" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-18" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-18"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --unshare-user --unshare-pid --unshare-ipc --unshare-uts --unshare-cgroup \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-19" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-19" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-19"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --die-with-parent \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-20" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-20" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-20"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --hostname bwrap \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-21" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-21" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-21"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --tmpfs /tmp \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-22" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-22" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-22"&gt;&lt;/a&gt;&lt;span class="s"&gt;      --setenv PATH "$HOME/.local/bin:$PATH" \&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-23" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-23" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-23"&gt;&lt;/a&gt;&lt;span class="s"&gt;      claude "$@"&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-24" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-24" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-24"&gt;&lt;/a&gt;&lt;span class="s"&gt;  }&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-25" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-25" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-25"&gt;&lt;/a&gt;&lt;span class="s"&gt;EOL&lt;/span&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-26" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-26" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-26"&gt;&lt;/a&gt;
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-27" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-27" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-27"&gt;&lt;/a&gt;&lt;span class="nb"&gt;source&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;./run_claude.sh
&lt;a id="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-28" name="rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-28" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b6eb07e8d1974911a7a92dbe7a4460d5-28"&gt;&lt;/a&gt;claude-safe
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Now I can use claude. Note it needs some more directories in order to run. This
script hard-codes the version, in the future YMMV. I want it to be able to look
at github, and also my local checkout of cpython so it can examine differences.
I created a read-only token by clicking on my avatar in the upper right corner
of a github we page, then going to Settings → Developer settings → Personal
access tokens → Fine-grained tokens → Generate new token. Since pypy is in the
pypy org, I used "Repository owner: pypy", "Repository access: pypy (only)" and
"Permissions: Contents". Then I made doubly sure the token permissions were
read-only. And checked again. Then I copied the token to the bash script. I
also added a &lt;code class="docutils literal"&gt;&lt;span class="pre"&gt;ro-bind&lt;/span&gt;&lt;/code&gt; to the cpython checkout, so I could tell claude code
where to look for CPython implementations of missing PyPy functionality.&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code bash"&gt;&lt;a id="rest_code_b5501b07254d49fc8239990c42feecf8-1" name="rest_code_b5501b07254d49fc8239990c42feecf8-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b5501b07254d49fc8239990c42feecf8-1"&gt;&lt;/a&gt;--ro-bind&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$HOME&lt;/span&gt;&lt;span class="s2"&gt;/oss/cpython"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$HOME&lt;/span&gt;&lt;span class="s2"&gt;/oss/cpython"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="se"&gt;\&lt;/span&gt;
&lt;a id="rest_code_b5501b07254d49fc8239990c42feecf8-2" name="rest_code_b5501b07254d49fc8239990c42feecf8-2" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_b5501b07254d49fc8239990c42feecf8-2"&gt;&lt;/a&gt;--setenv&lt;span class="w"&gt; &lt;/span&gt;GH_TOKEN&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"hah, sharing my token would not have been smart"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="se"&gt;\&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/section&gt;
&lt;section id="claude-sandbox"&gt;
&lt;h3&gt;Claude /sandbox&lt;/h3&gt;
&lt;p&gt;Claude comes with its own sandbox, configured by using the &lt;code class="docutils literal"&gt;/sandbox&lt;/code&gt; command.
I chose the defaults, which prevents malicious code in the repo from accessing
the file system and the network. I was missing some packages to get this to
work. Claude would hang until I installed them, and I needed to kill it with
&lt;code class="docutils literal"&gt;kill&lt;/code&gt;.&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code bash"&gt;&lt;a id="rest_code_c90a37aef50d4a04b5f446774817bb32-1" name="rest_code_c90a37aef50d4a04b5f446774817bb32-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_c90a37aef50d4a04b5f446774817bb32-1"&gt;&lt;/a&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;apt&lt;span class="w"&gt; &lt;/span&gt;install&lt;span class="w"&gt; &lt;/span&gt;socat
&lt;a id="rest_code_c90a37aef50d4a04b5f446774817bb32-2" name="rest_code_c90a37aef50d4a04b5f446774817bb32-2" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_c90a37aef50d4a04b5f446774817bb32-2"&gt;&lt;/a&gt;sudo&lt;span class="w"&gt; &lt;/span&gt;npm&lt;span class="w"&gt; &lt;/span&gt;install&lt;span class="w"&gt; &lt;/span&gt;-g&lt;span class="w"&gt; &lt;/span&gt;@anthropic-ai/sandbox-runtime
&lt;/pre&gt;&lt;/div&gt;
&lt;/section&gt;
&lt;section id="final-touches"&gt;
&lt;h3&gt;Final touches&lt;/h3&gt;
&lt;p&gt;One last thing that I discovered later: I needed to give claude access to some
grepping and git tools. While git should be locked down externally so it
cannot push to the repo, I do want claude to look at other issues and pull
requests in read-only mode. So I added a local &lt;code class="docutils literal"&gt;.claude/settings.json&lt;/code&gt; file
inside the repo (see below for which directory to do this):&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code json"&gt;&lt;a id="rest_code_0ace62623b2e40259686387767904a51-1" name="rest_code_0ace62623b2e40259686387767904a51-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-1"&gt;&lt;/a&gt;&lt;span class="p"&gt;{&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-2" name="rest_code_0ace62623b2e40259686387767904a51-2" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-2"&gt;&lt;/a&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="nt"&gt;"permissions"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-3" name="rest_code_0ace62623b2e40259686387767904a51-3" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-3"&gt;&lt;/a&gt;&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="nt"&gt;"allow"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-4" name="rest_code_0ace62623b2e40259686387767904a51-4" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-4"&gt;&lt;/a&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="s2"&gt;"Bash(sed*)"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-5" name="rest_code_0ace62623b2e40259686387767904a51-5" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-5"&gt;&lt;/a&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="s2"&gt;"Bash(grep*)"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-6" name="rest_code_0ace62623b2e40259686387767904a51-6" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-6"&gt;&lt;/a&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="s2"&gt;"Bash(cat*)"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-7" name="rest_code_0ace62623b2e40259686387767904a51-7" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-7"&gt;&lt;/a&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="s2"&gt;"Bash(find*)"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-8" name="rest_code_0ace62623b2e40259686387767904a51-8" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-8"&gt;&lt;/a&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="s2"&gt;"Bash(rg*)"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-9" name="rest_code_0ace62623b2e40259686387767904a51-9" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-9"&gt;&lt;/a&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="s2"&gt;"Bash(python*)"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-10" name="rest_code_0ace62623b2e40259686387767904a51-10" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-10"&gt;&lt;/a&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="s2"&gt;"Bash(pytest*)"&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-11" name="rest_code_0ace62623b2e40259686387767904a51-11" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-11"&gt;&lt;/a&gt;&lt;span class="w"&gt;    &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-12" name="rest_code_0ace62623b2e40259686387767904a51-12" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-12"&gt;&lt;/a&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;a id="rest_code_0ace62623b2e40259686387767904a51-13" name="rest_code_0ace62623b2e40259686387767904a51-13" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_0ace62623b2e40259686387767904a51-13"&gt;&lt;/a&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Then I made git ignore it, even when doing a &lt;code class="docutils literal"&gt;git clean&lt;/code&gt;, in a local (not part
of the repo) configuration&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code bash"&gt;&lt;a id="rest_code_9b91c8d2cbb64b4cb4539d7c847afd87-1" name="rest_code_9b91c8d2cbb64b4cb4539d7c847afd87-1" href="https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html#rest_code_9b91c8d2cbb64b4cb4539d7c847afd87-1"&gt;&lt;/a&gt;&lt;span class="nb"&gt;echo&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;-n&lt;span class="w"&gt; &lt;/span&gt;.claude&lt;span class="w"&gt; &lt;/span&gt;&amp;gt;&amp;gt;&lt;span class="w"&gt; &lt;/span&gt;~/.config/git/ignore
&lt;/pre&gt;&lt;/div&gt;
&lt;/section&gt;
&lt;section id="what-about-git-push"&gt;
&lt;h3&gt;What about &lt;code class="docutils literal"&gt;git push&lt;/code&gt;?&lt;/h3&gt;
&lt;p&gt;I don't want claude messing around with the upstream repo, only read access. But
I did not actively prevent &lt;code class="docutils literal"&gt;git push&lt;/code&gt;. So instead of using my actual pypy
repo, I cloned it to a separate directory and did not add a remote pointing to
github.com.&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;
&lt;section id="fixing-tests-easy"&gt;
&lt;h2&gt;Fixing tests - easy&lt;/h2&gt;
&lt;p&gt;Now that everything is set up (I hope I remembered everything), I could start
asking questions. The technique I chose was to feed claude the whole test
failure from the buildbot. So starting from the &lt;a class="reference external" href="https://buildbot.pypy.org/summary?branch=py3.11"&gt;buildbot py3.11 summary&lt;/a&gt;,
click on one of the &lt;code class="docutils literal"&gt;F&lt;/code&gt; links and copy-paste all that into the claude prompt.
It didn't take long for claude to come up with solutions for the long-standing
&lt;a class="reference external" href="https://github.com/pypy/pypy/commit/9e8e121b545dbea3f26ca436ae8a797617904306#diff-ab042b3dd16bf22b7e3d8595f182ad39d3823d76b414da7debe96081a884d16bR64-R330"&gt;ctype error missing exception&lt;/a&gt; which turned out to be due to an missing error
trap when already handling an error.&lt;/p&gt;
&lt;p&gt;Also a &lt;a class="reference external" href="https://github.com/pypy/pypy/commit/9e8e121b545dbea3f26ca436ae8a797617904306#diff-ab042b3dd16bf22b7e3d8595f182ad39d3823d76b414da7debe96081a884d16bR64-R53"&gt;CTYPES_MAX_ARGCOUNT check&lt;/a&gt; was
missing. At first, claude wanted to change the ctypes code from CPython's stdlib,
and so I had to make it clear that claude was not to touch the files in
&lt;code class="docutils literal"&gt;&lt;span class="pre"&gt;lib-python&lt;/span&gt;&lt;/code&gt;. They are copied verbatim from CPython and should not be
modified without really good reasons.&lt;/p&gt;
&lt;p&gt;The &lt;a class="reference external" href="https://github.com/pypy/pypy/commit/39ca7a1def272742e8aafd2a649ed4f8fed7038d"&gt;fix to raise&lt;/a&gt; &lt;code class="docutils literal"&gt;TypeError&lt;/code&gt; rather
than &lt;code class="docutils literal"&gt;Attribute Error&lt;/code&gt; for deleting ctype object's &lt;code class="docutils literal"&gt;value&lt;/code&gt; was maybe a little
trickier: claude needed to create its own &lt;code class="docutils literal"&gt;property&lt;/code&gt; class and use it in
assignments.&lt;/p&gt;
&lt;p&gt;The &lt;a class="reference external" href="https://github.com/pypy/pypy/commit/e0e401699c20a92d8db657879183c68ea44246b4"&gt;fix for a failing test&lt;/a&gt; for a correct &lt;code class="docutils literal"&gt;repr&lt;/code&gt; of a ctypes array was a
little more involved.  Claude needed to figure out that &lt;code class="docutils literal"&gt;newmemoryview&lt;/code&gt; was
raising an exception, dive into the RPython implementation and fix the problem,
and then also fix a pure-python &lt;code class="docutils literal"&gt;__buffer__&lt;/code&gt; shape edge case error.&lt;/p&gt;
&lt;p&gt;There were more, but you get the idea. With a little bit of coaching, and by showing
claude where the CPython implementation was, more tests are now passing.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="fixing-tests-harder"&gt;
&lt;h2&gt;Fixing tests - harder&lt;/h2&gt;
&lt;p&gt;PyPy has a HPy backend. There were some test failures that were
easy to fix (a handle not being closed, an annotation warning). But the big one
was a problem with the context tracking before and after ffi function calls. In
debug mode there is a check that the ffi call is done using the correct HPy
context. It turns out to be tricky to hang on to a reference to a context in
RPython since the context RPython object is pre-built. The solution, which took
quite a few tokens and translation cycles to work out, was to assign the
context on the C level, and have a getter to fish it out in RPython.&lt;/p&gt;
&lt;section id="conclusion"&gt;
&lt;h3&gt;Conclusion&lt;/h3&gt;
&lt;p&gt;I started this journey not more than 24 hours ago, after some successful
sessions using claude to refactor some web sites off hosting platforms and make
them static pages. I was impressed enough to try coding with it from the
terminal. It helps that I was given a generous budget to use Anthropic's tool.&lt;/p&gt;
&lt;p&gt;Claude seems capable of understanding the layers of PyPy: from the pure python
stdlib to RPython and into the small amount of C code. I even asked it to
examine a &lt;a class="reference external" href="https://github.com/pypy/pypy/issues/5398"&gt;segfault&lt;/a&gt; in the recently released PyPy7.3.21, and it seems to have
found the general area where there was a latent bug in the JIT.&lt;/p&gt;
&lt;p&gt;Like any tool, agentic programming must be used carefully to make sure it
cannot do damage. I hope I closed the most obvious foot-guns, if you have other
ideas of things I should do to protect myself while using an agent like this, I
would love to hear about them.&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;</description><category>AI</category><guid>https://www.pypy.org/posts/2026/03/using-claude-to-fix-pypy311-test-failures-securely.html</guid><pubDate>Mon, 23 Mar 2026 10:27:55 GMT</pubDate></item><item><title>PyPy v7.3.21 release</title><link>https://www.pypy.org/posts/2026/03/pypy-v7321-release.html</link><dc:creator>mattip</dc:creator><description>&lt;section id="pypy-v7-3-21-release-of-python-2-7-3-11"&gt;
&lt;h2&gt;PyPy v7.3.21: release of python 2.7, 3.11&lt;/h2&gt;
&lt;aside class="admonition warning"&gt;
&lt;p class="admonition-title"&gt;Warning&lt;/p&gt;
&lt;p&gt;This release has some known crashes. We recommend you use a different version&lt;/p&gt;
&lt;/aside&gt;
&lt;p&gt;The PyPy team is proud to release version 7.3.21 of PyPy after the previous
release on July 4, 2025. This is a bug-fix release that also updates to Python
3.11.15.&lt;/p&gt;
&lt;p&gt;The release includes two different interpreters:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;PyPy2.7, which is an interpreter supporting the syntax and the features of
Python 2.7 including the stdlib for CPython 2.7.18+ (the &lt;code class="docutils literal"&gt;+&lt;/code&gt; is for
backported security updates)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.11, which is an interpreter supporting the syntax and the features of
Python 3.11, including the stdlib for CPython 3.11.15.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The interpreters are based on much the same codebase, thus the double
release. This is a micro release, all APIs are compatible with the other 7.3
releases.&lt;/p&gt;
&lt;p&gt;We recommend updating. You can find links to download the releases here:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a class="reference external" href="https://pypy.org/download.html"&gt;https://pypy.org/download.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We would like to thank our donors for the continued support of the PyPy
project. If PyPy is not quite good enough for your needs, we are available for
&lt;a class="reference external" href="https://www.pypy.org/pypy-sponsors.html"&gt;direct consulting&lt;/a&gt; work. If PyPy is helping you out, we would love to hear
about it and encourage submissions to our &lt;a class="reference external" href="https://pypy.org/blog"&gt;blog&lt;/a&gt; via a pull request
to &lt;a class="reference external" href="https://github.com/pypy/pypy.org"&gt;https://github.com/pypy/pypy.org&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We would also like to thank our contributors and encourage new people to join
the project. PyPy has many layers and we need help with all of them: bug fixes,
&lt;a class="reference external" href="https://doc.pypy.org/"&gt;PyPy&lt;/a&gt; and &lt;a class="reference external" href="https://rpython.readthedocs.org"&gt;RPython&lt;/a&gt; documentation improvements, or general &lt;a class="reference external" href="https://doc.pypy.org/en/latest/project-ideas.html"&gt;help&lt;/a&gt; with
making RPython's JIT even better.&lt;/p&gt;
&lt;p&gt;If you are a python library maintainer and use C-extensions, please consider
making a &lt;a class="reference external" href="https://hpyproject.org/"&gt;HPy&lt;/a&gt; / &lt;a class="reference external" href="https://cffi.readthedocs.io"&gt;CFFI&lt;/a&gt; / &lt;a class="reference external" href="https://cppyy.readthedocs.io"&gt;cppyy&lt;/a&gt; version of your library that would be performant
on PyPy. In any case, &lt;a class="reference external" href="https://github.com/joerick/cibuildwheel"&gt;cibuildwheel&lt;/a&gt; supports building wheels for PyPy.&lt;/p&gt;
&lt;section id="what-is-pypy"&gt;
&lt;h3&gt;What is PyPy?&lt;/h3&gt;
&lt;p&gt;PyPy is a Python interpreter, a drop-in replacement for CPython
It's fast (&lt;a class="reference external" href="https://speed.pypy.org"&gt;PyPy and CPython&lt;/a&gt; performance
comparison) due to its integrated tracing JIT compiler.&lt;/p&gt;
&lt;p&gt;We also welcome developers of other &lt;a class="reference external" href="https://rpython.readthedocs.io/en/latest/examples.html"&gt;dynamic languages&lt;/a&gt; to see what RPython
can do for them.&lt;/p&gt;
&lt;p&gt;We provide binary builds for:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;x86&lt;/strong&gt; machines on most common operating systems
(Linux 32/64 bits, Mac OS 64 bits, Windows 64 bits)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;64-bit &lt;strong&gt;ARM&lt;/strong&gt; machines running Linux (&lt;code class="docutils literal"&gt;aarch64&lt;/code&gt;) and macos (&lt;code class="docutils literal"&gt;macos_arm64&lt;/code&gt;).&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;PyPy supports Windows 32-bit, Linux PPC64 big- and little-endian, Linux ARM
32 bit, RISC-V RV64IMAFD Linux, and s390x Linux but does not release binaries.
Please reach out to us if you wish to sponsor binary releases for those
platforms. Downstream packagers provide binary builds for debian, Fedora,
conda, OpenBSD, FreeBSD, Gentoo, and more.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="what-else-is-new"&gt;
&lt;h3&gt;What else is new?&lt;/h3&gt;
&lt;p&gt;For more information about the 7.3.21 release, see the &lt;a class="reference external" href="https://doc.pypy.org/en/latest/release-v7.3.21.html#changelog"&gt;full changelog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Please update, and continue to help us make pypy better.&lt;/p&gt;
&lt;p&gt;Cheers,
The PyPy Team&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;</description><category>release</category><guid>https://www.pypy.org/posts/2026/03/pypy-v7321-release.html</guid><pubDate>Fri, 13 Mar 2026 10:00:00 GMT</pubDate></item><item><title>PyPy v7.3.20 release</title><link>https://www.pypy.org/posts/2025/07/pypy-v7320-release.html</link><dc:creator>mattip</dc:creator><description>&lt;section id="pypy-v7-3-20-release-of-python-2-7-3-11"&gt;
&lt;h2&gt;PyPy v7.3.20: release of python 2.7, 3.11&lt;/h2&gt;
&lt;p&gt;The PyPy team is proud to release version 7.3.20 of PyPy after the previous
release on Feb 26, 2025. The release fixes some subtle bugs in ctypes and
&lt;code class="docutils literal"&gt;OrderedDict&lt;/code&gt; and makes PyPy3.11 compatible with an upcoming release of
Cython.&lt;/p&gt;
&lt;p&gt;The release includes two different interpreters:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;PyPy2.7, which is an interpreter supporting the syntax and the features of
Python 2.7 including the stdlib for CPython 2.7.18+ (the &lt;code class="docutils literal"&gt;+&lt;/code&gt; is for
backported security updates)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.11, which is an interpreter supporting the syntax and the features of
Python 3.11, including the stdlib for CPython 3.11.13.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The interpreters are based on much the same codebase, thus the double
release. This is a micro release, all APIs are compatible with the other 7.3
releases.&lt;/p&gt;
&lt;p&gt;We recommend updating. You can find links to download the releases here:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a class="reference external" href="https://pypy.org/download.html"&gt;https://pypy.org/download.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We would like to thank our donors for the continued support of the PyPy
project. If PyPy is not quite good enough for your needs, we are available for
&lt;a class="reference external" href="https://www.pypy.org/pypy-sponsors.html"&gt;direct consulting&lt;/a&gt; work. If PyPy is helping you out, we would love to hear
about it and encourage submissions to our &lt;a class="reference external" href="https://pypy.org/blog"&gt;blog&lt;/a&gt; via a pull request
to &lt;a class="reference external" href="https://github.com/pypy/pypy.org"&gt;https://github.com/pypy/pypy.org&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We would also like to thank our contributors and encourage new people to join
the project. PyPy has many layers and we need help with all of them: bug fixes,
&lt;a class="reference external" href="https://doc.pypy.org/"&gt;PyPy&lt;/a&gt; and &lt;a class="reference external" href="https://rpython.readthedocs.org"&gt;RPython&lt;/a&gt; documentation improvements, or general &lt;a class="reference external" href="https://doc.pypy.org/en/latest/project-ideas.html"&gt;help&lt;/a&gt; with
making RPython's JIT even better.&lt;/p&gt;
&lt;p&gt;If you are a python library maintainer and use C-extensions, please consider
making a &lt;a class="reference external" href="https://hpyproject.org/"&gt;HPy&lt;/a&gt; / &lt;a class="reference external" href="https://cffi.readthedocs.io"&gt;CFFI&lt;/a&gt; / &lt;a class="reference external" href="https://cppyy.readthedocs.io"&gt;cppyy&lt;/a&gt; version of your library that would be performant
on PyPy. In any case, &lt;a class="reference external" href="https://github.com/joerick/cibuildwheel"&gt;cibuildwheel&lt;/a&gt; supports building wheels for PyPy.&lt;/p&gt;
&lt;section id="what-is-pypy"&gt;
&lt;h3&gt;What is PyPy?&lt;/h3&gt;
&lt;p&gt;PyPy is a Python interpreter, a drop-in replacement for CPython
It's fast (&lt;a class="reference external" href="https://speed.pypy.org"&gt;PyPy and CPython&lt;/a&gt; performance
comparison) due to its integrated tracing JIT compiler.&lt;/p&gt;
&lt;p&gt;We also welcome developers of other &lt;a class="reference external" href="https://rpython.readthedocs.io/en/latest/examples.html"&gt;dynamic languages&lt;/a&gt; to see what RPython
can do for them.&lt;/p&gt;
&lt;p&gt;We provide binary builds for:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;x86&lt;/strong&gt; machines on most common operating systems
(Linux 32/64 bits, Mac OS 64 bits, Windows 64 bits)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;64-bit &lt;strong&gt;ARM&lt;/strong&gt; machines running Linux (&lt;code class="docutils literal"&gt;aarch64&lt;/code&gt;) and macos (&lt;code class="docutils literal"&gt;macos_arm64&lt;/code&gt;).&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;PyPy supports Windows 32-bit, Linux PPC64 big- and little-endian, Linux ARM
32 bit, RISC-V RV64IMAFD Linux, and s390x Linux but does not release binaries.
Please reach out to us if you wish to sponsor binary releases for those
platforms. Downstream packagers provide binary builds for debian, Fedora,
conda, OpenBSD, FreeBSD, Gentoo, and more.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="what-else-is-new"&gt;
&lt;h3&gt;What else is new?&lt;/h3&gt;
&lt;p&gt;For more information about the 7.3.20 release, see the &lt;a class="reference external" href="https://doc.pypy.org/en/latest/release-v7.3.20.html#changelog"&gt;full changelog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Please update, and continue to help us make pypy better.&lt;/p&gt;
&lt;p&gt;Cheers,
The PyPy Team&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;</description><category>release</category><guid>https://www.pypy.org/posts/2025/07/pypy-v7320-release.html</guid><pubDate>Fri, 04 Jul 2025 12:00:00 GMT</pubDate></item><item><title>PyPy v7.3.19 release</title><link>https://www.pypy.org/posts/2025/02/pypy-v7319-release.html</link><dc:creator>mattip</dc:creator><description>&lt;section id="pypy-v7-3-19-release-of-python-2-7-3-10-and-3-11-beta"&gt;
&lt;h2&gt;PyPy v7.3.19: release of python 2.7, 3.10 and 3.11 beta&lt;/h2&gt;
&lt;p&gt;The PyPy team is proud to release version 7.3.19 of PyPy. This is primarily a
bug-fix release fixing JIT-related problems and follows quickly on the heels of
the previous release on Feb 6, 2025.&lt;/p&gt;
&lt;p&gt;This release includes a python 3.11 interpreter. There were bugs in the first
beta that could prevent its wider use, so we are continuing to call this
release "beta". In the next release we will drop 3.10 and remove the "beta"
label.&lt;/p&gt;
&lt;p&gt;The release includes three different interpreters:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;PyPy2.7, which is an interpreter supporting the syntax and the features of
Python 2.7 including the stdlib for CPython 2.7.18+ (the &lt;code class="docutils literal"&gt;+&lt;/code&gt; is for
backported security updates)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.10, which is an interpreter supporting the syntax and the features of
Python 3.10, including the stdlib for CPython 3.10.16.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.11, which is an interpreter supporting the syntax and the features of
Python 3.11, including the stdlib for CPython 3.11.11.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The interpreters are based on much the same codebase, thus the triple
release. This is a micro release, all APIs are compatible with the other 7.3
releases. It follows after 7.3.17 release on August 28, 2024.&lt;/p&gt;
&lt;p&gt;We recommend updating. You can find links to download the releases here:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a class="reference external" href="https://pypy.org/download.html"&gt;https://pypy.org/download.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We would like to thank our donors for the continued support of the PyPy
project. If PyPy is not quite good enough for your needs, we are available for
&lt;a class="reference external" href="https://www.pypy.org/pypy-sponsors.html"&gt;direct consulting&lt;/a&gt; work. If PyPy is helping you out, we would love to hear
about it and encourage submissions to our &lt;a class="reference external" href="https://pypy.org/blog"&gt;blog&lt;/a&gt; via a pull request
to &lt;a class="reference external" href="https://github.com/pypy/pypy.org"&gt;https://github.com/pypy/pypy.org&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We would also like to thank our contributors and encourage new people to join
the project. PyPy has many layers and we need help with all of them: bug fixes,
&lt;a class="reference external" href="https://doc.pypy.org/"&gt;PyPy&lt;/a&gt; and &lt;a class="reference external" href="https://rpython.readthedocs.org"&gt;RPython&lt;/a&gt; documentation improvements, or general &lt;a class="reference external" href="https://doc.pypy.org/en/latest/project-ideas.html"&gt;help&lt;/a&gt; with
making RPython's JIT even better.&lt;/p&gt;
&lt;p&gt;If you are a python library maintainer and use C-extensions, please consider
making a &lt;a class="reference external" href="https://hpyproject.org/"&gt;HPy&lt;/a&gt; / &lt;a class="reference external" href="https://cffi.readthedocs.io"&gt;CFFI&lt;/a&gt; / &lt;a class="reference external" href="https://cppyy.readthedocs.io"&gt;cppyy&lt;/a&gt; version of your library that would be performant
on PyPy. In any case, both &lt;a class="reference external" href="https://github.com/joerick/cibuildwheel"&gt;cibuildwheel&lt;/a&gt; and the &lt;a class="reference external" href="https://github.com/matthew-brett/multibuild"&gt;multibuild system&lt;/a&gt; support
building wheels for PyPy.&lt;/p&gt;
&lt;section id="what-is-pypy"&gt;
&lt;h3&gt;What is PyPy?&lt;/h3&gt;
&lt;p&gt;PyPy is a Python interpreter, a drop-in replacement for CPython
It's fast (&lt;a class="reference external" href="https://speed.pypy.org"&gt;PyPy and CPython&lt;/a&gt; performance
comparison) due to its integrated tracing JIT compiler.&lt;/p&gt;
&lt;p&gt;We also welcome developers of other &lt;a class="reference external" href="https://rpython.readthedocs.io/en/latest/examples.html"&gt;dynamic languages&lt;/a&gt; to see what RPython
can do for them.&lt;/p&gt;
&lt;p&gt;We provide binary builds for:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;x86&lt;/strong&gt; machines on most common operating systems
(Linux 32/64 bits, Mac OS 64 bits, Windows 64 bits)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;64-bit &lt;strong&gt;ARM&lt;/strong&gt; machines running Linux (&lt;code class="docutils literal"&gt;aarch64&lt;/code&gt;) and macos (&lt;code class="docutils literal"&gt;macos_arm64&lt;/code&gt;).&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;PyPy supports Windows 32-bit, Linux PPC64 big- and little-endian, Linux ARM
32 bit, RISC-V RV64IMAFD Linux, and s390x Linux but does not release binaries.
Please reach out to us if you wish to sponsor binary releases for those
platforms. Downstream packagers provide binary builds for debian, Fedora,
conda, OpenBSD, FreeBSD, Gentoo, and more.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="what-else-is-new"&gt;
&lt;h3&gt;What else is new?&lt;/h3&gt;
&lt;p&gt;For more information about the 7.3.19 release, see the &lt;a class="reference external" href="https://doc.pypy.org/en/latest/release-v7.3.19.html#changelog"&gt;full changelog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Please update, and continue to help us make pypy better.&lt;/p&gt;
&lt;p&gt;Cheers,
The PyPy Team&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;</description><category>release</category><guid>https://www.pypy.org/posts/2025/02/pypy-v7319-release.html</guid><pubDate>Wed, 26 Feb 2025 12:00:00 GMT</pubDate></item><item><title>PyPy v7.3.18 release</title><link>https://www.pypy.org/posts/2025/02/pypy-v7318-release.html</link><dc:creator>mattip</dc:creator><description>&lt;section id="pypy-v7-3-18-release-of-python-2-7-3-10-and-3-11-beta"&gt;
&lt;h2&gt;PyPy v7.3.18: release of python 2.7, 3.10 and 3.11 beta&lt;/h2&gt;
&lt;p&gt;The PyPy team is proud to release version 7.3.18 of PyPy.&lt;/p&gt;
&lt;p&gt;This release includes a python 3.11 interpreter. We are labelling it "beta"
because it is the first one. In the next release we will drop 3.10 and remove
the "beta" label. There are a particularly large set of bugfixes in this
release thanks to @devdanzin using fusil on the 3.10 builds, originally written
by Victor Stinner. Other significant changes:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;We have updated libffi shipped in our portable builds. We also now statically
link to libffi where possible which reduces the number of
shared object dependencies.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;We have added code to be able to show the native function names when
profiling with VMProf. So far only Linux supports this feature.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;We have added a &lt;a class="reference external" href="https://peps.python.org/pep-0768/"&gt;PEP 768&lt;/a&gt;-inspired remote debugging facility.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The HPy backend has been updated to latest HPy HEAD&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The release includes three different interpreters:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;PyPy2.7, which is an interpreter supporting the syntax and the features of
Python 2.7 including the stdlib for CPython 2.7.18+ (the &lt;code class="docutils literal"&gt;+&lt;/code&gt; is for
backported security updates)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.10, which is an interpreter supporting the syntax and the features of
Python 3.10, including the stdlib for CPython 3.10.16.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.11, which is an interpreter supporting the syntax and the features of
Python 3.11, including the stdlib for CPython 3.11.11.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The interpreters are based on much the same codebase, thus the triple
release. This is a micro release, all APIs are compatible with the other 7.3
releases. It follows after 7.3.17 release on August 28, 2024.&lt;/p&gt;
&lt;p&gt;We recommend updating. You can find links to download the releases here:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a class="reference external" href="https://pypy.org/download.html"&gt;https://pypy.org/download.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We would like to thank our donors for the continued support of the PyPy
project. If PyPy is not quite good enough for your needs, we are available for
&lt;a class="reference external" href="https://www.pypy.org/pypy-sponsors.html"&gt;direct consulting&lt;/a&gt; work. If PyPy is helping you out, we would love to hear
about it and encourage submissions to our &lt;a class="reference external" href="https://pypy.org/blog"&gt;blog&lt;/a&gt; via a pull request
to &lt;a class="reference external" href="https://github.com/pypy/pypy.org"&gt;https://github.com/pypy/pypy.org&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We would also like to thank our contributors and encourage new people to join
the project. PyPy has many layers and we need help with all of them: bug fixes,
&lt;a class="reference external" href="https://doc.pypy.org/"&gt;PyPy&lt;/a&gt; and &lt;a class="reference external" href="https://rpython.readthedocs.org"&gt;RPython&lt;/a&gt; documentation improvements, or general &lt;a class="reference external" href="https://doc.pypy.org/en/latest/project-ideas.html"&gt;help&lt;/a&gt; with
making RPython's JIT even better.&lt;/p&gt;
&lt;p&gt;If you are a python library maintainer and use C-extensions, please consider
making a &lt;a class="reference external" href="https://hpyproject.org/"&gt;HPy&lt;/a&gt; / &lt;a class="reference external" href="https://cffi.readthedocs.io"&gt;CFFI&lt;/a&gt; / &lt;a class="reference external" href="https://cppyy.readthedocs.io"&gt;cppyy&lt;/a&gt; version of your library that would be performant
on PyPy. In any case, both &lt;a class="reference external" href="https://github.com/joerick/cibuildwheel"&gt;cibuildwheel&lt;/a&gt; and the &lt;a class="reference external" href="https://github.com/matthew-brett/multibuild"&gt;multibuild system&lt;/a&gt; support
building wheels for PyPy.&lt;/p&gt;
&lt;section id="vmprof-native-symbol-names"&gt;
&lt;h3&gt;VMProf Native Symbol Names&lt;/h3&gt;
&lt;p&gt;When running VMProf profiling with native profiling enabled, PyPy did so far
not produce function names for C functions. The output looked like this:&lt;/p&gt;
&lt;pre class="literal-block"&gt;pypy -m vmprof ~/projects/gitpypy/lib-python/2.7/test/pystone.py
Pystone(1.1) time for 50000 passes = 0.0109887
This machine benchmarks at 4.55011e+06 pystones/second
 vmprof output:
 %:      name:                location:
 100.0%  entry_point          &amp;lt;builtin&amp;gt;/app_main.py:874
 100.0%  run_command_line     &amp;lt;builtin&amp;gt;/app_main.py:601
 100.0%  run_toplevel         &amp;lt;builtin&amp;gt;/app_main.py:93
 100.0%  _run_module_as_main  /home/user/bin/pypy-c-jit-170203-99a72243b541-linux64/lib-python/2.7/runpy.py:150
 100.0%  _run_code            /home/user/bin/pypy-c-jit-170203-99a72243b541-linux64/lib-python/2.7/runpy.py:62
 100.0%  &amp;lt;module&amp;gt;             /home/user/bin/pypy-c-jit-170203-99a72243b541-linux64/site-packages/vmprof/__main__.py:1
 100.0%  main                 /home/user/bin/pypy-c-jit-170203-99a72243b541-linux64/site-packages/vmprof/__main__.py:30
 100.0%  run_path             /home/user/bin/pypy-c-jit-170203-99a72243b541-linux64/lib-python/2.7/runpy.py:238
 100.0%  _run_module_code     /home/user/bin/pypy-c-jit-170203-99a72243b541-linux64/lib-python/2.7/runpy.py:75
 100.0%  &amp;lt;module&amp;gt;             /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:3
 100.0%  main                 /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:60
 100.0%  pystones             /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:67
 100.0%  Proc0                /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:79
 76.9%   &amp;lt;unknown code&amp;gt;
 69.2%   &amp;lt;unknown code&amp;gt;
 53.8%   &amp;lt;unknown code&amp;gt;
 53.8%   &amp;lt;unknown code&amp;gt;
 46.2%   &amp;lt;unknown code&amp;gt;
 46.2%   &amp;lt;unknown code&amp;gt;
 38.5%   &amp;lt;unknown code&amp;gt;
 38.5%   Proc8                /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:212
 30.8%   &amp;lt;unknown code&amp;gt;
 ...&lt;/pre&gt;
&lt;p&gt;We can now symbolify these C functions and give function names and which
shared library they come from, at least on Linux:&lt;/p&gt;
&lt;pre class="literal-block"&gt;Pystone(1.1) time for 50000 passes = 0.218967
This machine benchmarks at 228345 pystones/second
 vmprof output:
 %:      name:                                           location:
 100.0%  entry_point                                     &amp;lt;builtin&amp;gt;/app_main.py:889
 100.0%  run_command_line                                &amp;lt;builtin&amp;gt;/app_main.py:616
 100.0%  run_toplevel                                    &amp;lt;builtin&amp;gt;/app_main.py:95
 100.0%  _run_module_as_main                             /home/user/projects/gitpypy/lib-python/2.7/runpy.py:150
 100.0%  _run_code                                       /home/user/projects/gitpypy/lib-python/2.7/runpy.py:62
 100.0%  &amp;lt;module&amp;gt;                                        /home/user/projects/gitpypy/site-packages/vmprof/__main__.py:1
 100.0%  main                                            /home/user/projects/gitpypy/site-packages/vmprof/__main__.py:30
 100.0%  run_module                                      /home/user/projects/gitpypy/lib-python/2.7/runpy.py:179
 100.0%  _run_module_code                                /home/user/projects/gitpypy/lib-python/2.7/runpy.py:75
 100.0%  &amp;lt;module&amp;gt;                                        /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:3
 100.0%  main                                            /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:60
 100.0%  pystones                                        /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:67
 100.0%  Proc0                                           /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:79
 95.5%   n:pypy_g_execute_frame:0:pypy-c
 91.4%   n:pypy_g_PyFrame_dispatch:0:pypy-c
 63.8%   n:pypy_g_PyFrame_dispatch_bytecode:0:pypy-c
 49.8%   Proc1                                           /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:137
 17.6%   copy                                            /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:53
 13.6%   n:pypy_g_PyFrame_CALL_FUNCTION:0:pypy-c
 10.4%   Proc8                                           /home/user/projects/gitpypy/lib-python/2.7/test/pystone.py:212
 8.6%    n:pypy_g_STORE_ATTR_slowpath:0:pypy-c&lt;/pre&gt;
&lt;p&gt;This becomes even more useful when using the &lt;a class="reference external" href="https://github.com/Cskorpion/vmprof-firefox-converter/"&gt;VMProf Firefox converter&lt;/a&gt;, which
uses the Firefox Profiler Web UI to visualize profiling output:&lt;/p&gt;
&lt;img alt="/images/2025-vmprof-firefox.png" src="https://www.pypy.org/images/2025-vmprof-firefox.png"&gt;
&lt;/section&gt;
&lt;section id="what-is-pypy"&gt;
&lt;h3&gt;What is PyPy?&lt;/h3&gt;
&lt;p&gt;PyPy is a Python interpreter, a drop-in replacement for CPython
It's fast (&lt;a class="reference external" href="https://speed.pypy.org"&gt;PyPy and CPython&lt;/a&gt; performance
comparison) due to its integrated tracing JIT compiler.&lt;/p&gt;
&lt;p&gt;We also welcome developers of other &lt;a class="reference external" href="https://rpython.readthedocs.io/en/latest/examples.html"&gt;dynamic languages&lt;/a&gt; to see what RPython
can do for them.&lt;/p&gt;
&lt;p&gt;We provide binary builds for:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;x86&lt;/strong&gt; machines on most common operating systems
(Linux 32/64 bits, Mac OS 64 bits, Windows 64 bits)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;64-bit &lt;strong&gt;ARM&lt;/strong&gt; machines running Linux (&lt;code class="docutils literal"&gt;aarch64&lt;/code&gt;) and macos (&lt;code class="docutils literal"&gt;macos_arm64&lt;/code&gt;).&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;PyPy supports Windows 32-bit, Linux PPC64 big- and little-endian, Linux ARM
32 bit, RISC-V RV64IMAFD Linux, and s390x Linux but does not release binaries.
Please reach out to us if you wish to sponsor binary releases for those
platforms. Downstream packagers provide binary builds for debian, Fedora,
conda, OpenBSD, FreeBSD, Gentoo, and more.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="what-else-is-new"&gt;
&lt;h3&gt;What else is new?&lt;/h3&gt;
&lt;p&gt;For more information about the 7.3.18 release, see the &lt;a class="reference external" href="https://doc.pypy.org/en/latest/release-v7.3.18.html#changelog"&gt;full changelog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Please update, and continue to help us make pypy better.&lt;/p&gt;
&lt;p&gt;Cheers,
The PyPy Team&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;</description><category>release</category><guid>https://www.pypy.org/posts/2025/02/pypy-v7318-release.html</guid><pubDate>Thu, 06 Feb 2025 12:00:00 GMT</pubDate></item><item><title>Towards PyPy3.11 - an update</title><link>https://www.pypy.org/posts/2025/01/towards-pypy311-an-update.html</link><dc:creator>mattip</dc:creator><description>&lt;p&gt;We&lt;sup id="fnref:0"&gt;&lt;a class="footnote-ref" href="https://www.pypy.org/posts/2025/01/towards-pypy311-an-update.html#fn:0"&gt;1&lt;/a&gt;&lt;/sup&gt; are steadily working towards a Python 3.11 interpreter, which will be part
of the upcoming PyPy 7.3.18 release. Along with that, we also recently updated 
&lt;a href="https://speed.pypy.org"&gt;speed.pypy.org&lt;/a&gt; to compare PyPy's performance to CPython
3.11 (it used to be CPython 3.7). &lt;/p&gt;
&lt;!-- TEASER_END --&gt;
&lt;h2 id="why-is-there-no-pypy-for-python-311"&gt;Why is there no PyPy for Python 3.11?&lt;/h2&gt;
&lt;p&gt;TL;DR: we are working on it and hopefully will have a beta version soon&lt;/p&gt;
&lt;p&gt;We started by merging the &lt;a href="https://peps.python.org/pep-0654/"&gt;exception groups&lt;/a&gt;
work by Nico Rittinghaus, merging the CPython stdlib for Python 3.11.9, and
updating the regex engine to handle atomic groupings. I think these were the
largest changes needed to support Python3.11, maybe I missed something else?&lt;/p&gt;
&lt;p&gt;We then created a &lt;a href="https://github.com/pypy/pypy/milestone/15"&gt;milestone&lt;/a&gt; with
many of the changes that might not be caught in testing. As of today that
milestone stands at 24/40 issues closed, 16 open. This is in addition to the
&lt;a href="https://github.com/pypy/pypy/milestone/22"&gt;v7.3.18 milestone&lt;/a&gt;, which has 11/23
issues closed, 12 open.&lt;/p&gt;
&lt;p&gt;We also updated our infrastructure to run nightly &lt;a href="https://buildbot.pypy.org/summary?branch=py3.11"&gt;buildbot test of the
py3.11&lt;/a&gt; branch, including adding py3.11 to our benchmarking site &lt;a href="https://speed.pypy.org/"&gt;speed.pypy.org&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Then the real work started: fixing these milestone issues and failing stdlib
tests. Some of the changes were cosmetic changes to error messages, some were
more involved changes to the interpreter to behave more like CPython. For instance,
&lt;code&gt;hex(x)&lt;/code&gt; where &lt;code&gt;x&lt;/code&gt; is an int calls &lt;code&gt;long.format(x, "#x")&lt;/code&gt; on CPython where in
PyPy we used &lt;code&gt;x.__format__("#x")&lt;/code&gt;. This subtle difference caused a failure in
the &lt;code&gt;repr&lt;/code&gt; of &lt;code&gt;IntEnum&lt;/code&gt;. Tracking down problems like these takes time. We are
now down to about 250 failing stdlib tests, with thousands passing. For comparison, 
PyPy3.10, first released in June 2023, still has around 100 failing stdlib
tests.&lt;/p&gt;
&lt;h3 id="c-extension-support"&gt;C-extension support&lt;/h3&gt;
&lt;p&gt;PyPy supports the Python C-API via a cpyext compatibility layer. We "mangle"
the CPython symbols to add an extra &lt;code&gt;Py&lt;/code&gt; to prevent loading CPython c-extension
modules into PyPy, since the ABI is different. So a function like
&lt;code&gt;PyLong_FromLong&lt;/code&gt; will be exported from the c shared object as
&lt;code&gt;PyPyLong_FromLong&lt;/code&gt;. One of my long-standing goals is to remove this mangling,
but it then requires that our c declarations, inlined functions, and macros in
the headers match 1:1 the CPython headers. We can get by with not declaring and
implementing parts of the interfaces, but what is declared must be identical.
This is a long-term project, with each release the headers get closer to the
CPython versions. I hope to concentrate on the PyUnicode interfaces for this
release.&lt;/p&gt;
&lt;p&gt;Note that the time to do this is before a new version release. Once the version
is released, we cannot change the headers significantly.&lt;/p&gt;
&lt;h3 id="so-what-is-left"&gt;So what is left?&lt;/h3&gt;
&lt;p&gt;Summarizing the milestones and other things to do:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Update to the recently released 3.11.11 stdlib&lt;/li&gt;
&lt;li&gt;Make sure &lt;a href="https://vmprof.readthedocs.io/en/latest/"&gt;vmprof&lt;/a&gt; works&lt;/li&gt;
&lt;li&gt;Update the &lt;code&gt;time&lt;/code&gt; module to use more &lt;code&gt;MONOTONIC_CLOCK&lt;/code&gt;, implement
  &lt;code&gt;time.sleep&lt;/code&gt; differently, and clean up the many duplicate &lt;code&gt;time&lt;/code&gt; like
  interfaces we have across the codebase. We have the &lt;code&gt;time&lt;/code&gt; module, some time
  routines in the &lt;code&gt;_threading&lt;/code&gt; module&lt;code&gt;and RPython threading support in the&lt;/code&gt;rpython/rlib` code. We should also make sure we are using 64-bit time
  interfaces.&lt;/li&gt;
&lt;li&gt;Decide whether zero-cost exceptions gain us in performance and whether we
  should implement them even if they do not improve performance.&lt;/li&gt;
&lt;li&gt;Update our &lt;a href="http://hpyproject.org/"&gt;hpy&lt;/a&gt; backend to the latest HEAD, which
  would allow running the &lt;a href="https://github.com/hpyproject/numpy-hpy/tree/graal-team/hpy#readme"&gt;hpy numpy
  fork&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Reintegrate the pure-python pyrepl libbrary from CPython 3.13.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;What else did I forget?&lt;/p&gt;
&lt;h2 id="why-did-the-benchmark-results-get-worse-on-speedpypyorg"&gt;Why did the benchmark results get worse on speed.pypy.org?&lt;/h2&gt;
&lt;p&gt;TL;DR: running a benchmark site is hard. Something changed in the benchmark
runner, and suddenly benchmarks got 10-15% slower.&lt;/p&gt;
&lt;p&gt;PyPy run an instance of
&lt;a href="https://github.com/python/codespeed/tree/speed.pypy.org"&gt;codepseed&lt;/a&gt; with a
very old &lt;a href="https://foss.heptapod.net/pypy/benchmarks"&gt;benchmarking suite&lt;/a&gt;
that can still run Python2 (remember: that is the language of
&lt;a href="https://rpython.readthedocs.io/en/latest/"&gt;RPython&lt;/a&gt; underlying PyPy). The site
runs on PSA infrastructure and the benchmarking machine is generously sponsored
by &lt;a href="https://baroquesoftware.com/"&gt;Baroque Software&lt;/a&gt;. On Nov 9, there was a
sudden jump in benchmarking times. For instance
&lt;a href="https://speed.pypy.org/timeline/#/?exe=21,8&amp;amp;base=10+2622&amp;amp;ben=float&amp;amp;revs=50&amp;amp;equid=off&amp;amp;quarts=on&amp;amp;extr=on&amp;amp;env=3"&gt;here&lt;/a&gt;
is the result for the &lt;code&gt;float&lt;/code&gt; benchmark. This happened across various benchmark
runs: both PyPy2.7 and PyPy3.11alpha, with and without the JIT. After spending
some time rerunning various benchmarks, I could only conclude the machine
itself had gotten slower, maybe due to some security update in the linux
kernel, maybe some change in the hosting platform. This "broke" the front-page
comparsison: suddenly "latest" is much slower than the historic benchmarks run
previous to the changes in the machine.&lt;/p&gt;
&lt;p&gt;That page also recently (as of last week) uses CPython 3.11 as a baseline for
comparison, where previously it used CPython3.7. It is common knowledge that
the newer CPython versions are faster, and we see this now quite clearly.
Diving into individual benchmarks, we can see that ones where PyPy-with-a-jit
was comparable to CPython3.7 seem to be the ones that CPython3.11 improved
greatly. Looking at a &lt;a href="https://speed.pypy.org/comparison/?exe=22%2BL%2Bpy3.11%2C2%2B2360%2C2%2B3893&amp;amp;ben=1%2C34%2C58%2C63%2C60%2C27%2C61%2C2%2C25%2C57%2C3%2C46%2C4%2C5%2C41%2C42%2C22%2C44%2C6%2C59%2C39%2C7%2C8%2C65%2C45%2C23%2C62%2C66%2C24%2C9%2C10%2C47%2C48%2C49%2C50%2C51%2C11%2C12%2C13%2C40%2C14%2C69%2C15%2C70%2C67%2C68%2C64%2C35%2C36%2C37%2C38%2C16%2C52%2C54%2C55%2C53%2C56%2C28%2C30%2C32%2C29%2C33%2C17%2C18%2C19%2C20%2C43&amp;amp;env=3&amp;amp;hor=true&amp;amp;bas=2%2B2360&amp;amp;chart=normal+bars"&gt;comparison of the
runs&lt;/a&gt;
this can be seen in benchmarks like deltablue and the sqlalchemy family. So the
new graph has more lines that extend past 1.5 than the old graph.&lt;/p&gt;
&lt;p style="text-align: center;"&gt;
New graph with PyPy3.11
&lt;/p&gt;
&lt;p&gt;&lt;img alt="new graph" src="https://www.pypy.org/images/2024-12-new-graph.png"&gt;&lt;/p&gt;
&lt;p style="text-align: center;"&gt;
Older graph with PyPy3.10
&lt;/p&gt;
&lt;p&gt;&lt;img alt="old
graph" src="https://www.pypy.org/images/2024-12-old-graph.png"&gt;.&lt;/p&gt;
&lt;div class="footnote"&gt;
&lt;hr&gt;
&lt;ol&gt;
&lt;li id="fn:0"&gt;
&lt;p&gt;These days most of the work is done by &lt;a href="https://cfbolz.de/"&gt;CF
Bolz-Tereick&lt;/a&gt; and &lt;a href="https://github.com/mattip"&gt;me&lt;/a&gt; on a
volunteer basis. Want to get involved? Reach out, we would love to expand the
team. Have an idea for funding the work? Fantastic, let's talk. &lt;a class="footnote-backref" href="https://www.pypy.org/posts/2025/01/towards-pypy311-an-update.html#fnref:0" title="Jump back to footnote 1 in the text"&gt;↩&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;</description><category>release</category><guid>https://www.pypy.org/posts/2025/01/towards-pypy311-an-update.html</guid><pubDate>Sat, 04 Jan 2025 13:29:11 GMT</pubDate></item><item><title>PyPy v7.3.17 release</title><link>https://www.pypy.org/posts/2024/08/pypy-v7317-release.html</link><dc:creator>mattip</dc:creator><description>&lt;section id="pypy-v7-3-17-release-of-python-2-7-and-3-10"&gt;
&lt;h2&gt;PyPy v7.3.17: release of python 2.7 and 3.10&lt;/h2&gt;
&lt;p&gt;The PyPy team is proud to release version 7.3.17 of PyPy.&lt;/p&gt;
&lt;p&gt;This release includes a new &lt;a class="reference internal" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#risc-v-jit-backend"&gt;RISC-V JIT backend&lt;/a&gt;, an &lt;a class="reference internal" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#improved-repl"&gt;improved REPL&lt;/a&gt; based on
work by the CPython team, and &lt;a class="reference internal" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#better-jit-optimizations"&gt;better JIT optimizations&lt;/a&gt; of integer
operations. Special shout-outs to &lt;a class="reference external" href="https://github.com/loganchien"&gt;Logan Chien&lt;/a&gt; for the &lt;a class="reference external" href="https://github.com/pypy/pypy/pull/5002"&gt;RISC-V backend
work&lt;/a&gt;, to &lt;a class="reference external" href="https://github.com/nirit100"&gt;Nico Rittinghaus&lt;/a&gt; for better integer optimization in the JIT, and
the CPython team that has worked on the repl.&lt;/p&gt;
&lt;p&gt;The release includes two different interpreters:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;PyPy2.7, which is an interpreter supporting the syntax and the features of
Python 2.7 including the stdlib for CPython 2.7.18+ (the &lt;code class="docutils literal"&gt;+&lt;/code&gt; is for
backported security updates)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;PyPy3.10, which is an interpreter supporting the syntax and the features of
Python 3.10, including the stdlib for CPython 3.10.14.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The interpreters are based on much the same codebase, thus the dual
release. This is a micro release, all APIs are compatible with the other 7.3
releases. It follows after 7.3.16 release on April 23, 2024.&lt;/p&gt;
&lt;p&gt;We recommend updating. You can find links to download the releases here:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a class="reference external" href="https://pypy.org/download.html"&gt;https://pypy.org/download.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;We would like to thank our donors for the continued support of the PyPy
project. If PyPy is not quite good enough for your needs, we are available for
&lt;a class="reference external" href="https://www.pypy.org/pypy-sponsors.html"&gt;direct consulting&lt;/a&gt; work. If PyPy is helping you out, we would love to hear
about it and encourage submissions to our &lt;a class="reference external" href="https://pypy.org/blog"&gt;blog&lt;/a&gt; via a pull request
to &lt;a class="reference external" href="https://github.com/pypy/pypy.org"&gt;https://github.com/pypy/pypy.org&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We would also like to thank our contributors and encourage new people to join
the project. PyPy has many layers and we need help with all of them: bug fixes,
&lt;a class="reference external" href="https://doc.pypy.org/"&gt;PyPy&lt;/a&gt; and &lt;a class="reference external" href="https://rpython.readthedocs.org"&gt;RPython&lt;/a&gt; documentation improvements, or general &lt;a class="reference external" href="https://doc.pypy.org/en/latest/project-ideas.html"&gt;help&lt;/a&gt; with
making RPython's JIT even better.&lt;/p&gt;
&lt;p&gt;If you are a python library maintainer and use C-extensions, please consider
making a &lt;a class="reference external" href="https://hpyproject.org/"&gt;HPy&lt;/a&gt; / &lt;a class="reference external" href="https://cffi.readthedocs.io"&gt;CFFI&lt;/a&gt; / &lt;a class="reference external" href="https://cppyy.readthedocs.io"&gt;cppyy&lt;/a&gt; version of your library that would be performant
on PyPy. In any case, both &lt;a class="reference external" href="https://github.com/joerick/cibuildwheel"&gt;cibuildwheel&lt;/a&gt; and the &lt;a class="reference external" href="https://github.com/matthew-brett/multibuild"&gt;multibuild system&lt;/a&gt; support
building wheels for PyPy.&lt;/p&gt;
&lt;section id="risc-v-backend-for-the-jit"&gt;
&lt;span id="risc-v-jit-backend"&gt;&lt;/span&gt;&lt;h3&gt;RISC-V backend for the JIT&lt;/h3&gt;
&lt;p&gt;PyPy's JIT has added support for generating 64-bit RISC-V machine code at
runtime (RV64-IMAD, specifically). So far we are not releasing binaries for any
RISC-V platforms, but there are &lt;a class="reference external" href="https://rpython.readthedocs.io/en/latest/riscv.html"&gt;instructions&lt;/a&gt; on how to cross-compile binaries.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="repl-improvements"&gt;
&lt;span id="improved-repl"&gt;&lt;/span&gt;&lt;h3&gt;REPL Improvements&lt;/h3&gt;
&lt;p&gt;The biggest user-visible change of the release is new features in the repl of
PyPy3.10. CPython 3.13 has adopted and extended PyPy's pure-Python repl, adding
a number of features and fixing a number or bugs in the process. We have
backported and added the following features:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;Prompts and tracebacks use terminal colors, as well as &lt;a class="reference external" href="https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda"&gt;terminal hyperlinks&lt;/a&gt;
for file names.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="https://en.wikipedia.org/wiki/Bracketed-paste"&gt;Bracketed paste&lt;/a&gt; enable pasting several lines of input into the terminal
without auto-indentation getting in the way.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;A special interactive help browser (F1), history browser (F2), explicit paste
mode (F3).&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Support for Ctrl-&amp;lt;left/right&amp;gt; to jump over whole words at a time.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;See the &lt;a class="reference external" href="https://docs.python.org/3.13/whatsnew/3.13.html#a-better-interactive-interpreter"&gt;CPython documentation for further details&lt;/a&gt;. Thanks to Łukasz Langa,
Pablo Galindo Salgado and the other CPython devs involved in this work.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="better-jit-optimizations-of-integer-operations"&gt;
&lt;span id="better-jit-optimizations"&gt;&lt;/span&gt;&lt;h3&gt;Better JIT optimizations of integer operations&lt;/h3&gt;
&lt;p&gt;The optimizers of PyPy's JIT have become much better at reasoning about and
optimizing integer operations. This is done with a new &lt;a class="reference external" href="https://pypy.org/posts/2024/08/toy-knownbits.html"&gt;"knownbits" abstract
domain&lt;/a&gt;. In many programs that do bit-manipulation of integers, some of the
bits of the integer variables of the program can be statically known. Here's a
simple example:&lt;/p&gt;
&lt;div class="code"&gt;&lt;pre class="code python"&gt;&lt;a id="rest_code_db709854b43a453aaab246e043c4e94f-1" name="rest_code_db709854b43a453aaab246e043c4e94f-1" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#rest_code_db709854b43a453aaab246e043c4e94f-1"&gt;&lt;/a&gt;&lt;span class="n"&gt;x&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;a&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;
&lt;a id="rest_code_db709854b43a453aaab246e043c4e94f-2" name="rest_code_db709854b43a453aaab246e043c4e94f-2" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#rest_code_db709854b43a453aaab246e043c4e94f-2"&gt;&lt;/a&gt;&lt;span class="o"&gt;...&lt;/span&gt;
&lt;a id="rest_code_db709854b43a453aaab246e043c4e94f-3" name="rest_code_db709854b43a453aaab246e043c4e94f-3" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#rest_code_db709854b43a453aaab246e043c4e94f-3"&gt;&lt;/a&gt;&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;x&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;a id="rest_code_db709854b43a453aaab246e043c4e94f-4" name="rest_code_db709854b43a453aaab246e043c4e94f-4" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#rest_code_db709854b43a453aaab246e043c4e94f-4"&gt;&lt;/a&gt;    &lt;span class="o"&gt;...&lt;/span&gt;
&lt;a id="rest_code_db709854b43a453aaab246e043c4e94f-5" name="rest_code_db709854b43a453aaab246e043c4e94f-5" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#rest_code_db709854b43a453aaab246e043c4e94f-5"&gt;&lt;/a&gt;&lt;span class="k"&gt;else&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
&lt;a id="rest_code_db709854b43a453aaab246e043c4e94f-6" name="rest_code_db709854b43a453aaab246e043c4e94f-6" href="https://www.pypy.org/posts/2024/08/pypy-v7317-release.html#rest_code_db709854b43a453aaab246e043c4e94f-6"&gt;&lt;/a&gt;    &lt;span class="o"&gt;...&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;With the new abstract domain, the JIT can optimize the &lt;code class="docutils literal"&gt;if&lt;/code&gt;-condition to
&lt;code class="docutils literal"&gt;True&lt;/code&gt;, because it already knows that the lowest bit of &lt;code class="docutils literal"&gt;x&lt;/code&gt; must be set.
This optimization applies to all Python-integers that fit into a machine word
(PyPy optimistically picks between two different representations for &lt;code class="docutils literal"&gt;int&lt;/code&gt;,
depending on the size of the value). Unfortunately there is very little impact
of this change on almost all Python code, because intensive bit-manipulation is
rare in Python. However, the change leads to significant performance
improvements in &lt;a class="reference external" href="https://docs.pydrofoil.org/en/latest/"&gt;Pydrofoil&lt;/a&gt; (the RPython-based RISC-V/ARM emulators that are
automatically generated from high-level &lt;a class="reference external" href="https://github.com/rems-project/sail/"&gt;Sail&lt;/a&gt; specifications of the respective
ISAs, and that use the RPython JIT to improve performance).&lt;/p&gt;
&lt;/section&gt;
&lt;section id="pypy-versions-and-speed-pypy-org"&gt;
&lt;h3&gt;PyPy versions and speed.pypy.org&lt;/h3&gt;
&lt;p&gt;The keen-eyed will have noticed no mention of Python version 3.9 in the
releases above. Typically we will maintain only one version of Python3, but due
to PyPy3.9 support on conda-forge we maintained multiple versions from the
first release of PyPy3.10 in PyPy v7.3.12 (Dec 2022). Conda-forge is
&lt;a class="reference external" href="https://pypy.org/posts/2024/08/conda-forge-proposes-dropping-support-for-pypy.html"&gt;sunsetting its PyPy support&lt;/a&gt;, which means we can drop PyPy3.9. Since that was
the major driver of benchmarks at &lt;a class="reference external" href="https://speed.pypy.org"&gt;https://speed.pypy.org&lt;/a&gt;, we revamped the site
to showcase PyPy3.9, PyPy3.10, and various versions of cpython on the home
page. For historical reasons, the "baseline" for comparison is still cpython
3.7.19.&lt;/p&gt;
&lt;p&gt;We will keep the buildbots building PyPY3.9 until the end of August, these
builds will still be available on the &lt;a class="reference external" href="https://buildbot.pypy.org/nightly/"&gt;nightly builds&lt;/a&gt; tab of the buildbot.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="what-is-pypy"&gt;
&lt;h3&gt;What is PyPy?&lt;/h3&gt;
&lt;p&gt;PyPy is a Python interpreter, a drop-in replacement for CPython
It's fast (&lt;a class="reference external" href="https://speed.pypy.org"&gt;PyPy and CPython&lt;/a&gt; performance
comparison) due to its integrated tracing JIT compiler.&lt;/p&gt;
&lt;p&gt;We also welcome developers of other &lt;a class="reference external" href="https://rpython.readthedocs.io/en/latest/examples.html"&gt;dynamic languages&lt;/a&gt; to see what RPython
can do for them.&lt;/p&gt;
&lt;p&gt;We provide binary builds for:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;x86&lt;/strong&gt; machines on most common operating systems
(Linux 32/64 bits, Mac OS 64 bits, Windows 64 bits)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;64-bit &lt;strong&gt;ARM&lt;/strong&gt; machines running Linux (&lt;code class="docutils literal"&gt;aarch64&lt;/code&gt;) and macos (&lt;code class="docutils literal"&gt;macos_arm64&lt;/code&gt;).&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;PyPy supports Windows 32-bit, Linux PPC64 big- and little-endian, Linux ARM
32 bit, RISC-V RV64IMAFD Linux, and s390x Linux but does not release binaries.
Please reach out to us if you wish to sponsor binary releases for those
platforms. Downstream packagers provide binary builds for debian, Fedora,
conda, OpenBSD, FreeBSD, Gentoo, and more.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="what-else-is-new"&gt;
&lt;h3&gt;What else is new?&lt;/h3&gt;
&lt;p&gt;For more information about the 7.3.17 release, see the &lt;a class="reference external" href="https://doc.pypy.org/en/latest/release-v7.3.17.html#changelog"&gt;full changelog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Please update, and continue to help us make pypy better.&lt;/p&gt;
&lt;p&gt;Cheers,
The PyPy Team&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;</description><category>release</category><guid>https://www.pypy.org/posts/2024/08/pypy-v7317-release.html</guid><pubDate>Wed, 28 Aug 2024 12:22:08 GMT</pubDate></item><item><title>Conda-forge proposes sunsetting support for PyPy</title><link>https://www.pypy.org/posts/2024/08/conda-forge-proposes-dropping-support-for-pypy.html</link><dc:creator>mattip</dc:creator><description>&lt;p&gt;Conda-forge has kindly been providing support for PyPy since 2019. The
conda-forge team has been very patient and generous with resources, but it
seems the uptake of PyPy has not justified the effort. Major packages still
are not &lt;a href="https://conda-forge.org/status/migration/?name=pypy38"&gt;available on PyPy&lt;/a&gt;,
others find it hard to &lt;a href="https://github.com/conda-forge/numpy-feedstock/pull/310"&gt;update
versions&lt;/a&gt;. We don't
get much feedback at all about people using PyPy, and even less about PyPy on
conda-forge. The conda-forge team has proposed &lt;a href="https://github.com/conda-forge/conda-forge.github.io/pull/2259"&gt;sunsetting
PyPy&lt;/a&gt; going
forward, which means current packages would remain but no new packages would be
built. If you have an opinion, you can comment on that PR, or on this blog post.&lt;/p&gt;
&lt;p&gt;Since conda-forge supports PyPy3.9 but not PyPy3.10, we have continued
releasing PyPy3.9 even though we typically support only one version of PyPy3.
With the sunsetting proposal, we will not release any more updates to PyPy3.9.
I opened a &lt;a href="https://github.com/orgs/pypy/discussions/4998"&gt;poll&lt;/a&gt; about the
intention to drop PyPy3.9. If you have an opinion, please chime in.&lt;/p&gt;</description><category>conda-forge</category><guid>https://www.pypy.org/posts/2024/08/conda-forge-proposes-dropping-support-for-pypy.html</guid><pubDate>Fri, 09 Aug 2024 06:27:41 GMT</pubDate></item></channel></rss>