[Bug 27727] account storage plugins can contain partial accounts

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Tue Jan 7 09:28:34 PST 2014


https://bugs.freedesktop.org/show_bug.cgi?id=27727

--- Comment #49 from Simon McVittie <simon.mcvittie at collabora.co.uk> ---
(In reply to comment #48)
> Added 2 trivial patches on top of you -round3 branch:
> http://cgit.collabora.com/git/user/xclaesse/telepathy-mission-control.git/
> log/?h=account-rework-27727-round3

They look fine.

Still to be done for this branch, then:

(In reply to comment #45)
> > If we have an untyped param, now is a good time to move to to sa->parameters
> > and consider that to be a change.
> 
> It breaks a regression test, which is trying to assert that if you have an
> account in a low-priority location, just starting MC isn't enough to get it
> copied into a higher-priority location. The same test verifies that
> keyfile-escaped parameters (UntypedParameters) are unescaped correctly.
> 
> For that test to check what it's meant to check, I need to split it into
> "the one that is in a low-priority location" and "the one that has old-style
> parameters".

Still to do

(In reply to comment #46)
> 0e7da13f3d4a1607372420fedca1124046b8716c _mcd_account_manager_setup:
> Nitpicking: you iterate on hash table values, but the key is already the
> unique_name, no? so you could just take the key instead of calling
> mcd_account_get_unique_name().

Yes, I think so. Still to do.

(In reply to comment #47)
> a231756bd832064d531195656df1110c63575717, commit msg says: "We should never
> have get_something(), commit() with a non-NULL account"
> s/non-// or s/never/always/ if I understand correctly, right?

No, I think I was right in the commit message. Read it as:

we should never have [any of]
  * get_something()
  * commit with a non-NULL account, or
  * set_something()
called on us while [either of]
  * inactive, or
  * with a nonexistent account

Here is (maybe) a better phrasing:

Methods that act on a single account should always be called with an account
that actually exists - if it didn't, where did you get its name from? - so
treat it as an error if they are called with a nonexistent account.

commit() has a dual role here: the method that takes a non-NULL account (which
acts on a single account, as described) and the method that takes NULL for the
account name (which is OK to call at any time, to commit all of our 0-or-more
accounts).

While we are not active, we don't claim to have any accounts at all, so treat
it as an error if any such method is called while inactive.

One exception (for now) is that it's less bad if delete_async() is called for
an account that doesn't exist, because in that case, the desired state "that
account doesn't exist" has already been reached. A later commit changes this to
be an error.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.


More information about the telepathy-bugs mailing list