Skip to content

Commit

Permalink
Updated code to eliminate trap caused by bug introduced in 7.02.00
Browse files Browse the repository at this point in the history
  • Loading branch information
taers232c committed Dec 26, 2024
1 parent 8c3eb47 commit 199da45
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/winget.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
- uses: vedantmgoyal2009/winget-releaser@v2
with:
identifier: taers232c.GAMADV-XTD3
release-tag: v7.02.03
release-tag: v7.02.04
max-versions-to-keep: 1 # keep only latest versions
installers-regex: '\.msi$'
token: ${{ secrets.WINGET_TOKEN }}
14 changes: 7 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,11 +96,11 @@ script:

before_deploy:
# Comment out for Linux Xenial and Trusty
#- yes | gem update --system --force
#- gem install bundler
#- gem install faraday-net_http -v '3.3.0' # Fix faraday version
#- gem install uri
#- gem install logger
- yes | gem update --system --force
- gem install bundler
- gem install faraday-net_http -v '3.3.0' # Fix faraday version
- gem install uri
- gem install logger
- export TRAVIS_TAG="preview"
- unset LD_LIBRARY_PATH

Expand All @@ -115,8 +115,8 @@ deploy:
# Linux 64-Bit Bionic and Linux ARM64 Focal and Linux ARM64 Bionic and Linux ARM64 Xenial
# edge: true
# Linux Xenial and Trusty
edge:
branch: v2.0.3-beta.4
# edge:
# branch: v2.0.3-beta.4
# branch: v2.0.5-beta.1
on:
repo: taers232c/GAMADV-XTD3
Expand Down
4 changes: 4 additions & 0 deletions src/GamUpdate.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
7.02.04

Updated code to eliminate trap caused by bug introduced in 7.02.00 that occurs when an invalid domain or OU is specified.

7.02.03

Added option `archive` to `gam <UserTypeEntity> update license <NewSKUID> from <OldSKUID>` that causes GAM
Expand Down
14 changes: 8 additions & 6 deletions src/gam/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"""

__author__ = 'Ross Scroggs <[email protected]>'
__version__ = '7.02.03'
__version__ = '7.02.04'
__license__ = 'Apache License 2.0 (http://www.apache.org/licenses/LICENSE-2.0)'

#pylint: disable=wrong-import-position
Expand Down Expand Up @@ -628,7 +628,7 @@ def formatKeyValueList(prefixStr, kvList, suffixStr):
msg += suffixStr
return msg

# Something's wrong with CustomerID
# Something's wrong with CustomerID??
def accessErrorMessage(cd, errMsg=None):
if cd is None:
cd = buildGAPIObject(API.DIRECTORY)
Expand All @@ -652,10 +652,12 @@ def accessErrorMessage(cd, errMsg=None):
Ent.DOMAIN, GC.Values[GC.DOMAIN],
Ent.USER, GM.Globals[GM.ADMIN]])+[Msg.ACCESS_FORBIDDEN],
'')
return formatKeyValueList('',
[Ent.Singular(Ent.CUSTOMER_ID), GC.Values[GC.CUSTOMER_ID],
errMsg],
'')
if errMsg:
return formatKeyValueList('',
[Ent.Singular(Ent.CUSTOMER_ID), GC.Values[GC.CUSTOMER_ID],
errMsg],
'')
return None

def accessErrorExit(cd, errMsg=None):
systemErrorExit(INVALID_DOMAIN_RC, accessErrorMessage(cd or buildGAPIObject(API.DIRECTORY), errMsg))
Expand Down
2 changes: 1 addition & 1 deletion src/gam/googleapiclient/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.

__version__ = "2.146.0"
__version__ = "2.156.0"

0 comments on commit 199da45

Please sign in to comment.