pydata/pandas — pull request #3519 by cpcloud (2013-05-03 03:14:34+00:00)
Title: Parse asserts

This PR partially addresses #3024. It also provides a shiny new script useful looking at the current state of the messages in raised exceptions. Here's an example of some output:

Example
=====
![pandas-shiny-new-parse-asserts](https://f.cloud.github.com/assets/417981/457480/70282b60-b39e-11e2-8db1-f5cfb4f0c5bf.png)

You can reproduce this with

```shell
scripts/parse_asserts.py --type empty --module pandas --kind assert --sparse-filename
```
from the top level pandas directory.

Description
=======
The above line searches for all empty raises in the module `pandas` whose constructor matches the regular expression `'.*assert.*'`--not case sensitive--and the `--sparse-filename` option shows the `DataFrame`'s index using the `display.multi_sparse` option set to `True` if it is passed and shows every single file name regardless of repeats if it is not passed.

Note: **This assumes you have installed pandas with `python setup.py develop`**. This will not work without that.

To see all of the options and a short description you can do the usual:
```shell
scripts/parse_asserts.py --help
```