Mintplex-Labs / anything-llm

The all-in-one Desktop & Docker AI application with built-in RAG, AI agents, and more.
https://anythingllm.com
MIT License
26.55k stars 2.65k forks source link

Inconsistent workspace name length validation? #1378

Closed jazelly closed 5 months ago

jazelly commented 5 months ago

How are you running AnythingLLM?

All versions

What happened?

in the onboarding flow, the workspace name length is restricted to be minimum 4 characters, while in the sidebar, a user can create a workspace name with any length.

Screenshot 2024-05-13 at 7 12 18 pm

Are there known steps to reproduce?

No response

timothycarambat commented 5 months ago

This is not a "strict" validation. We just wanted to have it to where the workspace name was not just a or something like that. I suppose it could be argued it doesn't make sense and we should permit anything since in the landing page that is also allowed

jazelly commented 5 months ago

@timothycarambat Yes, exactly, I think it's up to the design, but considering the name length has been allowed to be less than 4 characters in the workspace settings page, wouldn't it be kind of breaking backward compatibility by reintroducing that?

So IMHO, probably just remove the workspace length restriction in the onboarding flow. I'm happy to raise a PR to address this trivial change.

timothycarambat commented 5 months ago

IIRC, the reason it every existed is because in like the v0 version of AnythingLLM we did not use slugs for the paths, so there was no guarantee they would be unique. Now, that is long long gone and you can have 40 workspaces all named a and they will get unique slugs so its basically a non-issue now and that limitation can be removed.