This hack was necessary for django 2.x[1] which was the default `django`
version (i.e. current LTS) when this fix was needed. However, 2.x is now
EOL and not packaged anymore and mailman is running with django3, so
this can be dropped.
[1] https://github.com/psycopg/psycopg2/issues/1293
When having a patch for a python module that should only be used for
mailman, but for nothing else, it's now possible to apply it like this:
self: super: {
mailmanPackages = super.mailmanPackages.extend (mailmanSelf: mailmanSuper: {
python3 = mailmanSuper.python3.override {
overlay = pythonSelf: pythonSuper: {
psycopg2 = /* ... */;
};
};
});
}
The underlying issue is that the `packageOverrides`-mechanism of
`pkgs.python3` doesn't compose, so an optional overlay is manually
applied to the `python3` used for mailman.
* Removed unused `.package`-option.
* Added explicit postgresql support.
* Create a new meta-package for mailman to make sure each component has
the **same** python and packages can be downgraded if needed (e.g.
psycopg2 or sqlalchemy) without interfering with `pythonPackages` in any way.
* Document why certain python overrides are needed.
Closes#170035Closes#158424