# Citrix monitor with Powershell SDK

**URL:** <https://community.dynatrace.com/t/citrix-monitor-with-powershell-sdk/43144>\
**Category:** Extensions\
**Tags:** citrix, extensions\
**Created:** [December 12, 2023, 5:57am UTC](https://community.dynatrace.com/t/citrix-monitor-with-powershell-sdk/43144 "2023-12-12T05:57:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Candy](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/candy/32/20581_2.png) [@Candy](https://community.dynatrace.com/u/Candy)\
**Post date:** [December 12, 2023, 5:57am UTC](https://community.dynatrace.com/t/citrix-monitor-with-powershell-sdk/43144/1 "2023-12-12T05:57:54Z")

</div>

When I extended monitoring using the Powershell SDK monitoring mode, the following error was reported:  
Python datasource initialization error: Exception(“Could not run a test powershell script: ‘NoneType’ object has no attribute ‘stderr’”),  
How do I fix it? thank you.

---

<div class="post-metadata">

**Author:** ![RazTN7](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/raztn7/32/10208_2.png) [@RazTN7](https://community.dynatrace.com/u/RazTN7)\
**Post date:** [December 12, 2023, 7:54am UTC](https://community.dynatrace.com/t/citrix-monitor-with-powershell-sdk/43144/2 "2023-12-12T07:54:02Z")

</div>

[@Candy](https://community.dynatrace.com/user/62847)

Ref from external site

If code is written like this

```auto
def get_shape_of_object(obj):
  return obj.shape

value = None
print(get_shape_of_object(value))

```

should fix into below example

```auto
def get_shape_of_object(obj):
  if obj is None:
    return None
  return obj.shape

value = None
print(get_shape_of_object(value))

```

[How to Fix AttributeError: ‘NoneType’ object has no attribute ‘shape’ (appdividend.com)](https://appdividend.com/2022/12/20/attributeerror-nonetype-object-has-no-attribute-shape/)

[How to Fix the ‘NoneType’ object has no attribute: ‘text’ Error in Python - Nsikak Imoh](https://nsikakimoh.com/blog/fix-nonetype-object-has-no-attribute-text)

Cheers!

RN
