Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help!!! requests.exceptions.HTTPError: Invalid input. #385

Open
Vencent-Won opened this issue Feb 9, 2023 · 4 comments
Open

Help!!! requests.exceptions.HTTPError: Invalid input. #385

Vencent-Won opened this issue Feb 9, 2023 · 4 comments

Comments

@Vencent-Won
Copy link

Sorry to disturb you. When I try the example code.
client = NotionClient(token_v2="<token_v2>")
page = client.get_block("")

Then, it came out the error that:
Traceback (most recent call last):
File "D:\program files\JetBrains\PyCharm 2021.3.2\plugins\python\helpers\pydev\pydevd.py", line 1483, in _exec
pydev_imports.execfile(file, globals, locals) # execute the script
File "D:\program files\JetBrains\PyCharm 2021.3.2\plugins\python\helpers\pydev_pydev_imps_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "D:/Users/Vencent-Won/PycharmProjects/mark2notion/main.py", line 9, in
page = client.get_block("https://www.notion.so/Paper-Reading-Notes-2d79e4bcb83b4c22a7e054cd9bb6634a")
File "C:\Users\Vencent-Won\AppData\Roaming\Python\Python37\site-packages\notion\client.py", line 169, in get_block
block = self.get_record_data("block", block_id, force_refresh=force_refresh)
File "C:\Users\Vencent-Won\AppData\Roaming\Python\Python37\site-packages\notion\client.py", line 162, in get_record_data
return self._store.get(table, id, force_refresh=force_refresh)
File "C:\Users\Vencent-Won\AppData\Roaming\Python\Python37\site-packages\notion\store.py", line 184, in get
self.call_load_page_chunk(id)
File "C:\Users\Vencent-Won\AppData\Roaming\Python\Python37\site-packages\notion\store.py", line 286, in call_load_page_chunk
recordmap = self._client.post("loadPageChunk", data).json()["recordMap"]
File "C:\Users\Vencent-Won\AppData\Roaming\Python\Python37\site-packages\notion\client.py", line 262, in post
"message", "There was an error (400) submitting the request."
requests.exceptions.HTTPError: Invalid input.

@yxyx724
Copy link

yxyx724 commented Feb 28, 2023

I had the same issue.

@JorgeHI
Copy link

JorgeHI commented Apr 5, 2023

Same issue here, any solution?

@Mogby
Copy link

Mogby commented Apr 6, 2023

Found solution here: paperboi/kindle2notion#14

@quiri86
Copy link

quiri86 commented Apr 3, 2024

Didn't work for me, line 280 seems to have been amended in the package alraedy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants