[Matplotlib-devel] Pull requests for table.py

swfiua at gmail.com swfiua at gmail.com
Thu Jun 13 13:35:58 EDT 2019


On Thu, Jun 13, 2019 at 11:42 AM Antony Lee <antony.lee at institutoptique.fr>
wrote:

> Hi John,
>
> Thanks for your writeup.  It provides an interesting historical view on
> one of the oldest parts of the Matplotlib codebase, which is always nice
> read about.
>
> It is great that you intend to work again on table.py
>

I made no commitment to work on this again in the future ;)


> (which was mostly abandoned by the other core devs), but I am not sure to
> what extent the new API you propose has been stabilized, or whether you are
> still experimenting with it.  There are also other issues with the API
> design (e.g. https://github.com/matplotlib/matplotlib/issues/12931) that
> you may, perhaps, want to revisit?
>

There are four (now 5) pull requests with various API changes / bug fixes
for consideration -- just created one of issue 12931

Those requests themselves resulted in other discussion about API changes
(eg should visible_edges change its name to border?) -- so some on-going
experimentation.

Some of the bugs are such that they can't really be fixed without impacting
the API.

There is a fair bit to discuss here -- most of the feedback that I have
received so far has been about cosmetic stuff with very little comment on
the substance of the changes.

>From my point of view I am pretty much done experimenting at this point.



> As you may have noticed, making backwards incompatible changes to
> Matplotlib is a bit of an onerous process (due to the deprecation process,
> the baseline images problem, etc.).
>

Indeed.   Which is a big reason these problems have languished so long.

Just because the process is onerous, doesn't mean it shouldn't be done.

The baseline_images problem feels like the tail wagging the dog.


>   Given that table.py is fairly self-contained, perhaps you may want to
> consider moving it to its own separate package?
>


>  i.e. something published separately on PyPI (let us know if you need any
> help for that), so that one would do (for example)
>
> from mpltable import table
> table(...)
>
>
> This way you can play with the API in whatever way you want, and we could
> just point to your package as the "new, more modern" way to make tables
> with Matplotlib, and possibly import it back to the main repo as a single
> PR once everything is stabilized.
>

Whilst I can see the attraction with this approach, I am not really keen on
it.

Based on my experiences so far trying to help out here, there is no
guarantee that the new table would ever make it into the code and that
would leave me with an increasing maintenance burden of pulling on-going
changes to the code, whilst leaving matplotlib with a buggy and ugly table.

There are pros and cons with one big fix v a bunch of smaller ones.   I
lean towards the several smaller fix approach eg issue 12931 should
probably be done as a standalone request, making it easier to back out
later if it becomes necessary.

John


>
> Antony
>
> On Thu, Jun 13, 2019 at 5:01 PM swfiua at gmail.com <swfiua at gmail.com> wrote:
>
>> Hi,
>>
>> I just wanted to provide some background on the recent flurry of fixes to
>> table.py and the history behind the code.
>>
>> See attached pdf.
>>
>> There are 3 main themes to the changes:
>>
>> * better automatic setting of the font size
>> * change how horizontal padding around cell text is calculated
>> * add ability to specify cell edge colours
>>
>> John
>> _______________________________________________
>> Matplotlib-devel mailing list
>> Matplotlib-devel at python.org
>> https://mail.python.org/mailman/listinfo/matplotlib-devel
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/matplotlib-devel/attachments/20190613/67e41b26/attachment.html>


More information about the Matplotlib-devel mailing list