Skip to content

[Bug]: Leading/trailing whitespace in IP or hostname prevents monitoring from working #212

@kyob

Description

@kyob

Environment

Web Interface / All environments

Bug Description

The application does not sanitize the Target URL/Host input field in the "Create New Service" modal. When a user accidentally includes leading or trailing whitespaces, the service is saved with those spaces, causing the monitoring to fail or remain in an error state. The app should automatically trim whitespaces from the input.

Steps to Reproduce

  1. Click the + NewService button to open the "Create New Service" dialog.
  2. Fill in the Service Name (e.g., "Test Service").
  3. In the Target URL/Host field, enter an address with an accidental space, for example: google.com or 192.168.1.1
  4. Click Create to save the service.
  5. Observe that the monitor fails to function properly because the space is treated as part of the hostname/IP.

Expected Behavior

The application should perform a .trim() on the "Target URL/Host" input before saving. Leading or trailing spaces should be automatically removed so that the monitoring works regardless of accidental keyboard strokes.

Screenshots or Videos

No response

Logs

Checklist

  • I have searched existing issues to avoid creating duplicates.
  • I have provided sufficient information to reproduce the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions