@@ -543,7 +543,19 @@ loading of the settings from the settings file, assuming it exists.
543543(Failure to find the file at the indicated path will be logged as a
544544warning.)
545545
546- Settings can also be saved and loaded manually using the ` save() ` and
546+ If the process of loading configuration settings generates an unhandled exception,
547+ the ` irods ` module will consult the value of the environment variable
548+ ` PYTHON_IRODSCLIENT_CONFIGURATION_LOAD_ERRORS_FATAL ` and either (if ` True ` ) incur
549+ a fatal error or (if ` False ` ) simply log it as a warning. By default this
550+ environment variable is taken as ` False ` if not set, although that is likely to
551+ change to ` True ` in the future.
552+ This decision indicates a desire by the client library's designers to flag such
553+ errors as fatal by aborting the process if possible, rather than aquiescing silently
554+ to an unintended consequence. It is recommended that all client library users
555+ set this environment variable to ` True ` if their applications load settings
556+ from the environment or configuration files.
557+
558+ Settings can be saved and loaded manually using the ` save() ` and
547559` load() ` functions in the ` irods.client_configuration `
548560module. Each of these functions accepts an optional ` file `
549561parameter which, if set to a non-empty string, will override the
@@ -609,6 +621,12 @@ certain environment variables:
609621 - Default Value: ` False `
610622 - Environment Variable Override: ` PYTHON_IRODSCLIENT_CONFIG__LEGACY_AUTH__PAM__FORCE_USE_OF_DEDICATED_PAM_API `
611623
624+ - Setting: The maximum number of rows a Query iteration will retrieve. Can be overridden using Query's ` limit ` method. This is synonymous with the variable ` irods.query.IRODS_QUERY_LIMIT ` , and a read (or write) of this configuration setting will read (or affect) that variable.
625+ - Dotted Name: ` genquery1.irods_query_limit `
626+ - Type: ` int `
627+ - Default Value: 500 (The library's traditional maximum batch row count, also stored as ` irods.query._IRODS_QUERY_LIMIT ` )
628+ - Environment Variable Override: ` PYTHON_IRODSCLIENT_CONFIG__GENQUERY1__IRODS_QUERY_LIMIT `
629+
612630- Setting: Default choice of XML parser for all new threads.
613631 - Dotted Name: ` connections.xml_parser_default `
614632 - Type: ` str `
@@ -1176,8 +1194,8 @@ Also, core.py rules may only be run directly by a rodsadmin, currently.
11761194[See this issue for discussion](https:// github.com/ irods/ irods_rule_engine_plugin_python/ issues/ 105 ).
11771195
11781196
1179- General Queries
1180- -------------- -
1197+ GenQuery1 Queries
1198+ ---------------- -
11811199
11821200A session object ' s `query` method accepts a list of columns and models to be included in any returned rows.
11831201
@@ -1285,6 +1303,25 @@ parameter to the query:
12851303+ -------------------- -+
12861304```
12871305
1306+ If the user desires a smaller paging size, this can be accomplished by changing
1307+ the `genquery1.irods_query_limit` configuration setting. This directly changes
1308+ the `irods.query.IRODS_QUERY_LIMIT ` value and therefore affects Query objects'
1309+ `all ` and `get_batches` methods.
1310+
1311+ Note, however, that expressions such as `list (Query(... ))` and `(row for row in
1312+ Query)` are not affected by this setting.
1313+
1314+ The setting may be given any positive integer value. Attempting to set it to
1315+ zero or a negative number will not affect the value of `IRODS_QUERY_LIMIT ` but will
1316+ raise a `ConfigurationValueError` if done in the course of a running iRODS
1317+ client application. Importantly, if the invalid setting is attempted by a loading
1318+ configuration, the otherwise fatal error could be absorbed into a warning- level log action,
1319+ depending on the value of the `PYTHON_IRODSCLIENT_CONFIGURATION_LOAD_ERRORS_FATAL `
1320+ environment variable. See: [Python iRODS Client Settings File](# python-irods-client-settings-file).
1321+
1322+ A copy of the original value of `IRODS_QUERY_LIMIT ` (before overriding values are loaded from the
1323+ configuration) is stored within `irods.query.cached_values.IRODS_QUERY_LIMIT ` .
1324+
12881325Specific Queries
12891326----------------
12901327
0 commit comments