bndr / bndr/pipreqs

Pip package name problems, attr vs attrs

Open
#138 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
7.5k
Forks
424
PR merge metrics
No merged PRs in 30d

Description

Finding "import attr" in source, pipreqs reasonably includes:

`attr (0.3.1) - Simple decorator to set attributes of target function or class in a DRY way.`

Whereas I really want:

`attrs (18.2.0) - Classes Without Boilerplate`

What's the right option here?

Could one provide a "package name map file" as a config option?

Something like:

```
# import to package name mapping file
attr: attrs
```

Then specify this on the command line?

Contributor guide

Open the contributing guide

Research direction

Start by tracing how pipreqs resolves imports to package names and how command-line options are defined; the issue names no source files or tests. Compare the proposed attr-to-attrs mapping format with the existing configuration flow, then define completion as accepting a user-supplied mapping and selecting attrs for the attr import without changing unrelated package resolution.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli, tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.