Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e768c6f

Browse files
committed
Merge pull request #1 from matplotlib/master
Updating code
2 parents 5774fde + f859b74 commit e768c6f

File tree

3,768 files changed

+424062
-374741
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,768 files changed

+424062
-374741
lines changed

.coveragerc

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[run]
2+
source=matplotlib
3+
[report]
4+
omit =
5+
lib/matplotlib/tests/*
6+
lib/matplotlib/testing/*
7+
8+
exclude_lines =
9+
raise NotImplemented

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
* text=auto
2+
lib/matplotlib/_version.py export-subst

.github/ISSUE_TEMPLATE.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
To help us understand and resolve your issue please check that you have provided
2+
the information below.
3+
4+
- [ ] Matplotlib version, Python version and Platform (Windows, OSX, Linux ...)
5+
- [ ] How did you install Matplotlib and Python (pip, anaconda, from source ...)
6+
- [ ] If possible please supply a [Short, Self Contained, Correct, Example](http://sscce.org/)
7+
that demonstrates the issue i.e a small piece of code which reproduces the issue
8+
and can be run with out any other (or as few as possible) external dependencies.
9+
- [ ] If this is an image generation bug attach a screenshot demonstrating the issue.
10+
- [ ] If this is a regression (Used to work in an earlier version of Matplotlib), please
11+
note where it used to work.

.gitignore

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
#########################################
2+
# OS-specific temporary and backup files
3+
.DS_Store
4+
15
#########################################
26
# Editor temporary/working/backup files #
37
.#*
@@ -8,6 +12,8 @@
812
*.kdev4
913
.project
1014
.pydevproject
15+
*.swp
16+
.idea
1117

1218
# Compiled source #
1319
###################
@@ -30,8 +36,10 @@ doc/_build
3036
dist
3137
# Egg metadata
3238
*.egg-info
39+
.eggs
3340
# tox testing tool
3441
.tox
42+
setup.cfg
3543

3644
# OS generated files #
3745
######################
@@ -53,10 +61,25 @@ doc/examples
5361
doc/_templates/gallery.html
5462
doc/users/installing.rst
5563
doc/_static/matplotlibrc
64+
doc/pyplots/tex_demo.png
5665
lib/dateutil
5766
examples/*/*.pdf
5867
examples/*/*.png
5968
examples/tests/*
6069
!examples/tests/backend_driver.py
6170
texput.log
71+
texput.aux
6272
result_images
73+
74+
# Nose generated files #
75+
########################
76+
.coverage
77+
.coverage.*
78+
cover/
79+
.noseids
80+
81+
# Conda files #
82+
###############
83+
__conda_version__.txt
84+
lib/png.lib
85+
lib/z.lib

.mailmap

Lines changed: 73 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,74 @@
1-
John Hunter <[email protected]> jdh2358 <[email protected]>
2-
Michael Droettboom <[email protected]> Michael Droettboom <[email protected]>
3-
Jouni K. Seppänen <[email protected]> Jouni K. Seppänen <[email protected]>
4-
Ben Root <[email protected]> Benjamin Root <[email protected]>
1+
2+
3+
Ariel Hernán Curiale <[email protected]>
4+
5+
6+
Casper van der Wel <[email protected]>
7+
8+
Cimarron Mittelsteadt <[email protected]>
9+
Daniel Hyams <[email protected]>
10+
Daniel Hyams <[email protected]> Daniel Hyams <dhyams@gitdev.(none)>
11+
12+
13+
14+
15+
16+
17+
Francesco Montesano <[email protected]> montefra <[email protected]>
18+
Jaime Fernandez <[email protected]>
19+
Jake Vanderplas <[email protected]>
20+
21+
22+
James R. Evans <[email protected]>
23+
24+
Jeffrey Bingham <[email protected]>
25+
Jens Hedegaard Nielsen <[email protected]>
26+
Jens Hedegaard Nielsen <[email protected]> <[email protected]>
27+
John Hunter <[email protected]>
28+
Jorrit Wronski <[email protected]>
29+
Jouni K. Seppänen <[email protected]>
30+
Joseph Fox-Rabinovitz <[email protected]> Mad Physicist <[email protected]>
31+
32+
33+
34+
35+
Leeonadoh <[email protected]>
36+
37+
Levi Kilcher <[email protected]>
38+
Martin Fitzpatrick <[email protected]> <[email protected]>
39+
Matthew Emmett <[email protected]>
40+
41+
Matthias Bussonnier <[email protected]>
42+
Michael Droettboom <[email protected]> <[email protected]>
43+
Michael Droettboom <[email protected]> Michael Droettboom <mdboom@debian-vm>
44+
Michiel de Hoon <[email protected]>
45+
Michiel de Hoon <[email protected]> Michiel de Hoon <[email protected]>
546
Michiel de Hoon <[email protected]> Michiel de Hoon <[email protected]>
6-
Kevin Davies <[email protected]> Kevin Davies <[email protected]>
7-
Christoph Gohlke <[email protected]> cgohlke <[email protected]>
47+
Michiel de Hoon <[email protected]> Michiel de Hoon <[email protected]>
48+
Michiel de Hoon <[email protected]> Michiel de Hoon <[email protected]>
49+
50+
51+
Nelle Varoquaux <[email protected]>
52+
Nic Eggert <[email protected]> Nic Eggert <[email protected]>
53+
Nic Eggert <[email protected]> Nic Eggert <[email protected]>
54+
Nicolas P. Rougier <[email protected]>
55+
OceanWolf <[email protected]>
56+
Patrick Chen <[email protected]>
57+
58+
Per Parker <[email protected]>
59+
Peter Würtz <[email protected]>
60+
61+
Phil Elson <[email protected]>
62+
63+
64+
Scott Lasley <[email protected]>
65+
66+
67+
Stefan van der Walt <[email protected]> <[email protected]>
68+
69+
Thomas A Caswell <[email protected]> Thomas A Caswell <[email protected]>
70+
Thomas A Caswell <[email protected]> Thomas A Caswell <[email protected]>
71+
Thomas A Caswell <[email protected]> Thomas A Caswell <“[email protected]”>
72+
Werner F Bruhin <[email protected]>
73+
Yunfei Yang <yangyunf@iits-b473-20053.(none)> Yunfei Yang <yangyunf@iits-b473-20057.(none)>
74+
Yunfei Yang <yangyunf@iits-b473-20053.(none)> Yunfei Yang <yangyunf@iits-b473-20061.(none)>

.travis.yml

Lines changed: 184 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,202 @@
1+
sudo: false
2+
3+
cache:
4+
directories:
5+
- $HOME/.ccache
6+
- $HOME/.cache/pip
7+
- $HOME/.cache/matplotlib
8+
9+
addons:
10+
apt:
11+
packages:
12+
- inkscape
13+
- libav-tools
14+
- gdb
15+
- mencoder
16+
- dvipng
17+
- pgf
18+
- lmodern
19+
- cm-super
20+
- texlive-latex-base
21+
- texlive-latex-extra
22+
- texlive-fonts-recommended
23+
- texlive-latex-recommended
24+
- texlive-xetex
25+
- graphviz
26+
- libgeos-dev
27+
# - fonts-humor-sans
28+
# sources:
29+
# - debian-sid
30+
131
env:
232
global:
333
- ARTIFACTS_AWS_REGION=us-east-1
434
- ARTIFACTS_S3_BUCKET=matplotlib-test-results
535
- secure: RgJI7BBL8aX5FTOQe7xiXqWHMxWokd6GNUWp1NUV2mRLXPb9dI0RXqZt3UJwKTAzf1z/OtlHDmEkBoTVK81E9iUxK5npwyyjhJ8yTJmwfQtQF2n51Q1Ww9p+XSLORrOzZc7kAo6Kw6FIXN1pfctgYq2bQkrwJPRx/oPR8f6hcbY=
636
- secure: E7OCdqhZ+PlwJcn+Hd6ns9TDJgEUXiUNEI0wu7xjxB2vBRRIKtZMbuaZjd+iKDqCKuVOJKu0ClBUYxmgmpLicTwi34CfTUYt6D4uhrU+8hBBOn1iiK51cl/aBvlUUrqaRLVhukNEBGZcyqAjXSA/Qsnp2iELEmAfOUa92ZYo1sk=
7-
8-
before_script:
9-
- gem install travis-artifacts
37+
- secure: "dfjNqGKzQG5bu3FnDNwLG8H/C4QoieFo4PfFmZPdM2RY7WIzukwKFNT6kiDfOrpwt+2bR7FhzjOGlDECGtlGOtYPN8XuXGjhcP4a4IfakdbDfF+D3NPIpf5VlE6776k0VpvcZBTMYJKNFIMc7QPkOwjvNJ2aXyfe3hBuGlKJzQU="
38+
- BUILD_DOCS=false
39+
- NUMPY=numpy
40+
- PANDAS=
41+
- NPROC=2
42+
- TEST_ARGS=--no-pep8
43+
- NOSE_ARGS="--processes=$NPROC --process-timeout=300"
1044

1145
language: python
1246

13-
python:
14-
- 2.6
15-
- 2.7
16-
- 3.2
17-
- 3.3
47+
matrix:
48+
include:
49+
- python: 2.7
50+
env: MOCK=mock NUMPY=numpy==1.6
51+
- python: 3.4
52+
- python: 3.5
53+
env: PANDAS=pandas NOSE_ARGS=--with-coverage
54+
- python: 3.5
55+
env: TEST_ARGS=--pep8
56+
- python: 3.5
57+
env: BUILD_DOCS=true
58+
- python: "nightly"
59+
env: PRE=--pre
60+
allow_failures:
61+
- python: "nightly"
62+
63+
before_install:
64+
- |
65+
# Install into our own pristine virtualenv
66+
source ci/travis/travis_tools.sh
67+
virtualenv --python=python venv
68+
source venv/bin/activate
69+
export PATH=/usr/lib/ccache:$PATH
1870
1971
install:
20-
- pip install -q --use-mirrors nose python-dateutil numpy pep8 pyparsing pillow
21-
- sudo apt-get update && sudo apt-get -qq install inkscape libav-tools
22-
- python setup.py install
72+
- |
73+
# Setup environment
74+
ccache -s
75+
# Upgrade pip and setuptools and wheel to get as clean an install as possible
76+
pip install --upgrade pip
77+
pip install --upgrade wheel
78+
pip install --upgrade setuptools
79+
- |
80+
# Install dependencies
81+
if [ -z "$PRE" ]; then
82+
# Install only from travis wheelhouse
83+
wheelhouse_pip_install $NUMPY $PANDAS;
84+
else
85+
# Fall back to pypi for non suported python versions
86+
pip install $PRE $NUMPY $PANDAS;
87+
fi
88+
# Always install from pypi
89+
pip install $PRE pep8 cycler coveralls coverage python-dateutil pyparsing!=2.0.4
90+
pip install pillow sphinx!=1.3.0 $MOCK numpydoc ipython colorspacious
91+
# Install nose from a build which has partial
92+
# support for python36 and suport for coverage output suppressing
93+
pip install git+https://github.com/jenshnielsen/nose.git@matplotlibnose
94+
95+
# We manually install humor sans using the package from Ubuntu 14.10. Unfortunatly humor sans is not
96+
# availible in the Ubuntu version used by Travis but we can manually install the deb from a later
97+
# version since is it basically just a .ttf file
98+
# The current Travis Ubuntu image is to old to search .local/share/fonts so we store fonts in .fonts
99+
if [[ $BUILD_DOCS == true ]]; then
100+
wget https://github.com/google/fonts/blob/master/ofl/felipa/Felipa-Regular.ttf?raw=true -O Felipa-Regular.ttf
101+
wget http://mirrors.kernel.org/ubuntu/pool/universe/f/fonts-humor-sans/fonts-humor-sans_1.0-1_all.deb
102+
mkdir -p tmp
103+
mkdir -p ~/.fonts
104+
dpkg -x fonts-humor-sans_1.0-1_all.deb tmp
105+
cp tmp/usr/share/fonts/truetype/humor-sans/Humor-Sans.ttf ~/.fonts
106+
cp Felipa-Regular.ttf ~/.fonts
107+
fc-cache -f -v
108+
else
109+
# Use the special local version of freetype for testing
110+
cp ci/travis/setup.cfg .
111+
fi;
112+
- |
113+
# Install matplotlib
114+
pip install -e .
115+
- |
116+
# Installing basemap from github until it's back on pypi
117+
# We have to install it after matplotlib to avoid pulling in MPL as
118+
# a dependency
119+
if [[ $BUILD_DOCS == true ]]; then
120+
pip install https://github.com/matplotlib/basemap/tarball/master
121+
fi;
23122
24123
script:
25-
- mkdir ../tmp_test_dir
26-
- cd ../tmp_test_dir
27124
# The number of processes is hardcoded, because using too many causes the
28125
# Travis VM to run out of memory (since so many copies of inkscape and
29126
# ghostscript are running at the same time).
30-
- echo Testing using 8 processes
31-
# Generate the font caches in a single process before starting the
32-
# multiple processes
33-
- python -c "from matplotlib import font_manager"
34-
- python ../matplotlib/tests.py -sv --processes=8 --process-timeout=300
127+
- |
128+
echo Testing using $NPROC processes
129+
echo The following args are passed to nose $NOSE_ARGS
130+
if [[ $BUILD_DOCS == false ]]; then
131+
export MPL_REPO_DIR=$PWD # needed for pep8-conformance test of the examples
132+
gdb -return-child-result -batch -ex r -ex bt --args python tests.py $NOSE_ARGS $TEST_ARGS
133+
else
134+
cd doc
135+
python make.py html --small
136+
# We don't build the LaTeX docs here, so linkchecker will complain
137+
touch build/html/Matplotlib.pdf
138+
# Linkchecker only works with python 2.7 for the time being
139+
deactivate
140+
source ~/virtualenv/python2.7/bin/activate
141+
pip install pip --upgrade
142+
pip install linkchecker
143+
linkchecker build/html/index.html
144+
fi
145+
- rm -rf $HOME/.cache/matplotlib/tex.cache
146+
- rm -rf $HOME/.cache/matplotlib/test_cache
35147

36148
after_failure:
37-
- tar cjf result_images.tar.bz2 result_images
38-
- travis-artifacts upload --path result_images.tar.bz2
39-
- echo "The result images will only be uploaded if they are on the matplotlib/matplotlib repo - this is for security reasons to prevent arbitrary PRs echoing security details."
40-
- echo https://s3.amazonaws.com/matplotlib-test-results/artifacts/${TRAVIS_BUILD_NUMBER}/${TRAVIS_JOB_NUMBER}/result_images.tar.bz2
149+
- |
150+
if [[ $BUILD_DOCS == false && $TRAVIS_PULL_REQUEST == false && $TRAVIS_REPO_SLUG == 'matplotlib/matplotlib' ]]; then
151+
gem install travis-artifacts
152+
cd $TRAVIS_BUILD_DIR/../tmp_test_dir
153+
tar cjf result_images.tar.bz2 result_images
154+
travis-artifacts upload --path result_images.tar.bz2
155+
echo https://s3.amazonaws.com/matplotlib-test-results/artifacts/${TRAVIS_BUILD_NUMBER}/${TRAVIS_JOB_NUMBER}/result_images.tar.bz2
156+
else
157+
echo "The result images will only be uploaded if they are on the matplotlib/matplotlib repo - this is for security reasons to prevent arbitrary PRs echoing security details."
158+
fi
159+
160+
after_success:
161+
- |
162+
if [[ $TRAVIS_PULL_REQUEST == false && $TRAVIS_REPO_SLUG == 'matplotlib/matplotlib' && $BUILD_DOCS == true && $TRAVIS_BRANCH == 'master' ]]; then
163+
cd $TRAVIS_BUILD_DIR
164+
echo "Uploading documentation"
165+
openssl aes-256-cbc -K $encrypted_cc802e084cd0_key -iv $encrypted_cc802e084cd0_iv -in ci/travis/matplotlibDeployKey.enc -out ci/travis/matplotlibDeployKey -d
166+
eval `ssh-agent -s`
167+
chmod 600 ci/travis/matplotlibDeployKey
168+
ssh-add ci/travis/matplotlibDeployKey
169+
cd ..
170+
git clone [email protected]:matplotlib/devdocs.git
171+
cd devdocs
172+
git checkout --orphan gh-pages
173+
git reset --hard first_commit
174+
cp -R ../matplotlib/doc/build/html/. .
175+
touch .nojekyll
176+
git config --global user.email "MatplotlibTravisBot@nomail"
177+
git config --global user.name "MatplotlibTravisBot"
178+
git config --global push.default simple
179+
git add .
180+
git commit -m "Docs build of $TRAVIS_COMMIT"
181+
git push --set-upstream origin gh-pages --force
182+
else
183+
echo "Will only deploy docs build from matplotlib master branch"
184+
fi
185+
if [[ $TRAVIS_PULL_REQUEST == false ]] && \
186+
[[ $TRAVIS_REPO_SLUG == 'matplotlib/matplotlib' ]] && \
187+
[[ $TRAVIS_BRANCH == 'master' ]]; then
188+
cd $TRAVIS_BUILD_DIR
189+
python ci/travis/travis_after_all.py
190+
export $(cat .to_export_back)
191+
if [ "$BUILD_LEADER" = "YES" ]; then
192+
if [ "$BUILD_AGGREGATE_STATUS" = "others_succeeded" ]; then
193+
echo "All Succeeded! Triggering OSX build..."
194+
./ci/travis/build_children.sh
195+
else
196+
echo "Some Failed; no OSX build"
197+
fi
198+
fi
199+
fi
200+
if [[ $NOSE_ARGS="--with-coverage" ]]; then
201+
coveralls
202+
fi

0 commit comments

Comments
 (0)