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

pypi missing binary for windows #570

Closed
mrx23dot opened this issue Oct 4, 2021 · 16 comments
Closed

pypi missing binary for windows #570

mrx23dot opened this issue Oct 4, 2021 · 16 comments
Labels
miniupnpc windows bug related to MS Windows build

Comments

@mrx23dot
Copy link

mrx23dot commented Oct 4, 2021

Please add pre-compiled binary for windows x64/x32 to pypi.
Compiling on every client PC is impractical by pip installation.

@miniupnp
Copy link
Owner

miniupnp commented Oct 5, 2021

@mrx23dot aren't packages available on https://ci.appveyor.com/project/miniupnp/miniupnp OK ?
if not, why ?

@mrx23dot
Copy link
Author

mrx23dot commented Oct 5, 2021

Could we add them for pypi too? That's the most common lib distributor.
So pip install miniupnp would work.
should be very easy from appveyor: https://www.dynamsoft.com/codepool/appveyor-build-deploy-python-wheels.html

I tried to install it from whl on win10 x64:

pip install miniupnpc-2.2.3-cp37-cp37m-win_amd64.whl
Processing c:\tmp\miniupnpc-2.2.3-cp37-cp37m-win_amd64.whl
Installing collected packages: miniupnpc
Successfully installed miniupnpc-2.2.3

But loading it fails:

Python 3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:59:51) [MSC v.1914 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import miniupnpc
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: DLL load failed: The specified module could not be found.

What DLLs does it use?

@miniupnp
Copy link
Owner

miniupnp commented Oct 5, 2021

I'm neither a python developer, nor a Windows developer, so I'm not able to help you.

I'm accepting any Pull Request, but there have been a lot of people complaining the lack of precompiled python packages, and only a few offering help to build one.

@miniupnp miniupnp closed this as completed Oct 5, 2021
@miniupnp miniupnp added miniupnpc windows bug related to MS Windows build labels Oct 5, 2021
@mrx23dot
Copy link
Author

mrx23dot commented Oct 5, 2021

Only you have access to the appveyor, to take the built binaries from there to pypi you need to add this extra step:

deploy_script:
  - ps: |
      if($env:APPVEYOR_REPO_TAG -eq 'true') {
        Write-Output ("Deploying " + $env:APPVEYOR_REPO_TAG_NAME + " to PyPI...")
        &"${Env:PYTHON}/python.exe" -m pip install twine
        &"${Env:PYTHON}/python.exe" -m twine upload -u ${Env:USER} -p ${Env:PASS} --skip-existing dist/\*.whl
      } else {
        Write-Output "No tag for deployment"
      }

details https://www.dynamsoft.com/codepool/appveyor-build-deploy-python-wheels.html
it uses this lib to upload it: https://pypi.org/project/twine/
With binaries available more people can try it out, and get hooked.

@miniupnp
Copy link
Owner

miniupnp commented Oct 5, 2021

Only you have access to the appveyor

???
you mean the appveyor script ? https://github.com/miniupnp/miniupnp/blob/master/appveyor.yml

@mrx23dot
Copy link
Author

mrx23dot commented Oct 5, 2021

I added windows binaries and instruction in my release:
https://github.com/mrx23dot/miniupnp/releases/tag/miniupnpd_2_2_3
appveyor only retains binaries for 1month.

Only you have permission to publish into your repo
https://pypi.org/project/miniupnpc/
"The user 'me' isn't allowed to upload to project 'miniupnpc'."

You can try it manually:
pip3 install twine
python3 -m twine upload -u username -p pwd --skip-existing *.whl *.zip

I tried to rename the project to try it out, but wheel need comes from folder structure.

@miniupnp
Copy link
Owner

miniupnp commented Oct 5, 2021

Only you have permission to publish into your repo
https://pypi.org/project/miniupnpc/
"The user 'me' isn't allowed to upload to project 'miniupnpc'."

That is not my repo. I have no account on pypi.org. You should contact the listed maintainers.

@mrx23dot
Copy link
Author

mrx23dot commented Oct 6, 2021

@niamster could you please join in?

@niamster
Copy link
Contributor

niamster commented Oct 7, 2021

@niamster could you please join in?

Hello, I'm not a maintainer of that package either, by chance I got permissions to manage granted by https://pypi.org/user/chenhouwu/ to be able to push one update. Did you reach him?

@mrx23dot
Copy link
Author

mrx23dot commented Oct 7, 2021

I didn't find any contact detail, also I don't see him among the contributors.

@mrx23dot
Copy link
Author

mrx23dot commented Oct 7, 2021

Could you grant me and miniupnp maintainer permission?

@niamster
Copy link
Contributor

niamster commented Oct 8, 2021

For some reason I can't do that
Screenshot
@laishulu I think that were you who gave me some permissions initially

@niamster
Copy link
Contributor

@mrx23dot what's your pypi account? @laishulu granted me a maintainer permissions.

@mrx23dot
Copy link
Author

Awesome, could you grant me too? pypi: mrx23dot

@mrx23dot
Copy link
Author

pip install miniupnp
should work now on all Windows.
With an extra step of manually deploying scripts, from appropiate zip:
https://github.com/mrx23dot/miniupnp/releases/tag/miniupnpd_2_2_24

Auto copying those didnt work from yml.
Optimally binary should be portable.

@Julien00859
Copy link

Julien00859 commented Mar 21, 2022

Hello there, we have been trying to use miniupnpc on windows (installed from pypi), the installation goes well but import miniupnpc fails due to "missing DLL". Can you elaborate on how shall we install the package? I'm noticing there is no wheel for python3.8 see https://pypi.org/simple/miniupnpc/. Please note that we had to extensively search in order to find this issue, if this github repository is where we should report issues, could you please edit your setup.py/setup.cfg/pyproject.toml file so that it is mentioned?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
miniupnpc windows bug related to MS Windows build
Projects
None yet
Development

No branches or pull requests

4 participants