Skip to content

feat: Move contextlines code to sidecar - #454

Merged
BYK merged 2 commits into
mainfrom
byk/feat/contextlines-on-sidecar
Jul 25, 2024
Merged

BYK merged 2 commits into
mainfrom
byk/feat/contextlines-on-sidecar

Conversation

@BYK

@BYK BYK commented Jul 24, 2024 •

Copy link
Copy Markdown
Member

This change moves the contextlines provider to the sidecar from the Vite plugin opening it up to all SDKs and integrations, not just Vite-based ones. This also means we do not clobber Vite dev server's URL-space (not that it was a problem, but alas).

This required adding a setter to SentryDataCache class as it was used as a singleton from its module and handles the additional context line fetching per earlier PRs. It would be good to refactor this usage to make it more contained/encapsulated.

Closes #449.

@vercel

vercel Bot commented Jul 24, 2024 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
spotlightjs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 24, 2024 11:53pm

@BYK
BYK force-pushed the byk/feat/contextlines-on-sidecar branch from 2b8c9e7 to f0cf671 Compare July 24, 2024 23:43
@BYK
BYK marked this pull request as ready for review July 24, 2024 23:47
@BYK
BYK requested review from Lms24, Shubhdeep12 and dcramer July 24, 2024 23:47

@dcramer dcramer left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't review in detail but general change makes sense - not sure if we'll be able to keep this kind of behavior if Sidecar runs remotely though (which is fine)

@BYK

BYK commented Jul 25, 2024

Copy link
Copy Markdown
Member Author

Aware of the dependency on being local. Will look into that later.

@BYK
BYK merged commit 9a7357f into main Jul 25, 2024
@BYK
BYK deleted the byk/feat/contextlines-on-sidecar branch July 25, 2024 15:57
BYK pushed a commit that referenced this pull request Jul 29, 2024
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and publish to npm
yourself or [setup this action to publish
automatically](https://github.com/changesets/action#with-publishing). If
you're not ready to do a release yet, that's fine, whenever you add more
changesets to main, this PR will be updated.


# Releases
## @spotlightjs/[email protected]

### Minor Changes

- Add ability to use sidecar URL in a DSN
([#452](#452))

### Patch Changes

-   Updated dependencies

\[[`0a6486b14d96a0eafec27a94707e4715b9fc3583`](0a6486b),

[`9a7357f1dedc66d030358176bee777715b09c41b`](9a7357f),

[`06f3070867534641dbb5c394e5513ca9781bbfa8`](06f3070),

[`725cbb5daea8682fdf8fefb952ddce68c97c4d6f`](725cbb5)]:
    -   @spotlightjs/[email protected]
    -   @spotlightjs/[email protected]

## @spotlightjs/[email protected]

### Minor Changes

- Move contextlines provider to sidecar
([#454](#454))

- Add 'open in editor' icon
([#462](#462))

### Patch Changes

-   Fix incompatibility between Spotlight and Storybook's bundling.
    ([#420](#420))

## @spotlightjs/[email protected]

### Minor Changes

- Add ability to use sidecar URL in a DSN
([#452](#452))

- Move contextlines provider to sidecar
([#454](#454))

- Add 'open in editor' icon
([#462](#462))

## @spotlightjs/[email protected]

### Minor Changes

- Add ability to use sidecar URL in a DSN
([#452](#452))

- Move contextlines provider to sidecar
([#454](#454))

- Add 'open in editor' icon
([#462](#462))

### Patch Changes

-   Fix `npx @spotlightjs/spotlight` not running standalone overlay
    ([#457](#457))

-   Fix incompatibility between Spotlight and Storybook's bundling.
    ([#420](#420))

-   Updated dependencies

\[[`0a6486b14d96a0eafec27a94707e4715b9fc3583`](0a6486b),

[`9a7357f1dedc66d030358176bee777715b09c41b`](9a7357f),

[`06f3070867534641dbb5c394e5513ca9781bbfa8`](06f3070),

[`725cbb5daea8682fdf8fefb952ddce68c97c4d6f`](725cbb5)]:
    -   @spotlightjs/[email protected]
    -   @spotlightjs/[email protected]

## @spotlightjs/[email protected]

### Patch Changes

-   Updated dependencies

\[[`6cf5de875f3f8e5a6ff0ec165dbd71af3b1932f5`](6cf5de8),

[`0a6486b14d96a0eafec27a94707e4715b9fc3583`](0a6486b),

[`9a7357f1dedc66d030358176bee777715b09c41b`](9a7357f),

[`06f3070867534641dbb5c394e5513ca9781bbfa8`](06f3070),

[`725cbb5daea8682fdf8fefb952ddce68c97c4d6f`](725cbb5)]:
    -   @spotlightjs/[email protected]

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
dcramer pushed a commit that referenced this pull request Jun 3, 2025
This change moves the contextlines provider to the sidecar from the Vite
plugin opening it up to all SDKs and integrations, not just Vite-based
ones. This also means we do not clobber Vite dev server's URL-space (not
that it was a problem, but alas).

This required adding a setter to `SentryDataCache` class as it was used
as a singleton from its module and handles the additional context line
fetching per earlier PRs. It would be good to refactor this usage to
make it more contained/encapsulated.

Closes #449.
dcramer pushed a commit that referenced this pull request Jun 3, 2025
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and publish to npm
yourself or [setup this action to publish
automatically](https://github.com/changesets/action#with-publishing). If
you're not ready to do a release yet, that's fine, whenever you add more
changesets to main, this PR will be updated.


# Releases
## @spotlightjs/[email protected]

### Minor Changes

- Add ability to use sidecar URL in a DSN
([#452](#452))

### Patch Changes

-   Updated dependencies

\[[`0a6486b14d96a0eafec27a94707e4715b9fc3583`](0a6486b),

[`9a7357f1dedc66d030358176bee777715b09c41b`](9a7357f),

[`06f3070867534641dbb5c394e5513ca9781bbfa8`](06f3070),

[`725cbb5daea8682fdf8fefb952ddce68c97c4d6f`](725cbb5)]:
    -   @spotlightjs/[email protected]
    -   @spotlightjs/[email protected]

## @spotlightjs/[email protected]

### Minor Changes

- Move contextlines provider to sidecar
([#454](#454))

- Add 'open in editor' icon
([#462](#462))

### Patch Changes

-   Fix incompatibility between Spotlight and Storybook's bundling.
    ([#420](#420))

## @spotlightjs/[email protected]

### Minor Changes

- Add ability to use sidecar URL in a DSN
([#452](#452))

- Move contextlines provider to sidecar
([#454](#454))

- Add 'open in editor' icon
([#462](#462))

## @spotlightjs/[email protected]

### Minor Changes

- Add ability to use sidecar URL in a DSN
([#452](#452))

- Move contextlines provider to sidecar
([#454](#454))

- Add 'open in editor' icon
([#462](#462))

### Patch Changes

-   Fix `npx @spotlightjs/spotlight` not running standalone overlay
    ([#457](#457))

-   Fix incompatibility between Spotlight and Storybook's bundling.
    ([#420](#420))

-   Updated dependencies

\[[`0a6486b14d96a0eafec27a94707e4715b9fc3583`](0a6486b),

[`9a7357f1dedc66d030358176bee777715b09c41b`](9a7357f),

[`06f3070867534641dbb5c394e5513ca9781bbfa8`](06f3070),

[`725cbb5daea8682fdf8fefb952ddce68c97c4d6f`](725cbb5)]:
    -   @spotlightjs/[email protected]
    -   @spotlightjs/[email protected]

## @spotlightjs/[email protected]

### Patch Changes

-   Updated dependencies

\[[`6cf5de875f3f8e5a6ff0ec165dbd71af3b1932f5`](6cf5de8),

[`0a6486b14d96a0eafec27a94707e4715b9fc3583`](0a6486b),

[`9a7357f1dedc66d030358176bee777715b09c41b`](9a7357f),

[`06f3070867534641dbb5c394e5513ca9781bbfa8`](06f3070),

[`725cbb5daea8682fdf8fefb952ddce68c97c4d6f`](725cbb5)]:
    -   @spotlightjs/[email protected]

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

This branch was successfully deployed

1 active deployment
Preview — 7a792f1b Deployed Jul 24, 2024 by vercel[bot]
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.

Move contextlines endpoint to sidecar

2 participants