Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Qt Session management error with matplotlib.pyplot.plot

All of a sudden, whenever I call matplotlib.pyplot.plot (within a unix OS), the following error is printed to the screen:

Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed

This error does not interrupt the function; the plot is created successfully. But what does this error mean?

A user on linuxforums.org was able to find a way to prevent the error:

"I don't know exactly why, but giving permissions to the user in the sudoers file, and then running the program with the sudo command, fixes the error."

This, however, leaves unresolved the cause of the error and whether it influences at all the ongoing process.

Is there a solution that doesn't require editing the sudoers file?

NB: I'm doing this work on a shared computing cluster.

like image 873
dbliss Avatar asked May 02 '15 04:05

dbliss


2 Answers

The answer to the question is, yes, there is a solution that doesn't require editing the sudoers file. I noticed that in the .cache directory of my home directory, there was a matplotlib directory and a sessions directory.

I deleted these.

The problem was resolved.

I remain unsure why the error arose in the first place.

like image 100
dbliss Avatar answered Nov 01 '22 05:11

dbliss


Make sure you use "su -" and not just "su"

like image 2
Lex Avatar answered Nov 01 '22 07:11

Lex