Commit graph

600 commits

Author SHA1 Message Date
Kay Kurokawa
bd4dd8e114 add timeout to download_sd_blob and StandaloneBlobDownloader 2017-07-05 16:33:02 -04:00
Kay Kurokawa
1c1b5096be use LoopingCall in SingleProgressManager to simplify it 2017-07-05 16:33:02 -04:00
Jack Robison
e71389c7e3 update lbryum imports 2017-06-27 19:02:25 -04:00
Kay Kurokawa
14b2bb3019 add test for BlobManager 2017-06-23 10:24:27 -04:00
Kay Kurokawa
f9b4d46599 work on removing manage from BlobManager and simplify blob deletion 2017-06-23 10:24:27 -04:00
Jack Robison
bc34c22e58 update daemon settings and settings_set 2017-06-21 22:54:47 -04:00
Kay Kurokawa
59893e8fa8 fix typo which may not shut down blob_tracker 2017-06-16 14:00:08 -04:00
Jack Robison
9c88f820f9 add change_address param to publish 2017-06-12 13:43:15 -04:00
Jack Robison
c56ac12913 add claim_send_to_address 2017-06-12 10:30:18 -04:00
Jack Robison
ea0c6eca32 multi resolve 2017-06-09 14:48:55 -04:00
Jack Robison
2cfd29564b add resolution exception types 2017-06-09 14:48:55 -04:00
Jack Robison
82118e6692 fix blob manager db race condition 2017-06-09 14:09:17 -04:00
Kay Kurokawa
a577f38d80 add claim address as an option to publish API command 2017-06-04 19:26:28 -04:00
Jack Robison
96927ec985 remove lbrynet.metadata 2017-06-02 11:50:50 -04:00
Kay Kurokawa
da8256ad52 catch UnknownNamError instead of base Exception for resolve command 2017-06-01 16:26:03 -04:00
Jack Robison
cd67ca6ce3 remove clean_bad_records 2017-05-11 14:31:50 -04:00
Jack Robison
ecaa5249b4 migrate name metadata table 2017-05-11 14:31:50 -04:00
Jack Robison
ca092262fb fix name metadata db race condition 2017-05-11 14:31:50 -04:00
Jack Robison
12097e3bfa broadcast transactions and claim certificates as defer succeed 2017-05-11 14:31:50 -04:00
Jack Robison
632462e1d5 only save stream claims with a sd hash to name_metadata table 2017-05-11 14:19:52 -04:00
Jack Robison
56e214feb6 fix save_name_metadata 2017-05-10 11:26:14 -04:00
Jack Robison
2a8a984efa add claim and uri caching to wallet and wallet storage 2017-05-03 17:14:36 -04:00
Alex Grintsvayg
113f8ff2d7 fix set_build and version 2017-05-03 13:00:01 -04:00
Jack Robison
a9868a4f17 fix lbryum shut down 2017-05-01 21:09:23 -04:00
Jack Robison
dcdd4d8fd6 wallet config bug 2017-05-01 21:09:23 -04:00
Alex Grintsvayg
2353dbcb00 refactor analytics 2017-04-26 14:19:03 -04:00
Alex Grintsvayg
cd16383fa6 use git version when in dev 2017-04-26 14:18:41 -04:00
Alex Grintsvayg
cdf67de46c pylint type checking 2017-04-25 14:36:14 -04:00
Jack Robison
dffaf745ec wait for wallet subscriptions 2017-04-24 00:19:46 -04:00
Jack Robison
dc7193bb8f Merge pull request #619 from wallermadev/master
Adding functionality to check the balance of a given wallet.
2017-04-23 20:27:36 -04:00
Mathew WAller
c9c88055c3 Requested changes 2017-04-23 18:33:06 +01:00
Jack Robison
1ecb32b3ed less intensive blob availability check 2017-04-21 13:32:59 -04:00
Mathew WAller
6e37a0536a Removing pylint issues 2017-04-21 02:59:40 +01:00
Mathew WAller
8f0f27da1a Adding functionality to check the balance of a given wallet. 2017-04-21 02:16:26 +01:00
Alex Grintsvayg
492cbc83c9 pylint 2017-04-19 16:00:39 -04:00
Alex Grintsvayg
7f7a6a619f tests for windows, simplify pylint 2017-04-19 14:59:06 -04:00
Jack Robison
bbfb5a7853 include schema version in version() response 2017-04-19 13:54:38 -04:00
Jack Robison
6ccab8bcb8 get availability by uri 2017-04-10 14:29:24 -04:00
Alex Grintsvayg
8db7c37fa7 exploring dht 2017-04-10 13:45:43 -04:00
Jack Robison
a43127fffc add channel_new logging, fix docstring 2017-04-10 11:01:28 -04:00
Jack Robison
9531bdf396 fix file_list for files with abandoned claims 2017-04-09 21:44:58 -04:00
Jack Robison
04c119543f fix resolution and file_list bugs 2017-04-09 17:49:31 -04:00
Jack Robison
ccc94a0db9 update wallet for new lbryum functionality 2017-04-06 20:50:29 -04:00
Jack Robison
45b3837638 use ClaimDict.source_hash in utils.get_sd_hash 2017-04-06 20:50:28 -04:00
Kay Kurokawa
931038d478 bug fixes for lbryschema integration 2017-04-04 20:30:51 -04:00
Kay Kurokawa
ca041b5dc4 lbryschema integration 2017-04-04 20:30:51 -04:00
Alex Grin
5ec891c9ac Merge pull request #572 from lbryio/minor-wallet-updates
Minor wallet updates
2017-03-31 10:30:48 -04:00
Alex Grin
32e2ee8bf5 Merge pull request #569 from lbryio/fix_update
Remove update_metadata() function
2017-03-29 13:10:15 -04:00
Alex Grintsvayg
1916b990b7 typo 2017-03-28 17:14:13 -04:00
Alex Grintsvayg
84d9461deb Minor wallet updates 2017-03-28 17:13:59 -04:00
Alex Grintsvayg
9e5ac6f73e typo 2017-03-28 17:13:21 -04:00
Kay Kurokawa
bb4bf620f4 remove update_metadata() function 2017-03-27 16:46:41 -04:00
Kay Kurokawa
ddd8fd1a77 decrease connection timeout 2017-03-27 15:11:15 -04:00
Kay Kurokawa
3af5e9dc5c connect to multiple peers at once in manage 2017-03-27 15:11:15 -04:00
Kay Kurokawa
b0fd6e57df create and properly distinguish get_unused_address and get_new_address 2017-03-27 12:41:53 -04:00
Alex Grintsvayg
a2a29fc02c switch to txrequests to marry async requests to twisted 2017-03-24 17:20:33 -04:00
Alex Grintsvayg
0c42bc6382 fixes, refactors 2017-03-23 14:11:01 -04:00
Alex Grintsvayg
25d9f008de fix error handling in jsonrpc 2017-03-23 11:09:40 -04:00
Alex Grintsvayg
f515583ec4 fix _get_transaction 2017-03-21 12:11:47 -04:00
Alex Grintsvayg
8f3b53197f dont add expected payment when payment rate is 0 2017-03-20 15:37:45 -04:00
Jack Robison
a95c49bd08 add wallet_list 2017-03-19 10:52:51 -04:00
Kay Kurokawa
4edd13f4f4 fix wallet_public_key API command 2017-03-17 16:45:34 -04:00
Alex Grintsvayg
49b18a1fca minor 2017-03-15 16:33:41 -04:00
Alex Grintsvayg
29dea4901e add --version flag, remove simplejson dependency 2017-03-15 16:24:25 -04:00
Kay Kurokawa
b2c2edfb12 fixed bug of decimal not being subtractable from float 2017-03-10 18:33:21 -05:00
Kay Kurokawa
8c61185387 handle decimal encoded string output from lbryum 2017-03-10 12:56:58 -05:00
Kay Kurokawa
98d3a4cb46 fix api consistency issues from lbryum 2017-03-10 11:52:12 -05:00
Kay Kurokawa
881efabc0c remove unused _get_status_of_claim() and get_name_and_validity_for_sd_hash() function in Wallet 2017-03-09 12:02:36 -05:00
Jack Robison
5d6ca0aae6 add get_sd_hash to utils 2017-03-09 10:39:25 -05:00
Alex Grintsvayg
68f5588bd9 make loggly logs less verbose 2017-03-08 11:23:28 -05:00
Kay Kurokawa
931925be15 remove start and reveal from file_utils 2017-03-07 21:17:06 -05:00
Jack Robison
e2cc212eb8 Merge pull request #512 from lbryio/file-list-refactor
File list refactor
2017-03-07 20:38:04 -05:00
Alex Liebowitz
18c690d801 Add string comparison to ClaimOutpoint 2017-03-07 18:31:05 -05:00
Jack Robison
9744287370 change attribute "uri" to "name" 2017-03-07 18:29:44 -05:00
Kay Kurokawa
9755e9b11f Improvements to exchange rate manager 2017-03-03 12:50:47 -05:00
Kay Kurokawa
88f270180c add check in case local height is less than zero 2017-02-27 13:28:58 -05:00
Kay Kurokawa
824fbcc25a adding timeout to ClientProtocol 2017-02-27 13:02:35 -05:00
jobevers
70cf179139 Merge remote-tracking branch 'origin/master' into electron 2017-02-21 12:07:36 -06:00
jobevers
1d30ae447a Merge branch 'master' into electron 2017-02-21 10:47:28 -06:00
Job Evers‐Meltzer
998892ef0b Merge pull request #446 from lbryio/reseed
Script to Reseed a File
2017-02-21 06:11:32 -06:00
Kay Kurokawa
3522f9af7d use utils.call_later in DHTHash Announcer 2017-02-20 16:48:29 -05:00
Kay Kurokawa
c27fe7af31 use utils.call_later in ConnectionManager 2017-02-20 16:48:29 -05:00
Kay Kurokawa
30c7559d3a adding reactor.callLater as a utils function 2017-02-20 16:48:23 -05:00
Kay Kurokawa
7e2fad2397 dummy hash announcer requires hash_queue_size() function 2017-02-20 16:48:22 -05:00
Jack Robison
b18679af53 debug log 2017-02-19 19:37:50 -05:00
jobevers
993f2e54f9 more fixes for build 2017-02-16 14:13:01 -06:00
Job Evers‐Meltzer
fb2823f59e don't need this anymore 2017-02-16 14:13:00 -06:00
Jack Robison
3ddf8680fb blob commands
refactor blob_get
add descriptor_get
add blob_delete
refactor blob_list
2017-02-16 11:20:02 -05:00
Jack Robison
25ec8fde23 add timeout to get_availability and peer_list
-add optional timeout to DHTPeerFinder.find_peers_for_blob
-add peer_search_timeout setting
2017-02-16 11:17:37 -05:00
Jack Robison
bcd026a1b6 add only-free payment rate manager for testing 2017-02-16 11:17:37 -05:00
Jack Robison
1a6290eacc log blob count at startup 2017-02-16 11:17:37 -05:00
Jack Robison
0f907a209b add EncryptedFileDownloader.load_file_attributes 2017-02-16 09:12:47 -05:00
jobevers
9e2cda0cdc remove more upload_allowed arguments 2017-02-15 06:48:58 -06:00
Job Evers-Meltzer
2a45c91175 fix get_blob calls with upload_allowed arguments 2017-02-15 06:48:58 -06:00
Job Evers-Meltzer
a38e5c855e Remove upload_allowed attribute
This is unused and largely pulluting the argument list
of too many functions.
2017-02-15 06:48:50 -06:00
Job Evers-Meltzer
90d3a0ef9c Add script to reseed a file 2017-02-15 06:43:41 -06:00
Umpei Kay Kurokawa
37cc257555 Merge pull request #465 from lbryio/dht_hash_announcer_tests
Adjust hash reannounce based on queue size , test for DHTHashAnnouncer, immediately announce new blobs
2017-02-13 21:08:48 -05:00
Jack Robison
aa8375673b Merge pull request #477 from lbryio/inlinecallbacks-refactor
Refactor publish, file manager, and file downloader
2017-02-13 17:42:54 -05:00
Kay Kurokawa
34f5bc93ae adding immediate announce option to hash announce 2017-02-13 17:27:10 -05:00
Kay Kurokawa
8e0f71ac74 Make hash reannounce time adjusted based on the queue of hashes yet to be announced, add test for DHTHashAnnouncer 2017-02-13 17:27:10 -05:00
Jack Robison
8859c1b0c1 fix claim_abandon 2017-02-13 15:14:54 -05:00
Jack Robison
5a1bab2eaa refactor Publisher and jsonrpc_publish
-add get_read_handle to file_utils

-don’t leave read handle hanging after creating lbry file

-get rid of threaded weirdness

-remove reflector functionality from Publisher

-fix updating with an existing stream

-reflect new stream in thread after broadcasting name claim
2017-02-13 13:07:27 -05:00
Kay Kurokawa
4f87e87d3e Adding connection manager tests, and modifying connection manager to be testeable, fix bug where failed connection was not marked as down 2017-02-13 12:17:27 -05:00
Jack Robison
630d0bf5be convert Wallet.claim_name to use inlineCallbacks 2017-02-09 10:13:41 -05:00
Jack Robison
19fe101d73 fix claim update
dict.update does not return the dict, so this can’t be lambda’d
2017-02-09 10:11:46 -05:00
jobevers
4bb3e2a154 remove is_lagging wallet attribute 2017-02-01 12:13:43 -08:00
jobevers
ed227a239e Fixes #449
What was happening was the wallet claimed to be caught up before it
actually was and so the wallet’s local_height was still the value from
when lbry was last run, frequently more than 20 or 50 blocks
behind. _get_value_for_name uses the block at local_height as the
basis for the proof.  If _get_value_for_name is called during that
time between when the wallet claims to be caught up and it actually
is, the “Block too deep error” happens.  And since the discover page
of the UI does name resolution right away, the error basically happens
anytime somebody starts the app after not using it for a few hours.

This changes the startup behaviour of the wallet to
- use the `update` callback provided by lbryum
- check that local_height and network_height match before declaring
  that the wallet has caught up

For reference, the error is raised here:
1b896ae75b/src/rpc/claimtrie.cpp (L688)
2017-01-30 09:32:04 -08:00
jobevers
7360015fa4 small refactor 2017-01-30 09:32:04 -08:00
jobevers
04ee2f786d remove backslash line continuation 2017-01-30 09:32:04 -08:00
jobevers
43451c485f change alerts to logs 2017-01-30 09:32:04 -08:00
Umpei Kay Kurokawa
893fe8823e Merge pull request #409 from lbryio/fix_wallet_race_condition
Fix wallet balance interfaces
2017-01-26 15:12:54 -05:00
Kay Kurokawa
90438ddf9f removing str() from logging functions 2017-01-26 12:14:33 -05:00
Kay Kurokawa
08e336e476 adding better debug logs for ConnectionManager and ClientProtocol 2017-01-26 12:09:55 -05:00
Kay Kurokawa
0e864f5df1 Update interface for wallet balance 2017-01-26 11:41:27 -05:00
Alex Grintsvayg
c88631d910 fix long lines 2017-01-25 17:00:21 -05:00
Alex Grintsvayg
897fba35df fix formatting, reenable pylint 2017-01-25 15:33:46 -05:00
Jack Robison
3b65f5962c disable verbose twisted logs 2017-01-25 13:04:02 -05:00
Job Evers‐Meltzer
ec873129d5 Merge pull request #434 from lbryio/ensure-tmp-blobs-deleted
Bug fix: delete empty blobs
2017-01-24 11:55:13 -05:00
Job Evers‐Meltzer
a90f413f94 Merge pull request #438 from lbryio/warn_large_wallet
Add warning for large wallet sizes
2017-01-24 11:54:53 -05:00
Kay Kurokawa
ee84253b90 add warning for large wallet sizes 2017-01-23 18:55:20 -05:00
Job Evers‐Meltzer
06e45ee32a Merge pull request #410 from lbryio/reveal-open-refactor
Add open() API method and refactor/update reveal() API method (WIP)
2017-01-23 16:44:31 -05:00
Job Evers-Meltzer
7696f30009 add debug log to hash announcing 2017-01-21 22:48:16 -06:00
Job Evers-Meltzer
c211d87164 Bug fix: delete empty blobs
When creating a CryptStream, the last blob is always empty. Previously, this
blob wouldn't be deleted and would instead just stick around in the blobfiles
directory.
2017-01-21 17:27:19 -06:00
Alex Liebowitz
d3a63c38fc Fix pylint errors 2017-01-20 22:36:31 -05:00
Alex Liebowitz
8b68a752ed Add file_utils module 2017-01-20 22:29:27 -05:00
Job Evers-Meltzer
2c9c0da501 get_blob bug fix 2017-01-20 17:41:08 -06:00
Umpei Kay Kurokawa
60195ed6d4 Merge pull request #427 from lbryio/fix_new_address
Prevent excessive generation of new addresses
2017-01-20 17:14:21 -05:00
Job Evers-Meltzer
3e774fc158 missed another verified time check 2017-01-20 18:47:53 +00:00
Job Evers‐Meltzer
6c571b5227 Blob verification fixes (#428)
* Move the blob verification to the actual Blob object
 * remove the check on verification time
 * remove get_blob_length from BlobManager

Removed because I'm not sure what checking verification time against ctime gets us, except some protection against an accidental modification of the blob.
2017-01-20 10:54:36 -06:00
Kay Kurokawa
8628b127f7 do not create new addresses in lbryum, get unused ones 2017-01-18 20:48:23 -05:00
Job Evers-Meltzer
1a850b0256 log exception on callback failure 2017-01-17 20:01:04 -06:00
Alex Grin
17d9c0ab97 Merge pull request #417 from lbryio/refactor_settings
refactor conf.settings
2017-01-17 14:53:01 -05:00
Alex Grintsvayg
267c6cbaca refactor conf.settings 2017-01-16 22:32:54 -05:00
Kay Kurokawa
03b214a9d2 convert claim_out['fee'] to float 2017-01-16 15:36:37 -05:00
Job Evers‐Meltzer
2b2fa29db5 Merge pull request #395 from lbryio/fix_publish_output
Fix Daemon RPC command publish output
2017-01-13 14:02:23 -06:00
Job Evers‐Meltzer
ddcfa7f97c Merge pull request #383 from lbryio/logging-improvements
Logging Improvements
2017-01-13 13:42:35 -06:00
Alex Grintsvayg
8277df1034 minor nits 2017-01-13 12:26:37 -05:00
Job Evers-Meltzer
cb2bb6ee6b bug fix: properly stop ConnectionManager
It is possible (likely) that a manage call is in progress when
`stop` is called. When that happens, _manage will continue to
run, and schedule another call - and the manager won't actually stop,
and will likely cause an error as other components have been torn down.

This fix adds a deferred that gets created when a manage call starts
and is fired when its done.  At this points its safe to start the
stopping process.  Also add a check to not schedule another manage
call if we're stopped

This fixes https://app.asana.com/0/142330900434470/239832897034382
2017-01-13 08:24:06 -06:00
Job Evers-Meltzer
0bb62515a8 reorder functions to match call order 2017-01-13 08:24:06 -06:00
Job Evers-Meltzer
f535d96929 switch stop to inlineCallback 2017-01-13 08:24:06 -06:00
Job Evers-Meltzer
15c5075d38 refactor closing peers 2017-01-13 08:24:06 -06:00
Job Evers-Meltzer
2449604844 fixup: bug fix for stopping downloads 2017-01-13 08:24:06 -06:00
Job Evers-Meltzer
6035a84675 bug fix for stopping downloads
deferredlist returns a tuple of (success, result) and the previous
code was looking at the entire tuple not the success values.
2017-01-13 08:24:05 -06:00
Job Evers-Meltzer
1b2c46e224 make _download_manager private 2017-01-13 08:19:23 -06:00
Job Evers‐Meltzer
61702ba1e4 Merge pull request #301 from lbryio/query-available-blobs
Query available blobs and Upload to Lighthouse Scripts
2017-01-12 08:42:08 -06:00
Alex Grintsvayg
5c429e15bd remove authjsonrpc subhandlers. we dont use them 2017-01-11 15:39:28 -05:00
Alex Grintsvayg
628defa891 remove extraneous ellipses in messages 2017-01-11 15:39:28 -05:00
Alex Grintsvayg
962edb8e4c rename api endpoints 2017-01-11 15:39:28 -05:00
Job Evers-Meltzer
5dbf9034ec Add scripts related to querying / downloading sd blobs 2017-01-11 12:05:34 -06:00
Job Evers‐Meltzer
c393bd97e8 Merge pull request #388 from lbryio/hash-announce
ensure hash_announcer exists before announcing
2017-01-09 15:23:53 -06:00