Skip to content

Commit f576cb1

Browse files
author
TECHTANIC
committed
.
1 parent df72692 commit f576cb1

File tree

4 files changed

+13
-10
lines changed

4 files changed

+13
-10
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Changelog
22

3+
## v1.2
4+
- Fixed CourseVania
5+
36
## v1.1
47
- Fixed RealDiscount and CourseVania
58
- Added Russian Language filter

CLI/duce.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -137,8 +137,8 @@ def coursevania():
137137
cv_links = []
138138
r = requests.get("https://coursevania.com/courses/")
139139
soup = bs(r.content, "html5lib")
140-
nonce = soup.find_all("script")[20].text[30:]
141-
nonce = json.loads(nonce[: len(nonce) - 6])["load_content"]
140+
nonce = soup.find_all("script")[22].text[30:]
141+
nonce = json.loads(nonce.strip().strip(";"))["load_content"]
142142
r = requests.get(
143143
"https://coursevania.com/wp-admin/admin-ajax.php?&template=courses/grid&args={%22posts_per_page%22:%2230%22}&action=stm_lms_load_content&nonce="
144144
+ nonce
@@ -190,7 +190,7 @@ def idcoupons():
190190

191191
# Constants
192192

193-
version = "v1.1"
193+
version = "v1.2"
194194

195195

196196
def create_scrape_obj():

COLAB/DUCE.ipynb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -206,8 +206,8 @@
206206
" cv_links = []\n",
207207
" r = requests.get(\"https://coursevania.com/courses/\")\n",
208208
" soup = bs(r.content, \"html5lib\")\n",
209-
" nonce = soup.find_all(\"script\")[20].text[30:]\n",
210-
" nonce = json.loads(nonce[: len(nonce) - 6])[\"load_content\"]\n",
209+
" nonce = soup.find_all(\"script\")[22].text[30:]\n",
210+
" nonce = json.loads(nonce.strip().strip(\";\"))[\"load_content\"]\n",
211211
" r = requests.get(\n",
212212
" \"https://coursevania.com/wp-admin/admin-ajax.php?&template=courses/grid&args={%22posts_per_page%22:%2230%22}&action=stm_lms_load_content&nonce=\"\n",
213213
" + nonce\n",
@@ -259,7 +259,7 @@
259259
"\n",
260260
"# Constants\n",
261261
"\n",
262-
"version = \"v1.1\"\n",
262+
"version = \"v1.2\"\n",
263263
"\n",
264264
"\n",
265265
"def create_scrape_obj():\n",

GUI/duce.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,9 @@ def coursevania():
158158
cv_links = []
159159
r = requests.get("https://coursevania.com/courses/")
160160
soup = bs(r.content, "html5lib")
161-
nonce = soup.find_all("script")[20].text[30:]
162-
nonce = json.loads(nonce[: len(nonce) - 6])["load_content"]
161+
nonce = soup.find_all("script")[22].text[30:]
162+
163+
nonce = json.loads(nonce.strip().strip(";"))["load_content"]
163164
r = requests.get(
164165
"https://coursevania.com/wp-admin/admin-ajax.php?&template=courses/grid&args={%22posts_per_page%22:%2230%22}&action=stm_lms_load_content&nonce="
165166
+ nonce
@@ -182,7 +183,6 @@ def coursevania():
182183
main_window["pCourse Vania"].update(0, visible=False)
183184
main_window["iCourse Vania"].update(visible=True)
184185

185-
186186
def idcoupons():
187187

188188
global idc_links
@@ -213,7 +213,7 @@ def idcoupons():
213213

214214
########################### Constants
215215

216-
version = "v1.1"
216+
version = "v1.2"
217217

218218

219219
def create_scrape_obj():

0 commit comments

Comments
 (0)