Configparserenhanced

Latest version: v0.8.1.5

Safety actively analyzes 682471 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 3 of 4

0.4.0

Removed the regular expression based splitting method for keys into tokens
for the use of `shlex.split`, which looks to do a better job of extracting
tokens in the manner we would like without requiring a complex REGEX.

HandlerParameters was also changed to remove `op_params` in favor of two new
properties: `op` and `params`, where `op` is a string and `params` is a list
of strings.

Added
- HandlerParams property: `HandlerParams.op`
- HandlerParams property: `HandlerParams.params`
Changed
Deprecated
Removed
- ConfigParserEnhanced method: `ConfigParserEnhanced._regex_splitter()`
- ConfigParserEnhanced method: `ConfigParserEnhanced._regex_op_matcher()`
- ConfigParserEnhanced method: `ConfigParserEnhanced._get_op1_from_regex_match()`
- ConfigParserEnhanced method: `ConfigParserEnhanced._get_op2_from_regex_match()`
- HandlerParameters property : `HandlerParams.op_params`
Fixed
Internal
Security

0.3.1

Added
Changed
Deprecated
Removed
Fixed
- Issue 10: Bugfix: dots `.` in section names confused the `use` command.
Internal
- Add `_validate_parameter` internal function to wrap the parameter
check operation that we do around the code. This simplifies some
of the coverage issues and also makes it easier to put more type
checks around parameters.
Security

0.3.0

Added
- `ConfigParserEnhanced.parse_all_sections()` added as a shortcut to kick off
a full parse of ALL sections in the .ini file.
Changed
- Changed `ConfigParserEnhancedData.data` property to include an empty "DEFAULT"
section if none is provided by the .ini file. This is to maintain compatibility
with `ConfigParser`.
- Changed `ConfigParserEnhancedData.get(section, option)` to
`ConfigParserEnhancedData::get(section, option=None)`. Now `option` can be
an optional parameter and will return a `dict` containing the section's
keys if only a `section` is provided.
Deprecated
Removed
Fixed
Security

0.2.1

Added
- New private method: `_loginfo_reset`. This removes the `_loginfo` attribute.
- New internal method `_apply_transformation_to_operation()`.
Applies any needed transformations to the raw `<operation>` strings.
Currently this just replaces occurrences of `-` with `_` to operations.
- New internal method `_apply_transformation_to_parameter()`.
Applies any needed transformations to the raw `<parameter>` strings.
Currently this is just a pass-through, added now to pair with
`_apply_transformation_to_operation()`.
Changed
- Add parameter `parse` to `ConfigParserEnhancedData.sections` which can be
either `True`, `False`, or `"force"`.
- If `False` then requesting `configparserenhanceddata.sections()` will give
the list of sections in the .ini file without parseing them.
- If `True` then requesting `configparserenhanceddata.sections()` will give
the list of sections in the .ini file but it will also kick off the parser
to parse (and cache) them.
- If `"force"` then requesting `configparserenhanceddata.sections()` will
FORCE a (re)parse of the sections in the .ini file.
- Add parameter `force_parse` to `ConfigParserEnhancedData._parse_owner_sections()`
in support of new `parse` parameter to `ConfigParserEnhancedData.sections`.
- `operations` have added processing to do some normalization. Currently
this is just a replacement of any `-` with `_`. For example, an
operation such as `foo-bar-baz` will be converted to `foo_bar_baz`
internally.
Deprecated
Removed
Fixed
- Fix a bug in the indexing in the `ExceptionControl` module to print out the
correct stack entry showing where `exception_control_event` was called that
triggered the event in the traceback when `exception_control_compact_warnings`
is enabled.
Security

0.2.0

Added
Changed
- `ExceptionControl`
- Add property `_exception_control_map_event_to_level_req` to `ExceptionControl`
which maps the exception control levels to the type names.
- Add new class of `exception_control_event`: "CATASTROPHIC" which indicates
errors that will _always_ raise the exception and cannot be overridden.
- Added property `exception_control_silent_warnings` to `ExceptionControl`
to enable silencing events that would only print out a warning message.
- Added property `exception_control_compact_warnings` to `ExceptionControl`
to enable _compact_ one-line warning messages instead of the full message and
stack trace that is normally generated.
- Renamed `generic_handler` to `_generic_option_handler` because that name
could inadvertantly cause a `.ini` file option such as
`generic command: should not invoke a handler` to invoke the `generic_handler`
but it would go through the _handled operation_ code path and not the true _generic_
command code path.
Deprecated
Removed
Fixed
Security

0.1.4

Added
- New *property* to `ConfigParserEnhanced`: `parse_section_last_result`.
This property gives access to the results from the _last_ call to
`parse_section()`.
Changed
- `ConfigParserEnhanced.__init__` signature changed. The `filename` parameter
is now optional at construction time. It can be still be set via the `inifilepath`
property.
- Parses of sections kicked off via the inner class `ConfigParserEnhancedData`
such as `parser.configparserenhanceddata[section]` will no longer
tell `parse_section` to skip calling `handler_initialize` and `handler_finalize`.
The output of this call won't change, but this will affect the state of
`handler_parameters.data_shared`, and what is returned by `parse_section_last_result`.
Deprecated
Removed
Fixed
Security

Page 3 of 4

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.