Compare commits

...

2 Commits

Author SHA1 Message Date
2cd795d876 Add debug info 2022-07-18 11:30:55 +02:00
1650724326 Add --bom argument to all commands 2022-07-18 10:48:05 +02:00
2 changed files with 4 additions and 4 deletions

View File

@ -52,6 +52,7 @@ class CasWrapper:
"""
command = self._cas[
'notarize',
'--bom',
local_path,
'-o',
'json',
@ -88,7 +89,7 @@ class CasWrapper:
"""
command_args = ['authenticate', local_path]
if use_hash:
command_args = ['authenticate', '--hash', local_path]
command_args = ['authenticate', '--bom', '--hash', local_path]
command_args.extend(('-o', 'json'))
command = self._cas[command_args]
try:
@ -119,9 +120,9 @@ class CasWrapper:
"""
is_authenticated = False
commit_cas_hash = None
self.ensure_login()
try:
result_json = self.authenticate(local_path, return_json=True)
self._logger.error(result_json)
is_authenticated = result_json['verified']
commit_cas_hash = result_json['hash']
# we can fall with ProcessExecutionError,
@ -140,7 +141,6 @@ class CasWrapper:
Returns authenticate result.
"""
is_authenticated = False
self.ensure_login()
try:
is_authenticated = self.authenticate(
local_path,

View File

@ -2,7 +2,7 @@ from setuptools import setup
setup(
name="cas_wrapper",
version="0.0.2",
version="0.0.3",
author="Stepan Oksanichenko",
author_email="soksanichenko@almalinux.org",
description="The python wrapper around binary cas from "