This is an archive of the discontinued LLVM Phabricator instance.

Added an empty __init__.py file to the MLIR Python bindings
ClosedPublic

Authored by superbobry on Mar 31 2022, 2:28 AM.

Details

Summary

While not strictly required after PEP-420, it is better to have one, since not
all tooling supports implicit namespace packages.

Diff Detail

Event Timeline

superbobry created this revision.Mar 31 2022, 2:28 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 31 2022, 2:28 AM
superbobry requested review of this revision.Mar 31 2022, 2:28 AM
ftynse accepted this revision.Mar 31 2022, 2:37 AM
This revision is now accepted and ready to land.Mar 31 2022, 2:37 AM
This revision was landed with ongoing or failed builds.Mar 31 2022, 2:57 AM
This revision was automatically updated to reflect the committed changes.

Could we revert this and discuss? This source tree was designed explicitly to be namespace packaged, and iirc, there are cases where that is important: with an init file at the root, the entire tree must come from one directory. Further, since no changes were made to the build files, I don't even see how this is doing anything.

I'm not opposed to deciding differently or learning something new, but the description provides no material to do so. If re-applying, please include notes about which tools or workflows are having problems and reference any source for why "it is better to have one".

While this may look cosmetic, adding init files to namespace packaged is a functional change.