'Azure cli cant connect due to Invalid client secret provided
Pipeline error code AADSTS7000215- Invalid client secret is provided. however, the client secret provided is correct because when I run the script locally and provide client secret in .env file it runs. However, creating a yaml file with azurecli I get the error.
- task: AzureCLI@2
inputs:
azureSubscription: 'Subscription'
scriptType: 'pscore'
scriptLocation: 'inlineScript'
inlineScript: 'python script.py'
workingDirectory: 'workingdirectory'
Full ERROR: AADSTS7000215: Invalid client secret provided. Ensure the secret being sent in the request is the client secret value, not the client secret ID, for a secret added to app
Solution 1:[1]
Client secret error might be related to service connection you use. Did you verify that service connection and related SPN are properly configured?
Solution 2:[2]
Here is how you can use a bar chart to get (what I assume is your) desired result:
from matplotlib import pyplot as plt
import pandas as pd
import random # For creating example dataframe
# Define example dataframe
df = pd.DataFrame([random.choice(("setosa", "versicolor", "virginica")) for _ in range(100)], columns=("species",))
value_counts = df["species"].value_counts()
# Optional, just for checking the values are correct
print(value_counts)
# The important bit
plt.bar(value_counts.index, value_counts, width=0.4)
plt.xlabel("Species")
plt.ylabel("Number")
plt.show()
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Greg |
| Solution 2 |
