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]: Frontend changes cause Python unit tests workflow to fail but not frontend workflow #5343

Closed
1 task done
neubig opened this issue Dec 1, 2024 · 2 comments · Fixed by #5347
Closed
1 task done
Labels
bug Something isn't working fix-me Attempt to fix this issue with OpenHands

Comments

@neubig
Copy link
Contributor

neubig commented Dec 1, 2024

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Describe the bug and reproduction steps

Sometimes changes to the frontend cause Python unit tests to fail, but do not cause the frontend workflows to fail.

Here is an example of workflows from the same commit:

These failures were caused by the typescript changes in this commit: fc6b4af

If we look at the changes in the commit, they are related to the frontend, not related to Python.

Building frontend...

> [email protected] build
> npm run make-i18n && tsc && remix vite:build


> [email protected] make-i18n
> node scripts/make-i18n-translations.cjs

src/components/chat-input.tsx(90,25): error TS18047: 'textareaRef.current' is possibly 'null'.
make[1]: *** [Makefile:188: build-frontend] Error 2
make: *** [Makefile:29: build] Error 2
Error: Process completed with exit code 2.

It shouldn't be the case that frontend changes cause frontend tests to pass but the Python Unit Test workflow to fail. All bad frontend changes should be caught by frontend testing workflows.

To fix this we can gradually create a PR to fix these issues:

  1. carefully read all reference materials, the existing worfklows for "Lint / Lint frontend", "Run Frontend Unit Tests / FE Unit Tests", and "Python Unit Tests", as well as the output of the passing/failed github actions
  2. create a dummy PR that uses the code in the above commit to see if you can reproduce the issue of the Python Unit Tests workflow failing but the frontend tests passing on this small frontend bug
  3. try to fix the existing frontend workflows so that they also fail on this error
  4. revert all changes to the typescript files and make sure that all workflows now pass

OpenHands Installation

Docker command in README

OpenHands Version

No response

Operating System

None

Logs, Errors, Screenshots, and Additional Context

No response

@neubig neubig added bug Something isn't working fix-me Attempt to fix this issue with OpenHands labels Dec 1, 2024
Copy link
Contributor

github-actions bot commented Dec 1, 2024

OpenHands started fixing the issue! You can monitor the progress here.

Copy link
Contributor

github-actions bot commented Dec 1, 2024

A potential fix has been generated and a draft PR #5344 has been created. Please review the changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fix-me Attempt to fix this issue with OpenHands
Projects
None yet
1 participant