Sean_Moriarity:

No guarantees that changing the GRPC version will work correctly when building TF master.


It is quite common:

  

      github.com/tensorflow/tensorflow
  

  
    
  
    
  

  
    
      update grpc to v1.32.0 to fix val.val issues while compiling TFS from source 1
    

    
      tensorflow:master ← satishpasumarthi:grpc_fix
    

    
      
        opened 
        
          
        
        Oct 24, 2020
      
      

      
        
          
          satishpasumarthi
        
      

      
        
          +5
          -4
        
      
    
  


  
    - This PR addresses issue in TFS https://github.com/tensorflow/serving/issues/16…42 due to https://github.com/protocolbuffers/upb/issues/300.
- The fix for upb has gone into grpc v1.32.x
- This fix needs to go into TF from which TFS picks it up.
- This PR uses protobuf version upgrade to v3.15.1 and grpc 1.32.2

@mihaimaruseac @ncteisen : Could you please review this PR and see if this goes into 2.5 ?
  

  

  
    
    
  

  



  

      github.com/tensorflow/tensorflow
  

  
    
  
	  
  

  
    
      Failed when upgrading grpc to 1.36.0 1
    

    
      
        opened 
        
          
        
        Jul 28, 2021
      
      


      
        
          
          duanbing
        
      
    

    
        stat:awaiting tensorflower
        type:feature
        type:build/install
        TF 2.4
    
  


  
    <em>Please make sure that this is a feature request. As per our [GitHub Policy](…https://github.com/tensorflow/tensorflow/blob/master/ISSUES.md), we only address code/doc bugs, performance issues, feature requests and build/installation issues on GitHub. tag:feature_template</em>


**System information**
- TensorFlow version (you are using):  2.4.2
- Are you willing to contribute it (Yes/No): Yes, but no idea how get it work.


I try to upgrade grpc to 1.36 to use feature `grpc::experimental::TlsServerAuthorizationCheckConfig>` for client-side custom certificate verification.  Updates of workload.bzl: 
```
+++ b/tensorflow/workspace.bzl
@@ -650,8 +650,8 @@ def tf_repositories(path_prefix = "", tf_repo_name = ""):
     # WARNING: make sure ncteisen@ and vpai@ are cc-ed on any CL to change the below rule
     tf_http_archive(
         name = "com_github_grpc_grpc",
-        sha256 = "b956598d8cbe168b5ee717b5dafa56563eb5201a947856a6688bbeac9cac4e1f",
-        strip_prefix = "grpc-b54a5b338637f92bfcf4b0bc05e0f57a5fd8fadd",
+        sha256 = "019822cb6f1a339658fc620a54af9b710c39b540ae90e14c3babd6b16fb45b0f",
+        strip_prefix = "grpc-736e3758351ced3cd842bad3ba4e2540f01bbc48",
         system_build_file = clean_dep("//third_party/systemlibs:grpc.BUILD"),
         patch_file = clean_dep("//third_party/grpc:generate_cc_env_fix.patch"),
         system_link_files = {
@@ -664,8 +664,8 @@ def tf_repositories(path_prefix = "", tf_repo_name = ""):
             "//third_party/systemlibs:grpc.bazel.protobuf.bzl": "bazel/protobuf.bzl",
         },
         urls = [
-            "https://storage.googleapis.com/mirror.tensorflow.org/github.com/grpc/grpc/archive/b54a5b338637f92bfcf4b0bc05e0f57a5fd8fadd.tar.gz",
-            "https://github.com/grpc/grpc/archive/b54a5b338637f92bfcf4b0bc05e0f57a5fd8fadd.tar.gz",
+            "https://storage.googleapis.com/mirror.tensorflow.org/github.com/grpc/grpc/archive/736e3758351ced3cd842bad3ba4e2540f01bbc48.tar.gz",
+            "https://github.com/grpc/grpc/archive/736e3758351ced3cd842bad3ba4e2540f01bbc48.tar.gz",
```

but got errors as below:
```
ERROR: /root/.cache/bazel/_bazel_root/b2ed5105b9fe9c49ec55af56657398dc/external/upb/bazel/upb_proto_library.bzl:257:29: aspect() got unexpected keyword argument 'incompatible_use_toolchain_transition'
ERROR: /tf/src/tensorflow/tools/pip_package/BUILD:175:1: error loading package '@com_github_grpc_grpc//': in /root/.cache/bazel/_bazel_root/b2ed5105b9fe9c49ec55af56657398dc/external/com_github_grpc_grpc/bazel/grpc_build_system.bzl: Extension file 'bazel/upb_proto_library.bzl' has errors and referenced by '//tensorflow/tools/pip_package:licenses'
ERROR: Analysis of target '//tensorflow/tools/pip_package:build_pip_package' failed; build aborted: error loading package '@com_github_grpc_grpc//': in /root/.cache/bazel/_bazel_root/b2ed5105b9fe9c49ec55af56657398dc/external/com_github_grpc_grpc/bazel/grpc_build_system.bzl: Extension file 'bazel/upb_proto_library.bzl' has errors
INFO: Elapsed time: 1.187s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (29 packages loaded, 12 targets configured)
    currently loading: @com_google_protobuf// ... (2 packages)
    Fetching @rules_java; fetching
    Fetching @go_sdk; fetching
```
Could you give me some tips for debugging and upgrade?

Thanks!