Maniphest T69610

Outliner doesn't update text data-block list and crashes on unlinking text
Closed, Resolved

Assigned To
Nathan Craddock (natecraddock)
Authored By
Chris Tabron (tetrapixel)
Sep 7 2019, 9:43 AM
Tags
  • BF Blender
  • Text Editor
Subscribers
Chris Tabron (tetrapixel)
Dalai Felinto (dfelinto)
Nathan Craddock (natecraddock)

Description

Blender Version
Broken: version: 2.81 (sub 8), branch: master, commit date: 2019-09-06 22:44, hash: rBed779333bb82

Short description of error
After setting up my workspace layout for text editing, I set the outliner's display mode to "Blender File" and the filter ID type to "Text". And when I add an empty text data-block in the text editor, the list of text data-blocks in the outliner doesn't update instantly unless you hover anywhere on it's header. And when I tried to unlink the text data-block, it just crashes instantly.

Exact steps for others to reproduce the error

  1. In the outliner, set the display mode to "Blender file".
  2. Set the filter I.D. type to "Text".
  3. Click on the "New" button in the header of the text editor to open an empty text block.
  4. Hover over any part of the outliner's header.
  5. Click on the "Unlink" button to unlink the empty text block. [on the Text Editor header]

Revisions and Commits

rB Blender

Related Objects

Event Timeline

Chris Tabron (tetrapixel) renamed this task from Outliner list doesn't update text data-block list and crashes instantly after unlinking blank text data-block to Outliner doesn't update text data-block list and crashes instantly after unlinking blank text data-block.Sep 7 2019, 9:43 AM
Chris Tabron (tetrapixel) created this task.
Chris Tabron (tetrapixel) updated the task description.
Chris Tabron (tetrapixel) updated the task description.Sep 7 2019, 10:02 AM
Chris Tabron (tetrapixel) updated the task description.
Dalai Felinto (dfelinto) lowered the priority of this task from 90 to Low.Sep 18 2019, 2:21 AM
Dalai Felinto (dfelinto) added a project: Text Editor.
Dalai Felinto (dfelinto) added subscribers: Nathan Craddock (natecraddock), Dalai Felinto (dfelinto).

Confirmed. It should be a straightforward fix, and in a way it is the same solution for both:

  • A notifier/message when creating the text ID.
  • Tag outliner to redraw/free when deleting the text ID.

For the records the crash is:

//source/blender/editors/space_outliner/outliner_draw.c:3101
3101        if (ELEM(tselem->type, 0, TSE_LAYER_COLLECTION) && ID_IS_LINKED(tselem->id)) {

@Zachman can I interest you into looking at this?

Dalai Felinto (dfelinto) renamed this task from Outliner doesn't update text data-block list and crashes instantly after unlinking blank text data-block to Outliner doesn't update text data-block list and crashes on unlinking text.Sep 18 2019, 2:21 AM
Dalai Felinto (dfelinto) mentioned this in T68061: Text Editor Module.
Dalai Felinto (dfelinto) updated the task description.
Nathan Craddock (natecraddock) claimed this task.Sep 18 2019, 2:45 AM

Yes, I will take a look.

Nathan Craddock (natecraddock) changed the task status from Unknown Status to Resolved by committing rB2480c9236fd4: Fix T69610: Outliner doesn't update for text new and unlink.Sep 19 2019, 5:14 PM
Nathan Craddock (natecraddock) added a commit: rB2480c9236fd4: Fix T69610: Outliner doesn't update for text new and unlink.