What is / How to use AgentEnvironment?

I created a new identity and gave it the name of a principal i use + set a password.
When I use any critical dfx command in the root folder of the project like

dfx deploy

I get a prompt to

Please enter the passphrase for your identity: [hidden]

And carefully enter my pw but it still fails with the following err

Error: Failed to create AgentEnvironment.
Caused by: Failed to create AgentEnvironment.
** Failed to create AgentEnvironment for network ‘local’.**
** Failed to decrypt PEM file: /home/me/.config/dfx/identity/myidentity/identity.pem.encrypted**

Is there a solution or am i missing something ?
Feel free to ask me to elaborate, thx

This error comes from these lines:

        .decrypt(nonce, encrypted_content.as_ref())

The most likely source is a wrong password, but not 100% sure. Do you maybe have capslock on? We don’t get any more useful information from the decryption library :frowning_face: