pytest-dev / py

Python development support library (note: maintenance only)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`pyimport` fails for intentionally mismatching source/bytecode suffixes

brandonwillard opened this issue · comments

A check occuring here assumes that a module loaded from bytecode with a __file__ attribute ending in pyc must have a source file with suffix .py. This is not the case for the code I'm working on (https://github.com/hylang/hy), which has source files with intentionally different suffixes that compile to .pyc, and ultimately causes pyimport to fail.

Pytest no longer uses this code path