Skip to content

Tests errors related to 'MarkDecorator' #13182

Closed

Description

@ArchangeGabriel

Bug report

Bug summary

During ArchLinux packaging builds, we have a bunch of errors related to 'MarkDecorator'.

Three different errors:

E TypeError: object of type 'MarkDecorator' has no len()
E AttributeError: 'MarkDecorator' object has no attribute 'encode'
E TypeError: cannot concatenate 'str' and 'MarkDecorator' objects

that lead to think it is supposed to be a string but actually is not.

Full log (minus irrelevant ImageComparisonFailure: images not close due to fonts/freetype2 differences) available here: https://paste.xinu.at/KRdO/

Likely yet another pytest issue?

Matplotlib version

Activity

  1. added this to the v2.2.4 milestone on Jan 14, 2019
  2. ArchangeGabriel commented on Jan 14, 2019

    @ArchangeGabriel
    ContributorAuthor

    Could be related to https://github.com/matplotlib/matplotlib/pull/12297/files, will try to backport the changes locally and see what it gives.

  3. ArchangeGabriel commented on Jan 16, 2019

    @ArchangeGabriel
    ContributorAuthor

    First twos (which were ERRORS, not FAILURES) are indeed solved by backporting #12297. The last one, which is a FAILURE, still remains though:

    ________________________ test_mixedsubplots[extension2] ________________________
    [gw4] linux2 -- Python 2.7.15 /usr/bin/python2
    
    self = <matplotlib.testing.decorators._ImageComparisonBase object at 0x7fcc0038d5d0>
    idx = 0, baseline = 'mixedsubplot'
    extension = MarkDecorator(mark=Mark(name='xfail', args=('svg',), kwargs={'strict': False}))
    
        def compare(self, idx, baseline, extension):
            __tracebackhide__ = True 
            fignum = plt.get_fignums()[idx]
            fig = plt.figure(fignum)
        
            if self.remove_text:
                remove_ticks_and_titles(fig)
        
            actual_fname = (
    >           os.path.join(self.result_dir, baseline) + '.' + extension)
    E       TypeError: cannot concatenate 'str' and 'MarkDecorator' objects
    
    lib/matplotlib/testing/decorators.py:284: TypeError
    

    Interestingly, this is the only test showing this error in our builds, while in #13181 they are a lot of them.

    EDIT: The multiple failures in #13181 AppVeyor are due to image comparison tests being skipped (instead of properly run in the other builds), and skipping failing (but likely for the same reason as here).

  4. ArchangeGabriel commented on Jan 17, 2019

    @ArchangeGabriel
    ContributorAuthor

    Should be fixed by 13bde8f + bd7e729.

  5. ArchangeGabriel commented on Jan 17, 2019

    @ArchangeGabriel
    ContributorAuthor

    Confirmed on the ArchLinux build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions