Pytest | Visual Studio Code

แชร์
ฝัง
  • เผยแพร่เมื่อ 5 ก.ย. 2022
  • VSCODE - Pytest tips :
    ◼️ Missing "test tube" icon : fixed
    ◼️ 'Module not found' : fixed
    ◼️ Specify correct Python interpreter! (Ctrl + Shift + P )
    ◼️ Green Ticks in activity bar : fixed (create __init__.py )
    A quick demo of potential issues you may want to check for with Pytest in Visual Studio Code, and if you use Poetry, check this:
    :: Poetry ::
    -----------------
    If you are using Poetry, you may find you get an older version of pytest, so use "pip install pytest" to get version 7.1.3
    If your Visual Studio Code interpreter for poetry shows up with 3.8 or 3.9 then type :
    $ poetry env use 3.10
    Then you'll get the LATEST Python version when you create a new virtual environment (i.e The most recent version that you have installed on your computer)
    If you already have a project and the pyproject.toml file has the older versions then delete it and then type:
    $ poetry init
    And interactively follow the commands to generate a new pyproject.toml file.
    If you want a fast VPS server with Python installed check out :
    🌏 webdock.io/en?maff=wdaff--170
    👍 Become a patron 👍
    🌏 / drpi
    Buy Dr Pi a coffee (or Tea)
    ☕ www.buymeacoffee.com/DrPi
    Proxies
    =================================================
    If you need a good, easy to use proxy, I was recommended this one, and having used ScraperAPI for a while I can vouch for them. If you were going to sign up anyway, then maybe you would be kind enough to use the link and the coupon code below?
    You can also do a full working trial first as well, (unlike some other companies). The trial doesn't ask for any payment details either so all good! 👍
    🌏 10% off ScraperAPI : www.scraperapi.com?fpr=ken49
    ◼️ Coupon Code: DRPI10
    Thumbs up yeah? (cos Algos..)
    #webscraping #tutorials #python
  • วิทยาศาสตร์และเทคโนโลยี

ความคิดเห็น • 13

  • @dinugakasun5218
    @dinugakasun5218 ปีที่แล้ว +2

    Worked like a charm, Thanks for the video🙏🙏

  • @akshortman
    @akshortman 2 หลายเดือนก่อน +1

    Just what I needed, excellent video! Thank you.

    • @python360
      @python360  2 หลายเดือนก่อน

      Excellent. Thank you for the kind comment!

  • @misaelramirez9632
    @misaelramirez9632 8 หลายเดือนก่อน +1

    Thank you!

  • @franciscopovoas8798
    @franciscopovoas8798 ปีที่แล้ว +1

    You solved my problem. Thanks!

  • @JustMe-hv5re
    @JustMe-hv5re 5 หลายเดือนก่อน +1

    Thank you for doing this video!!!

    • @python360
      @python360  5 หลายเดือนก่อน

      Thank you! That's very kind of you to comment, much appreciated!!

  • @allan-mccombs
    @allan-mccombs 7 หลายเดือนก่อน +1

    Thank you for your post.

    • @python360
      @python360  7 หลายเดือนก่อน

      You're welcome

  • @Sureshkumar-ee3zu
    @Sureshkumar-ee3zu ปีที่แล้ว +1

    The session is realistic and helped how to debug.

    • @python360
      @python360  ปีที่แล้ว +1

      Thank you! Glad it helped 👍👍

  • @Mrtudor1987
    @Mrtudor1987 ปีที่แล้ว +2

    Thanks for sharings. I received ModuleNotFoundError: No module named . Can you explain it please? Thanks in advance

    • @python360
      @python360  ปีที่แล้ว +1

      You might have more than one version of Python on your machine? Either specify the version(ctrl, shift, p) and 'select interpreter' and chose the one that matches your current environment, or alternatively type 'python3 -m pytest' to run pytest