{"id":23531,"library":"deepcomparer","title":"DeepComparer","description":"A Python library for deep comparison of nested structures like dicts, lists, and iterables. Current version 0.4.0 (beta). Active development with monthly releases.","status":"active","version":"0.4.0","language":"python","source_language":"en","source_url":"https://github.com/jparadadev/deepcomparer.py","tags":["deep comparison","dict","list","testing","utility"],"install":[{"cmd":"pip install deepcomparer","lang":"bash","label":"Install from PyPI"}],"dependencies":[],"imports":[{"note":"Direct import without module name fails","wrong":"import DeepComparer","symbol":"DeepComparer","correct":"from deepcomparer import DeepComparer"}],"quickstart":{"code":"from deepcomparer import DeepComparer\ndc = DeepComparer()\nresult = dc.compare(\n    {'a': 1, 'b': {'c': 2}},\n    {'a': 1, 'b': {'c': 3}}\n)\nprint(result.differences())","lang":"python","description":"Compare two nested dicts and print differences."},"warnings":[{"fix":"Pin to exact version in requirements.txt, e.g. deepcomparer==0.4.0","message":"Library is in beta (pre-1.0). Breaking changes between minor versions expected; upgrade with caution.","severity":"breaking","affected_versions":"<1.0.0"},{"fix":"Ensure lists are sorted before comparison if order is irrelevant.","message":"Order of keys in dicts does not affect comparison; however, order of list items does. May cause unexpected mismatches if lists are compared element-wise.","severity":"gotcha","affected_versions":"all"},{"fix":"Convert custom iterables to list/dict if deep comparison should treat them same.","message":"Nested iterables other than dict/list (e.g., set, tuple) are compared as-is; sets are compared unordered, tuples ordered.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run 'pip install deepcomparer' in the correct Python environment.","cause":"Library not installed or installed in wrong environment.","error":"ModuleNotFoundError: No module named 'deepcomparer'"},{"fix":"Use 'from deepcomparer import DeepComparer' and then just 'DeepComparer'.","cause":"Importing incorrectly (e.g., 'import deepcomparer' then using deepcomparer.DeepComparer) but class is not top-level.","error":"AttributeError: module 'deepcomparer' has no attribute 'DeepComparer'"},{"fix":"Check documentation for available options; use sort or preprocess lists before comparison.","cause":"The compare method does not accept ignore_order parameter in current version.","error":"TypeError: compare() got an unexpected keyword argument 'ignore_order'"},{"fix":"Ensure you call dc.compare() first and store the result; then call result.differences().","cause":"Calling result.differences() before performing a comparison, or using wrong attribute name.","error":"KeyError: 'differences'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}