Skip to content

Commit

Permalink
Merge pull request #1 from Azure/master
Browse files Browse the repository at this point in the history
syncing
  • Loading branch information
useitcloud authored Nov 29, 2018
2 parents 5b87ef6 + ec18d0b commit 7d35523
Show file tree
Hide file tree
Showing 3,260 changed files with 267,923 additions and 28,119 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
8 changes: 6 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
__pycache__/
*.pyc
.pytest_cache
.mypy_cache
.cache

# Virtual environment
env*/
Expand All @@ -26,7 +28,7 @@ build/
# Test results
TestResults/

# Credentials
# Credentials
credentials_real.json
testsettings_local.json
testsettings_local.cfg
Expand Down Expand Up @@ -66,4 +68,6 @@ src/build
*.pubxml

# [begoldsm] ignore virtual env if it exists.
adlEnv/
adlEnv/

code_reports
1 change: 0 additions & 1 deletion azure-applicationinsights/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
include *.rst
include azure_bdist_wheel.py
2 changes: 1 addition & 1 deletion azure-applicationinsights/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This is the Microsoft Azure Application Insights Client Library.
Azure Resource Manager (ARM) is the next generation of management APIs that
replace the old Azure Service Management (ASM).

This package has been tested with Python 2.7, 3.4, 3.5 and 3.6.
This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7.

For the older Azure Service Management (ASM) libraries, see
`azure-servicemanagement-legacy <https://pypi.python.org/pypi/azure-servicemanagement-legacy>`__ library.
Expand Down
2 changes: 1 addition & 1 deletion azure-applicationinsights/azure/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__import__('pkg_resources').declare_namespace(__name__)
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
54 changes: 0 additions & 54 deletions azure-applicationinsights/azure_bdist_wheel.py

This file was deleted.

1 change: 0 additions & 1 deletion azure-applicationinsights/setup.cfg
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
[bdist_wheel]
universal=1
azure-namespace-package=azure-nspkg
18 changes: 9 additions & 9 deletions azure-applicationinsights/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,6 @@
import os.path
from io import open
from setuptools import find_packages, setup
try:
from azure_bdist_wheel import cmdclass
except ImportError:
from distutils import log as logger
logger.warn("Wheel is not available, disabling bdist_wheel hook")
cmdclass = {}

# Change the PACKAGE_NAME only to change folder and different name
PACKAGE_NAME = "azure-applicationinsights"
Expand Down Expand Up @@ -76,10 +70,16 @@
'License :: OSI Approved :: MIT License',
],
zip_safe=False,
packages=find_packages(exclude=["tests"]),
packages=find_packages(exclude=[
'tests',
# Exclude packages that will be covered by PEP420 or nspkg
'azure',
]),
install_requires=[
'msrest>=0.5.4,<2.0.0',
'msrest>=0.5.0',
'azure-common~=1.1',
],
cmdclass=cmdclass
extras_require={
":python_version<'3.0'": ['azure-nspkg'],
}
)
32 changes: 26 additions & 6 deletions azure-batch/HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,26 @@
Release History
===============

5.1.1 (2018-10-16)
++++++++++++++++++

**Bugfixes**

- Fix authentication class to allow HTTP session to be re-used

**Note**

- azure-nspkg is not installed anymore on Python 3 (PEP420-based namespace package)

5.1.0 (2018-08-28)
++++++++++++++++++

- Update operation TaskOperations.add_collection with the following added functionality:
- Retry server side errors.
- Automatically chunk lists of more than 100 tasks to multiple requests.
- If tasks are too large to be submitted in chunks of 100, reduces number of tasks per request.
- Add a parameter to specify number of threads to use when submitting tasks.

5.0.0 (2018-08-24)
++++++++++++++++++

Expand All @@ -19,7 +39,7 @@ Release History
- Operation ComputeNodeOperations.disable_scheduling
- Operation ComputeNodeOperations.reboot
- Operation JobOperations.terminate
- Enum types now use the "str" mixin (class AzureEnum(str, Enum)) to improve the behavior when unrecognized enum values are encountered.
- Enum types now use the "str" mixin (class AzureEnum(str, Enum)) to improve the behavior when unrecognized enum values are encountered.

4.1.3 (2018-04-24)
++++++++++++++++++
Expand Down Expand Up @@ -78,16 +98,16 @@ Release History
- Added a new `allow_low_priority_node` property to `JobManagerTask`, which if `true` allows the `JobManagerTask` to run on a low-priority compute node.
- `PoolResizeParameter` now takes two optional parameters, `target_dedicated_nodes` and `target_low_priority_nodes`, instead of one required parameter `target_dedicated`.
At least one of these two parameters must be specified.
- Added support for uploading task output files to persistent storage, via the `OutputFiles` property on `CloudTask` and `JobManagerTask`.
- Added support for specifying actions to take based on a task's output file upload status, via the `file_upload_error` property on `ExitConditions`.
- Added support for uploading task output files to persistent storage, via the `OutputFiles` property on `CloudTask` and `JobManagerTask`.
- Added support for specifying actions to take based on a task's output file upload status, via the `file_upload_error` property on `ExitConditions`.
- Added support for determining if a task was a success or a failure via the new `result` property on all task execution information objects.
- Renamed `scheduling_error` on all task execution information objects to `failure_information`. `TaskFailureInformation` replaces `TaskSchedulingError` and is returned any
time there is a task failure. This includes all previous scheduling error cases, as well as nonzero task exit codes, and file upload failures from the new output files feature.
time there is a task failure. This includes all previous scheduling error cases, as well as nonzero task exit codes, and file upload failures from the new output files feature.
- Renamed `SchedulingErrorCategory` enum to `ErrorCategory`.
- Renamed `scheduling_error` on `ExitConditions` to `pre_processing_error` to more clearly clarify when the error took place in the task life-cycle.
- Added support for provisioning application licenses to your pool, via a new `application_licenses` property on `PoolAddParameter`, `CloudPool` and `PoolSpecification`.
Please note that this feature is in gated public preview, and you must request access to it via a support ticket.
- The `ssh_private_key` attribute of a `UserAccount` object has been replaced with an expanded `LinuxUserConfiguration` object with additional settings for a user ID and group ID of the
- The `ssh_private_key` attribute of a `UserAccount` object has been replaced with an expanded `LinuxUserConfiguration` object with additional settings for a user ID and group ID of the
user account.
- Removed `unmapped` enum state from `AddTaskStatus`, `CertificateFormat`, `CertificateVisibility`, `CertStoreLocation`, `ComputeNodeFillType`, `OSType`, and `PoolLifetimeOption` as they were not ever used.
- Improved and clarified documentation.
Expand Down Expand Up @@ -124,7 +144,7 @@ Release History

- Added support for joining a CloudPool to a virtual network on using the network_configuration property.
- Added support for application package references on CloudTask and JobManagerTask.
- Added support for automatically terminating jobs when all tasks complete or when a task fails, via the on_all_tasks_complete property and
- Added support for automatically terminating jobs when all tasks complete or when a task fails, via the on_all_tasks_complete property and
the CloudTask exit_conditions property.

0.30.0rc5
Expand Down
3 changes: 2 additions & 1 deletion azure-batch/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
include *.rst
include azure_bdist_wheel.py
include azure/__init__.py

7 changes: 4 additions & 3 deletions azure-batch/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ Microsoft Azure SDK for Python

This is the Microsoft Azure Batch Client Library.

This package has been tested with Python 2.7, 3.4, 3.5 and 3.6.
This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7.

For a more complete set of Azure libraries, see the `azure <https://pypi.python.org/pypi/azure>`__ bundle package.


Compatibility
Expand All @@ -28,14 +30,13 @@ If you see azure==0.11.0 (or any version below 1.0), uninstall it first:
Usage
=====

For code examples, see `the Batch samples repo
For code examples, see `the Batch samples repo
<https://github.com/Azure/azure-batch-samples/tree/master/Python>`__
on GitHub or see `Batch
<https://docs.microsoft.com/python/api/overview/azure/batch>`__
on docs.microsoft.com.



Provide Feedback
================

Expand Down
2 changes: 1 addition & 1 deletion azure-batch/azure/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__import__('pkg_resources').declare_namespace(__name__)
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
6 changes: 3 additions & 3 deletions azure-batch/azure/batch/batch_auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,10 @@ def __init__(self, account_name, key):
super(SharedKeyCredentials, self).__init__()
self.auth = SharedKeyAuth(self.header, account_name, key)

def signed_session(self):
def signed_session(self, session=None):

session = super(SharedKeyCredentials, self).signed_session()
session = super(SharedKeyCredentials, self).signed_session(session=session)
session.auth = self.auth

return session


4 changes: 4 additions & 0 deletions azure-batch/azure/batch/batch_service_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
from .operations.task_operations import TaskOperations
from .operations.compute_node_operations import ComputeNodeOperations
from . import models
from .custom.patch import patch_client


class BatchServiceClientConfiguration(AzureConfiguration):
Expand Down Expand Up @@ -112,3 +113,6 @@ def __init__(
self._client, self.config, self._serialize, self._deserialize)
self.compute_node = ComputeNodeOperations(
self._client, self.config, self._serialize, self._deserialize)


patch_client()
Empty file.
19 changes: 19 additions & 0 deletions azure-batch/azure/batch/custom/custom_errors.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# --------------------------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# --------------------------------------------------------------------------------------------


class CreateTasksErrorException(Exception):
""" Aggregate Exception containing details for any failures from a task add operation.
:param str message: Error message describing exit reason
:param [~TaskAddParameter] pending_task_list: List of tasks remaining to be submitted.
:param [~TaskAddResult] failure_tasks: List of tasks which failed to add
:param [~Exception] errors: List of unknown errors forcing early termination
"""
def __init__(self, message, pending_task_list=None, failure_tasks=None, errors=None):
self.message = message
self.pending_tasks = list(pending_task_list)
self.failure_tasks = list(failure_tasks)
self.errors = list(errors)
Loading

0 comments on commit 7d35523

Please sign in to comment.