Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 10:16
    sonarcloud[bot] commented #7061
  • 10:12
    csigs review_requested #7061
  • 10:12
    csigs opened #7061
  • 10:12

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

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

  • Jun 24 22:29
    AmadeusW commented #6943
  • Jun 24 17:47
    StellaHuang95 assigned #6718
  • Jun 24 17:21
    StellaHuang95 assigned #6727
  • Jun 24 16:37
    StellaHuang95 unlabeled #7043
  • Jun 24 16:37
    StellaHuang95 labeled #7043
  • Jun 24 16:37
    StellaHuang95 commented #7043
  • Jun 24 15:36
    AdamYoblick closed #7058
  • Jun 24 15:36
    AdamYoblick commented #7058
  • Jun 24 15:35
    AdamYoblick closed #7060
  • Jun 24 15:35
    AdamYoblick commented #7060
  • Jun 24 15:31

    AdamYoblick on main

    LEGO: Pull request from lego/hb… (compare)

  • Jun 24 15:31

    AdamYoblick on hb_00719690-99d0-4d46-875c-cfd2b9712715_20220624095521909

    (compare)

  • Jun 24 15:31
    AdamYoblick closed #7059
  • Jun 24 15:00
    KorkyPlunger commented #7036
  • Jun 24 09:59
    sonarcloud[bot] commented #7059
  • Jun 24 09:56
    linette-zyy labeled #7060
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.
Steve Dower
@zooba
@skucher Configuring your environment and setting the version to 2.6 rather than 2.5 should deal with that error.
Xi Shen
@davidshen84
Hi. Am I suppose to run 'conda update' to update my conda installation which comes with VS 2017 installation?
I tried to run conda update --prefix "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Anaconda3_64" anaconda
but I got an error conda.CondaMultiError: post-link script failed for package defaults::ipykernel-4.8.0-py36_0
Steve Dower
@zooba
@davidshen84 You can if you want (make sure you run it from an administrative command prompt), it's just a regular Anaconda install. We periodically update the version included with the Visual Studio installer, and so updating Visual Studio will update the version of Anaconda at the same time.
For that error message, is there are more information in the output? I can take a look and see if there's something obviously wrong, but I suspect you'll be best to report it to Anaconda's support channels. You can also uninstall Anaconda through Visual Studio and install it manually from https://anaconda.com if you want a "regular" install - we will still detect it in Visual Studio just fine.
Juan Hernandez
@blindwiz_twitter
Hello, using vs 2017 pro, 15.6.7... I just started working with QT, but it autocomplete doesn't seem to work at all with qt. if I do app = QApplication() ; I then try app.: and get nothing. the same for window = QWidget(): window.: brings up no methods, nothing.
Also, forgot to say I'm using qt5, PyQt5
Alberto Garcia Illera
@illera88
hey there!
I've been using PTVS for a long time but I've never faced the problem I just did:
I have a fresh windows installation and installed visual studio with python support. I can create python projects but for some reason when I click on start it just does nothing. I'm just using a simple hello world and trying to hit a breakpoint in the print instruction but nothing happens
I can't see anything in the output tab. I thought it was related with the python environments but i've tried multiple and that seems not to be the problem.
Using Windows 10 x64 Visual Studio 2017 Professional
Alberto Garcia Illera
@illera88
I've installed Vs2017 preview and exactly same thing: bp does not get hit and there is no log or any info why that happened
Alberto Garcia Illera
@illera88
is there a way I can get more debug from PTVS?
found out that when I start without debugging it actually runs the code. It just seems that nothing is run if I just press F5 or click on Start
Hugues Valois
@huguesv
@illera88 One thing that is relatively new is the experimental debugger. If you look in tools/options/python/experimental, you can turn it on/off. Try both and see if that makes a difference.
Alberto Garcia Illera
@illera88
I rebooted my computer and automagically it started working
I get this with the experimental one:
warning: Debugger speedups using cython not found. Run '"C:\Python27.15-x64\python.exe" "C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\Extensions\Microsoft\Python\Core\Packages\ptvsd\pydevd\setup_cython.py" build_ext --inplace' to build.
and this when actually running what it ask for:
C:\windows\system32>"C:\Python37-x64\python.exe" "C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\Extensions\Microsoft\Python\Core\Packages\ptvsd\pydevd\setup_cython.py" build_ext --inplace
running build_ext
building '_pydevd_bundle.pydevd_cython' extension
creating build
creating build\temp.win-amd64-3.7
creating build\temp.win-amd64-3.7\Release
creating build\temp.win-amd64-3.7\Release\_pydevd_bundle
C:\Program Files (x86)\Microsoft Visual Studio\Preview\Professional\VC\Tools\MSVC\14.14.26428\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -IC:\Python37-x64\include -IC:\Python37-x64\include "-IC:\Program Files (x86)\Microsoft Visual Studio\Preview\Professional\VC\Tools\MSVC\14.14.26428\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\Preview\Professional\VC\Tools\MSVC\14.14.26428\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17134.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17134.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17134.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17134.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.17134.0\cppwinrt" /Tc_pydevd_bundle/pydevd_cython.c /Fobuild\temp.win-amd64-3.7\Release\_pydevd_bundle/pydevd_cython.obj
pydevd_cython.c
_pydevd_bundle/pydevd_cython.c(28837): error C2039: 'exc_type': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28838): error C2039: 'exc_value': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28839): error C2039: 'exc_traceback': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28846): error C2039: 'exc_type': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28847): error C2039: 'exc_value': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28848): error C2039: 'exc_traceback': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28849): error C2039: 'exc_type': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28850): error C2039: 'exc_value': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28851): error C2039: 'exc_traceback': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28896): error C2039: 'exc_type': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28897): error C2039: 'exc_value': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28898): error C2039: 'exc_traceback': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28899): error C2039: 'exc_type': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28900): error C2039: 'exc_value': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(28901): error C2039: 'exc_traceback': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(29032): error C2039: 'exc_type': is not a member of '_ts'
c:\python37-x64\include\pystate.h(209): note: see declaration of '_ts'
_pydevd_bundle/pydevd_cython.c(29033): error C2039: 'exc_value': is not a member of '_ts'
c:\python37-x64\include\pystate.
Steve Dower
@zooba
@illera88 I don't know what the status of 3.7 support is for pydevd right now, but it should work fine without the speedups. Once we have clarified/fixed it, we will include the speedups in a VS update.
Alberto Garcia Illera
@illera88
What version is tested for the speedups?
Thomas Thelen
@ThomasThelen
Regarding support for Mac,
Every instillation guide that I have seen says to install python support via the VS Installer. The mac installer however, does not support the option for this. Is this extension supported for Mac? I haven't any indication that is is.
Steve Dower
@zooba
@illera88 Currently only Python 3.6 IIRC, though I'm petitioning the ptvsd team to expand that. Feel free to post issues on https://github.com/Microsoft/ptvsd requesting it :)
@ThomasThelen It is not. VS for Mac is a totally different product and we would have to reimplement most of the Python support to make it work there. Currently we are focused on Visual Studio 2017 and VS Code - the latter works fine on Mac, so we suggest trying that out.
Benjamin Van Renterghem
@BenjaVR
I was reading the issues about embedding Jupyter Notebooks in Visual Studio itself, although I don't understand why this will (probably?) not happen. How I would see this: when opening a .ipynb file, start a NB server at project root (with an interpreter of choice), and render the .ipynb file. What's the catch here?