From b4bdbb765965bd9e989fabee7d30559da358c5a4 Mon Sep 17 00:00:00 2001 From: Benjamin Auquite Date: Sun, 26 Mar 2023 15:14:47 -0500 Subject: [PATCH] add testing steps to workflow action in logs. Help the next person running into this issue again. --- .github/workflows/pytest.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/pytest.yaml b/.github/workflows/pytest.yaml index 71e4fd54..66495b48 100644 --- a/.github/workflows/pytest.yaml +++ b/.github/workflows/pytest.yaml @@ -26,8 +26,18 @@ jobs: uses: actions/setup-python@v4.1.0 with: python-version: ${{ matrix.python-version }} + - name: Quick Troubleshooting steps if tests break + run: | + echo "::notice::\n\n\n### If tests fail, try these debug steps: ###\n" + echo "::notice::### 1. Replace '-qq' from .github/workflow/pytest.yaml. with '-v' for extra verbosity. ###" + echo "::notice::### 2. Push again ###" + echo "::notice::### 3. Check for any log messages in github actions resembling the following using CTRL+F ### + echo "::notice::### 4. ERROR:homeassistant.setup:Setup failed for 'component': Unable to import component: No module named ''module'' ###" + echo "::notice::### 5. add 'component'.'module' (without the '') from the above log into the 'required' list inside of 'test_dependencies.py' ###" + echo "::notice::### 6. Try again! The issue should be easily solvable by reading the verbose logs now. ###\n\n\n" - name: Install dependencies run: | + echo "::warning::\n\n ### WARNING! Deprecation warnings muted with option --use-pep517 please address at some point. ###\n\n" pip install -r core/requirements.txt --use-pep517 pip install -r core/requirements_test.txt --use-pep517 pip install -e core/ --use-pep517