Skip to content

Conversation

@ferm10n
Copy link
Collaborator

@ferm10n ferm10n commented Mar 27, 2023

thoughts / todo

John Sanders added 10 commits June 2, 2022 16:00
- this is useful for dependent projects that want type safety
- there's no way to import a json as a const type (where `subscribe` is stricter than `number`) so thats why the convert to js (see microsoft/TypeScript#32063)
- `_destroy` noops were removed since they prevent proper propagation of errors
  - not sure what this needed for backwards compat, but I assume it was added after node 10 defaulted `autoDestroy: true`
- tweaked some types on constructor options
- added a catch around the mid serializer fn, without which it would cause an unhandled rejection and silently stop working
@ferm10n ferm10n changed the title 2.0.0 1.2.0 Mar 27, 2023
@ferm10n ferm10n changed the title 1.2.0 Draft: 1.2.0 Mar 27, 2023
ferm10n and others added 14 commits March 27, 2023 12:58
ci: add github ci actions to build and test
fix: properly destroy streams when an error occurs
see the comments on this MR st-one-io#41
the `this` context might be lost, but that was also the case before this change
calling the callback passed to `_destroy` is not explicity mentioned as required in the nodejs docs, but it's necessary for error propagation.
this is why the tests listening for an error event from link layer would fail, because even though the link layer would be destroyed, it would not emit an error event.
Add subscription error codes to mid groups (RV develop)
this unit test was failing because the error is emitted synchronously when calling `parser.write`
It's functionality provided by nodejs internals, so it's a little weird to test for this in the first place
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.

2 participants