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

Publish as Package on PyPI to ease installation #51

Closed
1 of 9 tasks
johannesjh opened this issue Aug 19, 2018 · 4 comments
Closed
1 of 9 tasks

Publish as Package on PyPI to ease installation #51

johannesjh opened this issue Aug 19, 2018 · 4 comments
Assignees

Comments

@johannesjh
Copy link
Collaborator

johannesjh commented Aug 19, 2018

  • Read the Python packaging guide: https://packaging.python.org/tutorials/packaging-projects/#uploading-your-project-to-pypi
  • Setup Makefile targets similar to fava, using twine
  • Write a CHANGES file
  • Set the initial version to 0.1.0 in smart_importer/__init__.py
  • Tag v0.1.0 in git
  • Create a release v0.1.0 in github
  • Publish using twine on test.pypi.org and verify that it worked
  • Publish using twine on production pypi.org
  • Bump the version to 0.1.1-dev in smart_importer/__init__.py
@johannesjh johannesjh self-assigned this Aug 19, 2018
@yagebu
Copy link
Member

yagebu commented Dec 25, 2018

With setuptools_scm (#84), there's no need to bump versions and such, tagging is enough. I'll make a first release today.

@yagebu
Copy link
Member

yagebu commented Dec 25, 2018

Done.

@johannesjh Let me know if I should add you as a maintainer on PyPI

@yagebu yagebu closed this as completed Dec 25, 2018
@johannesjh
Copy link
Collaborator Author

Hi, thank you for publishing the package. And thank you for cleaning up the setup configuration, setuptools_scm looks very nice. If you could add me (account name: johannesjh) on pypi, that would be great, thank you.

@matthew-piziak
Copy link

matthew-piziak commented Dec 30, 2018

When I install smart_importer = "*" with pipenv, I get numpy incompatibility errors.

ValueError: numpy.ufunc size changed, may indicate binary incompatibility. Expected 216 from C header, got 192 from PyObject

This happens at runtime with import smart_importer. I am sandboxed with no numpy outside of my pipenv's virtualenv.

Full traceback:

Traceback (most recent call last):
  File "/home/matt/.local/share/virtualenvs/beancount-1FhiBumi/bin/bean-extract", line 4, in <module>
    from beancount.ingest.extract import main; main()
  File "/nix/store/7fj046k7zm3430wm0mcs62rxq0qj8n1l-python3-3.7.2-env/lib/python3.7/site-packages/beancount/ingest/extract.py", line 250, in main
    return scripts_utils.trampoline_to_ingest(sys.modules[__name__])
  File "/nix/store/7fj046k7zm3430wm0mcs62rxq0qj8n1l-python3-3.7.2-env/lib/python3.7/site-packages/beancount/ingest/scripts_utils.py", line 132, in trampoline_to_ingest
    return run_import_script_and_ingest(parser)
  File "/nix/store/7fj046k7zm3430wm0mcs62rxq0qj8n1l-python3-3.7.2-env/lib/python3.7/site-packages/beancount/ingest/scripts_utils.py", line 191, in run_import_script_and_ingest
    mod = runpy.run_path(args.config)
  File "/nix/store/4ag8gng51y7yw6nr3imwyppqfci3j643-python3-3.7.2/lib/python3.7/runpy.py", line 263, in run_path
    pkg_name=pkg_name, script_name=fname)
  File "/nix/store/4ag8gng51y7yw6nr3imwyppqfci3j643-python3-3.7.2/lib/python3.7/runpy.py", line 96, in _run_module_code
    mod_name, mod_spec, pkg_name, script_name)
  File "/nix/store/4ag8gng51y7yw6nr3imwyppqfci3j643-python3-3.7.2/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "ledger.config", line 2, in <module>
    from smart_importer import PREDICTPOSTINGS, apply_hooks
  File "/home/matt/.local/share/virtualenvs/beancount-1FhiBumi/lib/python3.7/site-packages/smart_importer/__init__.py", line 5, in <module>
    from smart_importer.predictor import EntryPredictor
  File "/home/matt/.local/share/virtualenvs/beancount-1FhiBumi/lib/python3.7/site-packages/smart_importer/predictor.py", line 8, in <module>
    from sklearn.pipeline import make_pipeline, FeatureUnion
  File "/home/matt/.local/share/virtualenvs/beancount-1FhiBumi/lib/python3.7/site-packages/sklearn/__init__.py", line 64, in <module>
    from .base import clone
  File "/home/matt/.local/share/virtualenvs/beancount-1FhiBumi/lib/python3.7/site-packages/sklearn/base.py", line 13, in <module>
    from .utils.fixes import signature
  File "/home/matt/.local/share/virtualenvs/beancount-1FhiBumi/lib/python3.7/site-packages/sklearn/utils/__init__.py", line 12, in <module>
    from .murmurhash import murmurhash3_32
  File "__init__.pxd", line 918, in init sklearn.utils.murmurhash
ValueError: numpy.ufunc size changed, may indicate binary incompatibility. Expected 216 from C header, got 192 from PyObject

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