Sourcemaps not being applied on Electron

I am using Electron v4 and the @sentry/electron SDK and this is my webpack config:

    new SentryWebpackPlugin({
      release: 'codekit@1.0.10',
      include: 'build/electron',
      ignoreFile: '.sentrycliignore',
      ignore: [
      configFile: ''

Which uploads the bundle.js and files to ~/build/electron/ on Sentry because that’s the output specified in the webpack config.

The problem I think that when an error is raised the electron app is reporting the bundle file is located at: file:/// so it doesn’t match the release artifact of ~/build/electron/bundle.js

When I uploaded the sourcemaps manually using the CLI directly on the root folder it started recognizing them sort of correctly. Although it was still raising an error that the location was invalid.

How can I specify on the SentryWebpackPlugin or where to upload the files and also how can I fix the Invalid location in sourcemap error?