aio-libs / aiopg

aiopg is a library for accessing a PostgreSQL database from the asyncio
http://aiopg.readthedocs.io
BSD 2-Clause "Simplified" License
1.4k stars 160 forks source link

Update version regex after blackifying code #867

Closed and-semakin closed 3 years ago

and-semakin commented 3 years ago

What do these changes do?

Fix make docs command to build documentation site locally. It used to fail like this:

$ make doc
cd docs && rm -rf _build/html
cd docs && make html
make[1]: Entering directory '/home/br0ke/git/aiopg/docs'
sphinx-build -b html -d _build/doctrees   . _build/html
Running Sphinx v4.0.3

Configuration error:
There is a programmable error in your configuration file:

Traceback (most recent call last):
  File "/home/br0ke/git/aiopg/.env/lib64/python3.8/site-packages/sphinx/config.py", line 323, in eval_config_file
    exec(code, namespace)
  File "/home/br0ke/git/aiopg/docs/conf.py", line 85, in <module>
    release = get_release()
  File "/home/br0ke/git/aiopg/docs/conf.py", line 29, in get_release
    raise RuntimeError('Cannot find version in aiopg/__init__.py')
RuntimeError: Cannot find version in aiopg/__init__.py

make[1]: *** [Makefile:53: html] Error 2
make[1]: Leaving directory '/home/br0ke/git/aiopg/docs'
make: *** [Makefile:7: doc] Error 2

Are there changes in behavior for the user?

No. This fix is only for maintainers.

Checklist

and-semakin commented 3 years ago

By the way, do you have an idea how the docs are published to the readthedocs? Is it done manually? I don't see anything related in the CI.

@Pliner

codecov[bot] commented 3 years ago

Codecov Report

Merging #867 (51d9d04) into master (849b83e) will not change coverage. The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #867   +/-   ##
=======================================
  Coverage   93.36%   93.36%           
=======================================
  Files          11       11           
  Lines        1568     1568           
  Branches      186      186           
=======================================
  Hits         1464     1464           
  Misses         73       73           
  Partials       31       31           

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 849b83e...51d9d04. Read the comment docs.