arigato changed the topic of #pypy to: PyPy, the flexible snake (IRC logs: https://quodlibet.duckdns.org/irc/pypy/latest.log.html#irc-end ) | use cffi for calling C | mac OS and Fedora are not Windows
speeder39_ has quit [Quit: Connection closed for inactivity]
alexge50 has quit [Read error: Connection reset by peer]
alexge50 has joined #pypy
dddddd has quit [Read error: Connection reset by peer]
xcm has quit [Read error: Connection reset by peer]
xcm has joined #pypy
xcm has quit [Remote host closed the connection]
<arigato> mattip: I agree with mjacob, and in my opinion it's bogus that CPython's default encoding is "utf8" and not "utf-8"
<arigato> I would fix the test
xcm has joined #pypy
<arigato> honestly I also have no idea how this test passes on CPython
<arigato> OK that's because this test doesn't exist on CPython
<arigato> it's in a file with a different name and with 'utf-8' instead of 'utf8' in the test
<arigato> test_utf8source.py, which we also have
<arigato> I think we somehow missed the files that were deleted (or renamed) and still have the originals
<arigato> this concerns at least all lib-python/3/test/test_pep*.py, which in CPython have all be renamed to something saner
<kenaan> arigo sandbox-2 7177f77afa08 /rpython/translator/sandbox/: Fix some of the tests
<kenaan> arigo sandbox-2 f4bf2fbd0c19 /: in-progress
tsaka__ has joined #pypy
* mattip looking at resyncing the test suite
<mattip> thanks arigato, mjacob
<tos9> bleh, tensorflow still doesn't work on pypy
<arigato> mattip: while you're at it, also check if there are files left over in lib-python/3/ directly
<kenaan> arigo sandbox-2 76b447660dd6 /rpython/: More review of the posix modules
<kenaan> arigo sandbox-2 bf7d11fce803 /: More fixes
<kenaan> mattip py3.6 81a9ec3c2935 /lib-python/3/: remove test files that no longer exist in cpython 3.6.9
<bbot2_> Started: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/6399 [mattip: check removed files, py3.6]
<kenaan> arigo sandbox-2 322c4bfc9c42 /rpython/: Revert the changes to backendopt done in 906b820ecdac; instead move the review-checking before running backendopt...
<mattip> the text for `python3 --help` and pypy3-c --help` is slightly different for -O and -OO
<mattip> cpython says:
<mattip> something about adding opt-1 or opt-2 to the pyc file, and also ignores __debug__ statements
<mattip> should we sync to that, or do we still only do the python2 optimizations?
<kenaan> mattip py3.6 39096734e7bc /pypy/interpreter/app_main.py: pypy3 -b and pypy3 -d now exist, add them to the --help text
tsaka__ has quit [Ping timeout: 245 seconds]
<kenaan> arigo sandbox-2 f4ba641484fa /rpython/translator/sandbox/graphchecker.py: Write docs about the @sandbox_review() and llexternal(sandboxsafe=..).
<bbot2_> Failure: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/6399 [mattip: check removed files, py3.6]
<kenaan> mattip py3.6 da64fb221689 /lib-python/conftest.py: fixup conftest for removed files
<bbot2_> Started: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/6400 [mattip: check removed files, py3.6]
tsaka__ has joined #pypy
tsaka__ has quit [Ping timeout: 268 seconds]
<kenaan> arigo py3.6-sandbox-2 dcecc1d7905b /: hg merge sandbox-2
<kenaan> arigo sandbox-2 a066296c84d2 /rpython/rlib/: More sandbox_review in rlib for py3.6
<kenaan> arigo py3.6-sandbox-2 1c3f982ecaec /rpython/rlib/: hg merge sandbox-2
<kenaan> arigo py3.6-sandbox-2 6dcefdad5651 /pypy/module/: More sandbox_reviews
<kenaan> arigo py3.6-sandbox-2 3a1756763860 /pypy/module/: Found out there are two versions of os.urandom() around, and figured out when one is shadowed by the other
<mattip> cfbolz: 520b3c9072f2 seems to be causing some test failures
<mattip> it also seems to block importing the test file lib-python/2.7/test/test_int_literal.py
<mjacob> arigato: i think that it's "utf8" on python 2 and "utf-8" on python 3
<mjacob> (cpython 2 / cpython 3)
<mjacob> arigato: some of the error messages seem to come from rpython, so we have to think how to call it there
<mjacob> the file name was renamed between 3.5 and 3.6
<mjacob> tracking the renames is hard :(
<mjacob> and it became harder after cpython switched to git
<cfbolz> mattip: sorry, will fix
<mattip> no hurry, just a "heads up"
<bbot2_> Failure: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/6400 [mattip: check removed files, py3.6]
<kenaan> cfbolz default 8a5b5159abd4 /rpython/rlib/rbigint.py: remove duplicate import
<kenaan> cfbolz default 0d2efab3484a /rpython/rlib/: fix untested rewind method
<kenaan> cfbolz default 7850e3eaeff8 /rpython/rlib/rarithmetic.py: remove pdb :-(
<arigato> mattip: needs to be checked but I think that pypy3 tries to do really the same as cpython3 for -O and -OO
<arigato> mjacob: yes, I guessed something similar, though maybe this particular error message used to contain "utf8" in 3.x for x < 6 or something
<arigato> historically it was not very consistent, and it seems they're improving that
<mjacob> no, here the problem is that it was modified in pypy (in fbe8e328bbe8)
<mattip> things I learned: -O produces a pyc file with a opt-1 in the name in the __pycache__ directory on cpython3 and pypy3
<mattip> __init__.cpython-36.opt-1.pyc and __init__.pypy3-72.opt-1.pyc
<kenaan> mattip py3.6 c919b265937a /pypy/interpreter/app_main.py: synch text of -O, -OO options to cpython, clean extraneous \n\
tsaka__ has joined #pypy
Dejan has joined #pypy
<Dejan> meep meep
lritter has joined #pypy
<kenaan> mattip py3.6 50fa3485909f /pypy/objspace/std/: test, fix cpython3 exception compatibility
<kenaan> mattip default 2fc0a2974836 /rpython/rlib/test/test_rbigint.py: remove pdb from test
<Dejan> I wish to thank you guys for the aarch64 support
<mattip> Dejan: is it working for you?
<Dejan> I use a nightly build from few days ago
<Dejan> so far so good
<mattip> we would love to hear more, especially if it is good, and even better if there are real world benchmarks
<cfbolz> Dejan: cool!
<Dejan> I have a VPS on Scaleway with 6 AArch64 vCPUs, and few tiny Python services running there, nothing fancy
<Dejan> they are all running on pypy3 now
<Dejan> it is just some personal stuff, nothing serious
<mattip> can you share what happened when you moved from cpython3 to pypy3?
<mattip> memory, cpu?
dddddd has joined #pypy
<Dejan> i did not look at monitor/cpu :) i just wanted my service to work with pypy3 :D
<Dejan> and it did
<Dejan> Python 3.6.9 (1cd037049338, Aug 22 2019, 01:13:56)
<Dejan> [PyPy 7.2.0-alpha0 with GCC 7.4.0]
<Dejan> this is what I am using there
<Dejan> I tried Celery 4.3.0 with Redis as broker
<Dejan> managed to run few dummy tasks without problems
tsaka_ has joined #pypy
tsaka__ has quit [Ping timeout: 272 seconds]
<mattip> cool, thanks for the feedback. Would be nice if you could compare to cpython3, we love getting real-world data
<mattip> but I understand that means setting up monitoring and then running them on some real tasks
<Dejan> i was wondering if PyPy could in theory do some internal optimization with IO - to automatically use memoryviews when it detects usage of buffers
<cfbolz> mattip: thanks matti, too hot to think it seems :-(
<Dejan> i am boiling here in the office... (London)
tsaka__ has joined #pypy
tsaka_ has quit [Read error: Connection reset by peer]
* mattip updated the aarch64 buildslave to use latest pypy2 build, maybe that will improve the success rate for py3.6 builds
ionelmc has joined #pypy
<tos9> github actions has support for pypy, that's nice
<tos9> maybe they are sending an olive branch :)
the_rat has joined #pypy
dddddd has quit [Quit: Hasta otra..]
dddddd has joined #pypy
<ionelmc> what make cffi produce a .py instead of a .so when using a builder (eg:cffi_modules=[i + ':ffi' for i in glob('src/*/_*_build.py')] in setup.py)
<kenaan> rlamy py3.6 92ad09ea1c06 /lib-python/3/collections/__main__.py: Remove file deleted in CPython
<kenaan> rlamy py3.6 cfffac8c5062 /lib-python/3/asyncio/futures.py: Remove accidentally duplicated definition for isfuture()
<tos9> ionelmc: probably would need to see the code there, nothing I know of, but yeah
<tos9> ionelmc: doubt it'd be related to using a list comp of course, so it's something about one of those files themselves presumably
<mattip> ionelmc: ffi.cdef / ffi.set_source / ffi.compile will produce an importable so
<mattip> ffi.cdef / ffi.dlopen will not compile at all, so it will remain a py file
<kenaan> rlamy py3.6 79ea93489fc4 /lib-python/3/ssl.py: fix bad merge
<cfbolz> tos9: cool, link?
xorAxAx has quit [Quit: Idle timeout reached: 172800s]
<ionelmc> ah ... i was using set_source("stuff", None)
<ionelmc> now it makes sense
<ionelmc> could i produce universal wheels in theory? without compilation the resulting py file only has a bunch of _cffi_backend calls - that should be cross platform right?
<mattip> cfbolz: I think github actions is built on "azure pipelines" which is travisCI but from Microsoft, and offers windows, macos and linux images
<mattip> for instance, here is the vs2019 image for windows, with pypy 2.7.13 and 3.5.3
<mattip> the linux 16.04 has pypy2 7.1 and pypy3 7.0 (scroll to the bottom of the link)
<cfbolz> mattip: cool, thanks. I should tweet about that
<mattip> ionelmc: once you do ffi.compile, you get a c-extension module compiled for a platform
<mattip> without compilation it should be pure python
<mattip> you may have to "trick" the call to ffi.dlopen() to find the right thing though
Dejan has quit [Quit: Leaving]
<kenaan> rlamy py3.6 b70c9c1a4b02 /lib-python/3/test/: fix old merge cruft
<arigato> more on git-vs-mercurial in this old post, which at least gives me some hint about how you're supposed to use git: https://jhw.dreamwidth.org/1868.html
<kenaan> rlamy py3.6 dfa10ae95bae /lib-python/3/ctypes/test/: Don't use @xfail for tests that can't possibly work on pypy
<kenaan> rlamy py3.6 18630a74b4d0 /lib-python/3/: Use @support.refcount_test to skip tests relying on sys.getrefcount()
xorAxAx has joined #pypy
<xorAxAx> .
<bbot2_> Started: http://buildbot.pypy.org/builders/own-linux-x86-64/builds/7643 [pjenvey: force build, stdlib-2.7.16]
<bbot2_> Started: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/6401 [pjenvey: force build, stdlib-2.7.16]
<bbot2_> Failure: http://buildbot.pypy.org/builders/own-linux-x86-64/builds/7643 [pjenvey: force build, stdlib-2.7.16]
xcm has quit [Remote host closed the connection]
xcm has joined #pypy
<ronan> aaaargh, the logic for calling error handlers in the unicodehelper.py encoders seems completely broken
<ronan> though I wonder why it hasn't caused more issues
<ronan> well, it's only utf8_encode_utf_16_helper() that's wrong, utf8_encode_utf_32_helper() is correct
ceridwen has quit [Quit: Ex-Chat]
ajlawrence has joined #pypy
<ajlawrence> What is a UnionError? How do I interpret the trace produced?
<simpson> Usually it means that your code gave two different types to a single value.
<ajlawrence> Oh dear
ajlawrence has quit [Remote host closed the connection]
<bbot2_> Failure: http://buildbot.pypy.org/builders/pypy-c-jit-linux-x86-64/builds/6401 [pjenvey: force build, stdlib-2.7.16]
antocuni has joined #pypy
<tos9> (i.e. basically saying: os: [ubuntu-latest, windows-latest, macOS-latest] python-version: [pypy2, pypy3, 3.5, 3.6, 3.7] gets you a build that in theory runs on that cross product)
<tos9> in practice I haven't gotten a successful run yet, but... tomorrow, tomorrow will be the day
speeder39_ has joined #pypy
antocuni has quit [Ping timeout: 272 seconds]
antocuni has joined #pypy
antocuni has quit [Ping timeout: 245 seconds]
jcea has joined #pypy