Package + Version
Version:
Description
In upgrading an application using @sentry/ember v6.6.0 to v6.15 we ran into some peculiar type regressions. Here's a snippet of our code that worked before:
assert(
'[ember-metrics] You must configure Heap adapter. See documentation.',
typeof config !== 'undefined'
);
const { appId, pageViewPrefix } = config;
Using v6.6.0 this code works, but suddenly, when v6.10 (or later), is introduced we see the type for assert fail.
I'm not entirely sure this is the problem, but this is a bit of a smoking gun:
|
declare module '@ember/debug' { |
|
export function assert(desc: string, test: unknown): void; |
|
} |
Note that this typing differs from the DefinitelyTyped version:
https://github.com/DefinitelyTyped/DefinitelyTyped/blob/4a4f37536cec0d38819acd9015600de7715ac6b3/types/ember__debug/index.d.ts#L10-L14
I believe that If you were to use the @types/ember__debug package instead of rolling your own type this problem should be resolved.
Package + Version
@sentry/browser:@sentry/noderaven-jsraven-node(raven for node)@sentry/emberVersion:
Description
In upgrading an application using
@sentry/emberv6.6.0 to v6.15 we ran into some peculiar type regressions. Here's a snippet of our code that worked before:Using v6.6.0 this code works, but suddenly, when v6.10 (or later), is introduced we see the type for
assertfail.I'm not entirely sure this is the problem, but this is a bit of a smoking gun:
sentry-javascript/packages/ember/addon/index.ts
Lines 11 to 13 in a72ea44
Note that this typing differs from the DefinitelyTyped version:
https://github.com/DefinitelyTyped/DefinitelyTyped/blob/4a4f37536cec0d38819acd9015600de7715ac6b3/types/ember__debug/index.d.ts#L10-L14
I believe that If you were to use the
@types/ember__debugpackage instead of rolling your own type this problem should be resolved.