Skip to content

Commit

Permalink
Merge branch 'release-3.11' into jerel/deprecate-schema-test-utilities
Browse files Browse the repository at this point in the history
  • Loading branch information
jerelmiller authored Jul 9, 2024
2 parents 3542d08 + 3812800 commit 3fa3eb6
Show file tree
Hide file tree
Showing 70 changed files with 2,713 additions and 1,422 deletions.
54 changes: 35 additions & 19 deletions .api-reports/api-report-core.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@ import { disableExperimentalFragmentVariables } from 'graphql-tag';
import { disableFragmentWarnings } from 'graphql-tag';
import type { DocumentNode } from 'graphql';
import { enableExperimentalFragmentVariables } from 'graphql-tag';
import type { ExecutionResult } from 'graphql';
import type { FieldNode } from 'graphql';
import type { FormattedExecutionResult } from 'graphql';
import type { FragmentDefinitionNode } from 'graphql';
import { gql } from 'graphql-tag';
import type { GraphQLError } from 'graphql';
import type { GraphQLErrorExtensions } from 'graphql';
import type { GraphQLFormattedError } from 'graphql';
import type { InlineFragmentNode } from 'graphql';
import { InvariantError } from 'ts-invariant';
import { Observable } from 'zen-observable-ts';
Expand Down Expand Up @@ -94,7 +94,7 @@ export class ApolloClient<TCacheShape> implements DataProxy {
__actionHookForDevTools(cb: () => any): void;
constructor(options: ApolloClientOptions<TCacheShape>);
// (undocumented)
__requestRaw(payload: GraphQLRequest): Observable<ExecutionResult>;
__requestRaw(payload: GraphQLRequest): Observable<FormattedExecutionResult>;
addResolvers(resolvers: Resolvers | Resolvers[]): void;
// (undocumented)
cache: ApolloCache<TCacheShape>;
Expand All @@ -103,6 +103,10 @@ export class ApolloClient<TCacheShape> implements DataProxy {
get defaultContext(): Partial<DefaultContext>;
// (undocumented)
defaultOptions: DefaultOptions;
// Warning: (ae-forgotten-export) The symbol "DevtoolsOptions" needs to be exported by the entry point index.d.ts
//
// (undocumented)
readonly devtoolsConfig: DevtoolsOptions;
// (undocumented)
disableNetworkFetches: boolean;
get documentTransform(): DocumentTransform;
Expand Down Expand Up @@ -144,12 +148,14 @@ export class ApolloClient<TCacheShape> implements DataProxy {
export interface ApolloClientOptions<TCacheShape> {
assumeImmutableResults?: boolean;
cache: ApolloCache<TCacheShape>;
// @deprecated
connectToDevTools?: boolean;
// (undocumented)
credentials?: string;
// (undocumented)
defaultContext?: Partial<DefaultContext>;
defaultOptions?: DefaultOptions;
devtools?: DevtoolsOptions;
// (undocumented)
documentTransform?: DocumentTransform;
// (undocumented)
Expand All @@ -172,14 +178,16 @@ export interface ApolloClientOptions<TCacheShape> {
export class ApolloError extends Error {
// Warning: (ae-forgotten-export) The symbol "ApolloErrorOptions" needs to be exported by the entry point index.d.ts
constructor({ graphQLErrors, protocolErrors, clientErrors, networkError, errorMessage, extraInfo, }: ApolloErrorOptions);
cause: ({
readonly message: string;
extensions?: GraphQLErrorExtensions[] | GraphQLFormattedError["extensions"];
} & Omit<Partial<Error> & Partial<GraphQLFormattedError>, "extensions">) | null;
// (undocumented)
clientErrors: ReadonlyArray<Error>;
// (undocumented)
extraInfo: any;
// Warning: (ae-forgotten-export) The symbol "GraphQLErrors" needs to be exported by the entry point index.d.ts
//
// (undocumented)
graphQLErrors: GraphQLErrors;
graphQLErrors: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
message: string;
// (undocumented)
Expand All @@ -202,7 +210,7 @@ interface ApolloErrorOptions {
// (undocumented)
extraInfo?: any;
// (undocumented)
graphQLErrors?: ReadonlyArray<GraphQLError>;
graphQLErrors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
networkError?: Error | ServerParseError | ServerError | null;
// (undocumented)
Expand Down Expand Up @@ -256,7 +264,7 @@ export interface ApolloQueryResult<T> {
// (undocumented)
data: T;
error?: ApolloError;
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
loading: boolean;
// (undocumented)
Expand Down Expand Up @@ -589,6 +597,12 @@ interface DeleteModifier {
// @public (undocumented)
const _deleteModifier: unique symbol;

// @public (undocumented)
interface DevtoolsOptions {
enabled?: boolean;
name?: string;
}

// @public (undocumented)
export type DiffQueryAgainstStoreOptions = ReadQueryOptions & {
returnPartialData?: boolean;
Expand Down Expand Up @@ -760,7 +774,7 @@ export interface ExecutionPatchInitialResult<TData = Record<string, any>, TExten
// (undocumented)
data: TData | null | undefined;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -977,9 +991,6 @@ const getInMemoryCacheMemoryInternals: (() => {

export { gql }

// @public (undocumented)
type GraphQLErrors = ReadonlyArray<GraphQLError>;

// @public (undocumented)
export interface GraphQLRequest<TVariables = Record<string, any>> {
// (undocumented)
Expand Down Expand Up @@ -1064,7 +1075,7 @@ export interface IncrementalPayload<TData, TExtensions> {
// (undocumented)
data: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -1696,7 +1707,7 @@ class QueryInfo {
// (undocumented)
getDiff(): Cache_2.DiffResult<any>;
// (undocumented)
graphQLErrors?: ReadonlyArray<GraphQLError>;
graphQLErrors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
init(query: {
document: DocumentNode;
Expand Down Expand Up @@ -1855,7 +1866,7 @@ class QueryManager<TStore> {
// (undocumented)
readonly ssrMode: boolean;
// (undocumented)
startGraphQLSubscription<T = any>({ query, fetchPolicy, errorPolicy, variables, context, }: SubscriptionOptions): Observable<FetchResult<T>>;
startGraphQLSubscription<T = any>({ query, fetchPolicy, errorPolicy, variables, context, extensions, }: SubscriptionOptions): Observable<FetchResult<T>>;
stop(): void;
// (undocumented)
stopQuery(queryId: string): void;
Expand Down Expand Up @@ -2073,11 +2084,15 @@ interface SharedWatchQueryOptions<TVariables extends OperationVariables, TData>
}

// @public (undocumented)
export interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> extends ExecutionResult<TData, TExtensions> {
export interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> {
// (undocumented)
context?: TContext;
// (undocumented)
data?: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
}

// @public (undocumented)
Expand Down Expand Up @@ -2127,6 +2142,7 @@ export type SubscribeToMoreOptions<TData = any, TSubscriptionVariables = Operati
export interface SubscriptionOptions<TVariables = OperationVariables, TData = any> {
context?: DefaultContext;
errorPolicy?: ErrorPolicy;
extensions?: Record<string, any>;
fetchPolicy?: FetchPolicy;
query: DocumentNode | TypedDocumentNode<TData, TVariables>;
variables?: TVariables;
Expand Down Expand Up @@ -2287,9 +2303,9 @@ interface WriteContext extends ReadMergeModifyContext {
// src/core/ObservableQuery.ts:117:5 - (ae-forgotten-export) The symbol "QueryInfo" needs to be exported by the entry point index.d.ts
// src/core/QueryManager.ts:124:5 - (ae-forgotten-export) The symbol "MutationStoreValue" needs to be exported by the entry point index.d.ts
// src/core/QueryManager.ts:158:5 - (ae-forgotten-export) The symbol "LocalState" needs to be exported by the entry point index.d.ts
// src/core/QueryManager.ts:390:7 - (ae-forgotten-export) The symbol "UpdateQueries" needs to be exported by the entry point index.d.ts
// src/core/watchQueryOptions.ts:269:2 - (ae-forgotten-export) The symbol "IgnoreModifier" needs to be exported by the entry point index.d.ts
// src/core/watchQueryOptions.ts:269:2 - (ae-forgotten-export) The symbol "UpdateQueryFn" needs to be exported by the entry point index.d.ts
// src/core/QueryManager.ts:391:7 - (ae-forgotten-export) The symbol "UpdateQueries" needs to be exported by the entry point index.d.ts
// src/core/watchQueryOptions.ts:272:2 - (ae-forgotten-export) The symbol "IgnoreModifier" needs to be exported by the entry point index.d.ts
// src/core/watchQueryOptions.ts:272:2 - (ae-forgotten-export) The symbol "UpdateQueryFn" needs to be exported by the entry point index.d.ts
// src/link/http/selectHttpOptionsAndBody.ts:128:32 - (ae-forgotten-export) The symbol "HttpQueryOptions" needs to be exported by the entry point index.d.ts

// (No @packageDocumentation comment for this package)
Expand Down
22 changes: 15 additions & 7 deletions .api-reports/api-report-errors.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,23 @@
```ts

import type { ExecutionResult } from 'graphql';
import type { GraphQLError } from 'graphql';
import type { GraphQLErrorExtensions } from 'graphql';
import type { GraphQLFormattedError } from 'graphql';

// @public (undocumented)
export class ApolloError extends Error {
constructor({ graphQLErrors, protocolErrors, clientErrors, networkError, errorMessage, extraInfo, }: ApolloErrorOptions);
cause: ({
readonly message: string;
extensions?: GraphQLErrorExtensions[] | GraphQLFormattedError["extensions"];
} & Omit<Partial<Error> & Partial<GraphQLFormattedError>, "extensions">) | null;
// (undocumented)
clientErrors: ReadonlyArray<Error>;
// (undocumented)
extraInfo: any;
// (undocumented)
graphQLErrors: GraphQLErrors;
graphQLErrors: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
message: string;
// (undocumented)
Expand All @@ -42,7 +46,7 @@ export interface ApolloErrorOptions {
// (undocumented)
extraInfo?: any;
// (undocumented)
graphQLErrors?: ReadonlyArray<GraphQLError>;
graphQLErrors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
networkError?: Error | ServerParseError | ServerError | null;
// (undocumented)
Expand Down Expand Up @@ -77,7 +81,7 @@ interface ExecutionPatchInitialResult<TData = Record<string, any>, TExtensions =
// (undocumented)
data: TData | null | undefined;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -109,7 +113,7 @@ type FetchResultWithSymbolExtensions<T> = FetchResult<T> & {
extensions: Record<string | symbol, any>;
};

// @public (undocumented)
// @public @deprecated (undocumented)
export type GraphQLErrors = ReadonlyArray<GraphQLError>;

// Warning: (ae-forgotten-export) The symbol "FetchResultWithSymbolExtensions" needs to be exported by the entry point index.d.ts
Expand All @@ -122,7 +126,7 @@ interface IncrementalPayload<TData, TExtensions> {
// (undocumented)
data: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -162,11 +166,15 @@ type ServerParseError = Error & {
// Warning: (ae-forgotten-export) The symbol "DefaultContext" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> extends ExecutionResult<TData, TExtensions> {
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> {
// (undocumented)
context?: TContext;
// (undocumented)
data?: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
}

// (No @packageDocumentation comment for this package)
Expand Down
13 changes: 8 additions & 5 deletions .api-reports/api-report-link_batch-http.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@

import type { ASTNode } from 'graphql';
import type { DocumentNode } from 'graphql';
import type { ExecutionResult } from 'graphql';
import type { GraphQLError } from 'graphql';
import type { GraphQLFormattedError } from 'graphql';
import { Observable } from 'zen-observable-ts';
import type { Observer } from 'zen-observable-ts';

Expand Down Expand Up @@ -117,7 +116,7 @@ interface ExecutionPatchInitialResult<TData = Record<string, any>, TExtensions =
// (undocumented)
data: TData | null | undefined;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -179,7 +178,7 @@ interface IncrementalPayload<TData, TExtensions> {
// (undocumented)
data: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -232,11 +231,15 @@ interface Printer {
type RequestHandler = (operation: Operation, forward: NextLink) => Observable<FetchResult> | null;

// @public (undocumented)
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> extends ExecutionResult<TData, TExtensions> {
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> {
// (undocumented)
context?: TContext;
// (undocumented)
data?: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
}

// @public (undocumented)
Expand Down
13 changes: 8 additions & 5 deletions .api-reports/api-report-link_batch.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
```ts

import type { DocumentNode } from 'graphql';
import type { ExecutionResult } from 'graphql';
import type { GraphQLError } from 'graphql';
import type { GraphQLFormattedError } from 'graphql';
import { Observable } from 'zen-observable-ts';
import type { Observer } from 'zen-observable-ts';

Expand Down Expand Up @@ -107,7 +106,7 @@ interface ExecutionPatchInitialResult<TData = Record<string, any>, TExtensions =
// (undocumented)
data: TData | null | undefined;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -153,7 +152,7 @@ interface IncrementalPayload<TData, TExtensions> {
// (undocumented)
data: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -208,11 +207,15 @@ type Path = ReadonlyArray<string | number>;
type RequestHandler = (operation: Operation, forward: NextLink) => Observable<FetchResult> | null;

// @public (undocumented)
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> extends ExecutionResult<TData, TExtensions> {
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> {
// (undocumented)
context?: TContext;
// (undocumented)
data?: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
}

// (No @packageDocumentation comment for this package)
Expand Down
13 changes: 8 additions & 5 deletions .api-reports/api-report-link_context.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
```ts

import type { DocumentNode } from 'graphql';
import type { ExecutionResult } from 'graphql';
import type { GraphQLError } from 'graphql';
import type { GraphQLFormattedError } from 'graphql';
import { Observable } from 'zen-observable-ts';
import type { Observer } from 'zen-observable-ts';

Expand Down Expand Up @@ -80,7 +79,7 @@ interface ExecutionPatchInitialResult<TData = Record<string, any>, TExtensions =
// (undocumented)
data: TData | null | undefined;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -124,7 +123,7 @@ interface IncrementalPayload<TData, TExtensions> {
// (undocumented)
data: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLError>;
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
Expand Down Expand Up @@ -169,11 +168,15 @@ type RequestHandler = (operation: Operation, forward: NextLink) => Observable<Fe
export function setContext(setter: ContextSetter): ApolloLink;

// @public (undocumented)
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> extends ExecutionResult<TData, TExtensions> {
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> {
// (undocumented)
context?: TContext;
// (undocumented)
data?: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
}

// (No @packageDocumentation comment for this package)
Expand Down
Loading

0 comments on commit 3fa3eb6

Please sign in to comment.