Thank you for the suggestion, but I'd rather change the cell content as 
little as possible. I'm trying to present a simple interface to my freshmen 
students, so I think it'll be easier to tell them to ignore the warnings 
than to explain the extra code.  (I was hoping the load command might have 
an "ignore warnings" option.)

On Wednesday, September 7, 2022 at 7:10:02 PM UTC-4 Nils Bruin wrote:

> On Tuesday, 24 May 2022 at 11:10:13 UTC-7 ingo...@gmail.com wrote:
>
>> When I call
>> *load('https://raw.githubusercontent.com/ingodahn/sageutils/master/physics.py
>>  
>> <https://raw.githubusercontent.com/ingodahn/sageutils/master/physics.py>')*
>> in a sagecell I get in the output
>> */home/sc_serv/sage/local/var/lib/sage/venv-python3.10.3/lib/python3.10/site-packages/sage/misc/remote_file.py:46:
>>  
>> DeprecationWarning: ssl.SSLContext() without protocol argument is 
>> deprecated. content = urlopen(req, timeout=1, context=SSLContext())*
>>
>> How can I avoid this message?
>>
>>
> If you're OK with changing the cell content, you can use python's standard 
> warning control infrastructure to suppress the message. For instance, the 
> following silences any warnings that would arise from the "load" invocation:
>  
> import warnings
> with warnings.catch_warnings():
>     warnings.simplefilter("ignore")
>     load('
> https://raw.githubusercontent.com/ingodahn/sageutils/master/physics.py') 
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-devel/a395355d-97d6-4f55-9711-7a641da0a929n%40googlegroups.com.

Reply via email to