Easy and recommended way to get path of datafile within package?

I’ve wondered about this as well. From the language it sounds like the package can somehow be installed into a wheel. i.e. the code is somehow still inside the wheel even when it’s installed then executed. I’m not sure if this can be the final distribution state of a package…

Another possibility is that maybe during the installation of a package that is distributed as a wheel it is possible to execute code within the wheel before it’s finally deployed onto a file system for some reason.

But I know very very little about this. This is just what I’ve inferred from language I’ve seen around this particular subject…

I also don’t know a use case for when you would be executing code within a .zip…