Skip to content
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

Running webex-skills project init switch encounter error #52

Closed
ChauncyYinXun opened this issue Jan 16, 2022 · 3 comments
Closed

Running webex-skills project init switch encounter error #52

ChauncyYinXun opened this issue Jan 16, 2022 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@ChauncyYinXun
Copy link

Hi, Team. I am using MacOS Monterey version 12.0.1 and python 3.7.5. I was following Webex Assistant Skills SDK Guide and encountered the following error when I was running:

webex-skills project init switch

I am getting:

Traceback (most recent call last):
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/bin/webex-skills", line 8, in <module>
    sys.exit(main())
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/webex_skills/cli/__init__.py", line 19, in main
    app()
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/typer/main.py", line 214, in __call__
    return get_command(self)(*args, **kwargs)
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/click/core.py", line 1128, in __call__
    return self.main(*args, **kwargs)
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/click/core.py", line 1053, in main
    rv = self.invoke(ctx)
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/click/core.py", line 1659, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/click/core.py", line 1659, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/click/core.py", line 1395, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/click/core.py", line 754, in invoke
    return __callback(*args, **kwargs)
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/typer/main.py", line 500, in wrapper
    return callback(**use_params)  # type: ignore
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/webex_skills/cli/project.py", line 39, in init
    if get_skill_config(skill_name):
  File "/Users/chauyin/.pyenv/versions/3.7.5/envs/webex-skills/lib/python3.7/site-packages/webex_skills/cli/config.py", line 16, in get_skill_config
    config = json.loads(config_file.read_text(encoding='utf-8')) or {}
  File "/Users/chauyin/.pyenv/versions/3.7.5/lib/python3.7/json/__init__.py", line 348, in loads
    return _default_decoder.decode(s)
  File "/Users/chauyin/.pyenv/versions/3.7.5/lib/python3.7/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/Users/chauyin/.pyenv/versions/3.7.5/lib/python3.7/json/decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

Any idea what's wrong? I am attaching my screenshot here.

Screen Shot 2022-01-16 at 11 59 08 PM

Screen Shot 2022-01-16 at 11 59 35 PM

@snow0x2d0 snow0x2d0 self-assigned this Jan 18, 2022
@snow0x2d0 snow0x2d0 added the bug Something isn't working label Jan 18, 2022
@snow0x2d0
Copy link
Contributor

It looks like your config directory exists but the file does not. The config and project initialization could use some cleanup anyway so I'll get a fix in soon. In the meantime you can just create an empty config file and you should be able to continue from there. You can create a config with something like: echo '{}' > ~/.skills-cli/config.json. Alternatively you could just remove the skills-cli directory itself if it's otherwise empty.

@ChauncyYinXun
Copy link
Author

Hi, @snow0x2d0. This is what I am getting after trying what you suggested echo '{}' > ~/.skills-cli/config.json
No configured remote with the name switch found

image

Can you advise? Thanks a lot!

@ChauncyYinXun
Copy link
Author

This is resolved. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants