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

Make options optional #5499

Merged
merged 2 commits into from
Jul 10, 2024
Merged

Make options optional #5499

merged 2 commits into from
Jul 10, 2024

Conversation

schaable
Copy link
Member

@schaable schaable commented Jul 9, 2024

Merge after #5495
Closes #5419

@schaable schaable added the v-next A Hardhat v3 development task label Jul 9, 2024
@schaable schaable requested a review from alcuadrado July 9, 2024 16:35
@schaable schaable self-assigned this Jul 9, 2024
Copy link

vercel bot commented Jul 9, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
hardhat ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 10, 2024 1:00pm

Copy link

changeset-bot bot commented Jul 9, 2024

⚠️ No Changeset found

Latest commit: 9bd70ac

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions github-actions bot added the status:ready This issue is ready to be worked on label Jul 9, 2024

// resolve defaults for optional arguments
if (value === undefined) {
taskArguments[option.name] = option.defaultValue;
Copy link
Member

@alcuadrado alcuadrado Jul 9, 2024

Choose a reason for hiding this comment

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

I wouldn't modify this input here, as that can be a user object.

Copy link
Member

Choose a reason for hiding this comment

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

Also, shouldn't we validate the type after resolving the default?

Copy link
Member Author

Choose a reason for hiding this comment

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

Will be addressed in a follow-up PR.

Copy link
Member

@alcuadrado alcuadrado left a comment

Choose a reason for hiding this comment

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

I just left two small comments.

Unfortunately, I think all your open PRs need to be rebased because of the new assertion-related eslint rules.

@schaable schaable force-pushed the sort-help-messages branch from 67037d5 to 1a6f115 Compare July 10, 2024 12:44
Base automatically changed from sort-help-messages to v-next July 10, 2024 12:46
@schaable schaable merged commit 378e9a8 into v-next Jul 10, 2024
52 checks passed
@schaable schaable deleted the make-options-optional branch July 10, 2024 13:32
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 9, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status:ready This issue is ready to be worked on v-next A Hardhat v3 development task
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants