mirror of
https://github.com/microsoft/onefuzz.git
synced 2025-06-20 05:23:44 +00:00
update python prereqs (#427)
Updates the following libraries in the service: * azure-core * azure-functions * azure-identity * azure-keyvault-keys * azure-keyvault-secrets * azure-mgmt-compute * azure-mgmt-core * azure-mgmt-loganalytics * azure-mgmt-network * azure-mgmt-resource * azure-mgmt-storage * azure-mgmt-subscription * azure-storage-blob * azure-storage-queue * pydantic * requests * jsonpatch Removes the following libraries in the service: * azure-cli-core * azure-cli-nspkg * azure-mgmt-cosmosdb * azure-servicebus Updates the following libraries in the CLI: * requests * semver * asciimatics * pydantic * tenacity Updates the following libraries in onefuzztypes: * pydantic The primary "legacy" libraries are [azure-graphrbac](https://pypi.org/project/azure-graphrbac/) and azure-cosmosdb-table. The former has not been updated to use azure-identity yet. The later is being rewritten as [azure-data-tables](https://pypi.org/project/azure-data-tables/), but is still in early beta.
This commit is contained in:
@ -85,10 +85,8 @@ class TaskFeature(Enum):
|
||||
class ContainerPermission(Enum):
|
||||
Read = "Read"
|
||||
Write = "Write"
|
||||
Create = "Create"
|
||||
List = "List"
|
||||
Delete = "Delete"
|
||||
Add = "Add"
|
||||
|
||||
|
||||
class JobState(Enum):
|
||||
|
@ -1 +1 @@
|
||||
pydantic~=1.6.1 --no-binary=pydantic
|
||||
pydantic~=1.7.3 --no-binary=pydantic
|
||||
|
@ -7,6 +7,7 @@ import unittest
|
||||
|
||||
from onefuzztypes.models import Scaleset, SecretData, TeamsTemplate
|
||||
from onefuzztypes.requests import NotificationCreate
|
||||
from onefuzztypes.primitives import PoolName, Region
|
||||
from pydantic import ValidationError
|
||||
|
||||
|
||||
@ -53,29 +54,29 @@ class TestScaleset(unittest.TestCase):
|
||||
def test_scaleset_size(self) -> None:
|
||||
with self.assertRaises(ValueError):
|
||||
Scaleset(
|
||||
pool_name="test_pool",
|
||||
pool_name=PoolName("test-pool"),
|
||||
vm_sku="Standard_D2ds_v4",
|
||||
image="Canonical:UbuntuServer:18.04-LTS:latest",
|
||||
region="westus2",
|
||||
region=Region("westus2"),
|
||||
size=-1,
|
||||
spot_instances=False,
|
||||
)
|
||||
|
||||
scaleset = Scaleset(
|
||||
pool_name="test_pool",
|
||||
pool_name=PoolName("test-pool"),
|
||||
vm_sku="Standard_D2ds_v4",
|
||||
image="Canonical:UbuntuServer:18.04-LTS:latest",
|
||||
region="westus2",
|
||||
region=Region("westus2"),
|
||||
size=0,
|
||||
spot_instances=False,
|
||||
)
|
||||
self.assertEqual(scaleset.size, 0)
|
||||
|
||||
scaleset = Scaleset(
|
||||
pool_name="test_pool",
|
||||
pool_name=PoolName("test-pool"),
|
||||
vm_sku="Standard_D2ds_v4",
|
||||
image="Canonical:UbuntuServer:18.04-LTS:latest",
|
||||
region="westus2",
|
||||
region=Region("westus2"),
|
||||
size=80,
|
||||
spot_instances=False,
|
||||
)
|
||||
|
Reference in New Issue
Block a user