Page MenuHomePhabricator

Run Query Button Should Display Clear Result Status Messages
Closed, ResolvedPublic

Description

Description:
Currently, when users click the "Run Query" button, there is no clear indication of what is happening. If the query succeeds, results appear without confirmation. If it fails, nothing is displayed, leaving users uncertain about the query status. This creates a poor user experience where users cannot distinguish between successful execution, errors, or system unresponsiveness.

Proposed Solution:

  1. Implement Query Status Messaging System:
    • Add a dedicated status message area below the query editor or above results.
    • Display clear, user-friendly messages for all query states:
      • Running: "Running query..." (with loading indicator)
      • Success: "Query executed successfully. Found X results in Y seconds."
      • Error: "Query failed: [specific error message]"
      • Empty Results: "Query executed successfully but returned no results."
  1. Visual Feedback Enhancement:
    • Change the Run Query button to show loading state (spinner, disabled state) during execution.
    • Use color-coded messages: green for success, yellow for warnings, red for errors.
    • Add icons (✓ for success, ⚠️ for warnings, ✗ for errors) for quick visual recognition.
  1. Error Handling Improvements:
    • Parse SPARQL endpoint error responses to extract human-readable error messages.
    • Display relevant error details (e.g., syntax errors, timeout, connection issues).
    • Provide suggestions for common errors (e.g., "Missing PREFIX declaration" or "Invalid variable name").
  1. Accessibility Considerations:
    • Ensure status messages are announced by screen readers.
    • Maintain sufficient color contrast for all message types.
    • Allow users to dismiss messages after they've been read.
  1. Performance Monitoring:
    • Display query execution time for successful queries.
    • Show response size or result count when applicable.
    • Implement timeout warnings for long-running queries.

Benefits:

  • Provides immediate, clear feedback on query execution status.
  • Reduces user confusion about whether queries are running or completed.
  • Helps users debug errors with specific, actionable error messages.
  • Improves accessibility and overall user experience.
  • Builds user confidence in the application's reliability.

Repository: https://github.com/kaliacad/wqsai/issues

Illustration

image.png (648×1 px, 28 KB)

image.png (648×1 px, 34 KB)