About 52 results
Open links in new tab
  1. For what uses do we need `sys` module in python?

    Jun 19, 2020 · I have come across made codes in jupyter notebooks where sys is imported. I can't see the further use of the sys module in the code. Can someone help me to understand what is the …

  2. Como funciona o módulo sys do python e para que ele serve?

    Jan 23, 2020 · 6 O módulo sys fornece funções e variáveis usadas para manipular diferentes partes do ambiente de tempo de execução do Python e apesar de serem completamente diferentes, muitas …

  3. Difference between exit () and sys.exit () in Python

    Oct 7, 2016 · In Python, there are two similarly-named functions, exit() and sys.exit(). What's the difference and when should I use one over the other?

  4. python - What does "sys.argv [1]" mean? (What is sys.argv, and where ...

    sys.argv is a attribute of the sys module. It says the arguments passed into the file in the command line. sys.argv[0] catches the directory where the file is located. sys.argv[1] returns the first argument …

  5. What does it mean that the sys module is built into every python ...

    Jul 11, 2018 · The sys module is written in C and compiled into the Python interpreter itself. Depending on the version of the interpreter, there may be more modules of this kind — …

  6. python - Possible values from sys.platform? - Stack Overflow

    Jan 15, 2009 · What are the possible return values from the following command? import sys print sys.platform I know there is a lot of possibilities, so I'm mainly interested in the "main" ones …

  7. Add a directory to Python sys.path so that it's included each time I ...

    Sep 19, 2011 · import sys sys.path.append('''C:\code\my-library''') from my-library import my-library Then, my-library will be part of sys.path for as long as the session is active. If I start a new file, I have …

  8. python - How to use the sys.executable - Stack Overflow

    That the libraries uses shutil and sys, when I did a little digging to find out what actually is the sys.executable I found this: sys.executable is a built-in variable in Python that returns the path to the …

  9. Python: Does importing "sys" module also import "os" module?

    Jun 28, 2023 · Does importing sys also impart os, as it seems to? If so, why is it common to import both individually? I can't test for the presence of os before importing sys, as I need sys to test for the …

  10. python - PYTHONPATH vs. sys.path - Stack Overflow

    Another developer and I disagree about whether PYTHONPATH or sys.path should be used to allow Python to find a Python package in a user (e.g., development) directory. We have a Python project …