indygreg / indygreg/PyOxidizer

importlib.metadata.version doesn't work for packages with dashes

Open
#451 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
6.2k
Forks
256
PR merge metrics
No merged PRs in 30d

Description

Hi!

How to reproduce:

1. Do `pyoxidizer init-config-file pyapp` from tutorial
2. Add `exe.add_python_resources(exe.pip_install(["more-itertools"]))` to `make_exe` target
3. `pyoxidizer run`
4. `from importlib.metadata import version; version('more-itertools')`
5. Same for `from importlib.metadata import version; version('more_itertools')`

```
$ pyoxidizer --version
PyOxidizer 0.17.0
commit: 36e50354c97275c7d9f47b3c38a8c216a08771f5
source: https://github.com/indygreg/PyOxidizer.git
pyembed crate location: version = "0.17.0"
```

Contributor guide

No contributing guide indexed for this repository

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

Reproduce the failure with the PyOxidizer tutorial configuration, `make_exe`, `pip_install`, and `importlib.metadata.version` as shown. Start by tracing how the embedded `more-itertools` distribution metadata is packaged and exposed; done means both `version('more-itertools')` and `version('more_itertools')` work in `pyoxidizer run`.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, rust
Domain
build-system
Issue type
Bug
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.