Skip to content
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

Invalid Date Exception In active_buses Method #2

Merged
merged 2 commits into from
Mar 3, 2012
Merged

Invalid Date Exception In active_buses Method #2

merged 2 commits into from
Mar 3, 2012

Conversation

bschoenfeld
Copy link
Contributor

Looks like there is a typo in bus.rb on line 66

time = HrtBus::Parse.time([time, date].join(""))
Resulting data looks like this: 01:35:2603/03

The Parse function is expecting a space in there: DateTime.strptime(data, '%H:%M:%S %m/%d')

Amazingly, this bug didn't break everything all the time. Just didn't work for some data. Adding a space to the join fixes it.

@bds
Copy link
Owner

bds commented Mar 3, 2012

Great catch Ben, thanks!

bds pushed a commit that referenced this pull request Mar 3, 2012
Invalid Date Exception In active_buses Method
@bds bds merged commit 99cec59 into bds:master Mar 3, 2012
@sjtipton
Copy link

sjtipton commented Mar 3, 2012

typo found? sounds like my kind of developer :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants