Fetch signal (AbortController) doesn't work with Shopify Resource Fetching

Topic summary

A developer is encountering an issue where AbortController signals are not functioning when used with Shopify’s Resource Fetching API.

Problem Details:

  • The user passes an AbortController signal to the fetch request targeting Shopify’s Admin GraphQL API
  • Calling abort() on the signal has no effect—the request is not canceled as expected
  • The implementation follows standard fetch API patterns with signal parameter

Current Status:

  • The issue remains unresolved with no responses or solutions provided
  • The developer is seeking assistance to identify why the abort mechanism fails with Shopify’s fetch wrapper
  • Code snippet shows a GraphQL POST request structure with signal parameter included

Key Question:
Whether Shopify’s Resource Fetching implementation supports standard AbortController functionality or requires alternative cancellation approaches.

Summarized with AI on November 8. AI used: claude-sonnet-4-5-20250929.

I’m trying to use the Shopify Resource Fetching https://shopify.dev/docs/api/app-bridge-library/apis/resource-fetching#example-fetch-directly-from-the-admin-api with the AbortController, but it doesn’t work. I pass the signal to the fetch and abort the signal, but nothing. Could you take a look at it?

const SHOPIFY_ADMIN_GRAPHQL_API = "shopify:admin/api/graphql.json";

export default async ({ query, signal = null /*, variables = {}*/ }) => {
  try {
    const response = await fetch(SHOPIFY_ADMIN_GRAPHQL_API, {
      method: "POST",
      signal,
      body: JSON.stringify({
        query,
      }),
    });

    if (!response.ok) throw new Error(response.statusText);

    return await response.json();
  } catch (error) {
    throw new Error(error);
  }