Installation steps don't work
Closed this issue · 4 comments
It seems that I'm unable to install the Apache Kibble from sources:
➜ pip install -e setup/.
Obtaining file:///Users/tomaszurbaszek/kibble/setup
ERROR: Command errored out with exit status 2:
command: /Users/tomaszurbaszek/.virtualenvs/kibble/bin/python3.6 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/Users/tomaszurbaszek/kibble/setup/setup.py'"'"'; __file__='"'"'/Users/tomaszurbaszek/kibble/setup/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /private/var/folders/_j/9tm1bndd0x909p5l34tsg4mw0000gn/T/pip-pip-egg-info-n31j6zo4
cwd: /Users/tomaszurbaszek/kibble/setup/
Complete output (5 lines):
/Users/tomaszurbaszek/kibble/setup/setup.py:36: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.
myyaml = yaml.load(open("kibble.yaml.sample"))
usage: setup.py [-h] [-e HOSTNAME] [-p PORT] [-d DBNAME] [-s SHARDS]
[-r REPLICAS] [-m MAILHOST] [-a] [-k]
setup.py: error: unrecognized arguments: egg_info --egg-base /private/var/folders/_j/9tm1bndd0x909p5l34tsg4mw0000gn/T/pip-pip-egg-info-n31j6zo4
----------------------------------------
ERROR: Command errored out with exit status 2: python setup.py egg_info Check the logs for full command output.
➜ cd setup
➜ pip install setup.py
ERROR: Could not find a version that satisfies the requirement setup.py (from versions: none)
ERROR: No matching distribution found for setup.py
I'm happy to improve it but at first, I would like to make sure that it's a real problem and not me.
What installation instructions are you following? The official documentation does not mention using pip install
for setup.py.
It specifically mentions this example:
- git clone https://github.com/apache/kibble.git /var/www/kibble
- cd /var/www/kibble/setup
- pip3 install -r requirements.txt
- python3 setup.py
Oh, sorry my bad... the python setup.py
works as described.
However, this is rather uncommon to use setup.py
in this way. The main purpose of this script should be to allow users to install the package using setuptools as described here:
https://packaging.python.org/tutorials/packaging-projects/#creating-setup-py
So I would like to propose to refactor this a little bit to avoid confusion with already known ways of installing and using python projects. WDYT @Humbedooh ?
That assumes that this is a python package, which it is not :) It's a simple WSGI web site.
I don't mind working towards a making it a proper pip package, but I think we'd need to discuss the overall structure and code if so.
The base code has been largely untouched for 3 years, perhaps it's time to build a kibble backend v2 and discuss how we want it to work. I could think of many improvements such as using type hints (bonus points for annotated types from 3.9) to define APIs etc, maybe use asyncio and aiohttp for the server...
Thanks @Humbedooh! Once I'm more familiar with the whole codebase I will be happy to help with bringing some improvements to Apache Kibble 👍
In the meantime I'm closing this issue as it seems to be solved.