azure-sdk-for-js
azure-sdk-for-js copied to clipboard
[identity] Samples are failing but pipeline continues to pass
Example: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=3972356&view=logs&j=4eaf6b84-07d0-5e66-f484-4e9defa3fc2f&t=c0bbcefe-75de-57d8-29b4-466c419539c4
Because we catch exceptions and log them, the pipeline continues to pass even when samples fail which they have been for quite some time.
Instead, we should either:
- Remove the
catch, replacing it withthenand letting errors propagate - Exit with exit code 1 in catch handlers (example: https://github.com/Azure/azure-sdk-for-js/blob/23705058f33df420a29c795bd9e0d67f0a03bede/sdk/keyvault/keyvault-keys/samples-dev/helloWorld.ts#L71-L74)
Then we need fix the samples that are failing of course