online_help#

scikitplot.online_help(query='', docs_root_url='https://scikit-plots.github.io/', search_page='search.html', new_window=0)[source]#

Open the online documentation search page in the default web browser.

Parameters:
querystr, optional

The search query. Defaults to "".

docs_root_urlstr, optional

Base URL of the documentation website. Overridden by the DOCS_ROOT_URL environment variable when set. Defaults to "https://scikit-plots.github.io/".

search_pagestr, optional

Search page path relative to docs_root_url. Defaults to "search.html".

new_windowint, optional

Browser open mode — 0 same window, 1 new window, 2 new tab. Defaults to 0.

Returns:
bool

True if the browser was successfully launched, False otherwise.

Raises:
Does not raise — all errors are caught and logged; returns False.
Parameters:
  • query (str)

  • docs_root_url (str)

  • search_page (str)

  • new_window (int)

Return type:

bool

Notes

User: Requires an active internet connection. The URL printed to stderr shows the exact page that will open.

Developer: URL construction is intentionally separated into _validate_base_url and _build_docs_url so that each concern is independently testable and the security boundary is explicit. os.getenv is resolved before validation so that an unsafe env value is rejected with a clear error rather than silently used.

Examples

>>> import scikitplot
>>> scikitplot.online_help("installation")
https://scikit-plots.github.io/dev/search.html?q=installation