Bug 391325 - Krita automatically blacklists newly-created brushes
Summary: Krita automatically blacklists newly-created brushes
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Usability (show other bugs)
Version: git master (please specify the git hash!)
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-03 07:44 UTC by Isaac Zuniga
Modified: 2018-03-06 17:12 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Capture with Process Monitor when overwriting the preset (12.99 KB, text/plain)
2018-03-06 16:08 UTC, Alvin Wong
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Isaac Zuniga 2018-03-03 07:44:22 UTC
I reported this issue earlier, but I did not know all the "specifics" for it to be helpful, I guess. Now, I do. I deleted my blacklist file and all of my old brushes appeared in Krita again, however, it seems whenever I create a new brush in Krita and edit it in the next session, a blacklist file is created so when that session ends, the third session will hide the brush, even though I never chose to delete it myself...

Here's a video showing the issue: https://drive.google.com/file/d/19vL2Y6ZIKqE1tQIN1wsG49XJVU8PbilO/view?usp=sharing

This is quite a pain, because the only way to combat this is to delete the blacklist file every time Krita is executed...

(Also, change the component if I filed it under the wrong category, I am unsure which category this issue belongs under.)
Comment 1 mvowada 2018-03-03 10:17:30 UTC
Hi isaac,

I'm not able to reproduce the problem on Linux Ubuntu (Krita 4 beta), with the following steps:

(I understand that the starting brush in the video ("A - 6") has appeared after you deleted the blacklist file).

    1) - new document

    2) - save new brush preset with the name: "AAA - brush - 444"
    3) - change its size + paint something
    4) - overwrite brush

    5) - quit + start Krita again

    6) - paint something
    7) - change the brush preset size
    8) - overwrite brush

    9) - quit + start

Might it be a naming issue in Windows?
Or maybe a brush preset setting? (just wondering...)
Comment 2 Isaac Zuniga 2018-03-03 16:57:47 UTC
(In reply to mvowada from comment #1)
> Hi isaac,
> 
> I'm not able to reproduce the problem on Linux Ubuntu (Krita 4 beta), with
> the following steps:
> 
> (I understand that the starting brush in the video ("A - 6") has appeared
> after you deleted the blacklist file).
> 
>     1) - new document
> 
>     2) - save new brush preset with the name: "AAA - brush - 444"
>     3) - change its size + paint something
>     4) - overwrite brush
> 
>     5) - quit + start Krita again
> 
>     6) - paint something
>     7) - change the brush preset size
>     8) - overwrite brush
> 
>     9) - quit + start
> 
> Might it be a naming issue in Windows?
> Or maybe a brush preset setting? (just wondering...)

That's a shame that you cannot reproduce it, it may be related to Windows only, as for the naming, I decided to retest it with a brush name that was not so arbitrary. (Notice the "AAA - Brush - 444" in the blacklist file in the beginning, it's still hidden until I delete the blacklist file.)

Google video: https://drive.google.com/file/d/1wQQLjRK1WR8PT_NnehgoXkgU1SrReMB5/view?usp=sharing

I do not believe that it's a naming convention as it has happened to any brush that I create, regardless of its name, since version... 3.3.2? (If memory serves me right.)
Comment 3 mvowada 2018-03-04 11:33:43 UTC
Hi Isaac,

I went through all the steps but I'm still not able to reproduce the issue in Linux Ubuntu, I'm sorry.

Watching the last video I noticed that:

1) overwriting the preset doesn't affect the blacklist file (point 11 below)
2) the presets listed in the blacklist, do not carry the suffix "_backup_(date)" (point 15)

My steps (tried mimicking yours in the video) are:

    1) start Krita

    2) blacklist file has "AAA - brush - 444.kpp"
    3) delete the blacklist file

    4) in Krita pick the preset "deevad 1a eraser thin"

    5) save a new brush with the name "Gene Wilder"
    6) change its size
    7) overwrite

    8) paint (erase)
    9) toggle erase + "Normal" blending + change hue
    10) overwrite

    11) blacklist file not been created (?)
    12) quit + start Krita

    13) paint with "Gene Wilder" + change its size
    14) overwrite

    15) preset blacklisted without suffix "_backup") (?)
    16) quit + start Krita
Comment 4 Isaac Zuniga 2018-03-04 17:16:45 UTC
(In reply to mvowada from comment #3)
> Hi Isaac,
> 
> I went through all the steps but I'm still not able to reproduce the issue
> in Linux Ubuntu, I'm sorry.
> 
> Watching the last video I noticed that:
> 
> 1) overwriting the preset doesn't affect the blacklist file (point 11 below)
> 2) the presets listed in the blacklist, do not carry the suffix
> "_backup_(date)" (point 15)
> 
> My steps (tried mimicking yours in the video) are:
> 
>     1) start Krita
> 
>     2) blacklist file has "AAA - brush - 444.kpp"
>     3) delete the blacklist file
> 
>     4) in Krita pick the preset "deevad 1a eraser thin"
> 
>     5) save a new brush with the name "Gene Wilder"
>     6) change its size
>     7) overwrite
> 
>     8) paint (erase)
>     9) toggle erase + "Normal" blending + change hue
>     10) overwrite
> 
>     11) blacklist file not been created (?)
>     12) quit + start Krita
> 
>     13) paint with "Gene Wilder" + change its size
>     14) overwrite
> 
>     15) preset blacklisted without suffix "_backup") (?)
>     16) quit + start Krita

That's a shame, but I am willing to accept that this may be an incompatibility with the program and Windows 10, especially since I'm running an "insider build", which is like a "Beta version". When the next Windows 10 build comes out for the public, I'll try it and see what happens, though I've been an insider since last March and the program worked just fine then, things broke around November...
Comment 5 Quiralta 2018-03-04 18:33:23 UTC
Modifying a brush "should" create a blacklist file, the problem I've seen in your case is that is omitting (in the blacklist) to append the word "backup" at the end, e.g. erasers.kpp > eraser_backup_2018_03_04.kpp

Modifying a brush also makes an actual copy/copies of the brush in the "paintoppresets" folder (an incremental backup practically).

I myself can not reproduce you issue, thus I wonder if it has to do with the windows build as like mvowada I'm also on Linux, for what its worth you should clean not only the blacklist but all the brushes (and its copies) that you are SURE don't need from the "paintoppresets" folder (if unsure just back up the folder) and try again, just to see that the names are not interfering.
Comment 6 Isaac Zuniga 2018-03-04 21:31:03 UTC
(In reply to Quiralta from comment #5)
> Modifying a brush "should" create a blacklist file, the problem I've seen in
> your case is that is omitting (in the blacklist) to append the word "backup"
> at the end, e.g. erasers.kpp > eraser_backup_2018_03_04.kpp
> 
> Modifying a brush also makes an actual copy/copies of the brush in the
> "paintoppresets" folder (an incremental backup practically).
> 
> I myself can not reproduce you issue, thus I wonder if it has to do with the
> windows build as like mvowada I'm also on Linux, for what its worth you
> should clean not only the blacklist but all the brushes (and its copies)
> that you are SURE don't need from the "paintoppresets" folder (if unsure
> just back up the folder) and try again, just to see that the names are not
> interfering.

I used used disk cleanup, CCleaner and Bleachbit to nuke my computer of all of Krita-related files, the temporary folders, the program folders, registry entries (everything of that nature), so that there can be absolutely NO conflictions this time, and this was the result:

https://drive.google.com/file/d/1ofGPNvIKrmQw4g-wbt9zjx_GUuXs19F-/view?usp=sharing

You can see that I followed through with that, as you can see most of the brushes I had in the other videos are missing, the UI looks like it does when you wipe the %appdata% folders, and so forth. Yet, the issue still remains... Notice how the file is created EXACTLY when I save changes to the newly-created brush...

So, is it safe to assume that Micro$oft did something with this upcoming version of Windows 10 that Krita just does not like?
Comment 7 mvowada 2018-03-06 12:06:42 UTC
Hi. Could we recap (is there any Windows user who can confirm?):

    1) save new preset + modify the size + overwrite = 
       it DOES NOT CREATE the blacklist file

    2) save new preset + "restart" + modify the size + overwrite = 
       it DOES CREATE the blacklist file.

    3) the blacklist file entries are written without the needed suffix (like i.e. "_backup_2018-03-05-12:34:08.kpp").


(Might be related):

    - https://forum.kde.org/viewtopic.php?f=139&t=151226&p=395294&hilit=blacklist#p395294

    - Bug 390159
Comment 8 Alvin Wong 2018-03-06 15:51:03 UTC
Please note that the original report happens with a pretty recent nightly build, not beta1. As there has been a lot of changes since beta1, please try to clarify the versions used to test in each comment, down to the specific git commit.
Comment 9 Isaac Zuniga 2018-03-06 15:54:24 UTC
(In reply to Alvin Wong from comment #8)
> Please note that the original report happens with a pretty recent nightly
> build, not beta1. As there has been a lot of changes since beta1, please try
> to clarify the versions used to test in each comment, down to the specific
> git commit.

I've been able to recreate/having this issue since Krita 3.3.2. right now I'm on the 4.1.0-pre-alpha (git 59675cc).
Comment 10 Alvin Wong 2018-03-06 16:06:52 UTC
Yes, I can reproduce this on Windows krita-nightly-x64-v4.0.0.51-594-gba8550543c
Comment 11 Alvin Wong 2018-03-06 16:08:07 UTC
Created attachment 111224 [details]
Capture with Process Monitor when overwriting the preset

I made a capture with Process Monitor of changes to the files under %AppData%\krita when pressing the overwrite preset button, might give some insight.
Comment 12 Alvin Wong 2018-03-06 16:20:23 UTC
Well, I was about to take a shower but I took a look anyway. The obvious problem is trying to create a file with colons (`:`) in the name, since it is one of the few reserved characters that can't be used in a file name. See https://en.wikipedia.org/wiki/Filename#Reserved_characters_and_words

This is a reminder that date/time in file names should be formatted in something like yyyyMMddHHmmss, yyyy-MM-dd_HHmmss, or just a Unix timestamp.
Comment 13 Isaac Zuniga 2018-03-06 17:08:47 UTC
(In reply to Alvin Wong from comment #12)
> Well, I was about to take a shower but I took a look anyway. The obvious
> problem is trying to create a file with colons (`:`) in the name, since it
> is one of the few reserved characters that can't be used in a file name. See
> https://en.wikipedia.org/wiki/Filename#Reserved_characters_and_words
> 
> This is a reminder that date/time in file names should be formatted in
> something like yyyyMMddHHmmss, yyyy-MM-dd_HHmmss, or just a Unix timestamp.

Do you think a fix will be possible before Krita 4.0's release? Or is this a Krita 4.1 fix at this point?
Comment 14 Alvin Wong 2018-03-06 17:12:31 UTC
Git commit 861444628a91761285736f8a8b8604ff6fce1db7 by Alvin Wong.
Committed on 06/03/2018 at 17:12.
Pushed by alvinwong into branch 'master'.

Do not include column in name when saving backup preset

M  +1    -1    libs/ui/widgets/kis_paintop_presets_save.cpp

https://commits.kde.org/krita/861444628a91761285736f8a8b8604ff6fce1db7
Comment 15 Alvin Wong 2018-03-06 17:12:50 UTC
Git commit 427efb5dc7875efe84906ac5512ce03d800c1389 by Alvin Wong.
Committed on 06/03/2018 at 17:12.
Pushed by alvinwong into branch 'krita/4.0'.

Do not include column in name when saving backup preset

M  +1    -1    libs/ui/widgets/kis_paintop_presets_save.cpp

https://commits.kde.org/krita/427efb5dc7875efe84906ac5512ce03d800c1389