cli icon indicating copy to clipboard operation
cli copied to clipboard

Fix webhook link logic

Open isaacroldan opened this issue 1 year ago β€’ 3 comments

WHY are these changes introduced?

There are two ways of defining webhooks in the toml:

  • Condensed: multiple topics in the same subscription definition (sharing the same URI)
  • Expanded: each subscription has only 1 topic

When linking to a new app we need to default to the condensed state, but right now we are doing expanded.

WHAT is this pull request doing?

  • Remove the simplify function from the specification
  • Update the webhook reverse transform to transform from expanded to condensed.

How to test your changes?

  • Try to link with an app that has multiple webhooks, they should appear in the condensed form in the toml file.

Post-release steps

Measuring impact

How do we know this change was effective? Please choose one:

  • [ ] n/a - this doesn't need measurement, e.g. a linting rule or a bug-fix
  • [ ] Existing analytics will cater for this addition
  • [ ] PR includes analytics changes to measure impact

Checklist

  • [ ] I've considered possible cross-platform impacts (Mac, Linux, Windows)
  • [ ] I've considered possible documentation changes
  • [ ] I've made sure that any changes to dev or deploy have been reflected in the internal flowchart.

isaacroldan avatar May 13 '24 15:05 isaacroldan

We detected some changes at either packages/*/src or packages/cli-kit/assets/cli-ruby/** and there are no updates in the .changeset. If the changes are user-facing, run "pnpm changeset add" to track your changes and include them in the next release CHANGELOG.

github-actions[bot] avatar May 13 '24 15:05 github-actions[bot]

Coverage report

St.:grey_question:
Category Percentage Covered / Total
🟑 Statements
71.88% (+0.05% πŸ”Ό)
7145/9940
🟑 Branches
69.17% (+0.05% πŸ”Ό)
3529/5102
🟑 Functions
71.58% (+0.12% πŸ”Ό)
1917/2678
🟑 Lines
73.14% (+0.04% πŸ”Ό)
6723/9192
Show files with reduced coverage πŸ”»
St.:grey_question:
File Statements Branches Functions Lines
🟑
... / select-app.ts
74.19% (-0.81% πŸ”»)
80% (-2.35% πŸ”»)
88.89% (-1.11% πŸ”»)
76.92% (-0.85% πŸ”»)
🟒
... / link.ts
96.7% (+0.19% πŸ”Ό)
90.91% (-1.03% πŸ”»)
100%
96.59% (+0.21% πŸ”Ό)

Test suite run success

1667 tests passing in 774 suites.

Report generated by πŸ§ͺjest coverage report action from 16d806c9721fb52c7c54e4e3e9094188bf6ec8c4

github-actions[bot] avatar May 13 '24 15:05 github-actions[bot]

only weirdness I saw when testing is that the the subscriptions showed 0 on the version page, but a refresh showed the subscription I was expecting. not blocking and not related to this PR since it seems to happen on main too but just noting it here

karenxie avatar May 23 '24 21:05 karenxie

Approved πŸ‘

isaacroldan avatar May 24 '24 08:05 isaacroldan