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

Basic management of variants in one place + Result view #123

Merged
merged 15 commits into from
Oct 11, 2023

Conversation

JoeAtHPI
Copy link
Collaborator

Adds an Exploriants Block, which has two tabs:

  • One tab which collects all variants in any method. Changing one variant here will change the original ones as well. Saving in Exploriants will recompile the methods.
  • A Result Tab, which executes all active examples through any permutation of variants and collects the watches users have set. Users can see through all permutations and apply the one they find gets the most wanted result.

This is currently a pragmatic solution and MVP without deeper integration testing or UI quality.

Features which were added:

  • SBVariantProxy takes inspiration from SBLinkedCopy for copying variants and keeping consistent state between the two objects. A new class was introduced as SBLinkedCopy assumed the original was an artefact itself. For variants, a few extra methods must be called too
  • Inactive watches: SBExampleWatch saves values for each example which reported values. When inactive, it will keep these results displayed and will not update itself in the future. When updating the modified expression, it will apply this on itself on an artefactChanged
  • SBExploriants as a tab view of things which users might find interesting
  • SBExploriantsView is a tab in Exploriants and currently consists of the variants and results
  • SBPermutation is a helper class to manage a permutation of alternative selections

image
image

@JoeAtHPI JoeAtHPI added enhancement New feature or request Exploriants labels Sep 18, 2023
@JoeAtHPI JoeAtHPI requested a review from tom95 September 18, 2023 16:43
@JoeAtHPI JoeAtHPI self-assigned this Sep 18, 2023
@github-actions
Copy link

github-actions bot commented Sep 18, 2023

Pull Request Test Coverage Report for Build 6482065396

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 0.0%

Totals Coverage Status
Change from base Build 6050508530: 0.0%
Covered Lines: 0
Relevant Lines: 0

💛 - Coveralls

Copy link
Collaborator

@tom95 tom95 left a comment

Choose a reason for hiding this comment

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

Features look great! Some minor structural things :)

@@ -371,7 +377,7 @@ SBTabView >> removeCurrentTab [
{ #category : #tabs }
SBTabView >> setActive: aNamedBlock [

self sandblockEditor do:
SBEditor current do:
Copy link
Collaborator

Choose a reason for hiding this comment

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

why was this change necessary?

Copy link
Collaborator

Choose a reason for hiding this comment

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

(also in the other places)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

when creating the exploriants block, the block is first created and then added to the editor. should it be the other way around?

packages/Sandblocks-Core/SBResultsView.class.st Outdated Show resolved Hide resolved
packages/Sandblocks-Smalltalk/SBPermutation.class.st Outdated Show resolved Hide resolved
@@ -3,7 +3,8 @@ Class {
#superclass : #SBStSubstitution,
Copy link
Collaborator

Choose a reason for hiding this comment

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

noticed late but maybe we want to move this one to -Babylonian as well?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

it's in the same category as toggledcode - and even though toggledcode might become obsolete in the future, the thought of different code paths does not relate to live programming at first glance imo

@@ -0,0 +1,122 @@
Class {
Copy link
Collaborator

Choose a reason for hiding this comment

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

probably best at home in -Babylonian, too

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

same as above

@JoeAtHPI JoeAtHPI requested a review from tom95 October 11, 2023 11:49
@tom95 tom95 merged commit ad50e0c into master Oct 11, 2023
2 checks passed
@JoeAtHPI JoeAtHPI deleted the feature/variant-view branch November 24, 2023 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Exploriants
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants