Maniphest T95962

Sapling Addon now broken because of "SPDX-License-Identifier" header
Closed, Resolved

Assigned To
Campbell Barton (campbellbarton)
Authored By
Adrian Sausenthaler (sausix)
Feb 22 2022, 6:10 PM
Tags
  • Add-ons (Community)
Subscribers
Adrian Sausenthaler (sausix)
Campbell Barton (campbellbarton)
Jesse Yurkovich (deadpin)
Matija Barac (Dontlose2soon)

Description

System Information
Operating system: Linux-5.16.9-arch1-1-x86_64-with-glibc2.35 64 Bits
Graphics card: NVIDIA GeForce RTX 2080/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 510.54

Blender Version
Broken: version: 3.2.0 Alpha, branch: makepkg (modified), commit date: 2022-02-17 12:14, hash: rB433fad50d859
Worked: Probably before the commit

Addon Information
Name: Sapling Tree Gen (0, 3, 4)
Author: Andrew Hale (TrumanBlending), Aaron Buchler, CansecoGPC

Short description of error
Python: "SyntaxError: invalid syntax" on adding tree

Exact steps for others to reproduce the error
View3D -> Add -> Curve -> Sapling Tree Gen

Problem
This commit added a new first line into callistemon.py: Diff

The addon code on line 185 (https://git.blender.org/gitweb/gitweb.cgi/blender-addons.git/blob/HEAD:/add_curve_sapling/__init__.py#l185) now reads the comment: SPDX-License-Identifier: GPL-2.0-or-later from file blender/3.2/scripts/addons/add_curve_sapling/presets/callistemon.py instead of the prior JSON string, which fails at the ast parser.

Stacktrace

location: /usr/share/blender/3.2/scripts/modules/bpy/ops.py:116
Error: Python: Traceback (most recent call last):
  File "/usr/share/blender/3.2/scripts/addons/add_curve_sapling/__init__.py", line 188, in execute
    settings = ast.literal_eval(settings)
  File "/usr/lib/python3.10/ast.py", line 62, in literal_eval
    node_or_string = parse(node_or_string.lstrip(" \t"), mode='eval')
  File "/usr/lib/python3.10/ast.py", line 50, in parse
    return compile(source, filename, mode, flags,
  File "<unknown>", line 1
    # SPDX-License-Identifier: GPL-2.0-or-later
SyntaxError: invalid syntax

Revisions and Commits

rBA Blender Add-ons

Related Objects

Event Timeline

Adrian Sausenthaler (sausix) created this task.Feb 22 2022, 6:10 PM
Jachym Michal (jachymmichal) added a subscriber: Jachym Michal (jachymmichal).Feb 22 2022, 6:27 PM
Jachym Michal (jachymmichal) removed a subscriber: Jachym Michal (jachymmichal).
Jesse Yurkovich (deadpin) changed the task status from Needs Triage to Confirmed.Feb 22 2022, 10:03 PM
Jesse Yurkovich (deadpin) added subscribers: Campbell Barton (campbellbarton), Jesse Yurkovich (deadpin).

CC @Campbell Barton (campbellbarton) The script is not expecting its supporting files to contain any lines other than the json blob.

Campbell Barton (campbellbarton) closed this task as Resolved by committing rBA593c699b2a50: Fix T95962: Sapling Addon now broken because of license header.Feb 23 2022, 2:46 AM
Campbell Barton (campbellbarton) claimed this task.
Campbell Barton (campbellbarton) added a commit: rBA593c699b2a50: Fix T95962: Sapling Addon now broken because of license header.
Omar Emara (OmarSquircleArt) merged a task: T96764: Add Curve: Sampling Tree Gen error.Mar 25 2022, 8:19 AM
Omar Emara (OmarSquircleArt) added a subscriber: Matija Barac (Dontlose2soon).