<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Using Python in WFA: The solution. in Active IQ Unified Manager Discussions</title>
    <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/141655#M25871</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;maybe the user base of Perl is shrinking. But at the end, Perl is the perfect language for WFA on the Linux side.&lt;/P&gt;
&lt;P&gt;It's available everywhere and compatible.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Python failed on the step from 2.6 to 3.0. They tried to introduce new things without backward compatibility.&lt;/P&gt;
&lt;P&gt;The community doesn't follow, so they moved features from 3 to 2.7.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RedHat 7.4 includes Python 2.7 it's now 8 years old. Current version is 3.7.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I wrote all my RestAPI scripts in Python, it works great. And it's simple.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But when it comes to simple scripts and string parsing, it's Perl.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Marcus&lt;/P&gt;</description>
    <pubDate>Mon, 23 Jul 2018 12:58:54 GMT</pubDate>
    <dc:creator>marcusgross</dc:creator>
    <dc:date>2018-07-23T12:58:54Z</dc:date>
    <item>
      <title>Using Python in WFA: The solution.</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/139691#M25493</link>
      <description>&lt;P&gt;Support for Python as a programming language for WFA commands/DataSources has been asked IIRC since 2013. Perl is largely outdated in programming world and its user base is shrinking.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Its a long wait, so let me not keep you waiting any longer. I have no clue when, if at all WFA is going to provide support for Python. I wish they do.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The following doc guides you to start using Python in WFA. This is the beauty of WFA. It allows room to be creative and build almost anything you want to.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;The solution logic:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To run python language code, I'm going to use the infrastructure that is given in WFA. The Perl's infrastructure.&amp;nbsp;So If I can get to know how Perl is being handled in WFA, I can make it to work with Python as well. And this is the core logic behind this solution.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;WFA version needed:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any version of WFA will do. Nothing specific.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;The Setup&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You need a time setup to be done.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;&lt;EM&gt;Windows:&lt;/EM&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Install &lt;FONT color="#0000FF"&gt;&lt;EM&gt;Python 2.7.X&lt;/EM&gt;&lt;/FONT&gt; on your WFA windows system. You can install Python 3.X as well, but I've not tested it. Likely will work. Python 2.7 is the most popular python version by a long stretch. So I would recommend it.&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;&amp;nbsp;The default Python installation path is: C:\Python27&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL start="2"&gt;
&lt;LI&gt;Install &lt;FONT color="#0000FF"&gt;&lt;EM&gt;Request&lt;/EM&gt;&lt;/FONT&gt;&amp;nbsp;Module. If you want latest version, take it from here. &lt;A href="http://docs.python-requests.org/en/master/user/install/#install" target="_blank"&gt;http://docs.python-requests.org/en/master/user/install/#install&lt;/A&gt;. There multiple ways to install. pipenv or Tar ball as described in the link document.&amp;nbsp; If you are having difficulty, or okay with the version I've tried, I've also added the requests.dar. Rename the file extension to .zip and then unzip the content folder 'requests' in yout &lt;FONT color="#0000FF"&gt;C:/P&lt;EM&gt;ython27/Lib/Site-Packages&lt;/EM&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Why this Module? Native python with urlib, urllib2, urllib3 etc do provide mechanism for making HTTP requests, but makes programming difficult. And I didn't want to do 90s style programming in 2017(Yes this solution was developed last year).&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;OL start="3"&gt;
&lt;LI&gt;Replace&amp;nbsp;your existing&amp;nbsp;&amp;nbsp;&lt;FONT color="#0000FF"&gt;&lt;EM&gt;\WFA\perl\WFAWrapperl.pl&lt;/EM&gt;&lt;/FONT&gt;&amp;nbsp;with the one attached here ( Modify the file extension from .txt&amp;nbsp; to .pl), . Find the line as below and if required modify it as per your python installation path. Save it.&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL start="3"&gt;
&lt;LI&gt;
&lt;PRE&gt;$python_path = "C://Python27//python.exe";&lt;/PRE&gt;
&lt;/LI&gt;
&lt;LI&gt;Download the attached&amp;nbsp;&lt;FONT color="#0000FF"&gt;&lt;EM&gt;WFAUtil.txt&lt;/EM&gt;&lt;/FONT&gt;&amp;nbsp;file and save it into your C:\Python27\Lib\Site-Packages. Modify the file extension to &lt;FONT color="#0000FF"&gt;&lt;EM&gt;.py&lt;/EM&gt;&lt;/FONT&gt;&amp;nbsp;. The tool doesn't allow me to attach .pl, .py files. This is the language pack library which will allow you to use python in WFA.&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That's all. Done.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;EM&gt;&lt;STRONG&gt;Linux/CentOS:&lt;/STRONG&gt;&lt;/EM&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;&lt;FONT color="#FF0000"&gt;&lt;FONT color="#000000"&gt;If your Linux has python, you&amp;nbsp;will not need to install it.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;FONT color="#FF0000"&gt;&lt;FONT color="#000000"&gt;Same as step-2 above.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;FONT color="#FF0000"&gt;&lt;FONT color="#000000"&gt;Take the WFAWrapper.pl attached here. Modify the above mentioned&amp;nbsp;line to point to your python binaries,&lt;/FONT&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;FONT color="#000000"&gt;That's all.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;&lt;FONT color="#000000"&gt;Test if your setup went fine.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Launch Python console and try the below lines. If they don't throw any error, we are good to go.&lt;/LI&gt;
&lt;/OL&gt;
&lt;PRE&gt;Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:42:59) [MSC v.1500 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
&amp;gt;&amp;gt;&amp;gt; import WFAUtil
&amp;gt;&amp;gt;&amp;gt; import requests
&amp;gt;&amp;gt;&amp;gt; &lt;/PRE&gt;
&lt;P&gt;Your WFA is ready to use python.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Creating Commands:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;WFA-&amp;gt;Designer-&amp;gt;Commands-&amp;gt; Add new.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Select language &lt;FONT color="#0000FF"&gt;&lt;EM&gt;"Perl'&lt;/EM&gt;&lt;/FONT&gt;. Yes this is what we have done. &lt;FONT color="#0000FF"&gt;Python in WFA is now posing as Perl&lt;/FONT&gt;. See I can't change the hard-coded names in GUI .&amp;nbsp; So just read 'Python' where ever there is Perl written. Just like in a Perl command, you would need to add 'Parameter Definitions' and Parameter Mappings manually. If you need to understand how to do this I can elaborate. Post your queries in comments.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've attached a sample Test Command. The test command gives example on how to use all the available WFA methods in python.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How to see what methods are available to use? On the python console just type&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:42:59) [MSC v.1500 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
&amp;gt;&amp;gt;&amp;gt; import WFAUtil
&amp;gt;&amp;gt;&amp;gt; import requests
&amp;gt;&amp;gt;&amp;gt; help(WFAUtil)
Help on module WFAUtil:

NAME
    WFAUtil

FILE
    c:\python27\lib\site-packages\wfautil.py

CLASSES
    WFAUtil
    
    class WFAUtil
     |  Methods defined here:
     |  
     |  __get_command_obj__(self, url)
     |  
     |  __get_xml_body__(self, root, hmap)
     |  
     |  __init__(self)
     |  
     |  __parse_xml_resp__(self, content)
     |  
     |  &lt;FONT color="#FF0000"&gt;add_wfa_workflow_parameter&lt;/FONT&gt;(self, name, value, add_return=False)
     |      :param name: Name of the dynamic Parameter
     |      :param value: Value of the dynamic Parameter
     |      :param add_return: True/False to have the parameter as a return parameter for the workflow
     |      :return: none
     |  
     |  &lt;FONT color="#FF0000"&gt;get_connection_details&lt;/FONT&gt;(self, host)
     |      :param host: Hostname or IP Address
     |      :return: Connection details Dictionary with keys userName, password, 'remoteSystemType',
     |  
     |  &lt;FONT color="#FF0000"&gt;get_credentials&lt;/FONT&gt;(self, host, is_datasource=False)
     |      :param host: hostname or IP Address
     |      :param is_datasource: True/False
     |      :return: credential dictionary with keys 'userName', 'password'
     |  
     |  &lt;FONT color="#FF0000"&gt;get_wfa_global_configuration&lt;/FONT&gt;(self, configkey)
     |      :param configkey: The global_config key whose value is required
     |      :return: The value of the config key (string)
     |  
     |  &lt;FONT color="#FF0000"&gt;get_wfa_input_password&lt;/FONT&gt;(self, encrypted_password)
     |      :param encrypted_password: Parameter of type Password in encrypted format.
     |      :return: password in plain text
     |  
     |  &lt;FONT color="#FF0000"&gt;get_wfa_rest_parameter&lt;/FONT&gt;(self, param)
     |      :param param: Parameter whose value needs to be obtained. Valid values are userName, jobId, workflowName, commandName, workflowId, Host, Port
     |      :return: The value of the Parameter (string)
     |  
     |  &lt;FONT color="#FF0000"&gt;get_wfa_vendor&lt;/FONT&gt;(self)
     |      :return: The WFA Vendor (string)
     |  
     |  &lt;FONT color="#FF0000"&gt;get_wfa_version&lt;/FONT&gt;(self, full=False)
     |      :param full: True/False to obtain the WFA version in full format
     |      :return: WFA version (sting)
     |  
     |  &lt;FONT color="#FF0000"&gt;get_wfa_workflow_parameter&lt;/FONT&gt;(self, name)
     |      :param name: The Parameter whose value needs to be obtained.
     |      :return: The string value of the parameter
     |  
     |  &lt;FONT color="#FF0000"&gt;report_progress&lt;/FONT&gt;(self, current, total, percentage, note='')
     |      :param current: Current completed out of the total
     |      :param total: Total number to be achieved
     |      :param percentage: current/total * 100
     |      :param note: Some note to pass
     |      :return: none
     |  
     |  &lt;FONT color="#FF0000"&gt;send_log&lt;/FONT&gt;(self, message, level='DEBUG')
     |      :param message: message to log and print command execution
     |      :param level: log level DEBUG/INFO/WARN/ERROR
     |      :return: none

DATA
    EMPTY_NAMESPACE = None
    EMPTY_PREFIX = None
    StringTypes = (&amp;lt;type 'str'&amp;gt;, &amp;lt;type 'unicode'&amp;gt;)
    XMLNS_NAMESPACE = 'http://www.w3.org/2000/xmlns/'


&amp;gt;&amp;gt;&amp;gt; &lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;FONT color="#000000"&gt;I've attached a sample code here. I'll also explain some code.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;import argparse
from WFAUtil import WFAUtil
import sys
import traceback
&lt;/PRE&gt;
&lt;P&gt;I would need the above libraries. argparse is needed for parsing the arguments, WFAUtil is my WFA python module.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;wfa=WFAUtil()&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Creating the WFAUtil object.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Now call a method to do any task. Let's print some output log messages of info, warn and error. Just the way its done for any python code.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;wfa.send_log("=== Testing Method send_log for all log levels ===", 'INFO')

wfa.send_log(message="=== INFO Message ===", level='INFO')
wfa.send_log( level='WARN', message="=== Warning Message ===")
wfa.send_log(message="=== Error Message ===", level='ERROR')
wfa.send_log(message="=== Debug Message ===")
&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Creating Data Source Type Script in Python.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Same for Data Source type.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Add a new Data Source Type, method = script, language= &lt;FONT color="#0000FF"&gt;&lt;EM&gt;perl&lt;/EM&gt;&lt;/FONT&gt;.&lt;/P&gt;
&lt;P&gt;Now provide your python code&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've attached a sample Data Source script at well.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;I've only provided methods which are WFA specific, which are needed to work with WFA. Methods like connecting to Cluster (Connect-WfaCluster equivalent) etc. are NOT provided. They are wrapper methods and can all be done by the users themselves.&lt;/LI&gt;
&lt;LI&gt;Now that your Perl=Python, you will No longer be able to use Perl. If you want perl back, just get&amp;nbsp; back the old WFAWrapper.pl which came with WFA. That's all.&lt;/LI&gt;
&lt;LI&gt;A lot of NetApp certified contents from WFA Automation store are only in Perl. So now, none of them will work. As mentioned above, you either get Perl or Python.&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; 4. This solution logic can be used for other languages like Ruby, Shell etc. as well. I can do it, if there are enough ask for those.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jun 2025 13:48:17 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/139691#M25493</guid>
      <dc:creator>sinhaa</dc:creator>
      <dc:date>2025-06-04T13:48:17Z</dc:date>
    </item>
    <item>
      <title>Re: Using Python in WFA: The solution.</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/139692#M25494</link>
      <description>&lt;P&gt;Adding the example codes here.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Apr 2018 19:04:24 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/139692#M25494</guid>
      <dc:creator>sinhaa</dc:creator>
      <dc:date>2018-04-18T19:04:24Z</dc:date>
    </item>
    <item>
      <title>Re: Using Python in WFA: The solution.</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/140204#M25608</link>
      <description>&lt;P&gt;Although I'm not a Python guy I'm always interested in using tools to their full potential -- even if it means bending the rules a bit &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For this particular hack I'm wondering though if it's not easier to go the other way round. By this I mean to use a Perl module to allow you to run python code from within the perl code, for example&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://search.cpan.org/dist/Inline-Python/Python.pod" target="_blank"&gt;http://search.cpan.org/dist/Inline-Python/Python.pod&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Afaik the WFA perl distribution can be managed using PPM so it should be possible to install this package "site-local". This way, the NetApp certified commands keep running and a future WFA upgrade might actually work because it (hopefully) preserves any "site-local" perl packages as opposed to the wrappers you're replacing which will probably get overwritten.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Of course, you need to wrap your python code in a minimal perl scaffolding for each command, but this seems to be the lesser of the two evils if you prefer python over perl (or even powershell)...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Totally untested, just felt like adding my 2 cent.&lt;/P&gt;</description>
      <pubDate>Mon, 14 May 2018 11:43:46 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/140204#M25608</guid>
      <dc:creator>MartinRohrbach</dc:creator>
      <dc:date>2018-05-14T11:43:46Z</dc:date>
    </item>
    <item>
      <title>Re: Using Python in WFA: The solution.</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/140246#M25615</link>
      <description>&lt;P&gt;&lt;a href="https://community.netapp.com/t5/user/viewprofilepage/user-id/60838"&gt;@MartinRohrbach&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Good to see this being discussed. I'll respond on the points brought out.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;sinhaa&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 16 May 2018 06:26:25 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/140246#M25615</guid>
      <dc:creator>sinhaa</dc:creator>
      <dc:date>2018-05-16T06:26:25Z</dc:date>
    </item>
    <item>
      <title>Re: Using Python in WFA: The solution.</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/141655#M25871</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;maybe the user base of Perl is shrinking. But at the end, Perl is the perfect language for WFA on the Linux side.&lt;/P&gt;
&lt;P&gt;It's available everywhere and compatible.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Python failed on the step from 2.6 to 3.0. They tried to introduce new things without backward compatibility.&lt;/P&gt;
&lt;P&gt;The community doesn't follow, so they moved features from 3 to 2.7.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RedHat 7.4 includes Python 2.7 it's now 8 years old. Current version is 3.7.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I wrote all my RestAPI scripts in Python, it works great. And it's simple.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But when it comes to simple scripts and string parsing, it's Perl.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Marcus&lt;/P&gt;</description>
      <pubDate>Mon, 23 Jul 2018 12:58:54 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/141655#M25871</guid>
      <dc:creator>marcusgross</dc:creator>
      <dc:date>2018-07-23T12:58:54Z</dc:date>
    </item>
    <item>
      <title>Re: Using Python in WFA: The solution.</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/141706#M25885</link>
      <description>&lt;P&gt;&lt;a href="https://community.netapp.com/t5/user/viewprofilepage/user-id/11404"&gt;@marcusgross&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Marcus,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000FF"&gt;&lt;SPAN&gt;Perl is the perfect language for WFA on the Linux side&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;-------&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;I didn't get why you say the above. Every method that is abaible on WFA Perl Module, i've provided in the python module.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000FF"&gt;Python failed on the step from 2.6 to 3.0. They tried to introduce new things without backward compatibility.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000FF"&gt;The community doesn't follow, so they moved features from 3 to 2.7.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000FF"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000FF"&gt;RedHat 7.4 includes Python 2.7 it's now 8 years old. Current version is 3.7.&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;-------&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RHEL 7.4 includes Python 2.7. But you can always install 3.7 or which ever latest you wish. The provided solution should work with Python 3.X as well. Are you facing any problems?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000FF"&gt;&lt;SPAN&gt;I wrote all my RestAPI scripts in Python, it works great. And it's simple.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;-------------&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Are you not using WFA? Those scripts can be in WFA&amp;nbsp; commands. This gives many advantages over a script. If there is a problem you are facing using python in WFA, let me help you.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;But when it comes to simple scripts and string parsing, it's Perl.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;-------------&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Simplicity of python including parsing etc. is the reason for its popularity. Subjective preferance is a totally different thing.&amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;sinhaa&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Jul 2018 08:58:19 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/141706#M25885</guid>
      <dc:creator>sinhaa</dc:creator>
      <dc:date>2018-07-25T08:58:19Z</dc:date>
    </item>
    <item>
      <title>Re: Using Python in WFA: The solution.</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/141707#M25886</link>
      <description>&lt;P&gt;&lt;a href="https://community.netapp.com/t5/user/viewprofilepage/user-id/60838"&gt;@MartinRohrbach&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The purpose of inline-python is is have your classes and the containing methods defined in Python. And their class objects and the methods on those being called from below Perl code. Your major programming has to be in Perl. Which not the intent.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;WFA generally commands do not use classes etc, Its makes not much sesnse here.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also if your python is only going to have a simple Printing Hello World. this may work. Accepting parameters from commands and then using those in Python will NOT work.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In short, this is not going to work in WFA.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;sinhaa&lt;/P&gt;</description>
      <pubDate>Wed, 25 Jul 2018 09:07:38 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Using-Python-in-WFA-The-solution/m-p/141707#M25886</guid>
      <dc:creator>sinhaa</dc:creator>
      <dc:date>2018-07-25T09:07:38Z</dc:date>
    </item>
  </channel>
</rss>

