question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Path not rendering after upgrade to react-native-svg 9.8.0

See original GitHub issue

Bug

Having today updated to 9.8.0, a SVG that has been rendering OK up until now is now not working.

I’ve narrowed it down to this part of the SVG. if I remove this, the remainder of the SVG renders OK:

<Path d="M469.61 246.97h-147.4l-39.5 97.88-35.15-99.8-35.17 99.8-39.25-97.88H25.26" fill="none" stroke="#fff" stroke-linecap="round" stroke-linejoin="round" stroke-miterlimit="10" stroke-width="4" />

The ‘Red box’ error says: Exception thrown while executing UI block: -[__NSCFString characterAtIndex:] Range index out of bounds

The console output is:

2019-08-30 19:01:40.953 [error][tid:main][RCTUIManager.m:1133] Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #3: Error setting property 'd' of RNSVGPath with tag #3: Error setting property 'd' of RNSVGPath with tag #3: Error setting property 'd' of RNSVGPath with tag #3: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Error setting property 'd' of RNSVGPath with tag #13: Exception thrown while executing UI block: 'parentNode' is a required parameter

Environment info

React native info output:

System:
    OS: macOS 10.14.6
    CPU: (8) x64 Intel(R) Core(TM) i7-4790K CPU @ 4.00GHz
    Memory: 106.09 MB / 16.00 GB
    Shell: 3.2.57 - /bin/bash
  Binaries:
    Node: 10.16.3 - /usr/local/bin/node
    Yarn: 1.17.3 - /usr/local/bin/yarn
    npm: 6.11.2 - /usr/local/bin/npm
    Watchman: 4.9.0 - /usr/local/bin/watchman
  SDKs:
    iOS SDK:
      Platforms: iOS 12.4, macOS 10.14, tvOS 12.4, watchOS 5.3
    Android SDK:
      API Levels: 25, 26, 27, 28
      Build Tools: 22.0.1, 23.0.1, 23.0.3, 24.0.0, 25.0.0, 26.0.2, 27.0.0, 27.0.3, 28.0.3
      System Images: android-26 | Google APIs Intel x86 Atom, android-28 | Google Play Intel x86 Atom
      Android NDK: 11.2.2725575
  IDEs:
    Android Studio: 3.5 AI-191.8026.42.35.5791312
    Xcode: 10.3/10G8 - /usr/bin/xcodebuild
  npmPackages:
    react: ^16.9.0 => 16.9.0
    react-native: ^0.60.5 => 0.60.5
  npmGlobalPackages:
    react-native-cli: 2.0.1
    react-native-create-library: 3.1.2
    react-native-git-upgrade: 0.2.7

Library version: 9.8.0

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:11

github_iconTop GitHub Comments

2reactions
msandcommented, Sep 3, 2019

Can you try v9.8.4?

2reactions
eahroldcommented, Sep 1, 2019
Read more comments on GitHub >

github_iconTop Results From Across the Web

Path not rendering after upgrade to react-native-svg 9.8.0 #1083
Having today updated to 9.8.0, a SVG that has been rendering OK up until now is now not working. I've narrowed it down...
Read more >
react-native-svg - npm
To render output like this: SVG example. Use the following code: import Svg, { Circle, Ellipse, G, Text, TSpan, TextPath, Path, Polygon, ...
Read more >
react native - Svg not showing correctly - Stack Overflow
I've been using react-native-svg and react-native-svg-transformer to render svg files in my app and it's worked fine.
Read more >
9.8 | Mendix Documentation
We upgraded the SVG library to version 3.3.0. We optimized the $currentUser variable in microflows. The current user will no longer always be...
Read more >
Upgrading to new versions - React Native
The new release may contain updates to other files that are generated when you run npx react-native init , those files are listed...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found