Ministack: Free, open-source local AWS emulator - 60+ services, Terraform compatible, real databases. Free forever. MIT licensed.
Python awsaws-emulatoraws-localaws-sdkdevtoolsdockerdynamodbec2emulatorlambdalocalstacklocalstack-alternativeministackmock-awsopen-sourcepythons3sqsterraform
release v1.5.10 (#1686)
Nahuel Nucerae6abf179c3d5
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 4bd50e78..010df17d 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -4,29 +4,35 @@ All notable changes to MiniStack will be documented here.Format follows [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).Versioning follows [Semantic Versioning](https://semver.org/).-## [Unreleased]-### Changed-- **API Gateway — a REST method's `COGNITO_USER_POOLS` authorizer is enforced** — the v1 data plane matched only `NONE`, `AWS_IAM` and `CUSTOM` and passed everything else through, so a method fronted by a user-pool authorizer served every caller: an anonymous request reached the backend, and `requestContext.authorizer.claims` was never populated, leaving a handler that branches on `claims` to take its no-claims path locally while the same code denied the request on AWS. The token named by the authorizer's `identitySource` (defaulting to the Authorization header, with or without a `Bearer` prefix) is now verified against the pools in `providerARNs` — RS256 signature against the pool's JWKS, `iss` naming one of those pools, and `exp`/`nbf`/`iat` — and its claims reach the backend as `requestContext.authorizer.claims`, stringified as API Gateway passes them, a list claim such as `cognito:groups` space-joined in brackets (`[admins staff]`). ID and access tokens are both accepted and the app client is never checked, matching AWS: a REST authorizer is configured with pool ARNs only, which is why it has no audience to validate. A method carrying `authorizationScopes` additionally requires one of those scopes in the token's `scope`/`scp` and answers `403` otherwise; everything else that fails is `401`. `PutMethod` also stops discarding `authorizationScopes`, so `GetMethod` reports it and a CloudFormation `AWS::ApiGateway::Method` declaring it provisions it.+## [1.5.10] — 2026-09-10### Added-- **CloudFormation — the `Rules` section is evaluated** — a template's rules were ignored; they now run after the parameters resolve and before any resource is touched, on `CreateStack`, `UpdateStack` and `CreateChangeSet`: a rule whose `RuleCondition` is false is skipped, a false `Assert` refuses the operation with its `AssertDescription` as a `ValidationError`, and the CDK's `CheckBootstrapVersion` rule therefore refuses an outdated bootstrap version instead of passing silently. `Fn::And`, `Fn::Or`, `Fn::Not`, `Fn::Equals`, `Fn::If`, `Fn::Contains`, `Fn::EachMemberEquals`, `Fn::EachMemberIn` and `Ref` are evaluated; `Fn::RefAll`, `Fn::ValueOf` and `Fn::ValueOfAll` are served from the EC2 store for the VPC, subnet and security-group id types, and a rule over any other type is skipped with a warning. A function outside the rule set is refused as a template format error. Contributed by @iot-rocket.-- **CloudFormation — the `AWS::Include` transform** — an embedded `Fn::Transform` naming `AWS::Include` was carried into the stack as a literal key; it is now replaced by the contents of the S3 object its `Location` points to (JSON or plain YAML, a key-value object) before the template is validated: next to a sibling resource inside `Resources`, as a whole `Properties` map, inside one next to other properties, in `Mappings`, or in `Outputs`. A location that is not an `s3://` URI, a snippet with a YAML shorthand tag, a missing object, a snippet that is not an object and a nested include are refused before a stack exists, with the sentence a real account answers where one is known. `UsePreviousTemplate` and a change set without a body reuse the stored processed template, so a snippet edited in S3 since the deploy is not picked up, as on AWS. Contributed by @iot-rocket.-- **Amazon Location — trackers and device positions, with `AWS::Location::Tracker`** — the service did not exist. `CreateTracker`, `DescribeTracker`, `UpdateTracker`, `ListTrackers` and `DeleteTracker` manage trackers; `BatchUpdateDevicePosition`, `GetDevicePosition`, `BatchGetDevicePosition` and `GetDevicePositionHistory` serve device positions, with the modeled wire shapes (`geo` signing scope, ISO 8601 timestamps, `Position` as the `[lon, lat]` pair, per-entry `Errors` for out-of-range coordinates, `NextToken` paging, the last 24 hours as the history default). `PositionFiltering` applies: `TimeBased` (the default) stores one sample per 30 seconds per device, `DistanceBased` ignores a move under 30 m and `AccuracyBased` a move under the two updates' measured accuracy, and a filtered update is not an error. The documented request constraints are checked before the tracker is looked up, so an invalid request naming a tracker that does not exist answers the `ValidationException`, not the 404, and `TrackerName` is held to its 1..100 length and to the ASCII the service-side Java `[-._\w]+` means, in the URL as well as in a body; `Accuracy` is the modeled `PositionalAccuracy`, whose required `Horizontal` runs 0..10000000 metres and can no longer arrive negative under the `AccuracyBased` filter it feeds; every `DeviceId` is the modeled `Id`, in an update, in a `DeviceIds` list and in the URL alike; a `GetDevicePositionHistory` window bound that is not a timestamp is refused instead of falling back to the 24-hour default. Positions are kept in memory, the newest 100 per device, rather than for the service's 30 days; `KmsKeyId`, `EventBridgeEnabled` and `Tags` are stored without effect; no consumers, geofences, maps, places or routes. The CloudFormation resource `Ref`s the name, exposes `Arn`/`TrackerArn`/`CreateTime`/`UpdateTime`, updates in place and receives the stack tags. Contributed by @iot-rocket.-- **AWS Signer — synchronous `StartSigningJob` with the S3 side effect** — the `signer` API did not exist. `StartSigningJob`, `DescribeSigningJob`, `ListSigningJobs`, `PutSigningProfile` and `GetSigningProfile` are served natively (REST-JSON). Signing is synchronous and synthetic: Start validates the source object against the local S3 store, writes a JSON marker (source reference + SHA-256 of the source bytes) to `destination.prefix + jobId` (`.zip` appended for a `.zip` source on the Lambda platform, as measured) and returns the job already `Succeeded`; a missing source, destination bucket or profile is `ResourceNotFoundException` at Start with no job recorded. `clientRequestToken` replays the first response. Jobs carry the profile's signing material and a `signatureExpiresAt`; list filters and the documented input constraints are enforced, and `ListSigningJobs` pages with a `nextToken` that is bound to the filters it was minted with. The unsigned path rules leave path-style S3 traffic for a bucket named `signing-jobs` alone unless the request looks like signer's own surface, and a job records the IAM principal that started it rather than the account root. `signatureValidityPeriod` follows the model, where both members are optional, and the documented constraints on `overrides`, `signingMaterial`, `tags`, `jobInvoker` and `profileOwner` are enforced instead of stored as sent. State persists with `PERSIST_STATE=1`. Contributed by @iot-rocket.-- **IoT Wireless — `GetPositionEstimate`** — the service was absent. `POST /position-estimate` now answers the way the API is shaped: the output structure declares a `payload` blob, so the HTTP body is the raw GeoJSON `Point` and boto3 hands the caller a `StreamingBody`, not a JSON envelope. The estimate is synthetic and deterministic (the canonical `Ip.IpAddress` hashes onto lon [-180, 180) / lat [-60, 60)); `properties` carry the two accuracy fields plus `timestamp`, which is always there: AWS documents the request's `Timestamp` as the time the position is resolved and the receive time as its substitute when the caller sends none, so a request that carries a `Timestamp` answers byte-identical bytes. `WiFiAccessPoints`, `CellTowers` and `Gnss` are accepted and ignored, while `AdvancedConfiguration.WiFiCellular.ConfidencePercent` drives the reported `horizontalConfidenceLevel` over 100, within the 50 to 99 the model allows. Refusals carry the live service's wording: no measurement, an unparseable address, a `Timestamp` that is not a Unix timestamp or a `ConfidencePercent` out of range is `ValidationException`; an address that is not globally routable, or is multicast, is `ResourceNotFoundException` `Cannot find position for the IP address <ip>`, as is a well-formed request whose only measurements are WLAN/cell/GNSS, which AWS documents that class for. Stateless. Contributed by @iot-rocket.+- **Amazon Location — trackers and device positions** — the service did not exist, so a client bound to it failed at the first call and a template with `AWS::Location::Tracker` did not deploy. `CreateTracker`, `DescribeTracker`, `UpdateTracker`, `ListTrackers` and `DeleteTracker` manage trackers, `BatchUpdateDevicePosition`, `GetDevicePosition`, `BatchGetDevicePosition` and `GetDevicePositionHistory` serve positions, and `PositionFiltering` applies (`TimeBased` stores one sample per 30 seconds per device, `DistanceBased` ignores a move under 30 m). Positions are held in memory, newest 100 per device, rather than for the service's 30 days. Contributed by @iot-rocket.+- **AWS Signer — `StartSigningJob` with its S3 side effect** — the `signer` API did not exist. `StartSigningJob`, `DescribeSigningJob`, `ListSigningJobs`, `PutSigningProfile` and `GetSigningProfile` are served natively; signing is synchronous and synthetic, so the marker object lands at `prefix + jobId` before the call returns and a caller whose contract is the signed object never polls. A missing source object, destination bucket or profile is `ResourceNotFoundException` with no job recorded. Contributed by @iot-rocket.+- **IoT Wireless — `GetPositionEstimate`** — the service was absent, so a client bound to it failed at the first call. `POST /position-estimate` now answers the way the API is shaped: the output structure declares a `payload` blob, so the body is the raw GeoJSON `Point` rather than a JSON envelope. The estimate resolves from `Ip` and is deterministic; `WiFiAccessPoints`, `CellTowers` and `Gnss` are accepted and not resolved. Contributed by @iot-rocket.+- **Amazon Translate — batch text translation jobs** — the service did not exist. `StartTextTranslationJob`, `DescribeTextTranslationJob`, `ListTextTranslationJobs` and `StopTextTranslationJob` run a job against the local S3 store, with the documented filters and paging. Contributed by @ppettitau.+- **Lambda Core — network connectors** — Terraform's `aws_lambdacore_network_connector` failed with `Function not found: /2026-04-04/network-connectors`: the service signs with Lambda's own credential scope, so the request reached the function router and the path was read as a function name. `CreateNetworkConnector`, `GetNetworkConnector`, `UpdateNetworkConnector`, `DeleteNetworkConnector` and `ListNetworkConnectors` now serve that path, with `ClientToken` idempotency and `Marker`/`MaxItems` paging. There is no VPC attachment behind a connector; it reaches `ACTIVE` on the next read. Reported by @edersonbrilhante.+- **CloudFormation — the `Rules` section is evaluated** — a template's rules were ignored; they now run after the parameters resolve and before any resource is touched, on `CreateStack`, `UpdateStack` and `CreateChangeSet`. A false `Assert` refuses the operation with its `AssertDescription` as a `ValidationError`, so the CDK's `CheckBootstrapVersion` rule refuses an outdated bootstrap instead of passing silently. Contributed by @iot-rocket.+- **CloudFormation — the `AWS::Include` transform** — an embedded `Fn::Transform` naming `AWS::Include` was carried into the stack as a literal key; it is now replaced by the contents of the S3 object its `Location` points to before the template is validated, and a location that is not an `s3://` URI, a missing object or a nested include is refused before a stack exists. Contributed by @iot-rocket.-### Fixed-- **EC2 — `AvailabilityZoneId` is populated on subnets** — `DescribeSubnets` and `CreateSubnet` always returned `null` for `AvailabilityZoneId`, even though `DescribeAvailabilityZones` reports the correct `ZoneId` mapping for the same account/region. Real AWS always populates this field, and consumers that fall back to computing it themselves when it's missing (e.g. the AWS Load Balancer Controller's subnet resolution) can crash on the fallback path. `CreateSubnet` now derives the id from the given (or default) `AvailabilityZone`; an `AvailabilityZoneId` supplied alongside it is preserved as given. The default-VPC and CloudFormation (`AWS::EC2::Subnet`) subnet-creation paths derive it the same way, and `DescribeSubnets` now always returns a non-null value. Subnets restored from state saved before this fix are backfilled on load. Contributed by @Alexis-DevOps.-- **EC2 — `DescribeAvailabilityZones` reports `ZoneType`** — the field was omitted entirely, so a consumer that branches on it (the AWS Load Balancer Controller's subnet locale resolution) read it as empty and refused to classify the subnet ("unknown zone type"), blocking Service/Ingress reconciliation. Every zone ministack fabricates is a standard Availability Zone, so `DescribeAvailabilityZones` now always reports `"availability-zone"`. Contributed by @Alexis-DevOps.-- **CloudFormation — the template and stack quotas are enforced** — a template of any size, with any number of resources, parameters, outputs or mappings, and a stack name of any shape were accepted, so a template that a real account refuses deployed. `CreateStack`, `UpdateStack`, `CreateChangeSet`, `ValidateTemplate` and `GetTemplateSummary` now refuse a `TemplateBody` over 51,200 bytes and a template behind `TemplateURL` over 1,000,000 bytes; the engine refuses more than 500 resources, 200 parameters, 200 outputs, 200 mappings or 200 attributes in a mapping, a name over 255 characters, a description over 1,024 bytes and a parameter default or value over 4,096 bytes; `CreateStack` and a `CREATE` change set refuse a stack name that is not alphanumeric-and-hyphens starting with a letter or longer than 128 characters, joined with an oversized body into the one message the API's parameter validation gives. All of it before a stack record exists, with the messages of the API's parameter validation and the template format errors. `ValidateTemplate` also takes `TemplateURL` now. Contributed by @iot-rocket.-### Fixed-- **CloudFormation — `Capabilities` are enforced under `AUTH=true`** — `CreateStack`, `UpdateStack` and `CreateChangeSet` accepted a template with IAM resources or a `Transform` whatever the request acknowledged, so a deploy that CloudFormation refuses with `InsufficientCapabilitiesException` went through. With `AUTH=true` they now answer that error (HTTP 400, `Requires capabilities : [CAPABILITY_IAM]`, measured) and create nothing: an IAM resource needs `CAPABILITY_IAM` or `CAPABILITY_NAMED_IAM`, one with a custom name `CAPABILITY_NAMED_IAM`, a template with a `Transform` `CAPABILITY_AUTO_EXPAND` on `CreateStack` and `UpdateStack` (not on a change set, as the API documents). Without `AUTH` nothing changes; `GetTemplateSummary` keeps reporting the same set. Contributed by @iot-rocket.+### Changed+- **API Gateway — a REST method's `COGNITO_USER_POOLS` authorizer is enforced** — the v1 data plane matched only `NONE`, `AWS_IAM` and `CUSTOM` and passed everything else through, so a method fronted by a user-pool authorizer served every caller and `requestContext.authorizer.claims` was never populated, leaving a handler that branches on claims to take its no-claims path locally while AWS denied the request. The token named by the authorizer's `identitySource` is now verified against the pools in `providerARNs` and its claims reach the backend; a method carrying `authorizationScopes` requires one of them and answers `403` otherwise. `PutMethod` also stops discarding `authorizationScopes`. Contributed by @ppettitau.+- **CloudFormation — the template and stack quotas are enforced** — a template of any size, with any number of resources, parameters, outputs or mappings, and a stack name of any shape were accepted, so a template a real account refuses deployed. The body, resource, parameter, output and mapping limits and the stack-name pattern are now checked before a stack record exists, with the messages the API's parameter validation gives; `ValidateTemplate` also takes `TemplateURL`. Contributed by @iot-rocket.+- **CloudFormation — `Capabilities` are enforced under `AUTH=true`** — `CreateStack`, `UpdateStack` and `CreateChangeSet` accepted a template with IAM resources or a `Transform` whatever the request acknowledged, so a deploy CloudFormation refuses went through. With `AUTH=true` they now answer `InsufficientCapabilitiesException` and create nothing. Without `AUTH` nothing changes. Contributed by @iot-rocket.-## [Unreleased]+### Fixed+- **EC2 — `AvailabilityZoneId` is populated on subnets** — `DescribeSubnets` and `CreateSubnet` always returned `null`, even though `DescribeAvailabilityZones` reported the correct mapping, and a consumer that recomputes the id when it is missing (the AWS Load Balancer Controller) can crash on that fallback. The id is now derived from the zone on every creation path, subnets restored from older state are backfilled, and the two members always name the same zone. Contributed by @Alexis-DevOps.+- **EC2 — `DescribeAvailabilityZones` reports `ZoneType`** — the field was omitted entirely, so a consumer that branches on it read it as empty and refused to classify the subnet, blocking Service and Ingress reconciliation. Every zone now reports `availability-zone`. Contributed by @Alexis-DevOps.+- **EC2 — `CreateFleet` applies a launch template's instance tags** — instances created by a fleet came back with an empty `Tags` list even though the referenced launch template carried `TagSpecifications`, which is the mechanism AWS documents for tagging fleet instances. The template's `instance` tags now reach the instances, with a request-level tag winning on a duplicate key. Reported by @edersonbrilhante.+- **Step Functions — numeric `*Path` Choice comparisons** — `NumericLessThanPath`, `NumericGreaterThanPath`, `NumericLessThanEqualsPath` and `NumericGreaterThanEqualsPath` silently evaluated false, so a batch loop guarded by one never exited and eventually failed in `States.ArrayGetItem`. The four operators now resolve the right operand from the input and compare it. Contributed by @jayjanssen.+- **SES — `SendBulkEmail` is routed** — `POST /v2/email/outbound-bulk-emails` reached no handler, so the call failed instead of sending. It now routes to the v2 handler. Contributed by @jgrumboe.+- **Glue — the Data Catalog operations** — the catalog operations were missing, so a client that creates or reads a catalog before its databases could not proceed. Catalog create, read and update are served.-### Added-- **Amazon Translate (`translate`)** — new service emulator for batch text translation jobs: `StartTextTranslationJob`, `DescribeTextTranslationJob`, `ListTextTranslationJobs`, `StopTextTranslationJob`, verified against botocore `translate-2017-07-01`. Jobs walk `SUBMITTED` → `IN_PROGRESS` → `COMPLETED` (paced by `TRANSLATE_JOB_RUN_SECONDS`), read every document under `InputDataConfig.S3Uri` from MiniStack S3, and write output to the location the real service uses — `OutputDataConfig.S3Uri` is reported as `s3://<bucket>/<prefix><account-id>-TranslateText-<JobId>/` — as `<target-code>.<input name>`, with a `details/<code>.auxiliary-translation-details.json` summary per target language. `text/plain`, `text/html` and `application/x-xliff+xml` are rewritten in place (an XLIFF job gets a populated `<target>` in every `<trans-unit>` and `target-language` on every `<file>`) and the Office ZIP types are copied through; an unreadable document ends the job `COMPLETED_WITH_ERROR`, and an empty or unreachable input location fails it with a `Message`. `ClientToken` is idempotent, `StopTextTranslationJob` reaches a running worker, and terminal states publish a `Translate TextTranslationJob State Change` event on the default bus. A Node.js Lambda that leaves `@aws-sdk/client-translate` unbundled reaches the service through the local executor's stub. The translated text is deterministic canned output — there is no machine translation. The synchronous `TranslateText` / `TranslateDocument` pair, custom terminologies, parallel data, `ListLanguages` and tagging are not implemented. Contributed by @ppettitau.+### Internal+- **CI — install with uv and collect test shards in one pass** — the shard planner ran `pytest --collect-only` once per marker filter for counts a single pass already has, and superseded pull-request runs competed for runners. Installs go through uv, one collection pass yields both counts, and a concurrency group cancels superseded runs (never on `main`). No user-visible behavior changes. Contributed by @jgrumboe.+- **Lint — `F401` is enforced** — unused imports were ignored repo-wide pending a manual review; the review is done, the rule is on, and the four dead imports it found are gone. No user-visible behavior changes.+- **Testcontainers — `containerd` bumped to 1.7.35** in the Go example module, picking up CVE-2026-53495. No user-visible behavior changes.## [1.5.9] — 2026-09-08diff --git a/pyproject.toml b/pyproject.tomlindex d57fec11..cc778e41 100644--- a/pyproject.toml+++ b/pyproject.toml@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"[project]name = "ministack"-version = "1.5.9"+version = "1.5.10"description = "Free, open-source local AWS emulator — drop-in LocalStack replacement"readme = "README.md"license = { file = "LICENSE" }