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

Brings ViewStarter to the UI update. #620

Merged
merged 21 commits into from
Jan 7, 2022

Commits on Dec 9, 2021

  1. View.launchWhenAttached tolerates strange ids

    Fixes a problem where `launchWhenAttached` would crash if it failed to fetch a
    resource name when trying to make a cute scope name. I happen to know of some
    view systems that break our assumption that every id is named.
    rjrjr committed Dec 9, 2021
    Configuration menu
    Copy the full SHA
    5be01a5 View commit details
    Browse the repository at this point in the history
  2. Merge pull request #604 from square/ray/more-robust-ensureAttachedScope

    View.launchWhenAttached tolerates strange ids
    rjrjr committed Dec 9, 2021
    Configuration menu
    Copy the full SHA
    757aa20 View commit details
    Browse the repository at this point in the history

Commits on Dec 10, 2021

  1. Fixes index out of bounds crash when attempting to add characters or …

    …moving the cursor to the ends of the string being edited.
    JsFlo committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    5931b4a View commit details
    Browse the repository at this point in the history
  2. Merge pull request #605 from JsFlo/joseflores/terminalIndexOutOfBounds

    Fixes index out of bounds crash in hello-todo-terminal sample
    rjrjr committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    821c7b6 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    e50052d View commit details
    Browse the repository at this point in the history
  4. Replaces *.initializeView with *.viewStarter

    Fixes #597.
    
    It used to be the case that every `DecorativeViewFactory` called
    `showRendering()` twice (#397). We fixed that (we thought) by introducing the
    `initializeView` lambda to `ViewRegistry.buildView` and
    `DecorativeViewFactory` (#408).
    
    Unfortunately, that fix botched recursion. Individual `DecorativeViewFactory`
    instances work fine, but if you wrap them you still get one `showRendering`
    call from each. Worse, upstream `initializeView` lambdas are clobbered by
    immediately downstream ones. e.g., when a `WorkflowViewStub` shows a
    `DecorativeViewFactory`, the `WorkflowLifecycleRunner.installOn` call in the
    former is clobbered.
    
    The fix is to completely decouple building a view from from this kind of
    initialization. `ViewRegistry.buildView` and its wrappers no longer try to
    call `showRendering` at all.
    
    Instead the caller of `buildView` (mostly `WorkflowViewStub`) is reponsible
    for immediately calling `View.start` on the new `View`. `View.start` makes
    the initial `showRendering` call that formerly was the job of
    `ViewFactory.buildView` -- the factory builds the view, and the container
    turns the key. Since `View.start` is called only after all wrapped
    `ViewFactory.buildView` functions have executed, we're certain it will only
    happen once.
    
    Of course we still need the ability to customize view initialization via
    wrapping, especially to invoke `WorkflowLifecycleOwner.installOn`. To
    accomodate that, the function that `View.start` executes can be wrapped via
    the new `viewStarter` argument to `ViewRegistry.buildView` and
    `DecorativeViewFactory`, which replaces `initializeView`.
    
    This required a pretty thorough overhaul of `ViewShowRendering.kt`
    The `ViewShowRenderingTag` that it hangs off of a view tag is renamed
    `WorkflowViewState`, and extracted to a separate file.
    
    `WorkflowViewState` is a sealed class with two implementations (`New` and
    `Started`) to help us enforce the order of the `ViewRegistry.buildView`,
    `View.bindShowRendering`, `View.start` and `View.showRendering` calls.
    rjrjr committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    b93a522 View commit details
    Browse the repository at this point in the history
  5. Merge pull request #602 from square/ray/initializeView-is-a-landmine

    Replaces *.initializeView with *.viewStarter
    rjrjr committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    df925e5 View commit details
    Browse the repository at this point in the history
  6. End CHANGELOG.md

    Because the [releases page](https://github.com/square/workflow-kotlin/releases) is so much nicer.
    rjrjr committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    aeed829 View commit details
    Browse the repository at this point in the history
  7. Merge pull request #607 from square/ray/no-more-changelog

    End CHANGELOG.md
    rjrjr committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    5cd4ba2 View commit details
    Browse the repository at this point in the history
  8. Releasing v1.3.0

    rjrjr committed Dec 10, 2021
    Configuration menu
    Copy the full SHA
    d87bef1 View commit details
    Browse the repository at this point in the history

Commits on Dec 13, 2021

  1. 608: Update TypedWorker kdoc

    When moving Workers to being wrapped by WorkerWorkflow we did not need to compare
    types included in the KType signature but that was not clear from the kdoc. Update
    that to make it clear.
    steve-the-edwards committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    085e097 View commit details
    Browse the repository at this point in the history
  2. Merge pull request #609 from square/sedwards/608-typed-worker-compare…

    …-output
    
    608: Update TypedWorker kdoc
    steve-the-edwards committed Dec 13, 2021
    Configuration menu
    Copy the full SHA
    9011f80 View commit details
    Browse the repository at this point in the history

Commits on Dec 16, 2021

  1. Use Gradle 7.3.2. Log4shell mitigation.

    Gradle 7.3.2 adds dependency constraints to the _build_ classpath to reject known-bad versions of log4j.
    
    See also https://blog.gradle.org/log4j-vulnerability.
    autonomousapps committed Dec 16, 2021
    Configuration menu
    Copy the full SHA
    42b6998 View commit details
    Browse the repository at this point in the history
  2. Merge pull request #613 from autonomousapps/patch-1

    Use Gradle 7.3.2. Log4shell mitigation.
    rjrjr committed Dec 16, 2021
    Configuration menu
    Copy the full SHA
    7c3bdb6 View commit details
    Browse the repository at this point in the history

Commits on Jan 4, 2022

  1. Configuration menu
    Copy the full SHA
    a80f9a0 View commit details
    Browse the repository at this point in the history
  2. Moves us to s01.oss.sonatype.org

    Fixes #615.
    rjrjr committed Jan 4, 2022
    Configuration menu
    Copy the full SHA
    4844ad8 View commit details
    Browse the repository at this point in the history

Commits on Jan 5, 2022

  1. Configuration menu
    Copy the full SHA
    588db3b View commit details
    Browse the repository at this point in the history
  2. Merge pull request #617 from square/ralf/compile-sdk

    Upgrade the compile SDK to 31.
    rjrjr committed Jan 5, 2022
    Configuration menu
    Copy the full SHA
    a88141c View commit details
    Browse the repository at this point in the history
  3. Merge pull request #616 from square/ray/sonatype-update

    Moves us to s01.oss.sonatype.org
    rjrjr committed Jan 5, 2022
    Configuration menu
    Copy the full SHA
    e85d260 View commit details
    Browse the repository at this point in the history
  4. Merge remote-tracking branch 'origin/main' into ray/ui-update

    * origin/main:
      Upgrade the compile SDK to 31.
      Moves us to s01.oss.sonatype.org
      Fixes version name after 1.3.0 release, forgot to bump it.
      Use Gradle 7.3.2. Log4shell mitigation.
      608: Update TypedWorker kdoc
      Releasing v1.3.0
      End CHANGELOG.md
      Replaces *.initializeView with *.viewStarter
      Adds (failing) DecorativeViewFactory double update test
      Fixes index out of bounds crash when attempting to add characters or moving the cursor to the ends of the string being edited.
      View.launchWhenAttached tolerates strange ids
    rjrjr committed Jan 5, 2022
    Configuration menu
    Copy the full SHA
    a691e8e View commit details
    Browse the repository at this point in the history

Commits on Jan 6, 2022

  1. Brings ViewStarter to the UI update.

    Propagates changes from #602 -- replace `initializeView`
    with `viewStarter` to fix #597.
    rjrjr committed Jan 6, 2022
    Configuration menu
    Copy the full SHA
    f0dce22 View commit details
    Browse the repository at this point in the history