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

Add 'after' support #17925

Merged
merged 5 commits into from
Oct 22, 2023
Merged

Add 'after' support #17925

merged 5 commits into from
Oct 22, 2023

Conversation

curtisman
Copy link
Member

@curtisman curtisman commented Oct 22, 2023

Similar to 'before', 'after' will schedule the task to be executed after all the specified task is executed.

Also,

  • Allow '#' and '^' expands on before (and after) just like dependsOn.
  • Added more validation of task definitions
  • Detect circular references of tasks
  • Output padding based on the number of total tasks.

@curtisman curtisman requested a review from a team as a code owner October 22, 2023 00:07
@github-actions github-actions bot added area: build Build related issues base: main PRs targeted against main branch labels Oct 22, 2023
Copy link
Member

@tylerbutler tylerbutler left a comment

Choose a reason for hiding this comment

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

I'd like to review the comments a bit more but let's merge and I will follow up with another PR with comment changes and any questions. Then you can just review. Thanks again for doing this!

@@ -65,25 +65,47 @@ export abstract class Task {
// This function should only be called by task with task names
assert.notStrictEqual(this.taskName, undefined);
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
this.dependentTasks = this.node.getDependentTasks(this, this.taskName!, pendingInitDep);
this.dependentTasks = this.node.getDependsOnTasks(this, this.taskName!, pendingInitDep);
Copy link
Member

Choose a reason for hiding this comment

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

I wonder why the earlier assertion doesn't narrow the type here so the ! isn't needed?

Copy link
Member Author

Choose a reason for hiding this comment

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

Node's typing for the assert function probably doesn't have assertions.

@curtisman curtisman enabled auto-merge (squash) October 22, 2023 20:56
@curtisman curtisman merged commit 2758c95 into microsoft:main Oct 22, 2023
@curtisman curtisman deleted the ocpy branch October 22, 2023 21:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: build Build related issues base: main PRs targeted against main branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants