this is a really simple question but I can't seem to find an example to do it. In a rust client I am just doing the following:
let (user_data_account, _user_bump_seed) = Pubkey::find_program_address(&[&user_id.to_le_bytes()], &program);
let (user_id_map, _user_id_map_bump_seed) = Pubkey::find_program_address(&[&user_account.to_bytes()], &program);
where user_account is a PubKey, and user_id is a u64.
In python, I am trying to use https://michaelhly.github.io/solana-py/ but PubKey doesn't have a to_bytes method, and i'm not really sure what to do to be able to get the same program address as I would get from the rust code (the same goes for the U64 really..)
Anyone done this before? Thanks