Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

meta(changelog): Update changelog for 7.92.0 #10063

Merged
merged 52 commits into from
Jan 4, 2024
Merged

Conversation

AbhiPrasad
Copy link
Member

No description provided.

github-actions bot and others added 30 commits December 22, 2023 11:39
[Gitflow] Merge master into develop
…ExtraErrorData` integration (#9914)

Co-authored-by: Lukas Stracke <[email protected]>
These types have been annoying me for a while. We can safely assume the
node version can be parsed.
… callbacks (#9974)

Oops, I noticed that our current `withScope` implementation does not
actually wait for async callbacks for setting the current scope 😬
Related to #9958,
which I copied there now!
…()` (#9970)

Also refactor it to use `continueTrace`.

Note that this already uses the "new" way of `startSpanManual` which
ignores the `finish` function.

---------

Co-authored-by: Lukas Stracke <[email protected]>
Add a top level `enabled` option to the Astro integration
options. This option can be used to globally enable/disable all Sentry
features, either for client or server separately or for both sides
simultaneously.

* Disabeling either side will avoid the respective SDK code being
injected into the bundles.
* If both sides are disabled, source maps will not be generated and
uploaded.
* If both or just the server side is disabled, the Sentry middleware
won't be added.
* Obviously, this options defaults to `true`
Bumps
[actions/upload-artifact](https://github.com/actions/upload-artifact)
from 3.1.3 to 4.0.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/actions/upload-artifact/releases">actions/upload-artifact's
releases</a>.</em></p>
<blockquote>
<h2>v4.0.0</h2>
<h2>What's Changed</h2>
<p>The release of upload-artifact@v4 and download-artifact@v4 are major
changes to the backend architecture of Artifacts. They have numerous
performance and behavioral improvements.</p>
<p>For more information, see the <a
href="https://github.com/actions/toolkit/tree/main/packages/artifact"><code>@​actions/artifact</code></a>
documentation.</p>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/vmjoseph"><code>@​vmjoseph</code></a>
made their first contribution in <a
href="https://redirect.github.com/actions/upload-artifact/pull/464">actions/upload-artifact#464</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/actions/upload-artifact/compare/v3...v4.0.0">https://github.com/actions/upload-artifact/compare/v3...v4.0.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/actions/upload-artifact/commit/c7d193f32edcb7bfad88892161225aeda64e9392"><code>c7d193f</code></a>
Merge pull request <a
href="https://redirect.github.com/actions/upload-artifact/issues/466">#466</a>
from actions/v4-beta</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/13131bb095770b4070a7477c3cd2d96e1c16d9f4"><code>13131bb</code></a>
licensed cache</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/4a6c273b9834f66a1d05c170dc3f80f9cdb9def1"><code>4a6c273</code></a>
Merge branch 'main' into v4-beta</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/f391bb91a3d3118aeca171c365bb319ece276b37"><code>f391bb9</code></a>
Merge pull request <a
href="https://redirect.github.com/actions/upload-artifact/issues/465">#465</a>
from actions/robherley/v4-documentation</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/9653d03c4b74c32144e02dae644fea70e079d4b3"><code>9653d03</code></a>
Apply suggestions from code review</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/875b63076402f25ef9d52c294c86ba4f97810575"><code>875b630</code></a>
add limitations section</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/ecb21463e93740a6be75c3116242169bfdbcb15a"><code>ecb2146</code></a>
add compression example</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/5e7604f84a055838f64ed68bb9904751523081ae"><code>5e7604f</code></a>
trim some repeated info</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/d6437d07581fe318a364512e6cf6b1dca6b4f92c"><code>d6437d0</code></a>
naming</li>
<li><a
href="https://github.com/actions/upload-artifact/commit/1b561557037b4957d7d184e9aac02bec86c771eb"><code>1b56155</code></a>
s/v4-beta/v4/g</li>
<li>Additional commits viewable in <a
href="https://github.com/actions/upload-artifact/compare/v3.1.3...v4.0.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/upload-artifact&package-manager=github_actions&previous-version=3.1.3&new-version=4.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This PR creates a new `LocalVariables` integration that uses the async
inspector API.

Rather than create a huge messy integration that supports both the sync
(node 18) and async (node >= v19) APIs, I created a new integration and
wrapped both the sync and async integrations with user facing
integration that switches depending on node version.

The async API doesn't require the stacking of callbacks that risks stack
overflows and limits the number of frames we dare to evaluate. When we
tried wrapping the sync API with promises, memory was leaked at an
alarming rate!

The inspector APIs are not available on all builds of Node so we have to
lazily load it and catch any exceptions.

I've had to use `dynamicRequire` because webpack picks up `import()` and
reports missing dependency when bundling for older versions of node.
Add a new eslint rule that flags the usage of `new RegExp()`
constructor calls. The purpose of this rule is to make us aware of the
potential danger of creating a regular expression from (end) user input.
This has led to security incidents in the past.

To be clear, it is perfectly okay to ignore this rule in cases where
we're sure that there's no danger or where input is already escaped.
It used to output all the files it processed, which lead to a very
verbose console output. By using `--check` we only get files that do not
match.
- No need to call `process.cwd()` on every iteration.
- No need to create paths on memory
We can simply use `AstroIntegrationLogger` instead of console. This
might improve DX.
https://docs.astro.build/en/reference/integrations-reference/#astrointegrationlogger
If the inspector is already running, then ANR should be able to (re)use
that, instead of opening it itself.
Disabled `noDelete` to avoid a huge change log. We can enable it
gradually.
…hods (#10006)

This was brought up in Slack, currently you cannot pass other span
properties directly to otel `startSpan()`. This now adds `attributes`,
`kind` and `startTime` to better align with OTEL.

Note that I chose to omit `root` and `links` options, not sure if we
want to support those in none-OTEL environments, and this API should
(~~) be the same for node & non-node in v8.
Together with `setAttribute()` and `setAttributes()` APIs, mirroring the
OpenTelemetry API for their spans.

For now, these are stored as `data` on spans/transactions, until we
"directly" support them.
mydea and others added 14 commits January 3, 2024 15:29
Instead, you can use a new `spanToTraceContext(span)` util function.
This PR makes a few fixes and additions to the ANR feature.
- Stops passing the `sdk` property with the event since
`enhanceEventWithSdkInfo` results in duplicate integrations/packages
being sent!
- Allows the passings of `staticTags` to attach to ANR events 
- Required by Electron SDK to tag the source
`process/origin/environment`
  - Could also be useful for other users
- Optionally enable normalising of stack frame paths to the app root
  - Required for Electron
  - Soon required for Node with #9072

The path normalisation code (and tests) are from the Electron SDK and is
well tested on all platforms. However, it will only be called when
`appRootPath` is supplied. If/when we add path normalisation to Node, it
will have a default which can be overridden.

The Electron SDK will then wrap the Node Anr integration something like
this:
```ts
class Anr extends NodeAnr {
  public constructor(options: Partial<Options> = {}) {
    super({
      ...options,
      staticTags: {
        'event.environment': 'javascript',
        'event.origin': 'electron',
        'event.process': 'browser',
        ...options.tags,        
      },
      appRootPath: app.getAppPath(),
    });
  }
}
```
```ts
import * as Sentry from '@sentry/node';
import { CronJob } from 'cron';

const CronJobWithCheckIn = Sentry.cron.instrumentCron(CronJob, 'my-cron-job');

// use the constructor
const job = new CronJobWithCheckIn('* * * * *', () => {
 console.log('You will see this message every minute');
});

// or from
const job = CronJobWithCheckIn.from({ cronTime: '* * * * *', onTick: () => {
  console.log('You will see this message every minute');
});
```
### Usage
```ts
import * as Sentry from "@sentry/node";
import cron from "node-cron";

const cronWithCheckIn = Sentry.cron.instrumentNodeCron(cron);

cronWithCheckIn.schedule(
  "* * * * *",
  () => {
    console.log("running a task every minute");
  },
  { name: "my-cron-job" },
);
 ```
Also add a `handleCallbackErrors` utility to replace this.

We've been using this in a few places, and since it has a bit of a
different usage than `startSpan` I had to add a new utility to properly
make this work. The upside is that we now can ensure to use the same
implementation for this "maybe promise" handling everywhere!

---------

Co-authored-by: Luca Forstner <[email protected]>
This is a WIP document about the new performance APIs. I'm sure I forgot
a bunch of things, but it's a start at least...!

[View
rendered](https://github.com/getsentry/sentry-javascript/blob/fn/docs-new-performance-apis/docs/v8-new-performance-apis.md)

---------

Co-authored-by: Lukas Stracke <[email protected]>
@AbhiPrasad AbhiPrasad requested review from mydea, lforst and Lms24 January 4, 2024 16:01
@AbhiPrasad AbhiPrasad force-pushed the prepare-release/7.92.0 branch from 821ea1d to 41bd1b5 Compare January 4, 2024 16:10
@AbhiPrasad AbhiPrasad force-pushed the prepare-release/7.92.0 branch from 41bd1b5 to 69a9caa Compare January 4, 2024 16:51
@AbhiPrasad AbhiPrasad force-pushed the prepare-release/7.92.0 branch 2 times, most recently from 24cc228 to 1c6f139 Compare January 4, 2024 17:31
@AbhiPrasad AbhiPrasad force-pushed the prepare-release/7.92.0 branch from 1c6f139 to c06c2d8 Compare January 4, 2024 17:31
@AbhiPrasad AbhiPrasad merged commit 7bca411 into master Jan 4, 2024
93 checks passed
@AbhiPrasad AbhiPrasad deleted the prepare-release/7.92.0 branch January 4, 2024 17:46
c298lee pushed a commit that referenced this pull request Jan 9, 2024
meta(changelog): Update changelog for 7.92.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants