By continuing you indicate that you have read and agree to our Terms of service and Privacy policy
By continuing you indicate that you have read and agree to our Terms of service and Privacy policy
Popular Releases
Popular Libraries
New Libraries
Top Authors
Trending Kits
Trending Discussions
Learning
Explore Related Topics
kubernetes | Kubernetes v1.24.0-rc.0 |
moby | v20.10.12 |
gogs | 0.12.6 |
traefik | v2.6.3 |
terraform | v1.1.9 |
kubernetes Kubernetes v1.24.0-rc.0 |
moby v20.10.12 |
gogs 0.12.6 |
traefik v2.6.3 |
terraform v1.1.9 |
by kubernetes go
87661 Apache-2.0
Production-Grade Container Scheduling and Management
by moby go
62382 Apache-2.0
Moby Project - a collaborative project for the container ecosystem to assemble container-based systems
by ripienaar html
53713
A list of SaaS, PaaS and IaaS offerings that have free tiers of interest to devops and infradev
by ansible python
52834 GPL-3.0
Ansible is a radically simple IT automation platform that makes your applications and systems easier to deploy and maintain. Automate everything from code deployment to network configuration to cloud management, in a language that approaches plain English, using SSH, with no agents to install on remote systems. https://docs.ansible.com.
by gogs go
38876 MIT
Gogs is a painless self-hosted Git service
by traefik go
37382 MIT
The Cloud Native Application Proxy
by chinese-poetry javascript
33797 MIT
The most comprehensive database of Chinese poetry 🧶最全中华古诗词数据库, 唐宋两朝近一万四千古诗人, 接近5.5万首唐诗加26万宋诗. 两宋时期1564位词人,21050首词。
by hashicorp go
32174 MPL-2.0
Terraform enables you to safely and predictably create, change, and improve infrastructure. It is an open source tool that codifies APIs into declarative configuration files that can be shared amongst team members, treated as code, edited, reviewed, and versioned.
by testerSunshine python
30070 MIT
12306智能刷票,订票
by kubernetes go
87661 Apache-2.0
Production-Grade Container Scheduling and Management
by moby go
62382 Apache-2.0
Moby Project - a collaborative project for the container ecosystem to assemble container-based systems
by ripienaar html
53713
A list of SaaS, PaaS and IaaS offerings that have free tiers of interest to devops and infradev
by ansible python
52834 GPL-3.0
Ansible is a radically simple IT automation platform that makes your applications and systems easier to deploy and maintain. Automate everything from code deployment to network configuration to cloud management, in a language that approaches plain English, using SSH, with no agents to install on remote systems. https://docs.ansible.com.
by gogs go
38876 MIT
Gogs is a painless self-hosted Git service
by traefik go
37382 MIT
The Cloud Native Application Proxy
by chinese-poetry javascript
33797 MIT
The most comprehensive database of Chinese poetry 🧶最全中华古诗词数据库, 唐宋两朝近一万四千古诗人, 接近5.5万首唐诗加26万宋诗. 两宋时期1564位词人,21050首词。
by hashicorp go
32174 MPL-2.0
Terraform enables you to safely and predictably create, change, and improve infrastructure. It is an open source tool that codifies APIs into declarative configuration files that can be shared amongst team members, treated as code, edited, reviewed, and versioned.
by testerSunshine python
30070 MIT
12306智能刷票,订票
by sickcodes shell
21476 GPL-3.0
Run Mac in a Docker! Run near native OSX-KVM in Docker! X11 Forwarding! CI/CD for OS X!
by backstage typescript
16116 Apache-2.0
Backstage is an open platform for building developer portals
by docker html
14536 CC0-1.0
Awesome Docker Compose samples
by lima-vm go
7768 Apache-2.0
Linux virtual machines, typically on macOS, for running containerd
by armosec go
5495 Apache-2.0
Kubescape is a K8s open-source tool providing a multi-cloud K8s single pane of glass, including risk analysis, security compliance, RBAC visualizer and image vulnerabilities scanning.
by datreeio go
5449 Apache-2.0
Prevent Kubernetes misconfigurations from reaching production (again 😤 )! Datree is a CLI tool to ensure K8s manifests and Helm charts follow best practices as well as your organization’s policies. See our docs: https://hub.datree.io
by dotnetcore csharp
4692 MIT
github加速神器,解决github打不开、用户头像无法加载、releases无法上传下载、git-clone、git-pull、git-push失败等问题
by dotnet csharp
4534 MIT
Tye is a tool that makes developing, testing, and deploying microservices and distributed applications easier. Project Tye includes a local orchestrator to make developing microservices easier and the ability to deploy microservices to Kubernetes with minimal configuration.
by k0sproject go
4410 NOASSERTION
k0s - The Zero Friction Kubernetes by Team Lens
by sickcodes shell
21476 GPL-3.0
Run Mac in a Docker! Run near native OSX-KVM in Docker! X11 Forwarding! CI/CD for OS X!
by backstage typescript
16116 Apache-2.0
Backstage is an open platform for building developer portals
by docker html
14536 CC0-1.0
Awesome Docker Compose samples
by lima-vm go
7768 Apache-2.0
Linux virtual machines, typically on macOS, for running containerd
by armosec go
5495 Apache-2.0
Kubescape is a K8s open-source tool providing a multi-cloud K8s single pane of glass, including risk analysis, security compliance, RBAC visualizer and image vulnerabilities scanning.
by datreeio go
5449 Apache-2.0
Prevent Kubernetes misconfigurations from reaching production (again 😤 )! Datree is a CLI tool to ensure K8s manifests and Helm charts follow best practices as well as your organization’s policies. See our docs: https://hub.datree.io
by dotnetcore csharp
4692 MIT
github加速神器,解决github打不开、用户头像无法加载、releases无法上传下载、git-clone、git-pull、git-push失败等问题
by dotnet csharp
4534 MIT
Tye is a tool that makes developing, testing, and deploying microservices and distributed applications easier. Project Tye includes a local orchestrator to make developing microservices easier and the ability to deploy microservices to Kubernetes with minimal configuration.
by k0sproject go
4410 NOASSERTION
k0s - The Zero Friction Kubernetes by Team Lens
1
157 Libraries
36916
2
129 Libraries
6295
3
129 Libraries
3045
4
123 Libraries
2462
5
122 Libraries
9603
6
121 Libraries
131295
7
121 Libraries
29936
8
112 Libraries
7026
9
107 Libraries
4199
10
102 Libraries
10089
Developing and deploying apps, managing infrastructure, monitoring, logging activity, and other development and operations procedures can all be automated using C-Sharp DevOps libraries. The programming language C# is frequently used to create various applications, including backend services, desktop, mobile, and web based. On the .NET platform, which offers a wealth of libraries and tools for creating, deploying, and maintaining applications, C# serves as the principal language for developing applications. Building and deploying apps, managing infrastructure, and monitoring and logging are just a few development and operations processes that can be automated in DevOps using C# libraries. By automating and streamlining their operations, these libraries can aid developers, and DevOps engineers in producing higher-quality software more rapidly and effectively. DevOps aims to make it possible for businesses to produce higher-quality, more reliable, and quicker software. A software development process called DevOps strongly emphasizes teamwork, communication, and integration between IT operations teams and software developers. Azure Microsoft offers a suite of DevOps tools and services for creating, delivering, and managing applications. It is a cloud-based platform that interfaces with various tools and services, such as GitHub, Azure, and Visual Studio, to offer a full range of DevOps capabilities. Check out the below list to find the best C# DevOps libraries for your application:
In recent years, the usage of mobile phones is increased. It has been surveyed that there is a rising interest in voting on SMS cell phones and through social networking tools like Facebook or Twitter. It's believed the voting process by cell phones gives some decision power to the citizens, which can actuate directly on decisions of their concerns. The voting process also can give ways for numerical information surveillance about social phenomena. It describes the intention to create an electronic voting process using mobile. You can create your own customized online e-voting system.
1. Development Environment
2. Database
3. Vote collecting Web Services
4. E-voting application
5. Vote Tally application
Development Environment VS code is used for development for web application.
Database Database is used to collect and maintain the voting data collected during the public voting
process.
Vote Tally application Application is used to tally the votes. Vote collecting Web Services The services are dynamic pages which receives parameters via the web browser component from inside Android application.
E-voting application e-voting application is used for smart voting from various devices
Build automated sanitization robots that can be employed in hospitals and other public and private premises using open-source libraries and frameworks. Today, sanitization is much needed in every place including hospitals, offices, homes, public places, and whatnot. The Covid-19 pandemic has made sanitization a buzzword even though it existed for ages. In this modern era, robots are playing a vital role in reducing human efforts and helping to get the job done by saving time and money. We can use these robots to sanitize the hospitals, that would eventually help in saving precious human life. The main purpose of these robots is to minimize person-to-person contact and to ensure cleaning, support in hospitals, and quarantine. This will help in reducing threats to medical staff and doctors taking an active role in pandemic for managing health care systems. You can use open-source libraries and components while building such robots. Listed below are the best libraries that can be reused by developers in their projects for building hospital sanitizing robots:
Build enhanced server side scripting for various usecases in Ruby for your application.Get ratings, code snippets & documentation for each library.
It consists of everything we needed in the proof of concept we explained in the presentation.
Thank you for letting us participate!
Regards,
Karthikeyan Umesh
G Nikhileswara Reddy
Anikireddy Rama Lingeswara Reddy
Akuluru Sai Lohith
Team Code Weebs Challenge Two Submission using Kandi Openweaver
Java E-Commerce Libraries are used to build e-commerce websites. These libraries provide various frameworks, tools, and utilities for developing online shopping websites. There are many Java E-Commerce libraries available in the market, which enable you to write your own e-commerce website in easy steps. Java E-Commerce Libraries like shopizer, micro-ecommerce, and keyist-ecommerce are also used for developing an eCommerce website. These libraries are used in e-commerce applications since they provide a platform for making payment gateways, shopping carts, and other functionalities of an eCommerce website.
Shopizer is the most popular Java e-commerce library that allows you to create a customized online store without any coding. It comes with integrated payment gateways, shipping plugins, and many other features, which make it one of the best options for small businesses looking to start an online store. Keyist-Ecommerce is an open-source Java library that allows you to build an online store with minimal effort and time. The library supports multiple languages, including English, Chinese, Japanese and Korean. It also offers integrated payment gateways, shipping plugins, and other features that make it easy for developers to build custom websites without having to write any code themselves. Micro-eCommerce is an open-source Java library that allows you to build an online store without any coding knowledge required by developers. It has over 350 features built in along with integrated payment gateways, shipping plugins, and many other features that make it easy for developers to create custom websites. Some of the most popular Java E-Commerce Libraries among developers are given below
Developing and deploying apps, managing infrastructure, monitoring, logging activity, and other development and operations procedures can all be automated using C-Sharp DevOps libraries. The programming language C# is frequently used to create various applications, including backend services, desktop, mobile, and web based. On the .NET platform, which offers a wealth of libraries and tools for creating, deploying, and maintaining applications, C# serves as the principal language for developing applications. Building and deploying apps, managing infrastructure, and monitoring and logging are just a few development and operations processes that can be automated in DevOps using C# libraries. By automating and streamlining their operations, these libraries can aid developers, and DevOps engineers in producing higher-quality software more rapidly and effectively. DevOps aims to make it possible for businesses to produce higher-quality, more reliable, and quicker software. A software development process called DevOps strongly emphasizes teamwork, communication, and integration between IT operations teams and software developers. Azure Microsoft offers a suite of DevOps tools and services for creating, delivering, and managing applications. It is a cloud-based platform that interfaces with various tools and services, such as GitHub, Azure, and Visual Studio, to offer a full range of DevOps capabilities. Check out the below list to find the best C# DevOps libraries for your application:
In recent years, the usage of mobile phones is increased. It has been surveyed that there is a rising interest in voting on SMS cell phones and through social networking tools like Facebook or Twitter. It's believed the voting process by cell phones gives some decision power to the citizens, which can actuate directly on decisions of their concerns. The voting process also can give ways for numerical information surveillance about social phenomena. It describes the intention to create an electronic voting process using mobile. You can create your own customized online e-voting system.
1. Development Environment
2. Database
3. Vote collecting Web Services
4. E-voting application
5. Vote Tally application
Development Environment VS code is used for development for web application.
Database Database is used to collect and maintain the voting data collected during the public voting
process.
Vote Tally application Application is used to tally the votes. Vote collecting Web Services The services are dynamic pages which receives parameters via the web browser component from inside Android application.
E-voting application e-voting application is used for smart voting from various devices
Build automated sanitization robots that can be employed in hospitals and other public and private premises using open-source libraries and frameworks. Today, sanitization is much needed in every place including hospitals, offices, homes, public places, and whatnot. The Covid-19 pandemic has made sanitization a buzzword even though it existed for ages. In this modern era, robots are playing a vital role in reducing human efforts and helping to get the job done by saving time and money. We can use these robots to sanitize the hospitals, that would eventually help in saving precious human life. The main purpose of these robots is to minimize person-to-person contact and to ensure cleaning, support in hospitals, and quarantine. This will help in reducing threats to medical staff and doctors taking an active role in pandemic for managing health care systems. You can use open-source libraries and components while building such robots. Listed below are the best libraries that can be reused by developers in their projects for building hospital sanitizing robots:
Build enhanced server side scripting for various usecases in Ruby for your application.Get ratings, code snippets & documentation for each library.
It consists of everything we needed in the proof of concept we explained in the presentation.
Thank you for letting us participate!
Regards,
Karthikeyan Umesh
G Nikhileswara Reddy
Anikireddy Rama Lingeswara Reddy
Akuluru Sai Lohith
Team Code Weebs Challenge Two Submission using Kandi Openweaver
Java E-Commerce Libraries are used to build e-commerce websites. These libraries provide various frameworks, tools, and utilities for developing online shopping websites. There are many Java E-Commerce libraries available in the market, which enable you to write your own e-commerce website in easy steps. Java E-Commerce Libraries like shopizer, micro-ecommerce, and keyist-ecommerce are also used for developing an eCommerce website. These libraries are used in e-commerce applications since they provide a platform for making payment gateways, shopping carts, and other functionalities of an eCommerce website.
Shopizer is the most popular Java e-commerce library that allows you to create a customized online store without any coding. It comes with integrated payment gateways, shipping plugins, and many other features, which make it one of the best options for small businesses looking to start an online store. Keyist-Ecommerce is an open-source Java library that allows you to build an online store with minimal effort and time. The library supports multiple languages, including English, Chinese, Japanese and Korean. It also offers integrated payment gateways, shipping plugins, and other features that make it easy for developers to build custom websites without having to write any code themselves. Micro-eCommerce is an open-source Java library that allows you to build an online store without any coding knowledge required by developers. It has over 350 features built in along with integrated payment gateways, shipping plugins, and many other features that make it easy for developers to create custom websites. Some of the most popular Java E-Commerce Libraries among developers are given below
QUESTION
Azure Pipelines local agent failing to connect with SSL error
Asked 2022-Mar-29 at 19:29We have an on premise server (Windows Server 2012 R2) with an Azure Pipelines agent running on it. Today (31st Jan 2022) this agent could not longer connect to our Azure DevOps organisation.
Judging by the log files, I assume this is because it is trying to connect with an older TLS version, which as of today is no longer available - https://devblogs.microsoft.com/devops/azure-devops-services-to-require-tls-1-2/
So I followed the instructions on how to make sure TLS 1.2 was enabled, and confirmed my settings in the registry editor and by running the PowerShell script suggested here - https://docs.microsoft.com/en-us/security/engineering/solving-tls1-problem#update-windows-powershell-scripts-or-related-registry-settings
All seems ok, yet it still fails to connect with the same issue. The machine has been restarted as well. If I try the URL it is requesting in the in built Internet Explorer browser, it fails, but with Chrome it succeeds, so it must still be trying to connect with TLS 1.2, but I don't know why. I've tried reinstalling the agent (with the latest build) as well but it fails on the same error. Any suggestions?
ANSWER
Answered 2022-Jan-31 at 23:27Enabling below Cyphers with IISCrypto on the server helped us fix the issue
Cipher Suites
TLS 1.2 (suites in server-preferred order) TLS
This from Vijay's solution
QUESTION
Unable to negotiate with 40.74.28.9 port 22: no matching host key type found. Their offer: ssh-rsa
Asked 2022-Mar-28 at 15:54After start of using NixOS as a new package management system, I get the following error when using git within Azure DevOps repositories and rsa ssh key:
1jaroslavbezdek@mac> git pull
2Unable to negotiate with 40.74.28.9 port 22: no matching host key type found. Their offer: ssh-rsa
3fatal: Could not read from remote repository.
4
5Please make sure you have the correct access rights
6and the repository exists.
7
What can I do with that, please?
ANSWER
Answered 2021-Nov-12 at 12:44According to this post, you can add ssh.dev.azure.com
host config to your ~/.ssh/config
file:
Final
~/.ssh/config
that worked for me:
1jaroslavbezdek@mac> git pull
2Unable to negotiate with 40.74.28.9 port 22: no matching host key type found. Their offer: ssh-rsa
3fatal: Could not read from remote repository.
4
5Please make sure you have the correct access rights
6and the repository exists.
7Host ssh.dev.azure.com
8 HostName ssh.dev.azure.com
9 User git
10 IdentityFile ~/.ssh/id_rsa
11 IdentitiesOnly yes
12 PubkeyAcceptedAlgorithms +ssh-rsa
13 HostkeyAlgorithms +ssh-rsa
14
QUESTION
Visual Studio 2022 not showing up in the dropdown
Asked 2022-Mar-26 at 17:18We have on-prem Azure DevOps 2020 installed. We built a .net core 6 app in Visual Studio 2022. However, when creating the build pipeline, VS 2022 is not showing up in the dropdown.
Has anyone faced this problem? Is MSFT supposed to release a patch that will start displaying VS 2022 in the dropdown?
ANSWER
Answered 2022-Jan-28 at 15:20Many people are running into this. No word from MS yet on when or if an update will be available. But these articles may help you find a workaround:
FWIW, I'm working around it by using an explicit MSBuild path as mentioned in this answer. I added a PreferredMSBuildExePath
variable to my pipeline and set it equal to %ProgramFiles%\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\MSBuild.exe
. Then I made all my MSBuild steps use $(PreferredMSBuildExePath)
as their MSBuild path under Specify Location. I also converted all my Visual Studio steps to MSBuild steps so I could use this explicit path variable.
QUESTION
NPM install task failing in Azure Devops, same code worked previously
Asked 2022-Mar-12 at 12:38I have yaml
pipeline running a build in Azure Devops. The Npm@1
task has started failing this morning. npm install
works locally with npm version 6.14.5 and it's all green lights on npm Status.
1pool:
2 name: 'Azure Pipelines'
3 vmImage: ubuntu-latest
4
5stages:
6 - stage:
7 variables:
8 buildConfiguration: "Release"
9 buildPlatform: "AnyCPU"
10 jobs:
11 - job:
12 steps:
13 - task: Npm@1
14 displayName: 'npm install'
15 inputs:
16 workingDir: Azure/MySite/ClientApp
17
Here's where things start to go wrong in the logs:
1pool:
2 name: 'Azure Pipelines'
3 vmImage: ubuntu-latest
4
5stages:
6 - stage:
7 variables:
8 buildConfiguration: "Release"
9 buildPlatform: "AnyCPU"
10 jobs:
11 - job:
12 steps:
13 - task: Npm@1
14 displayName: 'npm install'
15 inputs:
16 workingDir: Azure/MySite/ClientApp
17
181156 verbose pkgid node-sass@4.14.1
191157 verbose cwd /home/vsts/work/1/s/Azure/MySite/ClientApp
201158 verbose Linux 5.11.0-1021-azure
211159 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
221160 verbose node v16.13.0
231161 verbose npm v8.1.0
241162 error code 1
251163 error path /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass
261164 error command failed
271165 error command sh -c node scripts/build.js
281166 error Building: /usr/local/bin/node /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
291166 error make: Entering directory '/home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass/build'
301166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast.o ../src/libsass/src/ast.cpp
311166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o ../src/libsass/src/ast_fwd_decl.cpp
321166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/backtrace.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/backtrace.o ../src/libsass/src/backtrace.cpp
331166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/base64vlq.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/base64vlq.o ../src/libsass/src/base64vlq.cpp
34
35
36
There hadn't been any changes to the package.json
in several months. Going by the error message, I've narrowed the problem down to something to do with note-sass
so here's a minimal package.json
to reproduce the error.
1pool:
2 name: 'Azure Pipelines'
3 vmImage: ubuntu-latest
4
5stages:
6 - stage:
7 variables:
8 buildConfiguration: "Release"
9 buildPlatform: "AnyCPU"
10 jobs:
11 - job:
12 steps:
13 - task: Npm@1
14 displayName: 'npm install'
15 inputs:
16 workingDir: Azure/MySite/ClientApp
17
181156 verbose pkgid node-sass@4.14.1
191157 verbose cwd /home/vsts/work/1/s/Azure/MySite/ClientApp
201158 verbose Linux 5.11.0-1021-azure
211159 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
221160 verbose node v16.13.0
231161 verbose npm v8.1.0
241162 error code 1
251163 error path /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass
261164 error command failed
271165 error command sh -c node scripts/build.js
281166 error Building: /usr/local/bin/node /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
291166 error make: Entering directory '/home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass/build'
301166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast.o ../src/libsass/src/ast.cpp
311166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o ../src/libsass/src/ast_fwd_decl.cpp
321166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/backtrace.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/backtrace.o ../src/libsass/src/backtrace.cpp
331166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/base64vlq.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/base64vlq.o ../src/libsass/src/base64vlq.cpp
34
35
36{
37 "dependencies": {
38 "node-sass": "^4.14.1"
39 }
40}
41
42
ANSWER
Answered 2021-Dec-02 at 13:14I still don't know why this started failing all of a sudden but I have resolved the problem by updating node-sass
to version 6.0.1
.
1pool:
2 name: 'Azure Pipelines'
3 vmImage: ubuntu-latest
4
5stages:
6 - stage:
7 variables:
8 buildConfiguration: "Release"
9 buildPlatform: "AnyCPU"
10 jobs:
11 - job:
12 steps:
13 - task: Npm@1
14 displayName: 'npm install'
15 inputs:
16 workingDir: Azure/MySite/ClientApp
17
181156 verbose pkgid node-sass@4.14.1
191157 verbose cwd /home/vsts/work/1/s/Azure/MySite/ClientApp
201158 verbose Linux 5.11.0-1021-azure
211159 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
221160 verbose node v16.13.0
231161 verbose npm v8.1.0
241162 error code 1
251163 error path /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass
261164 error command failed
271165 error command sh -c node scripts/build.js
281166 error Building: /usr/local/bin/node /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
291166 error make: Entering directory '/home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass/build'
301166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast.o ../src/libsass/src/ast.cpp
311166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o ../src/libsass/src/ast_fwd_decl.cpp
321166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/backtrace.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/backtrace.o ../src/libsass/src/backtrace.cpp
331166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/base64vlq.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/base64vlq.o ../src/libsass/src/base64vlq.cpp
34
35
36{
37 "dependencies": {
38 "node-sass": "^4.14.1"
39 }
40}
41
42{
43 "dependencies": {
44 "node-sass": "6.0.1"
45 }
46}
47
QUESTION
Deps File Missing for Dotnet 6 Integration Tests
Asked 2022-Feb-17 at 21:19Before I start, I've tried all suggestions from the following and none work:
Integration testing ASP.NET Core with .NET Framework - can't find deps.json
https://zimmergren.net/unable-to-find-deps-json-dotnet-azure-devops/
So I'm trying to write some integration tests for dotnet 6. However, my WebApplicationFactory
throws the following error:
System.InvalidOperationException: Can't find '/repos/subscription-info-api/tests/SubscriptionInfoApi.Tests.Integration/bin/Debug/net6.0/...
System.InvalidOperationException Can't find '/repos/subscription-info-api/tests/SubscriptionInfoApi.Tests.Integration/bin/Debug/net6.0/testhost.deps.json'. This file is required for functional tests to run properly. There should be a copy of the file on your source project bin folder. If that is not the case, make sure that the property PreserveCompilationContext is set to true on your project file. E.g 'true'. For functional tests to work they need to either run from the build output folder or the testhost.deps.json file from your application's output directory must be copied to the folder where the tests are running on. A common cause for this error is having shadow copying enabled when the tests run. at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory
1.EnsureDepsFile() at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory
1.EnsureServer() at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory1.CreateDefaultClient(DelegatingHandler[] handlers) at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory
1.CreateDefaultClient(Uri baseAddress, DelegatingHandler[] handlers) at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory1.CreateClient(WebApplicationFactoryClientOptions options) at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory
1.CreateClient() at SubscriptionInfoApi.Tests.Integration.UnitTest1.Test1() in /repos/subscription-info-api/tests/SubscriptionInfoApi.Tests.Integration/UnitTest1.cs:line 14 at SubscriptionInfoApi.Tests.Integration.UnitTest1.Test1() in /repos/subscription-info-api/tests/SubscriptionInfoApi.Tests.Integration/UnitTest1.cs:line 16 at Xunit.Sdk.TestInvoker1.<>c__DisplayClass48_0.<<InvokeTestMethodAsync>b__1>d.MoveNext() in /_/src/xunit.execution/Sdk/Frameworks/Runners/TestInvoker.cs:line 264 --- End of stack trace from previous location --- at Xunit.Sdk.ExecutionTimer.AggregateAsync(Func
1 asyncAction) in //src/xunit.execution/Sdk/Frameworks/ExecutionTimer.cs:line 48 at Xunit.Sdk.ExceptionAggregator.RunAsync(Func`1 code) in //src/xunit.core/Sdk/ExceptionAggregator.cs:line 90
My actual test code is extremely simple:
1 [Fact]
2 public async Task Test1()
3 {
4 await using var app = new WebApplicationFactory<Program>();
5 using var client = app.CreateClient();
6 var res = await (await client.GetAsync("/alive-test")).Content.ReadAsStringAsync();
7 Assert.Equal("Alive!", res);
8 }
9
As per the suggestions, I've made sure I'm directly referencing Microsoft.AspNetCore.Mvc.Testing -> 6.0.0
in my integration tests project. I've also tried the various tweaks to the .csproj
files that were suggested but nothing seems to be working.
I'm stuck for things to try to debug this further, any ideas?
ANSWER
Answered 2021-Nov-18 at 21:03You are probably targeting the wrong namespace for Program in your test file (like I was).
I had to add the following at the end of my Program.cs file (last line) to make it visible to my test projects needing it:
1 [Fact]
2 public async Task Test1()
3 {
4 await using var app = new WebApplicationFactory<Program>();
5 using var client = app.CreateClient();
6 var res = await (await client.GetAsync("/alive-test")).Content.ReadAsStringAsync();
7 Assert.Equal("Alive!", res);
8 }
9public partial class Program { }
10
An example can be found here: minimal api testing example
QUESTION
Azure, .Net, Cobertura - ##[warning]Multiple file or directory matches were found
Asked 2022-Feb-16 at 10:41Hi i am trying to get code coverage with .net5 in azure pipeline.
Run tests (not entire file)
1Starting test execution, please wait...
2A total of 1 test files matched the specified pattern.
3Results File: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59.trx
4
5Attachments:
6 /home/vsts/work/_temp/f5dd5e9f-e260-437d-80ef-4fb917215b09/coverage.cobertura.xml
7Passed! - Failed: 0, Passed: 16, Skipped: 0, Total: 16, Duration: 732 ms - /home/vsts/work/1/s/sda2021_webapi/Test/sda2021_api.tests/bin/Release/net5.0/sda2021_webapi.tests.dll (net5.0)
8Result Attachments will be stored in LogStore
9Run Attachments will be stored in LogStore
10Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
11Async Command Start: Publish test results
12Publishing test results to test run '5152'.
13TestResults To Publish 16, Test run id:5152
14Test results publishing 16, remaining: 0. Test run id: 5152
15Published Test Run : https://dev.azure.com/sda-shs/Bratislava2021/_TestManagement/Runs?runId=5152&_a=runCharts
16Async Command End: Publish test results
17Finishing: Dotnet run tests
18
Publish tests(not entire file)
1Starting test execution, please wait...
2A total of 1 test files matched the specified pattern.
3Results File: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59.trx
4
5Attachments:
6 /home/vsts/work/_temp/f5dd5e9f-e260-437d-80ef-4fb917215b09/coverage.cobertura.xml
7Passed! - Failed: 0, Passed: 16, Skipped: 0, Total: 16, Duration: 732 ms - /home/vsts/work/1/s/sda2021_webapi/Test/sda2021_api.tests/bin/Release/net5.0/sda2021_webapi.tests.dll (net5.0)
8Result Attachments will be stored in LogStore
9Run Attachments will be stored in LogStore
10Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
11Async Command Start: Publish test results
12Publishing test results to test run '5152'.
13TestResults To Publish 16, Test run id:5152
14Test results publishing 16, remaining: 0. Test run id: 5152
15Published Test Run : https://dev.azure.com/sda-shs/Bratislava2021/_TestManagement/Runs?runId=5152&_a=runCharts
16Async Command End: Publish test results
17Finishing: Dotnet run tests
18##[warning]Multiple file or directory matches were found. Using the first match: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59/In/fv-az43-964/coverage.cobertura.xml
19/opt/hostedtoolcache/dotnet/dotnet /home/vsts/work/_tasks/PublishCodeCoverageResults_2a7ebc54-c13e-490e-81a5-d7561ab7cd97/1.189.0/netcoreapp2.0/ReportGenerator.dll -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml -targetdir:/home/vsts/work/_temp/cchtml -reporttypes:HtmlInline_AzurePipelines
202021-08-25T08:32:03: Arguments
212021-08-25T08:32:03: -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml
22
And of course my pipeline
1Starting test execution, please wait...
2A total of 1 test files matched the specified pattern.
3Results File: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59.trx
4
5Attachments:
6 /home/vsts/work/_temp/f5dd5e9f-e260-437d-80ef-4fb917215b09/coverage.cobertura.xml
7Passed! - Failed: 0, Passed: 16, Skipped: 0, Total: 16, Duration: 732 ms - /home/vsts/work/1/s/sda2021_webapi/Test/sda2021_api.tests/bin/Release/net5.0/sda2021_webapi.tests.dll (net5.0)
8Result Attachments will be stored in LogStore
9Run Attachments will be stored in LogStore
10Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
11Async Command Start: Publish test results
12Publishing test results to test run '5152'.
13TestResults To Publish 16, Test run id:5152
14Test results publishing 16, remaining: 0. Test run id: 5152
15Published Test Run : https://dev.azure.com/sda-shs/Bratislava2021/_TestManagement/Runs?runId=5152&_a=runCharts
16Async Command End: Publish test results
17Finishing: Dotnet run tests
18##[warning]Multiple file or directory matches were found. Using the first match: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59/In/fv-az43-964/coverage.cobertura.xml
19/opt/hostedtoolcache/dotnet/dotnet /home/vsts/work/_tasks/PublishCodeCoverageResults_2a7ebc54-c13e-490e-81a5-d7561ab7cd97/1.189.0/netcoreapp2.0/ReportGenerator.dll -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml -targetdir:/home/vsts/work/_temp/cchtml -reporttypes:HtmlInline_AzurePipelines
202021-08-25T08:32:03: Arguments
212021-08-25T08:32:03: -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml
22task: DotNetCoreCLI@2
23 displayName: Dotnet run tests
24 inputs:
25 command: "test"
26 projects: "**/xxxxx/*.tests.csproj"
27 arguments: '--configuration Release /p:CoverletOutputFormat=cobertura --collect:"XPlat Code Coverage" --no-build'
28 testRunTitle: "xxxx"
29 - task: PublishCodeCoverageResults@1
30 displayName: "publish coverage results"
31 inputs:
32 codeCoverageTool: "Cobertura"
33 summaryFileLocation: "$(Agent.TempDirectory)/**/coverage.cobertura.xml"
34
Why is more then one XML generated? I am basically balancing between no XML and more XML. I am just unable to generate one XML. (on my localhost it generates only one) Thanks for any tips.
ANSWER
Answered 2021-Aug-25 at 08:52Please replace your PublishCodeCoverageResults
with following steps:
1Starting test execution, please wait...
2A total of 1 test files matched the specified pattern.
3Results File: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59.trx
4
5Attachments:
6 /home/vsts/work/_temp/f5dd5e9f-e260-437d-80ef-4fb917215b09/coverage.cobertura.xml
7Passed! - Failed: 0, Passed: 16, Skipped: 0, Total: 16, Duration: 732 ms - /home/vsts/work/1/s/sda2021_webapi/Test/sda2021_api.tests/bin/Release/net5.0/sda2021_webapi.tests.dll (net5.0)
8Result Attachments will be stored in LogStore
9Run Attachments will be stored in LogStore
10Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
11Async Command Start: Publish test results
12Publishing test results to test run '5152'.
13TestResults To Publish 16, Test run id:5152
14Test results publishing 16, remaining: 0. Test run id: 5152
15Published Test Run : https://dev.azure.com/sda-shs/Bratislava2021/_TestManagement/Runs?runId=5152&_a=runCharts
16Async Command End: Publish test results
17Finishing: Dotnet run tests
18##[warning]Multiple file or directory matches were found. Using the first match: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59/In/fv-az43-964/coverage.cobertura.xml
19/opt/hostedtoolcache/dotnet/dotnet /home/vsts/work/_tasks/PublishCodeCoverageResults_2a7ebc54-c13e-490e-81a5-d7561ab7cd97/1.189.0/netcoreapp2.0/ReportGenerator.dll -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml -targetdir:/home/vsts/work/_temp/cchtml -reporttypes:HtmlInline_AzurePipelines
202021-08-25T08:32:03: Arguments
212021-08-25T08:32:03: -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml
22task: DotNetCoreCLI@2
23 displayName: Dotnet run tests
24 inputs:
25 command: "test"
26 projects: "**/xxxxx/*.tests.csproj"
27 arguments: '--configuration Release /p:CoverletOutputFormat=cobertura --collect:"XPlat Code Coverage" --no-build'
28 testRunTitle: "xxxx"
29 - task: PublishCodeCoverageResults@1
30 displayName: "publish coverage results"
31 inputs:
32 codeCoverageTool: "Cobertura"
33 summaryFileLocation: "$(Agent.TempDirectory)/**/coverage.cobertura.xml"
34 - task: reportgenerator@4
35 displayName: 'Merge code coverage reports'
36 inputs:
37 reports: '$(Agent.TempDirectory)/**/coverage.cobertura.xml'
38 targetdir: '$(Pipeline.Workspace)/coverlet'
39 reporttypes: 'Cobertura'
40 verbosity: 'Verbose'
41
42 - task: PublishCodeCoverageResults@1
43 displayName: 'Publish code coverage results'
44 inputs:
45 codeCoverageTool: Cobertura
46 summaryFileLocation: '$(Pipeline.Workspace)/coverlet/Cobertura.xml'
47
And you have multiple files, because probably you have more than one test project.
QUESTION
C# WASM without Blazor
Asked 2022-Jan-30 at 14:27I want to be able to call C# code from JavaScript. The mono project used to have a WASM SDK that you could download from their old Jenkins server, but that is no longer public. Existing docs tend to point toward those builds. The Azure Devops builds do not include this SDK. A few messages I've seen on their Github account indicate that they are now focusing on the .NET 6 for WASM. I do not wish to use the Blazor components. Is there a way in .NET 6 to build a minimally sized WASM binary without the Blazor UI?
ANSWER
Answered 2021-Aug-26 at 01:25Yes it's absolutely possible. Blazor does not have a monopoly on C#/WASM and it's far from clear that it's going to wind up being the best long term option (and a lot of evidence it's not).
I recommend starting with the Uno WASM Bootstrap. https://github.com/unoplatform/Uno.Wasm.Bootstrap
QUESTION
Azure DevOps Build pipeline `npm install` failing on node-gyp
Asked 2021-Dec-20 at 12:31We have a CD/CI Azure Devops build pipeline that has started failing for nodejs/node-gyp
.
error gyp info using node-gyp@3.8.0
error gyp info using node@16.13.0 | win32 | x64
Nothing about our build pipeline has changed, the pool we use is:
1pool:
2 vmImage: 'windows-latest'
3
Which is still mapped to windows-2019
https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml.
The pipeline fails when we hit the following task in the YAML file:
1pool:
2 vmImage: 'windows-latest'
3- task: Npm@1
4 displayName: 'npm install'
5 inputs:
6 command: 'install'
7 workingDir: 'FrontEnd'
8 verbose: true
9
Log file:
1pool:
2 vmImage: 'windows-latest'
3- task: Npm@1
4 displayName: 'npm install'
5 inputs:
6 command: 'install'
7 workingDir: 'FrontEnd'
8 verbose: true
9error gyp ERR! UNCAUGHT EXCEPTION
10error gyp ERR! stack Error: spawn C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\15.0\Bin\MSBuild.exe ENOENT
11error gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:282:19)
12error gyp ERR! stack at onErrorNT (node:internal/child_process:477:16)
13error gyp ERR! stack at processTicksAndRejections (node:internal/process/task_queues:83:21)
14error gyp ERR! System Windows_NT 10.0.17763
15error gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\a\\1\\s\\Presentation\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
16error gyp ERR! cwd D:\a\1\s\FrontEnd\node_modules\node-sass
17error gyp ERR! node -v v16.13.0
18error gyp ERR! node-gyp -v v3.8.0
19error gyp ERR! This is a bug in `node-gyp`.
20error gyp ERR! Try to update node-gyp and file an Issue if it does not help:
21error gyp ERR! <https://github.com/nodejs/node-gyp/issues>
22error Build failed with error code: 7
23verbose exit 1
24
25##[error]Error: Npm failed with return code: 1
26
ANSWER
Answered 2021-Dec-13 at 09:42Azure auto updated the version of node it was using, pushing the required version of node-gyp forward too, this lead to all of our builds failing. The versions it pushed to were:
Add task: NodeTool@0
to set the Node version to the last passed version which for us was:
The end code looks like this:
1pool:
2 vmImage: 'windows-latest'
3- task: Npm@1
4 displayName: 'npm install'
5 inputs:
6 command: 'install'
7 workingDir: 'FrontEnd'
8 verbose: true
9error gyp ERR! UNCAUGHT EXCEPTION
10error gyp ERR! stack Error: spawn C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\15.0\Bin\MSBuild.exe ENOENT
11error gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:282:19)
12error gyp ERR! stack at onErrorNT (node:internal/child_process:477:16)
13error gyp ERR! stack at processTicksAndRejections (node:internal/process/task_queues:83:21)
14error gyp ERR! System Windows_NT 10.0.17763
15error gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\a\\1\\s\\Presentation\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
16error gyp ERR! cwd D:\a\1\s\FrontEnd\node_modules\node-sass
17error gyp ERR! node -v v16.13.0
18error gyp ERR! node-gyp -v v3.8.0
19error gyp ERR! This is a bug in `node-gyp`.
20error gyp ERR! Try to update node-gyp and file an Issue if it does not help:
21error gyp ERR! <https://github.com/nodejs/node-gyp/issues>
22error Build failed with error code: 7
23verbose exit 1
24
25##[error]Error: Npm failed with return code: 1
26- task: NodeTool@0
27 inputs:
28 versionSpec: '14.x'
29
30- task: Npm@1
31 displayName: 'npm install'
32 inputs:
33 command: 'install'
34 workingDir: 'FrontEnd'
35 verbose: true
36
After re-running the pipeline it works again and produces artefacts.
QUESTION
How can I suppress or resolve "info: detecting host provider for..." in Git?
Asked 2021-Nov-25 at 13:09I'm getting the following output when executing a fetch / pull via a powershell script:
info: detecting host provider for '[devops site address]'...
Normally, this wouldn't be an issue, however, Azure DevOps sees this output as an error and labels the release stage as such. Is there a way I can either suppress this output, or resolve it via GIT?
The remote location for the repository is an on-prem version of DevOps.
Thanks!
ANSWER
Answered 2021-Nov-25 at 13:09This comes indeed from the GCM used by Git.
You can either downgrade to Git 2.32, or wait for the recently released Git-Credential-Manager-Core v2.0.603, which does remove those messages.
Said release is not yet packaged with the latest Git for Windows, like the recent 2.34.0, but expect it in 2.34.1.
A set GCM_PROVIDER=generic
could help too.
Update Nov. 25th, 2021: Git for Windows 2.34.1 has been released, and it does include Git Credential Manager Core v2.0.605.12951.
That GCM 2.0.605 includes "Remove noisy messages during auto-detection" (#492, #494).
QUESTION
Azure Devops - Hosted pool - ubuntu latest - How do i get ubuntu-latest to have the latest visual studio build tools (preview 2022)?
Asked 2021-Nov-05 at 14:04Our azure devops pipelines are configured to use hosted ubuntu-latest
I am using Azure Functions that require the package: packages/microsoft.net.sdk.functions/4.0.0 The hosted ubuntu latest is throwing non compatible framework version error.
1 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
2 error : It was not possible to find any compatible framework version
3 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
4 error : The framework 'Microsoft.NETCore.App', version
5 '6.0.0-rc.1.21451.13' was not found.**
6
When changing the pool to run on an on premise build agent, I was able to install the latest build tools (the one that comes with visual studio 2022 preview) and everything works fine. My question is how do I get the ubuntu-latest to have the latest dotnet build tools?
This is the output of dotnet info of the ubuntu-latest agent.
1 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
2 error : It was not possible to find any compatible framework version
3 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
4 error : The framework 'Microsoft.NETCore.App', version
5 '6.0.0-rc.1.21451.13' was not found.**
62021-10-27T04:54:16.4629465Z .NET SDKs installed:
72021-10-27T04:54:16.4630372Z 2.1.302 [/usr/share/dotnet/sdk]
82021-10-27T04:54:16.4630865Z 2.1.403 [/usr/share/dotnet/sdk]
92021-10-27T04:54:16.4631327Z 2.1.526 [/usr/share/dotnet/sdk]
102021-10-27T04:54:16.4631821Z 2.1.617 [/usr/share/dotnet/sdk]
112021-10-27T04:54:16.4632292Z 2.1.701 [/usr/share/dotnet/sdk]
122021-10-27T04:54:16.4632746Z 2.1.818 [/usr/share/dotnet/sdk]
132021-10-27T04:54:16.4633218Z 3.1.120 [/usr/share/dotnet/sdk]
142021-10-27T04:54:16.4633687Z 3.1.202 [/usr/share/dotnet/sdk]
152021-10-27T04:54:16.4634147Z 3.1.302 [/usr/share/dotnet/sdk]
162021-10-27T04:54:16.4634616Z 3.1.414 [/usr/share/dotnet/sdk]
172021-10-27T04:54:16.4635086Z 5.0.104 [/usr/share/dotnet/sdk]
182021-10-27T04:54:16.4635541Z 5.0.208 [/usr/share/dotnet/sdk]
192021-10-27T04:54:16.4636008Z 5.0.303 [/usr/share/dotnet/sdk]
202021-10-27T04:54:16.4636462Z 5.0.402 [/usr/share/dotnet/sdk]
212021-10-27T04:54:16.4636703Z
222021-10-27T04:54:16.4637082Z .NET runtimes installed:
232021-10-27T04:54:16.4637683Z Microsoft.AspNetCore.All 2.1.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
242021-10-27T04:54:16.4638405Z Microsoft.AspNetCore.All 2.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
252021-10-27T04:54:16.4639112Z Microsoft.AspNetCore.All 2.1.12 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
262021-10-27T04:54:16.4639839Z Microsoft.AspNetCore.All 2.1.24 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
272021-10-27T04:54:16.4640553Z Microsoft.AspNetCore.All 2.1.30 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
282021-10-27T04:54:16.4641691Z Microsoft.AspNetCore.App 2.1.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
292021-10-27T04:54:16.4642420Z Microsoft.AspNetCore.App 2.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
302021-10-27T04:54:16.4643130Z Microsoft.AspNetCore.App 2.1.12 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
312021-10-27T04:54:16.4643823Z Microsoft.AspNetCore.App 2.1.24 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
322021-10-27T04:54:16.4644541Z Microsoft.AspNetCore.App 2.1.30 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
332021-10-27T04:54:16.4645263Z Microsoft.AspNetCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
342021-10-27T04:54:16.4645958Z Microsoft.AspNetCore.App 3.1.6 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
352021-10-27T04:54:16.4646889Z Microsoft.AspNetCore.App 3.1.20 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
362021-10-27T04:54:16.4647598Z Microsoft.AspNetCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
372021-10-27T04:54:16.4648286Z Microsoft.AspNetCore.App 5.0.9 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
382021-10-27T04:54:16.4648995Z Microsoft.AspNetCore.App 5.0.11 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
392021-10-27T04:54:16.4649693Z Microsoft.NETCore.App 2.1.2 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
402021-10-27T04:54:16.4650357Z Microsoft.NETCore.App 2.1.5 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
412021-10-27T04:54:16.4651045Z Microsoft.NETCore.App 2.1.12 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
422021-10-27T04:54:16.4651737Z Microsoft.NETCore.App 2.1.24 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
432021-10-27T04:54:16.4652407Z Microsoft.NETCore.App 2.1.30 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
442021-10-27T04:54:16.4653101Z Microsoft.NETCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
452021-10-27T04:54:16.4653781Z Microsoft.NETCore.App 3.1.6 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
462021-10-27T04:54:16.4654445Z Microsoft.NETCore.App 3.1.20 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
472021-10-27T04:54:16.4655124Z Microsoft.NETCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
482021-10-27T04:54:16.4655799Z Microsoft.NETCore.App 5.0.9 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
492021-10-27T04:54:16.4656459Z Microsoft.NETCore.App 5.0.11 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
502021-10-27T04:54:16.4656807Z
51
ANSWER
Answered 2021-Nov-05 at 14:04use this in your pipeline definition:
1 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
2 error : It was not possible to find any compatible framework version
3 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
4 error : The framework 'Microsoft.NETCore.App', version
5 '6.0.0-rc.1.21451.13' was not found.**
62021-10-27T04:54:16.4629465Z .NET SDKs installed:
72021-10-27T04:54:16.4630372Z 2.1.302 [/usr/share/dotnet/sdk]
82021-10-27T04:54:16.4630865Z 2.1.403 [/usr/share/dotnet/sdk]
92021-10-27T04:54:16.4631327Z 2.1.526 [/usr/share/dotnet/sdk]
102021-10-27T04:54:16.4631821Z 2.1.617 [/usr/share/dotnet/sdk]
112021-10-27T04:54:16.4632292Z 2.1.701 [/usr/share/dotnet/sdk]
122021-10-27T04:54:16.4632746Z 2.1.818 [/usr/share/dotnet/sdk]
132021-10-27T04:54:16.4633218Z 3.1.120 [/usr/share/dotnet/sdk]
142021-10-27T04:54:16.4633687Z 3.1.202 [/usr/share/dotnet/sdk]
152021-10-27T04:54:16.4634147Z 3.1.302 [/usr/share/dotnet/sdk]
162021-10-27T04:54:16.4634616Z 3.1.414 [/usr/share/dotnet/sdk]
172021-10-27T04:54:16.4635086Z 5.0.104 [/usr/share/dotnet/sdk]
182021-10-27T04:54:16.4635541Z 5.0.208 [/usr/share/dotnet/sdk]
192021-10-27T04:54:16.4636008Z 5.0.303 [/usr/share/dotnet/sdk]
202021-10-27T04:54:16.4636462Z 5.0.402 [/usr/share/dotnet/sdk]
212021-10-27T04:54:16.4636703Z
222021-10-27T04:54:16.4637082Z .NET runtimes installed:
232021-10-27T04:54:16.4637683Z Microsoft.AspNetCore.All 2.1.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
242021-10-27T04:54:16.4638405Z Microsoft.AspNetCore.All 2.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
252021-10-27T04:54:16.4639112Z Microsoft.AspNetCore.All 2.1.12 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
262021-10-27T04:54:16.4639839Z Microsoft.AspNetCore.All 2.1.24 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
272021-10-27T04:54:16.4640553Z Microsoft.AspNetCore.All 2.1.30 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
282021-10-27T04:54:16.4641691Z Microsoft.AspNetCore.App 2.1.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
292021-10-27T04:54:16.4642420Z Microsoft.AspNetCore.App 2.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
302021-10-27T04:54:16.4643130Z Microsoft.AspNetCore.App 2.1.12 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
312021-10-27T04:54:16.4643823Z Microsoft.AspNetCore.App 2.1.24 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
322021-10-27T04:54:16.4644541Z Microsoft.AspNetCore.App 2.1.30 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
332021-10-27T04:54:16.4645263Z Microsoft.AspNetCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
342021-10-27T04:54:16.4645958Z Microsoft.AspNetCore.App 3.1.6 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
352021-10-27T04:54:16.4646889Z Microsoft.AspNetCore.App 3.1.20 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
362021-10-27T04:54:16.4647598Z Microsoft.AspNetCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
372021-10-27T04:54:16.4648286Z Microsoft.AspNetCore.App 5.0.9 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
382021-10-27T04:54:16.4648995Z Microsoft.AspNetCore.App 5.0.11 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
392021-10-27T04:54:16.4649693Z Microsoft.NETCore.App 2.1.2 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
402021-10-27T04:54:16.4650357Z Microsoft.NETCore.App 2.1.5 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
412021-10-27T04:54:16.4651045Z Microsoft.NETCore.App 2.1.12 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
422021-10-27T04:54:16.4651737Z Microsoft.NETCore.App 2.1.24 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
432021-10-27T04:54:16.4652407Z Microsoft.NETCore.App 2.1.30 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
442021-10-27T04:54:16.4653101Z Microsoft.NETCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
452021-10-27T04:54:16.4653781Z Microsoft.NETCore.App 3.1.6 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
462021-10-27T04:54:16.4654445Z Microsoft.NETCore.App 3.1.20 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
472021-10-27T04:54:16.4655124Z Microsoft.NETCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
482021-10-27T04:54:16.4655799Z Microsoft.NETCore.App 5.0.9 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
492021-10-27T04:54:16.4656459Z Microsoft.NETCore.App 5.0.11 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
502021-10-27T04:54:16.4656807Z
51- task: UseDotNet@2
52 displayName: 'Use .NET Core sdk'
53 inputs:
54 version: 6.0.x
55 includePreviewVersions: true
56
To explain, firstly Visual Studio only runs on Windows, so you can't install Visual Studio on Linux, but that's fine because you actually only want the .NET SDK. Secondly, both Visual Studio 2022 and .NET 6 are in preview.
Next, Azure DevOps have documented what software is pre-installed on all their hosted agents: https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software
If you follow the link to .NET Core SDK on Ubuntu 20.04 (latest), you see that they only pre-install Generally Available (GA; released) versions of the .NET SDK, not preview versions. After all, most customers building their production applications don't want the risk of using preview tools that might have bugs and break their builds.
So, if you want a preview .NET SDK, you need to explicitly install it as part of your build steps. The UseDotNet task does that, allowing you to specify a bunch of parameters, but in this case the most important two are version and include preview versions.
For other scenarios, for example anyone not using Azure Pipelines, the .NET team also have dotnet-install scripts, which you can download and execute in your pipeline.
For what it's worth, .NET 6 is having a launch party on the 9th to the 11th of November, and Visual Studio 2022 is having a launch event on the 8th of November. I don't know how quickly Azure DevOps will update their VM images with the newly released tools, but I guess it will be within days, so installing preview tooling in your build scripts won't be needed for much longer, unless you want to keep using preview tools. Note that once .NET 6 SDK's 6.0.100 goes GA, then the script that installs preview 6.0.x tooling will start installing the preview 6.0.200 previews
Community Discussions contain sources that include Stack Exchange Network
QUESTION
Azure Pipelines local agent failing to connect with SSL error
Asked 2022-Mar-29 at 19:29We have an on premise server (Windows Server 2012 R2) with an Azure Pipelines agent running on it. Today (31st Jan 2022) this agent could not longer connect to our Azure DevOps organisation.
Judging by the log files, I assume this is because it is trying to connect with an older TLS version, which as of today is no longer available - https://devblogs.microsoft.com/devops/azure-devops-services-to-require-tls-1-2/
So I followed the instructions on how to make sure TLS 1.2 was enabled, and confirmed my settings in the registry editor and by running the PowerShell script suggested here - https://docs.microsoft.com/en-us/security/engineering/solving-tls1-problem#update-windows-powershell-scripts-or-related-registry-settings
All seems ok, yet it still fails to connect with the same issue. The machine has been restarted as well. If I try the URL it is requesting in the in built Internet Explorer browser, it fails, but with Chrome it succeeds, so it must still be trying to connect with TLS 1.2, but I don't know why. I've tried reinstalling the agent (with the latest build) as well but it fails on the same error. Any suggestions?
ANSWER
Answered 2022-Jan-31 at 23:27Enabling below Cyphers with IISCrypto on the server helped us fix the issue
Cipher Suites
TLS 1.2 (suites in server-preferred order) TLS
This from Vijay's solution
QUESTION
Unable to negotiate with 40.74.28.9 port 22: no matching host key type found. Their offer: ssh-rsa
Asked 2022-Mar-28 at 15:54After start of using NixOS as a new package management system, I get the following error when using git within Azure DevOps repositories and rsa ssh key:
1jaroslavbezdek@mac> git pull
2Unable to negotiate with 40.74.28.9 port 22: no matching host key type found. Their offer: ssh-rsa
3fatal: Could not read from remote repository.
4
5Please make sure you have the correct access rights
6and the repository exists.
7
What can I do with that, please?
ANSWER
Answered 2021-Nov-12 at 12:44According to this post, you can add ssh.dev.azure.com
host config to your ~/.ssh/config
file:
Final
~/.ssh/config
that worked for me:
1jaroslavbezdek@mac> git pull
2Unable to negotiate with 40.74.28.9 port 22: no matching host key type found. Their offer: ssh-rsa
3fatal: Could not read from remote repository.
4
5Please make sure you have the correct access rights
6and the repository exists.
7Host ssh.dev.azure.com
8 HostName ssh.dev.azure.com
9 User git
10 IdentityFile ~/.ssh/id_rsa
11 IdentitiesOnly yes
12 PubkeyAcceptedAlgorithms +ssh-rsa
13 HostkeyAlgorithms +ssh-rsa
14
QUESTION
Visual Studio 2022 not showing up in the dropdown
Asked 2022-Mar-26 at 17:18We have on-prem Azure DevOps 2020 installed. We built a .net core 6 app in Visual Studio 2022. However, when creating the build pipeline, VS 2022 is not showing up in the dropdown.
Has anyone faced this problem? Is MSFT supposed to release a patch that will start displaying VS 2022 in the dropdown?
ANSWER
Answered 2022-Jan-28 at 15:20Many people are running into this. No word from MS yet on when or if an update will be available. But these articles may help you find a workaround:
FWIW, I'm working around it by using an explicit MSBuild path as mentioned in this answer. I added a PreferredMSBuildExePath
variable to my pipeline and set it equal to %ProgramFiles%\Microsoft Visual Studio\2022\Professional\MSBuild\Current\Bin\amd64\MSBuild.exe
. Then I made all my MSBuild steps use $(PreferredMSBuildExePath)
as their MSBuild path under Specify Location. I also converted all my Visual Studio steps to MSBuild steps so I could use this explicit path variable.
QUESTION
NPM install task failing in Azure Devops, same code worked previously
Asked 2022-Mar-12 at 12:38I have yaml
pipeline running a build in Azure Devops. The Npm@1
task has started failing this morning. npm install
works locally with npm version 6.14.5 and it's all green lights on npm Status.
1pool:
2 name: 'Azure Pipelines'
3 vmImage: ubuntu-latest
4
5stages:
6 - stage:
7 variables:
8 buildConfiguration: "Release"
9 buildPlatform: "AnyCPU"
10 jobs:
11 - job:
12 steps:
13 - task: Npm@1
14 displayName: 'npm install'
15 inputs:
16 workingDir: Azure/MySite/ClientApp
17
Here's where things start to go wrong in the logs:
1pool:
2 name: 'Azure Pipelines'
3 vmImage: ubuntu-latest
4
5stages:
6 - stage:
7 variables:
8 buildConfiguration: "Release"
9 buildPlatform: "AnyCPU"
10 jobs:
11 - job:
12 steps:
13 - task: Npm@1
14 displayName: 'npm install'
15 inputs:
16 workingDir: Azure/MySite/ClientApp
17
181156 verbose pkgid node-sass@4.14.1
191157 verbose cwd /home/vsts/work/1/s/Azure/MySite/ClientApp
201158 verbose Linux 5.11.0-1021-azure
211159 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
221160 verbose node v16.13.0
231161 verbose npm v8.1.0
241162 error code 1
251163 error path /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass
261164 error command failed
271165 error command sh -c node scripts/build.js
281166 error Building: /usr/local/bin/node /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
291166 error make: Entering directory '/home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass/build'
301166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast.o ../src/libsass/src/ast.cpp
311166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o ../src/libsass/src/ast_fwd_decl.cpp
321166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/backtrace.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/backtrace.o ../src/libsass/src/backtrace.cpp
331166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/base64vlq.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/base64vlq.o ../src/libsass/src/base64vlq.cpp
34
35
36
There hadn't been any changes to the package.json
in several months. Going by the error message, I've narrowed the problem down to something to do with note-sass
so here's a minimal package.json
to reproduce the error.
1pool:
2 name: 'Azure Pipelines'
3 vmImage: ubuntu-latest
4
5stages:
6 - stage:
7 variables:
8 buildConfiguration: "Release"
9 buildPlatform: "AnyCPU"
10 jobs:
11 - job:
12 steps:
13 - task: Npm@1
14 displayName: 'npm install'
15 inputs:
16 workingDir: Azure/MySite/ClientApp
17
181156 verbose pkgid node-sass@4.14.1
191157 verbose cwd /home/vsts/work/1/s/Azure/MySite/ClientApp
201158 verbose Linux 5.11.0-1021-azure
211159 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
221160 verbose node v16.13.0
231161 verbose npm v8.1.0
241162 error code 1
251163 error path /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass
261164 error command failed
271165 error command sh -c node scripts/build.js
281166 error Building: /usr/local/bin/node /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
291166 error make: Entering directory '/home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass/build'
301166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast.o ../src/libsass/src/ast.cpp
311166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o ../src/libsass/src/ast_fwd_decl.cpp
321166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/backtrace.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/backtrace.o ../src/libsass/src/backtrace.cpp
331166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/base64vlq.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/base64vlq.o ../src/libsass/src/base64vlq.cpp
34
35
36{
37 "dependencies": {
38 "node-sass": "^4.14.1"
39 }
40}
41
42
ANSWER
Answered 2021-Dec-02 at 13:14I still don't know why this started failing all of a sudden but I have resolved the problem by updating node-sass
to version 6.0.1
.
1pool:
2 name: 'Azure Pipelines'
3 vmImage: ubuntu-latest
4
5stages:
6 - stage:
7 variables:
8 buildConfiguration: "Release"
9 buildPlatform: "AnyCPU"
10 jobs:
11 - job:
12 steps:
13 - task: Npm@1
14 displayName: 'npm install'
15 inputs:
16 workingDir: Azure/MySite/ClientApp
17
181156 verbose pkgid node-sass@4.14.1
191157 verbose cwd /home/vsts/work/1/s/Azure/MySite/ClientApp
201158 verbose Linux 5.11.0-1021-azure
211159 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
221160 verbose node v16.13.0
231161 verbose npm v8.1.0
241162 error code 1
251163 error path /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass
261164 error command failed
271165 error command sh -c node scripts/build.js
281166 error Building: /usr/local/bin/node /home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
291166 error make: Entering directory '/home/vsts/work/1/s/Azure/MySite/ClientApp/node_modules/node-sass/build'
301166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast.o ../src/libsass/src/ast.cpp
311166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/ast_fwd_decl.o ../src/libsass/src/ast_fwd_decl.cpp
321166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/backtrace.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/backtrace.o ../src/libsass/src/backtrace.cpp
331166 error g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DLIBSASS_VERSION="3.5.5"' -I/home/vsts/.node-gyp/16.13.0/include/node -I/home/vsts/.node-gyp/16.13.0/src -I/home/vsts/.node-gyp/16.13.0/deps/openssl/config -I/home/vsts/.node-gyp/16.13.0/deps/openssl/openssl/include -I/home/vsts/.node-gyp/16.13.0/deps/uv/include -I/home/vsts/.node-gyp/16.13.0/deps/zlib -I/home/vsts/.node-gyp/16.13.0/deps/v8/include -I../src/libsass/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -std=gnu++14 -std=c++0x -fexceptions -frtti -MMD -MF ./Release/.deps/Release/obj.target/libsass/src/libsass/src/base64vlq.o.d.raw -c -o Release/obj.target/libsass/src/libsass/src/base64vlq.o ../src/libsass/src/base64vlq.cpp
34
35
36{
37 "dependencies": {
38 "node-sass": "^4.14.1"
39 }
40}
41
42{
43 "dependencies": {
44 "node-sass": "6.0.1"
45 }
46}
47
QUESTION
Deps File Missing for Dotnet 6 Integration Tests
Asked 2022-Feb-17 at 21:19Before I start, I've tried all suggestions from the following and none work:
Integration testing ASP.NET Core with .NET Framework - can't find deps.json
https://zimmergren.net/unable-to-find-deps-json-dotnet-azure-devops/
So I'm trying to write some integration tests for dotnet 6. However, my WebApplicationFactory
throws the following error:
System.InvalidOperationException: Can't find '/repos/subscription-info-api/tests/SubscriptionInfoApi.Tests.Integration/bin/Debug/net6.0/...
System.InvalidOperationException Can't find '/repos/subscription-info-api/tests/SubscriptionInfoApi.Tests.Integration/bin/Debug/net6.0/testhost.deps.json'. This file is required for functional tests to run properly. There should be a copy of the file on your source project bin folder. If that is not the case, make sure that the property PreserveCompilationContext is set to true on your project file. E.g 'true'. For functional tests to work they need to either run from the build output folder or the testhost.deps.json file from your application's output directory must be copied to the folder where the tests are running on. A common cause for this error is having shadow copying enabled when the tests run. at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory
1.EnsureDepsFile() at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory
1.EnsureServer() at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory1.CreateDefaultClient(DelegatingHandler[] handlers) at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory
1.CreateDefaultClient(Uri baseAddress, DelegatingHandler[] handlers) at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory1.CreateClient(WebApplicationFactoryClientOptions options) at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory
1.CreateClient() at SubscriptionInfoApi.Tests.Integration.UnitTest1.Test1() in /repos/subscription-info-api/tests/SubscriptionInfoApi.Tests.Integration/UnitTest1.cs:line 14 at SubscriptionInfoApi.Tests.Integration.UnitTest1.Test1() in /repos/subscription-info-api/tests/SubscriptionInfoApi.Tests.Integration/UnitTest1.cs:line 16 at Xunit.Sdk.TestInvoker1.<>c__DisplayClass48_0.<<InvokeTestMethodAsync>b__1>d.MoveNext() in /_/src/xunit.execution/Sdk/Frameworks/Runners/TestInvoker.cs:line 264 --- End of stack trace from previous location --- at Xunit.Sdk.ExecutionTimer.AggregateAsync(Func
1 asyncAction) in //src/xunit.execution/Sdk/Frameworks/ExecutionTimer.cs:line 48 at Xunit.Sdk.ExceptionAggregator.RunAsync(Func`1 code) in //src/xunit.core/Sdk/ExceptionAggregator.cs:line 90
My actual test code is extremely simple:
1 [Fact]
2 public async Task Test1()
3 {
4 await using var app = new WebApplicationFactory<Program>();
5 using var client = app.CreateClient();
6 var res = await (await client.GetAsync("/alive-test")).Content.ReadAsStringAsync();
7 Assert.Equal("Alive!", res);
8 }
9
As per the suggestions, I've made sure I'm directly referencing Microsoft.AspNetCore.Mvc.Testing -> 6.0.0
in my integration tests project. I've also tried the various tweaks to the .csproj
files that were suggested but nothing seems to be working.
I'm stuck for things to try to debug this further, any ideas?
ANSWER
Answered 2021-Nov-18 at 21:03You are probably targeting the wrong namespace for Program in your test file (like I was).
I had to add the following at the end of my Program.cs file (last line) to make it visible to my test projects needing it:
1 [Fact]
2 public async Task Test1()
3 {
4 await using var app = new WebApplicationFactory<Program>();
5 using var client = app.CreateClient();
6 var res = await (await client.GetAsync("/alive-test")).Content.ReadAsStringAsync();
7 Assert.Equal("Alive!", res);
8 }
9public partial class Program { }
10
An example can be found here: minimal api testing example
QUESTION
Azure, .Net, Cobertura - ##[warning]Multiple file or directory matches were found
Asked 2022-Feb-16 at 10:41Hi i am trying to get code coverage with .net5 in azure pipeline.
Run tests (not entire file)
1Starting test execution, please wait...
2A total of 1 test files matched the specified pattern.
3Results File: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59.trx
4
5Attachments:
6 /home/vsts/work/_temp/f5dd5e9f-e260-437d-80ef-4fb917215b09/coverage.cobertura.xml
7Passed! - Failed: 0, Passed: 16, Skipped: 0, Total: 16, Duration: 732 ms - /home/vsts/work/1/s/sda2021_webapi/Test/sda2021_api.tests/bin/Release/net5.0/sda2021_webapi.tests.dll (net5.0)
8Result Attachments will be stored in LogStore
9Run Attachments will be stored in LogStore
10Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
11Async Command Start: Publish test results
12Publishing test results to test run '5152'.
13TestResults To Publish 16, Test run id:5152
14Test results publishing 16, remaining: 0. Test run id: 5152
15Published Test Run : https://dev.azure.com/sda-shs/Bratislava2021/_TestManagement/Runs?runId=5152&_a=runCharts
16Async Command End: Publish test results
17Finishing: Dotnet run tests
18
Publish tests(not entire file)
1Starting test execution, please wait...
2A total of 1 test files matched the specified pattern.
3Results File: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59.trx
4
5Attachments:
6 /home/vsts/work/_temp/f5dd5e9f-e260-437d-80ef-4fb917215b09/coverage.cobertura.xml
7Passed! - Failed: 0, Passed: 16, Skipped: 0, Total: 16, Duration: 732 ms - /home/vsts/work/1/s/sda2021_webapi/Test/sda2021_api.tests/bin/Release/net5.0/sda2021_webapi.tests.dll (net5.0)
8Result Attachments will be stored in LogStore
9Run Attachments will be stored in LogStore
10Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
11Async Command Start: Publish test results
12Publishing test results to test run '5152'.
13TestResults To Publish 16, Test run id:5152
14Test results publishing 16, remaining: 0. Test run id: 5152
15Published Test Run : https://dev.azure.com/sda-shs/Bratislava2021/_TestManagement/Runs?runId=5152&_a=runCharts
16Async Command End: Publish test results
17Finishing: Dotnet run tests
18##[warning]Multiple file or directory matches were found. Using the first match: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59/In/fv-az43-964/coverage.cobertura.xml
19/opt/hostedtoolcache/dotnet/dotnet /home/vsts/work/_tasks/PublishCodeCoverageResults_2a7ebc54-c13e-490e-81a5-d7561ab7cd97/1.189.0/netcoreapp2.0/ReportGenerator.dll -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml -targetdir:/home/vsts/work/_temp/cchtml -reporttypes:HtmlInline_AzurePipelines
202021-08-25T08:32:03: Arguments
212021-08-25T08:32:03: -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml
22
And of course my pipeline
1Starting test execution, please wait...
2A total of 1 test files matched the specified pattern.
3Results File: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59.trx
4
5Attachments:
6 /home/vsts/work/_temp/f5dd5e9f-e260-437d-80ef-4fb917215b09/coverage.cobertura.xml
7Passed! - Failed: 0, Passed: 16, Skipped: 0, Total: 16, Duration: 732 ms - /home/vsts/work/1/s/sda2021_webapi/Test/sda2021_api.tests/bin/Release/net5.0/sda2021_webapi.tests.dll (net5.0)
8Result Attachments will be stored in LogStore
9Run Attachments will be stored in LogStore
10Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
11Async Command Start: Publish test results
12Publishing test results to test run '5152'.
13TestResults To Publish 16, Test run id:5152
14Test results publishing 16, remaining: 0. Test run id: 5152
15Published Test Run : https://dev.azure.com/sda-shs/Bratislava2021/_TestManagement/Runs?runId=5152&_a=runCharts
16Async Command End: Publish test results
17Finishing: Dotnet run tests
18##[warning]Multiple file or directory matches were found. Using the first match: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59/In/fv-az43-964/coverage.cobertura.xml
19/opt/hostedtoolcache/dotnet/dotnet /home/vsts/work/_tasks/PublishCodeCoverageResults_2a7ebc54-c13e-490e-81a5-d7561ab7cd97/1.189.0/netcoreapp2.0/ReportGenerator.dll -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml -targetdir:/home/vsts/work/_temp/cchtml -reporttypes:HtmlInline_AzurePipelines
202021-08-25T08:32:03: Arguments
212021-08-25T08:32:03: -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml
22task: DotNetCoreCLI@2
23 displayName: Dotnet run tests
24 inputs:
25 command: "test"
26 projects: "**/xxxxx/*.tests.csproj"
27 arguments: '--configuration Release /p:CoverletOutputFormat=cobertura --collect:"XPlat Code Coverage" --no-build'
28 testRunTitle: "xxxx"
29 - task: PublishCodeCoverageResults@1
30 displayName: "publish coverage results"
31 inputs:
32 codeCoverageTool: "Cobertura"
33 summaryFileLocation: "$(Agent.TempDirectory)/**/coverage.cobertura.xml"
34
Why is more then one XML generated? I am basically balancing between no XML and more XML. I am just unable to generate one XML. (on my localhost it generates only one) Thanks for any tips.
ANSWER
Answered 2021-Aug-25 at 08:52Please replace your PublishCodeCoverageResults
with following steps:
1Starting test execution, please wait...
2A total of 1 test files matched the specified pattern.
3Results File: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59.trx
4
5Attachments:
6 /home/vsts/work/_temp/f5dd5e9f-e260-437d-80ef-4fb917215b09/coverage.cobertura.xml
7Passed! - Failed: 0, Passed: 16, Skipped: 0, Total: 16, Duration: 732 ms - /home/vsts/work/1/s/sda2021_webapi/Test/sda2021_api.tests/bin/Release/net5.0/sda2021_webapi.tests.dll (net5.0)
8Result Attachments will be stored in LogStore
9Run Attachments will be stored in LogStore
10Info: Azure Pipelines hosted agents have been updated and now contain .Net 5.x SDK/Runtime along with the older .Net Core version which are currently lts. Unless you have locked down a SDK version for your project(s), 5.x SDK might be picked up which might have breaking behavior as compared to previous versions. You can learn more about the breaking changes here: https://docs.microsoft.com/en-us/dotnet/core/tools/ and https://docs.microsoft.com/en-us/dotnet/core/compatibility/ . To learn about more such changes and troubleshoot, refer here: https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/dotnet-core-cli?view=azure-devops#troubleshooting
11Async Command Start: Publish test results
12Publishing test results to test run '5152'.
13TestResults To Publish 16, Test run id:5152
14Test results publishing 16, remaining: 0. Test run id: 5152
15Published Test Run : https://dev.azure.com/sda-shs/Bratislava2021/_TestManagement/Runs?runId=5152&_a=runCharts
16Async Command End: Publish test results
17Finishing: Dotnet run tests
18##[warning]Multiple file or directory matches were found. Using the first match: /home/vsts/work/_temp/_fv-az43-964_2021-08-25_08_31_59/In/fv-az43-964/coverage.cobertura.xml
19/opt/hostedtoolcache/dotnet/dotnet /home/vsts/work/_tasks/PublishCodeCoverageResults_2a7ebc54-c13e-490e-81a5-d7561ab7cd97/1.189.0/netcoreapp2.0/ReportGenerator.dll -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml -targetdir:/home/vsts/work/_temp/cchtml -reporttypes:HtmlInline_AzurePipelines
202021-08-25T08:32:03: Arguments
212021-08-25T08:32:03: -reports:/home/vsts/work/_temp/**/coverage.cobertura.xml
22task: DotNetCoreCLI@2
23 displayName: Dotnet run tests
24 inputs:
25 command: "test"
26 projects: "**/xxxxx/*.tests.csproj"
27 arguments: '--configuration Release /p:CoverletOutputFormat=cobertura --collect:"XPlat Code Coverage" --no-build'
28 testRunTitle: "xxxx"
29 - task: PublishCodeCoverageResults@1
30 displayName: "publish coverage results"
31 inputs:
32 codeCoverageTool: "Cobertura"
33 summaryFileLocation: "$(Agent.TempDirectory)/**/coverage.cobertura.xml"
34 - task: reportgenerator@4
35 displayName: 'Merge code coverage reports'
36 inputs:
37 reports: '$(Agent.TempDirectory)/**/coverage.cobertura.xml'
38 targetdir: '$(Pipeline.Workspace)/coverlet'
39 reporttypes: 'Cobertura'
40 verbosity: 'Verbose'
41
42 - task: PublishCodeCoverageResults@1
43 displayName: 'Publish code coverage results'
44 inputs:
45 codeCoverageTool: Cobertura
46 summaryFileLocation: '$(Pipeline.Workspace)/coverlet/Cobertura.xml'
47
And you have multiple files, because probably you have more than one test project.
QUESTION
C# WASM without Blazor
Asked 2022-Jan-30 at 14:27I want to be able to call C# code from JavaScript. The mono project used to have a WASM SDK that you could download from their old Jenkins server, but that is no longer public. Existing docs tend to point toward those builds. The Azure Devops builds do not include this SDK. A few messages I've seen on their Github account indicate that they are now focusing on the .NET 6 for WASM. I do not wish to use the Blazor components. Is there a way in .NET 6 to build a minimally sized WASM binary without the Blazor UI?
ANSWER
Answered 2021-Aug-26 at 01:25Yes it's absolutely possible. Blazor does not have a monopoly on C#/WASM and it's far from clear that it's going to wind up being the best long term option (and a lot of evidence it's not).
I recommend starting with the Uno WASM Bootstrap. https://github.com/unoplatform/Uno.Wasm.Bootstrap
QUESTION
Azure DevOps Build pipeline `npm install` failing on node-gyp
Asked 2021-Dec-20 at 12:31We have a CD/CI Azure Devops build pipeline that has started failing for nodejs/node-gyp
.
error gyp info using node-gyp@3.8.0
error gyp info using node@16.13.0 | win32 | x64
Nothing about our build pipeline has changed, the pool we use is:
1pool:
2 vmImage: 'windows-latest'
3
Which is still mapped to windows-2019
https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml.
The pipeline fails when we hit the following task in the YAML file:
1pool:
2 vmImage: 'windows-latest'
3- task: Npm@1
4 displayName: 'npm install'
5 inputs:
6 command: 'install'
7 workingDir: 'FrontEnd'
8 verbose: true
9
Log file:
1pool:
2 vmImage: 'windows-latest'
3- task: Npm@1
4 displayName: 'npm install'
5 inputs:
6 command: 'install'
7 workingDir: 'FrontEnd'
8 verbose: true
9error gyp ERR! UNCAUGHT EXCEPTION
10error gyp ERR! stack Error: spawn C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\15.0\Bin\MSBuild.exe ENOENT
11error gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:282:19)
12error gyp ERR! stack at onErrorNT (node:internal/child_process:477:16)
13error gyp ERR! stack at processTicksAndRejections (node:internal/process/task_queues:83:21)
14error gyp ERR! System Windows_NT 10.0.17763
15error gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\a\\1\\s\\Presentation\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
16error gyp ERR! cwd D:\a\1\s\FrontEnd\node_modules\node-sass
17error gyp ERR! node -v v16.13.0
18error gyp ERR! node-gyp -v v3.8.0
19error gyp ERR! This is a bug in `node-gyp`.
20error gyp ERR! Try to update node-gyp and file an Issue if it does not help:
21error gyp ERR! <https://github.com/nodejs/node-gyp/issues>
22error Build failed with error code: 7
23verbose exit 1
24
25##[error]Error: Npm failed with return code: 1
26
ANSWER
Answered 2021-Dec-13 at 09:42Azure auto updated the version of node it was using, pushing the required version of node-gyp forward too, this lead to all of our builds failing. The versions it pushed to were:
Add task: NodeTool@0
to set the Node version to the last passed version which for us was:
The end code looks like this:
1pool:
2 vmImage: 'windows-latest'
3- task: Npm@1
4 displayName: 'npm install'
5 inputs:
6 command: 'install'
7 workingDir: 'FrontEnd'
8 verbose: true
9error gyp ERR! UNCAUGHT EXCEPTION
10error gyp ERR! stack Error: spawn C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\15.0\Bin\MSBuild.exe ENOENT
11error gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:282:19)
12error gyp ERR! stack at onErrorNT (node:internal/child_process:477:16)
13error gyp ERR! stack at processTicksAndRejections (node:internal/process/task_queues:83:21)
14error gyp ERR! System Windows_NT 10.0.17763
15error gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\a\\1\\s\\Presentation\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
16error gyp ERR! cwd D:\a\1\s\FrontEnd\node_modules\node-sass
17error gyp ERR! node -v v16.13.0
18error gyp ERR! node-gyp -v v3.8.0
19error gyp ERR! This is a bug in `node-gyp`.
20error gyp ERR! Try to update node-gyp and file an Issue if it does not help:
21error gyp ERR! <https://github.com/nodejs/node-gyp/issues>
22error Build failed with error code: 7
23verbose exit 1
24
25##[error]Error: Npm failed with return code: 1
26- task: NodeTool@0
27 inputs:
28 versionSpec: '14.x'
29
30- task: Npm@1
31 displayName: 'npm install'
32 inputs:
33 command: 'install'
34 workingDir: 'FrontEnd'
35 verbose: true
36
After re-running the pipeline it works again and produces artefacts.
QUESTION
How can I suppress or resolve "info: detecting host provider for..." in Git?
Asked 2021-Nov-25 at 13:09I'm getting the following output when executing a fetch / pull via a powershell script:
info: detecting host provider for '[devops site address]'...
Normally, this wouldn't be an issue, however, Azure DevOps sees this output as an error and labels the release stage as such. Is there a way I can either suppress this output, or resolve it via GIT?
The remote location for the repository is an on-prem version of DevOps.
Thanks!
ANSWER
Answered 2021-Nov-25 at 13:09This comes indeed from the GCM used by Git.
You can either downgrade to Git 2.32, or wait for the recently released Git-Credential-Manager-Core v2.0.603, which does remove those messages.
Said release is not yet packaged with the latest Git for Windows, like the recent 2.34.0, but expect it in 2.34.1.
A set GCM_PROVIDER=generic
could help too.
Update Nov. 25th, 2021: Git for Windows 2.34.1 has been released, and it does include Git Credential Manager Core v2.0.605.12951.
That GCM 2.0.605 includes "Remove noisy messages during auto-detection" (#492, #494).
QUESTION
Azure Devops - Hosted pool - ubuntu latest - How do i get ubuntu-latest to have the latest visual studio build tools (preview 2022)?
Asked 2021-Nov-05 at 14:04Our azure devops pipelines are configured to use hosted ubuntu-latest
I am using Azure Functions that require the package: packages/microsoft.net.sdk.functions/4.0.0 The hosted ubuntu latest is throwing non compatible framework version error.
1 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
2 error : It was not possible to find any compatible framework version
3 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
4 error : The framework 'Microsoft.NETCore.App', version
5 '6.0.0-rc.1.21451.13' was not found.**
6
When changing the pool to run on an on premise build agent, I was able to install the latest build tools (the one that comes with visual studio 2022 preview) and everything works fine. My question is how do I get the ubuntu-latest to have the latest dotnet build tools?
This is the output of dotnet info of the ubuntu-latest agent.
1 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
2 error : It was not possible to find any compatible framework version
3 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
4 error : The framework 'Microsoft.NETCore.App', version
5 '6.0.0-rc.1.21451.13' was not found.**
62021-10-27T04:54:16.4629465Z .NET SDKs installed:
72021-10-27T04:54:16.4630372Z 2.1.302 [/usr/share/dotnet/sdk]
82021-10-27T04:54:16.4630865Z 2.1.403 [/usr/share/dotnet/sdk]
92021-10-27T04:54:16.4631327Z 2.1.526 [/usr/share/dotnet/sdk]
102021-10-27T04:54:16.4631821Z 2.1.617 [/usr/share/dotnet/sdk]
112021-10-27T04:54:16.4632292Z 2.1.701 [/usr/share/dotnet/sdk]
122021-10-27T04:54:16.4632746Z 2.1.818 [/usr/share/dotnet/sdk]
132021-10-27T04:54:16.4633218Z 3.1.120 [/usr/share/dotnet/sdk]
142021-10-27T04:54:16.4633687Z 3.1.202 [/usr/share/dotnet/sdk]
152021-10-27T04:54:16.4634147Z 3.1.302 [/usr/share/dotnet/sdk]
162021-10-27T04:54:16.4634616Z 3.1.414 [/usr/share/dotnet/sdk]
172021-10-27T04:54:16.4635086Z 5.0.104 [/usr/share/dotnet/sdk]
182021-10-27T04:54:16.4635541Z 5.0.208 [/usr/share/dotnet/sdk]
192021-10-27T04:54:16.4636008Z 5.0.303 [/usr/share/dotnet/sdk]
202021-10-27T04:54:16.4636462Z 5.0.402 [/usr/share/dotnet/sdk]
212021-10-27T04:54:16.4636703Z
222021-10-27T04:54:16.4637082Z .NET runtimes installed:
232021-10-27T04:54:16.4637683Z Microsoft.AspNetCore.All 2.1.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
242021-10-27T04:54:16.4638405Z Microsoft.AspNetCore.All 2.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
252021-10-27T04:54:16.4639112Z Microsoft.AspNetCore.All 2.1.12 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
262021-10-27T04:54:16.4639839Z Microsoft.AspNetCore.All 2.1.24 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
272021-10-27T04:54:16.4640553Z Microsoft.AspNetCore.All 2.1.30 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
282021-10-27T04:54:16.4641691Z Microsoft.AspNetCore.App 2.1.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
292021-10-27T04:54:16.4642420Z Microsoft.AspNetCore.App 2.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
302021-10-27T04:54:16.4643130Z Microsoft.AspNetCore.App 2.1.12 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
312021-10-27T04:54:16.4643823Z Microsoft.AspNetCore.App 2.1.24 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
322021-10-27T04:54:16.4644541Z Microsoft.AspNetCore.App 2.1.30 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
332021-10-27T04:54:16.4645263Z Microsoft.AspNetCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
342021-10-27T04:54:16.4645958Z Microsoft.AspNetCore.App 3.1.6 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
352021-10-27T04:54:16.4646889Z Microsoft.AspNetCore.App 3.1.20 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
362021-10-27T04:54:16.4647598Z Microsoft.AspNetCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
372021-10-27T04:54:16.4648286Z Microsoft.AspNetCore.App 5.0.9 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
382021-10-27T04:54:16.4648995Z Microsoft.AspNetCore.App 5.0.11 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
392021-10-27T04:54:16.4649693Z Microsoft.NETCore.App 2.1.2 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
402021-10-27T04:54:16.4650357Z Microsoft.NETCore.App 2.1.5 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
412021-10-27T04:54:16.4651045Z Microsoft.NETCore.App 2.1.12 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
422021-10-27T04:54:16.4651737Z Microsoft.NETCore.App 2.1.24 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
432021-10-27T04:54:16.4652407Z Microsoft.NETCore.App 2.1.30 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
442021-10-27T04:54:16.4653101Z Microsoft.NETCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
452021-10-27T04:54:16.4653781Z Microsoft.NETCore.App 3.1.6 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
462021-10-27T04:54:16.4654445Z Microsoft.NETCore.App 3.1.20 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
472021-10-27T04:54:16.4655124Z Microsoft.NETCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
482021-10-27T04:54:16.4655799Z Microsoft.NETCore.App 5.0.9 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
492021-10-27T04:54:16.4656459Z Microsoft.NETCore.App 5.0.11 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
502021-10-27T04:54:16.4656807Z
51
ANSWER
Answered 2021-Nov-05 at 14:04use this in your pipeline definition:
1 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
2 error : It was not possible to find any compatible framework version
3 /home/vsts/.nuget/packages/microsoft.net.sdk.functions/4.0.0/build/Microsoft.NET.Sdk.Functions.Build.targets(32,5):
4 error : The framework 'Microsoft.NETCore.App', version
5 '6.0.0-rc.1.21451.13' was not found.**
62021-10-27T04:54:16.4629465Z .NET SDKs installed:
72021-10-27T04:54:16.4630372Z 2.1.302 [/usr/share/dotnet/sdk]
82021-10-27T04:54:16.4630865Z 2.1.403 [/usr/share/dotnet/sdk]
92021-10-27T04:54:16.4631327Z 2.1.526 [/usr/share/dotnet/sdk]
102021-10-27T04:54:16.4631821Z 2.1.617 [/usr/share/dotnet/sdk]
112021-10-27T04:54:16.4632292Z 2.1.701 [/usr/share/dotnet/sdk]
122021-10-27T04:54:16.4632746Z 2.1.818 [/usr/share/dotnet/sdk]
132021-10-27T04:54:16.4633218Z 3.1.120 [/usr/share/dotnet/sdk]
142021-10-27T04:54:16.4633687Z 3.1.202 [/usr/share/dotnet/sdk]
152021-10-27T04:54:16.4634147Z 3.1.302 [/usr/share/dotnet/sdk]
162021-10-27T04:54:16.4634616Z 3.1.414 [/usr/share/dotnet/sdk]
172021-10-27T04:54:16.4635086Z 5.0.104 [/usr/share/dotnet/sdk]
182021-10-27T04:54:16.4635541Z 5.0.208 [/usr/share/dotnet/sdk]
192021-10-27T04:54:16.4636008Z 5.0.303 [/usr/share/dotnet/sdk]
202021-10-27T04:54:16.4636462Z 5.0.402 [/usr/share/dotnet/sdk]
212021-10-27T04:54:16.4636703Z
222021-10-27T04:54:16.4637082Z .NET runtimes installed:
232021-10-27T04:54:16.4637683Z Microsoft.AspNetCore.All 2.1.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
242021-10-27T04:54:16.4638405Z Microsoft.AspNetCore.All 2.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
252021-10-27T04:54:16.4639112Z Microsoft.AspNetCore.All 2.1.12 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
262021-10-27T04:54:16.4639839Z Microsoft.AspNetCore.All 2.1.24 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
272021-10-27T04:54:16.4640553Z Microsoft.AspNetCore.All 2.1.30 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
282021-10-27T04:54:16.4641691Z Microsoft.AspNetCore.App 2.1.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
292021-10-27T04:54:16.4642420Z Microsoft.AspNetCore.App 2.1.5 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
302021-10-27T04:54:16.4643130Z Microsoft.AspNetCore.App 2.1.12 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
312021-10-27T04:54:16.4643823Z Microsoft.AspNetCore.App 2.1.24 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
322021-10-27T04:54:16.4644541Z Microsoft.AspNetCore.App 2.1.30 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
332021-10-27T04:54:16.4645263Z Microsoft.AspNetCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
342021-10-27T04:54:16.4645958Z Microsoft.AspNetCore.App 3.1.6 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
352021-10-27T04:54:16.4646889Z Microsoft.AspNetCore.App 3.1.20 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
362021-10-27T04:54:16.4647598Z Microsoft.AspNetCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
372021-10-27T04:54:16.4648286Z Microsoft.AspNetCore.App 5.0.9 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
382021-10-27T04:54:16.4648995Z Microsoft.AspNetCore.App 5.0.11 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
392021-10-27T04:54:16.4649693Z Microsoft.NETCore.App 2.1.2 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
402021-10-27T04:54:16.4650357Z Microsoft.NETCore.App 2.1.5 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
412021-10-27T04:54:16.4651045Z Microsoft.NETCore.App 2.1.12 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
422021-10-27T04:54:16.4651737Z Microsoft.NETCore.App 2.1.24 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
432021-10-27T04:54:16.4652407Z Microsoft.NETCore.App 2.1.30 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
442021-10-27T04:54:16.4653101Z Microsoft.NETCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
452021-10-27T04:54:16.4653781Z Microsoft.NETCore.App 3.1.6 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
462021-10-27T04:54:16.4654445Z Microsoft.NETCore.App 3.1.20 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
472021-10-27T04:54:16.4655124Z Microsoft.NETCore.App 5.0.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
482021-10-27T04:54:16.4655799Z Microsoft.NETCore.App 5.0.9 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
492021-10-27T04:54:16.4656459Z Microsoft.NETCore.App 5.0.11 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
502021-10-27T04:54:16.4656807Z
51- task: UseDotNet@2
52 displayName: 'Use .NET Core sdk'
53 inputs:
54 version: 6.0.x
55 includePreviewVersions: true
56
To explain, firstly Visual Studio only runs on Windows, so you can't install Visual Studio on Linux, but that's fine because you actually only want the .NET SDK. Secondly, both Visual Studio 2022 and .NET 6 are in preview.
Next, Azure DevOps have documented what software is pre-installed on all their hosted agents: https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software
If you follow the link to .NET Core SDK on Ubuntu 20.04 (latest), you see that they only pre-install Generally Available (GA; released) versions of the .NET SDK, not preview versions. After all, most customers building their production applications don't want the risk of using preview tools that might have bugs and break their builds.
So, if you want a preview .NET SDK, you need to explicitly install it as part of your build steps. The UseDotNet task does that, allowing you to specify a bunch of parameters, but in this case the most important two are version and include preview versions.
For other scenarios, for example anyone not using Azure Pipelines, the .NET team also have dotnet-install scripts, which you can download and execute in your pipeline.
For what it's worth, .NET 6 is having a launch party on the 9th to the 11th of November, and Visual Studio 2022 is having a launch event on the 8th of November. I don't know how quickly Azure DevOps will update their VM images with the newly released tools, but I guess it will be within days, so installing preview tooling in your build scripts won't be needed for much longer, unless you want to keep using preview tools. Note that once .NET 6 SDK's 6.0.100 goes GA, then the script that installs preview 6.0.x tooling will start installing the preview 6.0.200 previews
Community Discussions contain sources that include Stack Exchange Network
Tutorials and Learning Resources are not available at this moment for Devops
Share this Page
Get latest updates on Devops
Open Weaver – Develop Applications Faster with Open Source