Skip to content

fix: connectivity service#16232

Open
alperozturk96 wants to merge 20 commits into
masterfrom
fix/connectivity-serv
Open

fix: connectivity service#16232
alperozturk96 wants to merge 20 commits into
masterfrom
fix/connectivity-serv

Conversation

@alperozturk96
Copy link
Copy Markdown
Collaborator

@alperozturk96 alperozturk96 commented Jan 2, 2026

  • Tests written, or not not needed

Fixes: #14681

Deduplicates isNetworkAndServerAvailable logic

Implements ConnectivityManager.NetworkCallback for better network state listening

Removes deprecated logics

Adds better documentation

Adds exception handling for http call to prevent temporary issues thus we don't inform user with incorrect availability state

Uses for metered detection NET_CAPABILITY_NOT_METERED instead of NET_CAPABILITY_NOT_RESTRICTED

Removes network change receiver uses listener for much better reaction to network change

Converts to Kotlin

ZetaTom

This comment was marked as resolved.

@TheCrowned
Copy link
Copy Markdown

I gave this build a try - same error for me (both on upload, and on file listing).
The screenshot clearly shows network is available, both as WiFi and as data.
If it can help troubleshooting, upload works when I turn off WiFi and only leave data.
Screenshot_20260211-190409_Nextcloud QA

@alperozturk96
Copy link
Copy Markdown
Collaborator Author

@TheCrowned Hello. Thank you for the feedback. I updated the PR. Could you please check via latest APK file once its generated?

@nextcloud nextcloud deleted a comment from github-actions Bot Apr 7, 2026
@nextcloud nextcloud deleted a comment from github-actions Bot Apr 7, 2026
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 7, 2026

APK file: https://github.com/nextcloud/android/actions/runs/24078742104/artifacts/6304625309
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

@alperozturk96 alperozturk96 force-pushed the fix/connectivity-serv branch 2 times, most recently from 2181611 to 1fb36f6 Compare April 8, 2026 09:59
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 8, 2026

APK file: https://github.com/nextcloud/android/actions/runs/24130016101/artifacts/6325219637
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

@alperozturk96 alperozturk96 added the performance 🚀 Performance improvement opportunities (non-crash related) label Apr 8, 2026
@alperozturk96 alperozturk96 force-pushed the fix/connectivity-serv branch from 375d7aa to 71b5321 Compare April 8, 2026 14:28
@TheCrowned
Copy link
Copy Markdown

Still no, I'm sorry. WiFi is on, data is off (and in that condition I'm writing this message), and the app reports no connectivity when trying to uplaod files via the Share button in gallery. Also, the app allows to navigate through nextcloud directories and doesn't say "no connectivity", but shows all dirs I had not previously opened as empty.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 8, 2026

APK file: https://github.com/nextcloud/android/actions/runs/24140818844/artifacts/6330035040
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

alperozturk96 and others added 19 commits May 11, 2026 15:49
# Conflicts:
#	app/src/main/java/com/nextcloud/client/network/ConnectivityServiceImpl.java
Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
…vice.java

Co-authored-by: Tom <70907959+ZetaTom@users.noreply.github.com>
Signed-off-by: Alper Öztürk <67455295+alperozturk96@users.noreply.github.com>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>

# Conflicts:
#	gradle/libs.versions.toml
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
@alperozturk96 alperozturk96 force-pushed the fix/connectivity-serv branch from 71cfd4c to bfe2f88 Compare May 11, 2026 13:51
@alperozturk96
Copy link
Copy Markdown
Collaborator Author

@TheCrowned Could you explain your setup I cannot reproduce this issue?

Is it local Nextcloud instance?
VPN on or off?

@github-actions
Copy link
Copy Markdown

APK file: https://github.com/nextcloud/android/actions/runs/25674377280/artifacts/6920775898
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
@github-actions
Copy link
Copy Markdown

Codacy

SpotBugs

CategoryBaseNew
Bad practice3535
Correctness6767
Dodgy code216215
Experimental11
Internationalization77
Malicious code vulnerability22
Multithreaded correctness3434
Performance4242
Security1616
Total420419

@github-actions
Copy link
Copy Markdown

APK file: https://github.com/nextcloud/android/actions/runs/25717704400/artifacts/6937331531
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

@github-actions
Copy link
Copy Markdown

blue-Light-Screenshot test failed, but no output was generated. Maybe a preliminary stage failed.

@github-actions
Copy link
Copy Markdown

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

Labels

2. developing performance 🚀 Performance improvement opportunities (non-crash related)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Upload Failure with "No Internet Connection" Message After Upgrading to Version 3.31.0 on Android App

4 participants