Wireless Daemon for Linux
 help / color / mirror / Atom feed
From: "Jesse Lentz" <jesse@twosheds.org>
To: "Denis Kenzior" <denkenz@gmail.com>, <iwd@lists.linux.dev>
Subject: Re: [PATCH 2/2] doc: Add State and Role properties to DPP API
Date: Thu, 23 Jun 2022 15:07:06 -0400	[thread overview]
Message-ID: <CKXQZJ5G2LJO.1IJRN5WMBF3DY@laptop> (raw)
In-Reply-To: <4f8abe30-e9c2-0a35-a913-d67c3242ec3a@gmail.com>

Hi Denis,

> Inferring the state is fine if you can do this reliably.  One problem with 
> optional properties is that once they transition from 'defined' -> 'undefined' 
> there is no PropertiesChanged signal that is sent (or rather you have to look 
> into the invalidated_properties array of that signal).
>
> We have been designing our APIs with the assumption that many bindings wouldn't 
> be using this invalidated_properties reliably and added another point of reference.
>
> For example, Station.ConnectedNetwork is invalidated when Station.State goes 
> into the 'disconnected' state and thus not explicitly 'changed'.  But the DBus 
> client can infer that Station.ConnectedNetwork is 'undefined' at that point.
>
> But maybe bindings have improved over the years and we should just rely on 
> invalidated_properties being taken into account properly?  If so, that would be 
> a good argument to make 'State' optional.

Hmm, I wasn't aware of that. I can only comment on the GLib binding,
which works reliably as far as I can tell - it supplies both changed and
invalidated properties to the user-registered callback, which gets
called in response to both changed and to invalidated properties.

But if other bindings handle it incorrectly, then I suppose there's no
compelling reason to make it an optional property.

Thanks.

Sincerely,
Jesse

  reply	other threads:[~2022-06-23 19:07 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-22 19:41 [PATCH 1/2] dpp: Add State and Role properties to dbus API Jesse Lentz
2022-06-22 19:41 ` [PATCH 2/2] doc: Add State and Role properties to DPP API Jesse Lentz
2022-06-22 20:35   ` James Prestwood
2022-06-23 16:30     ` Jesse Lentz
2022-06-23 16:47       ` James Prestwood
2022-06-23 17:24         ` Jesse Lentz
2022-06-23 18:00       ` Denis Kenzior
2022-06-23 19:07         ` Jesse Lentz [this message]
2022-06-23 19:58           ` Denis Kenzior

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CKXQZJ5G2LJO.1IJRN5WMBF3DY@laptop \
    --to=jesse@twosheds.org \
    --cc=denkenz@gmail.com \
    --cc=iwd@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox