Re: [Mailman-Developers] Python 3

On Dec 26, 2014, at 10:32 PM, Aurelien Bompard wrote:
Right, I'm having issues too with the config file not being initalized. I'll have a closer look.
Awesome, thanks.
I wonder if it would be possible to refactor some of this code into separate libraries, which would reduce the surface area for bilingual support. The config object is probably the tricky part here, but also the Message class has a lot less in it now that we don't have to worry about all that unicode stuff. Really, it's essentially just the .sender and .senders properties and some backward compatible pickle support (unnecessary atm for MM3 and probably not much needed going forward, unless the stdlib Message object in some future Python grows internal attributes that break unpickling - I'll certainly test that against what will be Python 3.5).
But there could be! I took a very quick look at HK (but not KittyStore) and it doesn't look like you need much. What if I added a REST API to access the core's system configuration settings? They would be read-only, and I would only start with the minimum of what HK needs. I think it's probably dangerous in the long term to expect the core's internal config API to remain stable, so accessing that through REST would provide the guarantees you need, in addition to decoupling HK from the core.
Yep, I missed that. Is it possible to feed HK messages out-of-process? E.g. via the command line? If so, then we write HK's IArchiver implementation to make those out of process calls, and we can even pull that bit into the core.
I would be happy to help with that.
Cheers, -Barry

That would work.
Yep, I missed that. Is it possible to feed HK messages out-of-process? E.g. via the command line?
Not now. Would an LMTP server be appropriate? If so, could Mailman's internal LMTP server be split off into a Py2-compatible library? What protocol would be best suited in your opinion?
A.

Barry Warsaw writes:
Let's please take some care to think about this. ISTM this is like the Nth time we've bumped into "you need to be core to access config data".
This *may* be good enough (what with the guarantees the REST interface provides), but I think this really needs to take a generic approach, and some care should be taken to confirm that it is generic. It should eventually be TOOWTDI (ie, Postorius, mailman.client, and the new CLI should all go this way).

On Dec 27, 2014, at 12:48 PM, Stephen J. Turnbull wrote:
No more! See my other follow up. And there's no restriction on values. Sometimes generic is easier than specific (shouldn't that be a Zen of Python? :).
Hopefully Aurelien can confirm that this will be enough for HK, but of course Postorious can use it now too.
Cheers, -Barry

That would work.
Yep, I missed that. Is it possible to feed HK messages out-of-process? E.g. via the command line?
Not now. Would an LMTP server be appropriate? If so, could Mailman's internal LMTP server be split off into a Py2-compatible library? What protocol would be best suited in your opinion?
A.

Barry Warsaw writes:
Let's please take some care to think about this. ISTM this is like the Nth time we've bumped into "you need to be core to access config data".
This *may* be good enough (what with the guarantees the REST interface provides), but I think this really needs to take a generic approach, and some care should be taken to confirm that it is generic. It should eventually be TOOWTDI (ie, Postorius, mailman.client, and the new CLI should all go this way).

On Dec 27, 2014, at 12:48 PM, Stephen J. Turnbull wrote:
No more! See my other follow up. And there's no restriction on values. Sometimes generic is easier than specific (shouldn't that be a Zen of Python? :).
Hopefully Aurelien can confirm that this will be enough for HK, but of course Postorious can use it now too.
Cheers, -Barry
participants (3)
-
Aurelien Bompard
-
Barry Warsaw
-
Stephen J. Turnbull