Configuring exercism on MacOS seems broken

Open
#971 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
go, macos

Research direction

Reproduce the configuration with exercism configure from the home directory, then run exercism troubleshoot from the workspace subdirectory and compare the configuration lookup. Trace the CLI's config-discovery entry point to see why the token is missing; done means the configured token is recognized from challenge directories without rerunning configure.

Written by the indexing model from the issue text.

Description

I'm on MacOs Mojave, and things used to work months ago when I was using this cli.

Now, it seems that, when you set an workspace, and execute exercism troubleshoot, it only recognizes the token when you are in the directory that you issued the exercism configure command. See:

~ $  exercism configure --token=*************** --workspace=/Users/teixeira/Exercism

You have configured the Exercism command-line client:

Config dir:                       ~/.config/exercism
Token:         (-t, --token)      ***********
Workspace:     (-w, --workspace)  /Users/teixeira/Exercism
API Base URL:  (-a, --api)        https://api.exercism.io/v1

~ $ exercism troubleshoot

Troubleshooting Information
===========================

Version
----------------
Current: 3.0.13
Latest:  3.0.13


Operating System
----------------
OS:           darwin
Architecture: amd64


Configuration
----------------
Home:      /Users/teixeira
Workspace: /Users/teixeira/Exercism
Config:    ~/.config/exercism
API key:   4358*****************************657

API Reachability
----------------

GitHub:
    * https://api.github.com
    * [connected]
    * 155.35934ms

Exercism:
    * https://api.exercism.io/v1/ping
    * [connected]
    * 1.224142255s


If you are having trouble please file a GitHub issue at
https://github.com/exercism/exercism.io/issues and include
this information.

So token was recognized ok. Now if I cd into a subdir:

~ $ cd Exercism/python/
~/Exercism/python $ ls
acronym  grade-school  hello-world  isogram		 luhn	   matrix     scrabble-score	 twelve-days  word-count
clock	 hamming       high-scores  kindergarten-garden  markdown  raindrops  teste_markdown.py  two-fer
~/Exercism/python $ exercism troubleshoot

Troubleshooting Information
===========================

Version
----------------
Current: 3.0.13
Latest:  3.0.13


Operating System
----------------
OS:           darwin
Architecture: amd64


Configuration
----------------
Home:      /Users/teixeira
Workspace: /Users/teixeira/Exercism (default)
Config:    ~/.config/exercism
API key:   <not configured>
Find your API key at https://exercism.io/my/settings

API Reachability
----------------

GitHub:
    * https://api.github.com
    * [connected]
    * 148.12741ms

Exercism:
    * https://api.exercism.io/v1/ping
    * [connected]
    * 1.101968641s


If you are having trouble please file a GitHub issue at
https://github.com/exercism/exercism.io/issues and include
this information.

Not configured!

The workaround is to call exercism configure inside EVERY single challenge directory, so it creates a ~/.config structure and recognizes the token, but this is broken and didn't work like that before.....

Thanks for your attention.

Dominant language
Go
Stars
1.4k
Forks
363
Avg merge
6d 13h
Merged PRs (30d)
2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from exercism/cli

All issues in exercism/cli

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.