After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 722421 - Make PersonaStore.trust_level abstract
Make PersonaStore.trust_level abstract
Status: RESOLVED OBSOLETE
Product: folks
Classification: Platform
Component: libfolks
git master
Other All
: Normal normal
: next abi break
Assigned To: folks-maint
folks-maint
Depends on:
Blocks:
 
 
Reported: 2014-01-17 14:44 UTC by Renato Araujo Oliveira Filho
Modified: 2018-09-21 16:08 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
fix it using auto_trust_level property (1.82 KB, patch)
2014-01-17 14:46 UTC, Renato Araujo Oliveira Filho
rejected Details | Review
core: Document that PersonaStore.trust_level must not be set by clients (1.89 KB, patch)
2014-01-17 22:47 UTC, Philip Withnall
committed Details | Review

Description Renato Araujo Oliveira Filho 2014-01-17 14:44:36 UTC
Setting the trust_level using folks_persona_store_set_trust_level of an EDS persona store does not work. 

Looking on the EDS persona store source code I found that this class overwrite the trust_level on the function "_update_trust_level" based on some of the store capabilities.
Comment 1 Renato Araujo Oliveira Filho 2014-01-17 14:46:16 UTC
Created attachment 266551 [details] [review]
fix it using auto_trust_level property

This is a basic fix for it which uses a new EDS Persona store property "auto_trust_level" where you can disable/enable the auto trust level.
Comment 2 Philip Withnall 2014-01-17 22:44:31 UTC
As discussed on IRC, this is the wrong approach to prevent folks to link things: anti-links should be used instead.

However, the trust-level API isn’t great, and the documentation didn’t mention that the setter method is basically internal API, and shouldn’t be called by clients.

I’m appropriating this bug and turning it into a request to make the PersonaStore.trust_level property abstract when we next break API. Then backends can implement it how they like, and there will be no public setter.
Comment 3 Philip Withnall 2014-01-17 22:47:03 UTC
Created attachment 266586 [details] [review]
core: Document that PersonaStore.trust_level must not be set by clients

It’s effectively internal API, and is only exposed publicly due to me
foolishly not making it abstract when first implementing it.
Comment 4 Philip Withnall 2014-01-17 22:47:56 UTC
Pushed some documentation improvements, but the API rework still needs to be done (when we next break API).

Attachment 266586 [details] pushed as c505430 - core: Document that PersonaStore.trust_level must not be set by clients
Comment 5 GNOME Infrastructure Team 2018-09-21 16:08:16 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/folks/issues/88.