Takeshi KOMIYA
114ff77f68
test: Omit master_doc settings from testcases
2019-01-03 10:58:42 +09:00
Takeshi KOMIYA
5428d94d24
Remove coding magic comments from tests
2019-01-02 21:53:07 +09:00
Takeshi KOMIYA
da3075d0b7
A happy new year!
2019-01-02 16:17:25 +09:00
Takeshi KOMIYA
76e9f57c2e
Merge branch '1.8'
2019-01-02 16:16:25 +09:00
Takeshi KOMIYA
1b1ebd2c75
A happy new year!
2019-01-02 16:00:30 +09:00
jfbu
32d57b8637
Merge branch '1.8'
...
resolved Conflicts:
doc/development/tutorials/todo.rst
sphinx/locale/__init__.py
sphinx/search/zh.py
2018-12-28 12:50:20 +01:00
Timotheus Kampik
221614654f
#5605 fix Chinese search index ( #5611 )
...
generate search index for Latin words correctly if search language is Chinese
2018-12-25 18:41:52 +01:00
Takeshi KOMIYA
99a7dca216
Merge pull request #5806 from jdufresne/six-text-type
...
Replace use of six.text_type with str
2018-12-26 01:31:33 +09:00
Takeshi KOMIYA
b5c0edc949
Merge branch '1.8'
2018-12-26 00:37:55 +09:00
Timotheus Kampik
b779975a44
Merge branch 'master' into 5660-version-modified-classes
2018-12-24 14:57:42 +01:00
Takeshi KOMIYA
6ffe549f49
refactor chm_htmlescape()
2018-12-24 13:54:53 +09:00
Timotheus Kampik
edf9d210b6
#5660 adjust expected result to new classes
...
Also, fix formating glitch
2018-12-23 17:02:31 +01:00
Takeshi KOMIYA
4702086681
Merge branch '1.8'
2018-12-24 00:49:36 +09:00
animalize
9052471e19
don't generate build files inside /tests/roots/
2018-12-23 22:16:03 +08:00
animalize
cedd94c541
[1.8] htmlhelp: convert hex escaping to decimal escaping in .hhc/.hhk files ( #5853 )
...
* htmlhelp: convert hex escaping to decimal escaping in .hhc/.hhk files
.hhc/.hhk files don't recognize hex escaping, we need convert hex escaping to decimal escaping. for example: `'` -> `'`.
2018-12-23 22:39:12 +09:00
jfbu
701b39328f
Merge branch '1.8'
...
(Resolved) Conflicts:
sphinx/texinputs/sphinxmanual.cls
2018-12-23 11:23:04 +01:00
Takeshi KOMIYA
f06e84ac4f
Fix #5800 : todo: crashed if todo is defined in TextElement
2018-12-22 01:10:23 +09:00
Jon Dufresne
6978918ffc
Replace use of six.text_type with str
...
This removes the last use of the six package allowing Sphinx to remove
it as a dependency.
2018-12-18 16:23:10 -08:00
Takeshi KOMIYA
3905cb8b7c
Merge branch '1.8'
2018-12-18 23:32:52 +09:00
Takeshi KOMIYA
f04e161173
Merge pull request #5826 from tk0miya/refactor_intersphinx
...
intersphinx: Normalize mapping on config-inited
2018-12-18 23:29:25 +09:00
Takeshi KOMIYA
4c149f6458
Merge pull request #5835 from goerz/1.8
...
Use mathjax CDN "latest" URL by default
2018-12-18 23:07:42 +09:00
jfbu
bd2ca4763c
[tests] LaTeX: use latex engines with `--halt-on-error` option
2018-12-18 13:41:48 +01:00
Michael Goerz
77e617e25a
Use mathjax CDN "latest" URL by default
...
Closes #5725
2018-12-17 22:14:25 -05:00
Jon Dufresne
43ff640b58
Deprecate quickstart.term_decode() and remove internal uses
...
Per the Python 3 docs, input() always returns a string:
https://docs.python.org/3/library/functions.html#input
> The function then reads a line from input, converts it to a
> string (stripping a trailing newline), and returns that.
The stubs from typeshed say the same:
https://github.com/python/typeshed/blob/5c69373890dfaf4f07f0638766fb0a4903352892/stdlib/3/builtins.pyi#L835
Here is the implementation from CPython with also shows a call to
PyUnicode_Decode on the result:
https://github.com/python/cpython/blob/3.7/Python/bltinmodule.c#L1960-L2143
As the value is always a string, there is nothing to decode. Therefore
the call to term_decode() unnecessary and can safely be removed.
With this in mind, must adjust quickstart tests to be more
representative.
2018-12-17 06:44:17 -08:00
Takeshi KOMIYA
556f599e6e
intersphinx: Normalize mapping on config-inited
2018-12-17 22:03:47 +09:00
Takeshi KOMIYA
5e5bdb8a64
Remove absolute_import
2018-12-17 20:47:49 +09:00
Takeshi KOMIYA
8ea3f7fad9
Merge pull request #5509 from stephenfin/remove-future-imports
...
Remove future imports
2018-12-17 20:32:39 +09:00
Takeshi KOMIYA
d8b69c7f98
Merge pull request #5819 from jdufresne/coding-comment
...
Remove unnecessary encoding cookie from Python source files
2018-12-17 19:15:00 +09:00
Jon Dufresne
e9c87b3d13
Fix invalid escape sequence in test_directive_code.py
...
Fixes error when running tests:
tests/test_directive_code.py:359
sphinx/tests/test_directive_code.py:359: DeprecationWarning: invalid escape sequence \s
includes = '\\end{sphinxVerbatim}\n\sphinxresetverbatimhllines\n'
2018-12-17 11:11:41 +01:00
Takeshi KOMIYA
c7ed4f3ddd
Merge pull request #5814 from jdufresne/str-format-coerce
...
Remove redundant coerce to str in string formatting
2018-12-17 19:08:28 +09:00
Takeshi KOMIYA
71a7ce1453
Merge branch 'master' into string-classes
2018-12-17 18:58:32 +09:00
Stephen Finucane
5a9033e5aa
Specifically request Python 3
...
If Sphinx is Python 3-only, Sphinx's tooling should be Python 3-only
too.
Signed-off-by: Stephen Finucane <stephen@that.guru >
2018-12-17 09:46:18 +00:00
Stephen Finucane
d345d0f8c1
py3: Remove (most) __future__ imports
...
There were two used:
- print_function
- absolute_import
Both of these are mandatory in Python 3.0 onwards [1] and can therefore
be removed...mostly. Unfortunately, mypy is still running in Python 2.7
mode, meaning we need the 'print_function' future wherever we're calling
'print' with the 'file' argument. There's also a single
'absolute_import' future that must be retained as its removal breaks a
test for as-yet unknown reasons. TODOs are added to resolve both issues
in the future.
[1] https://docs.python.org/3/library/__future__.html
Signed-off-by: Stephen Finucane <stephen@that.guru >
2018-12-17 09:46:15 +00:00
Jon Dufresne
d210da96f6
Fix invalid escape sequence in test_directive_code.py
...
Fixes error when running tests:
tests/test_directive_code.py:359
sphinx/tests/test_directive_code.py:359: DeprecationWarning: invalid escape sequence \s
includes = '\\end{sphinxVerbatim}\n\sphinxresetverbatimhllines\n'
2018-12-16 13:37:47 -08:00
Jon Dufresne
bade33c7e4
Remove unnecessary encoding cookie from Python source files
...
In Python 3, the default encoding of source files is utf-8. The encoding
cookie is now unnecessary and redundant so remove it. For more details,
see the docs:
https://docs.python.org/3/howto/unicode.html#the-string-type
> The default encoding for Python source code is UTF-8, so you can
> simply include a Unicode character in a string literal ...
Includes a fix for the flake8 header checks to stop expecting an
encoding cookie.
2018-12-16 12:22:12 -08:00
Jon Dufresne
80861d105b
Deprecate sphinx.config.string_classes; remove all internal uses
...
With only a single text type across supported Python versions, the
string_classes is no longer necessary.
Internally, all uses were converted to the value `[str]`. For
.add_config_value() uses that also supply a default string, the type is
inferred.
2018-12-16 11:35:06 -08:00
Jon Dufresne
2b0096fba9
Remove redundant coerce to str in string formatting
...
When an object is passed to a string format placeholder '%s', Python
will implicitly call str() on the object. This applies to print() and
logging as well.
2018-12-16 10:03:45 -08:00
jfbu
30ec4b6bba
Merge branch '1.8'
2018-12-16 18:34:05 +01:00
Jakob Lykke Andersen
73a8b7e658
Merge branch 'cpp_fix_float_literals' into 1.8
2018-12-16 17:19:57 +01:00
Jakob Lykke Andersen
b3de33deef
C++, fix parsing of floating point literals
...
Fixes sphinx-doc/sphinx#5636
2018-12-16 16:56:55 +01:00
jfbu
88a019dc99
LaTeX: allow sphinxVerbatim usage without explicit "hllines" extra setup
...
Fixes : #5810
2018-12-16 16:54:28 +01:00
Takeshi KOMIYA
c6bd84a614
refactor: Remove u-prefix from strings
2018-12-16 21:28:51 +09:00
Takeshi KOMIYA
ea1d2d06f8
Merge pull request #5803 from jdufresne/encoding-utf8
...
Avoid respecifying default encoding for .encode()/.decode() calls
2018-12-16 20:01:43 +09:00
Takeshi KOMIYA
2597c4174e
Merge pull request #5796 from jdufresne/super
...
Use Python 3 super() argument-less syntax
2018-12-16 19:46:47 +09:00
Jon Dufresne
5bf25eb445
Avoid respecifying default encoding for .encode()/.decode() calls
...
In Python 3, both .encode() and .decode() default the encoding to
'utf-8'. See the docs:
https://docs.python.org/3/library/stdtypes.html#str.encode
https://docs.python.org/3/library/stdtypes.html#bytes.decode
Simplify and shorten the code by using the default instead of
respecifying it.
2018-12-15 17:19:56 -08:00
Jon Dufresne
49d3a3c0c1
Replace ENOENT errno checks with Python 3 FileNotFoundError
...
The error is more specific and self documenting.
This removes the last use of sphinx.util.osutil.ENOENT, so it is now
deprecated for removal. sphinx.util.osutil.EEXIST was already unused so
that is deprecated as well.
2018-12-15 09:02:55 -08:00
Jon Dufresne
ade973f4e3
Use Python 3 super() argument-less syntax
...
The form is less verbose and more idiomatic for Python 3 only code.
https://docs.python.org/3/library/functions.html#super
2018-12-15 08:35:55 -08:00
Takeshi KOMIYA
c70e65fc6c
Merge branch 'master' into 5770_doctest_refers_highlight_language
2018-12-16 00:32:10 +09:00
Takeshi KOMIYA
b56f4f9022
Remove print_function feature
2018-12-15 23:16:10 +09:00
Takeshi KOMIYA
415ebc15c5
Merge pull request #5784 from tk0miya/refactor_hack_for_py2
...
Refactor hack for py2
2018-12-15 22:40:46 +09:00