Fix bug with OT readings.
This commit is contained in:
parent
8c8efa80b7
commit
f4127b1008
@ -24,7 +24,7 @@ class HTTPClient:
|
|||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.session = requests.session()
|
self.session = requests.session()
|
||||||
|
|
||||||
base_ua = 'goarch_api (https://github.com/vypr/goarch_api 1.1.0), Python/'
|
base_ua = 'goarch_api (https://github.com/Oikonomia/goarch_api 1.1.1), Python/'
|
||||||
self.user_agent = f"{base_ua}{sys.version_info[0]}.{sys.version_info[1]}"
|
self.user_agent = f"{base_ua}{sys.version_info[0]}.{sys.version_info[1]}"
|
||||||
|
|
||||||
def request(self, method, path):
|
def request(self, method, path):
|
||||||
|
@ -29,8 +29,9 @@ class Reading:
|
|||||||
is_gospel = (_type == "G" and type_bb == "gospel")
|
is_gospel = (_type == "G" and type_bb == "gospel")
|
||||||
is_epistle = (_type == "E" and type_bb == "epistle")
|
is_epistle = (_type == "E" and type_bb == "epistle")
|
||||||
is_matins = (_type == "MG" and type_bb == "mg")
|
is_matins = (_type == "MG" and type_bb == "mg")
|
||||||
|
is_ot = (_type == "OT" and type_bb == "ot")
|
||||||
|
|
||||||
if not (is_gospel ^ is_epistle ^ is_matins):
|
if not (is_ot ^ is_gospel ^ is_epistle ^ is_matins):
|
||||||
raise Exception("Invalid or mismatching reading types.")
|
raise Exception("Invalid or mismatching reading types.")
|
||||||
|
|
||||||
if is_epistle:
|
if is_epistle:
|
||||||
|
4
setup.py
4
setup.py
@ -2,10 +2,10 @@ from setuptools import setup
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name="goarch_api",
|
name="goarch_api",
|
||||||
version="1.1.0",
|
version="1.1.1",
|
||||||
author="Elliott Pardee",
|
author="Elliott Pardee",
|
||||||
author_email="me@vypr.xyz",
|
author_email="me@vypr.xyz",
|
||||||
url="https://github.com/vypr/goarch_api",
|
url="https://github.com/Oikonomia/goarch_api",
|
||||||
license="GPLv3",
|
license="GPLv3",
|
||||||
packages=["goarch_api"],
|
packages=["goarch_api"],
|
||||||
description="A Python interface for the Greek Orthodox Archdiocese of America's Chapel API.",
|
description="A Python interface for the Greek Orthodox Archdiocese of America's Chapel API.",
|
||||||
|
Loading…
Reference in New Issue
Block a user