Skip to content

Commit

Permalink
Merge tag 'v0.11.0' into debian
Browse files Browse the repository at this point in the history
Version 0.11

* tag 'v0.11.0': (75 commits)
  RLS: Version 0.11
  BUG: respect passed chunksize in read_csv when using get_chunk function. close pandas-dev#3406
  DOC: Adding parameters to frequencies, offsets (issue pandas-dev#2916)
  BUG: fix broken validators again
  Revert "BUG: config.is_one_of_factory is broken"
  DOC: minor indexing.rst doc updates
  BUG: config.is_one_of_factory is broken
  TST: add test for config.is_one_of_factory
  DOC: RELEASE.rst mention new options disp.height/width and deprecated line_width
  BUG: fix validators for config options
  ENH: default dimensions for ip zmq frontends derive from disp.height/width defaults
  ENH: let display.notebook_repr_html control HTML repr in qtconsole again.
  ENH: fix df.repr() for scripts (keep GH1611 away), accept None for max_cols/rows
  BUG: rework get_console_size to handle cases properly
  ENH: optimize _repr_fits_horizontal_, to_string only on slice of interest
  BUG: for numerical option, sentry should be another Type, not 0
  TST: fix test_repr_non_interactive passing by accident
  TST: adjust tests to accommodate new defaults for display options
  ENH: Adjust height/width/max_rows defaults to match informal survey results
  CLN: convert test utilizing disp.line_width to disp.width
  ...
  • Loading branch information
yarikoptic committed Apr 23, 2013
2 parents f2ff2f7 + f9eea30 commit 388411e
Show file tree
Hide file tree
Showing 53 changed files with 1,717 additions and 893 deletions.
29 changes: 21 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,29 @@ language: python

python:
- 2.6
- 3.3

env:
global:
- NOSE_ARGS="not slow" # need at least this so travis page will show env column
- secure: "O04RU5QRKEDL/SrIWEsVe8O+1TxZqZQSa28Sd+Fz48NW/XddhefYyxzqcUXh\nk/NjWMqknJRQhApLolBianVpsE577OTllzlcyKn3nUL6hjOXcoszGaYray7S\niNGKGyO8xrtB/ZQDtmupz0ksK8sLoCTscdiGotFulczbx0zt+4g="
- secure: "PUJ9nC1/v2vpFUtELSoSjI53OHCVXfFTb8+t5lIGIqHtjUBkhiJSNPfCv8Bx\ndsdrx30qP8KsSceYzaa/bog6p8YNU1iih23S0KbjucutvA0LNHBTNvnxmjBR\nSJfKd5FmwnXvizRyghYBzmQ3NmGO7ADw2DBwKOhgGMqCHZ8Tlc8="
- secure: "IDcMrCCW+6pgJtsI3Q163OPc0iec1ogpitaqiRhHcrEBUCXZgVeclOeiZBlw\n/u+uGyW/O0NhHMaFXKB8BdDVwlQEEHv48syN6npS/A5+O6jriWKL4ozttOhE\npOlu+yLhHnEwx6wZVIHRTVn+t1GkOrjlBcjaQi+Z13G3XmDaSG8="
- secure: "Zu9aj0dTGpvMqT/HqBGQgDYl/v5ubC7lFwfE8Fqb0N1UVXqbpjXnNH/7oal1\nUsIT7klO++LWm+LxsP/A1FWENTSgdYe99JQtNyauW+0x5YR1JTuDJ8atDgx9\nSq66CaVpS5t+ov7UVm2bKSUX+1S8+8zGbIDADrMxEzYEMF7WoGM="
- secure: "AfIvLxvCxj22zrqg3ejGf/VePKT2AyGT9erYzlKpBS0H8yi5Pp1MfmJjhaR4\n51zBtzqHPHiIEY6ZdE06o9PioMWkXS+BqJNrxGSbt1ltxgOFrxW5zOpwiFGZ\nZOv1YeFkuPf8PEsWT7615mdydqTQT7B0pqUKK/d6aka4TQ/tg5Q="
- secure: "EM4ySBUusReNu7H1QHXvjnP/J1QowvfpwEBmjysYxJuq7KcG8HhhlfpUF+Gh\nLBzLak9QBA67k4edhum3qtKuJR5cHuja3+zuV8xmx096B/m96liJFTrwZpea\n58op3W6ZULctEpQNgIkyae20bjxl4f99JhZRUlonoPfx/rBIMFc="
- secure: "pgMYS/6MQqDGb58qdzTJesvAMmcJWTUEEM8gf9rVbfqfxceOL4Xpx8siR9B2\nC4U4MW1cHMPP3RFEb4Jy0uK49aHH10snwZY1S84YPPllpH5ZFXVdN68OayNj\nh4k5N/2hhaaQuJ6Uh8v8s783ye4oYTOW5RJUFqQu4QdG4IkTIMs="

- NOSE_ARGS="not slow" UPLOAD=true

matrix:
include:
- python: 2.7
env: NOSE_ARGS="not network" LOCALE_OVERRIDE="zh_CN.GB18030"
env: NOSE_ARGS="slow and not network" LOCALE_OVERRIDE="zh_CN.GB18030" FULL_DEPS=true UPLOAD=false
- python: 2.7
env: NOSE_ARGS="not slow" FULL_DEPS=true
env: NOSE_ARGS="not slow" FULL_DEPS=true UPLOAD=true
- python: 3.2
env: NOSE_ARGS="not slow" FULL_DEPS=true
env: NOSE_ARGS="not slow" FULL_DEPS=true UPLOAD=true
- python: 3.3
env: NOSE_ARGS="not slow" UPLOAD=true

# allow importing from site-packages,
# so apt-get python-x works for system pythons
Expand All @@ -26,11 +35,14 @@ virtualenv:
before_install:
- echo "Waldo1"
- echo $VIRTUAL_ENV
- df
- date
- export PIP_ARGS=-q # comment this this to debug travis install issues
- export APT_ARGS=-qq # comment this to debug travis install issues
# - export PIP_ARGS=-q # comment this this to debug travis install issues
# - export APT_ARGS=-qq # comment this to debug travis install issues
# - set -x # enable this to see bash commands
- source ci/before_install.sh # we need to source this to bring in the env
- export ZIP_FLAGS=-q # comment this to debug travis install issues
- source ci/envars.sh # we need to source this to bring in the envars
- ci/before_install.sh
- python -V

install:
Expand All @@ -43,3 +55,4 @@ script:

after_script:
- ci/print_versions.py
- ci/after_script.sh
13 changes: 12 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ your contribution or address the issue you're having.

- When submitting a Pull Request
- **Make sure the test suite passes**., and that means on python3 as well.
You can use "test_fast.sh", or tox locally and/or enable Travis-CI on your fork.
You can use "test_fast.sh", or tox locally and/or [enable Travis-CI](http://about.travis-ci.org/docs/user/getting-started/) on your fork.
- We suggest you enable Travis-CI on your fork, to make it easier for the team
to see that the PR does indeed pass all the tests.
- Back-compatiblitiy **really** matters. Pandas already has a large user-base and
Expand Down Expand Up @@ -47,6 +47,16 @@ your contribution or address the issue you're having.
and finally a commit message body if there's a need for one.
- Please reference the GH issue number in your commit message using GH1234
or #1234, either style is fine.
- Use "raise AssertionError" rather then plain `assert` in library code (using assert is fine
for test code). python -o strips assertions. better safe then sorry.
- When writing tests, don't use "new" assertion methods added to the unittest module
in 2.7 since pandas currently supports 2.6. The most common pitfall is:

with self.assertRaises(ValueError):
foo

which fails on python 2.6, use `self.assertRaises(TheException,func,args)` instead.

- RELEASE.rst and doc/source/vx.y.z.txt contain an on-going changelog for each
release as it is worked on. Add entries to these files as needed in
a separate commit in your PR, documenting the fix, enhancement or (unavoidable)
Expand All @@ -63,6 +73,7 @@ your contribution or address the issue you're having.
- If your code changes are intermixed with style fixes, they are harder to review
before merging. Keep style fixes in separate commits.
- it's fine to clean-up a little around an area you just worked on.
- Generally its a BAD idea to PEP8 on documentation.

Having said that, if you still feel a PEP8 storm is in order, go for it.

Expand Down
25 changes: 23 additions & 2 deletions RELEASE.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Where to get it
pandas 0.11.0
=============

**Release date:** 2013-??-??
**Release date:** 2013-04-22

**New features**

Expand Down Expand Up @@ -173,13 +173,23 @@ pandas 0.11.0
when invalid shapes are passed
- Don't suppress TypeError in GroupBy.agg (GH3238_)
- Methods return None when inplace=True (GH1893_)

- HTML repr output for dataframs is once again controlled by the option
`display.notebook_repr_html`, and on by default.
- ``HDFStore``

- added the method ``select_column`` to select a single column from a table as a Series.
- deprecated the ``unique`` method, can be replicated by ``select_column(key,column).unique()``
- ``min_itemsize`` parameter will now automatically create data_columns for passed keys

- Downcast on pivot if possible (GH3283_), adds argument ``downcast`` to ``fillna``
- Introduced options `display.height/width` for explicitly specifying terminal
height/width in characters. Deprecated display.line_width, now replaced by display.width.
These defaults are in effect for scripts as well, so unless disabled, previously
very wide output will now be output as "expand_repr" style wrapped output.
- Various defaults for options (including display.max_rows) have been revised,
after a brief survey concluded they were wrong for everyone. Now at w=80,h=60.
- HTML repr output for dataframes is once again controlled by the option
`display.notebook_repr_html`, and on by default.

**Bug Fixes**

Expand Down Expand Up @@ -296,12 +306,21 @@ pandas 0.11.0
- Ensure index casts work even in Int64Index
- Fix set_index segfault when passing MultiIndex (GH3308_)
- Ensure pickles created in py2 can be read in py3
- Insert ellipsis in MultiIndex summary repr (GH3348_)
- Groupby will handle mutation among an input groups columns (and fallback
to non-fast apply) (GH3380_)
- Eliminated unicode errors on FreeBSD when using MPL GTK backend (GH3360_)
- Period.strftime should return unicode strings always (GH3363_)
- Respect passed read_* chunksize in get_chunk function (GH3406_)

.. _GH3294: https://github.com/pydata/pandas/issues/3294
.. _GH622: https://github.com/pydata/pandas/issues/622
.. _GH3348: https://github.com/pydata/pandas/issues/3348
.. _GH797: https://github.com/pydata/pandas/issues/797
.. _GH1893: https://github.com/pydata/pandas/issues/1893
.. _GH1978: https://github.com/pydata/pandas/issues/1978
.. _GH3360: https://github.com/pydata/pandas/issues/3360
.. _GH3363: https://github.com/pydata/pandas/issues/3363
.. _GH2758: https://github.com/pydata/pandas/issues/2758
.. _GH3275: https://github.com/pydata/pandas/issues/3275
.. _GH2121: https://github.com/pydata/pandas/issues/2121
Expand Down Expand Up @@ -406,6 +425,8 @@ pandas 0.11.0
.. _GH2919: https://github.com/pydata/pandas/issues/2919
.. _GH3308: https://github.com/pydata/pandas/issues/3308
.. _GH3311: https://github.com/pydata/pandas/issues/3311
.. _GH3380: https://github.com/pydata/pandas/issues/3380
.. _GH3406: https://github.com/pydata/pandas/issues/3406

pandas 0.10.1
=============
Expand Down
48 changes: 28 additions & 20 deletions ci/before_install.sh
Original file line number Diff line number Diff line change
@@ -1,28 +1,36 @@
#!/bin/bash

# If envars.sh determined we're running in an authorized fork
# and the user opted in to the network cache,and that cached versions
# are available on the cache server, download and deploy the cached
# files to the local filesystem

echo "inside $0"

# overview
if [ ${TRAVIS_PYTHON_VERSION} == "3.3" ]; then
sudo add-apt-repository -y ppa:doko/ppa # we get the py3.3 debs from here
fi

sudo apt-get update $APT_ARGS # run apt-get update for all versions

# # hack for broken 3.3 env
# if [ x"$VIRTUAL_ENV" == x"" ]; then
# VIRTUAL_ENV=~/virtualenv/python$TRAVIS_PYTHON_VERSION_with_system_site_packages;
# fi
if $PLEASE_TRAVIS_FASTER ; then
echo "Faster? well... I'll try."

if $CACHE_FILE_AVAILABLE ; then
echo retrieving "$CACHE_FILE_URL";

wget -q "$CACHE_FILE_URL" -O "/tmp/_$CYTHON_HASH.zip";
unzip $ZIP_FLAGS /tmp/_"$CYTHON_HASH.zip" -d "$BUILD_CACHE_DIR";
rm -f /tmp/_"$CYTHON_HASH.zip"
# copy cythonized c files over
cp -R "$BUILD_CACHE_DIR"/pandas/*.c pandas/
cp -R "$BUILD_CACHE_DIR"/pandas/src/*.c pandas/src/
fi;
echo "VENV_FILE_AVAILABLE=$VENV_FILE_AVAILABLE"
if $VENV_FILE_AVAILABLE ; then
echo "getting venv"
wget -q $VENV_FILE_URL -O "/tmp/venv.zip";
sudo unzip $ZIP_FLAGS -o /tmp/venv.zip -d "/";
sudo chown travis -R "$VIRTUAL_ENV"
rm -f /tmp/_"$CYTHON_HASH.zip"
fi;
fi

# # we only recreate the virtualenv for 3.x
# # since the "Detach bug" only affects python3
# # and travis has numpy preinstalled on 2.x which is quicker
# _VENV=$VIRTUAL_ENV # save it
# if [ ${TRAVIS_PYTHON_VERSION:0:1} == "3" ] ; then
# deactivate # pop out of any venv
# sudo pip install virtualenv==1.8.4 --upgrade
# sudo apt-get install $APT_ARGS python3.3 python3.3-dev
# sudo rm -Rf $_VENV
# virtualenv -p python$TRAVIS_PYTHON_VERSION $_VENV --system-site-packages;
# source $_VENV/bin/activate
# fi
true # never fail because bad things happened here
67 changes: 67 additions & 0 deletions ci/envars.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
#!/bin/bash

# This must be sourced by .travis.yml, so any envars exported here will
# be available to the rest of the build stages

# - computes a hash based on the cython files in the codebade
# - retrieves the decrypted key if any for all whitelisted forks
# - checks whether the user optd int to use the cache
# - if so, check for availablity of cache files on the server, based on hash
# - set envars to control what the following scripts do

# at most one of these will decrypt, so the end result is that $STORE_KEY
# either holds a single key or does not
export STORE_KEY="$STORE_KEY0""$STORE_KEY1""$STORE_KEY2""$STORE_KEY3""$STORE_KEY4"
export STORE_KEY="$STORE_KEY""$STORE_KEY5""$STORE_KEY6""$STORE_KEY7"

export CYTHON_HASH=$(find pandas | grep -P '\.(pyx|pxd)$' | sort \
| while read N; do echo $(tail -n+1 $N | md5sum ) ;done | md5sum| cut -d ' ' -f 1)

export CYTHON_HASH=$CYTHON_HASH-$TRAVIS_PYTHON_VERSION

# where the cache files live on the server
export CACHE_FILE_URL="https://cache27-pypandas.rhcloud.com/static/$STORE_KEY/$CYTHON_HASH.zip"
export VENV_FILE_URL="https://cache27-pypandas.rhcloud.com/static/$STORE_KEY/venv-$TRAVIS_PYTHON_VERSION.zip"
export CACHE_FILE_STORE_URL="https://cache27-pypandas.rhcloud.com/store/$STORE_KEY"

echo "Hashing:"
find pandas | grep -P '\.(pyx|pxd)$'
echo "Key: $CYTHON_HASH"

export CACHE_FILE_AVAILABLE=false
export VENV_FILE_AVAILABLE=false
export PLEASE_TRAVIS_FASTER=false

# check whether the user opted in to use the cache via commit message
if [ x"$(git log --format='%B' -n 1 | grep PLEASE_TRAVIS_FASTER | wc -l)" != x"0" ]; then
export PLEASE_TRAVIS_FASTER=true
fi;
if [ x"$(git log --format='%B' -n 1 | grep PTF | wc -l)" != x"0" ]; then
export PLEASE_TRAVIS_FASTER=true
fi;

if $PLEASE_TRAVIS_FASTER; then

# check whether the files exists on the server
curl -s -f -I "$CACHE_FILE_URL" # silent, don;t expose key
if [ x"$?" == x"0" ] ; then
export CACHE_FILE_AVAILABLE=true;
fi


curl -s -f -I "$VENV_FILE_URL" # silent, don;t expose key
if [ x"$?" == x"0" ] ; then
export VENV_FILE_AVAILABLE=true;
fi

# the pandas build cache machinery needs this set, and the directory created
export BUILD_CACHE_DIR="/tmp/build_cache"
mkdir "$BUILD_CACHE_DIR"
fi;

# debug
echo "PLEASE_TRAVIS_FASTER=$PLEASE_TRAVIS_FASTER"
echo "CACHE_FILE_AVAILABLE=$CACHE_FILE_AVAILABLE"
echo "VENV_FILE_AVAILABLE=$VENV_FILE_AVAILABLE"

true
Loading

0 comments on commit 388411e

Please sign in to comment.