MicroStrategy / mstrio-py

Python integration for MicroStrategy
Apache License 2.0
89 stars 57 forks source link

Attribute Object - issue with the 'hidden' property #149

Closed DStavilaNI closed 6 months ago

DStavilaNI commented 11 months ago

Hey Guys,

Recently, while working on the mstrio API, I stumbled upon an issue. Specifically, Setting (or otherwise working with) the 'hidden' property of an Attribute object leads to some strange behavior and I would like to ask if this is expected or not.

  1. Attribute.alter(hidden=attribute_data.get_is_hidden()) - the 'alter' method throws the exception "I-Server Error ERR006, No properties changed or propagateACLToChildren set for the specified object" if the attribute hidden property is already set to the same value. This can be a problem and requires additional error handling when we have to programmatically update attributes and we do not know the previous hidden value. I believe that the exception here is unnecessary - it should simply override the existing value, as it is done for other properties.
  2. Accessing locally the Attribute.hidden property, to check the current hidden value for a given attribute returns False even if it was previously set to True - It might be just a local issue and it requires additional testing on a difference machine to confirm it.

I am looking forward for your reply, Sincerely yours, Denis

urszulajaczewska commented 10 months ago

Hi @DStavilaNI, we'll look into this. I'll update this issue when we have more info or when fix is available.

urszulajaczewska commented 6 months ago

Hi @DStavilaNI, fix is now available with new mstrio-py release.