Skip to content

Python-3 projects depending on matplotlib & plot-directive fail indeterministically #1056

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ankostis opened this issue Dec 1, 2014 · 5 comments
Labels
Needed: more information A reply from issue author is required

Comments

@ankostis
Copy link
Contributor

ankostis commented Dec 1, 2014

If a python-3 project needs matplotlib's plot-directive extension, fails on install because the native-library freetype2 is not installed:

Notice that freetype is indeed installed, so python2 projects are not affected by this bug
(see ie build: https://readthedocs.org/builds/xray/1889182/ collected by #1021)

The error produced is the following:

Setup Output

...

requirements
-----
...
BUILDING MATPLOTLIB
            matplotlib: yes [1.4.2]
                python: yes [3.4.0 (default, Apr 11 2014, 13:05:11)  [GCC
                        4.8.2]]
              platform: yes [linux]

REQUIRED DEPENDENCIES AND EXTENSIONS
                 numpy: yes [not found. pip may install it below.]
                   six: yes [six was not found.]
              dateutil: yes [dateutil was not found. It is required for date
                        axis support. pip/easy_install may attempt to
                        install it after matplotlib.]
                  pytz: yes [pytz was not found. pip will attempt to install
                        it after matplotlib.]
               tornado: yes [tornado was not found. It is required for the
                        WebAgg backend. pip/easy_install may attempt to
                        install it after matplotlib.]
             pyparsing: yes [pyparsing was not found. It is required for
                        mathtext support. pip/easy_install may attempt to
                        install it after matplotlib.]
                 pycxx: yes [Official versions of PyCXX are not compatible
                        with matplotlib on Python 3.x, since they lack
                        support for the buffer object.  Using local copy]
                libagg: yes [pkg-config information for 'libagg' could not
                        be found. Using local copy.]
              freetype: no  [The C/C++ header for freetype2 (ft2build.h)
                        could not be found.  You may need to install the
                        development package.]    
    OPTIONAL LATEX DEPENDENCIES
                dvipng: yes [version 1.14]
           ghostscript: yes [version 9.10]
                 latex: yes [version 3.1415926]
               pdftops: no

============================================================================
                        * The following required packages can not be built:
                        * freetype
@ankostis
Copy link
Contributor Author

ankostis commented Dec 1, 2014

I think i made it work, just by replicating the build i attached in the description:

No virtualenv, no nothingBUT with requirements.txt(see my next comment), check https://readthedocs.org/builds/wltp/1912467/ (which for some reason is stuck).
But i've seen it succeeding again in the past. Is it possible that certain builders have a more up-to-date setup?

@ankostis
Copy link
Contributor Author

ankostis commented Dec 2, 2014

Well i think i nailed it!
There are multiple issues related to this heisenbug:

  1. It works only without virtualenv BUT with requirements file listing matplotlib and numpy.
    Note that from the rtd-manuals one would think that the requirements file would be ignored when not using a virtualenv, so this part of the documentation needs attention.
  2. (i think that) Indeterministically, the RTD flips the virtualenv flag from build to buld, and then it suddenly starts to fail. I will keep an eye if that happens again.
  3. Finally you have to remember to wipe your slugs from the build-servers.
  4. But i'm still not 100% that this is the case! For instance, build 1913082 although it states it failed, it produced all docs and the error was first seen!
  5. Then a new commit build 1913182 with minute changes, and boom(!), finds almost nothing preinstalled and starts building mock, matplotlib etc as if virtualenv is enabled. But it's not!
    What is happening?

Some more builds to investigate:

@ankostis ankostis changed the title Python-3 projects depending on matplotlib & plot-directive fail due to missing freetype2 native-library Python-3 projects depending on matplotlib & plot-directive fail **indeterministically** Dec 2, 2014
@ankostis ankostis changed the title Python-3 projects depending on matplotlib & plot-directive fail **indeterministically** Python-3 projects depending on matplotlib & plot-directive fail indeterministically Dec 2, 2014
@ankostis
Copy link
Contributor Author

Any feedback on this?

@gregmuellegger
Copy link
Contributor

@ankostis I'm wading through old tickets and discovered that this was never responded to yet. Sorry for this! We updated the matplotlib on the server and some of its configuration lately so I'm wondering if that issue still exists for you and needs further investigation by readthedocs?

@gregmuellegger gregmuellegger added the Needed: more information A reply from issue author is required label Jul 20, 2015
@ankostis
Copy link
Contributor Author

Sorry, v cannot provide confirmation any more.
Have switched to using Python-2 for working with matplotlib in rtd.

Feel free to close it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needed: more information A reply from issue author is required
Projects
None yet
Development

No branches or pull requests

2 participants