Skip to content
This repository was archived by the owner on Feb 8, 2021. It is now read-only.

Commit 8f86437

Browse files
committed
some syntax errors fix
1 parent 38fd6fd commit 8f86437

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

novahyper/virt/hyper/api.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717
import json
1818

1919
class HyperClient(object):
20-
def __init__(self, url):
21-
self.base_url = url
20+
def __init__(self):
21+
pass
2222

2323
def ping(self):
2424
try:

novahyper/virt/hyper/client.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ class HyperHTTPClient(
3333
api.HyperClient):
3434

3535
def __init__(self, url='unix://var/run/hyper.sock'):
36-
super(HyperHTTPClient, self).__init__(url)
36+
super(HyperHTTPClient, self).__init__()
3737
self.base_url = url
3838
self._version = DEFAULT_VERSION
3939
self.timeout = TIMEOUT

novahyper/virt/hyper/driver.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ def get_available_resource(self, nodename):
286286

287287
memory = hostinfo.get_memory_usage()
288288
disk = hostinfo.get_disk_usage()
289-
cur_hv_type = hv_type.KVM #todo: check
289+
cur_hv_type = hv_type.HYPER #todo: check
290290
stats = {
291291
'vcpus': hostinfo.get_total_vcpus(),
292292
'vcpus_used': hostinfo.get_vcpus_used(self.list_instances(True)),
@@ -295,7 +295,7 @@ def get_available_resource(self, nodename):
295295
'local_gb': disk['total'] / units.Gi,
296296
'local_gb_used': disk['used'] / units.Gi,
297297
'disk_available_least': disk['available'] / units.Gi,
298-
'hypervisor_type': 'kvm', #todo: check
298+
'hypervisor_type': 'hyper', #todo: check
299299
'hypervisor_version': utils.convert_version_to_int('1.0'),
300300
'hypervisor_hostname': self._nodename,
301301
'cpu_info': '?',

0 commit comments

Comments
 (0)