madpah / madpah/requirements-parser

Refactor to remove methods deemed too complex by `flake8`

Open
#96 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Python
Stars
141
Forks
42
PR merge metrics
No merged PRs in 30d

Description

`flake8` complains that the following are too complex:

```
requirements/parser.py:42:1: C901 'parse' is too complex (11)
requirements/requirement.py:171:5: C901 'Requirement.parse_line' is too complex (11)
```

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with requirements/parser.py:42 and requirements/requirement.py:171, where the parse and Requirement.parse_line methods are flagged by flake8 C901. Run flake8 to reproduce the warnings, then refactor those methods without changing their behavior. Done means the reported complexity warnings are resolved.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
tooling
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.