Skip to content

Handle extras #7

Description

@tyilo

See https://packaging.python.org/specifications/entry-points/

Trying to install black's wheel with python-install, will produce the binary blackd with the following contents:

#!/usr/bin/python
# -*- coding: utf-8 -*-
import re
import sys
from blackd import patched_main [d]
if __name__ == "__main__":
    sys.argv[0] = re.sub(r"(-script\.pyw|\.exe)?$", "", sys.argv[0])
    sys.exit(patched_main [d]())

which of course doesn't work. python-install should not include the [d] in the file.

This is the contents of entry_points.txt for black's wheel:

[console_scripts]
black = black:patched_main
black-primer = black_primer.cli:main
blackd = blackd:patched_main [d]

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions