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

feat(yargs): add types for yargs@v17 #52169

Merged
merged 4 commits into from May 21, 2021
Merged

Conversation

bcoe
Copy link
Contributor

@bcoe bcoe commented Apr 3, 2021

yargs@17 is a major overhaul of how asynchronous commands, builders, and middleware are handled (it's now possible to await parse() and await .argv).

This should not be merged until yargs/yargs#1876 is released (once Node 10 is EOL).

If changing an existing definition:

  • Provide a URL to documentation or source code which provides context for the suggested changes: chore: release 17.0.0 yargs/yargs#1876
  • If this PR brings the type definitions up to date with a new version of the JS library, update the version number in the header.

@typescript-bot typescript-bot added Has Merge Conflict This PR can't be merged because it has a merge conflict. The author needs to update it. Edits Owners This PR adds or removes owners Critical package Check Config Changes a module config files labels Apr 3, 2021
@typescript-bot typescript-bot added this to Needs Author Action in New Pull Request Status Board Apr 3, 2021
@typescript-bot
Copy link
Contributor

typescript-bot commented Apr 3, 2021

@bcoe Thank you for submitting this PR! I see this is your first time submitting to DefinitelyTyped 👋 — I'm the local bot who will help you through the process of getting things through.

This is a live comment which I will keep updated.

1 package in this PR

@bcoe: I see that you have added yourself as an owner, are you sure you want to become an owner?

Code Reviews

Because this is a widely-used package, a DT maintainer will need to review it before it can be merged.

Status

  • ✅ No merge conflicts
  • ✅ Continuous integration tests have passed
  • 🕐 A DT maintainer needs to approve changes which affect module config files

Once every item on this list is checked, I'll ask you for permission to merge and publish the changes.


Diagnostic Information: What the bot saw about this PR
{
  "type": "info",
  "now": "-",
  "pr_number": 52169,
  "author": "bcoe",
  "headCommitOid": "291405ff143eb82ec9e3f1e11176f349a75c716c",
  "lastPushDate": "2021-05-21T00:33:35.000Z",
  "lastActivityDate": "2021-05-21T00:33:35.000Z",
  "hasMergeConflict": false,
  "isFirstContribution": true,
  "tooManyFiles": false,
  "popularityLevel": "Critical",
  "pkgInfo": [
    {
      "name": "yargs",
      "kind": "edit",
      "files": [
        {
          "path": "types/yargs/index.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/yargs/v16/helpers.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/yargs/v16/index.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/yargs/v16/tsconfig.json",
          "kind": "package-meta-ok"
        },
        {
          "path": "types/yargs/v16/tslint.json",
          "kind": "package-meta",
          "suspect": "not [the expected form](https://github.com/DefinitelyTyped/DefinitelyTyped#user-content-linter-tslintjson) (check: `rules`)"
        },
        {
          "path": "types/yargs/v16/yargs-tests.ts",
          "kind": "test"
        },
        {
          "path": "types/yargs/v16/yargs.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/yargs/yargs-tests.ts",
          "kind": "test"
        }
      ],
      "owners": [
        "poelstra",
        "mizunashi-mana",
        "pushplay",
        "JimiC",
        "steffenvv",
        "forivall",
        "ExE-Boss",
        "Aankhen"
      ],
      "addedOwners": [
        "bcoe"
      ],
      "deletedOwners": [],
      "popularityLevel": "Critical"
    }
  ],
  "reviews": [],
  "ciResult": "pass"
}

@typescript-bot
Copy link
Contributor

🔔 @poelstra @mizunashi-mana @pushplay @JimiC @steffenvv @forivall @ExE-Boss @Aankhen — please review this PR in the next few days. Be sure to explicitly select Approve or Request Changes in the GitHub UI so I know what's going on.

@typescript-bot
Copy link
Contributor

@bcoe Unfortunately, this pull request currently has a merge conflict 😥. Please update your PR branch to be up-to-date with respect to master. Have a nice day!

@typescript-bot typescript-bot removed the Has Merge Conflict This PR can't be merged because it has a merge conflict. The author needs to update it. label Apr 3, 2021
@typescript-bot typescript-bot moved this from Needs Author Action to Waiting for Code Reviews in New Pull Request Status Board Apr 3, 2021
@typescript-bot typescript-bot added the The CI failed When GH Actions fails label Apr 3, 2021
@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Author Action in New Pull Request Status Board Apr 3, 2021
@typescript-bot
Copy link
Contributor

@bcoe The CI build failed! Please review the logs for more information.

Once you've pushed the fixes, the build will automatically re-run. Thanks!

@typescript-bot typescript-bot removed the The CI failed When GH Actions fails label Apr 3, 2021
@typescript-bot typescript-bot moved this from Needs Author Action to Waiting for Code Reviews in New Pull Request Status Board Apr 3, 2021
@typescript-bot typescript-bot added the The CI failed When GH Actions fails label Apr 3, 2021
@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Author Action in New Pull Request Status Board Apr 3, 2021
@typescript-bot
Copy link
Contributor

@bcoe The CI build failed! Please review the logs for more information.

Once you've pushed the fixes, the build will automatically re-run. Thanks!

@typescript-bot typescript-bot removed the The CI failed When GH Actions fails label Apr 4, 2021
@typescript-bot typescript-bot moved this from Needs Author Action to Waiting for Code Reviews in New Pull Request Status Board Apr 4, 2021
@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Maintainer Review in New Pull Request Status Board Apr 4, 2021
@typescript-bot
Copy link
Contributor

👋 Hi there! I’ve run some quick measurements against master and your PR. These metrics should help the humans reviewing this PR gauge whether it might negatively affect compile times or editor responsiveness for users who install these typings.

Let’s review the numbers, shall we?

These typings are for a version of yargs that doesn’t yet exist on master, so I’ve compared them with v16.0.

Comparison details 📊
16.0@master 17.0 in #52169 diff
Batch compilation
Memory usage (MiB) 87.7 89.2 +1.8%
Type count 16984 17408 +2%
Assignability cache size 3010 3061 +2%
Language service
Samples taken 1578 1546 -2%
Identifiers in tests 1578 1546 -2%
getCompletionsAtPosition
    Mean duration (ms) 374.3 367.8 -1.7%
    Mean CV 9.5% 9.0%
    Worst duration (ms) 721.3 762.9 +5.8%
    Worst identifier yargs array
getQuickInfoAtPosition
    Mean duration (ms) 371.4 366.5 -1.3%
    Mean CV 9.3% 9.0%
    Worst duration (ms) 698.3 750.7 +7.5%
    Worst identifier positional default

It looks like nothing changed too much. I won’t post performance data again unless it gets worse.

@typescript-bot typescript-bot added the Perf: Same typescript-bot determined that this PR will not significantly impact compilation performance. label Apr 4, 2021
bcoe added a commit to yargs/yargs that referenced this pull request Apr 4, 2021
Introduces parseSync/parseAsync, allowing an application to explicitly state whether or not it expects the parse goal of yargs to be asynchronous or synchronous.

Refs: DefinitelyTyped/DefinitelyTyped#52169
@bcoe
Copy link
Contributor Author

bcoe commented Apr 4, 2021

this issue is tracking the additional work to be done for yargs@v17.

@typescript-bot
Copy link
Contributor

Re-ping @poelstra, @mizunashi-mana, @pushplay, @JimiC, @steffenvv, @forivall, @ExE-Boss, @Aankhen:

This PR has been out for over a week, yet I haven't seen any reviews.

Could someone please give it some attention? Thanks!

@typescript-bot typescript-bot added the Unreviewed No one showed up to review this PR, so it'll be reviewed by a DT maintainer. label Apr 15, 2021
@forivall
Copy link
Contributor

Please mark the PR as "Draft" status in github so that wee ol' typescript-bot knows it's still WIP!

@bcoe bcoe marked this pull request as ready for review May 2, 2021 18:59
@typescript-bot typescript-bot removed the Unreviewed No one showed up to review this PR, so it'll be reviewed by a DT maintainer. label May 2, 2021
@typescript-bot typescript-bot moved this from Needs Author Action to Waiting for Code Reviews in New Pull Request Status Board May 2, 2021
@bcoe
Copy link
Contributor Author

bcoe commented May 2, 2021

@forivall just released v17 of yargs, the bulk of the changes relate to handling of asynchronous behavior.

@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Maintainer Review in New Pull Request Status Board May 2, 2021
@elibarzilay elibarzilay moved this from Needs Maintainer Review to Waiting for Code Reviews in New Pull Request Status Board May 4, 2021
@typescript-bot
Copy link
Contributor

Re-ping @poelstra, @mizunashi-mana, @pushplay, @JimiC, @steffenvv, @forivall, @ExE-Boss, @Aankhen:

This PR has been out for over a week, yet I haven't seen any reviews.

Could someone please give it some attention? Thanks!

@typescript-bot typescript-bot added Unreviewed No one showed up to review this PR, so it'll be reviewed by a DT maintainer. Has Merge Conflict This PR can't be merged because it has a merge conflict. The author needs to update it. and removed Unreviewed No one showed up to review this PR, so it'll be reviewed by a DT maintainer. labels May 13, 2021
@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Author Action in New Pull Request Status Board May 18, 2021
@typescript-bot
Copy link
Contributor

@bcoe Unfortunately, this pull request currently has a merge conflict 😥. Please update your PR branch to be up-to-date with respect to master. Have a nice day!

@typescript-bot typescript-bot added Unreviewed No one showed up to review this PR, so it'll be reviewed by a DT maintainer. and removed Has Merge Conflict This PR can't be merged because it has a merge conflict. The author needs to update it. labels May 21, 2021
@typescript-bot typescript-bot moved this from Needs Author Action to Needs Maintainer Action in New Pull Request Status Board May 21, 2021
@typescript-bot
Copy link
Contributor

It has been more than two weeks and this PR still has no reviews.

I'll bump it to the DT maintainer queue. Thank you for your patience, @bcoe.

(Ping @poelstra, @mizunashi-mana, @pushplay, @JimiC, @steffenvv, @forivall, @ExE-Boss, @Aankhen.)

@typescript-bot typescript-bot removed the Unreviewed No one showed up to review this PR, so it'll be reviewed by a DT maintainer. label May 21, 2021
@typescript-bot typescript-bot moved this from Needs Maintainer Action to Waiting for Code Reviews in New Pull Request Status Board May 21, 2021
@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Maintainer Review in New Pull Request Status Board May 21, 2021
@weswigham weswigham merged commit 2772f88 into DefinitelyTyped:master May 21, 2021
@typescript-bot typescript-bot removed this from Needs Maintainer Review in New Pull Request Status Board May 21, 2021
@typescript-bot
Copy link
Contributor

I just published @types/yargs@17.0.0 to npm.

@typescript-bot
Copy link
Contributor

I just published @types/yargs@16.0.3 to npm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Check Config Changes a module config files Critical package Edits Owners This PR adds or removes owners Perf: Same typescript-bot determined that this PR will not significantly impact compilation performance.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants