Coder Social home page Coder Social logo

vs-azure-iot-edge-docs's Introduction

Azure IoT Edge Tools for Visual Studio Documentation

Announcement

The Azure IoT Visual Studio extension is in a maintenance mode. Please see this announcement for more details. We recommend using the command line steps to develop edge modules over VS extensions.

Overview

Azure IoT Edge Tools makes it easy to code, build, deploy, and debug your IoT Edge solutions in Visual Studio 2019 and in Visual Studio 2022

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

Legal Notices

Microsoft and any contributors grant you a license to the Microsoft documentation and other content in this repository under the Creative Commons Attribution 4.0 International Public License, see the LICENSE file, and grant you a license to any code in the repository under the MIT License, see the LICENSE-CODE file.

Microsoft, Windows, Microsoft Azure and/or other Microsoft products and services referenced in the documentation may be either trademarks or registered trademarks of Microsoft in the United States and/or other countries. The licenses for this project do not grant you rights to use any Microsoft names, logos, or trademarks. Microsoft's general trademark guidelines can be found at http://go.microsoft.com/fwlink/?LinkID=254653.

Privacy information can be found at https://privacy.microsoft.com/en-us/

Microsoft and any contributors reserve all other rights, whether under their respective copyrights, patents, or trademarks, whether by implication, estoppel or otherwise.

Support

The team monitors the issue section on regular basis and will try to assist with troubleshooting or questions related IoT Edge tools on a best effort basis.

A few tips before opening an issue. Try to generalize the problem as much as possible. Examples include

  • Removing 3rd party components
  • Reproduce the issue with provided deployment manifest used
  • Specify whether issue is reproducible on physical device or simulated device or both Also, Consider consulting on the docker docs channel for general docker questions.

vs-azure-iot-edge-docs's People

Contributors

erich-wang avatar konichi3 avatar marianan avatar mhshami01 avatar microsoft-github-policy-service[bot] avatar microsoftopensource avatar msftgits avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vs-azure-iot-edge-docs's Issues

configurable Docker-Root-Directory

Hi,

in our project, we want to use iot-edge-tools to develop different edge-modules. Some of these modules references against common libs which are also included as projects into the Edge solutions.

Our solution structure of the Edge Project in Visual studio looks like:

-IoT-Edge-Solution.sln
--| - Edge-Project
------| - Edge-Projet.iotedgeproj
--| - SharedNetCorelib (donet shared library)
------| - SharedNetCorelib.csproject
--| - Edge-Module1 (Edge Project) -> References SharedNetCoreLib
------| - Edge-Module1.csproject
------| - module.json
------| - DockerFile.amd64

The problem occurs now during the DockerBuild. We need to copy the sharedNetCore sourcecode into the Docker-Build-Image:

COPY ["../SharedNetCorelib/SharedNetCorelib.csproj", "SharedNetCorelib/"]

This copy command fails, because pathes out of the Docker-Working-Directory are not allowded.
It looks like, that the iot-edge-tools assumes the location of the Edge-Module1.csproject as the docker-root-working directory. This leads to problems, if there are shared librarys, like in our case.

Would be nice, if you could add a option to the edge-tools plugin which allows a different path for the docker-root.

Thanks.
Toni

"Build IoT Edge Modules" does not use module.json buildOptions

Machine

  • Windows 10 Pro 20H2
  • Visual Studio Community 2019 Version 16.9.4
  • Azure IoT Edge Tools for VS2019 Version 1.7.0

In my module.json I am attempting to pass a build arg like so:
"buildOptions": [ "--build-arg PAT=${PAT}" ] ($PAT coming from a .env file)

When I right-click on my iotedgeproj and hit "Build IoT Edge Modules", the docker build does not include my custom build options:

docker build --rm -f "C:\repos\EdgePlatform\CleanSpark.Edge\CleanSpark.Edge.FeedModule\Dockerfile.amd64.debug" -t localhost:5000/feedmodule:0.0.1-amd64.debug "C:\repos\EdgePlatform\CleanSpark.Edge\CleanSpark.Edge.FeedModule"

Latest extension targets older Net Core

I'm curious why the latest version of the extension (1.4.0) targets .NET Core 2.1 in the project files when 3.1 is the latest on my machine. Likewise in the Dockerfile it targets:

FROM microsoft/dotnet:2.1-sdk AS build-env
FROM microsoft/dotnet:2.1-runtime-stretch-slim-arm32v7

instead of:

FROM mcr.microsoft.com/dotnet/core/sdk:3.1 AS build-env
FROM mcr.microsoft.com/dotnet/core/runtime:3.1.1-buster-slim-arm32v7

Is it just a case of that was the latest when the extension was created and it hasn't been updated since? Or are their tooling or runtime requirements to use older, last verified versions?

Visual Studio 2022: iotedgehubdev.exe start vs modulecred

Hi,

I've 2 different IoT Edge modules projects using Visual Studio 2022.

I set up as Startup Project the iotedge projects.

When I press the debug button to run the modules and debug them:

image

The behaviour is different.

  1. First behavior (and what I want):

Build started at 11:11 AM...
1>------ Build started: Project: Project.Edge.Deployment, Configuration: Debug Any CPU ------
1>DOCKER_HOST:
1>DOCKER_TLS_VERIFY:
1>DOCKER_CERT_PATH:
1>Additional Env Variables:
1>SimulatorPath: C:\Users\User1\Documents\Visual Studio 2022\iotedgehubdev\v0.14.18\iotedgehubdev.exe
1>C:\Users\User1\Documents\Visual Studio 2022\iotedgehubdev\v0.14.18\iotedgehubdev.exe start -d "C:\projects\Solution\Project.Edge\Modules\obj\tmp_deployment_for_local_debug.json"

  1. Second behaviour:

C:\Users\User1\Documents\Visual Studio 2022\iotedgehubdev\v0.14.18\iotedgehubdev.exe modulecred -l -m "SignalProcessor"

How can I set the first behavior??

Simulated Temperature Sensor not configured correctly

Azure IoT Edge Tools for VS 2019 Version 1.7.0
Visual Studio 2019 Version 16.7.0 Preview 6.0

When I create a new Azure IoT Edge (Linux amd64) project and immediately add the Simulated Temperature Sensor module from Microsoft via the Azure Marketplace (all still in the configure new project wizard) the module does not get configured correctly e.g. its image location is not added to the deployment file.

If I add the Simulated Temperature Sensor after the initial project has been created all works as expected.

install simulator failed when set docker_host to "tcp://10.172.15.01:2375"

step:
1.open VS and set docker host to "tcp://10.172.15.01:2375"
2. create new edge project , then install simulator failed

Azure IoT Edge Simulator enable debugging Azure IoT Edge modules and solutions locally without Edge runtime installed.
Start downloading and installing Azure IoT Edge simulator...
[ERROR]: Download and install Azure IoT Edge simulator failed, please click menu 'Tools -> Azure IoT Edge Tools -> Update IoT Edge simulator' to reinstall simulator and try again.
Access to the path 'C:\Users\v-czg\Documents\Visual Studio 2017\iotedgehubdev\iotedgehubdev' is denied.
  1. remove docker_host settings and create new project again
  2. auto-install simulator pass

Cannot Add a FunctionsModule in VS2019

Hi,

I cannot get a FunctionModule to work in an IotEdge Hub Dev project under Visual Studio 2019.

I tried the following:

We run command:
dotnet new aziotedgefunction -n LogTransferModule

This generates a new Azure Functions Module Project in the Solution Directory

If you then try and include the Project into the existing solution you get the following error:

The following module cannot be added as a Module Reference because its not an IoT Edge module

I edited the Project File, and I noticed, that every IOT Edge module has an ItemGroup called ProjectCapability, I added that ItemGroup to the newly generated project. Now I could successfully Add the module to the Solution.

But when I run the solution on IoT Edge Hub dev simulator, the modules starts up, then the Client crashes and every module gets removed from IoT Edge hub dev.
Why can’t I add an Azure FunctionsModule in VS2019?

It works fine if I add a Functions Project in Visual Studio Code, but I want to use Visual Studio for development and debugging.

Hope you can help.

Azure IoT Edge Tools for VS 2019 - "Build IoT Edge Modules" command ignoring build args specified in module.json

I'm currently using the Azure IoT Edge Tools for VS 2019, and when I specify docker build args in the "buildOptions" section of the module.json, these build args are not being passed to the "docker build" command. When I use the same deployment.template.json and module.json using the VS Code tools, it works fine.

Attached is a zip file of a sample project illustrating the problem. If built in VS 2019, the RUN command checking the value of the build argument fails. When run in VS Code, it succeeds. You can also see that VS 2019 does not call "docker build" with the --build-arg parameter.

SampleIoTEdgeApp.zip

NU 1202 Error when creating projects from Template

hi Sir

I created a blank project (Windows, AMD 64) from Azure IoT Edge template in my VS2019 + Azure IoT tool (latest preview). and I build and push just after the project created. it pop up many NU1202 error like the following:

Error	NU1202	Package System.Threading.Overlapped 4.3.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package System.Threading.Overlapped 4.3.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package System.Runtime.Loader 4.3.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package System.Runtime.Loader 4.3.0 supports:
  - monoandroid10 (MonoAndroid,Version=v1.0)
  - monotouch10 (MonoTouch,Version=v1.0)
  - net462 (.NETFramework,Version=v4.6.2)
  - xamarinios10 (Xamarin.iOS,Version=v1.0)
  - xamarinmac20 (Xamarin.Mac,Version=v2.0)
  - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
  - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package Microsoft.Azure.Devices.Shared 1.16.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package Microsoft.Azure.Devices.Shared 1.16.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package DotNetty.Codecs.Mqtt 0.6.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package DotNetty.Codecs.Mqtt 0.6.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package DotNetty.Handlers 0.6.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package DotNetty.Handlers 0.6.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package Microsoft.Azure.Amqp 2.4.1 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package Microsoft.Azure.Amqp 2.4.1 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package Newtonsoft.Json 10.0.3 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package Newtonsoft.Json 10.0.3 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package System.Configuration.ConfigurationManager 4.4.1 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package System.Configuration.ConfigurationManager 4.4.1 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package WindowsAzure.Storage 9.3.2 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package WindowsAzure.Storage 9.3.2 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package DotNetty.Buffers 0.6.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package DotNetty.Buffers 0.6.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package DotNetty.Codecs 0.6.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package DotNetty.Codecs 0.6.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package DotNetty.Common 0.6.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package DotNetty.Common 0.6.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package DotNetty.Transport 0.6.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package DotNetty.Transport 0.6.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package System.Net.Security 4.3.2 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package System.Net.Security 4.3.2 supports:
  - monoandroid10 (MonoAndroid,Version=v1.0)
  - monotouch10 (MonoTouch,Version=v1.0)
  - xamarinios10 (Xamarin.iOS,Version=v1.0)
  - xamarinmac20 (Xamarin.Mac,Version=v2.0)
  - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
  - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package System.Net.WebSockets.Client 4.0.2 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package System.Net.WebSockets.Client 4.0.2 supports:
  - monoandroid10 (MonoAndroid,Version=v1.0)
  - monotouch10 (MonoTouch,Version=v1.0)
  - xamarinios10 (Xamarin.iOS,Version=v1.0)
  - xamarinmac20 (Xamarin.Mac,Version=v2.0)
  - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
  - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package System.Security.Cryptography.ProtectedData 4.4.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package System.Security.Cryptography.ProtectedData 4.4.0 supports:
  - monoandroid10 (MonoAndroid,Version=v1.0)
  - monotouch10 (MonoTouch,Version=v1.0)
  - xamarinios10 (Xamarin.iOS,Version=v1.0)
  - xamarinmac20 (Xamarin.Mac,Version=v2.0)
  - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
  - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package System.Runtime.CompilerServices.Unsafe 4.5.2 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package System.Runtime.CompilerServices.Unsafe 4.5.2 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package Microsoft.Extensions.Logging 1.1.1 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package Microsoft.Extensions.Logging 1.1.1 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package System.Net.WebSockets 4.0.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package System.Net.WebSockets 4.0.0 supports:
  - monoandroid10 (MonoAndroid,Version=v1.0)
  - monotouch10 (MonoTouch,Version=v1.0)
  - xamarinios10 (Xamarin.iOS,Version=v1.0)
  - xamarinmac20 (Xamarin.Mac,Version=v2.0)
  - xamarintvos10 (Xamarin.TVOS,Version=v1.0)
  - xamarinwatchos10 (Xamarin.WatchOS,Version=v1.0)	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package Microsoft.Extensions.DependencyInjection.Abstractions 1.1.0 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package Microsoft.Extensions.DependencyInjection.Abstractions 1.1.0 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1	
Error	NU1202	Package Microsoft.Extensions.Logging.Abstractions 1.1.1 is not compatible with netcoreapp2.1 (.NETCoreApp,Version=v2.1). Package Microsoft.Extensions.Logging.Abstractions 1.1.1 does not support any target frameworks.	SensorFilterModule	C:\Users\alpha\source\repos\MyEdgeFilterApp\SensorFilterModule\SensorFilterModule.csproj	1

do you have any idea how to fix it?

Br
ray

Add remote debug support

This is a feedback from customer in iotedghubdev repo Azure/iotedgehubdev#191

Add details here:

As far as I can tell, VS 2019 IoT Edge module projects don't work with remote debugging because iotedgehubdev doesn't. Remote debugging is necessary when developing on a Windows machine with an Insider build installed because Docker refuses to install. I have docker running on a remote linux machine that should work but I have no discernible options to do so in the UI.

SimulatedTemperatureSensor module Will not automatically add to default project

repro on v1.3.0-rc

  1. File->new project->Azure Iot Edge (Linux Amd 64)
  2. Create the project without adding any modules (Skip)
    here no SimulatedTemperatureSensor module in deployment
  3. add ->new IoT edge module->select C# module
    here only add IotEdgeModule1 in deployment , SimulatedTemperatureSensor module Will not automatically add to the file again

but if user create new project with c# modules, SimulatedTemperatureSensor module will add in templated.

VS IoT Edge Tools for VS 2019

Is there a timeline for having these tools available for VS 2019? I searched online but wasn't able to find any links or plans for Azure IoT Edge Tools for Visual Studio 2019.

Azure IoT Edge Tools for VS 2019 v2.0.0: Could not load file or assembly Microsoft.VisualStudio.Validation, Version=16.9.0.0

Hi, I've installed v.2.0 and when I launch to debug my modules, I receive the error:

Failed to exec task with error System.Exception: Cannot find executable of Azure IoT Edge simulator, please click menu 'Tools -> Azure IoT Edge Tools -> Update IoT Edge simulator' to reinstall simulator and try again.

(but the executable is on the printed path C:\Users\fmondelo\Documents\Visual Studio 2019\iotedgehubdev\v0.14.9\iotedgehubdev in the log)

When I try to click menu 'Tools -> Azure IoT Edge Tools -> Update IoT Edge simulator' I receive the next error:

image

In the ActivityLog.xml is this error, how I can resolve this:

SetSite failed for package [Tools for creating and debugging Azure IoT Edge Modules]Source: 'Microsoft.VisualStudio.Azure.IoT.Edge.ProjectSystem' Description: Could not load file or assembly 'Microsoft.VisualStudio.Validation, Version=16.9.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) System.IO.FileLoadException: Could not load file or assembly 'Microsoft.VisualStudio.Validation, Version=16.9.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) File name: 'Microsoft.VisualStudio.Validation, Version=16.9.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' at Microsoft.VisualStudio.Azure.IoT.Edge.ProjectSystem.Commands.ToolsEdgeCommandBase.Initialize() at Microsoft.VisualStudio.Azure.IoT.Edge.ProjectSystem.Commands.ToolsEdgeCommandBase..ctor(IoTEdgePackage package) at Microsoft.VisualStudio.Azure.IoT.Edge.ProjectSystem.IoTEdgePackage.<InitializeAsync>d__5.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.Shell.AsyncPackage.<>c__DisplayClass20_0.<<Microsoft-VisualStudio-Shell-Interop-IAsyncLoadablePackageInitialize-Initialize>b__1>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at Microsoft.VisualStudio.Services.VsTask.RethrowException(AggregateException e) at Microsoft.VisualStudio.Services.VsTask.InternalGetResult(Boolean ignoreUIThreadCheck) at Microsoft.VisualStudio.Services.VsTask.GetResult() WRN: Assembly binding logging is turned OFF. To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1. Note: There is some performance penalty associated with assembly bind failure logging. To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

When trying to generate new modules nothing happens

  • VS Community 2022 Version: 17.8.3
  • OS Version: Microsoft Windows 10 Pro Version 10.0.19045 Build 19045
  • Extension version: v2.0.8

Steps to Reproduce:

  1. Generate a new project. Parameters don't mather neither does the container registry that gets entered
  2. Once the project is done generating there will be no modules even tho the flow allows you to add one.
  3. After the project is done generating trying to add a module will result in nothing. No error, no module

Any advice on what this might be?

Default routes always added when opening visual studio

We've setup custom routes with custom names in our deployment.template.json.
Every time we open vs, a route named "[Modulename]ToIoTHub" is added for each module. How can we disable this feature?
We tried to use an empty string but it's not allowed by the schema.

Announcing the Azure IoT Edge tool offerings in maintenance mode

As Azure IoT Edge product continues to evolve with new features and updated version to the LTS 1.4 (Long term service), one of our goals is to ensure we deliver consistent ways to develop, debug and test Azure IoT Edge modules on various version of Azure IoT Edge.

To best support the consistency across heterogenous developer environments and requirements, we have now published a new documentation which describes how to develop, debug and test Azure IoT Edge modules using command line interface.
This is a new recommended way to develop Azure IoT Edge modules.

With this new way, effective immediately, we are putting these product offering in maintenance mode where we are making minimum updates/changes to the products moving forward. Note that these products will continue to be available via either Marketplace or GitHub release pages.

These product are:
Azure IoT Edge extension to Visual Studio Code
Azure IoT Edge extension to Visual Studio 2019/2022
IoTEdgeHubDev tool
Azure DevOps pipeline for IoT Edge

thank you,
Azure IoT Edge team

Access Denied error when starting iotedgehubdev on VS2019

HI, I get access denied error when i try build azure iot edge module from VS 2019

1>DOCKER_CERT_PATH:
1>Additional Env Variables:
1>SimulatorPath: C:\Users\471231\Documents\Visual Studio 2019\iotedgehubdev\v0.13.0\iotedgehubdev
1>C:\Users\471231\Documents\Visual Studio 2019\iotedgehubdev\v0.13.0\iotedgehubdev start -d "C:\projects\poc\test-project\AzureIotEdgeApp1\obj\tmp_deployment_for_local_debug.json"
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\MSBuild\Microsoft\VisualStudio\v16.0\Azure IoT Edge Tools\AzureIoTEdgeProject.Build.targets(19,5): warning : One or more errors occurred.
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\MSBuild\Microsoft\VisualStudio\v16.0\Azure IoT Edge Tools\AzureIoTEdgeProject.Build.targets(19,5): error : Failed to exec task with error System.AggregateException: One or more errors occurred. ---> System.ComponentModel.Win32Exception: Access is denied

Please let me know what could be the issue ?

Cannot create a file when that file already exists when update iot edge simulator

repro on VS2019 v1.4.0-rc1

Update standalone simulator

  1. In the visual studio configuration folder, change version in the “simulator.config” to “v0.11.0”, and also change the extension version folder to “v0.11.0”

  2. Go to Visual Studio and click “Tools -> Azure IoT Edge Tools -> Update IoT Edge Simulator”

  3. After successfully updating the simulator, check the iotedgehubdev folder, verify the latest version has been installed and the config has been changed to the latest version

actually:
Azure IoT Edge Simulator enable debugging Azure IoT Edge modules and solutions locally without Edge runtime installed.
Start downloading and installing Azure IoT Edge simulator...
[ERROR]: Download and install Azure IoT Edge simulator failed, please click menu 'Tools -> Azure IoT Edge Tools -> Update IoT Edge simulator' to reinstall simulator and try again.
Cannot create a file when that file already exists.

Azure IoT Edge Simulator enable debugging Azure IoT Edge modules and solutions locally without Edge runtime installed.
Start downloading and installing Azure IoT Edge simulator...
[ERROR]: Download and install Azure IoT Edge simulator failed, please click menu 'Tools -> Azure IoT Edge Tools -> Update IoT Edge simulator' to reinstall simulator and try again.
The file 'C:\Users\iotedge\Documents\Visual Studio 2019\iotedgehubdev\iotedgehubdev\api-ms-win-core-console-l1-1-0.dll' already exists.

VS2022 Support?

Hi,

Is there any plans for this tool to be migrated over and to support VS 2022?

or is vs code more the future direction?

thanks,
~whiskers434

Default template should not include SimulatedTemperatureSensor

File->new project->Azure Iot Edge (Linux Amd 64)
Create the project without adding any modules (Skip)

Expected. The manifest should not contain any user modules
Observed. the manifest includes the SimulatedTemperatureSensor module,

        "modules": {
          "SimulatedTemperatureSensor": {
            "version": "1.0",
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-simulated-temperature-sensor:1.0",
              "createOptions": {}
            }
          }
        }

Note there is not gesture to remove that module

Azure IoT Edge Tools for VS 2022 is generating the tmp_deployment_for_local_debug.json file from deployment.template.json instead of deployment.debug.template.json

Problem statement:

Azure IoT Edge Tools for VS 2022 is using the deployment.template.json file for generating local debug json file.

Expected Behavior

Azure IoT Edge Tools for VS 2022 should use the deployment.debug.template.json for generating local debug json file,
while the deployment.template.json should be used for deployments to the devices.

Current Behavior

My deployment.template.json file has entries for mounting Linux file system for module storage for the edgeAgent and edgeHub modules.
The deployment.debug.template.json file doesn't have these bind mount entries as I do not expect to mount these storage folders during development.

However, as I am debugging using Visual Studio 2022 on Windows 10 machine, the debug process throws error

ERROR: for edgeHubDev Cannot create container for service edgeHubDev: invalid mount config for type "bind": bind source path does not exist: /var/iotedge/edgeHub

img

I have uploaded the sample code in the following repository for reference

https://github.com/miniGweek/azure-iot-edge-module-simple

deployment.template.json

{
  "$schema-template": "2.0.0",
  "modulesContent": {
    "$edgeAgent": {
      "properties.desired": {
        "schemaVersion": "1.1",
        "runtime": {
          "type": "docker",
          "settings": {
            "minDockerVersion": "v1.25",
            "loggingOptions": "",
            "registryCredentials": {}
          }
        },
        "systemModules": {
          "edgeAgent": {
            "type": "docker",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-agent:DEFAULT_RT_IMAGE",
              "createOptions": {
                "HostConfig": {
                  "Binds": [ "/var/iotedge/edgeAgent:/storage" ]
                }
              }
            },
            "env": {
              "storageFolder": {
                "value": "/storage"
              }
            }
          },
          "edgeHub": {
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-hub:DEFAULT_RT_IMAGE",
              "createOptions": {
                "HostConfig": {
                  "Binds": [ "/var/iotedge/edgeHub:/storage" ],
                  "PortBindings": {
                    "5671/tcp": [
                      {
                        "HostPort": "5671"
                      }
                    ],
                    "8883/tcp": [
                      {
                        "HostPort": "8883"
                      }
                    ],
                    "443/tcp": [
                      {
                        "HostPort": "443"
                      }
                    ]
                  }
                }
              }
            },
            "env": {
              "storageFolder": {
                "value": "/storage"
              }
            }
          }
        },
        "modules": {
          "IotEdgeModule1": {
            "version": "1.0.0",
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "${MODULEDIR<../IotEdgeModule1>}",
              "createOptions": {}
            }
          },
          "SimulatedTemperatureSensor": {
            "version": "1.0",
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-simulated-temperature-sensor:1.0",
              "createOptions": {}
            }
          }
        }
      }
    },
    "$edgeHub": {
      "properties.desired": {
        "schemaVersion": "1.2",
        "routes": {
          "IotEdgeModule1ToIoTHub": "FROM /messages/modules/IotEdgeModule1/outputs/* INTO $upstream",
          "sensorToIotEdgeModule1": "FROM /messages/modules/SimulatedTemperatureSensor/outputs/temperatureOutput INTO BrokeredEndpoint(\"/modules/IotEdgeModule1/inputs/input1\")"
        },
        "storeAndForwardConfiguration": {
          "timeToLiveSecs": 7200
        }
      }
    }
  }
}

deployment.debug.template.json

{
  "$schema-template": "2.0.0",
  "modulesContent": {
    "$edgeAgent": {
      "properties.desired": {
        "schemaVersion": "1.1",
        "runtime": {
          "type": "docker",
          "settings": {
            "minDockerVersion": "v1.25",
            "loggingOptions": "",
            "registryCredentials": {}
          }
        },
        "systemModules": {
          "edgeAgent": {
            "type": "docker",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-agent:DEFAULT_RT_IMAGE",
              "createOptions": {}
            }
          },
          "edgeHub": {
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-hub:DEFAULT_RT_IMAGE",
              "createOptions": {
                "HostConfig": {
                  "PortBindings": {
                    "5671/tcp": [
                      {
                        "HostPort": "5671"
                      }
                    ],
                    "8883/tcp": [
                      {
                        "HostPort": "8883"
                      }
                    ],
                    "443/tcp": [
                      {
                        "HostPort": "443"
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "modules": {
          "IotEdgeModule1": {
            "version": "1.0.0",
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "${MODULEDIR<../IotEdgeModule1>.debug}",
              "createOptions": {}
            }
          },
          "SimulatedTemperatureSensor": {
            "version": "1.0",
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-simulated-temperature-sensor:1.0",
              "createOptions": {}
            }
          }
        }
      }
    },
    "$edgeHub": {
      "properties.desired": {
        "schemaVersion": "1.2",
        "routes": {
          "IotEdgeModule1ToIoTHub": "FROM /messages/modules/IotEdgeModule1/outputs/* INTO $upstream",
          "sensorToIotEdgeModule1": "FROM /messages/modules/SimulatedTemperatureSensor/outputs/temperatureOutput INTO BrokeredEndpoint(\"/modules/IotEdgeModule1/inputs/input1\")"
        },
        "storeAndForwardConfiguration": {
          "timeToLiveSecs": 7200
        }
      }
    }
  }
}

The tmp_deployment_for_local_debug.json generated inside the obj folder

{
  "modulesContent": {
    "$edgeAgent": {
      "properties.desired": {
        "schemaVersion": "1.1",
        "runtime": {
          "type": "docker",
          "settings": {
            "minDockerVersion": "v1.25",
            "loggingOptions": "",
            "registryCredentials": {}
          }
        },
        "systemModules": {
          "edgeAgent": {
            "type": "docker",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-agent:1.2",
              "createOptions": "{\"HostConfig\":{\"Binds\":[\"/var/iotedge/edgeAgent:/storage\"]}}"
            },
            "env": {
              "storageFolder": {
                "value": "/storage"
              }
            }
          },
          "edgeHub": {
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-hub:1.2",
              "createOptions": "{\"HostConfig\":{\"Binds\":[\"/var/iotedge/edgeHub:/storage\"],\"PortBindings\":{\"5671/tcp\":[{\"HostPort\":\"5671\"}],\"8883/tcp\":[{\"HostPort\":\"8883\"}],\"443/tcp\":[{\"HostPort\":\"443\"}]}}}"
            },
            "env": {
              "storageFolder": {
                "value": "/storage"
              }
            }
          }
        },
        "modules": {
          "SimulatedTemperatureSensor": {
            "version": "1.0",
            "type": "docker",
            "status": "running",
            "restartPolicy": "always",
            "settings": {
              "image": "mcr.microsoft.com/azureiotedge-simulated-temperature-sensor:1.0",
              "createOptions": "{}"
            }
          }
        }
      }
    },
    "$edgeHub": {
      "properties.desired": {
        "schemaVersion": "1.2",
        "routes": {
          "IotEdgeModule1ToIoTHub": "FROM /messages/modules/IotEdgeModule1/outputs/* INTO $upstream",
          "sensorToIotEdgeModule1": "FROM /messages/modules/SimulatedTemperatureSensor/outputs/temperatureOutput INTO BrokeredEndpoint(\"/modules/IotEdgeModule1/inputs/input1\")"
        },
        "storeAndForwardConfiguration": {
          "timeToLiveSecs": 7200
        }
      }
    }
  }
}

Azure IoT Edge Tools for VS 2019 v1.9.0: Automatic edit of files each time the project is opened

Issue
Already before version 1.9.0 the .iotedgeproj file was marked as edited without any changes each time the project was opened.
Since version 1.9.0 also the sln file is marked as modified without any changes each time it is opened.
Since version 1.9.0 the deployment.template.json and deployment.debug.template.json files are edited each time the project is opened by replacing the version numbers of the azureiotedge-agent and the azureiotedge-hub images with DEFAULT_RT_IMAGE.

Proposal
It would save a lot of time for developers if this automatic edits could be omitted or at least disabled in the extensions settings.

Azure IoT Edge Tools for VS 2019 - Create new IoT Edge project with a C# module - Error

Hi,

I am trying to create an IoT Edge project but I get this error message:
image

Steps to reproduce the error:
1- Create new project
image
2-Fill the project name and select the location
3-Create
4-Add a C# Module
image

It looks like something went wrong when installing the extension/template. It seems the C# project for the Edge module (or one of the dependencies) is not found.

I have no more details (no logs, no additional information in the Output window, etc).

Configuration:

  • Windows 10 x64 Enterprise
  • Visual Studio 2019 Enterprise v16.3.9
  • Docker Desktop 2.1.0 (39773)

I have tried to uninstall/reinstall the extension with no success.

The same extension in another laptop works properly (the OS is different though, Windows 10 x64 Pro).

Any idea of what could be the issue?
Thanks in advance for your time.

Debugging disabled for .NET Core projects after installing plugin

After installing the extension version 1.1 on VS 2019, I cannot debug or start .NET Core projects anymore. The "Start Debugging" and "Start Without Debugging" options are grayed out in the Debug menu and when right-clicking on the project. .NET Framework console application works as expected.

If I disable the extension and restart Visual Studio, debugging works again.

IOT Edge tools break debugging

I installed the IOT Edge Tools in Visual Studio 2019, after which debugging gets broken. I can no longer debug regular Azure Function projects for instance. After disabling the extension (and stopping and starting Visual Studio again) debugging works again.

(I was able to reproduce this behavious several times)

Various inconsistencies related to targeted configuration and multiple modules

I noticed various inconsistencies while using Azure IoT Edge Tools:

  • the selected configuration (Release/Debug) is not taken into consideration at various levels
  • *.csproj-files of different modules are interfering with each other when building Docker images

My development-setup

  • VS 2019 (Enterprise) v16.9.3
  • Azure IoT Edge Tools for VS 2019 v1.7.0
  • Docker Desktop v3.2.2 (61853), Engine: 20.10.5
  • Windows Enterprise 10.0.19042 Build 19042

Steps to reproduce:

  1. Create a new project of type "Azure IoT Edge (Linux amd64)"
  2. Create a C# Module with default settings
  3. Add second IoT Edge Module to solution
  4. In both projects, add line with RUN echo $(ls) in files Dockerfile.amd64 and Dockerfile.amd64.debug right before RUN dotnet publish -c (...)
  5. Right-click on AzureIotEdgeApp1-item and run Build IoT Edge Modules
  6. IoT Hub Output shows the errors that occurred while processing the second module:
  • IotEdgeModule1.csproj is polluting the working directory
  • dotnet publish (...) doesn't know which project to publish
  1. Switch configuration to Release and right-click on AzureIotEdgeApp1-item, run Build IoT Edge Modules
  2. IoT Hub Output shows the errors that occurred:
  • Both ..csproj-files are present => same error as in (6.)
  • The Release-config is not honored since it's still publishing with RUN dotnet publish -c Debug
  1. The AzureIotEdgeApp1\config-subfolder contains the debug deployment manifest - the release version should be there instead.

Package with sample:
AzureIotEdgeApp1.zip

Please add support for IoT Edge Runtime 1.4 to the Azure IoT Edge Tools for VS 2022

Problem statement:

Microsoft has released azure IoT Edge Runtime v1.4 ( LTS ) https://github.com/Azure/azure-iotedge/releases/tag/1.4.1
Azure IoT Edge Tools for VS 2022 does not support debugging C# IoT Edge Modules using IoT Edge Runtime version 1.4

Expected Behavior

In Visual Studio 2022, when I right-click on the Edge module deployment project,
Select Set IoT Edge Runtime Version
Expect to see 1.4 as one of the IoT Edge Runtime version
After selecting this, I should be able to debug the C# IoT Edge Module.

Current Behavior

  1. Only IoT Edge Runtime version 1.0, 1.1 and 1.2 are available for selection.

img

  1. Also, if I manually set DEFAULT_RT_IMAGE=1.4 ( in the .env file ) it throws error.

img

Build Edge solution with Visual Studio 2019 BuildTools

How to install the extension on Visual Studio 2019 Build Tools?

Or what do I need to add to the project(s)? It seems the variable MSBuildToolsRoot is not set

error MSB4019: The imported project "C:\Microsoft\VisualStudio\v16.0\Azure IoT Edge Tools\AzureIoTEdgeProject.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.

Run IoT edge simulator fail when update DOCKER_HOST as npipe:////./pipe/iotedge_moby_engine

  1. set docker_host to npipe:////./pipe/iotedge_moby_engine
  2. create c# project and build and run IoT edge in simulator

Step 10/10 : ENTRYPOINT ["dotnet", "IotEdgeModuleCS.dll"]
 ---> Using cache
 ---> 03508c52f4d1
Successfully built 03508c52f4d1
Successfully tagged czgacr.azurecr.io/iotedgemodulecs:0.0.1-windows-amd64
C:\Users\iotedge\Documents\Visual Studio 2019\iotedgehubdev\v0.13.0\iotedgehubdev start -d "D:\AzureIotEdgeAppCSACR\AzureIotEdgeAppCSACR\config\deployment.windows-amd64.json" -v
WARNING! Using --password via the CLI is insecure. Use --password-stdin.
Login Succeeded
ERROR: Docker create failed for image: hello-world:latest : 500 Server Error: Internal Server Error ("Failed to unmarshall layerchain json - invalid character '\x00' looking for beginning of value")
[ERROR]: Failed to run 'iotedgehubdev start -d "D:\AzureIotEdgeAppCSACR\AzureIotEdgeAppCSACR\config\deployment.windows-amd64.json" -v' with error: WARNING! Using --password via the CLI is insecure. Use --password-stdin.
ERROR: Docker create failed for image: hello-world:latest : 500 Server Error: Internal Server Error ("Failed to unmarshall layerchain json - invalid character '\x00' looking for beginning of value") 

[ERROR]: WARNING! Using --password via the CLI is insecure. Use --password-stdin.
ERROR: Docker create failed for image: hello-world:latest : 500 Server Error: Internal Server Error ("Failed to unmarshall layerchain json - invalid character '\x00' looking for beginning of value")
3. stop IoT edge simulator

DOCKER_HOST: npipe:////./pipe/iotedge_moby_engine
DOCKER_TLS_VERIFY: 
DOCKER_CERT_PATH: 
Additional Env Variables: 
C:\Users\iotedge\Documents\Visual Studio 2019\iotedgehubdev\v0.13.0\iotedgehubdev stop
yaml.reader.ReaderError: unacceptable character #x0000: special characters are not allowed
  in "C:\ProgramData\iotedgehubdev\data\data\docker-compose.yml", position 0
ERROR: Error while executing command: docker-compose -f C:\ProgramData\iotedgehubdev\data\data\docker-compose.yml down. Command '['docker-compose', '-f', 'C:\\ProgramData\\iotedgehubdev\\data\\data\\docker-compose.yml', 'down']' returned non-zero exit status 1.
[ERROR]: Failed to run 'iotedgehubdev stop' with error: yaml.reader.ReaderError: unacceptable character #x0000: special characters are not allowed
  in "C:\ProgramData\iotedgehubdev\data\data\docker-compose.yml", position 0
ERROR: Error while executing command: docker-compose -f C:\ProgramData\iotedgehubdev\data\data\docker-compose.yml down. Command '['docker-compose', '-f', 'C:\\ProgramData\\iotedgehubdev\\data\\data\\docker-compose.yml', 'down']' returned non-zero exit status 1. 

Older Versions of Azure IoT Edge Tools Visual Studio Extensions

I'm wondering if it would be possible to access older versions of the Azure IoT Edge Tools Visual Studio extension. I noticed in the most recent update to v2.0.8 it restricted support to IoTEdge v1.4. We have some devices in the field that are still running 1.1 that we won't be able to upgrade to 1.4 until next year. I'd like to still be able to write and update modules for those in the meantime, but I can't do that with the latest version of Azure IoT Edge Tools. Is there any place I could get the older releases?

Azure Marketplace broken?

Environment
VS 2019 16.2.2
Azure IoT Tools for VS 2019 v 1.1

Project
C# module for windows AMD64

Error
When creating a new project, the wizard pops up to create the first module, Choosing show modules from Azure Marketplace displays the error "Cannot load module list from marketplace, please try again". Trying to add a new module to an existing project shows the same error when Azure Marketplace is selected.

Fiddler shows the API call is returning a Json payload with the marketplace details.

Modules in subfolders don't start when debugging IoT Edge project

Environment:
Windows 10 Pro, Version 1803, Build 17134.885
Microsoft Visual Studio Enterprise 2019 Version 16.2.2
Azure IoT Edge Tools for VS 2019 Version 1.1
iotedgehubdev Version 0.10.0

Issue:
When trying to debug an IoT Edge project, any module that is not in the root of the solution is not starting during the debug. This is only referring to the location of the project in the solution, the location of the project on disk is the same whether or not the module is in a subfolder or not.

Expected Behavior:
I would expect that every module that is part of the the IoT Edge project should be started regardless of its location. Also, I would expect an error anytime there is a module that is not starting when debugging the project.

Repro:

  1. Create an IotEdge solution with default parameters.
  2. Add a C# with default parameters
  3. Add a second C# with default parameters.
  4. Debug AzureIotEdgeApp1.
    That should debug the solution with the two modules both starting up:
    image
    Startup Logs:
======================Preparing IoT Edge Runtime======================
iotedgehubdev modulecred -l -m "IotEdgeModule1|IotEdgeModule2"
...
  1. Create a new folder in the solution.
  2. Drag IoTEdgeModule1 into the newly created folder.
  3. Debug AzureIotEdgeApp1.
    That will result in only IoTEdgeModule2 starting during debug.
    image
    Startup Logs:
======================Preparing IoT Edge Runtime======================
iotedgehubdev modulecred -l -m "IotEdgeModule2"
...

Problem remains: Unable to load the service index for source https://api.nuget.org/v3/index.json

I was hoping that this long-standing bug would be resolved in the new 2019 version. It is not. I started from scratch after a fresh reboot, newest VS2019preview and EdgeToolsExtension. Created a new edge project in VS2019. Below is the output from "Build IoT-Edge Modules". This problem has been around for months, with lots of guesswork solutions. Nobody seems to be able to get to the bottom of it. It needs to be fixed if we are to be able to use iot-edge with VisualStudio. In the meantime, no other option but back to Linux with iot-edge.

It appears that the docker build (windows) is being done inside a (windows) docker container that can't reach nuget, but what to change and where? Nobody seems to know...

---snip---
Setup IoT Edge Simulator successfully.
DOCKER_HOST:
DOCKER_TLS_VERIFY:
DOCKER_CERT_PATH:
Additional Env Variables:
------ Build IoT Edge Modules started: Platform: Windows Amd64, Configuration: Release ------
The deployment manifest is generated at C:\Users\tt\source\repos\P2\AzureIotEdgeApp3\AzureIotEdgeApp3\config\deployment.windows-amd64.json
docker inspect registry --format='{{.State.Running}}'
Error: No such object: registry
docker run -d -p 5000:5000 --restart always --name registry registry:2
Unable to find image 'registry:2' locally
2: Pulling from library/registry
docker: no matching manifest for windows/amd64 10.0.17763 in the manifest list entries.
See 'docker run --help'.
docker build --rm -f "C:\Users\tt\source\repos\P2\AzureIotEdgeApp3\IotEdgeModuleCs1\Dockerfile.windows-amd64" -t localhost:5000/iotedgemodulecs1:0.0.1-windows-amd64 "C:\Users\tt\source\repos\P2\AzureIotEdgeApp3\IotEdgeModuleCs1"
Sending build context to Docker daemon 690.2kB
Step 1/10 : FROM microsoft/dotnet:2.1-sdk AS build-env
---> b45d6ac11a2b
Step 2/10 : WORKDIR /app
---> Using cache
---> 614ab20fdc13
Step 3/10 : COPY *.csproj ./
---> 454642614a37
Step 4/10 : RUN dotnet restore
---> Running in 87190a7a2ca8
C:\Program Files\dotnet\sdk\2.1.603\NuGet.targets(119,5): error : Unable to load the service index for source https://api.nuget.org/v3/index.json. [C:\app\IotEdgeModuleCs1.csproj]
C:\Program Files\dotnet\sdk\2.1.603\NuGet.targets(119,5): error : No such host is known [C:\app\IotEdgeModuleCs1.csproj]
The command 'cmd /S /C dotnet restore' returned a non-zero code: 1
[ERROR]: The command 'cmd /S /C dotnet restore' returned a non-zero code: 1

ModuleNotFoundError: No module named 'pkg_resources.py2_warn'

Azure Iot Edge Tools : 1.7
Visual Studio Pro 2019 16.7.6

Received an update to Azure Iot Edge Tools Extension around 10/16/2020 : 10:30pm CST.

All calls to iotedgehubdev (c:\users<redacted>\Documents\Visual Studio 2019\iotedgehubdev\v0.14.2\iotedgehubdev.exe)
now throw python package errors.

[11852] Failed to execute script pyi_rth_pkgres Traceback (most recent call last): File "lib\site-packages\PyInstaller\loader\rthooks\pyi_rth_pkgres.py", line 11, in <module> File "d:\a\1\s\venv\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 627, in exec_module File "lib\site-packages\pkg_resources\__init__.py", line 86, in <module> ModuleNotFoundError: No module named 'pkg_resources.py2_warn' [ERROR]: Failed to run 'iotedgehubdev setup -c HostName=brasherfarm.azure-devices.net;DeviceId=localdev;SharedAccessKey=xwmGIKdhB+/00lUjxZG+eNl8po/VCuntkoz2xwrR4oA=' with error: [11852] Failed to execute script pyi_rth_pkgres Traceback (most recent call last): File "lib\site-packages\PyInstaller\loader\rthooks\pyi_rth_pkgres.py", line 11, in <module> File "d:\a\1\s\venv\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 627, in exec_module File "lib\site-packages\pkg_resources\__init__.py", line 86, in <module> ModuleNotFoundError: No module named 'pkg_resources.py2_warn'

I have verified the package py2_warn does exist in the same folder as init.py
Using pip install --upgrade iotedgehubdev (version: 0.11.1) works fine, but visual studio using the path to extension installed version(v0.14.2) fails.

Documentation out of date for maintenance

I am trying to understand the maintenance - so just to make sure as documentation doesn't seem right:

The link that you provided to use (https://learn.microsoft.com/en-us/azure/iot-edge/tutorial-develop-for-linux?view=iotedge-1.4&tabs=csharp&pivots=iotedge-dev-cli) is for VSCode CLI.

On that same site in the menu is steps to develop in Visual Studio using Dev tool cli: https://learn.microsoft.com/en-us/azure/iot-edge/how-to-visual-studio-develop-module?view=iotedge-1.4&pivots=iotedge-dev-cli however all the instructions talk about creating solution and modules using the plugin.

So are we supposed to do everything in VSCode now? or is that Visual Studio instructions out of date, or am I just misunderstanding this?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.