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

[countries-and-timezones] Add typings for v2.0 #39052

Merged
merged 4 commits into from Oct 18, 2019
Merged

[countries-and-timezones] Add typings for v2.0 #39052

merged 4 commits into from Oct 18, 2019

Conversation

pokonski
Copy link
Contributor

@pokonski pokonski commented Oct 11, 2019

Please fill in this template.

  • Use a meaningful title for the pull request. Include the name of the package modified.
  • Test the change in your own code. (Compile and run.)
  • Add or edit tests to reflect the change. (Run with npm test.)
  • Follow the advice from the readme.
  • Avoid common mistakes.
  • Run npm run lint package-name (or tsc if no tslint.json is present).
  • Provide a URL to documentation or source code which provides context for the suggested changes: https://github.com/manuelmhtr/countries-and-timezones/blob/master/CHANGELOG.md#200---2019-10-10
  • 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.
  • If you are making substantial changes, consider adding a tslint.json containing { "extends": "dtslint/dt.json" }. If for reason the any rule need to be disabled, disable it for that line using // tslint:disable-next-line [ruleName] and not for whole package so that the need for disabling can be reviewed.

@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?

countries-and-timezones/v2

These typings are for a package that doesn’t yet exist on master, so I don’t have anything to compare against yet! In the future, I’ll be able to compare PRs to countries-and-timezones with its source on master.

Comparison details for countries-and-timezones/v2 📊
Batch compilation
Type count 2088
Assignability cache size 110
Language service measurements
Samples taken 13
Identifiers in tests 13
getCompletionsAtPosition
    Mean duration (ms) 86.9
    Mean CV 17.3%
    Worst duration (ms) 123.0
    Worst identifier lib
getQuickInfoAtPosition
    Mean duration (ms) 82.6
    Mean CV 18.4%
    Worst duration (ms) 100.1
    Worst identifier lib
System information
Node version v10.16.3
CPU count 2
CPU speed 2.294 GHz
CPU model Intel(R) Xeon(R) CPU E5-2673 v4 @ 2.30GHz
CPU Architecture x64
Memory 6.8 GiB
Platform linux
Release 4.15.0-1059-azure

countries-and-timezones/v1

Comparison details for countries-and-timezones/v1 📊
master #39052 diff
Batch compilation
Memory usage (MiB) 31.1 31.3 +0.8%
Type count 2083 2083 0%
Assignability cache size 110 110 0%
Language service
Samples taken 9 9 0%
Identifiers in tests 9 9 0%
getCompletionsAtPosition
    Mean duration (ms) 93.1 93.2 +0.1%
    Mean CV 22.9% 24.2%
    Worst duration (ms) 110.3 114.4 +3.7%
    Worst identifier lib lib
getQuickInfoAtPosition
    Mean duration (ms) 83.4 81.3 -2.5%
    Mean CV 22.3% 19.7% -11.4%
    Worst duration (ms) 92.7 90.2 -2.7%
    Worst identifier lib getAllTimezones

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 Oct 11, 2019
@typescript-bot typescript-bot added New Definition This PR creates a new definition package. Awaiting reviewer feedback labels Oct 11, 2019
@typescript-bot
Copy link
Contributor

typescript-bot commented Oct 11, 2019

@pokonski Thank you for submitting this PR!

🔔 @zero51 - 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.

If no reviewer appears after a week, a DefinitelyTyped maintainer will review the PR instead.

Copy link
Member

@andrewbranch andrewbranch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it shouldn’t be necessary to preserve the v1 typings. The only reason to do that is if the v1 typings will need to be serviced more in the future—usually this is only done for extremely popular libraries that have to keep shipping updates to older versions. Since (I’m assuming) v1 of countries-and-timezones will probably not receive new changes from here on, v1 of @types/countries-and-timezones doesn’t need to be updated either.

@typescript-bot typescript-bot moved this from Review to Needs Author Attention in Pull Request Status Board Oct 15, 2019
@typescript-bot typescript-bot added Revision needed This PR needs code changes before it can be merged. and removed Awaiting reviewer feedback labels Oct 15, 2019
@typescript-bot
Copy link
Contributor

@pokonski One or more reviewers has requested changes. Please address their comments. I'll be back once they sign off or you've pushed new commits or comments. Thank you!

@typescript-bot
Copy link
Contributor

Updated numbers for you here from d877546.

These typings are for a package that doesn’t yet exist on master, so I don’t have anything to compare against yet! In the future, I’ll be able to compare PRs to countries-and-timezones with its source on master.

Comparison details 📊
Batch compilation
Type count 2088
Assignability cache size 110
Language service measurements
Samples taken 13
Identifiers in tests 13
getCompletionsAtPosition
    Mean duration (ms) 87.6
    Mean CV 17.2%
    Worst duration (ms) 131.2
    Worst identifier getTimezonesForCountry
getQuickInfoAtPosition
    Mean duration (ms) 83.9
    Mean CV 18.3%
    Worst duration (ms) 100.9
    Worst identifier lib
System information
Node version v10.16.3
CPU count 2
CPU speed 2.294 GHz
CPU model Intel(R) Xeon(R) CPU E5-2673 v4 @ 2.30GHz
CPU Architecture x64
Memory 6.8 GiB
Platform linux
Release 4.15.0-1059-azure

@typescript-bot typescript-bot removed the Perf: Same typescript-bot determined that this PR will not significantly impact compilation performance. label Oct 18, 2019
@typescript-bot typescript-bot removed the New Definition This PR creates a new definition package. label Oct 18, 2019
@typescript-bot
Copy link
Contributor

🔔 @andrewbranch - Thanks for your review of this PR! Can you please look at the new code and update your review status if appropriate?

Copy link
Member

@andrewbranch andrewbranch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@andrewbranch andrewbranch merged commit 18653ea into DefinitelyTyped:master Oct 18, 2019
Pull Request Status Board automation moved this from Needs Author Attention to Done Oct 18, 2019
@typescript-bot
Copy link
Contributor

I just published @types/countries-and-timezones@2.0.0 to npm.

@pokonski pokonski deleted the add-typings-for-countries-and-timezones-v2 branch October 20, 2019 14:44
chivesrs pushed a commit to chivesrs/DefinitelyTyped that referenced this pull request Nov 19, 2019
* [countries-and-timezones] Add typings for v2.0

* Fix path mapping

* Fix copy pasta mistake

* Remove v1 typings
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Revision needed This PR needs code changes before it can be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants