Skip to content

Commit f9c6a9e

Browse files
committed
Match API change of HYS
1 parent 2f58677 commit f9c6a9e

File tree

4 files changed

+9
-6
lines changed

4 files changed

+9
-6
lines changed

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
1+
venv/
12
dist/
2-
src/hys_scraper.egg-info/
3+
src/hys_scraper.egg-info/
4+
5+
project_notes.txt

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "hys_scraper"
7-
version = "0.1.32"
7+
version = "0.1.33"
88
description = "Scrape feedback and statistics from the European Commission's 'Have your Say' plattform."
99
readme = "README.md"
1010
classifiers = [

requirements.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#
2-
# This file is autogenerated by pip-compile with python 3.9
3-
# To update, run:
2+
# This file is autogenerated by pip-compile with Python 3.10
3+
# by the following command:
44
#
55
# pip-compile pyproject.toml
66
#

src/hys_scraper/hys_scraper.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ def scrape_publication_name(self) -> str:
115115
"""
116116
url = (
117117
self.base_url
118-
+ f"brpapi/shortTitleByPublicationId?publicationId={self.publication_id}"
118+
+ f"api/shortTitleByPublicationId?publicationId={self.publication_id}"
119119
)
120120

121121
r = self._get(url)
@@ -148,7 +148,7 @@ def _scrape_page(self, page: int = 0, size: int = None) -> dict:
148148
dict
149149
Parsed JSON return value.
150150
"""
151-
url = self.base_url + f"brpapi/allFeedback?publicationId={self.publication_id}"
151+
url = self.base_url + f"api/allFeedback?publicationId={self.publication_id}"
152152
url += f"&page={page}"
153153
url += f"&size={size}" if size is not None else ""
154154

0 commit comments

Comments
 (0)