fastogt / fastonosql

FastoNoSQL is a crossplatform Redis, Memcached, SSDB, LevelDB, RocksDB, UnQLite, LMDB, ForestDB, Pika, Dynomite, KeyDB GUI management tool.
https://fastonosql.com
GNU General Public License v3.0
1.18k stars 96 forks source link

TypeError: 'NotImplementedType' object is not callable #61

Closed gcarq closed 6 years ago

gcarq commented 6 years ago

Raises TypeError in build.py if build on an unknown platform (commit b6f636edf7a4d99fff241708a6d83fdd0a241d75). NotImplementedError should be raised instead.

Backtrace:

Traceback (most recent call last):
  File "build.py", line 269, in <module>
    request = BuildRequest(platform_str, arch_name_str)
  File "build.py", line 88, in __init__
    self.platform_ = platform_or_none.make_platform_by_arch(arch, platform_or_none.package_types())
  File "/tmp/experiment/venv/lib/python3.6/site-packages/pyfastogt-1.0.0-py3.6.egg/pyfastogt/system_info.py", line 123, in make_platform_by_arch
    distr = linux_get_dist()
  File "/tmp/experiment/venv/lib/python3.6/site-packages/pyfastogt-1.0.0-py3.6.egg/pyfastogt/system_info.py", line 91, in linux_get_dist
    raise NotImplemented("Unknown platform '%s'" % dist_name)
TypeError: 'NotImplementedType' object is not callable

How to reproduce:

mkdir -p /tmp/experiment
cd /tmp/experiment
python -m venv venv
source venv/bin/activate

git clone https://github.com/fastogt/fastonosql
cd fastonosql
git submodule update --init --recursive
cd ..

git clone https://github.com/fastogt/pyfastogt
cd pyfastogt
python setup.py install
cd ..

cd fastonosql/build
python build.py ..

System info:

$ cat /etc/*release
Arch Linux release
LSB_VERSION=1.4
DISTRIB_ID=Arch
DISTRIB_RELEASE=rolling
DISTRIB_DESCRIPTION="Arch Linux"
NAME="Arch Linux"
PRETTY_NAME="Arch Linux"
ID=arch
ID_LIKE=archlinux
ANSI_COLOR="0;36"
HOME_URL="https://www.archlinux.org/"
SUPPORT_URL="https://bbs.archlinux.org/"
BUG_REPORT_URL="https://bugs.archlinux.org/
topilski commented 6 years ago

Hi, please update python scripts, i didn't have arch

gcarq commented 6 years ago

Thanks for the quick reply, are there plans to support builds on unsupported platforms (thus seeing all required dependencies as met)? Can you give me a pointer what to change? Unfortunately adapting the script isn't as easy as just adding Arch to a list.

topilski commented 6 years ago

Hi @gcarq i think need update here: https://github.com/fastogt/pyfastogt/blob/master/pyfastogt/system_info.py#L91

topilski commented 6 years ago

Also need add ArchPlatform https://github.com/fastogt/pyfastogt/blob/master/pyfastogt/system_info.py#L123

topilski commented 6 years ago

I will fix it

topilski commented 6 years ago

Hi @gcarq , i updated pyfastogt scripts please try again.

topilski commented 6 years ago

ping

gcarq commented 6 years ago

@topilski Thanks a lot, works as expected