Skip to content

Commit

Permalink
docs: add github actions gotcha docs
Browse files Browse the repository at this point in the history
  • Loading branch information
TheKevJames committed Apr 14, 2020
1 parent 3071fbb commit b120650
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
14 changes: 14 additions & 0 deletions docs/usage/configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,17 @@ Sample ``.coveralls.yml`` file::
repo_token: mV2Jajb8y3c6AFlcVNagHO20fiZNkXPVy
parallel: true
coveralls_host: https://coveralls.aperture.com

Github Actions Gotcha
---------------------

There's something weird with using Github Actions that we've not yet been able to entirely sort out -- if you find you're getting a 422 error on Github Actions which looks like this::

Could not submit coverage: 422 Client Error: Unprocessable Entity for url: https://coveralls.io/api/v1/jobs

Then you may be able to solve it by ensuring your ``secret`` is named ``COVERALLS_REPO_TOKEN``; it seems like Github Actions may do Magic(tm) to some environment variables based on their name. The following config block seems to work properly::

env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
run: |
coveralls
3 changes: 2 additions & 1 deletion docs/usage/tox.rst
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ All variables:


SemaphoreCI
-------
-----------
::

passenv = SEMAPHORE SEMAPHORE_BUILD_NUMBER BRANCH_NAME PULL_REQUEST_NUMBER
Expand All @@ -109,4 +109,5 @@ All variables:
- ``SEMAPHORE_BUILD_NUMBER``
- ``BRANCH_NAME``
- ``PULL_REQUEST_NUMBER``

.. _tox: https://tox.readthedocs.io/en/latest/

1 comment on commit b120650

@AndreMiras
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have sorted this out AndreMiras/coveralls-python-action@f04ece7
Basically if you want to use GITHUB_TOKEN the payload should be different. And yes I also think this is some hidden coveralls.io magic

Please sign in to comment.