Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: "start from scratch" button results in a "no query provided" error #7621

Open
1 task done
neubig opened this issue Apr 1, 2025 · 2 comments · May be fixed by #7622
Open
1 task done

[Bug]: "start from scratch" button results in a "no query provided" error #7621

neubig opened this issue Apr 1, 2025 · 2 comments · May be fixed by #7622
Labels
bug Something isn't working openhands Have Openhands attempt to fix the issue (via GH App)

Comments

@neubig
Copy link
Contributor

neubig commented Apr 1, 2025

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Describe the bug and reproduction steps

When clicking the "start from scratch" button on the hero page, this results in a "no query provided" toast. Instead, this should send the user to the workspace with no user message so they can start from scratch.

Screen.Recording.2025-04-01.at.9.00.37.AM.mov

OpenHands Installation

app.all-hands.dev

OpenHands Version

No response

Operating System

None

Logs, Errors, Screenshots, and Additional Context

No response

@neubig neubig added bug Something isn't working openhands Have Openhands attempt to fix the issue (via GH App) labels Apr 1, 2025
Copy link

openhands-ai bot commented Apr 1, 2025

I'm on it! @neubig can track my progress at all-hands.dev

Copy link

openhands-ai bot commented Apr 1, 2025

I successfully fixed issue #7621 in the OpenHands repository, which was about the "start from scratch" button resulting in a "no query provided" error.

Summary of Changes

  1. Root Cause Analysis: The issue occurred because the useCreateConversation hook was throwing an error when no query was provided, but the "Start from scratch" button was designed to create a conversation with an empty query.

  2. Solution Implemented:

    • Added an allowEmptyQuery parameter to the useCreateConversation hook to bypass the validation check when explicitly starting from scratch
    • Updated the CodeNotInGitHubLink component to use this new parameter when the "Start from scratch" button is clicked
    • Created comprehensive tests to verify the fix works correctly
  3. Testing:

    • Created unit tests for both the useCreateConversation hook and the CodeNotInGitHubLink component
    • All tests passed successfully, confirming the fix works as expected
  4. Pull Request:

The fix was minimal and focused on the specific issue, allowing users to start from scratch without encountering the error message. The implementation follows the repository's coding standards and includes proper test coverage.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working openhands Have Openhands attempt to fix the issue (via GH App)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant