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

Switch ExperimentsParamsAndMetricsTree to string | ParamsAndMetricsItem tree type #700

Merged
merged 6 commits into from
Aug 3, 2021

Conversation

mattseddon
Copy link
Contributor

@mattseddon mattseddon commented Aug 1, 2021

1/2 master <- this <- #703

This PR brings the data held inside of the ExperimentsParamsAndMetricsTree in line with the new format for our treeViews.

Note: My opinion now is that having more data in the tree makes them harder to test and I am concerned that by having more data exposed in more places that we could run into state issues.

@mattseddon mattseddon changed the title Switch ExperimentsParamsAndMetricsTree to string | ParamsAndMetricsItem tree type Switch ExperimentsParamsAndMetricsTree to string | ParamsAndMetricsItem tree type Aug 1, 2021
@mattseddon mattseddon marked this pull request as ready for review August 3, 2021 05:45
@codeclimate
Copy link

codeclimate bot commented Aug 3, 2021

Code Climate has analyzed commit acffc32 and detected 2 issues on this pull request.

Here's the issue category breakdown:

Category Count
Duplication 2

The test coverage on the diff in this pull request is 100.0% (85% is the threshold).

This pull request will bring the total coverage in the repository to 94.3% (0.0% change).

View more on Code Climate.

@rogermparent rogermparent merged commit 5ba2e56 into master Aug 3, 2021
@rogermparent rogermparent deleted the update-params-and-metrics-tree branch August 3, 2021 17:16
rogermparent pushed a commit that referenced this pull request Aug 3, 2021
…Item tree type (#700)

* move params and metrics tree to mixed type

* remove get param or metric methods where possible

* rework tree data type

* improve test

* improve test variable names
mattseddon added a commit that referenced this pull request Aug 11, 2021
* Get sortBy tree to the point where it displays sorts

* Adapt to renamed field

* Big refactor

- Split getChildren branches into methods
- Await experiments for root
- Turn getSort into getSorts (multi sorts not actually implemented)

* Sort sortByTree roots like paramsAndMetricsTree roots

* Add contextValue to TreeItems

* Remove accidentally merged file

* Revert file accidentally changed by merge

* Add commands to tree title and add tests

* Build mocked TreeItem that uses contructor

* Remove double mocks

* Remove unused mocks

* Prefix TreeItem contextValues with dvc

* Rename clearSort to clearSorts

* Add multi-sort capability to sort function

* More multi-sort support with test for sort function

* Add another test

* Add multi-sort functionality

* Fix integration test

* add windows hide option for windows users (#701)

* Switch `ExperimentsParamsAndMetricsTree` to string | ParamsAndMetricsItem tree type (#700)

* move params and metrics tree to mixed type

* remove get param or metric methods where possible

* rework tree data type

* improve test

* improve test variable names

* Add createTreeView wrapper (#703)

* move params and metrics tree to mixed type

* remove get param or metric methods where possible

* rework tree data type

* improve test

* improve test variable names

* add create tree view wrapper

Co-authored-by: rogermparent <rogermparent@gmail.com>

* add notes on disabling cli analytics to help performance (#699)

Co-authored-by: Roger <rogermparent@gmail.com>

* Add basic integration test and make sortBy non-mutating

* Add multi-sort to sorts integration test

* Add single sort removal to integration test

* Use removeAllSorts for final clear

* Add repo-level addSort and rework data piping so await works for it

* Add "all items are equal" test for multi-sort

* Add sort modification to integration test

* Return this.notifyChanged again to simplify diff

* clearExperimentsTableSort -> removeExperimentsTableSorts

* Rename a few commands and combine removeSorts commands

* Display empty array when there are are projects but no sorts

* Use createTreeView utility

* Change pluckTestParams inline helper to be a no-arg function

* Trim back sort integration test data to only params

* Rename command strings and remove unused ones

* Combine add and remove sort commands

* Swap removeSort params and use getRepository

* import { join } from 'path'

* interface SortDefinitionWithParent => type SortItem

* build => pick and simplify buildExperimentSortFunction

* Inline pickSort into experiments repository class, can => should

* Remove getOrPickRepo and change removeSorts behavior to be like filters

* Add another entry to integration test data

Co-authored-by: mattseddon <37993418+mattseddon@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants