-
Notifications
You must be signed in to change notification settings - Fork 38
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
Packaging #86
Packaging #86
Conversation
Gives a path issue when using pytest https://stackoverflow.com/a/41752043
Tests is no longer a package, so relative imports need to be replaced with absolute imports
This makes installation a lot easier as it takes care of installing the required dependencies automatically, provided npm is installed.
No longer needed, now in readabilipy/javascript
This can happen if a user installs the package from a binary wheel but doesn't have node installed.
Previous build failed because pytest was outdated
commit 025128e Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:52:35 2020 +0100 Ignore test directory with pylint Seems to be a known issue of pylint: https://stackoverflow.com/a/48025817 commit cf1e0eb Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:44:57 2020 +0100 Ignore missing __init__ in pylint Seems to be no other way to tell pylint that test is not a package commit ed367eb Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:38:38 2020 +0100 Also check major version of Node is sufficient commit ff4f1e7 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:29:48 2020 +0100 Add code style checking to Makefile commit 55a6c6d Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:29:38 2020 +0100 Fix remaining code style errors commit 4cb1c10 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:18:41 2020 +0100 Fix erroneous missing init error A test directory is not a package, it shouldn't have an __init__.py. commit 73c3c43 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:13:19 2020 +0100 Fix some code style issues commit abccad8 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:08:48 2020 +0100 Remove debug statements from setup.py commit 0b827aa Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:08:39 2020 +0100 Use pre-installed nvm to update node commit f27fc37 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 23:02:15 2020 +0100 Make sure nvm installs the version we want commit 14be23a Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 22:46:04 2020 +0100 Try updating node version using nvm commit ff20467 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 22:40:41 2020 +0100 Check nvm remotes Seems like Travis has its own node installation, even in this python-language vm. We'll need to somehow bypass that. commit af8c10b Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 22:31:03 2020 +0100 check npm config commit 5501e5e Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 22:13:25 2020 +0100 This can't be it, right? commit af6a402 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 22:08:04 2020 +0100 Check node version commit aefa005 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 22:04:30 2020 +0100 List installed packages commit dbe4c1c Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 22:02:06 2020 +0100 Try removing old npm first? commit be0c49f Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 21:57:01 2020 +0100 Try updating npm? Node is stuck on version 8.12.0 somehow commit d2bc162 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 21:51:16 2020 +0100 Update node version jsdom requires a newer version of node commit 9f8b599 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 21:30:20 2020 +0100 Debugging travis commit 757a318 Author: Gertjan van den Burg <[email protected]> Date: Sat Jun 20 21:18:50 2020 +0100 Debugging travis
Hi @GjjvdBurg - it looks like this PR has been waiting for review for a while, but I've only just got a notification about it. It looks good, but it might be nice to talk it through in person (I've not thought about this code base for over a year, so I might need to get back up to speed). Shall we set up a Zoom call later this week? |
Hi @jemrobinson! No worries, I actually only realised yesterday that I'd never requested a review on this PR, which is probably why you didn't get a notification. Happy to talk it through in person, I'll write you on slack to arrange a time. |
This ensures that it is pulled from the __version__ file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some thoughts/questions I had while looking this over. Overall I'm pretty happy with it though.
This PR reshuffles the repo a bit to facilitate packaging the module as a Python package. I'd like to use this package in another project and having it on PyPI would make that a lot easier.
This PR makes the following main changes:
simple_json.py
is updated to handle this. This makes installation easier and works even when installed as a binary wheel.extract_article.py
into the package, as a command line entry point. This is then installed as thereadabilipy
executable.I'm happy to push to PyPI myself if you'd like.