profile
viewpoint
遗忘

vscodewinodws/runtime 0

.NET is a cross-platform runtime for cloud, mobile, desktop, and IoT apps.

create barnchvscodewinodws/runtime

branch : mailaddresstostringserialize

created branch time in a month

fork vscodewinodws/runtime

.NET is a cross-platform runtime for cloud, mobile, desktop, and IoT apps.

https://docs.microsoft.com/dotnet/core/

fork in a month

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

but i seems to be able to work with many more solutions and very few has kind of weird errors

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

  • Did `\artifacts\bin\ref\net5.0\System.Linq.dll' exist?

yes it exist now , I rebuild the project and this particular solution vs does not complains any error as it should be , and it's working fine regarding my issue i check more couple of solutions and found they are working with vs.

but one System.text.json has weird errors vs shows rebuild all 4 project successful

image

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

just to update i have latest vs preview installed . but still shows error in code

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

i did that as well executed build.cmd from build.cmd but still errors persist , vs shows the error as shows in below image with

image

and log for vs stack trace open log file

===================== 28-05-2020 03:08:08 Recoverable System.AggregateException: Project system data flow 'DataflowBlockSlim (ActionBlockSlimAsync1 : 52753602)' closed because of an exception: System.AggregateException: One or more errors occurred. ---> System.ArgumentException: Must contain activeTargetFramework (Unsupported,Version=v0.0). Parameter name: dependenciesByTargetFramework at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Snapshot.DependenciesSnapshot..ctor(String projectPath, ITargetFramework activeTargetFramework, ImmutableDictionary2 dependenciesByTargetFramework) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Snapshot.DependenciesSnapshot.SetTargets(ImmutableArray1 targetFrameworks, ITargetFramework activeTargetFramework) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<>c__DisplayClass38_0.<UpdateProjectContextAndSubscriptionsAsync>b__2(DependenciesSnapshot previousSnapshot) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.SnapshotUpdater.TryUpdate(Func2 updateFunc, CancellationToken token) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<<UpdateProjectContextAndSubscriptionsAsync>b__38_0>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.Threading.SemaphoreSlimExtensions.<ExecuteWithinLockAsync>d__1.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<<OnProjectFactoryCompletedAsync>g__OnActiveConfiguredProjectEvaluatedAsync|30_1>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.ProjectSystem.DataReceivingBlockSlim1.<ProcessInputQueueAsync>d__5.MoveNext() --- End of inner exception stack trace --- ---> (Inner Exception #0) System.ArgumentException: Must contain activeTargetFramework (Unsupported,Version=v0.0). Parameter name: dependenciesByTargetFramework at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Snapshot.DependenciesSnapshot..ctor(String projectPath, ITargetFramework activeTargetFramework, ImmutableDictionary2 dependenciesByTargetFramework) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Snapshot.DependenciesSnapshot.SetTargets(ImmutableArray1 targetFrameworks, ITargetFramework activeTargetFramework) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<>c__DisplayClass38_0.<UpdateProjectContextAndSubscriptionsAsync>b__2(DependenciesSnapshot previousSnapshot) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.SnapshotUpdater.TryUpdate(Func2 updateFunc, CancellationToken token) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<<UpdateProjectContextAndSubscriptionsAsync>b__38_0>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.Threading.SemaphoreSlimExtensions.<ExecuteWithinLockAsync>d__1.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<<OnProjectFactoryCompletedAsync>g__OnActiveConfiguredProjectEvaluatedAsync|30_1>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.ProjectSystem.DataReceivingBlockSlim1.<ProcessInputQueueAsync>d__5.MoveNext()<--- . ---> System.ArgumentException: Must contain activeTargetFramework (Unsupported,Version=v0.0). Parameter name: dependenciesByTargetFramework at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Snapshot.DependenciesSnapshot..ctor(String projectPath, ITargetFramework activeTargetFramework, ImmutableDictionary2 dependenciesByTargetFramework) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Snapshot.DependenciesSnapshot.SetTargets(ImmutableArray1 targetFrameworks, ITargetFramework activeTargetFramework) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<>c__DisplayClass38_0.<UpdateProjectContextAndSubscriptionsAsync>b__2(DependenciesSnapshot previousSnapshot) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.SnapshotUpdater.TryUpdate(Func2 updateFunc, CancellationToken token) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<<UpdateProjectContextAndSubscriptionsAsync>b__38_0>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.Threading.SemaphoreSlimExtensions.<ExecuteWithinLockAsync>d__1.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<<OnProjectFactoryCompletedAsync>g__OnActiveConfiguredProjectEvaluatedAsync|30_1>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.ProjectSystem.DataReceivingBlockSlim1.<ProcessInputQueueAsync>d__5.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at Microsoft.VisualStudio.ProjectSystem.CommonProjectSystemTools.Rethrow(Exception ex) at Microsoft.VisualStudio.ProjectSystem.ProjectErrorReporting.<>c__DisplayClass6_0.<SubmitErrorReport>b__0() at Microsoft.VisualStudio.ProjectSystem.ExceptionFilter.<>c__DisplayClass2_0.<Guard>g__action|0() at GuardMethodClass.GuardMethod(Func1 , Func2 , Func2 ) --- End of inner exception stack trace --- ---> (Inner Exception #0) System.ArgumentException: Must contain activeTargetFramework (Unsupported,Version=v0.0). Parameter name: dependenciesByTargetFramework at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Snapshot.DependenciesSnapshot..ctor(String projectPath, ITargetFramework activeTargetFramework, ImmutableDictionary2 dependenciesByTargetFramework) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Snapshot.DependenciesSnapshot.SetTargets(ImmutableArray1 targetFrameworks, ITargetFramework activeTargetFramework) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<>c__DisplayClass38_0.<UpdateProjectContextAndSubscriptionsAsync>b__2(DependenciesSnapshot previousSnapshot) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.SnapshotUpdater.TryUpdate(Func2 updateFunc, CancellationToken token) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<<UpdateProjectContextAndSubscriptionsAsync>b__38_0>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.Threading.SemaphoreSlimExtensions.<ExecuteWithinLockAsync>d__1.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.ProjectSystem.VS.Tree.Dependencies.Subscriptions.DependenciesSnapshotProvider.<<OnProjectFactoryCompletedAsync>g__OnActiveConfiguredProjectEvaluatedAsync|30_1>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.ProjectSystem.DataReceivingBlockSlim1.<ProcessInputQueueAsync>d__5.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at Microsoft.VisualStudio.ProjectSystem.CommonProjectSystemTools.Rethrow(Exception ex) at Microsoft.VisualStudio.ProjectSystem.ProjectErrorReporting.<>c__DisplayClass6_0.<SubmitErrorReport>b__0() at Microsoft.VisualStudio.ProjectSystem.ExceptionFilter.<>c__DisplayClass2_0.<Guard>g__action|0() at GuardMethodClass.GuardMethod(Func1 , Func2 , Func`2 )<---

===================

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

just to add few words with preview version of vs , shows same error with latest preview

vscodewinodws

comment created time in 2 months

issue commentAzure/azure-sdk-for-net

write azure sdk logs to console , events log or any other way to get sdk logs

please find my below code that does not logs to console

using System; using Azure.Core.Diagnostics; using System.Diagnostics.Tracing; using Azure.Storage.Blobs; using Microsoft.Azure.Management.ResourceManager.Fluent; using Microsoft.Azure.Management.ResourceManager.Fluent.Authentication; using Microsoft.Azure.Management.ResourceManager.Fluent.Core; using System.Diagnostics.CodeAnalysis; using Microsoft.Azure.Management.Fluent; using Microsoft.Azure.Management.Compute.Fluent; using Microsoft.Azure.Management.AppService.Fluent; using System.Threading.Tasks;

namespace azurelogs { class Program { public async static Task Main(string[] args) { using AzureEventSourceListener listener = AzureEventSourceListener.CreateConsoleLogger(EventLevel.Verbose);

        VirtualMachineData virtualMachineData = new VirtualMachineData("myresourcegroup", "myresourcename", "my client id", "my client password", "tenantid", "subscription");

        var res = await virtualMachineData.RestartVirtualMachineAsync();

        Console.WriteLine(res);


        Console.ReadLine();

    }
}


public class AzureData
{

    [NotNull]
    protected IAzure AzureObj { get; private set; }



    public AzureData(string clientId, string clientSecret, string tenantId, string subscription)
    {
        if (string.IsNullOrEmpty(clientId) || string.IsNullOrWhiteSpace(clientId))
        {
            throw new ArgumentException("arg was null", nameof(clientId));
        }

        if (string.IsNullOrEmpty(clientSecret) || string.IsNullOrWhiteSpace(clientSecret))
        {
            throw new ArgumentException("arg was null", nameof(clientSecret));
        }

        if (string.IsNullOrEmpty(tenantId) || string.IsNullOrWhiteSpace(tenantId))
        {
            throw new ArgumentException("arg was null", nameof(tenantId));
        }

        if (string.IsNullOrEmpty(subscription) || string.IsNullOrWhiteSpace(subscription))
        {
            throw new ArgumentException("arg was null", nameof(subscription));
        }

        InitAzureObj(subscription, clientId, clientSecret, tenantId);


    }



    public void InitAzureObj(string Subsciption, string clientId, string clientSecret, string tenantId)
    {
        if (string.IsNullOrEmpty(Subsciption))
        {
            throw new ArgumentException("arg was null", nameof(Subsciption));
        }

        if (string.IsNullOrEmpty(clientId))
        {
            throw new ArgumentException("arg was null", nameof(clientId));
        }

        if (string.IsNullOrEmpty(clientSecret))
        {
            throw new ArgumentException("arg was null", nameof(clientSecret));
        }

        if (string.IsNullOrEmpty(tenantId))
        {
            throw new ArgumentException("arg was null", nameof(tenantId));
        }

        try
        {


            if (string.IsNullOrEmpty(Subsciption) || string.IsNullOrWhiteSpace(Subsciption))
            {
                throw new ArgumentNullException($"Azure subscription was null , value {Subsciption}");
            }


            AzureObj = Microsoft.Azure.Management.Fluent.Azure
                       .Configure()
                       .WithLogLevel(HttpLoggingDelegatingHandler.Level.BodyAndHeaders)
                       .Authenticate(InitAzureAppCrdentials(clientId, clientSecret, tenantId))
                       .WithSubscription(Subsciption);




        }
        catch (Exception ex)
        {
            Console.WriteLine(ex);
        }
    }



    private AzureCredentials InitAzureAppCrdentials(string ClientId, string ClientSecret, string TenantId)
    {
        if (string.IsNullOrEmpty(ClientId))
        {
            throw new ArgumentException("arg was null", nameof(ClientId));
        }

        if (string.IsNullOrEmpty(ClientSecret))
        {
            throw new ArgumentException("arg was null", nameof(ClientSecret));
        }

        if (string.IsNullOrEmpty(TenantId))
        {
            throw new ArgumentException("arg was null", nameof(TenantId));
        }

        try
        {
            var x = SdkContext.AzureCredentialsFactory.FromServicePrincipal(ClientId, ClientSecret, TenantId, AzureEnvironment.AzureGlobalCloud);


            return x;


        }
        catch (Exception ex)
        {


            Console.WriteLine(ex);

            return null;
        }
    }

}



public class VirtualMachineData : AzureData
{
    [DisallowNull]
    private string ResourceName { get; }

    [DisallowNull]
    private string ResourceGroupName { get; }

    private IVirtualMachines AzureVM { get; }


    public async Task<bool> RestartVirtualMachineAsync()
    {
        try
        {
            if (string.IsNullOrEmpty(ResourceGroupName) || string.IsNullOrWhiteSpace(ResourceGroupName))
            {
                throw new ArgumentException("arg was null", nameof(ResourceGroupName));
            }

            if (string.IsNullOrEmpty(ResourceName) || string.IsNullOrWhiteSpace(ResourceName))
            {
                throw new ArgumentException("arg was null", nameof(ResourceName));
            }



            var vmid = await AzureVM.GetByResourceGroupAsync(ResourceGroupName, ResourceName).ConfigureAwait(false);


            if (vmid != null)
            {



                await vmid.RestartAsync().ConfigureAwait(false);



                return true;
            }
            else
            {


                return false;
            }




        }
        catch (Exception ex)
        {
            return false;

        }
    }


    public VirtualMachineData(string? resourcegroup, string? resourcename, string clinetid, string clientsecret, string tenantid, string subscription) : base(clinetid, clientsecret, tenantid, subscription)
    {

        ResourceGroupName = resourcegroup;

        ResourceName = resourcename;

        AzureVM = AzureObj.VirtualMachines;

    }


}

}

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

as per your suggestion i executed command

build.cmd libs.tests -restore

with below op

image

when i see few solution e.g system.console are working fine after this restore but System.Text.Json , System.net.http etc shows the errors but very few compare to earlier

i have executed clean and rebuild also but does not seems to be working as expected , please see below image

any advice for me ?

vscodewinodws

comment created time in 2 months

issue commentAzure/azure-sdk-for-net

write azure sdk logs to console , events log or any other way to get sdk logs

yes sure will share example soon

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

trying it out will ping you back with results

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

there are so many different errors in different solutions adding snap for one of solution

system.console

image so if i open other solution there are different set of errors preventing me to write code and send pr

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

yes i did that and it was successful

vscodewinodws

comment created time in 2 months

issue commentAzure/azure-sdk-for-net

write azure sdk logs to console , events log or any other way to get sdk logs

your example is perfectly working and showing the expected output , but in my case i am doing various vm operations ( nuget are already updated and have latest libs) but when i put the same code it does not shows the log info , i am doing various operations e.g start , restart , stop , deallocate etc .

so any guess what is wrong here , even i tried to place the code inside the restart (restart async) method but it did not shown any log , if you need i can share code example.

vscodewinodws

comment created time in 2 months

issue commentdotnet/runtime

how to open library in visual studio in order to contribute

yes by your suggestion i downloaded exe for the preview sdk and installed it and it is working as expected it solved my half problem , but the strange errors visual studio still reports by opening solutions i think it should be not there since i got the code when build was passing and green so can you help me here ?

vscodewinodws

comment created time in 2 months

issue commentAzure/azure-sdk-for-net

write azure sdk logs to console , events log or any other way to get sdk logs

i tried but not working can you provide small app ?

vscodewinodws

comment created time in 2 months

issue openeddotnet/runtime

how to open library in visual studio in order to contribute

i want to contribute to the .net core so for that i cloned runtime and the build it , i got it build successfully . but when i follow this for the building libs

i have executed build.cmd command then trying to open in vs

https://github.com/dotnet/runtime/tree/master/docs/workflow/building/libraries

it gets visual studio open ( i tried both preview and stable ) but both shows error in code , there are so many errors in different solution , but i know this might be not the case i might be wrong .

apart from it if i go to the directory and try to open solution it shows error Unable to locate the .NET Core SDK. Check that it is installed and that the version specified in global.json (if any) matches the installed version.

i can not see that this specific version (5.0.100-preview.5.20251.2) in installed in my machine with the dotnet info command but during build.cmd i see it is downloading the this version 5.0.100-preview.5.20251.2 but opening with vs does not works and i never got success to build it can any one guide me on correct way to do it ?

created time in 2 months

issue openedAzure/azure-sdk-for-net

write azure sdk logs to console , events log or any other way to get sdk logs

Query/Question i want to log everything sdk is doing behind the method call.

i know this functionality exist, it has pr and issue as well and it has documentation for it

https://github.com/Azure/azure-sdk-for-net/issues/7556

https://docs.microsoft.com/en-us/dotnet/azure/sdk/logging

but using console or event logs i tried but sdk is not showing me any log in console or events (one more question in Linux where events will be stored ?)

i tried as per docs but found it's not giving expected output it so any one can help me here .

fyi i have already updated all nugets .

Environment: windows 10

  • Hosting platform or OS and .NET runtime version dotnet core 3.1

  • IDE and version : Visual Studio 16.6

created time in 2 months

issue commentAzure/azure-sdk-for-net

Ship console logger listener with Azure.Core

can you provide the example for it https://docs.microsoft.com/en-us/dotnet/azure/sdk/logging using this page info with below code as shown in docs with createconsolelogger does not print anything

using AzureEventSourceListener listener = AzureEventSourceListener.CreateConsoleLogger();

as well as i wan to know where it should be placed , i am facing issue with sdk and not able to get any exceptions i think this well help me a lot to find info

pakrym

comment created time in 2 months

startedmicrosoft/ProjectReunion

started time in 2 months

startedmicrosoft/winget-cli

started time in 2 months

starteddotnet/maui

started time in 2 months

issue commentAzure/azure-sdk-for-net

get virtual machines Resource health and health history

you are correct but api response for me does not shows the data back

vscodewinodws

comment created time in 2 months

issue commentAzure/azure-sdk-for-net

get virtual machines Resource health and health history

yes i seems able to find it over the internet but thanks for sharing, i used those rest api and i was able to retrieve Health history but the api is not showing any data for the status unknown , apart from it i am able to get all those , can you suggest to get unknow as well ?

vscodewinodws

comment created time in 2 months

issue commentAzure/azure-sdk-for-net

get virtual machines Resource health and health history

if method is not available in sdk i am also open to access using rest api , but from docs i am also not able to find that , i am not sure that api ( either sdk method, prop / azure rest api ) exist or not ?

vscodewinodws

comment created time in 2 months

issue openedAzure/azure-sdk-for-net

get virtual machines Resource health and health history

Query/Question How can we help?

i want to get virtual machines Resource health and health history from sdk using my c# code but seems there is no way to get it so if i am missing something please guide how to do it.

Environment:

  • Name and version of the Library package used: Microsoft.Azure.Management.Fluent 1.31.1 i am on this version but i can upgrade it if needed.
  • Hosting platform or OS and .NET runtime version (dotnet --info output for .NET Core projects): windows 10 with .net core 3.1
  • IDE and version : Visual Studio 16.4

created time in 2 months

issue closedAzure/azure-sdk-for-net

[QUERY] the remote certificate is invalid according to the validation procedure

Query/Question How can we help?

i want to pass httpclienthandler to by pass ssl erros on my cent os machine , i am aware this is not correct way to make it run but on my cent os server it has issue or miss configuration by communicating any azure rest api it shows below exception

the remote certificate is invalid according to the validation procedure

i am clearly aware that this is ssl certificate issue on the server i have and on other machines i have azure api works fine but i want to by pass ssl check using

httpClientHandler.ServerCertificateCustomValidationCallback = HttpClientHandler.DangerousAcceptAnyServerCertificateValidator;

so i can make it run on the server having issue .

is there any way i can pass httpClientHandler with HttpClientHandler.DangerousAcceptAnyServerCertificateValidator property so all call azure calls will ignore ssl errors ?

Environment: cent os 7 , .NET core 3.1] IDE and version : [e.g. Visual Studio 16.4]

closed time in 2 months

vscodewinodws

issue commentAzure/azure-sdk-for-net

[QUERY] the remote certificate is invalid according to the validation procedure

although it was not issue of azure sdk nor .net core (below link says for some linux distro ), i think there should be a way to pass custom http handler as argument as optional argument ?

https://github.com/dotnet/core/blob/master/Documentation/linux-setup.md#ssl-certificate-resolution-with-snap-installs

closing issue since it was platform dependent thing but i still recommend to pass custom http handler along with dependent object can help many others as well.

thanks.

vscodewinodws

comment created time in 2 months

issue commentAzure/azure-sdk-for-net

[QUERY] the remote certificate is invalid according to the validation procedure

i am still looking for a way to pass custom httpClientHandler for information only now , since i found that cent os machin had issue with the ssl certificate

and i resolved using below link if anybody needs in future

https://github.com/dotnet/core/blob/master/Documentation/linux-setup.md#ssl-certificate-resolution-with-snap-installs

vscodewinodws

comment created time in 2 months

issue commentAzure/azure-sdk-for-net

[QUERY] the remote certificate is invalid according to the validation procedure

@pakrym i found that httpClientHandler client handler is get only property in rest client , i am not using rest client and all available methods does not seems me to allow my httpClientHandler as argument what can ne done here ?

vscodewinodws

comment created time in 3 months

issue commentAzure/azure-sdk-for-net

[QUERY] the remote certificate is invalid according to the validation procedure

@pakrym i seen link you share but i am unsure at where we can attach it , for eg i have below code which gets azure object, docs stated that it should be in retry policy so i unsure about it can you help a bit here ?

Azure.Configure() .WithLogLevel(HttpLoggingDelegatingHandler.Level.BodyAndHeaders) .Authenticate(InitAzureAppCrdentials(clientId, clientSecret, tenantId)) .WithSubscription(Subsciption);

vscodewinodws

comment created time in 3 months

issue openedAzure/azure-sdk-for-net

[QUERY] the remote certificate is invalid according to the validation procedure

Query/Question How can we help?

i want to pass httpclienthandler to by pass ssl erros on my cent os machine , i am aware this is not correct way to make it run but on my cent os server it has issue or miss configuration by communicating any azure rest api it shows below exception

the remote certificate is invalid according to the validation procedure

i am clearly aware that this is ssl certificate issue on the server i have and on other machines i have azure api works fine but i want to by pass ssl check using

httpClientHandler.ServerCertificateCustomValidationCallback = HttpClientHandler.DangerousAcceptAnyServerCertificateValidator;

so i can make it run on the server having issue .

Environment: cent os 7 , .NET core 3.1] IDE and version : [e.g. Visual Studio 16.4]

created time in 3 months

more