Work with another time format
This commit is contained in:
parent
d9fa9420fd
commit
7f85b9d105
|
@ -3,6 +3,8 @@ Changelog
|
||||||
|
|
||||||
This changelog contains a list of versions with their respective high-level changes.
|
This changelog contains a list of versions with their respective high-level changes.
|
||||||
|
|
||||||
|
v0.5.8:
|
||||||
|
- deal with yet another time format
|
||||||
v0.5.7:
|
v0.5.7:
|
||||||
- fixed README
|
- fixed README
|
||||||
v0.5.6:
|
v0.5.6:
|
||||||
|
|
|
@ -6,7 +6,7 @@ ALLRIS Scraper
|
||||||
.. image:: https://img.shields.io/pypi/pyversions/twomartens.allrisscraper.svg
|
.. image:: https://img.shields.io/pypi/pyversions/twomartens.allrisscraper.svg
|
||||||
:alt: Python 3.7 and 3.8
|
:alt: Python 3.7 and 3.8
|
||||||
.. image:: https://img.shields.io/pypi/v/twomartens.allrisscraper.svg
|
.. image:: https://img.shields.io/pypi/v/twomartens.allrisscraper.svg
|
||||||
:alt: version 0.5.6
|
:alt: version 0.5.8
|
||||||
|
|
||||||
This scraper offers both public and private scraping. The latter requires your username and password and performs the
|
This scraper offers both public and private scraping. The latter requires your username and password and performs the
|
||||||
following tasks for you:
|
following tasks for you:
|
||||||
|
|
2
setup.py
2
setup.py
|
@ -30,7 +30,7 @@ setup(
|
||||||
author="Jim Martens",
|
author="Jim Martens",
|
||||||
author_email="github@2martens.de",
|
author_email="github@2martens.de",
|
||||||
url="https://git.2martens.de/2martens/allris-scraper",
|
url="https://git.2martens.de/2martens/allris-scraper",
|
||||||
version="0.5.7",
|
version="0.5.8",
|
||||||
namespace_packages=["twomartens"],
|
namespace_packages=["twomartens"],
|
||||||
packages=find_packages('src', exclude=["*.tests", "*.tests.*", "tests.*", "tests"]),
|
packages=find_packages('src', exclude=["*.tests", "*.tests.*", "tests.*", "tests"]),
|
||||||
package_dir={'': 'src'},
|
package_dir={'': 'src'},
|
||||||
|
|
|
@ -83,7 +83,11 @@ def get_meetings(driver: webdriver.Firefox) -> List[meeting.Meeting]:
|
||||||
for element in elements:
|
for element in elements:
|
||||||
tds = element.find_elements_by_tag_name("td")
|
tds = element.find_elements_by_tag_name("td")
|
||||||
date_obj = get_day(tds[0].text)
|
date_obj = get_day(tds[0].text)
|
||||||
time_obj = time.fromisoformat(str(tds[1].text).rstrip())
|
time_str = str(tds[1].text).rstrip()
|
||||||
|
time_index_space = time_str.find(" ")
|
||||||
|
if time_index_space != -1:
|
||||||
|
time_str = time_str[0:time_index_space]
|
||||||
|
time_obj = time.fromisoformat(time_str)
|
||||||
agenda_link = tds[4].find_element_by_tag_name("a").get_property("href")
|
agenda_link = tds[4].find_element_by_tag_name("a").get_property("href")
|
||||||
name = tds[4].find_element_by_tag_name("a").text
|
name = tds[4].find_element_by_tag_name("a").text
|
||||||
location = tds[5].text
|
location = tds[5].text
|
||||||
|
|
Loading…
Reference in New Issue