pcapriotti / pcapriotti/optparse-applicative

Handling argument deprecations and their warnings

Open
#323 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Haskell
Stars
959
Forks
123
Avg merge
3d 19h
Merged PRs (30d)
1

Description

Given the scenario:

  1. Argument --new was renamed to --old.
  2. --old should still do the same as --new but a warning should be printed.

This use-case can be seen when deprecating an argument in favor of other(s).

A similar use-case would be raising an error when --old is used. This would be useful when incompatible changes are introduced or when, after a deprecation cycle, the option is removed.

is there a common pattern that addresses these use-cases?

Contributor guide

No contributing guide indexed for this repository

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.

Research direction

The issue names no files, tests, or entry points; start by reviewing the option-parser API and its documentation for handling renamed or removed options. Done means establishing whether a reusable pattern supports preserving an old option with a warning and rejecting it after deprecation, with the behavior documented.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
cli
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.