Skip to content

Expose SourceMapView.get_source_contents function#921

Merged
loewenheim merged 2 commits intogetsentry:masterfrom
pablomatiasgomez:pablomatiasgomez/expose-get-source-contents
May 26, 2025
Merged

Expose SourceMapView.get_source_contents function#921
loewenheim merged 2 commits intogetsentry:masterfrom
pablomatiasgomez:pablomatiasgomez/expose-get-source-contents

Conversation

@pablomatiasgomez
Copy link
Copy Markdown
Contributor

Currently only a few functions of the underlying lib (https://github.com/getsentry/rust-sourcemap) are exposed.

In particular, there's currently no way to get the source code contents, but just the names can currently be retrieved.

This change adds support to expose the fn SourceMap::get_source_contents : https://github.com/getsentry/rust-sourcemap/blob/24a07e376a634c7823ada1b55326454ba7fc921d/src/types.rs#L787-L792

/**
* Return the number of sources.
*/
uint32_t symbolic_sourcemapview_get_source_count(const struct SymbolicSourceMapView *source_map);
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I just organized the functions here as they were sorted differently in each of the files.

@loewenheim
Copy link
Copy Markdown
Contributor

Hi, thank you for the contribution! Can you add an entry to the top of the changelog? Something like

## Unreleased

**Features**

- python bindings: Expose SourceMapView.get_source_contents function. ([#921](https://github.com/getsentry/symbolic/pull/921))

@pablomatiasgomez
Copy link
Copy Markdown
Contributor Author

Hi, thank you for the contribution! Can you add an entry to the top of the changelog? Something like

## Unreleased

**Features**

- python bindings: Expose SourceMapView.get_source_contents function. ([#921](https://github.com/getsentry/symbolic/pull/921))

sure! Added! Thanks for the review :)

@loewenheim loewenheim enabled auto-merge (squash) May 26, 2025 13:20
@loewenheim loewenheim merged commit e4c5267 into getsentry:master May 26, 2025
13 checks passed
@pablomatiasgomez pablomatiasgomez deleted the pablomatiasgomez/expose-get-source-contents branch May 26, 2025 13:24
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.

2 participants