Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add simple unit tests for server #32

Merged
merged 5 commits into from
Nov 12, 2023
Merged

Conversation

eyurtsev
Copy link
Contributor

  • Adds a simple unit tests to test one of the api endpoints

import os

# Temporary handling of environment variables for testing
os.environ["REDIS_URL"] = "redis://localhost:6379/3"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pretty hacky, but we can update afterwards to pick up settings properly

@eyurtsev eyurtsev merged commit d11ff09 into harrison/stateful Nov 12, 2023
7 checks passed
@eyurtsev eyurtsev deleted the eugene/add_app_tests branch November 12, 2023 21:16
}

# Check not visible to other users
headers = {"Cookie": "opengpts_user_id=2 flushdb"}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a header to flush db?

hwchase17 added a commit that referenced this pull request Nov 13, 2023
* start statefullness

* cr

* cr

* cr

* Fix

* with_types

* cr

* Fix uuids

* expose session_id

* cr

* cr

* Add thread and assistant storage endpoints

* Add deps

* Add message list to output value of list_threads

* Return created objects

* Frontend: store bots in backend

* Update api

* Finish frontend

* Finish frontend

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* secrets

* Update deps

* Fix gpt4

* fe: sort chats and configs

* Lint

* Lint

* Comment

* Storage helper funcs

* Fix chat order

* Add loading state for thread history

* Add more loading states

* Add research preview banner

* Add scoping on user_id

* Lint

* Fix chat history

* Finish file upload api and frontend

* Clear files when switcing configs

* Make assistants shareable

* Some work for feedback buttons

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* x

* Add redis service to CI (#24)

Add redis service to CI (still not used by tests)

* Set up tests with redis (#26)

- Add testing with redis
- Fix bug in ingest runnable
- Add RunnableBindingBase to this repo until it's merged and released via langchain

* x (#27)

* x

* cr

* cr

* cr

* cr

* Make tests work

* Format, lint
* Add new env varaibles to make file
* Comment out code that's not been released on langchain

* Fix missing deps

* Display bot name

* Fix stream state not resetting when switching threads

* Display error message

* Display file errors, accummulate files

* Fix bottom padding, move public link button to top

* Add icon to view config for bot used in current chat

* Add tool markdown descriptions

* Add feedback buttons

* Add tests for endpoints involving storage on server (#32)

Add tests for endpoints involving storage

* x

* x (#34)

* Add some validation to endpoints (#35)

Add a bit more validation to endpoints

* Use models with longer context windows

* Update gcp env file

* Remove dupe

* Use disabled var

* Disable autofocus on new bot name

* Add libmagic

* Lint

* Better public bot share link

* Add feature public bots

* Localize access to REDIS_URL (#36)

* Localize a bit access to REDIS_URL

* cr

---------

Co-authored-by: Nuno Campos <nuno@boringbits.io>
Co-authored-by: Eugene Yurtsev <eyurtsev@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants