diff options
author | MichaĆ Klichowicz <emkael@tlen.pl> | 2018-02-23 16:06:59 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-23 16:06:59 +0100 |
commit | 320868f72185630b59cc690e81fbb1f76e92075b (patch) | |
tree | a88e5a7aefddac8272e1d3a39c4da6e4db96b5b3 /jfr_playoff/tournamentinfo.py | |
parent | 2f4f93417bd0f3f6886a2a04ec0ef2054633d6b3 (diff) | |
parent | cab639df56676443dc7cd8b5ef3dc9ac5dae830b (diff) |
Merge pull request #19 from emkael/mysql-import-on-demand
Mysql import on demand
Diffstat (limited to 'jfr_playoff/tournamentinfo.py')
-rw-r--r-- | jfr_playoff/tournamentinfo.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/jfr_playoff/tournamentinfo.py b/jfr_playoff/tournamentinfo.py index 90637bc..ee96214 100644 --- a/jfr_playoff/tournamentinfo.py +++ b/jfr_playoff/tournamentinfo.py @@ -1,8 +1,6 @@ from math import ceil import re -import mysql - import jfr_playoff.sql as p_sql from jfr_playoff.remote import RemoteUrl as p_remote @@ -118,7 +116,7 @@ class TournamentInfo: teams = [] try: teams = self.__get_db_results() - except (mysql.connector.Error, TypeError, IndexError, KeyError): + except (IOError, TypeError, IndexError, KeyError): try: teams = self.__get_html_results() except (TypeError, IndexError, KeyError, IOError, ValueError): @@ -132,7 +130,7 @@ class TournamentInfo: def is_finished(self): try: return self.__get_db_finished() - except (mysql.connector.Error, TypeError, IndexError, KeyError): + except (IOError, TypeError, IndexError, KeyError): try: return self.__get_html_finished() except (TypeError, IndexError, KeyError, IOError, ValueError): @@ -142,7 +140,7 @@ class TournamentInfo: def get_results_link(self, suffix='leaderb.html'): try: return self.__get_db_link(suffix) - except (mysql.connector.Error, TypeError, IndexError, KeyError): + except (IOError, TypeError, IndexError, KeyError): try: return self.__get_html_link(suffix) except (KeyError, ValueError): |