Python-checkins
Threads by month
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2005 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2004 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2003 -----
- December
- November
- October
- September
- August
June 2024
- 1 participants
- 770 discussions
gh-121163: Add "all" as an valid alias for "always" in warnings.simplefilter() (#121164)
by vstinner 30 Jun '24
by vstinner 30 Jun '24
30 Jun '24
https://github.com/python/cpython/commit/1a84bdc2371ada60c01c72493caba62c98…
commit: 1a84bdc2371ada60c01c72493caba62c9860007b
branch: main
author: Kirill Podoprigora <kirill.bast9(a)mail.ru>
committer: vstinner <vstinner(a)python.org>
date: 2024-06-30T19:48:00+02:00
summary:
gh-121163: Add "all" as an valid alias for "always" in warnings.simplefilter() (#121164)
Add support for ``all`` as an valid alias for ``always`` in ``warnings.simplefilter()``
and ``warnings.filterswarnings()``.
files:
A Misc/NEWS.d/next/Library/2024-06-29-19-30-15.gh-issue-121163.SJKDFq.rst
M Doc/library/warnings.rst
M Lib/test/test_warnings/__init__.py
M Lib/warnings.py
M Python/_warnings.c
diff --git a/Doc/library/warnings.rst b/Doc/library/warnings.rst
index c66e65abee426f..68b9ff5ce2f78c 100644
--- a/Doc/library/warnings.rst
+++ b/Doc/library/warnings.rst
@@ -145,6 +145,8 @@ the disposition of the match. Each entry is a tuple of the form (*action*,
+---------------+----------------------------------------------+
| ``"always"`` | always print matching warnings |
+---------------+----------------------------------------------+
+ | ``"all"`` | alias to "always" |
+ +---------------+----------------------------------------------+
| ``"module"`` | print the first occurrence of matching |
| | warnings for each module where the warning |
| | is issued (regardless of line number) |
diff --git a/Lib/test/test_warnings/__init__.py b/Lib/test/test_warnings/__init__.py
index 36618d509fafe1..f9b2b07fbd6576 100644
--- a/Lib/test/test_warnings/__init__.py
+++ b/Lib/test/test_warnings/__init__.py
@@ -155,40 +155,42 @@ def f():
f()
self.assertEqual(len(w), 1)
- def test_always(self):
- with original_warnings.catch_warnings(record=True,
- module=self.module) as w:
- self.module.resetwarnings()
- self.module.filterwarnings("always", category=UserWarning)
- message = "FilterTests.test_always"
- def f():
- self.module.warn(message, UserWarning)
- f()
- self.assertEqual(len(w), 1)
- self.assertEqual(w[-1].message.args[0], message)
- f()
- self.assertEqual(len(w), 2)
- self.assertEqual(w[-1].message.args[0], message)
+ def test_always_and_all(self):
+ for mode in {"always", "all"}:
+ with original_warnings.catch_warnings(record=True,
+ module=self.module) as w:
+ self.module.resetwarnings()
+ self.module.filterwarnings(mode, category=UserWarning)
+ message = "FilterTests.test_always_and_all"
+ def f():
+ self.module.warn(message, UserWarning)
+ f()
+ self.assertEqual(len(w), 1)
+ self.assertEqual(w[-1].message.args[0], message)
+ f()
+ self.assertEqual(len(w), 2)
+ self.assertEqual(w[-1].message.args[0], message)
- def test_always_after_default(self):
- with original_warnings.catch_warnings(record=True,
- module=self.module) as w:
- self.module.resetwarnings()
- message = "FilterTests.test_always_after_ignore"
- def f():
- self.module.warn(message, UserWarning)
- f()
- self.assertEqual(len(w), 1)
- self.assertEqual(w[-1].message.args[0], message)
- f()
- self.assertEqual(len(w), 1)
- self.module.filterwarnings("always", category=UserWarning)
- f()
- self.assertEqual(len(w), 2)
- self.assertEqual(w[-1].message.args[0], message)
- f()
- self.assertEqual(len(w), 3)
- self.assertEqual(w[-1].message.args[0], message)
+ def test_always_and_all_after_default(self):
+ for mode in {"always", "all"}:
+ with original_warnings.catch_warnings(record=True,
+ module=self.module) as w:
+ self.module.resetwarnings()
+ message = "FilterTests.test_always_and_all_after_ignore"
+ def f():
+ self.module.warn(message, UserWarning)
+ f()
+ self.assertEqual(len(w), 1)
+ self.assertEqual(w[-1].message.args[0], message)
+ f()
+ self.assertEqual(len(w), 1)
+ self.module.filterwarnings(mode, category=UserWarning)
+ f()
+ self.assertEqual(len(w), 2)
+ self.assertEqual(w[-1].message.args[0], message)
+ f()
+ self.assertEqual(len(w), 3)
+ self.assertEqual(w[-1].message.args[0], message)
def test_default(self):
with original_warnings.catch_warnings(record=True,
diff --git a/Lib/warnings.py b/Lib/warnings.py
index 20a39d54bf7e6a..d344ceaebb0378 100644
--- a/Lib/warnings.py
+++ b/Lib/warnings.py
@@ -132,7 +132,7 @@ def filterwarnings(action, message="", category=Warning, module="", lineno=0,
append=False):
"""Insert an entry into the list of warnings filters (at the front).
- 'action' -- one of "error", "ignore", "always", "default", "module",
+ 'action' -- one of "error", "ignore", "always", "all", "default", "module",
or "once"
'message' -- a regex that the warning message must match
'category' -- a class that the warning must be a subclass of
@@ -140,7 +140,7 @@ def filterwarnings(action, message="", category=Warning, module="", lineno=0,
'lineno' -- an integer line number, 0 matches all warnings
'append' -- if true, append to the list of filters
"""
- if action not in {"error", "ignore", "always", "default", "module", "once"}:
+ if action not in {"error", "ignore", "always", "all", "default", "module", "once"}:
raise ValueError(f"invalid action: {action!r}")
if not isinstance(message, str):
raise TypeError("message must be a string")
@@ -171,13 +171,13 @@ def simplefilter(action, category=Warning, lineno=0, append=False):
"""Insert a simple entry into the list of warnings filters (at the front).
A simple filter matches all modules and messages.
- 'action' -- one of "error", "ignore", "always", "default", "module",
+ 'action' -- one of "error", "ignore", "always", "all", "default", "module",
or "once"
'category' -- a class that the warning must be a subclass of
'lineno' -- an integer line number, 0 matches all warnings
'append' -- if true, append to the list of filters
"""
- if action not in {"error", "ignore", "always", "default", "module", "once"}:
+ if action not in {"error", "ignore", "always", "all", "default", "module", "once"}:
raise ValueError(f"invalid action: {action!r}")
if not isinstance(lineno, int):
raise TypeError("lineno must be an int")
@@ -248,8 +248,7 @@ def _setoption(arg):
def _getaction(action):
if not action:
return "default"
- if action == "all": return "always" # Alias
- for a in ('default', 'always', 'ignore', 'module', 'once', 'error'):
+ for a in ('default', 'always', 'all', 'ignore', 'module', 'once', 'error'):
if a.startswith(action):
return a
raise _OptionError("invalid action: %r" % (action,))
@@ -397,7 +396,7 @@ def warn_explicit(message, category, filename, lineno,
if onceregistry.get(oncekey):
return
onceregistry[oncekey] = 1
- elif action == "always":
+ elif action in {"always", "all"}:
pass
elif action == "module":
registry[key] = 1
@@ -690,7 +689,7 @@ def extract():
# filters contains a sequence of filter 5-tuples
# The components of the 5-tuple are:
-# - an action: error, ignore, always, default, module, or once
+# - an action: error, ignore, always, all, default, module, or once
# - a compiled regex that must match the warning message
# - a class representing the warning category
# - a compiled regex that must match the module that is being warned
diff --git a/Misc/NEWS.d/next/Library/2024-06-29-19-30-15.gh-issue-121163.SJKDFq.rst b/Misc/NEWS.d/next/Library/2024-06-29-19-30-15.gh-issue-121163.SJKDFq.rst
new file mode 100644
index 00000000000000..029838030278a6
--- /dev/null
+++ b/Misc/NEWS.d/next/Library/2024-06-29-19-30-15.gh-issue-121163.SJKDFq.rst
@@ -0,0 +1,3 @@
+Add support for ``all`` as an valid ``action`` for :func:`warnings.simplefilter`
+and :func:`warnings.filterswarnings`.
+
diff --git a/Python/_warnings.c b/Python/_warnings.c
index 17404d33c1cc9b..3f9e73b5376223 100644
--- a/Python/_warnings.c
+++ b/Python/_warnings.c
@@ -704,9 +704,9 @@ warn_explicit(PyThreadState *tstate, PyObject *category, PyObject *message,
}
/* Store in the registry that we've been here, *except* when the action
- is "always". */
+ is "always" or "all". */
rc = 0;
- if (!_PyUnicode_EqualToASCIIString(action, "always")) {
+ if (!_PyUnicode_EqualToASCIIString(action, "always") && !_PyUnicode_EqualToASCIIString(action, "all")) {
if (registry != NULL && registry != Py_None &&
PyDict_SetItem(registry, key, Py_True) < 0)
{
1
0
[3.13] [doc] Update element positions and styles in logging flow diagram. (GH-121182) (GH-121183)
by vsajip 30 Jun '24
by vsajip 30 Jun '24
30 Jun '24
https://github.com/python/cpython/commit/af89237c9c1bdcda7915ea195b279734f7…
commit: af89237c9c1bdcda7915ea195b279734f7ebddf2
branch: 3.13
author: Miss Islington (bot) <31488909+miss-islington(a)users.noreply.github.com>
committer: vsajip <vinay_sajip(a)yahoo.co.uk>
date: 2024-06-30T15:06:27+01:00
summary:
[3.13] [doc] Update element positions and styles in logging flow diagram. (GH-121182) (GH-121183)
(cherry picked from commit 2a455bbe8fd91a688ae20509a2fdc8beaa8c8447)
files:
M Doc/howto/logging_flow.svg
diff --git a/Doc/howto/logging_flow.svg b/Doc/howto/logging_flow.svg
index 52206bdbcf503b..a5f656b1df0b42 100644
--- a/Doc/howto/logging_flow.svg
+++ b/Doc/howto/logging_flow.svg
@@ -1,281 +1,304 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/PR-SVG-20010719/DTD/svg10.dtd">
<svg width="22cm" height="23cm" viewBox="1 1 439 446" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-
<!-- Invert color in dark mode -->
<style type="text/css">
- @media (prefers-color-scheme: dark)
- {
- svg {
- filter: invert(93%) hue-rotate(180deg);
- background-color: transparent !important;
+ svg {
+ background-color: transparent !important;
+ }
+ line {
+ stroke: #000000;
+ fill: none;
+ stroke-opacity: 1;
+ }
+ polygon, rect {
+ fill: none;
+ stroke: #000000;
+ fill-opacity: 1;
+ stroke-opacity: 1;
+ }
+ polygon.filled {
+ fill: #ff0000;
+ }
+ polyline {
+ fill: none;
+ stroke-opacity: 1;
+ stroke: #000000;
}
- image {
- filter: invert(100%) hue-rotate(180deg) saturate(1.25);
+ text {
+ fill: #000000;
+ fill-opacity: 1;
+ stroke: none;
+ font-family: sans-serif;
+ font-style: normal;
+ font-weight: normal;
+ text-anchor: start;
+ }
+ @media (prefers-color-scheme: dark) {
+ polygon, rect, polyline, line {
+ stroke: #ffffff;
+ }
+ text {
+ fill: #ffffff;
+ }
+ image {
+ filter: invert(100%) hue-rotate(180deg) saturate(1.25);
+ }
}
- }
</style>
- <defs/>
+ <defs />
<g id="Background">
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.8; stroke-dasharray: 3; stroke: #000000" x="227.504" y="1.91011" width="211.607" height="207.375" rx="0" ry="0"/>
- <rect style="fill: #000000; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.2; stroke: #000000" x="230.966" y="5.62454" width="68.4216" height="21.9166" rx="0" ry="0"/>
- <rect style="fill: #000000; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.2; stroke: #000000" x="5.27912" y="5.70399" width="68.4216" height="21.9166" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:700" x="17.0649" y="19.0071">
+ <rect style="stroke-width: 1.8; stroke-dasharray: 3;" x="227.504" y="1.91011" width="211.607" height="207.375" rx="0" ry="0" />
+ <rect style="stroke-width: 1.2;" x="230.966" y="5.62454" width="68.4216" height="21.9166" rx="0" ry="0" />
+ <rect style="stroke-width: 1.2;" x="5.27912" y="5.70399" width="68.4216" height="21.9166" rx="0" ry="0" />
+ <text font-size="6.77333" style="font-weight: 700;" x="17.0649" y="19.0071">
<tspan x="17.0649" y="19.0071">Logger flow</tspan>
</text>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="81.5533" y="106.469" width="44.45" height="25.9333" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="117.256">
+ <rect x="81.5533" y="106.469" width="44.45" height="25.9333" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="117.256">
<tspan x="103.778" y="117.256">Create</tspan>
<tspan x="103.778" y="125.723">LogRecord</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="82.8734" x2="103.778" y2="102.351"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,105.351 101.778,101.351 103.778,102.351 105.778,101.351 "/>
+ <line x1="103.778" y1="82.8734" x2="103.778" y2="102.351" />
+ <polygon fill-rule="evenodd" points="103.778,105.351 101.778,101.351 103.778,102.351 105.778,101.351 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.774" y1="3.65583" x2="103.778" y2="30.3755"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,33.3755 101.778,29.3758 103.778,30.3755 105.778,29.3752 "/>
+ <line x1="103.774" y1="3.65583" x2="103.778" y2="30.3755" />
+ <polygon fill-rule="evenodd" points="103.778,33.3755 101.778,29.3758 103.778,30.3755 105.778,29.3752 " />
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="164.792" y="43.0505">
- <tspan x="164.792" y="43.0505"></tspan>
- </text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="236.978" y="43.0505">
- <tspan x="236.978" y="43.0505"></tspan>
- </text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="144.365" y="10.4604">
- <tspan x="144.365" y="10.4604">Logging call in user</tspan>
- <tspan x="144.365" y="18.927">code, e.g.</tspan>
+ <text font-size="6.77333" style="text-anchor: middle;" x="144.365" y="10.4604">
+ <tspan x="143.798" y="10.4604">Logging call in user</tspan>
+ <tspan x="143.798" y="18.927">code, e.g.</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:monospace;font-style:normal;font-weight:normal" x="110.837" y="27.4696">
- <tspan x="110.837" y="27.4696">logging.info(...)</tspan>
+ <text font-size="6.77333" style="font-family: monospace;" x="110.837" y="27.4696">
+ <tspan x="111.893" y="27.4696">logger.info(...)</tspan>
</text>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="155.62" y1="58.6834" x2="183.943" y2="58.6924"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="186.943,58.6933 182.942,60.6921 183.943,58.6924 182.943,56.6921 "/>
+ <line x1="155.62" y1="58.6834" x2="183.943" y2="58.6924" />
+ <polygon fill-rule="evenodd" points="186.943,58.6933 182.942,60.6921 183.943,58.6924 182.943,56.6921 " />
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="188.061" y="49.9604" width="24.4" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="200.261" y="60.7475">
+ <rect x="188.061" y="49.9604" width="24.4" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="200.261" y="60.7475">
<tspan x="200.261" y="60.7475">Stop</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,162.482 169.307,193.042 103.778,223.603 38.2493,193.042 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="186.629">
- <tspan x="103.778" y="186.629">Does a filter attached</tspan>
- <tspan x="103.778" y="195.096">to logger reject the</tspan>
- <tspan x="103.778" y="203.563">record?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,162.482 169.307,193.042 103.778,223.603 38.2493,193.042 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="186.629">
+ <tspan x="103.778" y="188.741">Does a filter attached</tspan>
+ <tspan x="103.778" y="197.208">to logger reject the</tspan>
+ <tspan x="103.778" y="205.675">record?</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="132.402" x2="103.778" y2="158.364"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,161.364 101.778,157.364 103.778,158.364 105.778,157.364 "/>
+ <line x1="103.778" y1="132.402" x2="103.778" y2="158.364" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,161.364 101.778,157.364 103.778,158.364 105.778,157.364 " />
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="75.2033" y="249.478" width="57.15" height="34.4" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="260.265">
+ <rect x="75.2033" y="249.478" width="57.15" height="34.4" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="260.265">
<tspan x="103.778" y="260.265">Pass to</tspan>
<tspan x="103.778" y="268.732">handlers of</tspan>
<tspan x="103.778" y="277.198">current logger</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,326.569 158.193,352.399 103.778,378.229 49.3637,352.399 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="350.22">
- <tspan x="103.778" y="350.22">Is propagate true for</tspan>
- <tspan x="103.778" y="358.686">current logger?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,326.569 158.193,352.399 103.778,378.229 49.3637,352.399 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="350.22">
+ <tspan x="103.778" y="351.276">Is propagate true for</tspan>
+ <tspan x="103.778" y="359.742">current logger?</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,399.9 150.573,422.994 103.778,446.087 56.984,422.994 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="420.814">
- <tspan x="103.778" y="420.814">Is there a parent</tspan>
- <tspan x="103.778" y="429.281">logger?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,399.9 150.573,422.994 103.778,446.087 56.984,422.994 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="420.814">
+ <tspan x="103.778" y="422.926">Is there a parent</tspan>
+ <tspan x="103.778" y="431.393">logger?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="2.43852" y="295.984" width="63.9" height="26.5909" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="34.3885" y="307.1">
+ <rect x="2.43852" y="295.984" width="63.9" height="26.5909" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="34.3885" y="307.1">
<tspan x="34.3885" y="307.1">Set current</tspan>
<tspan x="34.3885" y="315.566">logger to parent</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="278.422,240.202 330.96,266.686 278.422,293.169 225.885,266.686 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="278.422" y="264.506">
- <tspan x="278.422" y="264.506">At least one handler</tspan>
- <tspan x="278.422" y="272.973">in hierarchy?</tspan>
+ <polygon fill-rule="evenodd" points="278.422,240.202 330.96,266.686 278.422,293.169 225.885,266.686 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="278.422" y="264.506">
+ <tspan x="278.422" y="266.618">At least one handler</tspan>
+ <tspan x="278.422" y="275.085">in hierarchy?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="298.963" y="312.257" width="57.75" height="25.9333" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="327.838" y="323.044">
- <tspan x="327.838" y="323.044">Use lastResort</tspan>
- <tspan x="327.838" y="331.511">handler</tspan>
+ <rect x="298.963" y="312.257" width="57.75" height="25.9333" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="327.838" y="323.044">
+ <tspan x="327.838" y="324.100">Use lastResort</tspan>
+ <tspan x="327.838" y="332.567">handler</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,35.7307 373.377,60.8536 320.041,85.9765 266.704,60.8536 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="58.6741">
+ <polygon fill-rule="evenodd" points="320.041,35.7307 373.377,60.8536 320.041,85.9765 266.704,60.8536 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="58.6741">
<tspan x="320.041" y="58.6741">Handler enabled for</tspan>
<tspan x="320.041" y="67.1407">level of LogRecord?</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,105.448 386.002,135.748 320.041,166.047 254.08,135.748 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="129.335">
- <tspan x="320.041" y="129.335">Does a filter attached</tspan>
- <tspan x="320.041" y="137.802">to handler reject the</tspan>
- <tspan x="320.041" y="146.268">record?</tspan>
+ <polygon fill-rule="evenodd" points="320.041,105.448 386.002,135.748 320.041,166.047 254.08,135.748 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="129.335">
+ <tspan x="320.041" y="132.508">Does a filter attached</tspan>
+ <tspan x="320.041" y="140.970">to handler reject the</tspan>
+ <tspan x="320.041" y="149.436">record?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="409.532" y="52.4436" width="24.4" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="421.732" y="63.2307">
+ <rect x="409.532" y="52.4436" width="24.4" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="421.732" y="63.2307">
<tspan x="421.732" y="63.2307">Stop</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="271.091" y="185.519" width="97.9" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="196.306">
+ <rect x="271.091" y="185.519" width="97.9" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="196.306">
<tspan x="320.041" y="196.306">Emit (includes formatting)</tspan>
</text>
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:700" x="241.002" y="18.9277">
+ <text font-size="6.77333" style="font-weight: 700;" x="241.002" y="18.9277">
<tspan x="241.002" y="18.9277">Handler flow</tspan>
</text>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,34.4935 155.62,58.6834 103.778,82.8734 51.9368,58.6834 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="56.5039">
- <tspan x="103.778" y="56.5039">Logger enabled for</tspan>
- <tspan x="103.778" y="64.9705">level of call?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,34.4935 155.62,58.6834 103.778,82.8734 51.9368,58.6834 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="56.5039">
+ <tspan x="103.778" y="57.560">Logger enabled for</tspan>
+ <tspan x="103.778" y="66.026">level of call?</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="223.603" x2="103.778" y2="245.36"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,248.36 101.778,244.36 103.778,245.36 105.778,244.36 "/>
+ <line x1="103.778" y1="223.603" x2="103.778" y2="245.36" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,248.36 101.778,244.36 103.778,245.36 105.778,244.36 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="283.878" x2="103.778" y2="322.451"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,325.451 101.778,321.451 103.778,322.451 105.778,321.451 "/>
+ <line x1="103.778" y1="283.878" x2="103.778" y2="322.451" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,325.451 101.778,321.451 103.778,322.451 105.778,321.451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="378.229" x2="103.778" y2="395.782"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,398.782 101.778,394.782 103.778,395.782 105.778,394.782 "/>
+ <line x1="103.778" y1="378.229" x2="103.778" y2="395.782" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,398.782 101.778,394.782 103.778,395.782 105.778,394.782 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="56.984,422.994 34.3885,422.994 34.3885,326.693 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="34.3885,323.693 36.3885,327.693 34.3885,326.693 32.3885,327.693 "/>
+ <polyline points="56.984,422.994 34.3885,422.994 34.3885,326.693 " />
+ <polygon class="filled" fill-rule="evenodd" points="34.3885,323.693 36.3885,327.693 34.3885,326.693 32.3885,327.693 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="34.3885,295.984 34.3885,266.678 71.0853,266.678 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="74.0853,266.678 70.0853,268.678 71.0853,266.678 70.0853,264.678 "/>
+ <polyline points="34.3885,295.984 34.3885,266.678 71.0853,266.678 " />
+ <polygon class="filled" fill-rule="evenodd" points="74.0853,266.678 70.0853,268.678 71.0853,266.678 70.0853,264.678 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="150.573,422.994 200.261,422.994 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="150.573,422.994 200.261,422.994 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" x1="132.353" y1="266.678" x2="221.767" y2="266.685"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="224.767,266.686 220.766,268.685 221.767,266.685 220.767,264.685 "/>
+ <line style="stroke-dasharray: 5" x1="132.353" y1="266.678" x2="221.767" y2="266.685" />
+ <polygon class="filled" fill-rule="evenodd" points="224.767,266.686 220.766,268.685 221.767,266.685 220.767,264.685 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" points="278.422,293.169 278.422,325.224 294.845,325.224 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="297.845,325.224 293.845,327.224 294.845,325.224 293.845,323.224 "/>
+ <polyline style="stroke-dasharray: 5" points="278.422,293.169 278.422,325.224 294.845,325.224 " />
+ <polygon class="filled" fill-rule="evenodd" points="297.845,325.224 293.845,327.224 294.845,325.224 293.845,323.224 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="169.307,193.042 200.261,193.042 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="169.307,193.042 200.261,193.042 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="158.193,352.399 200.261,352.399 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="158.193,352.399 200.261,352.399 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="319.981" y1="4.27261" x2="320.033" y2="31.6127"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.039,34.6127 318.031,30.6165 320.033,31.6127 322.031,30.6089 "/>
+ <line x1="319.981" y1="4.27261" x2="320.033" y2="31.6127" />
+ <polygon class="filled" fill-rule="evenodd" points="320.039,34.6127 318.031,30.6165 320.033,31.6127 322.031,30.6089 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="320.041" y1="85.9765" x2="320.041" y2="101.33"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,104.33 318.041,100.33 320.041,101.33 322.041,100.33 "/>
+ <line x1="320.041" y1="85.9765" x2="320.041" y2="101.33" />
+ <polygon class="filled" fill-rule="evenodd" points="320.041,104.33 318.041,100.33 320.041,101.33 322.041,100.33 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="320.041" y1="166.047" x2="320.041" y2="181.401"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,184.401 318.041,180.401 320.041,181.401 322.041,180.401 "/>
+ <line x1="320.041" y1="166.047" x2="320.041" y2="181.401" />
+ <polygon class="filled" fill-rule="evenodd" points="320.041,184.401 318.041,180.401 320.041,181.401 322.041,180.401 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="386.002,135.748 421.732,135.748 421.732,74.0283 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="421.732,71.0283 423.732,75.0283 421.732,74.0283 419.732,75.0283 "/>
+ <polyline points="386.002,135.748 421.732,135.748 421.732,74.0283 " />
+ <polygon class="filled" fill-rule="evenodd" points="421.732,71.0283 423.732,75.0283 421.732,74.0283 419.732,75.0283 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="373.377" y1="60.8536" x2="405.415" y2="61.1401"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="408.414,61.1669 404.397,63.1311 405.415,61.1401 404.433,59.1312 "/>
+ <line x1="373.377" y1="60.8536" x2="405.415" y2="61.1401" />
+ <polygon class="filled" fill-rule="evenodd" points="408.414,61.1669 404.397,63.1311 405.415,61.1401 404.433,59.1312 " />
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="164.96" y="55.5649">
+ <text font-size="6.77333" x="164.96" y="55.5649">
<tspan x="164.96" y="55.5649">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="106.571" y="97.8453">
+ <text font-size="6.77333" x="106.571" y="97.8453">
<tspan x="106.571" y="97.8453">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="173.856" y="188.452">
+ <text font-size="6.77333" x="173.856" y="188.452">
<tspan x="173.856" y="188.452">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="107.446" y="239.221">
+ <text font-size="6.77333" x="107.446" y="239.221">
<tspan x="107.446" y="239.221">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="174.731" y="349.418">
+ <text font-size="6.77333" x="174.731" y="349.418">
<tspan x="174.731" y="349.418">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="106.571" y="390.507">
+ <text font-size="6.77333" x="106.571" y="390.507">
<tspan x="106.571" y="390.507">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="39.4722" y="417.667">
+ <text font-size="6.77333" x="39.4722" y="417.667">
<tspan x="39.4722" y="417.667">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="174.731" y="417.667">
+ <text font-size="6.77333" x="174.731" y="417.667">
<tspan x="174.731" y="417.667">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="281.451" y="313.406">
+ <text font-size="6.77333" x="281.451" y="313.406">
<tspan x="281.451" y="313.406">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.909" y="263.96">
+ <text font-size="6.77333" x="333.909" y="263.96">
<tspan x="333.909" y="263.96">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="385.766" y="56.9098">
+ <text font-size="6.77333" x="385.766" y="56.9098">
<tspan x="385.766" y="56.9098">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="397.102" y="130.471">
+ <text font-size="6.77333" x="397.102" y="130.471">
<tspan x="397.102" y="130.471">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="323.563" y="178.785">
+ <text font-size="6.77333" x="323.563" y="178.785">
<tspan x="323.563" y="178.785">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="323.75" y="99.0042">
+ <text font-size="6.77333" x="323.75" y="99.0042">
<tspan x="323.75" y="99.0042">Yes</tspan>
</text>
- <text font-size="6.77323" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="355.762" y="18.2449">
+ <text font-size="6.77323" style="text-anchor: middle;" x="355.762" y="18.2449">
<tspan x="355.762" y="18.2449">LogRecord passed</tspan>
<tspan x="355.762" y="26.7116">to handler</tspan>
</text>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" x1="330.96" y1="266.686" x2="377.733" y2="267.908"/>
+ <line style="stroke-dasharray: 5" x1="330.96" y1="266.686" x2="377.733" y2="267.908" />
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" points="356.713,325.224 377.733,325.224 377.733,214.711 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="377.733,211.711 379.733,215.711 377.733,214.711 375.733,215.711 "/>
+ <polyline style="fill: none; stroke-opacity: 1; stroke-dasharray: 5" points="356.713,325.224 377.733,325.224 377.733,214.711 " />
+ <polygon class="filled" fill-rule="evenodd" points="377.733,211.711 379.733,215.711 377.733,214.711 375.733,215.711 " />
</g>
</g>
</svg>
1
0
[3.12] [doc] Update element positions and styles in logging flow diagram. (GH-121182) (GH-121184)
by vsajip 30 Jun '24
by vsajip 30 Jun '24
30 Jun '24
https://github.com/python/cpython/commit/99bc8589f09e66682a52df1f1a9598c705…
commit: 99bc8589f09e66682a52df1f1a9598c7056d49dd
branch: 3.12
author: Miss Islington (bot) <31488909+miss-islington(a)users.noreply.github.com>
committer: vsajip <vinay_sajip(a)yahoo.co.uk>
date: 2024-06-30T14:53:10+01:00
summary:
[3.12] [doc] Update element positions and styles in logging flow diagram. (GH-121182) (GH-121184)
(cherry picked from commit 2a455bbe8fd91a688ae20509a2fdc8beaa8c8447)
files:
M Doc/howto/logging_flow.svg
diff --git a/Doc/howto/logging_flow.svg b/Doc/howto/logging_flow.svg
index 52206bdbcf503b..a5f656b1df0b42 100644
--- a/Doc/howto/logging_flow.svg
+++ b/Doc/howto/logging_flow.svg
@@ -1,281 +1,304 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/PR-SVG-20010719/DTD/svg10.dtd">
<svg width="22cm" height="23cm" viewBox="1 1 439 446" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-
<!-- Invert color in dark mode -->
<style type="text/css">
- @media (prefers-color-scheme: dark)
- {
- svg {
- filter: invert(93%) hue-rotate(180deg);
- background-color: transparent !important;
+ svg {
+ background-color: transparent !important;
+ }
+ line {
+ stroke: #000000;
+ fill: none;
+ stroke-opacity: 1;
+ }
+ polygon, rect {
+ fill: none;
+ stroke: #000000;
+ fill-opacity: 1;
+ stroke-opacity: 1;
+ }
+ polygon.filled {
+ fill: #ff0000;
+ }
+ polyline {
+ fill: none;
+ stroke-opacity: 1;
+ stroke: #000000;
}
- image {
- filter: invert(100%) hue-rotate(180deg) saturate(1.25);
+ text {
+ fill: #000000;
+ fill-opacity: 1;
+ stroke: none;
+ font-family: sans-serif;
+ font-style: normal;
+ font-weight: normal;
+ text-anchor: start;
+ }
+ @media (prefers-color-scheme: dark) {
+ polygon, rect, polyline, line {
+ stroke: #ffffff;
+ }
+ text {
+ fill: #ffffff;
+ }
+ image {
+ filter: invert(100%) hue-rotate(180deg) saturate(1.25);
+ }
}
- }
</style>
- <defs/>
+ <defs />
<g id="Background">
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.8; stroke-dasharray: 3; stroke: #000000" x="227.504" y="1.91011" width="211.607" height="207.375" rx="0" ry="0"/>
- <rect style="fill: #000000; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.2; stroke: #000000" x="230.966" y="5.62454" width="68.4216" height="21.9166" rx="0" ry="0"/>
- <rect style="fill: #000000; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.2; stroke: #000000" x="5.27912" y="5.70399" width="68.4216" height="21.9166" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:700" x="17.0649" y="19.0071">
+ <rect style="stroke-width: 1.8; stroke-dasharray: 3;" x="227.504" y="1.91011" width="211.607" height="207.375" rx="0" ry="0" />
+ <rect style="stroke-width: 1.2;" x="230.966" y="5.62454" width="68.4216" height="21.9166" rx="0" ry="0" />
+ <rect style="stroke-width: 1.2;" x="5.27912" y="5.70399" width="68.4216" height="21.9166" rx="0" ry="0" />
+ <text font-size="6.77333" style="font-weight: 700;" x="17.0649" y="19.0071">
<tspan x="17.0649" y="19.0071">Logger flow</tspan>
</text>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="81.5533" y="106.469" width="44.45" height="25.9333" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="117.256">
+ <rect x="81.5533" y="106.469" width="44.45" height="25.9333" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="117.256">
<tspan x="103.778" y="117.256">Create</tspan>
<tspan x="103.778" y="125.723">LogRecord</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="82.8734" x2="103.778" y2="102.351"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,105.351 101.778,101.351 103.778,102.351 105.778,101.351 "/>
+ <line x1="103.778" y1="82.8734" x2="103.778" y2="102.351" />
+ <polygon fill-rule="evenodd" points="103.778,105.351 101.778,101.351 103.778,102.351 105.778,101.351 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.774" y1="3.65583" x2="103.778" y2="30.3755"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,33.3755 101.778,29.3758 103.778,30.3755 105.778,29.3752 "/>
+ <line x1="103.774" y1="3.65583" x2="103.778" y2="30.3755" />
+ <polygon fill-rule="evenodd" points="103.778,33.3755 101.778,29.3758 103.778,30.3755 105.778,29.3752 " />
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="164.792" y="43.0505">
- <tspan x="164.792" y="43.0505"></tspan>
- </text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="236.978" y="43.0505">
- <tspan x="236.978" y="43.0505"></tspan>
- </text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="144.365" y="10.4604">
- <tspan x="144.365" y="10.4604">Logging call in user</tspan>
- <tspan x="144.365" y="18.927">code, e.g.</tspan>
+ <text font-size="6.77333" style="text-anchor: middle;" x="144.365" y="10.4604">
+ <tspan x="143.798" y="10.4604">Logging call in user</tspan>
+ <tspan x="143.798" y="18.927">code, e.g.</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:monospace;font-style:normal;font-weight:normal" x="110.837" y="27.4696">
- <tspan x="110.837" y="27.4696">logging.info(...)</tspan>
+ <text font-size="6.77333" style="font-family: monospace;" x="110.837" y="27.4696">
+ <tspan x="111.893" y="27.4696">logger.info(...)</tspan>
</text>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="155.62" y1="58.6834" x2="183.943" y2="58.6924"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="186.943,58.6933 182.942,60.6921 183.943,58.6924 182.943,56.6921 "/>
+ <line x1="155.62" y1="58.6834" x2="183.943" y2="58.6924" />
+ <polygon fill-rule="evenodd" points="186.943,58.6933 182.942,60.6921 183.943,58.6924 182.943,56.6921 " />
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="188.061" y="49.9604" width="24.4" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="200.261" y="60.7475">
+ <rect x="188.061" y="49.9604" width="24.4" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="200.261" y="60.7475">
<tspan x="200.261" y="60.7475">Stop</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,162.482 169.307,193.042 103.778,223.603 38.2493,193.042 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="186.629">
- <tspan x="103.778" y="186.629">Does a filter attached</tspan>
- <tspan x="103.778" y="195.096">to logger reject the</tspan>
- <tspan x="103.778" y="203.563">record?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,162.482 169.307,193.042 103.778,223.603 38.2493,193.042 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="186.629">
+ <tspan x="103.778" y="188.741">Does a filter attached</tspan>
+ <tspan x="103.778" y="197.208">to logger reject the</tspan>
+ <tspan x="103.778" y="205.675">record?</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="132.402" x2="103.778" y2="158.364"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,161.364 101.778,157.364 103.778,158.364 105.778,157.364 "/>
+ <line x1="103.778" y1="132.402" x2="103.778" y2="158.364" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,161.364 101.778,157.364 103.778,158.364 105.778,157.364 " />
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="75.2033" y="249.478" width="57.15" height="34.4" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="260.265">
+ <rect x="75.2033" y="249.478" width="57.15" height="34.4" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="260.265">
<tspan x="103.778" y="260.265">Pass to</tspan>
<tspan x="103.778" y="268.732">handlers of</tspan>
<tspan x="103.778" y="277.198">current logger</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,326.569 158.193,352.399 103.778,378.229 49.3637,352.399 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="350.22">
- <tspan x="103.778" y="350.22">Is propagate true for</tspan>
- <tspan x="103.778" y="358.686">current logger?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,326.569 158.193,352.399 103.778,378.229 49.3637,352.399 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="350.22">
+ <tspan x="103.778" y="351.276">Is propagate true for</tspan>
+ <tspan x="103.778" y="359.742">current logger?</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,399.9 150.573,422.994 103.778,446.087 56.984,422.994 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="420.814">
- <tspan x="103.778" y="420.814">Is there a parent</tspan>
- <tspan x="103.778" y="429.281">logger?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,399.9 150.573,422.994 103.778,446.087 56.984,422.994 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="420.814">
+ <tspan x="103.778" y="422.926">Is there a parent</tspan>
+ <tspan x="103.778" y="431.393">logger?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="2.43852" y="295.984" width="63.9" height="26.5909" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="34.3885" y="307.1">
+ <rect x="2.43852" y="295.984" width="63.9" height="26.5909" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="34.3885" y="307.1">
<tspan x="34.3885" y="307.1">Set current</tspan>
<tspan x="34.3885" y="315.566">logger to parent</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="278.422,240.202 330.96,266.686 278.422,293.169 225.885,266.686 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="278.422" y="264.506">
- <tspan x="278.422" y="264.506">At least one handler</tspan>
- <tspan x="278.422" y="272.973">in hierarchy?</tspan>
+ <polygon fill-rule="evenodd" points="278.422,240.202 330.96,266.686 278.422,293.169 225.885,266.686 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="278.422" y="264.506">
+ <tspan x="278.422" y="266.618">At least one handler</tspan>
+ <tspan x="278.422" y="275.085">in hierarchy?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="298.963" y="312.257" width="57.75" height="25.9333" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="327.838" y="323.044">
- <tspan x="327.838" y="323.044">Use lastResort</tspan>
- <tspan x="327.838" y="331.511">handler</tspan>
+ <rect x="298.963" y="312.257" width="57.75" height="25.9333" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="327.838" y="323.044">
+ <tspan x="327.838" y="324.100">Use lastResort</tspan>
+ <tspan x="327.838" y="332.567">handler</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,35.7307 373.377,60.8536 320.041,85.9765 266.704,60.8536 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="58.6741">
+ <polygon fill-rule="evenodd" points="320.041,35.7307 373.377,60.8536 320.041,85.9765 266.704,60.8536 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="58.6741">
<tspan x="320.041" y="58.6741">Handler enabled for</tspan>
<tspan x="320.041" y="67.1407">level of LogRecord?</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,105.448 386.002,135.748 320.041,166.047 254.08,135.748 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="129.335">
- <tspan x="320.041" y="129.335">Does a filter attached</tspan>
- <tspan x="320.041" y="137.802">to handler reject the</tspan>
- <tspan x="320.041" y="146.268">record?</tspan>
+ <polygon fill-rule="evenodd" points="320.041,105.448 386.002,135.748 320.041,166.047 254.08,135.748 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="129.335">
+ <tspan x="320.041" y="132.508">Does a filter attached</tspan>
+ <tspan x="320.041" y="140.970">to handler reject the</tspan>
+ <tspan x="320.041" y="149.436">record?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="409.532" y="52.4436" width="24.4" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="421.732" y="63.2307">
+ <rect x="409.532" y="52.4436" width="24.4" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="421.732" y="63.2307">
<tspan x="421.732" y="63.2307">Stop</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="271.091" y="185.519" width="97.9" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="196.306">
+ <rect x="271.091" y="185.519" width="97.9" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="196.306">
<tspan x="320.041" y="196.306">Emit (includes formatting)</tspan>
</text>
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:700" x="241.002" y="18.9277">
+ <text font-size="6.77333" style="font-weight: 700;" x="241.002" y="18.9277">
<tspan x="241.002" y="18.9277">Handler flow</tspan>
</text>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,34.4935 155.62,58.6834 103.778,82.8734 51.9368,58.6834 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="56.5039">
- <tspan x="103.778" y="56.5039">Logger enabled for</tspan>
- <tspan x="103.778" y="64.9705">level of call?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,34.4935 155.62,58.6834 103.778,82.8734 51.9368,58.6834 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="56.5039">
+ <tspan x="103.778" y="57.560">Logger enabled for</tspan>
+ <tspan x="103.778" y="66.026">level of call?</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="223.603" x2="103.778" y2="245.36"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,248.36 101.778,244.36 103.778,245.36 105.778,244.36 "/>
+ <line x1="103.778" y1="223.603" x2="103.778" y2="245.36" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,248.36 101.778,244.36 103.778,245.36 105.778,244.36 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="283.878" x2="103.778" y2="322.451"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,325.451 101.778,321.451 103.778,322.451 105.778,321.451 "/>
+ <line x1="103.778" y1="283.878" x2="103.778" y2="322.451" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,325.451 101.778,321.451 103.778,322.451 105.778,321.451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="378.229" x2="103.778" y2="395.782"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,398.782 101.778,394.782 103.778,395.782 105.778,394.782 "/>
+ <line x1="103.778" y1="378.229" x2="103.778" y2="395.782" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,398.782 101.778,394.782 103.778,395.782 105.778,394.782 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="56.984,422.994 34.3885,422.994 34.3885,326.693 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="34.3885,323.693 36.3885,327.693 34.3885,326.693 32.3885,327.693 "/>
+ <polyline points="56.984,422.994 34.3885,422.994 34.3885,326.693 " />
+ <polygon class="filled" fill-rule="evenodd" points="34.3885,323.693 36.3885,327.693 34.3885,326.693 32.3885,327.693 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="34.3885,295.984 34.3885,266.678 71.0853,266.678 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="74.0853,266.678 70.0853,268.678 71.0853,266.678 70.0853,264.678 "/>
+ <polyline points="34.3885,295.984 34.3885,266.678 71.0853,266.678 " />
+ <polygon class="filled" fill-rule="evenodd" points="74.0853,266.678 70.0853,268.678 71.0853,266.678 70.0853,264.678 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="150.573,422.994 200.261,422.994 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="150.573,422.994 200.261,422.994 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" x1="132.353" y1="266.678" x2="221.767" y2="266.685"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="224.767,266.686 220.766,268.685 221.767,266.685 220.767,264.685 "/>
+ <line style="stroke-dasharray: 5" x1="132.353" y1="266.678" x2="221.767" y2="266.685" />
+ <polygon class="filled" fill-rule="evenodd" points="224.767,266.686 220.766,268.685 221.767,266.685 220.767,264.685 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" points="278.422,293.169 278.422,325.224 294.845,325.224 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="297.845,325.224 293.845,327.224 294.845,325.224 293.845,323.224 "/>
+ <polyline style="stroke-dasharray: 5" points="278.422,293.169 278.422,325.224 294.845,325.224 " />
+ <polygon class="filled" fill-rule="evenodd" points="297.845,325.224 293.845,327.224 294.845,325.224 293.845,323.224 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="169.307,193.042 200.261,193.042 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="169.307,193.042 200.261,193.042 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="158.193,352.399 200.261,352.399 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="158.193,352.399 200.261,352.399 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="319.981" y1="4.27261" x2="320.033" y2="31.6127"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.039,34.6127 318.031,30.6165 320.033,31.6127 322.031,30.6089 "/>
+ <line x1="319.981" y1="4.27261" x2="320.033" y2="31.6127" />
+ <polygon class="filled" fill-rule="evenodd" points="320.039,34.6127 318.031,30.6165 320.033,31.6127 322.031,30.6089 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="320.041" y1="85.9765" x2="320.041" y2="101.33"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,104.33 318.041,100.33 320.041,101.33 322.041,100.33 "/>
+ <line x1="320.041" y1="85.9765" x2="320.041" y2="101.33" />
+ <polygon class="filled" fill-rule="evenodd" points="320.041,104.33 318.041,100.33 320.041,101.33 322.041,100.33 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="320.041" y1="166.047" x2="320.041" y2="181.401"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,184.401 318.041,180.401 320.041,181.401 322.041,180.401 "/>
+ <line x1="320.041" y1="166.047" x2="320.041" y2="181.401" />
+ <polygon class="filled" fill-rule="evenodd" points="320.041,184.401 318.041,180.401 320.041,181.401 322.041,180.401 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="386.002,135.748 421.732,135.748 421.732,74.0283 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="421.732,71.0283 423.732,75.0283 421.732,74.0283 419.732,75.0283 "/>
+ <polyline points="386.002,135.748 421.732,135.748 421.732,74.0283 " />
+ <polygon class="filled" fill-rule="evenodd" points="421.732,71.0283 423.732,75.0283 421.732,74.0283 419.732,75.0283 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="373.377" y1="60.8536" x2="405.415" y2="61.1401"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="408.414,61.1669 404.397,63.1311 405.415,61.1401 404.433,59.1312 "/>
+ <line x1="373.377" y1="60.8536" x2="405.415" y2="61.1401" />
+ <polygon class="filled" fill-rule="evenodd" points="408.414,61.1669 404.397,63.1311 405.415,61.1401 404.433,59.1312 " />
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="164.96" y="55.5649">
+ <text font-size="6.77333" x="164.96" y="55.5649">
<tspan x="164.96" y="55.5649">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="106.571" y="97.8453">
+ <text font-size="6.77333" x="106.571" y="97.8453">
<tspan x="106.571" y="97.8453">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="173.856" y="188.452">
+ <text font-size="6.77333" x="173.856" y="188.452">
<tspan x="173.856" y="188.452">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="107.446" y="239.221">
+ <text font-size="6.77333" x="107.446" y="239.221">
<tspan x="107.446" y="239.221">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="174.731" y="349.418">
+ <text font-size="6.77333" x="174.731" y="349.418">
<tspan x="174.731" y="349.418">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="106.571" y="390.507">
+ <text font-size="6.77333" x="106.571" y="390.507">
<tspan x="106.571" y="390.507">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="39.4722" y="417.667">
+ <text font-size="6.77333" x="39.4722" y="417.667">
<tspan x="39.4722" y="417.667">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="174.731" y="417.667">
+ <text font-size="6.77333" x="174.731" y="417.667">
<tspan x="174.731" y="417.667">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="281.451" y="313.406">
+ <text font-size="6.77333" x="281.451" y="313.406">
<tspan x="281.451" y="313.406">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.909" y="263.96">
+ <text font-size="6.77333" x="333.909" y="263.96">
<tspan x="333.909" y="263.96">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="385.766" y="56.9098">
+ <text font-size="6.77333" x="385.766" y="56.9098">
<tspan x="385.766" y="56.9098">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="397.102" y="130.471">
+ <text font-size="6.77333" x="397.102" y="130.471">
<tspan x="397.102" y="130.471">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="323.563" y="178.785">
+ <text font-size="6.77333" x="323.563" y="178.785">
<tspan x="323.563" y="178.785">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="323.75" y="99.0042">
+ <text font-size="6.77333" x="323.75" y="99.0042">
<tspan x="323.75" y="99.0042">Yes</tspan>
</text>
- <text font-size="6.77323" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="355.762" y="18.2449">
+ <text font-size="6.77323" style="text-anchor: middle;" x="355.762" y="18.2449">
<tspan x="355.762" y="18.2449">LogRecord passed</tspan>
<tspan x="355.762" y="26.7116">to handler</tspan>
</text>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" x1="330.96" y1="266.686" x2="377.733" y2="267.908"/>
+ <line style="stroke-dasharray: 5" x1="330.96" y1="266.686" x2="377.733" y2="267.908" />
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" points="356.713,325.224 377.733,325.224 377.733,214.711 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="377.733,211.711 379.733,215.711 377.733,214.711 375.733,215.711 "/>
+ <polyline style="fill: none; stroke-opacity: 1; stroke-dasharray: 5" points="356.713,325.224 377.733,325.224 377.733,214.711 " />
+ <polygon class="filled" fill-rule="evenodd" points="377.733,211.711 379.733,215.711 377.733,214.711 375.733,215.711 " />
</g>
</g>
</svg>
1
0
30 Jun '24
https://github.com/python/cpython/commit/2a455bbe8fd91a688ae20509a2fdc8beaa…
commit: 2a455bbe8fd91a688ae20509a2fdc8beaa8c8447
branch: main
author: Vinay Sajip <vinay_sajip(a)yahoo.co.uk>
committer: vsajip <vinay_sajip(a)yahoo.co.uk>
date: 2024-06-30T14:38:49+01:00
summary:
[doc] Update element positions and styles in logging flow diagram. (GH-121182)
Update element positions and styles.
files:
M Doc/howto/logging_flow.svg
diff --git a/Doc/howto/logging_flow.svg b/Doc/howto/logging_flow.svg
index 52206bdbcf503b..a5f656b1df0b42 100644
--- a/Doc/howto/logging_flow.svg
+++ b/Doc/howto/logging_flow.svg
@@ -1,281 +1,304 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/PR-SVG-20010719/DTD/svg10.dtd">
<svg width="22cm" height="23cm" viewBox="1 1 439 446" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-
<!-- Invert color in dark mode -->
<style type="text/css">
- @media (prefers-color-scheme: dark)
- {
- svg {
- filter: invert(93%) hue-rotate(180deg);
- background-color: transparent !important;
+ svg {
+ background-color: transparent !important;
+ }
+ line {
+ stroke: #000000;
+ fill: none;
+ stroke-opacity: 1;
+ }
+ polygon, rect {
+ fill: none;
+ stroke: #000000;
+ fill-opacity: 1;
+ stroke-opacity: 1;
+ }
+ polygon.filled {
+ fill: #ff0000;
+ }
+ polyline {
+ fill: none;
+ stroke-opacity: 1;
+ stroke: #000000;
}
- image {
- filter: invert(100%) hue-rotate(180deg) saturate(1.25);
+ text {
+ fill: #000000;
+ fill-opacity: 1;
+ stroke: none;
+ font-family: sans-serif;
+ font-style: normal;
+ font-weight: normal;
+ text-anchor: start;
+ }
+ @media (prefers-color-scheme: dark) {
+ polygon, rect, polyline, line {
+ stroke: #ffffff;
+ }
+ text {
+ fill: #ffffff;
+ }
+ image {
+ filter: invert(100%) hue-rotate(180deg) saturate(1.25);
+ }
}
- }
</style>
- <defs/>
+ <defs />
<g id="Background">
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.8; stroke-dasharray: 3; stroke: #000000" x="227.504" y="1.91011" width="211.607" height="207.375" rx="0" ry="0"/>
- <rect style="fill: #000000; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.2; stroke: #000000" x="230.966" y="5.62454" width="68.4216" height="21.9166" rx="0" ry="0"/>
- <rect style="fill: #000000; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1.2; stroke: #000000" x="5.27912" y="5.70399" width="68.4216" height="21.9166" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:700" x="17.0649" y="19.0071">
+ <rect style="stroke-width: 1.8; stroke-dasharray: 3;" x="227.504" y="1.91011" width="211.607" height="207.375" rx="0" ry="0" />
+ <rect style="stroke-width: 1.2;" x="230.966" y="5.62454" width="68.4216" height="21.9166" rx="0" ry="0" />
+ <rect style="stroke-width: 1.2;" x="5.27912" y="5.70399" width="68.4216" height="21.9166" rx="0" ry="0" />
+ <text font-size="6.77333" style="font-weight: 700;" x="17.0649" y="19.0071">
<tspan x="17.0649" y="19.0071">Logger flow</tspan>
</text>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="81.5533" y="106.469" width="44.45" height="25.9333" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="117.256">
+ <rect x="81.5533" y="106.469" width="44.45" height="25.9333" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="117.256">
<tspan x="103.778" y="117.256">Create</tspan>
<tspan x="103.778" y="125.723">LogRecord</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="82.8734" x2="103.778" y2="102.351"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,105.351 101.778,101.351 103.778,102.351 105.778,101.351 "/>
+ <line x1="103.778" y1="82.8734" x2="103.778" y2="102.351" />
+ <polygon fill-rule="evenodd" points="103.778,105.351 101.778,101.351 103.778,102.351 105.778,101.351 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.774" y1="3.65583" x2="103.778" y2="30.3755"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,33.3755 101.778,29.3758 103.778,30.3755 105.778,29.3752 "/>
+ <line x1="103.774" y1="3.65583" x2="103.778" y2="30.3755" />
+ <polygon fill-rule="evenodd" points="103.778,33.3755 101.778,29.3758 103.778,30.3755 105.778,29.3752 " />
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="164.792" y="43.0505">
- <tspan x="164.792" y="43.0505"></tspan>
- </text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="236.978" y="43.0505">
- <tspan x="236.978" y="43.0505"></tspan>
- </text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="144.365" y="10.4604">
- <tspan x="144.365" y="10.4604">Logging call in user</tspan>
- <tspan x="144.365" y="18.927">code, e.g.</tspan>
+ <text font-size="6.77333" style="text-anchor: middle;" x="144.365" y="10.4604">
+ <tspan x="143.798" y="10.4604">Logging call in user</tspan>
+ <tspan x="143.798" y="18.927">code, e.g.</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:monospace;font-style:normal;font-weight:normal" x="110.837" y="27.4696">
- <tspan x="110.837" y="27.4696">logging.info(...)</tspan>
+ <text font-size="6.77333" style="font-family: monospace;" x="110.837" y="27.4696">
+ <tspan x="111.893" y="27.4696">logger.info(...)</tspan>
</text>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="155.62" y1="58.6834" x2="183.943" y2="58.6924"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="186.943,58.6933 182.942,60.6921 183.943,58.6924 182.943,56.6921 "/>
+ <line x1="155.62" y1="58.6834" x2="183.943" y2="58.6924" />
+ <polygon fill-rule="evenodd" points="186.943,58.6933 182.942,60.6921 183.943,58.6924 182.943,56.6921 " />
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="188.061" y="49.9604" width="24.4" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="200.261" y="60.7475">
+ <rect x="188.061" y="49.9604" width="24.4" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="200.261" y="60.7475">
<tspan x="200.261" y="60.7475">Stop</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,162.482 169.307,193.042 103.778,223.603 38.2493,193.042 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="186.629">
- <tspan x="103.778" y="186.629">Does a filter attached</tspan>
- <tspan x="103.778" y="195.096">to logger reject the</tspan>
- <tspan x="103.778" y="203.563">record?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,162.482 169.307,193.042 103.778,223.603 38.2493,193.042 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="186.629">
+ <tspan x="103.778" y="188.741">Does a filter attached</tspan>
+ <tspan x="103.778" y="197.208">to logger reject the</tspan>
+ <tspan x="103.778" y="205.675">record?</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="132.402" x2="103.778" y2="158.364"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,161.364 101.778,157.364 103.778,158.364 105.778,157.364 "/>
+ <line x1="103.778" y1="132.402" x2="103.778" y2="158.364" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,161.364 101.778,157.364 103.778,158.364 105.778,157.364 " />
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="75.2033" y="249.478" width="57.15" height="34.4" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="260.265">
+ <rect x="75.2033" y="249.478" width="57.15" height="34.4" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="260.265">
<tspan x="103.778" y="260.265">Pass to</tspan>
<tspan x="103.778" y="268.732">handlers of</tspan>
<tspan x="103.778" y="277.198">current logger</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,326.569 158.193,352.399 103.778,378.229 49.3637,352.399 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="350.22">
- <tspan x="103.778" y="350.22">Is propagate true for</tspan>
- <tspan x="103.778" y="358.686">current logger?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,326.569 158.193,352.399 103.778,378.229 49.3637,352.399 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="350.22">
+ <tspan x="103.778" y="351.276">Is propagate true for</tspan>
+ <tspan x="103.778" y="359.742">current logger?</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,399.9 150.573,422.994 103.778,446.087 56.984,422.994 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="420.814">
- <tspan x="103.778" y="420.814">Is there a parent</tspan>
- <tspan x="103.778" y="429.281">logger?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,399.9 150.573,422.994 103.778,446.087 56.984,422.994 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="420.814">
+ <tspan x="103.778" y="422.926">Is there a parent</tspan>
+ <tspan x="103.778" y="431.393">logger?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="2.43852" y="295.984" width="63.9" height="26.5909" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="34.3885" y="307.1">
+ <rect x="2.43852" y="295.984" width="63.9" height="26.5909" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="34.3885" y="307.1">
<tspan x="34.3885" y="307.1">Set current</tspan>
<tspan x="34.3885" y="315.566">logger to parent</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="278.422,240.202 330.96,266.686 278.422,293.169 225.885,266.686 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="278.422" y="264.506">
- <tspan x="278.422" y="264.506">At least one handler</tspan>
- <tspan x="278.422" y="272.973">in hierarchy?</tspan>
+ <polygon fill-rule="evenodd" points="278.422,240.202 330.96,266.686 278.422,293.169 225.885,266.686 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="278.422" y="264.506">
+ <tspan x="278.422" y="266.618">At least one handler</tspan>
+ <tspan x="278.422" y="275.085">in hierarchy?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="298.963" y="312.257" width="57.75" height="25.9333" rx="0" ry="0"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="327.838" y="323.044">
- <tspan x="327.838" y="323.044">Use lastResort</tspan>
- <tspan x="327.838" y="331.511">handler</tspan>
+ <rect x="298.963" y="312.257" width="57.75" height="25.9333" rx="0" ry="0" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="327.838" y="323.044">
+ <tspan x="327.838" y="324.100">Use lastResort</tspan>
+ <tspan x="327.838" y="332.567">handler</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,35.7307 373.377,60.8536 320.041,85.9765 266.704,60.8536 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="58.6741">
+ <polygon fill-rule="evenodd" points="320.041,35.7307 373.377,60.8536 320.041,85.9765 266.704,60.8536 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="58.6741">
<tspan x="320.041" y="58.6741">Handler enabled for</tspan>
<tspan x="320.041" y="67.1407">level of LogRecord?</tspan>
</text>
</g>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,105.448 386.002,135.748 320.041,166.047 254.08,135.748 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="129.335">
- <tspan x="320.041" y="129.335">Does a filter attached</tspan>
- <tspan x="320.041" y="137.802">to handler reject the</tspan>
- <tspan x="320.041" y="146.268">record?</tspan>
+ <polygon fill-rule="evenodd" points="320.041,105.448 386.002,135.748 320.041,166.047 254.08,135.748 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="129.335">
+ <tspan x="320.041" y="132.508">Does a filter attached</tspan>
+ <tspan x="320.041" y="140.970">to handler reject the</tspan>
+ <tspan x="320.041" y="149.436">record?</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="409.532" y="52.4436" width="24.4" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="421.732" y="63.2307">
+ <rect x="409.532" y="52.4436" width="24.4" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="421.732" y="63.2307">
<tspan x="421.732" y="63.2307">Stop</tspan>
</text>
</g>
<g>
- <rect style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x="271.091" y="185.519" width="97.9" height="17.4667" rx="6" ry="6"/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="320.041" y="196.306">
+ <rect x="271.091" y="185.519" width="97.9" height="17.4667" rx="6" ry="6" />
+ <text font-size="6.77333" style="text-anchor: middle;" x="320.041" y="196.306">
<tspan x="320.041" y="196.306">Emit (includes formatting)</tspan>
</text>
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:700" x="241.002" y="18.9277">
+ <text font-size="6.77333" style="font-weight: 700;" x="241.002" y="18.9277">
<tspan x="241.002" y="18.9277">Handler flow</tspan>
</text>
<g>
- <polygon style="fill: #ffffff; fill-opacity: 0; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,34.4935 155.62,58.6834 103.778,82.8734 51.9368,58.6834 "/>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="103.778" y="56.5039">
- <tspan x="103.778" y="56.5039">Logger enabled for</tspan>
- <tspan x="103.778" y="64.9705">level of call?</tspan>
+ <polygon fill-rule="evenodd" points="103.778,34.4935 155.62,58.6834 103.778,82.8734 51.9368,58.6834 " />
+ <text font-size="6.77333" style="text-anchor: middle;" x="103.778" y="56.5039">
+ <tspan x="103.778" y="57.560">Logger enabled for</tspan>
+ <tspan x="103.778" y="66.026">level of call?</tspan>
</text>
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="223.603" x2="103.778" y2="245.36"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,248.36 101.778,244.36 103.778,245.36 105.778,244.36 "/>
+ <line x1="103.778" y1="223.603" x2="103.778" y2="245.36" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,248.36 101.778,244.36 103.778,245.36 105.778,244.36 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="283.878" x2="103.778" y2="322.451"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,325.451 101.778,321.451 103.778,322.451 105.778,321.451 "/>
+ <line x1="103.778" y1="283.878" x2="103.778" y2="322.451" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,325.451 101.778,321.451 103.778,322.451 105.778,321.451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="103.778" y1="378.229" x2="103.778" y2="395.782"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="103.778,398.782 101.778,394.782 103.778,395.782 105.778,394.782 "/>
+ <line x1="103.778" y1="378.229" x2="103.778" y2="395.782" />
+ <polygon class="filled" fill-rule="evenodd" points="103.778,398.782 101.778,394.782 103.778,395.782 105.778,394.782 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="56.984,422.994 34.3885,422.994 34.3885,326.693 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="34.3885,323.693 36.3885,327.693 34.3885,326.693 32.3885,327.693 "/>
+ <polyline points="56.984,422.994 34.3885,422.994 34.3885,326.693 " />
+ <polygon class="filled" fill-rule="evenodd" points="34.3885,323.693 36.3885,327.693 34.3885,326.693 32.3885,327.693 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="34.3885,295.984 34.3885,266.678 71.0853,266.678 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="74.0853,266.678 70.0853,268.678 71.0853,266.678 70.0853,264.678 "/>
+ <polyline points="34.3885,295.984 34.3885,266.678 71.0853,266.678 " />
+ <polygon class="filled" fill-rule="evenodd" points="74.0853,266.678 70.0853,268.678 71.0853,266.678 70.0853,264.678 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="150.573,422.994 200.261,422.994 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="150.573,422.994 200.261,422.994 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" x1="132.353" y1="266.678" x2="221.767" y2="266.685"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="224.767,266.686 220.766,268.685 221.767,266.685 220.767,264.685 "/>
+ <line style="stroke-dasharray: 5" x1="132.353" y1="266.678" x2="221.767" y2="266.685" />
+ <polygon class="filled" fill-rule="evenodd" points="224.767,266.686 220.766,268.685 221.767,266.685 220.767,264.685 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" points="278.422,293.169 278.422,325.224 294.845,325.224 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="297.845,325.224 293.845,327.224 294.845,325.224 293.845,323.224 "/>
+ <polyline style="stroke-dasharray: 5" points="278.422,293.169 278.422,325.224 294.845,325.224 " />
+ <polygon class="filled" fill-rule="evenodd" points="297.845,325.224 293.845,327.224 294.845,325.224 293.845,323.224 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="169.307,193.042 200.261,193.042 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="169.307,193.042 200.261,193.042 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="158.193,352.399 200.261,352.399 200.261,71.5451 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 "/>
+ <polyline points="158.193,352.399 200.261,352.399 200.261,71.5451 " />
+ <polygon class="filled" fill-rule="evenodd" points="200.261,68.5451 202.261,72.5451 200.261,71.5451 198.261,72.5451 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="319.981" y1="4.27261" x2="320.033" y2="31.6127"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.039,34.6127 318.031,30.6165 320.033,31.6127 322.031,30.6089 "/>
+ <line x1="319.981" y1="4.27261" x2="320.033" y2="31.6127" />
+ <polygon class="filled" fill-rule="evenodd" points="320.039,34.6127 318.031,30.6165 320.033,31.6127 322.031,30.6089 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="320.041" y1="85.9765" x2="320.041" y2="101.33"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,104.33 318.041,100.33 320.041,101.33 322.041,100.33 "/>
+ <line x1="320.041" y1="85.9765" x2="320.041" y2="101.33" />
+ <polygon class="filled" fill-rule="evenodd" points="320.041,104.33 318.041,100.33 320.041,101.33 322.041,100.33 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="320.041" y1="166.047" x2="320.041" y2="181.401"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="320.041,184.401 318.041,180.401 320.041,181.401 322.041,180.401 "/>
+ <line x1="320.041" y1="166.047" x2="320.041" y2="181.401" />
+ <polygon class="filled" fill-rule="evenodd" points="320.041,184.401 318.041,180.401 320.041,181.401 322.041,180.401 " />
</g>
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" points="386.002,135.748 421.732,135.748 421.732,74.0283 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="421.732,71.0283 423.732,75.0283 421.732,74.0283 419.732,75.0283 "/>
+ <polyline points="386.002,135.748 421.732,135.748 421.732,74.0283 " />
+ <polygon class="filled" fill-rule="evenodd" points="421.732,71.0283 423.732,75.0283 421.732,74.0283 419.732,75.0283 " />
</g>
<g>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke: #000000" x1="373.377" y1="60.8536" x2="405.415" y2="61.1401"/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="408.414,61.1669 404.397,63.1311 405.415,61.1401 404.433,59.1312 "/>
+ <line x1="373.377" y1="60.8536" x2="405.415" y2="61.1401" />
+ <polygon class="filled" fill-rule="evenodd" points="408.414,61.1669 404.397,63.1311 405.415,61.1401 404.433,59.1312 " />
</g>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="164.96" y="55.5649">
+ <text font-size="6.77333" x="164.96" y="55.5649">
<tspan x="164.96" y="55.5649">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="106.571" y="97.8453">
+ <text font-size="6.77333" x="106.571" y="97.8453">
<tspan x="106.571" y="97.8453">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="173.856" y="188.452">
+ <text font-size="6.77333" x="173.856" y="188.452">
<tspan x="173.856" y="188.452">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="107.446" y="239.221">
+ <text font-size="6.77333" x="107.446" y="239.221">
<tspan x="107.446" y="239.221">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="174.731" y="349.418">
+ <text font-size="6.77333" x="174.731" y="349.418">
<tspan x="174.731" y="349.418">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="106.571" y="390.507">
+ <text font-size="6.77333" x="106.571" y="390.507">
<tspan x="106.571" y="390.507">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="39.4722" y="417.667">
+ <text font-size="6.77333" x="39.4722" y="417.667">
<tspan x="39.4722" y="417.667">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="174.731" y="417.667">
+ <text font-size="6.77333" x="174.731" y="417.667">
<tspan x="174.731" y="417.667">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="281.451" y="313.406">
+ <text font-size="6.77333" x="281.451" y="313.406">
<tspan x="281.451" y="313.406">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.909" y="263.96">
+ <text font-size="6.77333" x="333.909" y="263.96">
<tspan x="333.909" y="263.96">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="385.766" y="56.9098">
+ <text font-size="6.77333" x="385.766" y="56.9098">
<tspan x="385.766" y="56.9098">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="397.102" y="130.471">
+ <text font-size="6.77333" x="397.102" y="130.471">
<tspan x="397.102" y="130.471">Yes</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="323.563" y="178.785">
+ <text font-size="6.77333" x="323.563" y="178.785">
<tspan x="323.563" y="178.785">No</tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="333.307" y="105.598">
+ <text font-size="6.77333" x="333.307" y="105.598">
<tspan x="333.307" y="105.598"></tspan>
</text>
- <text font-size="6.77333" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:start;font-family:sans-serif;font-style:normal;font-weight:normal" x="323.75" y="99.0042">
+ <text font-size="6.77333" x="323.75" y="99.0042">
<tspan x="323.75" y="99.0042">Yes</tspan>
</text>
- <text font-size="6.77323" style="fill: #000000; fill-opacity: 1; stroke: none;text-anchor:middle;font-family:sans-serif;font-style:normal;font-weight:normal" x="355.762" y="18.2449">
+ <text font-size="6.77323" style="text-anchor: middle;" x="355.762" y="18.2449">
<tspan x="355.762" y="18.2449">LogRecord passed</tspan>
<tspan x="355.762" y="26.7116">to handler</tspan>
</text>
- <line style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" x1="330.96" y1="266.686" x2="377.733" y2="267.908"/>
+ <line style="stroke-dasharray: 5" x1="330.96" y1="266.686" x2="377.733" y2="267.908" />
<g>
- <polyline style="fill: none; stroke-opacity: 1; stroke-width: 1; stroke-dasharray: 5; stroke: #000000" points="356.713,325.224 377.733,325.224 377.733,214.711 "/>
- <polygon style="fill: #000000; fill-opacity: 1; stroke-opacity: 1; stroke-width: 1; stroke: #000000" fill-rule="evenodd" points="377.733,211.711 379.733,215.711 377.733,214.711 375.733,215.711 "/>
+ <polyline style="fill: none; stroke-opacity: 1; stroke-dasharray: 5" points="356.713,325.224 377.733,325.224 377.733,214.711 " />
+ <polygon class="filled" fill-rule="evenodd" points="377.733,211.711 379.733,215.711 377.733,214.711 375.733,215.711 " />
</g>
</g>
</svg>
1
0
[3.13] gh-119447: Fix build with _PY_SHORT_FLOAT_REPR == 0 (GH-121178) (#121179)
by vstinner 30 Jun '24
by vstinner 30 Jun '24
30 Jun '24
https://github.com/python/cpython/commit/7776179ec459cc598fedf761a3c36463aa…
commit: 7776179ec459cc598fedf761a3c36463aa2e42a8
branch: 3.13
author: Miss Islington (bot) <31488909+miss-islington(a)users.noreply.github.com>
committer: vstinner <vstinner(a)python.org>
date: 2024-06-30T10:04:39Z
summary:
[3.13] gh-119447: Fix build with _PY_SHORT_FLOAT_REPR == 0 (GH-121178) (#121179)
gh-119447: Fix build with _PY_SHORT_FLOAT_REPR == 0 (GH-121178)
(cherry picked from commit c3677befbecbd7fa94cde8c1fecaa4cc18e6aa2b)
Co-authored-by: Yureka <yuka(a)yuka.dev>
files:
M Include/internal/pycore_dtoa.h
diff --git a/Include/internal/pycore_dtoa.h b/Include/internal/pycore_dtoa.h
index c5cfdf4ce8f823..e4222c5267d6be 100644
--- a/Include/internal/pycore_dtoa.h
+++ b/Include/internal/pycore_dtoa.h
@@ -11,8 +11,6 @@ extern "C" {
#include "pycore_pymath.h" // _PY_SHORT_FLOAT_REPR
-#if _PY_SHORT_FLOAT_REPR == 1
-
typedef uint32_t ULong;
struct
@@ -22,15 +20,15 @@ Bigint {
ULong x[1];
};
-#ifdef Py_USING_MEMORY_DEBUGGER
+#if defined(Py_USING_MEMORY_DEBUGGER) || _PY_SHORT_FLOAT_REPR == 0
struct _dtoa_state {
int _not_used;
};
-#define _dtoa_interp_state_INIT(INTERP) \
+#define _dtoa_state_INIT(INTERP) \
{0}
-#else // !Py_USING_MEMORY_DEBUGGER
+#else // !Py_USING_MEMORY_DEBUGGER && _PY_SHORT_FLOAT_REPR != 0
/* The size of the Bigint freelist */
#define Bigint_Kmax 7
@@ -66,8 +64,6 @@ extern char* _Py_dg_dtoa(double d, int mode, int ndigits,
int *decpt, int *sign, char **rve);
extern void _Py_dg_freedtoa(char *s);
-#endif // _PY_SHORT_FLOAT_REPR == 1
-
extern PyStatus _PyDtoa_Init(PyInterpreterState *interp);
extern void _PyDtoa_Fini(PyInterpreterState *interp);
1
0
[3.12] gh-119447: Fix build with _PY_SHORT_FLOAT_REPR == 0 (#121178) (#121180)
by vstinner 30 Jun '24
by vstinner 30 Jun '24
30 Jun '24
https://github.com/python/cpython/commit/e0b9905ce66fc0a73165608f8e67cc7d3d…
commit: e0b9905ce66fc0a73165608f8e67cc7d3dabbeb8
branch: 3.12
author: Victor Stinner <vstinner(a)python.org>
committer: vstinner <vstinner(a)python.org>
date: 2024-06-30T10:02:08Z
summary:
[3.12] gh-119447: Fix build with _PY_SHORT_FLOAT_REPR == 0 (#121178) (#121180)
gh-119447: Fix build with _PY_SHORT_FLOAT_REPR == 0 (#121178)
(cherry picked from commit c3677befbecbd7fa94cde8c1fecaa4cc18e6aa2b)
Co-authored-by: Yureka <yuka(a)yuka.dev>
files:
M Include/internal/pycore_dtoa.h
diff --git a/Include/internal/pycore_dtoa.h b/Include/internal/pycore_dtoa.h
index 4d9681d59a64f7..899d413b05e865 100644
--- a/Include/internal/pycore_dtoa.h
+++ b/Include/internal/pycore_dtoa.h
@@ -11,8 +11,6 @@ extern "C" {
#include "pycore_pymath.h" // _PY_SHORT_FLOAT_REPR
-#if _PY_SHORT_FLOAT_REPR == 1
-
typedef uint32_t ULong;
struct
@@ -22,15 +20,15 @@ Bigint {
ULong x[1];
};
-#ifdef Py_USING_MEMORY_DEBUGGER
+#if defined(Py_USING_MEMORY_DEBUGGER) || _PY_SHORT_FLOAT_REPR == 0
struct _dtoa_state {
int _not_used;
};
-#define _dtoa_interp_state_INIT(INTERP) \
+#define _dtoa_state_INIT(INTERP) \
{0}
-#else // !Py_USING_MEMORY_DEBUGGER
+#else // !Py_USING_MEMORY_DEBUGGER && _PY_SHORT_FLOAT_REPR != 0
/* The size of the Bigint freelist */
#define Bigint_Kmax 7
@@ -65,8 +63,6 @@ PyAPI_FUNC(char *) _Py_dg_dtoa(double d, int mode, int ndigits,
int *decpt, int *sign, char **rve);
PyAPI_FUNC(void) _Py_dg_freedtoa(char *s);
-#endif // _PY_SHORT_FLOAT_REPR == 1
-
#ifdef __cplusplus
}
#endif
1
0
https://github.com/python/cpython/commit/c3677befbecbd7fa94cde8c1fecaa4cc18…
commit: c3677befbecbd7fa94cde8c1fecaa4cc18e6aa2b
branch: main
author: Yureka <yuka(a)yuka.dev>
committer: vstinner <vstinner(a)python.org>
date: 2024-06-30T11:40:40+02:00
summary:
gh-119447: Fix build with _PY_SHORT_FLOAT_REPR == 0 (#121178)
files:
M Include/internal/pycore_dtoa.h
diff --git a/Include/internal/pycore_dtoa.h b/Include/internal/pycore_dtoa.h
index c5cfdf4ce8f823..e4222c5267d6be 100644
--- a/Include/internal/pycore_dtoa.h
+++ b/Include/internal/pycore_dtoa.h
@@ -11,8 +11,6 @@ extern "C" {
#include "pycore_pymath.h" // _PY_SHORT_FLOAT_REPR
-#if _PY_SHORT_FLOAT_REPR == 1
-
typedef uint32_t ULong;
struct
@@ -22,15 +20,15 @@ Bigint {
ULong x[1];
};
-#ifdef Py_USING_MEMORY_DEBUGGER
+#if defined(Py_USING_MEMORY_DEBUGGER) || _PY_SHORT_FLOAT_REPR == 0
struct _dtoa_state {
int _not_used;
};
-#define _dtoa_interp_state_INIT(INTERP) \
+#define _dtoa_state_INIT(INTERP) \
{0}
-#else // !Py_USING_MEMORY_DEBUGGER
+#else // !Py_USING_MEMORY_DEBUGGER && _PY_SHORT_FLOAT_REPR != 0
/* The size of the Bigint freelist */
#define Bigint_Kmax 7
@@ -66,8 +64,6 @@ extern char* _Py_dg_dtoa(double d, int mode, int ndigits,
int *decpt, int *sign, char **rve);
extern void _Py_dg_freedtoa(char *s);
-#endif // _PY_SHORT_FLOAT_REPR == 1
-
extern PyStatus _PyDtoa_Init(PyInterpreterState *interp);
extern void _PyDtoa_Fini(PyInterpreterState *interp);
1
0
[3.13] gh-120522: Add a `--with-app-store-compliance` configure option to patch out problematic code (GH-120984) (#121173)
by freakboy3742 30 Jun '24
by freakboy3742 30 Jun '24
30 Jun '24
https://github.com/python/cpython/commit/0dfb437a32f9b9a8a0ae61d8c43c474176…
commit: 0dfb437a32f9b9a8a0ae61d8c43c47417651f44e
branch: 3.13
author: Miss Islington (bot) <31488909+miss-islington(a)users.noreply.github.com>
committer: freakboy3742 <russell(a)keith-magee.com>
date: 2024-06-30T09:10:34+08:00
summary:
[3.13] gh-120522: Add a `--with-app-store-compliance` configure option to patch out problematic code (GH-120984) (#121173)
gh-120522: Add a `--with-app-store-compliance` configure option to patch out problematic code (GH-120984)
* Add --app-store-compliance configuration option.
* Added blurb.
* Correct tab-vs-spaces formatting issue.
* Correct source file name in docs.
* Correct source code reference in Mac docs
* Only apply the patch forward, and ensure the working directory is correct.
* Make patching reslient to multiple builds.
* Documentation fixes found during review
* Documentation and configure.ac syntax improvements
* Regenerate configure script.
* Silence the patch echo output.
---------
(cherry picked from commit 48cd104b0cf05dad8958efa9cb9666c029ef9201)
Co-authored-by: Russell Keith-Magee <russell(a)keith-magee.com>
Co-authored-by: Nice Zombies <nineteendo19d0(a)gmail.com>
Co-authored-by: Alyssa Coghlan <ncoghlan(a)gmail.com>
Co-authored-by: Erlend E. Aasland <erlend.aasland(a)protonmail.com>
files:
A Mac/Resources/app-store-compliance.patch
A Misc/NEWS.d/next/Build/2024-06-25-15-29-27.gh-issue-120522.5_n515.rst
M Doc/library/urllib.parse.rst
M Doc/using/configure.rst
M Doc/using/ios.rst
M Doc/using/mac.rst
M Makefile.pre.in
M configure
M configure.ac
diff --git a/Doc/library/urllib.parse.rst b/Doc/library/urllib.parse.rst
index 27909b763e9e43..fb5353e1895bf9 100644
--- a/Doc/library/urllib.parse.rst
+++ b/Doc/library/urllib.parse.rst
@@ -22,11 +22,19 @@ to an absolute URL given a "base URL."
The module has been designed to match the internet RFC on Relative Uniform
Resource Locators. It supports the following URL schemes: ``file``, ``ftp``,
-``gopher``, ``hdl``, ``http``, ``https``, ``imap``, ``mailto``, ``mms``,
+``gopher``, ``hdl``, ``http``, ``https``, ``imap``, ``itms-services``, ``mailto``, ``mms``,
``news``, ``nntp``, ``prospero``, ``rsync``, ``rtsp``, ``rtsps``, ``rtspu``,
``sftp``, ``shttp``, ``sip``, ``sips``, ``snews``, ``svn``, ``svn+ssh``,
``telnet``, ``wais``, ``ws``, ``wss``.
+.. impl-detail::
+
+ The inclusion of the ``itms-services`` URL scheme can prevent an app from
+ passing Apple's App Store review process for the macOS and iOS App Stores.
+ Handling for the ``itms-services`` scheme is always removed on iOS; on
+ macOS, it *may* be removed if CPython has been built with the
+ :option:`--with-app-store-compliance` option.
+
The :mod:`urllib.parse` module defines functions that fall into two broad
categories: URL parsing and URL quoting. These are covered in detail in
the following sections.
diff --git a/Doc/using/configure.rst b/Doc/using/configure.rst
index 428ee5275276a0..2a1f06e2d286ff 100644
--- a/Doc/using/configure.rst
+++ b/Doc/using/configure.rst
@@ -945,6 +945,17 @@ See :source:`Mac/README.rst`.
Specify the name for the python framework on macOS only valid when
:option:`--enable-framework` is set (default: ``Python``).
+.. option:: --with-app-store-compliance
+.. option:: --with-app-store-compliance=PATCH-FILE
+
+ The Python standard library contains strings that are known to trigger
+ automated inspection tool errors when submitted for distribution by
+ the macOS and iOS App Stores. If enabled, this option will apply the list of
+ patches that are known to correct app store compliance. A custom patch
+ file can also be specified. This option is disabled by default.
+
+ .. versionadded:: 3.13
+
iOS Options
-----------
diff --git a/Doc/using/ios.rst b/Doc/using/ios.rst
index 71fc29c450c8eb..774856e8aec2ac 100644
--- a/Doc/using/ios.rst
+++ b/Doc/using/ios.rst
@@ -312,3 +312,21 @@ modules in your app, some additional steps will be required:
* If you're using a separate folder for third-party packages, ensure that folder
is included as part of the ``PYTHONPATH`` configuration in step 10.
+
+App Store Compliance
+====================
+
+The only mechanism for distributing apps to third-party iOS devices is to
+submit the app to the iOS App Store; apps submitted for distribution must pass
+Apple's app review process. This process includes a set of automated validation
+rules that inspect the submitted application bundle for problematic code.
+
+The Python standard library contains some code that is known to violate these
+automated rules. While these violations appear to be false positives, Apple's
+review rules cannot be challenged; so, it is necessary to modify the Python
+standard library for an app to pass App Store review.
+
+The Python source tree contains
+:source:`a patch file <Mac/Resources/app-store-compliance.patch>` that will remove
+all code that is known to cause issues with the App Store review process. This
+patch is applied automatically when building for iOS.
diff --git a/Doc/using/mac.rst b/Doc/using/mac.rst
index 31d37aad2a7408..44fb00de3733c5 100644
--- a/Doc/using/mac.rst
+++ b/Doc/using/mac.rst
@@ -188,6 +188,28 @@ distributable application:
* `PyInstaller <https://pyinstaller.org/>`__: A cross-platform packaging tool that creates
a single file or folder as a distributable artifact.
+App Store Compliance
+--------------------
+
+Apps submitted for distribution through the macOS App Store must pass Apple's
+app review process. This process includes a set of automated validation rules
+that inspect the submitted application bundle for problematic code.
+
+The Python standard library contains some code that is known to violate these
+automated rules. While these violations appear to be false positives, Apple's
+review rules cannot be challenged. Therefore, it is necessary to modify the
+Python standard library for an app to pass App Store review.
+
+The Python source tree contains
+:source:`a patch file <Mac/Resources/app-store-compliance.patch>` that will remove
+all code that is known to cause issues with the App Store review process. This
+patch is applied automatically when CPython is configured with the
+:option:`--with-app-store-compliance` option.
+
+This patch is not normally required to use CPython on a Mac; nor is it required
+if you are distributing an app *outside* the macOS App Store. It is *only*
+required if you are using the macOS App Store as a distribution channel.
+
Other Resources
===============
diff --git a/Mac/Resources/app-store-compliance.patch b/Mac/Resources/app-store-compliance.patch
new file mode 100644
index 00000000000000..f4b7decc01cf1f
--- /dev/null
+++ b/Mac/Resources/app-store-compliance.patch
@@ -0,0 +1,29 @@
+diff --git a/Lib/test/test_urlparse.py b/Lib/test/test_urlparse.py
+index d6c83a75c1c..19ed4e01091 100644
+--- a/Lib/test/test_urlparse.py
++++ b/Lib/test/test_urlparse.py
+@@ -237,11 +237,6 @@ def test_roundtrips(self):
+ '','',''),
+ ('git+ssh', 'git(a)github.com','/user/project.git',
+ '', '')),
+- ('itms-services://?action=download-manifest&url=https://example.com/app',
+- ('itms-services', '', '', '',
+- 'action=download-manifest&url=https://example.com/app', ''),
+- ('itms-services', '', '',
+- 'action=download-manifest&url=https://example.com/app', '')),
+ ('+scheme:path/to/file',
+ ('', '', '+scheme:path/to/file', '', '', ''),
+ ('', '', '+scheme:path/to/file', '', '')),
+diff --git a/Lib/urllib/parse.py b/Lib/urllib/parse.py
+index 8f724f907d4..148caf742c9 100644
+--- a/Lib/urllib/parse.py
++++ b/Lib/urllib/parse.py
+@@ -59,7 +59,7 @@
+ 'imap', 'wais', 'file', 'mms', 'https', 'shttp',
+ 'snews', 'prospero', 'rtsp', 'rtsps', 'rtspu', 'rsync',
+ 'svn', 'svn+ssh', 'sftp', 'nfs', 'git', 'git+ssh',
+- 'ws', 'wss', 'itms-services']
++ 'ws', 'wss']
+
+ uses_params = ['', 'ftp', 'hdl', 'prospero', 'http', 'imap',
+ 'https', 'shttp', 'rtsp', 'rtsps', 'rtspu', 'sip',
diff --git a/Makefile.pre.in b/Makefile.pre.in
index 22d8bb96208754..9900560d31255a 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -178,6 +178,9 @@ EXPORTSFROM= @EXPORTSFROM@
EXE= @EXEEXT@
BUILDEXE= @BUILDEXEEXT@
+# Name of the patch file to apply for app store compliance
+APP_STORE_COMPLIANCE_PATCH=@APP_STORE_COMPLIANCE_PATCH@
+
# Short name and location for Mac OS X Python framework
UNIVERSALSDK=@UNIVERSALSDK@
PYTHONFRAMEWORK= @PYTHONFRAMEWORK@
@@ -691,7 +694,7 @@ list-targets:
@grep -E '^[A-Za-z][-A-Za-z0-9]+:' Makefile | awk -F : '{print $$1}'
.PHONY: build_all
-build_all: check-clean-src $(BUILDPYTHON) platform sharedmods \
+build_all: check-clean-src @APP_STORE_COMPLIANCE_PATCH_TARGET@ $(BUILDPYTHON) platform sharedmods \
gdbhooks Programs/_testembed scripts checksharedmods rundsymutil
.PHONY: build_wasm
@@ -927,6 +930,18 @@ SRC_GDB_HOOKS=$(srcdir)/Tools/gdb/libpython.py
$(BUILDPYTHON)-gdb.py: $(SRC_GDB_HOOKS)
$(INSTALL_DATA) $(SRC_GDB_HOOKS) $(BUILDPYTHON)-gdb.py
+# Compliance with app stores (such as iOS and macOS) sometimes requires making
+# modifications to the Python standard library. If enabled, apply the patch of
+# known modifications to the source tree before building. The patch will be
+# applied in a dry-run mode (validating, but not applying the patch) on builds
+# that *have* a compliance patch, but where compliance has not been enabled.
+build/app-store-compliant:
+ patch @APP_STORE_COMPLIANCE_PATCH_FLAGS@ --forward --strip=1 --directory="$(srcdir)" --input "$(APP_STORE_COMPLIANCE_PATCH)"
+ @if test "@APP_STORE_COMPLIANCE_PATCH_FLAGS@" == ""; then \
+ mkdir -p build ; \
+ echo "$(APP_STORE_COMPLIANCE_PATCH)" > build/app-store-compliant ; \
+ fi
+
# This rule is here for OPENSTEP/Rhapsody/MacOSX. It builds a temporary
# minimal framework (not including the Lib directory and such) in the current
# directory.
diff --git a/Misc/NEWS.d/next/Build/2024-06-25-15-29-27.gh-issue-120522.5_n515.rst b/Misc/NEWS.d/next/Build/2024-06-25-15-29-27.gh-issue-120522.5_n515.rst
new file mode 100644
index 00000000000000..4a397a445ccc3b
--- /dev/null
+++ b/Misc/NEWS.d/next/Build/2024-06-25-15-29-27.gh-issue-120522.5_n515.rst
@@ -0,0 +1,2 @@
+Added a :option:`--with-app-store-compliance` option to patch out known issues
+with macOS/iOS App Store review processes.
diff --git a/configure b/configure
index c92ec305333c5a..a5578fc9e8bae2 100755
--- a/configure
+++ b/configure
@@ -981,6 +981,9 @@ IPHONEOS_DEPLOYMENT_TARGET
EXPORT_MACOSX_DEPLOYMENT_TARGET
CONFIGURE_MACOSX_DEPLOYMENT_TARGET
_PYTHON_HOST_PLATFORM
+APP_STORE_COMPLIANCE_PATCH_FLAGS
+APP_STORE_COMPLIANCE_PATCH_TARGET
+APP_STORE_COMPLIANCE_PATCH
INSTALLTARGETS
FRAMEWORKINSTALLAPPSPREFIX
FRAMEWORKUNIXTOOLSPREFIX
@@ -1076,6 +1079,7 @@ enable_universalsdk
with_universal_archs
with_framework_name
enable_framework
+with_app_store_compliance
with_emscripten_target
enable_wasm_dynamic_linking
enable_wasm_pthreads
@@ -1855,6 +1859,10 @@ Optional Packages:
specify the name for the python framework on macOS
only valid when --enable-framework is set. see
Mac/README.rst (default is 'Python')
+ --with-app-store-compliance=[PATCH-FILE]
+ Enable any patches required for compiliance with app
+ stores. Optional PATCH-FILE specifies the custom
+ patch to apply.
--with-emscripten-target=[browser|node]
Emscripten platform
--with-suffix=SUFFIX set executable suffix to SUFFIX (default is empty,
@@ -4430,6 +4438,71 @@ fi
printf "%s\n" "#define _PYTHONFRAMEWORK \"${PYTHONFRAMEWORK}\"" >>confdefs.h
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-app-store-compliance" >&5
+printf %s "checking for --with-app-store-compliance... " >&6; }
+
+# Check whether --with-app_store_compliance was given.
+if test ${with_app_store_compliance+y}
+then :
+ withval=$with_app_store_compliance;
+ case "$withval" in
+ yes)
+ case $ac_sys_system in
+ Darwin|iOS)
+ # iOS is able to share the macOS patch
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ ;;
+ *) as_fn_error $? "no default app store compliance patch available for $ac_sys_system" "$LINENO" 5 ;;
+ esac
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: applying default app store compliance patch" >&5
+printf "%s\n" "applying default app store compliance patch" >&6; }
+ ;;
+ *)
+ APP_STORE_COMPLIANCE_PATCH="${withval}"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: applying custom app store compliance patch" >&5
+printf "%s\n" "applying custom app store compliance patch" >&6; }
+ ;;
+ esac
+
+else $as_nop
+
+ case $ac_sys_system in
+ iOS)
+ # Always apply the compliance patch on iOS; we can use the macOS patch
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: applying default app store compliance patch" >&5
+printf "%s\n" "applying default app store compliance patch" >&6; }
+ ;;
+ Darwin)
+ # Always *check* the compliance patch on macOS
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS="--dry-run"
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: checking (not applying) default app store compliance patch" >&5
+printf "%s\n" "checking (not applying) default app store compliance patch" >&6; }
+ ;;
+ *)
+ # No app compliance patching on any other platform
+ APP_STORE_COMPLIANCE_PATCH=
+ APP_STORE_COMPLIANCE_PATCH_TARGET=
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not patching for app store compliance" >&5
+printf "%s\n" "not patching for app store compliance" >&6; }
+ ;;
+ esac
+
+fi
+
+
+
+
+
if test "$cross_compiling" = yes; then
case "$host" in
diff --git a/configure.ac b/configure.ac
index 5fd9b1817347d0..723f36a52a108e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -695,6 +695,64 @@ AC_SUBST([INSTALLTARGETS])
AC_DEFINE_UNQUOTED([_PYTHONFRAMEWORK], ["${PYTHONFRAMEWORK}"],
[framework name])
+dnl quadrigraphs "@<:@" and "@:>@" produce "[" and "]" in the output
+AC_MSG_CHECKING([for --with-app-store-compliance])
+AC_ARG_WITH(
+ [app_store_compliance],
+ [AS_HELP_STRING(
+ [--with-app-store-compliance=@<:@PATCH-FILE@:>@],
+ [Enable any patches required for compiliance with app stores.
+ Optional PATCH-FILE specifies the custom patch to apply.]
+ )],[
+ case "$withval" in
+ yes)
+ case $ac_sys_system in
+ Darwin|iOS)
+ # iOS is able to share the macOS patch
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ ;;
+ *) AC_MSG_ERROR([no default app store compliance patch available for $ac_sys_system]) ;;
+ esac
+ AC_MSG_RESULT([applying default app store compliance patch])
+ ;;
+ *)
+ APP_STORE_COMPLIANCE_PATCH="${withval}"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ AC_MSG_RESULT([applying custom app store compliance patch])
+ ;;
+ esac
+ ],[
+ case $ac_sys_system in
+ iOS)
+ # Always apply the compliance patch on iOS; we can use the macOS patch
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ AC_MSG_RESULT([applying default app store compliance patch])
+ ;;
+ Darwin)
+ # Always *check* the compliance patch on macOS
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS="--dry-run"
+ AC_MSG_RESULT([checking (not applying) default app store compliance patch])
+ ;;
+ *)
+ # No app compliance patching on any other platform
+ APP_STORE_COMPLIANCE_PATCH=
+ APP_STORE_COMPLIANCE_PATCH_TARGET=
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ AC_MSG_RESULT([not patching for app store compliance])
+ ;;
+ esac
+])
+AC_SUBST([APP_STORE_COMPLIANCE_PATCH])
+AC_SUBST([APP_STORE_COMPLIANCE_PATCH_TARGET])
+AC_SUBST([APP_STORE_COMPLIANCE_PATCH_FLAGS])
+
AC_SUBST([_PYTHON_HOST_PLATFORM])
if test "$cross_compiling" = yes; then
case "$host" in
1
0
gh-120522: Add a `--with-app-store-compliance` configure option to patch out problematic code (#120984)
by freakboy3742 30 Jun '24
by freakboy3742 30 Jun '24
30 Jun '24
https://github.com/python/cpython/commit/48cd104b0cf05dad8958efa9cb9666c029…
commit: 48cd104b0cf05dad8958efa9cb9666c029ef9201
branch: main
author: Russell Keith-Magee <russell(a)keith-magee.com>
committer: freakboy3742 <russell(a)keith-magee.com>
date: 2024-06-30T08:34:35+08:00
summary:
gh-120522: Add a `--with-app-store-compliance` configure option to patch out problematic code (#120984)
* Add --app-store-compliance configuration option.
* Added blurb.
* Correct tab-vs-spaces formatting issue.
* Correct source file name in docs.
Co-authored-by: Nice Zombies <nineteendo19d0(a)gmail.com>
* Correct source code reference in Mac docs
Co-authored-by: Nice Zombies <nineteendo19d0(a)gmail.com>
* Only apply the patch forward, and ensure the working directory is correct.
* Make patching reslient to multiple builds.
* Documentation fixes found during review
Co-authored-by: Alyssa Coghlan <ncoghlan(a)gmail.com>
* Documentation and configure.ac syntax improvements
Co-authored-by: Erlend E. Aasland <erlend.aasland(a)protonmail.com>
* Regenerate configure script.
* Silence the patch echo output.
---------
Co-authored-by: Nice Zombies <nineteendo19d0(a)gmail.com>
Co-authored-by: Alyssa Coghlan <ncoghlan(a)gmail.com>
Co-authored-by: Erlend E. Aasland <erlend.aasland(a)protonmail.com>
files:
A Mac/Resources/app-store-compliance.patch
A Misc/NEWS.d/next/Build/2024-06-25-15-29-27.gh-issue-120522.5_n515.rst
M Doc/library/urllib.parse.rst
M Doc/using/configure.rst
M Doc/using/ios.rst
M Doc/using/mac.rst
M Makefile.pre.in
M configure
M configure.ac
diff --git a/Doc/library/urllib.parse.rst b/Doc/library/urllib.parse.rst
index 27909b763e9e43..fb5353e1895bf9 100644
--- a/Doc/library/urllib.parse.rst
+++ b/Doc/library/urllib.parse.rst
@@ -22,11 +22,19 @@ to an absolute URL given a "base URL."
The module has been designed to match the internet RFC on Relative Uniform
Resource Locators. It supports the following URL schemes: ``file``, ``ftp``,
-``gopher``, ``hdl``, ``http``, ``https``, ``imap``, ``mailto``, ``mms``,
+``gopher``, ``hdl``, ``http``, ``https``, ``imap``, ``itms-services``, ``mailto``, ``mms``,
``news``, ``nntp``, ``prospero``, ``rsync``, ``rtsp``, ``rtsps``, ``rtspu``,
``sftp``, ``shttp``, ``sip``, ``sips``, ``snews``, ``svn``, ``svn+ssh``,
``telnet``, ``wais``, ``ws``, ``wss``.
+.. impl-detail::
+
+ The inclusion of the ``itms-services`` URL scheme can prevent an app from
+ passing Apple's App Store review process for the macOS and iOS App Stores.
+ Handling for the ``itms-services`` scheme is always removed on iOS; on
+ macOS, it *may* be removed if CPython has been built with the
+ :option:`--with-app-store-compliance` option.
+
The :mod:`urllib.parse` module defines functions that fall into two broad
categories: URL parsing and URL quoting. These are covered in detail in
the following sections.
diff --git a/Doc/using/configure.rst b/Doc/using/configure.rst
index 428ee5275276a0..2a1f06e2d286ff 100644
--- a/Doc/using/configure.rst
+++ b/Doc/using/configure.rst
@@ -945,6 +945,17 @@ See :source:`Mac/README.rst`.
Specify the name for the python framework on macOS only valid when
:option:`--enable-framework` is set (default: ``Python``).
+.. option:: --with-app-store-compliance
+.. option:: --with-app-store-compliance=PATCH-FILE
+
+ The Python standard library contains strings that are known to trigger
+ automated inspection tool errors when submitted for distribution by
+ the macOS and iOS App Stores. If enabled, this option will apply the list of
+ patches that are known to correct app store compliance. A custom patch
+ file can also be specified. This option is disabled by default.
+
+ .. versionadded:: 3.13
+
iOS Options
-----------
diff --git a/Doc/using/ios.rst b/Doc/using/ios.rst
index 71fc29c450c8eb..774856e8aec2ac 100644
--- a/Doc/using/ios.rst
+++ b/Doc/using/ios.rst
@@ -312,3 +312,21 @@ modules in your app, some additional steps will be required:
* If you're using a separate folder for third-party packages, ensure that folder
is included as part of the ``PYTHONPATH`` configuration in step 10.
+
+App Store Compliance
+====================
+
+The only mechanism for distributing apps to third-party iOS devices is to
+submit the app to the iOS App Store; apps submitted for distribution must pass
+Apple's app review process. This process includes a set of automated validation
+rules that inspect the submitted application bundle for problematic code.
+
+The Python standard library contains some code that is known to violate these
+automated rules. While these violations appear to be false positives, Apple's
+review rules cannot be challenged; so, it is necessary to modify the Python
+standard library for an app to pass App Store review.
+
+The Python source tree contains
+:source:`a patch file <Mac/Resources/app-store-compliance.patch>` that will remove
+all code that is known to cause issues with the App Store review process. This
+patch is applied automatically when building for iOS.
diff --git a/Doc/using/mac.rst b/Doc/using/mac.rst
index 31d37aad2a7408..44fb00de3733c5 100644
--- a/Doc/using/mac.rst
+++ b/Doc/using/mac.rst
@@ -188,6 +188,28 @@ distributable application:
* `PyInstaller <https://pyinstaller.org/>`__: A cross-platform packaging tool that creates
a single file or folder as a distributable artifact.
+App Store Compliance
+--------------------
+
+Apps submitted for distribution through the macOS App Store must pass Apple's
+app review process. This process includes a set of automated validation rules
+that inspect the submitted application bundle for problematic code.
+
+The Python standard library contains some code that is known to violate these
+automated rules. While these violations appear to be false positives, Apple's
+review rules cannot be challenged. Therefore, it is necessary to modify the
+Python standard library for an app to pass App Store review.
+
+The Python source tree contains
+:source:`a patch file <Mac/Resources/app-store-compliance.patch>` that will remove
+all code that is known to cause issues with the App Store review process. This
+patch is applied automatically when CPython is configured with the
+:option:`--with-app-store-compliance` option.
+
+This patch is not normally required to use CPython on a Mac; nor is it required
+if you are distributing an app *outside* the macOS App Store. It is *only*
+required if you are using the macOS App Store as a distribution channel.
+
Other Resources
===============
diff --git a/Mac/Resources/app-store-compliance.patch b/Mac/Resources/app-store-compliance.patch
new file mode 100644
index 00000000000000..f4b7decc01cf1f
--- /dev/null
+++ b/Mac/Resources/app-store-compliance.patch
@@ -0,0 +1,29 @@
+diff --git a/Lib/test/test_urlparse.py b/Lib/test/test_urlparse.py
+index d6c83a75c1c..19ed4e01091 100644
+--- a/Lib/test/test_urlparse.py
++++ b/Lib/test/test_urlparse.py
+@@ -237,11 +237,6 @@ def test_roundtrips(self):
+ '','',''),
+ ('git+ssh', 'git(a)github.com','/user/project.git',
+ '', '')),
+- ('itms-services://?action=download-manifest&url=https://example.com/app',
+- ('itms-services', '', '', '',
+- 'action=download-manifest&url=https://example.com/app', ''),
+- ('itms-services', '', '',
+- 'action=download-manifest&url=https://example.com/app', '')),
+ ('+scheme:path/to/file',
+ ('', '', '+scheme:path/to/file', '', '', ''),
+ ('', '', '+scheme:path/to/file', '', '')),
+diff --git a/Lib/urllib/parse.py b/Lib/urllib/parse.py
+index 8f724f907d4..148caf742c9 100644
+--- a/Lib/urllib/parse.py
++++ b/Lib/urllib/parse.py
+@@ -59,7 +59,7 @@
+ 'imap', 'wais', 'file', 'mms', 'https', 'shttp',
+ 'snews', 'prospero', 'rtsp', 'rtsps', 'rtspu', 'rsync',
+ 'svn', 'svn+ssh', 'sftp', 'nfs', 'git', 'git+ssh',
+- 'ws', 'wss', 'itms-services']
++ 'ws', 'wss']
+
+ uses_params = ['', 'ftp', 'hdl', 'prospero', 'http', 'imap',
+ 'https', 'shttp', 'rtsp', 'rtsps', 'rtspu', 'sip',
diff --git a/Makefile.pre.in b/Makefile.pre.in
index 41904a2183ae70..1d106f30a101de 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -178,6 +178,9 @@ EXPORTSFROM= @EXPORTSFROM@
EXE= @EXEEXT@
BUILDEXE= @BUILDEXEEXT@
+# Name of the patch file to apply for app store compliance
+APP_STORE_COMPLIANCE_PATCH=@APP_STORE_COMPLIANCE_PATCH@
+
# Short name and location for Mac OS X Python framework
UNIVERSALSDK=@UNIVERSALSDK@
PYTHONFRAMEWORK= @PYTHONFRAMEWORK@
@@ -691,7 +694,7 @@ list-targets:
@grep -E '^[A-Za-z][-A-Za-z0-9]+:' Makefile | awk -F : '{print $$1}'
.PHONY: build_all
-build_all: check-clean-src $(BUILDPYTHON) platform sharedmods \
+build_all: check-clean-src @APP_STORE_COMPLIANCE_PATCH_TARGET@ $(BUILDPYTHON) platform sharedmods \
gdbhooks Programs/_testembed scripts checksharedmods rundsymutil
.PHONY: build_wasm
@@ -927,6 +930,18 @@ SRC_GDB_HOOKS=$(srcdir)/Tools/gdb/libpython.py
$(BUILDPYTHON)-gdb.py: $(SRC_GDB_HOOKS)
$(INSTALL_DATA) $(SRC_GDB_HOOKS) $(BUILDPYTHON)-gdb.py
+# Compliance with app stores (such as iOS and macOS) sometimes requires making
+# modifications to the Python standard library. If enabled, apply the patch of
+# known modifications to the source tree before building. The patch will be
+# applied in a dry-run mode (validating, but not applying the patch) on builds
+# that *have* a compliance patch, but where compliance has not been enabled.
+build/app-store-compliant:
+ patch @APP_STORE_COMPLIANCE_PATCH_FLAGS@ --forward --strip=1 --directory="$(srcdir)" --input "$(APP_STORE_COMPLIANCE_PATCH)"
+ @if test "@APP_STORE_COMPLIANCE_PATCH_FLAGS@" == ""; then \
+ mkdir -p build ; \
+ echo "$(APP_STORE_COMPLIANCE_PATCH)" > build/app-store-compliant ; \
+ fi
+
# This rule is here for OPENSTEP/Rhapsody/MacOSX. It builds a temporary
# minimal framework (not including the Lib directory and such) in the current
# directory.
diff --git a/Misc/NEWS.d/next/Build/2024-06-25-15-29-27.gh-issue-120522.5_n515.rst b/Misc/NEWS.d/next/Build/2024-06-25-15-29-27.gh-issue-120522.5_n515.rst
new file mode 100644
index 00000000000000..4a397a445ccc3b
--- /dev/null
+++ b/Misc/NEWS.d/next/Build/2024-06-25-15-29-27.gh-issue-120522.5_n515.rst
@@ -0,0 +1,2 @@
+Added a :option:`--with-app-store-compliance` option to patch out known issues
+with macOS/iOS App Store review processes.
diff --git a/configure b/configure
index 58be837f16b51d..99d86437327a01 100755
--- a/configure
+++ b/configure
@@ -981,6 +981,9 @@ IPHONEOS_DEPLOYMENT_TARGET
EXPORT_MACOSX_DEPLOYMENT_TARGET
CONFIGURE_MACOSX_DEPLOYMENT_TARGET
_PYTHON_HOST_PLATFORM
+APP_STORE_COMPLIANCE_PATCH_FLAGS
+APP_STORE_COMPLIANCE_PATCH_TARGET
+APP_STORE_COMPLIANCE_PATCH
INSTALLTARGETS
FRAMEWORKINSTALLAPPSPREFIX
FRAMEWORKUNIXTOOLSPREFIX
@@ -1076,6 +1079,7 @@ enable_universalsdk
with_universal_archs
with_framework_name
enable_framework
+with_app_store_compliance
with_emscripten_target
enable_wasm_dynamic_linking
enable_wasm_pthreads
@@ -1855,6 +1859,10 @@ Optional Packages:
specify the name for the python framework on macOS
only valid when --enable-framework is set. see
Mac/README.rst (default is 'Python')
+ --with-app-store-compliance=[PATCH-FILE]
+ Enable any patches required for compiliance with app
+ stores. Optional PATCH-FILE specifies the custom
+ patch to apply.
--with-emscripten-target=[browser|node]
Emscripten platform
--with-suffix=SUFFIX set executable suffix to SUFFIX (default is empty,
@@ -4430,6 +4438,71 @@ fi
printf "%s\n" "#define _PYTHONFRAMEWORK \"${PYTHONFRAMEWORK}\"" >>confdefs.h
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-app-store-compliance" >&5
+printf %s "checking for --with-app-store-compliance... " >&6; }
+
+# Check whether --with-app_store_compliance was given.
+if test ${with_app_store_compliance+y}
+then :
+ withval=$with_app_store_compliance;
+ case "$withval" in
+ yes)
+ case $ac_sys_system in
+ Darwin|iOS)
+ # iOS is able to share the macOS patch
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ ;;
+ *) as_fn_error $? "no default app store compliance patch available for $ac_sys_system" "$LINENO" 5 ;;
+ esac
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: applying default app store compliance patch" >&5
+printf "%s\n" "applying default app store compliance patch" >&6; }
+ ;;
+ *)
+ APP_STORE_COMPLIANCE_PATCH="${withval}"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: applying custom app store compliance patch" >&5
+printf "%s\n" "applying custom app store compliance patch" >&6; }
+ ;;
+ esac
+
+else $as_nop
+
+ case $ac_sys_system in
+ iOS)
+ # Always apply the compliance patch on iOS; we can use the macOS patch
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: applying default app store compliance patch" >&5
+printf "%s\n" "applying default app store compliance patch" >&6; }
+ ;;
+ Darwin)
+ # Always *check* the compliance patch on macOS
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS="--dry-run"
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: checking (not applying) default app store compliance patch" >&5
+printf "%s\n" "checking (not applying) default app store compliance patch" >&6; }
+ ;;
+ *)
+ # No app compliance patching on any other platform
+ APP_STORE_COMPLIANCE_PATCH=
+ APP_STORE_COMPLIANCE_PATCH_TARGET=
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not patching for app store compliance" >&5
+printf "%s\n" "not patching for app store compliance" >&6; }
+ ;;
+ esac
+
+fi
+
+
+
+
+
if test "$cross_compiling" = yes; then
case "$host" in
diff --git a/configure.ac b/configure.ac
index 84ba55e1c0c7ab..e4f8f4112283a8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -695,6 +695,64 @@ AC_SUBST([INSTALLTARGETS])
AC_DEFINE_UNQUOTED([_PYTHONFRAMEWORK], ["${PYTHONFRAMEWORK}"],
[framework name])
+dnl quadrigraphs "@<:@" and "@:>@" produce "[" and "]" in the output
+AC_MSG_CHECKING([for --with-app-store-compliance])
+AC_ARG_WITH(
+ [app_store_compliance],
+ [AS_HELP_STRING(
+ [--with-app-store-compliance=@<:@PATCH-FILE@:>@],
+ [Enable any patches required for compiliance with app stores.
+ Optional PATCH-FILE specifies the custom patch to apply.]
+ )],[
+ case "$withval" in
+ yes)
+ case $ac_sys_system in
+ Darwin|iOS)
+ # iOS is able to share the macOS patch
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ ;;
+ *) AC_MSG_ERROR([no default app store compliance patch available for $ac_sys_system]) ;;
+ esac
+ AC_MSG_RESULT([applying default app store compliance patch])
+ ;;
+ *)
+ APP_STORE_COMPLIANCE_PATCH="${withval}"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ AC_MSG_RESULT([applying custom app store compliance patch])
+ ;;
+ esac
+ ],[
+ case $ac_sys_system in
+ iOS)
+ # Always apply the compliance patch on iOS; we can use the macOS patch
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ AC_MSG_RESULT([applying default app store compliance patch])
+ ;;
+ Darwin)
+ # Always *check* the compliance patch on macOS
+ APP_STORE_COMPLIANCE_PATCH="Mac/Resources/app-store-compliance.patch"
+ APP_STORE_COMPLIANCE_PATCH_TARGET="build/app-store-compliant"
+ APP_STORE_COMPLIANCE_PATCH_FLAGS="--dry-run"
+ AC_MSG_RESULT([checking (not applying) default app store compliance patch])
+ ;;
+ *)
+ # No app compliance patching on any other platform
+ APP_STORE_COMPLIANCE_PATCH=
+ APP_STORE_COMPLIANCE_PATCH_TARGET=
+ APP_STORE_COMPLIANCE_PATCH_FLAGS=
+ AC_MSG_RESULT([not patching for app store compliance])
+ ;;
+ esac
+])
+AC_SUBST([APP_STORE_COMPLIANCE_PATCH])
+AC_SUBST([APP_STORE_COMPLIANCE_PATCH_TARGET])
+AC_SUBST([APP_STORE_COMPLIANCE_PATCH_FLAGS])
+
AC_SUBST([_PYTHON_HOST_PLATFORM])
if test "$cross_compiling" = yes; then
case "$host" in
1
0
[3.13] GH-119054: Add alt text to pathlib inheritance diagram (GH-121158) (#121168)
by barneygale 29 Jun '24
by barneygale 29 Jun '24
29 Jun '24
https://github.com/python/cpython/commit/00b071137bbae800d6b82596f156a51287…
commit: 00b071137bbae800d6b82596f156a51287708215
branch: 3.13
author: Miss Islington (bot) <31488909+miss-islington(a)users.noreply.github.com>
committer: barneygale <barney.gale(a)gmail.com>
date: 2024-06-29T18:02:53Z
summary:
[3.13] GH-119054: Add alt text to pathlib inheritance diagram (GH-121158) (#121168)
GH-119054: Add alt text to pathlib inheritance diagram (GH-121158)
(cherry picked from commit 6b280a84988ca221b5bdc1077a914e873790cce5)
Co-authored-by: Barney Gale <barney.gale(a)gmail.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk(a)users.noreply.github.com>
files:
M Doc/library/pathlib.rst
diff --git a/Doc/library/pathlib.rst b/Doc/library/pathlib.rst
index 166d8e31734fb0..6c3503a60e6e5e 100644
--- a/Doc/library/pathlib.rst
+++ b/Doc/library/pathlib.rst
@@ -21,6 +21,12 @@ inherit from pure paths but also provide I/O operations.
.. image:: pathlib-inheritance.png
:align: center
:class: invert-in-dark-mode
+ :alt: Inheritance diagram showing the classes available in pathlib. The
+ most basic class is PurePath, which has three direct subclasses:
+ PurePosixPath, PureWindowsPath, and Path. Further to these four
+ classes, there are two classes that use multiple inheritance:
+ PosixPath subclasses PurePosixPath and Path, and WindowsPath
+ subclasses PureWindowsPath and Path.
If you've never used this module before or just aren't sure which class is
right for your task, :class:`Path` is most likely what you need. It instantiates
1
0