<?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: Plugin Development for OneAgent: Sample py script does not work? in Extensions</title>
    <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34319#M50</link>
    <description>&lt;P&gt;Historical versions are not available to download from the UI.&lt;BR /&gt;However I'm uploading here the old version (113) that was laying around on my HDD from the time I made first steps with the SDK.&lt;BR /&gt;&lt;BR /&gt;Let's hope it won't violate some policy for uploading that here. &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; &lt;/P&gt;</description>
    <pubDate>Thu, 07 Sep 2017 07:29:49 GMT</pubDate>
    <dc:creator>Julius_Loman</dc:creator>
    <dc:date>2017-09-07T07:29:49Z</dc:date>
    <item>
      <title>Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34311#M42</link>
      <description>&lt;P&gt;Hi there. &lt;BR /&gt;&lt;BR /&gt;I try to understand and learn the plugin development of OneAgent plugins. I follow the documentation&lt;/P&gt;
&lt;P&gt;* &lt;A href="https://help.dynatrace.com/monitoring-plugins/custom-plugins/how-do-i-create-a-python-custom-plugin/" target="_blank"&gt;https://help.dynatrace.com/monitoring-plugins/cust...&lt;/A&gt; and&lt;BR /&gt;* &lt;A href="https://dynatrace.github.io/plugin-sdk/readme.html" target="_blank"&gt;https://dynatrace.github.io/plugin-sdk/readme.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;but I see after&lt;/P&gt;
&lt;P&gt;* installing a proper python on my debian workstation&lt;/P&gt;
&lt;P&gt;* installing the OneAgent and installing the whl file with pip3&lt;/P&gt;
&lt;P&gt;nothing working and I wonder why. &lt;BR /&gt;&lt;BR /&gt;First, the second documentation says that I will find a python script or module called&lt;/P&gt;
&lt;P&gt;* oneagent_sdk.demo_app&lt;/P&gt;
&lt;P&gt;but I do not see anything in the SDK (downloaded from the Dynatrace Server) or in the OneAgent installation directory (/opt/dynatrace). &lt;BR /&gt;Second, I find in the SDK directory (unzipped from the SDK archive I downloaded) the demo_plugin.py, which does nothing calling by python3.5. &lt;BR /&gt;&lt;BR /&gt;I am confused and got stuck, so my question is, what I miss to do here? May anyone help me to get my next step, running the demo plugin? &lt;BR /&gt;&lt;BR /&gt;Thanks in advance.&lt;BR /&gt;Jan&lt;/P&gt;</description>
      <pubDate>Mon, 28 Jun 2021 13:04:59 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34311#M42</guid>
      <dc:creator>jan_palic</dc:creator>
      <dc:date>2021-06-28T13:04:59Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34312#M43</link>
      <description>&lt;P&gt;I was playing with the Oneagent SDK a while ago also on Debian. It was quite a pain since Debian is still using Python 2.7 by default and some python 3 dependencies were missing.&lt;BR /&gt;&lt;BR /&gt;As far as I remember plugins are not intended to be executed directly as python files, but using oneagent_simulate_plugin command that gets installed with the SDK itself. Go to the demo_plugin directory of the SDK and run the simulate plugin command oneagent_simulate_plugin . &lt;BR /&gt;&lt;BR /&gt;Then running the python -m oneagent_sdk.demo_app from the documentation, I believe the python command resolves to Python 2.7 (debian default) and that is probably your cause.&lt;/P&gt;</description>
      <pubDate>Tue, 05 Sep 2017 11:27:37 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34312#M43</guid>
      <dc:creator>Julius_Loman</dc:creator>
      <dc:date>2017-09-05T11:27:37Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34313#M44</link>
      <description>&lt;P&gt;Hi Julius, &lt;/P&gt;&lt;P&gt;thank you for your answer and the hint. &lt;BR /&gt;&lt;BR /&gt;I was looking for a file oneagent_sdk.demo_app and did not found it (what is clear, now!).&lt;BR /&gt;My python is already set to 3.5 with update alternatives, so this was done before. &lt;BR /&gt;&lt;BR /&gt;Anyway, long story short, it works... thank you. &lt;BR /&gt;&lt;BR /&gt;.-) &lt;BR /&gt;&lt;BR /&gt;Jan&lt;/P&gt;</description>
      <pubDate>Tue, 05 Sep 2017 11:33:09 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34313#M44</guid>
      <dc:creator>jan_palic</dc:creator>
      <dc:date>2017-09-05T11:33:09Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34314#M45</link>
      <description>&lt;P&gt;&lt;BR /&gt;	Interesting - I can't get the simulator to work on Windows. Even with the supplied sample plugins I get an error:&lt;BR /&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;BR /&gt;	2017-09-06 13:25:37,314 [ERROR] - 3048(MainThread) - [_main] Plugin simulator was stopped with enexpected exception&lt;BR /&gt;Traceback (most recent call last):&lt;BR /&gt;  File "c:\users\torsten hellwig\appdata\local\programs\python\python35-32\lib\site-packages\oneagent_sdk\plugin_simulator.py", line 217, in _main&lt;BR /&gt;    external_api=external_api&lt;BR /&gt;TypeError: main() got an unexpected keyword argument 'external_api'&lt;BR /&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;BR /&gt;	Plugin simulator summary:&lt;BR /&gt;&lt;/P&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;BR /&gt;&lt;P&gt;&lt;BR /&gt;	Python Version is 3.5.3, 32bit.&lt;BR /&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;BR /&gt;	Any idea?&lt;BR /&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;BR /&gt;	cheers,&lt;BR /&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;BR /&gt;	Torsten&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Sep 2017 11:41:04 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34314#M45</guid>
      <dc:creator>TorstenHellwig</dc:creator>
      <dc:date>2017-09-06T11:41:04Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34315#M46</link>
      <description>&lt;P&gt;I'm currently encountering the same bug on Linux. Which version  of oneagent-sdk do you have? I have plugin-sdk-1.125.174.20170821-131816&lt;/P&gt;</description>
      <pubDate>Wed, 06 Sep 2017 15:35:05 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34315#M46</guid>
      <dc:creator>Julius_Loman</dc:creator>
      <dc:date>2017-09-06T15:35:05Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34316#M47</link>
      <description>&lt;P&gt;It must be definitely a bug in the simulator in recent versions. I've tried also the 123 version and 113 (I'v found the archive on my laptop). In 113 the oneagent_simulator seems to be working and it's not failing at the external_api error.&lt;/P&gt;</description>
      <pubDate>Wed, 06 Sep 2017 15:44:26 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34316#M47</guid>
      <dc:creator>Julius_Loman</dc:creator>
      <dc:date>2017-09-06T15:44:26Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34317#M48</link>
      <description>&lt;P&gt;Yes, I got the same answer in the meantime from &lt;A rel="user" href="https://answers.dynatrace.com/users/4119/view.html" nodeid="4119"&gt;@Michael L.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Seems to be a known bug with my 123.229 version. Good to know that 113 works.&lt;/P&gt;&lt;P&gt;torsten &lt;/P&gt;</description>
      <pubDate>Wed, 06 Sep 2017 15:58:15 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34317#M48</guid>
      <dc:creator>TorstenHellwig</dc:creator>
      <dc:date>2017-09-06T15:58:15Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34318#M49</link>
      <description>&lt;P&gt;,&lt;/P&gt;&lt;P&gt;Hi Guys, &lt;/P&gt;&lt;P&gt;Just begin my baby step to the plugin exploration and encountered the same issue on my vagrant - CentOS Linux release 7.3.1611 (Core). Do anyone know where to download the previous version that works ?&lt;/P&gt;&lt;P&gt;[vagrant@localhost demo_plugin_multi]$ oneagent_sim&lt;BR /&gt;2017-09-07 07:03:23,633 [ERROR] - 140201704101696(MainThread) - [_main] Plugin simulator was stopped with enexpected exception&lt;BR /&gt;Traceback (most recent call last):&lt;BR /&gt;  File "/usr/lib/python3.5/site-packages/oneagent_sdk/plugin_simulator.py", line 217, in _main&lt;BR /&gt;    external_api=external_api&lt;BR /&gt;TypeError: main() got an unexpected keyword argument 'external_api' &lt;/P&gt;</description>
      <pubDate>Thu, 07 Sep 2017 07:19:59 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34318#M49</guid>
      <dc:creator>chuan_sern_wong</dc:creator>
      <dc:date>2017-09-07T07:19:59Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34319#M50</link>
      <description>&lt;P&gt;Historical versions are not available to download from the UI.&lt;BR /&gt;However I'm uploading here the old version (113) that was laying around on my HDD from the time I made first steps with the SDK.&lt;BR /&gt;&lt;BR /&gt;Let's hope it won't violate some policy for uploading that here. &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; &lt;/P&gt;</description>
      <pubDate>Thu, 07 Sep 2017 07:29:49 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34319#M50</guid>
      <dc:creator>Julius_Loman</dc:creator>
      <dc:date>2017-09-07T07:29:49Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34320#M51</link>
      <description>&lt;P&gt;Perfect! Works...&lt;/P&gt;</description>
      <pubDate>Thu, 07 Sep 2017 08:30:21 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34320#M51</guid>
      <dc:creator>TorstenHellwig</dc:creator>
      <dc:date>2017-09-07T08:30:21Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34321#M52</link>
      <description>&lt;P&gt;This bug is fixed in agent 127. &lt;A rel="user" href="https://answers.dynatrace.com/users/16467/view.html" nodeid="16467"&gt;@Julius L.&lt;/A&gt; thx for workaround&lt;/P&gt;</description>
      <pubDate>Thu, 07 Sep 2017 09:36:40 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34321#M52</guid>
      <dc:creator>Jakub_Mierzewsk</dc:creator>
      <dc:date>2017-09-07T09:36:40Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34322#M53</link>
      <description>&lt;P&gt;No, it won't &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Actually, it's one of the best "self-service" threads I've read in the Dynatrace forums &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Karolina&lt;/P&gt;</description>
      <pubDate>Thu, 07 Sep 2017 09:41:38 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34322#M53</guid>
      <dc:creator>Karolina_Linda</dc:creator>
      <dc:date>2017-09-07T09:41:38Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34323#M54</link>
      <description>&lt;P&gt;FYI - It seems the problem is resolved in latest SDK - version 127. At least it works for me now.&lt;/P&gt;</description>
      <pubDate>Mon, 11 Sep 2017 08:06:36 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34323#M54</guid>
      <dc:creator>Julius_Loman</dc:creator>
      <dc:date>2017-09-11T08:06:36Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34324#M55</link>
      <description>&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;I am also trying to test out the SDK but I am getting the following error whenever I try to test the simulator:&lt;/P&gt;&lt;P&gt;--------------------------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;C:\Users\NB204316\Documents\plugin-sdk-1.149.213.20180809-141631\examples\demo_oneagent_plugin&amp;gt;oneagent_simulate_plugin INFO:ruxit.plugin_loop:Installing plugins with conflict resolution INFO:ruxit.package_utils.plugin_updater:Unable to get revision from plugin_directory_path 'C:\\Users\\NB204316\\Documents\\plugin-sdk-1.149.213.20180809-141631\\examples\\demo_oneagent_plugin', assuming -1 INFO:ruxit.package_utils.plugin_updater:plugins_by_revision: defaultdict(&amp;lt;class 'dict'&amp;gt;, {'no_revision': {'custom.python.demo_plugin': PluginInfo(name='custom.python.demo_plugin', reported_name='custom.python.demo_plugin', version='1.2', directory='C:\\Users\\NB204316\\Documents\\plugin-sdk-1.149.213.20180809-141631\\examples\\demo_oneagent_plugin' package='demo_plugin')}}) INFO:ruxit.package_utils.plugin_updater:Installing plugins INFO:ruxit.package_utils.plugin_updater:Processing revision 'no_revision' INFO:ruxit.package_utils.plugin_updater:Processing candidate_entries: {'custom.python.demo_plugin': PluginInfo(name='custom.python.demo_plugin', reported_name='custom.python.demo_plugin', version='1.2', directory='C:\\Users\\NB204316\\Documents\\plugin-sdk-1.149.213.20180809-141631\\examples\\demo_oneagent_plugin' package='demo_plugin')} INFO:ruxit.package_utils.plugin_updater:Working set validated, new current_entries: OrderedDict([('custom.python.demo_plugin', PluginInfo(name='custom.python.demo_plugin', reported_name='custom.python.demo_plugin', version='1.2', directory='C:\\Users\\NB204316\\Documents\\plugin-sdk-1.149.213.20180809-141631\\examples\\demo_oneagent_plugin' package='demo_plugin'))]) INFO:ruxit.package_utils.plugin_updater:Plugin PluginInfo(name='custom.python.demo_plugin', reported_name='custom.python.demo_plugin', version='1.2', directory='C:\\Users\\NB204316\\Documents\\plugin-sdk-1.149.213.20180809-141631\\examples\\demo_oneagent_plugin' package='demo_plugin') from revision 'no_revision' compatible INFO:ruxit.package_utils.plugin_updater:Processing revision 'plugin_deployment' INFO:ruxit.package_utils.plugin_updater:Processing revision 'plugin_development' INFO:ruxit.plugin_loop:========= INCOMPATIBLE PLUGINS ========= INFO:ruxit.plugin_loop:[] INFO:ruxit.plugin_loop:======================================== INFO:ruxit.plugin_loop:**************************************** INFO:ruxit.plugin_loop:[PluginInfo(name='custom.python.demo_plugin', reported_name='custom.python.demo_plugin', version='1.2', directory='C:\\Users\\NB204316\\Documents\\plugin-sdk-1.149.213.20180809-141631\\examples\\demo_oneagent_plugin' package='demo_plugin')] &lt;STRONG&gt;INFO:ruxit.plugin_loop:**************************************** INFO:ruxit.plugin_loop:sys.path after installing plugins: ['C:\\Python35\\Scripts\\oneagent_simulate_plugin.exe', 'c:\\python35\\python35.zip', 'c:\\python35\\DLLs', 'c:\\python35\\lib', 'c:\\python35', 'c:\\python35\\lib\\site-packages', 'C:\\Users\\NB204316\\Documents\\plugin-sdk-1.149.213.20180809-141631\\examples\\demo_oneagent_plugin'] ERROR:oneagent_sdk.plugin_simulator:Plugin simulator was stopped with unexpected exception Traceback (most recent call last): File "c:\python35\lib\site-packages\oneagent_sdk\plugin_simulator.py", line 265, in _main platform_api=platform_api File "c:\python35\lib\site-packages\ruxit\plugin_loop.py", line 340, in main loop.main() File "c:\python35\lib\site-packages\ruxit\plugin_loop.py", line 91, in main next(support_alert_creator) TypeError: 'Mock' object is not an iterator&lt;/STRONG&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;--------------------------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;I am running Python 3.5 and my sdk is plugin-sdk-1.149.213.20180809-141631 on Windows 10 &lt;/P&gt;&lt;P&gt;I am trying to run "oneagent_simulate_plugin"&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Sun, 09 Sep 2018 21:28:54 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34324#M55</guid>
      <dc:creator>thobishim</dc:creator>
      <dc:date>2018-09-09T21:28:54Z</dc:date>
    </item>
    <item>
      <title>Re: Plugin Development for OneAgent: Sample py script does not work?</title>
      <link>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34325#M56</link>
      <description>&lt;P&gt;I'm not sure if I am missing anything, as this is a the error that has more meaning "&lt;STRONG&gt;TypeError: 'Mock' object is not an iterator&lt;/STRONG&gt;"&lt;/P&gt;&lt;P&gt;It looks like python is having issues with the Mock object&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Sun, 09 Sep 2018 21:44:45 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Plugin-Development-for-OneAgent-Sample-py-script-does-not-work/m-p/34325#M56</guid>
      <dc:creator>thobishim</dc:creator>
      <dc:date>2018-09-09T21:44:45Z</dc:date>
    </item>
  </channel>
</rss>

