Skip to content

DOC: create shared includes for comparison docs, take II #38837

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from

Conversation

afeld
Copy link
Member

@afeld afeld commented Dec 30, 2020

This is a duplicate of #38771, but instead of defining :tips: in a :suppress: block, it attempts to tell flake8-rst to ignore those warnings. In other words, only one of these pull requests should be merged; the other can be closed.

  • closes #xxxx
  • tests added / passed
  • passes black pandas
  • passes git diff upstream/master -u -- "*.py" | flake8 --diff
  • whatsnew entry

@jreback jreback added the Docs label Dec 30, 2020
@jreback jreback added this to the 1.3 milestone Dec 30, 2020
@jreback
Copy link
Contributor

jreback commented Dec 30, 2020

great. let's see how the ci does.

@afeld
Copy link
Member Author

afeld commented Dec 30, 2020

As expected, it's getting F821 undefined name 'tips' in all those include files that reference that variable. Very possible I just don't know what I'm doing and missed some part of the configuration.

@jorisvandenbossche
Copy link
Member

The doc build is failing because flake8-rst is not installed in that env:

Could not import extension flake8_rst.sphinxext.custom_roles (exception: No module named 'flake8_rst')

Now, for the pre-commit check, that indeed fails.
For me locally, I get the same failure. If I do :flake8-group: Ignore (which ignores the block completely), then it doesn't complain.

Short term, I would maybe just add those */includes/* files to the exclude list of flake8-rst:

pandas/setup.cfg

Lines 51 to 52 in 72ad717

exclude =
doc/source/development/contributing_docstring.rst

And then I would open an issue at https://github.com/kataev/flake8-rst reporting that the :flake8-add-ignore: F821 is not working for this example (it might be a bug in the package).

@afeld
Copy link
Member Author

afeld commented Jan 1, 2021

I would maybe just add those /includes/ files to the exclude list of flake8-rst

Done: #38887 (Sorry for the litany of pull requests; just wanted to make sure the different approaches can be seen independently.)

I would open an issue at https://github.com/kataev/flake8-rst reporting that the :flake8-add-ignore: F821 is not working for this example

Done: flake8-docs/flake8-rst#25

@jreback
Copy link
Contributor

jreback commented Jan 3, 2021

#38887 is before this? should this close?

@afeld
Copy link
Member Author

afeld commented Jan 3, 2021

Closing in favor of #38887.

@afeld afeld closed this Jan 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants