hyunhwan-jeong / bear-app-to-notion Goto Github PK
View Code? Open in Web Editor NEWThis repository shows how to import bear app documents to notion
This repository shows how to import bear app documents to notion
As I found the script doesn't recognize converted path names:
if an image in Bear had whitespaces: "Screenshot 202021-11-05 20at 2022.35.55.png", after export they will be replaced with percent sign: "Screenshot%202021-11-05%20at%2022.35.55.png".
Which eventually gives an error FileNotFoundError: [Errno 2] No such file or directory: '/foo/bar/Screenshot%202021-11-05%20at%2022.35.55.png'
Tried to run the code, but got this.
python script.py
Traceback (most recent call last):
File "/Users/username/git/bear-app-to-notion/script.py", line 12, in <module>
client = NotionClient(token_v2=token_v2)
File "/Users/username/miniconda3/lib/python3.9/site-packages/notion/client.py", line 77, in __init__
self.session = create_session(client_specified_retry)
File "/Users/username/miniconda3/lib/python3.9/site-packages/notion/client.py", line 39, in create_session
retry = Retry(
TypeError: __init__() got an unexpected keyword argument 'method_whitelist'
First, issue though is that it is pretty hard to find the cookie. See attached screenshot, is it this?
Also, I am on python 3.9, is this an issue?
Something is wrong here, not working.
File "script.py", line 13, in <module>
page = client.get_block(page_url)
File "/opt/homebrew/anaconda3/envs/test_m1/lib/python3.8/site-packages/notion/client.py", line 169, in get_block
block = self.get_record_data("block", block_id, force_refresh=force_refresh)
File "/opt/homebrew/anaconda3/envs/test_m1/lib/python3.8/site-packages/notion/client.py", line 162, in get_record_data
return self._store.get(table, id, force_refresh=force_refresh)
File "/opt/homebrew/anaconda3/envs/test_m1/lib/python3.8/site-packages/notion/store.py", line 184, in get
self.call_load_page_chunk(id)
File "/opt/homebrew/anaconda3/envs/test_m1/lib/python3.8/site-packages/notion/store.py", line 286, in call_load_page_chunk
recordmap = self._client.post("loadPageChunk", data).json()["recordMap"]
File "/opt/homebrew/anaconda3/envs/test_m1/lib/python3.8/site-packages/notion/client.py", line 260, in post
raise HTTPError(
requests.exceptions.HTTPError: Invalid input.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.