refactor: centralize config and remove dead code#61
Merged
maskedsyntax merged 1 commit intomainfrom Feb 19, 2026
Merged
Conversation
- Create hashprep/config.py with all thresholds as typed dataclasses - Replace 80+ magic numbers across check files with config references - Remove ~160 lines of commented-out code in summaries/variables.py - Remove dead _check_feature_correlation() function in correlations.py - Remove unused imports (f_oneway, infer_types, numpy) in correlations.py and type_inference.py - Fix redundant infer_types() call: pass column_types from analyzer to summarize_variables() - Remove unused dependencies: fastapi, starlette, brotli from pyproject.toml - Clean up unused variables (text_cols, corr_methods, default_methods) in correlations.py
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
hashprep/config.pywith all thresholds as frozen dataclasses, single source of truth for 80+ magic numbers scattered across check filessummaries/variables.py_check_feature_correlation()function incorrelations.py(defined but never registered/called)infer_types()call : was called inDatasetAnalyzer.__init__AND again insidesummarize_variables(), now passescolumn_typesthroughfastapi,starlette,brotlifrompyproject.toml(dependency hygiene)correlations.pyandtype_inference.pyAll 82 tests pass with no regressions.
Test plan