Skip to content
This repository has been archived by the owner on Feb 17, 2023. It is now read-only.

Commit

Permalink
Merge branch 'master' of github.com:paultag/python-charlie
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul Tagliamonte committed Mar 17, 2012
2 parents 9c57251 + 8a70bef commit df1baac
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charlie/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def get_station_by_stop( platform ):
_apiurl = "http://developer.mbta.com/Data/"
# _apiurl = "http://tag.pault.ag/charlie-fake/"
# _apiurl = "http://localhost/"
_datadir = "/home/tag/dev/local/python-charlie/data"
_datadir = "/usr/share/charlie/data"
_csvfile = _datadir + "/station.data.csv"

def refresh():
Expand Down
3 changes: 2 additions & 1 deletion examples/events
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ while True:
event = t.getMostCloseEvent()
try:
if lkloc[train] != event["PlatformKey"]:
print "Train event: %s" % train
print "Train event: %s at %s" % ( train,
charlie.get_station_by_stop( event["PlatformKey"] ).name )
except KeyError:
print "New Train: %s" % train
lkloc[train] = event["PlatformKey"]

0 comments on commit df1baac

Please sign in to comment.