Getting the actual (not default) value of a node socket that is linked to another socket
Basically this cannot be done easily. The reason is:


The shader node tree is compiled by cycles in SVM or OCL. And here the actual calculation takes place.
Also every sample in Cycles can potentially have a different Roughness (for example when connected to a TextureImage along the way). So which sample do you want the result from.


If you have a special case you can mimic the needed nodes in python and evaluate for your needs.