🔧 fix: URL params, package mismatch, typing, shared link redirect, and o1 (azure) (#4899)

* fix: double decoding of URL params

* fix: prevent streaming options for O1 model (azure)

* fix: update @langchain/openai to version 0.3.14 in package-lock.json

* chore(AuthContext): typing

* chore(useTimeout): typing

* fix: shared link redirecting to login when code block includes "Run Code" button

* fix: typing
This commit is contained in:
Danny Avila 2024-12-07 16:55:17 -05:00 committed by GitHub
parent 85d92c2353
commit 2875380bf1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 41 additions and 22 deletions

View file

@ -14,13 +14,11 @@ export default function useQueryParams({
const maxAttempts = 50; // 5 seconds maximum (50 * 100ms)
useEffect(() => {
const promptParam = searchParams.get('prompt');
if (!promptParam) {
const decodedPrompt = searchParams.get('prompt') ?? '';
if (!decodedPrompt) {
return;
}
const decodedPrompt = decodeURIComponent(promptParam);
const intervalId = setInterval(() => {
// If already processed or max attempts reached, clear interval and stop
if (processedRef.current || attemptsRef.current >= maxAttempts) {