Skip to content

update clients' key package refs upon committing#2604

Merged
stefanwire merged 10 commits intodevelopfrom
FS-878/updatekeyref
Aug 11, 2022
Merged

update clients' key package refs upon committing#2604
stefanwire merged 10 commits intodevelopfrom
FS-878/updatekeyref

Conversation

@stefanwire
Copy link
Contributor

@stefanwire stefanwire commented Aug 10, 2022

https://wearezeta.atlassian.net/browse/FS-878

The logic has been manually tested. Automated tests will be added/integrated by FS-797.

Checklist

  • The PR Title explains the impact of the change.
  • The PR description provides context as to why the change should occur and what the code contributes to that effect. This could also be a link to a JIRA ticket or a Github issue, if there is one.
  • changelog.d contains the following bits of information (details):
    • A file with the changelog entry in one or more suitable sub-sections. The sub-sections are marked by directories inside changelog.d.
    • If internal end-points have been added or changed: which services have to be deployed in a specific order?

@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:16 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:16 Inactive
@zebot zebot added the ok-to-test Approved for running tests in CI, overrides not-ok-to-test if both labels exist label Aug 10, 2022
@stefanwire stefanwire changed the title FS-878 update client's key package refs upon committing Aug 10, 2022
@stefanwire stefanwire force-pushed the FS-878/updatekeyref branch from f0a4f57 to d73bb32 Compare August 10, 2022 10:25
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:25 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:25 Inactive
@stefanwire stefanwire changed the title update client's key package refs upon committing update clients' key package refs upon committing Aug 10, 2022
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:39 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:39 Inactive
@stefanwire stefanwire force-pushed the FS-878/updatekeyref branch from 1bf77c2 to b951773 Compare August 10, 2022 10:40
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:40 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:40 Inactive
@stefanwire stefanwire force-pushed the FS-878/updatekeyref branch from b951773 to f1e0b34 Compare August 10, 2022 10:42
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:42 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 10:42 Inactive
@stefanwire stefanwire marked this pull request as ready for review August 10, 2022 10:42
@mdimjasevic mdimjasevic self-requested a review August 10, 2022 11:03
Copy link
Contributor

@mdimjasevic mdimjasevic left a comment

Choose a reason for hiding this comment

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

I think you're pretty much there. I left a few comments inlined.

@mdimjasevic
Copy link
Contributor

Can you also add tests? It would be good to have one for the case when there's no key package in the update path and then one for the case when there is a key package.

@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 12:26 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 12:26 Inactive
@stefanwire
Copy link
Contributor Author

Can you also add tests? It would be good to have one for the case when there's no key package in the update path and then one for the case when there is a key package.

I'm not sure whether we can do this using the mls-test-cli. There's always an update path in a commit from what I see. 🤔

@mdimjasevic
Copy link
Contributor

I'm not sure whether we can do this using the mls-test-cli. There's always an update path in a commit from what I see. thinking

We're not there yet (or at least I haven't thought this through), but it would be nice if we didn't have to write an integration test for everything we do. With Galley polysemized, I think we ought to start thinking how to make testing easy without needing to reach for another integration test. For this particular scenario, perhaps it would be too much to construct by hand a binary representation of a commit so we can parseMLS it; with Paolo's serialisation PR #2597 , hopefully this will be a breeze.

Not every commit has an update path - it is an optional field.

@stefanwire
Copy link
Contributor Author

We're not there yet (or at least I haven't thought this through), but it would be nice if we didn't have to write an integration test for everything we do. With Galley polysemized, I think we ought to start thinking how to make testing easy without needing to reach for another integration test. For this particular scenario, perhaps it would be too much to construct by hand a binary representation of a commit so we can parseMLS it; with Paolo's serialisation PR #2597 , hopefully this will be a breeze.

Thanks for the pointer!

Not every commit has an update path - it is an optional field.

True and already acknowledged in code. 👍

@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 13:43 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 13:43 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 14:18 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 10, 2022 14:18 Inactive
@stefanwire stefanwire requested a review from mdimjasevic August 10, 2022 14:19
@mdimjasevic
Copy link
Contributor

I really think the PR should come with tests. One option is to see if OpenMLS supports explicitly leaving out/including an update path. Another one, which I've been doing in another PR, is to construct the payload directly in Haskell; sure, that's a bit tedious to do by hand until we get Paolo's serialisation PR merged, but it should be doable. And you can always cherry-pick from Paolo's branch.

@stefanwire stefanwire force-pushed the FS-878/updatekeyref branch from ea33455 to 63f5052 Compare August 11, 2022 08:19
@stefanwire stefanwire temporarily deployed to cachix August 11, 2022 08:20 Inactive
@stefanwire stefanwire temporarily deployed to cachix August 11, 2022 08:20 Inactive
Copy link
Contributor

@mdimjasevic mdimjasevic left a comment

Choose a reason for hiding this comment

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

Not happy with this, but I'm letting this to be merged without any tests.

On a more general note, testing changes to the application code ought to be easy. We should figure out how to do that easily with Polysemy.

@stefanwire stefanwire merged commit 5031a28 into develop Aug 11, 2022
@stefanwire stefanwire deleted the FS-878/updatekeyref branch August 11, 2022 09:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ok-to-test Approved for running tests in CI, overrides not-ok-to-test if both labels exist

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants