aws / aws-sdk-net

The official AWS SDK for .NET. For more information on the AWS SDK for .NET, see our web site:
http://aws.amazon.com/sdkfornet/
Apache License 2.0
2.06k stars 854 forks source link

Preview of the AWS Toolkit for Visual Studio 2017 #572

Closed normj closed 7 years ago

normj commented 7 years ago

Update: Toolkit Released

The GA version of AWS Toolkit for Visual Studio 2017 has been released to the Visual Studio Marketplace

Original Post

Today we released a preview of our AWS Toolkit for Visual Studio that includes support for the release candidate (RC) version of Visual Studio 2017. Because this Visual Studio release contains some significant changes for extension developers, we're making this preview available in advance of the formal release. We highly encourage you to pass along feedback about any issues you find or whether you were successful using the preview by commenting on this GitHub issue.

AWS Lambda .NET Core Support

Visual Studio 2017 also contains support for the new MSBuild project system for .NET Core projects. With this preview of the toolkit, we've updated the .NET Core Lambda support to use the new build system. For existing Lambda projects based on the Visual Studio 2015 project.json-based build system, Visual Studio 2017 offers to migrate them to the new build system when you open the projects.

Downloading and Installing the Preview

The AWS Toolkit for Visual Studio contains MSBuild target files for AWS CloudFormation projects. In previous releases of Visual Studio, you had to install these files and dependencies for an extension outside of the Visual Studio folder hierarchy. This required us to use a Windows Installer to install the toolkit. Starting with Visual Studio 2017, these MSBuild extensions exist within the Visual Studio folder hierarchy and can be installed from the VSIX extension package without an installer. As the installer technology we use doesn't yet support Visual Studio 2017, we've decided to distribute the preview as a VSIX file only.

To install the preview

After the installer finishes, the toolkit functions as it has in previous versions of Visual Studio.

yuribudilov commented 7 years ago

I have just installed this preview on the final RTM/RTW version of VS 2017. When I open the AWS Explorer I see everything BUT there is no Redshift.

PavelSafronov commented 7 years ago

@normj responded to this in a different issue:

Redshift is not a service we support inside the toolkit. You will need to use the Web Console or the SDK/CLI to manage Redshift.

readf commented 7 years ago

I am having trouble deploying my newly created netcore 1.0 app to Elastic Beanstalk using the AWS toolkit. It worked great in VS2015, but in 2017, the deployed application will not start. I found another person reporting the same issue on Stack Overflow here: http://stackoverflow.com/questions/42684640/sample-net-core-projects-no-longer-deploy-to-elastic-beanstalk-with-vs2017#

betimd commented 7 years ago

+1

betimd commented 7 years ago

It seems @normj is informed about this issue. We discussed this in a twitter message as well https://twitter.com/socketnorm/status/840340094242365440

readf commented 7 years ago

Oh, that is great to hear! I will stand by. @normj let me know if I can help at all!

normj commented 7 years ago

I pushed up a new build that will now include netcoreapp1.1 in the frameworks dialog box during deployment if you project is targeting .NET Core 1.1.

https://sdk-for-net.amazonwebservices.com/preview/AWSToolkitPackage.VS2017.vsix

There is another gotcha that you need to be aware. With the new GA tooling of .NET Core it implicitly adds a dependency on the latest patch version of the framework for your target framework. So if you are targeting .NET Core 1.0 it implicitly adds dependency to 1.0.4 and if you target .NET Core 1.1 it adds a dependency to 1.1.1 which both came out last week and the beanstalk AMI haven't been updated yet.

The beanstalk AMI will get updated once the Beanstalk team finishes their testing and verification but till then you need override the implicit dependency in your project. To do that edit your csproj file and add the following element in your PropertyGroup section where the target framework is specified.

For .NET Core 1.0

<RuntimeFrameworkVersion>1.0.3</RuntimeFrameworkVersion>

For .NET Core 1.1

<RuntimeFrameworkVersion>1.1.0</RuntimeFrameworkVersion>

Full example for context:

<Project Sdk="Microsoft.NET.Sdk.Web">

  <PropertyGroup>
    <TargetFramework>netcoreapp1.1</TargetFramework>
    <RuntimeFrameworkVersion>1.1.0</RuntimeFrameworkVersion>
  </PropertyGroup>

  ...

</Project>

We are looking into how we can improve this situation when new .NET Core patches versions are released.

betimd commented 7 years ago

My project is in .Net Core 1.0 and I corrected from 1.0.4 to 1.0.3 runtime version but still didn't work. Just to give you a picture, I reference two other projects, .Net Core class libraries with target framework netstandard1.6. Do I have to add runtime version to class libraries as well?

normj commented 7 years ago

Interesting. Another one of the quirks with the new .NET Core tooling is .NET Standard class libraries will implicitly pull in the NETStandard.Lbrary 1.6.1 meta NuGet package which is the .NET Core 1.1 implementation of the NET Standard. So in your case you have a .NET Core 1.0 application pulling in .NET Core 1.1 dependencies.

In your csproj for your class libraries add the following xml element in your PropertyGroup to force it to use the NETStandard.Library NuGet package 1.6.0 which is the .NET Core 1.0 implementation of the standard.

<NetStandardImplicitPackageVersion>1.6.0</NetStandardImplicitPackageVersion>
Kralizek commented 7 years ago

It really bothers me that a patch version change (from 1.6 to 1.6.1) changes which runtime is loaded. Also, since they put so much emphasis on LTS vs Current, they should find a way to lock yourself into one of these channels.

I understand not being able to run the latest bits of EF Core if I am using LTS, but I should be prohibited to even pull those bits.

normj commented 7 years ago

Yeap, I'm very disappointed by the over simplification done to the .NET Core projects system with these implicit project dependencies.

I added my feedback to the GitHub issue that added some of this behavior

https://github.com/dotnet/sdk/issues/860#issuecomment-286252275

Which caused another GitHub issue to be open up about this

https://github.com/dotnet/sdk/issues/983

I encourage others to add their feedback.

betimd commented 7 years ago

So interesting. I checked all csprojs they're forcing 1.6.0 NETStandard.Library NuGet package. I'm lost now. I don't have any idea what to check more. I'm attaching here deps.json & runtimeconfig.json of the published app to see if you're noticing anything I'm missing. TS.ApiIntegration.zip

Another logical question would be, how can I simulate a publish in local environment and find which proj / lib is referencing what implementation?

normj commented 7 years ago

One thing I see in your deps.json file is you have a reference to mandrill.net which has a dependency on 3 System packages of version 4.3.0

https://www.nuget.org/packages/mandrill.net/

The 4.3.0 line of System NuGet packages are part of .NET Core 1.1. So you have a mix of .NET Core 1.0 and 1.1 packages targeting the .NET Core 1.0 runtime.

betimd commented 7 years ago

All system packages of version 4.3.0 are in .NET Core 1.1?

normj commented 7 years ago

Version 1.6.1 of NETStandard.Library is for .NET Core 1.1 and you can see it references the 4.3.0 versions of the System packages

https://www.nuget.org/packages/NETStandard.Library/1.6.1

The 1.6.0 version which is for .NET Core 1.0 has references versions all below 4.3.0

https://www.nuget.org/packages/NETStandard.Library/1.6.0

betimd commented 7 years ago

Hmm how do I know in this "messy environment" now which is targeting 1.1 and which is 1.0? I see it sounds more a question to direct to .Net team but, I'm doing here while I just want to have my new version of the app published in elastic beanstalk.

betimd commented 7 years ago

Or is there any way to force specific version of the library, ex. Newtonsoft.Json 9. and 10. are working with System.Collections (>= 4.0.11), but I see in their dependencies in solution explorer they're referencing System.Collections (>= 4.3.0)?

normj commented 7 years ago

I think the problem is that mandrill.net dependency requires 4.3.0 so that makes all the other dependency bump up to 4.3.0. There might be others you have that are requiring 4.3.0. That was first I saw when I compare your dependency to the list required dependency on NuGet.org.

I am surprised the .NET Core packaging system doesn't give warnings for the mismatch in dependency and target framework.

betimd commented 7 years ago

First, I'm surprised that till now I updated ElasticBeanstalk, and I have no idea how it worked. Clearly remember I haven't updated the app. And I publish through publish tools in vs clearly targeting netcore1.0 and I have no warning or type of error. So bad!

Though, how can I make a workaround for this issue? Clearly I cannot wait for EB team to do the updates (unless they will come tomorrow)?

normj commented 7 years ago

As far as I can tell this issue has nothing to with EB but a mismatch of .NET Core 1.0 and .NET Core 1.1 libraries running on the .NET Core 1.0. EB does have .NET Core 1.1 installed and you can target hat framework. The thing missing on EB right now is it doesn't have version 1.1.1.

Are you still getting the process failed exception? You might get more information try the following.

betimd commented 7 years ago

Yes, still getting HTTP Error 502.5 - Process Failure. Can I update the EC2 instance that environment is referencing manually? Install there .Net 1.1. Or this is a bad idea?

jwcarroll commented 7 years ago

@normj - First off, thanks for all your work as it was a great help in resolving an issue I had earlier.

I have a question, but if it is the wrong forum feel free to redirect me.

I love the AWS tools, but would love to know how to do this manually using the EB CLI (or some other mechanism), but I couldn't quite figure out if/how that was possible. If nothing else it would be awesome if there was a verbose setting for the AWS tools so I could see exactly what it was doing.

Is it really just creating an archive after doing a dotnet publish, and then deploying that? Or are there also some environment variables and parameters being passed in?

betimd commented 7 years ago

@normj is there a difference between 1.0.3 and 1.0.4 for EB? If I put in <RuntimeFrameworkVersion>1.0.4</RuntimeFrameworkVersion> it shouldn't work, right?

betimd commented 7 years ago

Right now I do not see anything that's in .net core 1.1. I attached deps.json as well just for your curiosity TS-API.deps.json.txt.

normj commented 7 years ago

@betimd Did you ever log on to the instance and manually run dotnet like I suggested before? What did it tell you. Setting <RuntimeFrameworkVersion>1.0.4</RuntimeFrameworkVersion> won't work right now on EB. There is nothing in 1.0.4 that would affect applications running on EB. If you look at the release notes you can see it contains 2 fixes, one for debuggers and another to fix an issue on Macs. https://github.com/dotnet/core/blob/master/release-notes/1.0/1.0.4.md

normj commented 7 years ago

@jwcarroll .NET Core apps are published to beanstalk by zipping up the pubilsh folder and zipping up the folder with a beanstalk manifest. This blog post talks about how deploy multiple applications with the manifest. It also has a lot of detail on deploying from the command line. https://aws.amazon.com/blogs/developer/multiple-application-support-for-net-and-elastic-beanstalk/

betimd commented 7 years ago

Yes I did, this is the message I'm getting from CMD.

The specified framework 'Microsoft.NETCore.App', version '1.0.3' was not found.

When I access the app I'm getting HTTP Error 502.5 - Process Failure.

betimd commented 7 years ago

I finally resolved all conflicts and issues. Just as a feedback for others who might run in same troubles as I was. When you move to VS 2017, beyond converting just to project file (from json to csproj), it will try to upgrade your referenced libraries as well, and from that point everything stops working. But best part is that VS will create a backup with your original (old) files so, you can just compare side by side you json with csproj references, stick to versions that worked and continue working with VS2017.

AaronLangley commented 7 years ago

I had a bug in my web.config (repeated section) and kept republishing using the toolkit but it kept installing the old version and failing. But it was weird because when I checked the uploaded application zip it was the new web.config. Rebuilding the environment didn't fix it, however once I deleted Package directory and published again it worked..?

markereddick commented 7 years ago

Would you be able to add the ability to set the version "description" when publishing? We can set the label but I like to add information about what changed in the "description" field.

brunotag commented 7 years ago

AWS Explorer:

http://stackoverflow.com/questions/43059324/why-aws-explorer-for-vs2017-doesnt-want-session-profile-types

Can't use "ProfileType" : "Session" credentials anymore, is it intentional? If that's the case, is there any other way to get AWS Explorer impersonate a role and support Mfa?

damianh commented 7 years ago

Similar to @brunotag's request, for a profile I'd like to be able to specify a credential file and a profile from within it.

(I use this tool to generate the credential file: https://github.com/damianh/aws-adfs-credential-generator )

magudb commented 7 years ago

Installation fails It seems to be a problem when Build Tools are installed, I haven't quite figured out a workaround for this issue or found the solution elsewhere.

04-04-2017 10:49:22 - Found installed product - Microsoft Visual Studio 2010 Premium
04-04-2017 10:49:22 - Found installed product - Global Location
04-04-2017 10:49:22 - Found installed product - Visual Studio Build Tools 2017 (2)
04-04-2017 10:49:22 - System.IO.FileNotFoundException: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\
   at System.Diagnostics.FileVersionInfo.GetVersionInfo(String fileName)
   at VSIXInstaller.SupportedVSSKU.get_VersionWithBuildRevisionInfo()
   at VSIXInstaller.App.IsValidSKUForExtension(SupportedVSSKU supportedSKU, IExtension extension, List`1 validSKUs)
   at VSIXInstaller.App.ShouldAddSkuToValidSkuList(SupportedVSSKU sku, IInstallableExtension extension, List`1 validSKUs)
   at VSIXInstaller.App.GetInstallableData(String vsixPath, Boolean isRepairSupported, IEnumerable`1& skuData)
   at VSIXInstaller.App.Initialize(Boolean isRepairSupported)
   at VSIXInstaller.App.Initialize()
   at System.Threading.Tasks.Task`1.InnerInvoke()
   at System.Threading.Tasks.Task.Execute()

Reflecting on the VSIXInstaller it seems to be here the problem is

public virtual string AppIDPath
    {
      get
      {
        using (RegistryKey registryKey = Registry.LocalMachine.OpenSubKey(this.SKURegistryRoot))
        {
          if (registryKey == null)
            return this.AppIDExecutableName;
          string path1 = registryKey.GetValue("InstallDir") as string;
          if (path1 == null)
            return (string) null;
          return Path.Combine(path1, this.AppIDExecutableName);
        }
      }
    }
stevejroberts commented 7 years ago

Reproduced, but no idea as to the actual problem yet and the error message isn't exactly helpful - the folder exists, but what file can't be found?! The toolkit itself has no dependency on the build tools.

panodk commented 7 years ago

I'm not sure why but install does not detect my install of VS2017 Enterprise. It seems to be only looking for VS2017 Community Edition? The funny thing is it installed on my laptop just fine a few days earlier. The only difference I can think of is my desktop version had the "26228.12" released on March 31, 2017 prior to installing AWS Toolkit for Visual Studio 2017.

image

4/4/2017 5:12:05 PM - -------------------------------------------
4/4/2017 5:12:05 PM - Initializing Install...
4/4/2017 5:12:06 PM - Extension Details...
4/4/2017 5:12:06 PM -   Identifier         : 12ed248b-6d4a-47eb-be9e-8eabea0ff119
4/4/2017 5:12:06 PM -   Name               : AWS Toolkit for Visual Studio 2017
4/4/2017 5:12:06 PM -   Author             : Amazon Web Services LLC
4/4/2017 5:12:06 PM -   Version            : 1.12.0.1
4/4/2017 5:12:06 PM -   Description        : The AWS Toolkit for Visual Studio is an extension for Microsoft Visual Studio that makes it easier for developers to develop, debug, and deploy .NET applications using Amazon Web Services. With the AWS Toolkit for Visual Studio, you'll be able to get started faster and be more productive when building AWS applications.
4/4/2017 5:12:06 PM -   Locale             : en-US
4/4/2017 5:12:06 PM -   MoreInfoURL        : http://aws.amazon.com/sdkfornet
4/4/2017 5:12:06 PM -   InstalledByMSI     : False
4/4/2017 5:12:06 PM -   SupportedFrameworkVersionRange : [4.6,)
4/4/2017 5:12:06 PM - 
4/4/2017 5:12:06 PM -   SignatureState     : ValidSignature
4/4/2017 5:12:06 PM -   SignedBy           : Amazon.com, Inc.
4/4/2017 5:12:06 PM -   Certificate Info   : 
4/4/2017 5:12:06 PM -       -------------------------------------------------------
4/4/2017 5:12:06 PM -       [Subject]       : CN="Amazon.com, Inc.", OU=Amazon Web Services, O="Amazon.com, Inc.", L=Seattle, S=Washington, C=US
4/4/2017 5:12:06 PM -       [Issuer]        : CN=Symantec Class 3 SHA256 Code Signing CA, OU=Symantec Trust Network, O=Symantec Corporation, C=US
4/4/2017 5:12:06 PM -       [Serial Number] : 221F14F6E28EA1ABD010EA24DA1BBA0B
4/4/2017 5:12:06 PM -       [Not Before]    : 6/21/2016 7:00:00 PM
4/4/2017 5:12:06 PM -       [Not After]     : 6/18/2017 6:59:59 PM
4/4/2017 5:12:06 PM -       [Thumbprint]    : 695BF9422F01FFEEC9187B1FD688185A1B299CAE
4/4/2017 5:12:06 PM - 
4/4/2017 5:12:06 PM -   Supported Products : 
4/4/2017 5:12:06 PM -       Microsoft.VisualStudio.Community
4/4/2017 5:12:06 PM -           Version : [15.0,)
4/4/2017 5:12:06 PM - 
4/4/2017 5:12:06 PM -   References         : 
4/4/2017 5:12:06 PM -       -------------------------------------------------------
4/4/2017 5:12:06 PM -       Identifier   : Microsoft.VisualStudio.MPF.11.0
4/4/2017 5:12:06 PM -       Name         : Visual Studio MPF 11.0
4/4/2017 5:12:06 PM -       Version      : [11.0]
4/4/2017 5:12:06 PM -       MoreInfoURL  : 
4/4/2017 5:12:06 PM -       Nested       : No
4/4/2017 5:12:06 PM - 
4/4/2017 5:12:06 PM - Signature Details...
4/4/2017 5:12:06 PM -   Extension is signed with a valid signature.
4/4/2017 5:12:06 PM - 
4/4/2017 5:12:06 PM - Searching for applicable products...
4/4/2017 5:12:08 PM - Found installed product - Microsoft Visual Studio 2010 Shell - Integrated Mode
4/4/2017 5:12:08 PM - Found installed product - Microsoft Visual Studio Professional 2013
4/4/2017 5:12:08 PM - Found installed product - Microsoft Visual Studio 2013 Shell (Integrated)
4/4/2017 5:12:08 PM - Found installed product - Microsoft Visual Studio Enterprise 2015
4/4/2017 5:12:08 PM - Found installed product - Microsoft Visual Studio Professional 2015
4/4/2017 5:12:08 PM - Found installed product - Microsoft Visual Studio Community 2015
4/4/2017 5:12:08 PM - Found installed product - Microsoft Visual Studio 2015 Shell (Integrated)
4/4/2017 5:12:08 PM - Found installed product - Global Location
4/4/2017 5:12:08 PM - Found installed product - ssms
4/4/2017 5:12:08 PM - VSIXInstaller.NoApplicableSKUsException: This extension is not installable on any currently installed products.
   at VSIXInstaller.App.InitializeInstall(Boolean isRepairSupported)
   at VSIXInstaller.App.InitializeInstall()
   at System.Threading.Tasks.Task.InnerInvoke()
   at System.Threading.Tasks.Task.Execute()
brunotag commented 7 years ago

@panodk I had a similar issue with VS 2017 RC: I uninstalled it some days before I tried to install the add-in but there were some bits and pieces left in the registry. And the installer of the add-in was detecting them, trying to install the add-in for VS 2017 RC and failing miserably because VS 2017 RC wasn't there. To solve the issue, I had to hunt for keys related with VS 2017 RC (don't remember the build number) and delete them manually. This link might help.

panodk commented 7 years ago

Thanks for the suggestion @brunotag, but I was able to get it to work after recalling that I too had MSBuild Tool for 2017 installed. Once uninstalled the SDK installed without any problems.

stevejroberts commented 7 years ago

I ran an install on a system that had VS2017 Community, Professional and Enterprise editions installed and the vsix package installed cleanly on all three. Uninstalled the toolkit (again, cleanly) and installed the build tools sku. Install of the toolkit then failed with the logged error (by the way, the (2) shown against the sku in the log is the nickname of the install, which by default is a number but can be customized).

I'll follow this up on Microsoft's vsix forums to see if we can get more clarity on what might be causing the failure report from the vsix installer tool.

brendonwm commented 7 years ago

Working nicely so far for my DynamoDB stuff - including running running it locally. Thanks!

stevejroberts commented 7 years ago

FYI, we're continuing to ship updates to the preview package with bug fixes and other enhancements. The latest version is 1.12.0.8, published a few moments ago, to fix an issue (also reported on GitHub) with opening SQS Queue views from the Explorer.

austindimmer commented 7 years ago

Hi these tools are great thanks. I have an infuriating issue that when I try to right click and deploy the tool freezes my Visual Studio. This has been happening on both the RTM version for VS2105 and this pre release version for 2017. I will be happy to get to the root of this problem since I really need this tool to work for me without fail. I am losing quite some time due to this. Please let me know any logs or debugging steps you may need me to take.

MrZoidberg commented 7 years ago

It looks like that build .NET Core Lambda under Parallels Desktop virtualization doesn't work:

Executing publish command
... invoking 'dotnet publish', working folder '\\Mac\Home\Documents\code\jrt\JrtPrototype\jrt.Lambda.ProcessJiraWebhooks\bin\Release\netcoreapp1.0\publish'
... publish: Microsoft (R) Build Engine version 15.1.1012.6693
... publish: Copyright (C) Microsoft Corporation. All rights reserved.
... publish: CSC : error CS2001: Source file 'C:\Windows\TimeZoneHelper.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Utils\Jrt.Utils.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\WorklogReminderMailSenderTask.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Utils\Jrt.Utils.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\obj\Release\netstandard1.6\Jrt.Utils.AssemblyInfo.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Utils\Jrt.Utils.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\DateTimeDayOfMonthExtensions.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Utils\Jrt.Utils.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\MailSenderTask.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Utils\Jrt.Utils.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\AppConfig.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Utils\Jrt.Utils.csproj]
... publish: C:\Program Files\dotnet\sdk\1.0.4\Sdks\Microsoft.NET.Sdk\build\Microsoft.NET.Sdk.targets(92,5): error : Cannot find project info for '\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Utils\Jrt.Utils.csproj'. This can indicate a missing project reference. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Amazon\Jrt.Amazon.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\obj\Release\netstandard1.6\Jrt.Data.Mongo.AssemblyInfo.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\IEntity.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\Attributes\CollectionName.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\Attributes\ConnectionNameAttribute.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\Entity.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\Database.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\IRepository.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\Repository.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj]
... publish: C:\Program Files\dotnet\sdk\1.0.4\Sdks\Microsoft.NET.Sdk\build\Microsoft.NET.Sdk.targets(92,5): error : Cannot find project info for '\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data.Mongo\Jrt.Data.Mongo.csproj'. This can indicate a missing project reference. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data\Jrt.Data.csproj]
... publish: C:\Program Files\dotnet\sdk\1.0.4\Microsoft.Common.CurrentVersion.targets(1964,5): warning MSB3277: Found conflicts between different versions of the same dependent assembly that could not be resolved.  These reference conflicts are listed in the build log when log verbosity is set to detailed. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Log\Jrt.Log.csproj]
... publish: C:\Program Files\dotnet\sdk\1.0.4\Sdks\Microsoft.NET.Sdk\build\Microsoft.NET.Sdk.targets(92,5): error : Cannot find project info for '\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Data\Jrt.Data.csproj'. This can indicate a missing project reference. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Jira\Jrt.Jira.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\LoggingModule.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Log\Jrt.Log.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\obj\Release\netstandard1.6\Jrt.Log.AssemblyInfo.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Log\Jrt.Log.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\GenericLambdaFunctionBase.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Lambda.Core\Jrt.Lambda.Core.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\SnsEventFunctionBase.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Lambda.Core\Jrt.Lambda.Core.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\obj\Release\netstandard1.6\Jrt.Lambda.Core.AssemblyInfo.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Lambda.Core\Jrt.Lambda.Core.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\VoidLambdaFunctionBase.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Lambda.Core\Jrt.Lambda.Core.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\LambdaRequest.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Lambda.Core\Jrt.Lambda.Core.csproj]
... publish: CSC : error CS2001: Source file 'C:\Windows\LambdaResponse.cs' could not be found. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Lambda.Core\Jrt.Lambda.Core.csproj]
... publish: C:\Program Files\dotnet\sdk\1.0.4\Sdks\Microsoft.NET.Sdk\build\Microsoft.NET.Sdk.targets(92,5): error : Cannot find project info for '\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Amazon\Jrt.Amazon.csproj'. This can indicate a missing project reference. [\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Bl\Jrt.Bl.csproj]
... publish: C:\Program Files\dotnet\sdk\1.0.4\Sdks\Microsoft.NET.Sdk\build\Microsoft.NET.Sdk.targets(92,5): error : Cannot find project info for '\\Mac\Home\Documents\code\jrt\JrtPrototype\Jrt.Amazon\Jrt.Amazon.csproj'. This can indicate a missing project reference. [\\Mac\Home\Documents\code\jrt\JrtPrototype\jrt.Lambda.ProcessJiraWebhooks\jrt.Lambda.ProcessJiraWebhooks.csproj]

My configuration: Visual Studio Community Edition 15.2 Preview of the AWS Toolkit for Visual Studio 2017 Parallels Desktop 12.2

stevejroberts commented 7 years ago

systemsymbiosis - sorry to hear you are hitting problems. The toolkit does emit some logs and it would be worth checking them to see if there are any error messages related to Lambda getting written when the deployment wizard starts, to help us narrow down where to look to get you up and running.

The log location is under C:\Users\your-user-id\AppData\Local\AWSToolkit\logs.

austindimmer commented 7 years ago

OK Thanks I will keep an eye out for this next time it hits and post logs here.

KyleF-Monsanto commented 7 years ago

We use a hub and spoke approach, so switching roles is critical to access AWS capabilities. The account I use has no access to AWS, but has access to switch to roles that do.

Could specifying a role ARN be enabled?

normj commented 7 years ago

@KyleF-Monsanto Are you talking about using assume role to get your credentials? If so you can configure that in the shared credentials file that the AWS cli uses and the toolkit will pick that up. Here are some docs on how to configure that in the shared credentials file.

KyleF-Monsanto commented 7 years ago

Thanks for your initial guidance. I think I found the documents you referenced: http://docs.aws.amazon.com/cli/latest/userguide/cli-roles.html

I installed the AWS CLI, since I was only using nuget and the visual studio 2017 SDK.

I used the CLI to create the user, and then edited the credentials file.

[sandbox-user] aws_access_key_id = XXXX aws_secret_access_key = YYYY role_arn = arn:aws:iam::AAAAAA:role/RRRRRRR mfa_serial = arn:aws:iam::BBBBBBBBBBB:mfa/UUUUU

When I changed the aws-lambda-tools-defaults.json file, it seemed to take the new profile name, but the new profile created with the CLI is not available within the AWS Explorer within Visual Studio.

normj commented 7 years ago

The toolkit is skipping it because we don't yet support profiles with MFA. It is definitely something we want to get done in the toolkit.

austindimmer commented 7 years ago

My colleague just experienced the same issue here is the log file from his workstation. log.txt

stevejroberts commented 7 years ago

@systemsymbiosis, thanks for the log. Unfortunately it doesn't contain anything I can see pointing to the root cause.

You say the tool locks up Visual Studio - (1) does the lock up occur between right-clicking the mouse on the project and the context menu appearing, or after selecting the Publish to Lambda menu option and the deployment wizard appearing? Or sometime during use of the wizard? (2) are you able to use the Lamba node in the AWS Explorer to view functions etc (trying to establish if its a credential issue) (3) what region is your AWS Explorer set to when you try to deploy? (trying to establish if the tools are trying to hit a non-existent endpoint and taking excessive time to timeout)