.openhands_instructions 1.1 KB

123456789101112131415161718192021222324252627
  1. OpenHands is an automated AI software engineer. It is a repo with a Python backend
  2. (in the `openhands` directory) and TypeScript frontend (in the `frontend` directory).
  3. General Setup:
  4. - To set up the entire repo, including frontend and backend, run `make build`
  5. Backend:
  6. - Located in the `openhands` directory
  7. - Testing:
  8. - All tests are in `tests/unit/test_*.py`
  9. - To test new code, run `poetry run pytest tests/unit/test_xxx.py` where `xxx` is the appropriate file for the current functionality
  10. - Write all tests with pytest
  11. Frontend:
  12. - Located in the `frontend` directory
  13. - Prerequisites: A recent version of NodeJS / NPM
  14. - Setup: Run `npm install` in the frontend directory
  15. - Testing:
  16. - Run tests: `npm run test`
  17. - To run specific tests: `npm run test -- -t "TestName"`
  18. - Building:
  19. - Build for production: `npm run build`
  20. - Environment Variables:
  21. - Set in `frontend/.env` or as environment variables
  22. - Available variables: VITE_BACKEND_HOST, VITE_USE_TLS, VITE_INSECURE_SKIP_VERIFY, VITE_FRONTEND_PORT
  23. - Internationalization:
  24. - Generate i18n declaration file: `npm run make-i18n`