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

Notion Image do not load #463

Open
AnshumanFauzdar opened this issue Mar 10, 2023 · 16 comments
Open

Notion Image do not load #463

AnshumanFauzdar opened this issue Mar 10, 2023 · 16 comments

Comments

@AnshumanFauzdar
Copy link

Description

image
Image do not load up and throw {"message":"Something went wrong."} error.

Notion Test Page ID

bd999537dba44d68be67cbcf11ee6199

@heypratik
Copy link

@AnshumanFauzdar
Copy link
Author

@heypratik It was working without this image domain, is there any upgrade or dependency introduced which caused this issue?

@JYeop
Copy link

JYeop commented Mar 16, 2023

@adayush
Copy link

adayush commented Mar 22, 2023

It fixed for me when I added file.notion.so in next.config.js in the domains array inside images.

@ZuopieziChen
Copy link

It fixed for me when I added file.notion.so in next.config.js in the domains array inside images.

still not work for me.

@RichardS0268
Copy link

RichardS0268 commented Mar 26, 2023

I am facing the same problem. Images on my blog do not show and when I try to access the src from browser it raise {"message":"Something went wrong."}.
One example page is https://www.richardsong.space/l2-risk where images in original notion page do not show.
I have tried method mentioned by @adayush, it cannot work for me😥

@congnt24
Copy link

I have the same problem, the domain of the image is "file.notion.so" and when I access that image URL, it always returns {"message":"Something went wrong."}
I try to "file.notion.so" domain to next.config.js but it doesn't work

@0xFloyd
Copy link

0xFloyd commented Apr 17, 2023

same issue here. any update here? this is a pretty big issue IMO. It seems to only be private page images

@AnshumanFauzdar
Copy link
Author

@0xFloyd I didn't change anything and now its working as usual.

@Gumball12
Copy link

It works for now

@minesunny
Copy link

I am facing the same problem. Images on my blog do not show and when I try to access the src from browser it raise {"message":"Something went wrong."}. One example page is https://www.richardsong.space/l2-risk where images in original notion page do not show. I have tried method mentioned by @adayush, it cannot work for me😥

notion using Amazon’s cdn,its‘ period time is about one day(24hours),the static resources like src in html only Effective within 24 hours

@minesunny
Copy link

I am facing the same problem. Images on my blog do not show and when I try to access the src from browser it raise {"message":"Something went wrong."}. One example page is https://www.richardsong.space/l2-risk where images in original notion page do not show. I have tried method mentioned by @adayush, it cannot work for me😥

notion using Amazon’s cdn,its‘ period time is about one day(24hours),the static resources like src in html only Effective within 24 hours

I am facing the same problem. Images on my blog do not show and when I try to access the src from browser it raise {"message":"Something went wrong."}. One example page is https://www.richardsong.space/l2-risk where images in original notion page do not show. I have tried method mentioned by @adayush, it cannot work for me😥

I wanted to set static resources cnd cache lessthan 24hours,so that images' url can be valid,but I failed;Then,you can set a schedule task(less than 24 hours) to redeloy your project ,so that can refresh static resources

@minesunny
Copy link

If you deployed on local,see this #463 (comment) you deployed on vercel,I can explain why notion image can't load ? Vercel using next.js as Server render, For free personal,the timeout of function getStaticProps with limited in 10s,if some request timeout,it would use resource which last compiled (hold old timeStamp image url);seeing this
image; I configed navigationLinks,navigationStyle in site.config.ts and caused that problem.
navigationStyle with not default will request more notion's api, you can solve this problem from here.
image

@sivannavis
Copy link

sivannavis commented Oct 25, 2023

How did you guys solve it? I'm facing the same thing it only works when I refresh the page or switching the light mode, but it never works the first time you visited it, such a bad user experience : (

For example, one of my failing image address is https://www.sivan.fun/_next/image?url=https%3A%2F%2Fsummer-heart-0930.chufeiyun1688.workers.dev%3A443%2Fhttps%2Fwww.notion.so%2Fimage%2Fhttps%253A%252F%252Ffile.notion.so%252Ff%252Fs%252F0645a5ce-1e52-4aef-977b-e05a606611a4%252FUntitled.png%253Fid%253D13c21c56-8a17-44dd-87fa-9818614d7551%2526table%253Dblock%2526spaceId%253Db74133af-844e-4972-b144-c12554ed8914%2526expirationTimestamp%253D1698350400000%2526signature%253DYCU8p7ySl0bT7GcabU1W0wVmJbVVOz6C6TKJFHUxTd8%3Ftable%3Dblock%26id%3D13c21c56-8a17-44dd-87fa-9818614d7551%26cache%3Dv2&w=3840&q=75

And when I open it in new page, it shows:

400: BAD_REQUEST
Code: INVALID_IMAGE_OPTIMIZE_REQUEST
ID: iad1::b6d7n-1698260486516-913b8605f5e4

@jacksongoode
Copy link

Getting something similar in my deployment recently. I wonder if Notion changed some header in their image responses?

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