vendure 7.6.1
vendure: ^7.6.1 copied to clipboard
Typed Dart and Flutter SDK for Vendure GraphQL APIs - channel-aware catalog, cart, checkout, payment, and admin domain clients.
7.6.1 - 2026-11-20 #
7.6.1: pub.dev score improvements across the fleet — added a pana-recognized example/README.md to 12 packages (zuraffa_observability, session, storage, graphql, minio, tui, ffi, vendure, flutter, inappwebview, ocr, purchase); cleared all analyzer infos in zuraffa and zuraffa_flutter (deprecated flutter/material.dart -> material_ui, withOpacity -> withValues) for 50/50 static analysis.
7.6.0 - 2026-11-19 #
Fleet release 7.6.0: zuraffa_observability moves its OTel base to dartastic_opentelemetry with a sealed test-capture seam + facade re-exports (issue #4); zuraffa_vendure + zuraffa_graphql adopt graphql_plus ^5.3.0; fleet-wide zorphy/zorphy_annotation raised to ^2.5.1 with all entities regenerated from scratch.
7.5.0 - 2026-11-15 #
Release 7.5.0: Signal-backed view-state migration template with SignalScope ownership (#2076); signal listener/subscription cleanup on eager-delivery throw (#2081, #2083); UseCase/StreamUseCase catch-all SEVERE logs now carry the cause (#2077, #2079); dependencies upgraded and pinned to latest resolvable.
7.4.2 - 2026-11-13 #
- Mono-version fleet alignment to 7.4.2; internal dependencies refreshed; xml override 7.1.0.
7.4.1 - 2026-11-11 #
Fleet release 7.4.1: core adds zfa tunnel (Cloudflare-hosted MCP servers), MCP streamable-HTTP transport with usecase tools, blocking lifecycle hooks (#2032), typed tool param coercion (#2061); whole fleet mono-aligned to 7.4.1.
Unreleased #
Two transport regressions from the 7.x reimplementation, both reported live
on zik_zak (websocket churn + unhandled Bad state: Future already completed):
- Subscriptions speak
graphql-transport-wsagain. The reimplementation dropped the source SDK'ssubProtocol: GraphQLProtocol.graphqlTransportWson the subscriptionWebSocketLink, silently falling back to the legacygraphqlWsprotocol. Vendure servers close the socket right afterconnection_init, and withautoReconnectthat becomes the endlessConnected to websocket → Initialising connection → Disconnected from websocketloop (reconnect every 5s, forever). Restored from vendure-flutter-sdk 3.0.1_getSubscriptionClient. - The
timeoutparameter is wired into the client.VendureContext.timeoutwas dead code: the mainGraphQLClientwas built withoutqueryRequestTimeout, sographql's silent 5s default applied — exactly what consumers like zik_zak disable on purpose (zik_zak issue 265: the budget is enforced per call instead). The default'sStream.timeoutfires a syntheticTimeoutExceptionwhile the late real response still completes the query manager's unguardedonDatacompleter a second time — the unhandledBad state: Future already completedcrash throughHttpLink.request+ the AuthLink chain.queryRequestTimeout: context.timeoutrestores the source SDK'squeryRequestTimeoutcontract (timeout: null= no transport-level timeout). - Regression suite: T1–T4 in
test/graphql_datasource_suite_test.dartpin the client request timeout (context-carried, null = disabled) and the subscription wire configuration (protocol, endpoint scheme/languageCode swap). - The
timeoutwiring no longer arms graphql'sStream.timeout. Passingcontext.timeoutintoGraphQLClient.queryRequestTimeout(the 7.3.8 regression, issue #8) armed aStream.timeouton every Shop API call: when the stream went quiet past the budget, the request failed as a syntheticTimeoutException(No stream event) and the late real response then double-completed the query manager's unguarded completer — the unhandledBad state: Future already completedcrash in the root zone (graphql 5.2.4,query_manager.dart). The client now pinsqueryRequestTimeout: null(explicit — omitting restores the silent 5 s default), and the datasource enforcesVendureContext.timeoutin_executeRaw/mutateWithHeadersvia cancellableFuture.timeout, translating expiry toVendureDataSourceException. Regression suite: T1 re-pinned, T5–T7 intest/graphql_datasource_suite_test.dart(a quiet stream surfaces a clean exception with zero unhandled async errors; the late response lands silently). - Transport moved to the hardened
graphql_plusfork. The unhandledBad state: Future already completedhad a root cause in the dependency, not only in vendure's wiring: stockgraphql5.2.4'sQueryManagerpassescompleter.completestraight toStream.listen, so onceStream.timeouthas settled the completer the late response completes it again from inside the stream callback — wherefetchQuery's try/catch cannot reach it. The dependency is nowgraphql_plus: ^5.2.5(arrrrny's fork of 5.2.4), which guardsonData/onErrorwithisCompleted, cancels the subscription once the completer settles, and surfaces an empty response stream asStateError('No element')instead of hanging. The fork renamed the library file, sopackage:vendure/graphql.dartis the stable import for the transport types on vendure's public surface. Regression: T8 intest/graphql_datasource_suite_test.dart(red on 5.2.4, green on the fork). - BREAKING (transport imports): a consumer that imported
package:graphql/client.dartto name a client type (to build an injectedGraphQLClient, say) must importpackage:vendure/graphql.dartinstead — re-exported bypackage:vendure/vendure.dart, so the package's documented entrypoint is enough.graphqlis no longer a dependency of vendure, and a same-named class from a consumer's owngraphqlresolution is a different type from the one vendure's transport actually speaks. - Barrel reachability is now pinned:
test/barrel_transport_surface_test.dartimports onlypackage:vendure/vendure.dartand namesGraphQLClient, so droppingexport 'graphql.dart';from the barrel fails the suite at compile time instead of only in a consumer's build (arrrrny/zuraffa_vendure#15). - BREAKING (datasource port):
CustomOperations'expectedDataTypeno longer defaults to'data'. That default was a guaranteed-throw: the GraphQL client unwraps the top-leveldataenvelope before the SDK sees aQueryResult, so_handleErrorslooked for adatakey INSIDE the operation's own field map, found none, and threwNo data returned for expected type: data— on responses the backend had accepted (arrrrny/zuraffa_vendure#17; live as zik_zak#877 and zik_zak#897, where four listing posts false-failed since 2026-11-09). The default is nownull: the adapter returns the document's single root field (__typenameexcluded —gql()injects it into every selection set), or the whole envelope for a multi-field document. A root field the server answered withnull(a guest session'sactiveOrder) is that answer, not a failure; only an absent name still throws, and it reports the keys the response DID return (… (envelope keys: [postListing])) instead of a bare name.queryListPaginated/mutateListPaginatednow fail loudly when a multi-field envelope reaches them with neitheritemsnortotalItems, where they used to report a real page asitems: [], totalItems: 0. Widening the port is a source break for anyone who implementsVendureDataSourceoutside this package:query,mutate,queryList,mutateWithHeadersandsubscribetakerequired String? expectedDataType(aString-typed override no longer compiles —invalid_override),VendureRequestRecord.expectedDataTypeis nullable, andInMemoryVendureDataSource.scriptisMap<String?, dynamic>. Those implementers must widen their parameter types. The widened public port takes a MINOR bump: 7.5.0 is released, so this lands as 7.6.0. Regression: D1–D10 intest/custom_operations_default_expected_data_type_suite_test.dart.
7.3.6 - 2026-11-02 #
- Fix:
CustomOperations.queryListPaginated/mutateListPaginatedrestore the source SDK's envelope normalization —__typename→runtimeTypebeforefromJson(with the caller'sconvertEnumshonored on output, which was previously dead on this path).gql()injects__typenameinto every selection set and the raw escape hatch returns the payload as-is, so polymorphic entity decoders (zorphyexplicitSubTypesfromJson — e.g. zik_zak'sListing.fromJson) threwUnsupportedError: The __typename 'ChannelListing' is not supported…on every paginated row. Regression suite:test/custom_operations_paginated_suite_test.dart(zuraffa_vendure#2, PR#3). - Mono-version fleet alignment to 7.3.6; internal dependencies refreshed; xml override 7.1.0.
7.3.5 #
- Fix:
Vendure._finalizeInitializationconnection-check query now passesfromJson: nullso the scalar__typenamestring return doesn't fail theMap<String, dynamic>expectation.
7.3.4 #
- Fix:
CurrentUserChannel.codeis now nullable. Real Vendure backendauthenticate/firebaseAuthmutations selectchannels { id token permissions }withoutcode, which previously causedCheckedFromJsonExceptionduring JSON decoding.
7.3.3 #
Hotfix (consumer-reported via the fleet verification round — zik_zak's vendure-client init scenarios):
mutateWithHeaderstolerates an absent body — the auth seam's contract is headers-only (the session token rides thevendure-auth-tokenresponse header). A mutation whoseexpectedDataTypekey is absent in the response (e.g. a firebase token-exchange server answering with only__typename) now resolves to null data instead of throwingNo data returned for expected type: authenticate, matching vendure-flutter-sdk 3.0.1'sAuthBaseOperations.extractResponseHeaders.VendureResponse.dataisT?.- Regression locks A2 (in-memory, headers-only firebase exchange) and
G10 (graphql adapter,
__typename-only response).
7.3.2 #
The Zuraffa reimplementation of the Vendure Flutter SDK, shipped as the
same vendure package name.
- Facade (
Vendure): five init variants +forTesting, the runtime setters (auth token, languageCode, channelToken, apiKey),refreshToken,destroy, GetIt registration (registerVendureDependencies/registerVendureTestDependencies), and the connection-check ping. - Six operation groups on the facade:
order,auth,customer,catalog,system,custom(raw query/mutate/queryList/mutateList, paginated variants, response-header extraction). - Datasources: the
VendureDataSourceport (one error path —VendureDataSourceException),GraphQLVendureDataSource(link chain: HttpLink → apiKey → vendure-token → App Check → Bearer; noCache policies;__typename→runtimeTypenormalization; transient-network retry; WebSocket subscriptions with the Vendure initialPayload), and the pure-DartInMemoryVendureDataSource(scripted payloads, request recording, response-header scripting). - Entities: the schema's 179 entities as zorphy types (11 enums +
SearchResultPriceincluded), and the 18 mutation unions as hand-written sealed classes dispatching on the wireruntimeTypekey. - Auth:
DataAuthRepositorywith theAuthErrorClassifiercredential vocabulary; the session token is captured from thevendure-auth-tokenresponse header viamutateWithHeaders. - Token lifecycle:
TokenManager+TokenLocalDataSourceseam with the fetch-refresh closure wired by the facade.
Port fidelity notes (from vendure-flutter-sdk 3.0.1) #
queryListrequires the extracted payload to be a bare list; scalar lists (e.g.nextOrderStates) decode without afromJson.custom.query/mutateaccept an optionalfromJson; omitted, the extracted payload returns raw (scalar/Map/List).- Response normalization (
__typename→runtimeType, enum conversion off) runs before the typed decode on both adapters, so the sealed unions dispatch exactly like the old SDK's remote path. - The old SDK's
CustomOperationsbuilt a second datasource; this port wires the facade's single datasource through, so custom operations share the context, the error path, and the retry policy.
Tests #
24 behavioral tests, pure Dart, no network: the port contract and one error path (D1–D6), the GraphQL adapter's envelope/dot-path/ErrorResult handling, context assembly, and the union wire-dispatch normalization (G1–G9), and the facade lifecycle plus per-group request-shape fidelity (F1–F4, O1–O3, A1, C1) through the scripted in-memory datasource.