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

sync: deprecated exercises are included in output #518

Closed
junedev opened this issue Feb 3, 2022 · 5 comments · Fixed by #682
Closed

sync: deprecated exercises are included in output #518

junedev opened this issue Feb 3, 2022 · 5 comments · Fixed by #682
Assignees
Labels
cmd: sync kind: bug User-facing incorrect behavior

Comments

@junedev
Copy link
Member

junedev commented Feb 3, 2022

I ran configlet sync in the JavaScript track and it reported

[warn] accumulate: missing 6 test cases
       - accumulate empty (64d97c14-36dd-44a8-9621-2cecebd6ed23)
       - accumulate squares (00008ed2-4651-4929-8c08-8b4dbd70872e)
       - accumulate upcases (551016da-4396-4cae-b0ec-4c3a1a264125)
       - accumulate reversed strings (cdf95597-b6ec-4eac-a838-3480d13d0d05)
       - accumulate recursively (bee8e9b6-b16f-4cd2-be3b-ccf7457e50bb)
       - accumulate recursively (0b357334-4cad-49e1-a741-425202edfc7c)

But the accumulate exercise is depreacted, both in the problem spec repo and in the JavaScript track config.json.

      {
        "slug": "accumulate",
        "name": "Accumulate",
        "uuid": "6ebe247c-3d11-48b7-8e6f-39f98359d233",
        "practices": [],
        "prerequisites": [],
        "difficulty": 5,
        "topics": ["algorithms", "callbacks", "loops", "lists"],
        "status": "deprecated"
      },

So it looked like a bug too me that it is still reported as "not in sync".

Configlet version: 4.0.0-alpha.36

@ErikSchierboom ErikSchierboom transferred this issue from exercism/docs Feb 4, 2022
@ErikSchierboom
Copy link
Member

I've moved this to the configlet repo.

@junedev
Copy link
Member Author

junedev commented Feb 4, 2022

Oopsie, that's where I wanted to post this. Thanks @ErikSchierboom!

@ee7 ee7 added cmd: sync kind: bug User-facing incorrect behavior labels Feb 4, 2022
@ee7
Copy link
Member

ee7 commented Feb 4, 2022

I guess configlet sync should ignore an exercise that is both out of sync, and deprecated on the track. But not ignore an exercise that is only deprecated in problem-specifications.

Agreed?

Otherwise, there isn't much point in allowing a deprecated exercise to be updated in problem-specifications (which is what happened with accumulate).

@junedev
Copy link
Member Author

junedev commented Feb 4, 2022

Yes, exactly.

@ErikSchierboom
Copy link
Member

Agreed!

@ee7 ee7 changed the title Deprecated exercises are included in configlet sync output sync: deprecated exercises are included in output May 15, 2022
kytrinyx added a commit to exercism/ruby that referenced this issue Oct 16, 2022
The accumulate exercise is deprecated, but configlet is warning
that it is outdated, so I decided to sync it and exclude all the new tests.

Configlet has an open issue about not linting these (exercism/configlet#518).
kotp pushed a commit to exercism/ruby that referenced this issue Oct 16, 2022
The accumulate exercise is deprecated, but configlet is warning
that it is outdated, so I decided to sync it and exclude all the new tests.

Configlet has an open issue about not linting these (exercism/configlet#518).
@ee7 ee7 self-assigned this Oct 18, 2022
@ee7 ee7 closed this as completed in #682 Oct 27, 2022
ee7 added a commit that referenced this issue Oct 27, 2022
Before this commit, `configlet sync` operated on every practice exercise
in the track-level `config.json` file, even if the exercise had a
`status` of `deprecated`.

For example, if only `accumulate` and `binary` are deprecated on the
track, and `word-count` has unsynced tests, we might see:

    $ configlet sync
    Updating cached 'problem-specifications' data...
    Checking exercises...
    [warn] docs: instructions unsynced: accumulate
    [warn] metadata: unsynced: binary
    [warn] accumulate: missing 6 test cases
           - accumulate empty (64d97c14-36dd-44a8-9621-2cecebd6ed23)
           - accumulate squares (00008ed2-4651-4929-8c08-8b4dbd70872e)
           - accumulate upcases (551016da-4396-4cae-b0ec-4c3a1a264125)
           - accumulate reversed strings (cdf95597-b6ec-4eac-a838-3480d13d0d05)
           - accumulate recursively (bee8e9b6-b16f-4cd2-be3b-ccf7457e50bb)
           - accumulate recursively (0b357334-4cad-49e1-a741-425202edfc7c)
    [warn] word-count: missing 1 test case
           - quotation for word with apostrophe (6d00f1db-901c-4bec-9829-d20eb3044557)
    [warn] some exercises have unsynced docs
    [warn] some exercises have unsynced metadata
    [warn] some exercises are missing test cases

With this commit, `configlet sync` ignores practice exercises that are
deprecated on the track:

    $ configlet sync
    Updating cached 'problem-specifications' data...
    Checking exercises...
    [warn] word-count: missing 1 test case
           - quotation for word with apostrophe (6d00f1db-901c-4bec-9829-d20eb3044557)
    [warn] some exercises are missing test cases

Note that `configlet sync` will still operate on an exercise that is
deprecated only in problem-specifications.

Fixes: #518
@ee7 ee7 moved this to Done in Configlet roadmap Oct 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cmd: sync kind: bug User-facing incorrect behavior
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants