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

fix(nm): avoid error when Modem.Location interface is missing #4516

Conversation

mattdibi
Copy link
Contributor

@mattdibi mattdibi commented Mar 31, 2023

As per ModemManager DBus API documentation, the Modem.Location interface:

...allows devices to provide location information to client applications. Not all devices can provide this information, or even if they do, they may not be able to provide it while a data session is active.

This interface will only be available once the modem is ready to be registered in the cellular network...

This meant that, it was possible to find this error during Modem configuration:

org.freedesktop.dbus.errors.UnknownMethod: No such interface “org.freedesktop.ModemManager1.Modem.Location” on object at path /org/freedesktop/ModemManager1/Modem/8

This PR add the required checks to avoid throwing errors due to the lack of the Modem.Location interface during Modem configuration.

@mattdibi mattdibi changed the title fix(nm): avoid error when Modem.Location interface is missing fix(nm): avoid error when Modem.Location interface is missing Mar 31, 2023
@mattdibi mattdibi marked this pull request as ready for review March 31, 2023 14:42
@pierantoniomerlino pierantoniomerlino merged commit b01a813 into eclipse-kura:develop Apr 3, 2023
github-actions bot pushed a commit that referenced this pull request Apr 3, 2023
* fix(nm): avoid error when Modem.Location interface is missing

* fix: simplify logic

* fix: do not call Location.Setup if there's no location source available

* fix: change log level

(cherry picked from commit b01a813)
mattdibi added a commit that referenced this pull request Apr 4, 2023
…port release-5.3.0] (#4522)

fix(nm): avoid error when `Modem.Location` interface is missing (#4516)

* fix(nm): avoid error when Modem.Location interface is missing

* fix: simplify logic

* fix: do not call Location.Setup if there's no location source available

* fix: change log level

(cherry picked from commit b01a813)

Co-authored-by: Mattia Dal Ben <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants