diff options
| author | Florian Fischer <florian.fischer@muhq.space> | 2021-09-09 10:11:47 +0200 |
|---|---|---|
| committer | Florian Fischer <florian.fischer@muhq.space> | 2021-09-09 10:12:33 +0200 |
| commit | 0cece58b291adf043266dae0cf38369e76dd9589 (patch) | |
| tree | 81c0d52a0dfb897fc63f421342774b90fb5e7782 | |
| parent | c7a18cedc0c3b70d97b5a842617f1979a6b1fa62 (diff) | |
| download | geldschieberbot-0cece58b291adf043266dae0cf38369e76dd9589.tar.gz geldschieberbot-0cece58b291adf043266dae0cf38369e76dd9589.zip | |
[tanken] specify expected Errors
| -rw-r--r-- | tanken.py | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -10,7 +10,7 @@ def tanken(drives, cost, service_charge=0): for d in drives: try: d[0] = int(d[0]) - except: + except (IndexError, ValueError): return None, "Lines have to start with the driven distance!" # calculate overall distance |
