How can I get a list of modules that have been imported into my process?
sys.modules.values()... if you really need names for the modules, use sys.modules.keys ()
sys.modules.values()
dir() not what you want.
dir()
>>> import re >>> def foo(): ... import csv ... fubar = 0 ... print dir() ... >>> foo() ['csv', 'fubar'] # 're' is not in the current scope >>>
You can also start the interpreter with a parameter -vif you just want to see the imported modules (and the order of their import)
-v
Source: https://habr.com/ru/post/1748777/More articles:Unable to pass an object of type "System.Object []" to enter "System.String []" - c #IP Blocking with php / mysql - phpAndroid java.lang.VerifyError for a private method with annotated argument - javaLua: Random: Percentage - luaSQLAlchemy Expression Language Problem - postgresqlDetermine if javascript is complete - javascriptParse text from the capture screen - javaThe maximum number of C ++ compiler classes is c ++Отсутствует ошибка Java при условном выражении? - javaПодключение к службе SFTP через Java Runtime - javaAll Articles