Skip to content

Commit f9e22e1

Browse files
authored
Merge branch 'master' into slo-logs
2 parents 156a1cb + b3b6870 commit f9e22e1

File tree

6 files changed

+9
-4
lines changed

6 files changed

+9
-4
lines changed

.github/workflows/breaking.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ jobs:
1111
group: broken-changes-${{ github.ref }}
1212
cancel-in-progress: true
1313
runs-on: ubuntu-latest
14+
permissions:
15+
pull-requests: write
16+
contents: read
1417
steps:
1518
- name: Install Go
1619
uses: actions/setup-go@v3

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
* Added async put session into pool if external context is done
99
* Dropped intermediate callbacks from `trace.{Table,Retry,Query}` events
1010
* Wrapped errors from `internal/pool.Pool.getItem` as retryable
11+
* Disabled the logic of background grpc-connection parking
12+
* Improved stringification for postgres types
1113

1214
## v3.58.2
1315
* Added `trace.Query.OnSessionBegin` event

internal/types/types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,7 @@ func (v PgType) String() string {
479479
}
480480

481481
func (v PgType) Yql() string {
482-
return "pgunknown"
482+
return fmt.Sprintf("PgType(%v)", v.OID)
483483
}
484484

485485
func (v PgType) ToYDB(a *allocator.Allocator) *Ydb.Type {

internal/types/types_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ func TestTypeToString(t *testing.T) {
271271
},
272272
{
273273
t: PgType{OID: pg.OIDUnknown},
274-
s: "pgunknown",
274+
s: "PgType(705)",
275275
},
276276
} {
277277
t.Run(tt.s, func(t *testing.T) {

internal/value/value.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1267,7 +1267,7 @@ func (v pgValue) Yql() string {
12671267
//nolint:godox
12681268
// TODO: call special function for unknown oids
12691269
// https://github.com/ydb-platform/ydb/issues/2706
1270-
return fmt.Sprintf("PgUnknown(%q)", v.val)
1270+
return fmt.Sprintf(`PgConst("%v", PgType(%v))`, v.val, v.t.OID)
12711271
}
12721272

12731273
type setValue struct {

internal/value/value_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -502,7 +502,7 @@ func TestValueYql(t *testing.T) {
502502
},
503503
{
504504
value: PgValue(pg.OIDUnknown, "123"),
505-
literal: `PgUnknown("123")`,
505+
literal: `PgConst("123", PgType(705))`,
506506
},
507507
} {
508508
t.Run(strconv.Itoa(i)+"."+tt.literal, func(t *testing.T) {

0 commit comments

Comments
 (0)