Skip to content

tox: clean up docs target#3548

Merged
blueyed merged 1 commit into
pytest-dev:masterfrom
blueyed:fix-docs
Aug 14, 2018
Merged

tox: clean up docs target#3548
blueyed merged 1 commit into
pytest-dev:masterfrom
blueyed:fix-docs

Conversation

@blueyed

@blueyed blueyed commented Jun 7, 2018

Copy link
Copy Markdown
Contributor

OLD DESCRIPTION:
I had to add atomicwrites to deps to fix:

Warning, treated as error:
autodoc: failed to import class 'Mark' from module
'_pytest.mark.structures'; the following exception was raised:
No module named 'atomicwrites'
ERROR: InvocationError for command
'/home/user/Vcs/pytest/.tox/docs/bin/sphinx-build -W -b html . _build'
(exited with code 2)

I do not know why this is not failing on Travis, where atomicwrites gets
installed for some reason [1].
Removing usedevelop = True also fixes it, apparently since then
install_requires from setup.py gets used.

1: https://travis-ci.org/pytest-dev/pytest/jobs/388958175#L470

@coveralls

coveralls commented Jun 7, 2018

Copy link
Copy Markdown

Coverage Status

Coverage increased (+0.05%) to 92.517% when pulling dff7b20 on blueyed:fix-docs into 4705fd2 on pytest-dev:master.

@blueyed

blueyed commented Jun 7, 2018

Copy link
Copy Markdown
Contributor Author

For some reason pip install -e . does not install atomicwrites for me, while pip install . does.

There is no mention of "atomicwrites" with pip install -e ..

@blueyed

blueyed commented Jun 7, 2018

Copy link
Copy Markdown
Contributor Author

Seems to be related to my checkout. It works when using a fresh clone.
Very odd, any ideas?

But apart from that I think this PR might still make sense, at least partly (without the usedevelop removal).

@nicoddemus

Copy link
Copy Markdown
Member

It also works for me here. Perhaps you need to force tox to recreate the environment using tox -r? I've noticed it sometimes doesn't notice that the dependencies changed between master and features checkouts for example. This happened quite a few times with me, using -r always worked then.

@blueyed

blueyed commented Jun 9, 2018

Copy link
Copy Markdown
Contributor Author

I could fix pip install -e for my checkout by moving away
./pytest.egg-info (from 2015-11!).

requires.txt in there contained:

py>=1.5.0
six>=1.10.0
setuptools
attrs>=17.4.0
more-itertools>=4.0.0
pluggy<0.7,>=0.5

[:python_version < "3.0"]
funcsigs

[:sys_platform == "win32"]
colorama

Apparently this gets used instead of install_requires then?!

@nicoddemus

Copy link
Copy Markdown
Member

That I wouldn't know. 😁

@blueyed

blueyed commented Jun 9, 2018

Copy link
Copy Markdown
Contributor Author

Yes, looks like something strange/unexpected with setuptools/pip.

Using pip install -e . now creates ./src/pytest.egg-info instead/only, which existed before already.

Maybe there is something that could be specified in setup.py to make it look in src only for the egg-info?
It looks like this is an issue that arised from moving the code to src
/cc @RonnyPfannschmidt

@RonnyPfannschmidt

Copy link
Copy Markdown
Member

nope, this is and will stay a mess due to setuptools legacy ^^

Comment thread tox.ini

[testenv:docs]
skipsdist = True
usedevelop = True

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

usedevelop should stay

@blueyed

blueyed commented Aug 2, 2018

Copy link
Copy Markdown
Contributor Author

Amended.

@blueyed blueyed changed the title tox: fix docs target tox: clean up docs target Aug 2, 2018
@blueyed

blueyed commented Aug 13, 2018

Copy link
Copy Markdown
Contributor Author

Huh? Why is squash-and-merge in the Github UI not enabled?

@RonnyPfannschmidt

Copy link
Copy Markdown
Member

@blueyed all history editing should be explicit and consensual - squash merge makes it really easy to do it wrong

@blueyed

blueyed commented Aug 14, 2018

Copy link
Copy Markdown
Contributor Author

Well, I disagree - especially with regard to the Github UI.
It is not history editing (of the target branch) at all, but rather that you do not have the merge commit. It is really good for small commits like this, but I won't argue about it.

@blueyed blueyed merged commit b88e09a into pytest-dev:master Aug 14, 2018
@blueyed blueyed deleted the fix-docs branch August 14, 2018 13:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants