mirror of
https://github.com/pacnpal/Roo-Code.git
synced 2025-12-20 04:11:10 -05:00
feat: implement error handling for Azure AI model API interactions
This commit is contained in:
@@ -246,7 +246,9 @@ const AzureAiModelPicker: React.FC = () => {
|
|||||||
onClick: () => {
|
onClick: () => {
|
||||||
const apiConfig = {
|
const apiConfig = {
|
||||||
...apiConfiguration,
|
...apiConfiguration,
|
||||||
azureAiModelConfig: azureAiModelInfoSaneDefaults,
|
azureAiModelConfig: {
|
||||||
|
...azureAiModelInfoSaneDefaults,
|
||||||
|
},
|
||||||
}
|
}
|
||||||
setApiConfiguration(apiConfig)
|
setApiConfiguration(apiConfig)
|
||||||
onUpdateApiConfig(apiConfig)
|
onUpdateApiConfig(apiConfig)
|
||||||
@@ -300,14 +302,12 @@ const AzureAiModelPicker: React.FC = () => {
|
|||||||
const apiConfig = {
|
const apiConfig = {
|
||||||
...apiConfiguration,
|
...apiConfiguration,
|
||||||
azureAiModelConfig: {
|
azureAiModelConfig: {
|
||||||
...(apiConfiguration?.azureAiModelConfig ||
|
...azureAiModelInfoSaneDefaults,
|
||||||
azureAiModelInfoSaneDefaults),
|
...(apiConfiguration?.azureAiModelConfig || {}),
|
||||||
contextWindow:
|
contextWindow:
|
||||||
e.target.value === ""
|
isNaN(parsed) || e.target.value === ""
|
||||||
? undefined
|
? azureAiModelInfoSaneDefaults.contextWindow
|
||||||
: isNaN(parsed)
|
: parsed,
|
||||||
? azureAiModelInfoSaneDefaults.contextWindow
|
|
||||||
: parsed,
|
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
setApiConfiguration(apiConfig)
|
setApiConfiguration(apiConfig)
|
||||||
|
|||||||
Reference in New Issue
Block a user