[CDRIVER-2889] Fetch source in task instead of in "pre" section of Evergreen config Created: 28/Nov/18  Updated: 15/Apr/22  Resolved: 15/Apr/22

Status: Closed
Project: C Driver
Component/s: tests
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Minor - P4
Reporter: Kevin Albertson Assignee: Unassigned
Resolution: Won't Do Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Epic Link: CDRIVER-2733

 Description   

Currently our evergreen config fetches the git repository in the "pre" section, which runs before every task.

There are two problems with this:

1. Tasks that don't need to fetch the source always do needlessly. Integration test tasks don't need the source, they fetch the build from the dependant compilation task.

2. I've been bitten by Evergreen patch builds with a base commit that did not exist in upstream. This has happened to me when I've pushed commits to my fork (origin) before pushing to upstream, and creating a patch build afterwards. That's my mistake, but "pre" scripts that fail do so silently (as documented on the Evergreen wiki). So patch builds like this one end up checking out mongo-c-driver, not applying the patch, but running the rest of the task - causing confusing errors.

Instead of fetching the source in "pre", we should do it in the command list of individual tasks. That way we don't needlessly fetch source for tasks that don't need it, and if it fails we'll know right away.


Generated at Wed Feb 07 21:16:38 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.