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

Installation on Windows now failing #52

Open
pulpocaminante opened this issue Jan 25, 2023 · 3 comments
Open

Installation on Windows now failing #52

pulpocaminante opened this issue Jan 25, 2023 · 3 comments

Comments

@pulpocaminante
Copy link

pulpocaminante commented Jan 25, 2023

Seems to be an environment variable issue

amnesia ❯ git init .
Reinitialized existing Git repository in [ Truncated ]
                                                             
amnesia ❯ pip install .
Processing  [ Truncated ]\stickerpicker
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [10 lines of output]
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File " [ Truncated ]\stickerpicker\setup.py", line 3, in <module>
          from sticker.get_version import git_tag, git_revision, version, linkified_version
        File " [ Truncated ]\stickerpicker\sticker\get_version.py", line 9, in <module>

Specifically:

          "HOME": os.environ["HOME"],
        File " [ Truncated ]\Python\Python310\lib\os.py", line 680, in __getitem__
          raise KeyError(key) from None
      KeyError: 'HOME'
      [end of output]

Although setting %HOME%=anything has no effect on this error.

@pulpocaminante pulpocaminante changed the title Installation on Windows fails Installation on Windows now failing Jan 25, 2023
@Lewko6702
Copy link

hey I was able to actually fix this!

change these two lines in setup.py and get_version.py

get_version.py
"HOME": os.environ["USERPROFILE"],
and
setup.py
long_desc = open("README.md", encoding="utf-8").read()

this fixed it for me

@iraizo
Copy link

iraizo commented Jun 22, 2023

editing setup.py is required, but with the home env variable you can just type

 $env:HOME = $env:USERPROFILE

beforehand

@Lewko6702
Copy link

ah yeah that is a much better solution

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

No branches or pull requests

3 participants