document pyloglevel and pylogfilename

This commit is contained in:
Jean-Francois Dockes 2019-08-26 08:35:34 +02:00
parent d4c099ab59
commit bf5f74bc13
4 changed files with 98 additions and 63 deletions

View File

@ -38,6 +38,11 @@ list. </para></listitem></varlistentry>
<term><varname>skippedNames+</varname></term>
<listitem><para>List of name endings to add to the default skippedNames
list. </para></listitem></varlistentry>
<varlistentry id="RCL.INSTALL.CONFIG.RECOLLCONF.ONLYNAMES">
<term><varname>onlyNames</varname></term>
<listitem><para>Regular file name filter patterns If this is set, only the file names not in skippedNames and
matching one of the patterns will be considered for indexing. Can be
redefined per subtree. Does not apply to directories.</para></listitem></varlistentry>
<varlistentry id="RCL.INSTALL.CONFIG.RECOLLCONF.NOCONTENTSUFFIXES">
<term><varname>noContentSuffixes</varname></term>
<listitem><para>List of name endings (not necessarily dot-separated suffixes) for
@ -526,6 +531,12 @@ the log... values.</para></listitem></varlistentry>
<listitem><para>Override logfilename for the indexer in real time
mode. The default is to use the idx... values if set, else
the log... values.</para></listitem></varlistentry>
<varlistentry id="RCL.INSTALL.CONFIG.RECOLLCONF.PYLOGLEVEL">
<term><varname>pyloglevel</varname></term>
<listitem><para>Override loglevel for the python module. </para></listitem></varlistentry>
<varlistentry id="RCL.INSTALL.CONFIG.RECOLLCONF.PYLOGFILENAME">
<term><varname>pylogfilename</varname></term>
<listitem><para>Override logfilename for the python module. </para></listitem></varlistentry>
<varlistentry id="RCL.INSTALL.CONFIG.RECOLLCONF.ORGIDXCONFDIR">
<term><varname>orgidxconfdir</varname></term>
<listitem><para>Original location of the configuration directory. This is used exclusively for movable datasets. Locating the

View File

@ -337,12 +337,15 @@ alink="#0000FF">
"#RCL.PROGRAM.PYTHONAPI.ELEMENTS">Interface
elements</a></span></dt>
<dt><span class="sect2">4.3.3. <a href=
"#RCL.PROGRAM.PYTHONAPI.LOG">Log messages for
Python scripts</a></span></dt>
<dt><span class="sect2">4.3.4. <a href=
"#RCL.PROGRAM.PYTHONAPI.SEARCH">Python search
interface</a></span></dt>
<dt><span class="sect2">4.3.4. <a href=
<dt><span class="sect2">4.3.5. <a href=
"#RCL.PROGRAM.PYTHONAPI.UPDATE">Creating Python
external indexers</a></span></dt>
<dt><span class="sect2">4.3.5. <a href=
<dt><span class="sect2">4.3.6. <a href=
"#RCL.PROGRAM.PYTHONAPI.COMPAT">Package
compatibility with the previous
version</a></span></dt>
@ -6530,34 +6533,9 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
conjunction with regular ones, through the GUI or any of
the query interfaces.</p>
<p>The search API is modeled along the Python database
API specification. There were two major changes along
<span class="application">Recoll</span> versions:</p>
<div class="itemizedlist">
<ul class="itemizedlist" style=
"list-style-type: disc;">
<li class="listitem">
<p>The basis for the <span class=
"application">Recoll</span> API changed from Python
database API version 1.0 (<span class=
"application">Recoll</span> versions up to 1.18.1),
to version 2.0 (<span class=
"application">Recoll</span> 1.18.2 and later).</p>
</li>
<li class="listitem">
<p>The <code class="literal">recoll</code> module
became a package (with an internal <code class=
"literal">recoll</code> module) as of <span class=
"application">Recoll</span> version 1.19, in order
to add more functions. For existing code, this only
changes the way the interface must be imported.</p>
</li>
</ul>
</div>
<p>We will describe the new API and package structure
here. A paragraph at the end of this section will explain
a few differences and ways to write code compatible with
both versions.</p>
<p>The <code class="literal">recoll</code> package now
API version 2.0 specification (early versions used the
version 1.0 spec).</p>
<p>The <code class="literal">recoll</code> package
contains two modules:</p>
<div class="itemizedlist">
<ul class="itemizedlist" style=
@ -6570,7 +6548,9 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
<li class="listitem">
<p>The <code class="literal">rclextract</code>
module contains functions and classes used at query
time to access document data.</p>
time to access document data. The <code class=
"literal">recoll</code> module must be imported
before <code class="literal">rclextract</code></p>
</li>
</ul>
</div>
@ -6583,13 +6563,11 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
chapter</a>.</p>
<p>As an introduction, the following small sample will
run a query and list the title and url for each of the
results. It would work with <span class=
"application">Recoll</span> 1.19 and later. The
<code class="filename">python/samples</code> source
directory contains several examples of Python programming
with <span class="application">Recoll</span>, exercising
the extension more completely, and especially its data
extraction features.</p>
results. The <code class="filename">python/samples</code>
source directory contains several examples of Python
programming with <span class="application">Recoll</span>,
exercising the extension more completely, and especially
its data extraction features.</p>
<pre class="programlisting">
#!/usr/bin/env python
@ -6730,13 +6708,31 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
</dl>
</div>
</div>
<div class="sect2">
<div class="titlepage">
<div>
<div>
<h3 class="title"><a name=
"RCL.PROGRAM.PYTHONAPI.LOG" id=
"RCL.PROGRAM.PYTHONAPI.LOG"></a>4.3.3.&nbsp;Log
messages for Python scripts</h3>
</div>
</div>
</div>
<p>Two specific configuration variables: <code class=
"literal">pyloglevel</code> and <code class=
"literal">pylogfilename</code> allow overriding the
generic values for Python programs. Set <code class=
"literal">pyloglevel</code> to 2 to suppress default
startup messages (printed at level 3).</p>
</div>
<div class="sect2">
<div class="titlepage">
<div>
<div>
<h3 class="title"><a name=
"RCL.PROGRAM.PYTHONAPI.SEARCH" id=
"RCL.PROGRAM.PYTHONAPI.SEARCH"></a>4.3.3.&nbsp;Python
"RCL.PROGRAM.PYTHONAPI.SEARCH"></a>4.3.4.&nbsp;Python
search interface</h3>
</div>
</div>
@ -7307,7 +7303,7 @@ for i in range(nres):
<div>
<h3 class="title"><a name=
"RCL.PROGRAM.PYTHONAPI.UPDATE" id=
"RCL.PROGRAM.PYTHONAPI.UPDATE"></a>4.3.4.&nbsp;Creating
"RCL.PROGRAM.PYTHONAPI.UPDATE"></a>4.3.5.&nbsp;Creating
Python external indexers</h3>
</div>
</div>
@ -7529,7 +7525,7 @@ for i in range(nres):
<div>
<h3 class="title"><a name=
"RCL.PROGRAM.PYTHONAPI.COMPAT" id=
"RCL.PROGRAM.PYTHONAPI.COMPAT"></a>4.3.5.&nbsp;Package
"RCL.PROGRAM.PYTHONAPI.COMPAT"></a>4.3.6.&nbsp;Package
compatibility with the previous version</h3>
</div>
</div>
@ -8422,6 +8418,16 @@ for i in range(nres):
skippedNames list.</p>
</dd>
<dt><a name=
"RCL.INSTALL.CONFIG.RECOLLCONF.ONLYNAMES" id=
"RCL.INSTALL.CONFIG.RECOLLCONF.ONLYNAMES"></a><span class="term"><code class="varname">onlyNames</code></span></dt>
<dd>
<p>Regular file name filter patterns If this is
set, only the file names not in skippedNames and
matching one of the patterns will be considered
for indexing. Can be redefined per subtree. Does
not apply to directories.</p>
</dd>
<dt><a name=
"RCL.INSTALL.CONFIG.RECOLLCONF.NOCONTENTSUFFIXES"
id=
"RCL.INSTALL.CONFIG.RECOLLCONF.NOCONTENTSUFFIXES"></a><span class="term"><code class="varname">noContentSuffixes</code></span></dt>
@ -9268,6 +9274,19 @@ for i in range(nres):
values if set, else the log... values.</p>
</dd>
<dt><a name=
"RCL.INSTALL.CONFIG.RECOLLCONF.PYLOGLEVEL" id=
"RCL.INSTALL.CONFIG.RECOLLCONF.PYLOGLEVEL"></a><span class="term"><code class="varname">pyloglevel</code></span></dt>
<dd>
<p>Override loglevel for the python module.</p>
</dd>
<dt><a name=
"RCL.INSTALL.CONFIG.RECOLLCONF.PYLOGFILENAME" id=
"RCL.INSTALL.CONFIG.RECOLLCONF.PYLOGFILENAME"></a><span class="term"><code class="varname">pylogfilename</code></span></dt>
<dd>
<p>Override logfilename for the python
module.</p>
</dd>
<dt><a name=
"RCL.INSTALL.CONFIG.RECOLLCONF.ORGIDXCONFDIR" id=
"RCL.INSTALL.CONFIG.RECOLLCONF.ORGIDXCONFDIR"></a><span class="term"><code class="varname">orgidxconfdir</code></span></dt>
<dd>

View File

@ -5032,25 +5032,9 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
ones, through the GUI or any of the query interfaces.</para>
<para>The search API is modeled along the Python database API
specification. There were two major changes along &RCL; versions:
<itemizedlist>
<listitem><para>The basis for the &RCL; API changed from Python
database API version 1.0 (&RCL; versions up to 1.18.1),
to version 2.0 (&RCL; 1.18.2 and later).</para></listitem>
<listitem><para>The <literal>recoll</literal> module became a
package (with an internal <literal>recoll</literal>
module) as of &RCL; version 1.19, in order to add more
functions. For existing code, this only changes the way
the interface must be imported.</para></listitem>
</itemizedlist>
</para>
version 2.0 specification (early versions used the version 1.0 spec).</para>
<para>We will describe the new API and package structure here. A
paragraph at the end of this section will explain a few differences
and ways to write code compatible with both versions.</para>
<para>The <literal>recoll</literal> package now contains two
modules:</para>
<para>The <literal>recoll</literal> package contains two modules:</para>
<itemizedlist>
<listitem><para>The <literal>recoll</literal> module contains
functions and classes used to query (or update) the
@ -5058,7 +5042,8 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
<listitem><para>The <literal>rclextract</literal> module contains
functions and classes used at query time to access document
data.</para>
data. The <literal>recoll</literal> module must be imported
before <literal>rclextract</literal></para>
</listitem>
</itemizedlist>
@ -5068,8 +5053,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
refer to the <link linkend="RCL.INSTALL.BUILDING">Building from source chapter</link>.</para>
<para>As an introduction, the following small sample will run a
query and list the title and url for each of the results. It would
work with &RCL; 1.19 and later. The
query and list the title and url for each of the results. The
<filename>python/samples</filename> source directory contains
several examples of Python programming with &RCL;, exercising the
extension more completely, and especially its data extraction
@ -5186,6 +5170,17 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
</sect2>
<sect2 id="RCL.PROGRAM.PYTHONAPI.LOG">
<title>Log messages for Python scripts</title>
<para>Two specific configuration variables:
<literal>pyloglevel</literal> and <literal>pylogfilename</literal>
allow overriding the generic values for Python programs. Set
<literal>pyloglevel</literal> to 2 to suppress default startup messages
(printed at level 3).</para>
</sect2>
<sect2 id="RCL.PROGRAM.PYTHONAPI.SEARCH">
<title>Python search interface</title>

View File

@ -60,7 +60,7 @@ skippedNames- =
# list.</brief><descr></descr></var>
skippedNames+ =
# <var name="onlyNames" type="string>
# <var name="onlyNames" type="string">
# <brief>Regular file name filter patterns</brief>
# <descr>If this is set, only the file names not in skippedNames and
# matching one of the patterns will be considered for indexing. Can be
@ -655,6 +655,16 @@ logfilename = stderr
# the log... values.</descr></var>
#daemlogfilename = /dev/null
# <var name="pyloglevel" type="int">
#
# <brief>Override loglevel for the python module.</brief><descr></descr></var>
#pyloglevel = 3
# <var name="pylogfilename" type="fn">
#
# <brief>Override logfilename for the python module.</brief><descr></descr></var>
#pylogfilename = stderr
# <var name="orgidxconfdir" type="dfn">
#
# <brief>Original location of the configuration directory.</brief>