[ANN] PatModules.jl: a better module system for Julia

Thanks for the interest and welcomes everyone.

Of course this may not be for everybody, and I’m not here to try and convince anyone to switch. Just making something available for those who may be interested. :slight_smile:

Still, for those curious, to give an explicit example of the sort of thing that this tries to fix - what is OrdinaryDiffEqConstantCache here? (From OrdinaryDiffEq.jl.)

It’s just implicitly assumed to exist, but the reader is given no help finding where it comes from. It’s unsurprising to find that this file is included in the wrapping OrdinaryDiffEq.jl, but that doesn’t really help. All we know is that OrdinaryDiffEqConstantCache is something else that’s included in the same file, which prompts a bit of a manhunt.

That’s probably no issue if you’re intimately familiar with the package (maybe you are the developer) and have pretty much the whole thing in your head anyway, but it’s making life pretty difficult for everyone else. This is no bash on Chris/SciML by the way, I continue to be very impressed with the project.

I’m aware of #4600. Honestly I’m not a fan. At the moment include just handles files; import/using just handles modules. Muddying that seems like a mistake.
EDIT: #4600’s treatment of files/folders/modules is actually exactly what PatModules does – that’s clearly a good thing to my mind. It’s just the overloading of import/using that seems off to me.

5 Likes