https://learninghub.kx.com/forums/topic/pykx-not-allowing-to-change-python-attribute-of-q-object
I am trying to do the following:
```
import pykx
old=":host:Port:user:old"
pykx.q.my_handle=old
new=":host:Port:user:new"
pykx.q.my_handle=new
```
The above works as expected. If I then try to access vía Python or directly from Q memory I would get the string in the new var.
```
print(pykx.q.my_handle)
print(pykx.q('string .my_handle'))
```
**However**, if I access the attribute (for any reason) before setting It to new value then something *weird* happens:
```
import pykx
old=":host:Port:user:old"
pykx.q.my_handle=old
print(f"my handled: {pykx.q.my_handle}")
new=":host:Port:user:new"
pykx.q.my_handle=new
#prints old
print(pykx.q.my_handle)
#prints new
print(pykx.q("string .my_handle"))
```
Anyone knows why? **Note** my handled has to be refreshed with new password/token whenever needed, in theory I vannot think about a use cas