mustafa-tariqk / mindscape

Experience the truth of the trip
https://research.cs.queensu.ca/home/cisc498/index.html
MIT License
16 stars 0 forks source link

Updating auth to be compatible with segmented frontend/backend #73

Closed mustafa-tariqk closed 5 months ago

mustafa-tariqk commented 5 months ago

What does this PR do?

Add CORS support across the board, update auth to work if frontend/backend in different places (i.e. port 3000/8080 or even diff websites)

Also changed testing to be an env variable vs set in app.py

Github Issue Number

Resolves: #57 #74

Relates to: n/a

Warning: Introduces breaking changes. Format future fetch requests like the following

            fetch('http://localhost:8080/start_chat' + user_id, {
                method: 'GET',
                mode: 'cors',
                credentials: 'include',
                headers: {
                    'Content-Type': 'application/json'
                }
            })

Author checklist

If any of these points have yet to be satisfied, make sure that you set the title to the format DRAFT #issue-num Title

Reviewer checklist