[GODRIVER-2837] Prevent Makefile targets from swallowing errors Created: 09/May/23  Updated: 28/Oct/23  Resolved: 12/May/23

Status: Closed
Project: Go Driver
Component/s: None
Affects Version/s: None
Fix Version/s: 1.12.0

Type: Improvement Priority: Unknown
Reporter: Matt Dale Assignee: Matt Dale
Resolution: Fixed Votes: 0
Labels: release-improvements
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to GODRIVER-2831 Import failure in release v1.11.5 Closed
Documentation Changes: Not Needed
Documentation Changes Summary:

1. What would you like to communicate to the user about this feature?
2. Would you like the user to see examples of the syntax and/or executable code and its output?
3. Which versions of the driver/connector does this apply to?


 Description   

A recent release that failed to build on customers' workstations highlighted cases where the Makefile targets can silently swallow errors (see GODRIVER-2831). The main culprit is for loops in Makefiles, which only return the error code of the last evaluated statement in the loop. While we investigate better build systems, fix the issue in the short term by never using for loops in the Makefile.

Definition of done:

  • The Makefile does not use for loops.
  • Backport safe Makefile to release/1.11 branch.


 Comments   
Comment by Githook User [ 12/May/23 ]

Author:

{'name': 'Matt Dale', 'email': '9760375+matthewdale@users.noreply.github.com', 'username': 'matthewdale'}

Message: GODRIVER-2837 Backport safe Makefile to the release branch. (#1256)
Branch: release/1.11
https://github.com/mongodb/mongo-go-driver/commit/55fd8c9c30b37d48cf147901d98d942bc76ff23c

Comment by Githook User [ 11/May/23 ]

Author:

{'name': 'Matt Dale', 'email': '9760375+matthewdale@users.noreply.github.com', 'username': 'matthewdale'}

Message: GODRIVER-2837 Don't use for loops in the Makefile and always build test packages. (#1255)
Branch: master
https://github.com/mongodb/mongo-go-driver/commit/e102d9c7b07fd31bb32c08ad4c7bab8e619bce07

Comment by Matt Dale [ 09/May/23 ]

PR: https://github.com/mongodb/mongo-go-driver/pull/1255

Generated at Thu Feb 08 08:39:28 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.