Skip to content

Incorrect processing of plot_args when using data argument #11389

Closed

Description

@timhoffm

Bug report

As opposed to dicts, pandas.DataFramse etc. name in container does not check if a field exists in a numpy array. Hence, mustn't do args[1] in data unconditionally on the data type. This was spotted due to the indirectly related warning:

lib/matplotlib/tests/test_axes.py::test_structured_data
  /home/travis/build/matplotlib/matplotlib/lib/matplotlib/axes/_axes.py:52: FutureWarning: elementwise == comparison failed and returning scalar instead; this will raise an error or perform elementwise comparison in the future.
    if (not args[1] in data and

Possible fixes:

Activity

  1. added
    Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions.
    on Jun 6, 2018
  2. added this to the v2.2.3 milestone on Jun 6, 2018
  3. tacaswell commented on Jun 6, 2018

    @tacaswell
    Member

    I have a memory of a PR special casing structured arrays recently....

  4. jklymak commented on Jul 16, 2018

    @jklymak
    Member

    @timhoffm is this closed by #10872?

  5. timhoffm commented on Jul 16, 2018

    @timhoffm
    MemberAuthor

    Yes, fixed by #10872.

  6. removed
    Release criticalFor bugs that make the library unusable (segfaults, incorrect plots, etc) and major regressions.
    on Sep 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions