Added new matchfield option for events
Some checks failed
Build and test GAM / build (false, build, 1, Build Intel Ubuntu Jammy, ubuntu-22.04) (push) Has been cancelled
Build and test GAM / build (false, build, 10, Build x86_64 macOS 15, macos-15-intel) (push) Has been cancelled
Build and test GAM / build (false, build, 11, Build x86_64 macOS 26, macos-26-intel) (push) Has been cancelled
Build and test GAM / build (false, build, 12, Build Arm MacOS 26, macos-26) (push) Has been cancelled
Build and test GAM / build (false, build, 13, Build Intel Windows, windows-2025-vs2026) (push) Has been cancelled
Build and test GAM / build (false, build, 14, Build Arm Windows, windows-11-arm) (push) Has been cancelled
Build and test GAM / build (false, build, 2, Build Intel Ubuntu Noble, ubuntu-24.04) (push) Has been cancelled
Build and test GAM / build (false, build, 3, Build Arm Ubuntu Noble, ubuntu-24.04-arm) (push) Has been cancelled
Build and test GAM / build (false, build, 4, Build Arm Ubuntu Jammy, ubuntu-22.04-arm) (push) Has been cancelled
Build and test GAM / build (false, build, 5, Build Intel StaticX Legacy, ubuntu-22.04, yes) (push) Has been cancelled
Build and test GAM / build (false, build, 6, Build Arm StaticX Legacy, ubuntu-22.04-arm, yes) (push) Has been cancelled
Build and test GAM / build (false, build, 8, Build Arm MacOS 14, macos-14) (push) Has been cancelled
Build and test GAM / build (false, build, 9, Build Arm MacOS 15, macos-15) (push) Has been cancelled
Build and test GAM / build (false, test, 15, Test Python 3.10, ubuntu-24.04, 3.10) (push) Has been cancelled
Build and test GAM / build (false, test, 16, Test Python 3.11, ubuntu-24.04, 3.11) (push) Has been cancelled
Build and test GAM / build (false, test, 17, Test Python 3.12, ubuntu-24.04, 3.12) (push) Has been cancelled
Build and test GAM / build (false, test, 18, Test Python 3.13, ubuntu-24.04, 3.13) (push) Has been cancelled
Build and test GAM / build (false, test, 19, Test Python 3.15-dev, ubuntu-24.04, 3.15-dev) (push) Has been cancelled
Build and test GAM / build (true, test, 20, Test Python 3.14 freethread, ubuntu-24.04, 3.14) (push) Has been cancelled
Build and test GAM / publish (push) Has been cancelled
Check for Google Root CA Updates / check-certs (push) Has been cancelled
CodeQL / Analyze (python) (push) Has been cancelled
Quarantined Dependency Upgrade / upgrade-dependencies (push) Has been cancelled

This commit is contained in:
Ross Scroggs
2026-05-13 09:55:50 -07:00
parent a162cf870b
commit 425286482f
3 changed files with 23 additions and 2 deletions

View File

@@ -1720,6 +1720,7 @@ gam calendar <CalendarEntity> printacl [todrive <ToDriveAttribute>*]
<EventMatchProperty> ::=
(matchfield attendees <EmailAddressEntity>)|
(matchfield attendeesorganizer <Boolean> <EmailAddressEntity>)|
(matchfield attendeesonlydomainlist <DomainNameList>)|
(matchfield attendeesdomainlist <DomainNameList>)|
(matchfield attendeesnotdomainlist <DomainNameList>)|

View File

@@ -1,3 +1,9 @@
7.43.05
Added option `matchfield attendeesorganizer <Boolean> <EmailAddressEntity>` to `<EventMatchProperty>`
that is used in commands that process events. The match is true if all of the addresses in `<EmailAddressEntity>`
are present as attendees in the event and are an organizer or not based on `<Boolean>`.
7.43.04
Added option `include_suspended_zeros [<Boolean>]` to `gam print vaultcounts` that causes

View File

@@ -25,7 +25,7 @@ https://github.com/GAM-team/GAM/wiki
"""
__author__ = 'GAM Team <google-apps-manager@googlegroups.com>'
__version__ = '7.43.04'
__version__ = '7.43.05'
__license__ = 'Apache License 2.0 (http://www.apache.org/licenses/LICENSE-2.0)'
# pylint: disable=wrong-import-position
@@ -41121,6 +41121,8 @@ LIST_EVENTS_SELECT_PROPERTIES = {
LIST_EVENTS_MATCH_FIELDS = {
'attendees': ['attendees', 'email'],
'attendeesorganizer': ['attendees', 'organizer'],
'attendeesorganiser': ['attendees', 'organizer'],
'attendeesonlydomainlist': ['attendees', 'onlydomainlist'],
'attendeesdomainlist': ['attendees', 'domainlist'],
'attendeesnotdomainlist': ['attendees', 'notdomainlist'],
@@ -41200,6 +41202,8 @@ def getCalendarEventEntity():
calendarEventEntity['matches'].append((matchField, set(getString(Cmd.OB_DOMAIN_NAME_LIST).replace(',', ' ').split())))
elif matchField[1] == 'email':
calendarEventEntity['matches'].append((matchField, getNormalizedEmailAddressEntity()))
elif matchField[1] == 'organizer':
calendarEventEntity['matches'].append((matchField, getBoolean(defaultValue=None), getNormalizedEmailAddressEntity()))
else: #status
calendarEventEntity['matches'].append((matchField,
getChoice(CALENDAR_ATTENDEE_OPTIONAL_CHOICE_MAP, defaultChoice=False, mapChoice=True),
@@ -41531,7 +41535,17 @@ def _eventMatches(event, match):
if domain not in match[1]:
return True
return False
# status
if match[0][1] == 'organizer':
for matchEmail in match[2]:
for attendee in event['attendees']:
if 'email' in attendee and matchEmail == attendee['email']:
if attendee.get('organizer', False) != match[1]:
return False
break
else:
return False
return True
# if match[0][1] == 'status':
for matchEmail in match[3]:
for attendee in event['attendees']:
if 'email' in attendee and matchEmail == attendee['email']: