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

Chore/types #137

Merged
merged 3 commits into from
Feb 20, 2020
Merged

Chore/types #137

merged 3 commits into from
Feb 20, 2020

Conversation

Shesekino
Copy link
Contributor

@Shesekino Shesekino commented Feb 19, 2020

  • Ready for review
  • Follows CONTRIBUTING rules
  • Reviewed by Snyk internal team

What does this PR do?

some cosmetic changes to prepare improvements in the image static scanning capabilities.
each commit has plenty of information but the gist is:

  1. bump typescript version
  2. refactor a single function to async/await
  3. add some types where possible and simple. it's a first step, still relying on many any's, but it only surfaces these any without introducing new ones.

Where should the reviewer start?

each commit separately.

How should this be manually tested?

as the changes are only cosmetic, I'm hoping our automated tests suffice here.
open to suggestions on how to manually test it!

Any background context you want to provide?

https://snyk.slack.com/archives/CS76EM7UM/p1582131635005500

What are the relevant tickets?

https://snyksec.atlassian.net/browse/RUN-697

@Shesekino Shesekino requested a review from a team as a code owner February 19, 2020 18:50
@Shesekino Shesekino self-assigned this Feb 19, 2020
@ghost ghost requested review from mladkau and removed request for a team February 19, 2020 18:50
runtime,
dependencies,
dockerfileAnalysis,
manifestFiles!, // bug in typescript wrongly adds `undefined`
Copy link
Contributor Author

Choose a reason for hiding this comment

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

to slightly clarify the API between this library and its users, add a bit of types where easy.
many of the types I've added rely on some "any"s because I'm trying to provide some initial value to make future work easier.

a single place uses the non-null assertion operator: apparently there's an open bug in typescript where Promise.all() wrongly adds " | undefined"
microsoft/TypeScript#33752
we'll try to keep an eye open here to see when it can be removed.
@Shesekino Shesekino merged commit b8671ef into master Feb 20, 2020
@snyksec
Copy link

snyksec commented Feb 23, 2020

🎉 This PR is included in version 2.1.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants