Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement safer dependency parsing #159

Merged
merged 2 commits into from
Dec 5, 2023
Merged

Conversation

drdavella
Copy link
Member

@drdavella drdavella commented Dec 4, 2023

Overview

Make dependency parsing safer and more tolerant of unexpected conditions

Description

  • The heuristics we use to gather packaging metadata are necessarily messy
  • We need them to be highly fault tolerant to handle lots of unexpected situations
  • Under no circumstances should a failure to parse dependencies cause codemodder to crash

Copy link

codecov bot commented Dec 4, 2023

Codecov Report

Merging #159 (f3eb073) into main (c058932) will decrease coverage by 0.12%.
The diff coverage is 94.59%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #159      +/-   ##
==========================================
- Coverage   96.46%   96.35%   -0.12%     
==========================================
  Files          75       75              
  Lines        3452     3456       +4     
==========================================
  Hits         3330     3330              
- Misses        122      126       +4     
Files Coverage Δ
...der/project_analysis/file_parsers/package_store.py 100.00% <100.00%> (ø)
...lysis/file_parsers/requirements_txt_file_parser.py 100.00% <100.00%> (ø)
...ject_analysis/file_parsers/setup_py_file_parser.py 100.00% <100.00%> (ø)
...nalysis/file_parsers/pyproject_toml_file_parser.py 93.33% <87.50%> (-6.67%) ⬇️
...ect_analysis/file_parsers/setup_cfg_file_parser.py 93.75% <80.00%> (-6.25%) ⬇️
...odder/project_analysis/file_parsers/base_parser.py 93.33% <83.33%> (-6.67%) ⬇️

@drdavella drdavella force-pushed the safer-dependency-parsing branch from 0311f05 to f3eb073 Compare December 4, 2023 21:21
@drdavella drdavella marked this pull request as ready for review December 4, 2023 21:37
@drdavella drdavella added this pull request to the merge queue Dec 5, 2023
Merged via the queue into main with commit 0c8b51a Dec 5, 2023
13 checks passed
@drdavella drdavella deleted the safer-dependency-parsing branch December 5, 2023 15:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants