Skip to content

Commit f08c52a

Browse files
support attribute values with floating-point numeric data type
1 parent 0d6b4da commit f08c52a

File tree

4 files changed

+6
-3
lines changed

4 files changed

+6
-3
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ on:
1010
- master
1111

1212
env:
13-
VEKTONN_PYTHON_PACKAGE_VERSION: 0.5.0
13+
VEKTONN_PYTHON_PACKAGE_VERSION: 0.5.1
1414

1515
jobs:
1616
test:

src/vektonn/dtos.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ class AttributeValueDto(VektonnBaseModel):
3434
guid: Optional[UUID]
3535
bool: Optional[bool]
3636
int64: Optional[int]
37+
float64: Optional[float]
3738
date_time: Optional[datetime]
3839

3940

tests/test_dtos.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@ def test_json_serialization__vector_sparse():
3838
'{"key":"int_key","value":{"int64":42}}'),
3939
(AttributeDto(key='int_key', value=AttributeValueDto(int64=0)),
4040
'{"key":"int_key","value":{"int64":0}}'),
41+
(AttributeDto(key='float_key', value=AttributeValueDto(float64=3.1415926)),
42+
'{"key":"float_key","value":{"float64":3.1415926}}'),
4143
(AttributeDto(
4244
key='DateTimeKey',
4345
value=AttributeValueDto(date_time=datetime(year=2021, month=11, day=23, hour=23, minute=59, second=1))),

tests/vektonn-docker/docker-compose.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: '3.8'
22

33
services:
44
vektonn-api:
5-
image: ghcr.io/vektonn/api-service:0.5.8
5+
image: ghcr.io/vektonn/api-service:0.5.12
66
hostname: vektonn-api
77
container_name: vektonn-api
88
depends_on:
@@ -16,7 +16,7 @@ services:
1616
- VEKTONN_KAFKA_BOOTSTRAP_SERVERS=kafka-broker:29092
1717

1818
vektonn-index-shard:
19-
image: ghcr.io/vektonn/index-shard-service:0.5.8
19+
image: ghcr.io/vektonn/index-shard-service:0.5.12
2020
hostname: vektonn-index-shard
2121
container_name: vektonn-index-shard
2222
depends_on:

0 commit comments

Comments
 (0)