Repository navigation
Open
Description
Proposal:
According to Point definition, Point has only one field. However, influxdb-client-python allows Point class to has fields, like so:
influxdb-client-python/tests/test_point.py
Lines 71 to 94 in 854fc6c
| def test_FieldTypes(self): | |
| point = Point.measurement("h2o") \ | |
| .tag("location", "europe") \ | |
| .field("long", 1) \ | |
| .field("double", 250.69) \ | |
| .field("float", 35.0) \ | |
| .field("integer", 7) \ | |
| .field("short", 8) \ | |
| .field("byte", 9) \ | |
| .field("ulong", 10) \ | |
| .field("uint", 11) \ | |
| .field("sbyte", 12) \ | |
| .field("ushort", 13) \ | |
| .field("point", 13.3) \ | |
| .field("decimal", 25.6) \ | |
| .field("decimal-object", Decimal('0.142857')) \ | |
| .field("boolean", False) \ | |
| .field("string", "string value") | |
| expected = "h2o,location=europe boolean=false,byte=9i,decimal=25.6,decimal-object=0.142857,double=250.69," \ | |
| "float=35,integer=7i,long=1i,point=13.3,sbyte=12i,short=8i,string=\"string value\"," \ | |
| "uint=11i,ulong=10i,ushort=13i" | |
| self.assertEqual(expected, point.to_line_protocol()) |
So, I think that we should rename Point class to Points class.
Metadata
Metadata
Assignees
Labels
No labels
Activity