Skip to content
This repository has been archived by the owner on Dec 3, 2024. It is now read-only.

Run on specified networks does not work #1775

Open
ushai9726 opened this issue Mar 30, 2022 · 15 comments
Open

Run on specified networks does not work #1775

ushai9726 opened this issue Mar 30, 2022 · 15 comments

Comments

@ushai9726
Copy link

When I try to set specific networks Syncthing will work on, I just get a pop-up saying connect to a network to add it to the list.

I am connected to a Wifi network, but it is not added to a list. The setting is not changed, nor any list of networks appear.

If I disconnect from the wifi network and reconnect, nothing happens

Version Information

App Version: 1.19.0
Syncthing Version: v1.19.0.3
Android Version: Android 9
@ushai9726
Copy link
Author

Screenshot_20220330-114314_Syncthing

@ushai9726 ushai9726 reopened this Mar 31, 2022
@Knud3
Copy link

Knud3 commented Apr 14, 2022

Also I have this problem with Samsung S22. Works with S10 with same version.

I have manually selected location permission as "Allow all the time".

Also when trying to disable precise location Syncthing keeps asking location permission even it is given. Does it need precise location?

App Version: 1.19.2
Syncthing Version: v1.19.2
Android Version: Android 12 (newest firmware)

@imsodin
Copy link
Member

imsodin commented Apr 16, 2022

@Knud3 This issue isn't about location permissions and your requests sounds like a question for support on how to configure permissions with Syncthing in general. Please ask such questions on https://forum.syncthing.net instead of the issue tracker. There's more friendly eyes to chime in and help you there. Thanks!

@Knud3
Copy link

Knud3 commented Apr 16, 2022

@imsodin What do you mean? I can't select a specific Wi-Fi network no matter what permission is given. That is an issue, right?

An additional (more generic) question was, that why it asks location permission even when location permission is given.

My English is not the best, so let me illustrate the problem very simply:

  • Location permission: Don't allow > Syncthing gives "You need to grant LOCATION permission to use this feature."
  • Location permission: Allow all the time, Use precise location: Disabled > Syncthing gives "You need to grant LOCATION permission to use this feature."
  • Location permission: Allow all the time, Use precise location: Enabled > Syncthing gives "Please connect to a Wi-Fi to add it to the list"

And yes, it is connected to Wi-Fi all the time.

@imsodin
Copy link
Member

imsodin commented Apr 16, 2022

Thanks for the clarification: So you are experiencing the same bug. My reaction was about the more generic questions: Please direct those to https://forum.syncthing.net.

@Knud3
Copy link

Knud3 commented Apr 20, 2022

I found out that if I turn location on, then it starts working.

Also after Wi-Fi is selected and I disable location and/or any of location permission it stops working and do not work even when everything is set back to where it was. I need to de-select Wi-Fi network and select it again.

@felsgaertner
Copy link

felsgaertner commented May 2, 2022

@Knud3 Thanks for pointing that out - I had the same problem, and after enabling android's location, I could select networks.

@imsodin So that seems to be not an error, but kind of missing documentation: could you mention in the app that it needs location permission and location has to be turned on?

@Knud3
Copy link

Knud3 commented May 2, 2022

I actually got this working without location permission or location enabled.

With help of Tasker I set up profile which send com.nutomic.syncthingandroid.action.START intend when wpa_supplicant component give 'CTRL-EVENT-CONNECTED'.*'WIFINAME logcat entry.

Of course it is little more advanced setup, but for me thats more than ok, because I already use Tasker for ton of stuff.

Tasker also need some ADB commands to get permission to read log entries. https://tasker.joaoapps.com/userguide/en/help/ah_read_logs_grant.html

@ecanja
Copy link

ecanja commented Aug 9, 2022

Any plans to fix this? Unfortunately, that's still an unsolved bug.

@felsgaertner I wouldn't classify this as a documentation issue. Sure, the fact that you have to turn on location for this to work (why actually?) is missing in the documentation and should be added. But the problem @Knud3 pointed out is still there:

I found out that if I turn location on, then it starts working.

Also after Wi-Fi is selected and I disable location and/or any of location permission it stops working and do not work even when everything is set back to where it was. I need to de-select Wi-Fi network and select it again.

I also configured a specific Wi-Fi (with location on) and it worked, but after I turn off the Wi-Fi and location and turn it back on, it won't work anymore. I get the error message

Syncthing is disabled
[...]
Reasons:
Current WiFi SSID is not whitelisted

I can go to the settings and whitelist the exact same Wi-Fi that's already there in the settings and then it works again. But of course I don't want to do this every time when I turn (back) on Wi-Fi and location. But if I don't, synchronization will stop. That's why I would declare that a bug.

@Knud3
Copy link

Knud3 commented Aug 18, 2022

I had to change to Catfriend1 fork of Syncthing Android, because I also had problem with VPN that everytime I leave/enter my home it won't find my network without going to settings and do nothing (yes, just open settings and it started to work).

@LinuxOnTheDesktop
Copy link

Let me add - though perhaps I should create a separate issue for this - that the UI seems to add insult to injury. The injury is the failure to detect a whitelisted network. The insult (as it were) is that it is hard to determine how to work around the problem. For, it seems that the procedure to disable whitelisting is counter-intuitive. That procedure, I take it, is as follows (at least if one wants to retain some other - non-wifi - run-condition). One unticks each of any network boxes of this sort:

image

@LinuxOnTheDesktop
Copy link

It would be good to have someone 'assigned' to this, or a 'milestone' assigned.

@tomasz1986
Copy link
Contributor

I don't believe issues are "assigned" here, i.e. anyone can work on a particular one as long as they're willing to do so. As for the milestone, if no-one is working on the issue, there can be no milestone provided, as nobody can guarantee when the issue gets actually fixed.

@imsodin
Copy link
Member

imsodin commented Feb 24, 2024

Mainly: https://github.com/syncthing/syncthing/wiki/NoPlusOne
Also: https://github.com/syncthing/syncthing-android?tab=readme-ov-file#status-maintenance-mode---co-maintainers-welcome

Just in case: There will be no discussion on this here (github issues). If you want to discuss the "state of this app" or whatever, that's for https://forum.syncthing.net.

@quite
Copy link

quite commented Oct 2, 2024

@ecanja

Sure, the fact that you have to turn on location for this to work (why actually?) is missing in the documentation and should be added.

An app needs to be given the Location permission in order to get hold of details about the Wifi/WLAN it is connected to, because the (relative) physical location could be inferred from those. Location permission is also needed for certain Bluetooth operations, if I recall correctly.

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

No branches or pull requests

8 participants