From 125be91eedbde9ffaec9838e5ab7d94ef2760444 Mon Sep 17 00:00:00 2001 From: Spencer Nelson <spencer@twitch.tv> Date: Wed, 31 Jan 2018 09:27:38 -0800 Subject: [PATCH] Release version v5.2.0 This release includes the following changes: - Handling of Content-Type headers with name=value pairs after the MIME type is now correct. - Context values describing the requested service, package, and method are now available to HTTPClients passed to generated Twirp clients. - Generated clients no longer emit logs to the standard library logger under any circumstances. Instead, they will return any error encountered closing an HTTP response body if they found no other errors during the request. If they hit other errors, then HTTP response body close errors are ignored. - The vendor directory is now committed. This should make installation of protoc-gen-twirp more straightforward. --- clientcompat/internal/clientcompat/clientcompat.twirp.go | 8 ++++---- clientcompat/pycompat/clientcompat_pb2_twirp.py | 2 +- example/service.twirp.go | 8 ++++---- example/service_pb2_twirp.py | 2 +- internal/gen/version.go | 2 +- internal/twirptest/gogo_compat/service.twirp.go | 8 ++++---- internal/twirptest/importable/importable.twirp.go | 8 ++++---- internal/twirptest/importable/importable_pb2_twirp.py | 2 +- internal/twirptest/importer/importer.twirp.go | 8 ++++---- internal/twirptest/importer/importer_pb2_twirp.py | 2 +- internal/twirptest/multiple/multiple1.twirp.go | 8 ++++---- internal/twirptest/multiple/multiple1_pb2_twirp.py | 2 +- internal/twirptest/multiple/multiple2.twirp.go | 4 ++-- internal/twirptest/multiple/multiple2_pb2_twirp.py | 2 +- .../twirptest/no_package_name/no_package_name.twirp.go | 8 ++++---- .../no_package_name/no_package_name_pb2_twirp.py | 2 +- .../no_package_name_importer.twirp.go | 8 ++++---- .../no_package_name_importer_pb2_twirp.py | 2 +- internal/twirptest/proto/proto.twirp.go | 8 ++++---- internal/twirptest/proto/proto_pb2_twirp.py | 2 +- internal/twirptest/service.twirp.go | 8 ++++---- internal/twirptest/service_pb2_twirp.py | 2 +- 22 files changed, 53 insertions(+), 53 deletions(-) diff --git a/clientcompat/internal/clientcompat/clientcompat.twirp.go b/clientcompat/internal/clientcompat/clientcompat.twirp.go index 354368e5..bd6bae3d 100644 --- a/clientcompat/internal/clientcompat/clientcompat.twirp.go +++ b/clientcompat/internal/clientcompat/clientcompat.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: clientcompat.proto /* Package clientcompat is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. It is generated from these files: clientcompat.proto @@ -480,7 +480,7 @@ func (s *compatServiceServer) ServiceDescriptor() ([]byte, int) { } func (s *compatServiceServer) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -604,7 +604,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/clientcompat/pycompat/clientcompat_pb2_twirp.py b/clientcompat/pycompat/clientcompat_pb2_twirp.py index be8a070f..b0cf8abc 100644 --- a/clientcompat/pycompat/clientcompat_pb2_twirp.py +++ b/clientcompat/pycompat/clientcompat_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: clientcompat.proto import httplib diff --git a/example/service.twirp.go b/example/service.twirp.go index 786aab4b..3d77cb8e 100644 --- a/example/service.twirp.go +++ b/example/service.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: service.proto /* Package example is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. It is generated from these files: service.proto @@ -317,7 +317,7 @@ func (s *haberdasherServer) ServiceDescriptor() ([]byte, int) { } func (s *haberdasherServer) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -441,7 +441,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/example/service_pb2_twirp.py b/example/service_pb2_twirp.py index 5184fa0f..5ae6d8d5 100644 --- a/example/service_pb2_twirp.py +++ b/example/service_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: service.proto import httplib diff --git a/internal/gen/version.go b/internal/gen/version.go index 12e3c50d..65140cc2 100644 --- a/internal/gen/version.go +++ b/internal/gen/version.go @@ -13,4 +13,4 @@ package gen -const Version = "v5.1.0" +const Version = "v5.2.0" diff --git a/internal/twirptest/gogo_compat/service.twirp.go b/internal/twirptest/gogo_compat/service.twirp.go index 590ad127..4b6e7a8d 100644 --- a/internal/twirptest/gogo_compat/service.twirp.go +++ b/internal/twirptest/gogo_compat/service.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: service.proto /* Package gogo_compat is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. Test to make sure that Twirp plays well with code generated with github.com/gogo/protobuf/protoc-gen-gofast. @@ -319,7 +319,7 @@ func (s *svcServer) ServiceDescriptor() ([]byte, int) { } func (s *svcServer) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -443,7 +443,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/internal/twirptest/importable/importable.twirp.go b/internal/twirptest/importable/importable.twirp.go index fae20be1..31bee119 100644 --- a/internal/twirptest/importable/importable.twirp.go +++ b/internal/twirptest/importable/importable.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: importable.proto /* Package importable is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. Test to make sure that importing other packages doesnt break @@ -318,7 +318,7 @@ func (s *svcServer) ServiceDescriptor() ([]byte, int) { } func (s *svcServer) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -442,7 +442,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/internal/twirptest/importable/importable_pb2_twirp.py b/internal/twirptest/importable/importable_pb2_twirp.py index 5d0badf4..ae248e4e 100644 --- a/internal/twirptest/importable/importable_pb2_twirp.py +++ b/internal/twirptest/importable/importable_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: importable.proto import httplib diff --git a/internal/twirptest/importer/importer.twirp.go b/internal/twirptest/importer/importer.twirp.go index 953b110f..40b92334 100644 --- a/internal/twirptest/importer/importer.twirp.go +++ b/internal/twirptest/importer/importer.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: importer.proto /* Package importer is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. Test to make sure that importing other packages doesnt break @@ -320,7 +320,7 @@ func (s *svc2Server) ServiceDescriptor() ([]byte, int) { } func (s *svc2Server) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -444,7 +444,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/internal/twirptest/importer/importer_pb2_twirp.py b/internal/twirptest/importer/importer_pb2_twirp.py index 4b84cd8c..fdc38ae5 100644 --- a/internal/twirptest/importer/importer_pb2_twirp.py +++ b/internal/twirptest/importer/importer_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: importer.proto import httplib diff --git a/internal/twirptest/multiple/multiple1.twirp.go b/internal/twirptest/multiple/multiple1.twirp.go index 9b0758a6..6a01dcf3 100644 --- a/internal/twirptest/multiple/multiple1.twirp.go +++ b/internal/twirptest/multiple/multiple1.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: multiple1.proto /* Package multiple is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. test to make sure that multiple proto files in one package works @@ -319,7 +319,7 @@ func (s *svc1Server) ServiceDescriptor() ([]byte, int) { } func (s *svc1Server) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -443,7 +443,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/internal/twirptest/multiple/multiple1_pb2_twirp.py b/internal/twirptest/multiple/multiple1_pb2_twirp.py index 56b56784..dc450be1 100644 --- a/internal/twirptest/multiple/multiple1_pb2_twirp.py +++ b/internal/twirptest/multiple/multiple1_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: multiple1.proto import httplib diff --git a/internal/twirptest/multiple/multiple2.twirp.go b/internal/twirptest/multiple/multiple2.twirp.go index 970059ed..9cad2045 100644 --- a/internal/twirptest/multiple/multiple2.twirp.go +++ b/internal/twirptest/multiple/multiple2.twirp.go @@ -1,4 +1,4 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: multiple2.proto package multiple @@ -467,7 +467,7 @@ func (s *svc2Server) ServiceDescriptor() ([]byte, int) { } func (s *svc2Server) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } var twirpFileDescriptor1 = []byte{ diff --git a/internal/twirptest/multiple/multiple2_pb2_twirp.py b/internal/twirptest/multiple/multiple2_pb2_twirp.py index 0eb8ac53..dc25d46b 100644 --- a/internal/twirptest/multiple/multiple2_pb2_twirp.py +++ b/internal/twirptest/multiple/multiple2_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: multiple2.proto import httplib diff --git a/internal/twirptest/no_package_name/no_package_name.twirp.go b/internal/twirptest/no_package_name/no_package_name.twirp.go index 1d1c7d06..a865f18e 100644 --- a/internal/twirptest/no_package_name/no_package_name.twirp.go +++ b/internal/twirptest/no_package_name/no_package_name.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: no_package_name.proto /* Package no_package_name is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. It is generated from these files: no_package_name.proto @@ -315,7 +315,7 @@ func (s *svcServer) ServiceDescriptor() ([]byte, int) { } func (s *svcServer) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -439,7 +439,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/internal/twirptest/no_package_name/no_package_name_pb2_twirp.py b/internal/twirptest/no_package_name/no_package_name_pb2_twirp.py index 51017a6f..117bdd34 100644 --- a/internal/twirptest/no_package_name/no_package_name_pb2_twirp.py +++ b/internal/twirptest/no_package_name/no_package_name_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: no_package_name.proto import httplib diff --git a/internal/twirptest/no_package_name_importer/no_package_name_importer.twirp.go b/internal/twirptest/no_package_name_importer/no_package_name_importer.twirp.go index fbaf0a32..ee8714dc 100644 --- a/internal/twirptest/no_package_name_importer/no_package_name_importer.twirp.go +++ b/internal/twirptest/no_package_name_importer/no_package_name_importer.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: no_package_name_importer.proto /* Package no_package_name_importer is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. It is generated from these files: no_package_name_importer.proto @@ -317,7 +317,7 @@ func (s *svc2Server) ServiceDescriptor() ([]byte, int) { } func (s *svc2Server) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -441,7 +441,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/internal/twirptest/no_package_name_importer/no_package_name_importer_pb2_twirp.py b/internal/twirptest/no_package_name_importer/no_package_name_importer_pb2_twirp.py index 72be43b8..dcc19d27 100644 --- a/internal/twirptest/no_package_name_importer/no_package_name_importer_pb2_twirp.py +++ b/internal/twirptest/no_package_name_importer/no_package_name_importer_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: no_package_name_importer.proto import httplib diff --git a/internal/twirptest/proto/proto.twirp.go b/internal/twirptest/proto/proto.twirp.go index c7db8b5d..ce003ad7 100644 --- a/internal/twirptest/proto/proto.twirp.go +++ b/internal/twirptest/proto/proto.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: proto.proto /* Package proto is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. Test to make sure that a package named proto doesn't break @@ -318,7 +318,7 @@ func (s *svcServer) ServiceDescriptor() ([]byte, int) { } func (s *svcServer) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -442,7 +442,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/internal/twirptest/proto/proto_pb2_twirp.py b/internal/twirptest/proto/proto_pb2_twirp.py index 75159f73..7af69a2b 100644 --- a/internal/twirptest/proto/proto_pb2_twirp.py +++ b/internal/twirptest/proto/proto_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: proto.proto import httplib diff --git a/internal/twirptest/service.twirp.go b/internal/twirptest/service.twirp.go index 3aac6f8d..4c097a4b 100644 --- a/internal/twirptest/service.twirp.go +++ b/internal/twirptest/service.twirp.go @@ -1,9 +1,9 @@ -// Code generated by protoc-gen-twirp v5.1.0, DO NOT EDIT. +// Code generated by protoc-gen-twirp v5.2.0, DO NOT EDIT. // source: service.proto /* Package twirptest is a generated twirp stub package. -This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.1.0. +This code was generated with github.com/twitchtv/twirp/protoc-gen-twirp v5.2.0. It is generated from these files: service.proto @@ -317,7 +317,7 @@ func (s *haberdasherServer) ServiceDescriptor() ([]byte, int) { } func (s *haberdasherServer) ProtocGenTwirpVersion() string { - return "v5.1.0" + return "v5.2.0" } // ===== @@ -441,7 +441,7 @@ func newRequest(ctx context.Context, url string, reqBody io.Reader, contentType req.Header = customHeader } req.Header.Set("Content-Type", contentType) - req.Header.Set("Twirp-Version", "v5.1.0") + req.Header.Set("Twirp-Version", "v5.2.0") return req, nil } diff --git a/internal/twirptest/service_pb2_twirp.py b/internal/twirptest/service_pb2_twirp.py index af79b73e..c2b36a44 100644 --- a/internal/twirptest/service_pb2_twirp.py +++ b/internal/twirptest/service_pb2_twirp.py @@ -1,4 +1,4 @@ -# Code generated by protoc-gen-twirp_python v5.1.0, DO NOT EDIT. +# Code generated by protoc-gen-twirp_python v5.2.0, DO NOT EDIT. # source: service.proto import httplib