photopea / photopea

Photopea is online image editor
https://www.Photopea.com
7.39k stars 267 forks source link

Can't UNDO #7164

Open fidlip opened 2 weeks ago

fidlip commented 2 weeks ago

Your Operating System: Ubuntu 24.04.1 (LTS) Your Web Browser: Firefox 129.0 (64-bit) The problem happens in the Incognito Mode, too: don't know, didn't try

This must be done to see the problem

  1. Open large PSD files (I have 4 PSD's, they are 600MB all together)
  2. after many hours of "readonly work" there were many accidental changes in one document (relatively small one - 136MB)
  3. I needed to undo them
  4. only few steps backward was possible
  5. there are still some changes indicated by Photopea
  6. but undo makes nothing

This error shows in console each time I try to undo:

Uncaught TypeError: n.add.TySh is undefined
    aGh https://vecpea.com/code/pp/pp1724065681.js:8335
    JZ https://vecpea.com/code/pp/pp1724065681.js:8345
    r6 https://vecpea.com/code/pp/pp1724065681.js:8295
    K$ https://vecpea.com/code/pp/pp1724065681.js:8756
    VF https://vecpea.com/code/pp/pp1724065681.js:8753
    VF https://vecpea.com/code/pp/pp1724065681.js:16312
    m https://vecpea.com/code/pp/pp1724065681.js:11508
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    AB https://vecpea.com/code/pp/pp1724065681.js:11563

If I clicked directly to first item in changes history (Open), i received this error:

Uncaught TypeError: n.add.TySh is undefined
    aGh https://vecpea.com/code/pp/pp1724065681.js:8335
    JZ https://vecpea.com/code/pp/pp1724065681.js:8345
    r6 https://vecpea.com/code/pp/pp1724065681.js:8295
    K$ https://vecpea.com/code/pp/pp1724065681.js:8756
    VF https://vecpea.com/code/pp/pp1724065681.js:8752
    VF https://vecpea.com/code/pp/pp1724065681.js:16312
    m https://vecpea.com/code/pp/pp1724065681.js:11508
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    m https://vecpea.com/code/pp/pp1724065681.js:11513
    Je https://vecpea.com/code/pp/pp1724065681.js:14907
    RI https://vecpea.com/code/pp/pp1724065681.js:14906
    by https://vecpea.com/code/pp/pp1724065681.js:14904
    Ic https://vecpea.com/code/pp/pp1724065681.js:14900
    Ic https://vecpea.com/code/pp/pp1724065681.js:16657
    update https://vecpea.com/code/pp/pp1724065681.js:16522
    DJ https://vecpea.com/code/pp/pp1724065681.js:16516
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
    F0 https://vecpea.com/code/pp/pp1724065681.js:16192
pp1724065681.js:8335:70
fidlip commented 2 weeks ago

Here is attached content of object n at the moment the error occurred: scratch.json

photopea commented 2 weeks ago

How much RAM do you have? If Photopea runs out of RAM, you can not expect it to work normally.

E.g. if you create a new file, add a fully white layer, and make copies of that layer, sooner or later, after 10 - 100 - 100000 copies of that layer, Photopea will crash.

If you work with huge files and you dont have enough RAM, try to save your work often.

fidlip commented 2 weeks ago

Thank you for reply. I have 48GB totally (+64GB swap). I still have huge amount of free memory to satisfy all PhotoPea potential needs. This doesn't seems to be problem. I don't need to save anything at all. This is just annoying for me as I need to have original version before changes. Always when this happen, I must reopen files again ... and again ... and again. Btw how could help me to save more often? If I save I can't return to state before this save :)

PS: I wouldn't deal with this if Photopea didn't make changes accidentaly just because I selected some layer etc.

photopea commented 2 weeks ago

Can you press More - Peamark, and do the RAM test? It will show how much RAM can Photopea get from your browser.

"I wouldn't deal with this if Photopea didn't make changes accidentaly just because I selected some layer etc." - what do you mean?

fidlip commented 2 weeks ago

Should I close open documents first?

On Wed, Sep 18, 2024 at 7:28 PM Photopea @.***> wrote:

Can you press More - Peamark, and do the RAM test? It will show how much RAM can Photopea get from your browser.

"I wouldn't deal with this if Photopea didn't make changes accidentaly just because I selected some layer etc." - what do you mean?

— Reply to this email directly, view it on GitHub https://github.com/photopea/photopea/issues/7164#issuecomment-2359035745, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABSJTP2V7WXHUUQGJDCFF63ZXGZ4FAVCNFSM6AAAAABONJ2D7CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGNJZGAZTKNZUGU . You are receiving this because you authored the thread.Message ID: @.***>

fidlip commented 2 weeks ago

And what I mean ... sometimes i just click (no mouse movement) on some place to select some layer and Pea ads some strange change to history. For example if i try to select layer near some guide, it do not select layer and ads "Move Guide", you can see this screencast (wihout mouse pointer as I just realized, but hopefully it will be more clear): Screencast from 2024-09-18 20-38-30.webm

photopea commented 2 weeks ago

Your video is very confusing to me. You should tell me how to reproduce the issue, otherwise, it is not helpful to me in any way :(

photopea commented 2 weeks ago

Also, you might be using browser extensions, which modify the functionality of Photoepa. Please, do not report any "issues" which are not in Photopea (Photopea modified by your browser extensions is not Photopea anymore).

fidlip commented 2 weeks ago

Your video is very confusing to me. You should tell me how to reproduce the issue, otherwise, it is not helpful to me in any way :(

Yes, it can be little bit confusing without mouse cursor. I described what happened in previous comment but I am sending next video (stupidly got on phone, sorry for that, but can't capture mouse cursor), so you can see what exactly happening:

https://github.com/user-attachments/assets/416f364d-c49f-4f46-bf30-5334449168ee

Also, you might be using browser extensions, which modify the functionality of Photoepa. Please, do not report any "issues" which are not in Photopea (Photopea modified by your browser extensions is not Photopea anymore).

No, I am not using any extensions in firefox, which could do any modification to Pea. I am using this browser only for PhotoPea (because of Pea has some problems on Chrome).

Can you press More - Peamark, and do the RAM test? It will show how much RAM can Photopea get from your browser.

image

photopea commented 2 weeks ago

It seems like you are moving guides with the Move tool. You can learn about guides here: https://www.photopea.com/learn/guides-grid-snapping If you want to work with text, you need to use the Type tool. It is not clear to me what do you want to happen instead (in your video).

fidlip commented 2 weeks ago

It seems like you are moving guides with the Move tool. You can learn about guides here: https://www.photopea.com/learn/guides-grid-snapping If you want to work with text, you need to use the Type tool. It is not clear to me what do you want to happen instead (in your video).

No, I do not want to use TypeTool. I need to use MoveTool as I need to select any layer and see it's size, css properties, and so on. (That text layer was only example). Here is another video:

https://github.com/user-attachments/assets/858d681d-5c7a-4211-9a28-fe17dc97b58b

You can see that confusing pre-selection of layer (yes I noticed changed mouse cursor now, but I do not notice it during my daily work very often). And when I click (only click, do not move at all) I would expect that layer to be selected. But it is not selected, only change has been added to history.

But ... if you would consider this is also problem, I would create another issue, as this is not the concern of this issue.

photopea commented 2 weeks ago

The move tool works at it should - it should move the guide when your mouse is above the guide. I recommend reading www.photopea.com/learn or buy any book about Adobe Photoshop to learn how to work with Photoshop / Photopea.

If you have any other issue, please, write precise steps which I should follow to see a problem.