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

routes: rename workflows to workspace #1183

Merged
merged 2 commits into from
Jan 11, 2023

Conversation

oliver-sanders
Copy link
Member

As mentioned on Element

  • Rename the #/workflows route to #/workspace.
  • Split the GScan component into a view and component.
  • Use the #/workflows route for GScan.
  • Remove the sidebar for the standalone views.

Ideally get this into 1.4.0 before this gets into peoples browser history.

Requirements check-list

  • I have read CONTRIBUTING.md and added my name as a Code Contributor.
  • Contains logically grouped changes (else tidy your branch by rebase).
  • Does not contain off-topic changes (use other PRs for other changes).
  • Does not need tests (why?).
  • Appropriate change log entry included.
  • No documentation update required.

@oliver-sanders oliver-sanders added this to the 1.4.0 milestone Jan 4, 2023
@oliver-sanders oliver-sanders self-assigned this Jan 4, 2023
Comment on lines -203 to -214
import { mapState } from 'vuex'
import { mdiFilter } from '@mdi/js'
import uniq from 'lodash/uniq'
import subscriptionComponentMixin from '@/mixins/subscriptionComponent'
import TaskState from '@/model/TaskState.model'
import SubscriptionQuery from '@/model/SubscriptionQuery.model'
import { WorkflowState } from '@/model/WorkflowState.model'
import Job from '@/components/cylc/Job'
import Tree from '@/components/cylc/tree/Tree'
import WorkflowIcon from '@/components/cylc/gscan/WorkflowIcon'
import { filterHierarchically } from '@/components/cylc/gscan/filters'
import { GSCAN_DELTAS_SUBSCRIPTION } from '@/graphql/queries'
Copy link
Member Author

Choose a reason for hiding this comment

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

This separates the component from the view code as already done for some of the other views.

  • The component should be something you can mount by itself.
    • Functional dependencies should provided via props.
    • It shouldn't issue subscriptions or go looking in the store, it should work by itself.
    • It should be generic-ish and reusable.
    • It should be component testable!
  • The "view" should contain the application logic.
    • It should start the subscription (via the required mixins).
    • It should fetch the relevant items from the store.
    • It should be functional testable.

meta: {
layout: 'default',
toolbar: false,
showSidebar: false
Copy link
Member Author

Choose a reason for hiding this comment

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

Don't show the sidebar in the workflows view, it would be duplication.

{
path: '/tree/:workflowName(.*)',
view: 'Tree',
name: 'tree',
meta: {
layout: 'default',
toolbar: true
toolbar: true,
showSidebar: false
Copy link
Member Author

@oliver-sanders oliver-sanders Jan 4, 2023

Choose a reason for hiding this comment

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

Don't show the sidebar in the other standalone views, these were intended to contain just the view (and the workflow toolbar, but we can add that later, it's a little tricky to do ATM, will raise an issue).

The main use case for the standalone view (besides testing) is for operators who want to be able to display one workflow per screen in a monitoring station.

@oliver-sanders oliver-sanders force-pushed the workflows-to-workspace branch 3 times, most recently from 1c979ef to d0a383c Compare January 10, 2023 13:12
@oliver-sanders
Copy link
Member Author

Firefox e2e test failure fixed in another PR.

  1. Table view
    Filters
    displays and sorts dt-mean:
    CypressError: Timed out retrying after 10050ms: cy.click() failed because this element:
    <path d="M13,20H11V8L5.5,13.5L4.08,12.08L12,4.16L19.92,12.08L18.5,13.5L13,8V20Z"></path>

@oliver-sanders oliver-sanders marked this pull request as ready for review January 10, 2023 13:54
@MetRonnie
Copy link
Member

MetRonnie commented Jan 10, 2023

Sorry if already discussed, but what about workflow (singular) instead of workspace?

@oliver-sanders
Copy link
Member Author

oliver-sanders commented Jan 10, 2023

Workflow is a little ambiguous as all of the routes are "workflow" views. We do also intend to use the workspace view to show multiple workflows. What marks the workspace view apart from the others is Lumino.

Copy link
Member

@wxtim wxtim left a comment

Choose a reason for hiding this comment

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

Legit.
Happy for you to merge if you're ok to break master, or to wait for the fix to the broken test to go in first.

* Rename the `#/workflows` route to `#/workspace`.
* Split the GScan component into a view and component.
* Use the `#/workflows` route for GScan.
* Remove the sidebar for the standalone views.
@oliver-sanders
Copy link
Member Author

Rebased and applied the force fix to the failing e2e test...

@MetRonnie MetRonnie merged commit d8362ba into cylc:master Jan 11, 2023
@oliver-sanders oliver-sanders deleted the workflows-to-workspace branch January 11, 2023 11:52
@MetRonnie MetRonnie mentioned this pull request Jan 13, 2023
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.

3 participants