-
-
Notifications
You must be signed in to change notification settings - Fork 133
[WIP] feat(api): Integration of FCC Proper endpoints and Dynamic Student Data #576
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
base: main
Are you sure you want to change the base?
Conversation
…tudent data display Co-Authored by: @utsab Co-Authored by: @CarlyAThomas Co-Authored by: @ZhenyuYu1
|
Important: This issue won't be able to pass the checks because there's an unresolved TODO comment. This TODO comment refers to an PR #567 works to solve this issue. After #567 is merged, we can come back to this PR and make necessary edits. Important: This issue also requires that the endpoints are set up and available on FreeCodeCamp Proper. For now, we have a PR to set this up (PR #62063). However, until this PR is merged, testing this will require that you set up FCC Proper locally and add the changes mentioned in this PR. (Additionally, comment out ' Important: The PR #574 works to populate this challenge map from freeCodeCamp's curriculum GraphQL endpoints. Important: The logic for fetching student data assumes that each student in the classroom has already been onboarded onto the Classroom app. Thus, each student will need to have accepted a Classroom join link from their teacher, then linked their existing FreeCodeCamp Account, with the Classroom Account permission set up(PR #62891). The full onboarding flow will be implemented in a future PR. However, for testing this data, developers will need to manually set up each student in their prisma studio instance. |
|
Wonderful! Thank you for putting this together! I did notice a couple things:
I think this version of the challengeMapUtils.js may be better than the one in PR #574 and we should go through this with @utsab. |
| completedChallenges.forEach(challenge => { | ||
| const mapEntry = challengeMap[challenge.id]; | ||
| if (!mapEntry) { | ||
| // DEBUG: Print missing challenge IDs, confirm with curriculum team if these challenge IDs are no longer valid. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They have confirmed that we are to ignore missing challenge map IDs as they are in reference to old steps that are no longer included or tracked (therefore legacy) and we do not list legacy data. The only reason for keeping the notation is in case they might wanted the debug option here. Otherwise this notation can be removed.
Co-Authored by: @utsab
Co-Authored by: @CarlyAThomas
Co-Authored by: @ZhenyuYu1
Checklist:
Update index.md)Update to #548
Description
This PR is an update that branches off of the changes mentioned in PR #549.
Since #549 was created, the classroom team has discussed in detail the workflows involved in retrieving student data from the base freeCodeCamp application, and we've since updated the API endpoints (PR #62063) on freeCodeCamp.
This PR goes over the workflow for pulling student's data from the
get-user-dataendpoint in freeCodeCamp, then processing that data against a mapping of every challenge ID to its related metadata, before displaying it in the app.What is blocking this PR:
Important: This issue won't be able to pass the checks because there's an unresolved TODO comment. This TODO comment refers to an
import prismaline inapi_proccesor.js, which causes the app to break if left in. If removed, the app will work fine, as prisma has been imported elsewhere and Next.js allows it to work inapi_proccesor.js. But ESLint rules require that prisma is explicitly imported inapi_proccesor.jssince we're using it in the file.PR #567 works to solve this issue. After #567 is merged, we can come back to this PR and make necessary edits.
Important: This issue also requires that the endpoints are set up and available on FreeCodeCamp Proper. For now, we have a PR to set this up (PR #62063). However, until this PR is merged, testing this will require that you set up FCC Proper locally and add the changes mentioned in this PR. (Additionally, comment out '
, isClassroomAccount: true' in line 40 and 'isClassroomAccount: true' in line 80. The Classroom Account permissions in PR #62891 setting has not been implemented yet).Important: The
challengeMap.jsonfile is intended to be a comprehensive mapping of every freeCodeCamp challenge ID to the challenge's name, block, and superblock. The logic for fetching student data and validating it against this map assumes that thechallengeMap.jsonis populated and up-to-date.PR #574 works to populate this challenge map from freeCodeCamp's curriculum GraphQL endpoints.
Important: The logic for fetching student data assumes that each student in the classroom has already been onboarded onto the Classroom app. Thus, each student will need to have accepted a Classroom join link from their teacher, then linked their existing FreeCodeCamp Account, with the Classroom Account permission set up(PR #62891).
The full onboarding flow will be implemented in a future PR. However, for testing this data, developers will need to manually set up each student in their prisma studio instance.