omegaconf 2.4.0.dev3__tar.gz → 2.4.0.dev4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {omegaconf-2.4.0.dev3/omegaconf.egg-info → omegaconf-2.4.0.dev4}/PKG-INFO +17 -4
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/build_helpers/build_helpers.py +9 -10
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/_utils.py +65 -3
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/basecontainer.py +2 -2
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/gen/OmegaConfGrammarLexer.py +1 -1
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/gen/OmegaConfGrammarParser.py +1 -1
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/gen/OmegaConfGrammarParserListener.py +1 -1
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/gen/OmegaConfGrammarParserVisitor.py +1 -1
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar_parser.py +4 -2
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar_visitor.py +1 -1
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/omegaconf.py +2 -2
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/version.py +4 -4
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4/omegaconf.egg-info}/PKG-INFO +17 -4
- omegaconf-2.4.0.dev4/pydevd_plugins/__init__.py +3 -0
- omegaconf-2.4.0.dev4/pydevd_plugins/extensions/__init__.py +3 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/pyproject.toml +1 -1
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/setup.py +4 -2
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/test_oc_decode.py +2 -2
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_errors.py +1 -1
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_grammar.py +2 -2
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_nodes.py +49 -2
- omegaconf-2.4.0.dev3/pydevd_plugins/__init__.py +0 -6
- omegaconf-2.4.0.dev3/pydevd_plugins/extensions/__init__.py +0 -6
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/LICENSE +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/MANIFEST.in +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/README.md +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/build_helpers/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/build_helpers/bin/antlr-4.11.1-complete.jar +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/build_helpers/get_vendored.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/build_helpers/test_helpers.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/_impl.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/base.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/dictconfig.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/errors.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/OmegaConfGrammarLexer.g4 +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/OmegaConfGrammarParser.g4 +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/gen/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/listconfig.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/nodes.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/py.typed +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/resolvers/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/resolvers/oc/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/resolvers/oc/dict.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/typing.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/BufferedTokenStream.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/CommonTokenFactory.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/CommonTokenStream.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/FileStream.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/InputStream.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/IntervalSet.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/LL1Analyzer.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/Lexer.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/ListTokenSource.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/Parser.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/ParserInterpreter.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/ParserRuleContext.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/PredictionContext.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/Recognizer.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/RuleContext.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/StdinStream.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/Token.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/TokenStreamRewriter.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/Utils.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/_pygrun.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATN.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATNConfig.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATNConfigSet.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATNDeserializationOptions.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATNDeserializer.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATNSimulator.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATNState.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATNType.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/LexerATNSimulator.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/LexerAction.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/LexerActionExecutor.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ParserATNSimulator.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/PredictionMode.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/SemanticContext.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/Transition.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/dfa/DFA.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/dfa/DFASerializer.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/dfa/DFAState.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/dfa/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/error/DiagnosticErrorListener.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/error/ErrorListener.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/error/ErrorStrategy.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/error/Errors.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/error/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/Chunk.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/ParseTreeMatch.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/ParseTreePattern.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/ParseTreePatternMatcher.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/RuleTagToken.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/TokenTagToken.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/Tree.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/Trees.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/xpath/XPath.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/xpath/XPathLexer.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/xpath/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf.egg-info/SOURCES.txt +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf.egg-info/dependency_links.txt +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf.egg-info/requires.txt +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf.egg-info/top_level.txt +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/pydevd_plugins/extensions/pydevd_plugin_omegaconf.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/requirements/base.txt +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/setup.cfg +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/conftest.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/data/2.0.6.pickle +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/data/2.1.0.rc1.pickle +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/data/load.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/data/save.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/examples/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/examples/dataclass_postponed_annotations.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/examples/test_dataclass_example.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/examples/test_postponed_annotations.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/test_oc_create.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/test_oc_deprecated.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/test_oc_dict.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/test_oc_env.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/test_oc_select.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/test_custom_resolvers.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/test_interpolation.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/data/__init__.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/data/attr_classes.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/data/dataclasses.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/data/dataclasses_pre_311.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/test_structured_basic.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/test_structured_config.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_base_config.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_basic_ops_dict.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_basic_ops_list.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_compare_dictconfig_vs_dict.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_config_eq.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_create.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_get_full_key.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_matrix.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_merge.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_nested_containers.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_omegaconf.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_pydev_resolver_plugin.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_readonly.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_select.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_serialization.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_struct.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_to_container.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_to_yaml.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_unions.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_update.py +0 -0
- {omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/test_utils.py +0 -0
|
@@ -1,23 +1,36 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: omegaconf
|
|
3
|
-
Version: 2.4.0.
|
|
3
|
+
Version: 2.4.0.dev4
|
|
4
4
|
Summary: A flexible configuration library
|
|
5
5
|
Home-page: https://github.com/omry/omegaconf
|
|
6
6
|
Author: Omry Yadan
|
|
7
7
|
Author-email: omry@yadan.net
|
|
8
8
|
Keywords: yaml configuration config
|
|
9
|
-
Classifier: Programming Language :: Python :: 3.8
|
|
10
9
|
Classifier: Programming Language :: Python :: 3.9
|
|
11
10
|
Classifier: Programming Language :: Python :: 3.10
|
|
12
11
|
Classifier: Programming Language :: Python :: 3.11
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
13
15
|
Classifier: License :: OSI Approved :: BSD License
|
|
14
16
|
Classifier: Operating System :: OS Independent
|
|
15
|
-
Requires-Python: >=3.
|
|
17
|
+
Requires-Python: >=3.9
|
|
16
18
|
Description-Content-Type: text/markdown
|
|
17
19
|
License-File: LICENSE
|
|
18
20
|
Requires-Dist: PyYAML>=5.1.0
|
|
19
21
|
Requires-Dist: dataclasses; python_version == "3.6"
|
|
20
22
|
Requires-Dist: typing-extensions; python_version <= "3.9"
|
|
23
|
+
Dynamic: author
|
|
24
|
+
Dynamic: author-email
|
|
25
|
+
Dynamic: classifier
|
|
26
|
+
Dynamic: description
|
|
27
|
+
Dynamic: description-content-type
|
|
28
|
+
Dynamic: home-page
|
|
29
|
+
Dynamic: keywords
|
|
30
|
+
Dynamic: license-file
|
|
31
|
+
Dynamic: requires-dist
|
|
32
|
+
Dynamic: requires-python
|
|
33
|
+
Dynamic: summary
|
|
21
34
|
|
|
22
35
|
# OmegaConf
|
|
23
36
|
| | Description |
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import codecs
|
|
2
1
|
import distutils.log
|
|
3
2
|
import errno
|
|
4
3
|
import os
|
|
@@ -64,26 +63,26 @@ class ANTLRCommand(Command): # type: ignore # pragma: no cover
|
|
|
64
63
|
build_dir = Path(__file__).parent.absolute()
|
|
65
64
|
project_root = build_dir.parent
|
|
66
65
|
lib = "antlr4"
|
|
67
|
-
pkgname =
|
|
66
|
+
pkgname = "omegaconf.vendor"
|
|
68
67
|
|
|
69
68
|
replacements = [
|
|
70
69
|
partial( # import antlr4 -> import omegaconf.vendor.antlr4
|
|
71
|
-
re.compile(r
|
|
72
|
-
r
|
|
70
|
+
re.compile(r"(^\s*)import {}\n".format(lib), flags=re.M).sub,
|
|
71
|
+
r"\1from {} import {}\n".format(pkgname, lib),
|
|
73
72
|
),
|
|
74
73
|
partial( # from antlr4 -> from fomegaconf.vendor.antlr4
|
|
75
|
-
re.compile(r
|
|
76
|
-
r
|
|
74
|
+
re.compile(r"(^\s*)from {}(\.|\s+)".format(lib), flags=re.M).sub,
|
|
75
|
+
r"\1from {}.{}\2".format(pkgname, lib),
|
|
77
76
|
),
|
|
78
77
|
]
|
|
79
78
|
|
|
80
79
|
path = project_root / "omegaconf" / "grammar" / "gen"
|
|
81
80
|
for item in path.iterdir():
|
|
82
81
|
if item.is_file() and item.name.endswith(".py"):
|
|
83
|
-
text = item.read_text(
|
|
82
|
+
text = item.read_text("utf8")
|
|
84
83
|
for replacement in replacements:
|
|
85
84
|
text = replacement(text)
|
|
86
|
-
item.write_text(text,
|
|
85
|
+
item.write_text(text, "utf8")
|
|
87
86
|
|
|
88
87
|
|
|
89
88
|
class BuildPyCommand(build_py.build_py): # pragma: no cover
|
|
@@ -148,7 +147,7 @@ class DevelopCommand(develop.develop): # pragma: no cover
|
|
|
148
147
|
|
|
149
148
|
class SDistCommand(sdist.sdist): # pragma: no cover
|
|
150
149
|
def run(self) -> None:
|
|
151
|
-
if not self.dry_run:
|
|
150
|
+
if not self.dry_run:
|
|
152
151
|
self.run_command("clean")
|
|
153
152
|
run_antlr(self)
|
|
154
153
|
sdist.sdist.run(self)
|
|
@@ -196,7 +195,7 @@ def find(
|
|
|
196
195
|
|
|
197
196
|
def find_version(*file_paths: str) -> str:
|
|
198
197
|
root = Path(__file__).parent.parent.absolute()
|
|
199
|
-
with
|
|
198
|
+
with open(root / Path(*file_paths), "r", encoding="utf-8") as fp:
|
|
200
199
|
version_file = fp.read()
|
|
201
200
|
version_match = re.search(r"^__version__ = ['\"]([^'\"]*)['\"]", version_file, re.M)
|
|
202
201
|
if version_match:
|
|
@@ -114,6 +114,7 @@ _DEFAULT_MARKER_: Any = Marker("_DEFAULT_MARKER_")
|
|
|
114
114
|
|
|
115
115
|
class OmegaConfDumper(BaseDumper): # type: ignore
|
|
116
116
|
str_representer_added = False
|
|
117
|
+
pathlib_representers_added = False
|
|
117
118
|
|
|
118
119
|
@staticmethod
|
|
119
120
|
def str_representer(dumper: yaml.Dumper, data: str) -> yaml.ScalarNode:
|
|
@@ -124,11 +125,51 @@ class OmegaConfDumper(BaseDumper): # type: ignore
|
|
|
124
125
|
style=("'" if with_quotes else None),
|
|
125
126
|
)
|
|
126
127
|
|
|
128
|
+
@staticmethod
|
|
129
|
+
def pathlib_path_representer(dumper: yaml.Dumper, data: Any) -> yaml.Node:
|
|
130
|
+
# Use old pathlib.Path tag for cross-version compatibility
|
|
131
|
+
# Extract constructor args from __reduce__ and use sequence representation
|
|
132
|
+
return dumper.represent_sequence( # pragma: no cover
|
|
133
|
+
"tag:yaml.org,2002:python/object/apply:pathlib.Path",
|
|
134
|
+
[str(data)],
|
|
135
|
+
)
|
|
136
|
+
|
|
137
|
+
@staticmethod
|
|
138
|
+
def pathlib_posix_path_representer(dumper: yaml.Dumper, data: Any) -> yaml.Node:
|
|
139
|
+
# Use old pathlib.PosixPath tag for cross-version compatibility
|
|
140
|
+
return dumper.represent_sequence(
|
|
141
|
+
"tag:yaml.org,2002:python/object/apply:pathlib.PosixPath",
|
|
142
|
+
[str(data)],
|
|
143
|
+
)
|
|
144
|
+
|
|
145
|
+
@staticmethod
|
|
146
|
+
def pathlib_windows_path_representer(dumper: yaml.Dumper, data: Any) -> yaml.Node:
|
|
147
|
+
# Use old pathlib.WindowsPath tag for cross-version compatibility
|
|
148
|
+
return dumper.represent_sequence( # pragma: no cover
|
|
149
|
+
"tag:yaml.org,2002:python/object/apply:pathlib.WindowsPath",
|
|
150
|
+
[str(data)],
|
|
151
|
+
)
|
|
152
|
+
|
|
127
153
|
|
|
128
154
|
def get_omega_conf_dumper() -> Type[OmegaConfDumper]:
|
|
129
155
|
if not OmegaConfDumper.str_representer_added:
|
|
130
156
|
OmegaConfDumper.add_representer(str, OmegaConfDumper.str_representer)
|
|
131
157
|
OmegaConfDumper.str_representer_added = True
|
|
158
|
+
|
|
159
|
+
# Add representers for pathlib types to ensure cross-version compatibility.
|
|
160
|
+
# Python 3.13+ uses pathlib._local.* internally, so we normalize to old pathlib.* tags
|
|
161
|
+
if not OmegaConfDumper.pathlib_representers_added:
|
|
162
|
+
from pathlib import Path, PosixPath, WindowsPath
|
|
163
|
+
|
|
164
|
+
OmegaConfDumper.add_representer(Path, OmegaConfDumper.pathlib_path_representer)
|
|
165
|
+
OmegaConfDumper.add_representer(
|
|
166
|
+
PosixPath, OmegaConfDumper.pathlib_posix_path_representer
|
|
167
|
+
)
|
|
168
|
+
OmegaConfDumper.add_representer(
|
|
169
|
+
WindowsPath, OmegaConfDumper.pathlib_windows_path_representer
|
|
170
|
+
)
|
|
171
|
+
OmegaConfDumper.pathlib_representers_added = True
|
|
172
|
+
|
|
132
173
|
return OmegaConfDumper
|
|
133
174
|
|
|
134
175
|
|
|
@@ -190,6 +231,20 @@ def get_yaml_loader() -> Any:
|
|
|
190
231
|
lambda loader, node: pathlib.WindowsPath(*loader.construct_sequence(node)),
|
|
191
232
|
)
|
|
192
233
|
|
|
234
|
+
# Python 3.13+ uses internal pathlib._local module
|
|
235
|
+
loader.add_constructor(
|
|
236
|
+
"tag:yaml.org,2002:python/object/apply:pathlib._local.Path",
|
|
237
|
+
lambda loader, node: pathlib.Path(*loader.construct_sequence(node)),
|
|
238
|
+
)
|
|
239
|
+
loader.add_constructor(
|
|
240
|
+
"tag:yaml.org,2002:python/object/apply:pathlib._local.PosixPath",
|
|
241
|
+
lambda loader, node: pathlib.PosixPath(*loader.construct_sequence(node)),
|
|
242
|
+
)
|
|
243
|
+
loader.add_constructor(
|
|
244
|
+
"tag:yaml.org,2002:python/object/apply:pathlib._local.WindowsPath",
|
|
245
|
+
lambda loader, node: pathlib.WindowsPath(*loader.construct_sequence(node)),
|
|
246
|
+
)
|
|
247
|
+
|
|
193
248
|
return loader
|
|
194
249
|
|
|
195
250
|
|
|
@@ -350,7 +405,7 @@ def get_attr_data(obj: Any, allow_objects: Optional[bool] = None) -> Dict[str, A
|
|
|
350
405
|
value = MISSING
|
|
351
406
|
if is_union_annotation(type_) and not is_supported_union_annotation(type_):
|
|
352
407
|
e = ConfigValueError(
|
|
353
|
-
f"Unions of containers are not supported:\n{name}: {type_str(type_)}"
|
|
408
|
+
f"Unions of containers are not supported:\n{name}: {type_str(type_)}" # noqa: E231
|
|
354
409
|
)
|
|
355
410
|
format_and_raise(node=None, key=None, value=value, cause=e, msg=str(e))
|
|
356
411
|
|
|
@@ -409,7 +464,7 @@ def get_dataclass_data(
|
|
|
409
464
|
|
|
410
465
|
if is_union_annotation(type_) and not is_supported_union_annotation(type_):
|
|
411
466
|
e = ConfigValueError(
|
|
412
|
-
f"Unions of containers are not supported:\n{name}: {type_str(type_)}"
|
|
467
|
+
f"Unions of containers are not supported:\n{name}: {type_str(type_)}" # noqa: E231
|
|
413
468
|
)
|
|
414
469
|
format_and_raise(node=None, key=None, value=value, cause=e, msg=str(e))
|
|
415
470
|
try:
|
|
@@ -941,7 +996,14 @@ def type_str(t: Any, include_module_name: bool = False) -> str:
|
|
|
941
996
|
and t.__module__ != "typing"
|
|
942
997
|
and not t.__module__.startswith("omegaconf.")
|
|
943
998
|
):
|
|
944
|
-
|
|
999
|
+
module_name = str(t.__module__)
|
|
1000
|
+
if isinstance(t, type) and issubclass(t, pathlib.PurePath):
|
|
1001
|
+
# Python 3.13+ uses pathlib._local internally, normalize to pathlib for # Path types
|
|
1002
|
+
# Normalize pathlib._local to pathlib for cross-version compatibility
|
|
1003
|
+
if module_name == "pathlib._local": # pragma: no cover
|
|
1004
|
+
module_name = "pathlib"
|
|
1005
|
+
|
|
1006
|
+
module_prefix = module_name + "."
|
|
945
1007
|
else:
|
|
946
1008
|
module_prefix = ""
|
|
947
1009
|
ret = module_prefix + ret
|
|
@@ -738,9 +738,9 @@ class BaseContainer(Container, ABC):
|
|
|
738
738
|
|
|
739
739
|
def _slice_to_str(x: slice) -> str:
|
|
740
740
|
if x.step is not None:
|
|
741
|
-
return f"{x.start}:{x.stop}:{x.step}"
|
|
741
|
+
return f"{x.start}:{x.stop}:{x.step}" # noqa: E231
|
|
742
742
|
else:
|
|
743
|
-
return f"{x.start}:{x.stop}"
|
|
743
|
+
return f"{x.start}:{x.stop}" # noqa: E231
|
|
744
744
|
|
|
745
745
|
def prepand(
|
|
746
746
|
full_key: str,
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/gen/OmegaConfGrammarLexer.py
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Generated from /home/
|
|
1
|
+
# Generated from /home/runner/work/omegaconf/omegaconf/omegaconf/grammar/OmegaConfGrammarLexer.g4 by ANTLR 4.11.1
|
|
2
2
|
from omegaconf.vendor.antlr4 import *
|
|
3
3
|
from io import StringIO
|
|
4
4
|
import sys
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/gen/OmegaConfGrammarParser.py
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Generated from /home/
|
|
1
|
+
# Generated from /home/runner/work/omegaconf/omegaconf/omegaconf/grammar/OmegaConfGrammarParser.g4 by ANTLR 4.11.1
|
|
2
2
|
# encoding: utf-8
|
|
3
3
|
from omegaconf.vendor.antlr4 import *
|
|
4
4
|
from io import StringIO
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Generated from /home/
|
|
1
|
+
# Generated from /home/runner/work/omegaconf/omegaconf/omegaconf/grammar/OmegaConfGrammarParser.g4 by ANTLR 4.11.1
|
|
2
2
|
from omegaconf.vendor.antlr4 import *
|
|
3
3
|
if __name__ is not None and "." in __name__:
|
|
4
4
|
from .OmegaConfGrammarParser import OmegaConfGrammarParser
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/grammar/gen/OmegaConfGrammarParserVisitor.py
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Generated from /home/
|
|
1
|
+
# Generated from /home/runner/work/omegaconf/omegaconf/omegaconf/grammar/OmegaConfGrammarParser.g4 by ANTLR 4.11.1
|
|
2
2
|
from omegaconf.vendor.antlr4 import *
|
|
3
3
|
if __name__ is not None and "." in __name__:
|
|
4
4
|
from .OmegaConfGrammarParser import OmegaConfGrammarParser
|
|
@@ -28,8 +28,10 @@ _node_inter = f"\\${{\\s*{_node_path}\\s*}}" # node interpolation ${foo.bar}
|
|
|
28
28
|
_id = "[a-zA-Z_][\\w\\-]*" # foo, foo_bar, foo-bar, abc123
|
|
29
29
|
_resolver_name = f"({_id}(\\.{_id})*)?" # foo, ns.bar3, ns_1.ns_2.b0z
|
|
30
30
|
_arg = r"[a-zA-Z_0-9/\-\+.$%*@?|]+" # string representing a resolver argument
|
|
31
|
-
_args = f"{_arg}(\\s*,\\s*{_arg})*" # list of resolver arguments
|
|
32
|
-
_resolver_inter =
|
|
31
|
+
_args = f"{_arg}(\\s*,\\s*{_arg})*" # list of resolver arguments # noqa: E231
|
|
32
|
+
_resolver_inter = (
|
|
33
|
+
f"\\${{\\s*{_resolver_name}\\s*:\\s*{_args}?\\s*}}" # ${foo:bar} # noqa: E231
|
|
34
|
+
)
|
|
33
35
|
_inter = f"({_node_inter}|{_resolver_inter})" # any kind of interpolation
|
|
34
36
|
_outer = "([^$]|\\$(?!{))+" # any character except $ (unless not followed by {)
|
|
35
37
|
SIMPLE_INTERPOLATION_PATTERN = re.compile(
|
|
@@ -251,7 +251,7 @@ class GrammarVisitor(OmegaConfGrammarParserVisitor):
|
|
|
251
251
|
warnings.warn(
|
|
252
252
|
f"In the sequence `{txt}` some elements are missing: please replace "
|
|
253
253
|
f"them with empty quoted strings. "
|
|
254
|
-
f"See https://github.com/omry/omegaconf/issues/572 for details.",
|
|
254
|
+
f"See https://github.com/omry/omegaconf/issues/572 for details.", # noqa: E231
|
|
255
255
|
category=UserWarning,
|
|
256
256
|
)
|
|
257
257
|
|
|
@@ -372,7 +372,7 @@ class OmegaConf:
|
|
|
372
372
|
f"to be an interpolation. Nested interpolations are not supported for "
|
|
373
373
|
f"resolvers registered with `[legacy_]register_resolver()`, please use "
|
|
374
374
|
f"`register_new_resolver()` instead (see "
|
|
375
|
-
f"https://github.com/omry/omegaconf/issues/426 for migration instructions)."
|
|
375
|
+
f"https://github.com/omry/omegaconf/issues/426 for migration instructions)." # noqa: E231
|
|
376
376
|
)
|
|
377
377
|
key = args_str
|
|
378
378
|
val = cache[key] if key in cache else resolver(*args_unesc)
|
|
@@ -485,7 +485,7 @@ class OmegaConf:
|
|
|
485
485
|
Returns a bool: True if resolver is removed and False if not removed.
|
|
486
486
|
|
|
487
487
|
.. warning:
|
|
488
|
-
This method can remove
|
|
488
|
+
This method can remove default resolvers as well.
|
|
489
489
|
|
|
490
490
|
:param name: Name of the resolver.
|
|
491
491
|
:return: A bool (``True`` if resolver is removed, ``False`` if not found before removing).
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import sys # pragma: no cover
|
|
2
2
|
|
|
3
|
-
__version__ = "2.4.0.
|
|
3
|
+
__version__ = "2.4.0.dev4"
|
|
4
4
|
|
|
5
|
-
msg = """OmegaConf 2.4 and above is compatible with Python 3.
|
|
5
|
+
msg = """OmegaConf 2.4 and above is compatible with Python 3.9 and newer.
|
|
6
6
|
You have the following options:
|
|
7
|
-
1. Upgrade to Python 3.
|
|
7
|
+
1. Upgrade to Python 3.9 or newer.
|
|
8
8
|
This is highly recommended. new features will not be added to OmegaConf 2.3.
|
|
9
9
|
2. Continue using OmegaConf 2.3:
|
|
10
10
|
You can pip install 'OmegaConf<2.4' to do that.
|
|
11
11
|
"""
|
|
12
12
|
|
|
13
|
-
if sys.version_info < (3,
|
|
13
|
+
if sys.version_info < (3, 9):
|
|
14
14
|
raise ImportError(msg) # pragma: no cover
|
|
@@ -1,23 +1,36 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
2
|
Name: omegaconf
|
|
3
|
-
Version: 2.4.0.
|
|
3
|
+
Version: 2.4.0.dev4
|
|
4
4
|
Summary: A flexible configuration library
|
|
5
5
|
Home-page: https://github.com/omry/omegaconf
|
|
6
6
|
Author: Omry Yadan
|
|
7
7
|
Author-email: omry@yadan.net
|
|
8
8
|
Keywords: yaml configuration config
|
|
9
|
-
Classifier: Programming Language :: Python :: 3.8
|
|
10
9
|
Classifier: Programming Language :: Python :: 3.9
|
|
11
10
|
Classifier: Programming Language :: Python :: 3.10
|
|
12
11
|
Classifier: Programming Language :: Python :: 3.11
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
13
15
|
Classifier: License :: OSI Approved :: BSD License
|
|
14
16
|
Classifier: Operating System :: OS Independent
|
|
15
|
-
Requires-Python: >=3.
|
|
17
|
+
Requires-Python: >=3.9
|
|
16
18
|
Description-Content-Type: text/markdown
|
|
17
19
|
License-File: LICENSE
|
|
18
20
|
Requires-Dist: PyYAML>=5.1.0
|
|
19
21
|
Requires-Dist: dataclasses; python_version == "3.6"
|
|
20
22
|
Requires-Dist: typing-extensions; python_version <= "3.9"
|
|
23
|
+
Dynamic: author
|
|
24
|
+
Dynamic: author-email
|
|
25
|
+
Dynamic: classifier
|
|
26
|
+
Dynamic: description
|
|
27
|
+
Dynamic: description-content-type
|
|
28
|
+
Dynamic: home-page
|
|
29
|
+
Dynamic: keywords
|
|
30
|
+
Dynamic: license-file
|
|
31
|
+
Dynamic: requires-dist
|
|
32
|
+
Dynamic: requires-python
|
|
33
|
+
Dynamic: summary
|
|
21
34
|
|
|
22
35
|
# OmegaConf
|
|
23
36
|
| | Description |
|
|
@@ -14,7 +14,7 @@ exclude = '''
|
|
|
14
14
|
'''
|
|
15
15
|
|
|
16
16
|
[tool.pytest.ini_options]
|
|
17
|
-
addopts = "--import-mode=append -Werror
|
|
17
|
+
addopts = "--import-mode=append -Werror"
|
|
18
18
|
pythonpath = ["."]
|
|
19
19
|
|
|
20
20
|
[tool.towncrier]
|
|
@@ -70,12 +70,14 @@ with open("README.md", "r") as fh:
|
|
|
70
70
|
"pydevd_plugins.extensions",
|
|
71
71
|
]
|
|
72
72
|
+ vendored_packages,
|
|
73
|
-
python_requires=">=3.
|
|
73
|
+
python_requires=">=3.9",
|
|
74
74
|
classifiers=[
|
|
75
|
-
"Programming Language :: Python :: 3.8",
|
|
76
75
|
"Programming Language :: Python :: 3.9",
|
|
77
76
|
"Programming Language :: Python :: 3.10",
|
|
78
77
|
"Programming Language :: Python :: 3.11",
|
|
78
|
+
"Programming Language :: Python :: 3.12",
|
|
79
|
+
"Programming Language :: Python :: 3.13",
|
|
80
|
+
"Programming Language :: Python :: 3.14",
|
|
79
81
|
"License :: OSI Approved :: BSD License",
|
|
80
82
|
"Operating System :: OS Independent",
|
|
81
83
|
],
|
|
@@ -49,7 +49,7 @@ def test_decode(monkeypatch: Any, value: Optional[str], expected: Any) -> None:
|
|
|
49
49
|
{
|
|
50
50
|
# The node of interest is "node" (others are used to test interpolations).
|
|
51
51
|
"parent": {
|
|
52
|
-
"node": f"${{oc.decode:'{value}'}}",
|
|
52
|
+
"node": f"${{oc.decode:'{value}'}}", # noqa: E231
|
|
53
53
|
"sibling": 1,
|
|
54
54
|
},
|
|
55
55
|
"uncle": 2,
|
|
@@ -100,6 +100,6 @@ def test_decode_none() -> None:
|
|
|
100
100
|
],
|
|
101
101
|
)
|
|
102
102
|
def test_decode_error(monkeypatch: Any, value: Any, exc: Any) -> None:
|
|
103
|
-
c = OmegaConf.create({"x": f"${{oc.decode:{value}}}"})
|
|
103
|
+
c = OmegaConf.create({"x": f"${{oc.decode:{value}}}"}) # noqa: E231
|
|
104
104
|
with exc:
|
|
105
105
|
c.x
|
|
@@ -1663,7 +1663,7 @@ def test_resolver_error(restore_resolvers: Any, register_func: Any) -> None:
|
|
|
1663
1663
|
c = OmegaConf.create({"div_by_zero": "${div:1,0}"})
|
|
1664
1664
|
expected_msg = dedent(
|
|
1665
1665
|
"""\
|
|
1666
|
-
ZeroDivisionError raised while resolving interpolation: float division( by zero)?
|
|
1666
|
+
ZeroDivisionError raised while resolving interpolation: (float )?division( by zero)?
|
|
1667
1667
|
full_key: div_by_zero
|
|
1668
1668
|
object_type=dict"""
|
|
1669
1669
|
)
|
|
@@ -191,9 +191,9 @@ PARAMS_SINGLE_ELEMENT_NO_INTERPOLATION: List[Tuple[str, str, Any]] = [
|
|
|
191
191
|
),
|
|
192
192
|
(
|
|
193
193
|
"dict_unquoted_key",
|
|
194
|
-
rf"{{a0-null-1-3.14-NaN- {TAB}-true-False-{UNQUOTED_SPECIAL}\(\)\[\]\{{\}}\:\=\ \{TAB}\,:0}}",
|
|
194
|
+
rf"{{a0-null-1-3.14-NaN- {TAB}-true-False-{UNQUOTED_SPECIAL}\(\)\[\]\{{\}}\:\=\ \{TAB}\,:0}}", # noqa: E231
|
|
195
195
|
{
|
|
196
|
-
rf"a0-null-1-3.14-NaN- {TAB}-true-False-{UNQUOTED_SPECIAL}()[]{{}}:= {TAB},": 0
|
|
196
|
+
rf"a0-null-1-3.14-NaN- {TAB}-true-False-{UNQUOTED_SPECIAL}()[]{{}}:= {TAB},": 0 # noqa: E231
|
|
197
197
|
},
|
|
198
198
|
),
|
|
199
199
|
(
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import copy
|
|
2
2
|
import functools
|
|
3
3
|
import re
|
|
4
|
+
import sys
|
|
4
5
|
from enum import Enum
|
|
5
6
|
from functools import partial
|
|
6
7
|
from pathlib import Path
|
|
@@ -837,8 +838,11 @@ def test_eq(node: ValueNode, value: Any, expected: Any) -> None:
|
|
|
837
838
|
assert (value != node) != expected
|
|
838
839
|
|
|
839
840
|
# Check hash except for unhashable types (dict/list).
|
|
840
|
-
if
|
|
841
|
-
|
|
841
|
+
# Per Python's hash contract: if a == b, then hash(a) == hash(b)
|
|
842
|
+
# Note: if a != b, hashes may or may not be equal (collisions are allowed)
|
|
843
|
+
# E.g. Path('a') != 'a' but their hashes are equal as of Python 3.12
|
|
844
|
+
if not isinstance(value, (dict, list)) and expected:
|
|
845
|
+
assert node.__hash__() == value.__hash__()
|
|
842
846
|
|
|
843
847
|
|
|
844
848
|
@mark.parametrize(
|
|
@@ -992,3 +996,46 @@ def test_interpolation_result_readonly(flags: Any) -> None:
|
|
|
992
996
|
# If no value was provided for the "readonly" flag, it should be set.
|
|
993
997
|
if readonly is None:
|
|
994
998
|
assert node._get_node_flag("readonly")
|
|
999
|
+
|
|
1000
|
+
|
|
1001
|
+
@mark.skipif(
|
|
1002
|
+
sys.version_info < (3, 12),
|
|
1003
|
+
reason="Hash collision between Path and str only exists in Python 3.12+",
|
|
1004
|
+
)
|
|
1005
|
+
def test_path_str_hash_collision_handling() -> None:
|
|
1006
|
+
"""
|
|
1007
|
+
Regression test for Python 3.12+ hash collision between Path and str.
|
|
1008
|
+
|
|
1009
|
+
In Python 3.12+, Path('x') and 'x' have identical hashes but are not equal.
|
|
1010
|
+
This test verifies that OmegaConf's containers handle this collision correctly.
|
|
1011
|
+
"""
|
|
1012
|
+
from pathlib import Path
|
|
1013
|
+
|
|
1014
|
+
path_str = "hello.txt"
|
|
1015
|
+
path_obj = Path(path_str)
|
|
1016
|
+
assert hash(path_obj) == hash(path_str)
|
|
1017
|
+
assert path_obj != path_str # type: ignore[comparison-overlap]
|
|
1018
|
+
|
|
1019
|
+
# Test PathNode behavior with hash collision
|
|
1020
|
+
path_node = PathNode(path_obj)
|
|
1021
|
+
assert hash(path_node) == hash(path_str)
|
|
1022
|
+
assert path_node != path_str
|
|
1023
|
+
|
|
1024
|
+
list_cfg1 = OmegaConf.create([path_obj])
|
|
1025
|
+
assert path_obj in list_cfg1
|
|
1026
|
+
assert path_str not in list_cfg1
|
|
1027
|
+
|
|
1028
|
+
list_cfg2 = OmegaConf.create([path_str])
|
|
1029
|
+
assert path_obj not in list_cfg2
|
|
1030
|
+
assert path_str in list_cfg2
|
|
1031
|
+
|
|
1032
|
+
# Test DictConfig with both types as values
|
|
1033
|
+
dict_cfg = OmegaConf.create(
|
|
1034
|
+
{
|
|
1035
|
+
"by_path": {"file": path_obj},
|
|
1036
|
+
"by_string": {"file": path_str},
|
|
1037
|
+
}
|
|
1038
|
+
)
|
|
1039
|
+
assert dict_cfg.by_path.file == path_obj
|
|
1040
|
+
assert dict_cfg.by_string.file == path_str
|
|
1041
|
+
assert dict_cfg.by_path.file != dict_cfg.by_string.file
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/BufferedTokenStream.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/TokenStreamRewriter.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ATNDeserializer.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/LexerATNSimulator.py
RENAMED
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/LexerActionExecutor.py
RENAMED
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/ParserATNSimulator.py
RENAMED
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/atn/SemanticContext.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/error/ErrorListener.py
RENAMED
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/error/ErrorStrategy.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/ParseTreeMatch.py
RENAMED
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/omegaconf/vendor/antlr4/tree/ParseTreePattern.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/pydevd_plugins/extensions/pydevd_plugin_omegaconf.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/examples/dataclass_postponed_annotations.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/test_oc_dict.py
RENAMED
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/interpolation/built_in_resolvers/test_oc_env.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/data/dataclasses_pre_311.py
RENAMED
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/test_structured_basic.py
RENAMED
|
File without changes
|
{omegaconf-2.4.0.dev3 → omegaconf-2.4.0.dev4}/tests/structured_conf/test_structured_config.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|