code: def path_wo_ns(obj):
      
      if isinstance(obj, pywbem.CIMInstance):
          path = obj.path.copy()
      elif isinstance(obj, pywbem.CIMInstanceName):
          path = obj.copy()
      else:
          assert False
  
      path.host = None
      path.namespace = None
      return path
docs: Return path of an instance or instance path without host or namespace.
      Creates copy of the object so the original is not changed.