looptools gstretch/gpencil bug #63682

Closed
opened 2019-04-17 15:30:27 +02:00 by Ariel Gimenez · 22 comments

System Information
Operating system: windows 7 64 bits
Graphics card: gforce 9800gt

Blender Version
2019-04-17 10_27_09-Blender.jpg

Broken:

(example: 2.80, edbf15d3c044, blender2.8, 2018-11-28, as found on the splash screen)
It does not work well and if you press Gstrech it shows a bug

Worked: (optional)

Short description of error

Exact steps for others to reproduce the error
just press GStrech and they will see the error
2019-04-17 10_29_50-Blender.jpg

2019-04-17 10_29_38-Blender.jpg

**System Information** Operating system: windows 7 64 bits Graphics card: gforce 9800gt **Blender Version** ![2019-04-17 10_27_09-Blender.jpg](https://archive.blender.org/developer/F6954343/2019-04-17_10_27_09-Blender.jpg) Broken: (example: 2.80, edbf15d3c044, blender2.8, 2018-11-28, as found on the splash screen) It does not work well and if you press Gstrech it shows a bug Worked: (optional) **Short description of error** **Exact steps for others to reproduce the error** just press GStrech and they will see the error ![2019-04-17 10_29_50-Blender.jpg](https://archive.blender.org/developer/F6954348/2019-04-17_10_29_50-Blender.jpg) ![2019-04-17 10_29_38-Blender.jpg](https://archive.blender.org/developer/F6954347/2019-04-17_10_29_38-Blender.jpg)
Author

Added subscriber: @ArielEduardoGimenez

Added subscriber: @ArielEduardoGimenez

#63811 was marked as duplicate of this issue

#63811 was marked as duplicate of this issue

Added subscriber: @StephenSwaney

Added subscriber: @StephenSwaney

From the barely legible error, it looks like there is no Grease Pencil stroke associated with this object.

Got a .blend for us that shows the problem?

From the barely legible error, it looks like there is no Grease Pencil stroke associated with this object. Got a .blend for us that shows the problem?
Author

yes, try this .blend although the problem also appears with a new .blend file
I use google translate{F6954713}

yes, try this .blend although the problem also appears with a new .blend file I use google translate{[F6954713](https://archive.blender.org/developer/F6954713/JUSTICIALISTA.blend)}
Author

.blend
compressed in zip{F6954776}

.blend compressed in zip{[F6954776](https://archive.blender.org/developer/F6954776/JUSTICIALISTA.zip)}
Author

Also if you open a new file and press gstrech you will see what the bug does.
The tool is malfunctioning in general.
google translate

Also if you open a new file and press gstrech you will see what the bug does. The tool is malfunctioning in general. google translate

Added subscriber: @Gvgeo-1

Added subscriber: @Gvgeo-1

From what I can tell, grease_pencil was in object or scene in 2.79.
The addon used the objects grease_pencil to stretch the vertices.
Now grease_pencil is a separate object.
The error is exactly that, object has no grease_pencil anymore.
Not sure how the annotation work. Must be in scene?

The addon needs to be updated for 2.80.
The default cube is enough for the error.

Traceback (most recent call last):
  File "D:\blender-2.80\2.80\scripts\addons\mesh_looptools.py", line 3986, in invoke
    return self.execute(context)
  File "D:\blender-2.80\2.80\scripts\addons\mesh_looptools.py", line 4016, in execute
    if get_grease_pencil(object, context):
  File "D:\blender-2.80\2.80\scripts\addons\mesh_looptools.py", line 64, in get_grease_pencil
    gp = object.grease_pencil
AttributeError: 'Object' object has no attribute 'grease_pencil'
From what I can tell, grease_pencil was in object or scene in 2.79. The addon used the objects grease_pencil to stretch the vertices. Now grease_pencil is a separate object. The error is exactly that, object has no grease_pencil anymore. Not sure how the annotation work. Must be in scene? The addon needs to be updated for 2.80. The default cube is enough for the error. ``` Traceback (most recent call last): File "D:\blender-2.80\2.80\scripts\addons\mesh_looptools.py", line 3986, in invoke return self.execute(context) File "D:\blender-2.80\2.80\scripts\addons\mesh_looptools.py", line 4016, in execute if get_grease_pencil(object, context): File "D:\blender-2.80\2.80\scripts\addons\mesh_looptools.py", line 64, in get_grease_pencil gp = object.grease_pencil AttributeError: 'Object' object has no attribute 'grease_pencil' ```
Author

I really do not know what is wrong, but thanks for the explanation .. And yes, with a cube you can see the error

I really do not know what is wrong, but thanks for the explanation .. And yes, with a cube you can see the error
Member

Added subscribers: @makadir, @lichtwerk

Added subscribers: @makadir, @lichtwerk
Philipp Oeser changed title from looptools BUG! to looptools gstretch bug 2019-04-23 09:34:04 +02:00
Member

Will confirm for now, not sure yet how to convert this feature to 2.8, needs some thinking [since gpencil is indeed a separate object in 2.8]

Will confirm for now, not sure yet how to convert this feature to 2.8, needs some thinking [since gpencil is indeed a separate object in 2.8]
Philipp Oeser changed title from looptools gstretch bug to looptools gstretch/gpencil bug 2019-04-23 09:45:29 +02:00

in general, it was working with 2.80.54 (abt 6th april build), some thing changed by this time.

in general, it was working with 2.80.54 (abt 6th april build), some thing changed by this time.
Member

Added subscriber: @BrendonMurphy

Added subscriber: @BrendonMurphy
Member

hi, I've been looking here: https://docs.blender.org/api/blender2.8/bpy.ops.gpencil.html

64		-     gp = object.grease_pencil
	64	+     gp = bpy.data.grease_pencils
65	65	      if not gp:
66		-         gp = context.scene.grease_pencil
	66	+         gp = context.view_layers.grease_pencils
67	67	      return gp

This led to an error here:

2844		-     layer = gp.layers.active
	2844	+     layer = context.active_gpencil_layer

which led to errors in:

2845	2846	      if not layer:

this was to do with

frame = layer.active_frame

@lichtwerk I'm just guessing and stuck on frame atm. maybe on the right track?

hi, I've been looking here: https://docs.blender.org/api/blender2.8/bpy.ops.gpencil.html ``` 64 - gp = object.grease_pencil 64 + gp = bpy.data.grease_pencils 65 65 if not gp: 66 - gp = context.scene.grease_pencil 66 + gp = context.view_layers.grease_pencils 67 67 return gp ``` This led to an error here: ``` 2844 - layer = gp.layers.active 2844 + layer = context.active_gpencil_layer ``` which led to errors in: ``` 2845 2846 if not layer: ``` this was to do with ``` frame = layer.active_frame ``` @lichtwerk I'm just guessing and stuck on frame atm. maybe on the right track?

Added subscriber: @yursiv

Added subscriber: @yursiv

This comment was removed by @yursiv

*This comment was removed by @yursiv*
Member

Added subscribers: @antoniov, @cwolf3d

Added subscribers: @antoniov, @cwolf3d
Member

Committed 934b32af8e although it only part fixes the issue.
Using the default cube I needed to subdivide an edge at least once for it to run in Spread modes.
Project function not working.
@cwolf3d and @antoniov are helping with the issue.

Committed 934b32af8ef7 although it only part fixes the issue. Using the default cube I needed to subdivide an edge at least once for it to run in Spread modes. Project function not working. @cwolf3d and @antoniov are helping with the issue.

LoopTools: Gstretch fix. Grease pencil must have name 'GPencil'. Script take only the first strokes.
https://developer.blender.org/rBAb23f15603088f2e382ce9a53093b58debc3d70e6

LoopTools: Gstretch fix. Grease pencil must have name 'GPencil'. Script take only the first strokes. https://developer.blender.org/rBAb23f15603088f2e382ce9a53093b58debc3d70e6
Member

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Brendon Murphy self-assigned this 2019-06-09 02:04:42 +02:00
Member

closing as resolved

closing as resolved
Sign in to join this conversation.
No Milestone
No project
No Assignees
9 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-addons#63682
No description provided.