Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/image-copy/HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
Release History
===============

1.0.3
++++++
* Fix the issue for sasTokenParsing, removing python related warnings from the sasToken(cmd_output was unfiltered)

1.0.2
++++++
* Create temporary storage account with minimum TLS version set to `TLS1_2`
Expand Down
12 changes: 8 additions & 4 deletions src/image-copy/azext_imagecopy/create_target.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
import datetime
import time

from knack.util import CLIError
from azext_imagecopy.cli_utils import (get_storage_account_id_from_blob_path,
prepare_cli_command, run_cli_command)
from knack.log import get_logger

from azext_imagecopy.cli_utils import run_cli_command, prepare_cli_command, get_storage_account_id_from_blob_path
from knack.util import CLIError

logger = get_logger(__name__)

Expand Down Expand Up @@ -73,6 +73,10 @@ def create_target_image(location, transient_resource_group_name, source_type, so

sas_token = run_cli_command(cli_cmd)
sas_token = sas_token.rstrip("\n\r") # STRANGE
# Remove python related warnings from the SAS token if there are warning included in the SAS token
if len(sas_token.split()) > 1:
sas_token = sas_token.split()[-1]

logger.debug("sas token: %s", sas_token)

# create a container in the target blob storage account
Expand Down Expand Up @@ -206,7 +210,7 @@ def wait_for_blob_copy_operation(blob_name, target_container_name, target_storag


def get_random_string(length):
import string
import random
import string
chars = string.ascii_lowercase + string.digits
return ''.join(random.choice(chars) for _ in range(length))
4 changes: 2 additions & 2 deletions src/image-copy/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
# --------------------------------------------------------------------------------------------

from codecs import open
from setuptools import setup, find_packages
from setuptools import find_packages, setup

VERSION = "1.0.2"
VERSION = "1.0.3"

CLASSIFIERS = [
'Development Status :: 4 - Beta',
Expand Down
Loading