emberjs/ember.js · error · Error

You attempted to use @cached on with ${args.length > 1 ? 'ar

Error message

You attempted to use @cached on with ${args.length > 1 ? 'arguments' : 'an argument'} ( @cached(${args.map((d) => `'${d}'`).join(', ')}), which is not supported. Dependencies are automatically tracked, so you can just use `${'`@cached`'}`

What it means

Error "You attempted to use @cached on with ${args.length > 1 ? 'arguments' : 'an argument'} ( @cached(${args.map((d) => `'${d}'`).join(', ')}), which is not supported. Dependencies are automatically tracked, so you can just use `${'`@cached`'}`" thrown in emberjs/ember.js.

Source

Thrown at packages/@ember/-internals/metal/lib/cached.ts:137

      caches.set(this, createCache(getter.bind(this)));
    }

    return getValue(caches.get(this));
  };
};

function throwCachedExtraneousParens(): never {
  throw new Error(
    'You attempted to use @cached(), which is not necessary nor supported. Remove the parentheses and you will be good to go!'
  );
}

function throwCachedGetterOnlyError(key: string): never {
  throw new Error(`The @cached decorator must be applied to getters. '${key}' is not a getter.`);
}

function throwCachedInvalidArgsError(args: unknown[] = []): never {
  throw new Error(
    `You attempted to use @cached on with ${
      args.length > 1 ? 'arguments' : 'an argument'
    } ( @cached(${args
      .map((d) => `'${d}'`)
      .join(
        ', '
      )}), which is not supported. Dependencies are automatically tracked, so you can just use ${'`@cached`'}`
  );
}

View on GitHub (pinned to 26f97246a8)

When it happens

Trigger: Thrown at packages/@ember/-internals/metal/lib/cached.ts:137 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of emberjs/ember.js@26f97246a8 (2026-09-01). Data as JSON: /api/errors/9d7cf2f46976c903. Report an issue: GitHub.