duckietown / duckietown-shell-commands

Commands for the Duckietown Shell
4 stars 4 forks source link

dts challenge info #354

Open gyfkcq opened 1 year ago

gyfkcq commented 1 year ago

I had a problem installing C2, when #dts Challenges Info, the token was not displayed, and my ID was already displayed by the previous input token number. How to solve it?

The code shown is as follows:

●$ dts challenges info ●dts : Problems with a command? ● :
● : Report here: https://github.com/duckietown/duckietown-shell-commands/issues ● :
● : Troubleshooting: ● :
● : - If some commands update fail, delete ~/.dt-shell/commands ● :
● : - To reset the shell to "factory settings", delete ~/.dt-shell ● :
● : (Note: you will have to re-configure.) ●INFO:dts:Commands version: daffy ●INFO:dts:looking at /home/gyf/.dt-shell/commands-multi/daffy ●DEBUG:duckietown_docker_utils:duckietown_docker_utils version 6.1.1 path /home/gyf/.local/lib/python3.8/site-packages ●dts : Traceback (most recent call last): ● : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/main.py", line 40, in cli_main ● : climain() ● : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/main.py", line 201, in climain ● : shell.onecmd(cmdline) ● : File "/usr/lib/python3.8/cmd.py", line 217, in onecmd ● : return func(arg) ● : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/cli.py", line 284, in ● : do_command_lam = lambda s, w: do_command(klass, s, w) ● : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/dt_command_abs.py", line 48, in do_command ● : cls.command(shell, args) ● : File "/home/gyf/.dt-shell/commands-multi/daffy/challenges/command.py", line 17, in command ● : check_package_version("duckietown-docker-utils-daffy", "6.0.78") ● : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/package_version_check.py", line 47, in check_package_version ● : installed = _get_installed_distributions() ● : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/package_version_check.py", line 14, in _get_installed_distributions ● : from pip._internal.metadata import get_environment ● : ModuleNotFoundError: No module named 'pip._internal.metadata' ●WARNING:dts:Please update "pip" to have better debug info. ●dts : To report a bug, please also include the contents of /home/gyf/shell-debug-info.txt

jasonhu5 commented 1 year ago

Do you still see this issue? If so, could you please also include the contents of shell-debug-info.txt?

In the meantime, I would suggest performing a thorough update for dts and challenge related tools:

pip3 install --user --upgrade --no-cache-dir duckietown-shell
dts update
dts desktop update
gyfkcq commented 1 year ago

Hello, I have done it with three instructions as you said, but the bug is not solved.

shell-debug-info.txt: commands-version: daffy duckietown-shell: 5.4.5 duckietown-shell-commands: 5.4.5 encodings: locale: UTF-8 stderr: utf-8 stdout: utf-8 python: "3.8.10 (default, Nov 14 2022, 12:59:47) \n[GCC 9.4.0]"

Now I type dts challenge info, and the following code appears: dts : Problems with a command? :
: Report here: https://github.com/duckietown/duckietown-shell-commands/issues :
: Troubleshooting: :
: - If some commands update fail, delete ~/.dt-shell/commands :
: - To reset the shell to "factory settings", delete ~/.dt-shell :
: (Note: you will have to re-configure.) INFO:dts:Commands version: daffy INFO:dts:looking at /home/gyf/.dt-shell/commands-multi/daffy dts : An updated version of the commands is available. :
: Attempting auto-update. dts : Updating commands... dts : OK DEBUG:duckietown_docker_utils:duckietown_docker_utils version 6.1.1 path /home/gyf/.local/lib/python3.8/site-packages dts : Traceback (most recent call last): : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/main.py", line 40, in cli_main : climain() : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/main.py", line 201, in climain : shell.onecmd(cmdline) : File "/usr/lib/python3.8/cmd.py", line 217, in onecmd : return func(arg) : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/cli.py", line 284, in : do_command_lam = lambda s, w: do_command(klass, s, w) : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/dt_command_abs.py", line 48, in do_command : cls.command(shell, args) : File "/home/gyf/.dt-shell/commands-multi/daffy/challenges/command.py", line 17, in command : check_package_version("duckietown-docker-utils-daffy", "6.0.78") : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/package_version_check.py", line 47, in check_package_version : installed = _get_installed_distributions() : File "/home/gyf/.local/lib/python3.8/site-packages/dt_shell/package_version_check.py", line 14, in _get_installed_distributions : from pip._internal.metadata import get_environment : ModuleNotFoundError: No module named 'pip._internal.metadata' WARNING:dts:Please update "pip" to have better debug info. dts : To report a bug, please also include the contents of /home/gyf/shell-debug-info.txt

jesima31 commented 1 year ago

Is your pip updated?

python3 -m pip install --upgrade pip

gyfkcq commented 1 year ago

Yes,I did it according to your previous instructions

afdaniele commented 1 year ago

@gyfkcq Can you post the output of,

pip3 list
pip3 --version
gyfkcq commented 1 year ago

~$ pip3 list Package Version


apturl 0.5.2
async-timeout 4.0.2
attrs 19.3.0
base58 2.1.1
bcrypt 3.1.7
beautifulsoup4 4.11.1
blinker 1.4
Brlapi 0.7.0
cached-property 1.5.1
certifi 2019.11.28
chardet 3.0.4
click 8.1.3
colorama 0.4.3
command-not-found 0.3
cryptography 2.8
cupshelpers 1.0
dbus-python 1.2.16
defer 1.0.6
distro 1.4.0
distro-info 0.23ubuntu1
docker 4.1.0
docker-compose 1.25.0
dockerpty 0.4.1
dockertown 0.1.3
docopt 0.6.2
dt-authentication-daffy 0.1.16
dt-data-api-daffy 1.2.0
duckietown-docker-utils-daffy 6.1.1
duckietown-shell 5.4.5
duplicity 0.8.12.0
ecdsa 0.18.0
entrypoints 0.3
fasteners 0.14.1
future 0.18.2
gitdb 4.0.10
GitPython 3.1.30
httplib2 0.14.0
idna 2.8
ifaddr 0.2.0
importlib-metadata 1.5.0
jsonschema 3.2.0
keyring 18.0.1
language-selector 0.1
launchpadlib 1.10.13
lazr.restfulclient 0.14.2
lazr.uri 1.0.3
lockfile 0.12.2
louis 3.12.0
lxml 4.9.2
macaroonbakery 1.3.1
Mako 1.1.0
MarkupSafe 1.1.0
monotonic 1.5
more-itertools 4.2.0
netifaces 0.10.4
oauthlib 3.1.0
olefile 0.46
paramiko 2.6.0
pexpect 4.6.0
Pillow 7.0.0
pip 20.0.2
progressbar2 4.2.0
protobuf 3.6.1
psutil 5.9.4
pycairo 1.16.2
pycups 1.9.73
pydantic 1.10.4
PyGObject 3.36.0
PyJWT 1.7.1
pymacaroons 0.13.0
PyNaCl 1.3.0
pyRFC3339 1.1
pyrsistent 0.15.5
python-apt 2.0.0+ubuntu0.20.4.7 python-dateutil 2.7.3
python-debian 0.1.36ubuntu1
python-utils 3.4.5
pytz 2019.3
pyxdg 0.26
PyYAML 5.3.1
reportlab 3.5.34
requests 2.22.0
requests-unixsocket 0.2.0
SecretStorage 2.3.1
setuptools 45.2.0
simplejson 3.16.0
six 1.14.0
smmap 5.0.0
soupsieve 2.3.2.post1
style 1.1.0
systemd-python 234
termcolor 2.2.0
texttable 1.6.2
tqdm 4.64.1
typer 0.7.0
typing-extensions 4.4.0
ubuntu-advantage-tools 27.8
ubuntu-drivers-common 0.0.0
ufw 0.36
unattended-upgrades 0.1
update 0.0.1
urllib3 1.25.8
usb-creator 0.3.7
wadllib 1.3.3
websocket-client 0.53.0
wheel 0.34.2
whichcraft 0.6.1
xkit 0.0.0
zeroconf 0.47.1
zipp 1.0.0

~$ pip3 --version pip 20.0.2 from /usr/lib/python3/dist-packages/pip (python 3.8)

gyfkcq commented 1 year ago

@afdaniele