Skip to content

Commit 0ec4390

Browse files
authored
Godot: Creating source bundles for engine templates (#13665)
1 parent 1ccb14d commit 0ec4390

File tree

2 files changed

+52
-11
lines changed

2 files changed

+52
-11
lines changed
61.3 KB
Loading

docs/platforms/godot/configuration/stack-traces.mdx

Lines changed: 52 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -148,36 +148,77 @@ sentry-cli login
148148

149149
It will prompt you to create an auth token in your web browser. Follow the instructions, generate the token, and then paste it into the command-line prompt when asked.
150150

151-
To upload debug symbols to Sentry using `sentry-cli`, run the following command:
151+
To show inline source context in Sentry, `sentry-cli` can scan debug files for source references, resolves them locally, and creates an archive of all referenced source files called _source bundle_. The source bundle can be created by `sentry-cli` during the upload of debug information files.
152152

153-
```bash
154-
sentry-cli debug-files upload --org ___ORG_SLUG___ --project ___PROJECT_SLUG___ ./bin
153+
To upload the debug information files to Sentry with sources included, run the following command:
154+
155+
```bash {tabTitle:Bash/PowerShell}
156+
sentry-cli debug-files upload --include-sources --org ___ORG_SLUG___ --project ___PROJECT_SLUG___ bin
157+
```
158+
159+
This uploads debug information files from the `bin` directory to Sentry, creating the source bundles on the fly.
160+
161+
<Expandable title="Generating source bundle archives separately">
162+
163+
You can also create the source bundles separately from the upload step by running:
164+
165+
```PowerShell {tabTitle:Windows}
166+
sentry-cli debug-files bundle-sources bin\godot.windows.template_release.x86_64.pdb
167+
sentry-cli debug-files bundle-sources bin\godot.windows.template_release.x86_64.console.pdb
155168
```
156169

157-
This will upload the files with debug information from the `./bin` directory to Sentry.
170+
```bash {tabTitle:macOS}
171+
sentry-cli debug-files bundle-sources bin/godot.macos.template_release.x86_64.dSYM
172+
mv bin/godot.macos.template_release.src.zip bin/godot.macos.template_release.x86_64.src.zip
173+
sentry-cli debug-files bundle-sources bin/godot.macos.template_release.arm64.dSYM
174+
mv bin/godot.macos.template_release.src.zip bin/godot.macos.template_release.arm64.src.zip
175+
```
176+
177+
```bash {tabTitle:Linux}
178+
sentry-cli debug-files bundle-sources bin/godot.linuxbsd.template_release.x86_64.debugsymbols
179+
```
180+
181+
</Expandable>
158182

159183
Example output:
160184

161185
```PowerShell
162-
$ sentry-cli debug-files upload --org my-sentry-org --project my-game ./bin
186+
$ sentry-cli debug-files upload --include-sources --org my-sentry-org --project my-game bin
163187
> Found 4 debug information files
188+
WARN 2025-05-12 12:03:13.130458600 -07:00 Source exceeded maximum item size limit (1572415). C:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared\winerror.h
189+
WARN 2025-05-12 12:03:14.535023400 -07:00 Source exceeded maximum item size limit (1572415). C:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\shared\winerror.h
190+
WARN 2025-05-12 12:03:15.349655900 -07:00 Source exceeded maximum item size limit (1152425). C:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\um\shobjidl_core.h
191+
WARN 2025-05-12 12:03:15.947910200 -07:00 Source exceeded maximum item size limit (1145069). C:\Users\user\Projects\godot\4.4.1-stable\thirdparty\ufbx\ufbx.c
192+
> Resolved source code for 2 debug information files
164193
> Prepared debug information files for upload
165-
> Uploading completed in 7.429s
166-
> Uploaded 4 missing debug information files
194+
> Uploading completed in 10.049s
195+
> Uploaded 6 missing debug information files
167196
> File upload complete:
168197
169-
UPLOADED 88b87add-d362-406c-b3b7-9f019072a7e0-1 (godot.windows.template_release.x86_64.console.exe; x86_64 executable)
170-
UPLOADED 88b87add-d362-406c-b3b7-9f019072a7e0-1 (godot.windows.template_release.x86_64.console.pdb; x86_64 debug companion)
171-
UPLOADED 07c660ac-3f72-4c75-8aca-1378240cc949-1 (godot.windows.template_release.x86_64.pdb; x86_64 debug companion)
172-
UPLOADED 07c660ac-3f72-4c75-8aca-1378240cc949-1 (godot.windows.template_release.x86_64.exe; x86_64 executable)
198+
UPLOADED efc658cd-7481-4a15-93a5-9f8fa2b6c8a3-1 (godot.windows.template_release.x86_64.pdb; x86_64 sources)
199+
UPLOADED efc658cd-7481-4a15-93a5-9f8fa2b6c8a3-1 (godot.windows.template_release.x86_64.pdb; x86_64 debug companion)
200+
UPLOADED 050f8915-6eae-4054-8062-b90d75593f3a-1 (godot.windows.template_release.x86_64.console.pdb; x86_64 sources)
201+
UPLOADED efc658cd-7481-4a15-93a5-9f8fa2b6c8a3-1 (godot.windows.template_release.x86_64.exe; x86_64 executable)
202+
UPLOADED 050f8915-6eae-4054-8062-b90d75593f3a-1 (godot.windows.template_release.x86_64.console.exe; x86_64 executable)
203+
UPLOADED 050f8915-6eae-4054-8062-b90d75593f3a-1 (godot.windows.template_release.x86_64.console.pdb; x86_64 debug companion)
173204
```
174205

175206
<Alert>
176207

208+
A handful of Godot engine source files over 10 MiB may be excluded from the bundle. You’ll see warnings about them in the console output. While this isn’t an issue, stack frames pointing to those files won’t show inline source context.
209+
177210
For more information, refer to [Sentry CLI](/cli/) documentation.
178211

179212
</Alert>
180213

214+
You can also upload debug files for the Sentry SDK itself by running the following command from your project directory:
215+
216+
```bash {tabTitle:Bash/PowerShell}
217+
sentry-cli debug-files upload --org ___ORG_SLUG___ --project ___PROJECT_SLUG___ addons/sentrysdk/
218+
```
219+
220+
This uploads the SDK's debug files to Sentry. You can repeat this step for any other native extension used in your Godot project.
221+
181222
Congratulations! You're all set up. Your exported project should now produce symbolicated stack traces in Sentry.
182223

183224
![Symbolicated Issue](./imgs/symbolicated_issue.png)

0 commit comments

Comments
 (0)