Skip to content

integrate conductor into frontend #3084

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 24 commits into from
Feb 20, 2025
Merged

Conversation

tsammeow
Copy link
Contributor

@tsammeow tsammeow commented Feb 4, 2025

Description

integrated conductor system for a standard language implementation interface

implemented basic feature flag system

new conductor execution system is hidden behind the conductor.enable flag.

also upgraded yarn (4.6.0) to enable prepack script to be run automatically when installing raw dependencies

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

old behaviour was left untouched; no changes to tests.

publicFlags.ts contains a list of "public" flags to be displayed in some sort of UI later

set flag `conductor.enable` to true to use conductor execution
this enables use of prepack hooks to automatically build raw deps on install
resolved yarn lockfile merge conflict by regenerating based on local copy
@RichDom2185 RichDom2185 mentioned this pull request Feb 4, 2025
7 tasks
@RichDom2185
Copy link
Member

#3091 will fix the CI issues (hopefully)

Copy link
Member

@RichDom2185 RichDom2185 left a comment

Choose a reason for hiding this comment

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

Can also change ci.yml, and build-development.yml to use yarn install --immutable instead of yarn install --frozen-lockfile?

@coveralls
Copy link

coveralls commented Feb 5, 2025

Pull Request Test Coverage Report for Build 13384070990

Details

  • 30 of 131 (22.9%) changed or added relevant lines in 17 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.08%) to 31.118%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/commons/featureFlags/FeatureFlag.ts 5 6 83.33%
src/commons/featureFlags/publicFlags.ts 0 1 0.0%
src/commons/sagas/WorkspaceSaga/index.ts 1 2 50.0%
src/commons/dropdown/DropdownSettings.tsx 1 3 33.33%
src/commons/featureFlags/index.ts 5 7 71.43%
src/features/conductor/BrowserHostPlugin.ts 0 4 0.0%
src/features/conductor/createConductor.ts 0 5 0.0%
src/commons/sagas/WorkspaceSaga/helpers/evalCode.ts 1 33 3.03%
src/pages/featureFlags/FeatureFlags.tsx 0 53 0.0%
Totals Coverage Status
Change from base Build 13372832091: -0.08%
Covered Lines: 4870
Relevant Lines: 14775

💛 - Coveralls

this should fix webpack complaining about the dynamic import
also make feature flags a full class, and add evaluator url flag
…tFeature -> selectFeatureSaga

this makes it clear that selectFeature is intended to be called from redux-saga
…t should be a no-op

also change featureSelector to take a flag instead of just its name
@tsammeow tsammeow requested a review from RichDom2185 February 10, 2025 09:23
@tsammeow
Copy link
Contributor Author

hold on, there's a small bug with the repl eval button, will fix in a bit

@tsammeow tsammeow marked this pull request as draft February 11, 2025 05:21
@tsammeow tsammeow marked this pull request as ready for review February 11, 2025 07:48
@tsammeow
Copy link
Contributor Author

eval bug is fixed and there should be no change in behaviour when conductor.enable is off

there's a ui bug in conductor mode where running something in the repl while the runner isn't running will make it look like the runner is running, even though it will not be started (this is due to isRunning being set to true in replReducer/evalRepl - i cannot check the feature flag in this reducer to switch behaviour off)

@martin-henz martin-henz self-requested a review February 18, 2025 05:12
Copy link
Member

@martin-henz martin-henz left a comment

Choose a reason for hiding this comment

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

Reviewed with Sam. Looks good!

@martin-henz martin-henz enabled auto-merge (squash) February 18, 2025 05:13
Copy link
Member

@RichDom2185 RichDom2185 left a comment

Choose a reason for hiding this comment

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

Implementation wise, LGTM, thanks!

But please try to follow the code style and conventions (e.g. import style, variable names, file locations) next time (or even in a follow-up PR)

@martin-henz martin-henz merged commit 7e1a243 into source-academy:master Feb 20, 2025
6 checks passed
@tsammeow tsammeow mentioned this pull request Feb 24, 2025
6 tasks
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.

4 participants