#336 Remove outdated sphinxcontrib.issuetracker
Merged 4 years ago by lucarval. Opened 4 years ago by lucarval.

file modified
-40
@@ -42,7 +42,6 @@ 

      'sphinx.ext.napoleon',

      'sphinx.ext.viewcode',

      'sphinxcontrib.autohttp.flask',

-     'sphinxcontrib.issuetracker',

  ]

  

  # Add any paths that contain templates here, relative to this directory.
@@ -194,42 +193,3 @@ 

      'python': ('https://docs.python.org/3/', 'python-intersphinx.inv'),

      'greenwave': ('https://docs.pagure.org/greenwave/', 'greenwave-intersphinx.inv'),

  }

- 

- # Configuration for issue tracker magic linking.

- issuetracker = None

- issuetracker_url = 'https://pagure.io/'

- issuetracker_project = 'waiverdb'

- 

- # Until Pagure support is merged: https://github.com/ignatenkobrain/sphinxcontrib-issuetracker/pull/15

- import requests

- from sphinxcontrib.issuetracker import Issue

- PAGURE_URL = '{0.url}/{0.project}/issue/{1}'

- PAGURE_API_URL = '{0.url}/api/0/{0.project}/issue/{1}'

- HEADERS = {

-     'User-Agent': 'sphinxcontrib-issuetracker'

- }

- def get(app, url):

-     try:

-         response = requests.get(url, headers=HEADERS)

-         if response.status_code == requests.codes.ok:

-             return response

-         elif response.status_code != requests.codes.not_found:

-             msg = 'GET {0.url} failed with code {0.status_code}'

-             app.warn(msg.format(response))

-     except IOError as e:

-         msg = 'GET {0} failed with error: {1}'

-         app.warn(msg.format(url, e))

- def lookup_pagure_issue(app, tracker_config, issue_id):

-     if not tracker_config.url:

-         raise ValueError('URL required, try: https://pagure.io/')

-     issue_url = PAGURE_URL.format(tracker_config, issue_id)

-     response = get(app, PAGURE_API_URL.format(tracker_config, issue_id))

-     if response:

-         title = response.json()['title']

-         closed = response.json()['status'] != 'Open'

-         return Issue(id=issue_id, title=title, closed=closed, url=issue_url)

-     else:

-         return Issue(id=issue_id, title=None, closed=False, url=issue_url)

- 

- def setup(app):

-     app.connect('issuetracker-lookup-issue', lookup_pagure_issue)

file modified
+1 -6
@@ -1,9 +1,5 @@ 

  [tox]

- envlist = flake8,lint,py36

- 

- # Cannot build tox here until this is merged and released

- # https://github.com/ignatenkobrain/sphinxcontrib-issuetracker/pull/13

- # envlist = lint,py36,docs

+ envlist = lint,py36,docs

  

  # If the user is missing an interpreter, don't fail

  skip_missing_interpreters = True
@@ -24,7 +20,6 @@ 

  changedir = docs

  deps =

      -rrequirements.txt

-     sphinxcontrib-issuetracker

  whitelist_externals =

      mkdir

      rm

file modified
+1 -2
@@ -28,7 +28,6 @@ 

  %if %{with server}

  BuildRequires:  python3-sphinx

  BuildRequires:  python3-sphinxcontrib-httpdomain

- BuildRequires:  python3-sphinxcontrib-issuetracker

  BuildRequires:  python3-flask

  BuildRequires:  python3-sqlalchemy

  BuildRequires:  python3-flask-cors
@@ -112,7 +111,7 @@ 

  %build

  %if 0%{?fedora} || 0%{?rhel} > 7

  %py3_build

- make -C docs SPHINXOPTS="-D issuetracker_plaintext_issues=0" html man text

+ make -C docs html man text

  %else

  %py2_build

  %endif

Disable sphinxcontrib-issuetracker integration

This extension appears to no longer be maintained. The following issue
prevents adopting a newer version of Sphinx:
    https://github.com/ignatenkobrain/sphinxcontrib-issuetracker/issues/23
Fix typo in test_api_v10.py
Do not run tests twice

The flake8 environment does not have a corresponding [testenv:flake8]
section in tox.ini. This causes the default [testenv] section to be
used, causing the unit tests to execute twice. The lint environment is
responsible for running flake8.

Build 86951226981ad5fec1a4f336f348ba904f15172f FAILED!
Rebase or make new commits to rebuild.

2 new commits added

  • Do not run tests twice
  • Disable sphinxcontrib-issuetracker integration
4 years ago

+1

This would make issue numbers (#xyz) in release notes just plain text instead of links to issues. But I noticed that we haven't added these in release notes since v0.11.

Jenkins job is no longer updating the docs ( https://docs.pagure.org/waiverdb/release-notes.html#). Is this known issue?

Pull-Request has been merged by lucarval

4 years ago

+1
This would make issue numbers (#xyz) in release notes just plain text instead of links to issues. But I noticed that we haven't added these in release notes since v0.11.
Jenkins job is no longer updating the docs ( https://docs.pagure.org/waiverdb/release-notes.html#). Is this known issue?

I recall previous issues getting the docs to build. There are a few commits that suggest it may have been explicitly disabled:

🐚  git log --oneline | grep docs
17778ae docs: add more detailed release note about subject_type changes
509caca docs: add intersphinx config for linking to Greenwave docs
c30082e docs: add missing reference to #137 in release notes
8e31b9a docs: Fix option reference
00230d6 Merge #158 ` docs: no need for roadmap`
66402d2 Also, disable building docs until it works.
2f1fda2 docs: no need for roadmap
5cbc661 Try to get the docs building again.
7cfe897 update docs to correct the steps of setting up dev env
686f6bf update docs to correct the steps of setting up dev env
3227f31 exclude docs from flake8
2d974e7 docs: add a roadmap document
403831d docs: use sphinxcontrib.issuetracker extension
67a8f11 fix some type errors in the API docs examples
886554d Jenkinsfile: remove the leftover docs-on-pagure directory
425158c skip docs build in EPEL7
44d58ee keep a copy of docs.python.org intersphinx inventory
035a3db include built docs in the RPM, not raw Sphinx sources
557e31e Jenkinsfile: upload built docs to docs.pagure.org
b6fc027 fix docs build
c6c70f9 Jenkinsfile: build docs
7d42f18 Start a Sphinx docs project