I have just updated a package using python-pip. Two different users get different versions of the binary:
andrew$ which aws /usr/bin/aws andrew$ /usr/bin/aws --version aws-cli/1.16.194 Python/3.5.2 Linux/4.4.0-1087-aws botocore/1.12.184 andrew$ sudo su tomcat tomcat$ which aws /usr/bin/aws tomcat$ /usr/bin/aws --version aws-cli/1.11.13 Python/3.5.2 Linux/4.4.0-1087-aws botocore/1.4.70
That's happening within an application running as the tomcat user, as well as from the commandline. I have upgraded from 1.11 to 1.16 today (using
pip3 install --upgrade pip awscli), but the tomcat users still gets the old version. I've restarted the apache-tomcat server, logged out and in (although I haven't restarted the server). Is it even possible for a program to be cached by linux for one user but not another?
Based on the comments, I believe that the two users have different environments which mean that when python imports awscli.clidriver it's a different version. But how to find that out / fix it globally? debian stretch/sid, x86_64