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

Refused to set unsafe header [...] "accept-encoding" #40

Open
kidsonfilms-python-rules opened this issue Jan 16, 2021 · 1 comment
Open
Labels
invalid? This doesn't seem right waiting response from issuer Further information is requested

Comments

@kidsonfilms-python-rules

I am using the single video search mode using a video ID.

Here is a snippet of my code.

var videoInfo = await yts({ videoId: v })
vidTitle = videoInfo.title
console.log(videoInfo)
songname.innerText = vidTitle;

When I do that, it returns the following error:

Refused to set unsafe header {My Directory Path} "accept-encoding"

I am using this in an Electron Renderer process if this helps.

@kidsonfilms-python-rules kidsonfilms-python-rules changed the title Refused to set unsafe header [...] "user-agent" Refused to set unsafe header [...] "accept-encoding" Jan 16, 2021
@talmobi
Copy link
Owner

talmobi commented Jan 16, 2021

Hello there,

Sounds like a restriction from electron side. Try disabling the restriction or running it outside the render process (e.g. using electrons inter process communications).

@talmobi talmobi added invalid? This doesn't seem right waiting response from issuer Further information is requested labels Jan 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid? This doesn't seem right waiting response from issuer Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants