-
-
Notifications
You must be signed in to change notification settings - Fork 214
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
"CORS or Network issue" error in browser when List refresh blocky #1606
Comments
Hello! any answer for my question? |
Hi! I am having difficulties diagnosing and reproducing your issue. Can you provide other useful information like the logs of blocky and your browser? To help out the community, I would like to kindly request formatting your configuration file. GitHub supports Markdown, so you can delimit your configuration file with triple backticks (see https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#quoting-code) Doing so will help us save time formatting the configuration file and allow us to invest this time resolving the issue. The reference configuration file I used for my tests is the following. Can you confirm it reflects yours? bootstrapDns:
- upstream: https://cloudflare-dns.com/dns-query
ips:
- 104.16.248.249
- 104.16.249.249
upstreams:
timeout: 2s
strategy: strict
groups:
default:
- tcp+udp:1.1.1.1
blocking:
denylists:
ads:
- https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
- https://s3.amazonaws.com/lists.disconnect.me/simple_ad.txt
- http://sysctl.org/cameleon/hosts
- https://s3.amazonaws.com/lists.disconnect.me/simple_tracking.txt
clientGroupsBlock:
default:
- ads
loading:
refreshPeriod: 24h
downloads:
timeout: 60s
strategy: fast
ports:
dns: 1053
http: 4000 |
Hello!
The memory resources we have on our router is limited to 120 MB, so some operations like "list refresh" may take some more time (more than 20 seconds) and the browser throws this error.
from https://github.com/0xERR0R/blocky/blob/main/server/server.go source file, the behaviour changes and the error is not thrown anymore. We set it to 600. |
Thanks for diagnosing the issue further. I agree that moving the value to a configurable setting would be a good idea. The current value could be kept as a default. @0xERR0R, do you think adding a value in the configuration file would be an acceptable approach to resolve this issue? I'd be happy to have a try at solving it. Do you assign issues? If so, mind assigning it to me? |
Contributions are always welcome. We don't assign issues, you can just create a PR for this. If you leave the default value as is, it would not change any existing installation. Please also document the new config param in configuration.md file and in docs/config.yml. |
Thank you for your answers! @TheoTechnicguy it would be great if you are willing to create the PR for this issue! Thank you! |
This commit adds a write timeout configuration parameter. As it is part of the downloading cycle, it is available under `blocking/loading/downloads`. The default value comes from `server/http.go` line 23. Refs: 0xERR0R#1606
* feat(config): read write timeout value This commit adds a write timeout configuration parameter. As it is part of the downloading cycle, it is available under `blocking/loading/downloads`. The default value comes from `server/http.go` line 23. Refs: #1606 * feat(server): get write timeout from config Refs: #1606 * feat(docs): document additional config parameter --------- Co-authored-by: Dimitri Herzog <[email protected]>
Hello!
I run blocky app on an lxc container on Nokia router with OpenWRT as host OS, and when I trigger a List refresh action in WEB UI I got the error("CORS or Network issue"):
All the other API requests works perfectly.
Do you know why?
My config.yml file looks like this:
blocking:
denylists:
ads:
- https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
- https://s3.amazonaws.com/lists.disconnect.me/simple_ad.txt
- http://sysctl.org/cameleon/hosts
- https://s3.amazonaws.com/lists.disconnect.me/simple_tracking.txt
clientGroupsBlock:
default:
- ads
loading:
refreshPeriod: 24h
downloads:
timeout: 60s
strategy: fast
ports:
dns: 1053
http: 4000
Thank you very much!
The text was updated successfully, but these errors were encountered: