Bug 421977 - Vector shapes sometimes missing when loading file
Summary: Vector shapes sometimes missing when loading file
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Tools/Vector (other bugs)
Version First Reported In: 4.2.9
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-05-23 13:40 UTC by hawaiigames
Modified: 2020-05-24 15:11 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
A file reproducing the issue on my system. (3.07 MB, application/x-krita)
2020-05-23 13:40 UTC, hawaiigames
Details

Note You need to log in before you can comment on or make changes to this bug.
Description hawaiigames 2020-05-23 13:40:45 UTC
Created attachment 128718 [details]
A file reproducing the issue on my system.

SUMMARY
Sometimes when loading a file, vector shapes that should be visible are not visible and need to be made visible by interacting with them in some way. "Fixing" the file requires re-loading it several times until the bug does not occur, or twiddling every individual shape, which takes a lot of time when there are many.

STEPS TO REPRODUCE
I'm unsure how exactly to reproduce it as the effect seems somehow linked to my work process and how I stack layers. A file that reproduces the bug on my system is attached. It's structured to imitate my usual layer setup in a reduced manner. In most cases when I load the file, the shape in the layer called "main" is not visible, and the shapes in "MASK_a" and MASK_b" only appear when their layers are made visible.

OBSERVED RESULT
Vector shapes sometimes (3 out of 5 times?) don't load properly when a file containing them is loaded. When the bug occurs, the previews of all vector layers in the layers window are empty. 
Vector shapes that were in hidden layers can reappear if the layer is turned back to visible, correcting the previews in the process. 
Vector shapes that are on visible layers need to be modified (e.g. selected and moved, their opacity changed, etc...) to reappear. Hiding and unhiding the layer will have no effect. However, making an overlapping shape visible, even on another layer, will make the former shape reappear within the overlapping region.

EXPECTED RESULT
Vector shapes should be visible on file load as they were when the file was saved.

SOFTWARE/OS VERSIONS
Windows: 7 x64
Comment 1 Ahab Greybeard 2020-05-24 08:02:40 UTC
Can you try this with the 4.3.0 beta-1 (which is very close to formal release) to see if any of these problems are taken care of?

You can get it from here: https://krita.org/en/item/first-beta-of-krita-4-3-0-released/# and you can use the portable .zip version if you prefer.

There are two points in your post that puzzle me:

"the shapes in "MASK_a" and MASK_b" only appear when their layers are made visible."
"Vector shapes that were in hidden layers can reappear if the layer is turned back to visible, correcting the previews in the process."

Isn't that to be expected? If a layer is invisible/hidden, it won't be seen or affect anything.
Comment 2 hawaiigames 2020-05-24 09:30:29 UTC
(In reply to Ahab Greybeard from comment #1)
> Can you try this with the 4.3.0 beta-1 (which is very close to formal
> release) to see if any of these problems are taken care of?
> 
> You can get it from here:
> https://krita.org/en/item/first-beta-of-krita-4-3-0-released/# and you can
> use the portable .zip version if you prefer.
> 
> There are two points in your post that puzzle me:
> 
> "the shapes in "MASK_a" and MASK_b" only appear when their layers are made
> visible."
> "Vector shapes that were in hidden layers can reappear if the layer is
> turned back to visible, correcting the previews in the process."
> 
> Isn't that to be expected? If a layer is invisible/hidden, it won't be seen
> or affect anything.

I tested the 4.3.0 version you linked to, and that seems to have indeed taken care of the problem. I loaded the file several times, restarted Krita a few times in-between as well, but the file came up properly every time. Other files that had similar issues did as well.
I don't want to call it an unanimous "solved" since the issue occurred somewhat randomly, but it seems to work for now.

My apologies about the puzzling points, I missed out on some crucial information there. What I meant is that the previews in the "Layers" window were empty as well. 
E.g., "MASK_a" should have shown the bright green shape in the preview, even when the layer was checked as "hidden". But the preview in the "Layers" list only showed an alpha-grid square - as if the layer was empty.

So, what I meant to say is that the preview only updated correctly once a hidden layer was turned back to visible. 
The reason I didn't specify this is because I was more focused on the general symptom of Krita behaving as if all vector layers were empty, and depending on the state of each layer, I needed different kinds of "triggers" to make the vector shapes visible again. In the case of a layer that was hidden when I saved the file, un-hiding it was that trigger.
Comment 3 Ahab Greybeard 2020-05-24 09:46:34 UTC
It's good to hear that the 4.3.0 beta-1 seems to be working for you.
Can you come back to this and set the Status to Resolved Fixed when you're convinced that all is well?

The Layers docker thumbnails not showing layer content would be a separate bug so please report that separately if it's still a problem in 4.3.0.
(I have a feeling it's been seen before and may have an existing bug report but I can't find one with a simple search.)
Comment 4 hawaiigames 2020-05-24 12:07:15 UTC
(In reply to Ahab Greybeard from comment #3)
> It's good to hear that the 4.3.0 beta-1 seems to be working for you.
> Can you come back to this and set the Status to Resolved Fixed when you're
> convinced that all is well?
> 
> The Layers docker thumbnails not showing layer content would be a separate
> bug so please report that separately if it's still a problem in 4.3.0.
> (I have a feeling it's been seen before and may have an existing bug report
> but I can't find one with a simple search.)

I can do that. Is a week acceptable? I'll keep working as usual, and if the bug doesn't reoccur within the next 7 days, I'll set it to Resolved Fixed.

As for the Layers docker issue with empty thumbnails, I've not seen more of it in 4.3.0 beta-1 so far - so it seems fixed as well. But I'll keep that in mind, and I'll file a report if I notice anything.

And thank you very much for your help!
Comment 5 Ahab Greybeard 2020-05-24 12:59:06 UTC
Whenever you feel confident about it. You can always reopen it if that problem returns.
Comment 6 hawaiigames 2020-05-24 15:11:06 UTC
(In reply to Ahab Greybeard from comment #5)
> Whenever you feel confident about it. You can always reopen it if that
> problem returns.

Ah, I didn't realise that was an option. Doing it that way makes more sense. Thank you!