pycupra 0.0.1__py3-none-any.whl → 0.0.3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pycupra/__version__.py +1 -1
- pycupra/dashboard.py +1287 -1258
- pycupra/vehicle.py +13 -11
- {pycupra-0.0.1.dist-info → pycupra-0.0.3.dist-info}/METADATA +1 -1
- pycupra-0.0.3.dist-info/RECORD +13 -0
- pycupra-0.0.1.dist-info/RECORD +0 -13
- {pycupra-0.0.1.dist-info → pycupra-0.0.3.dist-info}/WHEEL +0 -0
- {pycupra-0.0.1.dist-info → pycupra-0.0.3.dist-info}/licenses/LICENSE +0 -0
- {pycupra-0.0.1.dist-info → pycupra-0.0.3.dist-info}/top_level.txt +0 -0
pycupra/vehicle.py
CHANGED
@@ -1075,7 +1075,7 @@ class Vehicle:
|
|
1075
1075
|
last_connected = last_connected_utc.replace(tzinfo=timezone.utc).astimezone(tz=None)
|
1076
1076
|
else:
|
1077
1077
|
last_connected = datetime.strptime(last_connected_utc,'%Y-%m-%dT%H:%M:%SZ').replace(tzinfo=timezone.utc).astimezone(tz=None)
|
1078
|
-
return last_connected
|
1078
|
+
return last_connected #.strftime('%Y-%m-%d %H:%M:%S')
|
1079
1079
|
|
1080
1080
|
@property
|
1081
1081
|
def is_last_connected_supported(self):
|
@@ -1282,13 +1282,15 @@ class Vehicle:
|
|
1282
1282
|
minutes = int(self.attrs.get('charging', {}).get('status', {}).get('charging', {}).get('remainingTimeInMinutes', 0))
|
1283
1283
|
else:
|
1284
1284
|
minutes = 0
|
1285
|
-
|
1286
|
-
|
1287
|
-
|
1288
|
-
|
1289
|
-
|
1290
|
-
|
1291
|
-
|
1285
|
+
return minutes
|
1286
|
+
#try:
|
1287
|
+
# if minutes == -1: return '00:00'
|
1288
|
+
# if minutes == 65535: return '00:00'
|
1289
|
+
# return "%02d:%02d" % divmod(minutes, 60)
|
1290
|
+
#except Exception:
|
1291
|
+
# pass
|
1292
|
+
#return '00:00'
|
1293
|
+
return 0
|
1292
1294
|
|
1293
1295
|
@property
|
1294
1296
|
def is_charging_time_left_supported(self):
|
@@ -1332,15 +1334,15 @@ class Vehicle:
|
|
1332
1334
|
"""Return true if external power is connected."""
|
1333
1335
|
response = ''
|
1334
1336
|
if self.attrs.get('charging', False):
|
1335
|
-
response = self.attrs.get('charging', {}).get('status', {}).get('
|
1337
|
+
response = self.attrs.get('charging', {}).get('status', {}).get('plug', {}).get('externalPower', '')
|
1336
1338
|
else:
|
1337
1339
|
response = ''
|
1338
|
-
return True if response in ['stationConnected', 'available', 'Charging'] else False
|
1340
|
+
return True if response in ['stationConnected', 'available', 'Charging', 'ready'] else False
|
1339
1341
|
|
1340
1342
|
@property
|
1341
1343
|
def is_external_power_supported(self):
|
1342
1344
|
"""External power supported."""
|
1343
|
-
if self.attrs.get('charging', {}).get('status', {}).get('
|
1345
|
+
if self.attrs.get('charging', {}).get('status', {}).get('plug, {}').get('externalPower', False):
|
1344
1346
|
return True
|
1345
1347
|
|
1346
1348
|
@property
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: pycupra
|
3
|
-
Version: 0.0.
|
3
|
+
Version: 0.0.3
|
4
4
|
Summary: A library to read and send vehicle data via Cupra/Seat portal using the same API calls as the MyCupra/MySeat mobile app.
|
5
5
|
Home-page: https://github.com/WulfgarW/pycupra
|
6
6
|
Author: WulfgarW
|
@@ -0,0 +1,13 @@
|
|
1
|
+
pycupra/__init__.py,sha256=VPzUfKd5mBFD1UERNV61FbGHih5dQPupLgIfYtmIUi4,230
|
2
|
+
pycupra/__version__.py,sha256=vOTajmv3IRptr-g9nG6y6xUN06JYKI_30Dty1N88ekk,207
|
3
|
+
pycupra/connection.py,sha256=9EXvTbBZJTcCAef5mYuvldAxBcNnxxxCdPZfi2_TtdM,76264
|
4
|
+
pycupra/const.py,sha256=Mx9pPZifQBpn9lTsLH8R7xkUHrXRvul8w_b6LLLD7gE,10038
|
5
|
+
pycupra/dashboard.py,sha256=a62F3Zsw2UyBUjYFOrhnqdSk2o2cSkSvmj67FwO8taw,37726
|
6
|
+
pycupra/exceptions.py,sha256=Nq_F79GP8wjHf5lpvPy9TbSIrRHAJrFMo0T1N9TcgSQ,2917
|
7
|
+
pycupra/utilities.py,sha256=cH4MiIzT2WlHgmnl_E7rR0R5LvCXfDNvirJolct50V8,2563
|
8
|
+
pycupra/vehicle.py,sha256=v9U_cBQGXwa8dsmqyfQZm2WGOZ9uKqWW7FoiO4JsAw0,108436
|
9
|
+
pycupra-0.0.3.dist-info/licenses/LICENSE,sha256=HrhfyXIkWY2tGFK11kg7vPCqhgh5DcxleloqdhrpyMY,11558
|
10
|
+
pycupra-0.0.3.dist-info/METADATA,sha256=scTdNoBQznv8WlxbYmU0MDLOEpYkyp_j9EFaeLr8tkM,2578
|
11
|
+
pycupra-0.0.3.dist-info/WHEEL,sha256=CmyFI0kx5cdEMTLiONQRbGQwjIoR1aIYB7eCAQ4KPJ0,91
|
12
|
+
pycupra-0.0.3.dist-info/top_level.txt,sha256=9Lbj_jG4JvpGwt6K3AwhWFc0XieDnuHFOP4x44wSXSQ,8
|
13
|
+
pycupra-0.0.3.dist-info/RECORD,,
|
pycupra-0.0.1.dist-info/RECORD
DELETED
@@ -1,13 +0,0 @@
|
|
1
|
-
pycupra/__init__.py,sha256=VPzUfKd5mBFD1UERNV61FbGHih5dQPupLgIfYtmIUi4,230
|
2
|
-
pycupra/__version__.py,sha256=RPTQ353sB0uLocLwAxWtJQh9oeF8Z1LzKtstisfsDT4,207
|
3
|
-
pycupra/connection.py,sha256=9EXvTbBZJTcCAef5mYuvldAxBcNnxxxCdPZfi2_TtdM,76264
|
4
|
-
pycupra/const.py,sha256=Mx9pPZifQBpn9lTsLH8R7xkUHrXRvul8w_b6LLLD7gE,10038
|
5
|
-
pycupra/dashboard.py,sha256=127hWC-1-BjF5Fx_b6BwVVntrc0jm3WEneRG0R_9GbM,35335
|
6
|
-
pycupra/exceptions.py,sha256=Nq_F79GP8wjHf5lpvPy9TbSIrRHAJrFMo0T1N9TcgSQ,2917
|
7
|
-
pycupra/utilities.py,sha256=cH4MiIzT2WlHgmnl_E7rR0R5LvCXfDNvirJolct50V8,2563
|
8
|
-
pycupra/vehicle.py,sha256=--9K8IXoq8swFWVUvf_jD5v0tm4ilM_tCU8yf7OS3Zk,108414
|
9
|
-
pycupra-0.0.1.dist-info/licenses/LICENSE,sha256=HrhfyXIkWY2tGFK11kg7vPCqhgh5DcxleloqdhrpyMY,11558
|
10
|
-
pycupra-0.0.1.dist-info/METADATA,sha256=qDe0tJ8RW4fko1nCSEUj0ijUgvFj5val0GpK1C4e1ro,2578
|
11
|
-
pycupra-0.0.1.dist-info/WHEEL,sha256=CmyFI0kx5cdEMTLiONQRbGQwjIoR1aIYB7eCAQ4KPJ0,91
|
12
|
-
pycupra-0.0.1.dist-info/top_level.txt,sha256=9Lbj_jG4JvpGwt6K3AwhWFc0XieDnuHFOP4x44wSXSQ,8
|
13
|
-
pycupra-0.0.1.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|