Commit graph

31 commits

Author SHA1 Message Date
Jonathan Zernik
7658a4d95c
Upgrade squeaklib to v013 (#2165)
* Upgrade to squeaklib v0.13

* Allow different squeak types in server reponse

* Add core method for create resqueak.

* Add make resqueak method for squeak store

* Update db migration to include resqueak hash

* Add db method to insert and get resqueak

* Return resqueak as squeak entry in db query method

* Add RPC method for make resqueak

* Got make resqueak modal working in frontend

* Show different content for resqueak in frontend

* Show resqueaed squeak in display

* Show resqueak correctly

* Got resqueak display working on squeak card component

* Fix display for missing resqueaked squeak.

* Fix display for missing resqueaked squeak in squeak card.

* Got resqueak from squeak card working

* Fix prevent default action on resqueak unlock click

* Fix prevent default on make reply squeak in squeak card

* Got number of replies to resqueaked squeak working

* Fix click on squeak card

* Fix too many characters warning message

* Fix click on squeak card image and name and pubkey

* Rename set reply modal state function

* Fix toggle modals for resqueaked squeak

* Fix form submit action for squeak modals

* Include num resqueaks and num resqueaked resqueaks in get squeak entry db query

* Show number of resqueaks in frontend

* Fix distinct count in query for num replies and num resqueaks

* Update resqueaked squeak in slice state

* Update frontend build
2022-04-24 17:54:07 -07:00
Jonathan Zernik
80a484ef3b
Simplify get payment summary in controller (#2159) 2022-04-14 15:17:26 -07:00
Jonathan Zernik
d626147c71
Show num replies (#2144)
* Got show num replies working on squeak page

* Fix group by squeak hash

* Fix db queries for get num replies

* Update frontend build
2022-04-13 15:47:28 -07:00
Jonathan Zernik
68e69e55c8
Use http for peer connection (#2002)
* Got basic web server running for peer

* Got squeak route and lookup route working

* Got secret key route working

* Got offer endpoint working

* Remove old comment

* Move peer server code to server subdir

* Create client subdir for peer client

* Return empty list for lookup when pubkeys is empty

* Add peer client and network controller class

* Remove old network code

* Remove old block subscription worker

* Remove network handler class

* Remove more old classes

* Add back twitter forwarder worker

* Remove download methods from controller

* Add websocket endpoint

* Add websocket subscribe method

* Add websocket client library

* Fetch squeaks from peer (slowly) on UI timeline load

* Fetch squeaks from peer (slowly) on UI pubkey squeaks load

* Got download squeaks working with HTTP requests

* Fixed external address method in controller

* Remove download pubkey squeak button and action

* Remove unused connection displays from peer ana peers page

* Fix 404 not found for offer endpoint

* Better handling of null cases in peer client downloader

* Simplify peer downloader

* Create subclass for range download

* Got single squeak download working

* Fix itest for get external address
2022-03-17 14:38:46 -07:00
Jonathan Zernik
20d651df8e
Implement unlock private squeak (#1910)
* Add method stub for unlock private squeak in controller class

* Add methods to unlock private squeak in controller

* Remove todo comments

* Add test for create and decrypt private squeak in core module

* Update handler method for make squeak to support recipient profile id

* Add itest for make private squeak and unlock content as author
2021-12-28 01:07:59 -08:00
Jonathan Zernik
51f412d75f
Update squeaklib to support private messages (#1897)
* Update squeaklib and update import from keys module

* Rename signing key variable to private key in test util

* Fix calling make squeak function

* Update db data file to v3

* Add recipient public key column to squeak table

* Got squeak entry db query working with alias for profiles table

* Add test for make squeak with recipient

* Add test case for get profile from squeak entry query

* Got outer join with recipient profile working

* Use outer join to get recipient profile for all squeak entry db queries
2021-12-27 00:56:31 -08:00
Jonathan Zernik
5198467889
Use new squeak protocol with schnorr and pubkey as identifier (#1870)
* Got all tests in core dir passing

* Got all tests in db dir passing

* Got tests for admin dir passing

* Got all unit tests passing

* Added migration for squeak table and profile table using new pubkey

* Re-start db migrations with new data-v2.db file

* Fix column type for profile public key

* Got all itests passing

* Log the public key in hex in create contact profile handle fn

* Rename rpc methods to use pubkey instead of address

* Got frontend mostly working with new profile pubkey

* Update frontend to use pubkey instead of address

* Change size of squeak profile detail item

* Update create contact profile dialog to use pubkey

* Update twitter account item to use pubkey

* Include label for pubkey in profile detail item

* Decrease size of profile detail item

* Update frontend build

* Improve logging of requests in handler
2021-12-20 09:28:38 -08:00
Jonathan Zernik
6233890e5b
Remove squeak detail include in squeak entry (#1837)
* Got squeak details dialog working without details rpc request

* Remove get squeak detail from rpc proto

* Update frontend build

* Remove old get squeak detail itest

* Remove unused fixture for squeak detail item
2021-11-30 22:25:43 -08:00
Jonathan Zernik
c0141effcb
Implement share for free with saved peer (#1782)
* Add share_for_free column to peer table in db and to core struct

* Got set share for free toggle working in frontend

* Got share for free working with price zero in controller
2021-11-07 02:21:13 -08:00
Jonathan Zernik
6c40891ad8
Add twitter forwarder (#1755)
* Add twitter stream class

* Got twitter forwarder subscription working

* Add config table in db with twitter bearer token

* Only run forward tweets task when twitter bearer token and twitter handles are not null

* Add twitter page to frontend and add button to set bearer token

* Reload bearer token in ui after setting value

* Add twitter accounts table to db

* Got get twitter accounts request working

* Display twitter account list items in twitter page

* Show twitter accounts in twitter page

* Got create squeak from tweet working

* Update twitter stream upon twitter accounts changes

* Got terminate twitter stream connection working

* Update frontend build

* Remove print statements from itest

* Remove main function from twitter stream module

* Make tweet forwarder worker run as daemon thread

* Use custom config for subscribe tweets retry interval
2021-11-04 19:10:00 -07:00
Jonathan Zernik
a8745d0dbd
Add test for download result to message (#1739) 2021-10-26 21:46:35 -07:00
Jonathan Zernik
4c71be584a
Add test for set sent offer paid (#1698)
* Add test for set sent offer paid

* Add test for set sent offer not paid
2021-10-23 00:26:04 -07:00
Jonathan Zernik
3fc34c8965
Add test for set received offer paid db method (#1678) 2021-10-22 17:16:37 -07:00
Jonathan Zernik
f4a317f571
Add unit test for get address squeaks method of db (#1637)
* Add unit test for get address squeaks method of db

* Add test for get search entries method of db

* Add tests for get ancestor squeaks method of db

* Add tests for get reply squeaks method of db
2021-10-18 09:51:00 -07:00
Jonathan Zernik
fd6ad232e1
Add function to get private key from profile (#1619) 2021-10-16 19:35:24 -07:00
Jonathan Zernik
0e85b37f02
Add functions for optional types to msgs (#1618)
* Add functions for convert some optional types to msgs

* Add functions for convert optional squeak entry to msg

* Add function for convert optional peer to msg

* Add function for convert optional received offer to msg

* Add function for convert optional sent payment to msg

* Add function for convert optional squeak to detail msg

* Add function for convert optional connected peer to msg

* Use function for convert optional connected peer to msg in handler
2021-10-16 18:59:56 -07:00
Jonathan Zernik
47a68505b7
Add test for connected peer to msg (#1610) 2021-10-15 20:47:27 -07:00
Jonathan Zernik
11d8c8a1e3
Add test for payment summary to msg (#1609) 2021-10-15 20:22:38 -07:00
Jonathan Zernik
9c3e63dd2e
Add test for squeak detail to msg (#1604) 2021-10-15 17:57:25 -07:00
Jonathan Zernik
5a339605f3
Add fixture for offer to global conftest (#1601)
* Add fixture for offer to global conftest

* Remove old not none assertion
2021-10-15 17:02:53 -07:00
Jonathan Zernik
2a25ea6f1c
Add fixture for sent payment in global conftest (#1600) 2021-10-15 16:51:16 -07:00
Jonathan Zernik
84f7159d39
Add test for subscribe received payments (#1596)
* Add test for get received payments method of squeak core

* Add assertion on number of received payments in test.
2021-10-14 23:22:56 -07:00
Jonathan Zernik
d351613880
Add tests for squeak entry to message and profile to message (#1593)
* Add tests for squeak entry to message and profile to message

* Move fixtures for admin module to separate conftest

* Add test for peer to msg

* Use global fixture for peer_address in squeak core test

* Move common fixtures to global conftest

* Add fixture for received offer

* Add unit test for received offer to msg

* Add fixture for sent offer

* Rename received offer to msg function
2021-10-14 19:57:48 -07:00
Jonathan Zernik
dd927036a5
Add block_info fixture to global conftest (#1584) 2021-10-12 19:00:44 -07:00
Jonathan Zernik
3dcc2681d5
Simplify unit tests for interests (#1579) 2021-10-12 15:11:38 -07:00
Jonathan Zernik
f49874c1e6
Improve squeak core tests (#1560)
* Use fixture for block in mock bitcoin client

* Simplify unit test for make squeak method

* Simplify make squeak method even more

* Added unit test for create offer

* Add TODO comment for preimage fixture
2021-10-10 23:48:06 -07:00
Jonathan Zernik
4ca835b2fb
Replace use_tor field with network in peer address (#1558)
* Replace use_tor field with network in peer address

* Got itest passing with network column in db.

* Got frontend working with network (ipv4 or torv3) configurable

* Fix go to peer address page navigation from sent payment and received payment
2021-10-10 21:00:56 -07:00
Jonathan Zernik
2e0fc25051
Got unit test working for insert and retrieve squeak in db (#1488) 2021-10-03 20:39:24 -07:00
Jonathan Zernik
46dd7f5287
Use separate modules client server (#1)
* Put server in separate module

* Fix flask app name for server in submodule

* Added common module
2020-02-29 18:30:52 -08:00
Jonathan Zernik
35ed57cc8b Rename to squeaknode 2020-02-28 19:13:19 -08:00
Jonathan Zernik
cea55d63bd Initial commit 2020-02-22 19:33:40 -08:00