assemblies not being included when deploying Azure webjobs - azure

I have 3 files
MyWebJob.exe
MyClassLibraryProject.dll
3rdPartyLib.dll (vc++)
I zipped them and uploded it to web job, but I got error below.
Unhandled Exception: System.IO.FileNotFoundException: Could not load file or assembly 'MyClassLibraryProject.dll' or one of its dependencies. The specified module could not be found.
How to fix it , thanks!

Related

Attempt to publish the ZIP file through https://xxx.scm.azurewebsites.net/api/zipdeploy failed with HTTP status code Forbidden

I'm getting this error window message while trying to deploy a .NET 6 Azure Functions app to Azure from Visual Studio 2022:
Publish has encountered an error. We
were unable to determine the cause of the error. Check the output log
for more details.
A diagnostic log has been written to the following location:
"C:\Users\MyUserName\AppData\Local\Temp\tmpEB87.tmp"
The tmpEB87.tmp file contents look like this:
2/16/2022 1:43:18 PM
System.AggregateException: One or more errors occurred. ---> Microsoft.WebTools.Shared.Exceptions.WebToolsException: Publish has encountered an error. We were unable to determine the cause of the error. Check the output log for more details.
--- End of inner exception stack trace ---
---> (Inner Exception #0) Microsoft.WebTools.Shared.Exceptions.WebToolsException: Publish has encountered an error. We were unable to determine the cause of the error. Check the output log for more details. <---
Microsoft.WebTools.Shared.Exceptions.WebToolsException: Publish has encountered an error. We were unable to determine the cause of the error. Check the output log for more details.
===================
The Output log says this:
The attempt to publish the ZIP file through
https://xxx.scm.azurewebsites.net/api/zipdeploy failed with HTTP
status code Forbidden.
The MyFunctionName - Zip Deploy.pubxml file contents looks like this:
<?xml version="1.0" encoding="utf-8"?>
<!--
https://go.microsoft.com/fwlink/?LinkID=208121.
-->
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<WebPublishMethod>ZipDeploy</WebPublishMethod>
<PublishProvider>AzureWebSite</PublishProvider>
<LastUsedBuildConfiguration>Release</LastUsedBuildConfiguration>
<LastUsedPlatform>Any CPU</LastUsedPlatform>
<SiteUrlToLaunchAfterPublish>https://xxx.azurewebsites.net</SiteUrlToLaunchAfterPublish>
<LaunchSiteAfterPublish>False</LaunchSiteAfterPublish>
<ResourceId>/subscriptions/some-random-letters-123456789/resourceGroups/my-resource-group-name/providers/Microsoft.Web/sites/MyFunctionName</ResourceId>
<UserName>$MyFunctionName</UserName>
<_SavePWD>True</_SavePWD>
<IsLinux>true</IsLinux>
<PublishUrl>https://xxx.scm.azurewebsites.net/</PublishUrl>
</PropertyGroup>
</Project>
I've already spent a ton of time on this, so any help is appreciated.
One of the workarounds that you can try is to create a new Publish profile and publish it again. For this navigate to Your project's directory -> Properties -> Publish Profiles and delete the contents (or you can move to another location). Finally, click Finish in the publish profile wizard again.
Make sure WEBSITE_RUN_FROM_PACKAGE is 1 from your Application settings. Also, try restarting your function app.
NOTE:- When deploying from Visual Studio, you should be asked whether you want to upgrade the version of the app that is currently deployed. If you say yes, your app will be deployed.

Failed to generate iOS ipa file

I followed the instruction here:
Deploying Your iOS Application for Submission to the App Store
Failed when Step 4:
Select Project > Deployment, and click the Deploy button to deploy your application.
It is suppose to generate an .ipa file, but I got the following error messages:
paclient command line for "Dell_Macbook_Air"
c:\program files (x86)\embarcadero\studio\21.0\bin\paclient.exe -u8 --ipa="ESF RC1.app,ESF RC1.ipa,'Apple Distribution: Courant Tseng
(LB289US7N2)','/Users/Courant/Library/MobileDevice/Provisioning Profiles/49871f08-e3ef-4ef6-9cef-2756304c93c1.mobileprovision',2" Dell_Macbook_Air
[PAClient Error] Error: E0776 2021-10-12 17:18:30.006 xcodebuild[1464:20952] [MT] IDEDistribution: -[IDEDistributionLogging _createLoggingBundleAtPath:]: Created bundle at path '/var/folders/wm/8hg70w3n355g3qsc5k9z34hh0000gn/T/ESF RC1_2021-10-12_17-18-30.002.xcdistributionlogs'.
[PAClient Error] Error: E0776 Exported ESF RC1 to: /Users/Courant/PAServer/scratch-dir/Courant-Dell_Macbook_Air/ESF RC1.archive/temp
[PAClient Error] Error: E0776 ** EXPORT SUCCEEDED **
Failed
Can anyone give some advise to solve the problem so that I can send it to App Store (Testflight)?
Got answer from Embarcadero Customer Support Center.
This "error" is connected with the CFBundleName/CFBundleDisplayName. If these parameters in the project's project option contains space characters, this error will occur.
I removed the spcace character off mu app name (ESF RC1--> ESF_RC1)
It works.
BTW, according to them, the bug had been fixed in Rad Studio 11.

Azure app service continuous deployment failure

I have an Azure App Service with two deployment slots, prod and dev. I have continuous deployment configured from VSTS set up to the dev slot and it's been working fine for months but all of a sudden it fails when running the deployment command step. This is the log for that step.
Installed:
81 package(s) to packages.config projects
D:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.CurrentVersion.targets(133,9): warning MSB3884: Could not find rule set file "ManagedMinimumRules.ruleset". [D:\home\site\repository\VendorPortalSite\VendorPortalSite.csproj]
Services\Data\UserRepository.cs(303,30): warning CS0168: The variable 'e' is declared but never used [D:\home\site\repository\VendorPortalSite\VendorPortalSite.csproj]
VendorPortalSite -> D:\home\site\repository\VendorPortalSite\bin\VendorPortalSite.dll
D:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.CurrentVersion.targets(133,9): warning MSB3884: Could not find rule set file "ManagedMinimumRules.ruleset". [D:\home\site\repository\VendorPortalSite\VendorPortalSite.csproj]
VendorPortalSite -> D:\home\site\repository\VendorPortalSite\bin\VendorPortalSite.dll
D:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.CurrentVersion.targets(133,9): warning MSB3884: Could not find rule set file "ManagedMinimumRules.ruleset". [D:\home\site\repository\VendorPortal\VendorPortal.csproj]
VendorPortal -> D:\home\site\repository\VendorPortal\bin\Release\VendorPortal.exe
D:\home\site\repository\packages\Microsoft.Web.WebJobs.Publish.1.0.12\tools\webjobs.wap.targets(151,5): warning : WebJob schedule for NotifyTeacher will not be created. WebJob schedules can only be created when the publish destination is an Azure Website [D:\home\site\repository\VendorPortalSite\VendorPortalSite.csproj]
D:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1819,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. [D:\home\site\repository\UploadTempData\UploadTempData.csproj]
D:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.CurrentVersion.targets(133,9): warning MSB3884: Could not find rule set file "ManagedMinimumRules.ruleset". [D:\home\site\repository\UploadTempData\UploadTempData.csproj]
UploadTempData -> D:\home\site\repository\UploadTempData\bin\Release\UploadTempData.exe
D:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\Web\Microsoft.Web.Publishing.targets(2673,5): error MSB4062: The "GetProjectProperties" task could not be loaded from the assembly D:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\Web\Microsoft.Web.Publishing.Tasks.dll. Could not load file or assembly 'file:///D:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\Web\Microsoft.Web.Publishing.Tasks.dll' or one of its dependencies. The system cannot find the file specified. Confirm that the <UsingTask> declaration is correct, that the assembly and all its dependencies are available, and that the task contains a public class that implements Microsoft.Build.Framework.ITask. [D:\home\site\repository\VendorPortalSite\VendorPortalSite.csproj]
Failed exitCode=1, command="D:\Program Files (x86)\MSBuild\14.0\Bin\MSBuild.exe" "D:\home\site\repository\VendorPortalSite\VendorPortalSite.csproj" /nologo /verbosity:m /t:Build /t:pipelinePreDeployCopyAllFilesToOneFolder /p:_PackageTempDir="D:\local\Temp\8d4069364ae5648";AutoParameterizationWebConfigConnectionStrings=false;Configuration=Release;UseSharedCompilation=false /p:SolutionDir="D:\home\site\repository\.\\"
An error has occurred during web site deployment.
\r\nD:\Program Files (x86)\SiteExtensions\Kudu\59.51102.2512\bin\Scripts\starter.cmd "D:\home\site\deployments\tools\deploy.cmd"
The warnings has always been there and never caused and issue before. I tried to delete and re-create the slot but that didn't help.

Veracode through an error - ASPCONFIG: Could not autodiscover 'components.config'

I have a Veracode plugin in my VS 2013 Professional.
I have ucommerce.dll, Sitecore.Kernel and Sitecore.Analytics.dll
I set copy local true for all above dll files.
When i tried to pre-compile all the web project I'm getting a below error message
1>------ Pre-compile started: Project: XXXXX.Web.PQRPorta\ ------
1>Pre-compiling with command similar to the following:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_compiler.exe -p
"C:/XXXXX.Web.PQRPortal" -v "XXXXX.Web.PQRPortal/" -fixednames -f -c
-d "C:/SVN/trunk/Releases/SourceCode/Source/PrecompiledWeb/XXXXX.Web.PQRPortal"
1>error ASPCONFIG: Could not autodiscover 'components.config'. Make
sure it's present in the application folder
'C:\SVN\trunk\Releases\SourceCode\Source\XXXXX.Web.PQRPortal\' or in a
sub folder. Paths ignored
''C:\SVN\trunk\Releases\SourceCode\Source\XXXXX.Web.PQRPortal\bin',
'C:\SVN\trunk\Releases\SourceCode\Source\XXXXX.Web.PQRPortal\App_Data',
'C:\SVN\trunk\Releases\SourceCode\Source\XXXXX.Web.PQRPortal\obj''
1>XXXXX.Web.PQRPortal\ - 1 error, 0 warnings
Is there any configuration missing?
Update
I found the components.config file inside
C:\inetpub\wwwroot\XXXX\Website\sitecore modules\Shell\uCommerce\Configuration
and I added the file inside the web project root directory and tried to precompile web project, now I’m getting different error error
ASPRUNTIME: Type is not resolved for member 'Castle.Windsor.Configuration.Interpreters.ConfigurationProcessingException,Cast‌​le.Windsor, Version=3.2.0.0, Culture=neutral, PublicKeyToken=407dd0808d44fbdc'.
any solution for it?
The components.config is a file uCommerce need.
The configuration file should be placed somewhere below the uCommerce folder. (not sure where depend on the version) It will automatically be picked up when the application starts up.

Could not load file or assembly 'Microsoft.VisualStudio.Shell, Version=2.0.0.0

I recently updated a website from VS2008 to VS2010. Publish with Web Deploy tool but I get the following error
Server Error in '/' Application. Parser Error Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. Parser Error Message: Reference.svcmap: Could not load file or assembly 'Microsoft.VisualStudio.Shell, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified. Source Error: [No relevant source lines] Source File: /App_WebReferences/websConsultarCOVE/ Line: 1 Assembly Load Trace: The following information can be helpful to determine why the assembly 'Microsoft.VisualStudio.Shell, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' could not be loaded. 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]. Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.18010
The error is in reference to a third party webservices
OS: Windows Server 2012
Thank you very much in advance

Resources