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

UI errors: only application/json is allowed | 415 #4970

Closed
3 tasks done
pendie opened this issue Sep 29, 2022 · 43 comments
Closed
3 tasks done

UI errors: only application/json is allowed | 415 #4970

pendie opened this issue Sep 29, 2022 · 43 comments
Assignees
Milestone

Comments

@pendie
Copy link

pendie commented Sep 29, 2022

Prerequisites

  • I have checked the Wiki and Discussions and found no answer

  • I have searched other issues and found no duplicates

  • I want to report a bug and not ask a question

Operating system type

Linux, Other (please mention the version in the description)

CPU architecture

ARMv7

Installation

Custom port

Setup

On a router, DHCP is handled by AdGuard Home

AdGuard Home version

AdGuard Home v0.107.14

Description

Error: control/querylog_clear | only application/json is allowed | 415

@ainar-g ainar-g self-assigned this Sep 29, 2022
@ainar-g ainar-g added this to the v0.107.15 milestone Sep 29, 2022
@ainar-g ainar-g changed the title clear query logs eror UI errors: only application/json is allowed | 415 Sep 29, 2022
@ainar-g
Copy link
Contributor

ainar-g commented Sep 29, 2022

Thanks for reporting! We'll try to fix these ASAP.

@kiwilad-nz
Copy link

Can confirm after updating in the last 5 minutes, this is preventing me from clearing the query log.

@ainar-g ainar-g pinned this issue Sep 29, 2022
@ghost
Copy link

ghost commented Sep 29, 2022

Same issue after today's update.

@n7lmf
Copy link

n7lmf commented Sep 29, 2022

Same issue. Affects the "Use AdGuard browsing security web service", "Use AdGuard parental control web service", and "Use Safe Search" buttons as well.

@fengyuclub
Copy link

Had the same problem just after the update

@pendie
Copy link
Author

pendie commented Sep 30, 2022

how to disable adguard notification update

@Disqu3-mirOir-qt
Copy link

@ainar-g

probably because this:

Screenshot_20220930-055345_1.jpg

// WriteJSONResponse sets the content-type header in w.Header() to 
 // "application/json", encodes resp to w, calls Error on any returned error, and 
 // returns it as well. 
 func WriteJSONResponse(w http.ResponseWriter, r *http.Request, resp any) (err error) { 
         w.Header().Set(HdrNameContentType, HdrValApplicationJSON) 
         err = json.NewEncoder(w).Encode(resp) 
         if err != nil { 
                 Error(r, w, http.StatusInternalServerError, "encoding resp: %s", err) 
         } 
  
         return err 
 }

@Disqu3-mirOir-qt
Copy link

w.Header().Set("Content-Type", "text/html")

maybe can solved issue

@hsdbql
Copy link

hsdbql commented Sep 30, 2022

I installed adguard home on an amd64-architected Debian 10 server, And ran into the same problem. So I installed it again on the Arm64 board, and it's still the same.

@eroxrodriguez
Copy link

Same here. Cant deactivate Ad Guard. And some other featrures like a tik brings error messages. have updated and restarted my ubuntu. nothing helps.

@yyysuo
Copy link

yyysuo commented Sep 30, 2022

same problem.

@reggieds
Copy link

Update to v0.107.14. Still have same issue.

@Hanfei799
Copy link

same problem.

adguard pushed a commit that referenced this issue Sep 30, 2022
Updates #4970.

Squashed commit of the following:

commit 10365d9
Author: Ainar Garipov <A.Garipov@AdGuard.COM>
Date:   Fri Sep 30 14:23:06 2022 +0300

    all: imp docs, names

commit cff1103
Author: Ainar Garipov <A.Garipov@AdGuard.COM>
Date:   Fri Sep 30 14:02:38 2022 +0300

    home: imp content-type check
@ainar-g
Copy link
Contributor

ainar-g commented Sep 30, 2022

This should be fixed on the Edge channel starting from version v0.108.0-a.307+4d404b88. Please verify that the fix is working for you. If it does, we plan to release it along with some other fixes.

@ShlomiD83
Copy link

@ainar-g I can confirm the fix is working using the edge image on docker.

@MiKing233
Copy link

i got same problem on my armv8 devices, v0.107.14

@njiangk
Copy link

njiangk commented Sep 30, 2022

same issue

@dimdedsec
Copy link

Got same issue here, have updated core to
v0.108.0-b.16 on amlogic s905x openwrt device but the problem is not fix yet.

@alfinauzikri
Copy link

Same issue after today's update..

@SurikasZen
Copy link

SurikasZen commented Oct 1, 2022

Same ussue with use safe search and use adguard parental control web services. When you try turn off you get Error.
Error: control/safesearch/disable | only application/json is allowed | 415
Error: control/parental/disable | only application/json is allowed | 415

@tzaky
Copy link

tzaky commented Oct 1, 2022

FIX: Install the EDGE version: "curl -s -S -L https://raw.githubusercontent.com/AdguardTeam/AdGuardHome/master/scripts/install.sh | sh -s -- -c edge"

@vger74656
Copy link

FIX: Install the EDGE version: "curl -s -S -L https://raw.githubusercontent.com/AdguardTeam/AdGuardHome/master/scripts/install.sh | sh -s -- -c edge"

This doesn't work for me, it just asks me if I want to reinstall or uninstall, if I put -r at the end, it borks up the install and I had to recover from backups.

@tzaky
Copy link

tzaky commented Oct 2, 2022

FIX: Install the EDGE version: "curl -s -S -L https://raw.githubusercontent.com/AdguardTeam/AdGuardHome/master/scripts/install.sh | sh -s -- -c edge"

This doesn't work for me, it just asks me if I want to reinstall or uninstall, if I put -r at the end, it borks up the install and I had to recover from backups.

uninstall the current version and install the edge version.

@vger74656
Copy link

Tried this, the web interface is still broken after edge installation, refuses to connect on port 3000

@Glassertje
Copy link

FIX: Install the EDGE version: "curl -s -S -L https://raw.githubusercontent.com/AdguardTeam/AdGuardHome/master/scripts/install.sh | sh -s -- -c edge"

Thaks for the fix. Works like a charm.

@vger74656 I have a raspberry pi 4 and did it:

sudo ./AdGuardHome -s uninstall
curl -s -S -L https://raw.githubusercontent.com/AdguardTeam/AdGuardHome/master/scripts/install.sh | sh -s -- -c edge -r

After that i could acces via port 3000 and configurate it again.
First i was getting an error but that was becourse i had no internet, so i first changed the dns after that in my router.

@lchagnoleau
Copy link

Hi, I'm running AdGuard over Docker and docker-compose on Raspberry pi. I do not understand how I can fix it. If someone know it :)
Here is my conf:

  adguard:
    image: adguard/adguardhome
    container_name: adguard
    restart: unless-stopped
    volumes:
      - ${CONFIG}/adguard:/opt/adguardhome/conf
      - ${DATA}/adguard:/opt/adguardhome/work
    ports:
      - 53:53/tcp
      - 53:53/udp
      - 853:853/tcp
      - 853:853/udp
      - 784:784/udp
      - 8853:8853/udp
      - 5443:5443/tcp
      - 5443:5443/udp
      - 3000:80/tcp

@toby1991
Copy link

toby1991 commented Oct 3, 2022

+1 facing the same problem

@skl283
Copy link

skl283 commented Oct 3, 2022

This should be fixed on the Edge channel starting from version v0.108.0-a.307+4d404b88. Please verify that the fix is working for you. If it does, we plan to release it along with some other fixes.

any news to a new stable Release with these fixes?

@ainar-g
Copy link
Contributor

ainar-g commented Oct 3, 2022

We're planning to release the fix to Beta and Release channels today.

@ainar-g ainar-g closed this as completed Oct 3, 2022
@kiwilad-nz
Copy link

Thank you guys! Appears to be working so far with no errors.

@lchagnoleau
Copy link

Works for me too !
A lot of thanks :)

@Al4ndil
Copy link

Al4ndil commented Oct 3, 2022

Works for me too :)
Thx a lot !

@arivelli
Copy link

it isn't working for me neither (from a fresh HomeAsistant OS instalation)

@fernvenue
Copy link
Contributor

Still shows on v0.107.19 armv7.

@mhellsten
Copy link

mhellsten commented Mar 1, 2023

This is still broken on "Custom filtering rules page" in the latest and edge builds:
Error: control/filtering/set_rules | only content-type application/json is allowed | 415
including v0.108.0-a.449+a772212d and v0.108.0-b.28

heyxkhoa pushed a commit to heyxkhoa/AdGuardHome that referenced this issue Mar 20, 2023
Updates AdguardTeam#4970.

Squashed commit of the following:

commit 10365d9
Author: Ainar Garipov <A.Garipov@AdGuard.COM>
Date:   Fri Sep 30 14:23:06 2022 +0300

    all: imp docs, names

commit cff1103
Author: Ainar Garipov <A.Garipov@AdGuard.COM>
Date:   Fri Sep 30 14:02:38 2022 +0300

    home: imp content-type check
@itsthejb
Copy link

Just got this trying to clear stats on v0.107.44

Screenshot 2024-02-10 at 08 53 14

@RyderCragie
Copy link

Screenshot 2024-02-10 at 15 42 10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests