ffbot 1.2.6__tar.gz → 1.2.7__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ffbot
3
- Version: 1.2.6
3
+ Version: 1.2.7
4
4
  Summary: Automate playing Yahoo Fantasy Football
5
5
  Home-page: https://github.com/amarvin/fantasy-football-bot
6
6
  Author: Alex Marvin
@@ -0,0 +1 @@
1
+ VERSION = "1.2.7"
@@ -1,3 +1,4 @@
1
+ import re
1
2
  from datetime import datetime
2
3
  from io import StringIO
3
4
 
@@ -188,8 +189,9 @@ def current_week():
188
189
  s.headers["User-Agent"] = generate_user_agent()
189
190
  r = s.get(url)
190
191
  soup = bs(r.text, "lxml")
191
- span = soup.select_one("li.Navitem.current a.Navtarget")
192
- week = span.text.split()[1]
192
+ matchups = soup.select_one("#matchupweek .matchups-body")
193
+ weeks = re.findall(r"Week (\d+)", matchups.text)
194
+ week = weeks[0]
193
195
  week = int(week)
194
196
 
195
197
  return week
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ffbot
3
- Version: 1.2.6
3
+ Version: 1.2.7
4
4
  Summary: Automate playing Yahoo Fantasy Football
5
5
  Home-page: https://github.com/amarvin/fantasy-football-bot
6
6
  Author: Alex Marvin
@@ -1 +0,0 @@
1
- VERSION = "1.2.6"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes