Open Medullitus opened 1 month ago
Same. Just tried now
Does not work for me either.
@Medullitus thanks for opening this issue -- I was also experiencing it, but haven't had time to dig in or debug @hardchor -- thanks for the reference link -- very helpful!
@ozdemir08 I started looking into this today.
I updated my local package.json
with the latest version of youtube-transcript "youtube-transcript": "^1.2.1"
and ran some tests:
Created a new test.mjs
file:
import { YoutubeTranscript } from "youtube-transcript";
YoutubeTranscript.fetchTranscript("https://www.youtube.com/watch?v=nJ660t5ku9A").then(console.log);
And ran it with node src/test.mjs
and was able to get the transcript data back -- no issues.
While running it in the plugin loaded in Obsidian though, I'm seeing a CORS error:
This fetch
from YoutubeTranscript seems to be failing:
I found one possible solution, but haven't tried it out yet: https://github.com/wanadev/obsidian-http-request -- this runs a proxy and wraps the requests so that CORS errors are bypassed. Implementing this would probably require us to bring in the fetchTranscript
functionality from YoutubeTranscript
, which I don't really like.
@hardchor @ozdemir08 & others -- do you have any suggestions?
When I try to add YT video url and push the "Generate summary" button it gives me error! The error is that "Error: [YoutubeTranscript] TypeError: Cannot read properties of undefinied (reading 'transcriptBodyRenderer'). So I can't use the plugin...