ankidroid / ankidroid/Anki-Android

[BUG]: Restricting cleartext network traffic breaks import and statistics pages

Offen
#15,991 4 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Bug Help Wanted Keep Open Priority-Medium
Vorherrschende Sprache
Kotlin
Sterne
11.8k
Forks
2.9k
Ø Merge
2 T. 3 Std.
Gemergte PRs (30 T.)
171

Beschreibung

### Checked for duplicates?

- [X] This issue is not a duplicate

### Does it also happen in the desktop version?

- [ ] This bug does not occur in the latest version of Anki

### What are the steps to reproduce this bug?

Restrict cleartext network traffic globally on your device (which blocks all non-TLS traffic). Open Ankidroid and try importing a deck from a local file or visit statistics page.

### Expected behaviour

The import page (after choosing a local deck package file) and statistics page should be accessible

### Actual behaviour

A blank page with "TypeError: failed to fetch" message is shown instead of import page and statistics page.

### Debug info

```text
AnkiDroid Version = 2.17.6 (568538896be943818ca793dd2635822265712def)

Backend Version = 0.1.34-anki23.12.1 (23.12.1 1a1d4d5419c6b57ef3baf99c9d2d9cf85d36ae0a)

Android Version = 14 (SDK 34)

ProductFlavor = full

Manufacturer = Fairphone

Model = FP5

Hardware = qcom

Webview User Agent = Mozilla/5.0 (Linux; Android 14; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/122.0.6261.90 Mobile Safari/537.36

ACRA UUID = 7a8bdf5f-c6c6-4679-b2fd-0ae240e97685

Crash Reports Enabled = true
```

### (Optional) Anything else you want to share?

_No response_

### Research

- [X] I am reporting a bug specific to AnkiDroid (Android app)
- [X] I have checked the [manual](https://ankidroid.org/docs/manual.html) and the [FAQ](https://github.com/ankidroid/Anki-Android/wiki/FAQ) and could not find a solution to my issue
- [ ] (Optional) I have confirmed the issue is not resolved in the latest alpha release ([instructions](https://docs.ankidroid.org/manual.html#betaTesting))

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.