Skip to content

Add file system directory for SICP workspace #2408

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

Merged
merged 4 commits into from
Apr 2, 2023

Conversation

ianyong
Copy link
Member

@ianyong ianyong commented Apr 2, 2023

Description

It turns out that the SICP workspace makes use of the Playground component which introduces terrible coupling between the playground workspace and the SICP workspace. Thankfully, Folder mode has been implemented in a generic enough way that adding a new directory to the in-browser file system along with changing the Redux store defaults fixes the issue.

Fixes #2407.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update
  • Code quality improvements

How to test

Test that the code snippets in the interactive SICP work.

@ianyong ianyong requested a review from zhaojj2209 April 2, 2023 09:50
@ianyong
Copy link
Member Author

ianyong commented Apr 2, 2023

It turns out that the SICP workspace makes use of the Playground component which introduces terrible coupling between the playground workspace and the SICP workspace.

We really should spin out a separate component for the SICP workspace. As more features get added to the Source Academy, this tight coupling will only make development harder.

@coveralls
Copy link

Pull Request Test Coverage Report for Build 4588066085

  • 3 of 11 (27.27%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.01%) to 34.848%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/pages/playground/Playground.tsx 0 8 0.0%
Totals Coverage Status
Change from base Build 4587815156: 0.01%
Covered Lines: 4793
Relevant Lines: 12814

💛 - Coveralls

@RichDom2185
Copy link
Member

It turns out that the SICP workspace makes use of the Playground component which introduces terrible coupling between the playground workspace and the SICP workspace.

We really should spin out a separate component for the SICP workspace. As more features get added to the Source Academy, this tight coupling will only make development harder.

Agreed, could you kindly create an issue for this and link it to this PR? Thanks!

@ianyong ianyong merged commit 3e377ba into master Apr 2, 2023
@ianyong ianyong deleted the add-file-system-directory-for-sicp-workspace branch April 2, 2023 12:31
RichDom2185 pushed a commit to NUS-CS1101S/cadet-frontend that referenced this pull request Jul 15, 2023
* Make Playground component workspace-agnostic

Why does the SICP workspace make use of the playground? Who thought
this was a great idea???

* Add BrowserFS directory for SICP workspace

* Set default file path when resetting SICP workspace

* Update tests
@coveralls
Copy link

coveralls commented Sep 22, 2024

Pull Request Test Coverage Report for Build 4588066085

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 3 of 11 (27.27%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.01%) to 34.848%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/pages/playground/Playground.tsx 0 8 0.0%
Totals Coverage Status
Change from base Build 4587815156: 0.01%
Covered Lines: 4793
Relevant Lines: 12814

💛 - Coveralls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SICP code snippets not loading
4 participants