SVG import is really finicky in 2.81 #71226

Closed
opened 2019-10-30 19:02:24 +01:00 by Fouad Hafiz · 7 comments

System Information
Operating system: Windows-10-10.0.18362 64 Bits
Graphics card: GeForce GTX 1070/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.08

Blender Version
Broken: version: 2.81 (sub 16), branch: master, commit date: 2019-10-29 20:49, hash: aff6446e06
Worked: 2.80 stable{F7873112}

Short description of error

Two files are attached. They both contain only vector path information, and no rasterized graphics.

I'm able to successfully import the attached SVG file test1.svg in 2.80, but not in 2.81

In order to troubleshoot the problem, I removed the long rectangular shape and saved the SVG file as test2.svg
Now, I am able to successfully import the file in 2.81.

Exact steps for others to reproduce the error
In 2.81, try to import the attached SVG file test1.svg (File>Import>SVG). Expected result: fail.

test1.svg

In 2.81, try to import the attached SVG file test2.svg (File>Import>SVG). Expected result: success.

test2.svg

**System Information** Operating system: Windows-10-10.0.18362 64 Bits Graphics card: GeForce GTX 1070/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.08 **Blender Version** Broken: version: 2.81 (sub 16), branch: master, commit date: 2019-10-29 20:49, hash: `aff6446e06` Worked: 2.80 stable{[F7873112](https://archive.blender.org/developer/F7873112/spot.svg)} **Short description of error** Two files are attached. They both contain only vector path information, and no rasterized graphics. I'm able to successfully import the attached SVG file **test1.svg** in 2.80, but not in 2.81 In order to troubleshoot the problem, I removed the long rectangular shape and saved the SVG file as **test2.svg** Now, I am able to successfully import the file in 2.81. **Exact steps for others to reproduce the error** In 2.81, try to import the attached SVG file **test1.svg** (File>Import>SVG). Expected result: fail. ![test1.svg](https://archive.blender.org/developer/F7873145/test1.svg) In 2.81, try to import the attached SVG file **test2.svg** (File>Import>SVG). Expected result: success. ![test2.svg](https://archive.blender.org/developer/F7873144/test2.svg)
Author

Added subscriber: @foodi-4

Added subscriber: @foodi-4
Member

Added subscriber: @CansecoGPC

Added subscriber: @CansecoGPC
Member

I can confirm this error (Blender 2.81.16) on Linux with the SVG importer on Official repos.

This is the error it shows:

Traceback (most recent call last):
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/__init__.py", line 59, in execute
    return import_svg.load(self, context, filepath=self.filepath)
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1882, in load
    load_svg(context, filepath, do_colormanage)
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1872, in load_svg
    loader.parse()
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1085, in parse
    ob = parseAbstractNode(node, self._context)
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1856, in parseAbstractNode
    ob.parse()
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1085, in parse
    ob = parseAbstractNode(node, self._context)
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1856, in parseAbstractNode
    ob.parse()
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1134, in parse
    pathParser = SVGPathParser(d, self._styles['useFill'])
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 508, in __init__
    self._data = SVGPathData(d)
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 420, in __init__
    token, last_char = read_float(d, i)
  File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/svg_util.py", line 88, in read_float
    raise Exception('Invalid float value near ' + text[start_index:start_index + 10])
Exception: Invalid float value near .188-1.392

location: <unknown location>:-1

But it works with Howard's AI/PDF/SVG importer/exporter on contrib repos.

I can confirm this error (Blender 2.81.16) on Linux with the SVG importer on Official repos. This is the error it shows: ``` Traceback (most recent call last): File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/__init__.py", line 59, in execute return import_svg.load(self, context, filepath=self.filepath) File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1882, in load load_svg(context, filepath, do_colormanage) File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1872, in load_svg loader.parse() File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1085, in parse ob = parseAbstractNode(node, self._context) File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1856, in parseAbstractNode ob.parse() File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1085, in parse ob = parseAbstractNode(node, self._context) File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1856, in parseAbstractNode ob.parse() File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 1134, in parse pathParser = SVGPathParser(d, self._styles['useFill']) File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 508, in __init__ self._data = SVGPathData(d) File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/import_svg.py", line 420, in __init__ token, last_char = read_float(d, i) File "/usr/share/blender/2.81/scripts/addons/io_curve_svg/svg_util.py", line 88, in read_float raise Exception('Invalid float value near ' + text[start_index:start_index + 10]) Exception: Invalid float value near .188-1.392 location: <unknown location>:-1 ``` But it works with Howard's AI/PDF/SVG importer/exporter on contrib repos.
Author

I forgot to include the error text. Thank you.

I forgot to include the error text. Thank you.

Added subscriber: @robbott

Added subscriber: @robbott

Changed status from 'Open' to: 'Archived'

Changed status from 'Open' to: 'Archived'
Jean First self-assigned this 2019-12-03 09:29:13 +01:00

duplicate of blender/blender-addons#71774. Please test your file and if it still fails to import, reopen this task.

duplicate of blender/blender-addons#71774. Please test your file and if it still fails to import, reopen this task.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#71226
No description provided.