Closed chathawee closed 6 months ago
Hi @chathawee ! Can you try using the --reinstall
option instead? The internal virtual environment is likely symlinked to the older python version. The --reinstall
option should delete the old venv and create a new one.
curl --silent --show-error --location-trusted https://raw.githubusercontent.com/thoughtspot/cs_tools/master/cs_tools/updater/_bootstrapper.py | python3 - --reinstall
It's passed now and I can run it. Thanks @boonhapus
First Stop
Platform Configuration
Python 3.8 CentOS 7
Description
I already installed the cs_tools on the CentOS7 but I faced the error about TypeError: 'type' object is not subscriptable. However, before I install the CS tools, I have upgraded the python from python3.6.8 to version 3.8.0. After I done upgrade the python. I have run this command
sys.exit(run())
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/cli/main.py", line 136, in run
_setup_tools(_tools.app, ctx_settings=app.info.context_settings)
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/cli/main.py", line 94, in _setup_tools
tool = get_cs_tool(path.name)
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/programmatic.py", line 21, in get_cs_tool
return CSTool(tool_dir)
File "pydantic/dataclasses.py", line 348, in pydantic.dataclasses._add_pydantic_validation_attributes.new_init
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/cli/loader.py", line 47, in post_init_post_parse__
self.app.rich_help_panel = "Available Tools"
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/cli/loader.py", line 117, in app
return self.lib.app
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/cli/loader.py", line 108, in lib
self._lib = importlib.import_module(import_path)
File "/usr/local/lib/python3.8/importlib/init.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1014, in _gcd_import
File "", line 991, in _find_and_load
File "", line 975, in _find_and_load_unlocked
File "", line 671, in _load_unlocked
File "", line 783, in exec_module
File "", line 219, in _call_with_frames_removed
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/cli/tools/git/ init__.py", line 2, in
from .app import app
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/cli/tools/git/app.py", line 12, in
from .config import app as configApp
File "/root/.config/cs_tools/.cs_tools/lib/python3.8/site-packages/cs_tools/cli/tools/git/config.py", line 176, in
def _show_configs_as_table(configs: list[dict], title: str = "Configuration Details"):
TypeError: 'type' object is not subscriptable
curl --silent --show-error --location-trusted https://raw.githubusercontent.com/thoughtspot/cs_tools/master/cs_tools/updater/_bootstrapper.py | python3 - --install
After done restarting the terminal. I started the command withcs_tools version
but I got the error below Traceback (most recent call last): File "/root/.config/cs_tools/.cs_tools/bin/cs_tools", line 8, inCould anyone help fix this?
Thanks, May