Compare commits

...

2 Commits

Author SHA1 Message Date
zxhlyh
3d9c8d76b9 fix: version check 2025-02-13 14:44:24 +08:00
非法操作
9ac6662635 fix: agent thought not saved (#13631) 2025-02-13 10:17:39 +08:00
2 changed files with 8 additions and 4 deletions

View File

@@ -329,6 +329,7 @@ class BaseAgentRunner(AppRunner):
)
if not updated_agent_thought:
raise ValueError("agent thought not found")
agent_thought = updated_agent_thought
if thought:
agent_thought.thought = thought

View File

@@ -112,10 +112,13 @@ export const AppContextProvider: FC<AppContextProviderProps> = ({ children }) =>
if (userProfileResponse && !userProfileResponse.bodyUsed) {
const result = await userProfileResponse.json()
setUserProfile(result)
const current_version = userProfileResponse.headers.get('x-version')
const current_env = process.env.NODE_ENV === 'development' ? 'DEVELOPMENT' : userProfileResponse.headers.get('x-env')
const versionData = await fetchLanggeniusVersion({ url: '/version', params: { current_version } })
setLangeniusVersionInfo({ ...versionData, current_version, latest_version: versionData.version, current_env })
if (process.env.NEXT_PUBLIC_SITE_ABOUT !== 'hide' && document?.body?.getAttribute('data-public-site-about') !== 'hide') {
const current_version = userProfileResponse.headers.get('x-version')
const current_env = process.env.NODE_ENV === 'development' ? 'DEVELOPMENT' : userProfileResponse.headers.get('x-env')
const versionData = await fetchLanggeniusVersion({ url: '/version', params: { current_version } })
setLangeniusVersionInfo({ ...versionData, current_version, latest_version: versionData.version, current_env })
}
}
}, [userProfileResponse])