OpenIxia / IxNetwork

A central location for IxNetwork sample scripts and utilities. Please also visit http://openixia.com
MIT License
50 stars 59 forks source link

the script "loadJsonConfigFile.robot" can not work #18

Closed sonicwallsun closed 6 years ago

sonicwallsun commented 6 years ago

the script "loadJsonConfigFile.robot" can not work 。Error happen in executing function “”fileMgmtObj.Import Json Config File‘’, shown that " 20181018 14:21:31.029 : INFO : 14:21:31.020000: Reading saved config file 20181018 14:21:31.032 : FAIL : TypeError: initial_value must be unicode or None, not str Ending test: Robot.loadJsonConfigFile.Load a JSON config file "

hubertgee commented 6 years ago

Hi sonicwallsun,

I know about this bug and this has been fixed recently. Please get latest updates. I verified it on Robot Framework also.

Thanks, Hubert

sonicwallsun commented 6 years ago

Hi ,Huberts I updated the script and checked again ,and the bug reproducted And the the Modules files is not newest in git,Can you check it for me ? Thanks Best regards

[cid:image001.png@01D467BF.47CAE240]

From: Hubert Gee notifications@github.com Sent: 2018年10月19日 12:14 To: OpenIxia/IxNetwork IxNetwork@noreply.github.com Cc: Lin Sun LSun@SonicWall.com; Author author@noreply.github.com Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Hi sonicwallsun,

I know about this bug and this has been fixed recently. Please get latest updates. I verified it on Robot Framework also.

Thanks, Hubert

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/OpenIxia/IxNetwork/issues/18#issuecomment-431239456, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AqNKdYzTdgjk_OKhnDoiW_ELo7kLhLrGks5umVGDgaJpZM4Xvk-w.

hubertgee commented 6 years ago

Can you email me the file ixNetRestApi.py? Which ixnetwork version are you using?

Hubert On mobile


From: sonicwallsun notifications@github.com Sent: Friday, October 19, 2018 12:31:28 AM To: OpenIxia/IxNetwork Cc: GEE,HUBERT (K-USA,ex1); State change Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Hi ,Huberts I updated the script and checked again ,and the bug reproducted And the the Modules files is not newest in git,Can you check it for me ? Thanks Best regards

[cid:image001.png@01D467BF.47CAE240]

From: Hubert Gee notifications@github.com Sent: 2018年10月19日 12:14 To: OpenIxia/IxNetwork IxNetwork@noreply.github.com Cc: Lin Sun LSun@SonicWall.com; Author author@noreply.github.com Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Hi sonicwallsun,

I know about this bug and this has been fixed recently. Please get latest updates. I verified it on Robot Framework also.

Thanks, Hubert

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/OpenIxia/IxNetwork/issues/18#issuecomment-431239456, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AqNKdYzTdgjk_OKhnDoiW_ELo7kLhLrGks5umVGDgaJpZM4Xvk-w.

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-431271640&data=02%7C01%7C%7C4a39237844064f9511c508d63594e2a2%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636755310911138275&sdata=pBuRmDdh8Jbqn75cxCf1jPXPNpJ3KVW0bZaHuandnnQ%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYXyOZTiOVHHDw84uyTY5ePXUu5kW5ks5umX_QgaJpZM4Xvk-w&data=02%7C01%7C%7C4a39237844064f9511c508d63594e2a2%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636755310911148287&sdata=leD3YPqLpD14l6Y3a5dztK9r%2B6j7TKDQh8i1SaQfPOY%3D&reserved=0.

sonicwallsun commented 5 years ago

Hi .Hubert the version for IxNetwork is 8.40,as below: [cid:image001.png@01D46A26.B9D802F0] Thanks

From: Hubert Gee notifications@github.com Sent: 2018年10月19日 12:14 To: OpenIxia/IxNetwork IxNetwork@noreply.github.com Cc: Lin Sun LSun@SonicWall.com; Author author@noreply.github.com Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Hi sonicwallsun,

I know about this bug and this has been fixed recently. Please get latest updates. I verified it on Robot Framework also.

Thanks, Hubert

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/OpenIxia/IxNetwork/issues/18#issuecomment-431239456, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AqNKdYzTdgjk_OKhnDoiW_ELo7kLhLrGks5umVGDgaJpZM4Xvk-w.

hubertgee commented 5 years ago

Hi,

It should work. Did you get the latest updates and retry?

Hubert Gee

From: sonicwallsun notifications@github.com Sent: Monday, October 22, 2018 9:44 AM To: OpenIxia/IxNetwork IxNetwork@noreply.github.com Cc: GEE,HUBERT (K-USA,ex1) hubert.gee@keysight.com; State change state_change@noreply.github.com Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Hi .Hubert the version for IxNetwork is 8.40,as below: [cid:image001.png@01D46A26.B9D802F0] Thanks

From: Hubert Gee notifications@github.com<mailto:notifications@github.com> Sent: 2018年10月19日 12:14 To: OpenIxia/IxNetwork IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com> Cc: Lin Sun LSun@SonicWall.com<mailto:LSun@SonicWall.com>; Author author@noreply.github.com<mailto:author@noreply.github.com> Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Hi sonicwallsun,

I know about this bug and this has been fixed recently. Please get latest updates. I verified it on Robot Framework also.

Thanks, Hubert

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/OpenIxia/IxNetwork/issues/18#issuecomment-431239456, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AqNKdYzTdgjk_OKhnDoiW_ELo7kLhLrGks5umVGDgaJpZM4Xvk-w.

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-431891959&data=02%7C01%7C%7C63f707df416940fd6e1008d6383d870f%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636758234255885518&sdata=tIAHaVCRklHWJtjSzNB9h9nvxua7AlS0O1yvsKnofyA%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYX-moC2UvM_i7RvrzVAYbkr8YZQaQks5unfW9gaJpZM4Xvk-w&data=02%7C01%7C%7C63f707df416940fd6e1008d6383d870f%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636758234255885518&sdata=K%2FN0ZFAsPffELhiNHn2u7s9nbaf0tZ%2BXbwwaseN9LKk%3D&reserved=0.

sonicwallsun commented 5 years ago

row 389 and 390 in IxNetRestApiFileMgmt.py : import io configContents = io.StringIO(configContents) . now my python version is 2.7.14,and can not execute those two rows ,can it modified as : configContents = io.BytesIO(configContents) ? thanks

hubertgee commented 5 years ago

Now that you mentioned you’re using Python v2, the problem is that Python v2 uses a different module called StringIO. I added code to support both Python versions. I tested both versions and it’s working. Please get the updated file IxNetRestApiFileMgmt.py and retry.

    # for python3
    if platform.python_version().startswith('3'):
        import io
        configContents = io.StringIO(configContents)

    # for python2
    if platform.python_version().startswith('2'):
        import StringIO
        configContents = StringIO.StringIO(configContents)

Thanks, Hubert Gee

From: sonicwallsun notifications@github.com Sent: Wednesday, October 24, 2018 7:59 PM To: OpenIxia/IxNetwork IxNetwork@noreply.github.com Cc: GEE,HUBERT (K-USA,ex1) hubert.gee@keysight.com; State change state_change@noreply.github.com Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

row 389 and 390 in IxNetRestApiFileMgmt.py : import io configContents = io.StringIO(configContents) . now my python version is 2.7.14,and can not execute those two rows ,can it modified as : configContents = io.BytesIO(configContents) ? thanks

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-432897154&data=02%7C01%7C%7C0dcfa33c9c2044c520f108d63a25c9ac%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636760331304447168&sdata=q51mh%2Fkp1gslDJFSkhe0N5lQfODUe1RewSMl8EP3bfw%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYX2AYcF7KpzRBEviijZLAdNB68cxGks5uoSjogaJpZM4Xvk-w&data=02%7C01%7C%7C0dcfa33c9c2044c520f108d63a25c9ac%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636760331304447168&sdata=NFf4Afs4uweHbYozcrzaaIN1guzFvvvva75IKl%2FqnNk%3D&reserved=0.

sonicwallsun commented 5 years ago

Now the function “fileMgmtObj.Import Json Config File” is OK,but something wrong with the function “fileMgmtObj.Json Assign Ports”, The IxNetwork config file and log for error are below ,can you check it for me ,thanks !

From: Hubert Gee notifications@github.com Sent: 2018年10月26日 1:10 To: OpenIxia/IxNetwork IxNetwork@noreply.github.com Cc: Lin Sun LSun@SonicWall.com; Author author@noreply.github.com Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Now that you mentioned you’re using Python v2, the problem is that Python v2 uses a different module called StringIO. I added code to support both Python versions. I tested both versions and it’s working. Please get the updated file IxNetRestApiFileMgmt.py and retry.

for python3

if platform.python_version().startswith('3'): import io configContents = io.StringIO(configContents)

for python2

if platform.python_version().startswith('2'): import StringIO configContents = StringIO.StringIO(configContents)

Thanks, Hubert Gee

From: sonicwallsun notifications@github.com<mailto:notifications@github.com> Sent: Wednesday, October 24, 2018 7:59 PM To: OpenIxia/IxNetwork IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com> Cc: GEE,HUBERT (K-USA,ex1) hubert.gee@keysight.com<mailto:hubert.gee@keysight.com>; State change state_change@noreply.github.com<mailto:state_change@noreply.github.com> Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

row 389 and 390 in IxNetRestApiFileMgmt.py : import io configContents = io.StringIO(configContents) . now my python version is 2.7.14,and can not execute those two rows ,can it modified as : configContents = io.BytesIO(configContents) ? thanks

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-432897154&data=02%7C01%7C%7C0dcfa33c9c2044c520f108d63a25c9ac%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636760331304447168&sdata=q51mh%2Fkp1gslDJFSkhe0N5lQfODUe1RewSMl8EP3bfw%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYX2AYcF7KpzRBEviijZLAdNB68cxGks5uoSjogaJpZM4Xvk-w&data=02%7C01%7C%7C0dcfa33c9c2044c520f108d63a25c9ac%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636760331304447168&sdata=NFf4Afs4uweHbYozcrzaaIN1guzFvvvva75IKl%2FqnNk%3D&reserved=0.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/OpenIxia/IxNetwork/issues/18#issuecomment-433132066, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AqNKdYNPfMC5Ztj0XTRi4_78w9OU-kaNks5uofCEgaJpZM4Xvk-w.

hubertgee commented 5 years ago

Hi,

Don’t use jsonAssignPorts. I’m going to remove it today. Follow the sample scripts in Github.

portObj = PortMgmt(mainObj)

portObj.connectIxChassis(ixChassisIp)

if portObj.arePortsAvailable(portList, raiseException=False) != 0:
    if forceTakePortOwnership == True:
        portObj.releasePorts(portList)
        portObj.clearPortOwnership(portList)
    else:
        raise IxNetRestApiException('\nPorts are owned by another user and forceTakePortOwnership is set to False. Exiting test.')

portObj.releasePorts(portList)
mainObj.configLicenseServerDetails([licenseServerIp], licenseModel)

fileMgmtObj = FileMgmt(mainObj)
fileMgmtObj.importJsonConfigFile(jsonConfigFile, option='newConfig')

# Set configPortName=False because loading a saved config file assumes ports already have configured names. Don't overwrite them.
portObj.assignPorts(portList, forceTakePortOwnership, configPortName=False)

Hubert Gee

From: sonicwallsun notifications@github.com Sent: Thursday, October 25, 2018 10:31 PM To: OpenIxia/IxNetwork IxNetwork@noreply.github.com Cc: GEE,HUBERT (K-USA,ex1) hubert.gee@keysight.com; State change state_change@noreply.github.com Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Now the function “fileMgmtObj.Import Json Config File” is OK,but something wrong with the function “fileMgmtObj.Json Assign Ports”, The IxNetwork config file and log for error are below ,can you check it for me ,thanks !

From: Hubert Gee notifications@github.com<mailto:notifications@github.com> Sent: 2018年10月26日 1:10 To: OpenIxia/IxNetwork IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com> Cc: Lin Sun LSun@SonicWall.com<mailto:LSun@SonicWall.com>; Author author@noreply.github.com<mailto:author@noreply.github.com> Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Now that you mentioned you’re using Python v2, the problem is that Python v2 uses a different module called StringIO. I added code to support both Python versions. I tested both versions and it’s working. Please get the updated file IxNetRestApiFileMgmt.py and retry.

for python3

if platform.python_version().startswith('3'): import io configContents = io.StringIO(configContents)

for python2

if platform.python_version().startswith('2'): import StringIO configContents = StringIO.StringIO(configContents)

Thanks, Hubert Gee

From: sonicwallsun notifications@github.com<mailto:notifications@github.com<mailto:notifications@github.com%3cmailto:notifications@github.com>> Sent: Wednesday, October 24, 2018 7:59 PM To: OpenIxia/IxNetwork IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com%3cmailto:IxNetwork@noreply.github.com>> Cc: GEE,HUBERT (K-USA,ex1) hubert.gee@keysight.com<mailto:hubert.gee@keysight.com<mailto:hubert.gee@keysight.com%3cmailto:hubert.gee@keysight.com>>; State change state_change@noreply.github.com<mailto:state_change@noreply.github.com<mailto:state_change@noreply.github.com%3cmailto:state_change@noreply.github.com>> Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

row 389 and 390 in IxNetRestApiFileMgmt.py : import io configContents = io.StringIO(configContents) . now my python version is 2.7.14,and can not execute those two rows ,can it modified as : configContents = io.BytesIO(configContents) ? thanks

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-432897154&data=02%7C01%7C%7C0dcfa33c9c2044c520f108d63a25c9ac%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636760331304447168&sdata=q51mh%2Fkp1gslDJFSkhe0N5lQfODUe1RewSMl8EP3bfw%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYX2AYcF7KpzRBEviijZLAdNB68cxGks5uoSjogaJpZM4Xvk-w&data=02%7C01%7C%7C0dcfa33c9c2044c520f108d63a25c9ac%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636760331304447168&sdata=NFf4Afs4uweHbYozcrzaaIN1guzFvvvva75IKl%2FqnNk%3D&reserved=0.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/OpenIxia/IxNetwork/issues/18#issuecomment-433132066, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AqNKdYNPfMC5Ztj0XTRi4_78w9OU-kaNks5uofCEgaJpZM4Xvk-w.

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-433291167&data=02%7C01%7C%7C653bb7bb2f1745b21c4808d63b043071%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636761286519894660&sdata=kK8H4JN8n%2FJbHmisurkowJvb4Omm7jCs7kHms1lk5xI%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYXyqtAgwhOelFNN1JeQhyTzhf6rmyks5uop4JgaJpZM4Xvk-w&data=02%7C01%7C%7C653bb7bb2f1745b21c4808d63b043071%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636761286519894660&sdata=ricfhBxKcDLvwn4Z6gDLx%2FHmUPzIv9OFRP%2Br3T%2BuDlE%3D&reserved=0.

hubertgee commented 5 years ago

Just a FYI. I don’t recommend loading a json config file. If you want to load a saved config file, load the .ixncfg binary config file instead because it’s much faster to load. Especially if you have a large configuration, json takes a long time to load.

Using json is good for modifying an existing configuration using XPATH and great for configuration something in large quantity. Not fast at loading a complete new configuration.

Hubert Gee

From: GEE,HUBERT (K-USA,ex1) Sent: Friday, October 26, 2018 9:26 AM To: 'OpenIxia/IxNetwork' reply@reply.github.com Subject: RE: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Hi,

Don’t use jsonAssignPorts. I’m going to remove it today. Follow the sample scripts in Github.

portObj = PortMgmt(mainObj)

portObj.connectIxChassis(ixChassisIp)

if portObj.arePortsAvailable(portList, raiseException=False) != 0:
    if forceTakePortOwnership == True:
        portObj.releasePorts(portList)
        portObj.clearPortOwnership(portList)
    else:
        raise IxNetRestApiException('\nPorts are owned by another user and forceTakePortOwnership is set to False. Exiting test.')

portObj.releasePorts(portList)
mainObj.configLicenseServerDetails([licenseServerIp], licenseModel)

fileMgmtObj = FileMgmt(mainObj)
fileMgmtObj.importJsonConfigFile(jsonConfigFile, option='newConfig')

# Set configPortName=False because loading a saved config file assumes ports already have configured names. Don't overwrite them.
portObj.assignPorts(portList, forceTakePortOwnership, configPortName=False)

Hubert Gee

From: sonicwallsun notifications@github.com<mailto:notifications@github.com> Sent: Thursday, October 25, 2018 10:31 PM To: OpenIxia/IxNetwork IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com> Cc: GEE,HUBERT (K-USA,ex1) hubert.gee@keysight.com<mailto:hubert.gee@keysight.com>; State change state_change@noreply.github.com<mailto:state_change@noreply.github.com> Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Now the function “fileMgmtObj.Import Json Config File” is OK,but something wrong with the function “fileMgmtObj.Json Assign Ports”, The IxNetwork config file and log for error are below ,can you check it for me ,thanks !

From: Hubert Gee notifications@github.com<mailto:notifications@github.com> Sent: 2018年10月26日 1:10 To: OpenIxia/IxNetwork IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com> Cc: Lin Sun LSun@SonicWall.com<mailto:LSun@SonicWall.com>; Author author@noreply.github.com<mailto:author@noreply.github.com> Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

Now that you mentioned you’re using Python v2, the problem is that Python v2 uses a different module called StringIO. I added code to support both Python versions. I tested both versions and it’s working. Please get the updated file IxNetRestApiFileMgmt.py and retry.

for python3

if platform.python_version().startswith('3'): import io configContents = io.StringIO(configContents)

for python2

if platform.python_version().startswith('2'): import StringIO configContents = StringIO.StringIO(configContents)

Thanks, Hubert Gee

From: sonicwallsun notifications@github.com<mailto:notifications@github.com<mailto:notifications@github.com%3cmailto:notifications@github.com>> Sent: Wednesday, October 24, 2018 7:59 PM To: OpenIxia/IxNetwork IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com<mailto:IxNetwork@noreply.github.com%3cmailto:IxNetwork@noreply.github.com>> Cc: GEE,HUBERT (K-USA,ex1) hubert.gee@keysight.com<mailto:hubert.gee@keysight.com<mailto:hubert.gee@keysight.com%3cmailto:hubert.gee@keysight.com>>; State change state_change@noreply.github.com<mailto:state_change@noreply.github.com<mailto:state_change@noreply.github.com%3cmailto:state_change@noreply.github.com>> Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

row 389 and 390 in IxNetRestApiFileMgmt.py : import io configContents = io.StringIO(configContents) . now my python version is 2.7.14,and can not execute those two rows ,can it modified as : configContents = io.BytesIO(configContents) ? thanks

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-432897154&data=02%7C01%7C%7C0dcfa33c9c2044c520f108d63a25c9ac%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636760331304447168&sdata=q51mh%2Fkp1gslDJFSkhe0N5lQfODUe1RewSMl8EP3bfw%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYX2AYcF7KpzRBEviijZLAdNB68cxGks5uoSjogaJpZM4Xvk-w&data=02%7C01%7C%7C0dcfa33c9c2044c520f108d63a25c9ac%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636760331304447168&sdata=NFf4Afs4uweHbYozcrzaaIN1guzFvvvva75IKl%2FqnNk%3D&reserved=0.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/OpenIxia/IxNetwork/issues/18#issuecomment-433132066, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AqNKdYNPfMC5Ztj0XTRi4_78w9OU-kaNks5uofCEgaJpZM4Xvk-w.

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-433291167&data=02%7C01%7C%7C653bb7bb2f1745b21c4808d63b043071%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636761286519894660&sdata=kK8H4JN8n%2FJbHmisurkowJvb4Omm7jCs7kHms1lk5xI%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYXyqtAgwhOelFNN1JeQhyTzhf6rmyks5uop4JgaJpZM4Xvk-w&data=02%7C01%7C%7C653bb7bb2f1745b21c4808d63b043071%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636761286519894660&sdata=ricfhBxKcDLvwn4Z6gDLx%2FHmUPzIv9OFRP%2Br3T%2BuDlE%3D&reserved=0.

hubertgee commented 5 years ago

Hi,

Both getStatsPage (8.40) and getStatsData (8.50) work. I verified them and no other customers are reporting issues. By default, getStatsPage get “Flow Statistics” stats. Do you have this enabled and is this the stat that you’re getting?

Your scripts should not be calling getStatsPage or getStatsData. Scripts should be calling getStats. Let the getStats API automatically point to either getStatsPage or getStatsData. It does this by looking at the IxNetwork version that you’re using.

Hubert Gee

From: sonicwallsun notifications@github.com Sent: Monday, October 29, 2018 1:52 AM To: OpenIxia/IxNetwork IxNetwork@noreply.github.com Cc: GEE,HUBERT (K-USA,ex1) hubert.gee@keysight.com; State change state_change@noreply.github.com Subject: Re: [OpenIxia/IxNetwork] the script "loadJsonConfigFile.robot" can not work (#18)

hi .Hubert Gee thanks for you kindly and professional help. There was still a prolblem : by using the function "def getStatsPage" ,can not get Statistics. and the IxNetwork version when testing is 8.40,can the function "def getStatsPage" work normal in 8.40 version?

Description :Starting 8.50, the new API to use is: /statistics/statView//data, which is in getStatsData()####

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FOpenIxia%2FIxNetwork%2Fissues%2F18%23issuecomment-433831731&data=02%7C01%7C%7Cc4c53b1656e8460226bf08d63d7bdb81%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636763999518762624&sdata=50w5ogRLTlNCKgEO7x2P7EHf1bGfH69kSDxX2bwlbG4%3D&reserved=0, or mute the threadhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAhtYX1Ck1rvAlSJkviYjeIjXsaEOJ9Rbks5upsHMgaJpZM4Xvk-w&data=02%7C01%7C%7Cc4c53b1656e8460226bf08d63d7bdb81%7C63545f2732324d74a44dcdd457063402%7C1%7C0%7C636763999518762624&sdata=YarPT36JkuMvDWsgOF87rxCLVcOFgYfDw6vnsTJ3XNc%3D&reserved=0.