@@ -244,33 +244,31 @@ def from_domain_model(
244244 GroupGet .from_domain_model (* gi ) for gi in groups_by_type .standard
245245 ],
246246 all = GroupGet .from_domain_model (* groups_by_type .everyone ),
247- product = GroupGet .from_domain_model (* my_product_group )
248- if my_product_group
249- else None ,
247+ product = (
248+ GroupGet .from_domain_model (* my_product_group )
249+ if my_product_group
250+ else None
251+ ),
250252 )
251253
252254
253255class GroupUserGet (OutputSchemaWithoutCamelCase ):
254256
255- # Identifiers
256257 id : Annotated [UserID | None , Field (description = "the user's id" )] = None
257- user_name : Annotated [UserNameID , Field (alias = "userName" )]
258+ user_name : Annotated [
259+ UserNameID | None , Field (alias = "userName" , description = "None if private" )
260+ ] = None
258261 gid : Annotated [
259262 GroupID | None ,
260263 Field (description = "the user primary gid" ),
261264 ] = None
262265
263- # Private Profile
264266 login : Annotated [
265267 LowerCaseEmailStr | None ,
266- Field (description = "the user's email, if privacy settings allows" ),
267- ] = None
268- first_name : Annotated [
269- str | None , Field (description = "If privacy settings allows" )
270- ] = None
271- last_name : Annotated [
272- str | None , Field (description = "If privacy settings allows" )
268+ Field (description = "the user's email or None if private" ),
273269 ] = None
270+ first_name : Annotated [str | None , Field (description = "None if private" )] = None
271+ last_name : Annotated [str | None , Field (description = "None if private" )] = None
274272 gravatar_id : Annotated [
275273 str | None , Field (description = "the user gravatar id hash" , deprecated = True )
276274 ] = None
@@ -309,6 +307,11 @@ class GroupUserGet(OutputSchemaWithoutCamelCase):
309307 "userName" : "mrprivate" ,
310308 "gid" : "55" ,
311309 },
310+ # very private user
311+ {
312+ "id" : "6" ,
313+ "gid" : "55" ,
314+ },
312315 {
313316 "id" : "56" ,
314317 "userName" : "mrpublic" ,
0 commit comments