Skip to content

sentry_cli (Unity native windows64) - generated command line too long during debug-symbols upload #1602

Open
@altereyes

Description

@altereyes

Causing/replicating the error: a Unity project with over 260 .pdb files.

Results in:

  1. Sentry: (Error) Failed to add the Sentry native integration to the built application System.ComponentModel.Win32Exception (0x80004005): ApplicationName='C:\Users\xxx\Library\PackageCache\io.sentry.unity@cfd1f01ace\Editor\sentry-cli\sentry-cli-Windows-x86_64.exe' [...many many pdb files....], Native error= The filename or extension is too long.

  2. BuildFailedException: Sentry Native BuildPostProcess failed
    Sentry.Unity.Editor.Native.BuildPostProcess.OnPostProcessBuild (UnityEditor.BuildTarget target, System.String executablePath) (at /sentry-unity/src/Sentry.Unity.Editor/Native/BuildPostProcess.cs:61)

Reason: generating a sentry_cli command line that exceeds the windows native command line size limit (which I belief is 8191 characters).

Solution (my initial thoughts, but you probably know better):

  1. (my pref) generate a txt file with the pdb files listed in it and use this txt file in the sentry_cli command line
  2. or, chunk the list of pdb files and launch sentry_cli multiple times (each time making sure not to exceed the command line size limit)
  3. or, I have to deal with it myself and try to reduce path lengths, thus reducing the overall command line size
  4. or, disable debug symbol upload all together

Version: https://github.com/getsentry/unity.git#1.8.0

Thanks for looking into this,
Pieter (paying Sentry customer :-)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    Status

    No status

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions