aboutsummaryrefslogtreecommitdiff
path: root/management/parsers/ups2018.py
diff options
context:
space:
mode:
authorAlban Gruin2019-08-30 13:59:13 +0200
committerAlban Gruin2019-09-01 13:28:32 +0200
commit683409424325e7048c802960e81585320904fac1 (patch)
treee752d9d9d4d24a45653af0bdd413f72618734d2b /management/parsers/ups2018.py
parent0ad58a9268130e49c017f13beacb618f466a722f (diff)
parenta85f2fb91d1a4a0e31c41c392e404d7ddbf21109 (diff)
Merge branch 'ag/parser-ups-2019' into futur
Diffstat (limited to 'management/parsers/ups2018.py')
-rw-r--r--management/parsers/ups2018.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/management/parsers/ups2018.py b/management/parsers/ups2018.py
index afbfc4b..0d6d798 100644
--- a/management/parsers/ups2018.py
+++ b/management/parsers/ups2018.py
@@ -32,6 +32,10 @@ from .abstractparser import AbstractParser, ParserError
VARNAME = "v.events.list = "
+GROUP_PREFIXES = ("L1 ", "L2 ", "L3 ", "L3P ", "M1 ", "M2 ", "DEUST ", "MAG1 ",
+ "1ERE ANNEE ", "2EME ANNEE ", "3EME ANNEE ",
+ "MAT-Agreg Interne ")
+
def find_events_list(soup):
res = []
@@ -123,11 +127,7 @@ class Parser(AbstractParser):
min_i = 1
i = min_i
- while i < len(data) and not data[i].startswith(
- ("L1 ", "L2 ", "L3 ", "L3P ", "M1 ", "M2 ", "DEUST ", "MAG1 ",
- "1ERE ANNEE ", "2EME ANNEE ", "3EME ANNEE ",
- "MAT-Agreg Interne ")
- ):
+ while i < len(data) and not data[i].startswith(GROUP_PREFIXES):
i += 1
groups = data[i]