fix the excel reader: hours & header
State: closed

in the excel.py there is a fix enabling reading xlsx files with both
datemodes: (see #4332)
in the parsers.py there is the fix for readinh the header even if there
are additional rows (to be skipped) between a header and the data (see: #4340)

I hope this PR is adequate. If not, please let me know.
I can supply the sample file for testing proving that it works. See also:
https://github.com/timmie/example_code_data


Labels:

Comments:
can u hook up travis ci?

https://github.com/pydata/pandas/wiki/Testing#hook-up-travis-ci

thanks

uff, never done this. I will see what I can do in the next days.

@timmie it's actually really easy to set up. All you need to do is log in to Travis with your github account and follow a few instructions. The upside is that Travis then tests your code against multiple versions of Python and multiple different environments, which can really help iron out bugs.

it's important for these kinds of prs especially since we don't want a bunch of failures simply because the underlying lib doesn't exist for, say, python 3.2

ok, I added the service hook in the GitHub settings.

What is the next step?

Do you also wanna have a test with the data from https://github.com/timmie/example_code_data?
Before, I woudl appreciate a comment if my changes are appropriate.

THX.

I find Travis really useful, TBH. You can kind of throw a bunch of things
at the wall and see what sticks without needing to go through the hassle of
compiling 5 times with dependencies.

we need that locally! i'm working on something to make `detox` more useful to pandas devs...just a better config really

git commit --amend -C HEAD
git push --force

so, no I see a lot of errors for code I never touched:
https://travis-ci.org/timmie/pandas/jobs/9669404
https://travis-ci.org/timmie/pandas

many of those are related to your  change

actually ALL of them are

mmh. worked with my files...

How can I test this on my machine?

`nosetests -w pandas/io/tests`

on my local I get:

```
 nosetests -w pandas/io/tests

----------------------------------------------------------------------
Ran 0 tests in 0.000s

OK
```

you're probably not in the pandas directory

I am:
~/coding/virtualenvs/pandas/pandas_fork

try `find . -name 'test_pytables.py'` from that dir what does it return?

find . -name 'test_pytables.py'
./pandas/io/tests/test_pytables.py

not sure what the issue is

@timmie 

make sure that you have these git options set

`git config -l --global`

so you don't change file modes and line endings are good (if you are on windows?)

```
core.filemode=False
core.autocrlf=input
```

@cpcloud maybe add to tip & tricks?

Sounds good 

@cpcloud , @jreback 
Thanks for the help.

I feel lost again. I found the error and tryed to fix it. But all these hurdles like git, travis etc. are too high for the occasional library contributor...

Ironically I didn't start to understand git until I started contributing more.. Just keep at it :) 

what does this mean

```
nosetests -w pandas/tests/test_series.py 
Traceback (most recent call last):
  File "/usr/bin/nosetests", line 9, in <module>
    load_entry_point('nose==1.1.2', 'console_scripts', 'nosetests')()
  File "/usr/lib/python2.7/dist-packages/nose/core.py", line 118, in __init__
    **extra_args)
  File "/usr/lib/python2.7/unittest/main.py", line 94, in __init__
    self.parseArgs(argv)
  File "/usr/lib/python2.7/dist-packages/nose/core.py", line 135, in parseArgs
    self.config.configure(argv, doc=self.usage())
  File "/usr/lib/python2.7/dist-packages/nose/config.py", line 317, in configure
    self.configureWhere(options.where)
  File "/usr/lib/python2.7/dist-packages/nose/config.py", line 400, in configureWhere
    "not a directory" % path)
ValueError: Working directory pandas/tests/test_series.py not found, or not a directory

```

The w option only accepts directories 

the `-w` option means "working directory"

I tried on anther machine.

```
nosetests -w pandas/io/tests
E
======================================================================
ERROR: Failure: ImportError (cannot import name hashtable)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\Python27\lib\site-packages\nose\loader.py", line 413, in loadTestsFromName
    addr.filename, addr.module)
  File "C:\Python27\lib\site-packages\nose\importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "C:\Python27\lib\site-packages\nose\importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "D:\development\GitHub\pandas\pandas\__init__.py", line 6, in <module>
    from . import hashtable, tslib, lib
ImportError: cannot import name hashtable

----------------------------------------------------------------------
Ran 1 test in 0.000s

FAILED (errors=1)

```

Apparently, one would need to complie befor that works ;-(

Sorry, this is really getting beyond my capabilities and time allowances.

I tried all recommended at http://pandas.pydata.org/developers.html#running-the-test-suite

tests do not run locally.

Ok, looking forward, what could be a solution?

Revert and check in step by step in order to see why it fails?

i don't think it's your commit that is causing tests not to run. try importing pandas from its directory in a vanilla Python interpreter...sometimes IPython can hide the causes of import failures, but vanilla python will give you a more informative traceback (one of the very rare times when this is true)

> try importing pandas from its directory in a vanilla Python interpreter

Do you me a virtualenvironment?