SigNoz / signoz

SigNoz is an open-source observability platform native to OpenTelemetry with logs, traces and metrics in a single application. An open-source alternative to DataDog, NewRelic, etc. 🔥 🖥. 👉 Open source Application Performance Monitoring (APM) & Observability tool
https://signoz.io
Other
19.27k stars 1.29k forks source link

[FE]: When attempting to save a view, the application currently allows saving even if the label field is left empty or contains only whitespace. #6445

Open Aarif5435 opened 3 hours ago

Aarif5435 commented 3 hours ago

Bug description

When attempting to save a view, the application currently allows saving even if the label field is left empty or contains only whitespace. This leads to confusion and inconsistent view names in the UI.

Expected behavior

The application should prevent saving a view with an empty label or a label containing only whitespace. An error message should prompt the user to enter a valid label name before proceeding.

How to reproduce

  1. Open the "Save this view" dialog.
  2. Leave the "Label" field empty or enter only spaces.
  3. Click on the "Save this view" button.
  4. Observe that the view is saved despite the empty or whitespace-only label.

Screenshort

https://github.com/user-attachments/assets/78401ca0-3cde-4edb-b691-76d9909086aa

Version information

Additional context

This issue impacts the user experience as it allows views to be saved without meaningful names, making it difficult to identify saved views later. A validation check should be added to ensure that the label field contains non-whitespace characters before allowing the view to be saved.

Thank you for your bug report – we love squashing them!

welcome[bot] commented 3 hours ago

Thanks for opening this issue. A team member should give feedback soon. In the meantime, feel free to check out the contributing guidelines.

Aarif5435 commented 3 hours ago

I have fixed this issue, please have look to the PR. PR:- https://github.com/SigNoz/signoz/pull/6446