Interesting. This does not work in Houdini 18.5:
from hashlib import pbkdf2_hmac data = "hello" salt = "secret" iterations = 10 print pbkdf2_hmac('sha1', data, salt, iterations) # ValueError: unsupported hash type
Even though it does have the algorithm:
>>> print hashlib.algorithms ('md5', 'sha1', 'sha224', 'sha256', 'sha384', 'sha512') >>> print hashlib.algorithms_guaranteed set(['sha1', 'sha224', 'sha384', 'sha256', 'sha512', 'md5'])
Interestingly enough hashlib should include the name of the hash type in that error message:
raise ValueError('unsupported hash type ' + name)
For sake of completeness - also reported to SideFX
Side Effects Support Ticket: # 98320
from maya import cmds value = cmds.getAttr("transform.scaleY") print value # 1.0 print value == 1.0 # False
So I know about floating point precision errors, etc. But if Python prints the value to be 1.0 but when comparing it shows as not being 1.0... how would I figure out that the original value actually deviated. And by how much? Could I force it to print with the precision to show it? I'm fine with it being in scientific notation.
print abs(value - 1.0) # 2.22044604925e-16
But I'd rather just see 1 + 2.22044604925e-16 as print-out. Or 1.0000000000000000222044604925
Warning Insufficient permissions to write to destination directory. no problem when export file like fbx or abc just USD having this issue.
Currently working on a small project, and just implemented a vertical extended TreeView that could scroll down to the very bottom so the last row can be scrolled to the top (Which behaves like modern text editor)
So I replace the Avalon's subset widget TreeView with it, and it looks nice :D
haha, yeah, I haven’t seen that before too.
I did that because I had a widget like, address book which has A-Z 26 tabs, clicking on tab can scroll to the first item that starts with the initial. And I’d like items that starts with e.g. U, V, ...Z which mostly sorted down the bottom can still be scrolled to top when user clicking on e.g U-Z tabs.
It's the license connection to the SideFX server. Basically if you serve floating licenses from a license server and the license server occasionally confirms with their online servers.
Actually, now thinking about it... what is up with that? Why the heck is that license server checking SideFX servers even though the licenses are already redeemed.
Maybe they can withdraw licenses under special circumstances? Or it's for like when you'd have them transfer licenses to a new host name, but secretly keep the old host too but forever offline. Double the license count.