react / react/metro

npx metro-symbolicate returns TypeError: Line must be greater than or equal to 1, got 0

Open
#966 11 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
5.6k
Forks
696
Avg merge
8m
Merged PRs (30d)
7

Description

Downloaded a minified hermes crash log from Crashlytics
Tried the following command: npx metro-symbolicate <path/to/sourcemapfile> < stacktrace.txt
Error: TypeError: Line must be greater than or equal to 1, got 0

info Fetching system and libraries information...
System:
OS: macOS 13.1
CPU: (8) arm64 Apple M2
Memory: 113.50 MB / 8.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 14.17.3 - ~/.nvm/versions/node/v14.17.3/bin/node
Yarn: 1.22.19 - ~/repos/aph-mobile-patients/node_modules/.bin/yarn
npm: 6.14.13 - ~/.nvm/versions/node/v14.17.3/bin/npm
Watchman: 2023.04.10.00 - /opt/homebrew/bin/watchman
Managers:
CocoaPods: 1.11.3 - /Users/ashishkumar/.rbenv/shims/pod
SDKs:
iOS SDK:
Platforms: DriverKit 22.4, iOS 16.4, macOS 13.3, tvOS 16.4, watchOS 9.4
Android SDK: Not Found
IDEs:
Android Studio: 2022.1 AI-221.6008.13.2211.9619390
Xcode: 14.3/14E222b - /usr/bin/xcodebuild
Languages:
Java: 11.0.18 - /usr/bin/javac
npmPackages:
@react-native-community/cli: ^4.5.1 => 4.14.0
react: ^18.2.0 => 18.2.0
react-native: 0.68.0 => 0.68.0
react-native-macos: Not Found
npmGlobalPackages:
react-native: Not Found

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the reported command with the sourcemap file and stacktrace.txt from a minified Hermes Crashlytics log. Investigate the metro-symbolicate CLI path that handles these inputs and the reported line-0 error; done means the command processes the input without throwing this TypeError.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react-native
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.