This attribute isn't present in PyOxidizer when loading modules
from memory.
Before, this code was crashing under PyOxidizer. After, it simply
yields unexpected results. This still isn't great (we need a better
mechanism to discover extensions when modules aren't loaded from
the filesystem). But it is strictly better since we no longer
get tracebacks.
Maybe mention that the result if "wrong" here? If I understand you commit message fine, this change does not make this code work as expected. It only prevent a crash. If I got this right, it would be useful to mention it in the comment.