Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 09:54
    sonarcloud[bot] commented #7124
  • 09:50
    csigs review_requested #7124
  • 09:50
    csigs opened #7124
  • 09:50

    csigs on hb_00719690-99d0-4d46-875c-cfd2b9712715_20220813095043485

    Juno: check in to lego/hb_00719… (compare)

  • Aug 12 15:30
    AdamYoblick commented #7118
  • Aug 12 06:21
    ttSpace labeled #7123
  • Aug 12 06:21
    ttSpace opened #7123
  • Aug 11 23:42
    AlphaScorpii-dev commented #7118
  • Aug 11 18:46
    AdamYoblick commented #7118
  • Aug 11 18:38

    StellaHuang95 on main

    Add some new settings to PTVS (… (compare)

  • Aug 11 18:38

    StellaHuang95 on settings

    (compare)

  • Aug 11 18:38
    StellaHuang95 closed #7105
  • Aug 11 18:38
    StellaHuang95 closed #7107
  • Aug 11 18:38
    StellaHuang95 closed #7121
  • Aug 11 17:52
    github-actions[bot] unlabeled #7122
  • Aug 11 17:52
    judej assigned #7122
  • Aug 11 17:52
    judej labeled #7122
  • Aug 11 17:43
    StellaHuang95 unlabeled #7115
  • Aug 11 17:43
    StellaHuang95 labeled #7115
  • Aug 11 17:25
    sonarcloud[bot] commented #7121
Ray Koopa
@RayKoopa
Hey there... I'm kinda confused now. I heard some guy saying only 3.1.0 works with VS2017, you say VS (which version?) was never upgraded to use 3.x. From my side, I can neither get 3.2.0 or 3.1.0 to work with VS2017 (15.3 update). Trying to debug Blender using my ptvsd 3.1.0 from my global Python installation, VS always claims it doesn't listen to connections or "the format of one argument does not meet the contract"... halp :(
Steve Dower
@zooba
@RayKoopa VS Code has not yet been updated for ptvsd 3. Since you are using Visual Studio 2017 15.3, you will need ptvsd==3.2.0.
Denis Akhiyarov
@denfromufa

@zooba @int19h sorry for hijacking this chat, but is there anyone in PTVS team who can review this code for properly finalizing and garbage collecting PyObject in pythonnet? I see that you use a lot of SuppressFinalize and safehandles, so you might be able to review this:

pythonnet/pythonnet#532

https://github.com/Microsoft/PTVS/search?utf8=%E2%9C%93&q=suppressfinalize&type=
https://github.com/Microsoft/PTVS/search?utf8=%E2%9C%93&q=safehandle&type=

The code is really mind-boggling to me.

Steve Dower
@zooba
@denfromufa Me too. Would love to be able to get up to speed on it, but afraid I can't spare the time this week
Joshua Barnett
@joshua-barnett

I cannot seem to get ptvsd (3.0.0) working with my Flask application.

I've set FLASK_DEBUG to false to prevent the live reload or werkzeug debugger causing issues.

I can see in netstat the python process waiting for the debugger to attach on port 5555.

Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
tcp        0      0 0.0.0.0:5555            0.0.0.0:*               LISTEN      7/python

When I attempt to connect I just get.

Debug adapter process has terminated unexpectedly

With no information in the Debug Console as to why it failed.

If I reload VSCode and attempt to attach again it appears to connect, but again no output in the Debug Console and the breakpoints are all inactive.

Steve Dower
@zooba
@synthecypher VS Code still requires an earlier version of ptvsd, as it has not been updated to use the latest yet. Downgrade to ptvsd<3 on the remote machine and it should be fine.
Joshua Barnett
@joshua-barnett
@zooba are you sure its <3 most of the issues I've seen cite ptvsd==3.0.0.
Steve Dower
@zooba
@synthecypher You could be right. I don't work on VS Code, and currently ptvsd does not officially support VS Code (it's the other way around). If you ask on one of their sites then they'll be able to tell you the right answer.
scatterblak
@scatterblak_twitter
Testing..1...2..3....anyone around who knows how to get PTVS running on MSVS 2017?
Steve Dower
@zooba
@scatterblak_twitter It's in the main Visual Studio 2017 installer - see the instructions at https://docs.microsoft.com/visualstudio/python/vs-tutorial-01-00
scatterblak
@scatterblak_twitter
Nope. Not there. It's there, of course, in the community/preview version, but the actual production version doesn't have it anymore - it's gone. You also can't get to it with the additional instructions to go ahead and install MSVS, and then go into Ctrl->Add/Remove Programs and select 'Change' for MSVS. It's not there.
Steve Dower
@zooba
What do you mean "the actual production version"? Are you stuck on 15.0 for some reason and can't install 15.3?
scatterblak
@scatterblak_twitter
...it might be there if you had the preview. If you're one of the unlucky ones like me who paid for MSDN just to be able to do python dev in the MSVS IDE, and you didn't have the MSVS preview, Python will not be available to you unless you dig through and install it the old fashioned way. Enjoy.
Steve Dower
@zooba
@scatterblak_twitter I'm the lead dev on this project and am the one responsible for checking in changes to VS to make sure it appears in the installer. When I run the current installer, both Release and Preview, it is there, and I can see the telemetry showing that tens of thousands of people have installed and are using it.
This is clearly an issue with your configuration, and I would like to help you diagnose and fix it.
Now, when you open the VS installer, there is going to be a version number in the bottom right corner. Can you please tell me what it is?
Supakorn Rassameemasmuang
@supakorn-ras
To
NVM
To add, is PTVS in 15.3 still 3.0 or has it been updated to 3.2? Mine's still showing Python 3.0 in the about section.
Steve Dower
@zooba
There should also be a version number underneath any available versions of Visual Studio (e.g. "15.0", "15.3", etc.) - could you tell me what you see there?
@supakorn-ras In 15.3, it is 3.1. 15.4 when it releases will have 3.2. We don't update the 3.x.y "x" part of the number, but the "y" automatically updates and is enough for us to find the matching sources. Each Visual Studio version, however, has exactly one PTVS version, so if you're on the latest VS then you have the latest PTVS that is available to you.
(The reason we don't change the version too dramatically is to do with .NET assembly resolution. If you're familiar with that, you won't be surprised that we don't want to rock that boat too much :) )
Supakorn Rassameemasmuang
@supakorn-ras
@zooba Oh okay. Thanks for clarification. I thought that the release was stuck in nowhere and that we were using the old version.
Benjamin Van Renterghem
@BenjaVR
hi, does anyone have a good 'workflow' with PTVS and Pipenv? It'll be the standard soon enough while working with python: https://packaging.python.org/new-tutorials/installing-and-using-packages/#installing-pipenv
Alberto Garcia Illera
@illera88
Hi, time to time while debugging PTVS hangs and I can't do anything but closing the python shell. How can I know the PTVS version I have installed and update it if it's old?
it happens when dealing with multiple threads
Alberto Garcia Illera
@illera88
hello??
Steve Dower
@zooba

@illera88 Sorry to have missed your messages (I was travelling at the time). If you're using VS 2017 and it isn't prompting you to update, then you're on the latest. If you are doing remote debugging, then pip install -U ptvsd on the remote machine will make sure you have the latest debugger (which you'll need if you have the latest VS 2017).

However, if you're doing multithreaded debugging, it's equally likely that you've discovered a bug. We're doing some heavy work on our debugger right now (expect an announcement in the next week or two), so we're unlikely to consider a bugfix to the old one, but if you can report an issue with enough info for us to reproduce it we can make sure it works with the next version.

Alberto Garcia Illera
@illera88
I'll wait for the announcements. Thank you!
Alberto Garcia Illera
@illera88
Hi @zooba .
I'm importing a class I installed using pip and PTVS does not find it so it throws an error.
ModuleNotFoundError: No module named 'binance.websockets'; 'binance' is not a package. If I open a shell and do from binance.websockets import BinanceSocketManager it works fine. I've updated the intelligence db but it still says the same
2017-12-31 13_01_27-bender - Microsoft Visual Studio.png
2017-12-31 13_03_06-bender - Microsoft Visual Studio.png
as you can see in the latest screenshot I can import it fine from the interactive shell
I tried restarting VS but same thing.
Thank you
Alberto Garcia Illera
@illera88
Happy new year!! Could you see my question?
Hugues Valois
@huguesv
@illera88 it looks like there are issues with the binance packages that were uploaded to PyPI. See https://pypi.python.org/pypi/binance/0.1 and https://pypi.python.org/pypi/binance/0.2 -- there's only one wheel file for 0.2, and it's Python 2.x only. So installing under Python 3.x will get you v0.1 installed from source, and the resulting install doesn't have the expected binance.py anywhere. You probably should contact the author to let them know about this.
Alberto Garcia Illera
@illera88
Thank you! I will
Kuno Meyer
@kunom
It looks as in the current VS2017 it looks as if there is no f-string support. This is quite annoying in every day use because it breaks most of the code introspection features like "show references" and "refactor". I browsed the Github repository but was neither able to find the behaviour documented nor a bug ticket or a roadmap entry. Is it already fixed but just not deployed to the production version of VS2017?
Steve Dower
@zooba
@kunom There's no specific support in there yet to enable parts of the contents of {} to be treated as code, and we haven't seen enough demand to prioritise the work (of significantly modifying our Python parser) over other items. We'll take your comment as a vote in favour. Thanks!
Kuno Meyer
@kunom
@zooba I understand that handling the contents of {} means a lot of parser work. It might be an acceptable intermediate solution to extend the parser that it just accepts the prefix f for strings (like f'' and f""), so that the parsing after the f-string is less impacted than now an that the "invalid syntax" red lines go away.
Steve Dower
@zooba
@kunom That has been fixed for ages - can you check exactly what version you have? There should be Python entries in the Help/About dialog with a precise version number
Kuno Meyer
@kunom
@zooba The Python entries are at version "3.0.17320.1". Then I found out that I had selected "IronPython 2.7" as default Python environment. Switching to 3.6 resolved my issues. Thanks a lot and sorry for the noise here!
Shaun van Zyl
@ShahuN-107
Hello! I'm very new to using Visual Studio, and would like to get CookieCutter Explorer installed on Visual Studio 2015 Professional. I've installed Python tools for Visual Studio 2.2.6, and I have both python 2.7 and 3.5(64-bit) installed, via CPython and Anaconda respectively, and those both show up in the Python Environments tab in Visual Studio, with 3.5 set as the default. Afaik, the CookieCutter Explorer should be present under View > CookieCutter Explorer. Am I missing something?
Hugues Valois
@huguesv
@ShahuN-107 the cookiecutter integration is a new feature that is only available in Visual Studio 2017.
yusufkaratoprak
@yusufkaratoprak
hi; how can I install python tools in visual studio 2017
Steve Dower
@zooba
@yusufkaratoprak Python is available as a workload when you install Visual Studio 2017. If you've already installed it and it's not there, open Quick Launch (top-right of the window) and type "Python" - it will help take you back to the installer
skucher
@skucher
Hello, Due to environment restriction my team is forced to develop and test on python 2.5. In Visual Studio 2017 I am getting an error while trying to run my unit tests saying 2.5 version of python is not supported anymore. Is there any way that we can do that in Visual Studio 2017?
Steve Dower
@zooba
@skucher Thanks for reaching out! We see so little usage of 2.5 that when we adopted JSON we chose to simply drop 2.5 support rather than provide workarounds. However, in most cases these steps should work:
  • add your 2.5 environment as a custom environment and mark its version as 2.6
  • install the simplejson package from PyPI
  • add a sitecustomize.py file to your Python 2.5 install that contains:
    import simplejson, sys
    sys.modules['json'] = simplejson
    Most of the problems that may occur with Python 2.5 are fixable in the .py files in our code, so feel free to modify those. We're open to merging pull requests to maintain Python 2.5 support (provided it doesn't impact later versions), but at this point we are no longer testing against Python 2.5 or 3.0.
skucher
@skucher
@zooba Thank you very much, the issue i am having is when i am trying to debug i have the following error:
System.NotSupportedException: Debugging is not supported for Python 2.5 and earlier.