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

build: fix depot_tools patch application #39742

Merged
merged 1 commit into from
Sep 6, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
22 changes: 11 additions & 11 deletions .circleci/config/base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -249,23 +249,23 @@
cd depot_tools
cat > gclient.diff \<< 'EOF'
diff --git a/gclient.py b/gclient.py
index 3a9c5c6..f222043 100755
index c305c248..e6e0fbdc 100755
--- a/gclient.py
+++ b/gclient.py
@@ -712,7 +712,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):

if dep_type == 'cipd':
cipd_root = self.GetCipdRoot()
- for package in dep_value.get('packages', []):
+ packages = dep_value.get('packages', [])
+ for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
deps_to_add.append(
CipdDependency(
parent=self,
@@ -735,7 +735,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
if dep_type == 'cipd':
cipd_root = self.GetCipdRoot()
- for package in dep_value.get('packages', []):
+ packages = dep_value.get('packages', [])
+ for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
deps_to_add.append(
CipdDependency(parent=self,

Check failure on line 263 in .circleci/config/base.yml

View check run for this annotation

trop / Backportable? - 24-x-y

.circleci/config/base.yml#L254-L263

Patch Conflict
Raw output
++<<<<<<< HEAD
 +      @@ -712,7 +712,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
 +      
 +             if dep_type == 'cipd':
 +               cipd_root = self.GetCipdRoot()
 +      -        for package in dep_value.get('packages', []):
 +      +        packages = dep_value.get('packages', [])
 +      +        for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
 +                 deps_to_add.append(
 +                     CipdDependency(
 +                         parent=self,
++=======
+       @@ -735,7 +735,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
+  
+                    if dep_type == 'cipd':
+                        cipd_root = self.GetCipdRoot()
+       -                for package in dep_value.get('packages', []):
+       +                packages = dep_value.get('packages', [])
+       +                for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
+                            deps_to_add.append(
+                                CipdDependency(parent=self,
+                                               name=name,
++>>>>>>> build: fix depot_tools patch application

Check failure on line 263 in .circleci/config/base.yml

View check run for this annotation

trop / Backportable? - 24-x-y

.circleci/config/base.yml#L254-L263

Patch Conflict
Raw output
++<<<<<<< HEAD
 +      @@ -712,7 +712,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
 +      
 +             if dep_type == 'cipd':
 +               cipd_root = self.GetCipdRoot()
 +      -        for package in dep_value.get('packages', []):
 +      +        packages = dep_value.get('packages', [])
 +      +        for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
 +                 deps_to_add.append(
 +                     CipdDependency(
 +                         parent=self,
++=======
+       @@ -735,7 +735,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
+  
+                    if dep_type == 'cipd':
+                        cipd_root = self.GetCipdRoot()
+       -                for package in dep_value.get('packages', []):
+       +                packages = dep_value.get('packages', [])
+       +                for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
+                            deps_to_add.append(
+                                CipdDependency(parent=self,
+                                               name=name,
++>>>>>>> build: fix depot_tools patch application
name=name,
EOF
git apply --3way gclient.diff
fi
# Ensure depot_tools does not update.

Check failure on line 268 in .circleci/config/base.yml

View check run for this annotation

trop / Backportable? - 25-x-y

.circleci/config/base.yml#L259-L268

Patch Conflict
Raw output
++<<<<<<< HEAD
 +      @@ -712,7 +712,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
 +      
 +             if dep_type == 'cipd':
 +               cipd_root = self.GetCipdRoot()
 +      -        for package in dep_value.get('packages', []):
 +      +        packages = dep_value.get('packages', [])
 +      +        for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
 +                 deps_to_add.append(
 +                     CipdDependency(
 +                         parent=self,
++=======
+       @@ -735,7 +735,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
+  
+                    if dep_type == 'cipd':
+                        cipd_root = self.GetCipdRoot()
+       -                for package in dep_value.get('packages', []):
+       +                packages = dep_value.get('packages', [])
+       +                for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
+                            deps_to_add.append(
+                                CipdDependency(parent=self,
+                                               name=name,
++>>>>>>> build: fix depot_tools patch application

Check failure on line 268 in .circleci/config/base.yml

View check run for this annotation

trop / Backportable? - 25-x-y

.circleci/config/base.yml#L259-L268

Patch Conflict
Raw output
++<<<<<<< HEAD
 +      @@ -712,7 +712,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
 +      
 +             if dep_type == 'cipd':
 +               cipd_root = self.GetCipdRoot()
 +      -        for package in dep_value.get('packages', []):
 +      +        packages = dep_value.get('packages', [])
 +      +        for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
 +                 deps_to_add.append(
 +                     CipdDependency(
 +                         parent=self,
++=======
+       @@ -735,7 +735,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
+  
+                    if dep_type == 'cipd':
+                        cipd_root = self.GetCipdRoot()
+       -                for package in dep_value.get('packages', []):
+       +                packages = dep_value.get('packages', [])
+       +                for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
+                            deps_to_add.append(
+                                CipdDependency(parent=self,
+                                               name=name,
++>>>>>>> build: fix depot_tools patch application

Check failure on line 268 in .circleci/config/base.yml

View check run for this annotation

trop / Backportable? - 26-x-y

.circleci/config/base.yml#L259-L268

Patch Conflict
Raw output
++<<<<<<< HEAD
 +      @@ -712,7 +712,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
 +      
 +             if dep_type == 'cipd':
 +               cipd_root = self.GetCipdRoot()
 +      -        for package in dep_value.get('packages', []):
 +      +        packages = dep_value.get('packages', [])
 +      +        for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
 +                 deps_to_add.append(
 +                     CipdDependency(
 +                         parent=self,
++=======
+       @@ -735,7 +735,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
+  
+                    if dep_type == 'cipd':
+                        cipd_root = self.GetCipdRoot()
+       -                for package in dep_value.get('packages', []):
+       +                packages = dep_value.get('packages', [])
+       +                for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
+                            deps_to_add.append(
+                                CipdDependency(parent=self,
+                                               name=name,
++>>>>>>> build: fix depot_tools patch application

Check failure on line 268 in .circleci/config/base.yml

View check run for this annotation

trop / Backportable? - 26-x-y

.circleci/config/base.yml#L259-L268

Patch Conflict
Raw output
++<<<<<<< HEAD
 +      @@ -712,7 +712,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
 +      
 +             if dep_type == 'cipd':
 +               cipd_root = self.GetCipdRoot()
 +      -        for package in dep_value.get('packages', []):
 +      +        packages = dep_value.get('packages', [])
 +      +        for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
 +                 deps_to_add.append(
 +                     CipdDependency(
 +                         parent=self,
++=======
+       @@ -735,7 +735,8 @@ class Dependency(gclient_utils.WorkItem, DependencySettings):
+  
+                    if dep_type == 'cipd':
+                        cipd_root = self.GetCipdRoot()
+       -                for package in dep_value.get('packages', []):
+       +                packages = dep_value.get('packages', [])
+       +                for package in (x for x in packages if "infra/3pp/tools/swift-format" not in x.get('package')):
+                            deps_to_add.append(
+                                CipdDependency(parent=self,
+                                               name=name,
++>>>>>>> build: fix depot_tools patch application
test -d depot_tools && cd depot_tools
touch .disable_auto_update

Expand Down