Skip to content

Switch to xmpp.js #353

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

Merged
merged 28 commits into from
Mar 29, 2021
Merged

Switch to xmpp.js #353

merged 28 commits into from
Mar 29, 2021

Conversation

silverbucket
Copy link
Member

@silverbucket silverbucket commented Mar 16, 2021

Ports the entire xmpp platform from a hybrid of node-xmpp and node-simple-xmpp to xmpp.js, adds unit tests for the platform improving on the coverage and switching to jest from jaribu. This doesn't add any new XMPP functionality but replaces what was already there before with the improved code.

silverbucket and others added 15 commits October 22, 2020 21:40
…functionality for joining a room and receiving chat messages
* switch to jest, move code to src
* stanzas for the actions we currently support
* coverage for functions which use xmpp.js added
* lower coverage threshold for now
* stanzas for the actions we currently support

* switch to jest, move code to src

* remove simple-xmpp handlers, stanza is public

* remove old test directory, implement new incoming-handlers.test.js and improve structure for clarity

* set thresholds

Co-authored-by: Garret Alfert <alfert@wevelop.de>

* Update packages/sockethub-platform-xmpp/src/index.test.js

Co-authored-by: Garret Alfert <alfert@wevelop.de>

* consolidate chat message handler, improve tests and use displayName prop

Co-authored-by: Garret Alfert <alfert@wevelop.de>
@silverbucket silverbucket self-assigned this Mar 16, 2021
@silverbucket silverbucket linked an issue Mar 16, 2021 that may be closed by this pull request
@silverbucket silverbucket added this to the XMPP Platform milestone Mar 16, 2021
@silverbucket silverbucket changed the title WIP: Switch to xmpp.js Switch to xmpp.js Mar 18, 2021
@silverbucket
Copy link
Member Author

silverbucket commented Mar 18, 2021

@raucao @galfert - OK this is ready for testing. I've enabled eslint but decided to keep codeclimate disabled for now to keep the diff noise low. Will plan that for a separate PR in the future.

Copy link
Contributor

@raucao raucao left a comment

Choose a reason for hiding this comment

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

Code LGTM. And I tested successfully with 2 XMPP accounts in Hyperchannel.

There are some warnings on startup, but not sure if they are new:

(node:137736) Warning: Accessing non-existent property 'lineno' of module exports inside circular dependency                                                                 
(Use `node --trace-warnings ...` to show where the warning was created)                                                                                                      
(node:137736) Warning: Accessing non-existent property 'column' of module exports inside circular dependency                                                                 
(node:137736) Warning: Accessing non-existent property 'filename' of module exports inside circular dependency                                                               
(node:137736) Warning: Accessing non-existent property 'lineno' of module exports inside circular dependency                                                                 
(node:137736) Warning: Accessing non-existent property 'column' of module exports inside circular dependency                                                                 
(node:137736) Warning: Accessing non-existent property 'filename' of module exports inside circular dependency 

@raucao
Copy link
Contributor

raucao commented Mar 26, 2021

Please manually kredit me a medium for pairing, when this is merged. I didn't help enough for assigning myself to the PR as well. Thanks.

@silverbucket silverbucket merged commit 35935d6 into master Mar 29, 2021
@raucao raucao deleted the td/switch_to_xmppjs_2 branch March 29, 2021 10:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Port XMPP platform to xmpp.js
2 participants