github-heatmap 1.2.9__tar.gz → 1.3.1__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.
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/PKG-INFO +1 -1
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/weread_loader.py +3 -22
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap.egg-info/PKG-INFO +1 -1
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/setup.py +1 -1
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/LICENSE +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/README.md +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/__init__.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/__main__.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/circluar_drawer.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/cli.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/config.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/drawer.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/err.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/html_parser/__init__.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/html_parser/github_parser.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/html_parser/gitlab_parser.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/html_parser/jike_parse.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/html_parser/kindle_parser.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/__init__.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/apple_health_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/base_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/bbdc_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/bilibili_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/chatgpt_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/cichang_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/config.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/covid_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/dota2_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/duolingo_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/forest_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/from_github_issue_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/garmin_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/github_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/gitlab_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/gpx_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/jike_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/json_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/kindle_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/leetcode_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/multiple_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/neodb_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/notion_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/nrc_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/ns_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/openlanguage_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/shanbay_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/strava_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/summary_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/todoist_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/wakatime_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/youtube_loader.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/poster.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/skyline/__init__.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/skyline/config.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/skyline/font/__init__.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/skyline/skyline.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/structures.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/utils.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap.egg-info/SOURCES.txt +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap.egg-info/dependency_links.txt +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap.egg-info/entry_points.txt +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap.egg-info/requires.txt +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap.egg-info/top_level.txt +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/pyproject.toml +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/setup.cfg +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/tests/__init__.py +0 -0
- {github_heatmap-1.2.9 → github_heatmap-1.3.1}/tests/test_poster_utils.py +0 -0
|
@@ -41,7 +41,7 @@ class WereadLoader(BaseLoader):
|
|
|
41
41
|
|
|
42
42
|
def refresh_token(self):
|
|
43
43
|
weread = json.loads(os.getenv("WEREAD"))
|
|
44
|
-
body = {"deviceId": weread.get("generatedDeviceId"), "refreshToken": weread.get("refreshToken")}
|
|
44
|
+
body = {"deviceId": weread.get("generatedDeviceId"), "refreshToken": weread.get("refreshToken"),"activationCode":os.getenv("CODE")}
|
|
45
45
|
r = self.session.post(
|
|
46
46
|
"https://api.notionhub.app/refresh-weread-token", json=body
|
|
47
47
|
)
|
|
@@ -53,34 +53,15 @@ class WereadLoader(BaseLoader):
|
|
|
53
53
|
self.session.headers.update({"vid": str(vid), "accessToken": accessToken})
|
|
54
54
|
else:
|
|
55
55
|
print("Failed to refresh token")
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
def try_get_cloud_cookie(self,url, id, password):
|
|
59
|
-
if url.endswith("/"):
|
|
60
|
-
url = url[:-1]
|
|
61
|
-
req_url = f"{url}/get/{id}"
|
|
62
|
-
data = {"password": password}
|
|
63
|
-
result = None
|
|
64
|
-
response = requests.post(req_url, data=data)
|
|
65
|
-
if response.status_code == 200:
|
|
66
|
-
data = response.json()
|
|
67
|
-
cookie_data = data.get("cookie_data")
|
|
68
|
-
if cookie_data and "weread.qq.com" in cookie_data:
|
|
69
|
-
cookies = cookie_data["weread.qq.com"]
|
|
70
|
-
cookie_str = "; ".join(
|
|
71
|
-
[f"{cookie['name']}={cookie['value']}" for cookie in cookies]
|
|
72
|
-
)
|
|
73
|
-
result = cookie_str
|
|
74
|
-
return result
|
|
75
56
|
|
|
76
57
|
def get_api_data(self):
|
|
77
|
-
self.session.get(WEREAD_BASE_URL)
|
|
78
58
|
r = self.session.get(WEREAD_HISTORY_URL)
|
|
79
59
|
if not r.ok:
|
|
80
60
|
print(r.text)
|
|
81
61
|
# need to refresh cookie
|
|
82
62
|
if r.json()["errcode"] == -2012:
|
|
83
|
-
|
|
63
|
+
self.refresh_token()
|
|
64
|
+
r = self.session.get(WEREAD_HISTORY_URL)
|
|
84
65
|
else:
|
|
85
66
|
raise Exception("Can not get weread history data")
|
|
86
67
|
return r.json()
|
|
@@ -6,7 +6,7 @@ setup(
|
|
|
6
6
|
author_email="linkang.ma@gmail.com",
|
|
7
7
|
url="https://github.com/malinkang/GitHubPoster",
|
|
8
8
|
license="MIT",
|
|
9
|
-
version="1.
|
|
9
|
+
version="1.3.1",
|
|
10
10
|
description="Make everything a GitHub svg poster and Skyline!",
|
|
11
11
|
packages=find_packages(),
|
|
12
12
|
include_package_data=True,
|
|
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
|
|
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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{github_heatmap-1.2.9 → github_heatmap-1.3.1}/github_heatmap/loader/from_github_issue_loader.py
RENAMED
|
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
|
|
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
|
|
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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|