Questions tagged [visual-studio-code]
Visual Studio Code is an open source text editor available for Linux, OS X, and Windows. It includes support for debugging, embedded Git Control, various extensions and rich development experiences such as intelligent code completion. It is open source driven by Microsoft, built on Electron like GitHub's Atom.
26 questions
0 votes
1 answer
140 views
Can't change geometry in GeoPandas
I have an extremely strange issue with my code. I have a dataframe with 2 columns with point geometries, startgeom and endgeom. I want to assign a geometry from startgeom, do some calculations and ...
3 votes
1 answer
555 views
Using PyQGIS 3 in Visual Studio Code
I did all the steps in the video below: https://www.youtube.com/watch?v=qobogVuXtJU&list=PLbGkCPlkC_XTAUG5HC1WPhxMuZQnBQ7jU&index=1&t=308s When I run the full Python file, it throws this: ...
1 vote
1 answer
141 views
Initial zoom to GeoJSON object from file (.js) in Leaflet
I am building a viewer with Leaflet API and OpenStreetMap base. I want that when I enter this viewer it shows me immediately in the initial visualization the extension of my layer that I am using. For ...
0 votes
1 answer
97 views
Is it possible to take a web map created via the qgis2web plugin & edit it in Visual Studio Code
After I export a map via qgis2web, is it possible to edit the code and add to it in Visual Studio Code? If so, how do i open it in VS? is it just the index.html file?
1 vote
1 answer
413 views
How to clone a copy using ArcGIS API for Python
What I am trying to do: Take a layer from ArcGIS Enterprise, clone it as a temporary file, overwrite a file in SQL DB, delete temporary file. What I have tried so far: def overwrite_existing_layer(...
0 votes
1 answer
285 views
VS Code re-installation: Pylance now complains about arcpy, but intellisense, code completion, and script execution works ok
I was recently victim to this bug where VS Code (Insiders) seems to uninstall itself. After a reinstallation, most of my settings and preferences were retained, but Pylance is now complaining about ...
3 votes
1 answer
2k views
Cannot visualize map with geemap when using VS Code
I am using Jupyter notebook on VS. I have generated script that gets an image collection, does some calculations on it and generates one image (ee.image.Image). I want to display it on a map. When I ...
0 votes
0 answers
247 views
gdal_calc.py not working with VSCode/Conda on Windows
I'm passing a simple gdal_calc.py command line argument to os.system() in a python script. However when I run the script, nothing is generated and the gdal_calc.py source script opens automatically: ...
0 votes
0 answers
1k views
Trying to configure ArcGIS Pro/ArcPy + VS Code, but can't activate conda environment. How do I correctly do this?
I'm attempting to configure VS Code for ArcPy/ArcGIS Pro development, and things have been going ok so far, however I have run into an issue I am not sure how to resolve. I'm also curious to hear how ...
1 vote
0 answers
85 views
Adding features to a vectorlayer using PyQGIS in VSCode
I'm trying to create a plugin that generate a vector layer with geometry using 2 other layers, the first one 'layer_segment'contain features with geometries to dissolve based on common field value ...
7 votes
1 answer
676 views
VS Code Intellisense with modern arcpy syntax
Does anyone know to get VS Code's intellisense to work with modern arcpy syntax? This post addresses VS Code not recognizing the correct interpreter at all: VS Code autocomplete for ArcPy But that isn'...
5 votes
0 answers
978 views
Looking for definitive way to enable ALL QGIS module access in VS Code (Windows 10)
I'm having trouble importing and getting code inspection/autocompletion working for all the PyQGIS modules I need to do scripting in VS Code. After looking at these questions: Understanding qgis....
2 votes
0 answers
364 views
Setting up environment for python MapScript development
I'm trying to setup a virtual environment for developing against the Python bindings of MapScript on Windows. So far, I've tried several things in various combinations: Install MapScript via pip ...
3 votes
1 answer
2k views
Using PyQGIS in Visual Studio Code
I have a standalone installation of QGIS 3.10.14, and I would like to use PyQGIS while working in Visual Studio Code. I have already tried customising the settings file: { "python.pythonPath"...
1 vote
1 answer
415 views
Visual Studio Code Upgrading to 1.56.0... Issues with Environment Windows
Prior to the last Visual Studio Code update, I was able to set the windows environment variables. Now with the new update I can't and I don't know what to do. My code is: { "folders": [ ...