Skip to content

Commit 3a9d6a4

Browse files
committed
Documentation update for 3.12.1
1 parent afb6380 commit 3a9d6a4

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+420
-463
lines changed

_inheritance.html

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@
55
<meta charset="utf-8" />
66
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="viewport" content="width=device-width, initial-scale=1" />
77

8-
<title>Test Suite Inheritance Diagram &#8212; Blivet 3.12.0 documentation</title>
8+
<title>Test Suite Inheritance Diagram &#8212; Blivet 3.12.1 documentation</title>
99
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
10-
<link rel="stylesheet" type="text/css" href="_static/classic.css?v=def86cc0" />
10+
<link rel="stylesheet" type="text/css" href="_static/classic.css?v=514cf933" />
1111

12-
<script src="_static/documentation_options.js?v=1b7a0a1e"></script>
13-
<script src="_static/doctools.js?v=9a2dae69"></script>
12+
<script src="_static/documentation_options.js?v=bf028e07"></script>
13+
<script src="_static/doctools.js?v=888ff710"></script>
1414
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
1515

1616
<link rel="index" title="Index" href="genindex.html" />
@@ -25,7 +25,7 @@ <h3>Navigation</h3>
2525
<li class="right" >
2626
<a href="py-modindex.html" title="Python Module Index"
2727
>modules</a> |</li>
28-
<li class="nav-item nav-item-0"><a href="index.html">Blivet 3.12.0 documentation</a> &#187;</li>
28+
<li class="nav-item nav-item-0"><a href="index.html">Blivet 3.12.1 documentation</a> &#187;</li>
2929
<li class="nav-item nav-item-this"><a href="">Test Suite Inheritance Diagram</a></li>
3030
</ul>
3131
</div>
@@ -66,15 +66,15 @@ <h3>This Page</h3>
6666
rel="nofollow">Show Source</a></li>
6767
</ul>
6868
</div>
69-
<search id="searchbox" style="display: none" role="search">
69+
<div id="searchbox" style="display: none" role="search">
7070
<h3 id="searchlabel">Quick search</h3>
7171
<div class="searchformwrapper">
7272
<form class="search" action="search.html" method="get">
7373
<input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
7474
<input type="submit" value="Go" />
7575
</form>
7676
</div>
77-
</search>
77+
</div>
7878
<script>document.getElementById('searchbox').style.display = "block"</script>
7979
</div>
8080
</div>
@@ -89,13 +89,13 @@ <h3>Navigation</h3>
8989
<li class="right" >
9090
<a href="py-modindex.html" title="Python Module Index"
9191
>modules</a> |</li>
92-
<li class="nav-item nav-item-0"><a href="index.html">Blivet 3.12.0 documentation</a> &#187;</li>
92+
<li class="nav-item nav-item-0"><a href="index.html">Blivet 3.12.1 documentation</a> &#187;</li>
9393
<li class="nav-item nav-item-this"><a href="">Test Suite Inheritance Diagram</a></li>
9494
</ul>
9595
</div>
9696
<div class="footer" role="contentinfo">
9797
&#169; Copyright 2013-2025, Red Hat, Inc..
98-
Created using <a href="https://www.sphinx-doc.org/">Sphinx</a> 7.3.7.
98+
Created using <a href="https://www.sphinx-doc.org/">Sphinx</a> 7.2.6.
9999
</div>
100100
</body>
101101
</html>

_static/basic.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*
55
* Sphinx stylesheet -- basic theme.
66
*
7-
* :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS.
7+
* :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
88
* :license: BSD, see LICENSE for details.
99
*
1010
*/

_static/classic.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*
55
* Sphinx stylesheet -- classic theme.
66
*
7-
* :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS.
7+
* :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
88
* :license: BSD, see LICENSE for details.
99
*
1010
*/

_static/doctools.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*
55
* Base JavaScript utilities for all Sphinx HTML documentation.
66
*
7-
* :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS.
7+
* :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
88
* :license: BSD, see LICENSE for details.
99
*
1010
*/

_static/documentation_options.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
const DOCUMENTATION_OPTIONS = {
2-
VERSION: '3.12.0',
2+
VERSION: '3.12.1',
33
LANGUAGE: 'en',
44
COLLAPSE_INDEX: false,
55
BUILDER: 'html',

_static/language_data.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@
55
* This script contains the language-specific data used by searchtools.js,
66
* namely the list of stopwords, stemmer, scorer and splitter.
77
*
8-
* :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS.
8+
* :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
99
* :license: BSD, see LICENSE for details.
1010
*
1111
*/
1212

1313
var stopwords = ["a", "and", "are", "as", "at", "be", "but", "by", "for", "if", "in", "into", "is", "it", "near", "no", "not", "of", "on", "or", "such", "that", "the", "their", "then", "there", "these", "they", "this", "to", "was", "will", "with"];
1414

1515

16-
/* Non-minified version is copied as a separate JS file, if available */
16+
/* Non-minified version is copied as a separate JS file, is available */
1717

1818
/**
1919
* Porter Stemmer

_static/searchtools.js

Lines changed: 60 additions & 105 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*
55
* Sphinx JavaScript utilities for the full-text search.
66
*
7-
* :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS.
7+
* :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
88
* :license: BSD, see LICENSE for details.
99
*
1010
*/
@@ -99,7 +99,7 @@ const _displayItem = (item, searchTerms, highlightTerms) => {
9999
.then((data) => {
100100
if (data)
101101
listItem.appendChild(
102-
Search.makeSearchSummary(data, searchTerms, anchor)
102+
Search.makeSearchSummary(data, searchTerms)
103103
);
104104
// highlight search terms in the summary
105105
if (SPHINX_HIGHLIGHT_ENABLED) // set in sphinx_highlight.js
@@ -116,8 +116,8 @@ const _finishSearch = (resultCount) => {
116116
);
117117
else
118118
Search.status.innerText = _(
119-
"Search finished, found ${resultCount} page(s) matching the search query."
120-
).replace('${resultCount}', resultCount);
119+
`Search finished, found ${resultCount} page(s) matching the search query.`
120+
);
121121
};
122122
const _displayNextItem = (
123123
results,
@@ -137,22 +137,6 @@ const _displayNextItem = (
137137
// search finished, update title and status message
138138
else _finishSearch(resultCount);
139139
};
140-
// Helper function used by query() to order search results.
141-
// Each input is an array of [docname, title, anchor, descr, score, filename].
142-
// Order the results by score (in opposite order of appearance, since the
143-
// `_displayNextItem` function uses pop() to retrieve items) and then alphabetically.
144-
const _orderResultsByScoreThenName = (a, b) => {
145-
const leftScore = a[4];
146-
const rightScore = b[4];
147-
if (leftScore === rightScore) {
148-
// same score: sort alphabetically
149-
const leftTitle = a[1].toLowerCase();
150-
const rightTitle = b[1].toLowerCase();
151-
if (leftTitle === rightTitle) return 0;
152-
return leftTitle > rightTitle ? -1 : 1; // inverted is intentional
153-
}
154-
return leftScore > rightScore ? 1 : -1;
155-
};
156140

157141
/**
158142
* Default splitQuery function. Can be overridden in ``sphinx.search`` with a
@@ -176,26 +160,13 @@ const Search = {
176160
_queued_query: null,
177161
_pulse_status: -1,
178162

179-
htmlToText: (htmlString, anchor) => {
163+
htmlToText: (htmlString) => {
180164
const htmlElement = new DOMParser().parseFromString(htmlString, 'text/html');
181-
for (const removalQuery of [".headerlinks", "script", "style"]) {
182-
htmlElement.querySelectorAll(removalQuery).forEach((el) => { el.remove() });
183-
}
184-
if (anchor) {
185-
const anchorContent = htmlElement.querySelector(`[role="main"] ${anchor}`);
186-
if (anchorContent) return anchorContent.textContent;
187-
188-
console.warn(
189-
`Anchored content block not found. Sphinx search tries to obtain it via DOM query '[role=main] ${anchor}'. Check your theme or template.`
190-
);
191-
}
192-
193-
// if anchor not specified or not found, fall back to main content
165+
htmlElement.querySelectorAll(".headerlink").forEach((el) => { el.remove() });
194166
const docContent = htmlElement.querySelector('[role="main"]');
195-
if (docContent) return docContent.textContent;
196-
167+
if (docContent !== undefined) return docContent.textContent;
197168
console.warn(
198-
"Content block not found. Sphinx search tries to obtain it via DOM query '[role=main]'. Check your theme or template."
169+
"Content block not found. Sphinx search tries to obtain it via '[role=main]'. Could you check your theme or template."
199170
);
200171
return "";
201172
},
@@ -268,7 +239,16 @@ const Search = {
268239
else Search.deferQuery(query);
269240
},
270241

271-
_parseQuery: (query) => {
242+
/**
243+
* execute search (requires search index to be loaded)
244+
*/
245+
query: (query) => {
246+
const filenames = Search._index.filenames;
247+
const docNames = Search._index.docnames;
248+
const titles = Search._index.titles;
249+
const allTitles = Search._index.alltitles;
250+
const indexEntries = Search._index.indexentries;
251+
272252
// stem the search terms and add them to the correct list
273253
const stemmer = new Stemmer();
274254
const searchTerms = new Set();
@@ -304,32 +284,16 @@ const Search = {
304284
// console.info("required: ", [...searchTerms]);
305285
// console.info("excluded: ", [...excludedTerms]);
306286

307-
return [query, searchTerms, excludedTerms, highlightTerms, objectTerms];
308-
},
309-
310-
/**
311-
* execute search (requires search index to be loaded)
312-
*/
313-
_performSearch: (query, searchTerms, excludedTerms, highlightTerms, objectTerms) => {
314-
const filenames = Search._index.filenames;
315-
const docNames = Search._index.docnames;
316-
const titles = Search._index.titles;
317-
const allTitles = Search._index.alltitles;
318-
const indexEntries = Search._index.indexentries;
319-
320-
// Collect multiple result groups to be sorted separately and then ordered.
321-
// Each is an array of [docname, title, anchor, descr, score, filename].
322-
const normalResults = [];
323-
const nonMainIndexResults = [];
324-
287+
// array of [docname, title, anchor, descr, score, filename]
288+
let results = [];
325289
_removeChildren(document.getElementById("search-progress"));
326290

327-
const queryLower = query.toLowerCase().trim();
291+
const queryLower = query.toLowerCase();
328292
for (const [title, foundTitles] of Object.entries(allTitles)) {
329-
if (title.toLowerCase().trim().includes(queryLower) && (queryLower.length >= title.length/2)) {
293+
if (title.toLowerCase().includes(queryLower) && (queryLower.length >= title.length/2)) {
330294
for (const [file, id] of foundTitles) {
331295
let score = Math.round(100 * queryLower.length / title.length)
332-
normalResults.push([
296+
results.push([
333297
docNames[file],
334298
titles[file] !== title ? `${titles[file]} > ${title}` : title,
335299
id !== null ? "#" + id : "",
@@ -344,47 +308,46 @@ const Search = {
344308
// search for explicit entries in index directives
345309
for (const [entry, foundEntries] of Object.entries(indexEntries)) {
346310
if (entry.includes(queryLower) && (queryLower.length >= entry.length/2)) {
347-
for (const [file, id, isMain] of foundEntries) {
348-
const score = Math.round(100 * queryLower.length / entry.length);
349-
const result = [
311+
for (const [file, id] of foundEntries) {
312+
let score = Math.round(100 * queryLower.length / entry.length)
313+
results.push([
350314
docNames[file],
351315
titles[file],
352316
id ? "#" + id : "",
353317
null,
354318
score,
355319
filenames[file],
356-
];
357-
if (isMain) {
358-
normalResults.push(result);
359-
} else {
360-
nonMainIndexResults.push(result);
361-
}
320+
]);
362321
}
363322
}
364323
}
365324

366325
// lookup as object
367326
objectTerms.forEach((term) =>
368-
normalResults.push(...Search.performObjectSearch(term, objectTerms))
327+
results.push(...Search.performObjectSearch(term, objectTerms))
369328
);
370329

371330
// lookup as search terms in fulltext
372-
normalResults.push(...Search.performTermsSearch(searchTerms, excludedTerms));
331+
results.push(...Search.performTermsSearch(searchTerms, excludedTerms));
373332

374333
// let the scorer override scores with a custom scoring function
375-
if (Scorer.score) {
376-
normalResults.forEach((item) => (item[4] = Scorer.score(item)));
377-
nonMainIndexResults.forEach((item) => (item[4] = Scorer.score(item)));
378-
}
379-
380-
// Sort each group of results by score and then alphabetically by name.
381-
normalResults.sort(_orderResultsByScoreThenName);
382-
nonMainIndexResults.sort(_orderResultsByScoreThenName);
383-
384-
// Combine the result groups in (reverse) order.
385-
// Non-main index entries are typically arbitrary cross-references,
386-
// so display them after other results.
387-
let results = [...nonMainIndexResults, ...normalResults];
334+
if (Scorer.score) results.forEach((item) => (item[4] = Scorer.score(item)));
335+
336+
// now sort the results by score (in opposite order of appearance, since the
337+
// display function below uses pop() to retrieve items) and then
338+
// alphabetically
339+
results.sort((a, b) => {
340+
const leftScore = a[4];
341+
const rightScore = b[4];
342+
if (leftScore === rightScore) {
343+
// same score: sort alphabetically
344+
const leftTitle = a[1].toLowerCase();
345+
const rightTitle = b[1].toLowerCase();
346+
if (leftTitle === rightTitle) return 0;
347+
return leftTitle > rightTitle ? -1 : 1; // inverted is intentional
348+
}
349+
return leftScore > rightScore ? 1 : -1;
350+
});
388351

389352
// remove duplicate search results
390353
// note the reversing of results, so that in the case of duplicates, the highest-scoring entry is kept
@@ -398,12 +361,7 @@ const Search = {
398361
return acc;
399362
}, []);
400363

401-
return results.reverse();
402-
},
403-
404-
query: (query) => {
405-
const [searchQuery, searchTerms, excludedTerms, highlightTerms, objectTerms] = Search._parseQuery(query);
406-
const results = Search._performSearch(searchQuery, searchTerms, excludedTerms, highlightTerms, objectTerms);
364+
results = results.reverse();
407365

408366
// for debugging
409367
//Search.lastresults = results.slice(); // a copy
@@ -508,18 +466,14 @@ const Search = {
508466
// add support for partial matches
509467
if (word.length > 2) {
510468
const escapedWord = _escapeRegExp(word);
511-
if (!terms.hasOwnProperty(word)) {
512-
Object.keys(terms).forEach((term) => {
513-
if (term.match(escapedWord))
514-
arr.push({ files: terms[term], score: Scorer.partialTerm });
515-
});
516-
}
517-
if (!titleTerms.hasOwnProperty(word)) {
518-
Object.keys(titleTerms).forEach((term) => {
519-
if (term.match(escapedWord))
520-
arr.push({ files: titleTerms[term], score: Scorer.partialTitle });
521-
});
522-
}
469+
Object.keys(terms).forEach((term) => {
470+
if (term.match(escapedWord) && !terms[word])
471+
arr.push({ files: terms[term], score: Scorer.partialTerm });
472+
});
473+
Object.keys(titleTerms).forEach((term) => {
474+
if (term.match(escapedWord) && !titleTerms[word])
475+
arr.push({ files: titleTerms[word], score: Scorer.partialTitle });
476+
});
523477
}
524478

525479
// no match but word was a required one
@@ -542,8 +496,9 @@ const Search = {
542496

543497
// create the mapping
544498
files.forEach((file) => {
545-
if (!fileMap.has(file)) fileMap.set(file, [word]);
546-
else if (fileMap.get(file).indexOf(word) === -1) fileMap.get(file).push(word);
499+
if (fileMap.has(file) && fileMap.get(file).indexOf(word) === -1)
500+
fileMap.get(file).push(word);
501+
else fileMap.set(file, [word]);
547502
});
548503
});
549504

@@ -594,8 +549,8 @@ const Search = {
594549
* search summary for a given text. keywords is a list
595550
* of stemmed words.
596551
*/
597-
makeSearchSummary: (htmlText, keywords, anchor) => {
598-
const text = Search.htmlToText(htmlText, anchor);
552+
makeSearchSummary: (htmlText, keywords) => {
553+
const text = Search.htmlToText(htmlText);
599554
if (text === "") return null;
600555

601556
const textLower = text.toLowerCase();

_static/sidebar.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
* Once the browser is closed the cookie is deleted and the position
1717
* reset to the default (expanded).
1818
*
19-
* :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS.
19+
* :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
2020
* :license: BSD, see LICENSE for details.
2121
*
2222
*/

0 commit comments

Comments
 (0)