mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-04-29 02:24:43 +00:00
commit
365852a442
17 changed files with 41 additions and 87 deletions
|
|
@ -4,11 +4,9 @@ python:
|
|||
- "3.6"
|
||||
- "3.7"
|
||||
- "3.8"
|
||||
- "3.9-dev"
|
||||
- "3.9"
|
||||
jobs:
|
||||
include:
|
||||
- python: "3.6"
|
||||
env: TOXENV=oldbs4
|
||||
- name: flake8
|
||||
env: TOXENV=flake8
|
||||
before_script:
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
#!/usr/bin/python
|
||||
# -*- coding: iso-8859-1 -*-
|
||||
#!/usr/bin/python3
|
||||
# Copyright (C) 2012 Bastian Kleineidam
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
|
|
|
|||
|
|
@ -1,3 +1,11 @@
|
|||
10.0.1 (released 29.1.2021)
|
||||
|
||||
Changes:
|
||||
- Minimum supported version of Beautiful Soup is 4.8.1
|
||||
|
||||
Fixes:
|
||||
- wsgi: Fix failure due to status logging being enabled
|
||||
|
||||
10.0 (released 15.1.2021)
|
||||
|
||||
Features:
|
||||
|
|
|
|||
|
|
@ -56,14 +56,22 @@ Execute ``windows\dist.bat`` to build a binary installer.
|
|||
Release process
|
||||
---------------
|
||||
|
||||
1. make sure tests pass (run `tox`)
|
||||
1. check whether updated translations need committing
|
||||
(`make locale; make -C doc locale; make -C doc man`)
|
||||
|
||||
2. bump AppVersion in `setup.py`, edit `changelog.txt` and commit changes
|
||||
2. bump AppVersion in `setup.py`, edit `changelog.txt`, and if applicable the
|
||||
copyright date in `linkcheck/configuration/__init__.py`
|
||||
|
||||
3. build Python distributions files (`setup.py sdist bdist_wheel`) and upload to PyPI
|
||||
3. confirm tests have passed
|
||||
|
||||
4. tag release (vX.Y.Z)
|
||||
4. submit a pull request
|
||||
|
||||
5. push
|
||||
5. create a new git clone
|
||||
|
||||
6. write release notes on github
|
||||
6. build Python distribution files (`setup.py sdist bdist_wheel`)
|
||||
|
||||
7. check distribution files (`twine check dist/*`) and upload to PyPI (`twine upload dist/*`)
|
||||
|
||||
8. create release (vX.Y.Z) on GitHub (GitHub creates the .tar.gz and .zip archives)
|
||||
|
||||
9. increment AppVersion to vX.Y.Z+1.dev0
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH "LINKCHECKER" "1" "August 22, 2020" "" "LinkChecker"
|
||||
.TH "LINKCHECKER" "1" "Januar 28, 2021" "2021-01-28" "LinkChecker"
|
||||
.SH NAME
|
||||
linkchecker \- Kommandozeilenprogramm zum Prüfen von HTML Dokumenten und Webseiten auf ungültige Verknüpfungen
|
||||
.
|
||||
|
|
@ -563,6 +563,6 @@ LinkChecker benutzt Hauptspeicher für jede zu prüfende URL, die in der Wartesc
|
|||
.SH AUTHOR
|
||||
Bastian Kleineidam <bastian.kleineidam@web.de>
|
||||
.SH COPYRIGHT
|
||||
2000-2014 Bastian Kleineidam
|
||||
2000-2016 Bastian Kleineidam, 2010-2021 LinkChecker Authors
|
||||
.\" Generated by docutils manpage writer.
|
||||
.
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH "LINKCHECKERRC" "5" "Oktober 02, 2020" "2020-10-02" "LinkChecker"
|
||||
.TH "LINKCHECKERRC" "5" "Januar 28, 2021" "2021-01-28" "LinkChecker"
|
||||
.SH NAME
|
||||
linkcheckerrc \- Konfigurationsdatei für LinkChecker
|
||||
.
|
||||
|
|
@ -587,6 +587,6 @@ Die URL %(url)s enthält Leerzeichen am Anfang oder Ende.
|
|||
.SH AUTHOR
|
||||
Bastian Kleineidam <bastian.kleineidam@web.de>
|
||||
.SH COPYRIGHT
|
||||
2000-2016 Bastian Kleineidam, 2010-2020 LinkChecker Authors
|
||||
2000-2016 Bastian Kleineidam, 2010-2021 LinkChecker Authors
|
||||
.\" Generated by docutils manpage writer.
|
||||
.
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH "LINKCHECKER" "1" "September 25, 2020" "2020-09-25" "LinkChecker"
|
||||
.TH "LINKCHECKER" "1" "January 28, 2021" "2021-01-28" "LinkChecker"
|
||||
.SH NAME
|
||||
linkchecker \- command line client to check HTML documents and websites for broken links
|
||||
.
|
||||
|
|
@ -680,6 +680,6 @@ documentation
|
|||
.SH AUTHOR
|
||||
Bastian Kleineidam <bastian.kleineidam@web.de>
|
||||
.SH COPYRIGHT
|
||||
2000-2016 Bastian Kleineidam, 2010-2020 LinkChecker Authors
|
||||
2000-2016 Bastian Kleineidam, 2010-2021 LinkChecker Authors
|
||||
.\" Generated by docutils manpage writer.
|
||||
.
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH "LINKCHECKERRC" "5" "October 02, 2020" "2020-10-02" "LinkChecker"
|
||||
.TH "LINKCHECKERRC" "5" "January 28, 2021" "2021-01-28" "LinkChecker"
|
||||
.SH NAME
|
||||
linkcheckerrc \- configuration file for LinkChecker
|
||||
.
|
||||
|
|
@ -670,6 +670,6 @@ The URL contains leading or trailing whitespace.
|
|||
.SH AUTHOR
|
||||
Bastian Kleineidam <bastian.kleineidam@web.de>
|
||||
.SH COPYRIGHT
|
||||
2000-2016 Bastian Kleineidam, 2010-2020 LinkChecker Authors
|
||||
2000-2016 Bastian Kleineidam, 2010-2021 LinkChecker Authors
|
||||
.\" Generated by docutils manpage writer.
|
||||
.
|
||||
|
|
|
|||
|
|
@ -35,8 +35,8 @@ AppName = configdata.name
|
|||
App = AppName + " " + Version
|
||||
Author = configdata.author
|
||||
HtmlAuthor = Author.replace(' ', ' ')
|
||||
Copyright = "Copyright (C) 2000-2016 Bastian Kleineidam, 2010-2020 " + Author
|
||||
HtmlCopyright = ("Copyright © 2000-2016 Bastian Kleineidam, 2010-2020 "
|
||||
Copyright = "Copyright (C) 2000-2016 Bastian Kleineidam, 2010-2021 " + Author
|
||||
HtmlCopyright = ("Copyright © 2000-2016 Bastian Kleineidam, 2010-2021 "
|
||||
+ HtmlAuthor)
|
||||
HtmlAppInfo = App + ", " + HtmlCopyright
|
||||
Url = configdata.url
|
||||
|
|
@ -208,6 +208,7 @@ class Configuration(dict):
|
|||
self["status"] = True
|
||||
self["status_wait_seconds"] = 5
|
||||
self['logger'] = None
|
||||
self.status_logger = None
|
||||
self.loggers = {}
|
||||
from ..logger import LoggerClasses
|
||||
|
||||
|
|
|
|||
|
|
@ -181,6 +181,7 @@ def get_configuration(form, out):
|
|||
config = configuration.Configuration()
|
||||
config["recursionlevel"] = int(formvalue(form, "level"))
|
||||
config["logger"] = config.logger_new('html', fd=out, encoding=HTML_ENCODING)
|
||||
config["status"] = False
|
||||
config["threads"] = 2
|
||||
if "anchors" in form:
|
||||
config["enabledplugins"].append("AnchorCheck")
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
# required:
|
||||
beautifulsoup4
|
||||
beautifulsoup4 >= 4.8.1
|
||||
requests >= 2.4
|
||||
pyxdg
|
||||
dnspython >= 2.0
|
||||
|
|
|
|||
3
setup.py
3
setup.py
|
|
@ -45,7 +45,7 @@ from distutils import util, log
|
|||
from distutils.core import Distribution
|
||||
|
||||
# the application version
|
||||
AppVersion = "10.0.0"
|
||||
AppVersion = "10.0.1"
|
||||
# the application name
|
||||
AppName = "LinkChecker"
|
||||
Description = "check links in web documents or full websites"
|
||||
|
|
@ -354,6 +354,7 @@ setup(
|
|||
url="https://linkchecker.github.io/linkchecker/",
|
||||
license="GPL",
|
||||
long_description=get_long_description(),
|
||||
long_description_content_type="text/x-rst",
|
||||
distclass=MyDistribution,
|
||||
cmdclass={
|
||||
"install_lib": MyInstallLib,
|
||||
|
|
|
|||
|
|
@ -1,8 +0,0 @@
|
|||
<!-- base without href -->
|
||||
<base target="_top">
|
||||
<!-- meta url -->
|
||||
<META HTTP-equiv="refresh" content="0; url=base2.html">
|
||||
<!-- spaces between key and value -->
|
||||
<a href
|
||||
=
|
||||
"file.html">
|
||||
|
|
@ -1,33 +0,0 @@
|
|||
url file://%(curdir)s/%(datadir)s/all_parts.html
|
||||
cache key file://%(curdir)s/%(datadir)s/all_parts.html
|
||||
real url file://%(curdir)s/%(datadir)s/all_parts.html
|
||||
name %(datadir)s/all_parts.html
|
||||
valid
|
||||
line None
|
||||
col None
|
||||
size 184
|
||||
parent_url
|
||||
page 0
|
||||
|
||||
content_type text/html
|
||||
url base2.html
|
||||
cache key file://%(curdir)s/%(datadir)s/base2.html
|
||||
real url file://%(curdir)s/%(datadir)s/base2.html
|
||||
valid
|
||||
line None
|
||||
col None
|
||||
size 64
|
||||
parent_url file://%(curdir)s/%(datadir)s/all_parts.html
|
||||
page 0
|
||||
content_type text/html
|
||||
|
||||
url file.html
|
||||
cache key file://%(curdir)s/%(datadir)s/file.html
|
||||
real url file://%(curdir)s/%(datadir)s/file.html
|
||||
valid
|
||||
line None
|
||||
col None
|
||||
size 115
|
||||
parent_url file://%(curdir)s/%(datadir)s/all_parts.html
|
||||
page 0
|
||||
content_type text/html
|
||||
|
|
@ -16,14 +16,9 @@
|
|||
"""
|
||||
Test http checking.
|
||||
"""
|
||||
from bs4 import BeautifulSoup
|
||||
import pytest
|
||||
|
||||
from . import LinkCheckTest
|
||||
from . import TestLogger
|
||||
|
||||
bs_has_linenos = BeautifulSoup("<a>", "html.parser").a.sourceline is not None
|
||||
|
||||
|
||||
class AllPartsLogger(TestLogger):
|
||||
logparts = [
|
||||
|
|
@ -51,12 +46,5 @@ class TestAllParts(LinkCheckTest):
|
|||
|
||||
logger = AllPartsLogger
|
||||
|
||||
@pytest.mark.skipif(bs_has_linenos, reason="Beautiful Soup supports line numbers")
|
||||
def test_all_parts(self):
|
||||
self.file_test("all_parts.html")
|
||||
|
||||
@pytest.mark.skipif(
|
||||
not bs_has_linenos, reason="Beautiful Soup does not support line numbers"
|
||||
)
|
||||
def test_all_parts_linenos(self):
|
||||
self.file_test("all_parts_linenos.html")
|
||||
|
|
|
|||
|
|
@ -76,3 +76,4 @@ class TestWsgi(unittest.TestCase):
|
|||
test_response += str_data
|
||||
self.assertEqual(test_status[0], "200 OK")
|
||||
self.assertTrue(b"Generated by LinkChecker" in test_response)
|
||||
self.assertFalse(b"internal error" in test_response)
|
||||
|
|
|
|||
12
tox.ini
12
tox.ini
|
|
@ -1,5 +1,5 @@
|
|||
[tox]
|
||||
envlist = py36, py37, py38, py39, oldbs4
|
||||
envlist = py36, py37, py38, py39
|
||||
|
||||
[base]
|
||||
deps =
|
||||
|
|
@ -22,16 +22,6 @@ commands =
|
|||
setenv =
|
||||
LC_ALL=en_US.utf-8
|
||||
|
||||
[testenv:oldbs4]
|
||||
# test bs4 without line number support
|
||||
basepython = python3
|
||||
deps =
|
||||
beautifulsoup4 < 4.8.1
|
||||
requests >= 2.4
|
||||
pyxdg
|
||||
dnspython >= 2.0
|
||||
{[base]deps}
|
||||
|
||||
[testenv:flake8]
|
||||
deps = flake8
|
||||
skip_install = true
|
||||
|
|
|
|||
Loading…
Reference in a new issue