DigitalCommons / land-explorer-front-end

React app for the Land Explorer front end
http://landexplorer.cc
GNU Affero General Public License v3.0
1 stars 0 forks source link

Cannot save polygon to layer or map #326

Open lin-d-hop opened 2 months ago

lin-d-hop commented 2 months ago

Clockify to the F&G project

Describe the bug I cannot save a poly to a map or save polys to layers.

I have tried this from two accounts.

To Reproduce Steps to reproduce the behavior:

  1. Create a poly
  2. Edit the poly name
  3. Try to save the map. See error
  4. try to add to a layer. See error.

Expected behaviour I should be able to save polys with names to maps and layers.

Screenshots/GIFs

Screenshot from 2024-07-15 11-22-13 Screenshot from 2024-07-15 11-22-31

Context (please complete the following information):

rogup commented 1 month ago

@lin-d-hop I'm not able to reproduce this. Is this on production?

Looking at the rubbish logs that we currently have, I can see there have been some jsonwebtoken errors recently (although not sure exactly when). Have you tried logging out / doing a hard refresh?

lin-d-hop commented 1 month ago

Yes I have tried those things.

Is there a max length to a poly name? I shortened the length of the name from the required name and it saved ok. The error happened consistently on multiple accounts and browsers (as stated on the issue). But each time with a long name...

rogup commented 1 month ago

@lin-d-hop The max length is 45 characters (not really sure why it's that short, I suppose it was to ensure the UI looks good and to save space). We could increase the limit or add an error message on the front end so the save can't be attempted.

lin-d-hop commented 1 month ago

Yeah we do need to have at least some kind of error. It's silly that I've made that mistake a few times now. TODO for me to update the issue.