Compare commits

...
3392 Commits
Author SHA1 Message Date
Jack Robison beab40a8dd Bump version 0.19.3rc3 --> 0.19.3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-05-04 11:16:44 -04:00
Jack Robison ba88878f10 changelog 2018-05-04 11:15:56 -04:00
Thomas Zarebczan 7800d8740f w > wb
https://docs.python.org/3/tutorial/inputoutput.html#reading-and-writing-files
2018-05-04 01:11:58 -04:00
Jack Robison e0812fd7ed show local, remote, and s3 header heights in the log 2018-05-02 17:26:49 -04:00
Jack Robison d2987ffc91 socket might not have TCP_KEEPx attributes 2018-05-02 17:26:37 -04:00
Jack Robison 41b9ad9458 Bump version 0.19.3rc2 --> 0.19.3rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-05-02 15:51:04 -04:00
Jack Robison 59138f8579 version 2018-05-02 15:50:45 -04:00
Jack Robison 40995f2809 download headers from s3 when more than 10 chunks behind 2018-05-02 15:35:17 -04:00
Jack Robison 1de6966cd2 fix tests 2018-05-02 15:31:33 -04:00
Alex Grintsvayg 00b8166bb1 undeprecated report_bug while app team works on a new bug reporting flow 2018-05-02 15:12:40 -04:00
Jack Robison b75c8d96ce Bump version 0.19.2rc3 --> 0.19.2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-28 15:35:46 -04:00
Jack Robison cb83531d05 Bump version 0.19.2rc2 --> 0.19.2rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-28 15:15:47 -04:00
Jack Robison dc65fd148e Bump version 0.19.2rc1 --> 0.19.2rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-26 13:36:51 -04:00
Jack Robison 439a0f8778 fix docstrings
-add docopt unit test
2018-03-26 13:20:33 -04:00
Jack Robison a9fd19e6cf Merge pull request #1157 from lbryio/fix-1156
Fixed regression in stream_availablity command
2018-03-26 10:20:08 -04:00
hackrush aa7b440989 Fixed regression in stream_availablity command 2018-03-26 19:43:06 +05:30
Jack Robison 1aeba976da Merge pull request #1139 from lbryio/no-short-flags
Remove flags decorator from server.py as short flags are no longer used
2018-03-23 15:05:25 -04:00
Jack Robison f0742675b8 Merge branch 'master' into no-short-flags 2018-03-23 14:59:53 -04:00
Alex Grintsvayg 9ee5a3511d missed this in dht-compat merge 2018-03-23 12:50:18 -04:00
Jack Robison 69657750b8 Bump version 0.19.1 --> 0.19.2rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-22 17:04:12 -04:00
Jack Robison cb069ca002 add blob_reflect 2018-03-22 16:54:29 -04:00
Jack Robison 3085e28490 don't try to resend failed blobs to reflector
-fixes infinite loop where client keeps trying to send failing blobs, which may be failing because they are invalid

-return list of reflected blob hashes from BlobReflectorClient
2018-03-22 16:53:16 -04:00
Jack Robison 679c2f403f fix incorrectly raised DownloadCanceledError for already verified blobs
-make InvalidDataError message clearer
-fix BlobReflectorClient result
2018-03-22 13:23:12 -04:00
Alex Grin 0cbe11b263 Update INSTALL.md 2018-03-21 08:25:24 -04:00
Alex Grintsvayg 539881b5ad oops 2018-03-20 11:38:02 -04:00
Thomas Zarebczan ba8248887a cleanup changelog 2018-03-20 11:29:30 -04:00
Jack Robison ef7a360ee6 docs 2018-03-20 10:44:17 -04:00
Jack Robison de280b5ebf Bump version 0.19.1rc7 --> 0.19.1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-20 10:15:50 -04:00
Jack Robison f283a2116e changelog 2018-03-20 10:15:01 -04:00
Jack Robison 113cc8bb15 Bump version 0.19.1rc6 --> 0.19.1rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-19 14:31:17 -04:00
Jack Robison 7096d54e60 Merge remote-tracking branch 'origin/fix-slow-file-manager-setup' 2018-03-19 14:28:57 -04:00
Jack Robison b28bdbd752 rename existing reupload.reflect_stream --> reupload.reflect_file, add a reupload.reflect_stream function 2018-03-19 13:55:11 -04:00
Jack Robison f94a9e8729 start lbry files in parallel 2018-03-19 13:46:27 -04:00
Jack Robison 43c73b9abf fix slow sqlite query 2018-03-19 13:31:05 -04:00
hackrush 9a3eec0950 Sanitize changelog 2018-03-18 16:13:45 +05:30
hackrush 3724fa1810 Removed last flag decorator 2018-03-18 16:11:19 +05:30
hackrush f7f6770120 Removed flags decorator as short flags are no longer used. 2018-03-18 16:11:19 +05:30
hackrush 1d9c996217 Merge pull request #1148 from lbryio/channel-bid
Update channel balance checking to match claim balance checking
2018-03-17 09:05:08 +05:30
hackrush 2b69d2fad0 Fix pylint error 2018-03-16 21:42:40 +05:30
Jack Robison 0313f857ba don't try to delete the stream terminator from the blob table when deleting a stream 2018-03-15 17:44:54 -04:00
Jack Robison 8af96a0c51 don't try to announce the stream terminator 2018-03-15 17:42:21 -04:00
Thomas Zarebczan db821c51b7 update changelog 2018-03-15 10:15:02 -04:00
Jack Robison adb1291c09 fix blob list key error 2018-03-15 09:55:40 -04:00
Thomas Zarebczan b218e84d29 update channel balance checking to match claim
Simple balance check before calling get_max_usable_balance_for_claim - matches what happens on the claim.

Also provide clearer error message about maximum amount
2018-03-15 09:42:17 -04:00
Jack Robison 80fcb760b7 Bump version 0.19.1rc5 --> 0.19.1rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-14 16:45:39 -04:00
Jack Robison 5ca48944c6 requirements 2018-03-14 16:45:08 -04:00
Jack Robison bc2f5901a7 Merge branch 'add-txlbryum' 2018-03-14 15:07:57 -04:00
Lex Berezhny 633b49da92 removed RequestCounter 2018-03-14 15:01:47 -04:00
Jack Robison 76b3d219c8 Bump version 0.19.1rc4 --> 0.19.1rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-14 13:54:05 -04:00
Jack Robison e94d10d3eb only call get_max_usable_balance_for_claim in Wallet.py if the bid looks too high for the balance 2018-03-14 13:47:34 -04:00
Jack Robison 25eb64b346 Bump version 0.19.1rc3 --> 0.19.1rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-13 17:34:08 -04:00
Jack Robison 9b44ba7c84 only call get_max_usable_balance when the bid might be too high 2018-03-13 17:32:29 -04:00
Jack Robison 69ecc6ce90 Bump version 0.19.1rc2 --> 0.19.1rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-13 11:44:27 -04:00
Jack Robison cde78f8134 migrate configured download directory instead of assuming the default 2018-03-13 11:40:34 -04:00
Alex Grintsvayg ed3e825472 cleaned up duplicates in changelog 2018-03-13 09:58:20 -04:00
Alex Grin 6dd8138c05 Merge pull request #1138 from lbryio/dht-compat
make dht forwards-compatible for upcoming switch to standardized bencode dict keys
2018-03-13 09:47:00 -04:00
Alex Grintsvayg d0aa0a7d0c make dht forwards-compatible for upcoming switch to standardized bencode dict keys 2018-03-13 09:43:32 -04:00
Lex Berezhny 37bfed8aee Merge pull request #1137 from lbryio/new-channel-fix
Error cleanly when claiming a new channel with exact or higher amount than balance
2018-03-12 16:17:18 -04:00
hackrush 16f2a5429b Name and output message fix. 2018-03-13 01:26:18 +05:30
Jack Robison e881b608bf Revert "don't block daemon startup on the file manager"
This reverts commit f25b772
2018-03-12 10:44:29 -04:00
Jack Robison b41bb9beee Bump version 0.19.1rc1 --> 0.19.1rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-09 14:14:02 -05:00
Jack Robison f25b772b56 don't block daemon startup on the file manager 2018-03-09 14:09:07 -05:00
Jack Robison f07e696c31 fix get_pending_blobs_for_stream 2018-03-09 14:07:26 -05:00
hackrush f5aadf3918 Sanitized logged error for channel and name claims 2018-03-09 21:28:33 +05:30
hackrush 6d4af4ba90 Error cleanly when claiming a new channel with exact or higher amount than balance
fixes #1107
2018-03-09 21:28:33 +05:30
Jack Robison 96e30984c1 Bump version 0.19.0 --> 0.19.1rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-08 16:51:23 -05:00
Jack Robison de0b60aa9a Merge branch 'fix-reflector' 2018-03-08 16:49:28 -05:00
Jack Robison 81de5fbbf4 verify_will_announce_head_and_sd_blobs 2018-03-08 16:46:39 -05:00
Jack Robison cdfb7f4cb4 fix blob_list error 2018-03-08 16:43:22 -05:00
Jack Robison 3f1bcbffeb fix blob_announce when announcing a single blob 2018-03-07 18:25:30 -05:00
Alex Grintsvayg 5f35cb43c8 better logo 2018-03-07 05:54:50 -05:00
Alex Grintsvayg 20da84ba09 add icon to docs 2018-03-07 05:30:16 -05:00
Jack Robison 2040748c62 add stratum client protocol 2018-03-06 14:30:19 -05:00
Alex Grintsvayg 3b855a286e didnt build it 2018-03-05 19:00:10 -05:00
Alex Grintsvayg a96ee6230f fix docs theme 2018-03-05 18:57:05 -05:00
Alex Grintsvayg 59d56acf09 Merge branch 'autogen_docs'
* autogen_docs:
  Consolidated all 3 scripts into 1, better error messages
  ImportError checking and kill process after completion
  Review and script fixes
  Added tests for removing short args in cli
  Added scripts to autogenerate docs and api from docstring
2018-03-05 18:19:06 -05:00
hackrush 53c5134591 Consolidated all 3 scripts into 1, better error messages 2018-03-06 03:55:50 +05:30
hackrush c7bfb0a2e7 ImportError checking and kill process after completion 2018-03-06 03:50:12 +05:30
hackrush 30bfb9ac88 Review and script fixes 2018-03-06 03:50:12 +05:30
hackrush 14c01b095b Added tests for removing short args in cli 2018-03-06 03:50:12 +05:30
hackrush da4a24d79f Added scripts to autogenerate docs and api from docstring
Summary of changes
  Removed single dashed(short args) arguments(possibly breaking changes
for app side)
  Standardised the docstrings
  Added scripts to autogenerate API and CLI documentation using the
docstrings
2018-03-06 03:50:12 +05:30
Alex Grintsvayg 95e12a208d deprecate report_bug 2018-03-05 14:17:57 -05:00
Jack Robison 67a3001a0b Bump version 0.19.0rc38 --> 0.19.0
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-02 23:01:23 -05:00
Jack Robison 1a749b6794 changelog 2018-03-02 23:00:16 -05:00
Jack Robison 323b1c34af Merge branch 'fix-update-download-metadata' 2018-03-02 19:46:52 -05:00
Jack Robison a12b011b1e get file claim info by outpoint 2018-03-02 18:25:53 -05:00
Jack Robison 2c91d30655 Bump version 0.19.0rc37 --> 0.19.0rc38
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-03-02 17:36:56 -05:00
Jack Robison e4acdba9e4 Merge branch 'remove-updated-stream-on-publish' 2018-03-02 17:31:21 -05:00
Jack Robison 7862ee6715 fix blob_announce command 2018-03-02 16:46:07 -05:00
Jack Robison 01c4c6ed97 fetch claim heights 2018-03-02 16:46:02 -05:00
Jack Robison 6a4b65a796 have get fail when given a channel uri before attempting to resolve 2018-03-02 15:34:34 -05:00
Jack Robison 35426c7350 remove some unused code 2018-03-02 15:34:34 -05:00
Jack Robison 1958327796 comments and logging 2018-03-02 15:34:34 -05:00
Jack Robison 76cb674ebb fix updating content claims for existing files
-update lbry file attributes as soon as a change to the content claim occurs
2018-03-02 15:34:20 -05:00
Jack Robison d1240541c8 always update lbry file attributes after publishing 2018-03-02 15:33:48 -05:00
Jack Robison 91229aac6e remove old stream on a publish update 2018-03-02 15:33:48 -05:00
Jack Robison d8a728e931 Merge branch 'fix-database-locked' 2018-03-02 15:17:09 -05:00
Jack Robison 96d435cebd don't import reactor, set in SqliteConnection 2018-03-02 15:15:42 -05:00
Jack Robison bceaaa5724 delay re-running query after database locked error 2018-03-02 15:15:41 -05:00
Jack Robison 476a44ddb5 Merge branch 'fix-join-dht-attribute-error' 2018-03-02 15:14:28 -05:00
Jack Robison a1aadb0bce fix join_dht attribute error 2018-03-02 15:13:22 -05:00
Alex Grintsvayg d086fb9547 only log errors to loggly 2018-03-01 16:31:00 -05:00
Alex Grin 6395ac4f59 close #1111 2018-02-27 14:12:15 -05:00
Alex Grin 7634d056a9 Update INSTALL.md 2018-02-27 14:10:49 -05:00
Alex Grintsvayg fa33110d04 stop spamming cryptonator errors. fixes #984 2018-02-27 14:06:45 -05:00
Jack Robison 38d1ee6500 Merge remote-tracking branch 'origin/update_fix' 2018-02-22 14:11:39 -05:00
Jack Robison dafa80ce29 Merge branch 'master' into update_fix 2018-02-22 14:10:51 -05:00
Jack Robison 21900b2e7f Bump version 0.19.0rc36 --> 0.19.0rc37
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-02-22 10:50:03 -05:00
Jack Robison a01dd0d21d Merge branch 'use-storage-functions' 2018-02-22 10:49:47 -05:00
Jack Robison 741e395677 fix blob_list falsely returning an empty list for streams with known blobs
-remove get_blobs functions from Daemon, use functions in SQLiteStorage instead
2018-02-22 10:37:53 -05:00
Jack Robison 9a046fca0f remove unused calculate_available_blob_size function 2018-02-22 10:22:53 -05:00
Jack Robison 3b369103a0 Bump version 0.19.0rc35 --> 0.19.0rc36
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-02-21 19:19:15 -05:00
Jack Robison b1c66015e1 detect and remove invalid streams and sd blobs 2018-02-21 19:09:10 -05:00
Jack Robison 466654ffd0 Merge branch 'fix-1124' 2018-02-21 17:23:17 -05:00
Jack Robison 73eb66c0f2 pylint 2018-02-21 16:45:12 -05:00
Jack Robison 4e599b30d3 changelog 2018-02-21 16:44:22 -05:00
Jack Robison 8b93fb5b13 update test
check sd info read from the blob and from the database
2018-02-21 16:41:15 -05:00
Jack Robison d7bfeae6b8 fix position of stream terminator blob 2018-02-21 16:37:00 -05:00
Jack Robison 3e6b00ad00 remove sort from get_stream_hash
error on zero length data blobs or a non-zero length stream terminator blob
2018-02-21 16:34:48 -05:00
Jack Robison 0904c74273 remove unused create_plain_sd function 2018-02-21 16:33:15 -05:00
hackrush 3754f34f53 Review fixes and additional comments in test 2018-02-21 14:22:11 +05:30
hackrush 2368433b22 Check for max usable balance before updating 2018-02-20 08:54:03 +05:30
hackrush d72ef784ed Removed daemon side bid checks during publish
Fixes #748

Fixed failing test, Yay!

Why CHANGELOG? Why not anarchy?
2018-02-20 08:54:03 +05:30
hackrush c4c443d8d7 Merge pull request #1110 from lbryio/Jeremy1026-add-new-exception
Jeremy1026 add new exception
2018-02-18 11:51:51 +05:30
hackrush 5fee660c9c Fixed error types to be more appropriate 2018-02-17 20:18:55 +05:30
hackrush 3a11956ec9 Fixed CHANGELOG 2018-02-17 19:29:53 +05:30
Jeremy Curcio 744dfb1234 Update change log 2018-02-17 19:29:53 +05:30
Jeremy Curcio 2621ba6982 Add exception for non-float bids when pubishing 2018-02-17 19:29:53 +05:30
Jack Robison 0edcf2dcc7 Bump version 0.19.0rc34 --> 0.19.0rc35
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-02-15 09:35:04 -05:00
Jack Robison 6ea5492ee5 dont delete old databases yet 2018-02-15 09:33:47 -05:00
Jack Robison 1a330fcb41 Bump version 0.19.0rc33 --> 0.19.0rc34
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-02-13 16:02:53 -05:00
Jack Robison e3d90f2240 Merge branch 'database-refactor' 2018-02-13 16:01:41 -05:00
Jack Robison 3da25b80b3 changelog 2018-02-13 15:44:21 -05:00
Jack Robison a7567361dc fix file name for files that already exist 2018-02-13 15:02:06 -05:00
Jack Robison e40d4f74d8 fix default db_revision 2018-02-13 14:42:53 -05:00
Jack Robison 73f09edcf0 fix setup and teardown for wallet tests
-also fixes a few wallet tests that weren't checking exceptions correctly
2018-02-13 14:22:52 -05:00
Jack Robison 9d87de1433 fix setup and teardown for blob manager tests 2018-02-13 14:22:40 -05:00
Jack Robison 3769287e88 fix setup and teardown for test_streamify 2018-02-13 14:22:21 -05:00
Jack Robison 68c906aff9 pylint 2018-02-13 10:27:52 -05:00
Jack Robison 9e11c075c6 cleaner foreign keys 2018-02-13 10:27:52 -05:00
Jack Robison b7d0191e5d update functional tests 2018-02-13 10:27:52 -05:00
Jack Robison 49507b98f4 update unit tests, add test_SQLiteStorage 2018-02-13 10:27:51 -05:00
Jack Robison e9b9118c2a whitespace 2018-02-13 10:27:51 -05:00
Jack Robison 9d539aaa16 migrate databases 2018-02-13 10:27:51 -05:00
Jack Robison c15850ccab re-enable filtering lbry files by claim attributes 2018-02-13 10:27:51 -05:00
Jack Robison 0df383b9f2 update Downloader and Publisher 2018-02-13 10:27:51 -05:00
Jack Robison ce4b82d929 update Daemon to use SQLiteStorage 2018-02-13 10:27:51 -05:00
Jack Robison 9a8cac20e7 update reflector client and server to use SQLiteStorage 2018-02-13 10:27:51 -05:00
Jack Robison 68542f3ae1 refactor EncryptedFileDownloader and EncryptedFileManager
-remove stream info manager (DBEncryptedMetadataManager)
-split `add_lbry_file` into separate `add_published_file` and `add_downloaded_file` functions
-set the download path upon adding file to the db, use the source file path for publishes
-remove the lbry file manager-wide download directory, set for each file individually
-add claim `metadata`, `claim_name`, `claim_id`, `outpoint`, `txid`, `nout`, `channel_claim_id`, and `channel_name` attributes to EncryptedFileDownloader
2018-02-13 10:27:50 -05:00
Jack Robison f8c33b6acb refactor lbrynet.core.StreamDescriptor
-remove lbrynet/lbry_file/StreamDescriptor.py
2018-02-13 10:27:50 -05:00
Jack Robison 0b1f4192fc update Wallet to use SQLiteStorage
-remove CachedClaim and wallet storage classes
2018-02-13 10:27:50 -05:00
Jack Robison af87df3709 remove sqlite_helpers 2018-02-13 10:27:50 -05:00
Jack Robison e671005c3c update BlobManager to use SQLiteStorage, remove old database functions
-remove blob upload/download history
2018-02-13 10:27:50 -05:00
Jack Robison db7061ce92 set up a SQLiteStorage object in Session 2018-02-13 10:27:50 -05:00
Jack Robison 2d462acefc add SQLiteStorage 2018-02-13 10:27:50 -05:00
Jack Robison e77e41fb6d move migrators to lbrynet.database, remove lbrynet.db_migrator 2018-02-13 10:27:49 -05:00
Jack Robison 5c4c182332 increase pylint line length
-run integration tests with -v
2018-02-13 10:27:42 -05:00
Jack Robison cec788ff4b clean up changelog 2018-02-13 09:32:28 -05:00
Alex Grin d6819d8091 Merge pull request #1086 from lbryio/add-conf-flag-to-cli
fixes for the --conf flag
2018-02-12 17:01:43 -05:00
Alex Grintsvayg 01a9d96f28 Merge branch 'KamilPiekutowski-channels_not_get_able'
* KamilPiekutowski-channels_not_get_able:
  fixed the error when trying to perform get on channels
2018-02-12 16:40:50 -05:00
Alex Grintsvayg bb2efdcc7c fixed the error when trying to perform get on channels
now it states that get cannot be used on channels

closes #623
closes #1085
2018-02-12 16:40:29 -05:00
Jack Robison bd6bd24478 Bump version 0.19.0rc32 --> 0.19.0rc33
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-02-12 13:24:19 -05:00
Antonio Quartulli 639744e047 conf: initialize IDs after reading config file
Installation_id and node_id are stored in the data dir.
For this reason they should be read/created only after the
config has been parsed.
This way they can be retrieved or stored at the right location.

Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2018-02-10 16:22:33 +08:00
Antonio Quartulli 34976c7602 DaemonCLI: add --conf flag
When starting a daemon with a different configuration,
the same should also be used by the cli tool.

Add the --conf flag to the cli command to allow using a
custom config file.

Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2018-02-10 16:22:32 +08:00
hackrush dc82c1be16 Merge pull request #1104 from rickbatka/fix-930
Fix #930 "Improper CLI parsing of settings_set"
2018-02-09 22:46:58 +05:30
rick batka 69a99a61ba Fix issue #930. Disallow positional arguments for CLI settings_set and fix error reporting when settings_set fails. 2018-02-09 11:30:29 -05:00
Alex Grintsvayg b3d3c1c93b drop commands list from cli help 2018-02-08 09:36:59 -05:00
Alex Grintsvayg 21e653367f Merge branch 'remove_temp_blob_manager'
* remove_temp_blob_manager:
  download script now gets all blobs in stream if you give it an sd hash
2018-02-07 11:22:00 -05:00
Alex Grintsvayg 2f8c645edc download script now gets all blobs in stream if you give it an sd hash 2018-02-07 11:21:34 -05:00
Jack Robison 1c45cf05d7 Merge branch 'atiaxi-blob-list-uri-fix' 2018-02-06 22:55:02 -05:00
Jack Robison 0f46785739 Merge branch 'blob-list-uri-fix' of https://github.com/atiaxi/lbry into atiaxi-blob-list-uri-fix 2018-02-06 22:51:06 -05:00
Alex Grin 433defa7c8 Merge pull request #1096 from lbryio/re-join-dht
Re-join the DHT if the node has no active peers
2018-02-06 09:13:50 -05:00
Roger Ostrander 44df26abd3 Removing unused import 2018-02-06 01:32:10 -05:00
Roger Ostrander d8e1738f27 Code review changes (removed safe_dict_descend) 2018-02-06 01:16:10 -05:00
Antonio Quartulli 8a7e707504 DHTPeerFinder: re-join the network if we have no peers
Periodically check if the routing table is empty and, if so,
re-attempt joining the DHT network.

This check is performed in the main DHTPeerFinder loop every 60 secs.

Closes: #1093
Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2018-02-06 12:33:12 +08:00
Antonio Quartulli 4f7885e499 dht_node: add hasContacts method
This method can be used by other components to check
if in the Node routing table there is at least one peer.

Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2018-02-06 12:33:10 +08:00
Antonio Quartulli ce0af77aa9 dht_node: split network start and join procedures
In order to attempt to join the DHT several times
(i.e. when the first attempt has failed) we need to
split the components initialization from the real
joining operation.

Create node.startNetwork() to initialize the node
and keep the rest in node.joinNetwork()

Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2018-02-06 12:19:33 +08:00
Jack Robison 1f68d29d73 Bump version 0.19.0rc31 --> 0.19.0rc32
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-02-05 21:25:33 -05:00
LBRY Docs f2e3b27b6a Update to reflect year 2018 2018-02-05 12:40:49 -08:00
Roger Ostrander 3fdde0f4ce Added CHANGELOG entry for issue 895 2018-02-03 23:23:34 -05:00
Roger Ostrander a4343c3eb3 API call to blob_list with uri parameter now succeeds 2018-02-03 23:08:15 -05:00
Jack Robison 5cbfa273e5 Merge branch 'remove-gmpy-and-seccure' 2018-02-01 14:14:52 -05:00
Jack Robison f918916160 remove gmpy and seccure dependencies 2018-02-01 12:39:00 -05:00
Jack Robison 1327757e35 Bump version 0.19.0rc30 --> 0.19.0rc31
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-01-31 19:52:24 -05:00
Jack Robison b8accbb049 Bump version 0.19.0rc29 --> 0.19.0rc30
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-01-29 10:29:54 -05:00
Jack Robison 787a7a0262 Merge remote-tracking branch 'lbryio/perm_url_changelog' 2018-01-29 10:24:26 -05:00
hackrush 5a3a592df8 Related changlelog for the PR lbryio/lbryum#203 2018-01-26 15:52:25 +05:30
Alex Grintsvayg 3b5978992c no more lbryapi 2018-01-23 16:53:29 -05:00
Jack Robison 798d2c6984 Bump version 0.19.0rc28 --> 0.19.0rc29
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-01-22 16:04:54 -05:00
Jack Robison 973978c1e5 pylint 2018-01-22 16:04:08 -05:00
Jack Robison 52aa1ba3a0 Bump version 0.19.0rc27 --> 0.19.0rc28
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-01-22 15:59:54 -05:00
Jack Robison 87d0f9a9e2 changelog 2018-01-22 15:59:20 -05:00
Jack Robison eb4ba089ab fix checking the external ip 2018-01-22 15:47:14 -05:00
Alex Grintsvayg a6588f740a stop sending useless analytics event 2018-01-22 15:21:39 -05:00
Alex Grintsvayg 2c8c400553 update issue template 2018-01-22 09:35:55 -05:00
Jack Robison 9121b79f22 Bump version 0.19.0rc26 --> 0.19.0rc27
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-01-18 13:44:15 -05:00
Jack Robison 02619259d1 Merge branch 'abandon_stuff' 2018-01-18 13:42:59 -05:00
Jack Robison edb0f8deed changelog and doc 2018-01-18 13:41:17 -05:00
hackrush 7472d12644 Removed include_tip_info from transaction_list, goes with lbryum#183 2018-01-18 08:43:58 +05:30
Umpei Kay Kurokawa 02a5069e3a Merge pull request #1053 from lbryio/new_paytomany
Fix to go with https://github.com/lbryio/lbryum/pull/195
2018-01-16 13:31:23 -05:00
Kay Kurokawa f5cc8b0961 add changelog 2018-01-16 13:30:12 -05:00
Kay Kurokawa 1c608a09a9 use reworked lbryum payto command 2018-01-16 13:30:12 -05:00
Jack Robison c29456b130 Bump version 0.19.0rc25 --> 0.19.0rc26
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-01-12 09:56:19 -05:00
Jack Robison 63a1f7071d Merge branch 'conf-file-server-lists' 2018-01-12 09:52:28 -05:00
Jack Robison b6afc437e6 combine auto_re_reflect and reflect_uploads settings 2018-01-12 09:21:24 -05:00
Jack Robison 8a133f9749 use lists of hostname:port strings in conf file 2018-01-09 16:55:39 -05:00
Jack Robison 9302d71012 Bump version 0.19.0rc24 --> 0.19.0rc25
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-01-07 12:18:37 -05:00
akinwale 5677f6d00d added a new startup stage for wallet_unlock (#1048)
* added a new startup stage to indicate if the daemon is waiting for wallet_unlock
2018-01-07 06:44:29 +01:00
Alex Grin 1c57b08dbe Merge pull request #1052 from lbryio/download_dir_remove
remove download_directory from options
2018-01-05 15:36:44 -05:00
Thomas Zarebczan 4b6d0d33ef remove download_directory from options 2018-01-05 14:19:21 -05:00
Jack Robison e4364a60c2 Bump version 0.19.0rc23 --> 0.19.0rc24
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2018-01-04 21:39:36 -05:00
Jack Robison b046a6578b add blockchain_name and lbryum_servers to the adjustable settings 2018-01-04 21:30:41 -05:00
Jack Robison 92356840ae Merge branch 'faster-startup' 2018-01-04 21:30:02 -05:00
Jack Robison 64e04f8a68 refactor start_lbry_file 2018-01-04 21:28:09 -05:00
Jack Robison 8a6291e37e changelog 2018-01-04 21:25:57 -05:00
Jack Robison 76de605b7f refactor start_lbry_files 2018-01-04 21:25:56 -05:00
Jack Robison 2af61460a7 add attributes to lbry file base classes 2018-01-04 21:25:56 -05:00
Jack Robison bc58add6de logging 2018-01-04 21:25:56 -05:00
Jack Robison ecb9909faa fix node and installation id whitespace bugs 2018-01-04 21:25:55 -05:00
Jack Robison 62a8789393 change default full_status to True in _get_lbry_files 2018-01-04 21:25:55 -05:00
Jack Robison 2523afa266 catch error from blob with invalid AES key size 2018-01-04 21:25:55 -05:00
Jack Robison 6385ab27c1 fix handling stream with no data blobs
fixes https://github.com/lbryio/lbry/issues/905
2018-01-04 21:25:54 -05:00
Jack Robison 7a020bec05 Merge remote-tracking branch 'origin/add-conf-file-flag' 2018-01-03 14:46:57 -05:00
Antonio Quartulli 1a234b0b88 Update CHANGELOG.md
Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2017-12-30 04:11:10 +08:00
Antonio Quartulli 79054037a7 conf: make config file a CLI parameter
The config file might be stores in an alternate location for several
reasons (i.e. testing different configs or running multiple nodes on the
same host). Make the config file a CLI parameter so that it can be
specified when launching the lbrynet-daemon.

Related to #1039

Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2017-12-30 04:11:06 +08:00
Jack Robison 3d94d9ad9e Bump version 0.19.0rc22 --> 0.19.0rc23
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-29 12:53:27 -05:00
Jack Robison bf46f5616b Merge branch 'add_lbry_file_manager_to_reflector_2' 2017-12-29 12:39:50 -05:00
Alex Grintsvayg b0c4746413 delete line that does nothing 2017-12-29 11:12:33 -05:00
Antonio Quartulli 0d3493ef73 conf: add method to check if a setting has default value
Sometimes it might be helpful to check if a given config
setting is still the default or if it was touched by the user
in any way (e.g. env, config file, ...).

Add is_default() method to Config object to perform such check.

Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2017-12-29 19:49:59 +08:00
Alex Grintsvayg 21d9b9bc71 minor fixes 2017-12-28 10:08:30 -05:00
Jack Robison f509f354b4 Merge branch 'stream-availability' 2017-12-20 21:29:07 -05:00
Jack Robison 09c57675a7 add stream_availability and blob_availability, deprecate get_availability 2017-12-20 21:23:54 -05:00
Jack Robison 7c6c666342 fix verbose error 2017-12-20 20:43:01 -05:00
Jack Robison f0a1adc9c5 whitespace, logging 2017-12-20 20:43:01 -05:00
Jack Robison 990e2a714a Bump version 0.19.0rc21 --> 0.19.0rc22
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-18 16:20:56 -05:00
Jack Robison 225745f0e1 Bump version 0.19.0rc20 --> 0.19.0rc21
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-18 14:34:48 -05:00
Jack Robison e22d43bb03 fix wallet_unlock 2017-12-18 13:17:54 -05:00
Jack Robison 4dc6eb8fea Bump version 0.19.0rc19 --> 0.19.0rc20
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-18 11:34:33 -05:00
Jack Robison 20b9e4d17e fix typo 2017-12-18 11:31:59 -05:00
Jack Robison 8c2d381aee Wallet encryption (#783)
* update known commands
* add wallet_unlock, block wallet startup on being unlocked
* add wallet_decrypt and wallet_encrypt
* wallet encryption unit tests
* added use_keyring configuration option in order to make keyring password storage optional
2017-12-17 07:00:12 +01:00
Jack Robison bcdeea75d6 Bump version 0.19.0rc18 --> 0.19.0rc19
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-15 20:39:39 -05:00
Jack Robison ce181f2896 Merge branch 'pylint' 2017-12-15 20:32:43 -05:00
Jack Robison a6f0c5fb4c pylint fixes
fix exception formatting and a circular import
2017-12-15 20:25:20 -05:00
Jack Robison 74ec4192e2 delete outdated scripts 2017-12-15 20:23:16 -05:00
Jack Robison 7794109e57 Bump version 0.19.0rc17 --> 0.19.0rc18
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-13 16:45:59 -05:00
Jack Robison e58f3593ee pylint 2017-12-13 16:43:49 -05:00
Jack Robison 5a41afc9fc Bump version 0.19.0rc16 --> 0.19.0rc17
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-13 16:40:25 -05:00
Alex Grintsvayg ebed4f010b fixes #1029 - stupid error messages 2017-12-13 13:56:44 -05:00
Jack Robison 668eaa6591 Bump version 0.19.0rc15 --> 0.19.0rc16
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-12 09:32:31 -05:00
Jack Robison b2141bdf3d fix import error 2017-12-12 09:26:28 -05:00
Jack Robison f29437f474 Bump version 0.19.0rc14 --> 0.19.0rc15
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-11 14:54:24 -05:00
Jack Robison 7e3abe0bda Bump version 0.19.0rc13 --> 0.19.0rc14
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-11 12:49:50 -05:00
Jack Robison 1307727130 revert run commands using deferToThread
reverts most of
https://github.com/lbryio/lbry/commit/100493f9068589095c489f797587ddbfd1
7f7899
2017-12-11 12:45:38 -05:00
Jack Robison fbe55d5cd3 Bump version 0.19.0rc12 --> 0.19.0rc13
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-07 15:06:11 -05:00
Jack Robison 58f0d5da24 Merge branch 'least-used-addresses' 2017-12-07 15:05:47 -05:00
Jack Robison 100493f906 run commands using the network as deferToThread, don't manually broadcast claims from lbrynet 2017-12-07 14:36:52 -05:00
Jack Robison 2ee1328eea changelog 2017-12-07 14:36:52 -05:00
Jack Robison b7ee5419d4 better address use, remove _save_wallet from Wallet.py 2017-12-07 14:36:51 -05:00
Jack Robison 66f0c0f296 Bump version 0.19.0rc11 --> 0.19.0rc12
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-07 14:36:02 -05:00
Jack Robison 0e47351521 Merge branch 'remove-lbryfile-message' 2017-12-07 14:23:54 -05:00
Jack Robison 330d0465b6 remove message field from lbry file json, add blobs_completed, blobs_in_stream, and status fields 2017-12-07 13:54:18 -05:00
Jack Robison fb65536f18 Bump version 0.19.0rc10 --> 0.19.0rc11
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-06 20:48:44 -05:00
Jack Robison 3793d7f5b8 Merge branch 'delete-unused-code' 2017-12-06 20:47:01 -05:00
Jack Robison fb6ceeed9e delete unused code 2017-12-06 20:41:24 -05:00
Jack Robison 6a83f67dfa Bump version 0.19.0rc9 --> 0.19.0rc10
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-06 20:22:39 -05:00
Jack Robison 8c865d4187 Merge branch 'refactor-file-manager' 2017-12-06 20:21:27 -05:00
Jack Robison 1b9b00b9de changelog 2017-12-06 20:20:29 -05:00
Jack Robison b7503f8b61 log traceback info for failed api requests 2017-12-06 19:52:29 -05:00
Jack Robison b2a0aa21c9 get search timeout from conf.settings 2017-12-06 19:52:29 -05:00
Jack Robison ac7ffdbf3a add lbry_file_metadata table to save outpoint data of downloads 2017-12-06 19:52:25 -05:00
Jack Robison 90aa89dcae re-add outpoint to file dictionary returned from file_ commands 2017-12-06 17:22:47 -05:00
Jack Robison 1594c6a831 move db functions in EncryptedFileManger to EncryptedFileMetadataManager
- remove TempEncryptedFileMetadataManager, run tests with the normal
DBEncryptedFileMetadataManager
2017-12-06 16:49:49 -05:00
Jack Robison f9dee51ca4 Bump version 0.19.0rc8 --> 0.19.0rc9
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-06 15:21:44 -05:00
Jack Robison eb3e1a195f Merge branch 'remove-file-name-logging' 2017-12-06 15:12:46 -05:00
Jack Robison 329d74f6be don't include file names when logging stream related info 2017-12-06 15:09:35 -05:00
Jack Robison a92191709d Bump version 0.19.0rc7 --> 0.19.0rc8
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-06 13:27:43 -05:00
Jack Robison 370d2f11da Merge branch 'fix-error-responses' 2017-12-06 13:26:55 -05:00
Jack Robison 8fdd8d8c43 fix api error responses 2017-12-06 13:25:58 -05:00
Jack Robison ecdba8dc38 Bump version 0.19.0rc6 --> 0.19.0rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-05 15:34:43 -05:00
Jack Robison 88c6eb7816 Merge branch 'increase_announce_duration' 2017-12-05 15:34:16 -05:00
Jack Robison 31e8e899c6 fix changelog 2017-12-05 14:19:39 -05:00
Jack Robison 7bb5448325 docs 2017-12-05 14:06:04 -05:00
Jack Robison 4c0692bd7a Bump version 0.19.0rc5 --> 0.19.0rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-05 14:03:10 -05:00
Jack Robison beb03e6425 Merge branch 'add-lbrynet-console' 2017-12-05 14:02:26 -05:00
Jack Robison 6b0d101115 add lbrynet-console to build 2017-12-05 13:34:50 -05:00
Jack Robison fbcc81adb4 add lbrynet-console 2017-12-05 13:34:46 -05:00
Kay Kurokawa 915ab668f5 add some tests to make sure file status after reflector server download (make sure in stopped state, and have correct number of blobs) 2017-12-05 13:18:31 -05:00
Kay Kurokawa 63c6d3580d do not yield on add_lbry_file() when obtaining sd blob as reflector server 2017-12-05 13:18:16 -05:00
Kay Kurokawa fcfeb0cb78 add changelog 2017-12-05 11:59:43 -05:00
Kay Kurokawa 989f77c00a increase SINGLE_HASH_ANNONCE_DURATION from 1 to 5 2017-12-05 11:55:59 -05:00
Jack Robison 5d95194469 Bump version 0.19.0rc4 --> 0.19.0rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-05 09:49:21 -05:00
Jack Robison 315ad70ce1 Merge branch 'add-claim-renew' 2017-12-05 09:43:47 -05:00
Jack Robison 23b7c5448b changelog 2017-12-05 09:42:44 -05:00
Kay Kurokawa 7e93ea8d97 do a sanity check to see if we have remote height, use remote height instead of local height when auto renewing 2017-12-05 09:41:45 -05:00
Kay Kurokawa bfbecd9196 fix use of return in inlinecallback, change to defer.returnValue(None) 2017-12-05 09:41:44 -05:00
Kay Kurokawa 707775214a update docstrings and make sure return value is consistent 2017-12-05 09:41:44 -05:00
Kay Kurokawa bf29d28c4d bug fix in claim_renew() 2017-12-05 09:41:43 -05:00
Kay Kurokawa 8f05c1083f pylint long lines 2017-12-05 09:41:43 -05:00
Kay Kurokawa 36510a0a59 make auto_renew_claim_height_delta settable in API commands settings_set 2017-12-05 09:41:43 -05:00
Kay Kurokawa e4e60ebe9b add auto_renew_claim_height_delta to configuration and auto renew after startup if necessary 2017-12-05 09:41:42 -05:00
Kay Kurokawa 1ea8c1ad29 no underscore necessary (not a private function) 2017-12-05 09:41:42 -05:00
Jack Robison d6e3b11026 add claim_renew 2017-12-05 09:41:42 -05:00
Jack Robison 0cf45657c0 Bump version 0.19.0rc3 --> 0.19.0rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-12-05 09:34:03 -05:00
Jack Robison 58b789ed42 fix https://github.com/lbryio/lbry/issues/1013 2017-12-05 09:31:29 -05:00
Jack Robison 1d3deb37b1 changelog 2017-12-04 13:13:40 -05:00
Kay Kurokawa 95289952b5 No need to set up DummmyRateLimiter for reflector test 2017-12-04 13:08:34 -05:00
Kay Kurokawa 4971ddda78 No need to check for None in reflector test tear down 2017-12-04 13:08:34 -05:00
Kay Kurokawa ae74d80c8a add lbry_file_manager to reflector server in functional reflector test, make sure file is added to lbry_file_manager when reflected 2017-12-04 13:08:34 -05:00
Kay Kurokawa ab667015c4 add lbry_file_manager to reflector server and add files to it 2017-12-04 13:08:33 -05:00
Kay Kurokawa 6218df2a92 make payment_rate_manager in add_lbry_file() an optional argument, initialize it from Session if not specified 2017-12-04 13:08:33 -05:00
Kay Kurokawa 57117baab5 remove ManagedEncryptedFileDownloader.load_file_attributes() move it to EncryptedFileDownloader.set_stream_info() 2017-12-04 13:08:32 -05:00
Jack Robison b859f7a23f Bump version 0.19.0rc2 --> 0.19.0rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-29 15:41:23 -05:00
Jack Robison ade8b64ca7 Merge branch 'remove-unused-files' 2017-11-29 12:48:23 -05:00
Jack Robison 552856ebaa remove old release scripts 2017-11-29 12:35:53 -05:00
Jack Robison 896f57a129 remove FAQ.md, update doc link in README.md 2017-11-29 12:17:04 -05:00
Jack Robison 00edd3cb66 remove unused files 2017-11-29 12:01:39 -05:00
Jack Robison 986fcd1660 docs 2017-11-28 13:12:57 -05:00
Jack Robison e3e8dea405 Bump version 0.19.0rc1 --> 0.19.0rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-28 12:59:17 -05:00
Jack Robison 188822ef20 Merge branch 'remove_claim_info_from_file' 2017-11-28 12:58:10 -05:00
Jack Robison 57152547ce docs 2017-11-28 12:19:19 -05:00
Kay Kurokawa c111bd49d3 add changelog 2017-11-28 11:53:17 -05:00
Kay Kurokawa c007ebd121 Fix test 2017-11-28 11:53:17 -05:00
Kay Kurokawa 50586fa39d use sd_hash instead of claim_id as a key for Daemon.streams dictionary 2017-11-28 11:53:16 -05:00
Kay Kurokawa 38834a083c when calling jsonrpc_get, check if you have to file by using the sd_hash instead of claim_id 2017-11-28 11:53:16 -05:00
Kay Kurokawa 70709b4ca4 remove use of name from reflector client, use file name instead 2017-11-28 11:53:15 -05:00
Kay Kurokawa 971c720642 removing claim information from files related API commands 2017-11-28 11:53:15 -05:00
Jack Robison 456c94b3cb Bump version 0.18.1rc13 --> 0.19.0rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-22 14:38:51 -05:00
Jack Robison e541f536d2 Bump version 0.18.1rc12 --> 0.18.1rc13
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-22 14:37:00 -05:00
Jack Robison 1819035566 Bump version 0.18.1rc11 --> 0.18.1rc12
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-22 14:12:10 -05:00
Jack Robison d0581f2cf7 Merge branch 'add-channel-import-and-export' 2017-11-22 14:03:45 -05:00
Jack Robison 200e9ae3d8 Bump version 0.18.1rc10 --> 0.18.1rc11
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-22 14:03:27 -05:00
Jack Robison 086c843068 add channel_list, deprecate channel_list_mine 2017-11-22 13:50:07 -05:00
Jack Robison d98e0e8110 add channel_import and channel_export 2017-11-22 13:46:34 -05:00
Umpei Kay Kurokawa d0b2de9850 Merge pull request #999 from lbryio/move_dht_tests
Merged DHT unit test folders
2017-11-16 15:00:51 -05:00
Kay Kurokawa 2208cede67 add changelog 2017-11-16 15:00:14 -05:00
Kay Kurokawa ed4104820d merge tests.dht into tests.unit.dht 2017-11-16 14:45:42 -05:00
Jack Robison e651c8269d Bump version 0.18.1rc9 --> 0.18.1rc10
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-15 14:35:10 -05:00
Jack Robison a8fa85ac94 Bump version 0.18.1rc8 --> 0.18.1rc9
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-15 09:27:21 -05:00
Jack Robison c93faa949d Bump version 0.18.1rc7 --> 0.18.1rc8
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-15 09:17:20 -05:00
Jack Robison fc68431048 Bump version 0.18.1rc6 --> 0.18.1rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-14 13:13:07 -05:00
Jack Robison 3ffe103824 Bump version 0.18.1rc5 --> 0.18.1rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-14 13:09:19 -05:00
Jack Robison 2f3bfb1a09 Bump version 0.18.1rc4 --> 0.18.1rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-13 14:17:54 -05:00
Jack Robison b000969ce5 Bump version 0.18.1rc3 --> 0.18.1rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-10 14:23:51 -05:00
Jack Robison 0b13615dc5 pylint 2017-11-10 14:23:14 -05:00
Jack Robison f65ec2c401 Bump version 0.18.1rc2 --> 0.18.1rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-10 13:16:53 -05:00
Alex Grin c3000e3b92 Merge pull request #993 from lbryio/fix-984
less verbose exchange rate error
2017-11-10 10:57:05 -05:00
Jack Robison 930e965d9c less verbose exchange rate error 2017-11-10 10:34:36 -05:00
Jack Robison 0cd497d602 Bump version 0.18.1rc1 --> 0.18.1rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-09 15:34:00 -05:00
Jack Robison 949b2dc215 Bump version 0.18.0 --> 0.18.1rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-08 19:57:49 -05:00
Jack Robison f2bd98509b Merge branch 'better-publish-errors' 2017-11-08 19:52:40 -05:00
Jack Robison 853bb67447 verify source and claim metadata before getting to _publish_stream 2017-11-08 19:50:37 -05:00
Jack Robison 28fea7093f Bump version 0.18.0rc1 --> 0.18.0
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-08 11:05:18 -05:00
Jack Robison 89d4351238 changelog 2017-11-08 11:03:59 -05:00
Jack Robison 143224fe0a Bump version 0.17.2rc11 --> 0.18.0rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-07 23:23:47 -05:00
Jack Robison e7a0aa28be Bump version 0.17.2rc10 --> 0.17.2rc11
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-07 23:22:13 -05:00
Jack Robison 8d2e8eac58 Bump version 0.17.2rc9 --> 0.17.2rc10
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-07 15:24:48 -05:00
Jack Robison c001a3d6a9 Merge branch 'remove-queued-decorator' 2017-11-07 15:18:56 -05:00
Jack Robison f87d6b08c8 remove queued decorator 2017-11-07 15:17:04 -05:00
Jack Robison 5bb08cdf5a Bump version 0.17.2rc8 --> 0.17.2rc9
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-07 15:15:54 -05:00
Umpei Kay Kurokawa 7898f6fdb2 Merge pull request #975 from lbryio/ordex-dht-list-fix
Don't filter out local node ID when returning peer list (continued)
2017-11-07 09:57:39 -05:00
Kay Kurokawa b380f5d344 completely remove unused from_peer field 2017-11-07 09:56:40 -05:00
Kay Kurokawa 9776655c3c remove unneeded if statement in getPeersForBlob 2017-11-07 09:56:40 -05:00
Kay Kurokawa 71ebf79939 add argument in DHTPeerFinder.find_peers_for_blob that filters itself from peer list. Use this argument to remove itself from peer list when downloading blobs
do not filter self on peer list
2017-11-07 09:56:40 -05:00
Kay Kurokawa 7e8f3254b1 Add to DHT Node class initialization argument peerPort where it serves blobs, instead of specifying it in announceHaveBlob 2017-11-07 09:56:40 -05:00
Kay Kurokawa cf1b9b2aa8 add changelog 2017-11-07 09:56:40 -05:00
Antonio Quartulli 965969b856 Don't filter out local node ID when returning peer list
If a node is returning a peer list for a given blob hash
(being this been requested via CLI or via DHT) and it is
part of the resulting peer list, it will filter itself out
before returning the list.

This makes the results across the DHT inconsistent as
different nodes won't include themselves when
responding a findValue/findNode query.

Remove such filtering so that the local node ID is always
included when needed.

Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2017-11-07 09:56:40 -05:00
Alex Grin 1ae3cd1f61 Merge pull request #989 from ian-h-chamberlain/fix-delete-blob-twice
Delete blob hash from list when blob is deleted
2017-11-07 09:30:03 -05:00
Ian Chamberlain 20e9ff2902 Delete blob hash from list when blob is deleted 2017-11-05 21:56:54 -05:00
Jack Robison 8d095ab36f Bump version 0.17.2rc7 --> 0.17.2rc8
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-04 21:03:46 -04:00
Jack Robison 6d2148c966 changelog 2017-11-04 21:02:00 -04:00
Jack Robison 81a44fa824 Merge branch 'use-shared-queued-deferredsemaphore' 2017-11-04 21:01:38 -04:00
Jack Robison 5506af03d8 Merge branch 'ian-h-chamberlain-fix-test-parallel-connections' 2017-11-04 20:56:15 -04:00
Jack Robison 43ba33fd80 changelog 2017-11-04 20:37:52 -04:00
Jack Robison a79a00180d rename variable 2017-11-04 20:37:52 -04:00
Jack Robison 36782e0878 use shared deferredSemaphore for daemon methods decorated with 'queued'
fixes race condition between publish and channel_new
2017-11-04 20:37:46 -04:00
Ian Chamberlain 733e356e55 Fix failing ConnectionManager unit test 2017-11-04 15:15:04 -04:00
Alex Grin 5c2d1ec3c2 We're on discord now. Fixes #986 2017-11-03 18:51:06 -04:00
Jack Robison 022e767bc4 Bump version 0.17.2rc6 --> 0.17.2rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-02 10:53:05 -04:00
Alex Grintsvayg cc61cc6b17 rename command to utxo_list 2017-11-02 07:14:35 -04:00
Jack Robison 12d88159a1 Bump version 0.17.2rc5 --> 0.17.2rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-01 20:33:08 -04:00
Jack Robison ccf3959e2f Bump version 0.17.2rc4 --> 0.17.2rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-01 19:44:52 -04:00
Jack Robison 2542883fde Bump version 0.17.2rc3 --> 0.17.2rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-01 17:39:37 -04:00
Alex Grin b7e1742bd4 Merge pull request #979 from lbryio/wallet_list_unspent
add wallet_list_unspent
2017-11-01 17:36:29 -04:00
Alex Grin fcfde63720 Merge branch 'master' into wallet_list_unspent 2017-11-01 17:35:31 -04:00
Alex Grintsvayg 3152ecfd71 add wallet_list_unspent 2017-11-01 17:29:11 -04:00
Jack Robison c86db2d846 Bump version 0.17.2rc2 --> 0.17.2rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-11-01 17:28:07 -04:00
Umpei Kay Kurokawa 62ec404acc Merge pull request #931 from lbryio/fix_blob_reader_closing
Fixes to Blob (unify way to read from BlobFile, move conf.py BLOB_SIZE  )
2017-10-31 15:44:23 -04:00
Kay Kurokawa 10ac86a99e use FileBodyProducer to read 2017-10-31 15:41:53 -04:00
Kay Kurokawa a5293de44b adding changelog 2017-10-31 15:41:49 -04:00
Kay Kurokawa 9470b318b0 moved BLOB_SIZE in conf to MAX_BLOB_SIZE constant in blob.blob_file 2017-10-31 15:38:00 -04:00
Kay Kurokawa 51d4668763 fix test 2017-10-31 15:38:00 -04:00
Kay Kurokawa 96d8cb17d9 delete deprecated producer/consumer read methods from BlobFile 2017-10-31 15:38:00 -04:00
Kay Kurokawa 1360345395 use blob.open_for_reading() in StreamBlobDecryptor 2017-10-31 15:38:00 -04:00
Kay Kurokawa e07c2f7bd8 take read handle as argument instead of file path 2017-10-31 15:38:00 -04:00
Kay Kurokawa d68ca65e41 warn if reader is garbage collected but not closed, do the same for writer 2017-10-31 15:38:00 -04:00
Umpei Kay Kurokawa 23108585f4 Merge pull request #963 from lbryio/redundant_exchange_apis
Added redundant market feed (continued)
2017-10-31 15:36:23 -04:00
Kay Kurokawa ea4b6935c9 remove unnecessary use of @property 2017-10-31 15:35:01 -04:00
Kay Kurokawa cf9f9d0e75 remove unused get_default_market_feed() function 2017-10-31 15:35:01 -04:00
Kay Kurokawa 020a2e0e89 adjust the _online variable to be set on the errback, so any exception will set _online to False 2017-10-31 15:35:01 -04:00
Kay Kurokawa 7e7931fbf1 add Bittrex feed as a redundant feed, add unit test for it 2017-10-31 15:35:01 -04:00
Kay Kurokawa 4411c5c202 add name of feed to log.info 2017-10-31 15:35:01 -04:00
Miroslav Kovar 433547407e Added tests. 2017-10-31 15:35:01 -04:00
Miroslav Kovar 34643b7f95 Added changelog entry. 2017-10-31 15:35:01 -04:00
Miroslav Kovar aa15f6c4b8 Added redundant market feed (cryptonator). 2017-10-31 15:35:01 -04:00
Alex Grintsvayg 4a9bf58bff wget required 2017-10-31 14:13:42 -04:00
Jack Robison ae32775cb8 Merge pull request #978 from Aldo-f/patch-1
Update README.md
2017-10-31 12:42:14 -04:00
Jack Robison ee3a2e88b7 Bump version 0.17.2rc1 --> 0.17.2rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-31 12:28:59 -04:00
Jack Robison b9e03a7f13 Merge branch 'mirgee-check_connection_bypass_dns' 2017-10-31 12:24:56 -04:00
Jack Robison cfd4a94450 logging 2017-10-31 12:21:36 -04:00
Jack Robison f7aa478b9b remove unused bypass_dns parameter 2017-10-31 12:21:35 -04:00
Jack Robison 3fd542f702 Merge branch 'check_connection_bypass_dns' of https://github.com/mirgee/lbry into mirgee-check_connection_bypass_dns 2017-10-31 12:21:35 -04:00
Alex Grintsvayg 4ea5c14a5a testing deploy changes 2017-10-31 12:12:41 -04:00
Aldo-f fe2c7efab1 Update README.md
Slack --> Discord
2017-10-31 15:36:21 +01:00
Alex Grintsvayg a26324d40b fix build version hash length 2017-10-31 09:47:50 -04:00
Alex Grintsvayg ceaa927ac5 Merge branch 'fix-971-dual-stack'
* fix-971-dual-stack:
  platform ip: ensure daemon retrieves IPv4 address only
2017-10-31 07:00:05 -04:00
Antonio Quartulli d827b4d5af platform ip: ensure daemon retrieves IPv4 address only
When contacting jsonip.com to retrieve the node external IP,
the connection might be established with IPv6 and thus return
an address belonging to that family.

This address is then used to initialize the external_ip member of
Daemon session, but unfortunately IPv6 is not yet handled well.

Using an IPv6 as external IP is currently breaking parts of the
Daemon resulting in no peer connectivity at all.

We should stick to IPv4 for time being.

http://jsonip.com/about says "ipv4-only":"https://ipv4.jsonip.com"

therefore, change the IP retrieval URL to ipv4.jsonip.com to
make sure the connection is established only using an IPv4 address.

Closes: https://github.com/lbryio/lbry/issues/971
Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2017-10-31 06:59:40 -04:00
Jack Robison db751eabb6 Bump version 0.17.1 --> 0.17.2rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-30 13:11:04 -04:00
Jack Robison c39568f488 Merge branch 'ordex-dht-fix-close-nodes-list-extension' 2017-10-30 13:10:04 -04:00
Jack Robison fdaaa0e678 changelog 2017-10-30 13:09:02 -04:00
Jack Robison e89f3db31b fix remaining length of close nodes list 2017-10-27 21:46:17 -04:00
Jack Robison ee90c877c7 Merge branch 'dht-fix-close-nodes-list-extension' of https://github.com/ordex/lbry into ordex-dht-fix-close-nodes-list-extension 2017-10-27 18:38:03 -04:00
Jack Robison 05489a5cee docs 2017-10-25 18:58:20 -04:00
Jack Robison 203f2f8988 Bump version 0.17.1rc5 --> 0.17.1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-25 17:33:55 -04:00
Antonio Quartulli 673d1c4d43 Extend close nodes list by right amount
When a k-bucket does not contain enough close nodes, the
DHT will look into neighbouring k-buckets in order to entend
the list of returned nodes.

However, the list should not be extended beyond its maximum size.

Signed-off-by: Antonio Quartulli <antonio@mandelbit.com>
2017-10-26 02:21:24 +08:00
Alex Grintsvayg c63d368e1c disable sourceclear again 2017-10-25 12:52:41 -04:00
Alex Grintsvayg 9eb40797ea extra word in changelog 2017-10-25 12:37:53 -04:00
Alex Grintsvayg beca640f89 Merge branch 'prefill_addresses'
* prefill_addresses:
  changes that jack pointed out
  add wallet_prefill_addresses command
2017-10-25 12:37:03 -04:00
Alex Grintsvayg 357f15c5b8 changes that jack pointed out 2017-10-25 12:36:54 -04:00
Alex Grintsvayg 2067180467 add wallet_prefill_addresses command 2017-10-25 12:29:51 -04:00
Alex Grintsvayg a212e77a12 dont build gh-pages 2017-10-25 12:26:04 -04:00
Jack Robison 6df5de209e Bump version 0.17.1rc4 --> 0.17.1rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-25 12:08:28 -04:00
Jack Robison 7ebfe77515 Merge branch 'android_tests_refactoring' 2017-10-25 12:06:06 -04:00
Jack Robison f3d45061e8 fix changelog merge conflict 2017-10-25 12:05:46 -04:00
Jack Robison e4d2a3d2ec Merge branch 'master' into android_tests_refactoring 2017-10-25 12:01:37 -04:00
Jack Robison 9decdf644d Bump version 0.17.1rc3 --> 0.17.1rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-25 10:59:43 -04:00
Jack Robison 0c66dfaaaf bump lbryschema 2017-10-25 10:56:12 -04:00
Jack Robison 2a467d8026 Merge branch 'update_jsonschema' 2017-10-25 10:51:01 -04:00
Jack Robison e799ad17b4 Merge branch 'master' into update_jsonschema 2017-10-25 10:50:06 -04:00
Jack Robison 3944c98b71 Bump version 0.17.1rc2 --> 0.17.1rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-24 20:48:58 -04:00
Jack Robison 988e54602e Merge branch 'fix-dht-rpc-id' 2017-10-24 20:48:11 -04:00
Jack Robison dc09996f43 changelog 2017-10-24 20:26:04 -04:00
Jack Robison 628c46e5d9 catch id validation errors 2017-10-24 20:26:03 -04:00
Jack Robison edb8928f5c update tests 2017-10-24 20:25:59 -04:00
Jack Robison e2259fd8f7 fix dht rpc id length 2017-10-24 20:25:54 -04:00
Jack Robison 78417db553 Bump version 0.17.1rc1 --> 0.17.1rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-24 19:29:05 -04:00
Jack Robison 5919271966 Merge branch 'fix-remove-contact' 2017-10-24 19:26:41 -04:00
Jack Robison 7a4ab73a72 Merge branch 'upnp-fixes' 2017-10-24 19:26:30 -04:00
Jack Robison 5bc856932d changelog 2017-10-24 19:18:13 -04:00
Jack Robison 9479179259 avoid future contact id parsing bugs by passing the contact id as an arg 2017-10-24 19:17:17 -04:00
Jack Robison 0b771c16ba fix lbry id for dead contact to replace in _IterativeFindHelper 2017-10-24 19:13:45 -04:00
Jack Robison 7e7ab8f72c changelog 2017-10-24 19:11:29 -04:00
Jack Robison 95a0653a58 better upnp redirect 2017-10-24 19:11:19 -04:00
Jack Robison bbc960aaf9 Bump version 0.17.0 --> 0.17.1rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-23 01:44:19 -04:00
Jack Robison 6be63b0bcd Merge branch 'dht-bug-fixes' 2017-10-23 01:38:32 -04:00
Jack Robison 8e94970b53 changelog 2017-10-23 01:34:40 -04:00
Jack Robison 45adfc533b fix id of new contact replacing a dead contact 2017-10-23 01:34:34 -04:00
Jack Robison c9a5512ed4 Merge branch 'startup-fixes' 2017-10-23 01:29:36 -04:00
Jack Robison d23d4c1d73 fix lbryid length comparison 2017-10-23 01:23:04 -04:00
Jack Robison 4b0082d5bc changelog 2017-10-23 01:20:02 -04:00
Jack Robison 529a11043b don't block file manager setup on all the streams being resumed 2017-10-23 01:17:54 -04:00
Jack Robison 4e4eb5e24c fix external ip 2017-10-23 01:17:25 -04:00
Jack Robison 93b91f8602 block session startup on joinNetwork 2017-10-23 01:16:29 -04:00
Akinwale Ariwodola e522e7e7f7 Changed AssertionError to ValueError. Skip tests that cannot pass on Android. 2017-10-17 03:15:50 +01:00
Kay Kurokawa 9c66d75c17 add changelog 2017-10-16 15:26:16 -04:00
Kay Kurokawa dec7af6bae update jsonschema version to 2.6.0 2017-10-16 15:23:39 -04:00
Jack Robison 1bcf7bd2f7 docs 2017-10-12 12:58:29 -04:00
Jack Robison 0793934d7b Bump version 0.17.0rc17 --> 0.17.0
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-12 12:39:09 -04:00
Jack Robison 3fdd04a0e3 Bump version 0.17.0rc16 --> 0.17.0rc17
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-12 12:30:28 -04:00
Jack Robison 79924f2c9e Merge branch 'fix_stream_tail_blob' 2017-10-12 12:29:50 -04:00
Kay Kurokawa 8b2b5b991b remove unneeded _error function from CryptStreamCreator 2017-10-12 12:17:04 -04:00
Kay Kurokawa 42990b582f add changelog 2017-10-12 11:26:44 -04:00
Kay Kurokawa 551eab9a42 fix bug where last blob in a stream was not saved to blob manager 2017-10-12 11:25:52 -04:00
Kay Kurokawa 574660cc20 add test to count the number of blobs created by EncryptedFileCreator 2017-10-12 11:16:20 -04:00
Josh Finer 69e11ace17 Merge pull request #948 from HugoHugo/patch-1
Update the year in the LICENSE
2017-10-11 21:12:35 -04:00
Hugo Valent 4c0e94e583 Update the year in the LICENSE
The current LICENSE contains copyright with the year 2016, so I propose to update the year to 2017.
2017-10-11 19:54:56 -05:00
Jack Robison fb071778dc fix docstring 2017-10-11 15:14:29 -04:00
Jack Robison 9585b444ab Bump version 0.17.0rc15 --> 0.17.0rc16
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-11 14:49:55 -04:00
Jack Robison 4b9c881cd0 fix recording reader was closed
reader_finished() is called when the reader closes, so the `readers -=
1` here was redundant and led to readers equalling -1 instead of 0.
2017-10-11 14:45:36 -04:00
Jack Robison 334a55bf7f Bump version 0.17.0rc14 --> 0.17.0rc15
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-11 14:06:33 -04:00
Jack Robison 78ad87d349 fix uncaught CancelledError in peer_list 2017-10-11 14:05:03 -04:00
Jack Robison 8c79421790 less verbose ClientProtocol log
fix https://github.com/lbryio/lbry/issues/917
2017-10-11 13:47:57 -04:00
Jack Robison 0a19dd938a Bump version 0.17.0rc13 --> 0.17.0rc14
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-11 13:07:49 -04:00
Jack Robison b95a89ec99 Merge branch 'dht-tests' 2017-10-11 13:06:43 -04:00
Jack Robison a0a7d5f569 add routing_table_get 2017-10-11 12:54:40 -04:00
Akinwale Ariwodola 0291482abb raised errors directly instead of wrapping with AssertionError 2017-10-11 07:59:30 +01:00
Jack Robison e7e987b07e changelog 2017-10-10 13:55:36 -04:00
Jack Robison 323c3e6cb3 add external_ip argument to Session, default to None 2017-10-10 13:55:36 -04:00
Jack Robison c7acb31614 add dht tests 2017-10-10 13:55:35 -04:00
Jack Robison e9fd8eb096 update tests and scripts 2017-10-10 13:55:31 -04:00
Jack Robison 9919fd06c6 uncomment error for store request where contact is not known 2017-10-10 13:29:54 -04:00
Jack Robison c9515f8fb6 logging and whitespace 2017-10-10 13:29:29 -04:00
Jack Robison 5937ead17c add Node.contacts helper property 2017-10-10 13:28:57 -04:00
Jack Robison 23ce278f8a add removePeer to interface 2017-10-10 13:27:44 -04:00
Jack Robison de1dc507ac fix findCloseNodes when buckets aren't fully populated 2017-10-10 13:21:06 -04:00
Jack Robison ab956d4a8e use count parameter in findCloseNodes 2017-10-10 13:20:19 -04:00
Jack Robison 7c50e26bd7 include method and args in _sentMessages 2017-10-10 13:19:03 -04:00
Jack Robison a942e6f3eb fix args for ping() 2017-10-10 13:18:38 -04:00
Jack Robison fe2d6bad1b fix logging error for dht rpc methods with no args (ping) 2017-10-10 13:18:00 -04:00
Jack Robison 3096c89e37 don't wrap exceptions with Failure 2017-10-10 13:17:36 -04:00
Jack Robison 2a47385b62 add rpcAttempts and replacementCacheSize constants 2017-10-10 13:16:26 -04:00
Jack Robison fcaca05a81 fix redundant lbryid 2017-10-10 13:15:25 -04:00
Jack Robison 46e31d5b45 getPeersForBlob inlinecallbacks refactor 2017-10-10 13:12:47 -04:00
Jack Robison 8e9f3c90a1 use looping call for Node.change_token to avoid hanging delayedCalls 2017-10-10 13:10:47 -04:00
Jack Robison f1980f524e fix raising remote exceptions 2017-10-10 13:09:25 -04:00
Jack Robison 4a567f7ab1 organize dht errors and interfaces 2017-10-10 13:08:22 -04:00
Akinwale Ariwodola 6ed56804b9 return empty string as default value when docstring is missing 2017-10-09 21:14:16 +01:00
Akinwale Ariwodola fb6545481b refactored one more assert 2017-10-09 20:41:08 +01:00
Akinwale Ariwodola 4f6f226b18 refactor asserts due to PYTHONOPTIMIZE flag 2017-10-09 20:20:58 +01:00
Jack Robison 777cda2cd3 Bump version 0.17.0rc12 --> 0.17.0rc13
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-09 10:40:23 -04:00
Jack Robison cdc65d36b0 Merge branch 'add_more_session_info' 2017-10-09 10:39:59 -04:00
Jack Robison 7898b9c2d8 Merge branch 'master' into add_more_session_info 2017-10-09 10:39:48 -04:00
Jack Robison e4cc87b8f0 Bump version 0.17.0rc11 --> 0.17.0rc12
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-09 10:30:36 -04:00
Jack Robison 7a351ffff0 Merge branch 'fix_freezing_2' 2017-10-09 10:29:51 -04:00
Kay Kurokawa b168c13c40 add changelog 2017-10-06 17:05:16 -04:00
Kay Kurokawa 043758c11f rename moved_verified_blob as saved_verified_blob 2017-10-06 17:05:16 -04:00
Kay Kurokawa d9cc81766d use DeferredLock instead of threading.Lock() as it can cause deadlocks 2017-10-06 17:05:10 -04:00
Kay Kurokawa 2115919c55 Add test when mutliple writers call _save_verified_blob at once, this will cause deadlock 2017-10-06 16:34:45 -04:00
Jack Robison d1511cba54 fix reading sd blob
TODO: add __enter__ and __exit__ methods to HashBlobReader to let it be
used as a contextmanager
2017-10-05 17:58:18 -04:00
Kay Kurokawa 3232daa178 add changelog 2017-10-05 14:00:04 -04:00
Kay Kurokawa db0bc92087 add unit tests for should annouce functions in BlobManager 2017-10-05 13:59:50 -04:00
Kay Kurokawa 1f839fe2a6 add blob announcement information to session_status 2017-10-05 13:59:27 -04:00
Kay Kurokawa be78390793 fix changelog having two Added sections
Signed-off-by: Kay Kurokawa <kay@lbry.io>
2017-10-05 13:50:59 -04:00
Umpei Kay Kurokawa a13b8eee40 Merge pull request #932 from lbryio/fix_reflector_client
Reflector client bug
2017-10-03 15:18:16 -04:00
Kay Kurokawa 4c63364b18 added changelog 2017-10-03 14:15:46 -04:00
Kay Kurokawa 0a919c3eab fix inconsistency in how blob_hashes_to_send is used, preventing proper reflecting 2017-10-03 11:22:07 -04:00
Alex Grin 010a1019fe Merge pull request #933 from lbryio/fix_concurrent_reflects
Fix to not reflect all the files at once
2017-10-02 20:02:08 -04:00
Kay Kurokawa 7557e3cc73 add changelog 2017-10-02 16:33:09 -04:00
Kay Kurokawa 6268e43509 make sure to close blob files when connection is lost on reflector client 2017-10-02 16:30:58 -04:00
Kay Kurokawa d33ebd60c4 fix to not reflect all the files at once 2017-10-02 16:30:58 -04:00
Jack Robison 64a4c47536 Bump version 0.17.0rc10 --> 0.17.0rc11
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-02 10:12:19 -07:00
Jack Robison 33a95abeac Merge branch 'tests_to_lbrynet' 2017-10-02 10:06:12 -07:00
Akinwale Ariwodola 63dd57aaea fixed long string concatenation and merged with master 2017-10-02 17:13:45 +01:00
Jack Robison b22c9c0f25 Bump version 0.17.0rc9 --> 0.17.0rc10
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-02 11:30:05 -04:00
Jack Robison a0817840c5 Bump version 0.17.0rc8 --> 0.17.0rc9
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-10-02 11:22:44 -04:00
Jack Robison aa3982f0e2 temporarily disable blob analytics 2017-10-02 11:21:51 -04:00
Jack Robison 6a7982022a Bump version 0.17.0rc7 --> 0.17.0rc8
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-29 12:37:57 -04:00
Jack Robison 838436d641 Merge remote-tracking branch 'origin/fix_blob_reader_closing' 2017-09-29 12:37:15 -04:00
Jack Robison 4c1c3592b7 changelog 2017-09-29 12:31:34 -04:00
Akinwale Ariwodola 191931d009 updated appveyor build configuration 2017-09-29 12:02:36 +01:00
Akinwale Ariwodola 91498822ae fixed all pylint errors 2017-09-29 11:44:22 +01:00
Jack Robison 5ac60cf2c2 Bump version 0.17.0rc6 --> 0.17.0rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-28 17:46:47 -04:00
Jack Robison b85a813aaf fix sd timeout 2017-09-28 17:36:55 -04:00
Jack Robison 89ef5620a4 Bump version 0.17.0rc5 --> 0.17.0rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-28 16:08:15 -04:00
Jack Robison 283dede833 Merge branch 'download-errors' 2017-09-28 16:07:16 -04:00
Jack Robison 2ebb9da108 move download_failed 2017-09-28 15:46:02 -04:00
Jack Robison c6db4b187a fix error name 2017-09-28 15:45:24 -04:00
Jack Robison b7bfb259e5 fix download exceptions 2017-09-28 15:28:39 -04:00
Jack Robison 9fd60c823f add _download_failed errback 2017-09-28 15:28:37 -04:00
Jack Robison 82a2805aaf json blobs 2017-09-28 15:28:06 -04:00
Jack Robison 50b51569a3 cancel streams on shutdown 2017-09-28 14:48:05 -04:00
Kay Kurokawa 89ebed570e fix test_timeout in test_Downloader 2017-09-28 14:48:05 -04:00
Jack Robison d2b91d5f51 changelog 2017-09-28 14:48:01 -04:00
Jack Robison 81b584a35a update tests and scripts 2017-09-28 14:04:03 -04:00
Jack Robison fa83a4f671 fix stop condition 2017-09-28 14:04:03 -04:00
Jack Robison c9ae251d60 download analytics 2017-09-28 14:04:03 -04:00
Jack Robison af99edc764 add get_host_downloaded_from 2017-09-28 14:04:03 -04:00
Jack Robison 9de4657a4d fix blob history and callback from _download_succeeded
previously _download_succeeded did not block on blob_completed,
presumably because even longer ago it did not block on a deriving
immediate_announce call and thus took a long time to return
2017-09-28 14:04:02 -04:00
Jack Robison 250855d45d stop failed downloader outside of GetStream 2017-09-28 14:04:02 -04:00
Jack Robison b0a3771ccf better download errors 2017-09-28 14:04:02 -04:00
Akinwale Ariwodola 2abe85ba25 moved tests into the lbrynet package 2017-09-28 18:21:26 +01:00
Alex Grintsvayg 42a141e7b7 contributing 2017-09-28 08:14:36 -04:00
Kay Kurokawa 8c41b9ecde added changelog 2017-09-27 17:41:52 -04:00
Kay Kurokawa cf3a0e2e9d add some more tests for deleting blob files 2017-09-27 17:40:57 -04:00
Kay Kurokawa 533835a732 add comments and docstrings 2017-09-27 17:40:52 -04:00
Kay Kurokawa a4ea49cf65 read handle was not being closed after file transfer 2017-09-27 17:30:20 -04:00
Kay Kurokawa aab43c8d6c close the reader directly instead of calling close_read_handle() 2017-09-27 17:30:20 -04:00
Kay Kurokawa f6da00cbab no need to catch IOError exception here, let it propagage 2017-09-27 17:30:20 -04:00
Kay Kurokawa 3b5690614c Return HashBlobReader instead of file handle in open_for_reading() 2017-09-27 17:30:20 -04:00
Kay Kurokawa 09e25ba285 add reader, for BlobFile, change original reader to v0 2017-09-27 17:30:20 -04:00
Jack Robison df9cec66be Bump version 0.17.0rc4 --> 0.17.0rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-26 16:53:27 -04:00
Jack Robison 53456c61b8 Bump version 0.17.0rc3 --> 0.17.0rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-25 19:11:10 -04:00
Jack Robison 8847e07f87 Bump version 0.17.0rc2 --> 0.17.0rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-25 13:30:10 -04:00
Jack Robison 414c877502 changelog 2017-09-25 13:29:36 -04:00
Jack Robison c7e4a1a1be Merge branch 'change_to_reflector_2' 2017-09-25 13:28:30 -04:00
Kay Kurokawa 0fc116fbdb Change to reflector2 in conf 2017-09-25 13:18:07 -04:00
Jack Robison d2de0911b3 Bump version 0.17.0rc1 --> 0.17.0rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-22 14:57:32 -04:00
Jack Robison 43e4b3f7d4 Merge branch 'reflector_announce_rework' 2017-09-22 14:55:48 -04:00
Kay Kurokawa f835ef1be4 add changelog 2017-09-22 14:46:29 -04:00
Kay Kurokawa cc98cdf933 announce_head_blobs_only is True by default 2017-09-22 14:46:28 -04:00
Kay Kurokawa 4941d1d31d test when you have a v1 blob reflect before a stream reflect over the same blobs 2017-09-22 14:46:28 -04:00
Jack Robison 4b8700268f discover stream info for uploads via reflector v1 2017-09-22 14:46:23 -04:00
Kay Kurokawa 474ce21a51 add more tests in test_reflector, make sure stream info is not affected for blob client v1 2017-09-22 14:39:39 -04:00
Kay Kurokawa 9bf159433d add changelog 2017-09-22 14:39:39 -04:00
Kay Kurokawa 4d5ba94a6e add tests for checking stream info on reflector server 2017-09-22 14:39:37 -04:00
Kay Kurokawa 32feb628c3 add stream_info_manager to reflector server initialization 2017-09-22 14:39:29 -04:00
Kay Kurokawa 1a8e11ead3 work on reflector head blob announce only 2017-09-22 14:39:28 -04:00
Jack Robison 5503b0f290 Bump version 0.16.1 --> 0.17.0rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-22 14:38:57 -04:00
Jack Robison 24d1632faa Merge branch 'blob-improvements' 2017-09-22 14:27:38 -04:00
Miroslav Kovar 0fca867ec0 Modified check_connection() to try bypassing DNS before giving up. 2017-09-20 23:36:08 +02:00
Jack Robison 6cbe86d057 rename is_validated() to get_is_verified() to distinguish from verified property 2017-09-20 14:02:34 -04:00
Jack Robison dbb658adec update changelog 2017-09-20 13:59:29 -04:00
Jack Robison ffbcd82263 fix redundant blob request to peer 2017-09-20 13:59:29 -04:00
Kay Kurokawa ab3c987034 fix lints 2017-09-20 13:59:28 -04:00
Jack Robison b6e9aa420c fix cancelled blob request? 2017-09-20 13:59:28 -04:00
Kay Kurokawa e50ade85be catch IOError properly 2017-09-20 13:59:28 -04:00
Kay Kurokawa ea49cddf52 catch IOError when writing 2017-09-20 13:59:28 -04:00
Jack Robison 85f25a8d99 remove debug logging 2017-09-20 13:59:27 -04:00
Jack Robison 19ff0941f5 fix ClientProtocol. _handle_response_error 2017-09-20 13:59:27 -04:00
Jack Robison adf89a9d1a logging 2017-09-20 13:59:27 -04:00
Jack Robison 8419e1e1d5 change some ValueErrors to IOErrors 2017-09-20 13:59:26 -04:00
Jack Robison 421141b958 raise instead of assert 2017-09-20 13:59:26 -04:00
Jack Robison 96357ab833 exchange rate error 2017-09-20 13:59:26 -04:00
Jack Robison b9b5e755db raise rather than assert 2017-09-20 13:59:26 -04:00
Jack Robison ad061b5ea3 use fixed BlobFile type 2017-09-20 13:59:25 -04:00
Kay Kurokawa 8d2cc4a4c0 lint, remove ununsed imports 2017-09-20 13:59:25 -04:00
Kay Kurokawa 3efefe8efd use cryptography version 2.0.3 2017-09-20 13:59:25 -04:00
Kay Kurokawa af3ab96815 deleting unused BlobFile.finished_deferred 2017-09-20 13:59:25 -04:00
Kay Kurokawa e046af57fa fix empty tail blobs in stream from being saved 2017-09-20 13:59:24 -04:00
Jack Robison 6f71a5003c remove unused EncryptedFileOpener 2017-09-20 13:59:24 -04:00
Jack Robison 14636a5d38 split up HashBlob.py into lbrynet.blob 2017-09-20 13:59:24 -04:00
Jack Robison 7d6e62eb77 consolidate HashBlob and BlobFile 2017-09-20 13:59:24 -04:00
Kay Kurokawa f816cc1637 add some unit tests for BlobFile.close() 2017-09-20 13:59:23 -04:00
Kay Kurokawa e92321a9c1 have BlobFile.open_for_writing() return the writer instead of write and close functions 2017-09-20 13:59:23 -04:00
Kay Kurokawa 39c4db3471 make sure that we don't call HashBlobWriter.finished_cb multiple times when calling close() 2017-09-20 13:59:23 -04:00
Kay Kurokawa 468a16af58 move check for write_handle to the beginning and raise exception when writing to a closed file handle 2017-09-20 13:59:23 -04:00
Kay Kurokawa 196aa24b8b add HashBlobWriter.close_handle() function to just close the write handle 2017-09-20 13:59:22 -04:00
Kay Kurokawa 94ff4e82bc remove HashBob._close_writer(), move the closing of write handler to HashBlobWriter 2017-09-20 13:59:22 -04:00
Kay Kurokawa 0f95712a0f rename HashBlobWriter.cancel() as close() to be more file like 2017-09-20 13:59:22 -04:00
Kay Kurokawa ab513d076b fix multiple writers writing to the same buffer 2017-09-20 13:59:22 -04:00
Kay Kurokawa f2deee7201 fireback finished_deferred after deleting from self.writers so that BlobFile state is accurate after finished_deferred is called 2017-09-20 13:59:21 -04:00
Kay Kurokawa b655cd4fa6 add better comments for classes in HashBlob.py 2017-09-20 13:59:21 -04:00
Kay Kurokawa 637d1f265b add unit tests for HashBlob.py classes 2017-09-20 13:59:21 -04:00
Jack Robison 487f2490ab simplify CryptStreamCreator 2017-09-20 13:59:20 -04:00
Jack Robison 90bce0b375 fix setting _final_blob_num in EncryptedFileMetadataHandler 2017-09-20 13:59:20 -04:00
Jack Robison b98cd24e10 don't reflect empty last blob 2017-09-20 13:59:20 -04:00
Jack Robison 070978248e return new lbry file status from _change_file_status 2017-09-20 13:59:20 -04:00
Jack Robison 100c18d9b6 send CryptBlobInfo (not a CryptStreamBlobMaker) to DiskBlobManager.creator_finished 2017-09-20 13:59:19 -04:00
Jack Robison e3cc3992b0 remove unnecessary functions 2017-09-20 13:59:19 -04:00
Jack Robison cfe73a8627 fix hanging streamprogressmanager 2017-09-20 13:59:19 -04:00
Jack Robison 632fd764fa show more information for a blob padding error 2017-09-20 13:59:19 -04:00
Jack Robison a72fef07c0 inlinecallbacks 2017-09-20 13:59:18 -04:00
Jack Robison 1148a533bf raise NotImplementedError on StreamCreator._blob_finished (sanity check) 2017-09-20 13:59:18 -04:00
Jack Robison c53a189605 remove TempBlob, clean up blob classes, use FBP and BytesIO in BlobFile 2017-09-20 13:59:18 -04:00
Victor Shyba 6022aa925b fix import 2017-09-20 13:59:18 -04:00
Victor Shyba d03aded31d add cryptography as a direct requirement 2017-09-20 13:59:17 -04:00
Victor Shyba e69ba64707 pycrypt -> cryptography + remove manual padding, use lib 2017-09-20 13:59:17 -04:00
Victor Shyba d2fc1daf26 use hashlib 2017-09-20 13:59:17 -04:00
Victor Shyba a6b8327fcf save using a FBP instead of thread 2017-09-20 13:59:17 -04:00
Victor Shyba a3e5c61b50 use FileBodyProducer for encrypt_blob script 2017-09-20 13:59:16 -04:00
Victor Shyba 7262e84150 use a buffer to wait for blob completion 2017-09-20 13:59:16 -04:00
Victor Shyba 5d69e74010 use WAL on sqlite3 2017-09-20 13:59:16 -04:00
Victor Shyba 5bbb29fd79 add error handling to blobs creation 2017-09-20 13:59:16 -04:00
Victor Shyba 84bd4fdc3e fix encryption script 2017-09-20 13:59:15 -04:00
Alex Grintsvayg 875d512680 update api docs 2017-09-20 11:19:23 -04:00
Alex Grintsvayg c98197f266 deprecated blob_announce_all 2017-09-20 11:16:10 -04:00
Jack Robison 1b2bd871f4 Bump version 0.16.1rc1 --> 0.16.1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-20 10:24:44 -04:00
Jack Robison 747b098d8b Bump version 0.16.0 --> 0.16.1rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-20 09:55:57 -04:00
Jack Robison a04fe638b8 Merge branch 'update-tip-history' 2017-09-20 09:54:51 -04:00
Jack Robison 88fcd5b711 update _get_history for change in lbryum 2017-09-20 09:51:52 -04:00
Jack Robison 9bb03757ec docopt fix 2017-09-20 09:50:48 -04:00
Alex Grintsvayg ab384f1c91 readme edit 2017-09-18 13:03:34 -04:00
Jack Robison 1f5b2203d7 Bump version 0.16.0rc9 --> 0.16.0
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-18 10:14:41 -04:00
Jack Robison 1a503dd94b Bump version 0.16.0rc8 --> 0.16.0rc9
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-15 19:45:39 -04:00
Umpei Kay Kurokawa 216d5cd4d0 Merge pull request #899 from lbryio/small_test_fix
fix bug found in test_EncryptedFileCreator.py,
2017-09-13 14:23:48 -04:00
Kay Kurokawa e52d707948 fix bug found in test_EncryptedFileCreator.py, need to yield for blob_manager.setup() 2017-09-13 14:16:07 -04:00
Alex Grintsvayg 8681686395 why would written_bytes ever be False? 2017-09-12 16:00:32 -04:00
Alex Grintsvayg 810089cd99 not sure why this is here 2017-09-12 13:47:08 -04:00
Mike Putnam e7094a92ab Docs spelling correction. (#873)
Docs spelling correction
2017-09-12 09:41:11 -04:00
Jack Robison 0f4dc67fb9 Bump version 0.16.0rc7 --> 0.16.0rc8
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-11 12:09:40 -04:00
Umpei Kay Kurokawa cb45d7cf8a Merge pull request #896 from lbryio/client_head_blob_announce_on
Turn on head blob seek for clients
2017-09-11 12:04:51 -04:00
Kay Kurokawa 70868767f7 add changelog 2017-09-11 11:43:46 -04:00
Kay Kurokawa 66152a8f93 turn on head blob announce seek for clients 2017-09-11 11:34:26 -04:00
Jack Robison 300426b912 Bump version 0.16.0rc6 --> 0.16.0rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-07 14:13:04 -04:00
Jack Robison 1f4dfe1f93 Merge branch 'patch-googlefinance2' 2017-09-07 14:10:37 -04:00
Jack Robison 4800f46a1a update changelog 2017-09-07 14:04:47 -04:00
Jack Robison 3f42716706 update tests 2017-09-07 14:01:06 -04:00
Jack Robison 5f9509db96 don't use google finance 2017-09-07 13:55:36 -04:00
Jack Robison 2d39f3b2ab Bump version 0.16.0rc5 --> 0.16.0rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-06 11:01:49 -04:00
Jack Robison dd036d15c8 update decode_address import from lbryschema
https://github.com/lbryio/lbryschema/pull/16
2017-09-06 10:58:52 -04:00
Jack Robison 1487ed713e Bump version 0.16.0rc4 --> 0.16.0rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-05 15:43:16 -04:00
Jack Robison 7e107ba87e Bump version 0.16.0rc3 --> 0.16.0rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-05 15:01:47 -04:00
Jack Robison c0365498ba Bump version 0.16.0rc2 --> 0.16.0rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-04 09:02:59 -04:00
Jack Robison f9147ea87c Merge branch 'ofek-patch-1' 2017-09-04 08:54:29 -04:00
Jack Robison de24d9f82c Merge branch 'patch-1' of https://github.com/ofek/lbry into ofek-patch-1 2017-09-04 08:52:08 -04:00
Jack Robison 1dda382e75 Bump version 0.16.0rc1 --> 0.16.0rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-01 10:44:20 -04:00
Jack Robison 5ece58b716 pylint 2017-09-01 10:43:46 -04:00
Jack Robison 15879e87f5 Bump version 0.15.2rc3 --> 0.16.0rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-09-01 10:38:11 -04:00
Jack Robison a12c0be0b9 Fix uncaught error when shutting down after a failed daemon startup 2017-09-01 10:32:47 -04:00
Jack Robison f1f543ee77 Bump version 0.15.2rc2 --> 0.15.2rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-31 17:09:34 -04:00
Jack Robison 6baf1fe40d Merge branch 'expose_include_tip_info' 2017-08-31 16:58:04 -04:00
hackrush fbd37c591f Expose include_tip_info param
Goes with lbryio/lbryum#153

Updated changelog and added docs for include_tip_info

Added proper doc for Returns of transaction_list

Fixed some other docs
2017-09-01 02:15:24 +05:30
Jack Robison 2254e3507a Bump version 0.15.2rc1 --> 0.15.2rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-31 13:51:07 -04:00
Jack Robison 036cfce5c5 fix typo in changelog 2017-08-31 13:49:19 -04:00
Alex Grin cd97c4a9f1 Merge pull request #875 from lbryio/wallermadev-patch-1
Updating documentation for clarity
2017-08-29 09:28:27 -04:00
Ofek Lev 780044ebd6 unify behavior 2017-08-28 14:32:55 -04:00
Alex Grintsvayg f4f861a163 Bump version 0.15.1 --> 0.15.2rc1 2017-08-28 11:03:42 -04:00
Umpei Kay Kurokawa 009080ba69 Merge pull request #819 from lbryio/client_seek_head_blob_only
Add option for clients to seek head blob first when downloading
2017-08-28 07:48:07 -07:00
Kay Kurokawa ed62566981 add changelog 2017-08-28 10:46:47 -04:00
Kay Kurokawa a9e6c89693 clean up and clarify in docstring when/where None is returned while searching for peers 2017-08-28 10:46:47 -04:00
Kay Kurokawa e0985695ac some pep8 fixes 2017-08-28 10:46:47 -04:00
Kay Kurokawa e2e28338f3 in ConnectionManager, be consistent and initialize conf values in __init__ 2017-08-28 10:46:47 -04:00
Kay Kurokawa a31b6b192f Create an optional way of downloading by head blob first in ConnectionManager 2017-08-28 10:46:47 -04:00
Umpei Kay Kurokawa 33843b3a19 Merge pull request #824 from lbryio/seeders_announce_rework
Add option for seeders to announce head blob only
2017-08-28 07:45:59 -07:00
Kay Kurokawa 5fb4c1ddcb add changelog 2017-08-28 10:43:57 -04:00
Kay Kurokawa c8bf1d8908 should_announce should be True by default 2017-08-28 10:43:57 -04:00
Kay Kurokawa 0494b11001 remove last_announce_time 2017-08-28 10:43:57 -04:00
Kay Kurokawa 0639bb9865 add support for should_announce feature 2017-08-28 10:43:57 -04:00
Kay Kurokawa 7e95169fbe add get_head_blob_hash() function in DownloadManager 2017-08-28 10:43:57 -04:00
Kay Kurokawa c0a2c6c830 remove blob manager reliance on HashBlob classes 2017-08-28 10:43:57 -04:00
Kay Kurokawa 8955838191 migrate blob database to have should_announce and last_announce_time 2017-08-28 10:43:57 -04:00
Mat Waller 16da099a1c Updating documentation for clarity
Updating `claim_new_support` documentation to add a bit more clarity to the name field.
2017-08-28 13:20:57 +01:00
Ofek Lev 95e503cf1f fix setup.py
`.decode('utf-8')` is unnecessary and breaks on Python 3
2017-08-23 20:53:57 -04:00
Jack Robison d840b107c8 fix changelog links 2017-08-22 18:34:31 -04:00
Jack Robison 8cf2bc2b19 Bump version 0.15.0 --> 0.15.1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-22 18:31:09 -04:00
Jack Robison eede1937a8 Merge branch 'android_platform_paths' 2017-08-22 15:39:21 -04:00
Jack Robison 5fc55fc482 Merge branch 'master' into android_platform_paths 2017-08-22 15:39:02 -04:00
Jack Robison e4990992fb update bumpversion 2017-08-22 12:56:23 -04:00
Alex Grin 128e893b0c Merge pull request #856 from lbryio/persist-node-id
persist dht node id
2017-08-18 16:04:33 -04:00
Akinwale Ariwodola 6252184699 fix pylint error 2017-08-18 15:09:08 +01:00
Akinwale Ariwodola 1d85f7127a updated changelog 2017-08-18 12:29:38 +01:00
Akinwale Ariwodola 70881dab6e added Android platform detection and androidhelpers module which will be used to determine base paths 2017-08-18 11:52:03 +01:00
Jack Robison e204a3b9a5 fix doc-string for resolve 2017-08-17 14:32:28 -04:00
Jack Robison d1b7de1807 persist dht node id 2017-08-16 21:18:10 -04:00
Jack Robison 8786133cd4 Revert "fix BlobFile._close_file"
reverts 5d24f7
2017-08-15 17:48:56 -04:00
Jack Robison a1fb5ca352 update cli docs 2017-08-15 15:44:14 -04:00
Alex Grintsvayg cfa57c15d5 fixed changelog 2017-08-15 13:16:42 -04:00
Alex Grintsvayg 693eb379fd Merge branch 'fix-close-writer'
* fix-close-writer:
  fix BlobFile._close_file
2017-08-15 12:34:09 -04:00
Jack Robison 5d24f75ce2 fix BlobFile._close_file 2017-08-15 12:34:00 -04:00
Jack Robison 518146396c Bump version 0.15.0rc8 --> 0.15.0
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-15 12:07:17 -04:00
Jack Robison f4ed2ec503 Bump version 0.15.0rc7 --> 0.15.0rc8
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-15 11:56:53 -04:00
Jack Robison b4354497c3 validate wallet_send parameters 2017-08-15 11:56:26 -04:00
Jack Robison da0b5352ee Bump version 0.15.0rc6 --> 0.15.0rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-15 11:49:46 -04:00
Jack Robison 7e685f764f fix handling deprecated commands in lbrynet-cli 2017-08-15 11:48:56 -04:00
Jack Robison 21ab4fb9c0 Bump version 0.15.0rc5 --> 0.15.0rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-15 11:37:02 -04:00
Jack Robison 4b716bbcdd fix send_amount_to_address backwards compatibility 2017-08-15 11:36:03 -04:00
Jack Robison 46c5a98752 return results for new command for commands marked with the deprecated decorator 2017-08-15 11:31:35 -04:00
Jack Robison 667f417060 Bump version 0.15.0rc4 --> 0.15.0rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-15 11:22:32 -04:00
Jack Robison c07230a5f1 Merge branch 'wallet_send' 2017-08-15 11:20:28 -04:00
Jack Robison 18f5f850cd show deprecated warning 2017-08-15 11:17:50 -04:00
Jack Robison ac4d905a7e add wallet_send 2017-08-15 11:11:38 -04:00
Umpei Kay Kurokawa 690ef15ba1 Merge pull request #756 from lbryio/fix_integer_resolve
Fix error when resolving an integer
2017-08-14 22:52:20 -04:00
Umpei Kay Kurokawa 34ed2467f2 Merge pull request #829 from lbryio/fix_abandon
Expose abandon by txid/nout in Daemon
2017-08-14 22:51:39 -04:00
Kay Kurokawa b2f0dedefb fix error when resolving true/false/floats and also prevent other keys from being parsed as boolean, int, or float in CLI 2017-08-14 18:33:41 +02:00
Zestyr 0c2d049c90 Fix error when resolving an integer
Fixes #588
2017-08-14 12:15:08 -04:00
Jack Robison 2d1624f088 Bump version 0.15.0rc3 --> 0.15.0rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-10 15:06:08 -04:00
Jack Robison c622cf13f0 Merge branch 'fast-blob-completed' 2017-08-10 15:03:18 -04:00
Jack Robison f3c4bfec6a update changelog 2017-08-10 13:53:10 -04:00
Jack Robison 09d336bd0c don't block blob_completed on the blob being announced
this considerably slows down the rate at which reflector server can
receive blobs
2017-08-10 13:53:10 -04:00
Alex Grintsvayg 350386ba21 Merge branch 'daemon_fixes'
* daemon_fixes:
  fix tests
  no datas
  fix daemon shutdown
  dont ignore SIGTERM/SIGINT when already shutting down
  removed old /view and /upload endpoints, moved api to root path
  fixed shutdown messages
  build from setuptools entry_point
2017-08-09 19:10:27 -04:00
Alex Grintsvayg 2927f40ccf fix tests 2017-08-09 19:10:12 -04:00
Alex Grintsvayg a5f753dfa2 no datas 2017-08-09 19:10:11 -04:00
Alex Grintsvayg ea9d368d09 fix daemon shutdown 2017-08-09 19:10:11 -04:00
Alex Grintsvayg ddcf3a47f8 dont ignore SIGTERM/SIGINT when already shutting down 2017-08-09 19:10:11 -04:00
Alex Grintsvayg cc5b626a54 removed old /view and /upload endpoints, moved api to root path 2017-08-09 19:10:11 -04:00
Alex Grintsvayg 02d4444780 fixed shutdown messages 2017-08-09 19:10:11 -04:00
Alex Grintsvayg f916a4a82d build from setuptools entry_point 2017-08-09 19:10:11 -04:00
Kay Kurokawa b10d7c0923 add changelog 2017-08-08 13:55:57 -04:00
Kay Kurokawa 7a2f607998 no need to catch exception when abandoning in Daemon 2017-08-08 13:55:03 -04:00
Kay Kurokawa 4e8d8dfc23 Expose abandon by txid/nout in Daemon 2017-08-08 13:55:03 -04:00
Jack Robison c7ba901819 Bump version 0.15.0rc2 --> 0.15.0rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-04 16:11:37 -04:00
Jack Robison b725906c95 Merge branch 'improve-reflector-commands' 2017-08-04 16:09:43 -04:00
Jack Robison af7eec8ba5 update changelog 2017-08-04 16:08:51 -04:00
Jack Robison c971cce717 file_reflect 2017-08-04 16:08:03 -04:00
Jack Robison d5f2481af5 handle ip addresses given as reflector servers 2017-08-04 16:08:02 -04:00
Jack Robison 0bdcab1166 Merge branch 'conf_reflect_options' 2017-08-04 15:17:05 -04:00
Jack Robison 89e7d7a44d Merge branch 'master' into conf_reflect_options 2017-08-04 15:16:51 -04:00
Jack Robison d1332debf8 Bump version 0.15.0rc1 --> 0.15.0rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-04 10:59:34 -04:00
Jack Robison 0458295113 Bump version 0.14.3 --> 0.15.0rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-04 10:54:16 -04:00
Jack Robison ed819f67bc Merge branch 'add-claim-tip' 2017-08-04 10:49:18 -04:00
Jack Robison c5fe8b5381 add claim_send_tip 2017-08-04 10:48:13 -04:00
Jack Robison dd8db5a6b0 Bump version 0.14.3rc7 --> 0.14.3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-04 10:12:55 -04:00
Kay Kurokawa 303b9bd9f0 add changelog 2017-08-03 23:44:24 -04:00
Kay Kurokawa 9d92fba02e add ability to control re-reflects through config 2017-08-03 23:44:20 -04:00
Jack Robison 9121059613 Bump version 0.14.3rc6 --> 0.14.3rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-03 22:28:53 -04:00
Jack Robison 8d8946b96e Merge branch 'remove_tempblobmanager' 2017-08-03 22:27:21 -04:00
Jack Robison 7b93073f7b Merge branch 'master' into remove_tempblobmanager 2017-08-03 22:26:35 -04:00
Jack Robison 2aee5f7948 Bump version 0.14.3rc5 --> 0.14.3rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-02 17:09:40 -04:00
Jack Robison 5312b2b988 Bump version 0.14.3rc4 --> 0.14.3rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-08-02 10:41:06 -04:00
Jack Robison e1287c9b66 Bump version 0.14.3rc3 --> 0.14.3rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-31 11:16:33 -04:00
Umpei Kay Kurokawa 5ce360511b Merge pull request #793 from lbryio/blob_announce
Better blob announce API command
2017-07-31 11:09:03 -04:00
Kay Kurokawa 999d223241 add changelog 2017-07-31 10:52:28 -04:00
Kay Kurokawa 4e05eac854 add blob_announce API command, to eventually replace blob_announce_all 2017-07-31 10:52:23 -04:00
Jack Robison c108ef0f83 Bump version 0.14.3rc2 --> 0.14.3rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-31 10:49:20 -04:00
Jack Robison 15e44b0c9d Merge branch 'fix_resolve_formatting' 2017-07-31 10:46:02 -04:00
Zestyr 2f2b27e872 Remove old float formatting 2017-07-31 10:38:20 -04:00
Kay Kurokawa 99b7ac2856 add changelog 2017-07-27 13:38:40 -04:00
Kay Kurokawa 79d25f710d remove base BlobManager class 2017-07-27 13:38:40 -04:00
Kay Kurokawa 30689b09e6 fix tests to not use TempBlobManager and use tempfile to create temporary directories for DiskBlobManager 2017-07-27 13:38:35 -04:00
Kay Kurokawa d5664efdbf no longer allow initialization of TempBlobManager in Session 2017-07-27 11:38:29 -04:00
Kay Kurokawa f9b728530e Remove TempBlobManager 2017-07-27 11:38:23 -04:00
Jack Robison cc7a3d3dcc Bump version 0.14.3rc1 --> 0.14.3rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-27 09:54:38 -04:00
Jack Robison 9d7067f3b7 Merge branch 'hackrush_max_key' 2017-07-27 09:53:57 -04:00
Jack Robison 93135f847b Merge branch 'master' into hackrush_max_key 2017-07-27 09:53:47 -04:00
Jack Robison c3a16ad837 Bump version 0.14.2 --> 0.14.3rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-27 09:53:11 -04:00
Jack Robison d428bbeb5e Merge branch 'hackrush01-no_of_claims' 2017-07-27 09:51:17 -04:00
hackrush ecd602e5fb Added validation for currencies.
Now while setting currency via API/CLI it is checked that the user has
not entered any currency other that LBC, BTC or USD.

Fixes #778
2017-07-24 16:38:15 -04:00
hackrush b9257004dd Resolving a channel returns 'channel_claim_count'
Since I couldn't get my lbryum server up for testing this, it is a dry
fix based on the review.

Goes with lbryio/lbryum#138
2017-07-25 01:26:17 +05:30
Jack Robison bf6bc02828 Bump version 0.14.2rc7 --> 0.14.2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-24 14:03:25 -04:00
Kay Kurokawa 15d672bfe0 fix if statment for resolving certificate 2017-07-20 14:05:00 -04:00
Umpei Kay Kurokawa 32a9e1c4bd Merge pull request #791 from lbryio/fix_cache_fail
Fix if statement causing claim with certificate to not get cached, and cause downloading to fail
2017-07-20 13:37:29 -04:00
Kay Kurokawa fa1ebc995c fix if statement causing claim with certificate to not get cached 2017-07-20 12:38:06 -04:00
Jack Robison 941c0d8d8f Bump version 0.14.2rc6 --> 0.14.2rc7
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-19 19:41:52 -04:00
Jack Robison c96ce5b8ad Merge pull request #790 from lbryio/fix-new-directories
Fix new default directories
2017-07-19 19:00:52 -04:00
Jack Robison 5e2e96b1ff fix directories 2017-07-19 18:52:48 -04:00
Jack Robison ac2602e8b3 Merge branch 'fix-allowed-during-startup' 2017-07-19 12:09:52 -04:00
Jack Robison 4e5ff49177 fix allowed_during_startup 2017-07-19 11:43:45 -04:00
Jack Robison d3bf097687 Bump version 0.14.2rc5 --> 0.14.2rc6
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-18 15:56:09 -04:00
Alex Grin 5a230fdab4 Merge pull request #780 from vv181/remove-stream-info-cache
remove stream info cache
2017-07-18 08:32:17 -04:00
Alex Grintsvayg 83c413e10c Merge branch 'fix_default_directories'
* fix_default_directories:
  Fix unit test
  Update default directories
  Clean up legacy code
2017-07-18 08:31:16 -04:00
Zestyr 3c40957575 Fix unit test 2017-07-17 21:51:01 +02:00
Zestyr bfa626c6e6 Update default directories
Fixes #574
2017-07-17 21:50:58 +02:00
Zestyr a2350fd539 Clean up legacy code 2017-07-17 21:39:40 +02:00
Jack Robison 21de1fceee Bump version 0.14.2rc4 --> 0.14.2rc5
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-17 14:18:08 -04:00
Jack Robison 9b49d3592e Merge pull request #730 from lbryio/fix_claim_show_args
Fix claim_show (API change)
2017-07-17 14:08:08 -04:00
Kay Kurokawa 7072362fd7 add changelog 2017-07-17 12:17:39 -04:00
Kay Kurokawa e4df0bdb5f create UnknownOutpoint exception and use it 2017-07-17 12:17:35 -04:00
Kay Kurokawa 3cd972a4da fix UnknownNameError message 2017-07-17 12:01:20 -04:00
Kay Kurokawa b355e9ed8e make accurate docstring of claim_show 2017-07-17 12:01:20 -04:00
Kay Kurokawa 24035406d6 have claim_show no longer handle name argument, do not catch exceptions here as they will be caught in Wallet 2017-07-17 12:01:20 -04:00
Kay Kurokawa 21c1786dc6 rename Wallet.get_claim() to get_claim_by_claim_id() 2017-07-17 12:01:20 -04:00
vv181 196c7eb494 remove stream info cache
remove stream info cache
2017-07-15 23:54:23 +07:00
Jack Robison ab3278c50a Bump version 0.14.2rc3 --> 0.14.2rc4
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-14 14:44:03 -04:00
Jack Robison aced5b6499 Merge pull request #779 from lbryio/fix-loggly
Fix loggly
2017-07-14 14:42:47 -04:00
Jack Robison 19578fb10f update changelog 2017-07-14 14:35:51 -04:00
Jack Robison dfedb6cd01 update loggly token 2017-07-14 14:29:12 -04:00
Jack Robison 422dbb549b catch network-unreachable error in dht protocol 2017-07-14 14:29:12 -04:00
Jack Robison 7f36bed79d increase third party logger levels 2017-07-14 14:29:12 -04:00
Jack Robison 4c7c94e190 fix loggly setup 2017-07-14 14:29:02 -04:00
Jack Robison 142d30bbcf fix HTTPSHandler 2017-07-14 14:29:01 -04:00
Umpei Kay Kurokawa 06edd1f16a Merge pull request #781 from lbryio/disable_max_key_fee
Updated max_key_fee setting with disable_max_key_fee
2017-07-14 14:19:17 -04:00
hackrush f7b6a09110 Updated max_key_fee_setting
Added an option to disable max key fee check.
Did the required docs changes.
2017-07-14 14:09:30 -04:00
Jack Robison 80bca06bef Bump version 0.14.2rc2 --> 0.14.2rc3
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-14 13:24:49 -04:00
Jack Robison 738fa339df clean up changelog 2017-07-14 13:23:29 -04:00
Jack Robison 9b4d2b565e Bump version 0.14.2rc1 --> 0.14.2rc2
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-14 13:07:19 -04:00
Jack Robison edbab2a844 Merge pull request #759 from lbryio/dry_fix_handle_claim_result
Fix file_list failing due to malformed supports in the cache
2017-07-14 13:04:21 -04:00
Kay Kurokawa 314a45a7c2 add changelog 2017-07-14 12:53:40 -04:00
Kay Kurokawa 4bebfe9e25 fix malformed supports and amount in cache 2017-07-14 12:53:40 -04:00
Kay Kurokawa cbd85cd7d8 DRY fix for _handle_claim_result 2017-07-14 12:53:39 -04:00
Jack Robison 2728b1ed60 pylint 2017-07-12 14:21:30 -04:00
Jack Robison e24d626b07 fix lbryum requirement 2017-07-12 14:15:00 -04:00
Alex Grin ead3550588 Merge pull request #749 from hackrush01/hackrush
Daemon connects even if port 3333 is bound.
2017-07-12 14:14:42 -04:00
Alex Grin 53579dc613 Merge branch 'master' into hackrush 2017-07-12 14:14:26 -04:00
Jack Robison e86f8daf17 Bump version 0.14.1 --> 0.14.2rc1
Signed-off-by: Jack Robison <jackrobison@lbry.io>
2017-07-12 14:08:50 -04:00
Jack Robison 1f1d352429 bump lbryschema 2017-07-12 14:06:34 -04:00
Jack Robison ce76b7d14f Bump version: 0.14.1rc2 → 0.14.1 2017-07-07 17:51:37 -04:00
Jack Robison 58a1f444da Bump version: 0.14.1rc1 → 0.14.1rc2 2017-07-07 16:58:46 -04:00
Jack Robison 4e382b77a0 bump lbryum requirement 2017-07-07 16:57:50 -04:00
Jack Robison 72ec32c486 Bump version: 0.14.0 → 0.14.1rc1 2017-07-07 16:56:45 -04:00
Jack Robison 2e230828fd Merge pull request #766 from lbryio/negative-send-to-address
raise error on negative point reservation
2017-07-07 16:52:52 -04:00
Jack Robison 65bc93f2fe raise error on negative point reservation 2017-07-07 16:43:13 -04:00
hackrush 02c868512f Daemon provides steps on how to change the port.
Daemon now points to a faq on how to change the port if it can't
connect to 3333(default) and adds support for the required api/cli call.

Fixex #710
2017-07-06 03:48:13 +05:30
Umpei Kay Kurokawa cd98367039 Merge pull request #724 from lbryio/add_timeout_download_sd_blob
Add timeout to download_sd_blob
2017-07-05 17:09:50 -04:00
Kay Kurokawa bc498e60b7 add changelog 2017-07-05 16:34:36 -04:00
Kay Kurokawa 4019f2a2e1 fix problems with DownloadManager startup and stop 2017-07-05 16:33:02 -04:00
Kay Kurokawa 36dea2afbf use timeout in Daemon._download_blob() 2017-07-05 16:33:02 -04:00
Kay Kurokawa 73927e2b57 improve tests for GetStream 2017-07-05 16:33:02 -04:00
Kay Kurokawa a1292254bb use utils.safe_start_looping_call and utils.safe_stop_looping_call 2017-07-05 16:33:02 -04:00
Kay Kurokawa 8398d57024 use DownloadTimeoutError instead of generic Exception 2017-07-05 16:33:02 -04:00
Kay Kurokawa be75c1bc5b break up GetStream.start() function further for testing 2017-07-05 16:33:02 -04:00
Kay Kurokawa fc40f5525a add download_sd_blob timeout to GetStream 2017-07-05 16:33:02 -04:00
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
Alex Grintsvayg f99995a990 minor update 2017-07-05 16:30:35 -04:00
Alex Grintsvayg 2c7a73fd52 no more free credits for learning 2017-07-05 16:28:41 -04:00
Alex Grintsvayg 3382c18f81 Bump version: 0.14.0rc99 → 0.14.0 2017-07-05 15:58:59 -04:00
Alex Grintsvayg da511700a7 fixing version number before 0.14 release 2017-07-05 15:58:40 -04:00
Kay Kurokawa 03db114ba8 fix test_BlobManager race condition 2017-07-04 17:23:56 -04:00
Umpei Kay Kurokawa c79ecdb0dc Merge pull request #746 from lbryio/windows_path_fix
Make sure window paths of directories are in string not unicode
2017-07-04 14:25:45 -04:00
Kay Kurokawa a8e3132559 add changelog 2017-07-03 16:01:39 -04:00
Kay Kurokawa 7fb5b04bb4 add directory encoding test in test_conf 2017-07-03 16:01:28 -04:00
Kay Kurokawa 2730aa9ad6 make sure window paths of directories are in string not unicode 2017-07-03 16:01:18 -04:00
Umpei Kay Kurokawa efb30a9560 Merge pull request #751 from lbryio/fix_windows_tests
Fix windows tests
2017-07-03 15:39:54 -04:00
Umpei Kay Kurokawa 9c28b9f523 Merge pull request #754 from lbryio/revert-705-master
Revert "Fix default directories (fixes #574)"
2017-07-03 11:27:36 -04:00
Umpei Kay Kurokawa 4e42ae97ea Revert "Fix default directories (fixes #574)" 2017-07-03 11:09:59 -04:00
Kay Kurokawa 4b1905e448 add changelog 2017-07-02 22:08:51 -04:00
Kay Kurokawa 00b6808ded fix functional tests for windows 2017-07-02 21:58:11 -04:00
Kay Kurokawa 55c90e0657 make sure DBEncryptedFileMetadataManager closes db connection 2017-07-02 21:58:02 -04:00
Kay Kurokawa 99c2130be7 fix for test_blobmanager 2017-07-02 21:57:54 -04:00
Kay Kurokawa d21b1bcef1 enable tests 2017-07-02 21:57:46 -04:00
Kay Kurokawa 1bf4048c46 pylint fix 2017-06-30 12:51:05 -04:00
Alex Grintsvayg c7b254ec88 Merge branch 'remove_download_directory_get'
* remove_download_directory_get:
  delete download_directory argument for API command get
2017-06-30 09:40:08 -04:00
Kay Kurokawa f71696ee50 delete download_directory argument for API command get 2017-06-30 09:39:49 -04:00
Alex Grin 8d6a7155ef Merge pull request #705 from zestyr/master
Fix default directories (fixes #574)
2017-06-30 09:34:00 -04:00
Alex Grintsvayg 4e4eeae79c Merge branch 'zestyr-improve_get_error'
* zestyr-improve_get_error:
  Improve error message upon failing to resolve a claim
2017-06-30 09:14:22 -04:00
Zestyr 8735e1bb53 Improve error message upon failing to resolve a claim 2017-06-30 09:13:42 -04:00
Umpei Kay Kurokawa f06366b7dd Merge pull request #733 from lbryio/crypstream_tests
Add docstring and unit test for CryptBlob.py
2017-06-28 14:45:53 -04:00
Jack Robison a7d60a18e0 Bump version: 0.14.2rc1 → 0.14.2rc2 2017-06-28 13:14:28 -04:00
Jack Robison b8732e451b bump lbryum requirement 2017-06-28 13:13:45 -04:00
Kay Kurokawa 9ffcd9c1b1 added changelog 2017-06-28 12:13:24 -04:00
Kay Kurokawa 3479c6ea8d add docstring and unit test for CryptBlob.py 2017-06-28 12:13:24 -04:00
Zestyr 9bcd550f0a Merge changelog 2017-06-28 17:55:44 +02:00
Zestyr 091c49115c Merge remote-tracking branch 'upstream/master' 2017-06-28 17:54:42 +02:00
Jack Robison 0f32260e2c Merge pull request #718 from lbryio/lbryum-refactor
update lbryum imports
2017-06-27 19:15:21 -04:00
Jack Robison e71389c7e3 update lbryum imports 2017-06-27 19:02:25 -04:00
Jack Robison d9acb7fdab Merge pull request #736 from hackrush01/hackrush
Increased max_key_fee
2017-06-27 13:25:15 -04:00
hackrush 9743162cda Increased max_key_fee
The default max_key_fee value is increased to US$ 50.
Fixes #721
2017-06-27 21:48:42 +05:30
Jack Robison aef31991f9 Merge pull request #731 from lbryio/module-cleanup
module cleanup
2017-06-26 11:35:04 -04:00
Jack Robison efd46a9715 update changelog 2017-06-25 21:29:36 -04:00
Jack Robison 85cc843d36 initialize settings if necessary when configuring an api client 2017-06-25 21:25:49 -04:00
Jack Robison d9ced3c6f7 convenient import for api client 2017-06-25 21:25:49 -04:00
Jack Robison 967cc4c63c rename lbrynet.lbrynet_daemon to lbrynet.daemon 2017-06-25 21:25:41 -04:00
Jack Robison eba74b97bd rename lbrynet.lbryfilemanager to lbrynet.file_manager 2017-06-25 21:04:04 -04:00
Jack Robison 1ec3218f18 rename lbrynet.lbryfile to lbrynet.lbry_file 2017-06-25 21:03:37 -04:00
Jack Robison 30a8a951b2 Bump version: 0.14.1rc1 → 0.14.2rc1 2017-06-23 13:26:56 -04:00
Jack Robison 5e0a82da54 Merge pull request #704 from lbryio/fix_blobmanager_manage
Fix blobmanager manage
2017-06-23 13:26:21 -04:00
Kay Kurokawa b4224812ba add changelog 2017-06-23 10:26:51 -04:00
Kay Kurokawa 613278de12 fix test_misc, check before deleting 2017-06-23 10:24:27 -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
Zed 9caea54490 Merge branch 'master' into master 2017-06-23 02:45:12 +02:00
Alex Grintsvayg fa9b9233d1 better err mesg 2017-06-22 06:10:26 -04:00
Jack Robison 77da61c44b Bump version: 0.14.0rc1 → 0.14.1rc1 2017-06-21 23:12:10 -04:00
Jack Robison 56b744caec bump lbryum 2017-06-21 23:11:09 -04:00
Jack Robison 534fbb784f Bump version: 0.13.1 → 0.14.0rc1 2017-06-21 23:08:11 -04:00
Jack Robison 732fdaa377 Merge pull request #725 from lbryio/update-settings
remove unused settings
2017-06-21 23:06:54 -04:00
Jack Robison ae0ac4f369 bump lbryum 2017-06-21 23:06:14 -04:00
Jack Robison 031e4401f2 Merge pull request #717 from lbryio/fix_support_typo
Fix support typo fixes #741
2017-06-21 22:56:39 -04:00
Jack Robison 10f8143a7b update changelog 2017-06-21 22:54:53 -04:00
Jack Robison bc34c22e58 update daemon settings and settings_set 2017-06-21 22:54:47 -04:00
Jack Robison 4c1a2b7e72 fix blob_list docstring 2017-06-21 21:25:06 -04:00
Jack Robison de455c0cce install ruby on travis? 2017-06-21 21:22:17 -04:00
Zestyr 6a1a91f8f1 Fix old legacy Windows location 2017-06-22 02:28:32 +02:00
Kay Kurokawa 0a2a6c812d add changelog 2017-06-20 10:50:07 -04:00
Kay Kurokawa 39195568cc fix typo in claim_new_support docstring 2017-06-20 10:49:27 -04:00
Zestyr ebec2fe955 Make directories lowercase, catch exception, initialize settings 2017-06-19 19:49:27 +02:00
Zestyr ddde036e3a Add check for old folder locations 2017-06-19 19:24:39 +02:00
Zestyr 75d1f7f897 Add changelog 2017-06-18 07:15:34 +02:00
Zestyr 28613f1990 Shorten download dir variable for consistency 2017-06-18 07:15:28 +02:00
Zestyr 5db5d20f77 Remove duplicated legacy code for creating directories 2017-06-18 07:14:42 +02:00
Zestyr e0ff3171d8 Fix default directories 2017-06-18 07:14:42 +02:00
Jack Robison 2dab24ea14 Merge pull request #694 from lbryio/fix_session_close
fix typo which may not shut down blob_tracker
2017-06-16 14:07:05 -04:00
Jack Robison 1785c8ba6a changelog 2017-06-16 14:00:48 -04:00
Kay Kurokawa 59893e8fa8 fix typo which may not shut down blob_tracker 2017-06-16 14:00:08 -04:00
Jack Robison ed23622521 Merge pull request #697 from lbryio/fix_log_exceptions
Fix log exceptions
2017-06-16 13:55:00 -04:00
Jack Robison 51263f380e Merge branch 'master' into fix_log_exceptions 2017-06-16 13:54:26 -04:00
Jack Robison 2725f384d9 Bump version: 0.13.1rc2 → 0.13.1 2017-06-15 20:25:07 -04:00
Jack Robison a822d05692 update docs 2017-06-15 19:55:44 -04:00
Jack Robison 1211fa031d Bump version: 0.13.1rc1 → 0.13.1rc2 2017-06-15 18:29:43 -04:00
Jack Robison e862f94e54 bump lbryum requirement 2017-06-15 18:28:43 -04:00
Kay Kurokawa a324a3147e add changelog 2017-06-15 16:13:49 -04:00
Kay Kurokawa 114f6ef8f8 fix file_delete log from throwing exception on unicode file_name 2017-06-15 15:58:32 -04:00
Kay Kurokawa 0b5051823f fix case when downloader is stopped before sd_hash is loaded 2017-06-15 14:31:02 -04:00
Jack Robison a5b33fdb0b Bump version: 0.13.0rc1 → 0.13.1rc1 2017-06-14 15:55:57 -04:00
Jack Robison 950c1e6d44 Merge pull request #690 from lbryio/total_contacts
add unique_contacts to status response
2017-06-14 15:55:26 -04:00
Jack Robison 9f15573742 add unique_contacts 2017-06-14 15:46:38 -04:00
Jack Robison d4835153cd Bump version: 0.12.3rc1 → 0.13.0rc1 2017-06-14 15:34:12 -04:00
Jack Robison 0941a207f1 Merge pull request #672 from lbryio/fix_file_delete
Fix file delete
2017-06-14 15:33:32 -04:00
Kay Kurokawa 4c22362cc1 add changelog 2017-06-14 15:28:59 -04:00
Kay Kurokawa 69dacffc7a rename delete_target_file to delete_from_download_dir, remove -a delete_all option 2017-06-14 15:28:59 -04:00
Kay Kurokawa ae9a6b524f add changelog 2017-06-14 15:28:59 -04:00
Kay Kurokawa a1c99594b3 add tests for CLI flags 2017-06-14 15:28:59 -04:00
Kay Kurokawa 9bf533fc73 fix delete_target_file flag, add longer flag name option 2017-06-14 15:28:59 -04:00
Kay Kurokawa 602eada430 fix delete_all option in file_delete API command 2017-06-14 15:28:59 -04:00
Jack Robison 01d906b06a Bump version: 0.12.2rc3 → 0.12.3rc1 2017-06-14 15:27:22 -04:00
Umpei Kay Kurokawa 05e556d066 Merge pull request #674 from lbryio/fix_getstream
Fix GetStream class
2017-06-14 15:15:21 -04:00
Kay Kurokawa 1b944688c1 add changelog 2017-06-14 15:05:43 -04:00
Kay Kurokawa 711c4f3196 Various improvements, fixes, and tests for GetStream class 2017-06-14 15:05:43 -04:00
Jack Robison 0caa83c10c Bump version: 0.12.2rc2 → 0.12.2rc3 2017-06-13 21:22:24 -04:00
Jack Robison 9bdba2172a bump lbryum 2017-06-13 21:22:00 -04:00
Jack Robison 0f2f5f91df Bump version: 0.12.2rc1 → 0.12.2rc2 2017-06-12 14:14:56 -04:00
Alex Grin 49b255a2b5 Merge pull request #687 from lbryio/fix_daemoncontrol_deprecated
DaemonControl is using deprecated is_running API command
2017-06-12 14:07:49 -04:00
Alex Grin da8ce591bc Merge pull request #681 from lbryio/remove_unused_add_stream
remove unused add_stream() function from Daemon
2017-06-12 14:07:36 -04:00
Jack Robison 7bb76a41bb Bump version: 0.12.1rc1 → 0.12.2rc1 2017-06-12 13:52:34 -04:00
Jack Robison 0fce59f4f2 Merge pull request #688 from lbryio/add-claim-address-param
add change_address param to publish
2017-06-12 13:51:45 -04:00
Jack Robison 9c88f820f9 add change_address param to publish 2017-06-12 13:43:15 -04:00
Kay Kurokawa 4bc512bacb is_running is deprecated, replace with status in DaemonControl 2017-06-12 13:05:41 -04:00
Jack Robison 00fbe306c5 Bump version: 0.12.0rc1 → 0.12.1rc1 2017-06-12 11:18:38 -04:00
Alex Grin bea6e2913f Merge pull request #686 from lbryio/claim-send-to-address
add claim_send_to_address
2017-06-12 10:44:31 -04:00
Jack Robison c56ac12913 add claim_send_to_address 2017-06-12 10:30:18 -04:00
Jack Robison c393822c2b Bump version: 0.11.1rc1 → 0.12.0rc1 2017-06-09 16:03:13 -04:00
Jack Robison 9a3c6ea18b Merge pull request #643 from lbryio/batched-resolve
Batched uri resolution
2017-06-09 16:01:57 -04:00
Jack Robison 1c8fb9a324 claim_list_by_channel 2017-06-09 14:48:56 -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 b85655ff58 bump lbryum requirement 2017-06-09 14:48:55 -04:00
Jack Robison ca2f0d827d Bump version: 0.11.0 → 0.11.1rc1 2017-06-09 14:45:06 -04:00
Jack Robison 42d40b2e1c Merge pull request #682 from lbryio/fix-blob-manager-db-race-condition
fix blob manager db race condition
2017-06-09 14:41:11 -04:00
Jack Robison 82118e6692 fix blob manager db race condition 2017-06-09 14:09:17 -04:00
Jack Robison 5679ffb6a9 Bump version: 0.11.0rc3 → 0.11.0 2017-06-09 13:01:56 -04:00
Kay Kurokawa b3cd128779 remove unused add_stream() function from Daemon 2017-06-09 12:59:49 -04:00
Jack Robison 2aec457a19 Merge pull request #680 from lbryio/update-docs
add cli docs
2017-06-09 12:56:12 -04:00
Jack Robison c3799b9c8c add cli docs 2017-06-09 12:14:03 -04:00
Jack Robison 21fb3b9fae Bump version: 0.11.0rc2 → 0.11.0rc3 2017-06-08 19:26:34 -04:00
Jack Robison 515b3124db Merge pull request #677 from lbryio/fix-version-cli
fix cli version and --version arguments
2017-06-08 19:22:55 -04:00
Jack Robison c9a8016ae7 Merge pull request #676 from longle255/fix_insufficient_funds_message
add message for exception so that app can render
2017-06-08 19:22:34 -04:00
Jack Robison 869a95c4c7 fix cli version and --version arguments 2017-06-08 19:08:51 -04:00
Jack Robison 53f2147ecb Bump version: 0.11.0rc1 → 0.11.0rc2 2017-06-08 18:45:57 -04:00
Jack Robison fe9ec918e2 bump requirements 2017-06-08 18:42:48 -04:00
Le Long 87b6eeeef5 trim line for pylint 2017-06-09 00:39:26 +02:00
Le Long 8b9c6f5315 add changelog 2017-06-09 00:30:48 +02:00
Le Long 4c06db1901 add message for exception so that app can render 2017-06-09 00:16:32 +02:00
Alex Grintsvayg dbe071cbb7 keep it neat 2017-06-08 15:24:58 -04:00
Jack Robison b5d7d961de Bump version: 0.10.4rc1 → 0.11.0rc1 2017-06-05 11:39:56 -04:00
Jack Robison 791a060123 fix changelog 2017-06-05 11:39:18 -04:00
Jack Robison d8f3984477 Merge pull request #669 from lbryio/remove-deprecated
Remove deprecated commands
2017-06-05 11:02:52 -04:00
Jack Robison 6e17060819 remove deprecated commands 2017-06-05 10:46:19 -04:00
Jack Robison 363db1073e return error for deprecated functions 2017-06-05 10:46:19 -04:00
Jack Robison cfcc4205ab Merge pull request #670 from lbryio/add_claim_addr
Add claim address as an option to publish
2017-06-05 10:16:44 -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 8112658d70 Merge pull request #667 from lbryio/old_fee_check
Add check for old fee format and throw releveant exception
2017-06-02 16:06:51 -04:00
Kay Kurokawa 363ad8452c add changelog 2017-06-02 14:52:27 -04:00
Kay Kurokawa 4bfd2e630b add check for old fee format and throw releveant exception 2017-06-02 14:09:07 -04:00
Jack Robison d3099643e4 Merge pull request #668 from lbryio/fix-analytics-error
fix download analytics error
2017-06-02 14:04:54 -04:00
Jack Robison f5b4d9f384 fix download analytics error 2017-06-02 14:00:13 -04:00
Jack Robison 522cb9cb82 Merge pull request #657 from lbryio/remove-old-metadata
remove lbrynet.metadata
2017-06-02 12:27:53 -04:00
Jack Robison 5b297f165f set fee version 2017-06-02 11:52:57 -04:00
Kay Kurokawa c3f61b3e69 improve tests for ExchangeRateManager 2017-06-02 11:52:57 -04:00
Jack Robison 9f87d502c3 update currency conversion 2017-06-02 11:52:51 -04:00
Jack Robison 96927ec985 remove lbrynet.metadata 2017-06-02 11:50:50 -04:00
Alex Grin 7c18a4a8f7 Merge pull request #664 from techtonik/patch-1
README.md: Fix link to releases
2017-06-02 05:35:42 -04:00
anatoly techtonik df006c71d3 README.md: Fix link to releases 2017-06-02 10:44:25 +03:00
Jack Robison 8a73315541 Bump version: 0.10.3production4 → 0.10.4rc1 2017-06-01 16:37:55 -04:00
Jack Robison 11dc17d131 Merge pull request #656 from lbryio/fix_resolve_exception
catch UnknownNamError instead of base Exception for resolve command
2017-06-01 16:35:46 -04:00
Jack Robison 6a2fcbab67 bump lbryum requirement 2017-06-01 16:27:41 -04:00
Kay Kurokawa da8256ad52 catch UnknownNamError instead of base Exception for resolve command 2017-06-01 16:26:03 -04:00
Jack Robison 8bc611cc88 Bump version: 0.10.3production3 → 0.10.3production4 2017-06-01 16:12:02 -04:00
Jack Robison 84bac4bab7 Merge pull request #652 from lbryio/arg-parsing
Parse cli args from docstrings and add positional arguments
2017-06-01 16:03:37 -04:00
Kay Kurokawa 58dd576adc add CLI docopt parsing tests to integration tests 2017-06-01 15:39:08 -04:00
Kay Kurokawa 257d025d98 add integration test 2017-06-01 15:26:03 -04:00
Kay Kurokawa 90033692d4 normalize file_set_status CLI args with file_list, add name arg to file_list,file_set_status,file_delete 2017-06-01 15:26:03 -04:00
Alex Grintsvayg 803cd98fef add raspbian instructions 2017-06-01 14:23:59 -04:00
Kay Kurokawa 1cf32436f2 added missing closing brackets > 2017-06-01 12:16:19 -04:00
Jack Robison 180e1d4768 update changelog 2017-05-30 17:43:59 -04:00
Jack Robison 57c3d2590c update arg parsing to use docopt 2017-05-30 17:43:59 -04:00
Jack Robison 0eac1e6ed0 update docstrings 2017-05-30 17:43:54 -04:00
Jack Robison 0b4c4cf6ca register api command with metaclass, add deprecated and flags decorators 2017-05-30 17:42:48 -04:00
Jack Robison 17b692d258 Merge pull request #650 from lbryio/dht-bandwidth-tracking
add dht bandwidth tracking
2017-05-30 11:42:55 -04:00
Jack Robison 02475ff985 add dht bandwidth tracking 2017-05-30 11:41:54 -04:00
Jack Robison 73a5828865 Merge pull request #653 from lbryio/add_publish_filecheck
add ispath, and file size check before publishing
2017-05-30 11:39:56 -04:00
Jack Robison ffe04950bc Bump version: 0.10.3production2 → 0.10.3production3 2017-05-30 11:25:19 -04:00
Jack Robison 9c2ec3a8eb fix changelog 2017-05-30 11:25:07 -04:00
Jack Robison 30185d2548 Merge pull request #658 from lbryio/publish-fixes
Publish fixes
2017-05-30 11:20:51 -04:00
Jack Robison 4643309e6b update changelog 2017-05-30 11:10:31 -04:00
Jack Robison 61cb3e2a8d update fee parameter to match lbryschema 2017-05-30 11:10:31 -04:00
Jack Robison f258df95e6 fix licenseUrl metadata key name 2017-05-30 11:10:31 -04:00
Jack Robison ccbb5d88dc don't allow bid to be equal to wallet balance (nothing left for the tx fee) 2017-05-30 11:10:31 -04:00
Jack Robison 5d4e4a8753 Bump version: 0.10.3 → 0.10.3production2 2017-05-30 11:02:37 -04:00
Jack Robison 89ada85f0f bump lbryschema requirement 2017-05-30 10:58:07 -04:00
Kay Kurokawa 3c880a1684 add ispath, and file size check before publishing 2017-05-29 14:42:19 -04:00
Umpei Kay Kurokawa 12fc722712 Merge pull request #647 from lbryio/fix_claimshow
allow claim_show to be specified without name
2017-05-29 12:55:53 -04:00
Kay Kurokawa ed3896f3e9 allow claim_show to be specified without name 2017-05-29 12:17:46 -04:00
Alex Grintsvayg 8a2a8ce05f doesnt need to be a global 2017-05-24 14:45:41 -04:00
Alex Grintsvayg 18e63303bf upload builds to s3 2017-05-24 14:43:24 -04:00
Jeremy Kauffman c8142a2fb2 Bump version: 0.10.3rc5 → 0.10.3 2017-05-23 16:19:57 -04:00
Alex Grintsvayg 05c44eab08 those reqs moved to main requirements.txt 2017-05-23 13:21:48 -04:00
Alex Grintsvayg 4528a68f5c fix windows build version 2017-05-22 16:30:54 -04:00
Jeremy Kauffman 00876c7d43 add requirements for releasing 2017-05-20 13:09:19 -04:00
Jack Robison b38614e29c Bump version: 0.10.3rc4 → 0.10.3rc5 2017-05-20 12:05:09 -04:00
Jack Robison 82be3bb2cb whitespace 2017-05-20 11:59:55 -04:00
Jack Robison 06741f8560 Bump version: 0.10.3rc3 → 0.10.3rc4 2017-05-20 11:53:44 -04:00
Jack Robison c0be8ddcdf add channel_id 2017-05-19 17:26:58 -04:00
Jack Robison 3253c6bd60 Bump version: 0.10.3rc2 → 0.10.3rc3 2017-05-16 19:49:10 -04:00
Jack Robison a870ca0a80 Merge pull request #641 from lbryio/add_force_to_resolve
Add force option to resolve
2017-05-12 15:42:01 -04:00
Kay Kurokawa 5da062482d add changelog 2017-05-12 15:15:14 -04:00
Kay Kurokawa 7ac88ea3ea add force option to resolve 2017-05-12 13:02:25 -04:00
Jack Robison da6858f1c3 Bump version: 0.10.3rc1 → 0.10.3rc2 2017-05-11 19:50:07 -04:00
Jack Robison 4bd3d49827 Merge pull request #636 from lbryio/fix-publish-race-conditions
Fix publish race conditions
2017-05-11 15:21:41 -04:00
Jack Robison f4efb9c192 update changelog 2017-05-11 14:31:50 -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 4224d63603 fix sd hash race condition when loading lbry file attributes 2017-05-11 14:31:50 -04:00
Jack Robison f33b14e325 insert or ignore instead of trapping sqlite3. IntegrityError 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 6931d8e586 decorator for queued api commands 2017-05-11 14:31:49 -04:00
Jack Robison a49039117f bump lbryum requirement 2017-05-11 14:30:54 -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
Alex Grintsvayg d99fc519b5 Bump version: 0.10.2 → 0.10.3rc1 2017-05-04 11:40:37 -04:00
Alex Grintsvayg dcff18323d update api docs 2017-05-04 11:37:15 -04:00
Alex Grin 89ecd2c571 Merge pull request #620 from lbryio/claim-caching
Add claim caching to wallet storage
2017-05-04 11:36:03 -04:00
Jack Robison 18747d4349 update changelog 2017-05-03 17:14:49 -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 11cfd9083e Bump version: 0.10.2rc1 → 0.10.2 2017-05-03 13:17:46 -04:00
Alex Grintsvayg f7793cea7f dont error if no changelog 2017-05-03 13:17:38 -04:00
Alex Grintsvayg df4aa691cd Bump version: 0.10.1 → 0.10.2rc1 2017-05-03 13:00:35 -04:00
Alex Grintsvayg 113f8ff2d7 fix set_build and version 2017-05-03 13:00:01 -04:00
Alex Grintsvayg 6097ebb7b8 Bump version: 0.10.1rc2 → 0.10.1 2017-05-03 11:37:00 -04:00
Jack Robison 1c8735295b Bump version: 0.10.1rc1 → 0.10.1rc2 2017-05-01 21:34:54 -04:00
Jack Robison 6081b77167 Merge pull request #629 from lbryio/shutdown-fixes
Shutdown fixes
2017-05-01 21:24:44 -04:00
Jack Robison e124b7fd63 update changelog 2017-05-01 21:09:34 -04:00
Jack Robison 8243349b20 use reactor.fireSystemEvent instead of reactor.stop 2017-05-01 21:09:24 -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 c525c8f5d1 delete unused 2017-04-29 12:21:33 -04:00
Alex Grintsvayg 16c18c59ff Bump version: 0.10.0 → 0.10.1rc1 2017-04-27 08:38:35 -04:00
Alex Grintsvayg e4f8f50b08 unused import 2017-04-26 21:06:16 -04:00
Alex Grintsvayg 15e89650ff track more events 2017-04-26 20:02:00 -04:00
Alex Grintsvayg 8afe4d1af8 dont send analytics info if its disabled 2017-04-26 18:20:02 -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 e19e2f3609 stop checking github for new versions 2017-04-26 14:18:30 -04:00
Alex Grintsvayg cc14ac4a46 catch ctrl-c on confirm 2017-04-25 16:56:07 -04:00
Alex Grintsvayg c7161ba1ac nicer changelog 2017-04-25 16:54:29 -04:00
Alex Grintsvayg 8495e62329 Bump version: 0.10.0rc15 → 0.10.0 2017-04-25 16:22:53 -04:00
Alex Grintsvayg d438bfdf0e Bump version: 0.10.0rc14 → 0.10.0rc15 2017-04-25 15:23:03 -04:00
Alex Grintsvayg 4724f53bc4 changelog 2017-04-25 14:37:43 -04:00
Alex Grintsvayg 06fab24437 Merge branch 'fix-windows-signing'
* fix-windows-signing:
  pylint type checking
  pointless strings
  pylint
  try decrypting cert
  re-enable secure vars
2017-04-25 14:37:04 -04:00
Alex Grintsvayg cdf67de46c pylint type checking 2017-04-25 14:36:14 -04:00
Alex Grintsvayg d6e7fde90a pointless strings 2017-04-25 14:36:14 -04:00
Alex Grintsvayg fd51d8ddf0 pylint 2017-04-25 14:36:14 -04:00
Jack Robison a50cbdcbb8 try decrypting cert 2017-04-25 14:36:14 -04:00
Jack Robison 8b2cffd34e re-enable secure vars 2017-04-25 14:36:05 -04:00
Alex Grintsvayg 25b6fbb73e remove another pylint exception 2017-04-25 14:09:03 -04:00
Alex Grintsvayg 50152210e4 figured it out 2017-04-25 12:38:51 -04:00
Alex Grintsvayg edc62c82e3 working on fixing appveyor build 2017-04-25 12:28:07 -04:00
Alex Grintsvayg 3a66a740d3 Bump version: 0.10.0rc13 → 0.10.0rc14 2017-04-25 08:59:31 -04:00
Alex Grintsvayg 8a6a00f49e mkdocs 2017-04-25 08:58:56 -04:00
Jack Robison f08079dc9b Merge pull request #621 from lbryio/wait-for-wallet-subscriptions
wait for address subscriptions before announcing the wallet has started
2017-04-24 00:25:41 -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 4f43a63131 removing requirements_base.txt 2017-04-23 18:35:40 +01:00
Mathew WAller c9c88055c3 Requested changes 2017-04-23 18:33:06 +01:00
Alex Grintsvayg 8498eae90b debug for daemon upload, since its not working on appveyor 2017-04-21 19:01:59 -04:00
Alex Grintsvayg 73ee5786e2 Bump version: 0.10.0rc12 → 0.10.0rc13 2017-04-21 15:37:42 -04:00
Alex Grintsvayg ce40efa6cb mkdocs 2017-04-21 15:14:33 -04:00
Jack Robison 1dda158087 Bump version: 0.10.0rc11 → 0.10.0rc12 2017-04-21 13:33:21 -04:00
Jack Robison 37a03a28ce update requirements 2017-04-21 13:33:09 -04:00
Jack Robison 1ecb32b3ed less intensive blob availability check 2017-04-21 13:32:59 -04:00
Alex Grintsvayg 0830c8bde2 Bump version: 0.10.0rc10 → 0.10.0rc11 2017-04-21 13:23:23 -04:00
Alex Grintsvayg a31783fc84 disable stupid version setting 2017-04-21 13:13:31 -04:00
Alex Grintsvayg 0a3e00b276 Revert "will this fix tests?"
This reverts commit 0b668fb1dd.
2017-04-21 12:15:32 -04:00
Alex Grintsvayg 0b668fb1dd will this fix tests? 2017-04-21 12:07:11 -04:00
Alex Grintsvayg bfd0a322ae wrong path 2017-04-21 11:59:01 -04:00
Alex Grintsvayg 11d516794d you have to install lbrynet to run twisted tests on it 2017-04-21 11:55:20 -04:00
Mathew WAller 28b56f05cc Updated changelog and removed requirements_base.txt 2017-04-21 14:40:46 +01:00
Alex Grintsvayg cb883e9316 delete requirements_base 2017-04-21 09:00:19 -04:00
Mathew WAller 6e37a0536a Removing pylint issues 2017-04-21 02:59:40 +01:00
Mathew WAller 8f559c370a Updating changelog 2017-04-21 02:28:04 +01:00
Mathew WAller 8f0f27da1a Adding functionality to check the balance of a given wallet. 2017-04-21 02:16:26 +01:00
Umpei Kay Kurokawa cb8730e696 Merge pull request #614 from lbryio/fix_stream_cost_est
Fix stream_cost_estimate
2017-04-19 18:24:37 -04:00
Kay Kurokawa c4b69055c7 add changelog 2017-04-19 18:18:54 -04:00
Kay Kurokawa bbbdf5486e clarify docstring for stream_cost_estimate 2017-04-19 18:18:54 -04:00
Kay Kurokawa a634c49e1c stream_cost_estimate throws exception when value is not decodeable 2017-04-19 18:18:54 -04:00
Alex Grintsvayg 7ee5c1696a Bump version: 0.10.0rc9 → 0.10.0rc10 2017-04-19 16:02:07 -04:00
Alex Grintsvayg 492cbc83c9 pylint 2017-04-19 16:00:39 -04:00
Jack Robison d2f01a214d reduce logging level for noisy dht warning 2017-04-19 15:59:50 -04:00
Alex Grintsvayg c5b8859504 Bump version: 0.10.0rc8 → 0.10.0rc9 2017-04-19 15:43:35 -04:00
Alex Grintsvayg 290d204659 wrong repo 2017-04-19 15:43:26 -04:00
Alex Grintsvayg 1f231286b4 Bump version: 0.10.0rc7 → 0.10.0rc8 2017-04-19 15:42:20 -04:00
Alex Grintsvayg fa9378c2ae release.py 2017-04-19 15:42:11 -04:00
Alex Grintsvayg 127c4e90a2 Merge branch 'build'
* build:
  one less pylint exception
  tests for windows, simplify pylint
  lbryum is in requirements now
  build daemon separately in teamcity
2017-04-19 15:01:06 -04:00
Alex Grintsvayg 28cccd7574 one less pylint exception 2017-04-19 14:59:06 -04:00
Alex Grintsvayg 7f7a6a619f tests for windows, simplify pylint 2017-04-19 14:59:06 -04:00
Alex Grintsvayg 55d47b9f19 lbryum is in requirements now 2017-04-19 14:59:06 -04:00
Alex Grintsvayg 371efb59c7 build daemon separately in teamcity 2017-04-19 14:59:06 -04:00
Jack Robison bc84d16de7 Bump version: 0.10.0rc6 → 0.10.0rc7 2017-04-19 13:54:51 -04:00
Jack Robison bbfb5a7853 include schema version in version() response 2017-04-19 13:54:38 -04:00
Jack Robison 8ce4039093 bump lbryum 2017-04-19 13:48:53 -04:00
Jack Robison 01d86204d0 Bump version: 0.10.0rc5 → 0.10.0rc6 2017-04-19 12:49:33 -04:00
Jack Robison 990179655d bump lbryum and lbryschema 2017-04-19 12:48:38 -04:00
Alex Grintsvayg 52a42ce2fc Bump version: 0.10.0rc4 → 0.10.0rc5 2017-04-18 17:27:33 -04:00
Jack Robison 05387bd743 Merge pull request #605 from lbryio/upgrade_appdirs
use appdirs 1.4.3 in requirements.txt
2017-04-18 14:42:18 -04:00
Alex Liebowitz 27788829b0 Bump version: 0.10.0rc3 → 0.10.0rc4 2017-04-17 17:31:19 -04:00
Alex Grintsvayg af455ff52e Bump version: 0.10.0rc2 → 0.10.0rc3 2017-04-17 12:37:37 -04:00
Alex Grintsvayg 6c0f805ec3 Bump version: 0.10.0rc1 → 0.10.0rc2 2017-04-17 10:46:37 -04:00
Alex Grintsvayg 41204f7cbe Merge remote-tracking branch 'origin/return-full-ids'
* origin/return-full-ids:
  Return full LBRY ID and installation ID in jsonrpc_status()
2017-04-17 09:25:36 -04:00
alexliebowitz fca79139ff Return full LBRY ID and installation ID in jsonrpc_status()
Better to let the client decide whether to display the short or long version
2017-04-14 11:26:05 -04:00
Alex Grintsvayg e8bccec71c Bump version: 0.9.2rc24 → 0.10.0rc1 2017-04-13 13:15:25 -04:00
Jack Robison 342ae231ea fix uncaught error stream_cost_estimate 2017-04-13 13:00:18 -04:00
Alex Grintsvayg 8b11521868 Bump version: 0.9.2rc23 → 0.9.2rc24 2017-04-12 18:51:06 -04:00
Jack Robison c26f83d81f Bump version: 0.9.2rc22 → 0.9.2rc23 2017-04-12 18:08:42 -04:00
Jack Robison e6f92a2dc7 fix fee tests, whitespace 2017-04-12 17:43:00 -04:00
Alex Grintsvayg 4698910ab7 Bump version: 0.9.2rc21 → 0.9.2rc22 2017-04-12 15:23:08 -04:00
Jack Robison 8c361aef1a fix typo 2017-04-12 14:48:47 -04:00
Jack Robison 2c8b99df76 fix balance check when claiming a name 2017-04-12 14:47:46 -04:00
Jack Robison 10c72dcfd2 stream_cost_estimate fixes 2017-04-12 14:46:27 -04:00
Jack Robison 10dcc429f3 update resolve doc 2017-04-12 14:04:11 -04:00
Jack Robison 31b5026570 return false from claim_show when claim is not found 2017-04-12 13:53:07 -04:00
Jack Robison f38120fdfc Merge pull request #608 from lbryio/uncaught-publish-errors
raise errors before we get further into the publish process
2017-04-12 13:41:48 -04:00
Jack Robison 06cd14e0ff raise errors before we get further into the publish process 2017-04-12 13:02:04 -04:00
Alex Grintsvayg 3820401fce Bump version: 0.9.2rc20 → 0.9.2rc21 2017-04-12 12:25:56 -04:00
Alex Grintsvayg ddf907231d Bump version: 0.9.2rc19 → 0.9.2rc20 2017-04-12 11:46:04 -04:00
Alex Grintsvayg 2df1092e1a Bump version: 0.9.2rc18 → 0.9.2rc19 2017-04-12 11:05:11 -04:00
Jack Robison d1414bc03a Bump version: 0.9.2rc17 → 0.9.2rc18 2017-04-11 19:22:01 -04:00
Jack Robison c9e3f1fd02 bump lbryum requirement 2017-04-11 19:21:44 -04:00
Jack Robison 33c754f5a6 Bump version: 0.9.2rc16 → 0.9.2rc17 2017-04-11 01:18:13 -04:00
Jack Robison 9669e06279 Merge pull request #607 from lbryio/fix-stream-cost-estimate
fix stream_cost_estimate
2017-04-11 01:17:46 -04:00
Jack Robison 389ee2ad70 fix stream_cost_estimate 2017-04-11 01:13:10 -04:00
Jack Robison c87c8beeb4 Bump version: 0.9.2rc15 → 0.9.2rc16 2017-04-10 21:52:00 -04:00
Jack Robison f53cde824e Merge pull request #606 from lbryio/channel-name-in-file-dict
Include channel name in claim and file responses
2017-04-10 21:50:53 -04:00
Jack Robison 63142df865 update changelog 2017-04-10 21:46:16 -04:00
Jack Robison 023f81674c update requirements 2017-04-10 21:43:22 -04:00
Jack Robison b644125e93 return None for failed resolve uri 2017-04-10 21:32:41 -04:00
Jack Robison c5699db30a add channel name to file dict 2017-04-10 21:32:20 -04:00
Kay Kurokawa 1f45054d40 use appdirs 1.4.3 in requirements.txt 2017-04-10 16:15:31 -04:00
Jack Robison c1525760d8 verbose sourceclear 2017-04-10 15:22:36 -04:00
Jack Robison b773cbbec6 add sourceclear 2017-04-10 15:13:04 -04:00
Jack Robison 043e2d0ab9 Bump version: 0.9.2rc14 → 0.9.2rc15 2017-04-10 14:31:06 -04:00
Jack Robison 16221d08a9 Merge pull request #603 from lbryio/get-availability-by-uri
get availability by uri
2017-04-10 14:30:05 -04:00
Jack Robison 6ccab8bcb8 get availability by uri 2017-04-10 14:29:24 -04:00
Jack Robison a87834bacc skip test_parallel_connections 2017-04-10 14:21:46 -04:00
Jack Robison 105fa0b947 pylint 2017-04-10 13:59:31 -04:00
Alex Grintsvayg 8db7c37fa7 exploring dht 2017-04-10 13:45:43 -04:00
Alex Grintsvayg 54c29d4a8d formatting 2017-04-10 13:45:43 -04:00
Alex Grintsvayg a2eb0cad33 delete live lbrylive livestreaming code 2017-04-10 13:45:43 -04:00
Jack Robison 4c122f4ab0 Bump version: 0.9.2rc13 → 0.9.2rc14 2017-04-10 11:04:28 -04:00
Jack Robison a43127fffc add channel_new logging, fix docstring 2017-04-10 11:01:28 -04:00
Jack Robison 66ab1386c5 Bump version: 0.9.2rc12 → 0.9.2rc13 2017-04-10 09:57:55 -04:00
Jack Robison 22381f9427 update lbryum requirement 2017-04-10 09:57:49 -04:00
Jack Robison 5efbafec39 Bump version: 0.9.2rc11 → 0.9.2rc12 2017-04-09 21:51:42 -04:00
Jack Robison 0ff308e3eb Merge pull request #602 from lbryio/fix-file-with-abandoned-claim
fix file_list for files with abandoned claims
2017-04-09 21:51:02 -04:00
Jack Robison 9531bdf396 fix file_list for files with abandoned claims 2017-04-09 21:44:58 -04:00
Jack Robison 978139a631 Bump version: 0.9.2rc10 → 0.9.2rc11 2017-04-09 17:53:55 -04:00
Jack Robison 86117c431b Merge pull request #601 from lbryio/channels-fixes
Channels fixes
2017-04-09 17:53:16 -04:00
Jack Robison 585a17c830 update changelog 2017-04-09 17:49:31 -04:00
Jack Robison 04c119543f fix resolution and file_list bugs 2017-04-09 17:49:31 -04:00
Jack Robison 33c4856f00 update required lbryschema and lbryum versions 2017-04-09 17:49:10 -04:00
Jack Robison ead32f32d8 Bump version: 0.9.2rc9 → 0.9.2rc10 2017-04-08 23:58:02 -04:00
Alex Grintsvayg e54dc9a01d Bump version: 0.9.2rc8 → 0.9.2rc9 2017-04-08 19:24:23 -04:00
Jack Robison c0ccfe2046 Merge pull request #594 from lbryio/use-lbryio-price-api
use lbryio api for price data instead of bittrex
2017-04-07 20:13:55 -04:00
Jack Robison 40374ec202 use lbryio api for price data instead of bittrex 2017-04-07 19:33:13 -04:00
Jack Robison 6ed2c5831e install lbryschema before lbryum 2017-04-07 16:30:36 -04:00
Jack Robison dc0699b929 Merge pull request #593 from lbryio/channels
Channels
2017-04-07 15:55:11 -04:00
Jack Robison eb1bdcc312 update changelog 2017-04-07 14:04:18 -04:00
Jack Robison e9cfbea75f update lbrynet api and tests 2017-04-07 14:04:13 -04:00
Jack Robison ccc94a0db9 update wallet for new lbryum functionality 2017-04-06 20:50:29 -04:00
Jack Robison bcf7a28fc8 update download, handle fee conversion error, use uri instead of name to get() 2017-04-06 20:50:28 -04:00
Jack Robison 1880f64da2 raise default download timeout 2017-04-06 20:50:28 -04:00
Jack Robison 45b3837638 use ClaimDict.source_hash in utils.get_sd_hash 2017-04-06 20:50:28 -04:00
Alex Grintsvayg ee7ca0978f Bump version: 0.9.2rc7 → 0.9.2rc8 2017-04-06 19:14:19 -04:00
Alex Grintsvayg fc3573f823 Bump version: 0.9.2rc6 → 0.9.2rc7 2017-04-06 18:55:07 -04:00
Alex Grintsvayg 8e15eddf9b Bump version: 0.9.2rc5 → 0.9.2rc6 2017-04-06 18:39:49 -04:00
Alex Grintsvayg 880b974b84 Bump version: 0.9.2rc4 → 0.9.2rc5 2017-04-06 18:16:46 -04:00
Alex Grintsvayg 5b78215063 Bump version: 0.9.2rc3 → 0.9.2rc4 2017-04-06 17:50:40 -04:00
Alex Grin bf7882d393 Merge pull request #583 from lbryio/keyerror_fix
fix KeyError bug in dht
2017-04-06 16:09:39 -04:00
Alex Grin 7a798616d6 Update INSTALL.md 2017-04-05 18:34:25 -04:00
Jack Robison 6f909f9654 Merge pull request #586 from lbryio/lbryschema_2
Lbryschema integration
2017-04-04 22:00:07 -04:00
Jack Robison 528ce42821 smart_decode metadata shown in file commands 2017-04-04 21:50:27 -04:00
Kay Kurokawa 931038d478 bug fixes for lbryschema integration 2017-04-04 20:30:51 -04:00
Kay Kurokawa 60d6666abf added changelog 2017-04-04 20:30:51 -04:00
Kay Kurokawa ca041b5dc4 lbryschema integration 2017-04-04 20:30:51 -04:00
Kay Kurokawa f43b38a5ea update INSTALL.md to include protobuf dependencies for lbryschema 2017-04-04 20:27:12 -04:00
Kay Kurokawa 769329c90e add lbryschema to requirements.txt and setup.py 2017-04-04 20:27:12 -04:00
Kay Kurokawa 23596b434a rename update_stream and prevent it from using old metadata 2017-04-04 20:27:12 -04:00
Alex Grintsvayg 22f57f6490 add test to reproduce keyerror 2017-04-04 15:10:46 -04:00
Alex Grintsvayg 99e4f9b00b we dont always want to encode key here. bucket.keyInRange() already does it when necessary 2017-04-04 15:01:59 -04:00
Alex Grintsvayg bee67117c8 changelog 2017-03-31 14:52:56 -04:00
Alex Grintsvayg 502e2227b5 fix KeyError bug in dht 2017-03-31 14:26:19 -04:00
Alex Grintsvayg d3173b157e oops 2017-03-31 14:26:09 -04:00
Alex Grintsvayg c0a40605ad formatting and minor fixes on scripts 2017-03-31 14:23:35 -04:00
Alex Grintsvayg c20ba29c7a move scripts into scripts dir 2017-03-31 14:23:09 -04:00
Alex Grintsvayg 850f51140e formatting 2017-03-31 13:32:43 -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 5e936ef3cc Merge pull request #582 from gaojiuli/patch-1
Update FAQ.md
2017-03-31 10:29:32 -04:00
JiuLi Gao d23e3cf066 Update FAQ.md 2017-03-31 11:13:27 +08:00
Alex Grintsvayg bacc3a0b3a log receive request 2017-03-29 16:56:34 -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 beeaec986a share_debug_info is settable 2017-03-29 11:20:38 -04:00
Alex Grintsvayg e32aa928ac Bump version: 0.9.2rc2 → 0.9.2rc3 2017-03-29 11:10:57 -04:00
Alex Grintsvayg 1a562d70aa config to share debug info with lbry devs 2017-03-29 11:06:07 -04:00
Jeremy Kauffman 8dbadbd75b Merge pull request #573 from lbryio/get-by-claim-id
add claim_id param to get()
2017-03-29 09:41:14 -04:00
Jack Robison 370a91fdaa add claim_id param to get(), remove stream_info param 2017-03-28 22:04:13 -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
Umpei Kay Kurokawa 5dbe2fdcec Merge pull request #571 from lbryio/clarify_pulish_docstring
clarify publish API command docstring
2017-03-28 14:25:10 -04:00
Kay Kurokawa eabf9f1c4a clarify publish API command docstring 2017-03-28 11:48:26 -04:00
Kay Kurokawa bb4bf620f4 remove update_metadata() function 2017-03-27 16:46:41 -04:00
Alex Grintsvayg 7abfbc4c5f Merge branch 'connection_manager_improve_manage'
* connection_manager_improve_manage:
  add changelog
  decrease connection timeout
  connect to multiple peers at once in manage
2017-03-27 15:11:23 -04:00
Kay Kurokawa b2d0c53bbe add changelog 2017-03-27 15:11:15 -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
Alex Grin 23f1cf9c82 Merge pull request #568 from lbryio/get_unused_address
get_unused_address / get_new_address
2017-03-27 13:06:36 -04:00
Kay Kurokawa 26f40b62f9 run gen_api_docs.py script 2017-03-27 12:51:19 -04:00
Kay Kurokawa b15fba9c34 add changelog 2017-03-27 12:45:16 -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 b04455f9c7 Bump version: 0.9.2rc1 → 0.9.2rc2 2017-03-25 10:29:07 -04:00
Alex Grintsvayg b4f5f2068f Merge branch 'fix_file_seed'
* fix_file_seed:
  Ran gen_api_docs.py
  rename file_seed
2017-03-25 10:20:19 -04:00
Kay Kurokawa 948d606268 Ran gen_api_docs.py 2017-03-25 10:20:07 -04:00
Kay Kurokawa f5c533e2f1 rename file_seed 2017-03-25 10:20:07 -04:00
Alex Grintsvayg a0a122f0ef Merge branch 'txrequests'
* txrequests:
  switch to txrequests to marry async requests to twisted
2017-03-24 17:20:43 -04:00
Alex Grintsvayg a2a29fc02c switch to txrequests to marry async requests to twisted 2017-03-24 17:20:33 -04:00
Alex Grintsvayg c9c84784c9 restore http error codes, add some color 2017-03-24 17:19:55 -04:00
Alex Grintsvayg 8fa2524e54 properly handle true/false cli args 2017-03-23 17:44:12 -04:00
Alex Grin 41257c07e6 Merge pull request #561 from lbryio/remove_check_pending
Remove pending_claims logic from Daemon
2017-03-23 16:52:45 -04:00
Kay Kurokawa e7b90055ed remove pending_claims logic from Daemon 2017-03-23 16:44:18 -04:00
Alex Grintsvayg 3f08b5f711 pylint errors 2017-03-23 16:05:26 -04:00
Alex Grintsvayg f0e7f38519 changelog 2017-03-23 15:45:50 -04:00
Alex Grintsvayg 12b428f02d Merge branch 'jsonrpc-fix-errors'
* jsonrpc-fix-errors:
  add todo
  format response and error properly
  fixes, refactors
  changelog
  hack for lbrynet-cli for now
  fix error handling in jsonrpc
2017-03-23 15:44:43 -04:00
Alex Grintsvayg 7708c4a15c add todo 2017-03-23 15:44:23 -04:00
Alex Grintsvayg 9410cd9e77 format response and error properly 2017-03-23 15:37:28 -04:00
Alex Grintsvayg 0c42bc6382 fixes, refactors 2017-03-23 14:11:01 -04:00
Alex Grintsvayg b4364f661c changelog 2017-03-23 11:09:40 -04:00
Alex Grintsvayg 63c71760dd hack for lbrynet-cli for now 2017-03-23 11:09:40 -04:00
Alex Grintsvayg 25d9f008de fix error handling in jsonrpc 2017-03-23 11:09:40 -04:00
Alex Grintsvayg 41fbb1399c Merge branch 'mk_download_dir'
* mk_download_dir:
  make directories in one place when initializing
  create download directory if it doesn't exist
  Fix restart procedure in DaemonControl
  Revert "Bump version: 0.9.2rc1 → 0.9.3rc1"
  Bump version: 0.9.2rc1 → 0.9.3rc1
  Bump version: 0.9.1 → 0.9.2rc1
  update changelog
  handle not being able to decode claim cache file
2017-03-23 11:07:15 -04:00
Kay Kurokawa 2cc2505cfd make directories in one place when initializing 2017-03-23 11:07:03 -04:00
Kay Kurokawa 7fac63a37b create download directory if it doesn't exist 2017-03-23 11:07:03 -04:00
Alex Grin c18c1725c4 Merge pull request #554 from lbryio/fix_restart
Fix restart procedure in DaemonControl
2017-03-22 16:52:55 -04:00
Kay Kurokawa 5e6a742bd3 Fix restart procedure in DaemonControl 2017-03-22 11:48:31 -04:00
Alex Grintsvayg 790baea191 Revert "Bump version: 0.9.2rc1 → 0.9.3rc1"
This reverts commit e8e2a0d353.
2017-03-21 17:24:07 -04:00
Alex Grintsvayg e8e2a0d353 Bump version: 0.9.2rc1 → 0.9.3rc1 2017-03-21 17:12:29 -04:00
Alex Grintsvayg da3ed0756e Bump version: 0.9.1 → 0.9.2rc1 2017-03-21 17:10:51 -04:00
Alex Grin 05f7f5c73c Merge pull request #550 from lbryio/handle-bad-claim-cache-file
Handle failure to read claim cache file
2017-03-21 16:44:37 -04:00
Jack Robison b19e3adadd update changelog 2017-03-21 16:33:17 -04:00
Jack Robison 824f2f1d0f handle not being able to decode claim cache file 2017-03-21 16:32:32 -04:00
Alex Grintsvayg f515583ec4 fix _get_transaction 2017-03-21 12:11:47 -04:00
Jack Robison c1a5806bc0 Merge pull request #532 from lbryio/fix_descriptor_get
Fix broken descriptor_get command
2017-03-20 16:50:19 -04:00
Jack Robison c66225ccf8 Merge branch 'master' into fix_descriptor_get 2017-03-20 16:42:10 -04:00
Alex Grintsvayg 8f3b53197f dont add expected payment when payment rate is 0 2017-03-20 15:37:45 -04:00
Alex Grin 4027733f2c Merge pull request #542 from lbryio/wallet-list
add wallet_list
2017-03-20 15:31:45 -04:00
Alex Grin 3d606b95aa Merge pull request #546 from lbryio/fix_cli_error_msg
format help message properly in case of error in CLI
2017-03-20 15:29:00 -04:00
Kay Kurokawa 85845414b8 format help message properly in case of error in CLI 2017-03-20 13:41:32 -04:00
Jack Robison a95c49bd08 add wallet_list 2017-03-19 10:52:51 -04:00
Alex Grintsvayg c422b5252e Bump version: 0.9.1rc6 → 0.9.1 2017-03-17 18:24:20 -04:00
Alex Grin cb4c93bcd9 Merge pull request #540 from lbryio/fix_getpubkey
fix wallet_public_key API command
2017-03-17 17:49:29 -04:00
Kay Kurokawa 4edd13f4f4 fix wallet_public_key API command 2017-03-17 16:45:34 -04:00
Alex Grintsvayg a4de0056ab Bump version: 0.9.1rc5 → 0.9.1rc6 2017-03-17 13:11:38 -04:00
Alex Grintsvayg ee77bb0670 unused imports 2017-03-17 13:10:40 -04:00
Alex Grintsvayg 6482619fac stupid bug 2017-03-17 13:07:23 -04:00
Alex Grintsvayg b00c20180b Bump version: 0.9.1rc4 → 0.9.1rc5 2017-03-16 17:56:25 -04:00
Kay Kurokawa 001ebd02e3 fix broken descriptor_get command 2017-03-16 17:55:35 -04:00
Alex Grintsvayg 15517732ae add config to disable reflecting on publish 2017-03-16 17:49:24 -04:00
Jeremy Kauffman ebb6813df3 Merge pull request #531 from lbryio/better_jsonrpc_publish
Change publish to take metadata fields as arguments, docstring change
2017-03-16 16:02:49 -04:00
Alex Grintsvayg bfd822782d small fixes 2017-03-16 15:35:54 -04:00
Kay Kurokawa e66a1d3577 add changelog 2017-03-16 14:48:12 -04:00
Kay Kurokawa 61d27f010e Change publish to take metadata fields as arguments, docstring change 2017-03-16 14:38:27 -04:00
Alex Grintsvayg 52d471d660 Bump version: 0.9.1rc3 → 0.9.1rc4 2017-03-15 21:53:36 -04:00
Alex Grintsvayg 33c9a7a098 Bump version: 0.9.1rc2 → 0.9.1rc3 2017-03-15 21:26:08 -04:00
Alex Grintsvayg 8201fc186d Bump version: 0.9.1rc1 → 0.9.1rc2 2017-03-15 19:59:59 -04:00
Alex Grintsvayg 9d7dcf4af7 no more stop-daemon command 2017-03-15 19:58:52 -04:00
Alex Grintsvayg 49b18a1fca minor 2017-03-15 16:33:41 -04:00
Alex Grintsvayg 26d2347812 update docs 2017-03-15 16:31:58 -04:00
Alex Grintsvayg 29dea4901e add --version flag, remove simplejson dependency 2017-03-15 16:24:25 -04:00
Alex Grintsvayg 1c2290dc8e update template 2017-03-15 14:53:00 -04:00
Alex Grintsvayg 8c664a939b add issues template 2017-03-15 14:49:52 -04:00
Alex Grintsvayg 12bc804622 Bump version: 0.9.0 → 0.9.1rc1 2017-03-15 12:34:32 -04:00
Alex Grintsvayg 593e8a94ad no more rc0 2017-03-15 12:32:49 -04:00
Alex Grintsvayg 2c4e4d4526 Revert "Bump version: 0.9.0 → 0.9.1rc0"
This reverts commit 74844f18ad.
2017-03-15 12:31:40 -04:00
Alex Grintsvayg 74844f18ad Bump version: 0.9.0 → 0.9.1rc0 2017-03-15 12:30:52 -04:00
Alex Grintsvayg 93406fe07f Revert "Bump version: 0.9.0 → 0.9.001"
This reverts commit 820e3091bf.
2017-03-15 11:31:36 -04:00
Alex Grintsvayg 820e3091bf Bump version: 0.9.0 → 0.9.001 2017-03-15 11:19:07 -04:00
Alex Grintsvayg c4b65fddac newline after jsonrpc response 2017-03-14 11:11:29 -04:00
Alex Grintsvayg 25dcf592a0 Bump version: 0.9.0rc17 → 0.9.0 2017-03-13 23:16:01 -04:00
Umpei Kay Kurokawa 02bae15b02 Merge pull request #528 from lbryio/api_doc_consis
Make api docstrings consistent
2017-03-13 20:50:45 -04:00
Kay Kurokawa b32b7091ad make api docstrings consistent 2017-03-13 20:43:18 -04:00
Alex Grintsvayg 28e662a53e Revert "Bump version: 0.9.0rc17 → 0.9.1rc0"
This reverts commit a440656a33.
2017-03-13 18:45:14 -04:00
Alex Grintsvayg a440656a33 Bump version: 0.9.0rc17 → 0.9.1rc0 2017-03-13 18:15:37 -04:00
Jack Robison 4e765b265f fix reading description in setup.py 2017-03-13 16:05:54 -04:00
Umpei Kay Kurokawa ec35eb2397 Merge pull request #526 from lbryio/api_doc_string
Daemon API doc string update
2017-03-13 14:18:14 -04:00
Alex Grintsvayg be4e1c99d5 update setup.py 2017-03-13 14:10:33 -04:00
Jeremy Kauffman 031d9c28ed more readme cleanup 2017-03-13 12:14:02 -04:00
Jeremy Kauffman 6d53a582cf running and usage 2017-03-13 12:05:13 -04:00
Jeremy Kauffman 64668d0043 update readme to reflect new packaging 2017-03-13 11:59:12 -04:00
Alex Grintsvayg 92d423aefd fix jsonrpc http headers 2017-03-13 11:54:40 -04:00
Kay Kurokawa 0ec9b6545f edit doc strings and update doc file 2017-03-12 14:45:46 -04:00
Umpei Kay Kurokawa 003b3df378 Merge pull request #525 from lbryio/fix_update
Fix bug in update
2017-03-10 18:39:46 -05:00
Umpei Kay Kurokawa f409d43dcc Merge pull request #524 from lbryio/fix_fee_validator
Fix fee validation in publisher and clarify publish docstring
2017-03-10 18:38:07 -05:00
Kay Kurokawa b2c2edfb12 fixed bug of decimal not being subtractable from float 2017-03-10 18:33:21 -05:00
Kay Kurokawa e7dc841bb7 fix fee validation in publisher and clarify publish docstring 2017-03-10 18:24:32 -05:00
Alex Grintsvayg 2303f88bd4 Bump version: 0.9.0rc16 → 0.9.0rc17 2017-03-10 16:30:28 -05:00
Umpei Kay Kurokawa 7291efac83 Merge pull request #513 from lbryio/fix_api_consistency_lbryum
Integrate more consistent dictionary keys and values from lbryum
2017-03-10 14:12:04 -05:00
Kay Kurokawa 8c61185387 handle decimal encoded string output from lbryum 2017-03-10 12:56:58 -05:00
Kay Kurokawa 371591f96e add changelog 2017-03-10 11:52:12 -05:00
Kay Kurokawa 98d3a4cb46 fix api consistency issues from lbryum 2017-03-10 11:52:12 -05:00
Alex Grintsvayg ab1bdb7eaf Bump version: 0.9.0rc15 → 0.9.0rc16 2017-03-09 15:30:36 -05:00
Umpei Kay Kurokawa 8ef3f81f0c Merge pull request #523 from lbryio/remove_unused_wallet_func
remove unused functions in wallet
2017-03-09 13:15:26 -05:00
Umpei Kay Kurokawa cf56d8fa4a Merge pull request #522 from lbryio/do_not_expose_get_claims_from_tx
Do not expose get_claims_from_tx() from the API
2017-03-09 13:15:13 -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
Kay Kurokawa aef274577f Do not expose get_claims_from_tx() from the API 2017-03-09 11:54:34 -05:00
Jack Robison 5d6ca0aae6 add get_sd_hash to utils 2017-03-09 10:39:25 -05:00
Alex Grintsvayg 9a4230dd96 Bump version: 0.9.0rc14 → 0.9.0rc15 2017-03-09 10:37:44 -05:00
Alex Grintsvayg 3f4a4728e6 fixed my silly mistakes 2017-03-09 07:58:36 -05:00
Alex Grintsvayg 63cb2cf571 raise exceptions, dont yield them 2017-03-08 17:14:31 -05:00
Alex Grintsvayg 54b4b6984e fix jsonrpc help 2017-03-08 17:10:03 -05:00
Kay Kurokawa 98f90a4ad6 fixing minor debugging bug 2017-03-08 15:32:00 -05:00
Jack Robison e29a91b69a fix pylint 2017-03-08 14:19:54 -05:00
Jack Robison fdcc5e6829 fix file delete keyword arg bug 2017-03-08 14:04:40 -05:00
Umpei Kay Kurokawa da99f3f22b Merge pull request #493 from lbryio/filemanager_related_tests
Filemanager related unit tests
2017-03-08 11:53:46 -05:00
Jack Robison 992be881af fix _get_lbry_file return bug 2017-03-08 11:53:24 -05:00
Alex Grintsvayg a0cbd5af33 Merge branch 'less_verbose_loggly'
* less_verbose_loggly:
  make loggly logs less verbose
2017-03-08 11:23:37 -05:00
Alex Grintsvayg 68f5588bd9 make loggly logs less verbose 2017-03-08 11:23:28 -05:00
Umpei Kay Kurokawa 531fa63590 Merge pull request #519 from lbryio/fix_publish_docstring
fix docstring for daemon publish command
2017-03-08 10:50:54 -05:00
Kay Kurokawa 9048244cdc fix docstring for daemon publish command 2017-03-08 10:39:31 -05:00
Jack Robison 74754c9870 Merge pull request #517 from lbryio/fix-filter-by-outpoint
fix filter files by outpoint
2017-03-08 09:40:14 -05:00
Jack Robison a7c2ad470c fix tests 2017-03-08 09:36:32 -05:00
Jack Robison a132496643 fix filter files by outpoint 2017-03-08 09:31:36 -05:00
Kay Kurokawa f600038712 work on unit tests for file management related classes 2017-03-08 09:15:06 -05:00
Kay Kurokawa eae8f8a00e add random_lbry_hash() function to tests.util 2017-03-08 09:15:06 -05:00
Umpei Kay Kurokawa ac33663444 Merge pull request #510 from lbryio/remove_jsonrpc_coms
Removing unuseful/unused commands from daemon API
2017-03-07 21:23:33 -05:00
Kay Kurokawa ba8b7ca090 add changelog 2017-03-07 21:17:06 -05:00
Kay Kurokawa 1aa715c927 remove file_utils import from Daemon 2017-03-07 21:17:06 -05:00
Kay Kurokawa 931925be15 remove start and reveal from file_utils 2017-03-07 21:17:06 -05:00
Kay Kurokawa e2ed9f21d2 delete reveal and open command from api, not needed for electron 2017-03-07 21:17:06 -05:00
Kay Kurokawa e6cd4c9877 removing unuseful/unused commands from daemon API 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
Jack Robison 74cf14df48 Merge pull request #514 from lbryio/fix-compare-outpoint
Add string comparison to ClaimOutpoint
2017-03-07 20:36:44 -05:00
Alex Liebowitz 18c690d801 Add string comparison to ClaimOutpoint 2017-03-07 18:31:05 -05:00
Jack Robison 9e09d1fc38 handle multiple files to delete in file_delete 2017-03-07 18:30:18 -05:00
Jack Robison 454755169a explain get_count_for_stream in file_delete 2017-03-07 18:29:44 -05:00
Jack Robison bc9b990728 return file json from get 2017-03-07 18:29:44 -05:00
Jack Robison 7ad46e70be remove deprecated delete_lbry_file, move file deletion to lbry_file_manager 2017-03-07 18:29:44 -05:00
Jack Robison 4f9b5c4624 refactor file_list, remove deprecated file retrieval functions 2017-03-07 18:29:44 -05:00
Jack Robison 9744287370 change attribute "uri" to "name" 2017-03-07 18:29:44 -05:00
Alex Grintsvayg 59a5a3164f Bump version: 0.9.0rc13 → 0.9.0rc14 2017-03-07 16:03:19 -05:00
Alex Grintsvayg 6fb3313eaf Bump version: 0.9.0rc12 → 0.9.0rc13 2017-03-06 18:15:45 -05:00
Alex Grintsvayg 2bfbae9d4e Bump version: 0.9.0rc11 → 0.9.0rc12 2017-03-06 17:47:50 -05:00
Alex Grin daa0ff036d Merge pull request #507 from lbryio/fix_download_timeout
Fix downloading not timing out properly when unable to download sd blob
2017-03-03 17:14:00 -05:00
Kay Kurokawa d642ba039d Fix downloading not timing out properly when unable to download sd blob 2017-03-03 16:45:25 -05:00
Umpei Kay Kurokawa 9350b9e127 Merge pull request #501 from lbryio/fix_exchange_rate_manager
Improvements to exchange rate manager
2017-03-03 12:54:57 -05:00
Kay Kurokawa 9755e9b11f Improvements to exchange rate manager 2017-03-03 12:50:47 -05:00
Alex Grin a64424f28c Merge pull request #503 from lbryio/exclude_tests_setup
Exclude tests folders in setup.py
2017-03-02 09:04:18 -05:00
Kay Kurokawa eee1acb24a Exclude tests folders in setup.py 2017-02-28 15:03:00 -05:00
Alex Grintsvayg 0e76ca0767 update docs 2017-02-28 12:31:55 -05:00
Alex Liebowitz e8afad7af8 Bump version: 0.9.0rc10 → 0.9.0rc11 2017-02-27 17:49:07 -05:00
Jeremy Kauffman f9642018ae documentation config changes 2017-02-27 17:36:29 -05:00
Umpei Kay Kurokawa 41d96fec00 Merge pull request #500 from lbryio/fix_height_error
Add check in case local height is less than zero
2017-02-27 13:39:49 -05:00
Kay Kurokawa 88f270180c add check in case local height is less than zero 2017-02-27 13:28:58 -05:00
Umpei Kay Kurokawa 76df0e3940 Merge pull request #497 from lbryio/client_protocol_timeout
Adding timeout to ClientProtocol
2017-02-27 13:17:41 -05:00
Kay Kurokawa 7128b6401e adding missing __init__.py file in test folder 2017-02-27 13:10:23 -05:00
Kay Kurokawa 824fbcc25a adding timeout to ClientProtocol 2017-02-27 13:02:35 -05:00
Job Evers‐Meltzer fba91139e3 Merge pull request #499 from lbryio/requirements-vs-setup
cleaner separation between requirements and setup
2017-02-24 06:59:48 -06:00
jobevers 090840ee25 cleaner separation between requirements and setup 2017-02-23 14:18:52 -06:00
jobevers d3d8426430 Bump version: 0.9.0rc9 → 0.9.0rc10 2017-02-22 16:14:40 -06:00
jobevers 40d4fb5641 fix section headers on changelog 2017-02-22 13:13:14 -06:00
jobevers d986fc27f3 update changelog 2017-02-22 12:58:39 -06:00
jobevers 9af1cae249 Bump version: 0.9.0rc8 → 0.9.0rc9 2017-02-22 12:51:10 -06:00
jobevers 056ee2d1ce Stop using bumpversion to bump the changelog
It wasn't working very well so its being replaced by a stand-alone
script
2017-02-21 22:19:07 -06:00
jobevers 301e4ae0fa update version to 0.9.0rc8 2017-02-21 21:03:58 -06:00
jobevers d359949a5c check network exists on jsonrpc_status call 2017-02-21 15:30:36 -06:00
jobevers d4900fd607 add emacs temp files to gitignore 2017-02-21 15:15:52 -06:00
jobevers f596d42ca2 restore needed gmpy binary to build lbrynet 2017-02-21 14:08:34 -06:00
Job Evers‐Meltzer 04b36e2252 Merge pull request #486 from lbryio/electron
Electron
2017-02-21 13:19:55 -06:00
Alex Grintsvayg 2add545ab6 unbreak tests 2017-02-21 13:48:05 -05:00
jobevers 70cf179139 Merge remote-tracking branch 'origin/master' into electron 2017-02-21 12:07:36 -06:00
jobevers b6086a7d6d cleanup changelog 2017-02-21 12:05:50 -06:00
Alex Grintsvayg 62ab4c769d move blocks_behind into blockchain_status 2017-02-21 12:51:15 -05:00
jobevers c920663444 Bump version: 0.8.6 → 0.8.7 2017-02-21 11:36:44 -06:00
jobevers 1d30ae447a Merge branch 'master' into electron 2017-02-21 10:47:28 -06:00
jobevers ff5980dfca fix broken version check 2017-02-21 09:36:08 -06:00
jobevers e4b77a4a0a clean up lint errors 2017-02-21 08:45:12 -06:00
jobevers 666b568eea update version info 2017-02-21 08:39:32 -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
jobevers 847a79f526 use union merge on CHANGELOG.md
http://krlmlr.github.io/using-gitattributes-to-avoid-merge-conflicts/
2017-02-20 21:37:50 -06:00
Umpei Kay Kurokawa 07841a7803 Merge pull request #475 from lbryio/call_later
Adding reactor.callLater as a utils function
2017-02-20 19:15:12 -05:00
jobevers 4e55d674da WIP: update bumpversion 2017-02-20 16:29:12 -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
jobevers 06466db1b0 update readme 2017-02-20 15:12:47 -06:00
Umpei Kay Kurokawa 213a7ab66c Merge pull request #489 from lbryio/fix_dummy_hash_announcer
dummy hash announcer requires hash_queue_size() function
2017-02-20 14:48:28 -05:00
jobevers a1650d7f03 remove update url 2017-02-20 12:55:21 -06:00
Kay Kurokawa 5737d26ffe dummy hash announcer requires hash_queue_size() function 2017-02-20 12:05:12 -05:00
Alex Grintsvayg c85226d5a6 stop showing deprecated commands in cli help 2017-02-20 00:21:16 -05:00
Jack Robison 37b2297fb7 Bump version: 0.8.6rc0 → 0.8.6 2017-02-19 19:50:41 -05:00
Jack Robison 450ac7aa57 Bump version: 0.8.5 → 0.8.6rc0 2017-02-19 19:50:30 -05:00
Jack Robison 68e7c66e3a Merge pull request #495 from lbryio/fix-get
bug fixes in get and get_availability
2017-02-19 19:48:41 -05:00
Jack Robison 55f4e2939a update changelog 2017-02-19 19:37:50 -05:00
Jack Robison b18679af53 debug log 2017-02-19 19:37:50 -05:00
Jack Robison d0b64ef255 don't return blob timeout error from get_availability 2017-02-19 19:37:50 -05:00
Jack Robison e2f97ba0b4 get file by stream hash 2017-02-19 19:37:44 -05:00
Jack Robison c6e614ebec fix get()
-get_file_by_sd_hash raises NoSuchSDHash if there is no file, which
otherwise doesn’t get trapped

-remove unnecessary try/except around _DownloadNameHelper.__init__

-don’t delete self.waiting_on[name]
2017-02-19 19:17:25 -05:00
Jack Robison 76b4b1e939 Update CHANGELOG.md 2017-02-18 14:59:40 -05:00
Jack Robison 29ff39fdc9 Bump version: 0.8.5rc0 → 0.8.5 2017-02-18 14:50:39 -05:00
Jack Robison d2e1eeb61e Bump version: 0.8.4 → 0.8.5rc0 2017-02-18 14:26:57 -05:00
Jack Robison e86bada307 Merge pull request #494 from lbryio/fix-download-button
fix missing download button
2017-02-18 14:23:29 -05:00
Jack Robison 59750843d4 update changelog 2017-02-18 14:16:48 -05:00
Jack Robison ab46a33913 fix missing download button 2017-02-18 14:07:07 -05:00
jobevers 5bf5a7d0b1 Bump version: 0.8.4rc0 → 0.8.4 2017-02-17 14:39:37 -06:00
jobevers 23f2a42372 Bump version: 0.8.3 → 0.8.4rc0 2017-02-17 14:37:21 -06:00
jobevers 14b4c06969 Merge branch 'master' into electron 2017-02-17 09:46:35 -06:00
jobevers 6d4c606abd remove version check also supplies a download url 2017-02-16 21:25:09 -06:00
Job Evers‐Meltzer eb039201e8 Merge pull request #484 from lbryio/add-traceback-to-reported-errors
record traceback in error event
2017-02-16 15:50:26 -06:00
jobevers 723105157f check lbry-electron for releases 2017-02-16 14:18:32 -06:00
jobevers 17d32ca696 remove lbryum version check 2017-02-16 14:18:23 -06:00
jobevers 0eb8e1609f add changelog 2017-02-16 14:13:43 -06:00
jobevers 85390302e2 still more fixes 2017-02-16 14:13:01 -06:00
jobevers 993f2e54f9 more fixes for build 2017-02-16 14:13:01 -06:00
jobevers 87b7e5c742 more fixes for build 2017-02-16 14:13:01 -06:00
jobevers 8b9fef4ed5 forgot to install lbryum 2017-02-16 14:13:01 -06:00
jobevers d4cd8308f1 use build_script for appveyor 2017-02-16 14:13:01 -06:00
jobevers 73eebdb0e3 move to sudoless; install pre-reqs 2017-02-16 14:13:00 -06:00
jobevers 0c30655605 make appveyor build do nothing 2017-02-16 14:13:00 -06:00
jobevers e1455c3a0d add danger; build in venv 2017-02-16 14:13:00 -06:00
jobevers 205fd66a18 don't build lbry package on travis 2017-02-16 14:13:00 -06:00
jobevers 705b65fa3c Update twisted version
This fixes https://github.com/lbryio/lbry/issues/487
2017-02-16 14:13:00 -06:00
Job Evers‐Meltzer fb2823f59e don't need this anymore 2017-02-16 14:13:00 -06:00
jobevers ddfaf51393 simplify setup.py 2017-02-16 14:12:56 -06:00
jobevers f1231bd8e5 remove UI_Manager 2017-02-16 14:11:54 -06:00
jobevers 19aa1eebd5 use lbryum submodule instead 2017-02-16 14:11:36 -06:00
jobevers 24e7b7797c remove packaging 2017-02-16 14:09:59 -06:00
Job Evers-Meltzer caa8f73f7c remove header check 2017-02-16 14:09:43 -06:00
jobevers 0674b48223 record traceback in error event 2017-02-16 13:31:59 -06:00
Job Evers‐Meltzer 5bf75ef139 Merge pull request #404 from lbryio/match-allow-origin
Allow requests that match allowed-origin
2017-02-16 12:02:20 -06:00
Jack Robison 6e310517e0 Merge pull request #469 from lbryio/blob-commands
Blob commands
2017-02-16 12:18:23 -05:00
Job Evers-Meltzer e2db99f7ab allow requests that match allowed-origin 2017-02-16 11:44:23 -05:00
Jack Robison 3151c10556 update changelog 2017-02-16 11:20:11 -05: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 f4217d5593 Merge pull request #485 from lbryio/return-pending-claim-lbry-file
file_get by name for file with pending claim
2017-02-16 11:16:46 -05:00
Jack Robison 8bba5c04db update tests and changelog 2017-02-16 09:12:57 -05:00
Jack Robison 345301a9ee return file with pending claim with get_lbry_file
if a lbry file from the winning claim is in the file manager, return
it. otherwise return a lbry file with a pending claim if one exists.
2017-02-16 09:12:57 -05:00
Jack Robison 0f907a209b add EncryptedFileDownloader.load_file_attributes 2017-02-16 09:12:47 -05:00
Jack Robison 03c0ff8529 Merge pull request #359 from lbryio/no-more-upload-allowed
No more upload_allowed
2017-02-15 22:52:07 -05:00
Jack Robison 80dd02483e Merge branch 'master' into no-more-upload-allowed 2017-02-15 22:39:26 -05:00
jobevers 8452620f99 Bump version: 0.8.3rc3 → 0.8.3 2017-02-15 16:29:40 -06:00
jobevers 287e62b71b bump lbryum version 2017-02-15 12:54:38 -06:00
Job Evers‐Meltzer 934a46a8b6 Merge pull request #452 from lbryio/retry-startup
Retry startup
2017-02-15 08:34:26 -06:00
Job Evers‐Meltzer 23e06ba872 Merge pull request #482 from lbryio/catch-unknown-name-error
Catch unknown name error
2017-02-15 07:54:04 -06:00
jobevers 1fd87b7caa add changelog 2017-02-15 07:09:43 -06:00
jobevers f7c105fd80 fixes 2017-02-15 06:48:59 -06:00
jobevers 9e2cda0cdc remove more upload_allowed arguments 2017-02-15 06:48:58 -06:00
jobevers 4fb5e932e6 fix indentation 2017-02-15 06:48:58 -06:00
jobevers fe4dac8236 change downloader options to data_rate 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 439a840700 Better log in tests on failure 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
jobevers f989814e69 catch Unknownnameerror for resolve_name
Its expected behavior that a name won't resolve so this more
gracefully handles that case
2017-02-14 16:16:22 -06:00
Job Evers‐Meltzer 9f4ccfe7c3 Merge pull request #483 from lbryio/add-traceback
Add traceback to error in EncryptedFileManager
2017-02-14 16:02:14 -06:00
jobevers 520ac9b50a change filemanger setup to inlinecallbacks 2017-02-14 10:27:16 -06:00
jobevers dbb6c6f3a4 remove unused parts of file manager 2017-02-14 10:26:45 -06:00
jobevers 993d606bc6 add logging on downloader start 2017-02-14 10:26:03 -06:00
jobevers ffb48ef287 bugfix: on restore, dont wait for download to finish 2017-02-14 10:25:34 -06:00
jobevers 62fcbc23e3 bugfix: exception needs string interpolation 2017-02-14 10:25:03 -06:00
jobevers a43b726f32 update changelog 2017-02-14 09:29:42 -06:00
jobevers 3bdd33567b whitespace 2017-02-14 09:14:18 -06:00
jobevers 6bdb0280be better log exception in EncryptedFileManager
The error message in #478 is too generic. This wraps the source of the
error in a try/catch and logs the traceback.
2017-02-14 09:11:39 -06:00
jobevers 77746cea5f Bump version: 0.8.3rc2 → 0.8.3rc3 2017-02-14 07:55:54 -06:00
jobevers 25cede0dc3 remove branches restriction on travis builds 2017-02-14 07:55:45 -06:00
jobevers acfe034990 Bump version: 0.8.3rc1 → 0.8.3rc2 2017-02-13 23:34:36 -06:00
jobevers e2021deae1 Bump version: 0.8.3rc0 → 0.8.3rc1 2017-02-13 22:06:57 -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
jobevers a22758d5c7 try building tags too 2017-02-13 16:56:10 -06: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 5831e253cd adding change log 2017-02-13 17:27:52 -05:00
Kay Kurokawa 34f5bc93ae adding immediate announce option to hash announce 2017-02-13 17:27:10 -05:00
Kay Kurokawa aa45b0e121 Fixes for other tests now that BlobManager relies on DHTHashAnnouncer.get_next_announce_time() 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 55445b1bb7 update changelog 2017-02-13 15:27:39 -05:00
Jack Robison 3cc8a4b168 add local and remote heights to blockchain status 2017-02-13 15:14:54 -05:00
Jack Robison 8859c1b0c1 fix claim_abandon 2017-02-13 15:14:54 -05:00
Jack Robison 867275461c feedback from job 2017-02-13 15:14:54 -05:00
Jack Robison 2190f4ac85 refactor GetStream
-convert to inline callbacks

-return more errors than just timeouts

-delete on timeout

-have a more understandable return condition (first data blob having
downloaded)
2017-02-13 15:14:54 -05:00
Jack Robison b51d3a28e3 update changelog 2017-02-13 15:14:54 -05:00
Jack Robison 7720724ec0 reflect lbry_files in looping call in EncryptedFileManager
-remove ManagedEncryptedFileDownloader._reupload

-clean up reflector functions in Daemon, move to reflector.reupload

-check ConnectionLost in reflector client

-close sd blob file handle when it wont be sent (otherwise read handle stays open)

-log reflector sd info

-give reflector client factory a lbry file
2017-02-13 15:13:37 -05:00
Umpei Kay Kurokawa dbd71c93e7 Merge pull request #458 from lbryio/connection_manager_tests
Connection Manager tests and upgrades
2017-02-13 13:55:33 -05:00
Jack Robison d137528f67 convert Daemon._delete_lbry_file to inlineCallbacks 2017-02-13 13:07:27 -05:00
Jack Robison e292abceee convert EncryptedFileManager to use inlineCallbacks 2017-02-13 13:07:27 -05:00
Jack Robison 8de6bd7c7a convert EncryptedFileDownloader to inlineCallbacks 2017-02-13 13:07:27 -05:00
jobevers bb9b221cf6 convert publish_sd_blob to inlineCallback 2017-02-13 13:07:27 -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
Alex Grintsvayg c7106dfc97 reduce loudness of reflector message 2017-02-13 12:12:32 -05:00
Alex Grin 11b1f8c7af Merge pull request #382 from lbryio/silence_socket_error
silence "[Errno 11] Resource temporarily unavailable" error
2017-02-12 20:46:59 -05:00
jobevers f5e6ff0c32 add changelog 2017-02-11 13:05:10 -06:00
jobevers 71123c0de1 add warning log on EWOULDBLOCK 2017-02-11 13:04:36 -06:00
Alex Grintsvayg 35b2e56bd4 silence "[Errno 11] Resource temporarily unavailable" error 2017-02-11 13:04:35 -06:00
jobevers 41abd0a171 Bump version: 0.8.2 → 0.8.3rc0 2017-02-10 14:16:29 -06:00
Jack Robison cea4eca775 update example script 2017-02-09 10:44:29 -05:00
Jack Robison 6b22debb79 Merge pull request #474 from lbryio/fix-update-claim
fix Wallet.claim_name, convert to inlineCallbacks
2017-02-09 10:23:48 -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
Jack Robison 75cc0dcce9 Merge pull request #472 from lbryio/fix-bug-report-slack-key
Fix how the bug report code accesses Slack API key setting
2017-02-09 00:07:52 -05:00
Alex Liebowitz 0e8e489ad6 Fix how the bug report code accesses Slack API key setting
It was trying to access this setting as an attribute, which doesn't
work anymore. (Not sure if this is an API change in conf.settings or
just a bug.)
2017-02-08 23:05:32 -05:00
Jack Robison b03e7e14f3 Merge pull request #471 from lbryio/fix-delete-lbry-file
fix file_delete
2017-02-08 21:04:54 -05:00
Jack Robison e2050b4fc1 fix get_count_for_stream returning [(count, )] instead an int 2017-02-08 20:58:45 -05:00
Jack Robison d1aa69bfa3 Merge pull request #466 from lbryio/fix-untracked-lbry-streams
fix streams in stream_info_manager not being loaded by lbry_file_manager
2017-02-08 19:47:03 -05:00
Jack Robison 7e2456fa69 convert _setup, _check_stream_is_managed, _check_stream_info_manager, and _start_lbry_files to inlineCallbacks
remove unused MissingLBRYFile exception
2017-02-08 19:34:54 -05:00
Jack Robison ecac2ae2ca update changelog 2017-02-08 17:03:53 -05:00
Jack Robison bfc02dd3e5 fix streams in stream_info_manager not being loaded by lbry_file_manager 2017-02-08 17:02:02 -05:00
Jack Robison c527c32e5f Merge pull request #467 from lbryio/fix-reflector-bugs
Fix reflector bugs
2017-02-08 16:40:57 -05:00
Jack Robison 777419b4a9 log traceback on failed blob upload
-move status message on connectionDone to client, indicate if blobs
were sent or not (and how many blobs reflector still needs, if any)

-only try uploading failed blob once after first failure, to prevent
indefinite retries
2017-02-08 16:18:34 -05:00
Jack Robison 832a32474f update changelog 2017-02-08 14:46:18 -05:00
Jack Robison f2ddc9bd98 fix recursion depth bug upon failed blob 2017-02-08 14:28:30 -05:00
Jack Robison d053db8dfd add uri to stream reflector for better logging 2017-02-08 14:28:16 -05:00
Jack Robison a58a81a841 stopProducing in reflector client file_sender when uploading is done
this fixes exceptions.ValueError: I/O operation on closed file in
twisted.protocols.basic.ResumeProducing
2017-02-08 14:09:03 -05:00
jobevers df40c7fb76 bumpversion updates the changelog 2017-02-08 01:30:37 -06:00
jobevers ef65d8dd1c fix because the danger.systems code example was wrong 2017-02-07 23:08:35 -06:00
Job Evers‐Meltzer a8780f03a8 Add changelog (#463)
Add changelog and danger checks
2017-02-07 21:34:15 -06:00
Jeremy Kauffman 61e78c1b69 pip install must be run with upgrade flag 2017-02-07 20:51:10 -05:00
Jack Robison a167beaad1 Merge pull request #457 from lbryio/stream-availability
Reflector v2
2017-02-06 16:05:14 -05:00
Jack Robison 4c76e1b98f add blob reflector and v1 tests 2017-02-06 15:56:00 -05:00
Jack Robison f614a13db4 update documentation 2017-02-06 15:56:00 -05:00
Jack Robison 6fae07d29e reflector v2
-add {‘sd_blob_hash’: …, ‘sd_blob_size ‘: …} query type with
{‘send_sd_blob’: True/False, ‘needed_blobs’: []} response

this allows the reflector client to know how much of a stream reflector
already has covered, as to minimize the number of subsequent requests
and prevent streams from being partially reflected

-remove empty {} request
2017-02-06 15:55:46 -05:00
Jack Robison 2126f69c93 use only DBEncryptedFileMetadataManager in Daemon
-fix Daemon.stream_info_manager and Daemon.lbry_file_metadata_manager
being different
2017-02-06 13:15:50 -05:00
Jack Robison 6f0581104a Merge pull request #408 from lbryio/non-blocking-update-check
non-blocking version check
2017-02-05 15:44:29 -05:00
Alex Grintsvayg 47c92f04d2 urihandler takes you to show, not watch 2017-02-03 13:34:16 -05:00
Jack Robison 06be60e3a3 Merge pull request #406 from lbryio/installation-id
add installation id, re-initialize lbryid on each start
2017-02-02 11:37:31 -05:00
Jack Robison 45a6228b58 fix threaded lbryum check 2017-02-02 11:31:31 -05:00
jobevers 773cbe3ace Bump version: 0.8.1 → 0.8.2 2017-02-02 07:43:28 -08:00
Jack Robison c6648ff6bc add installation id, re-initialize lbryid on each start 2017-02-02 10:23:17 -05:00
Jack Robison f737b3aaf7 non-blocking version check
this fixes a bug where if github is down the app will fail to start.

-check for new version every 30 min instead of every 12 hours

-check connection problems every 30 seconds instead of every second
2017-02-02 10:18:09 -05:00
Job Evers‐Meltzer 41d937d1b4 Merge pull request #461 from lbryio/named-parameters
Fixes for named parameter changes on api
2017-02-01 20:56:01 -08:00
jobevers 8e349f17c1 fixes for named parameter changes on api 2017-02-01 20:47:53 -08:00
jobevers 4ab5ace668 Bump version: 0.8.1rc0 → 0.8.1 2017-02-01 15:57:05 -08:00
Job Evers‐Meltzer f46ae75f73 Merge pull request #459 from lbryio/lbryum-version
require minimum version for lbryum
2017-02-01 15:56:32 -08:00
jobevers 61c5a5b2a4 require minimum version for lbryum 2017-02-01 15:08:31 -08:00
Job Evers‐Meltzer 2c137a99d1 Merge pull request #453 from lbryio/add-details-to-error-event
Add details to error event
2017-02-01 14:23:26 -08:00
Job Evers‐Meltzer d1ed8a769a Merge pull request #450 from lbryio/block-too-deep
Fix #449: Block to deep error
2017-02-01 13:45:12 -08:00
jobevers 4bb3e2a154 remove is_lagging wallet attribute 2017-02-01 12:13:43 -08:00
Kay Kurokawa a5e8c561e4 Revert "adding connection manager tests, and modifying connection manager to be testeable"
This reverts commit 7b6e233d22, as it was an accidental push to master
2017-02-01 11:59:36 -05:00
Kay Kurokawa 7b6e233d22 adding connection manager tests, and modifying connection manager to be testeable 2017-02-01 11:52:16 -05:00
Job Evers‐Meltzer ac8a63bc33 Merge pull request #455 from lbryio/better-defaults
Change default behavior with daemon cmdline args
2017-01-31 10:13:18 -08:00
Alex Grintsvayg 15ebc39f95 Merge branch 'nicer_error_output'
* nicer_error_output:
  nicer error output
2017-01-31 10:38:19 -05:00
Alex Grintsvayg 46cb6b204a nicer error output 2017-01-31 10:38:07 -05:00
Alex Grin b219806959 Merge pull request #448 from lbryio/jsonrpc_params_in_function_signature
explicitly list jsonrpc params in function signature. add jsonrpc tests
2017-01-30 16:34:50 -05:00
jobevers 8fc6feb316 log to console by default 2017-01-30 12:08:32 -08:00
jobevers 7377158631 change no-launch to launchui 2017-01-30 12:04:07 -08:00
Alex Grintsvayg 86ba7ffd5c explicitly list jsonrpc params in function signature. add jsonrpc tests 2017-01-30 09:58:28 -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:
https://github.com/lbryio/lbrycrd/blob/1b896ae75b0fc7081ab9e4a1b7d45c94dcd73cbd/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
jobevers 565f26bdad switch error event to use log record and add more details 2017-01-30 09:30:46 -08:00
jobevers b7478ba817 replace send_error with log.error 2017-01-30 09:30:46 -08:00
jobevers 1c92b5d2ea retry startup 2017-01-30 09:25:44 -08:00
Job Evers‐Meltzer b744a54340 Merge pull request #451 from lbryio/move-uri-handler
move urihandler out of packaging dir
2017-01-30 09:22:03 -08:00
Jeremy Kauffman 8805d1d0cf a joke I couldn't resist 2017-01-29 15:45:11 -05:00
jobevers b674e5c57a move urihandler out of packaging dir 2017-01-28 22:09:40 -08:00
Job Evers‐Meltzer 139af85b52 Merge pull request #445 from lbryio/retry-get
Retry the get call three times before failing
2017-01-27 10:08:25 -06:00
Alex Grintsvayg ee0f7375d6 fix install bug 2017-01-26 16:48:34 -05: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
Umpei Kay Kurokawa f54d42b8fa Merge pull request #441 from lbryio/connection_manager_logging
Better Connection manager and Client Protocol logging
2017-01-26 15:11:56 -05:00
jobevers 3dc1a523cf retry the get call three times before failing 2017-01-26 14:09:54 -06: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 eebf32362a add unit tests for wallet interface changes to balances 2017-01-26 11:41:39 -05:00
Kay Kurokawa 0e864f5df1 Update interface for wallet balance 2017-01-26 11:41:27 -05:00
Jack Robison 854dea797e Bump version: 0.8.0 → 0.8.1rc0 2017-01-25 17:49:52 -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 74b4e4508a Merge pull request #440 from lbryio/reflect-missing-blobs
Reflect missing blobs
2017-01-25 15:33:14 -05:00
Jack Robison 74a872d763 fix pylint errors 2017-01-25 13:10:38 -05:00
Jack Robison 3b65f5962c disable verbose twisted logs 2017-01-25 13:04:02 -05:00
Jack Robison 5fa2dfeca7 try reflecting all the blobs in a stream
previously only the sd blob was reflected, if the server indicated it
needed the blob then the rest of the stream would follow. this allowed
for many streams to be partially reflected, where for whatever reason
the connection was broken before the full upload was completed. this
meant that on a subsequent run, the client would falsely believe
reflector had the whole stream when it actually only had some portion
of it.

this solution isn’t ideal, I’m most of the way done with a better one,
but this can be deployed now.
2017-01-25 13:03:48 -05:00
Job Evers-Meltzer 7cac8dad7a remove header check 2017-01-25 01:12:56 -05:00
Job Evers‐Meltzer b80a1f66da Merge pull request #439 from lbryio/readme-dmg
Update readme to refer to lbry.dmg instead of lbry.pkg
2017-01-24 17:30:10 -05:00
alexliebowitz 20da97de6a Update readme to refer to lbry.dmg instead of lbry.pkg 2017-01-24 17:29:08 -05:00
Job Evers-Meltzer bb9d3bff74 Bump version: 0.8.0rc2 → 0.8.0 2017-01-24 11:56:36 -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
Alex Grin db1abd8cca Merge pull request #433 from lbryio/kauffj-patch-1
Clarify how to install, verify install, and make a change
2017-01-24 11:52:23 -05:00
Alex Grin 18a0b07181 Update INSTALL.md 2017-01-24 11:52:02 -05:00
Alex Grin 8fd7489d99 Update INSTALL.md 2017-01-24 11:51:12 -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
Job Evers-Meltzer dc57b62157 add script to run tests 2017-01-21 16:04:38 -06:00
Jeremy Kauffman c71ac5b535 Ignore the folder we recommend to use for virtual-env in INSTALL.md 2017-01-21 11:19:44 -05:00
Jeremy Kauffman 5a467f55ba easier to read 2017-01-21 11:17:05 -05:00
Jeremy Kauffman 9a24bddead amend/clarify install instructions 2017-01-21 11:13:55 -05:00
Alex Liebowitz d3a63c38fc Fix pylint errors 2017-01-20 22:36:31 -05:00
Alex Liebowitz 08aa024499 Use inlineCallbacks for jsonrpc_open() and jsonrpc_reveal() 2017-01-20 22:29:27 -05:00
Alex Liebowitz 5db1a4d328 Refactor and update open() and reveal() RPC methods
- Both methods now take an SD hash instead of a path (more logical API
   and avoids potential security problems)
 - Moves the core logic into functions on a new module,
   lbry.core.file_utils
 - Adds reveal support for Windows
2017-01-20 22:29:27 -05:00
Alex Liebowitz e95adecd41 Rename jsonrpc_open_file to jsonrpc_open 2017-01-20 22:29:27 -05:00
Alex Liebowitz 8b68a752ed Add file_utils module 2017-01-20 22:29:27 -05:00
Alex Liebowitz 51a5510b38 Add open_file() RPC method 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 e37fbc4fdb Merge pull request #430 from lbryio/more-verified-time
missed another verified time check
2017-01-20 13:34:43 -06:00
Job Evers-Meltzer 3e774fc158 missed another verified time check 2017-01-20 18:47:53 +00:00
Alex Grintsvayg c62ee6bb0c fix loading settings from env 2017-01-20 13:38:49 -05:00
Alex Grintsvayg 3aea476014 ignore invalid config file keys 2017-01-20 12:39:59 -05:00
Job Evers-Meltzer 8c5f7a9849 fix missing arg in get_blob 2017-01-20 11:35:34 -06:00
Jeremy Kauffman 6bc3e8a3f4 fix typo in readme link 2017-01-20 12:27:19 -05: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 91d673a539 Merge pull request #423 from lbryio/check-wallet-on-status
Safegaurd against there not being a wallet on status call
2017-01-18 10:10:52 -06:00
Job Evers-Meltzer 851ab7ba28 Safegaurd against there not being a wallet on status call
Also switch status call to an inlineCallback
2017-01-18 09:36:01 -06:00
Job Evers-Meltzer 7bc1bc487f Bump version: 0.8.0rc1 → 0.8.0rc2 2017-01-17 22:08:34 -06:00
Job Evers‐Meltzer 05d50c1821 Merge pull request #420 from lbryio/fix-watch-resource
fix resource needed for watch
2017-01-17 22:07:06 -06:00
Job Evers‐Meltzer 40b6476cf7 Merge pull request #421 from lbryio/add-back-id
Add back id
2017-01-17 22:06:56 -06:00
Job Evers-Meltzer 13bfcb3561 fix missing id_ parameter to _render_error 2017-01-17 20:01:28 -06:00
Job Evers-Meltzer 1a850b0256 log exception on callback failure 2017-01-17 20:01:04 -06:00
Job Evers-Meltzer 78b0f923f4 fix resource needed for watch 2017-01-17 19:26:09 -06:00
Job Evers-Meltzer 1aa7981ab1 download blob script update 2017-01-17 17:11:14 -06:00
Alex Grin 17d9c0ab97 Merge pull request #417 from lbryio/refactor_settings
refactor conf.settings
2017-01-17 14:53:01 -05:00
Umpei Kay Kurokawa 8d1404bd1e Merge pull request #413 from lbryio/fix_fee_out
fix log message in publisher
2017-01-17 14:05:57 -05:00
Alex Grintsvayg 4634179a7e more long lines 2017-01-17 12:51:33 -05:00
Alex Grintsvayg 23872c77e9 fix long lines 2017-01-17 12:31:48 -05:00
Alex Grintsvayg cac8267e85 updates, more refactoring for greater clarity 2017-01-17 12:29:09 -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 8a026071eb Bump version: 0.8.0rc0 → 0.8.0rc1 2017-01-16 12:01:35 -05:00
Job Evers‐Meltzer 9fb1cd0944 Merge pull request #412 from lbryio/revert-405-no-more-osx-on-travis
Revert "Remove osx from travis build matrix"
2017-01-16 10:53:56 -06:00
Job Evers‐Meltzer a338d1f0e1 Revert "Remove osx from travis build matrix" 2017-01-16 11:52:19 -05:00
Job Evers-Meltzer 8a338b37b2 Bump version: 0.7.12 → 0.8.0rc0 2017-01-13 14:15:01 -06: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
Job Evers‐Meltzer ddf24de16d Merge pull request #407 from lbryio/handle-closed-api-requests-rebase
handle dropped api requests
2017-01-13 13:33:42 -06:00
Alex Grintsvayg 8277df1034 minor nits 2017-01-13 12:26:37 -05:00
Job Evers‐Meltzer 3bed768d10 Merge pull request #402 from lbryio/fix-needed-blobs
Bug Fix for ConnectionManager
2017-01-13 10:42:50 -06:00
Jack Robison e03bba0b62 handle dropped api requests 2017-01-13 10:41:59 -06:00
Job Evers-Meltzer e61260a263 merge with change stop to be an inlineCallback 2017-01-13 08:24:07 -06:00
Job Evers-Meltzer a9261b2032 change stop to be an inlineCallback 2017-01-13 08:24:07 -06:00
Job Evers-Meltzer 9366a6e561 bug fix: reset blob_requester between start/stop 2017-01-13 08:24:06 -06:00
Job Evers-Meltzer 488c04543d add TODO comment 2017-01-13 08:24:06 -06: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 1151019186 Improve downloader error handling
Instead of having an error cause a timeout, send
the error directly to the callback
2017-01-13 08:24:05 -06:00
Job Evers-Meltzer 8075ced1af bug fix for file_seed
cannot return a deferred in inlineCallbacks, it must be a value
2017-01-13 08:23:52 -06:00
Job Evers-Meltzer 1b2c46e224 make _download_manager private 2017-01-13 08:19:23 -06:00
Alex Grin 7f6e9fff30 Merge pull request #403 from lbryio/fix-result
bug fix: jsonrpc methods no longer have a 'result' key
2017-01-12 12:19:27 -05:00
Job Evers‐Meltzer bb1b7b66f7 Merge pull request #405 from lbryio/no-more-osx-on-travis
Remove osx from travis build matrix
2017-01-12 11:14:54 -06:00
Job Evers-Meltzer deae84a563 remove osx from travis build matrix 2017-01-12 10:45:31 -06:00
Job Evers-Meltzer 20f113d3da bug fix: jsonrpc methods no longer have a 'result' key 2017-01-12 09:55:38 -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 d100a24a29 Merge branch 'api_docs'
* api_docs:
  api doc generator
2017-01-11 17:30:26 -05:00
Alex Grintsvayg d06211015d api doc generator 2017-01-11 17:30:16 -05:00
Alex Grintsvayg 93ff4f63b5 Merge branch 'rename_api_methods'
* rename_api_methods:
  updates based on job's comments
  appveyor is a line-length nazi
  detect authentication error and warn accordingly
  remove authjsonrpc subhandlers. we dont use them
  rpc works with authentication
  restore one deprecated method (for now)
  incorporate job's changes
  remove return codes that are not being used
  make sure deprecated methods still return results
  better cli help
  remove extraneous ellipses in messages
  rename api endpoints
2017-01-11 16:36:59 -05:00
Alex Grintsvayg 86aa8e1de0 updates based on job's comments 2017-01-11 15:39:28 -05:00
Alex Grintsvayg 495a48add1 appveyor is a line-length nazi 2017-01-11 15:39:28 -05:00
Alex Grintsvayg a6457d2c0a detect authentication error and warn accordingly 2017-01-11 15:39:28 -05:00
Alex Grintsvayg 5c429e15bd remove authjsonrpc subhandlers. we dont use them 2017-01-11 15:39:28 -05:00
Alex Grintsvayg 05725e0dc9 rpc works with authentication 2017-01-11 15:39:28 -05:00
Alex Grintsvayg 53acb2d9cd restore one deprecated method (for now) 2017-01-11 15:39:28 -05:00
Alex Grintsvayg f050337dbc incorporate job's changes 2017-01-11 15:39:28 -05:00
Alex Grintsvayg 6d7b09a3aa remove return codes that are not being used 2017-01-11 15:39:28 -05:00
Alex Grintsvayg dd87aa3ce6 make sure deprecated methods still return results 2017-01-11 15:39:28 -05:00
Alex Grintsvayg b602b09ca3 better cli help 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
Umpei Kay Kurokawa a67aab0797 Merge pull request #393 from lbryio/fix_github_version_request
Fix obtaining version from github
2017-01-10 20:42:08 -05:00
Kay Kurokawa 52500bfbf5 use latest release for getting lbryum version, add a timeout when requesting lbrynet/lbryum version 2017-01-10 12:55:47 -05:00
Alex Grin f4790a46ee Update README.md 2017-01-09 18:07:39 -05:00
Jeremy Kauffman fd5b4f403a improvements to readme and install instructions (#396)
* improvements to readme and install instructions

* Update README.md

* Update INSTALL.md
2017-01-09 18:01:50 -05: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
Job Evers‐Meltzer d32bb9270a Merge pull request #376 from lbryio/add-id
add id field to jsonrpc response
2017-01-09 15:23:24 -06:00
Kay Kurokawa 9e7b69f4a0 fix publish output 2017-01-09 14:35:29 -05:00
Jeremy Kauffman 3c60b35e2e Merge pull request #384 from lbryio/ubuntu_install_paths
fix linux packaging to work with new install paths
2017-01-06 14:58:29 -05:00
Job Evers‐Meltzer 69c0da695b Merge pull request #387 from lbryio/wallet-whitespace
cleanup whitespace for increased readability
2017-01-06 08:20:06 -06:00
Job Evers-Meltzer 68887d145f cleanup whitespace for increased readability 2017-01-06 08:04:18 -06:00
Job Evers-Meltzer f37808859f ensure hash_announcer exists before announcing 2017-01-06 08:00:22 -06:00
Jeremy Kauffman 14c835b41e fix linux packaging to work with new install paths 2017-01-04 09:51:15 -05:00
Job Evers abc122f77b Don't send log messages to loggly in dev mode 2017-01-03 22:17:44 -06:00
Job Evers 0ababb7f3b Route twisted logging messages to the python stdlib logger 2017-01-03 22:16:57 -06:00
Job Evers-Meltzer 30af8a0e20 Bump version: 0.7.12rc4 → 0.7.12 2017-01-03 21:09:25 -06:00
Job Evers‐Meltzer 389fc67d51 Merge pull request #381 from lbryio/fix-watch
Fix watch
2017-01-03 21:08:33 -06:00
Job Evers c2fc15160f Fix watch
I changed the _download_name return type without realizing that
it was also used by the watch endpoint.  This switches the endpoint
to go through get so that watches can be tracked just like downloads
2017-01-03 18:08:31 -06:00
Job Evers-Meltzer 40d4f5a292 Bump version: 0.7.12rc3 → 0.7.12rc4 2017-01-03 15:29:20 -06:00
Job Evers‐Meltzer 38e6b4e6c6 Merge pull request #379 from lbryio/open-ui-asap
open the ui as soon as possible
2017-01-03 15:28:50 -06:00
Jack 3541625825 move launch into own function 2017-01-03 15:51:42 -05:00
Job Evers‐Meltzer f8f83fccf1 Merge pull request #375 from lbryio/fix-stop-errors
Fix stop errors
2017-01-03 14:13:24 -06:00
Job Evers‐Meltzer b3175af16f Merge pull request #374 from lbryio/allow-jsonrpc-v2
upgrade txJson-RCP to 0.5
2017-01-03 14:11:48 -06:00
Jack 5f8a06443c open the ui as soon as UIManager finishes setting itself up 2017-01-03 11:44:29 -05:00
Job Evers 4e0194d576 add id field to jsonrpc response 2017-01-02 20:12:37 -06:00
Job Evers 16fc416d88 more informative name error 2017-01-02 19:47:34 -06:00
Job Evers 6faee910de Raise exception if lbry_file can't be found 2017-01-02 19:46:40 -06:00
Job Evers f7308beee9 upgrade txJson-RCP to 0.5
The older version we were running didn't support jsonrpc v2 for
error codes, which both the command line client and ui client
were expecting.
2017-01-02 19:15:25 -06:00
Job Evers-Meltzer 5233dc303e Bump version: 0.7.12rc2 → 0.7.12rc3 2017-01-02 17:18:46 -06:00
Job Evers‐Meltzer 3d0913ca94 Merge pull request #373 from lbryio/bundled-version
Set ui_version for Bundled UI
2017-01-02 17:17:31 -06:00
Job Evers‐Meltzer c37bb0d1ed Merge pull request #372 from lbryio/fix-stop
fix the stop script
2017-01-02 16:50:34 -06:00
Job Evers-Meltzer a4a9a2b0b0 fix the stop script 2017-01-02 16:40:50 -06:00
Job Evers-Meltzer 9e320921a9 Bump version: 0.7.12rc1 → 0.7.12rc2 2017-01-02 16:12:35 -06:00
Jack Robison 21602dc5a1 Merge pull request #368 from lbryio/bug-report
bug reports sent to slack
2017-01-02 16:24:57 -05:00
Jack 2cf08fda2d use urllib for loggly url formatting 2017-01-02 16:09:28 -05:00
Jack c2c7d2b327 send bug reports to slack 2017-01-02 14:52:24 -05:00
Job Evers‐Meltzer 585f802a91 Merge pull request #370 from lbryio/fail-wallet
Stop eating wallet connection error
2017-01-02 12:02:35 -06:00
Job Evers-Meltzer 26cf04e0c1 refactor requirements parsing 2017-01-02 12:01:55 -06:00
Job Evers-Meltzer 3bb8f4ac21 set ui_version for bundled ui 2017-01-02 12:01:55 -06:00
Job Evers‐Meltzer 2afc4c25a2 Merge pull request #371 from lbryio/fix-settings
Fix settings
2017-01-01 11:24:25 -06:00
Job Evers-Meltzer a5c25ff887 Stop eating wallet connection error 2016-12-30 22:34:08 -06:00
Job Evers-Meltzer e823bb2012 Bug fix in auth.server
Fixes a mistake in fa8190356a,
where an usage of _log_and_render_error was overlooked
2016-12-30 16:48:44 -06:00
Job Evers-Meltzer eec25791a5 fix lbryid in settings dict
The lbryid is stored as raw bytes, need to hexlify
it before sending it over to the client
2016-12-30 16:47:50 -06:00
Job Evers-Meltzer 18a47a048a Bump version: 0.7.12rc0 → 0.7.12rc1 2016-12-30 15:42:13 -06:00
Job Evers‐Meltzer 6936dbd588 Merge pull request #369 from lbryio/track-errors
track errors in analytics
2016-12-30 15:39:41 -06:00
Job Evers‐Meltzer 621530b3b8 Merge pull request #367 from lbryio/analytics-on-get
Analytics on get
2016-12-30 15:39:06 -06:00
Job Evers-Meltzer 123fda1844 track errors in analytics 2016-12-30 15:09:34 -06:00
Job Evers-Meltzer 1299c23bcc fix cli 2016-12-30 15:07:24 -06:00
Job Evers-Meltzer 1747f53276 Remove _set_events
Function was removed in 101985ca11,
but wasn't removed from setup()
2016-12-30 14:42:03 -06:00
Job Evers-Meltzer 669a567545 add id to link download events 2016-12-30 13:35:16 -06:00
Job Evers-Meltzer 6bdc9069c9 on get, first check if we already have the name 2016-12-30 13:35:16 -06:00
Job Evers-Meltzer ad1e2650e3 add events for downloading stages 2016-12-30 13:31:20 -06:00
Job Evers-Meltzer 1bf1b7624c more inlineCallback cleanup 2016-12-30 13:28:38 -06:00
Job Evers-Meltzer 0b53fde352 refactor connectionmanager to use inlineCallbacks 2016-12-30 13:28:34 -06:00
Job Evers-Meltzer 4eb10b56c1 small changes 2016-12-30 13:27:17 -06:00
Job Evers-Meltzer 227323b7a4 convert more to inlineCallbacks 2016-12-30 13:27:16 -06:00
Job Evers-Meltzer 1256beea96 remove blob_requester from DownloadManager 2016-12-30 13:27:16 -06:00
Job Evers-Meltzer 01cc4f28e0 Refactor jsonrpc_get
Convert some of the calls to inlineCallbacks, which
allowed the code to be cleaned up and made more clear
2016-12-30 13:27:12 -06:00
Job Evers-Meltzer 689ac431d3 bug fix in log.fail()
The value of the callback needs to be returned.  In particular,
this allows the error to be passed along.
2016-12-30 13:22:06 -06:00
Job Evers-Meltzer ccfb1f3921 refactor: name private/public variables 2016-12-30 13:22:06 -06:00
Job Evers‐Meltzer cc008766ec Merge pull request #361 from lbryio/analytics-on-startup
Analytics on startup
2016-12-30 13:21:14 -06:00
Job Evers-Meltzer 4b1530b554 fix typo in osx build script 2016-12-30 13:05:19 -06:00
Job Evers-Meltzer 5eecae8889 record server startup event as part of start_server 2016-12-30 13:05:19 -06:00
Job Evers-Meltzer 5aa10031bc Move log_support import earlier
Since log_support configures the logging class, it needs
to be early in the initialization process.
2016-12-30 13:05:19 -06:00
Job Evers-Meltzer 52010ade41 add docstring 2016-12-30 13:05:19 -06:00
Job Evers-Meltzer 101985ca11 Remove analytics setup code from daemon
Now that lbryid and session_id are available at startup
we don't need to reconfigure the analytics manager
inside the daemon
2016-12-30 13:05:19 -06:00
Job Evers-Meltzer 8f61fb3fc4 Initialize settings, along with lbryid and session_id on startup 2016-12-30 13:05:19 -06:00
Job Evers-Meltzer 39b2e44492 Replace settings with conf.settings
In the next commit I change conf.settings to be initialized
at runtime instead of load time and so any import of
`from lbrynet.conf import settings` will be and stay None if
it happens before the initialization.
2016-12-30 13:05:18 -06:00
Job Evers-Meltzer 26bc6d05a0 Consistently use lbryid over lbry_id variable name 2016-12-30 12:40:36 -06:00
Job Evers‐Meltzer 47f71fd363 Merge pull request #360 from lbryio/store-offer
Only store the offer explicitly when its sent
2016-12-30 12:15:06 -06:00
Job Evers‐Meltzer 4574e3317c Merge pull request #363 from lbryio/wallet-storage
Wallet storage
2016-12-30 11:41:38 -06:00
Job Evers‐Meltzer b59c098d58 Merge pull request #364 from lbryio/fix_serverprotocol
Fix bug in server protocol
2016-12-30 11:28:08 -06:00
Job Evers-Meltzer 22ff87b885 fix tests for new query_handler_factory format 2016-12-30 09:07:24 -06:00
Job Evers‐Meltzer 42edf49468 Merge pull request #365 from lbryio/fix-set-settings-typo
Fix typo in set_settings API method
2016-12-30 08:22:14 -06:00
Alex Liebowitz da0b4e9a1a Fix typo in set_settings API method 2016-12-30 05:00:28 -05:00
Kay Kurokawa 7d5dd1ff51 fix bug in ServerProtocol 2016-12-28 14:34:38 -05:00
Umpei Kay Kurokawa d1ccac1b04 Merge pull request #362 from lbryio/fix_getvalueforname_bug
Fixing get_value_for_name bug
2016-12-28 13:35:48 -05:00
Job Evers‐Meltzer a289886365 Merge pull request #350 from lbryio/reflector-test
scripts to test reflector
2016-12-28 11:29:14 -06:00
Job Evers-Meltzer 2c7fc3fb46 switch startup sequence to use inlineCallbacks
This cleans up the process, makes it more readable,
and better surfaces errors.
2016-12-28 11:21:10 -06:00
Job Evers-Meltzer fc24d9b5aa pull out metadata storage from the wallet 2016-12-28 11:18:55 -06:00
Kay Kurokawa da366495b0 fixing get_value_for_name bug 2016-12-28 10:37:53 -05:00
Umpei Kay Kurokawa 552ed77882 Merge pull request #358 from lbryio/fix_wallet_init_3
Fix wallet initialization
2016-12-22 12:12:27 -05:00
Jack Robison c53e0baca6 Merge pull request #357 from lbryio/no-brew-error
Fix error on brew when package is already installed
2016-12-21 22:43:39 -05:00
Jack Robison aa3353ae49 Merge pull request #345 from lbryio/better-dht-shutdown
Better dht shutdown.
2016-12-21 17:15:17 -05:00
Job Evers‐Meltzer 521ad57b61 Merge pull request #353 from lbryio/update-six
allow more recent versions of six
2016-12-21 12:20:11 -08:00
Job Evers-Meltzer f62456bb68 allow more recent versions of six 2016-12-20 18:06:59 -08:00
Job Evers-Meltzer f7864e8cb7 Only store the offer explicitly when its sent
Ran into a situation where I was recieving an offer response without
something in protocol_offers. I think this was because
get_and_set_rate doesn't always populate that dictionary.

Worried that there still might be issues if the connection is
unreliable: if a response comes in twice it will error or
if a second offer is made without a response to the first
there will be an error.
2016-12-20 10:37:42 -08:00
Kay Kurokawa 1690e71ad1 setup Commands class on run, instead of on initialization 2016-12-19 19:15:59 -05:00
Kay Kurokawa 7d02e7d370 changing wallet initialization order 2016-12-19 19:15:50 -05:00
Umpei Kay Kurokawa 7404b127bf Merge pull request #354 from lbryio/fix_publisher_bug
Fixing bug in publisher
2016-12-19 19:12:00 -05:00
Kay Kurokawa 10810226ff Fixing bug in publisher 2016-12-19 18:41:35 -05:00
Job Evers-Meltzer a2497e0854 Fix error on brew when package is already installed 2016-12-19 15:39:06 -08:00
Jack Robison c0f22decd7 Merge pull request #347 from lbryio/log-error-on-lbry-files
Log failure when attempting to get_lbry_files
2016-12-19 16:22:37 -05:00
Jack Robison 3da82ce895 Merge pull request #348 from lbryio/remove-old-settings
remove unqlite requirement and old Settings.py
2016-12-19 14:38:31 -05:00
Jack ba90fb3349 fix os x build 2016-12-19 14:10:37 -05:00
Jack 618d0ebd5b newline 2016-12-19 13:40:33 -05:00
Jack f301741807 re-use lbryid 2016-12-19 13:27:45 -05:00
Jack 0044d6cf75 BlobAvailabilityTracker.sample bug, remove whitespace 2016-12-17 20:05:27 -05:00
Jack 5a76a03cb6 remove unqlite requirement
-conditionally import PTCWallet (needed for testing, requires unqlite)

-install unqlite on travis and appveyor
2016-12-17 20:03:35 -05:00
Jack 09846413bd remove Settings.py
remove old settings class, which was only used for the lbryid and
required unqlite.

this allows the daemon startup to be simplified, it previously relied
on Settings in a few places. lbryid had been stored in the old
settings, this initializes it at startup.
2016-12-17 20:01:06 -05:00
Job Evers-Meltzer a8cb255d24 Bump version: 0.7.11rc0 → 0.7.12rc0 2016-12-16 21:45:02 -06:00
Job Evers-Meltzer 6172924021 Bump version: 0.7.8 → 0.7.11rc0 2016-12-16 20:58:24 -06:00
Job Evers‐Meltzer 7bb570c051 Merge pull request #352 from lbryio/fixup-logging
change error log on resolve-name to info
2016-12-16 20:00:37 -06:00
Job Evers-Meltzer d5d0d0e31c change error log on resolve-name to info 2016-12-16 19:51:10 -06:00
Job Evers‐Meltzer 83e797d7f6 Merge pull request #351 from lbryio/ssl-handshake
Fix SSL handshake issue
2016-12-16 19:25:00 -06:00
Job Evers-Meltzer 6c2b3d9ed6 fix ssl handshake error 2016-12-16 19:13:23 -06:00
Job Evers-Meltzer c6f4c17597 upgrade to py2app v0.10 2016-12-16 19:13:23 -06:00
Job Evers-Meltzer d19afd856b allow skipping of some time consuming parts of the build 2016-12-16 19:00:25 -06:00
Job Evers-Meltzer 29e59e783a scripts to test reflector 2016-12-16 15:58:20 -06:00
Job Evers‐Meltzer 107860ea19 Merge pull request #349 from lbryio/force-pyobjc-3.1.1
Pin pyobjc to version 3.1.1
2016-12-16 13:37:08 -06:00
Job Evers-Meltzer a9bfd8d6ae Pin pyobjc to version 3.1.1 2016-12-16 13:02:52 -06:00
Job Evers‐Meltzer 9ee95d57fc Merge pull request #342 from lbryio/update-https
Update https
2016-12-16 11:28:42 -06:00
Job Evers-Meltzer 4a8a8b8d33 sync setup.py with requirements.txt 2016-12-16 11:04:47 -06:00
Job Evers-Meltzer c825d88dbf OSX is having https issues, hopefully this fixes it
When I build locally, the resulting app doesn't have https issues. Looking
over the build script output, I notice that its copying

copying /usr/local/opt/openssl/lib/libssl.1.0.0.dylib -> /Users/jobevers/tmp/lbry/packaging/osx/lbry-osx-app/dist/LBRY.app/Contents/Frameworks

such a line isn't present when travis builds.  This version of libssl
is installed by homebrew. Fingers crossed.
2016-12-16 10:35:13 -06:00
Job Evers-Meltzer 15ade508aa add ndg-httpsclient as a requirement 2016-12-16 10:35:13 -06:00
Job Evers-Meltzer 53df361d23 Log failure when attempting to get_lbry_files
I had an old version of lbryum installed and so no
names were coming back. But the daemon was failing
silently. This at least logs the error.
2016-12-16 00:32:06 -06:00
Job Evers-Meltzer 8fe15f507b Better dht shutdown.
The old code relied on the timing of DelayedCalls
to see what had been called or not, but unfortunately
we don't have a real-time OS so the timing on DelayedCalls
can only be approximate. Changed to explicitly keep
track of which calls had been made.

This simplifies the shutdown logic drastically, and I believe
we can take out the reactor.iterate() now
2016-12-15 23:44:35 -06:00
Job Evers‐Meltzer 3dde7af576 Merge pull request #339 from lbryio/all-prs
All The PRs
2016-12-15 19:42:35 -06:00
Job Evers-Meltzer 7af6e9e0dd Improve BlobAvailabilityTracker performance
For daemons with a lot of blobs, getting mean availabity
will be slow. Samples the blobs in an attempt at getting
better performance.
2016-12-15 19:03:37 -06:00
Job Evers-Meltzer 56d394fb5f Add timing to hash announcements
This could potentially be a performance issue
on reflector or any daemon with a large number of blobs.
2016-12-15 18:58:16 -06:00
Job Evers-Meltzer 3585d861ff Add TRACE level logging 2016-12-15 18:58:16 -06:00
Job Evers-Meltzer f181af8547 Cleanup code in BlobManager 2016-12-15 18:58:16 -06:00
Job Evers-Meltzer 84baa5e065 dht: refactor _msgTimeout 2016-12-15 18:58:16 -06:00
Job Evers-Meltzer 781b915717 remove unused check_consistency function 2016-12-15 18:58:16 -06:00
Job Evers-Meltzer fa29c92760 Add setting to disable reuploading to reflector 2016-12-15 18:58:16 -06:00
Job Evers-Meltzer fec917b9c1 rename platform to system_info 2016-12-15 18:58:16 -06:00
Job Evers-Meltzer 4f3b5cd802 Better logging on DHT errors
Timeout errors are common on the dht so log those
at debug, but other errors need to (potentially) recieve
more attention
2016-12-15 18:58:16 -06:00
Job Evers-Meltzer 250831a86a remove unused distance function from routingtable 2016-12-15 18:58:15 -06:00
Job Evers-Meltzer 323bccb0ae another distance optimization 2016-12-15 18:58:15 -06:00
Job Evers-Meltzer 0084d4684f Add distance optimization 2016-12-15 18:58:15 -06:00
Job Evers-Meltzer 740fad5cbe Refactor dht.node.iterativeFind
Move nested functions into a helper class.
Add new, smaller functions to increase readability
2016-12-15 18:58:15 -06:00
Job Evers-Meltzer fa8190356a replace log_support.failure calls 2016-12-15 18:58:15 -06:00
Job Evers-Meltzer 4ca33505b5 logging: add kwargs to fail() call 2016-12-15 18:58:15 -06:00
Job Evers-Meltzer 20b6b22334 Add callback functionality to log.fail
This enables the common pattern of being able to log a failure and
then do something.
2016-12-15 18:58:15 -06:00
Job Evers-Meltzer b8c91c61bb Make a new logger with a fail method that is useful for errbacks.
Extracting useful tracebacks and line numbers from failures
withing twisted's deferred can be a pain. Hopefully this is a step
in the right direction.
2016-12-15 18:58:15 -06:00
Job Evers-Meltzer c30ea04959 Remove commented code
This is the result of running eradicate (https://github.com/myint/eradicate)
on the code and double-checking the changes.
2016-12-15 18:58:06 -06:00
Umpei Kay Kurokawa 27a09d4a4f Merge pull request #331 from lbryio/fix_wallet_threading_issue
Fix wallet concurrency issue
2016-12-15 10:57:11 -05:00
Kay Kurokawa 23bf43f40c fixing bug where broadcast_transaction function would not return a deferred 2016-12-15 10:28:49 -05:00
Kay Kurokawa 6f60b8b827 work on resolving threading issues with lbryum in Wallet.py 2016-12-15 10:28:49 -05:00
Kay Kurokawa 965f8f1238 removing unused get_transaction function from daemon and wallet 2016-12-15 10:28:49 -05:00
Jack Robison ab78b7f5fa Merge pull request #338 from lbryio/zipsafe-or-bust
Fix the Build
2016-12-14 22:04:58 -05:00
Job Evers-Meltzer 083092ad5e pylint: add check for mixed-indentation 2016-12-14 19:22:00 -06:00
Job Evers-Meltzer 7bce37a720 pylint: add check for missing-final-newline 2016-12-14 19:21:59 -06:00
Job Evers-Meltzer 14ac2bac39 pylint: fix trailing-whitespace 2016-12-14 19:21:59 -06:00
Jeremy Kauffman 32fa2460ff sort the help functions 2016-12-14 19:21:54 -06:00
Job Evers-Meltzer f796f701f2 Immediately announce completed blobs
It doesn't seem necessary to wait up to 60 seconds for a new blob to
be announced to the dht. Immediately announce it and schedule the next
announce time as usual.
2016-12-14 19:05:24 -06:00
Kay Kurokawa fe4ea9b33a use assertFailure, move around assertEqual arguments to standard locations 2016-12-14 19:05:24 -06:00
Kay Kurokawa c278972f26 adding unit tests for Wallet.py 2016-12-14 19:05:23 -06:00
Kay Kurokawa bce41ddab4 Do not return 'success' and 'reason' as outputs in claim commands
We throw an Exception instead
2016-12-14 19:05:05 -06:00
Job Evers-Meltzer 666a62ae3d try setting zip_safe=False 2016-12-14 16:28:38 -06:00
Jack 5bf20096b2 fix wallet_balance when checking fee amount 2016-12-12 14:32:33 -05:00
Alex Grintsvayg 52099c7da7 update gitignore 2016-12-08 18:35:57 -05:00
Job Evers‐Meltzer 9619b8dfca Merge pull request #299 from lbryio/long-lines
Wrap Long lines
2016-12-07 11:41:21 -05:00
Job Evers-Meltzer e8faadc324 fix more long lines 2016-12-07 10:10:46 -05:00
Job Evers-Meltzer 667d5ac622 add emacs tmp files to pylint blacklist 2016-12-07 09:38:38 -05:00
Job Evers-Meltzer afba045c29 add line-to-long check 2016-12-07 09:38:37 -05:00
Job Evers-Meltzer b64fa51567 fixup long lines 2016-12-07 09:38:34 -05:00
Job Evers-Meltzer fe3e25982c don't lint unused files 2016-12-07 09:35:16 -05:00
Jack Robison 9ad55e93b9 Merge pull request #315 from kaykurokawa/fix_claim_bug
Fix bug to exclude support in get_my_claim
2016-12-07 09:25:44 -05:00
Jack Robison 9e7e168175 Merge pull request #319 from lbryio/reenable-startup-status-codes
Reenable startup status
2016-12-06 17:00:03 -05:00
Jack Robison f84df50d7f Merge pull request #317 from lbryio/remove-lbrynet-console
Remove lbrynet-console
2016-12-06 16:59:52 -05:00
Jack f0ed4e5513 move listen to DaemonServer startup 2016-12-06 16:34:50 -05:00
Jack Robison 0af445cbbc Merge pull request #318 from lbryio/build-osx
put back accidental deleted build
2016-12-06 16:21:05 -05:00
Job Evers-Meltzer 99fe28366f put back accidental deleted build 2016-12-06 15:16:41 -05:00
alexliebowitz 39005ffc14 Merge pull request #310 from lbryio/allow-cors-config
allow Access-Control-Allow-Origin to be configurable
2016-12-06 15:11:38 -05:00
Jack 239e5c2126 remove unused imports in LBRYApp.py 2016-12-06 13:01:36 -05:00
Jack Robison 28e88d89a5 Merge pull request #313 from lbryio/config-bittrex
Add bittrex to conf
2016-12-06 12:41:45 -05:00
Jack Robison c85b795fc6 Merge pull request #316 from lbryio/rm-old-install
remove old installation script
2016-12-06 12:40:00 -05:00
Jack 979f8efa79 remove unused lbrynet-console 2016-12-06 12:35:27 -05:00
Jack Robison 4c4bccfe73 Merge pull request #312 from lbryio/local-ui-conf
local_ui_path needs to be a str
2016-12-06 12:23:45 -05:00
Jack 8cb0f99e30 fix pylint errors 2016-12-06 12:22:43 -05:00
Job Evers-Meltzer 44554b63f4 remove old installation script 2016-12-06 12:15:56 -05:00
Umpei Kay Kurokawa 6076861cd0 Merge pull request #304 from kaykurokawa/remove_lbrycrd
Remove lbrycrdd
2016-12-06 12:06:09 -05:00
Job Evers‐Meltzer 8b427a92ac Merge pull request #311 from lbryio/fix-server-port
port needs to be an int
2016-12-06 09:48:08 -05:00
Job Evers‐Meltzer 6c4736d1bd Merge pull request #314 from lbryio/proper-getattr
__getattr__ should call __getattribute__
2016-12-06 09:47:04 -05:00
Kay Kurokawa 9c50cfdcdb fix bug in get_my_claim 2016-12-05 17:17:17 -05:00
Job Evers-Meltzer 8f80e8a3da add bittrex to conf 2016-12-05 17:14:25 -05:00
Job Evers-Meltzer cd44ae02a3 __getattr__ should call __getattribute__ 2016-12-05 17:06:45 -05:00
Job Evers-Meltzer 848f1f025c local_ui_path needs to be a str 2016-12-05 16:29:18 -05:00
Job Evers-Meltzer d2cc8355dc port needs to be an int 2016-12-05 16:20:16 -05:00
Job Evers ee00d1984a allow Access-Control-Allow-Origin to be configurable 2016-12-05 15:34:48 -05:00
Jack Robison 2fb71610a4 Merge pull request #294 from lbryio/approximate-stream-price
Add 'size' parameter to get_est_cost
2016-12-05 12:22:26 -05:00
Jack 948be0f040 clean up tests 2016-12-05 11:48:44 -05:00
Jack b9bb337a07 add tests for daemon.get_est_cost 2016-12-05 11:48:44 -05:00
Jack d93f86030c clean up get_est_cost functions 2016-12-05 11:48:44 -05:00
Jack d9e1e88c05 refactor get_est_cost
-add size parameter, if provided the sd blob won’t be downloaded (can
be used with size information from lighthouse)

-check if blob was already downloaded before trying to download it again
2016-12-05 11:48:43 -05:00
Job Evers-Meltzer f579c8dbb8 Bump version: 0.7.7 → 0.7.8 2016-12-02 20:05:08 -06:00
Job Evers-Meltzer 0005ba0715 pin dmgbuild version
When run with v1.2.0 the build fails with:

dmgbuild -s dmg_settings.py LBRY lbrynet.0.7.7.dmg
Traceback (most recent call last):
  File "[..]/2.7/bin/dmgbuild", line 36, in <module>
    dmgbuild.build_dmg(args.filename, args.volume_name, args.settings, defines=defines, lookForHiDPI=args.lookForHiDPI)
  File "[..]/2.7/lib/python2.7/site-packages/dmgbuild/core.py", line 440, in build_dmg
    d['.']['pBBk'] = background_bmk
  File "[..]/2.7/lib/python2.7/site-packages/ds_store/store.py", line 1183, in __setitem__
    entry_type = value[0]
  File "[..]/2.7/lib/python2.7/site-packages/mac_alias/bookmark.py", line 365, in __getitem__
    raise KeyError('Key not found')
KeyError: u'Key not found'
2016-12-02 16:31:45 -06:00
Jack Robison 13d74d1f76 Merge pull request #297 from lbryio/better-name-error
Provide better feedback on why a name is invalid
2016-12-02 12:08:58 -05:00
Job Evers-Meltzer ddf678af8a Bump version: 0.7.7rc0 → 0.7.7 2016-12-02 09:47:27 -06:00
Job Evers‐Meltzer 2c6d6d1602 Merge pull request #303 from lbryio/settings-api-fixes
Fixes to get_settings() and set_settings()
2016-12-02 09:41:22 -06:00
Alex Liebowitz 7d0e9f6ab9 Tweak logic in ApplicationSettings
Use self.environ instead of ENVIRONMENT to avoid global reference
2016-12-01 23:51:58 -05:00
Kay Kurokawa 200a22c93b Remove support for lbrycrdd wallet and related code 2016-12-01 16:45:48 -05:00
Alex Grin 31a90e7f60 Merge pull request #302 from lbryio/fix-analytics-error
Attempt to fix analytics badstatusline error
2016-12-01 16:25:05 -05:00
Job Evers-Meltzer 2bf098b5a3 add tests for settings change 2016-12-01 15:22:53 -05:00
Alex Liebowitz 458561fe6f In AdjustableSettings, initialize all keys on init
Settings.update() method expects keys to already be present, so load
them all up front
2016-12-01 15:22:52 -05:00
Alex Liebowitz 157d6dca93 Save settings in conf.py 2016-12-01 15:22:52 -05:00
Alex Liebowitz 7b1b7fbf13 Call conf.settings.get_dict() in jsonrpc_get_daemon_settings() 2016-12-01 15:22:51 -05:00
Alex Liebowitz 876cdce51f Add Config.get_dict()
We don't want the version from DefaultSettings, so use super() to get
the standard functionality from conf.Settings.
2016-12-01 15:22:51 -05:00
Alex Liebowitz 205a10bc8e Refactor how adjustable settings are pulled out of config.settings
- Factor out this functionality into separate method
 - Change the set_settings() JSON-RPC method to use this (before, it was
   just returning all fields, which doesn't work anymore after the
   settings refactor)
2016-12-01 15:22:51 -05:00
Alex Liebowitz ef8d1cfdc2 Rename var in Settings.update() 2016-12-01 15:22:51 -05:00
Alex Liebowitz 879c01ba00 Add separate list of excluded fields to AdjustableSettings
Adds "environ" field. Also renames __excluded to _excluded so it can
be overridden by child classes.
2016-12-01 15:22:44 -05:00
Alex Liebowitz 8bb7517f32 Merge pull request #300 from kaykurokawa/fix_claim_defer
Missing the return of a defer.fail when claim fails, changing to raise Exception
2016-12-01 13:49:29 -05:00
Job Evers-Meltzer 70d9b3ed74 Attempt to fix analytics badstatusline error
We've started seeing a lot of:
ConnectionError: ('Connection aborted.', BadStatusLine("''",))

Hopefully this fixes the problem. Its hard to test, so I'll
have to check the logs after releasing.
2016-12-01 12:13:12 -06:00
Job Evers-Meltzer f39a21cf7b Provide better feedback on why a name is invalid 2016-12-01 11:02:37 -06:00
Umpei Kay Kurokawa 67b169c5a1 Merge pull request #300 from kaykurokawa/fix_claim_defer
Missing the return of a defer.fail when claim fails, changing to raise Exception
2016-11-30 23:08:48 -05:00
Kay Kurokawa ff10546152 Missing the return of a defer.fail when claim fails, changing to raise Exception 2016-11-30 22:57:23 -05:00
Umpei Kay Kurokawa bd6fe4f986 Merge pull request #290 from kaykurokawa/fix_logging2
Converting some log.info to log.debug in Wallet
2016-11-30 19:22:16 -05:00
Kay Kurokawa 360f4e50a0 converting some log.info to log.debug in Wallet 2016-11-30 16:37:28 -05:00
Job Evers‐Meltzer f11f486f5a Merge pull request #292 from lbryio/allow-rc
allow for rc in version values
2016-11-30 14:16:17 -06:00
Jack Robison fe53cc97d9 Merge pull request #285 from lbryio/more-flexible-origin-check
Allow 0.0.0.0 for api interface
2016-11-30 14:04:52 -05:00
Jack Robison baf6ff3f50 Merge pull request #296 from lbryio/dont-allow-zero-bid
don't allow 0 bid in publish
2016-11-30 13:59:31 -05:00
Jack 051e63d76b don't allow 0 bid 2016-11-29 20:17:06 -05:00
Job Evers-Meltzer 8cdda7d845 Bump version: 0.7.6 → 0.7.7rc0 2016-11-28 23:33:57 -06:00
Job Evers-Meltzer 6a8789050c Allow 0.0.0.0 for api interface
For a host to be able to access the daemon running inside a docker
container the damon needs to be listening to 0.0.0.0

- move the API_INTERFACE setting to the adjustablesettings
- check the port matches as well as the interface
2016-11-28 19:19:05 -06:00
Job Evers‐Meltzer 9140c95a0c Merge pull request #291 from lbryio/fix-pylint
fix pylint errors
2016-11-28 15:32:16 -06:00
Job Evers-Meltzer 4b52c88d45 fix functional tests 2016-11-28 13:55:38 -06:00
Jeremy Kauffman b7dd9c176a remove broken link and clarify INSTALL link 2016-11-28 14:47:21 -05:00
Job Evers-Meltzer 6f2e2e727e fix pylint errors 2016-11-28 13:33:34 -06:00
Jack Robison 48b137fe4c Merge pull request #287 from lbryio/version-add-lbry-id
get_lbry_session_info
2016-11-28 14:26:43 -05:00
Jack a6326ee7a1 get_lbry_session_info 2016-11-28 14:16:21 -05:00
Job Evers‐Meltzer c91034ee4c Update INSTALL.md
Change instructions to prefer to use pip for installation
2016-11-28 12:57:52 -06:00
Umpei Kay Kurokawa 7c505f2e23 Merge pull request #245 from kaykurokawa/add_nout_final
use nOut in addition with txid to identify claims
2016-11-25 17:15:04 -05:00
Jack bfcd84a568 use nOut in addition with txid to identify claims 2016-11-25 16:59:23 -05:00
Jeremy Kauffman a314c530bc remove outdate doc url 2016-11-25 15:20:39 -05:00
Alex Liebowitz 4cb2a8f2aa Include LBRY ID in version() API method result 2016-11-23 20:29:45 -05:00
Alex Liebowitz 9d272befcd Convert length of shortened plaintext LBRY ID to constant 2016-11-23 20:28:16 -05:00
Job Evers‐Meltzer 1695b26416 Merge pull request #276 from lbryio/configuration
Better parse environment variables for configuration
2016-11-22 23:24:13 -06:00
Job Evers 91fb78b077 Update TODO with more useful info 2016-11-22 18:14:41 -06:00
Job Evers-Meltzer 0bbc8f5b7e add envparse to requirements 2016-11-22 18:14:41 -06:00
Job Evers-Meltzer 464bd11c3a Improve parsing of environment variables
Switch adjustable settings to use the envparse library. This
provides more flexible and robust parsing.
2016-11-22 18:14:36 -06:00
Job Evers-Meltzer b88e771eb2 bug fix: use proper settings dictionary 2016-11-22 16:03:37 -06:00
Job Evers-Meltzer 7a76763610 rename Setting to Settings 2016-11-22 16:03:37 -06:00
Job Evers-Meltzer 02d2bad03f allow json to be used to set settings 2016-11-22 16:03:37 -06:00
Jack Robison f65a50a6a3 Merge pull request #260 from lbryio/error-messages
meaningful error messages, improve cli, remove unused search from daemon
2016-11-22 15:54:21 -05:00
Jack 0a9ef07787 Merge branch 'master' into error-messages
# Conflicts:
#	lbrynet/lbrynet_daemon/Daemon.py
#	lbrynet/lbrynet_daemon/auth/server.py
2016-11-22 15:44:47 -05:00
Jack Robison 0e9ad16a2e Merge pull request #278 from lbryio/fix-uncaught-analytics-exception
fix uncaught analytics exception
2016-11-22 15:25:07 -05:00
Jack cd0a9ba9e8 feedback from job 2016-11-22 15:18:01 -05:00
Jack e08d0eb8f9 _log_and_render_error 2016-11-22 15:11:25 -05:00
Jack Robison 82f9cc57fd Merge pull request #283 from lbryio/fail-blank-uri
fail verify_name_characters for blank uri
2016-11-22 13:55:12 -05:00
Umpei Kay Kurokawa ae53129b25 Merge pull request #282 from kaykurokawa/fix_autoconnect2
fix spelling mistake for auto connect
2016-11-21 22:13:13 -05:00
Jack 543f65fc24 fail verify_name_characters for blank name 2016-11-21 21:58:04 -05:00
Kay Kurokawa 896a16c15d fix spelling mistake for auto connect 2016-11-19 19:29:58 -05:00
Job Evers-Meltzer 3d7dee1208 allow for rc in version values 2016-11-19 16:58:40 -06:00
Alex Liebowitz e03db79f79 Always return array from jsonrpc_get_lbry_files()
Before, would return false when there were no files in the DB.
2016-11-16 23:57:02 -05:00
Jack 0b0150ad73 fix uncaught analytics exception 2016-11-16 19:10:49 -05:00
Jack Robison 0490250da4 Merge pull request #272 from lbryio/setup-ui-defaults
Give priority to arguments over settings in UIManager.setup()
2016-11-16 18:53:26 -05:00
Job Evers-Meltzer dd952ddbe3 Bug fix: pkg_resources doesn't like cx_freeze.
Getting the location of bundling resources doesn't work
with cx_freeze so putting in some temporary error handling
while we figure out a better way to bundle the UI.
2016-11-16 15:15:46 -06:00
Alex Liebowitz 776fe41e03 Switch back to "or" style for default params in UIManager.setup() 2016-11-16 16:09:42 -05:00
Alex Liebowitz 8b1ea0a6a7 Give priority to arguments over settings in UIManager.setup() 2016-11-16 15:58:11 -05:00
Job Evers-Meltzer 183617c85b try patched version of cx_freeze 4.3.3 2016-11-16 14:53:27 -06:00
Job Evers-Meltzer 386c67fa70 revert cx-freeze back to 4.3.3 2016-11-16 14:23:48 -06:00
Jack ba7f326e72 use log_support 2016-11-16 15:16:15 -05:00
Job Evers-Meltzer b9caf2c4a9 Bump version: 0.7.6rc0 → 0.7.6 2016-11-16 11:06:53 -06:00
Job Evers‐Meltzer 3188165514 Merge pull request #274 from lbryio/fix-rc-regex
remove - from regex for rc tag
2016-11-15 23:33:57 -06:00
Job Evers-Meltzer 1c036cce78 remove - from regex for rc tag 2016-11-15 22:01:20 -06:00
Alex Grin a2e648fcfc Merge pull request #273 from lbryio/test-build-type
set build type in travis
2016-11-15 23:01:15 -05:00
Alex Grintsvayg b75a89e876 set build type in travis 2016-11-15 22:30:10 -05:00
Alex Grintsvayg 82a3b5e9c5 Merge branch 'better_metrics'
* better_metrics:
  improve error analytics
  use constants for wallet types
2016-11-15 10:32:14 -05:00
Alex Grintsvayg 7ecc8103d8 improve error analytics
- move analytics creation earlier in the startup process
- add several events to track startup, startup failure, other errors
- abstract platform detection into separate file
- add "build" type to platform so we can differentiate devs vs live users
2016-11-15 10:31:35 -05:00
Alex Grintsvayg 6b72b4de11 use constants for wallet types 2016-11-15 10:31:35 -05:00
Job Evers‐Meltzer 8e1ad0aa8b Merge pull request #270 from lbryio/survive-lbry-down
Bug fix: continue even if log fails to upload
2016-11-15 08:48:05 -06:00
Job Evers‐Meltzer 5b7f80487f Merge pull request #271 from lbryio/log-lbryum-on-verbose
enable lbryum info logging when verbose
2016-11-15 08:47:51 -06:00
Job Evers‐Meltzer ebc400804f Merge pull request #262 from lbryio/dry-reflector
Remove repeated code for reflector
2016-11-14 20:54:53 -06:00
Job Evers-Meltzer 9940327b9a enable lbryum info logging when verbose 2016-11-14 20:34:56 -06:00
Job Evers-Meltzer b300afb504 Bug fix: continue even if log fails to upload
lbry.io being down caused lbrynet to die when uploading a log.
2016-11-14 20:16:34 -06:00
Job Evers-Meltzer 0941618048 move reflector blob client to its own module 2016-11-14 19:33:36 -06:00
Job Evers-Meltzer abc7b11e26 remove repeated code for reflector 2016-11-14 19:33:36 -06:00
Job Evers-Meltzer 85dee27c92 whitespace 2016-11-14 19:33:36 -06:00
Jack 5ae3485411 Merge branch 'master' into error-messages
# Conflicts:
#	lbrynet/dht/protocol.py
2016-11-14 14:11:02 -05:00
Jack 8f98469969 unused imports 2016-11-14 14:10:19 -05:00
Jack e1cdbdc91d fix coveralls error 2016-11-14 14:02:19 -05:00
Jack 908c9a3bfa feedback from job 2016-11-14 13:53:11 -05:00
Jack f45a2cba32 fix insufficient funds and max key fee bug 2016-11-14 13:41:05 -05:00
Jack Robison 763fefb33f Merge pull request #256 from kaykurokawa/fix_get_my_claim
Update right after making claim will fail due to get_my_claim()
2016-11-14 13:37:54 -05:00
Job Evers‐Meltzer ce7463f684 Merge pull request #269 from lbryio/normalize-version
Normalize python version
2016-11-11 14:48:33 -06:00
Job Evers-Meltzer cd65b6fd13 Normalize python version
setuptools will force a version to be 'normalized'
which means that it removes the dash.

This will probably cause some weirdness on the version
numbers in the windows build; might have to re-work
my patches on cx_freeze: https://bitbucket.org/jobevers/cx_freeze/commits/all
2016-11-11 14:34:01 -06:00
Jack 472bb6af1b remove unused lighthouse search from daemon 2016-11-11 13:43:58 -05:00
Jack 7f96e35b0e clean up daemon imports and settings var name 2016-11-11 13:42:51 -05:00
Jack f9fef3d586 reactor.iterate() in dht shutdown
-fixes enigmatic  `’Port' object has no attribute 'socket’` error
2016-11-11 13:41:36 -05:00
Jack ec4f9011b9 meaningful API error messages 2016-11-11 13:40:19 -05:00
Job Evers-Meltzer d634c009d3 Bump version: 0.7.5 → 0.7.6-rc0 2016-11-11 12:04:21 -06:00
Job Evers‐Meltzer 1872256d7a Merge pull request #268 from lbryio/bundle-rc
add ui bundle to RC too
2016-11-11 12:02:43 -06:00
Job Evers-Meltzer 81d107d99c better regex for tag match on appveyor 2016-11-11 11:44:35 -06:00
Job Evers‐Meltzer a7589914d0 Merge pull request #267 from lbryio/fix-dht-ports
Restore reactor.iterate in dht shutdown
2016-11-11 11:42:43 -06:00
Job Evers‐Meltzer 0736fa506b Merge pull request #266 from lbryio/startup-logging
more logging on startup
2016-11-11 11:11:02 -06:00
Job Evers‐Meltzer dfec3c1a15 Merge pull request #264 from lbryio/bumpversion
Add release candidates to bumpversion
2016-11-11 11:10:37 -06:00
Job Evers‐Meltzer edc89be794 Merge pull request #257 from lbryio/ensure-ui-loads
bug fix: ensure the bundled ui is loaded
2016-11-11 10:26:54 -06:00
Job Evers-Meltzer d41881596d Restore reactor.iterate in dht shutdown
This reverts the change made in 693fef1964

Not sure why this is needed, but taking this out sometimes causes
`exceptions.AttributeError: 'Port' object has no attribute 'socket'`
to happen on shutdown.
2016-11-11 10:21:50 -06:00
Job Evers-Meltzer 3b34bddf0a more logging on startup 2016-11-11 10:14:41 -06:00
Job Evers-Meltzer 23c012f417 add ui bundle to RC too 2016-11-11 09:49:27 -06:00
Job Evers-Meltzer 2c8d643f4b Add release candidates to bumpversion
The release process now looks like:
starting version: 0.7.5
bumpversion patch -> 0.7.6-rc0
bumpversion candidate -> 0.7.6-rc1
bumpversion release -> 0.7.6
2016-11-11 07:19:39 -06:00
Jack Robison 0abc081edc Merge pull request #259 from lbryio/use-whole-message-in-auth
use whole message to make hmac
2016-11-10 17:07:39 -05:00
Kay Kurokawa 11b36ff4c8 fixing to remove supports from get_my_claim 2016-11-10 12:52:35 -05:00
alexliebowitz c407d32f5d Merge pull request #258 from lbryio/fix-user-specified-ui-bug
Fix deferred for loading user-specified UIs
2016-11-10 03:51:58 -05:00
Alex Liebowitz 87cc487051 Fix deferred for loading user-specified UIs
In UIManager, pass self._load_ui into deferred as function object
instead of calling immediately
2016-11-10 03:47:32 -05:00
Jack Robison 5ea945ca0b Merge pull request #249 from lbryio/settings-bugs
fix --wallet argument bug, use .json conf file if not given a .yml file
2016-11-09 16:53:46 -05:00
Kay Kurokawa 1f06339d5a fix get_my_claim command 2016-11-09 15:19:58 -05:00
Job Evers-Meltzer 09d248b3cc bug fix: ensure the bundled ui is loaded 2016-11-09 13:34:04 -06:00
Umpei Kay Kurokawa 28bf5215e4 Merge pull request #251 from kaykurokawa/fix_unknonwname_exc
fixing UnknownNameError exception initialization
2016-11-09 12:37:03 -05:00
Job Evers-Meltzer f3a71245e8 Add missing files
Somehow these files got lost in a rebase. I'm sort of at a loss
for how, but well, adding them back in.
2016-11-09 11:35:03 -06:00
Job Evers‐Meltzer 37fee71898 Merge pull request #247 from lbryio/bad-whitespace
add bad-whitespace check to pylint
2016-11-09 11:27:45 -06:00
Job Evers-Meltzer 61a354fa60 add bad-whitespace check to pylint 2016-11-09 11:27:07 -06:00
Job Evers‐Meltzer 1d4b2c3527 Merge pull request #253 from lbryio/bundled-ui-squash
Bundle the UI into non-tagged builds.
2016-11-09 11:03:23 -06:00
Job Evers-Meltzer 694b5b9ee5 switch branch to master 2016-11-09 11:02:00 -06:00
Job Evers-Meltzer 838508f342 Bundle the UI into non-tagged builds.
Updates the UIManager to check if a bundled UI was included
in the package and preferentially use that.
2016-11-09 09:29:39 -06:00
Job Evers-Meltzer 694db88ac1 bug fix: fail build if tests fail 2016-11-09 09:28:47 -06:00
Job Evers-Meltzer cb7c849273 bug fix: actually read the environment variable 2016-11-09 09:28:18 -06:00
Alex Grin 9d82be6664 that server's not up anymore 2016-11-09 10:13:36 -05:00
Job Evers‐Meltzer 66745b0820 Merge pull request #242 from lbryio/shutdown-issues
Shutdown issues
2016-11-09 08:17:13 -06:00
Job Evers‐Meltzer f845729adb Merge pull request #246 from lbryio/refactor-upload
Refactor upload
2016-11-09 08:16:34 -06:00
Job Evers-Meltzer 6a587d03cf refactor upload endpoint 2016-11-09 08:16:08 -06:00
Job Evers-Meltzer affb7d837a better logging, cleanup whitespace 2016-11-09 08:16:08 -06:00
Kay Kurokawa 4ad6405f35 fixing UnknownNameError exception initialization 2016-11-08 14:28:17 -05:00
Job Evers‐Meltzer 906e6b238e Merge pull request #243 from lbryio/unicode-publish
Unicode publish
2016-11-08 08:45:26 -06:00
Jack 297865902b use json conf file if not given yml 2016-11-05 14:23:48 -04:00
Jack ab15074ae4 fix --wallet=lbrycrd argument 2016-11-05 14:10:26 -04:00
Job Evers-Meltzer b68a1838f2 eliminate unused return value 2016-11-04 11:44:50 -05:00
Job Evers-Meltzer 43b2cd1433 cleanup whitespace and long-lines 2016-11-04 11:44:50 -05:00
Job Evers-Meltzer 0036685ece use more readable KB, MB 2016-11-04 11:44:50 -05:00
Job Evers-Meltzer d06c670a12 Allow publishing with unicode filenames
encodes unicode into a string before hashing.  Also adds tests
to verify that the fix works and that normal files
can be made into EncryptedFiles
2016-11-04 11:44:50 -05:00
Job Evers-Meltzer 6d6cfbc7cc whitespace 2016-11-03 16:57:42 -05:00
Job Evers-Meltzer 3c977f961f improve osx app shutdown 2016-11-03 16:57:29 -05:00
Job Evers-Meltzer 59c4593bf4 whitespace 2016-11-03 14:42:57 -05:00
Job Evers-Meltzer 5bccfdb244 add logging to shutdown process 2016-11-03 14:42:45 -05:00
Job Evers-Meltzer 10cb20d08f fix whitespace and long-lines 2016-11-03 14:22:16 -05:00
Job Evers-Meltzer 693fef1964 remove reactor.iterate from dht shutdown 2016-11-03 10:43:24 -05:00
Job Evers-Meltzer fe7700d726 Bump version: 0.7.4 → 0.7.5 2016-11-02 10:50:42 -05:00
Job Evers‐Meltzer fee6de1c1f Merge pull request #238 from lbryio/missing-conf
fix missing conf file on first run
2016-11-02 10:49:49 -05:00
Jack 7d04ae2237 use whole message to make hmac 2016-11-02 11:38:09 -04:00
Jack c748572bf6 feedback from job 2016-11-02 11:32:46 -04:00
Jack 660bf74d42 fix missing conf file on first run 2016-11-02 10:41:47 -04:00
Job Evers-Meltzer 4db3be345b Bump version: 0.7.3 → 0.7.4 2016-11-02 07:43:11 -05:00
Job Evers‐Meltzer dcea8a8c78 Merge pull request #236 from lbryio/better-log-and-kill
More robustly stop the reactor
2016-11-02 07:36:21 -05:00
Job Evers-Meltzer 815696485f More robustly stop the reactor
Was getting a "cannot stop a reactor that isn't running error"
when playing around with error handling on startup.

Following the suggestion from http://stackoverflow.com/a/36738480
it seems to work better
2016-11-02 07:23:37 -05:00
Job Evers‐Meltzer b316b56885 Merge pull request #234 from lbryio/unicode-settings
download directory and ui bug fixes for windows
2016-11-02 07:19:51 -05:00
Job Evers‐Meltzer 269dc47b69 Merge pull request #230 from kaykurokawa/better_stream_info_error
Better error detection in Wallet for invalid streams
2016-11-02 07:13:48 -05:00
Job Evers‐Meltzer a7e3246a82 Merge pull request #233 from lbryio/add-more-pylint
lint the osx and windows apps
2016-11-01 18:33:44 -05:00
Jack 96ef5089fc fix data_dir problem in UIManager 2016-11-01 16:40:50 -04:00
Job Evers-Meltzer c0d96a5733 fix bug in jsonrpc_get_settings 2016-11-01 15:39:51 -05:00
Job Evers-Meltzer 7de4340c38 lint the osx and windows apps
This also fixes a trivial bug in the osx release.
2016-11-01 15:39:50 -05:00
kkurokawa 7dd5e7ceeb spacing after comma fix, use Exception init in InvalidStreamInfoError 2016-11-01 16:35:44 -04:00
Jack 9de7354ea0 drop connection on failed read blob 2016-11-01 16:32:34 -04:00
Jack cfbdda411a whoops 2016-11-01 13:23:02 -04:00
Jack 96c4837cb8 clean up errback 2016-11-01 13:19:13 -04:00
Jack 2294e6bf36 Merge branch 'master' into unicode-settings 2016-11-01 13:06:20 -04:00
Jack 4cffc32328 catch availability check error 2016-11-01 13:05:19 -04:00
Jack d1b23e25d9 allow unicode settings 2016-11-01 12:53:04 -04:00
Job Evers-Meltzer e5ba70c3ba Bump version: 0.7.2 → 0.7.3 2016-11-01 11:38:45 -05:00
Job Evers‐Meltzer c88e4aecf5 Merge pull request #232 from lbryio/read-config
Read config
2016-11-01 11:33:17 -05:00
Job Evers‐Meltzer 469df84990 Merge pull request #229 from kaykurokawa/fix_updates
Fix updates in name_claim function
2016-11-01 11:16:03 -05:00
Job Evers-Meltzer a4ec706b06 enable console logging for apps 2016-11-01 11:14:04 -05:00
Job Evers-Meltzer 30533a7986 Read config file in windows and osx
Also moves the config loading to BEFORE the log configuration
2016-11-01 11:14:04 -05:00
kkurokawa 39b47bc569 better error detection in _get_stream_info_from_value 2016-11-01 10:34:08 -04:00
Job Evers‐Meltzer 96104e65ed Merge pull request #226 from lbryio/start-tcp-earlier
Start listening before launching browser
2016-11-01 07:33:33 -05:00
kkurokawa e9bab33e2a fixing claim updates 2016-10-31 19:17:37 -04:00
Job Evers-Meltzer 3b6006d759 Start listening before launching browser 2016-10-31 14:00:07 -05:00
Job Evers‐Meltzer 9535a24706 Merge pull request #221 from lbryio/less-lbryum-logs
set lbryum to log at warning level
2016-10-30 17:04:37 -05:00
Job Evers‐Meltzer 8f2be46536 Add coveralls badge 2016-10-30 16:55:12 -05:00
Job Evers-Meltzer 9ca80a7cf7 set lbryum to log at warning level
lbryum is very chatty at the info level. As a rough estimate a bit
over half of our logs in loggly are a result of lbrum.

The better, long-term, solution would be to modify lbryum to move more
logs to the debug level.
2016-10-30 16:47:37 -05:00
Job Evers‐Meltzer 72078f4af3 Merge pull request #220 from lbryio/add-coverage
Add coverage reporting
2016-10-30 16:05:46 -05:00
Job Evers-Meltzer ff9ea37e0c add coverage reporting 2016-10-30 15:44:45 -05:00
Job Evers-Meltzer 9baf261cb3 Bump version: 0.7.1 → 0.7.2 2016-10-30 14:47:21 -05:00
Job Evers-Meltzer f03a15d503 remove unneeded 'after_first_run' check 2016-10-30 14:46:16 -05:00
Job Evers-Meltzer 1a70a20c8b Bump version: 0.7.0 → 0.7.1 2016-10-30 10:57:41 -05:00
Job Evers-Meltzer 359cb83fab change windows log file location 2016-10-30 10:46:58 -05:00
Job Evers-Meltzer 0893858385 Bump version: 0.6.10 → 0.7.0 2016-10-28 18:03:40 -05:00
Job Evers-Meltzer e1997a6852 dumb bug fix 2016-10-28 17:55:34 -05:00
Job Evers‐Meltzer 0f4fee475f Merge pull request #201 from lbryio/reflect-my-unavailable-streams
Upload unavailable streams to reflector on startup
2016-10-28 17:29:28 -05:00
Job Evers-Meltzer 864e963dea Merge remote-tracking branch 'origin/master' into reflect-my-unavailable-streams
Conflicts:
	lbrynet/core/log_support.py
2016-10-28 17:16:39 -05:00
Job Evers‐Meltzer 3d0debd775 Merge pull request #218 from lbryio/misc-fixes
various fixes
2016-10-28 17:12:07 -05:00
Job Evers‐Meltzer 6cc2b48a06 Merge pull request #217 from lbryio/safer-conversion
For settings: On conversion failure, fallback to default values
2016-10-28 16:57:40 -05:00
Job Evers-Meltzer dee0917642 various fixes 2016-10-28 16:57:25 -05:00
Job Evers-Meltzer 395a68b261 For settings: On conversion failure, fallback to default values 2016-10-28 16:29:16 -05:00
Job Evers‐Meltzer 0d066b2d11 Merge pull request #213 from lbryio/log-errors-on-resolve-name
Log error when resolve name fails
2016-10-28 16:25:19 -05:00
Job Evers-Meltzer 353ede26b8 Log error when resolve name fails 2016-10-28 16:03:58 -05:00
Job Evers‐Meltzer 46cfa20f65 Merge pull request #204 from lbryio/cleanup-logging
Cleanup logging
2016-10-28 15:56:54 -05:00
Job Evers‐Meltzer 30b1dd3ce6 Merge pull request #210 from lbryio/app-startup
make app startup consistent across versions
2016-10-28 15:55:09 -05:00
Jack da601818a3 return from restore_status properly 2016-10-28 16:47:45 -04:00
Job Evers-Meltzer 6fa624ec8a switch LogUploader to use an already encoded lbryid 2016-10-28 15:44:24 -05:00
Job Evers-Meltzer 779ba8e214 Fix missing conf imports 2016-10-28 15:43:04 -05:00
Job Evers-Meltzer 80f548fdfd use same logging for apps 2016-10-28 15:43:04 -05:00
Job Evers-Meltzer 6f9ec2fa66 remove repeated log code 2016-10-28 15:43:04 -05:00
Job Evers-Meltzer 40437e4a82 log cleanup 2016-10-28 15:43:04 -05:00
Job Evers-Meltzer 2ee6fac014 redo logging configuration for lbrynet-daemon script 2016-10-28 15:43:04 -05:00
Job Evers-Meltzer 8fe5eb514a make app startup consistent across versions 2016-10-28 15:41:48 -05:00
Jack c4312cc387 Merge branch 'master' into reflect-my-unavailable-streams 2016-10-28 16:05:16 -04:00
Jack 110a9b1e0f whoops 2016-10-28 15:56:22 -04:00
Jack 035a1cf758 feedback from job 2016-10-28 15:48:51 -04:00
Jack d4785849e1 remove unused imports 2016-10-28 14:22:37 -04:00
Job Evers-Meltzer b41756e38a Bump version: 0.6.9 → 0.6.10 2016-10-28 12:29:15 -05:00
Job Evers‐Meltzer 60ee278519 Merge pull request #215 from lbryio/delete_running
delete RUNNING.md
2016-10-28 11:10:54 -05:00
Alex Grintsvayg b49e44926a this is very out of date 2016-10-28 12:01:10 -04:00
Job Evers‐Meltzer 81187da5b7 Merge pull request #211 from lbryio/refactor-settings
Refactor settings
2016-10-27 15:36:11 -05:00
Job Evers-Meltzer e70ecc8ac9 change settings object for packages too 2016-10-27 14:57:02 -05:00
Job Evers-Meltzer 862055a6de move settings into conf file 2016-10-27 14:31:27 -05:00
Job Evers-Meltzer 7076c0c870 Require env settings are in LBRY namespace 2016-10-27 11:05:21 -05:00
Job Evers-Meltzer 2cd6c644a0 Merge remote-tracking branch 'origin/master' into refactor-settings
Conflicts:
	lbrynet/lbrynet_daemon/Daemon.py
	lbrynet/lbrynet_daemon/DaemonControl.py
	lbrynet/lbrynet_daemon/DaemonServer.py
2016-10-27 10:34:48 -05:00
Job Evers-Meltzer 0edacbe4c8 Merge remote-tracking branch 'origin/master' into refactor-settings
Conflicts:
	lbrynet/conf.py
	lbrynet/lbrynet_daemon/Daemon.py
	lbrynet/lbrynet_daemon/DaemonCLI.py
	lbrynet/lbrynet_daemon/UIManager.py
	tests/functional/test_misc.py
2016-10-27 10:18:56 -05:00
Job Evers‐Meltzer 4b330d0e9f Update Installation instructions 2016-10-27 09:25:06 -05:00
Job Evers‐Meltzer 8ce08f7da1 Merge pull request #206 from lbryio/shutdown-during-setup
Shutdown during setup
2016-10-26 19:09:33 -05:00
Jack 127987f3ba upload log if lbry id is not yet set, clean up crash log 2016-10-26 17:39:47 -05:00
Job Evers-Meltzer 3c7eec9456 raise error if database is newer 2016-10-26 17:39:46 -05:00
Job Evers-Meltzer 5d45345398 shutdown if there are errors during setup 2016-10-26 17:39:43 -05:00
Jack Robison b360eb6181 Merge pull request #207 from lbryio/better-json
Use better json formatting
2016-10-26 16:32:19 -04:00
Jack 369cd516c0 move availability check and fix from ManagedEncryptedFileDownloader to ReflectorAvailabilityHelper 2016-10-26 16:17:01 -04:00
Jack 24320d6444 remove debug line 2016-10-26 03:22:45 -04:00
Jack 1951ea09cd updates from master, more refactoring
-lbrynet.lbrynet_daemon.auth.client.LBRYAPIClient.config will detect if
it needs to return the auth/non-auth version
2016-10-26 03:16:33 -04:00
Job Evers-Meltzer 4d391e7429 Use better json formatting
Apply json.dumps at the end of the formatting process instead of the
middle.  This allows for proper escaping of quotes and allows for
actual json to be emitted.
2016-10-25 17:49:35 -05:00
Job Evers‐Meltzer fb88cdb445 Merge pull request #203 from lbryio/github-bug
catch exception if github is down
2016-10-24 11:02:12 -05:00
Job Evers‐Meltzer 572f1d1f6e Merge pull request #200 from lbryio/cleanup-tests
Start to cleanup functional tests to improve readability
2016-10-24 11:01:20 -05:00
Job Evers‐Meltzer 27a8114b6f Merge pull request #197 from lbryio/add-dht-tests
Rename DHT tests such that trial automatically runs them
2016-10-24 11:00:40 -05:00
Job Evers‐Meltzer 6f3873d99b Merge pull request #178 from lbryio/track-data-upload-rebase
Track Data Uploaded and other stuff
2016-10-24 08:20:29 -07:00
Job Evers-Meltzer e62e2cc440 catch exception if github is down 2016-10-21 16:12:56 -07:00
Job Evers-Meltzer a5797cdeb3 Better handling of lbry file search
- replace lbry file search strings with constants
- refactor repeated code for deciding what search type to use
2016-10-20 16:01:54 -07:00
Jack 3dd99fdc92 upload unavailable streams to reflector on startup 2016-10-20 15:40:35 -04:00
Job Evers-Meltzer 0c2265a8da replace some strings 2016-10-20 11:30:38 -07:00
Job Evers-Meltzer 01811621a6 shorten is_valid_blobhash logic 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer 229ed0d7dc rename summarize to summarize_and_reset 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer 7f800ce5bb fix rebase error 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer aa291ca79a fix pylint 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer 813267ae18 fix tests 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer fbf7928412 rename events to be seperate for each metric 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer 7167d47631 bug fixes 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer 8b1bb673c1 report available blobs 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer 417a8f719f Add looping call manager to analytics manager 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer ddb88eb1c9 move LoopingCallManager to own module 2016-10-20 11:29:58 -07:00
Job Evers-Meltzer d5f0001950 small cleanups 2016-10-20 11:29:15 -07:00
Job Evers-Meltzer 4a07b56e8a refactor analytics manager to use dependency injection 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer 9da1b3c5b7 analytics manager bug fix 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer f9f07c47e2 move analytics manager 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer f5213fb77a GetFileHelper bug fixes 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer 48a61605de bug fix: looping calls 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer 76fb7697ff misc 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer b71a3fee43 add tracked metrics reporting to analytics 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer 3a91896d8a track the amount of data uploaded 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer 36ae0d5f20 remove utils file - function moved to core 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer 3f727d892c refactor events; add tests 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer c104ed3f8b better time handling in tests 2016-10-20 11:28:05 -07:00
Job Evers-Meltzer 9416376a34 refactor: add GetFileHelper
Move the code related to getting a lbry file into
its own class
2016-10-20 11:26:10 -07:00
Job Evers-Meltzer 66e139c566 set development version based on environment variable 2016-10-20 11:26:10 -07:00
Job Evers-Meltzer d0a82c68df move analytics related calls into their own class 2016-10-20 11:25:17 -07:00
Job Evers-Meltzer 93e2b3e20a Extract some looping call code out of the daemon 2016-10-20 11:25:17 -07:00
Job Evers-Meltzer 2e59e5e3b8 extract individual functions 2016-10-20 11:16:36 -07:00
Jack 727ea12dbd Bump version: 0.6.8 → 0.6.9 2016-10-20 12:41:49 -04:00
Jack Robison ea3225c897 Merge pull request #198 from lbryio/fix-blobrequester
fix problems in blobrequester
2016-10-20 12:41:26 -04:00
Job Evers-Meltzer bfcfa9dc3c cleanup tests to improve readability 2016-10-20 09:30:08 -07:00
Jack ea21821558 fix issues with is_generous
-stop requesting blobs if price limit is reached and the offer still
has not been accepted

-drop max rate to old flat rate (0.005lbc/mb)
2016-10-20 12:29:55 -04:00
Jack a9ae1a1016 fix bug where support claim is returned when it shouldn't be 2016-10-20 11:15:35 -04:00
Jack 3f5efb1fa3 fix problems in blobrequester
-also move is_generous_host into a conf setting
2016-10-20 01:35:18 -04:00
Job Evers-Meltzer 9ba38c84cc Bump version: 0.6.7 → 0.6.8 2016-10-19 15:56:58 -07:00
Job Evers-Meltzer a5d3c0bbe1 rename tests such that trial automatically runs them 2016-10-19 16:38:59 -05:00
Jack Robison d4aa109b73 Merge pull request #193 from lbryio/check-remote-conn
Use lbry.io instead of google to check for internet connection
2016-10-19 15:06:33 -04:00
Jack Robison bdeccb49b8 Merge pull request #191 from lbryio/verify-published-file-exists
make publish fail when given an invalid file
2016-10-19 15:05:33 -04:00
Jack Robison 35ce7bbd61 Merge pull request #195 from lbryio/fail-appveyor
Appveyor build needs to fail when tests fail
2016-10-19 15:04:20 -04:00
Jack 293933163f move USE_AUTH_HTTP to adjustable settings 2016-10-19 14:59:10 -04:00
Jack 22fc26797d pylint fixes 2016-10-19 14:40:01 -04:00
Jack 8a95c8b7af whoops 2016-10-19 14:26:19 -04:00
Jack 33674f8cc3 remove logging in conf, rearrange platform 2016-10-19 00:39:19 -04:00
Jack 6799de645b Merge branch 'master' into refactor-settings
# Conflicts:
#	packaging/osx/lbry-osx-app/lbrygui/LBRYApp.py
#	packaging/windows/lbry-win32-app/LBRYWin32App.py
2016-10-19 00:19:45 -04:00
Jack 06a88599df --http-auth flag to use authentication, refactor settings
settings will prefer, in order:
-defaults
-settings in config file
-settings given as environmental variables
-settings given as command line args
2016-10-19 00:12:44 -04:00
Jack 03877f7ebd remove str 2016-10-18 17:11:45 -04:00
Job Evers-Meltzer 9f2dbd4291 Appveyor build needs to fail when tests fail
According to
https://www.appveyor.com/docs/build-configuration/#script-blocks-in-build-configuration
a build only fails if an exception is thrown. This is causing builds to pass even if
the tests fail. That same link suggests adding the code that is in this commit.
2016-10-18 09:44:21 -05:00
Job Evers 6b7d575e95 use lbry.io to check for an internet connection 2016-10-17 20:11:08 -05:00
Job Evers 640db41555 only need lbrycrdd_path when using lbrycrdd 2016-10-17 19:58:04 -05:00
Jack d860c2a2b4 make publish fail when given an invalid file
otherwise a less obvious error is returned in
lbrynet_daemon.Publisher.Publisher._show_publish_error
2016-10-17 14:25:36 -04:00
Jack 733bb3bccf Bump version: 0.6.6 → 0.6.7 2016-10-16 02:55:19 -04:00
Jack Robison 307751277d Merge pull request #189 from lbryio/include-jsonschema
fix jsonschema includes
2016-10-16 02:54:55 -04:00
Jack 62c2539475 include jsonschema.schemas files 2016-10-16 02:49:19 -04:00
Jack 5b15da2c55 add jsonschema to windows build 2016-10-16 00:29:32 -04:00
Jack 830f5ff6e3 Bump version: 0.6.5 → 0.6.6 2016-10-15 23:35:17 -04:00
Jack ea1f260ed9 Bump version: 0.6.4 → 0.6.5 2016-10-14 23:06:03 -04:00
Jack Robison 3e86254324 Merge pull request #188 from lbryio/fix-DaemonRequest-import
fix DaemonRequest import in apps
2016-10-14 23:04:52 -04:00
Jack b5311dd1c3 fix DaemonRequest import in apps 2016-10-14 23:01:15 -04:00
Jack a8a581d35c Merge branch 'master' into auth-jsonrpc
# Conflicts:
#	lbrynet/conf.py
#	lbrynet/core/Error.py
#	lbrynet/lbrynet_daemon/Daemon.py
#	lbrynet/lbrynet_daemon/DaemonControl.py
#	lbrynet/lbrynet_daemon/ExchangeRateManager.py
2016-10-14 18:25:37 -04:00
Job Evers-Meltzer 5f129faf32 Bump version: 0.6.3 → 0.6.4 2016-10-14 16:06:12 -05:00
Job Evers‐Meltzer 018d78be6f Merge pull request #187 from lbryio/new-metadata-system
Rewrite of migration and validation system using JSON Schema
2016-10-14 15:51:49 -05:00
Alex Liebowitz b5a3929bb5 Fix imports 2016-10-14 16:41:02 -04:00
Alex Liebowitz b67b4b2ef6 Refactor metadata upgrade version range calculation to use generator 2016-10-14 15:58:18 -04:00
Alex Liebowitz bed3f551fd Light refactor of Metadata class 2016-10-14 15:58:04 -04:00
Alex Liebowitz 5b0b8a19ff Add requirements.txt for jsonschema 2016-10-14 15:57:09 -04:00
Alex Liebowitz 988c9595c7 Add default MIME type during publication
Needed because the new JSON schema enforces that the content type is a
string (not null).
2016-10-14 10:37:19 -04:00
Alex Liebowitz 92700808eb Add back current_version attribute to Metadata 2016-10-14 10:37:19 -04:00
Alex Liebowitz 0dd9aa0d67 Update error that daemon catches for malformed metadata
Now jsonschema.ValidationError instead of AssertionError
2016-10-14 10:37:19 -04:00
Alex Liebowitz 9cf1d6b710 Tests for new JSON Schema system 2016-10-14 10:37:18 -04:00
Alex Liebowitz d8d462f43c Convert Metadata and Fee validators to use new JSON Schema-based system 2016-10-14 10:37:18 -04:00
Alex Liebowitz 3f22f39ce1 Refactor Validator to new StructuredDict class that uses JSON Schema
- Uses JSON schema for all validation (so far no custom code needed)
 - Can migrate up and down with any versioning scheme
 - Does migrations with regular dictionary operations instead of a DSL
2016-10-14 10:35:17 -04:00
Job Evers-Meltzer e647663c34 Fix error when version is None
Logs were reporting:

Failure instance: Traceback: <type 'exceptions.AttributeError'>: StrictVersion instance has no attribute 'version'
/Volumes/LBRY/LBRY.app/Contents/Resources/lib/python2.7/lbrynet/lbrynet_daemon/DaemonServer.py:121:requestReceived
twisted/web/server.pyc:183:process
twisted/web/server.pyc:234:render
/Volumes/LBRY/LBRY.app/Contents/Resources/lib/python2.7/lbrynet/lbrynet_daemon/Daemon.py:450:render
--- <exception caught here> ---
twisted/internet/defer.pyc:150:maybeDeferred
/Volumes/LBRY/LBRY.app/Contents/Resources/lib/python2.7/lbrynet/lbrynet_daemon/Daemon.py:1561:jsonrpc_version
/Volumes/LBRY/LBRY.app/Contents/Resources/lib/python2.7/lbrynet/core/utils.py:39:version_is_greater_than
distutils/version.pyc:140:__cmp__
2016-10-14 10:35:17 -04:00
Jack Robison b5987c75da Merge pull request #184 from lbryio/missing-version
Fix error when version is None
2016-10-13 15:02:49 -04:00
Jack Robison 32a973943f Merge pull request #173 from lbryio/blob-prices
Blob prices
2016-10-13 14:59:26 -04:00
Jack 99c060719a clean up test_strategy 2016-10-13 14:00:46 -04:00
Jack d9cd215a60 set seed for strategy tests 2016-10-13 13:48:18 -04:00
Jack 2d3b1fd4eb clean up test_misc 2016-10-13 13:36:22 -04:00
Jack 19c2264429 clean up 2016-10-13 13:35:55 -04:00
Job Evers-Meltzer ae4b984f0b Fix error when version is None
Logs were reporting:

Failure instance: Traceback: <type 'exceptions.AttributeError'>: StrictVersion instance has no attribute 'version'
/Volumes/LBRY/LBRY.app/Contents/Resources/lib/python2.7/lbrynet/lbrynet_daemon/DaemonServer.py:121:requestReceived
twisted/web/server.pyc:183:process
twisted/web/server.pyc:234:render
/Volumes/LBRY/LBRY.app/Contents/Resources/lib/python2.7/lbrynet/lbrynet_daemon/Daemon.py:450:render
--- <exception caught here> ---
twisted/internet/defer.pyc:150:maybeDeferred
/Volumes/LBRY/LBRY.app/Contents/Resources/lib/python2.7/lbrynet/lbrynet_daemon/Daemon.py:1561:jsonrpc_version
/Volumes/LBRY/LBRY.app/Contents/Resources/lib/python2.7/lbrynet/core/utils.py:39:version_is_greater_than
distutils/version.pyc:140:__cmp__
2016-10-11 20:48:29 -05:00
Job Evers‐Meltzer 897c113db1 Merge pull request #180 from lbryio/configure-lbryum
Configure lbryum
2016-10-11 16:46:39 -05:00
Jack 50e5a59420 remove unused imports 2016-10-07 17:29:20 -04:00
alexliebowitz 8735112f70 Merge pull request #182 from lbryio/no-cache-static-file
NoCacheStaticFile
2016-10-07 17:15:35 -04:00
Jack 5a0b5dc680 Merge branch 'master' into auth-jsonrpc
# Conflicts:
#	lbrynet/lbrynet_daemon/Daemon.py
#	lbrynet/lbrynet_daemon/DaemonControl.py
2016-10-07 17:11:43 -04:00
Job Evers‐Meltzer d91e9aa910 Fix Instructions 2016-10-07 16:17:47 -04:00
Jack be1803d558 remove unused imports 2016-10-07 14:52:54 -04:00
Jack 84bbf2f76e move set_no_cache into own function 2016-10-07 14:28:38 -04:00
Jack fe7ea7c679 refactor resources and file streamer into their own files, use NoCacheStaticFile instead of static.File 2016-10-07 14:01:59 -04:00
Jack 782e197e66 Merge branch 'master' into blob-prices 2016-10-05 23:25:39 -04:00
Jack 88be425ab2 fix pylint errors 2016-10-05 23:24:22 -04:00
Jack 7025c5102a skip live transfer 2016-10-05 23:17:45 -04:00
Jack 1ee9b3c7a6 add reply_to_offer to livepaymentratemanager 2016-10-05 23:03:16 -04:00
Jack 4f60a98eb2 fix functional tests, add a few unit tests,
-add ‘generous’ parameter for NegotiatedPaymentRateManager to turn free
hosting on/off, by default set to true.
2016-10-05 22:58:34 -04:00
Job Evers-Meltzer a71e87a398 throw error when invalid wallet is specified 2016-10-04 13:59:04 -05:00
Job Evers-Meltzer 0ecfad0ae9 add configuration to LBRYumWallet 2016-10-04 13:58:44 -05:00
Job Evers-Meltzer e909ae566b add TODO 2016-10-03 16:19:58 -05:00
Jack dc2f0adb3e update LiveStreamPaymentRateManager 2016-10-03 16:54:46 -04:00
Jack 180d981ed8 fix more functional tests 2016-10-03 16:37:27 -04:00
Jack fd9bc6214a fix functional tests 2016-10-03 15:40:27 -04:00
Jack b3f3ed8026 start fixing functional tests 2016-10-03 02:59:40 -04:00
Jack 967700dc28 BlobRequestHandler and Strategy tests 2016-10-03 02:44:58 -04:00
Jack 3ad4ad50ec Bump version: 0.6.2 → 0.6.3 2016-10-02 03:33:12 -04:00
Jack Robison 7f980446db Merge pull request #137 from lbryio/html5
More reliable stream producer
2016-10-02 03:31:54 -04:00
Alex Liebowitz 04ced2e975 Fix import issues in DaemonServer.py 2016-10-02 02:50:17 -04:00
Alex Liebowitz 2253943eba Shorten time between sending chunks of video stream 2016-10-02 02:03:47 -04:00
Alex Liebowitz a6fcd5d1f2 More refactoring in LBRYStreamProducer 2016-10-01 23:35:07 -04:00
Alex Liebowitz f245822814 Refactor of LBRYStreamProducer 2016-10-01 23:35:07 -04:00
Alex Liebowitz aa3aff91d0 Refactor LBRYStreamProducer and add Content-Length header
Also fixes producer pause/unpause behavior and adds slight delay
between sending chunks
2016-10-01 23:33:51 -04:00
Alex Liebowitz 5537dd878f Add basic support for streaming partially downloaded files 2016-10-01 23:29:08 -04:00
Jack 5e4e619708 squelch loud log 2016-10-01 15:20:19 -04:00
Jack d741c705cd add some tests, don't use lighthouse for cost ests 2016-10-01 01:09:27 -04:00
Jack d83abd81f8 job's comments 2016-09-30 14:26:13 -04:00
Jack 640e000b9f fix timeouts in get_availability 2016-09-30 13:35:13 -04:00
Jack 8d961d6ce6 add get_availability 2016-09-30 13:28:01 -04:00
Jack 0a612ba36c Merge branch 'master' into blob-prices 2016-09-30 12:36:10 -04:00
Jack eb7cc8463b Bump version: 0.6.1 → 0.6.2 2016-09-30 11:26:55 -04:00
Jack 50f0430d04 fix broken windows import 2016-09-30 11:26:37 -04:00
Jack 6e5ea935f6 Bump version: 0.6.0 → 0.6.1 2016-09-30 11:18:07 -04:00
Jack c4eb3de5b2 update app imports 2016-09-30 11:17:47 -04:00
Jack f79b651b05 Bump version: 0.5.0 → 0.6.0 2016-09-30 02:16:06 -04:00
Jack c130879ef7 frontload bug
divide availability adjusted price by frontload factor, which will be
close to 1 while index is low and close to 2 when index is high - the
reduction approaches 50% as index goes up.
2016-09-30 00:36:23 -04:00
Jack 5c391f4bb4 remove unnecessary class 2016-09-30 00:12:17 -04:00
Jack b853656aa6 Merge branch 'master' into blob-prices
# Conflicts:
#	lbrynet/core/server/BlobRequestHandler.py
2016-09-30 00:11:53 -04:00
Jack Robison 8222f940b4 Merge pull request #177 from lbryio/blob-request-handler-refactor
refactor BlobRequestHandler
2016-09-29 23:52:14 -04:00
Jack 71b989b29b update from master
resolve merge conflicts:
lbrynet/core/client/BlobRequester.py
lbrynet/core/Peer.py
lbrynet/lbryfilemanager/EncryptedFileManager.py
lbrynet/lbrynet_daemon/Daemon.py
lbrynet/lbrynet_daemon/Publisher.py
2016-09-29 23:34:59 -04:00
Jack Robison 7e2f7e6f68 Merge pull request #170 from lbryio/appveyor-deploy
appveyor updates
2016-09-29 12:51:16 -04:00
Jack Robison aefb6c5dc8 Merge pull request #175 from lbryio/skip-tests
Tests requiring epoll should only run on linux
2016-09-29 12:50:44 -04:00
Jack Robison b892b81dad Merge pull request #172 from lbryio/add-venv-instr
encourage use of virtualenv
2016-09-29 12:50:05 -04:00
Jack Robison 4d63629919 Merge pull request #164 from lbryio/refactor-blob-requester
Refactor blob requester
2016-09-29 12:49:28 -04:00
Jack 4727ee0403 Merge branch 'master' into refactor-blob-requester 2016-09-29 12:48:34 -04:00
Jack Robison fc47e8074f Merge pull request #174 from lbryio/rename-LBRY
Remove LBRY Prefix
2016-09-29 12:47:50 -04:00
Jack ff7829a078 Merge branch 'master' into rename-LBRY 2016-09-29 12:47:22 -04:00
Job Evers-Meltzer d05bbea131 refactor BlobRequestHandler 2016-09-28 17:00:34 -07:00
Job Evers‐Meltzer e08a681c8f Merge pull request #176 from lbryio/start-stream-event
Start stream event
2016-09-28 12:15:56 -07:00
Job Evers-Meltzer 6a72b3683e send Download Started event 2016-09-28 09:07:25 -07:00
Job Evers-Meltzer b201fc331c simplify callback when downloading 2016-09-28 09:06:51 -07:00
Job Evers-Meltzer 27337a9243 appveyor updates
- move init and build steps into dedicated scripts
- deploy msi artifact on tag
2016-09-28 07:38:12 -07:00
Jack b671a3c2ba Merge branch 'master' into blob-prices 2016-09-27 23:59:14 -04:00
Jack 1cc6b7658c get uploads working
-add error catching in exchange rate manager
-add free data on first request with default negotiation strategy
2016-09-27 23:56:08 -04:00
Job Evers-Meltzer 12e2827286 tests requiring epoll should only run on linux 2016-09-27 16:01:47 -07:00
Job Evers-Meltzer 548d37929e more fixes 2016-09-27 12:08:32 -07:00
Job Evers-Meltzer eb783b6b6f rename File to EncryptedFile 2016-09-27 11:26:01 -07:00
Job Evers-Meltzer d1b06c3688 more fixes 2016-09-27 11:18:52 -07:00
Job Evers-Meltzer d16b3429cd more work to fix tests 2016-09-27 11:18:52 -07:00
Job Evers-Meltzer 1e4b5cb450 rename test files 2016-09-27 11:18:52 -07:00
Job Evers-Meltzer a9da6e4bdf run sed on tests too 2016-09-27 11:18:52 -07:00
Job Evers-Meltzer a099e2db6a fix errors 2016-09-27 11:18:52 -07:00
Job Evers-Meltzer 7dbeb1f2cf Remove LBRY prefix from class and module names
This is the result of running:
    grep -RlI LBRY . | xargs sed -i 's/LBRY\([A-Z]\)/\1/g'
2016-09-27 11:18:35 -07:00
Job Evers-Meltzer 550fd185a3 rename LBRYFile to EncryptedFile 2016-09-27 11:18:16 -07:00
Jack 1720cce3b0 negotiated downloads
-uploads are still underway
2016-09-27 13:52:44 -04:00
Job Evers-Meltzer 078b254d1d rename files to remove LBRY prefix 2016-09-25 18:11:23 -07:00
Job Evers-Meltzer 6057dc0804 whitespace 2016-09-25 17:18:29 -07:00
Job Evers-Meltzer 5ea7c4f016 fix typo in string format 2016-09-25 17:17:48 -07:00
Job Evers-Meltzer 4334cdace1 Refactor blob requester to better seperate out the three requests
Each blob requests has three parts
- A request to see what blobs are available
- A request to download and pay for one of those blobs
- A request to negotiate data costs

Before the refactoring all of the code to accomplish this was mixed into
one class.  They are now three seperate classes.

There is still a lot of room for improvement, but it is at least better than
it was.
2016-09-25 16:55:55 -07:00
Alex Grintsvayg 6803bfae99 add more bins to path 2016-09-24 15:48:07 -04:00
Jack c49b0fdd49 Bump version: 0.4.9 → 0.5.0 2016-09-24 01:50:14 -04:00
Jack bf3c56f0ec only run unit tests on windows 2016-09-24 01:47:37 -04:00
Jack Robison bbcecea28d Merge pull request #165 from lbryio/get-my-claim
add get_my_claim, remove is_mine from get_claim_info response
2016-09-24 01:01:51 -04:00
Jack a936782ddc fix amount formatting between get_claim_info and get_my_claim 2016-09-24 00:58:54 -04:00
Jack 7ac0fc5a24 convert amount 2016-09-24 00:49:03 -04:00
Jack e115158f86 docstring 2016-09-23 03:04:59 -04:00
Jack bf34fa39b4 unused import 2016-09-23 03:03:15 -04:00
Jack 5dd29da84f blob upload/download history and BlobPriceAndAvailabilityTracker 2016-09-23 03:02:17 -04:00
Job Evers-Meltzer 2107ffdd18 encourage use of virtualenv 2016-09-22 10:19:28 -07:00
Jack 492fc510fa move _get_my_unspent_claim to function 2016-09-21 22:10:19 -04:00
Jack Robison c75d240a65 Merge pull request #169 from lbryio/functional-tests
Enable functional tests
2016-09-21 22:05:16 -04:00
Jack dbeb6bc3bc update uri handler 2016-09-21 21:55:10 -04:00
Jack 4d79a7828c more cleaning up 2016-09-21 21:36:06 -04:00
Jack aecafbbebd clean up 2016-09-21 03:49:52 -04:00
Jack 130f9cfc4d api sessions
-user starts a httpauthsession with an api key and name
-user initializes jsonrpc hmac secret to sha256 of session id
-server sends new random hmac secret after each api call

-a user without an authenticated session will get a authorization error
2016-09-20 16:58:30 -04:00
Job Evers-Meltzer 98d02b3fce [ci skip] add newlines 2016-09-19 12:07:47 -07:00
Jack 4d52a33ee5 Bump version: 0.4.8 → 0.4.9 2016-09-16 04:12:55 -04:00
Jack 7ad916f116 fix api being blocked for /? pages 2016-09-16 04:12:13 -04:00
Jack 05b47a9180 Bump version: 0.4.7 → 0.4.8 2016-09-16 03:56:14 -04:00
Jack Robison 9a412bbc76 Merge pull request #168 from lbryio/fewer-desktop-shortcuts
no extra desktop shortcuts in windows
2016-09-16 03:50:04 -04:00
Jack Robison b3a16f95f7 Merge pull request #167 from lbryio/block-api-requests-by-referer
block api requests by referer
2016-09-16 03:49:55 -04:00
Jack 871b3be09a no extra desktop shortcuts 2016-09-16 03:42:25 -04:00
Jack 7085b1e3c3 block api requests by referer 2016-09-16 03:40:06 -04:00
Jack Robison a9e4343775 Merge pull request #166 from lbryio/daemon-settings-yml
.yml daemon settings file
2016-09-16 01:22:20 -04:00
Jack 3d4d895d9b fix windows requirement 2016-09-16 01:14:56 -04:00
Jack 3d89e3fd93 add to appveyor.yml 2016-09-16 01:08:43 -04:00
Jack a8e2dd3f2a add pyyaml to requirements.txt 2016-09-16 00:57:30 -04:00
Jack 3ae0664fa9 use prettier file format for daemon conf file 2016-09-16 00:14:25 -04:00
Jack 98b9f2cf73 Bump version: 0.4.6 → 0.4.7 2016-09-15 23:06:56 -04:00
Jack Robison 6fa65ebb9f Merge pull request #163 from lbryio/windows-cli
fix windows cli
2016-09-15 22:57:44 -04:00
Jack add163a092 move get_params to own function, add some tests 2016-09-15 22:20:00 -04:00
Jack fcfed3f441 add get_my_claim and get rid of is_mine in get_claim_info 2016-09-15 20:15:20 -04:00
Jack 7b84d9b10a handle no params 2016-09-15 15:04:42 -04:00
Jack e9a1dbca4b fix windows cli
make cli easier to use on windows by converting keyword args to json

cli now accepts commands like:

lbrynet-cli resolve_name name=one

as well as:

lbrynet-cli resolve_name ‘{“name”: “one”}’
2016-09-15 14:47:32 -04:00
Jack 145a2654d2 Bump version: 0.4.5 → 0.4.6 2016-09-15 12:36:37 -04:00
Jack Robison 9f14cdb1d7 Merge pull request #162 from lbryio/fix-appveyor
fix appveyor error
2016-09-15 12:36:02 -04:00
Jack 5cefa2e995 set default logger in __init__ 2016-09-15 12:19:49 -04:00
Jack 13cbe0fd42 fix appveyor error 2016-09-14 23:03:18 -04:00
Jack Robison c8bb0c0bc8 Merge pull request #161 from lbryio/delete-lbry-file-without-claim
Delete lbry file with abandoned claim
2016-09-14 22:41:43 -04:00
Jack 4cc941fbec make abandon_claim compatible with old function name 2016-09-14 22:36:18 -04:00
Jack b010192f8e improve logging 2016-09-14 22:28:59 -04:00
Jack 2b1af8eea2 delete lbry file with an abandoned claim 2016-09-14 22:27:57 -04:00
Jack 6ea1f6f78c block api calls from bad origins 2016-09-14 17:39:19 -04:00
Alex Grintsvayg 1215470cc1 MIT license 2016-09-13 22:10:12 -04:00
Jack Robison 94195b7018 Merge pull request #160 from lbryio/allow-retry-after-timeout
Allow download attempts after having timed out and lower the name cache time
2016-09-13 15:17:13 -04:00
Jack 3c9c178bdc fix conf update 2016-09-12 15:44:56 -04:00
Jack cc64547920 Bump version: 0.4.4 → 0.4.5 2016-09-12 15:42:48 -04:00
Jack a23f2ca956 allow more download attempts after having timed out
-also lower the name cache time
2016-09-12 15:39:19 -04:00
Jack Robison 4dacc52ecb Merge pull request #159 from lbryio/rename-abandon-name
Include unconfirmed balance and rename abandon_name
2016-09-12 14:50:45 -04:00
Jack ccaeecfd46 bug fix 2016-09-12 13:17:21 -04:00
Jack 3e45449e8c return unconfirmed balance 2016-09-12 13:16:56 -04:00
Jack f352a3c597 rename abandon_name to abandon_claim 2016-09-12 13:16:03 -04:00
Job Evers-Meltzer d9a08f0c03 import unittest 2016-09-09 23:44:07 -07:00
Job Evers-Meltzer c77f24dde3 skip instead of fix tests 2016-09-09 23:39:35 -07:00
Job Evers-Meltzer 48c31a2119 remove redundant reflector test 2016-09-09 23:37:51 -07:00
Job Evers-Meltzer 5a578d6d79 enable functional tests 2016-09-09 23:29:46 -07:00
Jack 8cdbc847d1 add get_search_servers to allowed_during_startup 2016-09-09 05:11:51 -04:00
Jack 54dbf66cb7 update secure vars for appveyor 2016-09-09 04:14:56 -04:00
Jack 177d384126 Bump version: 0.4.3 → 0.4.4 2016-09-09 04:12:42 -04:00
Jack Robison 561fe757f3 Merge pull request #152 from DaveA50/master
Fix shortcut icons
2016-09-09 04:09:48 -04:00
Jack Robison c670ab638f Merge pull request #158 from lbryio/get-search-servers
add get_search_servers
2016-09-09 04:04:51 -04:00
Jack eea5cbbafc add get_search_servers 2016-09-09 04:04:35 -04:00
Jack Robison e4c61a4a13 Merge pull request #155 from lbryio/get-block-by-height
add 'height' parameter to get_block
2016-09-09 00:57:51 -04:00
Jack 0f0afadc94 add 'height' parameter to get_block 2016-09-09 00:48:54 -04:00
Alex Grintsvayg 659563f27a fix indent 2016-09-08 13:41:11 -04:00
Alex Grintsvayg cbd8a68d0f print actual json 2016-09-08 13:40:43 -04:00
Jack Robison 54229282a4 Merge pull request #149 from lbryio/address-is-mine
Add address_is_mine() API method
2016-09-06 13:09:08 -04:00
David Amrhein 514575d0f1 Fix Shortcuts icons 2016-09-03 14:39:39 -04:00
David Amrhein 756427560c Attempt to fix CannotListenError 2016-09-02 16:04:27 -04:00
Alex Liebowitz 900eeb177a Add address_is_mine() API method 2016-09-02 01:27:30 -04:00
David Amrhein e67fa3cadc Merge remote-tracking branch 'origin/master' 2016-09-01 10:31:20 -04:00
Dave-A c7c32fd4dc Merge pull request #12 from lbryio/master
Update
2016-09-01 10:30:23 -04:00
Jack 9471748f4c Bump version: 0.4.2 → 0.4.3 2016-09-01 01:35:44 -04:00
Jack Robison 920b1868bb Merge pull request #148 from lbryio/windows-setup
sign msi on appveyor, add command line to msi, remove leveldb requirement
2016-09-01 01:25:02 -04:00
Jack Robison eed7c54aaf Merge pull request #146 from kaykurokawa/fix_lbryum_getbalance
Use new exclude_claimtrietx option in lbryum getbalance command, fix maturity use
2016-09-01 01:24:08 -04:00
Jack 36e58a33ad delete old windows setup.py 2016-09-01 01:09:38 -04:00
Jack 93e8ff749c another try 2016-09-01 00:47:38 -04:00
Jack 6cb22444ac try fixing signtool again 2016-09-01 00:40:06 -04:00
Jack 78df101473 add quotes 2016-09-01 00:29:57 -04:00
Jack 840508b8ba add signtool to the env path 2016-09-01 00:19:02 -04:00
Jack 2761254790 fix pfx decryption 2016-08-31 23:54:00 -04:00
Jack f47d174f0b fix file 2016-08-31 23:09:01 -04:00
Jack c50fbc7935 fix path 2016-08-31 23:02:07 -04:00
Jack 75f23a1723 sign msi 2016-08-31 23:00:16 -04:00
Jack f0aa31f9e8 unused import 2016-08-31 20:45:49 -04:00
Jack aaf59218da comment out migrate0to1 import 2016-08-31 20:41:29 -04:00
Jack 0203ef66ea build windows in setup.py, drop leveldb requirement 2016-08-31 20:20:07 -04:00
Jack Robison 9c66108dc5 Merge pull request #142 from lbryio/skip-dust
skip dust transactions
2016-08-30 20:29:56 -04:00
kkurokawa 558da0a027 Using new exclude_claimtrietx option in lbryum's getbalance command. Fixing incorrect use of maturity. 2016-08-29 22:33:10 -04:00
Jack 1d39ec0317 Bump version: 0.4.1 → 0.4.2 2016-08-29 16:41:48 -04:00
Jack Robison 281b6468a0 Merge pull request #145 from lbryio/appveyor
build msi in appveyor
2016-08-29 16:39:46 -04:00
Jack Robison 9ba6da1f4d set development version to false 2016-08-29 16:28:49 -04:00
Jack bde7a7fed6 use normal lighthouse servers 2016-08-29 16:27:45 -04:00
David Amrhein 7e021746e4 Merge remote-tracking branch 'origin/master' 2016-08-29 16:22:16 -04:00
Dave-A a61bb5f528 Merge pull request #11 from lbryio/master
Update
2016-08-29 16:21:55 -04:00
Jack 6a5289b2a2 add master to branches 2016-08-29 15:50:54 -04:00
Jack 081a5df82c notifications 2016-08-29 15:24:55 -04:00
Jack 3e77ec8008 add slack notifications 2016-08-29 15:21:06 -04:00
Jack b0b222afa8 add errback 2016-08-29 14:55:26 -04:00
Jack d85d6f627d Merge branch 'master' into appveyor 2016-08-29 14:48:05 -04:00
Jack 9505f93da6 skip reflector test on windows 2016-08-29 14:47:54 -04:00
Jack 1671034330 fix json bug 2016-08-29 14:33:56 -04:00
Jack 3f0ca563e4 json encode metadata just before sending it 2016-08-29 14:26:20 -04:00
Jack ffa2a5e8fd skip pylint for now 2016-08-29 13:48:45 -04:00
Jack c3633895d0 Merge branch 'master' into appveyor 2016-08-29 13:46:08 -04:00
Jack c15af0a63a Bump version: 0.4.0 → 0.4.1 2016-08-29 13:44:46 -04:00
Jack 56e2d77039 fix _send_name_claim json 2016-08-29 13:44:18 -04:00
Jack 2cf6fa14a1 pylint path 2016-08-29 00:34:24 -04:00
Jack c374725255 test_script 2016-08-28 23:11:24 -04:00
Jack babfb6b8d6 add . to appveyor file, try tests 2016-08-28 23:05:40 -04:00
Jack 2ffa8ec7d0 use yml generated from appveyor 2016-08-28 19:26:37 -04:00
Jack b516119224 build appveyor branch only 2016-08-28 19:23:16 -04:00
Jack c0e6bb97d8 remove lbrynet_gui include 2016-08-28 17:33:30 -04:00
Jack cc30223ff1 don't cd to lbry in init 2016-08-28 16:42:07 -04:00
Jack 53c8748942 try again 2016-08-28 16:20:28 -04:00
Jack b3a8966e71 fix path 2016-08-28 15:42:14 -04:00
Jack 74800a0767 download lbrynet tar.gz 2016-08-28 15:34:04 -04:00
Jack cadd1f993d clone lbryio/lbry repo in appveyor build script 2016-08-28 15:10:29 -04:00
David Amrhein d3807cb86c Python script for win registry 2016-08-28 14:33:46 -04:00
Dave-A 735e9195b5 Merge pull request #10 from lbryio/master
Update
2016-08-28 14:14:08 -04:00
Jack a6619a628e flag to use development lighthouse servers 2016-08-28 05:25:48 -04:00
Jack 456572f87c Bump version: 0.3.22 → 0.4.0 2016-08-28 05:01:49 -04:00
Jack f024b96934 allow int fee amount 2016-08-28 03:09:36 -04:00
Jack Robison 25c71bcd98 Merge pull request #140 from lbryio/reflect-blobs
reflect_all_blobs daemon command
2016-08-28 01:33:13 -04:00
Jack Robison 319e7ecc61 Merge pull request #131 from lbryio/content_type
change content-type to content_type, refactor metadata validation
2016-08-28 01:29:51 -04:00
Jack Robison d9ece5e96a Merge pull request #143 from lbryio/sandbox-displayed-files
prevent lbry files opened through the ui from making api calls
2016-08-28 01:28:56 -04:00
Jack Robison 4bfe4450b1 Merge pull request #144 from lbryio/pr/141
Add windows URI Handling
2016-08-28 01:28:12 -04:00
Jack f9f12ffb61 move uri handler to packaging/uri_handler 2016-08-28 01:10:28 -04:00
Jack 63f81d1033 prevent a lbry files opened through the ui from making api calls 2016-08-27 23:16:48 -04:00
Jack 8895d21abf skip dust transactions 2016-08-27 02:42:20 -04:00
David Amrhein 2ac1ebeaa0 Temp solution for distributing the regedit for windows URI handling 2016-08-27 01:37:25 -04:00
David Amrhein 25437602d7 Add URI handling as an arg 2016-08-27 01:32:28 -04:00
Jack Robison 8159c71950 update os x instructions 2016-08-26 22:13:04 -04:00
Jack aa66af7ba6 fix tests 2016-08-26 20:22:11 -04:00
Jack be3633622c whoops 2016-08-26 20:13:10 -04:00
Jack 31655a641c fix setup.py 2016-08-26 19:59:17 -04:00
Jack b235f6fc6b send all blobs to reflector 2016-08-26 19:58:53 -04:00
Jack Robison 76b297b173 Merge pull request #139 from lbryio/get_all_verified_blobs
Get all verified blobs
2016-08-26 19:45:49 -04:00
Jack Robison 1e5cff1d8b Merge pull request #130 from lbryio/osx-command-line-install
add os x install script to replace out of date and non existent one in lbry-setup
2016-08-26 16:08:08 -04:00
Jack Robison 4e2296d5f6 Merge pull request #115 from lbryio/get-stream-timeout
raise Exception on GetStream timeout
2016-08-26 16:07:42 -04:00
Dave-A 18310632eb Merge pull request #9 from lbryio/master
Update
2016-08-26 10:16:46 -04:00
Jack 80ed8d9869 Bump version: 0.3.21 → 0.3.22 2016-08-26 00:56:06 -04:00
Jack 2a2658d440 fix Access-Control-Allow-Origin problem 2016-08-26 00:50:31 -04:00
Jack 710e549c03 add get_all_verified_blobs 2016-08-26 00:32:33 -04:00
Jack 47fae977dd fix Access-Control-Allow-Origin problem 2016-08-25 23:39:05 -04:00
Alex Grintsvayg 0111919975 jack fixed the unicode bug here 2016-08-25 19:09:55 -04:00
Jack 80837cb040 Merge branch 'master' into content_type
fix conflicts:
	lbrynet/lbrynet_daemon/LBRYPublisher.py
2016-08-25 17:59:20 -04:00
Jack 46153a8991 second shot at pylint error 2016-08-23 02:25:32 -04:00
Jack a9fccfd4ce fix pylint error 2016-08-23 02:17:32 -04:00
Dave-A dfb57e9438 Merge pull request #8 from lbryio/master
Update version
2016-08-23 02:17:29 -04:00
Jack eda2731702 Bump version: 0.3.20 -> 0.3.21 2016-08-23 01:59:50 -04:00
Jack Robison f47eac5935 Merge pull request #136 from DaveA50/master
Add Windows support
2016-08-23 01:53:50 -04:00
David Amrhein 3bb4dece5a Use main lbry repo for gmpy wheel url 2016-08-23 01:26:35 -04:00
David Amrhein 0504e231a1 Use main lbryum repo 2016-08-23 01:16:04 -04:00
David Amrhein 6097e14617 Make systray thread a daemon to close on api.stop() 2016-08-23 01:05:07 -04:00
David Amrhein 0b149ce5f1 Remove old osx imports 2016-08-22 21:21:56 -04:00
Dave-A 79384e7bf8 Merge pull request #7 from lbryio/master
Update
2016-08-22 20:02:35 -04:00
Jack Robison 01eb79cac2 Merge pull request #135 from lbryio/lbrycrdwallet-updateclaim-fix
LBRYcrdWallet update claim fix
2016-08-22 19:58:28 -04:00
Jack 128b32c62c even less noisy logs 2016-08-22 19:56:42 -04:00
David Amrhein c1233bd26b Make 'rb' file mode windows specific 2016-08-22 19:55:08 -04:00
David Amrhein e23f67def6 File handle for publishing on windows needs to handle binary data as 'rb' 2016-08-22 19:24:57 -04:00
Jack 95f4b29be5 noisy log 2016-08-22 18:59:17 -04:00
Jack 5727c708cf fix get_transaction
previously get_tx_json was only in LBRYumWallet
2016-08-22 18:43:52 -04:00
Jack e49f0f99a1 LBRYcrdWallet update claim fix
-fix log line that could raise an exception
-json encode value sent to lbrycrd-cli updateclaim
2016-08-22 16:57:22 -04:00
David Amrhein 84d340382b Fix for icon path when running shortcut 2016-08-21 18:58:50 -04:00
David Amrhein 5bfb067d0f Rename to just Open 2016-08-21 18:49:41 -04:00
David Amrhein d8cb62a92c Run win32 as systray app 2016-08-21 18:44:16 -04:00
Dave-A aab8cc40f9 Merge pull request #6 from lbryio/master
Update from Origin
2016-08-21 14:13:59 -04:00
Jack 9c82689f65 Bump version: 0.3.19 -> 0.3.20 2016-08-21 04:04:11 -04:00
Jack Robison ce2755467d Merge pull request #133 from sonatagreen/patch-1
spelling fix
2016-08-21 03:44:10 -04:00
Jack Robison 02b19402ae Merge pull request #116 from lbryio/reflector
Backend for pushing newly created files to a designated server
2016-08-21 03:43:03 -04:00
Jack 80af66e852 Merge branch 'master' into reflector
# Conflicts:
#	lbrynet/core/log_support.py
2016-08-21 01:12:29 -04:00
Jack 15cfa45646 remove duplicate function 2016-08-21 00:58:25 -04:00
Jack Robison ac63849b49 Merge pull request #132 from lbryio/fix-get-history
fix get_history in lbrycrdwallet
2016-08-21 00:07:41 -04:00
Jack Robison 02142e352b Merge pull request #127 from lbryio/disable-more-noisy-loggers
reduce logging to sub fire hazard levels
2016-08-21 00:07:19 -04:00
Jack 3d92413372 debug logging 2016-08-20 23:47:41 -04:00
Jack 5022ed2acc blob_completed before moving to next one
otherwise blob files download to the blobfiles directory, but they are
never recorded in blobs.db
2016-08-20 23:47:12 -04:00
Sonata Green 31b9d22649 spelling fix 2016-08-19 21:12:02 -05:00
Jack 7a54894015 debugging stuff 2016-08-19 02:41:23 -04:00
Jack 7100345a09 Merge branch 'master' into reflector 2016-08-18 22:42:27 -04:00
Jack 929db15214 fix get_history in lbrycrdwallet 2016-08-18 22:15:49 -04:00
Jack d9455926c5 Merge branch 'master' into content_type 2016-08-18 21:56:55 -04:00
David Amrhein ba5cd741e1 Testing copying instead of moving upload file to avoid access error 2016-08-18 10:45:03 -04:00
Dave-A 8c94b6243e Merge pull request #5 from lbryio/master
Update to 0.3.19
2016-08-18 10:38:07 -04:00
Jack f6473e3383 Bump version: 0.3.18 -> 0.3.19 2016-08-18 06:41:17 -04:00
Jack Robison 3cd9d6a604 Merge pull request #129 from kimihiro64/patch-2
Proper no-cache for web-ui index.html
2016-08-18 06:39:11 -04:00
Jack 142281777e stop heartbeat looping call on shutdown 2016-08-18 06:37:57 -04:00
Jack 8e7b8af180 call blob_completed when is_validated is true 2016-08-18 06:23:27 -04:00
Jack c046cd02d5 call blob_completed after receiving blob 2016-08-18 05:58:13 -04:00
Jack f5508fcdf1 typo 2016-08-18 05:36:17 -04:00
Jack adc2eab6da log request dict 2016-08-18 05:36:01 -04:00
Jack 702698d8aa stop heartbeat looping call on shutdown 2016-08-18 05:25:23 -04:00
David Amrhein 73dbe1de37 Fix relative pathing for cacert for win builds 2016-08-18 01:25:48 -04:00
Jack c5706fa28b fix imports in tests 2016-08-18 00:38:38 -04:00
Jack c906a9571e add service identity 2016-08-18 00:31:05 -04:00
Jack 038712f431 install script 2016-08-18 00:30:57 -04:00
David Amrhein ed2d2c6f86 Ignore msi_data shortcuts, which didn't work anyway 2016-08-18 00:13:31 -04:00
kimihiro64 e7158e5a4b Fix editor spacing again 2016-08-17 23:02:38 -05:00
kimihiro64 c66df259a6 fix editor spacing 2016-08-17 23:02:00 -05:00
kimihiro64 0b8437fa12 Proper no-cache for web-ui index.html 2016-08-17 22:34:20 -05:00
Jack a32b6ebf82 add reflect jsonrpc command 2016-08-17 21:33:41 -04:00
Jack edbda1696e logging fire hazard 2016-08-17 20:24:48 -04:00
Jack ece218785c reduce logging to sub fire hazard levels 2016-08-17 20:20:03 -04:00
Jack cc1b3609a1 Merge branch 'master' into reflector
# Conflicts:
#	lbrynet/__init__.py
2016-08-17 19:01:38 -04:00
Alex Grintsvayg 0841aad07a fix double-tab bug on linux 2016-08-17 14:30:56 -04:00
David Amrhein 30b04ed0c2 Change naming conventions 2016-08-17 14:25:02 -04:00
David Amrhein 90b28b3dbd Pass WindowsError when moving uploaded file 2016-08-17 14:15:55 -04:00
Jack 0f7ca8f24e move metadata and validator classes into their own directory 2016-08-17 12:28:15 -04:00
David Amrhein 726d85ebd0 Remove blindrepeater.yapsy-plugin from build 2016-08-17 12:13:47 -04:00
David Amrhein c524de9198 Update protobuf out of beta 2016-08-17 12:12:28 -04:00
Dave-A 2fbf03d8ca Merge pull request #4 from lbryio/master
Update from lbry
2016-08-17 12:03:08 -04:00
Jack 68b8112af0 Merge branch 'master' into content_type 2016-08-17 03:04:14 -04:00
Jack 975e83a015 Bump version: 0.3.17 -> 0.3.18 2016-08-17 02:39:48 -04:00
Jack 1ddb02dbb7 speed up search
get results for get_est_cost from lighthouse instead of manually trying
unless force=True
2016-08-17 02:38:59 -04:00
Jack Robison 1159204ed8 Merge pull request #126 from lbryio/pretty-dmg
Make a pretty dmg
2016-08-17 01:36:44 -04:00
Jack Robison a5212e7741 Merge pull request #121 from lbryio/save-settings
Save settings
2016-08-17 01:34:50 -04:00
Jack Robison 1932fd72e3 Merge pull request #123 from lbryio/add-heartbeat
Add basic analytics api and heartbeat event
2016-08-17 01:34:31 -04:00
Jack Robison c061fe091b Merge pull request #122 from lbryio/add-debug-logging
Add debug logging
2016-08-17 01:33:07 -04:00
Jack Robison 3621983a4d Merge pull request #119 from lbryio/update-protobuf
Update protobuf
2016-08-17 01:31:48 -04:00
Dave-A b6656690ca Merge pull request #3 from lbryio/master
Update from lbry
2016-08-16 21:13:24 -04:00
David Amrhein 0c9e82ee6b Update appveyor to DaveA50 git repo links 2016-08-16 20:04:11 -04:00
David Amrhein b8ebb1faf1 Convert to lbryum github repo 2016-08-16 19:58:47 -04:00
David Amrhein 690575193f Add gmpy windows wheel 2016-08-16 18:01:18 -04:00
David Amrhein 9e9cf63c90 Add appveyor.yml build script 2016-08-16 17:54:36 -04:00
Job Evers-Meltzer f5dc213e53 need to not be in build dir 2016-08-16 15:16:55 -05:00
Job Evers-Meltzer 138e9c1486 throw more things at wall 2016-08-16 15:03:41 -05:00
Job Evers-Meltzer 7053c0dc93 argh. so much hate 2016-08-16 14:52:08 -05:00
Job Evers-Meltzer ee8a653b13 argh. so much hate 2016-08-16 14:43:49 -05:00
Job Evers-Meltzer 71fad7e97f also need wheel 2016-08-16 13:41:04 -05:00
Job Evers-Meltzer 04740eb928 need to detect if ON_TRAVIS earlier 2016-08-16 13:24:38 -05:00
Job Evers-Meltzer 8c63d58c96 tmp: debug travis 2016-08-16 13:21:38 -05:00
Job Evers-Meltzer 991672d423 move pyobj building earlier 2016-08-16 13:16:25 -05:00
Job Evers-Meltzer 55ce38cc87 temp: debug travis 2016-08-16 12:52:55 -05:00
Job Evers‐Meltzer 96f3390407 Merge pull request #120 from lbryio/defer-later
replace callLater with deferLater
2016-08-16 12:36:43 -05:00
Job Evers-Meltzer aa2426d4e4 ignore DS_Store files 2016-08-16 12:26:19 -05:00
Job Evers-Meltzer d0e3e13852 ignore osx build artifacts 2016-08-16 12:25:35 -05:00
Job Evers-Meltzer a2a1e30d68 remove unnecessary libgmp 2016-08-16 12:25:18 -05:00
Job Evers-Meltzer a6f08b9e0c Prettifies the osx dmg
Adds a new background image, along with precisely located icon files.
Also updates the icon files to have white backgrounds. The icon files were
created using the 256px icon used in the ubuntu build.
2016-08-16 12:22:14 -05:00
David Amrhein e70842a38c Better fix for finding protobuf namespace 2016-08-15 23:09:46 -04:00
David Amrhein 2af98d7d42 Add loggly and request futures to includes 2016-08-15 20:48:27 -04:00
David Amrhein f28eee34e8 Merge remote-tracking branch 'origin/master' 2016-08-15 20:31:59 -04:00
Dave-A 208610b645 Merge pull request #2 from lbryio/master
Update from base
2016-08-15 20:31:31 -04:00
David Amrhein e38f8076bc Create site-package protobuf __init__ if needed 2016-08-15 19:40:32 -04:00
David Amrhein 6180e1a48b Update to build and distribute >v0.3.12 2016-08-15 19:19:26 -04:00
Jack e8fe1cd14d more test fixes 2016-08-15 18:39:09 -04:00
Jack 75d1fa585c fix tests 2016-08-15 18:30:14 -04:00
Jack 072ff4b02e fix tests 2016-08-15 18:13:36 -04:00
Jack d8c4e2a72e whoops 2016-08-15 17:54:43 -04:00
Jack 66396de6a3 remove as_json and serialize 2016-08-15 17:41:38 -04:00
Jack 1ca9f575ef decorator prettiness 2016-08-15 17:07:50 -04:00
Jack 272e074a15 change content-type to content_type, make changing metadata easier 2016-08-14 01:00:49 -04:00
Job Evers 9a738c3783 Add basic analytics api and heartbeat event 2016-08-12 13:37:26 -05:00
Jack 6b4519e959 squelch very verbose dht error log 2016-08-12 10:46:05 -05:00
Job Evers-Meltzer 9b1d5213a6 improve logging 2016-08-12 10:44:37 -05:00
Job Evers-Meltzer f9ed9a4505 fixup logging some more 2016-08-12 10:42:31 -05:00
Job Evers-Meltzer 3ed7ce5630 Ensure settings are actually committed
Without committing or closing the db, settings were not being saved.

Also, adds a run_in_thread decorator to simplify the code.
2016-08-12 10:08:21 -05:00
Job Evers 63cd8343c4 replace callLater with deferLater 2016-08-11 13:41:42 -05:00
Jack 2d5f8aed24 whitespace 2016-08-11 12:38:10 -04:00
Jack b8d23d0965 add announce_all_blobs_to_dht 2016-08-11 12:36:13 -04:00
Job Evers-Meltzer f4ef92e653 fixup logging some more 2016-08-11 05:37:45 +00:00
Job Evers-Meltzer c7430f4ae9 better more logging on the server side 2016-08-11 05:25:45 +00:00
Job Evers-Meltzer 623fda3087 improve logging 2016-08-11 05:16:50 +00:00
Job Evers-Meltzer 80f27f2b29 Revert "more logging on the server side"
This reverts commit f83daa5a22.
2016-08-11 05:11:18 +00:00
Jack defbd73b4f squelch very verbose dht error log 2016-08-11 01:07:51 -04:00
Jack 5285982515 resolve reflector ip 2016-08-11 01:07:51 -04:00
Job Evers-Meltzer f83daa5a22 more logging on the server side 2016-08-11 04:45:25 +00:00
Job Evers-Meltzer 0a07c8f131 log on closed/lost connection 2016-08-10 19:39:28 -05:00
Job Evers-Meltzer 35481a92f5 actually cleanup patched time.time 2016-08-10 19:36:52 -05:00
Job Evers-Meltzer 0995d864e8 connectTCP wants an ip address, not a url 2016-08-10 19:09:20 -05:00
Job Evers-Meltzer 1a42e43573 log all the things 2016-08-10 19:06:26 -05:00
Jack 132aa569fe move run_reflector_server into settings file and add debug lines 2016-08-10 16:51:46 -04:00
Job Evers-Meltzer e93a787bd6 update protobuf out of beta 2016-08-10 09:28:13 -05:00
Job Evers-Meltzer d6f902653f put import in alphabetical order 2016-08-10 08:35:15 -05:00
Job Evers-Meltzer d172d43ddf add reflector functional test to travis 2016-08-10 08:29:44 -05:00
Job Evers-Meltzer 67909724e7 fix up import paths 2016-08-10 07:44:41 -05:00
Jack 1c88cbc5f6 Merge branch 'master' into reflector 2016-08-10 02:31:28 -04:00
Jack 3fb4831804 raise exception when curr_pos > 100 and json fails to decode 2016-08-10 02:30:41 -04:00
Jack b65570fb16 drop connection on response longer than 100 bytes that can't' be decoded 2016-08-09 19:53:13 -04:00
Jack 871e6e6f64 remove files that didn't fix test 2016-08-09 17:53:34 -04:00
Jack 0cd92a96c0 add reflector files to tests directory 2016-08-09 17:46:25 -04:00
Jack ff31ddd2d5 Bump version: 0.3.16 -> 0.3.17 2016-08-09 14:40:18 -04:00
Jack e9f5b43785 fix exceptions 2016-08-09 14:29:59 -04:00
Jack 36b41081ab Bump version: 0.3.15 -> 0.3.16 2016-08-09 12:41:11 -04:00
Jack Robison 1092313892 Merge pull request #118 from lbryio/add-LBRYDaemonRequest
add LBRYDaemonRequest to os x app
2016-08-09 12:35:08 -04:00
Jack Robison ce605cb8f3 Merge pull request #117 from lbryio/update-lbrycrdd
use most recent lbrycrdd release on github
2016-08-09 12:32:40 -04:00
Jack 0733d885fb start reflector upload in publish 2016-08-09 12:26:34 -04:00
Jack ef6fe3d1d9 add variable to enable running reflector server 2016-08-09 12:18:46 -04:00
Jack 82a4fea81a fix log statement 2016-08-09 12:12:40 -04:00
Jack 14a0252819 hooking up reflector plumbing 2016-08-09 12:07:26 -04:00
Job Evers-Meltzer 849aeb65f0 use most recent lbrycrdd release on github 2016-08-09 11:03:40 -05:00
Jack a99dc6e93d add LBRYDaemonRequest to os x app 2016-08-09 11:19:01 -04:00
Alex Liebowitz 1a5fcc1348 Add requests_futures dependency 2016-08-09 07:59:27 -04:00
Jack c9d88f5628 Bump version: 0.3.14 -> 0.3.15 2016-08-09 03:29:51 -04:00
Jack Robison 0910711aca Merge pull request #111 from lbryio/update-claim
claim updates
2016-08-09 03:29:12 -04:00
Jack 6a1a9ef6bc encode claim id to be shown in log 2016-08-09 03:25:20 -04:00
Jack ef1c059079 clean up log line 2016-08-09 03:18:44 -04:00
Jack a05ab37373 Merge branch 'master' into update-claim
# Conflicts:
#	lbrynet/lbrynet_daemon/LBRYDaemon.py
2016-08-09 03:09:06 -04:00
Jack 7ea88cfd22 crudely fix loggly import problem 2016-08-09 03:01:33 -04:00
Jack Robison 8d14fe6a90 Merge pull request #113 from lbryio/log-to-loggly
Log to loggly
2016-08-09 02:30:55 -04:00
Jack Robison 49a05b42f9 Merge pull request #114 from lbryio/no-unused-imports
Remove all unused imports; add check to pylint
2016-08-09 02:30:49 -04:00
Jack b6da1d7769 decode and reverse claim id for updateclaim in lbryum 2016-08-09 01:26:55 -04:00
Jimmy Kiselak 7e2ad58edd get reflector client and server working; add func test to prove it 2016-08-09 00:59:50 -04:00
Jack 7ad0d98404 Merge branch 'master' into update-claim 2016-08-08 21:39:41 -04:00
Jack b7052bba95 rename variable 2016-08-08 21:34:05 -04:00
Jack 4a5618bcc4 get update claim working with lbryumwallet 2016-08-08 21:32:39 -04:00
Job Evers-Meltzer c1850fe604 raise Exception on GetStream timeout 2016-08-08 16:26:33 -05:00
Job Evers-Meltzer fccdf32c9f Remove all unused imports; add check to pylint 2016-08-08 15:42:35 -05:00
Jack c474411e1b delete bad records that got into name_metadata 2016-08-08 16:35:55 -04:00
Job Evers-Meltzer 9033eac5b1 Remove commented code 2016-08-08 15:07:25 -05:00
Job Evers-Meltzer 0ba0426591 Refactor lbrycrdd path function for osx 2016-08-08 15:06:48 -05:00
Job Evers-Meltzer 9a9b540701 Move some ServerRequestHandling logging to debug level 2016-08-08 15:04:50 -05:00
Job Evers-Meltzer b8ddbb9a26 Add loggly logger
It configured twice, once right at startup without the lbry id and then
after the settings database is available it gets reconfigured with the
lbry id and a session id.
2016-08-08 15:02:36 -05:00
Job Evers-Meltzer bc3c2b96ed disable noisy loggers 2016-08-08 14:59:30 -05:00
Job Evers-Meltzer 622dc87d84 Remove log handlers with the same name
Also renames functions to follow underscore convention
2016-08-08 14:57:49 -05:00
Jack 18edbdf404 squelch resolve_name logging 2016-08-08 14:58:31 -04:00
Job Evers-Meltzer 02a3eab693 add loggly dependency 2016-08-08 11:39:11 -05:00
Job Evers-Meltzer dded868a80 remove leveldb requirement 2016-08-08 11:37:01 -05:00
Jack 6fe878bdb9 make load_from_hex a class method 2016-08-08 03:18:32 -04:00
Jack 505ece9e36 add txid param to get_claim_info and update todo note 2016-08-08 02:37:08 -04:00
Jack 72acfa1e0c add support_claim 2016-08-08 02:32:56 -04:00
Jack 02cd8b9a44 fix callback 2016-08-08 02:08:09 -04:00
Jack f32250f431 whoops 2016-08-08 01:54:41 -04:00
Jack 1523cad044 refactor get_claim_info 2016-08-08 01:46:19 -04:00
Jack ed55353700 bug fix 2016-08-08 01:43:28 -04:00
Jack 8d3bd45102 get_claims_for_name daemon function 2016-08-08 01:43:10 -04:00
Jack f69753f6a0 add get_claims_for_name 2016-08-08 01:42:37 -04:00
Jimmy Kiselak b7e2e87ac1 fill in much of the skeleton for the reflector protocol 2016-08-07 22:33:40 -04:00
Jack 3b98508986 clean up claim_name function 2016-08-07 16:13:47 -04:00
Jack 36ebfc42d9 update from master 2016-08-06 21:44:14 -04:00
Jack ae5f55ff65 Bump version: 0.3.13 -> 0.3.14 2016-08-06 20:07:28 -04:00
Jack Robison 01131da5b7 Merge pull request #99 from lbryio/refactor-refresh
Add DownloadNameHelper and ResolveNameHelper
2016-08-06 20:06:43 -04:00
Jack 66ae865de0 don't make new lbry file if publish is given a full metadata dict, remove update_claim() 2016-08-06 20:02:51 -04:00
Job Evers-Meltzer 8c50f08fec refactor _start_download 2016-08-05 11:37:24 -05:00
Job Evers-Meltzer e69de47daf refactor wait_on_write stopping condition 2016-08-05 11:37:24 -05:00
Job Evers-Meltzer acef10e848 fix merge oversight 2016-08-05 11:37:24 -05:00
Job Evers edb9d50d9e fix typo in docstring 2016-08-05 11:37:24 -05:00
Job Evers b989d4f6be Bug fix: correct the check on wait_or_get_stream
I reversed the check on lbry_file. Compare to the original code:
https://github.com/lbryio/lbry/blob/e67f55bd7447cbee730d895b7f35cf53cf69dba5/lbrynet/lbrynet_daemon/LBRYDaemon.py#L1119
2016-08-05 11:37:24 -05:00
Job Evers 84dd5c0eca Revert "revert get() refactor"
This reverts commit 5eb7c64ec3.
2016-08-05 11:37:24 -05:00
Job Evers-Meltzer db8daf20b7 quiet noisy log statement 2016-08-05 05:50:24 -05:00
Jack cb985b5a03 log conditions of lbry_file failing to start 2016-08-04 23:27:44 -04:00
Jack 28c4e38272 make line neater 2016-08-04 23:27:25 -04:00
Jack b29377dc2b keep claim id history 2016-08-04 23:27:10 -04:00
Jack ca09592a72 make logs easier to scroll through 2016-08-04 23:10:15 -04:00
Jack b0e14fae43 update over existing claim in publish() 2016-08-04 23:08:54 -04:00
Jack dfa68f126b get update_name in lbrycrdwallet working 2016-08-04 20:43:39 -04:00
Jack 4570f68727 add claim_id to lbry_file and to get_claim_info 2016-08-04 18:44:12 -04:00
Jack 4705acba55 use lbryum updateclaim 2016-08-04 02:22:10 -04:00
Jimmy Kiselak 1dea20a358 include sd blob hashes in list of blob hashes to send via reflector 2016-08-03 23:11:29 -04:00
Jimmy Kiselak 191f661b35 skeleton for reflector protocol 2016-08-03 23:03:14 -04:00
Jack f3ab38ba8f Bump version: 0.3.12 -> 0.3.13 2016-08-03 18:01:18 -04:00
Jack Robison 2d0a892e70 Merge pull request #110 from lbryio/lighthouse-client
Lighthouse client
2016-08-03 18:00:04 -04:00
Jack Robison 00eefe87d7 Merge pull request #109 from lbryio/download-descriptor
add download_descriptor
2016-08-03 17:59:52 -04:00
Jack f68fd96555 break out sd timeout into a variable 2016-08-03 17:57:26 -04:00
Jack fc50a3242f add note about request.notifyFinish 2016-08-03 17:49:13 -04:00
Jack 64e9ce2bfa comments about the upnp redirects 2016-08-03 17:44:41 -04:00
Jack e8d04b1921 specify a lighthouse server 2016-08-03 17:44:32 -04:00
Jack 9fedf14e55 request.notifyFinish 2016-08-03 12:46:46 -04:00
David Amrhein 7d535ef7d1 Make ca_path checks for frozen windows only 2016-08-03 10:16:14 -04:00
Jack 85d610bcdf add get_peers_for_hash 2016-08-03 03:16:06 -04:00
Jack 3af8b7bd0c use upnp redirects if they're already set 2016-08-03 01:27:40 -04:00
Jack 6215d85581 add LighthouseClient, announce sd hash after publishing 2016-08-02 18:34:48 -04:00
Jack 308d9f5abd add todo 2016-08-02 17:33:57 -04:00
Jack bcfabba038 fast search
use cost from lighthouse
2016-08-02 16:45:06 -04:00
Jack 69139b1987 already called error 2016-08-02 16:03:47 -04:00
Jack 3f8f9d9d73 add timeout to download_sd_blob 2016-08-02 02:54:04 -04:00
Jack 2283579109 reorganize download_descriptor 2016-08-01 23:15:32 -04:00
Jack 1e0af94ba2 add download_descriptor 2016-08-01 22:31:49 -04:00
David Amrhein dd631328e0 Update windows distribution setup 2016-07-30 22:54:51 -04:00
David Amrhein cca2a57c69 Set cacert environ path for windows distribution 2016-07-30 22:52:49 -04:00
David Amrhein bbfbcacc6a Add windows icons for packaging 2016-07-30 22:10:30 -04:00
David Amrhein 3f95c1a9d5 Skip db migration in windows 2016-07-30 17:09:38 -04:00
David Amrhein 7bd05e9b16 Handle creation of settings directory in windows 2016-07-30 17:09:15 -04:00
Dave-A 10742d7c51 Merge pull request #1 from lbryio/master
Update from original
2016-07-30 16:48:25 -04:00
Jack bbf7940e45 Bump version: 0.3.11 -> 0.3.12 2016-07-29 23:44:04 -04:00
Jack Robison f5af71f4e6 Merge pull request #107 from lbryio/metadata-version
Metadata versioning, publishing things, and USD denominated key fees
2016-07-29 23:43:11 -04:00
Jack 1ffcd67c9d specify exception 2016-07-29 23:05:01 -04:00
Jack cf8592ba12 docstring and todo 2016-07-29 22:49:50 -04:00
Jack 1e1d036590 clean log line 2016-07-29 22:44:38 -04:00
Jack 64afb6d305 clean up get_est_costs in search 2016-07-29 22:43:50 -04:00
Jack 20a9e018f7 revert updates to git 2016-07-29 22:36:30 -04:00
Jack a574c33ac6 multiple search servers 2016-07-29 21:37:44 -04:00
Jack d21e458fe1 remove debug line 2016-07-29 02:42:58 -04:00
Jack bb3ba53c6e fix search results 2016-07-28 22:39:34 -04:00
Jack ba2e4df76b remove debug stuff 2016-07-28 21:31:19 -04:00
Jack 33e7e4bee3 fancy search 2016-07-28 21:25:37 -04:00
Jack b83dce2cb3 no tricky characters 2016-07-28 18:48:29 -04:00
Jack 6821676853 handle decimals in jsonrpc return 2016-07-28 18:12:54 -04:00
Jack 52024986ee derp 2016-07-28 16:32:59 -04:00
Jack 2e3342d20d fix test 2016-07-28 16:27:16 -04:00
Jack 419aa1d78f fix est data cost / search 2016-07-28 16:12:20 -04:00
Jack de4ddd578f improve readability of metadata and fee requirements 2016-07-28 15:24:20 -04:00
Jack 5dd68a7ed4 add get_claim_info, clean up _get_stream_info_from_value 2016-07-28 14:55:17 -04:00
Jack 881168dc7a fix too many args 2016-07-28 13:16:33 -04:00
Job Evers-Meltzer 295e427abe bug fix: check if fee is in metadata before loading 2016-07-28 12:04:25 -05:00
Job Evers 67c5d15f51 stupid typo 2016-07-28 11:46:33 -05:00
Job Evers 39a7f37f35 muck with pending_claims... still not sure this is correct 2016-07-28 11:43:47 -05:00
Job Evers 15d276b0bc fix case where to and from currencies are the same 2016-07-28 11:43:20 -05:00
Jack 4387025c48 another still 2016-07-28 06:07:33 -04:00
Jack 52c20f02c7 one more 2016-07-28 06:03:47 -04:00
Jack 413dab8094 whoops 2016-07-28 05:59:10 -04:00
Jack 6b1d11a04d fix rate in test 2016-07-28 05:53:31 -04:00
Jack 5441379f38 fix LBRYExchangeRateManager test 2016-07-28 05:49:31 -04:00
Jack 52d954c64e don't spam the market apis 2016-07-28 05:34:20 -04:00
Jack 415495fc16 LBRYExchangeRateManager 2016-07-28 05:30:13 -04:00
Jack 4223298634 test wrong metadata version 2016-07-28 02:49:35 -04:00
Jack e058c71019 test data 2016-07-28 02:46:46 -04:00
Jack 12b2bbfa26 make sure claimed ver is true 2016-07-28 02:36:07 -04:00
Jack 7d22bfffa5 fee tests 2016-07-28 02:30:37 -04:00
Jack 4ade80c8a9 clean up metadata and fee 2016-07-28 02:19:45 -04:00
Jack 9674381fc2 Merge remote-tracking branch 'origin/metadata-version-avec-tests' into metadata-version 2016-07-27 20:18:00 -04:00
Jack f6d91280d7 remove debug print line 2016-07-27 15:03:03 -04:00
Jack e4ebbd8f69 neater force param in resolve_name 2016-07-27 15:02:54 -04:00
Jack 7f5560de6d comment spacing and removing setLevel 2016-07-27 15:02:19 -04:00
Job Evers-Meltzer 0925171e07 bug fix: use txid attribute, not key 2016-07-27 13:59:26 -05:00
Job Evers-Meltzer 900d3ad01d Fixes errback not being callable
Small code refactoring to make it more obvious what
both the callback and errback are doing
2016-07-27 13:12:20 -05:00
Job Evers-Meltzer 6a1efedc1f some example tests. please expand on these 2016-07-27 12:05:29 -05:00
Job Evers-Meltzer 0f602e0e62 allow bittrex fee to be changed 2016-07-27 11:59:57 -05:00
Jack 3a425fc47d Merge branch 'master' into metadata-version 2016-07-27 05:07:23 -04:00
Jack 36722cbbd8 Bump version: 0.3.10 -> 0.3.11 2016-07-27 03:58:25 -04:00
Jack 9572336e96 Merge branch 'master' into metadata-version
# Conflicts:
#	lbrynet/core/utils.py
#	lbrynet/lbrynet_daemon/LBRYDaemon.py
2016-07-27 03:54:10 -04:00
Jack 4895cde474 fix conflicts 2016-07-27 03:48:32 -04:00
Jack Robison 21ca1a73cf Merge pull request #100 from lbryio/change-ui-location
web-ui files are on S3 now
2016-07-27 03:44:28 -04:00
Jack Robison 457c1c6ae6 Merge pull request #101 from lbryio/version-cmp
Properly Compare Version Strings
2016-07-27 03:43:13 -04:00
Jack Robison c1ff127101 Merge pull request #102 from lbryio/log-configure
Fix: Log configuration should not happen when a module is imported
2016-07-27 03:42:51 -04:00
Jack 5e815a5832 merge master 2016-07-27 03:22:03 -04:00
Jack 4604e9cd54 check pending claims after one is made 2016-07-27 03:00:44 -04:00
Jack ef580a7680 errback for pending of date lbry_file 2016-07-27 01:51:09 -04:00
Jack 2102776be8 another errback 2016-07-27 01:44:01 -04:00
Jack f3af7a6b77 add errback for unknown name 2016-07-27 01:39:23 -04:00
Jack 5abeceac1f abandon previous claim in update 2016-07-27 01:13:41 -04:00
Jack 22f73a0817 add force parameter to resolve_name 2016-07-26 21:46:04 -04:00
Jack 29b5aef73a call restore() after claiming name 2016-07-26 21:24:58 -04:00
Jack 3e602bce52 fix publish callback 2016-07-26 20:58:37 -04:00
Jack fe39901885 update claim when publishing to an already claimed name
-also save name_metadata for each unique claim rather than for each name
2016-07-26 20:52:05 -04:00
Jack ee9e8b365c add debug log line 2016-07-26 18:42:51 -04:00
Jack bd6fa35d4a disable verbose dht error 2016-07-26 18:19:40 -04:00
Jack 5e1fdf66b0 fix download problem 2016-07-26 18:18:34 -04:00
Jack d86e709b90 reduce min blob prices 2016-07-26 17:24:59 -04:00
Jack f82cffe882 verbose logging 2016-07-26 17:21:41 -04:00
Jack 3d88eb92c1 change default max fee to $25 2016-07-26 17:21:03 -04:00
Jack 0811ebb52d fix key payment problems 2016-07-26 17:20:51 -04:00
Jack 491d431ea5 remove price updater from daemon 2016-07-26 17:19:26 -04:00
Job Evers‐Meltzer ceeebebcad Merge pull request #106 from lbryio/no-blobs-in-logs
Have TimeoutError hexlify blobs
2016-07-26 14:57:30 -05:00
Job Evers‐Meltzer 04d766aba7 Merge pull request #105 from lbryio/bug-fixes
misc bug fixes and code cleanup
2016-07-26 14:56:50 -05:00
Job Evers‐Meltzer 3b431e180e Merge pull request #98 from lbryio/log-cleanup
Remove datetime.now() from log statements
2016-07-26 14:54:36 -05:00
Job Evers a2eab1577d Have TimeoutError hexlify blobs 2016-07-26 13:54:46 -05:00
Job Evers-Meltzer f8dd3d05dc misc bug fixes and code cleanup 2016-07-26 12:24:25 -05:00
Job Evers-Meltzer 93993e62d6 Fix: Log configuration should not happen when a module is imported
Instead, move the responsibility to the main program. Also,
each module had the same, redundant setup.
2016-07-26 12:01:03 -05:00
Job Evers‐Meltzer 483c88b958 Merge pull request #104 from lbryio/no-print
Remove print line
2016-07-26 11:36:00 -05:00
Job Evers 4a1e846958 Remove print line
This line is responsible for flooding the console with messages like
<_io.BytesIO object at 0x7f9e286e52f0>
2016-07-26 11:34:13 -05:00
Job Evers-Meltzer 927b9afe7c forgot to add the test file 2016-07-26 09:34:00 -05:00
Jack 9e8827f015 resolve name bug 2016-07-25 23:46:18 -04:00
Jack ca45f461ae spelling 2016-07-25 23:42:03 -04:00
Jack 7e5af11c2d fix key fee payment problem 2016-07-25 23:41:26 -04:00
Jack 102436274f USD denominated max_key_fee in settings 2016-07-25 22:46:04 -04:00
Jack 49c26a76b4 remove fee checking from autofetcher script 2016-07-25 22:28:01 -04:00
Jack d469ef7bf2 add googlefinance to requirements 2016-07-25 22:21:38 -04:00
Jack a5374cb876 fix currencies and LBRYFeeFormat 2016-07-25 22:17:31 -04:00
Jack a53e911a0c stop looping call when stop() is called 2016-07-25 21:48:39 -04:00
Jack c4a78a149b LBRYFee things
-move exchange rate updates to wallet, do them every half hour
-add convention checker for fees
-pay BTC or USD denominated key fees in converted LBC amount
2016-07-25 21:45:42 -04:00
Job Evers-Meltzer 3814912adf Move to core.utils and expand to check lbryum too 2016-07-25 16:09:13 -05:00
Jack 75ef652cb3 add googlefinance to setup.py 2016-07-25 17:08:56 -04:00
Job Evers-Meltzer 1eae3fe5dc pylint doesn't like distutils 2016-07-25 14:53:07 -05:00
Job Evers-Meltzer d0bc383a79 bug fix: version comparison is not lexographic.
Use distutils.version to compare version strings.
2016-07-25 12:25:10 -05:00
Job Evers-Meltzer ea5d31b530 OCD: alphabetize and group imports
I'm not the only one:
https://google.github.io/styleguide/pyguide.html?showone=Imports_formatting#Imports_formatting
2016-07-25 12:19:19 -05:00
Job Evers‐Meltzer e56ad19e81 Merge pull request #95 from lbryio/deployment-update
Updates the deployment process and the version check associated with it
2016-07-25 12:10:29 -05:00
Job Evers ed393eb75c Updates the deployment process and the version check associated with it
This commit supports steps 1 and 2 in the new workflow:
1. Change the logic in the daemon to check the github api for the latest release that is not a pre release
2. Change travis to mark all releases as pre release
3. When we are ready to stage a release we push a tag to master. Travis builds the packages and releases them
4. We manually check them
5. Remove the pre release mark when we are happy
2016-07-25 11:13:47 -05:00
Jack 2e2d309d38 BTC/USD denominated fees, metadata revisions 2016-07-25 01:40:26 -04:00
Jack 6bfb33adb2 fix version comparison 2016-07-24 22:03:32 -04:00
Job Evers-Meltzer 05138e1db1 web-ui files are on S3 now 2016-07-22 10:58:37 -05:00
Jack b65402db41 debug line 2016-07-21 16:47:47 -04:00
Jack fbef187400 Merge branch 'master' into metadata-version
# Conflicts:
#	lbrynet/conf.py
#	lbrynet/lbrynet_daemon/LBRYDaemon.py
2016-07-21 16:45:41 -04:00
Jack 25d1b8b9e5 move towards better fees and metadata 2016-07-21 16:11:14 -04:00
Job Evers ec91594083 Remove datetime.now() from log statements 2016-07-21 10:41:26 -05:00
Jack e67f55bd74 disable debug logging 2016-07-20 22:40:55 -04:00
Jack Robison 276a7f9d2a Merge pull request #92 from lbryio/file-uploads
Add support for file uploads (for Publish page)
2016-07-20 22:37:08 -04:00
Jack 4888d7a567 Bump version: 0.3.9 -> 0.3.10 2016-07-20 22:34:16 -04:00
Jack Robison 767f78315b Merge pull request #97 from lbryio/lbryum-catchup
lbryum fixes
2016-07-20 22:33:16 -04:00
Jack 4311b218fb fix auto_connect 2016-07-20 22:13:22 -04:00
Jack 89892042dd remove unused line 2016-07-20 20:57:05 -04:00
Jack a22dfb3864 cleaner logging
from https://github.com/lbryio/lbry/pull/94
2016-07-20 20:56:56 -04:00
Jack f40c42dcf0 Merge branch 'master' into lbryum-catchup 2016-07-20 20:38:42 -04:00
Jack 1d31aa9da3 Bump version: 0.3.8 -> 0.3.9 2016-07-20 20:34:41 -04:00
Jack f999073fb4 revert download refactor
to be re-merged after fixes
2016-07-20 20:34:02 -04:00
Jack 5eb7c64ec3 revert get() refactor 2016-07-20 20:30:57 -04:00
Jack 7e79818555 Revert "Merge branch 'master' into lbryum-catchup"
This reverts commit a51576b250, reversing
changes made to 0bee2689d1.
2016-07-20 20:24:49 -04:00
Jack a51576b250 Merge branch 'master' into lbryum-catchup 2016-07-20 20:17:08 -04:00
Jack 0bee2689d1 download fixes 2016-07-20 20:17:01 -04:00
Jack c232743963 fix LBRYumWallet._do_send_many 2016-07-20 20:13:44 -04:00
Job Evers‐Meltzer c2d5f092b3 Merge pull request #94 from lbryio/logging-reformat-2
use asctime in logging format
2016-07-20 18:41:54 -05:00
Jack 8e8e186de9 Merge branch 'master' into lbryum-catchup 2016-07-20 19:29:11 -04:00
Jack 55f47a2b1b lbryum catchup 2016-07-20 17:32:15 -04:00
Job Evers-Meltzer 5c27b9eb90 use asctime in logging format
Instead of manually adding datetime.now() use
asctime formatter to do it for us.
2016-07-20 07:21:12 -05:00
Job Evers‐Meltzer 1d018533d1 Merge pull request #81 from lbryio/deprecate-lbry-console
deprecate lbry-console script
2016-07-20 07:07:16 -05:00
Job Evers‐Meltzer 34b8841f5c Merge pull request #73 from lbryio/refactor-dl-name
Refactor jsonrpc_get, _download_name, _resolve_name
2016-07-20 07:07:02 -05:00
Alex Liebowitz a54166a27c Add support for file uploads (for Publish page) 2016-07-20 02:36:55 -04:00
Job Evers 4adec39dce Bump version: 0.3.7 -> 0.3.8 2016-07-18 16:00:52 -05:00
Job Evers‐Meltzer e63ae08638 Merge pull request #86 from lbryio/back-to-lbryum
Revert default wallet back to lbryum
2016-07-18 15:33:03 -05:00
Job Evers‐Meltzer f1b4c6a1ec Cache pyobjc (#87)
* cache pyobjc modules as wheels
2016-07-18 14:50:05 -05:00
Job Evers-Meltzer 78b4b3ffa8 revert default wallet back to lbryum 2016-07-18 11:30:21 -05:00
Job Evers‐Meltzer f51fd48cdb Merge pull request #85 from lbryio/update-protobuf
Update protobuf library
2016-07-18 11:26:47 -05:00
Job Evers-Meltzer 9127a816e3 Update protobuf library
Updating to protobuf-v3.0.0b3 because it
fixes a bug here https://github.com/google/protobuf/blob/e841bac4fcf47f809e089a70d5f84ac37b3883df/python/google/protobuf/internal/python_message.py#L59
where six.moves is not always available.
In particular, the system python on OSX has an old version of six
which is without six.moves.
2016-07-18 10:12:49 -05:00
Job Evers-Meltzer 1a5cd9b062 Forget about trying to set a label.
Setting a label also sets the account, but the LBRY app
only looks at the default "" account.  Marking the imported
keys would have been nice, but it doesn't work.
2016-07-18 09:14:50 -05:00
Job Evers-Meltzer a86b4c4e58 bug fix: use sys.exit() not exit() 2016-07-18 08:52:56 -05:00
Job Evers-Meltzer a384960a7b deprecate lbry-console script 2016-07-18 08:45:28 -05:00
Job Evers‐Meltzer 5817b80c94 script to migrate private keys to lbrycrd (#79)
* script to migrate private keys to lbrycrd
* handle compressed keys too
* validate private key actually gets added
* add lbrycrdd and lbrycrd-cli checks
* exit if no wallet path
* move each imported address into the default account
2016-07-17 20:17:42 -05:00
Job Evers-Meltzer 97efd63c99 deprecate lbry-console script 2016-07-17 19:19:00 -05:00
Job Evers-Meltzer 5ebcc01bcc Bump version: 0.3.6 -> 0.3.7 2016-07-17 14:10:11 -05:00
Job Evers‐Meltzer ddcc008ea6 Merge pull request #78 from lbryio/force-wallet
emergency fix: force lbrycrd to be the default wallet
2016-07-17 14:08:41 -05:00
Job Evers-Meltzer 8ec10e2304 emergency fix: force lbrycrd to be the default wallet
Ignore save settings for wallet type and use the default wallet (lbrycrd)
instead.  lbryum can be used but only if specified on the command line.
2016-07-17 13:45:26 -05:00
Job Evers-Meltzer 172f275bc7 Refactor _resolve_name.
Continue using the delegation/helper pattern for the daemon.
2016-07-16 09:24:27 -05:00
Job Evers‐Meltzer 0dac5943bb Merge pull request #74 from llllIHARWINDERIllll/patch-3
Need to have git installed
2016-07-15 13:42:21 -05:00
Jack 2dcd2b13be add LBRYMetadata.py 2016-07-15 14:09:43 -04:00
Harwinder 8743decd17 Need to have git installed.
You cant execute the code that follows after if you havent installed git already.
2016-07-15 20:01:25 +02:00
Job Evers-Meltzer a15d7ca543 Refactor _download_name
Nested functions are the devil, especially ones that
use variables from the outer scope. Refactoring
_download_name to use a helper class helps make
the scoping more explicit and will undoubtably
prevent bugs in the future.

I think this makes _download_name drastically more readable.

Also cleaned up some duplicated code and
made download_directory respect the passed in parameter
instead of being the default.
2016-07-15 12:42:26 -05:00
Job Evers-Meltzer a90029ec50 update doc string 2016-07-15 11:37:04 -05:00
Job Evers-Meltzer 563896b126 fix bug in reveal code 2016-07-15 11:33:38 -05:00
Job Evers-Meltzer 5aecd02668 Refactor jsonrpc_get.
Move parameter handling into its own function and
better use the `.get()` function for dictionaries.

Early return on the failed checks is more readable.

The lambda function in the callback was long and
hard to read so moved it out.
2016-07-15 11:32:46 -05:00
Jeremy Kauffman eef6312a17 Merge pull request #71 from llllIHARWINDERIllll/patch-2
Cant use git if its not installed
2016-07-14 16:26:23 -04:00
Harwinder 1e48f5c8f4 Cant use git if its not installed
First install needed packages then execute the task. Cant run the whole code if git isnt installed :)
2016-07-14 22:25:32 +02:00
Jeremy Kauffman 7908fa2814 Merge pull request #70 from llllIHARWINDERIllll/patch-1
Adding git to linux install command
2016-07-14 16:16:51 -04:00
Harwinder 7ffb3ea042 Added git to linux install command
Some people dont have git installed so adding it to it solves confusion for people new to linux.
2016-07-14 18:41:23 +02:00
Job Evers‐Meltzer 842dd90780 Merge pull request #66 from lbryio/add-tests-blob-handler
add tests for BlobRequestHandler and run on travis
2016-07-14 09:33:06 -05:00
kimihiro64 ee71a03f96 Revert to 2 params as isinstance cannot support 3+ (#69)
* Revert to 2 params as isinstance cannot support 3+

* Use basestring for maximum efficiency
2016-07-13 22:44:02 -05:00
Jack 5221631b40 Bump version: 0.3.5 -> 0.3.6 2016-07-12 17:30:58 -04:00
Job Evers‐Meltzer ade2b4ac0d Merge pull request #68 from lbryio/switch-slack
switch slack notification token
2016-07-12 15:25:21 -05:00
Job Evers-Meltzer 643b95c0e4 switch slack notification token 2016-07-12 14:48:13 -05:00
Jack Robison ed0f9d4fb5 Merge pull request #67 from lbryio/real-lbryum
Real lbryum
2016-07-12 15:35:54 -04:00
Jack 6f353c31cb Merge branch 'master' into real-lbryum 2016-07-11 22:04:32 -04:00
Jack 404412a950 return publish error message 2016-07-11 21:57:34 -04:00
Job Evers‐Meltzer 0e1778d8da Merge pull request #65 from lbryio/add-slack-notifications
add slack notifications to travis
2016-07-11 13:28:56 -05:00
Job Evers-Meltzer dfc0ca9525 change slack key and encrypt it 2016-07-11 12:05:27 -05:00
Job Evers-Meltzer 53bf1fe4fd add send_blob tests 2016-07-10 21:56:00 -05:00
Jack 5c05daa007 update import to new file name 2016-07-10 22:21:50 -04:00
Job Evers-Meltzer f74f075b4e add tests for BlobRequestHandler and run on travis 2016-07-10 18:48:14 -05:00
Jack 1b53e8e98c re-enable lbryum 2016-07-09 13:31:07 -04:00
Job Evers-Meltzer 4caee284bc add slack notifications to travis 2016-07-07 12:06:07 -05:00
Alex Grintsvayg 5368c91399 lbry replaces old lbrynet 2016-07-07 00:18:29 -04:00
Alex Grintsvayg 00b1881f20 dont forget to run bumpversion instead of manually bumping 2016-07-06 22:56:23 -04:00
Jack b727bd20c8 version bump 2016-07-06 22:48:38 -04:00
Jack 5a703c116f linux lbrycrdd path 2016-07-06 22:46:59 -04:00
Alex Grintsvayg 57f728f40e desc update 2016-07-06 22:29:12 -04:00
Alex Grintsvayg 74bbde0c34 fix "launch as root" bug, update package name and maintainer 2016-07-06 21:54:55 -04:00
Alex Liebowitz c58fc0781c Call xdg-open properly in jsonrpc_reveal() 2016-07-06 15:57:00 -04:00
Alex Grintsvayg 7a266d49c1 fix 2016-07-06 15:33:06 -04:00
Alex Grintsvayg 344eeeb8c0 typo 2016-07-06 15:04:41 -04:00
Alex Grintsvayg 08d50ddfc5 bundle lbrycrdd bins instead of downloading them 2016-07-06 14:58:06 -04:00
Alex Grintsvayg f83c892b13 fix lbry symlink, fix icon path, add .desktop file to bumpversion 2016-07-06 14:13:11 -04:00
Alex Grintsvayg 7dbec9d395 typo 2016-07-06 13:41:47 -04:00
Alex Grintsvayg 5171c801d9 add lbry icons, symlink into user path 2016-07-06 13:34:17 -04:00
Alex Grintsvayg 72b4a778a6 dont forget bumpversion 2016-07-06 10:09:40 -04:00
Jack Robison 0254df63f9 Merge pull request #64 from lbryio/check-for-new-ui
Check for new ui periodically
2016-07-06 04:35:06 -04:00
Jack 03c02ff74f lbrycrdd path wierdness 2016-07-06 03:37:31 -04:00
Jack 9277c3c674 add help for when things go wrong 2016-07-06 03:02:55 -04:00
Jack 34b1259dc6 move check for if daemon is running to inside of function 2016-07-06 02:20:18 -04:00
Jack 257e38de12 add command line wrapper for lbrynet-daemon calls 2016-07-06 02:17:38 -04:00
Jack 1984132eae add update_available keys to version()
as to not require making the version string comparison in whatever is
making the daemon call
2016-07-06 01:46:49 -04:00
Jack 8b1d75ea98 check every 30 minutes for a new ui version
-previously the check for a new ui version was only at startup, which
resulted in bugs persisting after they’d been fixed

-add option to skip requirements check

-try to load an existing ui if it can’t be obtained from github
2016-07-06 01:27:25 -04:00
Job Evers‐Meltzer a79af11371 Merge pull request #60 from lbryio/change-make-deb
Use patched version of make-deb
2016-07-05 15:08:42 -05:00
Job Evers 087a9b70b4 Use patched version of make-deb
Ran into a bug in make-deb that fails when there is utf-8 characters
in the git commit message. https://github.com/nylas/make-deb/issues/13.

I wrote a patch to fix the bug and am installing that version until the
make-deb maintainers incorporate it
2016-07-05 14:57:48 -05:00
Alex Grintsvayg 8b37952128 make-deb doesn't like utf8 arrow in commit message 2016-07-05 15:53:51 -04:00
Alex Grintsvayg 8336930091 Bump version: 0.3.2 → 0.3.3 2016-07-05 15:20:35 -04:00
Alex Grintsvayg d875325cee better non-root fix, restore version var 2016-07-05 15:20:30 -04:00
Alex Grintsvayg f1c5d1cb23 Bump version: 0.3.1 → 0.3.2 2016-07-05 14:30:35 -04:00
Alex Grintsvayg b55752e715 add bumpversion script 2016-07-05 14:29:24 -04:00
Alex Grintsvayg 36a99e6ec8 run lbry as non-root user 2016-07-05 14:06:41 -04:00
Jack df3c5b9a77 open conf for write in app 2016-07-04 20:47:43 -04:00
Jack 4c2ab23c1f write to the file that's supposed to be written to 2016-07-04 20:19:04 -04:00
Jack 0a3f81e364 fix download directory not existing problem 2016-07-04 20:02:38 -04:00
Jack 69c5631b25 make lbrycrddpath.conf if it doesnt exist, point to binary in app 2016-07-04 19:53:01 -04:00
Jack cca4331ac4 create lbrycrddpath.conf if it doesnt exist 2016-07-04 19:34:51 -04:00
Alex Grintsvayg 5972dbb6a7 fix lbry init script 2016-07-04 19:18:22 -04:00
Job Evers-Meltzer 794f2d8576 version bump: 0.3.0.2 2016-07-04 16:51:29 -05:00
Alex Liebowitz e35dce530a Set default download dir to ~/Downloads on Linux 2016-07-04 17:49:48 -04:00
Job Evers-Meltzer 6034bd3cb2 version bump: 0.3.0.1 2016-07-04 15:47:12 -05:00
Job Evers‐Meltzer 42c77bbb67 Merge pull request #51 from lbryio/restart-lbrycrd
add a more useful exception if auth fails on lbrycrd
2016-07-04 15:45:44 -05:00
Job Evers‐Meltzer d504c8f4a3 Merge pull request #50 from lbryio/lbrycrd-in-bundle
Add lbrycrd to app bundle on macos
2016-07-04 15:42:24 -05:00
Job Evers-Meltzer 976c8b3ce0 add a more useful exception if auth fails on lbrycrd 2016-07-04 15:40:52 -05:00
Alex Liebowitz 905e7e41a6 Merge branch 'master' of https://github.com/lbryio/lbry 2016-07-04 16:26:35 -04:00
Job Evers-Meltzer 16f48d0400 Add lbrycrd to app bundle on macos 2016-07-04 15:18:08 -05:00
Alex Liebowitz 6d7608d851 Create lbrycrd.conf if needed 2016-07-04 16:16:34 -04:00
Jack 7cd30efbe9 download lbrycrd binaries and set up lbrycrddpath.conf 2016-07-04 08:41:44 -04:00
Jack Robison 8c3652e1ac Merge pull request #49 from lbryio/real-lbrycrd2
real blockchain
2016-07-04 05:48:49 -04:00
Jack 7b9e3aace9 use lbrycrd 2016-07-04 05:43:26 -04:00
Jack 568737e123 change lbryum version constant name 2016-07-04 05:15:53 -04:00
Jack 808e3ea6e3 rename LBRYcrdWallet.py to LBRYWallet.py and change default wallet to lbrycrd 2016-07-04 04:57:30 -04:00
Jack e4f14d871f update setup.py 2016-07-01 03:36:51 -04:00
Jack 1cedd8ee5b update name 2016-07-01 03:16:08 -04:00
Jack b80fe24179 tanstaafl 2016-07-01 02:55:20 -04:00
Jack 3cea41a854 remove lbrynet_gui 2016-07-01 02:42:34 -04:00
Jack 62b80c13cc version bump 2016-06-30 01:26:33 -04:00
Jack 08b612575c update_claim fix and clean up publish keys
-replace ‘value’ key with ‘metadata’

-update claim metadata in db when an update is published
2016-06-28 23:20:28 -04:00
Jack b3b804bf2d add update_name 2016-06-28 14:28:59 -04:00
Jack 09d8a86e30 rename variable 2016-06-28 02:06:04 -04:00
Jack cc5d917c72 download fix 2016-06-28 01:51:05 -04:00
Jack 7cc3e9d5ef publish updates
-adds a base set of metadata fields required for results to be rendered
in conf.py, including language and content-type

-dont support old style claims on the new blockchain
2016-06-27 17:07:59 -04:00
Job Evers‐Meltzer 87aa9fc6c4 Merge pull request #48 from lbryio/add-cache
add caching for travis
2016-06-27 11:50:23 -05:00
Job Evers 8d5c315817 add caching for travis 2016-06-27 11:21:30 -05:00
Jack f89486f5fe port and import name 2016-06-24 13:12:27 -04:00
Job Evers‐Meltzer cf4d78a24c Merge pull request #47 from lbryio/fix-osx-build
Fix OSX build issue with openssl
2016-06-23 16:35:13 -05:00
Job Evers-Meltzer ee88970075 use the python installer from python.org
The python from brew links to brew's version of openssl
while the python one works with what osx has by default.
We need the later or else the resultiing app bundle
only works on machines that have brew's version of
openssl.
2016-06-23 15:24:19 -05:00
Job Evers‐Meltzer f5fa40feb7 Merge pull request #44 from lbryio/new-osx-container
Use a more up-to-date OSX version
2016-06-23 08:52:03 -05:00
Job Evers-Meltzer da13192cfe Use a more up-to-date OSX version
Also related:
 - install framework version of python
 - ensure unencrypted keys are never accidently added to repo
2016-06-22 23:23:26 -05:00
Job Evers‐Meltzer 8ff65a65db Merge pull request #43 from lbryio/no-libgmp
No longer swap libgmp
2016-06-21 18:07:24 -05:00
Job Evers-Meltzer 2d882a11a5 No longer swap libgmp
The correct libgmp builds on travis so we don't need to swap it out anymore
2016-06-21 16:21:46 -05:00
Jack Robison 79adc677a1 add --log-to-console 2016-06-21 16:58:08 -04:00
Jack Robison a8e2dad6d0 fix link 2016-06-21 16:55:52 -04:00
Jack Robison 16954c5626 add FAQ 2016-06-21 16:54:22 -04:00
Job Evers-Meltzer 56305c4ede allow tags that start with test to pass 2016-06-21 15:05:15 -05:00
Job Evers‐Meltzer 30713cc21d Merge pull request #42 from lbryio/osx-pyobjc
Install pyobjc dependencies
2016-06-21 14:45:43 -05:00
Job Evers-Meltzer 2bac0a25e0 install pyobjc dependencies 2016-06-21 13:51:53 -05:00
Job Evers-Meltzer c3aa5b0515 restore version check 2016-06-21 01:36:03 -05:00
Job Evers-Meltzer 30afa43ed4 how about two providers? 2016-06-21 01:24:34 -05:00
Job Evers-Meltzer f2e66abe67 can there be two deploys? 2016-06-21 01:08:06 -05:00
Job Evers-Meltzer cdb311a501 build dmg from LBRY.app 2016-06-21 00:19:40 -05:00
Job Evers-Meltzer 4c2b3e157c deactivate version check so that I can do a test release 2016-06-20 22:57:04 -05:00
Job Evers-Meltzer 52625b710b trying to release linux and OSX files 2016-06-20 22:55:55 -05:00
Job Evers‐Meltzer b411bb4e85 Merge pull request #41 from lbryio/add-osx-certs
Add osx certs
2016-06-20 21:39:41 -05:00
Job Evers-Meltzer f16111369f Update build script
setup_uri_handler.py has moved, update build script to reflect
 again, setup_uri_handler changed location
 remove pipe to /dev/null
 try updating openssl
 try deep signing
 another file renamed
 install a dependency
 prereqs
 install requirements
 install certifi
 only install requirements on osx
 thin binaries only if they're actually fat
2016-06-20 20:45:28 -05:00
Job Evers-Meltzer 628d052749 move contents of lbry-osx-app into lbry repo 2016-06-20 20:43:48 -05:00
Job Evers-Meltzer 2e26bb0e57 remove submodule 2016-06-20 20:43:47 -05:00
Job Evers 652c7d72f6 Add encrypted certificate needed for code signing
This is a cleaned up version of commit c5dc06962d
  add OSX build to travis matrix
  fix the OSX build not failing
  add encrypted certificate and identity file
  Update submodule to lbry-osx-app/master
2016-06-20 20:43:34 -05:00
Alex Grin 0b046ea8cf fix flipped if statement 2016-06-16 22:41:08 -04:00
Jack Robison 7133f05fea update readme 2016-06-10 18:39:35 -04:00
Jack Robison da1c23d7dd update readme 2016-06-10 18:28:21 -04:00
Job Evers‐Meltzer a329dcd844 Merge pull request #40 from lbryio/fix-travis-build
Fix travis build
2016-06-10 08:47:19 -05:00
Job Evers b57212d5f7 print package size in travis 2016-06-10 01:38:05 -05:00
Job Evers 12c9e16f37 fix typo to actually use ubuntu trusty 2016-06-10 01:22:51 -05:00
Job Evers‐Meltzer 422381ac01 Merge pull request #39 from lbryio/add-tracing
activate tracing flag on build script
2016-06-07 10:59:47 -05:00
Job Evers-Meltzer 4b817cef65 activate tracing flag on build script 2016-06-07 10:52:21 -05:00
Jack Robison 4255a9916d Merge pull request #38 from lbryio/development
0.2.5
2016-06-07 04:54:39 -04:00
Jack Robison b1566e904b Merge pull request #36 from lbryio/add-tests-to-travis
Add tests to travis
2016-06-07 04:51:09 -04:00
Jack 8629076814 use lbryio/lbry-osx-app.git for lbry/packaging/osx/lbry-osx-app 2016-06-07 04:41:26 -04:00
Jack 761e4f2718 change variable name to lbrynet_log 2016-06-07 04:30:22 -04:00
Jack 3441dd4d2d don't mess with logging 2016-06-07 04:19:51 -04:00
Jack 9a8139a8b2 merge conflict 2016-06-07 03:21:18 -04:00
Jack a0f823910c delete accidentally committed file 2016-06-07 03:16:22 -04:00
Jack 755338ded0 import logging.handlers 2016-06-07 03:08:32 -04:00
Jack ecd85a53a1 ui dir for linux 2016-06-07 01:20:44 -04:00
Jack 8faa0d9e01 update lbryum log path 2016-06-06 15:24:29 -04:00
Jack 20ca2eac37 lbryum logging in lbryum.log, add to upload_log() 2016-06-04 17:05:14 -04:00
Jack 85b56247a3 merge add-tests-to-travis updates 2016-06-04 15:11:51 -04:00
Jack febc66fb02 missing keyword args for travis 2016-06-04 15:03:16 -04:00
Jack 3f929aee3c merge travis fixes 2016-06-04 14:28:32 -04:00
Jack 8c46dd194d save command line wallet choice to config 2016-06-04 14:18:58 -04:00
Jack a9f99d05b9 add more known dht nodes
also fix migrator bug
2016-06-03 20:20:16 -04:00
Jack e224c33817 add mime_type to get_lbry_file 2016-06-03 03:45:46 -04:00
Job Evers-Meltzer 4e6afbc8ff Merge remote-tracking branch 'origin/master' into add-tests-to-travis 2016-06-01 22:56:05 -05:00
Job Evers-Meltzer 80b912ea14 pylint: disable incorrect not-callable message 2016-06-01 22:40:01 -05:00
Job Evers-Meltzer 85a571521b disambuguate popup functions 2016-06-01 22:38:24 -05:00
Job Evers-Meltzer 98efa9f466 pylint: ignore incorrect not-callable message 2016-06-01 22:35:30 -05:00
Job Evers-Meltzer a30a9ad763 have pylint skip currently unmaintained files 2016-06-01 22:31:41 -05:00
Jack 36787eeeeb default value 2016-06-01 21:05:38 -04:00
Jack 104cafedb0 --wallet fix 2016-06-01 20:52:15 -04:00
Job Evers-Meltzer 284d307c0f fix logging-too-few-args errors 2016-05-31 22:49:00 -05:00
Jack f50c98e10d revert import
see if this helps travis
2016-05-31 17:45:04 -04:00
Jack a4a5d63da7 fix update settings problem
also move log upload url constant to conf.py
2016-05-31 17:38:00 -04:00
Jack 9f0f9e0928 Merge remote-tracking branch 'origin/better_log_names' into add-tests-to-travis 2016-05-30 17:09:39 -04:00
Jack ef62fd7e34 fix pip install jsonrpc 2016-05-30 16:37:47 -04:00
Jack 0151dd8875 remove test_bot
test bot was moved to keynes repo, and shouldn’t be with the tests
script
2016-05-30 16:14:32 -04:00
Jack 2026024c8a updates from development 2016-05-30 15:49:25 -04:00
Jack 3d56baddd7 fix import error 2016-05-30 15:44:31 -04:00
Jack c10e7b2b41 fix import 2016-05-30 15:39:27 -04:00
Jack ba605e985a no shell=True 2016-05-30 04:40:58 -04:00
Jack 4cd1cdf495 escape spaces in paths given to reveal() 2016-05-30 04:37:34 -04:00
Jack f9c644b964 fix switching between --branch and --ui 2016-05-30 04:00:47 -04:00
Jack da68bcf952 third time's the charm 2016-05-30 03:14:59 -04:00
Jack 2c3b625b6b change full_path to path 2016-05-30 02:56:08 -04:00
Jack 16ef259ae1 add full_path to lbry_file 2016-05-30 02:53:36 -04:00
Jack c56b3e75ea add download_directory to lbry_file 2016-05-30 02:42:33 -04:00
Jack 772866389f ui manager fixes
load a ui when it’s supposed to be loaded
2016-05-30 02:36:13 -04:00
Jack 41f8b5aee2 add reveal() function and delete_target_file param for delete_lbry_file 2016-05-30 02:05:16 -04:00
Jack 75052fc773 remove check_for_new_version vestige 2016-05-30 00:10:43 -04:00
Jack e7a580fd3a add lbry_ui_manager 2016-05-29 23:18:30 -04:00
Job Evers c967230969 restore version consistency check 2016-05-28 11:04:10 -05:00
Job Evers f3e6b2ab57 on travis, move built deb file for easier access 2016-05-28 10:55:15 -05:00
Job Evers 7385cb0c89 try new filename for travis deployment 2016-05-28 09:54:08 -05:00
Job Evers‐Meltzer d1be9e7dc8 Merge pull request #37 from lbryio/tmp-remove-version-check
comment out version check
2016-05-28 09:38:44 -05:00
Job Evers a22052e85b comment out version check 2016-05-28 09:32:41 -05:00
Alex Grintsvayg ab401541f2 Merge branch 'travis-release'
* travis-release:
  add deployment section to .travis.yml
  fail build if version doens't match tag
  fix whitespace
2016-05-28 10:08:24 -04:00
Job Evers-Meltzer dab4427c18 add deployment section to .travis.yml
- not sure if the file name entry will work.
2016-05-28 10:08:18 -04:00
Job Evers-Meltzer ad7d508a3c fail build if version doens't match tag 2016-05-28 10:08:18 -04:00
Job Evers-Meltzer cb30514cbc fix whitespace 2016-05-28 10:08:18 -04:00
Job Evers 53af9db285 add tests and linting 2016-05-27 15:46:00 -05:00
Job Evers-Meltzer b557a14134 fix whitespace 2016-05-27 13:27:44 -05:00
Jack 8922fd6dde add startup scripts
-populate blockchainname.db on first run from older version
2016-05-25 22:28:45 -04:00
Jack 6b39e549f7 add developer id to travis.yml 2016-05-25 21:02:30 -04:00
Jack eb0dd827b1 delete old unused app and move uri handler to lbry-osx-app 2016-05-24 17:54:44 -04:00
Jack a48902d7d3 fix merge conflict 2016-05-24 17:51:00 -04:00
Jack 7fca1f865d update from master 2016-05-24 17:50:01 -04:00
Jack c5dc06962d travis code signing 2016-05-24 17:44:26 -04:00
Alex Grintsvayg 45ecdafd52 i have the best words 2016-05-23 16:25:14 -04:00
Alex Grintsvayg f9e8bf92bd readme rewrite 2016-05-23 16:13:53 -04:00
Alex Grintsvayg de614b293c change description 2016-05-23 16:13:53 -04:00
Jack Robison 8382075147 add divider line 2016-05-23 15:22:42 -04:00
Jack Robison b605630a9c update install instructions 2016-05-23 15:21:47 -04:00
Alex Grintsvayg 0a89fb1928 10 is too long 2016-05-23 00:40:18 -04:00
Alex Grintsvayg 4c81906b50 run lbry instructions in bg 2016-05-23 00:35:44 -04:00
Alex Grintsvayg b6220e985a let user know how to run lbry after install 2016-05-23 00:19:55 -04:00
Alex Grintsvayg 7a97a28e00 fix lbry icon 2016-05-22 23:48:51 -04:00
Alex Grintsvayg dda8f281a1 :shipit: travis build badge :shipit: 2016-05-22 22:45:08 -04:00
Alex Grintsvayg 28b561a810 Merge branch 'travis-ci-integration'
* travis-ci-integration:
  need fakeroot too
  Enabling builds on travis-ci
2016-05-22 22:38:22 -04:00
Alex Grintsvayg 44aba93d37 need fakeroot too 2016-05-22 22:36:56 -04:00
Job Evers efb5157027 Enabling builds on travis-ci
- adds a travis.yml config file
- modifies the ubuntu build script to work on travis
- adds start of osx builds
   - waiting for certs to be added
2016-05-22 20:17:36 -05:00
Alex Grintsvayg f48c1562f3 better log names 2016-05-20 19:59:49 -04:00
Alex Grintsvayg 098b5b28a8 fix web ui branch in install script 2016-05-20 12:13:58 -04:00
Jack Robison 998e8e748c Merge pull request #32 from lbryio/development
more stream and file fixes
2016-05-16 20:28:13 -04:00
Jack be96c77467 add set_miner and get_miner_status
set_miner takes parameter key ‘run’, which is True or False
2016-05-14 17:57:34 -04:00
Jack b5e8aec548 fix --wallet=lbrycrd 2016-05-14 17:36:30 -04:00
Jack 278c7dc836 have get() wait for file to have written data before returning by default
controlled by wait_for_write parameter
2016-05-13 19:35:38 -04:00
Jack 1425ad87ab fix get_lbry_file problem 2016-05-11 04:44:23 -04:00
Jack f985a2a8ad add waiting_for_credits startup code 2016-05-11 02:47:33 -04:00
Jack 20f423a2fc bump version 2016-05-11 02:08:13 -04:00
Jack 210c1215d6 add metadata to lbry_file 2016-05-11 01:48:23 -04:00
Jack 1c507393a9 fix problem with getting a stream where the file has been deleted 2016-05-10 21:01:53 -04:00
Jack b04cfdc091 load uri and txid when stream is started 2016-05-10 20:47:35 -04:00
Jack 42a3006f6e add claim txid and uri to lbry_file 2016-05-10 19:03:18 -04:00
Jack Robison 7d5c618246 Merge pull request #29 from lbryio/development
0.2.3
2016-05-06 18:06:46 -04:00
Alex Grintsvayg 74250982d1 update linux uri handler 2016-05-06 17:38:59 -04:00
Jack 8bd6fb5b4e clean up uri handler
clean up work arounds from when ui didn’t do loading nicely
2016-05-06 17:20:03 -04:00
Jack bb2fb92b0e have uri handler fail silently to prevent misleading error
otherwise first run produced an error while it was downloading the
headers if the app was started by going to lbry://lbry
2016-05-06 16:59:23 -04:00
Jack 10b016312d get rid of Xcode tools and git requirement 2016-05-06 16:16:09 -04:00
Jack b4500a2914 get rid of git HEAD stuff 2016-05-06 15:51:59 -04:00
Jack da9b1b3f58 merge conflicts 2016-05-06 15:42:21 -04:00
Alex Grintsvayg da31520465 use github api instead of git 2016-05-06 15:34:41 -04:00
Jack f3d3a0e57f Don't show 0 while downloading headers from amazon, fix uri handler 2016-05-06 14:31:44 -04:00
Alex Grintsvayg 9a655988dd update script to build against diff web ui branches 2016-05-06 14:30:00 -04:00
Jack 43b541bb7d Merge branch 'master' into development 2016-05-06 02:11:30 -04:00
Jack e32853744a better loading message 2016-05-05 22:26:25 -04:00
Jack b017b63745 status code for previously downloaded file
also fix return for files downloaded manually with stream_info
2016-05-05 21:45:25 -04:00
Jack 29d6d824fc write cryptsd files to data dir instead of cwd 2016-05-05 19:16:36 -04:00
Jack d6983a25b0 fix metadata problem in downloader and publisher 2016-05-04 23:40:05 -04:00
Jack 4cab6726b0 log to file from publisher
also fix sd_hash exception that could happen
2016-05-04 23:27:40 -04:00
Jack 509b8f3a29 add file_name and stream_info fields to get()
-file_name is the name of the file in the downloads folder

-stream_info is a dict of the metadata in a name claim, it can be used
to download streams where the claim hasn’t yet been added to the
nametrie
2016-05-04 21:25:46 -04:00
Jack 461c2f9055 add file download statuses for get_lbry_file
also clean up remaining fetcher stuff
2016-05-04 05:20:38 -04:00
Jack c1d0f9cf1b get rid of autofetcher in daemon
the purpose of the autofetcher was to automatically back up and host
published content, it is simpler to do this in a separate script that
uses existing daemon functions than to have it be built in
2016-05-04 04:12:11 -04:00
Jack 019de08c64 add more transaction functions to daemon
also fix —wallet command line option
2016-05-03 23:13:31 -04:00
Jack 30f88f99b7 use static.File 2016-05-02 15:58:40 -04:00
Jack 04ee9894c9 speed up streaming, off by one errors 2016-05-02 04:10:50 -04:00
Jack 46368f52f5 streaming files
still needs work, still has problems in safari and is otherwise slow
2016-05-01 05:17:59 -04:00
Jack 226e9084c9 return false from get_lbry_file if the file doesnt exist 2016-04-30 23:43:02 -04:00
Jack caf5d2f788 update uri handler to use /watch 2016-04-26 19:48:43 -04:00
Jack 591634f175 cache name claim info
-cache name claim info for an hour rather than looking it up each time
it’s required

-add default thumbnail to search results
2016-04-25 22:35:21 -04:00
Jack dfaf51a432 lbry file improvements
-fix daemon functions to start/stop lbry files

-remove unused stuff in LBRYFileManager

-improve and use new get_lbry_file function instead of _check_history,
which didn’t use the lbry file manager

-use said function to let delete_lbry_file use the same search keys
(sd_hash, name, and file_name)

-logging in LBRYDownloader
2016-04-24 17:51:24 -04:00
Jack c2ec066c85 add LBRYFileProducer
-Add LBRYFileProducer, to host the contents of a download without
having to keep re-opening it as it is added to

-included sd hash in ManagedLBRYFileDownloader, to make comparing the
contents of the file manager against name claims easier

-add get_lbry_file function, which returns information about a LBRY
file found by sd_hash, file name, or lbry uri
2016-04-24 04:42:42 -04:00
Jack 3e7c09bb44 fix duplicate/buffering problem
fix problem where get request takes time to respond, in this time it
can receive more get requests that each manage to start downloading
2016-04-22 18:48:44 -04:00
Jack 28f66e30dd improve timeouts 2016-04-22 18:18:17 -04:00
Jack bac7f097a9 add -x to filename before extension for duplicate downloads 2016-04-22 02:45:41 -04:00
Jack fecd29a967 only load /view page when file isn't empty 2016-04-22 02:45:05 -04:00
Alex Grintsvayg c22eed9109 improved unity description 2016-04-21 17:18:51 -04:00
Jack 2c1ba623a4 add message key to upload_log
log the message which is then uploaded with a special file prefix, and
also send the message to slack
2016-04-20 23:50:13 -04:00
Jack 561cdba7c9 fix jsonrpc import 2016-04-20 22:59:46 -04:00
Jack e5e25012ff move daemon server stuff into its own class 2016-04-20 22:02:52 -04:00
Jack c5d653a51a add bug report page
adds a page to submit a message and upload log at /report
2016-04-20 14:44:26 -04:00
Jack c4620a0b0c add problem_code to daemon_status 2016-04-20 04:24:32 -04:00
Jack dc969f80f3 Merge branch '0.2.3-development' into development 2016-04-20 03:02:57 -04:00
Jack a82f85f058 bump version, increase log size, fix shutdown problem 2016-04-20 02:56:29 -04:00
Jack 3ef85e711d Merge branch 'master' into development 2016-04-19 19:23:56 -04:00
Jack 29f7307f9d periodically check internet connection and for new versions 2016-04-18 13:21:53 -04:00
Jack 24eed71959 upload log function doc string 2016-04-18 03:41:16 -04:00
Jack 9341ccb643 Merge branch 'master' into transaction-explorer
fix conflicts in LBRYDaemonControl.py
2016-04-17 23:28:00 -04:00
Jack 4385b90cca add get transaction and history functions to daemon 2016-04-17 23:23:20 -04:00
Jack Robison 9c10ee12fd Merge pull request #28 from lbryio/lag-and-diagnostics
fix lagging indicator, improve diagnostics, fix lbryum link, make ui easier to launch on linux
2016-04-17 23:05:55 -04:00
Jack 7a622986d6 remove lbryum version from setup.py
version number made dependency link not work
2016-04-17 22:56:51 -04:00
Jack 99b3cdd45d default on launching ui if daemon already running when command is called
-also update deb version
2016-04-17 20:16:35 -04:00
Jack 7b9d84f528 use master branch for ui in .deb 2016-04-17 20:11:10 -04:00
Jack 5f49827bd2 fix lagging indicator and improve diagnostic
-make is_lagging more meaningful - it is set to true after 90 seconds
with no progress, this is to stop slow but steady catchups from
triggering it

-prevent situation where repeated shutdowns before wallet catchup
results in never receiving first run credits

-fix settings to write new defaults that aren’t already in the
configuration file

-report log of startup sequence if upload_log set to true

-redirect /view?name=lbry to the main UI page. This is to make the ui
accessible from a lbry:// link on linux
2016-04-17 19:54:04 -04:00
Jack Robison e1b4fe02d6 Merge pull request #27 from lbryio/development
merge updates from development into master
2016-04-16 01:15:50 -04:00
Jack cdab127b98 have separate handlers for uris on linux and os x 2016-04-15 23:57:52 -04:00
Jack bac7ea5dc0 include platform information in version() 2016-04-15 22:31:06 -04:00
Jack b3b5581f2d don't log to console, add --no-launch flag, fix help()
by default, the ui opens in the lbrynet-daemon startup sequence, the
—no-launch flag stops the ui from launching
2016-04-15 19:37:27 -04:00
Jack 9a26d869fe better first run message 2016-04-14 17:01:05 -04:00
Jack 57138d9629 is_lagging message 2016-04-14 16:50:11 -04:00
Jack 47d897b48d is_lagging indicator and internet connection check
-adds is_lagging indicator as a key from daemon_status, which is set to
True during a phase of the startup sequence, presently only during
loading_wallet if catching up with the blockchain takes longer than a
minute.

-checks if connected to internet before trying to start
2016-04-14 00:29:40 -04:00
Jack 6b9f1d519e remove null handling used to fix a now resolved bug, update daemon_status outputs per alex's suggestions 2016-04-13 23:10:17 -04:00
Jack 8b966c61d8 check version during startup 2016-04-13 22:07:27 -04:00
Jack 87e09efff5 update lbryum version in setup.py 2016-04-13 20:52:51 -04:00
Jack 65a0583c85 add help function and documentation for functions
-calling help() will return the list of functions

-setting the ‘function’ param in the help function will return the doc
string for that function

-setting the ‘callable_on_startup’ in the help function will return the
list of functions callable during the startup sequence
2016-04-13 14:47:34 -04:00
Jack 2000a1b334 replace rawgit with raw.githubusercontent 2016-04-13 02:52:41 -04:00
Jack cdd44af043 fix links in LBRYDaemonControl
https was failing
2016-04-13 02:39:50 -04:00
Jack df99d06d11 fix links in check_for_new_version and log version info
-also handle situation where function is given a null argument
2016-04-13 02:35:31 -04:00
Alex Grintsvayg b32d096be2 add png to setup.py 2016-04-12 20:44:47 -04:00
Alex Grintsvayg b9d5d1041c bump version, better icon 2016-04-12 19:27:26 -04:00
Alex Grintsvayg 994dc9ff33 Merge branch 'linux-install' into development
* linux-install:
  bunch of changes, ready to roll
  add ubuntu package scripts, lbry:// uri handler
2016-04-12 18:53:56 -04:00
Alex Grintsvayg 2ac97736ce bunch of changes, ready to roll 2016-04-12 18:53:36 -04:00
Alex Grintsvayg 925e106c43 add ubuntu package scripts, lbry:// uri handler 2016-04-12 18:53:36 -04:00
Jack 59002413f8 organize daemon init, move more into daemon_settings.json
-also add wallet.catchup_progress to get a rough percentage of how
caught up the daemon is, this is accessed through daemon_status()
2016-04-12 02:03:57 -04:00
Jack Robison 32293ee3bb Merge pull request #26 from lbryio/settings
merge in updates from settings branch
2016-04-11 23:19:40 -04:00
Jack e04f35af4f fix check_for_new_version
returns true if new version is available, otherwise false

check_for_new_version is callable during startup
2016-04-11 23:13:26 -04:00
Jack c50f83400a make version callable during startup 2016-04-11 22:37:42 -04:00
Jack 31fa974379 version function, ui version tracking, blocks behind blockchain during startup, cleaner set_vars
-adds version() function, which can be called after the daemon is
running and returns lbrynet, lbryum, and lbry ui version information.

-daemon_status now returns how far behind its behind the blockchain
when in the loading_wallet phase of startup

-cleans up set_vars by moving to init
2016-04-11 22:28:46 -04:00
Jack aa8c362cb8 add --branch arg to lbrynet-daemon to specify ui branch 2016-04-11 16:15:12 -04:00
Jack e48cc40610 fix incorrect variable 2016-04-09 16:18:06 -04:00
Jack a931f59dda only return first run message until credits arrive 2016-04-09 16:14:28 -04:00
Jack 4140fc4d28 add base58 2016-04-09 15:43:25 -04:00
Jack f0d39e6081 log LBRYDaemonControl and return None from get_start_notice if there is no notice to give 2016-04-09 15:43:10 -04:00
Jack c11872a229 default on no startup message 2016-04-09 04:35:34 -04:00
Jack f4fe730dc9 add get_start_notice to return startup messages 2016-04-09 04:15:58 -04:00
Jack a4c83a08c7 change name of check_first_run to is_first_run 2016-04-09 04:00:31 -04:00
Jack c3277d24c3 use status_message and status_code return fields for daemon_status() 2016-04-09 02:09:30 -04:00
Jack 28a23590ef add message for startup status
-added daemon_status function that returns {'status': startup status
message, 'is_running': true/false}
2016-04-09 01:33:27 -04:00
Jack 162275992b return fail from check_first_run when is_first_run isn't callable 2016-04-08 23:52:43 -04:00
Jack 08e25f4622 convert ints to floats if given as settings params 2016-04-08 23:38:57 -04:00
Jack 9a300d773f optional download_directory parameter for get function
-optional download_directory parameter to choose the directory a file
is saved to, if not given or not a valid directory it uses the default
2016-04-08 22:23:37 -04:00
Jack a5362f3170 daemon settings
-set_settings accepts a dict of settings
    -adds upload_log field, defaulting on true, this uploads the lbry
log file to lbry.io to help figure out if and where things aren’t
working
    -default_download_directory is the key of the path where files are
saved

-gets publish working with sources

-adds check_first_run function, returns True/False

-previously only is_running would work during startup, check_first_run,
 get_time_behind_blockchain, and stop have been added

-requires six 1.9, 1.10.0 produced errors
2016-04-07 03:12:09 -04:00
Jimmy Kiselak 7b653b90a8 Merge branch 'abandonclaimfix' into development 2016-04-04 22:20:29 -04:00
Jimmy Kiselak f464b3ae7c when decoding lbryum transactions, return values as Decimal 2016-04-04 22:20:15 -04:00
Jack d4b7064d2f fix sources problems 2016-04-01 22:11:11 -04:00
Jack 2540b9969f check UI version from command line
-check UI version, if out of date get a fresh copy. overridden by —ui
flag, which is used to specify a ui directory
2016-04-01 22:06:06 -04:00
Jack 4355b799cb before is_running is true all other methods return a failure 2016-03-29 22:02:36 -04:00
Jack a7fb434f9f update uri handler for change in daemon output 2016-03-29 17:04:01 -04:00
Jack b3465f3bbf fix /view, improve is_running, clean function outputs
-Use localhost:5279/view?name=wonderfullife to download and render a
file

-is_running is now the only function that will work during startup

-functions output json, rather than json in your json
2016-03-29 16:42:47 -04:00
Jack 4dfc3ff94c Merge branch 'master' into development 2016-03-29 16:34:47 -04:00
Jack 2670279b0d change access control allow origin to * 2016-03-28 16:49:51 -04:00
Jack Robison f4fd4245be Merge pull request #24 from lbryio/development
fix daemon directories for linux
2016-03-28 14:58:15 -04:00
Jack 200d239e0b log ui directory 2016-03-28 14:54:01 -04:00
Jack 41a0590182 fix daemon directories for linux 2016-03-28 14:53:32 -04:00
Jack 63b2c49354 don't start lbry app if daemon is running in console 2016-03-28 14:21:41 -04:00
Alex Grintsvayg c99d7ce89d fix weird version, add required fields for deb package 2016-03-27 18:20:02 -04:00
Alex Grintsvayg 79e382e064 add requirements.txt so we can have repeatable builds 2016-03-27 18:19:53 -04:00
Jack fa1d4dae0f add --ui parameter to lbrynet-daemon to set ui path
defaults on temp, which will download a .zip of the current ui to a
temp directory, which will be deleted when lbrynet-daemon closes
2016-03-25 21:03:58 -04:00
Jack 35f84b4414 Merge branch 'master' into development 2016-03-25 21:02:51 -04:00
Jack a882bdb08c fix output of get_time_behind_blockchain function 2016-03-25 09:32:24 -04:00
Jimmy Kiselak b5c2e1c95b Merge branch 'development' 2016-03-24 22:16:07 -04:00
Jack cfd6ea5a34 Merge branch 'development' 2016-03-24 21:15:54 -04:00
Jack b3cf5e8698 add bundle identifier to uri handler 2016-03-24 20:46:44 -04:00
Jimmy Kiselak 2d07223995 Merge branch 'fixsetuptools' into development 2016-03-24 20:01:05 -04:00
Jimmy Kiselak 32bb9fd4ec reorder setuptools 2016-03-24 20:00:56 -04:00
Jack Robison 37b5f22c1a Merge pull request #23 from lbryio/jsonrpc
Jsonrpc
2016-03-23 22:37:29 -04:00
Jack e0b00c09ce fix conflicts 2016-03-23 22:36:14 -04:00
Jack 71c4dba34d Merge branch 'development' into jsonrpc
# Conflicts:
#	setup.py
2016-03-23 22:34:27 -04:00
Jack 9a3187e36c merge updates 2016-03-23 22:29:48 -04:00
Jack c714a3f91c merge updates 2016-03-23 22:27:48 -04:00
Jimmy Kiselak 5d4846cf60 Merge branch 'versioning' into development 2016-03-23 22:07:11 -04:00
Jack 543b327d09 use only six 1.9 on os x 2016-03-23 22:06:04 -04:00
Jimmy Kiselak 1ccd2a3cc9 do version better 2016-03-23 22:02:02 -04:00
Jack 94398071eb have uri handler check if app is running
-checks if LBRY.app is running, starts it if it isn’t

-delete unused function in LBRYDaemon
2016-03-23 19:49:14 -04:00
Jimmy Kiselak 143476c76c Merge branch 'showwalletcatchup' into development 2016-03-22 22:43:10 -04:00
Jimmy Kiselak e85683e40f show more informative messages when blockchain is catching up 2016-03-22 22:42:45 -04:00
Alex Grintsvayg 141162e5ae fixes so we can build an sdist 2016-03-22 22:15:07 -04:00
Jack 13acbfb64f update uri handler
-use new jsonrpc daemon, start app if it isn’t running on first lbry://
request
2016-03-22 11:51:27 -04:00
Jack a55e3d8578 use UI downloaded to temp folder at startup 2016-03-22 10:37:13 -04:00
Jack 2486ae6d3f get rid of unused updater function
updater function was hacky and not the most reliable, to be replaced by
app version checking
2016-03-22 09:40:18 -04:00
Jack ba991b47ea add /view to dynamically generate a video containing page
-uses UI stored in Resources folder of app

-going to /view?name=  will download the corresponding stream and
display the file in the browser

-adds default daemon settings, currently they don’t do anything, to be
added to

-adds missing packages to setup.py
2016-03-22 00:03:17 -04:00
Jimmy Kiselak a096d0db37 Merge branch 'versioning' into development 2016-03-21 21:37:26 -04:00
Jimmy Kiselak e4a30c052e put the actual version in __init__.py 2016-03-21 21:37:15 -04:00
Jimmy Kiselak ccfe80ecfa Merge branch 'versioning' into development 2016-03-21 21:34:05 -04:00
Jimmy Kiselak df5b889f7d add a version to lbrynet 2016-03-21 21:33:55 -04:00
Jack 55f25c2613 consolidate search output
consolidate search output into a list of dicts
2016-03-21 12:06:19 -04:00
Jack 34eaa822a0 handle null parameter 2016-03-21 10:12:01 -04:00
Jack 5072f503c4 fix cross scripting problem
add access-control-allow-origin: http://localhost:5279
2016-03-20 22:53:01 -04:00
Jimmy Kiselak 8e6b5a5e55 Merge branch 'fewerlogstatements' into development 2016-03-19 22:39:59 -04:00
Jimmy Kiselak 246647641a remove some log statements that are useless, instead log whenever balance changes 2016-03-19 22:39:47 -04:00
Jimmy Kiselak 06a1bdbcba Merge branch 'lbcpatience' into development 2016-03-19 22:33:56 -04:00
Jimmy Kiselak a0b75d7ada Tell user to be patient if it's the first run and user has no funds, in two more places 2016-03-19 22:30:55 -04:00
Jimmy Kiselak d36036a9fe Tell user to be patient if it's the first run and user has no funds 2016-03-19 21:50:38 -04:00
Jimmy Kiselak a68d891770 enable checking first run status multiple times 2016-03-19 21:24:44 -04:00
Jimmy Kiselak f272a9ead2 Merge branch 'badunicode' into development 2016-03-19 18:56:21 -04:00
Jimmy Kiselak 8db2e10696 Merge branch 'master' of github.com:lbryio/lbry 2016-03-19 18:55:50 -04:00
Jimmy Kiselak bea4f7da98 Merge branch 'badunicode' 2016-03-19 18:55:37 -04:00
Jimmy Kiselak 3cd74c06d6 convert description in ControlHandlers to str so that the prompt does not get converted to unicode 2016-03-19 18:55:17 -04:00
Jack Robison 053681e4a5 Merge pull request #21 from lbryio/detect-if-daemon-is-running
check if daemon is running before starting console
2016-03-17 23:08:12 -04:00
Jack e3225f7123 add missing commits 2016-03-17 22:50:15 -04:00
Jack ef62b0e746 fix conflicts 2016-03-17 22:38:48 -04:00
Jack 7756d12993 check if daemon is running before starting console 2016-03-17 22:03:56 -04:00
Jimmy Kiselak 3b92d12a44 Merge branch 'walletbalancerefresh' into development 2016-03-17 21:55:20 -04:00
Jimmy Kiselak 4449bf3c75 change manage timer back to 60 seconds 2016-03-17 21:55:06 -04:00
Jimmy Kiselak 0200ed1341 refresh wallet balance every 3 seconds instead of 60 2016-03-17 20:19:13 -04:00
Jack 02bde900d6 update daemon and console
-don’t start console if daemon is running, display a message alerting
user

-move os x data directory to match app

-add timeout parameter to get function
2016-03-17 10:19:36 -04:00
Jack 36e299b4cf fix files
-don’t automatically remove files that can’t be found from
LBRYFileManager

-add timeout to GetStream
2016-03-17 00:44:04 -04:00
Jack 4e34f861c9 Merge branch 'development' into jsonrpc 2016-03-15 23:02:06 -04:00
Jack 42df2fe242 update daemon
convert to jsonrpc, fix a few issues, remove hacky functions
2016-03-14 12:30:22 -04:00
Jimmy Kiselak 7f11da8650 Merge branch 'walletcatchup' into development 2016-03-12 14:59:23 -05:00
Jimmy Kiselak dff0fcb1fd ensure the lbryum wallet is caught up before giving the prompt 2016-03-12 14:58:58 -05:00
Jimmy Kiselak c31d22f996 Merge branch 'metadata' into development 2016-03-12 14:46:31 -05:00
Jimmy Kiselak 14ab2b52e9 create fee field in metadata 2016-03-12 14:42:57 -05:00
Jimmy Kiselak e91f34f09b change metadata structure to use sources key 2016-03-12 14:25:46 -05:00
Jimmy Kiselak 6c733f84e9 Merge branch 'stopexceptions' into development 2016-03-12 14:08:42 -05:00
Jimmy Kiselak 71c2cd5065 Merge branch 'stopexceptions' 2016-03-12 14:08:32 -05:00
Jimmy Kiselak 45f9a10bfb hide exceptions that show up in the dht and due to bad metadata in the blockchain 2016-03-12 14:08:15 -05:00
Jimmy Kiselak 6ad203f767 Merge branch 'docsupdate' into development 2016-03-09 12:26:27 -05:00
Jimmy Kiselak 5bf895eefe update documentation to reflect using lbryum by default 2016-03-09 12:26:07 -05:00
Jack 5a8f5b14c1 Merge branch 'master' into development 2016-03-08 12:16:34 -05:00
Jack 27ccb37646 update daemon
check that managed files still exist, if they don’t remove them from
the manager
2016-03-08 12:15:49 -05:00
Jack Robison b4c528f6b5 Merge pull request #18 from lbryio/development
merge in commit that got left out
2016-03-03 14:05:25 -05:00
Jack Robison 517a255d5a Merge pull request #17 from lbryio/development
merge lbryum updates
2016-03-03 14:00:34 -05:00
Jack d76feeb320 use master branches 2016-03-03 13:55:03 -05:00
Jack e4f23b3fce better organize apps 2016-03-03 00:16:51 -05:00
Jack 02d8dc22e9 update daemon
-notify user when connected to lbrynet
-check for updates from status bar app
2016-03-02 18:32:48 -05:00
Jack 2fc3ec7224 update status bar app 2016-03-02 02:00:45 -05:00
Jack a243ac7a01 fix bug starting daemon from status bar 2016-02-29 15:04:20 -05:00
Jack 6f1ee78623 update daemon 2016-02-29 13:25:47 -05:00
Jack 6633370a34 Merge branch 'development' of https://github.com/lbryio/lbry into development 2016-02-28 23:51:09 -05:00
Jack a22e29532c start daemon from status bar 2016-02-28 23:49:37 -05:00
Jimmy Kiselak 96c8d1f68b Merge branch 'development' of github.com:lbryio/lbry into development 2016-02-28 12:46:29 -05:00
Jimmy Kiselak 4aa3bd56c4 Merge branch 'win32build' into development 2016-02-28 12:45:39 -05:00
Jimmy Kiselak 7d1cf7975a update win32 setup script to include lbryum 2016-02-28 12:45:21 -05:00
Jack 59d08a92d0 update status bar app 2016-02-27 17:49:49 -05:00
Jack 33c1a002da update daemon
only let local user connect to lbrynet-daemon
2016-02-27 13:19:26 -05:00
Jack 8f04d3418a get channel id from slack for test bot
in case i accidentally delete the bot conf file again and don’t want to
look up the channel id
2016-02-26 11:20:31 -05:00
Jimmy Kiselak f5b556c6cb Merge branch 'development' 2016-02-26 11:02:41 -05:00
Jack a18f3bf08a disable status bar 2016-02-26 10:59:09 -05:00
Jack Robison 41a0a0c64c Merge pull request #15 from lbryio/lbryum
merge updates
2016-02-26 10:41:07 -05:00
Jack b4c8a317d0 switch branch 2016-02-26 10:39:56 -05:00
Jack Robison 30ac075555 Merge pull request #14 from lbryio/development
merge updates
2016-02-26 10:29:38 -05:00
Jimmy Kiselak fcb317ca40 Merge branch 'electrumparity' into development 2016-02-26 01:46:21 -05:00
Jimmy Kiselak 9991f79326 add support for claiming names, abandoning names, and listing claimed names to the LBRYumWallet 2016-02-26 01:45:52 -05:00
Jack 7cf3f8c7cd fix typo 2016-02-25 17:18:18 -05:00
Jack eeef183cc6 update lbrynet-daemon 2016-02-25 17:17:07 -05:00
Jack 96bc02c8cb Merge branch 'development' into lbryum 2016-02-24 16:19:19 -05:00
Jimmy Kiselak af276a24ed Merge branch 'development' 2016-02-23 15:48:00 -05:00
Jimmy Kiselak a92dbae459 Merge branch 'electrum' into development 2016-02-23 15:17:52 -05:00
Jimmy Kiselak b0bfb5e443 use electrum as default 2016-02-23 15:13:34 -05:00
Jimmy Kiselak 671e6da104 show when the wallet is starting/started 2016-02-22 23:31:07 -05:00
Jack 485be533c9 make lbryum default wallet for daemon
with optional command line argument —wallet=
2016-02-22 22:32:07 -05:00
Jimmy Kiselak 53ff4cd651 Merge branch 'electruminstall' into development 2016-02-22 18:22:08 -05:00
Jimmy Kiselak a98c760d93 Merge branch 'electruminstall' 2016-02-22 18:22:00 -05:00
Jimmy Kiselak 9b0c95e37d make sure the correct version of six gets installed 2016-02-22 18:21:39 -05:00
Jimmy Kiselak b419b8f642 enable getting the whole claim trie 2016-02-22 14:24:49 -05:00
Jimmy Kiselak c32f8d0998 implement getblock 2016-02-22 12:18:28 -05:00
Jimmy Kiselak c6d253cc25 Merge branch 'updateinstructions' into development 2016-02-22 10:29:14 -05:00
Jimmy Kiselak c05cb62cdb Merge branch 'updateinstructions' 2016-02-22 10:29:00 -05:00
Jimmy Kiselak ddd213dda3 update manual build instructions to check out lbrycrd alpha 2016-02-22 10:28:33 -05:00
Jack 8aab844a48 add bdb 2016-02-22 10:05:55 -05:00
Jack 8fc1cbfc54 check for six 1.9.0 2016-02-20 15:30:30 -05:00
Jack 82ea330dda Merge remote-tracking branch 'origin/master' 2016-02-19 23:27:29 -05:00
Jack c63aa3033a install lbryum 2016-02-19 23:26:24 -05:00
Jimmy Kiselak 7837738c17 Merge branch 'master' of github.com:lbryio/lbry 2016-02-19 00:44:35 -05:00
Jimmy Kiselak bdb0ad4836 enable lbryum, the lightweight lbrycrd client 2016-02-19 00:44:08 -05:00
Jack 0dbf810cfe move status bar stuff 2016-02-19 00:07:19 -05:00
Jack 58aa4887ad update daemon
Start status bar if possible
2016-02-18 20:55:59 -05:00
Jack 3ff0916f49 remove icon 2016-02-18 20:48:43 -05:00
Jack cc9fb3ff41 fix icon path 2016-02-18 20:45:16 -05:00
Jack 2c51928b9d Status bar for lbrynet daemon 2016-02-18 20:41:23 -05:00
Jimmy Kiselak 4451978af6 make wallet method public and move common functions back into parent wallet class 2016-02-17 11:47:39 -05:00
Jack d4193c55ae update fetcher 2016-02-17 10:45:33 -05:00
Jimmy Kiselak ec3e365b3c fix up LBRYcrdWallet and split it into two classes 2016-02-16 23:10:26 -05:00
Jack c245c69389 Add check-for-new-version function to daemon 2016-02-16 14:48:10 -05:00
Jack 9a9a7c9d7a update daemon 2016-02-16 13:55:46 -05:00
Jack 20b516b5fa automatic updates
Adds automatic updates to lbrynet-daemon, this will check if the
installed versions of LBRY applications as well as the lbrynet python
installation are up to date. If they aren’t, it downloads the new
versions, installs them, and restarts the daemon.
2016-02-16 13:39:08 -05:00
Jack 4dcfeca092 speed up update scripts
don’t download repo history, only what’s current.
2016-02-16 10:25:15 -05:00
Jack 8ca8c73868 update scripts 2016-02-16 09:09:50 -05:00
Jack 1a1c101b9a Add lbry app update script 2016-02-15 23:00:24 -05:00
Jack a0a0e2d324 add daemon update script 2016-02-15 21:31:29 -05:00
Jack d544199eff Fix search issue and move some settings to conf.py 2016-02-15 10:12:49 -05:00
Jack 407ebeb699 Update daemon 2016-02-11 08:32:48 -05:00
Jimmy Kiselak 9ba12b3e3f Merge branch 'master' of github.com:lbryio/lbry 2016-02-04 15:19:47 -05:00
Jimmy Kiselak 97976cbee9 lower the minimum rate 2016-02-04 15:18:47 -05:00
Jack cb5c772233 Have autofetcher use managed downloader 2016-01-27 11:05:40 -05:00
Jimmy Kiselak 2bfbb824bf Merge branch 'master' of github.com:lbryio/lbry 2016-01-27 02:56:41 -05:00
Jimmy Kiselak 05189651ee update path for close file name on windows 2016-01-27 02:55:45 -05:00
James Kiselak 0c80134523 Merge pull request #12 from DaveA50/master
Enable building and installing of GUI for windows
2016-01-27 00:47:32 -05:00
David Amrhein 6c686520c4 Add instructions for setting up windows environment 2016-01-26 22:52:55 -05:00
Jack 49ae029572 Don't try to process blank IPs 2016-01-26 16:07:33 -05:00
David Amrhein 10e43203ed Enable building and installing of GUI for windows 2016-01-26 11:56:28 -05:00
Jack e25be5a522 Update lbrynet-daemon
Use PaymentRateManager
2016-01-25 23:59:57 -05:00
Jack 47ff64a9e9 Update lbrynet-daemon
Adds the following:

-Abandon claim from its txid
-Get your name claims
-Get time behind blockchain
-Fixes upload
2016-01-25 20:28:05 -05:00
Jack 35f3887d79 Don't try to download a blank name 2016-01-24 00:26:41 -05:00
Jack dacfc8b00a Update lbrynet-daemon
-Add optional content_license to name claim

-Get a better cost estimate, if the sd blob takes longer than 5 seconds
to download just use the key fee

-Adds the free speech flag as the default thumbnail if none is provided
2016-01-24 00:10:39 -05:00
Jimmy Kiselak 0840ac7d06 Merge branch 'master' of github.com:lbryio/lbry 2016-01-22 18:16:14 -05:00
Jimmy Kiselak f34b96f565 print a message when a download finishes 2016-01-22 18:16:00 -05:00
jackrobison 808fbed4f3 Don't open links while having a 0.0 balance 2016-01-22 16:46:35 -05:00
jackrobison b48800049b fix url 2016-01-22 16:19:20 -05:00
jackrobison 7e5d4166d8 Use locally hosted gui 2016-01-22 16:04:23 -05:00
Jimmy Kiselak 6b724ba8db Merge branch 'master' of github.com:lbryio/lbry 2016-01-22 15:56:01 -05:00
Jimmy Kiselak 25e1427a84 fix error that occurred when one connection's download was stopped due to another download finishing 2016-01-22 15:50:18 -05:00
jackrobison 82944bc103 Merge pull request #11 from jackrobison/master
Update daemon and uri handler
2016-01-22 09:45:34 -05:00
Jack 1e73b2437d Update daemon and uri handler
Add command to stop daemon from the terminal

If lbrynet-daemon isn’t running the uri handler will now redirect to
lbry.io/get
2016-01-22 09:44:38 -05:00
jackrobison 574cd304e3 Test ability to download from lbrynet
This tries to download a small image with a five minute timeout. After this, the bot waits ten minutes and tries again. Any failures get posted to slack.
2016-01-20 22:52:58 -05:00
jackrobison 2edcd1f5b2 Merge pull request #10 from jackrobison/master
Update lbrynet-daemon
2016-01-20 22:10:15 -05:00
Jack e144b26619 Merge remote-tracking branch 'lbryio/master' 2016-01-20 22:05:16 -05:00
Jack 9ef9220689 Add thumbnail option to name claim
Add thumbnail option to name claim
2016-01-20 22:01:03 -05:00
Jack 23b6a8c495 Add publish
Add publish function
2016-01-20 22:00:28 -05:00
jackrobison 4b9552fdf5 Fix output from shutdown function 2016-01-20 12:55:15 -05:00
jackrobison a249097170 Merge pull request #9 from jackrobison/master
Merge updates
2016-01-19 21:36:41 -05:00
jackrobison 6f4b2d7967 Delete x.sh 2016-01-19 21:13:29 -05:00
Jack 888d77c96c Update lbrynet-daemon
-Get rid of separate db for daemon, instead use already existing files
-Simplify the get function
-Add start/stop functions for lbry files
2016-01-19 21:07:16 -05:00
Jack e2ae1ca866 Remove file handle 2016-01-17 01:49:17 -05:00
Jack 7ef9a0f0bf Merge remote-tracking branch 'lbryio/master' 2016-01-16 23:16:21 -05:00
Jack 885a0882f2 Update daemon and uri handler 2016-01-16 23:06:24 -05:00
Jimmy Kiselak 2ddeca2976 fix bug caused by downloading file twice and deleting one 2016-01-16 01:16:37 -05:00
Jack 2085012874 Get managed lbry files 2016-01-13 09:42:30 -05:00
Jack ebb495ab8b Fix error at shutdown
Fixed messy error message that sometimes appeared at shutdown
2016-01-12 13:41:20 -05:00
Jack 905274d6d4 Use same downloader for daemon as is used for console
Use
lbrynet.lbryfilemanager.LBRYFileDownloader.ManagedLBRYFileDownloaderFact
ory instead of
lbrynet.lbryfile.client.LBRYFileDownloader.LBRYFileSaverFactory
2016-01-12 13:40:51 -05:00
Jack 120d7edf12 Better handle bad names, improve browser uri handler
Play videos in browser rather than in a separate application window
2016-01-12 12:42:32 -05:00
Jack 12cd06cae5 Add download history logging
Logs downloads as to not make duplicate files
2016-01-11 18:01:46 -05:00
Jack 42c26102d8 Make daemon shut down properly
Makes the daemon shutdown properly and adds better start/stop messages.
2016-01-11 15:52:38 -05:00
jackrobison e906564f70 Merge pull request #8 from jackrobison/master
Fix daemon paths and add settings
2016-01-07 10:28:59 -05:00
Jack b8b2dc3b6d Fix daemon paths and add settings
Fixed lbrycrdd path in lbrynet-daemon, added configurable max key fee
and data payment rate
2016-01-07 10:24:55 -05:00
Jack d69f76e68a Merge remote-tracking branch 'lbryio/master' 2016-01-07 10:20:46 -05:00
Jimmy Kiselak ec1ba02cca show where the log file is, and log failure to open file better 2016-01-06 13:08:20 -05:00
Jimmy Kiselak 49869d071a show when lbrycrdd is being stopped and when it stops 2016-01-06 00:56:45 -05:00
Jimmy Kiselak 39275682d9 show the estimated cost of a download and format the download size better 2016-01-06 00:50:50 -05:00
jackrobison 1dbc3a049b Merge pull request #7 from jackrobison/master
Fix paths for os x binaries
2015-12-30 23:56:26 -05:00
Jack 0a7b2683ff Fix paths for os x
Fix paths to use binaries in the app bundle
2015-12-20 03:29:13 -05:00
Jimmy Kiselak 9714985855 Merge branch 'master' of github.com:lbryio/lbry 2015-12-18 15:48:16 -05:00
Jimmy Kiselak d809b8eee0 increase usefulness of error messages and change the download directory back to pwd for linux 2015-12-18 15:48:02 -05:00
jackrobison 52e2ed2aa7 Update download directory for os x gui 2015-12-16 23:42:38 -05:00
jackrobison ab3cc3d2b6 Merge pull request #6 from jackrobison/master
Add 'get' function to daemon
2015-12-16 09:26:43 -05:00
Jack 0a33324321 Merge remote-tracking branch 'lbryio/master' 2015-12-16 09:16:42 -05:00
Jimmy Kiselak a948335cb9 show if the application is behind on the blockchain if an error occurs that could be caused by that 2015-12-15 14:42:29 -05:00
Jimmy Kiselak 6d2e5af6bc Inform user that they are behind on the blockchain if they get certain errors 2015-12-14 23:49:27 -05:00
Jimmy Kiselak 9a7c71394e make welcome messages more friendly 2015-12-14 22:35:16 -05:00
Jack 1ebf184e9f Add get function for daemon
Adds a ‘get’ function to the daemon, which downloads a file and returns
its file path.
2015-12-14 21:49:01 -05:00
jackrobison 48b013fa85 Delete autodownloader.py
File still exists in autodownloader branch
2015-12-14 15:56:19 -05:00
Jack e96dee478d Remove autofetcher from lbrynet-console
Disabled autofetcher in the console, moved getstream and fetcherdaemon
to their own file in lbrynet-daemon
2015-12-14 15:54:33 -05:00
Jimmy Kiselak 25d2a12a92 Merge branch 'master' of github.com:lbryio/lbry 2015-12-14 14:12:14 -05:00
Jimmy Kiselak b0af31a71c use version of unqlite that does not require cython 2015-12-14 14:12:01 -05:00
Jack 9fdd766429 Fix import error 2015-12-14 13:24:29 -05:00
jackrobison 28ce23350d Merge pull request #5 from lbryio/autodownloader
lbrynet-daemon
2015-12-14 13:19:01 -05:00
Jack 1abe890067 Disable console autofetcher 2015-12-14 13:14:04 -05:00
Jack 75fbedeeac Merge branch 'master' into autodownloader 2015-12-14 13:03:17 -05:00
Jack a1861a2f84 Update lbrynet-daemon
Add auto fetcher to fetch new name claims
2015-12-14 12:59:44 -05:00
Jack 0eecfb52ed Update lbrynet-daemon
Daemon creates data directory if it doesn’t already exist
2015-12-14 10:22:52 -05:00
Jimmy Kiselak ce1c28ffb9 allow the thumbnail link to get to the gui 2015-12-10 00:37:43 -05:00
Jack 9667b81c8d Update url handler 2015-12-09 23:59:19 -05:00
Jack afac596a7b Update url handler 2015-12-09 23:57:58 -05:00
Jimmy Kiselak 636692ba6a show a thumbnail if one is included in the blockchain 2015-12-09 02:33:50 -05:00
Jack 203f7e7ea6 Update lbry daemon 2015-12-08 00:37:49 -05:00
Jack 8aee19b0ef Fix error
Fixes an error if you don’t have a conf file set up, previously it
would fail because the AutoFetcher object doesn’t have a console object
until it’s called for the first time
2015-12-07 18:02:29 -05:00
Jimmy Kiselak 49ed31c895 stop showing options, show estimated cost 2015-12-07 15:54:51 -05:00
Jack 526075cd5e Fix get_downloads function
get_downloads would throw an error when it tried to open a file that
had already been downloaded, now it just ignores these duplicates
2015-12-07 09:17:45 -05:00
Jimmy Kiselak 71340805ec Merge branch 'master' of github.com:lbryio/lbry 2015-12-07 00:51:54 -05:00
Jimmy Kiselak 654585aa68 require version of requests that supports json parameter 2015-12-07 00:51:40 -05:00
Jack 441d3c1220 LBRYNet daemon
Adds a daemon for lbrynet. Currently commands are limited the following:

download_name(name)
resolve_name(name)
get_downloads
stop

This allows other programs to easily interact with lbrynet, such as
LBRYURIHandler. LBRYURIHandler can be built with py2app, the resulting
plist file must be edited in the same way the committed plist file has
been edited. When built and installed to the /Applications folder
lbry:// domain names will download and open the corresponding file so
long as the daemon is running.
2015-12-06 17:32:17 -05:00
James Kiselak fc2d7258fb Merge pull request #4 from teran-mckinney/master
Fix LICENSE link
2015-12-06 16:23:33 -05:00
Teran McKinney 8195cedcf4 Fix LICENSE link
I broke it, oops.
2015-12-06 19:36:41 +00:00
Jeremy Kauffman 3e98477707 Merge pull request #2 from teran-mckinney/master
Markdown cleanups
2015-12-06 11:26:35 -05:00
Teran McKinney 7b9479eca9 Markdown cleanups 2015-12-05 21:28:29 +00:00
Jack f15b67d386 Merge branch 'master' into autodownloader 2015-12-03 21:09:26 -05:00
Jack f3141727d7 Update from master and fix a path problem
Update from the master branch and a fix to a path problem in lbrynet-gui
2015-12-03 20:56:56 -05:00
Jimmy Kiselak c7e4638736 update gui to work with updated LBRYcrdWallet 2015-12-02 14:53:39 -05:00
Jimmy Kiselak d04981969f increase the time limit for waiting for lbrycrdd to start up 2015-11-25 11:16:27 -05:00
Jimmy Kiselak a148d4f446 use specific version of python-bitcoinrpc 2015-11-25 10:31:43 -05:00
Jack a9e105f9eb Make autofetcher ignore key payments 2015-11-24 01:17:47 -05:00
Jimmy Kiselak c8afce2a3a stop console from crashing on input before it is started 2015-11-23 15:11:34 -05:00
Jack ebf9d11f4d Rename a class 2015-11-20 10:42:19 -05:00
Jimmy Kiselak 7a3bdf93e9 make sure upnp is neither set nor unset if upnp is disabled 2015-11-19 23:20:17 -05:00
Jack 35d5c585ec Added a max key price set in autofetcher.conf 2015-11-19 16:20:12 -05:00
Jack 45eb4f7201 Improved autofetcher
Added commands:

start-autofetcher
stop-autofetcher
autofetcher-status
2015-11-19 14:43:36 -05:00
Jimmy Kiselak e4c2585e23 pass console object to all control handlers 2015-11-17 17:28:17 -05:00
jackrobison a05f2fe3fb Check blocks for new claims more frequently 2015-11-16 12:55:01 -05:00
jackrobison 94cdd6829c Delete workspace.xml 2015-11-14 21:59:57 -05:00
Jack 34aa51e98a remove debugging messages 2015-11-14 21:57:58 -05:00
Jack 6e93c68a77 Run AutoFetcher in the background 2015-11-14 21:53:16 -05:00
Jack f16eec2ad2 Automatic downloading now works 2015-11-14 20:36:53 -05:00
Jack 657c1a4626 Adds a command to automatically download files as names are claimed
Defaults on only trying to download wonderfullife
2015-11-12 00:03:49 -05:00
Jimmy Kiselak 6bf6e943cc Merge branch 'master' of github.com:lbryio/lbry 2015-11-11 15:06:31 -05:00
Jimmy Kiselak 6252f903ee automatically give LBC to users on the first run and update RUNNING.md for prompt interface 2015-11-11 15:06:14 -05:00
Jack a1e827fb3b LBRY autodownloader
Aquire LBRY files as they are published
2015-11-10 11:33:35 -05:00
Jack 40218e02e1 fixed a problem with publish 2015-11-07 00:15:42 -05:00
Jack 0891b0d294 Changed LBRYcrdWallet to retrieve the rpc config 2015-10-28 20:59:07 -04:00
Jimmy Kiselak 756c43c087 Merge branch 'master' of github.com:lbryio/lbry 2015-10-28 01:38:13 -04:00
Jimmy Kiselak 6488e66088 show lbry:// name of downloaded files if applicable as well as the status of the claim 2015-10-28 01:38:01 -04:00
jackrobison 31ee3fb12b Update LBRYConsole.py
Forgetting to add a new line at the end of lbrycrd.conf will no longer mess up the rpc login.
2015-10-27 12:07:09 -04:00
Jimmy Kiselak b80d45ad45 Prompt for file path instead of file name, then show file name and file path 2015-10-26 13:15:32 -04:00
jackrobison ea2a3c3b70 Update LBRYSettings.py 2015-10-26 11:00:07 -04:00
Jimmy Kiselak c0312159eb update help strings, reorder main commands, and take application status info out of 'status' command 2015-10-23 18:00:10 -04:00
Jimmy Kiselak e124f582aa make a single publish step and consolidate status 2015-10-23 14:51:26 -04:00
Jimmy Kiselak 54150a8f2a move some stream descriptor functions to the appropriate file, start creating a publish command 2015-10-22 20:36:03 -04:00
Jimmy Kiselak 385c221ef8 add some status messages when starting up and break commands into common and debug 2015-10-22 02:23:12 -04:00
Jimmy Kiselak 7df6e99e28 fix typo and formatting errors, stop console's shutdown from running twice on exit, give more informative message if ports can't be bound, only set upnp if there isn't already a redirect on that port/protocol, and only unset upnp if the redirect was set by the program 2015-10-19 15:05:17 -04:00
Jimmy Kiselak 76a5f2f516 show and log when an error occurs during shutdown 2015-10-18 23:56:13 -04:00
Jimmy Kiselak 936c1f2ada fix typo and make sure objects exist before trying to stop them 2015-10-18 22:36:09 -04:00
Jimmy Kiselak 5787802077 change the console ui to command based rather than option based 2015-10-15 14:12:22 -04:00
Jimmy Kiselak c902d25524 start upgroading the console interface 2015-10-12 13:52:47 -04:00
Jimmy Kiselak d152336f42 initial commit of auto-launch lbrycrdd 2015-10-08 11:01:50 -04:00
Jimmy Kiselak 7ab0ae18be fix typo 2015-10-02 18:32:20 -04:00
Jimmy Kiselak 6189eddecf more formatting 2015-10-02 18:30:16 -04:00
Jimmy Kiselak cc7471a9af fix formatting more 2015-10-02 18:23:11 -04:00
Jimmy Kiselak eabaca361c fix formatting 2015-10-02 17:08:15 -04:00
Jimmy Kiselak 141ca2498c rename RUNNING to RUNNING.md 2015-10-02 16:40:46 -04:00
Jimmy Kiselak 964db2a779 enable setting lbrycrdd path in gui conf, disable launching lbrycrdd by default in linux gui, change running instructions, put linux gui conf in users home directory 2015-10-02 16:38:57 -04:00
Jimmy Kiselak f2867542b1 remove length from metadata stored in blockchain 2015-09-22 13:06:20 -04:00
Jimmy Kiselak 8f6e886821 show metadata found in blockchain in console 2015-09-22 12:21:16 -04:00
Jimmy Kiselak dfca7bc2c4 make console pay decryption key fee 2015-09-22 12:08:17 -04:00
Jimmy Kiselak f94b04bb19 make class to encompass stream metadata 2015-09-21 22:06:04 -04:00
Jimmy Kiselak be1e97c616 show name claim options better, and fix bug when length is entered manually 2015-09-20 23:05:10 -04:00
Jimmy Kiselak 9790e9f843 put more fields into the value of a name claim, and fix bug where creating a plain stream descriptor file fails if no file name is given 2015-09-20 00:49:29 -04:00
Jimmy Kiselak e339d3857f make saving plain stream descriptor file work when no file name is given 2015-09-18 00:49:06 -04:00
Jimmy Kiselak 0e4f21842c when creating a new lbry file, make sure its status is set to completed 2015-09-18 00:20:07 -04:00
Jimmy Kiselak d4ea9a1ba3 rename downloader gui to simply gui 2015-09-18 00:09:53 -04:00
Jimmy Kiselak 5300fa929b make sure blobfiles directory is created in console, and make sure blobfiles dir is always inside the db dir for the gui 2015-09-17 23:47:36 -04:00
Jimmy Kiselak 8a5a66a06a in console disable putting blob dir outside of the db dir, and rename conf_dir to db_dir/data_dir 2015-09-17 23:10:14 -04:00
Jimmy Kiselak 43ed4427b4 stop the console from upgrading the db on a brand new conf dir 2015-09-17 12:05:08 -04:00
Jimmy Kiselak 22b0d92e6b disable the blind repeater 2015-09-17 11:03:57 -04:00
Jimmy Kiselak 7eb528232e enable getting a new address via the console 2015-09-17 10:59:57 -04:00
Jimmy Kiselak 33b6b85e72 better error messages in console when funds are exhausted 2015-09-17 01:43:41 -04:00
Jimmy Kiselak 8177119671 Fix how some errors are presented to the user
If an invalid stream descriptor hash is entered, abort and
give a useful error.

If a name doesn't resolve, abort and give a useful error.

If a name resolves to something invalid, abort and give a useful error.
2015-09-16 16:27:46 -04:00
Jimmy Kiselak 4b407a9dd2 shut down session last, actually save LBRY file metadata 2015-09-15 00:30:49 -04:00
kauffj 9b904a7b4a Rename INSTALL to INSTALL.md 2015-09-11 15:07:25 -04:00
kauffj e0424a1e38 Or it needs to be .md? 2015-09-11 15:06:59 -04:00
kauffj 00c08e05f5 github doesn't like setext markdown headers 2015-09-11 15:06:28 -04:00
Jimmy Kiselak 0836d9c5ee fix bug pulling blob length out of the database 2015-09-10 21:43:46 -04:00
Jimmy Kiselak ff5b6c4eab if lbrycrd server fails to launch, don't stop it at shutdown 2015-09-09 12:17:46 -04:00
Jimmy Kiselak bb5cd49327 Use named loggers, fix some pep8 formatting mistakes 2015-09-08 15:42:56 -04:00
Jimmy Kiselak 6f40ef6015 fix typo in migrator path, set up logging and running as a script for migrator, change args to windows migrator exe so they are all strings 2015-09-07 23:59:59 -04:00
Jimmy Kiselak c7758506ac remove leveldb, use sqlite and unqlite. create migrator tool 2015-09-04 16:22:02 -04:00
Jimmy Kiselak 192ac6959a more specific exceptions, and change when blobs are deleted
More specific exceptions are raised when problems are encountered
looking up metadata and validating stream descriptor files, and
on the GUI those more specific exceptions are used to prevent
errors from being presented to the user.

If the user has selected the option to re-upload data for some
stream, blobs downloaded for that purpose will not be deleted
when they are finished being output. Instead, by default, for
the GUI they will be deleted when the stream is removed from
the GUI. That can be changed so they are not deleted at all,
using the lbry.conf file.
2015-09-01 17:49:26 -04:00
Jimmy Kiselak 465a4643a8 change how the windows client finds pictures 2015-09-01 00:08:53 -04:00
Jimmy Kiselak 1bf0065d9d Show download progress in terms of percent, console startup errors now cause the application to abort, and a friendlier error is shown when no lbrycrd server is running 2015-08-31 22:05:50 -04:00
Jimmy Kiselak c14efc843c disable the URI entry bar until the app has finished starting up 2015-08-31 11:25:48 -04:00
Jimmy Kiselak 0506dfba10 when looking up peers, only return one instance of each peer 2015-08-31 11:14:25 -04:00
Jimmy Kiselak 7e4f36e8b4 Make sure errors resulting from connections failing don't make it to the user interface, as they are expected 2015-08-31 10:46:22 -04:00
Jimmy Kiselak 55dc482a61 enable running a server within lbrydownloader, and create a configuration file for lbrydownloader 2015-08-31 01:14:11 -04:00
Jimmy Kiselak 05b9f9cae6 refactor the downloading app a bit 2015-08-28 15:17:28 -04:00
Jimmy Kiselak c79868de3e check for specific vlc paths on windows 2015-08-28 11:47:21 -04:00
Jimmy Kiselak 7eeac060ab don't use distutils to check if vlc is available 2015-08-27 23:32:45 -04:00
Jimmy Kiselak c8b2b7b279 Downloader options in its own class, show options in gui downloader
Put stream downloader options into its own class, and make stream
downloader options global to the stream type rather than specific
to each factory.

Show downloader options in the lbrynet-downloader-gui.

Make a class for downloader option choices, so that the descriptions
can be displayed.

In the console, if there are multiple choices for the download
option, make it a list selected by its index.

Make sure that the ConnectionManager closes properly when some of
the connections fail to open (e.g. due to a host being down)
2015-08-27 15:41:17 -04:00
Jimmy Kiselak f4b3187494 use lbrycrd.conf in LBRYConsole to get rpc credentials 2015-08-24 13:19:03 -04:00
314 changed files with 31159 additions and 14209 deletions

No files matched your search

+44
View File
@@ -0,0 +1,44 @@
version: 1.0.{build}
environment:
GH_TOKEN:
secure: LiI5jyuHUw6XbH4kC3gP1HX4P/v4rwD/gCNtaFhQu2AvJz1/1wALkp5ECnIxRySN
key_pass:
secure: u6DydPcdrUJlxGL9uc7yQRYG8+5rY6aAEE9nfCSzFyNzZlX9NniOp8Uh5ZKQqX7bGEngLI6ipbLfiJvn0XFnhbn2iTkOuMqOXVJVOehvwlQ=
pfx_key:
secure: 1mwqyRy7hDqDjDK+TIAoaXyXzpNgwruFNA6TPkinUcVM7A+NLD33RQLnfnwVy+R5ovD2pUfhQ6+N0Fqebv6tZh436LIEsock+6IOdpgFwrg=
AWS_ACCESS_KEY_ID:
secure: iVGwoJ7ogspjSmuqr+haVPLglSgQsp6tUZx6mIlKH7Q=
AWS_SECRET_ACCESS_KEY:
secure: zKaqdZGPl0exDL5YhJkb33prSemC9Rzg9S7Lw2wFy1WnJ6ffgl6mQH7jqJDUTqsY
#notifications:
# - provider: Slack
# incoming_webhook:
# secure: LuxwG5OZnnA//gmSXzCKu8/FRqYjCgGfVFqajSsGHeQ1HQNp7rYNhQpsO8/3PK63xKJj3wzt86DJekf9q9Q5OcHa9AHXUQbEveX0psd7elw=
clone_folder: c:\projects\lbry
test_script:
- cd C:\projects\lbry\
- pip install cython
- pip install mock pylint unqlite
- pip install .
- pylint lbrynet
# disable tests for now so that appveyor can build the app
- set PYTHONPATH=.
- trial lbrynet.tests
# TODO: integration tests do not work
#- python -m unittest discover tests/integration
#- rvm use 2.3.1 && gem install danger --version '~> 4.0' && danger
build_script:
- cd C:\projects\lbry\build\
- ps: .\build.ps1
artifacts:
- path: build\dist\*.zip
name: lbrynet-daemon
+1
View File
@@ -0,0 +1 @@
/CHANGELOG.md merge=union
+53
View File
@@ -0,0 +1,53 @@
<!--
Thanks for reporting an issue to LBRY and helping us improve!
To make it possible for us to help you, please fill out below information carefully.
Before reporting any issues, please make sure that you're using the latest version.
- App: https://github.com/lbryio/lbry-app/releases
- Daemon: https://github.com/lbryio/lbry/releases
We are also available on Discord at https://chat.lbry.io
-->
## The Issue
In order to <achieve some value>,
as a <type of user>,
I want <some functionality>.
### Steps to reproduce
1.
2.
3.
### Expected behaviour
Tell us what should happen
### Actual behaviour
Tell us what happens instead
## System Configuration
<!-- For the app, this info is in the About section at the bottom of the Help page.
You can include a screenshot instead of typing it out -->
<!-- For the daemon, run:
curl 'http://localhost:5279' --data '{"method":"version"}'
and include the full output -->
- LBRY Daemon version:
- LBRY App version:
- LBRY Installation ID:
- Operating system:
## Anything Else
<!-- Include anything else that does not fit into the above sections -->
## Screenshots
<!-- If a screenshot would help explain the bug, please include one or two here -->
+24
View File
@@ -1 +1,25 @@
*.pyc
*.egg
*.so
*.xml
*.iml
*.log
*.pem
*.decTest
*.prof
.#*
/build/build
/build/dist
/bulid/requirements_base.txt
/lbrynet.egg-info
/docs_build
/lbry-venv
.idea/
.coverage
.DS_Store
# temporary files from the twisted.trial test runner
_trial_temp/
+443
View File
@@ -0,0 +1,443 @@
[MASTER]
# Specify a configuration file.
#rcfile=
# Python code to execute, usually for sys.path manipulation such as
# pygtk.require().
#init-hook=
# Add files or directories to the blacklist. They should be base names, not
# paths.
ignore=CVS
# Add files or directories matching the regex patterns to the
# blacklist. The regex matches against base names, not paths.
# `\.#.*` - add emacs tmp files to the blacklist
ignore-patterns=\.#.*
# Pickle collected data for later comparisons.
persistent=yes
# List of plugins (as comma separated values of python modules names) to load,
# usually to register additional checkers.
load-plugins=
# Use multiple processes to speed up Pylint.
jobs=1
# Allow loading of arbitrary C extensions. Extensions are imported into the
# active Python interpreter and may run arbitrary code.
unsafe-load-any-extension=no
# A comma-separated list of package or module names from where C extensions may
# be loaded. Extensions are loading into the active Python interpreter and may
# run arbitrary code
extension-pkg-whitelist=
miniupnpc,
unqlite
# Allow optimization of some AST trees. This will activate a peephole AST
# optimizer, which will apply various small optimizations. For instance, it can
# be used to obtain the result of joining multiple strings with the addition
# operator. Joining a lot of strings can lead to a maximum recursion error in
# Pylint and this flag can prevent that. It has one side effect, the resulting
# AST will be different than the one from reality.
optimize-ast=no
[MESSAGES CONTROL]
# Only show warnings with the listed confidence levels. Leave empty to show
# all. Valid levels: HIGH, INFERENCE, INFERENCE_FAILURE, UNDEFINED
confidence=
# Enable the message, report, category or checker with the given id(s). You can
# either give multiple identifier separated by comma (,) or put this option
# multiple time (only on the command line, not in the configuration file where
# it should appear only once). See also the "--disable" option for examples.
#enable=
# Disable the message, report, category or checker with the given id(s). You
# can either give multiple identifiers separated by comma (,) or put this
# option multiple times (only on the command line, not in the configuration
# file where it should appear only once).You can also use "--disable=all" to
# disable everything first and then reenable specific checks. For example, if
# you want to run only the similarities checker, you can use "--disable=all
# --enable=similarities". If you want to run only the classes checker, but have
# no Warning level messages displayed, use"--disable=all --enable=classes
# --disable=W"
disable=
anomalous-backslash-in-string,
arguments-differ,
attribute-defined-outside-init,
bad-continuation,
bare-except,
broad-except,
cell-var-from-loop,
consider-iterating-dictionary,
dangerous-default-value,
duplicate-code,
fixme,
global-statement,
inherit-non-class,
invalid-name,
len-as-condition,
locally-disabled,
logging-not-lazy,
missing-docstring,
no-else-return,
no-init,
no-member,
no-self-use,
protected-access,
redefined-builtin,
redefined-outer-name,
redefined-variable-type,
relative-import,
signature-differs,
super-init-not-called,
too-few-public-methods,
too-many-arguments,
too-many-branches,
too-many-instance-attributes,
too-many-lines,
too-many-locals,
too-many-nested-blocks,
too-many-public-methods,
too-many-return-statements,
too-many-statements,
trailing-newlines,
undefined-loop-variable,
ungrouped-imports,
unnecessary-lambda,
unused-argument,
unused-variable,
wildcard-import,
wrong-import-order,
wrong-import-position,
deprecated-lambda,
simplifiable-if-statement,
unidiomatic-typecheck,
global-at-module-level,
inconsistent-return-statements,
keyword-arg-before-vararg
[REPORTS]
# Set the output format. Available formats are text, parseable, colorized, msvs
# (visual studio) and html. You can also give a reporter class, eg
# mypackage.mymodule.MyReporterClass.
output-format=text
# Put messages in a separate file for each module / package specified on the
# command line instead of printing them on stdout. Reports (if any) will be
# written in a file name "pylint_global.[txt|html]".
files-output=no
# Tells whether to display a full report or only the messages
reports=no
# Python expression which should return a note less than 10 (10 is the highest
# note). You have access to the variables errors warning, statement which
# respectively contain the number of errors / warnings messages and the total
# number of statements analyzed. This is used by the global evaluation report
# (RP0004).
evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10)
# Template used to display messages. This is a python new-style format string
# used to format the message information. See doc for all details
#msg-template=
[VARIABLES]
# Tells whether we should check for unused import in __init__ files.
init-import=no
# A regular expression matching the name of dummy variables (i.e. expectedly
# not used).
dummy-variables-rgx=_$|dummy
# List of additional names supposed to be defined in builtins. Remember that
# you should avoid to define new builtins when possible.
additional-builtins=
# List of strings which can identify a callback function by name. A callback
# name must start or end with one of those strings.
callbacks=cb_,_cb
[LOGGING]
# Logging modules to check that the string format arguments are in logging
# function parameter format
logging-modules=logging
[BASIC]
# List of builtins function names that should not be used, separated by a comma
bad-functions=map,filter,input
# Good variable names which should always be accepted, separated by a comma
# allow `d` as its used frequently for deferred callback chains
good-names=i,j,k,ex,Run,_,d
# Bad variable names which should always be refused, separated by a comma
bad-names=foo,bar,baz,toto,tutu,tata
# Colon-delimited sets of names that determine each other's naming style when
# the name regexes allow several styles.
name-group=
# Include a hint for the correct naming format with invalid-name
include-naming-hint=no
# Regular expression matching correct function names
function-rgx=[a-z_][a-z0-9_]{2,30}$
# Naming hint for function names
function-name-hint=[a-z_][a-z0-9_]{2,30}$
# Regular expression matching correct variable names
variable-rgx=[a-z_][a-z0-9_]{2,30}$
# Naming hint for variable names
variable-name-hint=[a-z_][a-z0-9_]{2,30}$
# Regular expression matching correct constant names
const-rgx=(([A-Z_][A-Z0-9_]*)|(__.*__))$
# Naming hint for constant names
const-name-hint=(([A-Z_][A-Z0-9_]*)|(__.*__))$
# Regular expression matching correct attribute names
attr-rgx=[a-z_][a-z0-9_]{2,30}$
# Naming hint for attribute names
attr-name-hint=[a-z_][a-z0-9_]{2,30}$
# Regular expression matching correct argument names
argument-rgx=[a-z_][a-z0-9_]{2,30}$
# Naming hint for argument names
argument-name-hint=[a-z_][a-z0-9_]{2,30}$
# Regular expression matching correct class attribute names
class-attribute-rgx=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
# Naming hint for class attribute names
class-attribute-name-hint=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
# Regular expression matching correct inline iteration names
inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$
# Naming hint for inline iteration names
inlinevar-name-hint=[A-Za-z_][A-Za-z0-9_]*$
# Regular expression matching correct class names
class-rgx=[A-Z_][a-zA-Z0-9]+$
# Naming hint for class names
class-name-hint=[A-Z_][a-zA-Z0-9]+$
# Regular expression matching correct module names
module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
# Naming hint for module names
module-name-hint=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
# Regular expression matching correct method names
method-rgx=[a-z_][a-z0-9_]{2,30}$
# Naming hint for method names
method-name-hint=[a-z_][a-z0-9_]{2,30}$
# Regular expression which should only match function or class names that do
# not require a docstring.
no-docstring-rgx=^_
# Minimum line length for functions/classes that require docstrings, shorter
# ones are exempt.
docstring-min-length=-1
[ELIF]
# Maximum number of nested blocks for function / method body
max-nested-blocks=5
[SPELLING]
# Spelling dictionary name. Available dictionaries: none. To make it working
# install python-enchant package.
spelling-dict=
# List of comma separated words that should not be checked.
spelling-ignore-words=
# A path to a file that contains private dictionary; one word per line.
spelling-private-dict-file=
# Tells whether to store unknown words to indicated private dictionary in
# --spelling-private-dict-file option instead of raising a message.
spelling-store-unknown-words=no
[FORMAT]
# Maximum number of characters on a single line.
max-line-length=120
# Regexp for a line that is allowed to be longer than the limit.
ignore-long-lines=^\s*(# )?<?https?://\S+>?$
# Allow the body of an if to be on the same line as the test if there is no
# else.
single-line-if-stmt=no
# List of optional constructs for which whitespace checking is disabled. `dict-
# separator` is used to allow tabulation in dicts, etc.: {1 : 1,\n222: 2}.
# `trailing-comma` allows a space between comma and closing bracket: (a, ).
# `empty-line` allows space-only lines.
no-space-check=trailing-comma,dict-separator
# Maximum number of lines in a module
max-module-lines=1000
# String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
# tab).
indent-string=' '
# Number of spaces of indent required inside a hanging or continued line.
indent-after-paren=4
# Expected format of line ending, e.g. empty (any line ending), LF or CRLF.
expected-line-ending-format=
[MISCELLANEOUS]
# List of note tags to take in consideration, separated by a comma.
notes=FIXME,XXX,TODO
[SIMILARITIES]
# Minimum lines number of a similarity.
min-similarity-lines=4
# Ignore comments when computing similarities.
ignore-comments=yes
# Ignore docstrings when computing similarities.
ignore-docstrings=yes
# Ignore imports when computing similarities.
ignore-imports=no
[TYPECHECK]
# Tells whether missing members accessed in mixin class should be ignored. A
# mixin class is detected if its name ends with "mixin" (case insensitive).
ignore-mixin-members=yes
# List of module names for which member attributes should not be checked
# (useful for modules/projects where namespaces are manipulated during runtime
# and thus existing member attributes cannot be deduced by static analysis. It
# supports qualified module names, as well as Unix pattern matching.
ignored-modules=twisted.internet.reactor,leveldb,distutils
# Ignoring distutils because: https://github.com/PyCQA/pylint/issues/73
# List of classes names for which member attributes should not be checked
# (useful for classes with attributes dynamically set). This supports can work
# with qualified names.
ignored-classes=twisted.internet.reactor,RequestMessage
# List of members which are set dynamically and missed by pylint inference
# system, and so shouldn't trigger E1101 when accessed. Python regular
# expressions are accepted.
generated-members=lbrynet.lbrynet_daemon.LBRYDaemon.Parameters
[IMPORTS]
# Deprecated modules which should not be used, separated by a comma
deprecated-modules=regsub,TERMIOS,Bastion,rexec
# Create a graph of every (i.e. internal and external) dependencies in the
# given file (report RP0402 must not be disabled)
import-graph=
# Create a graph of external dependencies in the given file (report RP0402 must
# not be disabled)
ext-import-graph=
# Create a graph of internal dependencies in the given file (report RP0402 must
# not be disabled)
int-import-graph=
[DESIGN]
# Maximum number of arguments for function / method
max-args=5
# Argument names that match this expression will be ignored. Default to name
# with leading underscore
ignored-argument-names=_.*
# Maximum number of locals for function / method body
max-locals=15
# Maximum number of return / yield for function / method body
max-returns=6
# Maximum number of branch for function / method body
max-branches=12
# Maximum number of statements in function / method body
max-statements=50
# Maximum number of parents for a class (see R0901).
max-parents=7
# Maximum number of attributes for a class (see R0902).
max-attributes=7
# Minimum number of public methods for a class (see R0903).
min-public-methods=2
# Maximum number of public methods for a class (see R0904).
max-public-methods=20
# Maximum number of boolean expressions in a if statement
max-bool-expr=5
[CLASSES]
# List of method names used to declare (i.e. assign) instance attributes.
defining-attr-methods=__init__,__new__,setUp
# List of valid names for the first argument in a class method.
valid-classmethod-first-arg=cls
# List of valid names for the first argument in a metaclass class method.
valid-metaclass-classmethod-first-arg=mcs
# List of member names, which should be excluded from the protected access
# warning.
exclude-protected=_asdict,_fields,_replace,_source,_make
[EXCEPTIONS]
# Exceptions that will emit a warning when being caught. Defaults to
# "Exception"
overgeneral-exceptions=Exception
+47
View File
@@ -0,0 +1,47 @@
os: linux
dist: trusty
language: python
python: 2.7
branches:
except:
- gh-pages
notifications:
slack:
secure: "Am13HPtpgCMljh0MDVuoFHvQXB8yhf4Kvf/qAeSp5N0vsHGL70CSF9Ahccw8dVPE6mbuak1OGtSUb6/UaErLHkpz3ztaRLkDa9x7CmBB3Kynnh8oO2VbB7b/2ROULqkhF4VZmAnNfwrQrbC3gs8Sybp261Nyc7y4ww15xDYBrk2fyq4ds2DCaJdRxfJUJFonrZ6KXr3fVaXosO6cjuyS8eRodcmrqsT4cCtinjNTD1hGWoH107E4ObSmpVelxQO193KhNJMRiLlEcVkvYUOqIWBtwdGHbNE/6Yeuq1TXgKJ0KeJWAmW3wTfUYNngGXNAsyCnrhul5TKNevNzfIAQZHvRsczYiWPJV6LtohHT0CcUiCXJtvEPOyahEBfwK3etY/xxFqny7N9OEmpdW2sgsEPNPX2LJynJti2rQA9SuAD1ogR3ZpDy/NXoaAZf8PTdPcuNUMULV9PGG7tVrLBecO/W1qO6hdFxwlLdgqGLxAENZgGp++v/DhPk/WvtmHj7iTbRq0nxaTWyX5uKOn2ADH+k/yfutjv6BsQU9xNyPeZEEtuEpc6X6waiYn/8G9vl9PecvKC5H0MgsZ6asAxmg7mZ3VSMFG7mo8ENeOhSZ0Oz6ZTBILL3wFccZA9uJIq7NWmqC9dRiGiuKXBB62No7sINoHg3114e2xYa9qvNmGg="
cache:
directories:
- $HOME/.cache/pip
- $HOME/Library/Caches/pip
- $TRAVIS_BUILD_DIR/cache/wheel
addons:
#srcclr:
# debug: true
apt:
packages:
- libgmp3-dev
- build-essential
- git
- libssl-dev
- libffi-dev
before_install:
- virtualenv venv
- source venv/bin/activate
install:
- pip install -U pip
- pip install -r requirements.txt
- pip install .
script:
- pip install cython
- pip install mock pylint unqlite
- pylint lbrynet
- PYTHONPATH=. trial lbrynet.tests
- python -m unittest discover lbrynet/tests/integration -v
- rvm install ruby-2.3.1
- rvm use 2.3.1 && gem install danger --version '~> 4.0' && danger
+737
View File
@@ -0,0 +1,737 @@
# Change Log
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/) with
regard to the json-rpc api. As we're currently pre-1.0 release, we
can and probably will change functionality and break backwards compatability
at anytime.
## [Unreleased]
### Security
*
*
### Fixed
*
*
### Deprecated
*
*
### Changed
*
*
### Added
*
*
### Removed
*
*
## [0.19.3] - 2018-05-04
### Changed
* download blockchain headers from s3 before starting the wallet when the local height is more than s3_headers_depth (a config setting) blocks behind
* un-deprecated report_bug command
## [0.19.2] - 2018-03-28
### Fixed
* incorrectly raised download cancelled error for already verified blob files
* infinite loop where reflector client keeps trying to send failing blobs, which may be failing because they are invalid and thus will never be successfully received
* docstring bugs for `stream_availability`, `channel_import`, and `blob_announce`
### Added
* `blob_reflect` command to send specific blobs to a reflector server
* unit test for docopt
### Removed
* `flags` decorator from server.py as short flags are no longer used when using api/cli methods
### Changed
* Bumped `lbryum` requirement to 3.2.1 [see changelog](https://github.com/lbryio/lbryum/blob/master/CHANGELOG.md#321---2018-03-28)
## [0.19.1] - 2018-03-20
### Fixed
* Fixed the inconsistencies in API and CLI docstrings
* `blob_announce` error when announcing a single blob
* `blob_list` error when looking up blobs by stream or sd hash ([1126](https://github.com/lbryio/lbry/pull/1126))
* Claiming a channel with the exact amount present in wallet would return a confusing error ([1107](https://github.com/lbryio/lbry/issues/1107))
* Channel creation to use same bid logic as for claims ([1148](https://github.com/lbryio/lbry/pull/1148))
### Deprecated
* `report_bug` jsonrpc command
### Changed
* Bumped `lbryschema` requirement to 0.0.15 [see changelog](https://github.com/lbryio/lbryschema/blob/master/CHANGELOG.md#0015---2018-03-20)
* Bumped `lbryum` requirement to 3.2.0 [see changelog](https://github.com/lbryio/lbryum/blob/master/CHANGELOG.md#320---2018-03-20)
* Reflector server to periodically check and set `should_announce` for sd and head blobs instead of during each request
* Reflector server to use `SQLiteStorage` to find needed blob hashes for a stream
### Added
* Scripts to auto-generate documentation ([1128](https://github.com/lbryio/lbry/pull/1128))
* Now updating new channel also takes into consideration the original bid amount, so now channel could be updated for wallet balance + the original bid amount ([1137](https://github.com/lbryio/lbry/pull/1137))
* Forward-compatibility for upcoming DHT bencoding changes
### Removed
* Short(single dashed) arguments for `lbrynet-cli`
## [0.19.0] - 2018-03-02
### Fixed
* improper parsing of arguments to CLI settings_set (https://github.com/lbryio/lbry/issues/930)
* unnecessarily verbose exchange rate error (https://github.com/lbryio/lbry/issues/984)
* value error due to a race condition when saving to the claim cache (https://github.com/lbryio/lbry/issues/1013)
* being unable to re-download updated content (https://github.com/lbryio/lbry/issues/951)
* sending error messages for failed api requests
* file manager startup being slow when handling thousands of files
* handling decryption error for blobs encrypted with an invalid key
* handling stream with no data blob (https://github.com/lbryio/lbry/issues/905)
* fetching the external ip
* `blob_list` returning an error with --uri parameter and incorrectly returning `[]` for streams where blobs are known (https://github.com/lbryio/lbry/issues/895)
* `get` failing with a non-useful error message when given a uri for a channel claim
* exception checking in several wallet unit tests
* daemon not erring properly for non-numeric values being passed to the `bid` parameter for the `publish` method
* `publish` command to allow updating claims with a `bid` amount higher than the wallet balance, so long as the amount is less than the wallet balance plus the bid amount of the claim being updated (https://github.com/lbryio/lbry/issues/748)
* incorrect `blob_num` for the stream terminator blob, which would result in creating invalid streams. Such invalid streams are detected on startup and are automatically removed (https://github.com/lbryio/lbry/issues/1124)
### Deprecated
* `channel_list_mine`, replaced with `channel_list`
* `get_availability`, replaced with `stream_availability`
### Changed
* dht tests to only be in one folder
* config file format of `known_dht_nodes`, `lbryum_servers`, and `reflector_servers` to lists of `hostname:port` strings
* startup of `lbrynet-daemon` to block on the wallet being unlocked if it is encrypted
* `publish` to verify the claim schema before trying to make the claim and to return better error messages
* `channel_list_mine` to be instead named `channel_list`
* `channel_list` to include channels where the certificate info has been imported but the claim is not in the wallet
* file objects returned by `file_list` and `get` to contain `claim_name` field instead of `name`
* `name` filter parameter for `file_list`, `file_set_status`, `file_reflect`, and `file_delete` to be named `claim_name`
* `metadata` field in file objects returned by `file_list` and `get` to be a [Metadata object](https://github.com/lbryio/lbryschema/blob/master/lbryschema/proto/metadata.proto#L5)
* assumption for time it takes to announce single hash from 1 second to 5 seconds
* HTTP error codes for failed api requests, conform to http://www.jsonrpc.org/specification#error_object (previously http errors were set for jsonrpc errors)
* api requests resulting in errors to return less verbose tracebacks
* logging about streams to not include file names (only include sd hashes)
* wallet info exchange to re-use addresses, this was a significant source of address bloat in the wallet
* lbrynet to not manually save the wallet file and to let lbryum handle it
* internals to use reworked lbryum `payto` command
* dht `Node` class to re-attempt joining the network every 60 secs if no peers are known
* lbrynet database and file manager to separate the creation of lbry files (from downloading or publishing) from the handling of a stream. All files have a stream, but not all streams may have a file. (https://github.com/lbryio/lbry/issues/1020)
* manager classes to use new `SQLiteStorage` for database interaction. This class uses a single `lbrynet.sqlite` database file.
### Added
* `lbrynet-console`, a tool to run or connect to lbrynet-daemon and launch an interactive python console with the api functions built in.
* `--conf` CLI flag to specify an alternate config file
* `peer_port`, `disable_max_key_fee`, `auto_renew_claim_height_delta`, `blockchain_name`, and `lbryum_servers` to configurable settings
* `wallet_unlock` command (available during startup to unlock an encrypted wallet)
* support for wallet encryption via new commands `wallet_decrypt` and `wallet_encrypt`
* `channel_import`, `channel_export`, and `claim_renew` commands
* `blob_availability` and `stream_availability` commands for debugging download issues
* a new startup stage to indicate if the daemon is waiting for the `wallet_unlock` command.
* `abandon_info` dictionary (containing `claim_name`, `claim_id`, `address`, `amount`, `balance_delta` and `nout`) for claims, supports, and updates returned by `transaction_list`
* `permanent_url` string to `channel_list_mine`, `claim_list`, `claim_show`, `resolve` and `resolve_name` (see lbryio/lbryum#203)
* `is_mine` boolean to `channel_list` results
* `txid`, `nout`, `channel_claim_id`, `channel_claim_name`, `status`, `blobs_completed`, and `blobs_in_stream` fields to file objects returned by `file_list` and `get`
* `txid`, `nout`, `channel_claim_id`, and `channel_claim_name` filters for `file` commands (`file_list`, `file_set_status`, `file_reflect`, and `file_delete`)
* unit tests for `SQLiteStorage` and updated old tests for relevant changes (https://github.com/lbryio/lbry/issues/1088)
### Removed
* `seccure` and `gmpy` dependencies
* support for positional arguments in cli `settings_set`. Now only accepts settings changes in the form `--setting_key=value`
* `auto_re_reflect` setting from the conf file, use the `reflect_uploads` setting instead
* `name` argument for `claim_show` command
* `message` response field in file objects returned by `file_list` and `get`
* `include_tip_info` argument from `transaction_list`, which will now always include tip information.
* old and unused UI related code
* unnecessary `TempBlobManager` class
* old storage classes used by the file manager, wallet, and blob manager
* old `.db` database files from the data directory
## [0.18.0] - 2017-11-08
### Fixed
* Fixed amount of close nodes to add to list in case of extension to neighbouring k-buckets
* Fixed external IP detection via jsonip.com (avoid detecting IPv6)
* Fixed failing ConnectionManager unit test for parallel connections
* Fixed race condition between `publish` and `channel_new`
* Fixed incorrect response on attempting to delete blob twice
* Fixed local node ID reporting in peer list
### Changed
* Bumped `lbryschema` requirement to 0.0.14 [see changelog](https://github.com/lbryio/lbryschema/blob/master/CHANGELOG.md#0014---2017-11-08)
* Bumped `lbryum` requirement to 3.1.11 [see changelog](https://github.com/lbryio/lbryum/blob/master/CHANGELOG.md#3111---2017-11-08)
* Moved BLOB_SIZE from conf.py to MAX_BLOB_SIZE in blob/blob_file.py
### Added
* Added `utxo_list` command to list unspent transaction outputs
* Added redundant API server for currency conversion
### Removed
* Removed some alternate methods of reading from blob files
* Removed `@AuthJSONRPCServer.queued` decorator
## [0.17.1] - 2017-10-25
### Fixed
* Fixed slow startup for nodes with many lbry files
* Fixed setting the external ip on startup
* Fixed session startup not blocking on joining the dht
* Fixed several parsing bugs that prevented replacing dead dht contacts
* Fixed lbryid length validation
* Fixed an old print statement that polluted logs
* Fixed rpc id length for dht requests
### Changed
* Bumped `lbryschema` requirement to 0.0.13 [see changelog](https://github.com/lbryio/lbryschema/blob/master/CHANGELOG.md#0013---2017-10-25)
* Bumped `lbryum` requirement to 3.1.10 [see changelog](https://github.com/lbryio/lbryum/blob/master/CHANGELOG.md#3110---2017-10-25)
* Use the first port available for the peer and dht ports, starting with the provided values (defaults of 3333 and 4444). This allows multiple lbrynet instances in a LAN with UPnP.
* Detect a UPnP redirect that didn't get cleaned up on a previous run and use it
* Bumped jsonschema requirement to 2.6.0
* Refactor some assert statements to accommodate the PYTHONOPTIMIZE flag set for Android.
### Added
* Added `wallet_prefill_addresses` command, which distributes credits to multiple addresses
## [0.17.0] - 2017-10-12
### Fixed
* Fixed handling cancelled blob and availability requests
* Fixed redundant blob requests to a peer
* Fixed https://github.com/lbryio/lbry/issues/923
* Fixed concurrent reflects opening too many files
* Fixed cases when reflecting would fail on error conditions
* Fixed deadlocks from occuring during blob writes
* Fixed and updated`lbrynet.tests.dht`
* Fixed redundant dht id
* Fixed dht `ping` method
* Fixed raising remote exceptions in dht
* Fixed hanging delayedCall in dht node class
* Fixed logging error in dht when calling or receiving methods with no arguments
* Fixed IndexError in routingTable.findCloseNodes which would cause an empty list to be returned
* Fixed bug where last blob in a stream was not saved to blob manager
### Deprecated
* Deprecated `blob_announce_all` JSONRPC command. Use `blob_announce` instead.
### Changed
* Bumped `lbryschema` requirement to 0.0.12 [see changelog](https://github.com/lbryio/lbryschema/blob/master/CHANGELOG.md#0012---2017-10-12)
* Bumped `lbryum` requirement to 3.1.9 [see changelog](https://github.com/lbryio/lbryum/blob/master/CHANGELOG.md#319---2017-10-12)
* Announcing by head blob is turned on by default
* Updated reflector server dns
* Moved tests into the lbrynet package.
### Added
* Added WAL pragma to sqlite3
* Added unit tests for `BlobFile`
* Use `hashlib` for sha384 instead of `pycrypto`
* Use `cryptography` instead of `pycrypto` for blob encryption and decryption
* Use `cryptography` for PKCS7 instead of doing it manually
* Use `BytesIO` buffers instead of temp files when processing blobs
* Refactored and pruned blob related classes into `lbrynet.blobs`
* Changed several `assert`s to raise more useful errors
* Added ability for reflector to store stream information for head blob announce
* Added blob announcement information to API call status with session flag
### Removed
* Removed `TempBlobFile`
* Removed unused `EncryptedFileOpener`
## [0.16.3] - 2017-09-28
### Fixed
* Fixed blob download history
### Changed
* Improved download analytics
* Improved download errors by distinguishing a data timeout from a sd timeout
## [0.16.2] - 2017-09-26
### Fixed
* Fixed https://github.com/lbryio/lbry/issues/771 (handle when a certificate is missing for a signed claim in `claim_list_mine`)
## [0.16.1] - 2017-09-20
### Fixed
* Fixed `transaction_list` doc string
* Fixed ([in lbryum](https://github.com/lbryio/lbryum/pull/156)) batched queries responsible for making transaction and tip histories slow
* Fixed daemon refusing to start if DNS cannot resolve lbry.io domain.
### Changed
* Bumped `lbryum` requirement to 3.1.8 [see changelog](https://github.com/lbryio/lbryum/blob/master/CHANGELOG.md#318---2017-09-20)
## [0.16.0] - 2017-09-18
### Fixed
* Fixed uncaught error when shutting down after a failed daemon startup
* Fixed spelling error in documentation.
### Changed
* Bumped `lbryschema` requirement to 0.0.11 [see changelog](https://github.com/lbryio/lbryschema/blob/master/CHANGELOG.md#0011---2017-09-18)
* Bumped `lbryum` requirement to 3.1.7 [see changelog](https://github.com/lbryio/lbryum/blob/master/CHANGELOG.md#317---2017-09-18)
* Updated exchange rate tests for the lbry.io api
### Added
* Added option to announce head blob only if seeding
* Added option to download by seeking head blob first
* By default, option to download seeking head blob first is turned on
* Added `include_tip_info` param to `transaction_list` API call
## [0.15.2] - 2017-09-07
### Changed
* Use lbry.io exchange rate API instead of google finance
## [0.15.1] - 2017-08-22
### Changed
* Bumped `lbryschema` requirement to 0.0.10 [see changelog](https://github.com/lbryio/lbryschema/blob/master/CHANGELOG.md#0010---2017-08-22)
* Bumped `lbryum` requirement to 3.1.6 [see changelog](https://github.com/lbryio/lbryum/blob/master/CHANGELOG.md#316---2017-08-22)
* Persist DHT node id
### Added
* Android platform detection in lbrynet/conf.py
* androidhelpers module for determining base file paths
## [0.15.0] - 2017-08-15
### Fixed
* Fixed reflector server blocking the `received_blob` reply on the server announcing the blob to the dht
* Fixed handling of SIGINT, SIGTERM.
* Fixed shutdown sequence
* Fix error when resolving an integer
### Deprecated
* The API will no longer be served at the /lbryapi path. It will now be at the root.
* Deprecated `send_amount_to_address` in favor of `wallet_send`
### Changed
* Renamed `reflect` command to `file_reflect`
* Allow IP addresses to be configured as reflector servers, not just host names.
* Return list of blobs that were reflected from `file_reflect`
### Added
* Added `wallet_send`, a command to send credits and tips
* Added `reflector` keyword parameter to `file_reflect` command
* Added configuration options for auto re-reflect
* Added option to abandon by txid/nout
## [0.14.3] - 2017-08-04
### Fixed
* Fixed incorrect formatting of "amount" fields
### Added
* Added validation of currencies.
* Added blob_announce API command
### Removed
* Removed TempBlobManager
* Removed old /view and /upload API paths
*
## [0.14.2] - 2017-07-24
### Fixed
* Fix for https://github.com/lbryio/lbry/issues/750
* Fixed inconsistencies in claim_show output
* Fixed daemon process hanging when started without an internet connection
* Fixed https://github.com/lbryio/lbry/issues/774
* Fix XDG compliance on Linux
* Fixed https://github.com/lbryio/lbry/issues/760
* Fixed default directories bug
### Changed
* claim_show API command no longer takes name as argument
* Linux default downloads folder changed from `~/Downloads` to `XDG_DOWNLOAD_DIR`
* Linux folders moved from the home directory to `~/.local/share/lbry`
* Windows folders moved from `%AppData%/Roaming` to `%AppData%/Local/lbry`
* Changed `claim_list_by_channel` to return the `claims_in_channel` count instead of the `claims_in_channel_pages` count
### Added
* Add link to instructions on how to change the default peer port
* Add `peer_port` to settings configurable using `settings_set`
* Added an option to disable max key fee check.
## [0.14.1] - 2017-07-07
### Fixed
* Fixed timeout behaviour when calling API command get
* Fixed https://github.com/lbryio/lbry/issues/765
### Removed
* Removed stream_info_cache.json from daemon.py
## [0.14.0] - 2017-07-05
### Added
* Missing docstring for `blob_list`
* Added convenient import for setting up a daemon client, `from lbrynet.daemon import get_client`
* Added unit tests for CryptBlob.py
### Changed
* Change `max_key_fee` setting to be a dictionary with values for `currency` and `amount`
* Renamed `lbrynet.lbryfile` to `lbrynet.lbry_file`
* Renamed `lbrynet.lbryfilemanager` to `lbrynet.file_manager`
* Renamed `lbrynet.lbrynet_daemon` to `lbrynet.daemon`
* Initialize lbrynet settings when configuring an api client if they are not set yet
* Updated lbryum imports
* Improve error message when resolving a claim fails using the "get" command
### Removed
* Removed unused settings from conf.py and `settings_set`
* Removed download_directory argument from API command get
### Fixed
* Fixed some log messages throwing exceptions
* Fix shutdown of the blob tracker by Session
* Fixed claim_new_support docstrings
* Fixed BlobManager causing functional tests to fail, removed its unneeded manage() loop
* Increased max_key_fee
* Fixed unit tests on appveyor Windows build
* Fixed [#692](https://github.com/lbryio/lbry/issues/692)
## [0.13.1] - 2017-06-15
### Added
* Add `claim_send_to_address`
* Add `change_address` argument to `publish`
* Add `unique_contacts` count to `status` response
### Changed
* Support resolution of multiple uris with `resolve`, all results are keyed by uri
* Add `error` responses for failed resolves
* Add `claim_list_by_channel`, supports multiple channel resolution
* Rename delete_target_file argument of delete API command to delete_from_download_dir
* Rename delete_all CLI flag -a to --delete_all
### Removed
* Remove `claims_in_channel` from `resolve` response
### Fixed
* Race condition from improper initialization and shutdown of the blob manager database
* Various fixes for GetStream class used in API command get
* Fixed flag options in file_delete API command
## [0.11.0] - 2017-06-09
### Added
* Added claim_address option to publish API command
* Added message for InsufficientFundsError exception
* Add CLI docs
### Changed
* Do not catch base exception in API command resolve
* Remove deprecated `lbrynet.metadata` and update what used it to instead use `lbryschema`
* Get version information locally instead of via api for cli
### Deprecated
* Old fee metadata format in publish API command is deprecated, throw relevant exception
* Removed deprecated `get_best_blockhash`
* Removed deprecated `is_running`
* Removed deprecated `daemon_status`
* Removed deprecated `is_first_run`
* Removed deprecated `get_lbry_session_info`
* Removed deprecated `get_time_behind_blockchain`
* Removed deprecated `get_settings`
* Removed deprecated `set_settings`
* Removed deprecated `get_balance`
* Removed deprecated `stop`
* Removed deprecated `get_claim_info`
* Removed deprecated `stop_lbry_file`
* Removed deprecated `start_lbry_file`
* Removed deprecated `get_est_cost`
* Removed deprecated `abandon_claim`
* Removed deprecated `support_claim`
* Removed deprecated `get_my_claim`
* Removed deprecated `get_name_claims`
* Removed deprecated `get_claims_for_tx`
* Removed deprecated `get_transaction_history`
* Removed deprecated `get_transaction`
* Removed deprecated `address_is_mine`
* Removed deprecated `get_public_key_from_wallet`
* Removed deprecated `get_new_address`
* Removed deprecated `get_block`
* Removed deprecated `descriptor_get`
* Removed deprecated `download_descriptor`
* Removed deprecated `get_peers_for_hash`
* Removed deprecated `announce_all_blobs_to_dht`
* Removed deprecated `get_blob_hashes`
* Removed deprecated `reflect_all_blobs`
* Removed deprecated `get_start_notice`
### Fixed
* Download analytics error
## [0.10.3] - 2017-05-23
### Added
* Add decorator to support queueing api calls
* Added force option to API command resolve
### Changed
* Cache claims in wallet storage for use looking claims up by id or outpoint
* Try to use cached claim info for `file_list`
* Convert wallet storage to inlinecallbacks
* Improve internal name_metadata sqlite table
### Fixed
* Fix race condition in publish that resulted in claims being rejected when making many publishes concurrently
## [0.10.1] - 2017-05-03
### Fixed
* Fix multiple reactor.stop() calls
* Properly shut down lbryum wallet from lbrynet
* Set LBRYumWallet.config upon initialization, fixes attribute error
## [0.10.0] - 2017-04-25
### Added
* Add `lbryschema_version` to response from `version`
* Added call to `get_address_balance` when `address` conditional returns true
* Added `address` conditional to `jsonrpc_wallet_balance`
* Added `get_address_balance` method to the `Wallet` class
### Changed
* Added optional `address` and `include_unconfirmed` params to `jsonrpc_wallet_balance` method
* Wait for subscriptions before announcing wallet has finished starting
### Fixed
* fix stream_cost_estimate throwing exception on non decodeable claims
* fixed signing of Windows binaries
* fixed a few pylint warnings
## [0.10.0rc2] - 2017-04-17
### Changed
* Return full `lbry_id` and `installation_id` from `status`
## [0.10.0rc1] - 2017-04-13
### Fixed
* Fix uncaught exception in `stream_cost_estimate`
## [0.9.2rc22] - 2017-04-12
### Added
* Add `claim_id` parameter to `claim_show`
* Add `hex` field to claim responses for the raw claim value
* Add an `error` field to to file responses if an error occurs
### Changed
* Use `uri` instead of `name` in `get_availability`
* Add `channel_name` to claim and file responses where applicable
* Return None (instead of errors) if a uri cannot be resolved
* Use `uri` instead of `name` for `stream_cost_estimate`, update cost estimate for lbryschema
### Fixed
* `file_list` for files with bad signatures
* return None from resolve commands when nothing is found
* return lbry files with claims that are abandoned
* unhelpful error messages in `publish` and `channel_new`
## [0.9.2rc9] - 2017-04-08
### Added
* Use `claim_id` instead of outpoint for `claim_abandon`
* Add `channel_name` parameter to `publish`
* Add `delete_all` parameter to `file_delete` to allow deleting multiple files
* Add `channel_list_mine`
* Add `channel_new`
* Add `resolve` to resolve lbry uris
### Changed
* Use `uri` instead of `name` for `get`, remove explicit `claim_id` parameter
* Increase default download timeout
* Use lbry.io api for exchange rate data
## [0.9.2rc4] - 2017-04-06
### Changed
* Use lbryschema library for metadata
### Fixed
* Removed update_metadata function that could cause update problems
* Fix DHT contact bug
## [0.9.2rc3] - 2017-03-29
### Added
* Create wallet_unused_address API command
* Add `claim_id` parameter to `get`, used to specify non-default claim for `name`
### Changed
* wallet_new_address API command always returns new address
* Improved ConnectionManager speed
* Remove unused `stream_info` parameter in `get`
## [0.9.2rc2] - 2017-03-25
### Added
* Add `wallet_list` command
* Add checks for missing/extraneous params when calling jsonrpc commands
* Added colors to cli error messages
### Changed
* Removed check_pending logic from Daemon
* Switched to txrequests so requests can use twisted event loop
* Renamed API command file_seed to file_set_status
* Dont add expected payment to wallet when payment rate is 0
### Fixed
* Fix restart procedure in DaemonControl
* Create download directory if it doesn't exist
* Fixed descriptor_get
* Fixed API command descriptor_get
* Fixed API command transaction_show
* Fixed error handling for jsonrpc commands
* Handle failure to decode claim cache file
## [0.9.1] - 2017-03-17
### Added
* publish API command can take metadata fields as arguments
* Added `reflect_uploads` config to disable reflecting on upload
* Added `--version` flag
### Fixed
* Fix wallet_public_key API command
* Fixed jsonrpc_reflect()
* Fixed api help return
### Changed
* Removed `simplejson` dependency in favor of bulitin `json`
## [0.9.0rc17] - 2017-03-10
### Fixed
* Added string comparison to ClaimOutpoint (needed to look things up by outpoint)
* Remove unused API commands from daemon
* Fix file filter `outpoint`
* Made dictionary key names in API commmand outputs to be more consistent
### Added
* Add file filters: `claim_id`, `outpoint`, and `rowid`
* Make loggly logs less verbose
### Changed
* Change file filter `uri` to `name` and return field `lbry_uri` to `name`
* Refactor file_list, add `full_status` argument to populate resource intensive fields
* Remove deprecated file commands: `get_lbry_files`, `get_lbry_file`, and `file_get`
* Remove deprecated `delete_lbry_file` command
* Return standard file json from `get`
## [0.9.0rc12] - 2017-03-06
### Fixed
* Fixed ExchangeRateManager freezing the app
* Fixed download not timing out properly when downloading sd blob
* Fixed ExchangeRateManager freezing the app
* Fixed download not timing out properly when downloading sd blob
* Fixed get not reassembling an already downloaded file that was deleted from download directory
## [0.9.0rc11] - 2017-02-27
### Fixed
* Added timeout to ClientProtocol
* Add check for when local height of wallet is less than zero
## [0.9.0rc9] - 2017-02-22
### Changed
* Add blockchain status to jsonrpc_status
## [0.8.7] - 2017-02-21
## [0.8.6] - 2017-02-19
### Changed
* Add `file_get` by stream hash
* Add utils.call_later to replace reactor.callLater
### Fixed
* Fix unhandled error in `get`
* Fix sd blob timeout handling in `get_availability`, return 0.0
## [0.8.5] - 2017-02-18
### Fixed
* Fix result expected by ui from file_get for missing files
## [0.8.4] - 2017-02-17
### Changed
* Remove unused upload_allowed option
* Remove code related to packaging as that step is now done in the electron client
* Remove lbryum version check; use lbry-electron as version source
* Include download url in version check
### Fixed
* add misssing traceback to logging
## [0.8.3] - 2017-02-15
### Fixed
* Get lbry files with pending claims
* Add better logging to help track down [#478](https://github.com/lbryio/lbry/issues/478)
* Catch UnknownNameErrors when resolving a name. [#479](https://github.com/lbryio/lbry/issues/479)
* Change EWOULDBLOCK error in DHT to warning. #481
* mark peers as down if it fails download protocol
* Made hash reannounce time to be adjustable to fix [#432](https://github.com/lbryio/lbry/issues/432)
* Fix recursion depth error upon failed blob
* Call stopProducing in reflector client file_sender when uploading is done
* Ensure streams in stream_info_manager are saved in lbry_file_manager
* Fixed file_delete not deleting data from stream_info_manager [#470](https://github.com/lbryio/lbry/issues/470)
* Fixed upload of bug reports to Slack ([#472](https://github.com/lbryio/lbry/issues/472))
* Fixed claim updates [#473](https://github.com/lbryio/lbry/issues/473)
* Handle ConnectionLost error in reflector client
* Fix updating a claim where the stream doesn't change
* Fix claim_abandon
### Changed
* Add blob_get, descriptor_get, and blob_delete
* Add filter keyword args to blob_list
* Refactor get_availability
* Add optional peer search timeout, add peer_search_timeout setting
* make connection manager unit testeable
* Convert EncryptedFileDownloader to inlineCallbacks
* Convert EncryptedFileManager to use inlineCallbacks
* Convert Daemon._delete_lbry_file to inlineCallbacks
* Add uri to stream reflector to de-obfuscate reflector logs
* Simplify lbrynet.lbrynet_daemon.Publisher
* Reflect streams in file manager looping call rather than in each file
* Convert GetStream to inclineCallbacks
* Change callback condition in GetStream to the first data blob completing
* Add local and remote heights to blockchain status
## [0.8.1] - 2017-02-01
### Changed
* reflect all the blobs in a stream
* change command line flags so that the more common usage is the default
* change daemon function signatures to include names arguments
### Fixed
* disable verbose twisted logs
* improved wallet balance calculations
* fix block too deep error
## [0.8.0] - 2017-01-24
### Changed
* renamed api endpoints
* improved command line user experience
* integrate twisted logging with python logging
* Updated READMEs
### Fixed
* Fixed bug where ConnectionManager wasn't being stopped
* Fixed: #343
* Stop hanging if github is down
* paths for debian package have been updated to be correct
* improved output of the publish command
+3
View File
@@ -0,0 +1,3 @@
## Contributing to LBRY
https://lbry.io/faq/contributing
+6
View File
@@ -0,0 +1,6 @@
# Add a CHANGELOG entry for app changes
has_app_changes = !git.modified_files.grep(/lbrynet/).empty?
if !git.modified_files.include?("CHANGELOG.md") && has_app_changes
fail("Please include a CHANGELOG entry.")
message "See http://keepachangelog.com/en/0.3.0/ for details on good changelog guidelines"
end
-34
View File
@@ -1,34 +0,0 @@
Prerequisites
-------------
To use the LBRYWallet, which enables spending and accepting LBRYcrds in exchange for data, the
LBRYcrd application (insert link to LBRYcrd website here) must be installed and running. If
this is not desired, the testing client can be used to simulate trading points, which is
built into LBRYnet.
on Ubuntu:
sudo apt-get install libgmp3-dev build-essential python-dev python-pip
Getting the source
------------------
Don't you already have it?
Setting up the environment
--------------------------
It's recommended that you use a virtualenv
sudo apt-get install python-virtualenv
cd <source base directory>
virtualenv .
source bin/activate
(to deactivate the virtualenv, enter 'deactivate')
python setup.py install
this will install all of the libraries and a few applications
For running the file sharing application, see RUNNING
+106
View File
@@ -0,0 +1,106 @@
# Installing LBRY
The recommended way to install LBRY is to use an installer. We provide installers for all major operating systems. See the [README](README.md).
These instructions are for installing from source code, which is recommended if you are interested in doing development work or LBRY is not available on your operating system (godspeed, TempleOS users).
## Prerequisites
Before starting, you'll need to install some additional libraries depending on your operating system.
### Python
LBRY requires Python 2.7. Python 3 is not supported.
### OS X Prerequisites
Install [xcode command line tools](https://developer.xamarin.com/guides/testcloud/calabash/configuring/osx/install-xcode-command-line-tools/) and [homebrew](http://brew.sh/).
Remaining dependencies can then be installed by running:
```
brew install mpfr libmpc protobuf
sudo easy_install pip
sudo pip install virtualenv
```
### Linux Prerequisites
On Ubuntu (we recommend 16.04), install the following:
```
sudo apt-get install build-essential python2.7 python2.7-dev python-pip git python-virtualenv libssl-dev libffi-dev python-protobuf
```
On Raspbian, you will also need to install `python-pyparsing`.
If you're running another Linux flavor, install the equivalent of the above packages for your system.
### Windows Prerequisites
Install [mingw32](http://www.mingw.org/) base and c++ compiler.
Add C:\MinGW\bin to the windows PATH.
Enable distutils to compile with mingw32 by creating a distutils.cfg file in *PYTHONPATH\Lib\distutils* containing:
```
[build]
compiler = mingw32
```
If using virtualenv, which is recommended, copy the *PYTHONPATH\Lib\distutils* directory to the virtualenv.
It's recommended to use [Unofficial Windows Binaries for Python Extension Packages](http://www.lfd.uci.edu/~gohlke/pythonlibs/) for as many of the required packages as possible.
Currently, available binaries include:
- Cython
- Twisted
- Zope.interface
- pywin32
- requests
Install the above binaries with `pip install *.whl`
Install pywin32 system files by run `python.exe Scripts\pywin32_postinstall.py -install` from an elevated command prompt.
Finally, you'll need [miniupnpc](https://pypi.python.org/pypi/miniupnpc/1.9). Download the source and compile with MinGW by running `mingw32make.bat`. Then install the module by running `python setupmingw32.py install`.
## Installation
To install:
```
git clone https://github.com/lbryio/lbry.git
cd lbry
virtualenv lbry-venv
source lbry-venv/bin/activate
python --version # Python 3 is not supported. Make sure you're on Python 2.7
pip install -U -r requirements.txt
pip install --editable .
```
To start LBRY, run `lbrynet-daemon` in a terminal.
To verify your install, `which lbrynet-daemon` should return a path inside of the `lbry-venv` folder created by the `virtualenv` command.
## Making a Change
If you are not already inside the virtual environment, run:
```
source lbry-venv/bin/activate
```
Then run:
```
pip install --editable .
```
This will install `lbrynet-daemon` in such a way that the changes you make to the code will be used as soon as you restart the daemon.
Happy hacking!
+12 -19
View File
@@ -1,22 +1,15 @@
Copyright (c) 2015, LBRY, Inc.
All rights reserved.
The MIT License (MIT)
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
Copyright (c) 2015-2018 LBRY Inc
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the
following conditions:
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-57
View File
@@ -1,57 +0,0 @@
LBRYnet
=======
LBRYnet is a fully decentralized network for distributing data. It consists of peers uploading
and downloading data from other peers, possibly in exchange for payments, and a distributed hash
table, used by peers to discover other peers.
Overview
--------
On LBRYnet, data is broken into chunks, and each chunk is specified by its sha384 hash sum. This
guarantees that peers can verify the correctness of each chunk without having to know anything
about its contents, and can confidently re-transmit the chunk to other peers. Peers wishing to
transmit chunks to other peers announce to the distributed hash table that they are associated
with the sha384 hash sum in question. When a peer wants to download that chunk from the network,
it asks the distributed hash table which peers are associated with that sha384 hash sum. The
distributed hash table can also be used more generally. It simply stores IP addresses and
ports which are associated with 384-bit numbers, and can be used by any type of application to
help peers find each other. For example, an application for which clients don't know all of the
necessary chunks may use some identifier, chosen by the application, to find clients which do
know all of the necessary chunks.
Running
-------
LBRYnet comes with an file sharing application, called 'lbrynet-console', which breaks
files into chunks, encrypts them with a symmetric key, computes their sha384 hash sum, generates
a special file called a 'stream descriptor' containing the hash sums and some other file metadata,
and makes the chunks available for download by other peers. A peer wishing to download the file
must first obtain the 'stream descriptor' and then may open it with his 'lbrynet-console' client,
download all of the chunks by locating peers with the chunks via the DHT, and then combine the
chunks into the original file, according to the metadata included in the 'stream descriptor'.
To install and use this client, see INSTALL and RUNNING
Installation
------------
See INSTALL
Developers
----------
Documentation: doc.lbry.io
Source code: trac.lbry.io/browser
To contribute to the development of LBRYnet or lbrynet-console, contact jimmy@lbry.io
Support
-------
Send all support requests to jimmy@lbry.io
License
-------
See LICENSE
+52
View File
@@ -0,0 +1,52 @@
[![Build Status](https://travis-ci.org/lbryio/lbry.svg?branch=master)](https://travis-ci.org/lbryio/lbry)
[![Coverage Status](https://coveralls.io/repos/github/lbryio/lbry/badge.svg)](https://coveralls.io/github/lbryio/lbry)
# LBRY
LBRY is an open-source protocol providing distribution, discovery, and purchase of digital content (data) via a decentralized network.
This repo is a reference implementation of the [LBRY API](https://lbry.io/api).
It provides a daemon that can interact with the network via a json-rpc interface over HTTP.
## Installing
**Note**: This project no longer bundles a graphic interface (browser). If you want to use LBRY via a GUI, [use the LBRY App](https://github.com/lbryio/lbry-app).
Our [releases page](https://github.com/lbryio/lbry/releases) contains pre-built binaries of the latest release, pre-releases, and past releases, for macOS, Debian-based Linux, and Windows.
Installing from source is also relatively painless, full instructions are in [INSTALL.md](INSTALL.md)
## Running
Run `lbrynet-daemon` to launch the daemon.
## Using
By default, `lbrynet-daemon` will provide a JSON-RPC server at `http://localhost:5279`. It is easy to interact with via cURL or sane programming languages.
Our [quickstart guide](http://lbry.io/quickstart) provides a simple walkthrough and examples for learning.
The full API is documented [here](https://lbryio.github.io/lbry/cli).
## What is LBRY?
LBRY is a protocol that provides a fully decentralized network for the discovery, distribution, and payment of data.
It utilizes the [LBRY blockchain](https://github.com/lbryio/lbrycrd) as a global namespace and database of digital content. Blockchain entries contain searchable content metadata, identities, and rights and access rules.
LBRY also provides a data network consists of peers uploading and downloading data from other peers, possibly in exchange for payments, and a distributed hash table, used by peers to discover other peers.
## Contributions
To contribute, [join us on Discord](https://chat.lbry.io/) or contact jeremy@lbry.io. Pull requests are also welcome.
## Support
Please open an issue and describe your situation in detail. We will respond as soon as we can.
For private issues, contact jeremy@lbry.io.
## License
See [LICENSE](LICENSE)
-52
View File
@@ -1,52 +0,0 @@
To install LBRYnet and lbrynet-console, see INSTALL
lbrynet-console is a console application which makes use of the LBRYnet to share files.
In particular, lbrynet-console splits files into encrypted chunks of data compatible with
LBRYnet, groups all metadata into a 'stream descriptor file' which can be sent directly to
others wishing to obtain the file, or can be itself turned into a chunk compatible with
LBRYnet and downloaded via LBRYnet by anyone knowing its sha384 hashsum. lbrynet-console
also acts as a client whichreads a stream descriptor file, downloads the chunks of data
specified by the hash sums found in the stream descriptor file, decrypts them according to
metadata found in the stream, and reconstructs the original file. lbrynet-console features
a server so that clients can connect to it and download the chunks and other data gotten
from files created locally and files that have been downloaded from LBRYnet.
lbrynet-console also has a plugin system. There are two plugins: a live stream proof of
concept which is currently far behind the development of the rest of the application and
therefore will not run, and a plugin which attempts to determine which chunks on the
network should be downloaded in order for the application to turn a profit. It will run,
but its usefulness is extremely limited.
Passing '--help' to lbrynet-console will cause it to print out a quick help message
describing other command line options to the application.
Once the application has been started, the user is presented with a numbered list of
actions which looks something like this:
...
[2] Toggle whether an LBRY File is running
[3] Create an LBRY File from file
[4] Publish a stream descriptor file to the DHT for an LBRY File
...
To perform an action, type the desired number and then hit enter. For example, if you wish
to create an LBRY file from a file as described in the beginning of this document, type 3 and
hit enter.
If the application needs more input in order to for the action to be taken, the application
will continue to print prompts for input until it has received what it needs.
For example, when creating an LBRY file from a file, the application needs to know which file
it's supposed to use to create the LBRY file, so the user will be prompted for it:
File name:
The user should input the desired file name and hit enter, at which point the application
will go about splitting the file and making it available on the network.
Some actions will produce sub-menus of actions, which work the same way.
A more detailed user guide is available at doc.lbry.io
Any issues may be reported to jimmy@lbry.io
+33
View File
@@ -0,0 +1,33 @@
$env:Path += ";C:\MinGW\bin\"
$env:Path += ";C:\Program Files (x86)\Windows Kits\10\bin\x86\"
gcc --version
mingw32-make --version
# build/install miniupnpc manually
tar zxf miniupnpc-1.9.tar.gz
cd miniupnpc-1.9
mingw32-make -f Makefile.mingw
python setupmingw32.py build --compiler=mingw32
python setupmingw32.py install
cd ..\
Remove-Item -Recurse -Force miniupnpc-1.9
# copy requirements from lbry, but remove miniupnpc (installed manually)
Get-Content ..\requirements.txt | Select-String -Pattern 'miniupnpc' -NotMatch | Out-File requirements_base.txt
python set_build.py
pip install -r requirements.txt
pip install ..\.
pyinstaller -y daemon.onefile.spec
pyinstaller -y cli.onefile.spec
pyinstaller -y console.onefile.spec
nuget install secure-file -ExcludeVersion
secure-file\tools\secure-file -decrypt .\lbry2.pfx.enc -secret "$env:pfx_key"
signtool.exe sign /f .\lbry2.pfx /p "$env:key_pass" /tr http://tsa.starfieldtech.com /td SHA256 /fd SHA256 dist\*.exe
python zip_daemon.py
python upload_assets.py
Executable
+59
View File
@@ -0,0 +1,59 @@
#!/bin/bash
set -euo pipefail
set -x
ROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )/.." && pwd )"
cd "$ROOT"
BUILD_DIR="$ROOT/build"
FULL_BUILD="${FULL_BUILD:-false}"
if [ -n "${TEAMCITY_VERSION:-}" -o -n "${APPVEYOR:-}" ]; then
FULL_BUILD="true"
fi
[ -d "$BUILD_DIR/bulid" ] && rm -rf "$BUILD_DIR/build"
[ -d "$BUILD_DIR/dist" ] && rm -rf "$BUILD_DIR/dist"
if [ "$FULL_BUILD" == "true" ]; then
# install dependencies
$BUILD_DIR/prebuild.sh
VENV="$BUILD_DIR/venv"
if [ -d "$VENV" ]; then
rm -rf "$VENV"
fi
virtualenv "$VENV"
set +u
source "$VENV/bin/activate"
set -u
# must set build before installing lbrynet. otherwise it has no effect
python "$BUILD_DIR/set_build.py"
fi
cp "$ROOT/requirements.txt" "$BUILD_DIR/requirements_base.txt"
(
cd "$BUILD_DIR"
pip install -r requirements.txt
)
(
cd "$BUILD_DIR"
pyinstaller -y daemon.onefile.spec
pyinstaller -y cli.onefile.spec
pyinstaller -y console.onefile.spec
)
python "$BUILD_DIR/zip_daemon.py"
if [ "$FULL_BUILD" == "true" ]; then
# electron-build has a publish feature, but I had a hard time getting
# it to reliably work and it also seemed difficult to configure. Not proud of
# this, but it seemed better to write my own.
python "$BUILD_DIR/upload_assets.py"
deactivate
fi
echo 'Build complete.'
+42
View File
@@ -0,0 +1,42 @@
# -*- mode: python -*-
import platform
import os
dir = 'build';
cwd = os.getcwd()
if os.path.basename(cwd) != dir:
raise Exception('pyinstaller build needs to be run from the ' + dir + ' directory')
repo_base = os.path.abspath(os.path.join(cwd, '..'))
execfile(os.path.join(cwd, "entrypoint.py")) # ghetto import
system = platform.system()
if system == 'Darwin':
icns = os.path.join(repo_base, 'build', 'icon.icns')
elif system == 'Linux':
icns = os.path.join(repo_base, 'build', 'icons', '256x256.png')
elif system == 'Windows':
icns = os.path.join(repo_base, 'build', 'icons', 'lbry256.ico')
else:
print 'Warning: System {} has no icons'.format(system)
icns = None
a = Entrypoint('lbrynet', 'console_scripts', 'lbrynet-cli', pathex=[cwd])
pyz = PYZ(a.pure, a.zipped_data)
exe = EXE(
pyz,
a.scripts,
a.binaries,
a.zipfiles,
a.datas,
name='lbrynet-cli',
debug=False,
strip=False,
upx=True,
console=True,
icon=icns
)
+50
View File
@@ -0,0 +1,50 @@
# -*- mode: python -*-
import platform
import os
import lbryum
dir = 'build';
cwd = os.getcwd()
if os.path.basename(cwd) != dir:
raise Exception('pyinstaller build needs to be run from the ' + dir + ' directory')
repo_base = os.path.abspath(os.path.join(cwd, '..'))
execfile(os.path.join(cwd, "entrypoint.py")) # ghetto import
system = platform.system()
if system == 'Darwin':
icns = os.path.join(repo_base, 'build', 'icon.icns')
elif system == 'Linux':
icns = os.path.join(repo_base, 'build', 'icons', '256x256.png')
elif system == 'Windows':
icns = os.path.join(repo_base, 'build', 'icons', 'lbry256.ico')
else:
print 'Warning: System {} has no icons'.format(system)
icns = None
datas = [
(os.path.join(os.path.dirname(lbryum.__file__), 'wordlist', language + '.txt'), 'lbryum/wordlist')
for language in ('chinese_simplified', 'japanese', 'spanish','english', 'portuguese')
]
a = Entrypoint('lbrynet', 'console_scripts', 'lbrynet-console', pathex=[cwd], datas=datas)
pyz = PYZ(a.pure, a.zipped_data)
exe = EXE(
pyz,
a.scripts,
a.binaries,
a.zipfiles,
a.datas,
name='lbrynet-console',
debug=False,
strip=False,
upx=True,
console=True,
icon=icns
)
+50
View File
@@ -0,0 +1,50 @@
# -*- mode: python -*-
import platform
import os
import lbryum
dir = 'build';
cwd = os.getcwd()
if os.path.basename(cwd) != dir:
raise Exception('pyinstaller build needs to be run from the ' + dir + ' directory')
repo_base = os.path.abspath(os.path.join(cwd, '..'))
execfile(os.path.join(cwd, "entrypoint.py")) # ghetto import
system = platform.system()
if system == 'Darwin':
icns = os.path.join(repo_base, 'build', 'icon.icns')
elif system == 'Linux':
icns = os.path.join(repo_base, 'build', 'icons', '256x256.png')
elif system == 'Windows':
icns = os.path.join(repo_base, 'build', 'icons', 'lbry256.ico')
else:
print 'Warning: System {} has no icons'.format(system)
icns = None
datas = [
(os.path.join(os.path.dirname(lbryum.__file__), 'wordlist', language + '.txt'), 'lbryum/wordlist')
for language in ('chinese_simplified', 'japanese', 'spanish','english', 'portuguese')
]
a = Entrypoint('lbrynet', 'console_scripts', 'lbrynet-daemon', pathex=[cwd], datas=datas)
pyz = PYZ(a.pure, a.zipped_data)
exe = EXE(
pyz,
a.scripts,
a.binaries,
a.zipfiles,
a.datas,
name='lbrynet-daemon',
debug=False,
strip=False,
upx=True,
console=True,
icon=icns
)
+47
View File
@@ -0,0 +1,47 @@
# https://github.com/pyinstaller/pyinstaller/wiki/Recipe-Setuptools-Entry-Point
def Entrypoint(dist, group, name,
scripts=None, pathex=None, binaries=None, datas=None,
hiddenimports=None, hookspath=None, excludes=None, runtime_hooks=None,
cipher=None, win_no_prefer_redirects=False, win_private_assemblies=False):
import pkg_resources
# get toplevel packages of distribution from metadata
def get_toplevel(dist):
distribution = pkg_resources.get_distribution(dist)
if distribution.has_metadata('top_level.txt'):
return list(distribution.get_metadata('top_level.txt').split())
else:
return []
hiddenimports = hiddenimports or []
packages = []
for distribution in hiddenimports:
packages += get_toplevel(distribution)
scripts = scripts or []
pathex = pathex or []
# get the entry point
ep = pkg_resources.get_entry_info(dist, group, name)
# insert path of the egg at the verify front of the search path
pathex = [ep.dist.location] + pathex
# script name must not be a valid module name to avoid name clashes on import
script_path = os.path.join(workpath, name + '-script.py')
print "creating script for entry point", dist, group, name
with open(script_path, 'w') as fh:
fh.write("import {0}\n".format(ep.module_name))
fh.write("{0}.{1}()\n".format(ep.module_name, '.'.join(ep.attrs)))
for package in packages:
fh.write("import {0}\n".format(package))
return Analysis([script_path] + scripts,
pathex=pathex,
binaries=binaries,
datas=datas,
hiddenimports=hiddenimports,
hookspath=hookspath,
excludes=excludes,
runtime_hooks=runtime_hooks,
cipher=cipher,
win_no_prefer_redirects=win_no_prefer_redirects,
win_private_assemblies=win_private_assemblies
)
Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 361 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.
Binary file not shown.
+81
View File
@@ -0,0 +1,81 @@
#!/bin/bash
set -euo pipefail
set -x
LINUX=false
OSX=false
if [ "$(uname)" == "Darwin" ]; then
OSX=true
elif [ "$(expr substr $(uname -s) 1 5)" == "Linux" ]; then
LINUX=true
else
echo "Platform detection failed"
exit 1
fi
SUDO=''
if $LINUX && (( $EUID != 0 )); then
SUDO='sudo'
fi
cmd_exists() {
command -v "$1" >/dev/null 2>&1
return $?
}
set +eu
GITUSERNAME=$(git config --global --get user.name)
if [ -z "$GITUSERNAME" ]; then
git config --global user.name "$(whoami)"
fi
GITEMAIL=$(git config --global --get user.email)
if [ -z "$GITEMAIL" ]; then
git config --global user.email "$(whoami)@lbry.io"
fi
set -eu
if $LINUX; then
INSTALL="$SUDO apt-get install --no-install-recommends -y"
$INSTALL build-essential libssl-dev libffi-dev python2.7-dev wget
elif $OSX && ! cmd_exists brew ; then
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
fi
if ! cmd_exists python; then
if $LINUX; then
$INSTALL python2.7
elif $OSX; then
brew install python
fi
fi
PYTHON_VERSION=$(python -c 'import sys; print(".".join(map(str, sys.version_info[:2])))')
if [ "$PYTHON_VERSION" != "2.7" ]; then
echo "Python 2.7 required"
exit 1
fi
if ! cmd_exists pip; then
if $LINUX; then
$INSTALL python-pip
$SUDO pip install --upgrade pip
else
echo "Pip required"
exit 1
fi
fi
if $LINUX && [ "$(pip list --format=columns | grep setuptools | wc -l)" -ge 1 ]; then
#$INSTALL python-setuptools
$SUDO pip install setuptools
fi
if ! cmd_exists virtualenv; then
$SUDO pip install virtualenv
fi
+11
View File
@@ -0,0 +1,11 @@
# install daemon requirements (created by build script. see build.sh, build.ps1)
-r requirements_base.txt
# install daemon itself. make sure you run `pip install` from this dir. this is how you do relative file paths with pip
file:../.
# install other build requirements
PyInstaller==3.2.1
requests[security]==2.13.0
uritemplate==3.0.0
boto3==1.4.4
+29
View File
@@ -0,0 +1,29 @@
"""Set the build version to be 'dev', 'qa', 'rc', 'release'"""
import os.path
import re
import subprocess
import sys
def main():
build = get_build()
root_dir = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
with open(os.path.join(root_dir, 'lbrynet', 'build_type.py'), 'w') as f:
f.write("BUILD = '{}'\n".format(build))
def get_build():
try:
tag = subprocess.check_output(['git', 'describe', '--exact-match']).strip()
if re.match('v\d+\.\d+\.\d+rc\d+', tag):
return 'rc'
else:
return 'release'
except subprocess.CalledProcessError:
# if the build doesn't have a tag
return 'qa'
if __name__ == '__main__':
sys.exit(main())
+143
View File
@@ -0,0 +1,143 @@
import glob
import json
import os
import subprocess
import sys
import github
import uritemplate
import boto3
def main():
upload_to_github_if_tagged('lbryio/lbry')
upload_to_s3('daemon')
def get_asset_filename():
this_dir = os.path.dirname(os.path.realpath(__file__))
return glob.glob(this_dir + '/dist/*.zip')[0]
def upload_to_s3(folder):
tag = subprocess.check_output(['git', 'describe', '--always', '--abbrev=8', 'HEAD']).strip()
commit_date = subprocess.check_output([
'git', 'show', '-s', '--format=%cd', '--date=format:%Y%m%d-%H%I%S', 'HEAD']).strip()
asset_path = get_asset_filename()
bucket = 'releases.lbry.io'
key = folder + '/' + commit_date + '-' + tag + '/' + os.path.basename(asset_path)
print "Uploading " + asset_path + " to s3://" + bucket + '/' + key + ''
if 'AWS_ACCESS_KEY_ID' not in os.environ or 'AWS_SECRET_ACCESS_KEY' not in os.environ:
print 'Must set AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY to publish assets to s3'
return 1
s3 = boto3.resource(
's3',
aws_access_key_id=os.environ['AWS_ACCESS_KEY_ID'],
aws_secret_access_key=os.environ['AWS_SECRET_ACCESS_KEY'],
config=boto3.session.Config(signature_version='s3v4')
)
s3.meta.client.upload_file(asset_path, bucket, key)
def upload_to_github_if_tagged(repo_name):
try:
current_tag = subprocess.check_output(
['git', 'describe', '--exact-match', 'HEAD']).strip()
except subprocess.CalledProcessError:
print 'Not uploading to GitHub as we are not currently on a tag'
return 1
print "Current tag: " + current_tag
if 'GH_TOKEN' not in os.environ:
print 'Must set GH_TOKEN in order to publish assets to a release'
return 1
gh_token = os.environ['GH_TOKEN']
auth = github.Github(gh_token)
repo = auth.get_repo(repo_name)
if not check_repo_has_tag(repo, current_tag):
print 'Tag {} is not in repo {}'.format(current_tag, repo)
# TODO: maybe this should be an error
return 1
asset_path = get_asset_filename()
print "Uploading " + asset_path + " to Github tag " + current_tag
release = get_github_release(repo, current_tag)
upload_asset_to_github(release, asset_path, gh_token)
def check_repo_has_tag(repo, target_tag):
tags = repo.get_tags().get_page(0)
for tag in tags:
if tag.name == target_tag:
return True
return False
def get_github_release(repo, current_tag):
for release in repo.get_releases():
if release.tag_name == current_tag:
return release
raise Exception('No release for {} was found'.format(current_tag))
def upload_asset_to_github(release, asset_to_upload, token):
basename = os.path.basename(asset_to_upload)
for asset in release.raw_data['assets']:
if asset['name'] == basename:
print 'File {} has already been uploaded to {}'.format(basename, release.tag_name)
return
upload_uri = uritemplate.expand(release.upload_url, {'name': basename})
count = 0
while count < 10:
try:
output = _curl_uploader(upload_uri, asset_to_upload, token)
if 'errors' in output:
raise Exception(output)
else:
print 'Successfully uploaded to {}'.format(output['browser_download_url'])
except Exception:
print 'Failed uploading on attempt {}'.format(count + 1)
count += 1
def _curl_uploader(upload_uri, asset_to_upload, token):
# using requests.post fails miserably with SSL EPIPE errors. I spent
# half a day trying to debug before deciding to switch to curl.
#
# TODO: actually set the content type
print 'Using curl to upload {} to {}'.format(asset_to_upload, upload_uri)
cmd = [
'curl',
'-sS',
'-X', 'POST',
'-u', ':{}'.format(os.environ['GH_TOKEN']),
'--header', 'Content-Type: application/octet-stream',
'--data-binary', '@-',
upload_uri
]
# '-d', '{"some_key": "some_value"}',
print 'Calling curl:'
print cmd
print
with open(asset_to_upload, 'rb') as fp:
p = subprocess.Popen(cmd, stdin=fp, stderr=subprocess.PIPE, stdout=subprocess.PIPE)
stdout, stderr = p.communicate()
print 'curl return code:', p.returncode
if stderr:
print 'stderr output from curl:'
print stderr
print 'stdout from curl:'
print stdout
return json.loads(stdout)
if __name__ == '__main__':
sys.exit(main())
+29
View File
@@ -0,0 +1,29 @@
import os
import platform
import subprocess
import sys
import zipfile
def main():
this_dir = os.path.dirname(os.path.realpath(__file__))
tag = subprocess.check_output(['git', 'describe']).strip()
zipfilename = 'lbrynet-daemon-{}-{}.zip'.format(tag, get_system_label())
full_filename = os.path.join(this_dir, 'dist', zipfilename)
executables = ['lbrynet-daemon', 'lbrynet-cli', 'lbrynet-console']
ext = '.exe' if platform.system() == 'Windows' else ''
with zipfile.ZipFile(full_filename, 'w') as myzip:
for executable in executables:
myzip.write(os.path.join(this_dir, 'dist', executable + ext), executable + ext)
def get_system_label():
system = platform.system()
if system == 'Darwin':
return 'macos'
else:
return system.lower()
if __name__ == '__main__':
sys.exit(main())
+307
View File
@@ -0,0 +1,307 @@
<!DOCTYPE html>
<html lang="en" class="no-js">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="lang:clipboard.copy" content="Copy to clipboard">
<meta name="lang:clipboard.copied" content="Copied to clipboard">
<meta name="lang:search.language" content="en">
<meta name="lang:search.pipeline.stopwords" content="True">
<meta name="lang:search.pipeline.trimmer" content="True">
<meta name="lang:search.result.none" content="No matching documents">
<meta name="lang:search.result.one" content="1 matching document">
<meta name="lang:search.result.other" content="# matching documents">
<meta name="lang:search.tokenizer" content="[\s\-]+">
<link rel="shortcut icon" href="/assets/images/favicon.png">
<meta name="generator" content="mkdocs-0.17.3, mkdocs-material-2.7.0">
<title>LBRY</title>
<link rel="stylesheet" href="/assets/stylesheets/application.78aab2dc.css">
<link rel="stylesheet" href="/assets/stylesheets/application-palette.6079476c.css">
<script src="/assets/javascripts/modernizr.1aa3b519.js"></script>
<link href="https://fonts.gstatic.com" rel="preconnect" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,400i,700|Roboto+Mono">
<style>body,input{font-family:"Roboto","Helvetica Neue",Helvetica,Arial,sans-serif}code,kbd,pre{font-family:"Roboto Mono","Courier New",Courier,monospace}</style>
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
</head>
<body dir="ltr" data-md-color-primary="teal" data-md-color-accent="green">
<svg class="md-svg">
<defs>
<svg xmlns="http://www.w3.org/2000/svg" width="416" height="448"
viewBox="0 0 416 448" id="github">
<path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19-18.125
8.5-18.125-8.5-10.75-19-3.125-20.5 3.125-20.5 10.75-19 18.125-8.5
18.125 8.5 10.75 19 3.125 20.5zM320 304q0 10-3.125 20.5t-10.75
19-18.125 8.5-18.125-8.5-10.75-19-3.125-20.5 3.125-20.5 10.75-19
18.125-8.5 18.125 8.5 10.75 19 3.125 20.5zM360
304q0-30-17.25-51t-46.75-21q-10.25 0-48.75 5.25-17.75 2.75-39.25
2.75t-39.25-2.75q-38-5.25-48.75-5.25-29.5 0-46.75 21t-17.25 51q0 22 8
38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0
37.25-1.75t35-7.375 30.5-15 20.25-25.75 8-38.375zM416 260q0 51.75-15.25
82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5-41.75
1.125q-19.5 0-35.5-0.75t-36.875-3.125-38.125-7.5-34.25-12.875-30.25-20.25-21.5-28.75q-15.5-30.75-15.5-82.75
0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25
30.875q36.75-8.75 77.25-8.75 37 0 70 8 26.25-20.5
46.75-30.25t47.25-9.75q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34
99.5z" />
</svg>
</defs>
</svg>
<input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="drawer">
<input class="md-toggle" data-md-toggle="search" type="checkbox" id="search">
<label class="md-overlay" data-md-component="overlay" for="drawer"></label>
<header class="md-header" data-md-component="header">
<nav class="md-header-nav md-grid">
<div class="md-flex">
<div class="md-flex__cell md-flex__cell--shrink">
<a href="/" title="LBRY" class="md-header-nav__button md-logo">
<img src="https://s3.amazonaws.com/files.lbry.io/logo-square-white-bookonly.png" width="24" height="24">
</a>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--menu md-header-nav__button" for="drawer"></label>
</div>
<div class="md-flex__cell md-flex__cell--stretch">
<div class="md-flex__ellipsis md-header-nav__title" data-md-component="title">
<span class="md-header-nav__topic">
LBRY
</span>
<span class="md-header-nav__topic">
</span>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--search md-header-nav__button" for="search"></label>
<div class="md-search" data-md-component="search" role="dialog">
<label class="md-search__overlay" for="search"></label>
<div class="md-search__inner" role="search">
<form class="md-search__form" name="search">
<input type="text" class="md-search__input" name="query" placeholder="Search" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="query" data-md-state="active">
<label class="md-icon md-search__icon" for="search"></label>
<button type="reset" class="md-icon md-search__icon" data-md-component="reset" tabindex="-1">
&#xE5CD;
</button>
</form>
<div class="md-search__output">
<div class="md-search__scrollwrap" data-md-scrollfix>
<div class="md-search-result" data-md-component="result">
<div class="md-search-result__meta">
Type to start searching
</div>
<ol class="md-search-result__list"></ol>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<div class="md-header-nav__source">
<a href="https://github.com/lbryio/lbry/" title="Go to repository" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
GitHub
</div>
</a>
</div>
</div>
</div>
</nav>
</header>
<div class="md-container">
<main class="md-main">
<div class="md-main__inner md-grid" data-md-component="container">
<div class="md-sidebar md-sidebar--primary" data-md-component="navigation">
<div class="md-sidebar__scrollwrap">
<div class="md-sidebar__inner">
<nav class="md-nav md-nav--primary" data-md-level="0">
<label class="md-nav__title md-nav__title--site" for="drawer">
<span class="md-nav__button md-logo">
<img src="https://s3.amazonaws.com/files.lbry.io/logo-square-white-bookonly.png" width="48" height="48">
</span>
LBRY
</label>
<div class="md-nav__source">
<a href="https://github.com/lbryio/lbry/" title="Go to repository" class="md-source" data-md-source="github">
<div class="md-source__icon">
<svg viewBox="0 0 24 24" width="24" height="24">
<use xlink:href="#github" width="24" height="24"></use>
</svg>
</div>
<div class="md-source__repository">
GitHub
</div>
</a>
</div>
<ul class="md-nav__list" data-md-scrollfix>
<li class="md-nav__item">
<a href="/" title="API" class="md-nav__link">
API
</a>
</li>
<li class="md-nav__item">
<a href="/cli/" title="CLI" class="md-nav__link">
CLI
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<div class="md-content">
<article class="md-content__inner md-typeset">
<h1>404 - Not found</h1>
</article>
</div>
</div>
</main>
<footer class="md-footer">
<div class="md-footer-meta md-typeset">
<div class="md-footer-meta__inner md-grid">
<div class="md-footer-copyright">
powered by
<a href="http://www.mkdocs.org">MkDocs</a>
and
<a href="https://squidfunk.github.io/mkdocs-material/">
Material for MkDocs</a>
</div>
</div>
</div>
</footer>
</div>
<script src="/assets/javascripts/application.8eb9be28.js"></script>
<script>app.initialize({version:"0.17.3",url:{base:""}})</script>
<script>!function(e,a,t,n,o,c,i){e.GoogleAnalyticsObject=o,e.ga=e.ga||function(){(e.ga.q=e.ga.q||[]).push(arguments)},e.ga.l=1*new Date,c=a.createElement(t),i=a.getElementsByTagName(t)[0],c.async=1,c.src="https://www.google-analytics.com/analytics.js",i.parentNode.insertBefore(c,i)}(window,document,"script",0,"ga"),ga("create","UA-60403362-1","auto"),ga("set","anonymizeIp",!0),ga("send","pageview");var links=document.getElementsByTagName("a");if(Array.prototype.map.call(links,function(e){e.host!=document.location.host&&e.addEventListener("click",function(){var a=e.getAttribute("data-md-action")||"follow";ga("send","event","outbound",a,e.href)})}),document.forms.search){var query=document.forms.search.query;query.addEventListener("blur",function(){if(this.value){var e=document.location.pathname;ga("send","pageview",e+"?q="+this.value)}})}</script>
</body>
</html>
Binary file not shown.

After

Width:  |  Height:  |  Size: 521 B

@@ -0,0 +1,20 @@
<svg xmlns="http://www.w3.org/2000/svg" width="352" height="448"
viewBox="0 0 352 448" id="bitbucket">
<path fill="currentColor" d="M203.75 214.75q2 15.75-12.625 25.25t-27.875
1.5q-9.75-4.25-13.375-14.5t-0.125-20.5 13-14.5q9-4.5 18.125-3t16 8.875
6.875 16.875zM231.5 209.5q-3.5-26.75-28.25-41t-49.25-3.25q-15.75
7-25.125 22.125t-8.625 32.375q1 22.75 19.375 38.75t41.375 14q22.75-2
38-21t12.5-42zM291.25
74q-5-6.75-14-11.125t-14.5-5.5-17.75-3.125q-72.75-11.75-141.5 0.5-10.75
1.75-16.5 3t-13.75 5.5-12.5 10.75q7.5 7 19 11.375t18.375 5.5 21.875
2.875q57 7.25 112 0.25 15.75-2 22.375-3t18.125-5.375 18.75-11.625zM305.5
332.75q-2 6.5-3.875 19.125t-3.5 21-7.125 17.5-14.5 14.125q-21.5
12-47.375 17.875t-50.5 5.5-50.375-4.625q-11.5-2-20.375-4.5t-19.125-6.75-18.25-10.875-13-15.375q-6.25-24-14.25-73l1.5-4
4.5-2.25q55.75 37 126.625 37t126.875-37q5.25 1.5 6 5.75t-1.25 11.25-2
9.25zM350.75 92.5q-6.5 41.75-27.75 163.75-1.25 7.5-6.75 14t-10.875
10-13.625 7.75q-63 31.5-152.5
22-62-6.75-98.5-34.75-3.75-3-6.375-6.625t-4.25-8.75-2.25-8.5-1.5-9.875-1.375-8.75q-2.25-12.5-6.625-37.5t-7-40.375-5.875-36.875-5.5-39.5q0.75-6.5
4.375-12.125t7.875-9.375 11.25-7.5 11.5-5.625 12-4.625q31.25-11.5
78.25-16 94.75-9.25 169 12.5 38.75 11.5 53.75 30.5 4 5 4.125
12.75t-1.375 13.5z" />
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

@@ -0,0 +1,18 @@
<svg xmlns="http://www.w3.org/2000/svg" width="416" height="448"
viewBox="0 0 416 448" id="github">
<path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19-18.125
8.5-18.125-8.5-10.75-19-3.125-20.5 3.125-20.5 10.75-19 18.125-8.5
18.125 8.5 10.75 19 3.125 20.5zM320 304q0 10-3.125 20.5t-10.75
19-18.125 8.5-18.125-8.5-10.75-19-3.125-20.5 3.125-20.5 10.75-19
18.125-8.5 18.125 8.5 10.75 19 3.125 20.5zM360
304q0-30-17.25-51t-46.75-21q-10.25 0-48.75 5.25-17.75 2.75-39.25
2.75t-39.25-2.75q-38-5.25-48.75-5.25-29.5 0-46.75 21t-17.25 51q0 22 8
38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0
37.25-1.75t35-7.375 30.5-15 20.25-25.75 8-38.375zM416 260q0 51.75-15.25
82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5-41.75
1.125q-19.5 0-35.5-0.75t-36.875-3.125-38.125-7.5-34.25-12.875-30.25-20.25-21.5-28.75q-15.5-30.75-15.5-82.75
0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25
30.875q36.75-8.75 77.25-8.75 37 0 70 8 26.25-20.5
46.75-30.25t47.25-9.75q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34
99.5z" />
</svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

@@ -0,0 +1,38 @@
<svg xmlns="http://www.w3.org/2000/svg" width="500" height="500"
viewBox="0 0 500 500" id="gitlab">
<g transform="translate(156.197863, 1.160267)">
<path fill="currentColor"
d="M93.667,473.347L93.667,473.347l90.684-279.097H2.983L93.667,
473.347L93.667,473.347z" />
</g>
<g transform="translate(28.531199, 1.160800)" opacity="0.7">
<path fill="currentColor"
d="M221.333,473.345L130.649,194.25H3.557L221.333,473.345L221.333,
473.345z" />
</g>
<g transform="translate(0.088533, 0.255867)" opacity="0.5">
<path fill="currentColor"
d="M32,195.155L32,195.155L4.441,279.97c-2.513,7.735,0.24,16.21,6.821,
20.99l238.514,173.29 L32,195.155L32,195.155z" />
</g>
<g transform="translate(29.421866, 280.255593)">
<path fill="currentColor"
d="M2.667-84.844h127.092L75.14-252.942c-2.811-8.649-15.047-8.649-17.856,
0L2.667-84.844 L2.667-84.844z" />
</g>
<g transform="translate(247.197860, 1.160800)" opacity="0.7">
<path fill="currentColor"
d="M2.667,473.345L93.351,194.25h127.092L2.667,473.345L2.667,
473.345z" />
</g>
<g transform="translate(246.307061, 0.255867)" opacity="0.5">
<path fill="currentColor"
d="M221.334,195.155L221.334,195.155l27.559,84.815c2.514,7.735-0.24,
16.21-6.821,20.99 L3.557,474.25L221.334,195.155L221.334,195.155z" />
</g>
<g transform="translate(336.973725, 280.255593)">
<path fill="currentColor"
d="M130.667-84.844H3.575l54.618-168.098c2.811-8.649,15.047-8.649,
17.856,0L130.667-84.844 L130.667-84.844z" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.6 KiB

@@ -0,0 +1 @@
!function(e,t){for(var n in t)e[n]=t[n]}(window,function(e){function t(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,t),i.l=!0,i.exports}var n={};return t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=6)}([function(e,t,n){"use strict";t.__esModule=!0,t.default={createElement:function(e,t){var n=document.createElement(e);t&&Array.prototype.forEach.call(Object.keys(t),function(e){n.setAttribute(e,t[e])});for(var r=arguments.length,i=Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];return function e(t){Array.prototype.forEach.call(t,function(t){"string"==typeof t||"number"==typeof t?n.textContent+=t:Array.isArray(t)?e(t):void 0!==t.__html?n.innerHTML+=t.__html:t instanceof Node&&n.appendChild(t)})}(i),n}},e.exports=t.default},function(e,t){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r="function"==typeof fetch?fetch.bind():function(e,t){return t=t||{},new Promise(function(n,r){function i(){var e,t=[],n=[],r={};return o.getAllResponseHeaders().replace(/^(.*?):\s*([\s\S]*?)$/gm,function(i,o,a){t.push(o=o.toLowerCase()),n.push([o,a]),e=r[o],r[o]=e?e+","+a:a}),{ok:1==(o.status/200|0),status:o.status,statusText:o.statusText,url:o.responseURL,clone:i,text:function(){return Promise.resolve(o.responseText)},json:function(){return Promise.resolve(o.responseText).then(JSON.parse)},blob:function(){return Promise.resolve(new Blob([o.response]))},headers:{keys:function(){return t},entries:function(){return n},get:function(e){return r[e.toLowerCase()]},has:function(e){return e.toLowerCase()in r}}}}var o=new XMLHttpRequest;o.open(t.method||"get",e);for(var a in t.headers)o.setRequestHeader(a,t.headers[a]);o.withCredentials="include"==t.credentials,o.onload=function(){n(i())},o.onerror=r,o.send(t.body)})};t.default=r},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var i=function(){function e(t,n,i){var o=this;r(this,e),this.els_=Array.prototype.slice.call("string"==typeof t?document.querySelectorAll(t):[].concat(t)),this.handler_="function"==typeof i?{update:i}:i,this.events_=[].concat(n),this.update_=function(e){return o.handler_.update(e)}}return e.prototype.listen=function(){var e=this;this.els_.forEach(function(t){e.events_.forEach(function(n){t.addEventListener(n,e.update_,!1)})}),"function"==typeof this.handler_.setup&&this.handler_.setup()},e.prototype.unlisten=function(){var e=this;this.els_.forEach(function(t){e.events_.forEach(function(n){t.removeEventListener(n,e.update_)})}),"function"==typeof this.handler_.reset&&this.handler_.reset()},e}();t.default=i},,,function(e,t,n){"use strict";(function(e){function r(e){return e&&e.__esModule?e:{default:e}}function i(t){new f.default.Event.Listener(document,"DOMContentLoaded",function(){if(!(document.body instanceof HTMLElement))throw new ReferenceError;l.default.attach(document.body),Modernizr.addTest("ios",function(){return!!navigator.userAgent.match(/(iPad|iPhone|iPod)/g)});var t=document.querySelectorAll("table:not([class])");if(Array.prototype.forEach.call(t,function(t){var n=e.createElement("div",{class:"md-typeset__scrollwrap"},e.createElement("div",{class:"md-typeset__table"}));t.nextSibling?t.parentNode.insertBefore(n,t.nextSibling):t.parentNode.appendChild(n),n.children[0].appendChild(t)}),c.default.isSupported()){var n=document.querySelectorAll(".codehilite > pre, pre > code");Array.prototype.forEach.call(n,function(t,n){var r="__code_"+n,i=e.createElement("button",{class:"md-clipboard",title:h("clipboard.copy"),"data-clipboard-target":"#"+r+" pre, #"+r+" code"},e.createElement("span",{class:"md-clipboard__message"})),o=t.parentNode;o.id=r,o.insertBefore(i,t)});new c.default(".md-clipboard").on("success",function(e){var t=e.trigger.querySelector(".md-clipboard__message");if(!(t instanceof HTMLElement))throw new ReferenceError;e.clearSelection(),t.dataset.mdTimer&&clearTimeout(parseInt(t.dataset.mdTimer,10)),t.classList.add("md-clipboard__message--active"),t.innerHTML=h("clipboard.copied"),t.dataset.mdTimer=setTimeout(function(){t.classList.remove("md-clipboard__message--active"),t.dataset.mdTimer=""},2e3).toString()})}if(!Modernizr.details){var r=document.querySelectorAll("details > summary");Array.prototype.forEach.call(r,function(e){e.addEventListener("click",function(e){var t=e.target.parentNode;t.hasAttribute("open")?t.removeAttribute("open"):t.setAttribute("open","")})})}var i=function(){if(document.location.hash){var e=document.getElementById(document.location.hash.substring(1));if(!Line truncated
+1
View File
@@ -0,0 +1 @@
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,i,n;e.da=function(){this.pipeline.reset(),this.pipeline.add(e.da.trimmer,e.da.stopWordFilter,e.da.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.da.stemmer))},e.da.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.da.trimmer=e.trimmerSupport.generateTrimmer(e.da.wordCharacters),e.Pipeline.registerFunction(e.da.trimmer,"trimmer-da"),e.da.stemmer=(r=e.stemmerSupport.Among,i=e.stemmerSupport.SnowballProgram,n=new function(){var e,n,t,s=[new r("hed",-1,1),new r("ethed",0,1),new r("ered",-1,1),new r("e",-1,1),new r("erede",3,1),new r("ende",3,1),new r("erende",5,1),new r("ene",3,1),new r("erne",3,1),new r("ere",3,1),new r("en",-1,1),new r("heden",10,1),new r("eren",10,1),new r("er",-1,1),new r("heder",13,1),new r("erer",13,1),new r("s",-1,2),new r("heds",16,1),new r("es",16,1),new r("endes",18,1),new r("erendes",19,1),new r("enes",18,1),new r("ernes",18,1),new r("eres",18,1),new r("ens",16,1),new r("hedens",24,1),new r("erens",24,1),new r("ers",16,1),new r("ets",16,1),new r("erets",28,1),new r("et",-1,1),new r("eret",30,1)],o=[new r("gd",-1,-1),new r("dt",-1,-1),new r("gt",-1,-1),new r("kt",-1,-1)],a=[new r("ig",-1,1),new r("lig",0,1),new r("elig",1,1),new r("els",-1,1),new r("løst",-1,2)],d=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,48,0,128],u=[239,254,42,3,0,0,0,0,0,0,0,0,0,0,0,0,16],c=new i;function l(){var e,r=c.limit-c.cursor;c.cursor>=n&&(e=c.limit_backward,c.limit_backward=n,c.ket=c.cursor,c.find_among_b(o,4)?(c.bra=c.cursor,c.limit_backward=e,c.cursor=c.limit-r,c.cursor>c.limit_backward&&(c.cursor--,c.bra=c.cursor,c.slice_del())):c.limit_backward=e)}this.setCurrent=function(e){c.setCurrent(e)},this.getCurrent=function(){return c.getCurrent()},this.stem=function(){var r,i=c.cursor;return function(){var r,i=c.cursor+3;if(n=c.limit,0<=i&&i<=c.limit){for(e=i;;){if(r=c.cursor,c.in_grouping(d,97,248)){c.cursor=r;break}if(c.cursor=r,r>=c.limit)return;c.cursor++}for(;!c.out_grouping(d,97,248);){if(c.cursor>=c.limit)return;c.cursor++}(n=c.cursor)<e&&(n=e)}}(),c.limit_backward=i,c.cursor=c.limit,function(){var e,r;if(c.cursor>=n&&(r=c.limit_backward,c.limit_backward=n,c.ket=c.cursor,e=c.find_among_b(s,32),c.limit_backward=r,e))switch(c.bra=c.cursor,e){case 1:c.slice_del();break;case 2:c.in_grouping_b(u,97,229)&&c.slice_del()}}(),c.cursor=c.limit,l(),c.cursor=c.limit,function(){var e,r,i,t=c.limit-c.cursor;if(c.ket=c.cursor,c.eq_s_b(2,"st")&&(c.bra=c.cursor,c.eq_s_b(2,"ig")&&c.slice_del()),c.cursor=c.limit-t,c.cursor>=n&&(r=c.limit_backward,c.limit_backward=n,c.ket=c.cursor,e=c.find_among_b(a,5),c.limit_backward=r,e))switch(c.bra=c.cursor,e){case 1:c.slice_del(),i=c.limit-c.cursor,l(),c.cursor=c.limit-i;break;case 2:c.slice_from("løs")}}(),c.cursor=c.limit,c.cursor>=n&&(r=c.limit_backward,c.limit_backward=n,c.ket=c.cursor,c.out_grouping_b(d,97,248)?(c.bra=c.cursor,t=c.slice_to(t),c.limit_backward=r,c.eq_v_b(t)&&c.slice_del()):c.limit_backward=r),!0}},function(e){return"function"==typeof e.update?e.update(function(e){return n.setCurrent(e),n.stem(),n.getCurrent()}):(n.setCurrent(e),n.stem(),n.getCurrent())}),e.Pipeline.registerFunction(e.da.stemmer,"stemmer-da"),e.da.stopWordFilter=e.generateStopWordFilter("ad af alle alt anden at blev blive bliver da de dem den denne der deres det dette dig din disse dog du efter eller en end er et for fra ham han hans har havde have hende hendes her hos hun hvad hvis hvor i ikke ind jeg jer jo kunne man mange med meget men mig min mine mit mod ned noget nogle nu når og også om op os over på selv sig sin sine sit skal skulle som sådan thi til ud under var vi vil ville vor være været".split(" ")),e.Pipeline.registerFunction(e.da.stopWordFilter,"stopWordFilter-da")}});
+1
View File
@@ -0,0 +1 @@
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,n,i;e.de=function(){this.pipeline.reset(),this.pipeline.add(e.de.trimmer,e.de.stopWordFilter,e.de.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.de.stemmer))},e.de.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.de.trimmer=e.trimmerSupport.generateTrimmer(e.de.wordCharacters),e.Pipeline.registerFunction(e.de.trimmer,"trimmer-de"),e.de.stemmer=(r=e.stemmerSupport.Among,n=e.stemmerSupport.SnowballProgram,i=new function(){var e,i,s,t=[new r("",-1,6),new r("U",0,2),new r("Y",0,1),new r("ä",0,3),new r("ö",0,4),new r("ü",0,5)],o=[new r("e",-1,2),new r("em",-1,1),new r("en",-1,2),new r("ern",-1,1),new r("er",-1,1),new r("s",-1,3),new r("es",5,2)],c=[new r("en",-1,1),new r("er",-1,1),new r("st",-1,2),new r("est",2,1)],u=[new r("ig",-1,1),new r("lich",-1,1)],a=[new r("end",-1,1),new r("ig",-1,2),new r("ung",-1,1),new r("lich",-1,3),new r("isch",-1,2),new r("ik",-1,2),new r("heit",-1,3),new r("keit",-1,4)],d=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,8,0,32,8],l=[117,30,5],m=[117,30,4],h=new n;function w(e,r,n){return!(!h.eq_s(1,e)||(h.ket=h.cursor,!h.in_grouping(d,97,252)))&&(h.slice_from(r),h.cursor=n,!0)}function f(){for(;!h.in_grouping(d,97,252);){if(h.cursor>=h.limit)return!0;h.cursor++}for(;!h.out_grouping(d,97,252);){if(h.cursor>=h.limit)return!0;h.cursor++}return!1}function b(){return s<=h.cursor}function _(){return i<=h.cursor}this.setCurrent=function(e){h.setCurrent(e)},this.getCurrent=function(){return h.getCurrent()},this.stem=function(){var r=h.cursor;return function(){for(var e,r,n,i,s=h.cursor;;)if(e=h.cursor,h.bra=e,h.eq_s(1,"ß"))h.ket=h.cursor,h.slice_from("ss");else{if(e>=h.limit)break;h.cursor=e+1}for(h.cursor=s;;)for(r=h.cursor;;){if(n=h.cursor,h.in_grouping(d,97,252)){if(i=h.cursor,h.bra=i,w("u","U",n))break;if(h.cursor=i,w("y","Y",n))break}if(n>=h.limit)return void(h.cursor=r);h.cursor=n+1}}(),h.cursor=r,function(){s=h.limit,i=s;var r=h.cursor+3;0<=r&&r<=h.limit&&(e=r,f()||((s=h.cursor)<e&&(s=e),f()||(i=h.cursor)))}(),h.limit_backward=r,h.cursor=h.limit,function(){var e,r,n,i,s=h.limit-h.cursor;if(h.ket=h.cursor,(e=h.find_among_b(o,7))&&(h.bra=h.cursor,b()))switch(e){case 1:h.slice_del();break;case 2:h.slice_del(),h.ket=h.cursor,h.eq_s_b(1,"s")&&(h.bra=h.cursor,h.eq_s_b(3,"nis")&&h.slice_del());break;case 3:h.in_grouping_b(l,98,116)&&h.slice_del()}if(h.cursor=h.limit-s,h.ket=h.cursor,(e=h.find_among_b(c,4))&&(h.bra=h.cursor,b()))switch(e){case 1:h.slice_del();break;case 2:if(h.in_grouping_b(m,98,116)){var t=h.cursor-3;h.limit_backward<=t&&t<=h.limit&&(h.cursor=t,h.slice_del())}}if(h.cursor=h.limit-s,h.ket=h.cursor,(e=h.find_among_b(a,8))&&(h.bra=h.cursor,_()))switch(e){case 1:h.slice_del(),h.ket=h.cursor,h.eq_s_b(2,"ig")&&(h.bra=h.cursor,r=h.limit-h.cursor,h.eq_s_b(1,"e")||(h.cursor=h.limit-r,_()&&h.slice_del()));break;case 2:n=h.limit-h.cursor,h.eq_s_b(1,"e")||(h.cursor=h.limit-n,h.slice_del());break;case 3:if(h.slice_del(),h.ket=h.cursor,i=h.limit-h.cursor,!h.eq_s_b(2,"er")&&(h.cursor=h.limit-i,!h.eq_s_b(2,"en")))break;h.bra=h.cursor,b()&&h.slice_del();break;case 4:h.slice_del(),h.ket=h.cursor,(e=h.find_among_b(u,2))&&(h.bra=h.cursor,_()&&1==e&&h.slice_del())}}(),h.cursor=h.limit_backward,function(){for(var e,r;;){if(r=h.cursor,h.bra=r,!(e=h.find_among(t,6)))return;switch(h.ket=h.cursor,e){case 1:h.slice_from("y");break;case 2:case 5:h.slice_from("u");break;case 3:h.slice_from("a");break;case 4:h.slice_from("o");break;case 6:if(h.cursor>=h.limit)return;h.cursor++}}}(),!0}},function(e){return"function"==typeof e.update?e.update(function(e){return i.setCurrent(e),i.stem(),i.getCurrent()}):(i.setCurrent(e),i.stem(),i.getCurrent())}),e.Pipeline.registerFunction(e.de.stemmer,"stemmer-de"),e.de.stopWordFilter=e.generateStopWordFilter("aber alle allem allen aller alles als also am an ander andere anderem anderen anderer anderes anderm andern anderr anders auch auf aus bei bin bis bist da damit dann das dasselbe dazu daß dein deine deinem deinen deiner deines dem demselben den denn denselben der derer derselbe derselben des desselben dessen dich die dies diese dieselbe dieselben diesem diesen dieser dieses dir doch dort du durch ein eine einem einen einer eines einig einige einigem einigen einiger einiges einmal er es etwas euch euer eure eurem euren eurer eures für gegen gewesen hab habe haben hat hatte hatten hier hin hinter ich ihm ihn ihnen ihr ihre ihrem ihren ihrer ihres im in indem ins ist jede jedem jedenLine truncated
+1
View File
@@ -0,0 +1 @@
!function(r,e){"function"==typeof define&&define.amd?define(e):"object"==typeof exports?module.exports=e():e()(r.lunr)}(this,function(){return function(r){if(void 0===r)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===r.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var e,i,n;r.du=function(){this.pipeline.reset(),this.pipeline.add(r.du.trimmer,r.du.stopWordFilter,r.du.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(r.du.stemmer))},r.du.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",r.du.trimmer=r.trimmerSupport.generateTrimmer(r.du.wordCharacters),r.Pipeline.registerFunction(r.du.trimmer,"trimmer-du"),r.du.stemmer=(e=r.stemmerSupport.Among,i=r.stemmerSupport.SnowballProgram,n=new function(){var r,n,o,t=[new e("",-1,6),new e("á",0,1),new e("ä",0,1),new e("é",0,2),new e("ë",0,2),new e("í",0,3),new e("ï",0,3),new e("ó",0,4),new e("ö",0,4),new e("ú",0,5),new e("ü",0,5)],s=[new e("",-1,3),new e("I",0,2),new e("Y",0,1)],u=[new e("dd",-1,-1),new e("kk",-1,-1),new e("tt",-1,-1)],c=[new e("ene",-1,2),new e("se",-1,3),new e("en",-1,2),new e("heden",2,1),new e("s",-1,3)],a=[new e("end",-1,1),new e("ig",-1,2),new e("ing",-1,1),new e("lijk",-1,3),new e("baar",-1,4),new e("bar",-1,5)],l=[new e("aa",-1,-1),new e("ee",-1,-1),new e("oo",-1,-1),new e("uu",-1,-1)],m=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,128],d=[1,0,0,17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,128],f=[17,67,16,1,0,0,0,0,0,0,0,0,0,0,0,0,128],_=new i;function w(r){return _.cursor=r,r>=_.limit||(_.cursor++,!1)}function b(){for(;!_.in_grouping(m,97,232);){if(_.cursor>=_.limit)return!0;_.cursor++}for(;!_.out_grouping(m,97,232);){if(_.cursor>=_.limit)return!0;_.cursor++}return!1}function p(){return n<=_.cursor}function g(){return r<=_.cursor}function h(){var r=_.limit-_.cursor;_.find_among_b(u,3)&&(_.cursor=_.limit-r,_.ket=_.cursor,_.cursor>_.limit_backward&&(_.cursor--,_.bra=_.cursor,_.slice_del()))}function k(){var r;o=!1,_.ket=_.cursor,_.eq_s_b(1,"e")&&(_.bra=_.cursor,p()&&(r=_.limit-_.cursor,_.out_grouping_b(m,97,232)&&(_.cursor=_.limit-r,_.slice_del(),o=!0,h())))}function v(){var r;p()&&(r=_.limit-_.cursor,_.out_grouping_b(m,97,232)&&(_.cursor=_.limit-r,_.eq_s_b(3,"gem")||(_.cursor=_.limit-r,_.slice_del(),h())))}this.setCurrent=function(r){_.setCurrent(r)},this.getCurrent=function(){return _.getCurrent()},this.stem=function(){var e=_.cursor;return function(){for(var r,e,i,n=_.cursor;;){if(_.bra=_.cursor,r=_.find_among(t,11))switch(_.ket=_.cursor,r){case 1:_.slice_from("a");continue;case 2:_.slice_from("e");continue;case 3:_.slice_from("i");continue;case 4:_.slice_from("o");continue;case 5:_.slice_from("u");continue;case 6:if(_.cursor>=_.limit)break;_.cursor++;continue}break}for(_.cursor=n,_.bra=n,_.eq_s(1,"y")?(_.ket=_.cursor,_.slice_from("Y")):_.cursor=n;;)if(e=_.cursor,_.in_grouping(m,97,232)){if(i=_.cursor,_.bra=i,_.eq_s(1,"i"))_.ket=_.cursor,_.in_grouping(m,97,232)&&(_.slice_from("I"),_.cursor=e);else if(_.cursor=i,_.eq_s(1,"y"))_.ket=_.cursor,_.slice_from("Y"),_.cursor=e;else if(w(e))break}else if(w(e))break}(),_.cursor=e,n=_.limit,r=n,b()||((n=_.cursor)<3&&(n=3),b()||(r=_.cursor)),_.limit_backward=e,_.cursor=_.limit,function(){var r,e,i,n,t,s,u=_.limit-_.cursor;if(_.ket=_.cursor,r=_.find_among_b(c,5))switch(_.bra=_.cursor,r){case 1:p()&&_.slice_from("heid");break;case 2:v();break;case 3:p()&&_.out_grouping_b(f,97,232)&&_.slice_del()}if(_.cursor=_.limit-u,k(),_.cursor=_.limit-u,_.ket=_.cursor,_.eq_s_b(4,"heid")&&(_.bra=_.cursor,g()&&(e=_.limit-_.cursor,_.eq_s_b(1,"c")||(_.cursor=_.limit-e,_.slice_del(),_.ket=_.cursor,_.eq_s_b(2,"en")&&(_.bra=_.cursor,v())))),_.cursor=_.limit-u,_.ket=_.cursor,r=_.find_among_b(a,6))switch(_.bra=_.cursor,r){case 1:if(g()){if(_.slice_del(),i=_.limit-_.cursor,_.ket=_.cursor,_.eq_s_b(2,"ig")&&(_.bra=_.cursor,g()&&(n=_.limit-_.cursor,!_.eq_s_b(1,"e")))){_.cursor=_.limit-n,_.slice_del();break}_.cursor=_.limit-i,h()}break;case 2:g()&&(t=_.limit-_.cursor,_.eq_s_b(1,"e")||(_.cursor=_.limit-t,_.slice_del()));break;case 3:g()&&(_.slice_del(),k());break;case 4:g()&&_.slice_del();break;case 5:g()&&o&&_.slice_del()}_.cursor=_.limit-u,_.out_grouping_b(d,73,232)&&(s=_.limit-_.cursor,_.find_among_b(l,4)&&_.out_grouping_b(m,97,232)&&(_.cursor=_.limit-s,_.ket=_.cursor,_.cursor>_.limit_backward&&(_.cursor--,_.bra=_.cursor,_.slice_del())))}(),_.cursor=_.limit_backward,function(){for(var r;;)if(_.bra=_.cursor,r=_.find_among(s,3))switch(_.ket=_.cursor,r){case 1:_.slice_from("y");break;case 2:_.slice_from("i");break;case 3:if(_.cursor>=_.limit)return;_.cursor++}}(),!0}},function(r){return"function"==typeof r.update?r.update(function(r){return n.setCurrent(r),n.stem(),n.getCurrent()}):(n.setCurrent(r),n.stem(),n.getCurrent())}),r.PLine truncated
+1
View File
@@ -0,0 +1 @@
!function(e,s){"function"==typeof define&&define.amd?define(s):"object"==typeof exports?module.exports=s():s()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var s,r,n;e.es=function(){this.pipeline.reset(),this.pipeline.add(e.es.trimmer,e.es.stopWordFilter,e.es.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.es.stemmer))},e.es.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.es.trimmer=e.trimmerSupport.generateTrimmer(e.es.wordCharacters),e.Pipeline.registerFunction(e.es.trimmer,"trimmer-es"),e.es.stemmer=(s=e.stemmerSupport.Among,r=e.stemmerSupport.SnowballProgram,n=new function(){var e,n,i,a=[new s("",-1,6),new s("á",0,1),new s("é",0,2),new s("í",0,3),new s("ó",0,4),new s("ú",0,5)],t=[new s("la",-1,-1),new s("sela",0,-1),new s("le",-1,-1),new s("me",-1,-1),new s("se",-1,-1),new s("lo",-1,-1),new s("selo",5,-1),new s("las",-1,-1),new s("selas",7,-1),new s("les",-1,-1),new s("los",-1,-1),new s("selos",10,-1),new s("nos",-1,-1)],o=[new s("ando",-1,6),new s("iendo",-1,6),new s("yendo",-1,7),new s("ándo",-1,2),new s("iéndo",-1,1),new s("ar",-1,6),new s("er",-1,6),new s("ir",-1,6),new s("ár",-1,3),new s("ér",-1,4),new s("ír",-1,5)],u=[new s("ic",-1,-1),new s("ad",-1,-1),new s("os",-1,-1),new s("iv",-1,1)],w=[new s("able",-1,1),new s("ible",-1,1),new s("ante",-1,1)],c=[new s("ic",-1,1),new s("abil",-1,1),new s("iv",-1,1)],m=[new s("ica",-1,1),new s("ancia",-1,2),new s("encia",-1,5),new s("adora",-1,2),new s("osa",-1,1),new s("ista",-1,1),new s("iva",-1,9),new s("anza",-1,1),new s("logía",-1,3),new s("idad",-1,8),new s("able",-1,1),new s("ible",-1,1),new s("ante",-1,2),new s("mente",-1,7),new s("amente",13,6),new s("ación",-1,2),new s("ución",-1,4),new s("ico",-1,1),new s("ismo",-1,1),new s("oso",-1,1),new s("amiento",-1,1),new s("imiento",-1,1),new s("ivo",-1,9),new s("ador",-1,2),new s("icas",-1,1),new s("ancias",-1,2),new s("encias",-1,5),new s("adoras",-1,2),new s("osas",-1,1),new s("istas",-1,1),new s("ivas",-1,9),new s("anzas",-1,1),new s("logías",-1,3),new s("idades",-1,8),new s("ables",-1,1),new s("ibles",-1,1),new s("aciones",-1,2),new s("uciones",-1,4),new s("adores",-1,2),new s("antes",-1,2),new s("icos",-1,1),new s("ismos",-1,1),new s("osos",-1,1),new s("amientos",-1,1),new s("imientos",-1,1),new s("ivos",-1,9)],l=[new s("ya",-1,1),new s("ye",-1,1),new s("yan",-1,1),new s("yen",-1,1),new s("yeron",-1,1),new s("yendo",-1,1),new s("yo",-1,1),new s("yas",-1,1),new s("yes",-1,1),new s("yais",-1,1),new s("yamos",-1,1),new s("yó",-1,1)],d=[new s("aba",-1,2),new s("ada",-1,2),new s("ida",-1,2),new s("ara",-1,2),new s("iera",-1,2),new s("ía",-1,2),new s("aría",5,2),new s("ería",5,2),new s("iría",5,2),new s("ad",-1,2),new s("ed",-1,2),new s("id",-1,2),new s("ase",-1,2),new s("iese",-1,2),new s("aste",-1,2),new s("iste",-1,2),new s("an",-1,2),new s("aban",16,2),new s("aran",16,2),new s("ieran",16,2),new s("ían",16,2),new s("arían",20,2),new s("erían",20,2),new s("irían",20,2),new s("en",-1,1),new s("asen",24,2),new s("iesen",24,2),new s("aron",-1,2),new s("ieron",-1,2),new s("arán",-1,2),new s("erán",-1,2),new s("irán",-1,2),new s("ado",-1,2),new s("ido",-1,2),new s("ando",-1,2),new s("iendo",-1,2),new s("ar",-1,2),new s("er",-1,2),new s("ir",-1,2),new s("as",-1,2),new s("abas",39,2),new s("adas",39,2),new s("idas",39,2),new s("aras",39,2),new s("ieras",39,2),new s("ías",39,2),new s("arías",45,2),new s("erías",45,2),new s("irías",45,2),new s("es",-1,1),new s("ases",49,2),new s("ieses",49,2),new s("abais",-1,2),new s("arais",-1,2),new s("ierais",-1,2),new s("íais",-1,2),new s("aríais",55,2),new s("eríais",55,2),new s("iríais",55,2),new s("aseis",-1,2),new s("ieseis",-1,2),new s("asteis",-1,2),new s("isteis",-1,2),new s("áis",-1,2),new s("éis",-1,1),new s("aréis",64,2),new s("eréis",64,2),new s("iréis",64,2),new s("ados",-1,2),new s("idos",-1,2),new s("amos",-1,2),new s("ábamos",70,2),new s("áramos",70,2),new s("iéramos",70,2),new s("íamos",70,2),new s("aríamos",74,2),new s("eríamos",74,2),new s("iríamos",74,2),new s("emos",-1,1),new s("aremos",78,2),new s("eremos",78,2),new s("iremos",78,2),new s("ásemos",78,2),new s("iésemos",78,2),new s("imos",-1,2),new s("arás",-1,2),new s("erás",-1,2),new s("irás",-1,2),new s("ís",-1,2),new s("ará",-1,2),new s("erá",-1,2),new s("irá",-1,2),new s("aré",-1,2),new s("eré",-1,2),new s("iré",-1,2),new s("ió",-1,2)],b=[new s("a",-1,1),new s("e",-1,2),new s("o",-1,1),new s("os",-1,1),new s("á",-1,1),new s("é",-1,2),new s("í",-1,1),new s("ó",-1,1)],f=[17,65,16,0,0,0,0,0,0,0,0,0,0,0,0,0,1,17,4,1Line truncated
+1
View File
@@ -0,0 +1 @@
!function(i,e){"function"==typeof define&&define.amd?define(e):"object"==typeof exports?module.exports=e():e()(i.lunr)}(this,function(){return function(i){if(void 0===i)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===i.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var e,r,n;i.fi=function(){this.pipeline.reset(),this.pipeline.add(i.fi.trimmer,i.fi.stopWordFilter,i.fi.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(i.fi.stemmer))},i.fi.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",i.fi.trimmer=i.trimmerSupport.generateTrimmer(i.fi.wordCharacters),i.Pipeline.registerFunction(i.fi.trimmer,"trimmer-fi"),i.fi.stemmer=(e=i.stemmerSupport.Among,r=i.stemmerSupport.SnowballProgram,n=new function(){var i,n,t,s,l=[new e("pa",-1,1),new e("sti",-1,2),new e("kaan",-1,1),new e("han",-1,1),new e("kin",-1,1),new e("hän",-1,1),new e("kään",-1,1),new e("ko",-1,1),new e("pä",-1,1),new e("kö",-1,1)],o=[new e("lla",-1,-1),new e("na",-1,-1),new e("ssa",-1,-1),new e("ta",-1,-1),new e("lta",3,-1),new e("sta",3,-1)],a=[new e("llä",-1,-1),new e("nä",-1,-1),new e("ssä",-1,-1),new e("tä",-1,-1),new e("ltä",3,-1),new e("stä",3,-1)],u=[new e("lle",-1,-1),new e("ine",-1,-1)],c=[new e("nsa",-1,3),new e("mme",-1,3),new e("nne",-1,3),new e("ni",-1,2),new e("si",-1,1),new e("an",-1,4),new e("en",-1,6),new e("än",-1,5),new e("nsä",-1,3)],m=[new e("aa",-1,-1),new e("ee",-1,-1),new e("ii",-1,-1),new e("oo",-1,-1),new e("uu",-1,-1),new e("ää",-1,-1),new e("öö",-1,-1)],w=[new e("a",-1,8),new e("lla",0,-1),new e("na",0,-1),new e("ssa",0,-1),new e("ta",0,-1),new e("lta",4,-1),new e("sta",4,-1),new e("tta",4,9),new e("lle",-1,-1),new e("ine",-1,-1),new e("ksi",-1,-1),new e("n",-1,7),new e("han",11,1),new e("den",11,-1,C),new e("seen",11,-1,v),new e("hen",11,2),new e("tten",11,-1,C),new e("hin",11,3),new e("siin",11,-1,C),new e("hon",11,4),new e("hän",11,5),new e("hön",11,6),new e("ä",-1,8),new e("llä",22,-1),new e("nä",22,-1),new e("ssä",22,-1),new e("tä",22,-1),new e("ltä",26,-1),new e("stä",26,-1),new e("ttä",26,9)],_=[new e("eja",-1,-1),new e("mma",-1,1),new e("imma",1,-1),new e("mpa",-1,1),new e("impa",3,-1),new e("mmi",-1,1),new e("immi",5,-1),new e("mpi",-1,1),new e("impi",7,-1),new e("ejä",-1,-1),new e("mmä",-1,1),new e("immä",10,-1),new e("mpä",-1,1),new e("impä",12,-1)],k=[new e("i",-1,-1),new e("j",-1,-1)],b=[new e("mma",-1,1),new e("imma",0,-1)],d=[17,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8],f=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,8,0,32],h=[17,65,16,0,0,0,0,0,0,0,0,0,0,0,0,0,8,0,32],p=[17,97,24,1,0,0,0,0,0,0,0,0,0,0,0,0,8,0,32],g=new r;function j(){for(var i;i=g.cursor,!g.in_grouping(f,97,246);){if(g.cursor=i,i>=g.limit)return!0;g.cursor++}for(g.cursor=i;!g.out_grouping(f,97,246);){if(g.cursor>=g.limit)return!0;g.cursor++}return!1}function q(){var i,e;if(g.cursor>=s)if(e=g.limit_backward,g.limit_backward=s,g.ket=g.cursor,i=g.find_among_b(l,10)){switch(g.bra=g.cursor,g.limit_backward=e,i){case 1:if(!g.in_grouping_b(p,97,246))return;break;case 2:if(!(t<=g.cursor))return}g.slice_del()}else g.limit_backward=e}function v(){return g.find_among_b(m,7)}function C(){return g.eq_s_b(1,"i")&&g.in_grouping_b(h,97,246)}this.setCurrent=function(i){g.setCurrent(i)},this.getCurrent=function(){return g.getCurrent()},this.stem=function(){var e,r=g.cursor;return s=g.limit,t=s,j()||(s=g.cursor,j()||(t=g.cursor)),i=!1,g.limit_backward=r,g.cursor=g.limit,q(),g.cursor=g.limit,function(){var i,e,r;if(g.cursor>=s)if(e=g.limit_backward,g.limit_backward=s,g.ket=g.cursor,i=g.find_among_b(c,9))switch(g.bra=g.cursor,g.limit_backward=e,i){case 1:r=g.limit-g.cursor,g.eq_s_b(1,"k")||(g.cursor=g.limit-r,g.slice_del());break;case 2:g.slice_del(),g.ket=g.cursor,g.eq_s_b(3,"kse")&&(g.bra=g.cursor,g.slice_from("ksi"));break;case 3:g.slice_del();break;case 4:g.find_among_b(o,6)&&g.slice_del();break;case 5:g.find_among_b(a,6)&&g.slice_del();break;case 6:g.find_among_b(u,2)&&g.slice_del()}else g.limit_backward=e}(),g.cursor=g.limit,function(){var e,r,n;if(g.cursor>=s)if(r=g.limit_backward,g.limit_backward=s,g.ket=g.cursor,e=g.find_among_b(w,30)){switch(g.bra=g.cursor,g.limit_backward=r,e){case 1:if(!g.eq_s_b(1,"a"))return;break;case 2:case 9:if(!g.eq_s_b(1,"e"))return;break;case 3:if(!g.eq_s_b(1,"i"))return;break;case 4:if(!g.eq_s_b(1,"o"))return;break;case 5:if(!g.eq_s_b(1,"ä"))return;break;case 6:if(!g.eq_s_b(1,"ö"))return;break;case 7:if(n=g.limit-g.cursor,!v()&&(g.cursor=g.limit-n,!g.eq_s_b(2,"ie"))){g.cursor=g.limit-n;break}if(g.cursor=g.limit-n,g.cursor<=g.limit_backward){g.cursor=g.limit-n;break}g.cursor--,g.bra=g.cursor;break;case 8:if(!g.in_grouping_b(f,97,246)||!g.out_grouping_b(f,97,246))return}g.slice_del(),i=!0}else g.limiLine truncated
+1
View File
@@ -0,0 +1 @@
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,s,i;e.fr=function(){this.pipeline.reset(),this.pipeline.add(e.fr.trimmer,e.fr.stopWordFilter,e.fr.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.fr.stemmer))},e.fr.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.fr.trimmer=e.trimmerSupport.generateTrimmer(e.fr.wordCharacters),e.Pipeline.registerFunction(e.fr.trimmer,"trimmer-fr"),e.fr.stemmer=(r=e.stemmerSupport.Among,s=e.stemmerSupport.SnowballProgram,i=new function(){var e,i,n,t=[new r("col",-1,-1),new r("par",-1,-1),new r("tap",-1,-1)],u=[new r("",-1,4),new r("I",0,1),new r("U",0,2),new r("Y",0,3)],o=[new r("iqU",-1,3),new r("abl",-1,3),new r("Ièr",-1,4),new r("ièr",-1,4),new r("eus",-1,2),new r("iv",-1,1)],c=[new r("ic",-1,2),new r("abil",-1,1),new r("iv",-1,3)],a=[new r("iqUe",-1,1),new r("atrice",-1,2),new r("ance",-1,1),new r("ence",-1,5),new r("logie",-1,3),new r("able",-1,1),new r("isme",-1,1),new r("euse",-1,11),new r("iste",-1,1),new r("ive",-1,8),new r("if",-1,8),new r("usion",-1,4),new r("ation",-1,2),new r("ution",-1,4),new r("ateur",-1,2),new r("iqUes",-1,1),new r("atrices",-1,2),new r("ances",-1,1),new r("ences",-1,5),new r("logies",-1,3),new r("ables",-1,1),new r("ismes",-1,1),new r("euses",-1,11),new r("istes",-1,1),new r("ives",-1,8),new r("ifs",-1,8),new r("usions",-1,4),new r("ations",-1,2),new r("utions",-1,4),new r("ateurs",-1,2),new r("ments",-1,15),new r("ements",30,6),new r("issements",31,12),new r("ités",-1,7),new r("ment",-1,15),new r("ement",34,6),new r("issement",35,12),new r("amment",34,13),new r("emment",34,14),new r("aux",-1,10),new r("eaux",39,9),new r("eux",-1,1),new r("ité",-1,7)],l=[new r("ira",-1,1),new r("ie",-1,1),new r("isse",-1,1),new r("issante",-1,1),new r("i",-1,1),new r("irai",4,1),new r("ir",-1,1),new r("iras",-1,1),new r("ies",-1,1),new r("îmes",-1,1),new r("isses",-1,1),new r("issantes",-1,1),new r("îtes",-1,1),new r("is",-1,1),new r("irais",13,1),new r("issais",13,1),new r("irions",-1,1),new r("issions",-1,1),new r("irons",-1,1),new r("issons",-1,1),new r("issants",-1,1),new r("it",-1,1),new r("irait",21,1),new r("issait",21,1),new r("issant",-1,1),new r("iraIent",-1,1),new r("issaIent",-1,1),new r("irent",-1,1),new r("issent",-1,1),new r("iront",-1,1),new r("ît",-1,1),new r("iriez",-1,1),new r("issiez",-1,1),new r("irez",-1,1),new r("issez",-1,1)],w=[new r("a",-1,3),new r("era",0,2),new r("asse",-1,3),new r("ante",-1,3),new r("ée",-1,2),new r("ai",-1,3),new r("erai",5,2),new r("er",-1,2),new r("as",-1,3),new r("eras",8,2),new r("âmes",-1,3),new r("asses",-1,3),new r("antes",-1,3),new r("âtes",-1,3),new r("ées",-1,2),new r("ais",-1,3),new r("erais",15,2),new r("ions",-1,1),new r("erions",17,2),new r("assions",17,3),new r("erons",-1,2),new r("ants",-1,3),new r("és",-1,2),new r("ait",-1,3),new r("erait",23,2),new r("ant",-1,3),new r("aIent",-1,3),new r("eraIent",26,2),new r("èrent",-1,2),new r("assent",-1,3),new r("eront",-1,2),new r("ât",-1,3),new r("ez",-1,2),new r("iez",32,2),new r("eriez",33,2),new r("assiez",33,3),new r("erez",32,2),new r("é",-1,2)],f=[new r("e",-1,3),new r("Ière",0,2),new r("ière",0,2),new r("ion",-1,1),new r("Ier",-1,2),new r("ier",-1,2),new r("ë",-1,4)],m=[new r("ell",-1,-1),new r("eill",-1,-1),new r("enn",-1,-1),new r("onn",-1,-1),new r("ett",-1,-1)],_=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,128,130,103,8,5],b=[1,65,20,0,0,0,0,0,0,0,0,0,0,0,0,0,128],d=new s;function k(e,r,s){return!(!d.eq_s(1,e)||(d.ket=d.cursor,!d.in_grouping(_,97,251)))&&(d.slice_from(r),d.cursor=s,!0)}function p(e,r,s){return!!d.eq_s(1,e)&&(d.ket=d.cursor,d.slice_from(r),d.cursor=s,!0)}function g(){for(;!d.in_grouping(_,97,251);){if(d.cursor>=d.limit)return!0;d.cursor++}for(;!d.out_grouping(_,97,251);){if(d.cursor>=d.limit)return!0;d.cursor++}return!1}function q(){return n<=d.cursor}function v(){return i<=d.cursor}function h(){return e<=d.cursor}function z(){if(!function(){var e,r;if(d.ket=d.cursor,e=d.find_among_b(a,43)){switch(d.bra=d.cursor,e){case 1:if(!h())return!1;d.slice_del();break;case 2:if(!h())return!1;d.slice_del(),d.ket=d.cursor,d.eq_s_b(2,"ic")&&(d.bra=d.cursor,h()?d.slice_del():d.slice_from("iqU"));break;case 3:if(!h())return!1;d.slice_from("log");break;case 4:if(!h())return!1;d.slice_from("u");break;case 5:if(!h())return!1;d.slice_from("ent");break;case 6:if(!q())return!1;if(d.slice_del(),d.ket=d.cursor,e=d.find_among_b(o,6))switch(d.bra=d.cursor,e){case 1:h()&&(d.slice_del(),d.ket=d.cursor,d.eq_s_Line truncated
+1
View File
@@ -0,0 +1 @@
!function(e,n){"function"==typeof define&&define.amd?define(n):"object"==typeof exports?module.exports=n():n()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var n,r,i;e.hu=function(){this.pipeline.reset(),this.pipeline.add(e.hu.trimmer,e.hu.stopWordFilter,e.hu.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.hu.stemmer))},e.hu.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.hu.trimmer=e.trimmerSupport.generateTrimmer(e.hu.wordCharacters),e.Pipeline.registerFunction(e.hu.trimmer,"trimmer-hu"),e.hu.stemmer=(n=e.stemmerSupport.Among,r=e.stemmerSupport.SnowballProgram,i=new function(){var e,i=[new n("cs",-1,-1),new n("dzs",-1,-1),new n("gy",-1,-1),new n("ly",-1,-1),new n("ny",-1,-1),new n("sz",-1,-1),new n("ty",-1,-1),new n("zs",-1,-1)],a=[new n("á",-1,1),new n("é",-1,2)],t=[new n("bb",-1,-1),new n("cc",-1,-1),new n("dd",-1,-1),new n("ff",-1,-1),new n("gg",-1,-1),new n("jj",-1,-1),new n("kk",-1,-1),new n("ll",-1,-1),new n("mm",-1,-1),new n("nn",-1,-1),new n("pp",-1,-1),new n("rr",-1,-1),new n("ccs",-1,-1),new n("ss",-1,-1),new n("zzs",-1,-1),new n("tt",-1,-1),new n("vv",-1,-1),new n("ggy",-1,-1),new n("lly",-1,-1),new n("nny",-1,-1),new n("tty",-1,-1),new n("ssz",-1,-1),new n("zz",-1,-1)],s=[new n("al",-1,1),new n("el",-1,2)],c=[new n("ba",-1,-1),new n("ra",-1,-1),new n("be",-1,-1),new n("re",-1,-1),new n("ig",-1,-1),new n("nak",-1,-1),new n("nek",-1,-1),new n("val",-1,-1),new n("vel",-1,-1),new n("ul",-1,-1),new n("nál",-1,-1),new n("nél",-1,-1),new n("ból",-1,-1),new n("ról",-1,-1),new n("tól",-1,-1),new n("bõl",-1,-1),new n("rõl",-1,-1),new n("tõl",-1,-1),new n("ül",-1,-1),new n("n",-1,-1),new n("an",19,-1),new n("ban",20,-1),new n("en",19,-1),new n("ben",22,-1),new n("képpen",22,-1),new n("on",19,-1),new n("ön",19,-1),new n("képp",-1,-1),new n("kor",-1,-1),new n("t",-1,-1),new n("at",29,-1),new n("et",29,-1),new n("ként",29,-1),new n("anként",32,-1),new n("enként",32,-1),new n("onként",32,-1),new n("ot",29,-1),new n("ért",29,-1),new n("öt",29,-1),new n("hez",-1,-1),new n("hoz",-1,-1),new n("höz",-1,-1),new n("vá",-1,-1),new n("vé",-1,-1)],w=[new n("án",-1,2),new n("én",-1,1),new n("ánként",-1,3)],o=[new n("stul",-1,2),new n("astul",0,1),new n("ástul",0,3),new n("stül",-1,2),new n("estül",3,1),new n("éstül",3,4)],l=[new n("á",-1,1),new n("é",-1,2)],u=[new n("k",-1,7),new n("ak",0,4),new n("ek",0,6),new n("ok",0,5),new n("ák",0,1),new n("ék",0,2),new n("ök",0,3)],m=[new n("éi",-1,7),new n("áéi",0,6),new n("ééi",0,5),new n("é",-1,9),new n("ké",3,4),new n("aké",4,1),new n("eké",4,1),new n("oké",4,1),new n("áké",4,3),new n("éké",4,2),new n("öké",4,1),new n("éé",3,8)],k=[new n("a",-1,18),new n("ja",0,17),new n("d",-1,16),new n("ad",2,13),new n("ed",2,13),new n("od",2,13),new n("ád",2,14),new n("éd",2,15),new n("öd",2,13),new n("e",-1,18),new n("je",9,17),new n("nk",-1,4),new n("unk",11,1),new n("ánk",11,2),new n("énk",11,3),new n("ünk",11,1),new n("uk",-1,8),new n("juk",16,7),new n("ájuk",17,5),new n("ük",-1,8),new n("jük",19,7),new n("éjük",20,6),new n("m",-1,12),new n("am",22,9),new n("em",22,9),new n("om",22,9),new n("ám",22,10),new n("ém",22,11),new n("o",-1,18),new n("á",-1,19),new n("é",-1,20)],f=[new n("id",-1,10),new n("aid",0,9),new n("jaid",1,6),new n("eid",0,9),new n("jeid",3,6),new n("áid",0,7),new n("éid",0,8),new n("i",-1,15),new n("ai",7,14),new n("jai",8,11),new n("ei",7,14),new n("jei",10,11),new n("ái",7,12),new n("éi",7,13),new n("itek",-1,24),new n("eitek",14,21),new n("jeitek",15,20),new n("éitek",14,23),new n("ik",-1,29),new n("aik",18,26),new n("jaik",19,25),new n("eik",18,26),new n("jeik",21,25),new n("áik",18,27),new n("éik",18,28),new n("ink",-1,20),new n("aink",25,17),new n("jaink",26,16),new n("eink",25,17),new n("jeink",28,16),new n("áink",25,18),new n("éink",25,19),new n("aitok",-1,21),new n("jaitok",32,20),new n("áitok",-1,22),new n("im",-1,5),new n("aim",35,4),new n("jaim",36,1),new n("eim",35,4),new n("jeim",38,1),new n("áim",35,2),new n("éim",35,3)],b=[17,65,16,0,0,0,0,0,0,0,0,0,0,0,0,0,1,17,52,14],d=new r;function g(){return e<=d.cursor}function h(){var e=d.limit-d.cursor;return!!d.find_among_b(t,23)&&(d.cursor=d.limit-e,!0)}function p(){if(d.cursor>d.limit_backward){d.cursor--,d.ket=d.cursor;var e=d.cursor-1;d.limit_backward<=e&&e<=d.limit&&(d.cursor=e,d.bra=e,d.slice_del())}}function _(){d.ket=d.cursor,d.find_among_b(c,44)&&(d.bra=d.cursor,g()&&(d.slice_del(),function(){var e;if(d.ket=d.cursor,(e=d.find_among_b(a,2))&&(d.bra=d.cursor,g()))switch(e){case 1:d.slice_from(Line truncated
+1
View File
@@ -0,0 +1 @@
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,i,n;e.it=function(){this.pipeline.reset(),this.pipeline.add(e.it.trimmer,e.it.stopWordFilter,e.it.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.it.stemmer))},e.it.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.it.trimmer=e.trimmerSupport.generateTrimmer(e.it.wordCharacters),e.Pipeline.registerFunction(e.it.trimmer,"trimmer-it"),e.it.stemmer=(r=e.stemmerSupport.Among,i=e.stemmerSupport.SnowballProgram,n=new function(){var e,n,o,t=[new r("",-1,7),new r("qu",0,6),new r("á",0,1),new r("é",0,2),new r("í",0,3),new r("ó",0,4),new r("ú",0,5)],s=[new r("",-1,3),new r("I",0,1),new r("U",0,2)],a=[new r("la",-1,-1),new r("cela",0,-1),new r("gliela",0,-1),new r("mela",0,-1),new r("tela",0,-1),new r("vela",0,-1),new r("le",-1,-1),new r("cele",6,-1),new r("gliele",6,-1),new r("mele",6,-1),new r("tele",6,-1),new r("vele",6,-1),new r("ne",-1,-1),new r("cene",12,-1),new r("gliene",12,-1),new r("mene",12,-1),new r("sene",12,-1),new r("tene",12,-1),new r("vene",12,-1),new r("ci",-1,-1),new r("li",-1,-1),new r("celi",20,-1),new r("glieli",20,-1),new r("meli",20,-1),new r("teli",20,-1),new r("veli",20,-1),new r("gli",20,-1),new r("mi",-1,-1),new r("si",-1,-1),new r("ti",-1,-1),new r("vi",-1,-1),new r("lo",-1,-1),new r("celo",31,-1),new r("glielo",31,-1),new r("melo",31,-1),new r("telo",31,-1),new r("velo",31,-1)],u=[new r("ando",-1,1),new r("endo",-1,1),new r("ar",-1,2),new r("er",-1,2),new r("ir",-1,2)],c=[new r("ic",-1,-1),new r("abil",-1,-1),new r("os",-1,-1),new r("iv",-1,1)],w=[new r("ic",-1,1),new r("abil",-1,1),new r("iv",-1,1)],l=[new r("ica",-1,1),new r("logia",-1,3),new r("osa",-1,1),new r("ista",-1,1),new r("iva",-1,9),new r("anza",-1,1),new r("enza",-1,5),new r("ice",-1,1),new r("atrice",7,1),new r("iche",-1,1),new r("logie",-1,3),new r("abile",-1,1),new r("ibile",-1,1),new r("usione",-1,4),new r("azione",-1,2),new r("uzione",-1,4),new r("atore",-1,2),new r("ose",-1,1),new r("ante",-1,1),new r("mente",-1,1),new r("amente",19,7),new r("iste",-1,1),new r("ive",-1,9),new r("anze",-1,1),new r("enze",-1,5),new r("ici",-1,1),new r("atrici",25,1),new r("ichi",-1,1),new r("abili",-1,1),new r("ibili",-1,1),new r("ismi",-1,1),new r("usioni",-1,4),new r("azioni",-1,2),new r("uzioni",-1,4),new r("atori",-1,2),new r("osi",-1,1),new r("anti",-1,1),new r("amenti",-1,6),new r("imenti",-1,6),new r("isti",-1,1),new r("ivi",-1,9),new r("ico",-1,1),new r("ismo",-1,1),new r("oso",-1,1),new r("amento",-1,6),new r("imento",-1,6),new r("ivo",-1,9),new r("ità",-1,8),new r("istà",-1,1),new r("istè",-1,1),new r("istì",-1,1)],m=[new r("isca",-1,1),new r("enda",-1,1),new r("ata",-1,1),new r("ita",-1,1),new r("uta",-1,1),new r("ava",-1,1),new r("eva",-1,1),new r("iva",-1,1),new r("erebbe",-1,1),new r("irebbe",-1,1),new r("isce",-1,1),new r("ende",-1,1),new r("are",-1,1),new r("ere",-1,1),new r("ire",-1,1),new r("asse",-1,1),new r("ate",-1,1),new r("avate",16,1),new r("evate",16,1),new r("ivate",16,1),new r("ete",-1,1),new r("erete",20,1),new r("irete",20,1),new r("ite",-1,1),new r("ereste",-1,1),new r("ireste",-1,1),new r("ute",-1,1),new r("erai",-1,1),new r("irai",-1,1),new r("isci",-1,1),new r("endi",-1,1),new r("erei",-1,1),new r("irei",-1,1),new r("assi",-1,1),new r("ati",-1,1),new r("iti",-1,1),new r("eresti",-1,1),new r("iresti",-1,1),new r("uti",-1,1),new r("avi",-1,1),new r("evi",-1,1),new r("ivi",-1,1),new r("isco",-1,1),new r("ando",-1,1),new r("endo",-1,1),new r("Yamo",-1,1),new r("iamo",-1,1),new r("avamo",-1,1),new r("evamo",-1,1),new r("ivamo",-1,1),new r("eremo",-1,1),new r("iremo",-1,1),new r("assimo",-1,1),new r("ammo",-1,1),new r("emmo",-1,1),new r("eremmo",54,1),new r("iremmo",54,1),new r("immo",-1,1),new r("ano",-1,1),new r("iscano",58,1),new r("avano",58,1),new r("evano",58,1),new r("ivano",58,1),new r("eranno",-1,1),new r("iranno",-1,1),new r("ono",-1,1),new r("iscono",65,1),new r("arono",65,1),new r("erono",65,1),new r("irono",65,1),new r("erebbero",-1,1),new r("irebbero",-1,1),new r("assero",-1,1),new r("essero",-1,1),new r("issero",-1,1),new r("ato",-1,1),new r("ito",-1,1),new r("uto",-1,1),new r("avo",-1,1),new r("evo",-1,1),new r("ivo",-1,1),new r("ar",-1,1),new r("ir",-1,1),new r("erà",-1,1),new r("irà",-1,1),new r("erò",-1,1),new r("irò",-1,1)],f=[17,65,16,0,0,0,0,0,0,0,0,0,0,0,0,128,128,8,2,1],v=[17,65,0,0,0,0,0,0,0,0,0,0,0,0,0,128,128,8,2],b=[17],d=new i;function _(e,r,i){return!(!d.eq_s(1,e)||(d.ket=d.cursor,!dLine truncated
+1
View File
@@ -0,0 +1 @@
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r="2"==e.version[0];e.jp=function(){this.pipeline.reset(),this.pipeline.add(e.jp.stopWordFilter,e.jp.stemmer),r?this.tokenizer=e.jp.tokenizer:(e.tokenizer&&(e.tokenizer=e.jp.tokenizer),this.tokenizerFn&&(this.tokenizerFn=e.jp.tokenizer))};var t=new e.TinySegmenter;e.jp.tokenizer=function(n){if(!arguments.length||null==n||null==n)return[];if(Array.isArray(n))return n.map(function(t){return r?new e.Token(t.toLowerCase()):t.toLowerCase()});for(var i=n.toString().toLowerCase().replace(/^\s+/,""),o=i.length-1;o>=0;o--)if(/\S/.test(i.charAt(o))){i=i.substring(0,o+1);break}return t.segment(i).filter(function(e){return!!e}).map(function(t){return r?new e.Token(t):t})},e.jp.stemmer=function(e){return e},e.Pipeline.registerFunction(e.jp.stemmer,"stemmer-jp"),e.jp.wordCharacters="一二三四五六七八九十百千万億兆一-龠々〆ヵヶぁ-んァ-ヴーア-ン゙a-zA-Za-zA-Z0-90-9",e.jp.stopWordFilter=function(t){if(-1===e.jp.stopWordFilter.stopWords.indexOf(r?t.toString():t))return t},e.jp.stopWordFilter=e.generateStopWordFilter("これ それ あれ この その あの ここ そこ あそこ こちら どこ だれ なに なん 何 私 貴方 貴方方 我々 私達 あの人 あのかた 彼女 彼 です あります おります います は が の に を で え から まで より も どの と し それで しかし".split(" ")),e.Pipeline.registerFunction(e.jp.stopWordFilter,"stopWordFilter-jp")}});
@@ -0,0 +1 @@
!function(e,i){"function"==typeof define&&define.amd?define(i):"object"==typeof exports?module.exports=i():i()(e.lunr)}(this,function(){return function(e){e.multiLanguage=function(){for(var i=Array.prototype.slice.call(arguments),t=i.join("-"),r="",n=[],s=[],p=0;p<i.length;++p)"en"==i[p]?(r+="\\w",n.unshift(e.stopWordFilter),n.push(e.stemmer),s.push(e.stemmer)):(r+=e[i[p]].wordCharacters,n.unshift(e[i[p]].stopWordFilter),n.push(e[i[p]].stemmer),s.push(e[i[p]].stemmer));var o=e.trimmerSupport.generateTrimmer(r);return e.Pipeline.registerFunction(o,"lunr-multi-trimmer-"+t),n.unshift(o),function(){this.pipeline.reset(),this.pipeline.add.apply(this.pipeline,n),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add.apply(this.searchPipeline,s))}}}});
+1
View File
@@ -0,0 +1 @@
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,n,i;e.no=function(){this.pipeline.reset(),this.pipeline.add(e.no.trimmer,e.no.stopWordFilter,e.no.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.no.stemmer))},e.no.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.no.trimmer=e.trimmerSupport.generateTrimmer(e.no.wordCharacters),e.Pipeline.registerFunction(e.no.trimmer,"trimmer-no"),e.no.stemmer=(r=e.stemmerSupport.Among,n=e.stemmerSupport.SnowballProgram,i=new function(){var e,i,t=[new r("a",-1,1),new r("e",-1,1),new r("ede",1,1),new r("ande",1,1),new r("ende",1,1),new r("ane",1,1),new r("ene",1,1),new r("hetene",6,1),new r("erte",1,3),new r("en",-1,1),new r("heten",9,1),new r("ar",-1,1),new r("er",-1,1),new r("heter",12,1),new r("s",-1,2),new r("as",14,1),new r("es",14,1),new r("edes",16,1),new r("endes",16,1),new r("enes",16,1),new r("hetenes",19,1),new r("ens",14,1),new r("hetens",21,1),new r("ers",14,1),new r("ets",14,1),new r("et",-1,1),new r("het",25,1),new r("ert",-1,3),new r("ast",-1,1)],o=[new r("dt",-1,-1),new r("vt",-1,-1)],s=[new r("leg",-1,1),new r("eleg",0,1),new r("ig",-1,1),new r("eig",2,1),new r("lig",2,1),new r("elig",4,1),new r("els",-1,1),new r("lov",-1,1),new r("elov",7,1),new r("slov",7,1),new r("hetslov",9,1)],a=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,48,0,128],m=[119,125,149,1],l=new n;this.setCurrent=function(e){l.setCurrent(e)},this.getCurrent=function(){return l.getCurrent()},this.stem=function(){var r,n,u,d,c=l.cursor;return function(){var r,n=l.cursor+3;if(i=l.limit,0<=n||n<=l.limit){for(e=n;;){if(r=l.cursor,l.in_grouping(a,97,248)){l.cursor=r;break}if(r>=l.limit)return;l.cursor=r+1}for(;!l.out_grouping(a,97,248);){if(l.cursor>=l.limit)return;l.cursor++}(i=l.cursor)<e&&(i=e)}}(),l.limit_backward=c,l.cursor=l.limit,function(){var e,r,n;if(l.cursor>=i&&(r=l.limit_backward,l.limit_backward=i,l.ket=l.cursor,e=l.find_among_b(t,29),l.limit_backward=r,e))switch(l.bra=l.cursor,e){case 1:l.slice_del();break;case 2:n=l.limit-l.cursor,l.in_grouping_b(m,98,122)?l.slice_del():(l.cursor=l.limit-n,l.eq_s_b(1,"k")&&l.out_grouping_b(a,97,248)&&l.slice_del());break;case 3:l.slice_from("er")}}(),l.cursor=l.limit,n=l.limit-l.cursor,l.cursor>=i&&(r=l.limit_backward,l.limit_backward=i,l.ket=l.cursor,l.find_among_b(o,2)?(l.bra=l.cursor,l.limit_backward=r,l.cursor=l.limit-n,l.cursor>l.limit_backward&&(l.cursor--,l.bra=l.cursor,l.slice_del())):l.limit_backward=r),l.cursor=l.limit,l.cursor>=i&&(d=l.limit_backward,l.limit_backward=i,l.ket=l.cursor,(u=l.find_among_b(s,11))?(l.bra=l.cursor,l.limit_backward=d,1==u&&l.slice_del()):l.limit_backward=d),!0}},function(e){return"function"==typeof e.update?e.update(function(e){return i.setCurrent(e),i.stem(),i.getCurrent()}):(i.setCurrent(e),i.stem(),i.getCurrent())}),e.Pipeline.registerFunction(e.no.stemmer,"stemmer-no"),e.no.stopWordFilter=e.generateStopWordFilter("alle at av bare begge ble blei bli blir blitt både båe da de deg dei deim deira deires dem den denne der dere deres det dette di din disse ditt du dykk dykkar då eg ein eit eitt eller elles en enn er et ett etter for fordi fra før ha hadde han hans har hennar henne hennes her hjå ho hoe honom hoss hossen hun hva hvem hver hvilke hvilken hvis hvor hvordan hvorfor i ikke ikkje ikkje ingen ingi inkje inn inni ja jeg kan kom korleis korso kun kunne kva kvar kvarhelst kven kvi kvifor man mange me med medan meg meget mellom men mi min mine mitt mot mykje ned no noe noen noka noko nokon nokor nokre nå når og også om opp oss over på samme seg selv si si sia sidan siden sin sine sitt sjøl skal skulle slik so som som somme somt så sånn til um upp ut uten var vart varte ved vere verte vi vil ville vore vors vort vår være være vært å".split(" ")),e.Pipeline.registerFunction(e.no.stopWordFilter,"stopWordFilter-no")}});
+1
View File
@@ -0,0 +1 @@
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,s,n;e.pt=function(){this.pipeline.reset(),this.pipeline.add(e.pt.trimmer,e.pt.stopWordFilter,e.pt.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.pt.stemmer))},e.pt.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.pt.trimmer=e.trimmerSupport.generateTrimmer(e.pt.wordCharacters),e.Pipeline.registerFunction(e.pt.trimmer,"trimmer-pt"),e.pt.stemmer=(r=e.stemmerSupport.Among,s=e.stemmerSupport.SnowballProgram,n=new function(){var e,n,i,o=[new r("",-1,3),new r("ã",0,1),new r("õ",0,2)],a=[new r("",-1,3),new r("a~",0,1),new r("o~",0,2)],t=[new r("ic",-1,-1),new r("ad",-1,-1),new r("os",-1,-1),new r("iv",-1,1)],u=[new r("ante",-1,1),new r("avel",-1,1),new r("ível",-1,1)],w=[new r("ic",-1,1),new r("abil",-1,1),new r("iv",-1,1)],m=[new r("ica",-1,1),new r("ância",-1,1),new r("ência",-1,4),new r("ira",-1,9),new r("adora",-1,1),new r("osa",-1,1),new r("ista",-1,1),new r("iva",-1,8),new r("eza",-1,1),new r("logía",-1,2),new r("idade",-1,7),new r("ante",-1,1),new r("mente",-1,6),new r("amente",12,5),new r("ável",-1,1),new r("ível",-1,1),new r("ución",-1,3),new r("ico",-1,1),new r("ismo",-1,1),new r("oso",-1,1),new r("amento",-1,1),new r("imento",-1,1),new r("ivo",-1,8),new r("aça~o",-1,1),new r("ador",-1,1),new r("icas",-1,1),new r("ências",-1,4),new r("iras",-1,9),new r("adoras",-1,1),new r("osas",-1,1),new r("istas",-1,1),new r("ivas",-1,8),new r("ezas",-1,1),new r("logías",-1,2),new r("idades",-1,7),new r("uciones",-1,3),new r("adores",-1,1),new r("antes",-1,1),new r("aço~es",-1,1),new r("icos",-1,1),new r("ismos",-1,1),new r("osos",-1,1),new r("amentos",-1,1),new r("imentos",-1,1),new r("ivos",-1,8)],c=[new r("ada",-1,1),new r("ida",-1,1),new r("ia",-1,1),new r("aria",2,1),new r("eria",2,1),new r("iria",2,1),new r("ara",-1,1),new r("era",-1,1),new r("ira",-1,1),new r("ava",-1,1),new r("asse",-1,1),new r("esse",-1,1),new r("isse",-1,1),new r("aste",-1,1),new r("este",-1,1),new r("iste",-1,1),new r("ei",-1,1),new r("arei",16,1),new r("erei",16,1),new r("irei",16,1),new r("am",-1,1),new r("iam",20,1),new r("ariam",21,1),new r("eriam",21,1),new r("iriam",21,1),new r("aram",20,1),new r("eram",20,1),new r("iram",20,1),new r("avam",20,1),new r("em",-1,1),new r("arem",29,1),new r("erem",29,1),new r("irem",29,1),new r("assem",29,1),new r("essem",29,1),new r("issem",29,1),new r("ado",-1,1),new r("ido",-1,1),new r("ando",-1,1),new r("endo",-1,1),new r("indo",-1,1),new r("ara~o",-1,1),new r("era~o",-1,1),new r("ira~o",-1,1),new r("ar",-1,1),new r("er",-1,1),new r("ir",-1,1),new r("as",-1,1),new r("adas",47,1),new r("idas",47,1),new r("ias",47,1),new r("arias",50,1),new r("erias",50,1),new r("irias",50,1),new r("aras",47,1),new r("eras",47,1),new r("iras",47,1),new r("avas",47,1),new r("es",-1,1),new r("ardes",58,1),new r("erdes",58,1),new r("irdes",58,1),new r("ares",58,1),new r("eres",58,1),new r("ires",58,1),new r("asses",58,1),new r("esses",58,1),new r("isses",58,1),new r("astes",58,1),new r("estes",58,1),new r("istes",58,1),new r("is",-1,1),new r("ais",71,1),new r("eis",71,1),new r("areis",73,1),new r("ereis",73,1),new r("ireis",73,1),new r("áreis",73,1),new r("éreis",73,1),new r("íreis",73,1),new r("ásseis",73,1),new r("ésseis",73,1),new r("ísseis",73,1),new r("áveis",73,1),new r("íeis",73,1),new r("aríeis",84,1),new r("eríeis",84,1),new r("iríeis",84,1),new r("ados",-1,1),new r("idos",-1,1),new r("amos",-1,1),new r("áramos",90,1),new r("éramos",90,1),new r("íramos",90,1),new r("ávamos",90,1),new r("íamos",90,1),new r("aríamos",95,1),new r("eríamos",95,1),new r("iríamos",95,1),new r("emos",-1,1),new r("aremos",99,1),new r("eremos",99,1),new r("iremos",99,1),new r("ássemos",99,1),new r("êssemos",99,1),new r("íssemos",99,1),new r("imos",-1,1),new r("armos",-1,1),new r("ermos",-1,1),new r("irmos",-1,1),new r("ámos",-1,1),new r("arás",-1,1),new r("erás",-1,1),new r("irás",-1,1),new r("eu",-1,1),new r("iu",-1,1),new r("ou",-1,1),new r("ará",-1,1),new r("erá",-1,1),new r("irá",-1,1)],l=[new r("a",-1,1),new r("i",-1,1),new r("o",-1,1),new r("os",-1,1),new r("á",-1,1),new r("í",-1,1),new r("ó",-1,1)],f=[new r("e",-1,1),new r("ç",-1,2),new r("é",-1,1),new r("ê",-1,1)],d=[17,65,16,0,0,0,0,0,0,0,0,0,0,0,0,0,3,19,12,2],v=new s;function p(){if(v.out_grouping(d,97,250)){for(;!v.in_grouping(d,97,250);){if(v.cursor>=v.limit)return!0;v.cursor++}return!1}return!0}function _(){var e,r,s=v.cursor;if(v.in_groupLine truncated
+1
View File
@@ -0,0 +1 @@
!function(e,i){"function"==typeof define&&define.amd?define(i):"object"==typeof exports?module.exports=i():i()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var i,r,n;e.ro=function(){this.pipeline.reset(),this.pipeline.add(e.ro.trimmer,e.ro.stopWordFilter,e.ro.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.ro.stemmer))},e.ro.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.ro.trimmer=e.trimmerSupport.generateTrimmer(e.ro.wordCharacters),e.Pipeline.registerFunction(e.ro.trimmer,"trimmer-ro"),e.ro.stemmer=(i=e.stemmerSupport.Among,r=e.stemmerSupport.SnowballProgram,n=new function(){var e,n,t,a,o=[new i("",-1,3),new i("I",0,1),new i("U",0,2)],s=[new i("ea",-1,3),new i("aţia",-1,7),new i("aua",-1,2),new i("iua",-1,4),new i("aţie",-1,7),new i("ele",-1,3),new i("ile",-1,5),new i("iile",6,4),new i("iei",-1,4),new i("atei",-1,6),new i("ii",-1,4),new i("ului",-1,1),new i("ul",-1,1),new i("elor",-1,3),new i("ilor",-1,4),new i("iilor",14,4)],c=[new i("icala",-1,4),new i("iciva",-1,4),new i("ativa",-1,5),new i("itiva",-1,6),new i("icale",-1,4),new i("aţiune",-1,5),new i("iţiune",-1,6),new i("atoare",-1,5),new i("itoare",-1,6),new i("ătoare",-1,5),new i("icitate",-1,4),new i("abilitate",-1,1),new i("ibilitate",-1,2),new i("ivitate",-1,3),new i("icive",-1,4),new i("ative",-1,5),new i("itive",-1,6),new i("icali",-1,4),new i("atori",-1,5),new i("icatori",18,4),new i("itori",-1,6),new i("ători",-1,5),new i("icitati",-1,4),new i("abilitati",-1,1),new i("ivitati",-1,3),new i("icivi",-1,4),new i("ativi",-1,5),new i("itivi",-1,6),new i("icităi",-1,4),new i("abilităi",-1,1),new i("ivităi",-1,3),new i("icităţi",-1,4),new i("abilităţi",-1,1),new i("ivităţi",-1,3),new i("ical",-1,4),new i("ator",-1,5),new i("icator",35,4),new i("itor",-1,6),new i("ător",-1,5),new i("iciv",-1,4),new i("ativ",-1,5),new i("itiv",-1,6),new i("icală",-1,4),new i("icivă",-1,4),new i("ativă",-1,5),new i("itivă",-1,6)],u=[new i("ica",-1,1),new i("abila",-1,1),new i("ibila",-1,1),new i("oasa",-1,1),new i("ata",-1,1),new i("ita",-1,1),new i("anta",-1,1),new i("ista",-1,3),new i("uta",-1,1),new i("iva",-1,1),new i("ic",-1,1),new i("ice",-1,1),new i("abile",-1,1),new i("ibile",-1,1),new i("isme",-1,3),new i("iune",-1,2),new i("oase",-1,1),new i("ate",-1,1),new i("itate",17,1),new i("ite",-1,1),new i("ante",-1,1),new i("iste",-1,3),new i("ute",-1,1),new i("ive",-1,1),new i("ici",-1,1),new i("abili",-1,1),new i("ibili",-1,1),new i("iuni",-1,2),new i("atori",-1,1),new i("osi",-1,1),new i("ati",-1,1),new i("itati",30,1),new i("iti",-1,1),new i("anti",-1,1),new i("isti",-1,3),new i("uti",-1,1),new i("işti",-1,3),new i("ivi",-1,1),new i("ităi",-1,1),new i("oşi",-1,1),new i("ităţi",-1,1),new i("abil",-1,1),new i("ibil",-1,1),new i("ism",-1,3),new i("ator",-1,1),new i("os",-1,1),new i("at",-1,1),new i("it",-1,1),new i("ant",-1,1),new i("ist",-1,3),new i("ut",-1,1),new i("iv",-1,1),new i("ică",-1,1),new i("abilă",-1,1),new i("ibilă",-1,1),new i("oasă",-1,1),new i("ată",-1,1),new i("ită",-1,1),new i("antă",-1,1),new i("istă",-1,3),new i("ută",-1,1),new i("ivă",-1,1)],w=[new i("ea",-1,1),new i("ia",-1,1),new i("esc",-1,1),new i("ăsc",-1,1),new i("ind",-1,1),new i("ând",-1,1),new i("are",-1,1),new i("ere",-1,1),new i("ire",-1,1),new i("âre",-1,1),new i("se",-1,2),new i("ase",10,1),new i("sese",10,2),new i("ise",10,1),new i("use",10,1),new i("âse",10,1),new i("eşte",-1,1),new i("ăşte",-1,1),new i("eze",-1,1),new i("ai",-1,1),new i("eai",19,1),new i("iai",19,1),new i("sei",-1,2),new i("eşti",-1,1),new i("ăşti",-1,1),new i("ui",-1,1),new i("ezi",-1,1),new i("âi",-1,1),new i("aşi",-1,1),new i("seşi",-1,2),new i("aseşi",29,1),new i("seseşi",29,2),new i("iseşi",29,1),new i("useşi",29,1),new i("âseşi",29,1),new i("işi",-1,1),new i("uşi",-1,1),new i("âşi",-1,1),new i("aţi",-1,2),new i("eaţi",38,1),new i("iaţi",38,1),new i("eţi",-1,2),new i("iţi",-1,2),new i("âţi",-1,2),new i("arăţi",-1,1),new i("serăţi",-1,2),new i("aserăţi",45,1),new i("seserăţi",45,2),new i("iserăţi",45,1),new i("userăţi",45,1),new i("âserăţi",45,1),new i("irăţi",-1,1),new i("urăţi",-1,1),new i("ârăţi",-1,1),new i("am",-1,1),new i("eam",54,1),new i("iam",54,1),new i("em",-1,2),new i("asem",57,1),new i("sesem",57,2),new i("isem",57,1),new i("usem",57,1),new i("âsem",57,1),new i("im",-1,2),new i("âm",-1,2),new i("ăm",-1,2),new i("arăm",65,1),new i("serăm",65,2),new i("aserăm",67,1),new i("seserăm",67,2),new i("iserăm",67,1),new i("userăm",67,1),new i("âserăm",67,1),new i("irăm",65,1),newLine truncated
+1
View File
@@ -0,0 +1 @@
!function(e,n){"function"==typeof define&&define.amd?define(n):"object"==typeof exports?module.exports=n():n()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var n,r,t;e.ru=function(){this.pipeline.reset(),this.pipeline.add(e.ru.trimmer,e.ru.stopWordFilter,e.ru.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.ru.stemmer))},e.ru.wordCharacters="Ѐ-҄҇-ԯᴫᵸⷠ-ⷿꙀ-ꚟ︮︯",e.ru.trimmer=e.trimmerSupport.generateTrimmer(e.ru.wordCharacters),e.Pipeline.registerFunction(e.ru.trimmer,"trimmer-ru"),e.ru.stemmer=(n=e.stemmerSupport.Among,r=e.stemmerSupport.SnowballProgram,t=new function(){var e,t,w=[new n("в",-1,1),new n("ив",0,2),new n("ыв",0,2),new n("вши",-1,1),new n("ивши",3,2),new n("ывши",3,2),new n("вшись",-1,1),new n("ившись",6,2),new n("ывшись",6,2)],i=[new n("ее",-1,1),new n("ие",-1,1),new n("ое",-1,1),new n("ые",-1,1),new n("ими",-1,1),new n("ыми",-1,1),new n("ей",-1,1),new n("ий",-1,1),new n("ой",-1,1),new n("ый",-1,1),new n("ем",-1,1),new n("им",-1,1),new n("ом",-1,1),new n("ым",-1,1),new n("его",-1,1),new n("ого",-1,1),new n("ему",-1,1),new n("ому",-1,1),new n("их",-1,1),new n("ых",-1,1),new n("ею",-1,1),new n("ою",-1,1),new n("ую",-1,1),new n("юю",-1,1),new n("ая",-1,1),new n("яя",-1,1)],u=[new n("ем",-1,1),new n("нн",-1,1),new n("вш",-1,1),new n("ивш",2,2),new n("ывш",2,2),new n("щ",-1,1),new n("ющ",5,1),new n("ующ",6,2)],s=[new n("сь",-1,1),new n("ся",-1,1)],o=[new n("ла",-1,1),new n("ила",0,2),new n("ыла",0,2),new n("на",-1,1),new n("ена",3,2),new n("ете",-1,1),new n("ите",-1,2),new n("йте",-1,1),new n("ейте",7,2),new n("уйте",7,2),new n("ли",-1,1),new n("или",10,2),new n("ыли",10,2),new n("й",-1,1),new n("ей",13,2),new n("уй",13,2),new n("л",-1,1),new n("ил",16,2),new n("ыл",16,2),new n("ем",-1,1),new n("им",-1,2),new n("ым",-1,2),new n("н",-1,1),new n("ен",22,2),new n("ло",-1,1),new n("ило",24,2),new n("ыло",24,2),new n("но",-1,1),new n("ено",27,2),new n("нно",27,1),new n("ет",-1,1),new n("ует",30,2),new n("ит",-1,2),new n("ыт",-1,2),new n("ют",-1,1),new n("уют",34,2),new n("ят",-1,2),new n("ны",-1,1),new n("ены",37,2),new n("ть",-1,1),new n("ить",39,2),new n("ыть",39,2),new n("ешь",-1,1),new n("ишь",-1,2),new n("ю",-1,2),new n("ую",44,2)],c=[new n("а",-1,1),new n("ев",-1,1),new n("ов",-1,1),new n("е",-1,1),new n("ие",3,1),new n("ье",3,1),new n("и",-1,1),new n("еи",6,1),new n("ии",6,1),new n("ами",6,1),new n("ями",6,1),new n("иями",10,1),new n("й",-1,1),new n("ей",12,1),new n("ией",13,1),new n("ий",12,1),new n("ой",12,1),new n("ам",-1,1),new n("ем",-1,1),new n("ием",18,1),new n("ом",-1,1),new n("ям",-1,1),new n("иям",21,1),new n("о",-1,1),new n("у",-1,1),new n("ах",-1,1),new n("ях",-1,1),new n("иях",26,1),new n("ы",-1,1),new n("ь",-1,1),new n("ю",-1,1),new n("ию",30,1),new n("ью",30,1),new n("я",-1,1),new n("ия",33,1),new n("ья",33,1)],m=[new n("ост",-1,1),new n("ость",-1,1)],l=[new n("ейше",-1,1),new n("н",-1,2),new n("ейш",-1,1),new n("ь",-1,3)],f=[33,65,8,232],a=new r;function p(){for(;!a.in_grouping(f,1072,1103);){if(a.cursor>=a.limit)return!1;a.cursor++}return!0}function d(){for(;!a.out_grouping(f,1072,1103);){if(a.cursor>=a.limit)return!1;a.cursor++}return!0}function _(e,n){var r,t;if(a.ket=a.cursor,r=a.find_among_b(e,n)){switch(a.bra=a.cursor,r){case 1:if(t=a.limit-a.cursor,!a.eq_s_b(1,"а")&&(a.cursor=a.limit-t,!a.eq_s_b(1,"я")))return!1;case 2:a.slice_del()}return!0}return!1}function b(e,n){var r;return a.ket=a.cursor,!!(r=a.find_among_b(e,n))&&(a.bra=a.cursor,1==r&&a.slice_del(),!0)}function h(){return!!b(i,26)&&(_(u,8),!0)}function g(){var n;a.ket=a.cursor,(n=a.find_among_b(m,2))&&(a.bra=a.cursor,e<=a.cursor&&1==n&&a.slice_del())}this.setCurrent=function(e){a.setCurrent(e)},this.getCurrent=function(){return a.getCurrent()},this.stem=function(){return t=a.limit,e=t,p()&&(t=a.cursor,d()&&p()&&d()&&(e=a.cursor)),a.cursor=a.limit,!(a.cursor<t)&&(a.limit_backward=t,_(w,9)||(a.cursor=a.limit,b(s,2)||(a.cursor=a.limit),h()||(a.cursor=a.limit,_(o,46)||(a.cursor=a.limit,b(c,36)))),a.cursor=a.limit,a.ket=a.cursor,a.eq_s_b(1,"и")?(a.bra=a.cursor,a.slice_del()):a.cursor=a.limit,g(),a.cursor=a.limit,function(){var e;if(a.ket=a.cursor,e=a.find_among_b(l,4))switch(a.bra=a.cursor,e){case 1:if(a.slice_del(),a.ket=a.cursor,!a.eq_s_b(1,"н"))break;a.bra=a.cursor;case 2:if(!a.eq_s_b(1,"н"))break;case 3:a.slice_del()}}(),!0)}},function(e){return"function"==typeof e.update?e.update(function(e){return t.setCLine truncated
@@ -0,0 +1 @@
!function(r,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():t()(r.lunr)}(this,function(){return function(r){r.stemmerSupport={Among:function(r,t,i,s){if(this.toCharArray=function(r){for(var t=r.length,i=new Array(t),s=0;s<t;s++)i[s]=r.charCodeAt(s);return i},!r&&""!=r||!t&&0!=t||!i)throw"Bad Among initialisation: s:"+r+", substring_i: "+t+", result: "+i;this.s_size=r.length,this.s=this.toCharArray(r),this.substring_i=t,this.result=i,this.method=s},SnowballProgram:function(){var r;return{bra:0,ket:0,limit:0,cursor:0,limit_backward:0,setCurrent:function(t){r=t,this.cursor=0,this.limit=t.length,this.limit_backward=0,this.bra=this.cursor,this.ket=this.limit},getCurrent:function(){var t=r;return r=null,t},in_grouping:function(t,i,s){if(this.cursor<this.limit){var e=r.charCodeAt(this.cursor);if(e<=s&&e>=i&&t[(e-=i)>>3]&1<<(7&e))return this.cursor++,!0}return!1},in_grouping_b:function(t,i,s){if(this.cursor>this.limit_backward){var e=r.charCodeAt(this.cursor-1);if(e<=s&&e>=i&&t[(e-=i)>>3]&1<<(7&e))return this.cursor--,!0}return!1},out_grouping:function(t,i,s){if(this.cursor<this.limit){var e=r.charCodeAt(this.cursor);if(e>s||e<i)return this.cursor++,!0;if(!(t[(e-=i)>>3]&1<<(7&e)))return this.cursor++,!0}return!1},out_grouping_b:function(t,i,s){if(this.cursor>this.limit_backward){var e=r.charCodeAt(this.cursor-1);if(e>s||e<i)return this.cursor--,!0;if(!(t[(e-=i)>>3]&1<<(7&e)))return this.cursor--,!0}return!1},eq_s:function(t,i){if(this.limit-this.cursor<t)return!1;for(var s=0;s<t;s++)if(r.charCodeAt(this.cursor+s)!=i.charCodeAt(s))return!1;return this.cursor+=t,!0},eq_s_b:function(t,i){if(this.cursor-this.limit_backward<t)return!1;for(var s=0;s<t;s++)if(r.charCodeAt(this.cursor-t+s)!=i.charCodeAt(s))return!1;return this.cursor-=t,!0},find_among:function(t,i){for(var s=0,e=i,n=this.cursor,u=this.limit,o=0,h=0,c=!1;;){for(var a=s+(e-s>>1),f=0,l=o<h?o:h,_=t[a],m=l;m<_.s_size;m++){if(n+l==u){f=-1;break}if(f=r.charCodeAt(n+l)-_.s[m])break;l++}if(f<0?(e=a,h=l):(s=a,o=l),e-s<=1){if(s>0||e==s||c)break;c=!0}}for(;;){if(o>=(_=t[s]).s_size){if(this.cursor=n+_.s_size,!_.method)return _.result;var b=_.method();if(this.cursor=n+_.s_size,b)return _.result}if((s=_.substring_i)<0)return 0}},find_among_b:function(t,i){for(var s=0,e=i,n=this.cursor,u=this.limit_backward,o=0,h=0,c=!1;;){for(var a=s+(e-s>>1),f=0,l=o<h?o:h,_=(m=t[a]).s_size-1-l;_>=0;_--){if(n-l==u){f=-1;break}if(f=r.charCodeAt(n-1-l)-m.s[_])break;l++}if(f<0?(e=a,h=l):(s=a,o=l),e-s<=1){if(s>0||e==s||c)break;c=!0}}for(;;){var m;if(o>=(m=t[s]).s_size){if(this.cursor=n-m.s_size,!m.method)return m.result;var b=m.method();if(this.cursor=n-m.s_size,b)return m.result}if((s=m.substring_i)<0)return 0}},replace_s:function(t,i,s){var e=s.length-(i-t),n=r.substring(0,t),u=r.substring(i);return r=n+s+u,this.limit+=e,this.cursor>=i?this.cursor+=e:this.cursor>t&&(this.cursor=t),e},slice_check:function(){if(this.bra<0||this.bra>this.ket||this.ket>this.limit||this.limit>r.length)throw"faulty slice operation"},slice_from:function(r){this.slice_check(),this.replace_s(this.bra,this.ket,r)},slice_del:function(){this.slice_from("")},insert:function(r,t,i){var s=this.replace_s(r,t,i);r<=this.bra&&(this.bra+=s),r<=this.ket&&(this.ket+=s)},slice_to:function(){return this.slice_check(),r.substring(this.bra,this.ket)},eq_v_b:function(r){return this.eq_s_b(r.length,r)}}}},r.trimmerSupport={generateTrimmer:function(r){var t=new RegExp("^[^"+r+"]+"),i=new RegExp("[^"+r+"]+$");return function(r){return"function"==typeof r.update?r.update(function(r){return r.replace(t,"").replace(i,"")}):r.replace(t,"").replace(i,"")}}}}});
+1
View File
@@ -0,0 +1 @@
!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var r,n,t;e.sv=function(){this.pipeline.reset(),this.pipeline.add(e.sv.trimmer,e.sv.stopWordFilter,e.sv.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.sv.stemmer))},e.sv.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.sv.trimmer=e.trimmerSupport.generateTrimmer(e.sv.wordCharacters),e.Pipeline.registerFunction(e.sv.trimmer,"trimmer-sv"),e.sv.stemmer=(r=e.stemmerSupport.Among,n=e.stemmerSupport.SnowballProgram,t=new function(){var e,t,i=[new r("a",-1,1),new r("arna",0,1),new r("erna",0,1),new r("heterna",2,1),new r("orna",0,1),new r("ad",-1,1),new r("e",-1,1),new r("ade",6,1),new r("ande",6,1),new r("arne",6,1),new r("are",6,1),new r("aste",6,1),new r("en",-1,1),new r("anden",12,1),new r("aren",12,1),new r("heten",12,1),new r("ern",-1,1),new r("ar",-1,1),new r("er",-1,1),new r("heter",18,1),new r("or",-1,1),new r("s",-1,2),new r("as",21,1),new r("arnas",22,1),new r("ernas",22,1),new r("ornas",22,1),new r("es",21,1),new r("ades",26,1),new r("andes",26,1),new r("ens",21,1),new r("arens",29,1),new r("hetens",29,1),new r("erns",21,1),new r("at",-1,1),new r("andet",-1,1),new r("het",-1,1),new r("ast",-1,1)],s=[new r("dd",-1,-1),new r("gd",-1,-1),new r("nn",-1,-1),new r("dt",-1,-1),new r("gt",-1,-1),new r("kt",-1,-1),new r("tt",-1,-1)],a=[new r("ig",-1,1),new r("lig",0,1),new r("els",-1,1),new r("fullt",-1,3),new r("löst",-1,2)],o=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,24,0,32],u=[119,127,149],m=new n;this.setCurrent=function(e){m.setCurrent(e)},this.getCurrent=function(){return m.getCurrent()},this.stem=function(){var r,n=m.cursor;return function(){var r,n=m.cursor+3;if(t=m.limit,0<=n||n<=m.limit){for(e=n;;){if(r=m.cursor,m.in_grouping(o,97,246)){m.cursor=r;break}if(m.cursor=r,m.cursor>=m.limit)return;m.cursor++}for(;!m.out_grouping(o,97,246);){if(m.cursor>=m.limit)return;m.cursor++}(t=m.cursor)<e&&(t=e)}}(),m.limit_backward=n,m.cursor=m.limit,function(){var e,r=m.limit_backward;if(m.cursor>=t&&(m.limit_backward=t,m.cursor=m.limit,m.ket=m.cursor,e=m.find_among_b(i,37),m.limit_backward=r,e))switch(m.bra=m.cursor,e){case 1:m.slice_del();break;case 2:m.in_grouping_b(u,98,121)&&m.slice_del()}}(),m.cursor=m.limit,r=m.limit_backward,m.cursor>=t&&(m.limit_backward=t,m.cursor=m.limit,m.find_among_b(s,7)&&(m.cursor=m.limit,m.ket=m.cursor,m.cursor>m.limit_backward&&(m.bra=--m.cursor,m.slice_del())),m.limit_backward=r),m.cursor=m.limit,function(){var e,r;if(m.cursor>=t){if(r=m.limit_backward,m.limit_backward=t,m.cursor=m.limit,m.ket=m.cursor,e=m.find_among_b(a,5))switch(m.bra=m.cursor,e){case 1:m.slice_del();break;case 2:m.slice_from("lös");break;case 3:m.slice_from("full")}m.limit_backward=r}}(),!0}},function(e){return"function"==typeof e.update?e.update(function(e){return t.setCurrent(e),t.stem(),t.getCurrent()}):(t.setCurrent(e),t.stem(),t.getCurrent())}),e.Pipeline.registerFunction(e.sv.stemmer,"stemmer-sv"),e.sv.stopWordFilter=e.generateStopWordFilter("alla allt att av blev bli blir blivit de dem den denna deras dess dessa det detta dig din dina ditt du där då efter ej eller en er era ert ett från för ha hade han hans har henne hennes hon honom hur här i icke ingen inom inte jag ju kan kunde man med mellan men mig min mina mitt mot mycket ni nu när någon något några och om oss på samma sedan sig sin sina sitta själv skulle som så sådan sådana sådant till under upp ut utan vad var vara varför varit varje vars vart vem vi vid vilka vilkas vilken vilket vår våra vårt än är åt över".split(" ")),e.Pipeline.registerFunction(e.sv.stopWordFilter,"stopWordFilter-sv")}});
+1
View File
@@ -0,0 +1 @@
!function(r,i){"function"==typeof define&&define.amd?define(i):"object"==typeof exports?module.exports=i():i()(r.lunr)}(this,function(){return function(r){if(void 0===r)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===r.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");var i,e,n;r.tr=function(){this.pipeline.reset(),this.pipeline.add(r.tr.trimmer,r.tr.stopWordFilter,r.tr.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(r.tr.stemmer))},r.tr.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",r.tr.trimmer=r.trimmerSupport.generateTrimmer(r.tr.wordCharacters),r.Pipeline.registerFunction(r.tr.trimmer,"trimmer-tr"),r.tr.stemmer=(i=r.stemmerSupport.Among,e=r.stemmerSupport.SnowballProgram,n=new function(){var r,n=[new i("m",-1,-1),new i("n",-1,-1),new i("miz",-1,-1),new i("niz",-1,-1),new i("muz",-1,-1),new i("nuz",-1,-1),new i("müz",-1,-1),new i("nüz",-1,-1),new i("mız",-1,-1),new i("nız",-1,-1)],t=[new i("leri",-1,-1),new i("ları",-1,-1)],u=[new i("ni",-1,-1),new i("nu",-1,-1),new i("nü",-1,-1),new i("nı",-1,-1)],o=[new i("in",-1,-1),new i("un",-1,-1),new i("ün",-1,-1),new i("ın",-1,-1)],s=[new i("a",-1,-1),new i("e",-1,-1)],c=[new i("na",-1,-1),new i("ne",-1,-1)],l=[new i("da",-1,-1),new i("ta",-1,-1),new i("de",-1,-1),new i("te",-1,-1)],a=[new i("nda",-1,-1),new i("nde",-1,-1)],m=[new i("dan",-1,-1),new i("tan",-1,-1),new i("den",-1,-1),new i("ten",-1,-1)],d=[new i("ndan",-1,-1),new i("nden",-1,-1)],f=[new i("la",-1,-1),new i("le",-1,-1)],b=[new i("ca",-1,-1),new i("ce",-1,-1)],w=[new i("im",-1,-1),new i("um",-1,-1),new i("üm",-1,-1),new i("ım",-1,-1)],_=[new i("sin",-1,-1),new i("sun",-1,-1),new i("sün",-1,-1),new i("sın",-1,-1)],k=[new i("iz",-1,-1),new i("uz",-1,-1),new i("üz",-1,-1),new i("ız",-1,-1)],p=[new i("siniz",-1,-1),new i("sunuz",-1,-1),new i("sünüz",-1,-1),new i("sınız",-1,-1)],g=[new i("lar",-1,-1),new i("ler",-1,-1)],y=[new i("niz",-1,-1),new i("nuz",-1,-1),new i("nüz",-1,-1),new i("nız",-1,-1)],z=[new i("dir",-1,-1),new i("tir",-1,-1),new i("dur",-1,-1),new i("tur",-1,-1),new i("dür",-1,-1),new i("tür",-1,-1),new i("dır",-1,-1),new i("tır",-1,-1)],h=[new i("casına",-1,-1),new i("cesine",-1,-1)],v=[new i("di",-1,-1),new i("ti",-1,-1),new i("dik",-1,-1),new i("tik",-1,-1),new i("duk",-1,-1),new i("tuk",-1,-1),new i("dük",-1,-1),new i("tük",-1,-1),new i("dık",-1,-1),new i("tık",-1,-1),new i("dim",-1,-1),new i("tim",-1,-1),new i("dum",-1,-1),new i("tum",-1,-1),new i("düm",-1,-1),new i("tüm",-1,-1),new i("dım",-1,-1),new i("tım",-1,-1),new i("din",-1,-1),new i("tin",-1,-1),new i("dun",-1,-1),new i("tun",-1,-1),new i("dün",-1,-1),new i("tün",-1,-1),new i("dın",-1,-1),new i("tın",-1,-1),new i("du",-1,-1),new i("tu",-1,-1),new i("dü",-1,-1),new i("tü",-1,-1),new i("dı",-1,-1),new i("tı",-1,-1)],q=[new i("sa",-1,-1),new i("se",-1,-1),new i("sak",-1,-1),new i("sek",-1,-1),new i("sam",-1,-1),new i("sem",-1,-1),new i("san",-1,-1),new i("sen",-1,-1)],C=[new i("miş",-1,-1),new i("muş",-1,-1),new i("müş",-1,-1),new i("mış",-1,-1)],P=[new i("b",-1,1),new i("c",-1,2),new i("d",-1,3),new i("ğ",-1,4)],F=[17,65,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,32,8,0,0,0,0,0,0,1],S=[1,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,0,0,0,0,0,0,1],W=[65],L=[65],x=[["a",[1,64,16,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1],97,305],["e",[17,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,130],101,252],["ı",[1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1],97,305],["i",[17],101,105],["o",W,111,117],["ö",L,246,252],["u",W,111,117]],A=new e;function E(r,i,e){for(;;){var n=A.limit-A.cursor;if(A.in_grouping_b(r,i,e)){A.cursor=A.limit-n;break}if(A.cursor=A.limit-n,A.cursor<=A.limit_backward)return!1;A.cursor--}return!0}function j(){var r,i;r=A.limit-A.cursor,E(F,97,305);for(var e=0;e<x.length;e++){i=A.limit-A.cursor;var n=x[e];if(A.eq_s_b(1,n[0])&&E(n[1],n[2],n[3]))return A.cursor=A.limit-r,!0;A.cursor=A.limit-i}return A.cursor=A.limit-i,!(!A.eq_s_b(1,"ü")||!E(L,246,252))&&(A.cursor=A.limit-r,!0)}function T(r,i){var e,n=A.limit-A.cursor;return r()&&(A.cursor=A.limit-n,A.cursor>A.limit_backward&&(A.cursor--,e=A.limit-A.cursor,i()))?(A.cursor=A.limit-e,!0):(A.cursor=A.limit-n,r()?(A.cursor=A.limit-n,!1):(A.cursor=A.limit-n,!(A.cursor<=A.limit_backward)&&(A.cursor--,!!i()&&(A.cursor=A.limit-n,!0))))}function Z(r){return T(r,function(){return A.in_grouping_b(F,97,305)})}function B(){return Z(function(){return A.eq_s_b(1,"n")})}function D(){return Z(function(){return A.eq_s_b(1,"y")})}function G(){return A.find_among_b(n,10)&&T(function(){return A.in_grouping_b(S,105,305)},function(){return A.out_grouping_b(F,97,305)})}function H(){return j()&&A.in_grouping_b(S,105,305)&&Z(function(){return A.eq_sLine truncated
+1
View File
@@ -0,0 +1 @@
!function(_,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():t()(_.lunr)}(this,function(){return function(_){function t(){var _={"[一二三四五六七八九十百千万億兆]":"M","[一-龠々〆ヵヶ]":"H","[ぁ-ん]":"I","[ァ-ヴーア-ン゙ー]":"K","[a-zA-Za-zA-Z]":"A","[0-90-9]":"N"};for(var t in this.chartype_=[],_){var H=new RegExp;H.compile(t),this.chartype_.push([H,_[t]])}return this.BIAS__=-332,this.BC1__={HH:6,II:2461,KH:406,OH:-1378},this.BC2__={AA:-3267,AI:2744,AN:-878,HH:-4070,HM:-1711,HN:4012,HO:3761,IA:1327,IH:-1184,II:-1332,IK:1721,IO:5492,KI:3831,KK:-8741,MH:-3132,MK:3334,OO:-2920},this.BC3__={HH:996,HI:626,HK:-721,HN:-1307,HO:-836,IH:-301,KK:2762,MK:1079,MM:4034,OA:-1652,OH:266},this.BP1__={BB:295,OB:304,OO:-125,UB:352},this.BP2__={BO:60,OO:-1762},this.BQ1__={BHH:1150,BHM:1521,BII:-1158,BIM:886,BMH:1208,BNH:449,BOH:-91,BOO:-2597,OHI:451,OIH:-296,OKA:1851,OKH:-1020,OKK:904,OOO:2965},this.BQ2__={BHH:118,BHI:-1159,BHM:466,BIH:-919,BKK:-1720,BKO:864,OHH:-1139,OHM:-181,OIH:153,UHI:-1146},this.BQ3__={BHH:-792,BHI:2664,BII:-299,BKI:419,BMH:937,BMM:8335,BNN:998,BOH:775,OHH:2174,OHM:439,OII:280,OKH:1798,OKI:-793,OKO:-2242,OMH:-2402,OOO:11699},this.BQ4__={BHH:-3895,BIH:3761,BII:-4654,BIK:1348,BKK:-1806,BMI:-3385,BOO:-12396,OAH:926,OHH:266,OHK:-2036,ONN:-973},this.BW1__={",と":660,",同":727,"B1あ":1404,"B1同":542,"、と":660,"、同":727,"」と":1682,"あっ":1505,"いう":1743,"いっ":-2055,"いる":672,"うし":-4817,"うん":665,"から":3472,"がら":600,"こう":-790,"こと":2083,"こん":-1262,"さら":-4143,"さん":4573,"した":2641,"して":1104,"すで":-3399,"そこ":1977,"それ":-871,"たち":1122,"ため":601,"った":3463,"つい":-802,"てい":805,"てき":1249,"でき":1127,"です":3445,"では":844,"とい":-4915,"とみ":1922,"どこ":3887,"ない":5713,"なっ":3015,"など":7379,"なん":-1113,"にし":2468,"には":1498,"にも":1671,"に対":-912,"の一":-501,"の中":741,"ませ":2448,"まで":1711,"まま":2600,"まる":-2155,"やむ":-1947,"よっ":-2565,"れた":2369,"れで":-913,"をし":1860,"を見":731,"亡く":-1886,"京都":2558,"取り":-2784,"大き":-2604,"大阪":1497,"平方":-2314,"引き":-1336,"日本":-195,"本当":-2423,"毎日":-2113,"目指":-724,"B1あ":1404,"B1同":542,"」と":1682},this.BW2__={"..":-11822,11:-669,"――":-5730,"−−":-13175,"いう":-1609,"うか":2490,"かし":-1350,"かも":-602,"から":-7194,"かれ":4612,"がい":853,"がら":-3198,"きた":1941,"くな":-1597,"こと":-8392,"この":-4193,"させ":4533,"され":13168,"さん":-3977,"しい":-1819,"しか":-545,"した":5078,"して":972,"しな":939,"その":-3744,"たい":-1253,"たた":-662,"ただ":-3857,"たち":-786,"たと":1224,"たは":-939,"った":4589,"って":1647,"っと":-2094,"てい":6144,"てき":3640,"てく":2551,"ては":-3110,"ても":-3065,"でい":2666,"でき":-1528,"でし":-3828,"です":-4761,"でも":-4203,"とい":1890,"とこ":-1746,"とと":-2279,"との":720,"とみ":5168,"とも":-3941,"ない":-2488,"なが":-1313,"など":-6509,"なの":2614,"なん":3099,"にお":-1615,"にし":2748,"にな":2454,"によ":-7236,"に対":-14943,"に従":-4688,"に関":-11388,"のか":2093,"ので":-7059,"のに":-6041,"のの":-6125,"はい":1073,"はが":-1033,"はず":-2532,"ばれ":1813,"まし":-1316,"まで":-6621,"まれ":5409,"めて":-3153,"もい":2230,"もの":-10713,"らか":-944,"らし":-1611,"らに":-1897,"りし":651,"りま":1620,"れた":4270,"れて":849,"れば":4114,"ろう":6067,"われ":7901,"を通":-11877,"んだ":728,"んな":-4115,"一人":602,"一方":-1375,"一日":970,"一部":-1051,"上が":-4479,"会社":-1116,"出て":2163,"分の":-7758,"同党":970,"同日":-913,"大阪":-2471,"委員":-1250,"少な":-1050,"年度":-8669,"年間":-1626,"府県":-2363,"手権":-1982,"新聞":-4066,"日新":-722,"日本":-7068,"日米":3372,"曜日":-601,"朝鮮":-2355,"本人":-2697,"東京":-1543,"然と":-1384,"社会":-1276,"立て":-990,"第に":-1612,"米国":-4268,"11":-669},this.BW3__={"あた":-2194,"あり":719,"ある":3846,"い.":-1185,"い。":-1185,"いい":5308,"いえ":2079,"いく":3029,"いた":2056,"いっ":1883,"いる":5600,"いわ":1527,"うち":1117,"うと":4798,"えと":1454,"か.":2857,"か。":2857,"かけ":-743,"かっ":-4098,"かに":-669,"から":6520,"かり":-2670,"が,":1816,"が、":1816,"がき":-4855,"がけ":-1127,"がっ":-913,"がら":-4977,"がり":-2064,"きた":1645,"けど":1374,"こと":7397,"この":1542,"ころ":-2757,"さい":-714,"さを":976,"し,":1557,"し、":1557,"しい":-3714,"した":3562,"して":1449,"しな":2608,"しま":1200,"す.":-1310,"す。":-1310,"する":6521,"ず,":3426,"ず、":3426,"ずに":841,"そう":428,"た.":8875,"た。":8875,"たい":-594,"たの":812,"たり":-1183,"たる":-853,"だ.":4098,"だ。":4098,"だっ":1004,"った":-4748,"って":300,"てい":6240,"てお":855,"てLine truncated
@@ -0,0 +1 @@
!function(e,t){for(var n in t)e[n]=t[n]}(window,function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var n={};return t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=4)}({4:function(e,t,n){"use strict";n(5)},5:function(e,t){!function(t){!function(e,t,n){function r(e,t){return typeof e===t}function o(e){var t=_.className,n=C._config.classPrefix||"";if(T&&(t=t.baseVal),C._config.enableJSClass){var r=new RegExp("(^|\\s)"+n+"no-js(\\s|$)");t=t.replace(r,"$1"+n+"js$2")}C._config.enableClasses&&(t+=" "+n+e.join(" "+n),T?_.className.baseVal=t:_.className=t)}function i(e,t){if("object"==typeof e)for(var n in e)b(e,n)&&i(n,e[n]);else{e=e.toLowerCase();var r=e.split("."),s=C[r[0]];if(2==r.length&&(s=s[r[1]]),void 0!==s)return C;t="function"==typeof t?t():t,1==r.length?C[r[0]]=t:(!C[r[0]]||C[r[0]]instanceof Boolean||(C[r[0]]=new Boolean(C[r[0]])),C[r[0]][r[1]]=t),o([(t&&0!=t?"":"no-")+r.join("-")]),C._trigger(e,t)}return C}function s(){return"function"!=typeof t.createElement?t.createElement(arguments[0]):T?t.createElementNS.call(t,"http://www.w3.org/2000/svg",arguments[0]):t.createElement.apply(t,arguments)}function a(){var e=t.body;return e||(e=s(T?"svg":"body"),e.fake=!0),e}function u(e,n,r,o){var i,u,l,f,c="modernizr",d=s("div"),p=a();if(parseInt(r,10))for(;r--;)l=s("div"),l.id=o?o[r]:c+(r+1),d.appendChild(l);return i=s("style"),i.type="text/css",i.id="s"+c,(p.fake?p:d).appendChild(i),p.appendChild(d),i.styleSheet?i.styleSheet.cssText=e:i.appendChild(t.createTextNode(e)),d.id=c,p.fake&&(p.style.background="",p.style.overflow="hidden",f=_.style.overflow,_.style.overflow="hidden",_.appendChild(p)),u=n(d,e),p.fake?(p.parentNode.removeChild(p),_.style.overflow=f,_.offsetHeight):d.parentNode.removeChild(d),!!u}function l(e,t){return!!~(""+e).indexOf(t)}function f(e){return e.replace(/([A-Z])/g,function(e,t){return"-"+t.toLowerCase()}).replace(/^ms-/,"-ms-")}function c(t,n,r){var o;if("getComputedStyle"in e){o=getComputedStyle.call(e,t,n);var i=e.console;if(null!==o)r&&(o=o.getPropertyValue(r));else if(i){var s=i.error?"error":"log";i[s].call(i,"getComputedStyle returning null, its possible modernizr test results are inaccurate")}}else o=!n&&t.currentStyle&&t.currentStyle[r];return o}function d(t,r){var o=t.length;if("CSS"in e&&"supports"in e.CSS){for(;o--;)if(e.CSS.supports(f(t[o]),r))return!0;return!1}if("CSSSupportsRule"in e){for(var i=[];o--;)i.push("("+f(t[o])+":"+r+")");return i=i.join(" or "),u("@supports ("+i+") { #modernizr { position: absolute; } }",function(e){return"absolute"==c(e,null,"position")})}return n}function p(e){return e.replace(/([a-z])-([a-z])/g,function(e,t,n){return t+n.toUpperCase()}).replace(/^-/,"")}function h(e,t,o,i){function a(){f&&(delete j.style,delete j.modElem)}if(i=!r(i,"undefined")&&i,!r(o,"undefined")){var u=d(e,o);if(!r(u,"undefined"))return u}for(var f,c,h,m,v,g=["modernizr","tspan","samp"];!j.style&&g.length;)f=!0,j.modElem=s(g.shift()),j.style=j.modElem.style;for(h=e.length,c=0;h>c;c++)if(m=e[c],v=j.style[m],l(m,"-")&&(m=p(m)),j.style[m]!==n){if(i||r(o,"undefined"))return a(),"pfx"!=t||m;try{j.style[m]=o}catch(e){}if(j.style[m]!=v)return a(),"pfx"!=t||m}return a(),!1}function m(e,t){return function(){return e.apply(t,arguments)}}function v(e,t,n){var o;for(var i in e)if(e[i]in t)return!1===n?e[i]:(o=t[e[i]],r(o,"function")?m(o,n||t):o);return!1}function g(e,t,n,o,i){var s=e.charAt(0).toUpperCase()+e.slice(1),a=(e+" "+k.join(s+" ")+s).split(" ");return r(t,"string")||r(t,"undefined")?h(a,t,o,i):(a=(e+" "+A.join(s+" ")+s).split(" "),v(a,t,n))}function y(e,t,r){return g(e,n,n,t,r)}var w=[],S={_version:"3.5.0",_config:{classPrefix:"",enableClasses:!0,enableJSClass:!0,usePrefixes:!0},_q:[],on:function(e,t){var n=this;setTimeout(function(){t(n[e])},0)},addTest:function(e,t,n){w.push({name:e,fn:t,options:n})},addAsyncTest:function(e){w.push({name:null,fn:e})}},C=function(){};C.prototype=S,C=new C;var b,x=[],_=t.documentElement,T="svg"===_.nodeName.toLowerCase();!function(){var e={}.hasOwnProperty;b=r(e,"undefined")||r(e.call,"undefined")?function(e,t){return t in e&&r(e.constructor.prototype[t],"undefined")}:function(t,n){return e.call(t,n)}}(),S._l={},S.on=function(e,t){this._l[e]||(this._l[e]=[]),this._l[e].push(t),C.hasOwnProperty(e)&&setTimeout(function(){C._trigger(e,C[e])},0)},S._trigger=function(e,t){if(this._l[e]){var n=this._l[e];setTimeout(function(){var e;for(e=0;e<n.length;e++)(0,n[e])(t)},0),delete this._l[e]}},C._q.push(function(){S.addTest=i}),C.addTest("json","JSON"in e&&"parse"in JSON&&"stringify"in JSON),C.addTest("svg",!!t.createElementNS&&!!t.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect);var P=S.testStylesLine truncated
@@ -0,0 +1,2 @@
button[data-md-color-accent],button[data-md-color-primary]{width:13rem;margin-bottom:.4rem;padding:2.4rem .8rem .4rem;transition:background-color .25s,opacity .25s;border-radius:.2rem;color:#fff;font-size:1.28rem;text-align:left;cursor:pointer}button[data-md-color-accent]:hover,button[data-md-color-primary]:hover{opacity:.75}button[data-md-color-primary=red]{background-color:#ef5350}[data-md-color-primary=red] .md-typeset a{color:#ef5350}[data-md-color-primary=red] .md-header,[data-md-color-primary=red] .md-hero{background-color:#ef5350}[data-md-color-primary=red] .md-nav__link--active,[data-md-color-primary=red] .md-nav__link:active{color:#ef5350}[data-md-color-primary=red] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=pink]{background-color:#e91e63}[data-md-color-primary=pink] .md-typeset a{color:#e91e63}[data-md-color-primary=pink] .md-header,[data-md-color-primary=pink] .md-hero{background-color:#e91e63}[data-md-color-primary=pink] .md-nav__link--active,[data-md-color-primary=pink] .md-nav__link:active{color:#e91e63}[data-md-color-primary=pink] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=purple]{background-color:#ab47bc}[data-md-color-primary=purple] .md-typeset a{color:#ab47bc}[data-md-color-primary=purple] .md-header,[data-md-color-primary=purple] .md-hero{background-color:#ab47bc}[data-md-color-primary=purple] .md-nav__link--active,[data-md-color-primary=purple] .md-nav__link:active{color:#ab47bc}[data-md-color-primary=purple] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=deep-purple]{background-color:#7e57c2}[data-md-color-primary=deep-purple] .md-typeset a{color:#7e57c2}[data-md-color-primary=deep-purple] .md-header,[data-md-color-primary=deep-purple] .md-hero{background-color:#7e57c2}[data-md-color-primary=deep-purple] .md-nav__link--active,[data-md-color-primary=deep-purple] .md-nav__link:active{color:#7e57c2}[data-md-color-primary=deep-purple] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=indigo]{background-color:#3f51b5}[data-md-color-primary=indigo] .md-typeset a{color:#3f51b5}[data-md-color-primary=indigo] .md-header,[data-md-color-primary=indigo] .md-hero{background-color:#3f51b5}[data-md-color-primary=indigo] .md-nav__link--active,[data-md-color-primary=indigo] .md-nav__link:active{color:#3f51b5}[data-md-color-primary=indigo] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=blue]{background-color:#2196f3}[data-md-color-primary=blue] .md-typeset a{color:#2196f3}[data-md-color-primary=blue] .md-header,[data-md-color-primary=blue] .md-hero{background-color:#2196f3}[data-md-color-primary=blue] .md-nav__link--active,[data-md-color-primary=blue] .md-nav__link:active{color:#2196f3}[data-md-color-primary=blue] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=light-blue]{background-color:#03a9f4}[data-md-color-primary=light-blue] .md-typeset a{color:#03a9f4}[data-md-color-primary=light-blue] .md-header,[data-md-color-primary=light-blue] .md-hero{background-color:#03a9f4}[data-md-color-primary=light-blue] .md-nav__link--active,[data-md-color-primary=light-blue] .md-nav__link:active{color:#03a9f4}[data-md-color-primary=light-blue] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=cyan]{background-color:#00bcd4}[data-md-color-primary=cyan] .md-typeset a{color:#00bcd4}[data-md-color-primary=cyan] .md-header,[data-md-color-primary=cyan] .md-hero{background-color:#00bcd4}[data-md-color-primary=cyan] .md-nav__link--active,[data-md-color-primary=cyan] .md-nav__link:active{color:#00bcd4}[data-md-color-primary=cyan] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=teal]{background-color:#009688}[data-md-color-primary=teal] .md-typeset a{color:#009688}[data-md-color-primary=teal] .md-header,[data-md-color-primary=teal] .md-hero{background-color:#009688}[data-md-color-primary=teal] .md-nav__link--active,[data-md-color-primary=teal] .md-nav__link:active{color:#009688}[data-md-color-primary=teal] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=green]{background-color:#4caf50}[data-md-color-primary=green] .md-typeset a{color:#4caf50}[data-md-color-primary=green] .md-header,[data-md-color-primary=green] .md-hero{background-color:#4caf50}[data-md-color-primary=green] .md-nav__link--active,[data-md-color-primary=green] .md-nav__link:active{color:#4caf50}[data-md-color-primary=green] .md-nav__item--nested>.md-nav__link{color:inherit}button[data-md-color-primary=light-green]{background-color:#7cb342}[data-md-color-primary=light-green] .md-typeset a{color:#7cb342}[data-md-color-primary=light-green] .md-header,[data-md-color-primary=light-green] .md-hero{background-color:#7cb342}[data-md-color-primary=light-green] .md-nav__link--active,[data-md-color-primary=light-green] .md-nav__link:active{color:#7cb342}[data-md-color-primary=light-green] Line truncated
/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsImZpbGUiOiJhc3NldHMvc3R5bGVzaGVldHMvYXBwbGljYXRpb24tcGFsZXR0ZS42MDc5NDc2Yy5jc3MiLCJzb3VyY2VSb290IjoiIn0=*/
@@ -0,0 +1,2 @@
html{box-sizing:border-box}*,:after,:before{box-sizing:inherit}html{-webkit-text-size-adjust:none;-moz-text-size-adjust:none;-ms-text-size-adjust:none;text-size-adjust:none}body{margin:0}hr{overflow:visible;box-sizing:content-box}a{-webkit-text-decoration-skip:objects}a,button,input,label{-webkit-tap-highlight-color:transparent}a{color:inherit;text-decoration:none}small,sub,sup{font-size:80%}sub,sup{position:relative;line-height:0;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}img{border-style:none}table{border-collapse:separate;border-spacing:0}td,th{font-weight:400;vertical-align:top}button{margin:0;padding:0;border:0;outline-style:none;background:transparent;font-size:inherit}input{border:0;outline:0}.md-clipboard:before,.md-icon,.md-nav__button,.md-nav__link:after,.md-nav__title:before,.md-search-result__article--document:before,.md-source-file:before,.md-typeset .admonition>.admonition-title:before,.md-typeset .admonition>summary:before,.md-typeset .critic.comment:before,.md-typeset .footnote-backref,.md-typeset .task-list-control .task-list-indicator:before,.md-typeset details>.admonition-title:before,.md-typeset details>summary:before,.md-typeset summary:after{font-family:Material Icons;font-style:normal;font-variant:normal;font-weight:400;line-height:1;text-transform:none;white-space:nowrap;speak:none;word-wrap:normal;direction:ltr}.md-content__icon,.md-footer-nav__button,.md-header-nav__button,.md-nav__button,.md-nav__title:before,.md-search-result__article--document:before{display:inline-block;margin:.4rem;padding:.8rem;font-size:2.4rem;cursor:pointer}.md-icon--arrow-back:before{content:"\E5C4"}.md-icon--arrow-forward:before{content:"\E5C8"}.md-icon--menu:before{content:"\E5D2"}.md-icon--search:before{content:"\E8B6"}[dir=rtl] .md-icon--arrow-back:before{content:"\E5C8"}[dir=rtl] .md-icon--arrow-forward:before{content:"\E5C4"}body{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}body,input{color:rgba(0,0,0,.87);-webkit-font-feature-settings:"kern","liga";font-feature-settings:"kern","liga";font-family:Helvetica Neue,Helvetica,Arial,sans-serif}code,kbd,pre{color:rgba(0,0,0,.87);-webkit-font-feature-settings:"kern";font-feature-settings:"kern";font-family:Courier New,Courier,monospace}.md-typeset{font-size:1.6rem;line-height:1.6;-webkit-print-color-adjust:exact}.md-typeset blockquote,.md-typeset ol,.md-typeset p,.md-typeset ul{margin:1em 0}.md-typeset h1{margin:0 0 4rem;color:rgba(0,0,0,.54);font-size:3.125rem;line-height:1.3}.md-typeset h1,.md-typeset h2{font-weight:300;letter-spacing:-.01em}.md-typeset h2{margin:4rem 0 1.6rem;font-size:2.5rem;line-height:1.4}.md-typeset h3{margin:3.2rem 0 1.6rem;font-size:2rem;font-weight:400;letter-spacing:-.01em;line-height:1.5}.md-typeset h2+h3{margin-top:1.6rem}.md-typeset h4{font-size:1.6rem}.md-typeset h4,.md-typeset h5,.md-typeset h6{margin:1.6rem 0;font-weight:700;letter-spacing:-.01em}.md-typeset h5,.md-typeset h6{color:rgba(0,0,0,.54);font-size:1.28rem}.md-typeset h5{text-transform:uppercase}.md-typeset hr{margin:1.5em 0;border-bottom:.1rem dotted rgba(0,0,0,.26)}.md-typeset a{color:#3f51b5;word-break:break-word}.md-typeset a,.md-typeset a:before{transition:color .125s}.md-typeset a:active,.md-typeset a:hover{color:#536dfe}.md-typeset code,.md-typeset pre{background-color:hsla(0,0%,93%,.5);color:#37474f;font-size:85%;direction:ltr}.md-typeset code{margin:0 .29412em;padding:.07353em 0;border-radius:.2rem;box-shadow:.29412em 0 0 hsla(0,0%,93%,.5),-.29412em 0 0 hsla(0,0%,93%,.5);word-break:break-word;-webkit-box-decoration-break:clone;box-decoration-break:clone}.md-typeset h1 code,.md-typeset h2 code,.md-typeset h3 code,.md-typeset h4 code,.md-typeset h5 code,.md-typeset h6 code{margin:0;background-color:transparent;box-shadow:none}.md-typeset a>code{margin:inherit;padding:inherit;border-radius:none;background-color:inherit;color:inherit;box-shadow:none}.md-typeset pre{position:relative;margin:1em 0;border-radius:.2rem;line-height:1.4;-webkit-overflow-scrolling:touch}.md-typeset pre>code{display:block;margin:0;padding:1.05rem 1.2rem;background-color:transparent;font-size:inherit;box-shadow:none;-webkit-box-decoration-break:none;box-decoration-break:none;overflow:auto}.md-typeset pre>code::-webkit-scrollbar{width:.4rem;height:.4rem}.md-typeset pre>code::-webkit-scrollbar-thumb{background-color:rgba(0,0,0,.26)}.md-typeset pre>code::-webkit-scrollbar-thumb:hover{background-color:#536dfe}.md-typeset kbd{padding:0 .29412em;border:.1rem solid #c9c9c9;border-radius:.3rem;border-bottom-color:#bcbcbc;background-color:#fcfcfc;color:#555;font-size:85%;box-shadow:0 .1rem 0 #b0b0b0;word-break:break-word}.md-typeset mark{margin:0 .25em;padding:.0625em 0;border-radius:.2rem;background-color:rgba(255,235,59,.5);box-shadow:.25em 0 0 rgba(255,235,59,.5),-.25em 0 0 rgba(255,235,59,.5);word-break:break-word;-webkit-box-decoration-break:clone;box-decoration-break:clone}.md-typeset abbr{border-bottom:.1rem dotted rgba(0,0,0,.54);text-decoration:noneLine truncated
/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsImZpbGUiOiJhc3NldHMvc3R5bGVzaGVldHMvYXBwbGljYXRpb24uNzhhYWIyZGMuY3NzIiwic291cmNlUm9vdCI6IiJ9*/
+2494
View File
File diff suppressed because it is too large. Load diff
+2230
View File
File diff suppressed because it is too large. Load diff
+554
View File
@@ -0,0 +1,554 @@
{
"docs": [
{
"location": "/",
"text": "LBRY JSON-RPC API Documentation\n\n\nblob_announce\n\n\nAnnounce blobs to the DHT\n\nArgs:\n 'announce_all' : (bool) announce all the blobs possessed by user\n 'blob_hash' : (str) announce a blob, specified by blob_hash\n 'stream_hash' : (str) announce all blobs associated with\n stream_hash\n 'sd_hash' : (str) announce all blobs associated with\n sd_hash and the sd_hash itself\n\nReturns:\n (bool) true if successful\n\n\n\n\nblob_availability\n\n\nGet blob availability\n\nArgs:\n 'blob_hash' : (str) check availability for this blob hash\n 'search_timeout' : (int) how long to search for peers for the blob\n in the dht\n 'blob_timeout' : (int) how long to try downloading from a peer\n\nReturns:\n (dict) {\n \nis_available\n: \nbool, true if blob is available from a peer from peer list\n\n \nreachable_peers\n: [\nip\n:\nport\n],\n \nunreachable_peers\n: [\nip\n:\nport\n]\n }\n\n\n\n\nblob_delete\n\n\nDelete a blob\n\nArgs:\n 'blob_hash' : (str) blob hash of the blob to delete\n\nReturns:\n (str) Success/fail message\n\n\n\n\nblob_get\n\n\nDownload and return a blob\n\nArgs:\n 'blob_hash' (required) : (str) blob hash of the blob to get\n 'timeout' : (int) timeout in number of seconds\n 'encoding' : (str) by default no attempt at decoding\n is made, can be set to one of the\n following decoders:\n 'json'\n 'payment_rate_manager' : (str) if not given the default payment rate\n manager will be used.\n supported alternative rate managers:\n 'only-free'\n\nReturns:\n (str) Success/Fail message or (dict) decoded data\n\n\n\n\nblob_list\n\n\nReturns blob hashes. If not given filters, returns all blobs known by the blob manager\n\nArgs:\n 'needed' : (bool) only return needed blobs\n 'finished' : (bool) only return finished blobs\n 'uri' : (str) filter blobs by stream in a uri\n 'stream_hash' : (str) filter blobs by stream hash\n 'sd_hash' : (str) filter blobs by sd hash\n 'page_size' : (int) results page size\n 'page' : (int) page of results to return\n\nReturns:\n (list) List of blob hashes\n\n\n\n\nblob_reflect_all\n\n\nReflects all saved blobs\n\nArgs:\n None\n\nReturns:\n (bool) true if successful\n\n\n\n\nblock_show\n\n\nGet contents of a block\n\nArgs:\n 'blockhash' (required) : (str) hash of the block to look up\n 'height' (required) : (int) height of the block to look up\n\nReturns:\n (dict) Requested block\n\n\n\n\nchannel_export\n\n\nExport serialized channel signing information for a given certificate claim id\n\nArgs:\n 'claim_id' (required) : (str) Claim ID to export information about\n\nReturns:\n (str) Serialized certificate information\n\n\n\n\nchannel_import\n\n\nImport serialized channel signing information (to allow signing new claims to the channel)\n\nArgs:\n 'serialized_certificate_info' : (str) certificate info\n\nReturns:\n (dict) Result dictionary\n\n\n\n\nchannel_list\n\n\nGet certificate claim infos for channels that can be published to\n\nArgs:\n None\n\nReturns:\n (list) ClaimDict, includes 'is_mine' field to indicate if the certificate claim\n is in the wallet.\n\n\n\n\nchannel_new\n\n\nGenerate a publisher key and create a new '@' prefixed certificate claim\n\nArgs:\n 'channel_name' (required) : (str) name of the channel prefixed with '@'\n 'amount' (required) : (float) bid amount on the channel\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n }\n\n\n\n\nclaim_abandon\n\n\nAbandon a name and reclaim credits from the claim\n\nArgs:\n 'claim_id' : (str) claim_id of the claim to abandon\n 'txid' : (str) txid of the claim to abandon\n 'nout' : (int) nout of the claim to abandon\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n txid : (str) txid of resulting transaction\n fee : (float) fee paid for the transaction\n }\n\n\n\n\nclaim_list\n\n\nList current claims and information about them for a given name\n\nArgs:\n 'name' (required) : (str) name of the claim to list info about\n\nReturns:\n (dict) State of claims assigned for the name\n {\n 'claims': (list) list of claims for the Line truncated
"title": "API"
},
{
"location": "/#lbry-json-rpc-api-documentation",
"text": "",
"title": "LBRY JSON-RPC API Documentation"
},
{
"location": "/#blob_announce",
"text": "Announce blobs to the DHT\n\nArgs:\n 'announce_all' : (bool) announce all the blobs possessed by user\n 'blob_hash' : (str) announce a blob, specified by blob_hash\n 'stream_hash' : (str) announce all blobs associated with\n stream_hash\n 'sd_hash' : (str) announce all blobs associated with\n sd_hash and the sd_hash itself\n\nReturns:\n (bool) true if successful",
"title": "blob_announce"
},
{
"location": "/#blob_availability",
"text": "Get blob availability\n\nArgs:\n 'blob_hash' : (str) check availability for this blob hash\n 'search_timeout' : (int) how long to search for peers for the blob\n in the dht\n 'blob_timeout' : (int) how long to try downloading from a peer\n\nReturns:\n (dict) {\n is_available : bool, true if blob is available from a peer from peer list \n reachable_peers : [ ip : port ],\n unreachable_peers : [ ip : port ]\n }",
"title": "blob_availability"
},
{
"location": "/#blob_delete",
"text": "Delete a blob\n\nArgs:\n 'blob_hash' : (str) blob hash of the blob to delete\n\nReturns:\n (str) Success/fail message",
"title": "blob_delete"
},
{
"location": "/#blob_get",
"text": "Download and return a blob\n\nArgs:\n 'blob_hash' (required) : (str) blob hash of the blob to get\n 'timeout' : (int) timeout in number of seconds\n 'encoding' : (str) by default no attempt at decoding\n is made, can be set to one of the\n following decoders:\n 'json'\n 'payment_rate_manager' : (str) if not given the default payment rate\n manager will be used.\n supported alternative rate managers:\n 'only-free'\n\nReturns:\n (str) Success/Fail message or (dict) decoded data",
"title": "blob_get"
},
{
"location": "/#blob_list",
"text": "Returns blob hashes. If not given filters, returns all blobs known by the blob manager\n\nArgs:\n 'needed' : (bool) only return needed blobs\n 'finished' : (bool) only return finished blobs\n 'uri' : (str) filter blobs by stream in a uri\n 'stream_hash' : (str) filter blobs by stream hash\n 'sd_hash' : (str) filter blobs by sd hash\n 'page_size' : (int) results page size\n 'page' : (int) page of results to return\n\nReturns:\n (list) List of blob hashes",
"title": "blob_list"
},
{
"location": "/#blob_reflect_all",
"text": "Reflects all saved blobs\n\nArgs:\n None\n\nReturns:\n (bool) true if successful",
"title": "blob_reflect_all"
},
{
"location": "/#block_show",
"text": "Get contents of a block\n\nArgs:\n 'blockhash' (required) : (str) hash of the block to look up\n 'height' (required) : (int) height of the block to look up\n\nReturns:\n (dict) Requested block",
"title": "block_show"
},
{
"location": "/#channel_export",
"text": "Export serialized channel signing information for a given certificate claim id\n\nArgs:\n 'claim_id' (required) : (str) Claim ID to export information about\n\nReturns:\n (str) Serialized certificate information",
"title": "channel_export"
},
{
"location": "/#channel_import",
"text": "Import serialized channel signing information (to allow signing new claims to the channel)\n\nArgs:\n 'serialized_certificate_info' : (str) certificate info\n\nReturns:\n (dict) Result dictionary",
"title": "channel_import"
},
{
"location": "/#channel_list",
"text": "Get certificate claim infos for channels that can be published to\n\nArgs:\n None\n\nReturns:\n (list) ClaimDict, includes 'is_mine' field to indicate if the certificate claim\n is in the wallet.",
"title": "channel_list"
},
{
"location": "/#channel_new",
"text": "Generate a publisher key and create a new '@' prefixed certificate claim\n\nArgs:\n 'channel_name' (required) : (str) name of the channel prefixed with '@'\n 'amount' (required) : (float) bid amount on the channel\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n }",
"title": "channel_new"
},
{
"location": "/#claim_abandon",
"text": "Abandon a name and reclaim credits from the claim\n\nArgs:\n 'claim_id' : (str) claim_id of the claim to abandon\n 'txid' : (str) txid of the claim to abandon\n 'nout' : (int) nout of the claim to abandon\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n txid : (str) txid of resulting transaction\n fee : (float) fee paid for the transaction\n }",
"title": "claim_abandon"
},
{
"location": "/#claim_list",
"text": "List current claims and information about them for a given name\n\nArgs:\n 'name' (required) : (str) name of the claim to list info about\n\nReturns:\n (dict) State of claims assigned for the name\n {\n 'claims': (list) list of claims for the name\n [\n {\n 'amount': (float) amount assigned to the claim\n 'effective_amount': (float) total amount assigned to the claim,\n including supports\n 'claim_id': (str) claim ID of the claim\n 'height': (int) height of block containing the claim\n 'txid': (str) txid of the claim\n 'nout': (int) nout of the claim\n 'permanent_url': (str) permanent url of the claim,\n 'supports': (list) a list of supports attached to the claim\n 'value': (str) the value of the claim\n },\n ]\n 'supports_without_claims': (list) supports without any claims attached to them\n 'last_takeover_height': (int) the height of last takeover for the name\n }",
"title": "claim_list"
},
{
"location": "/#claim_list_by_channel",
"text": "Get paginated claims in a channel specified by a channel uri\n\nArgs:\n 'uri' (required) : (str) uri of the channel\n 'uris' : (list) uris of the channel\n 'page' : (int) which page of results to return where page 1 is the first\n page, defaults to no pages\n 'page_size' : (int) number of results in a page, default of 10\n\nReturns:\n {\n resolved channel uri: {\n If there was an error:\n 'error': (str) error message\n\n 'claims_in_channel': the total number of results for the channel,\n\n If a page of results was requested:\n 'returned_page': page number returned,\n 'claims_in_channel': [\n {\n 'absolute_channel_position': (int) claim index number in sorted list of\n claims which assert to be part of the\n channel\n 'address': (str) claim address,\n 'amount': (float) claim amount,\n 'effective_amount': (float) claim amount including supports,\n 'claim_id': (str) claim id,\n 'claim_sequence': (int) claim sequence number,\n 'decoded_claim': (bool) whether or not the claim value was decoded,\n 'height': (int) claim height,\n 'depth': (int) claim depth,\n 'has_signature': (bool) included if decoded_claim\n 'name': (str) claim name,\n 'supports: (list) list of supports [{'txid': (str) txid,\n 'nout': (int) nout,\n 'amount': (float) amount}],\n 'txid': (str) claim txid,\n 'nout': (str) claim nout,\n 'signature_is_valid': (bool), included if has_signature,\n 'value': ClaimDict if decoded, otherwise hex string\n }\n ],\n }\n }",
"title": "claim_list_by_channel"
},
{
"location": "/#claim_list_mine",
"text": "List my name claims\n\nArgs:\n None\n\nReturns:\n (list) List of name claims owned by user\n [\n {\n 'address': (str) address that owns the claim\n 'amount': (float) amount assigned to the claim\n 'blocks_to_expiration': (int) number of blocks until it expires\n 'category': (str) claim , update , or support \n 'claim_id': (str) claim ID of the claim\n 'confirmations': (int) number of blocks of confirmations for the claim\n 'expiration_height': (int) the block height which the claim will expire\n 'expired': (bool) true if expired, false otherwise\n 'height': (int) height of the block containing the claim\n 'is_spent': (bool) true if claim is abandoned, false otherwise\n 'name': (str) name of the claim\n 'permanent_url': (str) permanent url of the claim,\n 'txid': (str) txid of the cliam\n 'nout': (int) nout of the claim\n 'value': (str) value of the claim\n },\n ]",
"title": "claim_list_mine"
},
{
"location": "/#claim_new_support",
"text": "Support a name claim\n\nArgs:\n 'name' (required) : (str) name of the claim to support\n 'claim_id' (required) : (str) claim_id of the claim to support\n 'amount' (required) : (float) amount of support\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n txid : (str) txid of resulting support claim\n nout : (int) nout of the resulting support claim\n fee : (float) fee paid for the transaction\n }",
"title": "claim_new_support"
},
{
"location": "/#claim_renew",
"text": "Renew claim(s) or support(s)\n\nArgs:\n 'outpoint' (required) : (str) outpoint of the claim to renew\n 'height' (required) : (str) update claims expiring before or at this block height\n\nReturns:\n (dict) Dictionary where key is the the original claim's outpoint and\n value is the result of the renewal\n {\n outpoint:{\n\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n },\n }",
"title": "claim_renew"
},
{
"location": "/#claim_send_to_address",
"text": "Send a name claim to an address\n\nArgs:\n 'claim_id' (required) : (str) claim_id to send\n 'address' (required) : (str) address to send the claim to\n 'amount' : (int) Amount of credits to claim name for, defaults to the current amount\n on the claim\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n }",
"title": "claim_send_to_address"
},
{
"location": "/#claim_show",
"text": "Resolve claim info from txid/nout or with claim ID\n\nArgs:\n 'txid' : (str) look for claim with this txid, nout must\n also be specified\n 'nout' : (int) look for claim with this nout, txid must\n also be specified\n 'claim_id' : (str) look for claim with this claim id\n\nReturns:\n (dict) Dictionary containing claim info as below,\n\n {\n 'txid': (str) txid of claim\n 'nout': (int) nout of claim\n 'amount': (float) amount of claim\n 'value': (str) value of claim\n 'height' : (int) height of claim takeover\n 'claim_id': (str) claim ID of claim\n 'supports': (list) list of supports associated with claim\n }\n\n if claim cannot be resolved, dictionary as below will be returned\n\n {\n 'error': (str) reason for error\n }",
"title": "claim_show"
},
{
"location": "/#cli_test_command",
"text": "This command is only for testing the CLI argument parsing\nArgs:\n 'a_arg' : a arg\n 'b_arg' : b arg\n 'pos_arg' (required) : pos arg\n 'pos_args' : pos args\n 'pos_arg2' : pos arg 2\n 'pos_arg3' : pos arg 3\n\nReturns:\n pos args",
"title": "cli_test_command"
},
{
"location": "/#commands",
"text": "Return a list of available commands\n\nArgs:\n None\n\nReturns:\n (list) list of available commands",
"title": "commands"
},
{
"location": "/#daemon_stop",
"text": "Stop lbrynet-daemon\n\nArgs:\n None\n\nReturns:\n (string) Shutdown message",
"title": "daemon_stop"
},
{
"location": "/#file_delete",
"text": "Delete a LBRY file\n\nArgs:\n 'delete_from_download_dir' : (bool) delete file from download directory,\n instead of just deleting blobs\n 'delete_all' : (bool) if there are multiple matching files,\n allow the deletion of multiple files.\n Otherwise do not delete anything.\n 'sd_hash' : (str) delete by file sd hash\n 'file_name' : (str) delete by file name in downloads folder\n 'stream_hash' : (str) delete by file stream hash\n 'rowid' : (int) delete by file row id\n 'claim_id' : (str) delete by file claim id\n 'txid' : (str) delete by file claim txid\n 'nout' : (int) delete by file claim nout\n 'claim_name' : (str) delete by file claim name\n 'channel_claim_id' : (str) delete by file channel claim id\n 'channel_name' : (str) delete by file channel claim name\n\nReturns:\n (bool) true if deletion was successful",
"title": "file_delete"
},
{
"location": "/#file_list",
"text": "List files limited by optional filters\n\nArgs:\n 'sd_hash' : (str) get file with matching sd hash\n 'file_name' : (str) get file with matching file name in the\n downloads folder\n 'stream_hash' : (str) get file with matching stream hash\n 'rowid' : (int) get file with matching row id\n 'claim_id' : (str) get file with matching claim id\n 'outpoint' : (str) get file with matching claim outpoint\n 'txid' : (str) get file with matching claim txid\n 'nout' : (int) get file with matching claim nout\n 'channel_claim_id' : (str) get file with matching channel claim id\n 'channel_name' : (str) get file with matching channel name\n 'claim_name' : (str) get file with matching claim name\n 'full_status' : (bool) full status, populate the\n 'message' and 'size' fields\n\nReturns:\n (list) List of files\n\n [\n {\n 'completed': (bool) true if download is completed,\n 'file_name': (str) name of file,\n 'download_directory': (str) download directory,\n 'points_paid': (float) credit paid to download file,\n 'stopped': (bool) true if download is stopped,\n 'stream_hash': (str) stream hash of file,\n 'stream_name': (str) stream name ,\n 'suggested_file_name': (str) suggested file name,\n 'sd_hash': (str) sd hash of file,\n 'download_path': (str) download path of file,\n 'mime_type': (str) mime type of file,\n 'key': (str) key attached to file,\n 'total_bytes': (int) file size in bytes, None if full_status is false,\n 'written_bytes': (int) written size in bytes,\n 'blobs_completed': (int) num_completed, None if full_status is false,\n 'blobs_in_stream': (int) None if full_status is false,\n 'status': (str) downloader status, None if full_status is false,\n 'claim_id': (str) None if full_status is false or if claim is not found,\n 'outpoint': (str) None if full_status is false or if claim is not found,\n 'txid': (str) None if full_status is false or if claim is not found,\n 'nout': (int) None if full_status is false or if claim is not found,\n 'metadata': (dict) None if full_status is false or if claim is not found,\n 'channel_claim_id': (str) None if full_status is false or if claim is not found or signed,\n 'channel_name': (str) None if full_status is false or if claim is not found or signed,\n 'claim_name': (str) None if full_status is false or if claim is not found\n },\n ]",
"title": "file_list"
},
{
"location": "/#file_reflect",
"text": "Reflect all the blobs in a file matching the filter criteria\n\nArgs:\n 'sd_hash' : (str) get file with matching sd hash\n 'file_name' : (str) get file with matching file name in the\n downloads folder\n 'stream_hash' : (str) get file with matching stream hash\n 'rowid' : (int) get file with matching row id\n 'reflector' : (str) reflector server, ip address or url\n by default choose a server from the config\n\nReturns:\n (list) list of blobs reflected",
"title": "file_reflect"
},
{
"location": "/#file_set_status",
"text": "Start or stop downloading a file\n\nArgs:\n 'status' (required) : (str) one of start or stop \n 'sd_hash' : (str) set status of file with matching sd hash\n 'file_name' : (str) set status of file with matching file name in the\n downloads folder\n 'stream_hash' : (str) set status of file with matching stream hash\n 'rowid' : (int) set status of file with matching row id\n\nReturns:\n (str) Confirmation message",
"title": "file_set_status"
},
{
"location": "/#get",
"text": "Download stream from a LBRY name.\n\nArgs:\n 'uri' : (str) uri of the content to download\n 'file_name' : (str) specified name for the downloaded file\n 'timeout' : (int) download timeout in number of seconds\n\nReturns:\n (dict) Dictionary containing information about the stream\n {\n 'completed': (bool) true if download is completed,\n 'file_name': (str) name of file,\n 'download_directory': (str) download directory,\n 'points_paid': (float) credit paid to download file,\n 'stopped': (bool) true if download is stopped,\n 'stream_hash': (str) stream hash of file,\n 'stream_name': (str) stream name ,\n 'suggested_file_name': (str) suggested file name,\n 'sd_hash': (str) sd hash of file,\n 'download_path': (str) download path of file,\n 'mime_type': (str) mime type of file,\n 'key': (str) key attached to file,\n 'total_bytes': (int) file size in bytes, None if full_status is false,\n 'written_bytes': (int) written size in bytes,\n 'blobs_completed': (int) num_completed, None if full_status is false,\n 'blobs_in_stream': (int) None if full_status is false,\n 'status': (str) downloader status, None if full_status is false,\n 'claim_id': (str) claim id,\n 'outpoint': (str) claim outpoint string,\n 'txid': (str) claim txid,\n 'nout': (int) claim nout,\n 'metadata': (dict) claim metadata,\n 'channel_claim_id': (str) None if claim is not signed\n 'channel_name': (str) None if claim is not signed\n 'claim_name': (str) claim name\n }",
"title": "get"
},
{
"location": "/#help",
"text": "Return a useful message for an API command\n\nArgs:\n 'command' : (str) command to retrieve documentation for\n\nReturns:\n (str) Help message",
"title": "help"
},
{
"location": "/#peer_list",
"text": "Get peers for blob hash\n\nArgs:\n 'blob_hash' (required) : (str) find available peers for this blob hash\n 'timeout' : (int) peer search timeout in seconds\n\nReturns:\n (list) List of contacts",
"title": "peer_list"
},
{
"location": "/#publish",
"text": "Make a new name claim and publish associated data to lbrynet,\nupdate over existing claim if user already has a claim for name.\n\nFields required in the final Metadata are:\n 'title'\n 'description'\n 'author'\n 'language'\n 'license'\n 'nsfw'\n\nMetadata can be set by either using the metadata argument or by setting individual arguments\nfee, title, description, author, language, license, license_url, thumbnail, preview, nsfw,\nor sources. Individual arguments will overwrite the fields specified in metadata argument.\n\nArgs:\n 'name' (required) : (str) name of the content\n 'bid' (required) : (float) amount to back the claim\n 'metadata' : (dict) ClaimDict to associate with the claim.\n 'file_path' : (str) path to file to be associated with name. If provided,\n a lbry stream of this file will be used in 'sources'.\n If no path is given but a sources dict is provided,\n it will be used. If neither are provided, an\n error is raised.\n 'fee' : (dict) Dictionary representing key fee to download content:\n {\n 'currency': currency_symbol,\n 'amount': float,\n 'address': str, optional\n }\n supported currencies: LBC, USD, BTC\n If an address is not provided a new one will be\n automatically generated. Default fee is zero.\n 'title' : (str) title of the publication\n 'description' : (str) description of the publication\n 'author' : (str) author of the publication\n 'language' : (str) language of the publication\n 'license' : (str) publication license\n 'license_url' : (str) publication license url\n 'thumbnail' : (str) thumbnail url\n 'preview' : (str) preview url\n 'nsfw' : (bool) title of the publication\n 'sources' : (str) {'lbry_sd_hash': sd_hash} specifies sd hash of file\n 'channel_name' : (str) name of the publisher channel name in the wallet\n 'channel_id' : (str) claim id of the publisher channel, does not check\n for channel claim being in the wallet. This allows\n publishing to a channel where only the certificate\n private key is in the wallet.\n 'claim_address' : (str) address where the claim is sent to, if not specified\n new address wil automatically be created\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n }",
"title": "publish"
},
{
"location": "/#resolve",
"text": "Resolve given LBRY URIs\n\nArgs:\n 'force' : (bool) force refresh and ignore cache\n 'uri' (required) : (str) uri to resolve\n 'uris' : (list) uris to resolve\n\nReturns:\n Dictionary of results, keyed by uri\n ' uri ': {\n If a resolution error occurs:\n 'error': Error message\n\n If the uri resolves to a channel or a claim in a channel:\n 'certificate': {\n 'address': (str) claim address,\n 'amount': (float) claim amount,\n 'effective_amount': (float) claim amount including supports,\n 'claim_id': (str) claim id,\n 'claim_sequence': (int) claim sequence number,\n 'decoded_claim': (bool) whether or not the claim value was decoded,\n 'height': (int) claim height,\n 'depth': (int) claim depth,\n 'has_signature': (bool) included if decoded_claim\n 'name': (str) claim name,\n 'permanent_url': (str) permanent url of the certificate claim,\n 'supports: (list) list of supports [{'txid': (str) txid,\n 'nout': (int) nout,\n 'amount': (float) amount}],\n 'txid': (str) claim txid,\n 'nout': (str) claim nout,\n 'signature_is_valid': (bool), included if has_signature,\n 'value': ClaimDict if decoded, otherwise hex string\n }\n\n If the uri resolves to a channel:\n 'claims_in_channel': (int) number of claims in the channel,\n\n If the uri resolves to a claim:\n 'claim': {\n 'address': (str) claim address,\n 'amount': (float) claim amount,\n 'effective_amount': (float) claim amount including supports,\n 'claim_id': (str) claim id,\n 'claim_sequence': (int) claim sequence number,\n 'decoded_claim': (bool) whether or not the claim value was decoded,\n 'height': (int) claim height,\n 'depth': (int) claim depth,\n 'has_signature': (bool) included if decoded_claim\n 'name': (str) claim name,\n 'permanent_url': (str) permanent url of the claim,\n 'channel_name': (str) channel name if claim is in a channel\n 'supports: (list) list of supports [{'txid': (str) txid,\n 'nout': (int) nout,\n 'amount': (float) amount}]\n 'txid': (str) claim txid,\n 'nout': (str) claim nout,\n 'signature_is_valid': (bool), included if has_signature,\n 'value': ClaimDict if decoded, otherwise hex string\n }\n }",
"title": "resolve"
},
{
"location": "/#resolve_name",
"text": "Resolve stream info from a LBRY name\n\nArgs:\n 'name' (required) : (str) the name to resolve\n 'force' : (bool) force refresh and do not check cache\n\nReturns:\n (dict) Metadata dictionary from name claim, None if the name is not\n resolvable",
"title": "resolve_name"
},
{
"location": "/#routing_table_get",
"text": "Get DHT routing information\n\nArgs:\n None\n\nReturns:\n (dict) dictionary containing routing and contact information\n {\n buckets : {\n bucket index : [\n {\n address : (str) peer address,\n node_id : (str) peer node id,\n blobs : (list) blob hashes announced by peer\n }\n ]\n },\n contacts : (list) contact node ids,\n blob_hashes : (list) all of the blob hashes stored by peers in the list of buckets,\n node_id : (str) the local dht node id\n }",
"title": "routing_table_get"
},
{
"location": "/#settings_get",
"text": "Get daemon settings\n\nArgs:\n None\n\nReturns:\n (dict) Dictionary of daemon settings\n See ADJUSTABLE_SETTINGS in lbrynet/conf.py for full list of settings",
"title": "settings_get"
},
{
"location": "/#settings_set",
"text": "Set daemon settings\n\nArgs:\n 'download_directory' : (str) path of download directory\n 'data_rate' : (float) 0.0001\n 'download_timeout' : (int) 180\n 'peer_port' : (int) 3333\n 'max_key_fee' : (dict) maximum key fee for downloads,\n in the format:\n {\n 'currency': currency_symbol ,\n 'amount': amount \n }.\n In the CLI, it must be an escaped JSON string\n Supported currency symbols: LBC, USD, BTC\n 'disable_max_key_fee' : (bool) False\n 'use_upnp' : (bool) True\n 'run_reflector_server' : (bool) False\n 'cache_time' : (int) 150\n 'reflect_uploads' : (bool) True\n 'share_usage_data' : (bool) True\n 'peer_search_timeout' : (int) 3\n 'sd_download_timeout' : (int) 3\n 'auto_renew_claim_height_delta' : (int) 0\n claims set to expire within this many blocks will be\n automatically renewed after startup (if set to 0, renews\n will not be made automatically)\n\nReturns:\n (dict) Updated dictionary of daemon settings",
"title": "settings_set"
},
{
"location": "/#status",
"text": "Get daemon status\n\nArgs:\n 'session_status' : (bool) include session status in results\n 'dht_status' : (bool) include dht network and peer status\n\nReturns:\n (dict) lbrynet-daemon status\n {\n 'lbry_id': lbry peer id, base58,\n 'installation_id': installation id, base58,\n 'is_running': bool,\n 'is_first_run': bool,\n 'startup_status': {\n 'code': status code,\n 'message': status message\n },\n 'connection_status': {\n 'code': connection status code,\n 'message': connection status message\n },\n 'blockchain_status': {\n 'blocks': local blockchain height,\n 'blocks_behind': remote_height - local_height,\n 'best_blockhash': block hash of most recent block,\n },\n 'wallet_is_encrypted': bool,\n\n If given the session status option:\n 'session_status': {\n 'managed_blobs': count of blobs in the blob manager,\n 'managed_streams': count of streams in the file manager\n 'announce_queue_size': number of blobs currently queued to be announced\n 'should_announce_blobs': number of blobs that should be announced\n }\n\n If given the dht status option:\n 'dht_status': {\n 'kbps_received': current kbps receiving,\n 'kbps_sent': current kdps being sent,\n 'total_bytes_sent': total bytes sent,\n 'total_bytes_received': total bytes received,\n 'queries_received': number of queries received per second,\n 'queries_sent': number of queries sent per second,\n 'recent_contacts': count of recently contacted peers,\n 'unique_contacts': count of unique peers\n },\n }",
"title": "status"
},
{
"location": "/#stream_availability",
"text": "Get stream availability for lbry uri\n\nArgs:\n 'uri' (required) : (str) check availability for this uri\n 'search_timeout' : (int) how long to search for peers for the blob\n in the dht\n 'search_timeout' : (int) how long to try downloading from a peer\n\nReturns:\n (dict) {\n 'is_available': bool ,\n 'did_decode': bool ,\n 'did_resolve': bool ,\n 'is_stream': bool ,\n 'num_blobs_in_stream': int ,\n 'sd_hash': str ,\n 'sd_blob_availability': dict see `blob_availability`,\n 'head_blob_hash': str ,\n 'head_blob_availability': dict see `blob_availability`,\n 'use_upnp': bool ,\n 'upnp_redirect_is_set': bool ,\n 'error': None | str error message\n }",
"title": "stream_availability"
},
{
"location": "/#stream_cost_estimate",
"text": "Get estimated cost for a lbry stream\n\nArgs:\n 'uri' (required) : (str) uri to use\n 'size' : (float) stream size in bytes. if provided an sd blob won't be\n downloaded.\n\nReturns:\n (float) Estimated cost in lbry credits, returns None if uri is not\n resolvable",
"title": "stream_cost_estimate"
},
{
"location": "/#transaction_list",
"text": "List transactions belonging to wallet\n\nArgs:\n None\n\nReturns:\n (list) List of transactions\n\n {\n claim_info : (list) claim info if in txn [{\n address : (str) address of claim,\n balance_delta : (float) bid amount,\n amount : (float) claim amount,\n claim_id : (str) claim id,\n claim_name : (str) claim name,\n nout : (int) nout\n }],\n abandon_info : (list) abandon info if in txn [{\n address : (str) address of abandoned claim,\n balance_delta : (float) returned amount,\n amount : (float) claim amount,\n claim_id : (str) claim id,\n claim_name : (str) claim name,\n nout : (int) nout\n }],\n confirmations : (int) number of confirmations for the txn,\n date : (str) date and time of txn,\n fee : (float) txn fee,\n support_info : (list) support info if in txn [{\n address : (str) address of support,\n balance_delta : (float) support amount,\n amount : (float) support amount,\n claim_id : (str) claim id,\n claim_name : (str) claim name,\n is_tip : (bool),\n nout : (int) nout\n }],\n timestamp : (int) timestamp,\n txid : (str) txn id,\n update_info : (list) update info if in txn [{\n address : (str) address of claim,\n balance_delta : (float) credited/debited\n amount : (float) absolute amount,\n claim_id : (str) claim id,\n claim_name : (str) claim name,\n nout : (int) nout\n }],\n value : (float) value of txn\n }",
"title": "transaction_list"
},
{
"location": "/#transaction_show",
"text": "Get a decoded transaction from a txid\n\nArgs:\n 'txid' (required) : (str) txid of the transaction\n\nReturns:\n (dict) JSON formatted transaction",
"title": "transaction_show"
},
{
"location": "/#utxo_list",
"text": "List unspent transaction outputs\n\nArgs:\n None\n\nReturns:\n (list) List of unspent transaction outputs (UTXOs)\n [\n {\n address : (str) the output address\n amount : (float) unspent amount\n height : (int) block height\n is_claim : (bool) is the tx a claim\n is_coinbase : (bool) is the tx a coinbase tx\n is_support : (bool) is the tx a support\n is_update : (bool) is the tx an update\n nout : (int) nout of the output\n txid : (str) txid of the output\n },\n ...\n ]",
"title": "utxo_list"
},
{
"location": "/#version",
"text": "Get lbry version information\n\nArgs:\n None\n\nReturns:\n (dict) Dictionary of lbry version information\n {\n 'build': (str) build type (e.g. dev , rc , release ),\n 'ip': (str) remote ip, if available,\n 'lbrynet_version': (str) lbrynet_version,\n 'lbryum_version': (str) lbryum_version,\n 'lbryschema_version': (str) lbryschema_version,\n 'os_release': (str) os release string\n 'os_system': (str) os name\n 'platform': (str) platform string\n 'processor': (str) processor type,\n 'python_version': (str) python version,\n }",
"title": "version"
},
{
"location": "/#wallet_balance",
"text": "Return the balance of the wallet\n\nArgs:\n 'address' : (str) If provided only the balance for this\n address will be given\n 'include_unconfirmed' : (bool) Include unconfirmed\n\nReturns:\n (float) amount of lbry credits in wallet",
"title": "wallet_balance"
},
{
"location": "/#wallet_decrypt",
"text": "Decrypt an encrypted wallet, this will remove the wallet password\n\nArgs:\n None\n\nReturns:\n (bool) true if wallet is decrypted, otherwise false",
"title": "wallet_decrypt"
},
{
"location": "/#wallet_encrypt",
"text": "Encrypt a wallet with a password, if the wallet is already encrypted this will update\nthe password\n\nArgs:\n 'new_password' (required) : (str) password string to be used for encrypting wallet\n\nReturns:\n (bool) true if wallet is decrypted, otherwise false",
"title": "wallet_encrypt"
},
{
"location": "/#wallet_is_address_mine",
"text": "Checks if an address is associated with the current wallet.\n\nArgs:\n 'address' (required) : (str) address to check\n\nReturns:\n (bool) true, if address is associated with current wallet",
"title": "wallet_is_address_mine"
},
{
"location": "/#wallet_list",
"text": "List wallet addresses\n\nArgs:\n None\n\nReturns:\n List of wallet addresses",
"title": "wallet_list"
},
{
"location": "/#wallet_new_address",
"text": "Generate a new wallet address\n\nArgs:\n None\n\nReturns:\n (str) New wallet address in base58",
"title": "wallet_new_address"
},
{
"location": "/#wallet_prefill_addresses",
"text": "Create new addresses, each containing `amount` credits\n\nArgs:\n 'no_broadcast' : (bool) whether to broadcast or not\n 'num_addresses' (required) : (int) num of addresses to create\n 'amount' (required) : (float) initial amount in each address\n\nReturns:\n (dict) the resulting transaction",
"title": "wallet_prefill_addresses"
},
{
"location": "/#wallet_public_key",
"text": "Get public key from wallet address\n\nArgs:\n 'address' (required) : (str) address for which to get the public key\n\nReturns:\n (list) list of public keys associated with address.\n Could contain more than one public key if multisig.",
"title": "wallet_public_key"
},
{
"location": "/#wallet_send",
"text": "Send credits. If given an address, send credits to it. If given a claim id, send a tip\nto the owner of a claim specified by uri. A tip is a claim support where the recipient\nof the support is the claim address for the claim being supported.\n\nArgs:\n 'amount' (required) : (float) amount of credit to send\n 'address' (required) : (str) address to send credits to\n 'claim_id' (required) : (float) claim_id of the claim to send to tip to\n\nReturns:\n If sending to an address:\n (bool) true if payment successfully scheduled\n\n If sending a claim tip:\n (dict) Dictionary containing the result of the support\n {\n txid : (str) txid of resulting support claim\n nout : (int) nout of the resulting support claim\n fee : (float) fee paid for the transaction\n }",
"title": "wallet_send"
},
{
"location": "/#wallet_unlock",
"text": "Unlock an encrypted wallet\n\nArgs:\n 'password' (required) : (str) password for unlocking wallet\n\nReturns:\n (bool) true if wallet is unlocked, otherwise false",
"title": "wallet_unlock"
},
{
"location": "/#wallet_unused_address",
"text": "Return an address containing no balance, will create\na new address if there is none.\n\nArgs:\n None\n\nReturns:\n (str) Unused wallet address in base58",
"title": "wallet_unused_address"
},
{
"location": "/cli/",
"text": "LBRY JSON-RPC API Documentation\n\n\nblob_announce\n\n\nAnnounce blobs to the DHT\n\nUsage:\n blob_announce [--announce_all] [\nblob_hash\n | --blob_hash=\nblob_hash\n]\n [\nstream_hash\n | --stream_hash=\nstream_hash\n]\n [\nsd_hash\n | --sd_hash=\nsd_hash\n]\n\n\nOptions:\n --announce_all=\nannounce_all\n : (bool) announce all the blobs possessed by user\n --blob_hash=\nblob_hash\n : (str) announce a blob, specified by blob_hash\n --stream_hash=\nstream_hash\n : (str) announce all blobs associated with\n stream_hash\n --sd_hash=\nsd_hash\n : (str) announce all blobs associated with\n sd_hash and the sd_hash itself\n\nReturns:\n (bool) true if successful\n\n\n\n\nblob_availability\n\n\nGet blob availability\n\nUsage:\n blob_availability (\nblob_hash\n) [\nsearch_timeout\n | --search_timeout=\nsearch_timeout\n]\n [\nblob_timeout\n | --blob_timeout=\nblob_timeout\n]\n\n\nOptions:\n --blob_hash=\nblob_hash\n : (str) check availability for this blob hash\n --search_timeout=\nsearch_timeout\n : (int) how long to search for peers for the blob\n in the dht\n --blob_timeout=\nblob_timeout\n : (int) how long to try downloading from a peer\n\nReturns:\n (dict) {\n \nis_available\n: \nbool, true if blob is available from a peer from peer list\n\n \nreachable_peers\n: [\nip\n:\nport\n],\n \nunreachable_peers\n: [\nip\n:\nport\n]\n }\n\n\n\n\nblob_delete\n\n\nDelete a blob\n\nUsage:\n blob_delete (\nblob_hash\n | --blob_hash=\nblob_hash)\n\n\nOptions:\n --blob_hash=\nblob_hash\n : (str) blob hash of the blob to delete\n\nReturns:\n (str) Success/fail message\n\n\n\n\nblob_get\n\n\nDownload and return a blob\n\nUsage:\n blob_get (\nblob_hash\n | --blob_hash=\nblob_hash\n) [--timeout=\ntimeout\n]\n [--encoding=\nencoding\n] [--payment_rate_manager=\npayment_rate_manager\n]\n\n\nOptions:\n --blob_hash=\nblob_hash\n : (str) blob hash of the blob to get\n --timeout=\ntimeout\n : (int) timeout in number of seconds\n --encoding=\nencoding\n : (str) by default no attempt at decoding\n is made, can be set to one of the\n following decoders:\n 'json'\n --payment_rate_manager=\npayment_rate_manager\n : (str) if not given the default payment rate\n manager will be used.\n supported alternative rate managers:\n 'only-free'\n\nReturns:\n (str) Success/Fail message or (dict) decoded data\n\n\n\n\nblob_list\n\n\nReturns blob hashes. If not given filters, returns all blobs known by the blob manager\n\nUsage:\n blob_list [--needed] [--finished] [\nuri\n | --uri=\nuri\n]\n [\nstream_hash\n | --stream_hash=\nstream_hash\n]\n [\nsd_hash\n | --sd_hash=\nsd_hash\n]\n [\npage_size\n | --page_size=\npage_size\n]\n [\npage\n | --page=\npage\n]\n\n\nOptions:\n --needed : (bool) only return needed blobs\n --finished : (bool) only return finished blobs\n --uri=\nuri\n : (str) filter blobs by stream in a uri\n --stream_hash=\nstream_hash\n : (str) filter blobs by stream hash\n --sd_hash=\nsd_hash\n : (str) filter blobs by sd hash\n --page_size=\npage_size\n : (int) results page size\n --page=\npage\n : (int) page of results to return\n\nReturns:\n (list) List of blob hashes\n\n\n\n\nblob_reflect_all\n\n\nReflects all saved blobs\n\nUsage:\n blob_reflect_all\n\n\nOptions:\n None\n\nReturns:\n (bool) true if successful\n\n\n\n\nblock_show\n\n\nGet contents of a block\n\nUsage:\n block_show (\nblockhash\n | --blockhash=\nblockhash\n) | (\nheight\n | --height=\nheight\n)\n\n\nOptions:\n --blockhash=\nblockhash\n : (str) hash of the block to look up\n --height=\nheight\n : (int) height of the block to look up\n\nReturns:\n (dict) Requested block\n\n\n\n\nchannel_export\n\n\nExport serialized channel signing information for a given certificate claim id\n\nUsage:\n channel_export (\nclaim_id\n | --claim_id=\nclaim_id\n)\n\n\nOptions:\n --claim_id=\nclaim_id\n : (str) Claim ID to export information about\n\nReturns:\n (str) Serialized certificate information\n\n\n\n\nchannel_import\n\n\nImport serialized channel signing informatLine truncated
"title": "CLI"
},
{
"location": "/cli/#lbry-json-rpc-api-documentation",
"text": "",
"title": "LBRY JSON-RPC API Documentation"
},
{
"location": "/cli/#blob_announce",
"text": "Announce blobs to the DHT\n\nUsage:\n blob_announce [--announce_all] [ blob_hash | --blob_hash= blob_hash ]\n [ stream_hash | --stream_hash= stream_hash ]\n [ sd_hash | --sd_hash= sd_hash ]\n\n\nOptions:\n --announce_all= announce_all : (bool) announce all the blobs possessed by user\n --blob_hash= blob_hash : (str) announce a blob, specified by blob_hash\n --stream_hash= stream_hash : (str) announce all blobs associated with\n stream_hash\n --sd_hash= sd_hash : (str) announce all blobs associated with\n sd_hash and the sd_hash itself\n\nReturns:\n (bool) true if successful",
"title": "blob_announce"
},
{
"location": "/cli/#blob_availability",
"text": "Get blob availability\n\nUsage:\n blob_availability ( blob_hash ) [ search_timeout | --search_timeout= search_timeout ]\n [ blob_timeout | --blob_timeout= blob_timeout ]\n\n\nOptions:\n --blob_hash= blob_hash : (str) check availability for this blob hash\n --search_timeout= search_timeout : (int) how long to search for peers for the blob\n in the dht\n --blob_timeout= blob_timeout : (int) how long to try downloading from a peer\n\nReturns:\n (dict) {\n is_available : bool, true if blob is available from a peer from peer list \n reachable_peers : [ ip : port ],\n unreachable_peers : [ ip : port ]\n }",
"title": "blob_availability"
},
{
"location": "/cli/#blob_delete",
"text": "Delete a blob\n\nUsage:\n blob_delete ( blob_hash | --blob_hash= blob_hash)\n\n\nOptions:\n --blob_hash= blob_hash : (str) blob hash of the blob to delete\n\nReturns:\n (str) Success/fail message",
"title": "blob_delete"
},
{
"location": "/cli/#blob_get",
"text": "Download and return a blob\n\nUsage:\n blob_get ( blob_hash | --blob_hash= blob_hash ) [--timeout= timeout ]\n [--encoding= encoding ] [--payment_rate_manager= payment_rate_manager ]\n\n\nOptions:\n --blob_hash= blob_hash : (str) blob hash of the blob to get\n --timeout= timeout : (int) timeout in number of seconds\n --encoding= encoding : (str) by default no attempt at decoding\n is made, can be set to one of the\n following decoders:\n 'json'\n --payment_rate_manager= payment_rate_manager : (str) if not given the default payment rate\n manager will be used.\n supported alternative rate managers:\n 'only-free'\n\nReturns:\n (str) Success/Fail message or (dict) decoded data",
"title": "blob_get"
},
{
"location": "/cli/#blob_list",
"text": "Returns blob hashes. If not given filters, returns all blobs known by the blob manager\n\nUsage:\n blob_list [--needed] [--finished] [ uri | --uri= uri ]\n [ stream_hash | --stream_hash= stream_hash ]\n [ sd_hash | --sd_hash= sd_hash ]\n [ page_size | --page_size= page_size ]\n [ page | --page= page ]\n\n\nOptions:\n --needed : (bool) only return needed blobs\n --finished : (bool) only return finished blobs\n --uri= uri : (str) filter blobs by stream in a uri\n --stream_hash= stream_hash : (str) filter blobs by stream hash\n --sd_hash= sd_hash : (str) filter blobs by sd hash\n --page_size= page_size : (int) results page size\n --page= page : (int) page of results to return\n\nReturns:\n (list) List of blob hashes",
"title": "blob_list"
},
{
"location": "/cli/#blob_reflect_all",
"text": "Reflects all saved blobs\n\nUsage:\n blob_reflect_all\n\n\nOptions:\n None\n\nReturns:\n (bool) true if successful",
"title": "blob_reflect_all"
},
{
"location": "/cli/#block_show",
"text": "Get contents of a block\n\nUsage:\n block_show ( blockhash | --blockhash= blockhash ) | ( height | --height= height )\n\n\nOptions:\n --blockhash= blockhash : (str) hash of the block to look up\n --height= height : (int) height of the block to look up\n\nReturns:\n (dict) Requested block",
"title": "block_show"
},
{
"location": "/cli/#channel_export",
"text": "Export serialized channel signing information for a given certificate claim id\n\nUsage:\n channel_export ( claim_id | --claim_id= claim_id )\n\n\nOptions:\n --claim_id= claim_id : (str) Claim ID to export information about\n\nReturns:\n (str) Serialized certificate information",
"title": "channel_export"
},
{
"location": "/cli/#channel_import",
"text": "Import serialized channel signing information (to allow signing new claims to the channel)\n\nUsage:\n channel_import ( serialized_certificate_info |\n --serialized_certificate_info= serialized_certificate_info )\n\n\nOptions:\n --serialized_certificate_info= serialized_certificate_info : (str) certificate info\n\nReturns:\n (dict) Result dictionary",
"title": "channel_import"
},
{
"location": "/cli/#channel_list",
"text": "Get certificate claim infos for channels that can be published to\n\nUsage:\n channel_list\n\n\nOptions:\n None\n\nReturns:\n (list) ClaimDict, includes 'is_mine' field to indicate if the certificate claim\n is in the wallet.",
"title": "channel_list"
},
{
"location": "/cli/#channel_new",
"text": "Generate a publisher key and create a new '@' prefixed certificate claim\n\nUsage:\n channel_new ( channel_name | --channel_name= channel_name )\n ( amount | --amount= amount )\n\n\nOptions:\n --channel_name= channel_name : (str) name of the channel prefixed with '@'\n --amount= amount : (float) bid amount on the channel\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n }",
"title": "channel_new"
},
{
"location": "/cli/#claim_abandon",
"text": "Abandon a name and reclaim credits from the claim\n\nUsage:\n claim_abandon [ claim_id | --claim_id= claim_id ]\n [ txid | --txid= txid ] [ nout | --nout= nout ]\n\n\nOptions:\n --claim_id= claim_id : (str) claim_id of the claim to abandon\n --txid= txid : (str) txid of the claim to abandon\n --nout= nout : (int) nout of the claim to abandon\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n txid : (str) txid of resulting transaction\n fee : (float) fee paid for the transaction\n }",
"title": "claim_abandon"
},
{
"location": "/cli/#claim_list",
"text": "List current claims and information about them for a given name\n\nUsage:\n claim_list ( name | --name= name )\n\n\nOptions:\n --name= name : (str) name of the claim to list info about\n\nReturns:\n (dict) State of claims assigned for the name\n {\n 'claims': (list) list of claims for the name\n [\n {\n 'amount': (float) amount assigned to the claim\n 'effective_amount': (float) total amount assigned to the claim,\n including supports\n 'claim_id': (str) claim ID of the claim\n 'height': (int) height of block containing the claim\n 'txid': (str) txid of the claim\n 'nout': (int) nout of the claim\n 'permanent_url': (str) permanent url of the claim,\n 'supports': (list) a list of supports attached to the claim\n 'value': (str) the value of the claim\n },\n ]\n 'supports_without_claims': (list) supports without any claims attached to them\n 'last_takeover_height': (int) the height of last takeover for the name\n }",
"title": "claim_list"
},
{
"location": "/cli/#claim_list_by_channel",
"text": "Get paginated claims in a channel specified by a channel uri\n\nUsage:\n claim_list_by_channel ( uri | --uri= uri ) [ uris ...] [--page= page ]\n [--page_size= page_size ]\n\n\nOptions:\n --uri= uri : (str) uri of the channel\n --uris= uris : (list) uris of the channel\n --page= page : (int) which page of results to return where page 1 is the first\n page, defaults to no pages\n --page_size= page_size : (int) number of results in a page, default of 10\n\nReturns:\n {\n resolved channel uri: {\n If there was an error:\n 'error': (str) error message\n\n 'claims_in_channel': the total number of results for the channel,\n\n If a page of results was requested:\n 'returned_page': page number returned,\n 'claims_in_channel': [\n {\n 'absolute_channel_position': (int) claim index number in sorted list of\n claims which assert to be part of the\n channel\n 'address': (str) claim address,\n 'amount': (float) claim amount,\n 'effective_amount': (float) claim amount including supports,\n 'claim_id': (str) claim id,\n 'claim_sequence': (int) claim sequence number,\n 'decoded_claim': (bool) whether or not the claim value was decoded,\n 'height': (int) claim height,\n 'depth': (int) claim depth,\n 'has_signature': (bool) included if decoded_claim\n 'name': (str) claim name,\n 'supports: (list) list of supports [{'txid': (str) txid,\n 'nout': (int) nout,\n 'amount': (float) amount}],\n 'txid': (str) claim txid,\n 'nout': (str) claim nout,\n 'signature_is_valid': (bool), included if has_signature,\n 'value': ClaimDict if decoded, otherwise hex string\n }\n ],\n }\n }",
"title": "claim_list_by_channel"
},
{
"location": "/cli/#claim_list_mine",
"text": "List my name claims\n\nUsage:\n claim_list_mine\n\n\nOptions:\n None\n\nReturns:\n (list) List of name claims owned by user\n [\n {\n 'address': (str) address that owns the claim\n 'amount': (float) amount assigned to the claim\n 'blocks_to_expiration': (int) number of blocks until it expires\n 'category': (str) claim , update , or support \n 'claim_id': (str) claim ID of the claim\n 'confirmations': (int) number of blocks of confirmations for the claim\n 'expiration_height': (int) the block height which the claim will expire\n 'expired': (bool) true if expired, false otherwise\n 'height': (int) height of the block containing the claim\n 'is_spent': (bool) true if claim is abandoned, false otherwise\n 'name': (str) name of the claim\n 'permanent_url': (str) permanent url of the claim,\n 'txid': (str) txid of the cliam\n 'nout': (int) nout of the claim\n 'value': (str) value of the claim\n },\n ]",
"title": "claim_list_mine"
},
{
"location": "/cli/#claim_new_support",
"text": "Support a name claim\n\nUsage:\n claim_new_support ( name | --name= name ) ( claim_id | --claim_id= claim_id )\n ( amount | --amount= amount )\n\n\nOptions:\n --name= name : (str) name of the claim to support\n --claim_id= claim_id : (str) claim_id of the claim to support\n --amount= amount : (float) amount of support\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n txid : (str) txid of resulting support claim\n nout : (int) nout of the resulting support claim\n fee : (float) fee paid for the transaction\n }",
"title": "claim_new_support"
},
{
"location": "/cli/#claim_renew",
"text": "Renew claim(s) or support(s)\n\nUsage:\n claim_renew ( outpoint | --outpoint= outpoint ) | ( height | --height= height )\n\n\nOptions:\n --outpoint= outpoint : (str) outpoint of the claim to renew\n --height= height : (str) update claims expiring before or at this block height\n\nReturns:\n (dict) Dictionary where key is the the original claim's outpoint and\n value is the result of the renewal\n {\n outpoint:{\n\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n },\n }",
"title": "claim_renew"
},
{
"location": "/cli/#claim_send_to_address",
"text": "Send a name claim to an address\n\nUsage:\n claim_send_to_address ( claim_id | --claim_id= claim_id )\n ( address | --address= address )\n [ amount | --amount= amount ]\n\n\nOptions:\n --claim_id= claim_id : (str) claim_id to send\n --address= address : (str) address to send the claim to\n --amount amount : (int) Amount of credits to claim name for, defaults to the current amount\n on the claim\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n }",
"title": "claim_send_to_address"
},
{
"location": "/cli/#claim_show",
"text": "Resolve claim info from txid/nout or with claim ID\n\nUsage:\n claim_show [ txid | --txid= txid ] [ nout | --nout= nout ]\n [ claim_id | --claim_id= claim_id ]\n\n\nOptions:\n --txid= txid : (str) look for claim with this txid, nout must\n also be specified\n --nout= nout : (int) look for claim with this nout, txid must\n also be specified\n --claim_id= claim_id : (str) look for claim with this claim id\n\nReturns:\n (dict) Dictionary containing claim info as below,\n\n {\n 'txid': (str) txid of claim\n 'nout': (int) nout of claim\n 'amount': (float) amount of claim\n 'value': (str) value of claim\n 'height' : (int) height of claim takeover\n 'claim_id': (str) claim ID of claim\n 'supports': (list) list of supports associated with claim\n }\n\n if claim cannot be resolved, dictionary as below will be returned\n\n {\n 'error': (str) reason for error\n }",
"title": "claim_show"
},
{
"location": "/cli/#cli_test_command",
"text": "This command is only for testing the CLI argument parsing\nUsage:\n cli_test_command [--a_arg] [--b_arg] ( pos_arg | --pos_arg= pos_arg )\n [ pos_args ...] [--pos_arg2= pos_arg2 ]\n [--pos_arg3= pos_arg3 ]\n\n\nOptions:\n --a_arg : a arg\n --b_arg : b arg\n --pos_arg= pos_arg : pos arg\n --pos_args= pos_args : pos args\n --pos_arg2= pos_arg2 : pos arg 2\n --pos_arg3= pos_arg3 : pos arg 3\n\nReturns:\n pos args",
"title": "cli_test_command"
},
{
"location": "/cli/#commands",
"text": "Return a list of available commands\n\nUsage:\n commands\n\n\nOptions:\n None\n\nReturns:\n (list) list of available commands",
"title": "commands"
},
{
"location": "/cli/#daemon_stop",
"text": "Stop lbrynet-daemon\n\nUsage:\n daemon_stop\n\n\nOptions:\n None\n\nReturns:\n (string) Shutdown message",
"title": "daemon_stop"
},
{
"location": "/cli/#file_delete",
"text": "Delete a LBRY file\n\nUsage:\n file_delete [--delete_from_download_dir] [--delete_all] [--sd_hash= sd_hash ] [--file_name= file_name ]\n [--stream_hash= stream_hash ] [--rowid= rowid ] [--claim_id= claim_id ] [--txid= txid ]\n [--nout= nout ] [--claim_name= claim_name ] [--channel_claim_id= channel_claim_id ]\n [--channel_name= channel_name ]\n\n\nOptions:\n --delete_from_download_dir : (bool) delete file from download directory,\n instead of just deleting blobs\n --delete_all : (bool) if there are multiple matching files,\n allow the deletion of multiple files.\n Otherwise do not delete anything.\n --sd_hash= sd_hash : (str) delete by file sd hash\n --file_name file_name : (str) delete by file name in downloads folder\n --stream_hash= stream_hash : (str) delete by file stream hash\n --rowid= rowid : (int) delete by file row id\n --claim_id= claim_id : (str) delete by file claim id\n --txid= txid : (str) delete by file claim txid\n --nout= nout : (int) delete by file claim nout\n --claim_name= claim_name : (str) delete by file claim name\n --channel_claim_id= channel_claim_id : (str) delete by file channel claim id\n --channel_name= channel_name : (str) delete by file channel claim name\n\nReturns:\n (bool) true if deletion was successful",
"title": "file_delete"
},
{
"location": "/cli/#file_list",
"text": "List files limited by optional filters\n\nUsage:\n file_list [--sd_hash= sd_hash ] [--file_name= file_name ] [--stream_hash= stream_hash ]\n [--rowid= rowid ] [--claim_id= claim_id ] [--outpoint= outpoint ] [--txid= txid ] [--nout= nout ]\n [--channel_claim_id= channel_claim_id ] [--channel_name= channel_name ]\n [--claim_name= claim_name ] [--full_status]\n\n\nOptions:\n --sd_hash= sd_hash : (str) get file with matching sd hash\n --file_name= file_name : (str) get file with matching file name in the\n downloads folder\n --stream_hash= stream_hash : (str) get file with matching stream hash\n --rowid= rowid : (int) get file with matching row id\n --claim_id= claim_id : (str) get file with matching claim id\n --outpoint= outpoint : (str) get file with matching claim outpoint\n --txid= txid : (str) get file with matching claim txid\n --nout= nout : (int) get file with matching claim nout\n --channel_claim_id= channel_claim_id : (str) get file with matching channel claim id\n --channel_name= channel_name : (str) get file with matching channel name\n --claim_name= claim_name : (str) get file with matching claim name\n --full_status : (bool) full status, populate the\n 'message' and 'size' fields\n\nReturns:\n (list) List of files\n\n [\n {\n 'completed': (bool) true if download is completed,\n 'file_name': (str) name of file,\n 'download_directory': (str) download directory,\n 'points_paid': (float) credit paid to download file,\n 'stopped': (bool) true if download is stopped,\n 'stream_hash': (str) stream hash of file,\n 'stream_name': (str) stream name ,\n 'suggested_file_name': (str) suggested file name,\n 'sd_hash': (str) sd hash of file,\n 'download_path': (str) download path of file,\n 'mime_type': (str) mime type of file,\n 'key': (str) key attached to file,\n 'total_bytes': (int) file size in bytes, None if full_status is false,\n 'written_bytes': (int) written size in bytes,\n 'blobs_completed': (int) num_completed, None if full_status is false,\n 'blobs_in_stream': (int) None if full_status is false,\n 'status': (str) downloader status, None if full_status is false,\n 'claim_id': (str) None if full_status is false or if claim is not found,\n 'outpoint': (str) None if full_status is false or if claim is not found,\n 'txid': (str) None if full_status is false or if claim is not found,\n 'nout': (int) None if full_status is false or if claim is not found,\n 'metadata': (dict) None if full_status is false or if claim is not found,\n 'channel_claim_id': (str) None if full_status is false or if claim is not found or signed,\n 'channel_name': (str) None if full_status is false or if claim is not found or signed,\n 'claim_name': (str) None if full_status is false or if claim is not found\n },\n ]",
"title": "file_list"
},
{
"location": "/cli/#file_reflect",
"text": "Reflect all the blobs in a file matching the filter criteria\n\nUsage:\n file_reflect [--sd_hash= sd_hash ] [--file_name= file_name ]\n [--stream_hash= stream_hash ] [--rowid= rowid ]\n [--reflector= reflector ]\n\n\nOptions:\n --sd_hash= sd_hash : (str) get file with matching sd hash\n --file_name= file_name : (str) get file with matching file name in the\n downloads folder\n --stream_hash= stream_hash : (str) get file with matching stream hash\n --rowid= rowid : (int) get file with matching row id\n --reflector= reflector : (str) reflector server, ip address or url\n by default choose a server from the config\n\nReturns:\n (list) list of blobs reflected",
"title": "file_reflect"
},
{
"location": "/cli/#file_set_status",
"text": "Start or stop downloading a file\n\nUsage:\n file_set_status ( status | --status= status ) [--sd_hash= sd_hash ]\n [--file_name= file_name ] [--stream_hash= stream_hash ] [--rowid= rowid ]\n\n\nOptions:\n --status= status : (str) one of start or stop \n --sd_hash= sd_hash : (str) set status of file with matching sd hash\n --file_name= file_name : (str) set status of file with matching file name in the\n downloads folder\n --stream_hash= stream_hash : (str) set status of file with matching stream hash\n --rowid= rowid : (int) set status of file with matching row id\n\nReturns:\n (str) Confirmation message",
"title": "file_set_status"
},
{
"location": "/cli/#get",
"text": "Download stream from a LBRY name.\n\nUsage:\n get uri [ file_name | --file_name= file_name ] [ timeout | --timeout= timeout ]\n\n\n\nOptions:\n --uri= uri : (str) uri of the content to download\n --file_name= file_name : (str) specified name for the downloaded file\n --timeout= timeout : (int) download timeout in number of seconds\n\nReturns:\n (dict) Dictionary containing information about the stream\n {\n 'completed': (bool) true if download is completed,\n 'file_name': (str) name of file,\n 'download_directory': (str) download directory,\n 'points_paid': (float) credit paid to download file,\n 'stopped': (bool) true if download is stopped,\n 'stream_hash': (str) stream hash of file,\n 'stream_name': (str) stream name ,\n 'suggested_file_name': (str) suggested file name,\n 'sd_hash': (str) sd hash of file,\n 'download_path': (str) download path of file,\n 'mime_type': (str) mime type of file,\n 'key': (str) key attached to file,\n 'total_bytes': (int) file size in bytes, None if full_status is false,\n 'written_bytes': (int) written size in bytes,\n 'blobs_completed': (int) num_completed, None if full_status is false,\n 'blobs_in_stream': (int) None if full_status is false,\n 'status': (str) downloader status, None if full_status is false,\n 'claim_id': (str) claim id,\n 'outpoint': (str) claim outpoint string,\n 'txid': (str) claim txid,\n 'nout': (int) claim nout,\n 'metadata': (dict) claim metadata,\n 'channel_claim_id': (str) None if claim is not signed\n 'channel_name': (str) None if claim is not signed\n 'claim_name': (str) claim name\n }",
"title": "get"
},
{
"location": "/cli/#help",
"text": "Return a useful message for an API command\n\nUsage:\n help [ command | --command= command ]\n\n\nOptions:\n --command= command : (str) command to retrieve documentation for\n\nReturns:\n (str) Help message",
"title": "help"
},
{
"location": "/cli/#peer_list",
"text": "Get peers for blob hash\n\nUsage:\n peer_list ( blob_hash | --blob_hash= blob_hash ) [ timeout | --timeout= timeout ]\n\n\nOptions:\n --blob_hash= blob_hash : (str) find available peers for this blob hash\n --timeout= timeout : (int) peer search timeout in seconds\n\nReturns:\n (list) List of contacts",
"title": "peer_list"
},
{
"location": "/cli/#publish",
"text": "Make a new name claim and publish associated data to lbrynet,\nupdate over existing claim if user already has a claim for name.\n\nFields required in the final Metadata are:\n 'title'\n 'description'\n 'author'\n 'language'\n 'license'\n 'nsfw'\n\nMetadata can be set by either using the metadata argument or by setting individual arguments\nfee, title, description, author, language, license, license_url, thumbnail, preview, nsfw,\nor sources. Individual arguments will overwrite the fields specified in metadata argument.\n\nUsage:\n publish ( name | --name= name ) ( bid | --bid= bid ) [--metadata= metadata ]\n [--file_path= file_path ] [--fee= fee ] [--title= title ]\n [--description= description ] [--author= author ] [--language= language ]\n [--license= license ] [--license_url= license_url ] [--thumbnail= thumbnail ]\n [--preview= preview ] [--nsfw= nsfw ] [--sources= sources ]\n [--channel_name= channel_name ] [--channel_id= channel_id ]\n [--claim_address= claim_address ] [--change_address= change_address ]\n\n\nOptions:\n --name= name : (str) name of the content\n --bid= bid : (float) amount to back the claim\n --metadata= metadata : (dict) ClaimDict to associate with the claim.\n --file_path= file_path : (str) path to file to be associated with name. If provided,\n a lbry stream of this file will be used in 'sources'.\n If no path is given but a sources dict is provided,\n it will be used. If neither are provided, an\n error is raised.\n --fee= fee : (dict) Dictionary representing key fee to download content:\n {\n 'currency': currency_symbol,\n 'amount': float,\n 'address': str, optional\n }\n supported currencies: LBC, USD, BTC\n If an address is not provided a new one will be\n automatically generated. Default fee is zero.\n --title= title : (str) title of the publication\n --description= description : (str) description of the publication\n --author= author : (str) author of the publication\n --language= language : (str) language of the publication\n --license= license : (str) publication license\n --license_url= license_url : (str) publication license url\n --thumbnail= thumbnail : (str) thumbnail url\n --preview= preview : (str) preview url\n --nsfw= nsfw : (bool) title of the publication\n --sources= sources : (str) {'lbry_sd_hash': sd_hash} specifies sd hash of file\n --channel_name= channel_name : (str) name of the publisher channel name in the wallet\n --channel_id= channel_id : (str) claim id of the publisher channel, does not check\n for channel claim being in the wallet. This allows\n publishing to a channel where only the certificate\n private key is in the wallet.\n --claim_address= claim_address : (str) address where the claim is sent to, if not specified\n new address wil automatically be created\n\nReturns:\n (dict) Dictionary containing result of the claim\n {\n 'tx' : (str) hex encoded transaction\n 'txid' : (str) txid of resulting claim\n 'nout' : (int) nout of the resulting claim\n 'fee' : (float) fee paid for the claim transaction\n 'claim_id' : (str) claim ID of the resulting claim\n }",
"title": "publish"
},
{
"location": "/cli/#resolve",
"text": "Resolve given LBRY URIs\n\nUsage:\n resolve [--force] ( uri | --uri= uri ) [ uris ...]\n\n\nOptions:\n --force : (bool) force refresh and ignore cache\n --uri= uri : (str) uri to resolve\n --uris= uris : (list) uris to resolve\n\nReturns:\n Dictionary of results, keyed by uri\n ' uri ': {\n If a resolution error occurs:\n 'error': Error message\n\n If the uri resolves to a channel or a claim in a channel:\n 'certificate': {\n 'address': (str) claim address,\n 'amount': (float) claim amount,\n 'effective_amount': (float) claim amount including supports,\n 'claim_id': (str) claim id,\n 'claim_sequence': (int) claim sequence number,\n 'decoded_claim': (bool) whether or not the claim value was decoded,\n 'height': (int) claim height,\n 'depth': (int) claim depth,\n 'has_signature': (bool) included if decoded_claim\n 'name': (str) claim name,\n 'permanent_url': (str) permanent url of the certificate claim,\n 'supports: (list) list of supports [{'txid': (str) txid,\n 'nout': (int) nout,\n 'amount': (float) amount}],\n 'txid': (str) claim txid,\n 'nout': (str) claim nout,\n 'signature_is_valid': (bool), included if has_signature,\n 'value': ClaimDict if decoded, otherwise hex string\n }\n\n If the uri resolves to a channel:\n 'claims_in_channel': (int) number of claims in the channel,\n\n If the uri resolves to a claim:\n 'claim': {\n 'address': (str) claim address,\n 'amount': (float) claim amount,\n 'effective_amount': (float) claim amount including supports,\n 'claim_id': (str) claim id,\n 'claim_sequence': (int) claim sequence number,\n 'decoded_claim': (bool) whether or not the claim value was decoded,\n 'height': (int) claim height,\n 'depth': (int) claim depth,\n 'has_signature': (bool) included if decoded_claim\n 'name': (str) claim name,\n 'permanent_url': (str) permanent url of the claim,\n 'channel_name': (str) channel name if claim is in a channel\n 'supports: (list) list of supports [{'txid': (str) txid,\n 'nout': (int) nout,\n 'amount': (float) amount}]\n 'txid': (str) claim txid,\n 'nout': (str) claim nout,\n 'signature_is_valid': (bool), included if has_signature,\n 'value': ClaimDict if decoded, otherwise hex string\n }\n }",
"title": "resolve"
},
{
"location": "/cli/#resolve_name",
"text": "Resolve stream info from a LBRY name\n\nUsage:\n resolve_name ( name | --name= name ) [--force]\n\n\nOptions:\n --name= name : (str) the name to resolve\n --force : (bool) force refresh and do not check cache\n\nReturns:\n (dict) Metadata dictionary from name claim, None if the name is not\n resolvable",
"title": "resolve_name"
},
{
"location": "/cli/#routing_table_get",
"text": "Get DHT routing information\n\nUsage:\n routing_table_get\n\n\nOptions:\n None\n\nReturns:\n (dict) dictionary containing routing and contact information\n {\n buckets : {\n bucket index : [\n {\n address : (str) peer address,\n node_id : (str) peer node id,\n blobs : (list) blob hashes announced by peer\n }\n ]\n },\n contacts : (list) contact node ids,\n blob_hashes : (list) all of the blob hashes stored by peers in the list of buckets,\n node_id : (str) the local dht node id\n }",
"title": "routing_table_get"
},
{
"location": "/cli/#settings_get",
"text": "Get daemon settings\n\nUsage:\n settings_get\n\n\nOptions:\n None\n\nReturns:\n (dict) Dictionary of daemon settings\n See ADJUSTABLE_SETTINGS in lbrynet/conf.py for full list of settings",
"title": "settings_get"
},
{
"location": "/cli/#settings_set",
"text": "Set daemon settings\n\nUsage:\n settings_set [--download_directory= download_directory ]\n [--data_rate= data_rate ]\n [--download_timeout= download_timeout ]\n [--peer_port= peer_port ]\n [--max_key_fee= max_key_fee ]\n [--disable_max_key_fee= disable_max_key_fee ]\n [--use_upnp= use_upnp ]\n [--run_reflector_server= run_reflector_server ]\n [--cache_time= cache_time ]\n [--reflect_uploads= reflect_uploads ]\n [--share_usage_data= share_usage_data ]\n [--peer_search_timeout= peer_search_timeout ]\n [--sd_download_timeout= sd_download_timeout ]\n [--auto_renew_claim_height_delta= auto_renew_claim_height_delta ]\n\n\nOptions:\n --download_directory= download_directory : (str) path of download directory\n --data_rate= data_rate : (float) 0.0001\n --download_timeout= download_timeout : (int) 180\n --peer_port= peer_port : (int) 3333\n --max_key_fee= max_key_fee : (dict) maximum key fee for downloads,\n in the format:\n {\n 'currency': currency_symbol ,\n 'amount': amount \n }.\n In the CLI, it must be an escaped JSON string\n Supported currency symbols: LBC, USD, BTC\n --disable_max_key_fee= disable_max_key_fee : (bool) False\n --use_upnp= use_upnp : (bool) True\n --run_reflector_server= run_reflector_server : (bool) False\n --cache_time= cache_time : (int) 150\n --reflect_uploads= reflect_uploads : (bool) True\n --share_usage_data= share_usage_data : (bool) True\n --peer_search_timeout= peer_search_timeout : (int) 3\n --sd_download_timeout= sd_download_timeout : (int) 3\n --auto_renew_claim_height_delta= auto_renew_claim_height_delta : (int) 0\n claims set to expire within this many blocks will be\n automatically renewed after startup (if set to 0, renews\n will not be made automatically)\n\nReturns:\n (dict) Updated dictionary of daemon settings",
"title": "settings_set"
},
{
"location": "/cli/#status",
"text": "Get daemon status\n\nUsage:\n status [--session_status] [--dht_status]\n\n\nOptions:\n --session_status : (bool) include session status in results\n --dht_status : (bool) include dht network and peer status\n\nReturns:\n (dict) lbrynet-daemon status\n {\n 'lbry_id': lbry peer id, base58,\n 'installation_id': installation id, base58,\n 'is_running': bool,\n 'is_first_run': bool,\n 'startup_status': {\n 'code': status code,\n 'message': status message\n },\n 'connection_status': {\n 'code': connection status code,\n 'message': connection status message\n },\n 'blockchain_status': {\n 'blocks': local blockchain height,\n 'blocks_behind': remote_height - local_height,\n 'best_blockhash': block hash of most recent block,\n },\n 'wallet_is_encrypted': bool,\n\n If given the session status option:\n 'session_status': {\n 'managed_blobs': count of blobs in the blob manager,\n 'managed_streams': count of streams in the file manager\n 'announce_queue_size': number of blobs currently queued to be announced\n 'should_announce_blobs': number of blobs that should be announced\n }\n\n If given the dht status option:\n 'dht_status': {\n 'kbps_received': current kbps receiving,\n 'kbps_sent': current kdps being sent,\n 'total_bytes_sent': total bytes sent,\n 'total_bytes_received': total bytes received,\n 'queries_received': number of queries received per second,\n 'queries_sent': number of queries sent per second,\n 'recent_contacts': count of recently contacted peers,\n 'unique_contacts': count of unique peers\n },\n }",
"title": "status"
},
{
"location": "/cli/#stream_availability",
"text": "Get stream availability for lbry uri\n\nUsage:\n stream_availability ( uri | --uri= uri )\n [ search_timeout | --search_timeout= search_timeout ]\n [ blob_timeout | --blob_timeout= blob_timeout ]\n\n\nOptions:\n --uri= uri : (str) check availability for this uri\n --search_timeout= search_timeout : (int) how long to search for peers for the blob\n in the dht\n --search_timeout= blob_timeout : (int) how long to try downloading from a peer\n\nReturns:\n (dict) {\n 'is_available': bool ,\n 'did_decode': bool ,\n 'did_resolve': bool ,\n 'is_stream': bool ,\n 'num_blobs_in_stream': int ,\n 'sd_hash': str ,\n 'sd_blob_availability': dict see `blob_availability`,\n 'head_blob_hash': str ,\n 'head_blob_availability': dict see `blob_availability`,\n 'use_upnp': bool ,\n 'upnp_redirect_is_set': bool ,\n 'error': None | str error message\n }",
"title": "stream_availability"
},
{
"location": "/cli/#stream_cost_estimate",
"text": "Get estimated cost for a lbry stream\n\nUsage:\n stream_cost_estimate ( uri | --uri= uri ) [ size | --size= size ]\n\n\nOptions:\n --uri= uri : (str) uri to use\n --size= size : (float) stream size in bytes. if provided an sd blob won't be\n downloaded.\n\nReturns:\n (float) Estimated cost in lbry credits, returns None if uri is not\n resolvable",
"title": "stream_cost_estimate"
},
{
"location": "/cli/#transaction_list",
"text": "List transactions belonging to wallet\n\nUsage:\n transaction_list\n\n\nOptions:\n None\n\nReturns:\n (list) List of transactions\n\n {\n claim_info : (list) claim info if in txn [{\n address : (str) address of claim,\n balance_delta : (float) bid amount,\n amount : (float) claim amount,\n claim_id : (str) claim id,\n claim_name : (str) claim name,\n nout : (int) nout\n }],\n abandon_info : (list) abandon info if in txn [{\n address : (str) address of abandoned claim,\n balance_delta : (float) returned amount,\n amount : (float) claim amount,\n claim_id : (str) claim id,\n claim_name : (str) claim name,\n nout : (int) nout\n }],\n confirmations : (int) number of confirmations for the txn,\n date : (str) date and time of txn,\n fee : (float) txn fee,\n support_info : (list) support info if in txn [{\n address : (str) address of support,\n balance_delta : (float) support amount,\n amount : (float) support amount,\n claim_id : (str) claim id,\n claim_name : (str) claim name,\n is_tip : (bool),\n nout : (int) nout\n }],\n timestamp : (int) timestamp,\n txid : (str) txn id,\n update_info : (list) update info if in txn [{\n address : (str) address of claim,\n balance_delta : (float) credited/debited\n amount : (float) absolute amount,\n claim_id : (str) claim id,\n claim_name : (str) claim name,\n nout : (int) nout\n }],\n value : (float) value of txn\n }",
"title": "transaction_list"
},
{
"location": "/cli/#transaction_show",
"text": "Get a decoded transaction from a txid\n\nUsage:\n transaction_show ( txid | --txid= txid )\n\n\nOptions:\n --txid= txid : (str) txid of the transaction\n\nReturns:\n (dict) JSON formatted transaction",
"title": "transaction_show"
},
{
"location": "/cli/#utxo_list",
"text": "List unspent transaction outputs\n\nUsage:\n utxo_list\n\n\nOptions:\n None\n\nReturns:\n (list) List of unspent transaction outputs (UTXOs)\n [\n {\n address : (str) the output address\n amount : (float) unspent amount\n height : (int) block height\n is_claim : (bool) is the tx a claim\n is_coinbase : (bool) is the tx a coinbase tx\n is_support : (bool) is the tx a support\n is_update : (bool) is the tx an update\n nout : (int) nout of the output\n txid : (str) txid of the output\n },\n ...\n ]",
"title": "utxo_list"
},
{
"location": "/cli/#version",
"text": "Get lbry version information\n\nUsage:\n version\n\n\nOptions:\n None\n\nReturns:\n (dict) Dictionary of lbry version information\n {\n 'build': (str) build type (e.g. dev , rc , release ),\n 'ip': (str) remote ip, if available,\n 'lbrynet_version': (str) lbrynet_version,\n 'lbryum_version': (str) lbryum_version,\n 'lbryschema_version': (str) lbryschema_version,\n 'os_release': (str) os release string\n 'os_system': (str) os name\n 'platform': (str) platform string\n 'processor': (str) processor type,\n 'python_version': (str) python version,\n }",
"title": "version"
},
{
"location": "/cli/#wallet_balance",
"text": "Return the balance of the wallet\n\nUsage:\n wallet_balance [ address | --address= address ] [--include_unconfirmed]\n\n\nOptions:\n --address= address : (str) If provided only the balance for this\n address will be given\n --include_unconfirmed : (bool) Include unconfirmed\n\nReturns:\n (float) amount of lbry credits in wallet",
"title": "wallet_balance"
},
{
"location": "/cli/#wallet_decrypt",
"text": "Decrypt an encrypted wallet, this will remove the wallet password\n\nUsage:\n wallet_decrypt\n\n\nOptions:\n None\n\nReturns:\n (bool) true if wallet is decrypted, otherwise false",
"title": "wallet_decrypt"
},
{
"location": "/cli/#wallet_encrypt",
"text": "Encrypt a wallet with a password, if the wallet is already encrypted this will update\nthe password\n\nUsage:\n wallet_encrypt ( new_password | --new_password= new_password )\n\n\nOptions:\n --new_password= new_password : (str) password string to be used for encrypting wallet\n\nReturns:\n (bool) true if wallet is decrypted, otherwise false",
"title": "wallet_encrypt"
},
{
"location": "/cli/#wallet_is_address_mine",
"text": "Checks if an address is associated with the current wallet.\n\nUsage:\n wallet_is_address_mine ( address | --address= address )\n\n\nOptions:\n --address= address : (str) address to check\n\nReturns:\n (bool) true, if address is associated with current wallet",
"title": "wallet_is_address_mine"
},
{
"location": "/cli/#wallet_list",
"text": "List wallet addresses\n\nUsage:\n wallet_list\n\n\nOptions:\n None\n\nReturns:\n List of wallet addresses",
"title": "wallet_list"
},
{
"location": "/cli/#wallet_new_address",
"text": "Generate a new wallet address\n\nUsage:\n wallet_new_address\n\n\nOptions:\n None\n\nReturns:\n (str) New wallet address in base58",
"title": "wallet_new_address"
},
{
"location": "/cli/#wallet_prefill_addresses",
"text": "Create new addresses, each containing `amount` credits\n\nUsage:\n wallet_prefill_addresses [--no_broadcast]\n ( num_addresses | --num_addresses= num_addresses )\n ( amount | --amount= amount )\n\n\nOptions:\n --no_broadcast : (bool) whether to broadcast or not\n --num_addresses= num_addresses : (int) num of addresses to create\n --amount= amount : (float) initial amount in each address\n\nReturns:\n (dict) the resulting transaction",
"title": "wallet_prefill_addresses"
},
{
"location": "/cli/#wallet_public_key",
"text": "Get public key from wallet address\n\nUsage:\n wallet_public_key ( address | --address= address )\n\n\nOptions:\n --address= address : (str) address for which to get the public key\n\nReturns:\n (list) list of public keys associated with address.\n Could contain more than one public key if multisig.",
"title": "wallet_public_key"
},
{
"location": "/cli/#wallet_send",
"text": "Send credits. If given an address, send credits to it. If given a claim id, send a tip\nto the owner of a claim specified by uri. A tip is a claim support where the recipient\nof the support is the claim address for the claim being supported.\n\nUsage:\n wallet_send ( amount | --amount= amount )\n (( address | --address= address ) | ( claim_id | --claim_id= claim_id ))\n\n\nOptions:\n --amount= amount : (float) amount of credit to send\n --address= address : (str) address to send credits to\n --claim_id= claim_id : (float) claim_id of the claim to send to tip to\n\nReturns:\n If sending to an address:\n (bool) true if payment successfully scheduled\n\n If sending a claim tip:\n (dict) Dictionary containing the result of the support\n {\n txid : (str) txid of resulting support claim\n nout : (int) nout of the resulting support claim\n fee : (float) fee paid for the transaction\n }",
"title": "wallet_send"
},
{
"location": "/cli/#wallet_unlock",
"text": "Unlock an encrypted wallet\n\nUsage:\n wallet_unlock ( password | --password= password )\n\n\nOptions:\n --password= password : (str) password for unlocking wallet\n\nReturns:\n (bool) true if wallet is unlocked, otherwise false",
"title": "wallet_unlock"
},
{
"location": "/cli/#wallet_unused_address",
"text": "Return an address containing no balance, will create\na new address if there is none.\n\nUsage:\n wallet_unused_address\n\n\nOptions:\n None\n\nReturns:\n (str) Unused wallet address in base58",
"title": "wallet_unused_address"
}
]
}
-332
View File
@@ -1,332 +0,0 @@
#!/usr/bin/env python
"""Bootstrap setuptools installation
To use setuptools in your package's setup.py, include this
file in the same directory and add this to the top of your setup.py::
from ez_setup import use_setuptools
use_setuptools()
To require a specific version of setuptools, set a download
mirror, or use an alternate download directory, simply supply
the appropriate options to ``use_setuptools()``.
This file can also be run as a script to install or upgrade setuptools.
"""
import os
import shutil
import sys
import tempfile
import zipfile
import optparse
import subprocess
import platform
import textwrap
import contextlib
from distutils import log
try:
from urllib.request import urlopen
except ImportError:
from urllib2 import urlopen
try:
from site import USER_SITE
except ImportError:
USER_SITE = None
DEFAULT_VERSION = "4.0.1"
DEFAULT_URL = "https://pypi.python.org/packages/source/s/setuptools/"
def _python_cmd(*args):
"""
Return True if the command succeeded.
"""
args = (sys.executable,) + args
return subprocess.call(args) == 0
def _install(archive_filename, install_args=()):
with archive_context(archive_filename):
# installing
log.warn('Installing Setuptools')
if not _python_cmd('setup.py', 'install', *install_args):
log.warn('Something went wrong during the installation.')
log.warn('See the error message above.')
# exitcode will be 2
return 2
def _build_egg(egg, archive_filename, to_dir):
with archive_context(archive_filename):
# building an egg
log.warn('Building a Setuptools egg in %s', to_dir)
_python_cmd('setup.py', '-q', 'bdist_egg', '--dist-dir', to_dir)
# returning the result
log.warn(egg)
if not os.path.exists(egg):
raise IOError('Could not build the egg.')
class ContextualZipFile(zipfile.ZipFile):
"""
Supplement ZipFile class to support context manager for Python 2.6
"""
def __enter__(self):
return self
def __exit__(self, type, value, traceback):
self.close()
def __new__(cls, *args, **kwargs):
"""
Construct a ZipFile or ContextualZipFile as appropriate
"""
if hasattr(zipfile.ZipFile, '__exit__'):
return zipfile.ZipFile(*args, **kwargs)
return super(ContextualZipFile, cls).__new__(cls)
@contextlib.contextmanager
def archive_context(filename):
# extracting the archive
tmpdir = tempfile.mkdtemp()
log.warn('Extracting in %s', tmpdir)
old_wd = os.getcwd()
try:
os.chdir(tmpdir)
with ContextualZipFile(filename) as archive:
archive.extractall()
# going in the directory
subdir = os.path.join(tmpdir, os.listdir(tmpdir)[0])
os.chdir(subdir)
log.warn('Now working in %s', subdir)
yield
finally:
os.chdir(old_wd)
shutil.rmtree(tmpdir)
def _do_download(version, download_base, to_dir, download_delay):
egg = os.path.join(to_dir, 'setuptools-%s-py%d.%d.egg'
% (version, sys.version_info[0], sys.version_info[1]))
if not os.path.exists(egg):
archive = download_setuptools(version, download_base,
to_dir, download_delay)
_build_egg(egg, archive, to_dir)
sys.path.insert(0, egg)
# Remove previously-imported pkg_resources if present (see
# https://bitbucket.org/pypa/setuptools/pull-request/7/ for details).
if 'pkg_resources' in sys.modules:
del sys.modules['pkg_resources']
import setuptools
setuptools.bootstrap_install_from = egg
def use_setuptools(version=DEFAULT_VERSION, download_base=DEFAULT_URL,
to_dir=os.curdir, download_delay=15):
to_dir = os.path.abspath(to_dir)
rep_modules = 'pkg_resources', 'setuptools'
imported = set(sys.modules).intersection(rep_modules)
try:
import pkg_resources
except ImportError:
return _do_download(version, download_base, to_dir, download_delay)
try:
pkg_resources.require("setuptools>=" + version)
return
except pkg_resources.DistributionNotFound:
return _do_download(version, download_base, to_dir, download_delay)
except pkg_resources.VersionConflict as VC_err:
if imported:
msg = textwrap.dedent("""
The required version of setuptools (>={version}) is not available,
and can't be installed while this script is running. Please
install a more recent version first, using
'easy_install -U setuptools'.
(Currently using {VC_err.args[0]!r})
""").format(VC_err=VC_err, version=version)
sys.stderr.write(msg)
sys.exit(2)
# otherwise, reload ok
del pkg_resources, sys.modules['pkg_resources']
return _do_download(version, download_base, to_dir, download_delay)
def _clean_check(cmd, target):
"""
Run the command to download target. If the command fails, clean up before
re-raising the error.
"""
try:
subprocess.check_call(cmd)
except subprocess.CalledProcessError:
if os.access(target, os.F_OK):
os.unlink(target)
raise
def download_file_powershell(url, target):
"""
Download the file at url to target using Powershell (which will validate
trust). Raise an exception if the command cannot complete.
"""
target = os.path.abspath(target)
ps_cmd = (
"[System.Net.WebRequest]::DefaultWebProxy.Credentials = "
"[System.Net.CredentialCache]::DefaultCredentials; "
"(new-object System.Net.WebClient).DownloadFile(%(url)r, %(target)r)"
% vars()
)
cmd = [
'powershell',
'-Command',
ps_cmd,
]
_clean_check(cmd, target)
def has_powershell():
if platform.system() != 'Windows':
return False
cmd = ['powershell', '-Command', 'echo test']
with open(os.path.devnull, 'wb') as devnull:
try:
subprocess.check_call(cmd, stdout=devnull, stderr=devnull)
except Exception:
return False
return True
download_file_powershell.viable = has_powershell
def download_file_curl(url, target):
cmd = ['curl', url, '--silent', '--output', target]
_clean_check(cmd, target)
def has_curl():
cmd = ['curl', '--version']
with open(os.path.devnull, 'wb') as devnull:
try:
subprocess.check_call(cmd, stdout=devnull, stderr=devnull)
except Exception:
return False
return True
download_file_curl.viable = has_curl
def download_file_wget(url, target):
cmd = ['wget', url, '--quiet', '--output-document', target]
_clean_check(cmd, target)
def has_wget():
cmd = ['wget', '--version']
with open(os.path.devnull, 'wb') as devnull:
try:
subprocess.check_call(cmd, stdout=devnull, stderr=devnull)
except Exception:
return False
return True
download_file_wget.viable = has_wget
def download_file_insecure(url, target):
"""
Use Python to download the file, even though it cannot authenticate the
connection.
"""
src = urlopen(url)
try:
# Read all the data in one block.
data = src.read()
finally:
src.close()
# Write all the data in one block to avoid creating a partial file.
with open(target, "wb") as dst:
dst.write(data)
download_file_insecure.viable = lambda: True
def get_best_downloader():
downloaders = (
download_file_powershell,
download_file_curl,
download_file_wget,
download_file_insecure,
)
viable_downloaders = (dl for dl in downloaders if dl.viable())
return next(viable_downloaders, None)
def download_setuptools(version=DEFAULT_VERSION, download_base=DEFAULT_URL,
to_dir=os.curdir, delay=15, downloader_factory=get_best_downloader):
"""
Download setuptools from a specified location and return its filename
`version` should be a valid setuptools version number that is available
as an egg for download under the `download_base` URL (which should end
with a '/'). `to_dir` is the directory where the egg will be downloaded.
`delay` is the number of seconds to pause before an actual download
attempt.
``downloader_factory`` should be a function taking no arguments and
returning a function for downloading a URL to a target.
"""
# making sure we use the absolute path
to_dir = os.path.abspath(to_dir)
zip_name = "setuptools-%s.zip" % version
url = download_base + zip_name
saveto = os.path.join(to_dir, zip_name)
if not os.path.exists(saveto): # Avoid repeated downloads
log.warn("Downloading %s", url)
downloader = downloader_factory()
downloader(url, saveto)
return os.path.realpath(saveto)
def _build_install_args(options):
"""
Build the arguments to 'python setup.py install' on the setuptools package
"""
return ['--user'] if options.user_install else []
def _parse_args():
"""
Parse the command line for options
"""
parser = optparse.OptionParser()
parser.add_option(
'--user', dest='user_install', action='store_true', default=False,
help='install in user site package (requires Python 2.6 or later)')
parser.add_option(
'--download-base', dest='download_base', metavar="URL",
default=DEFAULT_URL,
help='alternative URL from where to download the setuptools package')
parser.add_option(
'--insecure', dest='downloader_factory', action='store_const',
const=lambda: download_file_insecure, default=get_best_downloader,
help='Use internal, non-validating downloader'
)
parser.add_option(
'--version', help="Specify which version to download",
default=DEFAULT_VERSION,
)
options, args = parser.parse_args()
# positional arguments are ignored
return options
def main():
"""Install or upgrade setuptools and EasyInstall"""
options = _parse_args()
archive = download_setuptools(
version=options.version,
download_base=options.download_base,
downloader_factory=options.downloader_factory,
)
return _install(archive, _build_install_args(options))
if __name__ == '__main__':
sys.exit(main())
+6
View File
@@ -0,0 +1,6 @@
import logging
__version__ = "0.19.3"
version = tuple(__version__.split('.'))
logging.getLogger(__name__).addHandler(logging.NullHandler())
+268
View File
@@ -0,0 +1,268 @@
import collections
import logging
from twisted.internet import defer, task
from requests import auth
from txrequests import Session
from lbrynet import conf
from lbrynet.core import looping_call_manager, utils, system_info
# Things We Track
SERVER_STARTUP = 'Server Startup'
SERVER_STARTUP_SUCCESS = 'Server Startup Success'
SERVER_STARTUP_ERROR = 'Server Startup Error'
DOWNLOAD_STARTED = 'Download Started'
DOWNLOAD_ERRORED = 'Download Errored'
DOWNLOAD_FINISHED = 'Download Finished'
HEARTBEAT = 'Heartbeat'
CLAIM_ACTION = 'Claim Action' # publish/create/update/abandon
NEW_CHANNEL = 'New Channel'
CREDITS_SENT = 'Credits Sent'
BLOB_BYTES_UPLOADED = 'Blob Bytes Uploaded'
log = logging.getLogger(__name__)
class Manager(object):
def __init__(self, analytics_api, context=None, installation_id=None, session_id=None):
self.analytics_api = analytics_api
self._tracked_data = collections.defaultdict(list)
self.looping_call_manager = self._setup_looping_calls()
self.context = context or self._make_context(
system_info.get_platform(), conf.settings['wallet'])
self.installation_id = installation_id or conf.settings.installation_id
self.session_id = session_id or conf.settings.get_session_id()
self.is_started = False
@classmethod
def new_instance(cls, enabled=None):
api = Api.new_instance(enabled)
return cls(api)
# Things We Track
def send_server_startup(self):
self.analytics_api.track(self._event(SERVER_STARTUP))
def send_server_startup_success(self):
self.analytics_api.track(self._event(SERVER_STARTUP_SUCCESS))
def send_server_startup_error(self, message):
self.analytics_api.track(self._event(SERVER_STARTUP_ERROR, {'message': message}))
def send_download_started(self, id_, name, claim_dict=None):
self.analytics_api.track(
self._event(DOWNLOAD_STARTED, self._download_properties(id_, name, claim_dict))
)
def send_download_errored(self, err, id_, name, claim_dict, report):
download_error_properties = self._download_error_properties(err, id_, name, claim_dict,
report)
self.analytics_api.track(self._event(DOWNLOAD_ERRORED, download_error_properties))
def send_download_finished(self, id_, name, report, claim_dict=None):
download_properties = self._download_properties(id_, name, claim_dict, report)
self.analytics_api.track(self._event(DOWNLOAD_FINISHED, download_properties))
def send_claim_action(self, action):
self.analytics_api.track(self._event(CLAIM_ACTION, {'action': action}))
def send_new_channel(self):
self.analytics_api.track(self._event(NEW_CHANNEL))
def send_credits_sent(self):
self.analytics_api.track(self._event(CREDITS_SENT))
def _send_heartbeat(self):
self.analytics_api.track(self._event(HEARTBEAT))
def _update_tracked_metrics(self):
should_send, value = self.summarize_and_reset(BLOB_BYTES_UPLOADED)
if should_send:
self.analytics_api.track(self._metric_event(BLOB_BYTES_UPLOADED, value))
# Setup / Shutdown
def start(self):
if not self.is_started:
for name, _, interval in self._get_looping_calls():
self.looping_call_manager.start(name, interval)
self.is_started = True
def shutdown(self):
self.looping_call_manager.shutdown()
def register_repeating_metric(self, event_name, value_generator, frequency=300):
lcall = task.LoopingCall(self._send_repeating_metric, event_name, value_generator)
self.looping_call_manager.register_looping_call(event_name, lcall)
lcall.start(frequency)
def _get_looping_calls(self):
return [
('send_heartbeat', self._send_heartbeat, 60),
('update_tracked_metrics', self._update_tracked_metrics, 300),
]
def _setup_looping_calls(self):
call_manager = looping_call_manager.LoopingCallManager()
for name, fn, _ in self._get_looping_calls():
call_manager.register_looping_call(name, task.LoopingCall(fn))
return call_manager
def _send_repeating_metric(self, event_name, value_generator):
result = value_generator()
self._if_deferred(result, self._send_repeating_metric_value, event_name)
def _send_repeating_metric_value(self, result, event_name):
should_send, value = result
if should_send:
self.analytics_api.track(self._metric_event(event_name, value))
def add_observation(self, metric, value):
self._tracked_data[metric].append(value)
def summarize_and_reset(self, metric, op=sum):
"""Apply `op` on the current values for `metric`.
This operation also resets the metric.
Returns:
a tuple (should_send, value)
"""
try:
values = self._tracked_data.pop(metric)
return True, op(values)
except KeyError:
return False, None
def _event(self, event, event_properties=None):
return {
'userId': 'lbry',
'event': event,
'properties': self._event_properties(event_properties),
'context': self.context,
'timestamp': utils.isonow()
}
def _metric_event(self, metric_name, value):
return self._event(metric_name, {'value': value})
def _event_properties(self, event_properties=None):
properties = {
'lbry_id': self.installation_id,
'session_id': self.session_id,
}
properties.update(event_properties or {})
return properties
@staticmethod
def _download_properties(id_, name, claim_dict=None, report=None):
sd_hash = None if not claim_dict else claim_dict.source_hash
p = {
'download_id': id_,
'name': name,
'stream_info': sd_hash
}
if report:
p['report'] = report
return p
@staticmethod
def _download_error_properties(error, id_, name, claim_dict, report):
def error_name(err):
if not hasattr(type(err), "__name__"):
return str(type(err))
return type(err).__name__
return {
'download_id': id_,
'name': name,
'stream_info': claim_dict.source_hash,
'error': error_name(error),
'reason': error.message,
'report': report
}
@staticmethod
def _make_context(platform, wallet):
return {
'app': {
'name': 'lbrynet',
'version': platform['lbrynet_version'],
'python_version': platform['python_version'],
'build': platform['build'],
'wallet': {
'name': wallet,
'version': platform['lbryum_version'] if wallet == conf.LBRYUM_WALLET else None
},
},
# TODO: expand os info to give linux/osx specific info
'os': {
'name': platform['os_system'],
'version': platform['os_release']
},
'library': {
'name': 'lbrynet-analytics',
'version': '1.0.0'
},
}
@staticmethod
def _if_deferred(maybe_deferred, callback, *args, **kwargs):
if isinstance(maybe_deferred, defer.Deferred):
maybe_deferred.addCallback(callback, *args, **kwargs)
else:
callback(maybe_deferred, *args, **kwargs)
class Api(object):
def __init__(self, session, url, write_key, enabled):
self.session = session
self.url = url
self._write_key = write_key
self._enabled = enabled
def _post(self, endpoint, data):
# there is an issue with a timing condition with keep-alive
# that is best explained here: https://github.com/mikem23/keepalive-race
#
# If you make a request, wait just the right amount of time,
# then make another request, the requests module may opt to
# reuse the connection, but by the time the server gets it the
# timeout will have expired.
#
# by forcing the connection to close, we will disable the keep-alive.
assert endpoint[0] == '/'
headers = {"Connection": "close"}
return self.session.post(
self.url + endpoint,
json=data,
auth=auth.HTTPBasicAuth(self._write_key, ''),
headers=headers
)
def track(self, event):
"""Send a single tracking event"""
if not self._enabled:
return defer.succeed('Analytics disabled')
def _log_error(failure, event):
log.warning('Failed to send track event. %s (%s)', failure.getTraceback(), str(event))
log.debug('Sending track event: %s', event)
d = self._post('/track', event)
d.addErrback(_log_error, event)
return d
@classmethod
def new_instance(cls, enabled=None):
"""Initialize an instance using values from the configuration"""
session = Session()
if enabled is None:
enabled = conf.settings['share_usage_data']
return cls(
session,
conf.settings['ANALYTICS_ENDPOINT'],
utils.deobfuscate(conf.settings['ANALYTICS_TOKEN']),
enabled,
)
+1
View File
@@ -0,0 +1 @@
import paths
+26
View File
@@ -0,0 +1,26 @@
# App root files dir
# https://developer.android.com/reference/android/content/ContextWrapper.html#getFilesDir%28%29
def android_files_dir():
return None
# Base internal storage path
def android_internal_storage_dir():
return None
# Base external (SD card, if present) storage path
def android_external_storage_dir():
return None
# Internal device storage (private app folder)
# https://developer.android.com/reference/android/content/ContextWrapper.html#getExternalFilesDirs(java.lang.String)
def android_app_internal_storage_dir():
return None
# External (app folder on SD card, if present) storage
# https://developer.android.com/reference/android/content/ContextWrapper.html#getExternalFilesDirs(java.lang.String)
def android_app_external_storage_dir():
return None
+4
View File
@@ -0,0 +1,4 @@
from blob_file import BlobFile
from creator import BlobFileCreator
from writer import HashBlobWriter
from reader import HashBlobReader
+209
View File
@@ -0,0 +1,209 @@
import logging
import os
from twisted.internet import defer, threads
from twisted.web.client import FileBodyProducer
from twisted.python.failure import Failure
from lbrynet.core.Error import DownloadCanceledError, InvalidDataError, InvalidBlobHashError
from lbrynet.core.utils import is_valid_blobhash
from lbrynet.blob.writer import HashBlobWriter
from lbrynet.blob.reader import HashBlobReader
log = logging.getLogger(__name__)
MAX_BLOB_SIZE = 2 * 2 ** 20
class BlobFile(object):
"""
A chunk of data available on the network which is specified by a hashsum
This class is used to create blobs on the local filesystem
when we already know the blob hash before hand (i.e., when downloading blobs)
Also can be used for reading from blobs on the local filesystem
"""
def __str__(self):
return self.blob_hash[:16]
def __repr__(self):
return '<{}({})>'.format(self.__class__.__name__, str(self))
def __init__(self, blob_dir, blob_hash, length=None):
if not is_valid_blobhash(blob_hash):
raise InvalidBlobHashError(blob_hash)
self.blob_hash = blob_hash
self.length = length
self.writers = {} # {Peer: writer, finished_deferred}
self._verified = False
self.readers = 0
self.blob_dir = blob_dir
self.file_path = os.path.join(blob_dir, self.blob_hash)
self.blob_write_lock = defer.DeferredLock()
self.saved_verified_blob = False
if os.path.isfile(self.file_path):
self.set_length(os.path.getsize(self.file_path))
# This assumes that the hash of the blob has already been
# checked as part of the blob creation process. It might
# be worth having a function that checks the actual hash;
# its probably too expensive to have that check be part of
# this call.
self._verified = True
def open_for_writing(self, peer):
"""
open a blob file to be written by peer, supports concurrent
writers, as long as they are from differnt peers.
returns tuple of (writer, finished_deferred)
writer - a file like object with a write() function, close() when finished
finished_deferred - deferred that is fired when write is finished and returns
a instance of itself as HashBlob
"""
if not peer in self.writers:
log.debug("Opening %s to be written by %s", str(self), str(peer))
finished_deferred = defer.Deferred()
writer = HashBlobWriter(self.get_length, self.writer_finished)
self.writers[peer] = (writer, finished_deferred)
return (writer, finished_deferred)
log.warning("Tried to download the same file twice simultaneously from the same peer")
return None, None
def open_for_reading(self):
"""
open blob for reading
returns a file like object that can be read() from, and closed() when
finished
"""
if self._verified is True:
f = open(self.file_path, 'rb')
reader = HashBlobReader(f, self.reader_finished)
self.readers += 1
return reader
return None
def delete(self):
"""
delete blob file from file system, prevent deletion
if a blob is being read from or written to
returns a deferred that firesback when delete is completed
"""
if not self.writers and not self.readers:
self._verified = False
self.saved_verified_blob = False
def delete_from_file_system():
if os.path.isfile(self.file_path):
os.remove(self.file_path)
d = threads.deferToThread(delete_from_file_system)
def log_error(err):
log.warning("An error occurred deleting %s: %s",
str(self.file_path), err.getErrorMessage())
return err
d.addErrback(log_error)
return d
else:
return defer.fail(Failure(
ValueError("File is currently being read or written and cannot be deleted")))
@property
def verified(self):
"""
Protect verified from being modified by other classes.
verified is True if a write to a blob has completed succesfully,
or a blob has been read to have the same length as specified
in init
"""
return self._verified
def set_length(self, length):
if self.length is not None and length == self.length:
return True
if self.length is None and 0 <= length <= MAX_BLOB_SIZE:
self.length = length
return True
log.warning("Got an invalid length. Previous length: %s, Invalid length: %s",
self.length, length)
return False
def get_length(self):
return self.length
def get_is_verified(self):
return self.verified
def is_downloading(self):
if self.writers:
return True
return False
def reader_finished(self, reader):
self.readers -= 1
return defer.succeed(True)
def writer_finished(self, writer, err=None):
def fire_finished_deferred():
self._verified = True
for p, (w, finished_deferred) in self.writers.items():
if w == writer:
del self.writers[p]
finished_deferred.callback(self)
return True
log.warning(
"Somehow, the writer that was accepted as being valid was already removed: %s",
writer)
return False
def errback_finished_deferred(err):
for p, (w, finished_deferred) in self.writers.items():
if w == writer:
del self.writers[p]
finished_deferred.errback(err)
def cancel_other_downloads():
for p, (w, finished_deferred) in self.writers.items():
w.close()
if err is None:
if writer.len_so_far == self.length and writer.blob_hash == self.blob_hash:
if self._verified is False:
d = self.save_verified_blob(writer)
d.addCallbacks(lambda _: fire_finished_deferred(), errback_finished_deferred)
d.addCallback(lambda _: cancel_other_downloads())
else:
d = defer.succeed(None)
fire_finished_deferred()
else:
if writer.len_so_far != self.length:
err_string = "blob length is %i vs expected %i" % (writer.len_so_far, self.length)
else:
err_string = "blob hash is %s vs expected %s" % (writer.blob_hash, self.blob_hash)
errback_finished_deferred(Failure(InvalidDataError(err_string)))
d = defer.succeed(None)
else:
errback_finished_deferred(err)
d = defer.succeed(None)
d.addBoth(lambda _: writer.close_handle())
return d
def save_verified_blob(self, writer):
# we cannot have multiple _save_verified_blob interrupting
# each other, can happen since startProducing is a deferred
return self.blob_write_lock.run(self._save_verified_blob, writer)
@defer.inlineCallbacks
def _save_verified_blob(self, writer):
if self.saved_verified_blob is False:
writer.write_handle.seek(0)
out_path = os.path.join(self.blob_dir, self.blob_hash)
producer = FileBodyProducer(writer.write_handle)
yield producer.startProducing(open(out_path, 'wb'))
self.saved_verified_blob = True
defer.returnValue(True)
else:
raise DownloadCanceledError()
+51
View File
@@ -0,0 +1,51 @@
import os
import logging
from io import BytesIO
from twisted.internet import defer
from twisted.web.client import FileBodyProducer
from lbrynet.core.cryptoutils import get_lbry_hash_obj
log = logging.getLogger(__name__)
class BlobFileCreator(object):
"""
This class is used to create blobs on the local filesystem
when we do not know the blob hash beforehand (i.e, when creating
a new stream)
"""
def __init__(self, blob_dir):
self.blob_dir = blob_dir
self.buffer = BytesIO()
self._is_open = True
self._hashsum = get_lbry_hash_obj()
self.len_so_far = 0
self.blob_hash = None
self.length = None
@defer.inlineCallbacks
def close(self):
self.length = self.len_so_far
self.blob_hash = self._hashsum.hexdigest()
if self.blob_hash and self._is_open and self.length > 0:
# do not save 0 length files (empty tail blob in streams)
# or if its been closed already
self.buffer.seek(0)
out_path = os.path.join(self.blob_dir, self.blob_hash)
producer = FileBodyProducer(self.buffer)
yield producer.startProducing(open(out_path, 'wb'))
self._is_open = False
if self.length > 0:
defer.returnValue(self.blob_hash)
else:
# 0 length files (empty tail blob in streams )
# must return None as their blob_hash for
# it to be saved properly by EncryptedFileMetadataManagers
defer.returnValue(None)
def write(self, data):
if not self._is_open:
raise IOError
self._hashsum.update(data)
self.len_so_far += len(data)
self.buffer.write(data)
+32
View File
@@ -0,0 +1,32 @@
import logging
log = logging.getLogger(__name__)
class HashBlobReader(object):
"""
This is a file like reader class that supports
read(size) and close()
"""
def __init__(self, read_handle, finished_cb):
self.finished_cb = finished_cb
self.finished_cb_d = None
self.read_handle = read_handle
def __del__(self):
if self.finished_cb_d is None:
log.warn("Garbage collection was called, but reader for %s was not closed yet",
self.read_handle.name)
self.close()
def read(self, size=-1):
return self.read_handle.read(size)
def close(self):
# if we've already closed and called finished_cb, do nothing
if self.finished_cb_d is not None:
return
self.read_handle.close()
self.finished_cb_d = self.finished_cb(self)
+58
View File
@@ -0,0 +1,58 @@
import logging
from io import BytesIO
from twisted.python.failure import Failure
from lbrynet.core.Error import DownloadCanceledError, InvalidDataError
from lbrynet.core.cryptoutils import get_lbry_hash_obj
log = logging.getLogger(__name__)
class HashBlobWriter(object):
def __init__(self, length_getter, finished_cb):
self.write_handle = BytesIO()
self.length_getter = length_getter
self.finished_cb = finished_cb
self.finished_cb_d = None
self._hashsum = get_lbry_hash_obj()
self.len_so_far = 0
def __del__(self):
if self.finished_cb_d is None:
log.warn("Garbage collection was called, but writer was not closed yet")
self.close()
@property
def blob_hash(self):
return self._hashsum.hexdigest()
def write(self, data):
if self.write_handle is None:
log.exception("writer has already been closed")
raise IOError('I/O operation on closed file')
self._hashsum.update(data)
self.len_so_far += len(data)
if self.len_so_far > self.length_getter():
self.finished_cb_d = self.finished_cb(
self,
Failure(InvalidDataError("Length so far is greater than the expected length."
" %s to %s" % (self.len_so_far,
self.length_getter()))))
else:
self.write_handle.write(data)
if self.len_so_far == self.length_getter():
self.finished_cb_d = self.finished_cb(self)
def close_handle(self):
if self.write_handle is not None:
self.write_handle.close()
self.write_handle = None
def close(self, reason=None):
# if we've already called finished_cb because we either finished writing
# or closed already, do nothing
if self.finished_cb_d is not None:
return
if reason is None:
reason = Failure(DownloadCanceledError())
self.finished_cb_d = self.finished_cb(self, reason)
+2
View File
@@ -0,0 +1,2 @@
# dont touch this. CI server changes this during build/deployment
BUILD = "dev"
+635 -20
View File
@@ -1,25 +1,640 @@
"""
Some network wide and also application specific parameters
"""
import base58
import json
import logging
import os
import re
import sys
import yaml
import envparse
from appdirs import user_data_dir, user_config_dir
from lbrynet.core import utils
from lbrynet.core.Error import InvalidCurrencyError, NoSuchDirectoryError
from lbrynet.androidhelpers.paths import (
android_internal_storage_dir,
android_app_internal_storage_dir
)
try:
from lbrynet.winhelpers.knownpaths import get_path, FOLDERID, UserHandle
except (ImportError, ValueError, NameError):
# Android platform: NameError: name 'c_wchar' is not defined
pass
log = logging.getLogger(__name__)
ROOT_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
ENV_NAMESPACE = 'LBRY_'
LBRYCRD_WALLET = 'lbrycrd'
LBRYUM_WALLET = 'lbryum'
PTC_WALLET = 'ptc'
PROTOCOL_PREFIX = 'lbry'
APP_NAME = 'LBRY'
LINUX = 1
DARWIN = 2
WINDOWS = 3
ANDROID = 4
KB = 2 ** 10
MB = 2 ** 20
DEFAULT_DHT_NODES = [
('lbrynet1.lbry.io', 4444),
('lbrynet2.lbry.io', 4444),
('lbrynet3.lbry.io', 4444)
]
settings_decoders = {
'.json': json.loads,
'.yml': yaml.load
}
settings_encoders = {
'.json': json.dumps,
'.yml': yaml.safe_dump
}
# set by CLI when the user specifies an alternate config file path
conf_file = None
MAX_HANDSHAKE_SIZE = 2**16
MAX_REQUEST_SIZE = 2**16
MAX_BLOB_REQUEST_SIZE = 2**16
MAX_RESPONSE_INFO_SIZE = 2**16
MAX_BLOB_INFOS_TO_REQUEST = 20
BLOBFILES_DIR = ".blobfiles"
BLOB_SIZE = 2**21
MIN_BLOB_DATA_PAYMENT_RATE = .5 # points/megabyte
MIN_BLOB_INFO_PAYMENT_RATE = 2.0 # points/1000 infos
MIN_VALUABLE_BLOB_INFO_PAYMENT_RATE = 5.0 # points/1000 infos
MIN_VALUABLE_BLOB_HASH_PAYMENT_RATE = 5.0 # points/1000 infos
MAX_CONNECTIONS_PER_STREAM = 5
def _win_path_to_bytes(path):
"""
Encode Windows paths to string. appdirs.user_data_dir()
on windows will return unicode path, unlike other platforms
which returns string. This will cause problems
because we use strings for filenames and combining them with
os.path.join() will result in errors.
"""
for encoding in ('ASCII', 'MBCS'):
try:
return path.encode(encoding)
except (UnicodeEncodeError, LookupError):
pass
return path
POINTTRADER_SERVER = 'http://ec2-54-187-192-68.us-west-2.compute.amazonaws.com:2424'
#POINTTRADER_SERVER = 'http://127.0.0.1:2424'
CRYPTSD_FILE_EXTENSION = ".cryptsd"
def _get_old_directories(platform_type):
directories = {}
if platform_type == WINDOWS:
appdata = get_path(FOLDERID.RoamingAppData, UserHandle.current)
directories['data'] = os.path.join(appdata, 'lbrynet')
directories['lbryum'] = os.path.join(appdata, 'lbryum')
directories['download'] = get_path(FOLDERID.Downloads, UserHandle.current)
elif platform_type == DARWIN:
directories['data'] = user_data_dir('LBRY')
directories['lbryum'] = os.path.expanduser('~/.lbryum')
directories['download'] = os.path.expanduser('~/Downloads')
elif platform_type == LINUX:
directories['data'] = os.path.expanduser('~/.lbrynet')
directories['lbryum'] = os.path.expanduser('~/.lbryum')
directories['download'] = os.path.expanduser('~/Downloads')
else:
raise ValueError('unknown platform value')
return directories
def _get_new_directories(platform_type):
directories = {}
if platform_type == ANDROID:
directories['data'] = '%s/lbrynet' % android_app_internal_storage_dir()
directories['lbryum'] = '%s/lbryum' % android_app_internal_storage_dir()
directories['download'] = '%s/Download' % android_internal_storage_dir()
elif platform_type == WINDOWS:
directories['data'] = user_data_dir('lbrynet', 'lbry')
directories['lbryum'] = user_data_dir('lbryum', 'lbry')
directories['download'] = get_path(FOLDERID.Downloads, UserHandle.current)
elif platform_type == DARWIN:
directories = _get_old_directories(platform_type)
elif platform_type == LINUX:
directories['data'] = user_data_dir('lbry/lbrynet')
directories['lbryum'] = user_data_dir('lbry/lbryum')
try:
with open(os.path.join(user_config_dir(), 'user-dirs.dirs'), 'r') as xdg:
down_dir = re.search(r'XDG_DOWNLOAD_DIR=(.+)', xdg.read()).group(1)
down_dir = re.sub('\$HOME', os.getenv('HOME'), down_dir)
directories['download'] = re.sub('\"', '', down_dir)
except EnvironmentError:
directories['download'] = os.getenv('XDG_DOWNLOAD_DIR')
if not directories['download']:
directories['download'] = os.path.expanduser('~/Downloads')
else:
raise ValueError('unknown platform value')
return directories
if 'ANDROID_ARGUMENT' in os.environ:
# https://github.com/kivy/kivy/blob/master/kivy/utils.py#L417-L421
platform = ANDROID
dirs = _get_new_directories(ANDROID)
elif 'darwin' in sys.platform:
platform = DARWIN
dirs = _get_old_directories(DARWIN)
elif 'win' in sys.platform:
platform = WINDOWS
if os.path.isdir(_get_old_directories(WINDOWS)['data']) or \
os.path.isdir(_get_old_directories(WINDOWS)['lbryum']):
dirs = _get_old_directories(WINDOWS)
else:
dirs = _get_new_directories(WINDOWS)
dirs['data'] = _win_path_to_bytes(dirs['data'])
dirs['lbryum'] = _win_path_to_bytes(dirs['lbryum'])
dirs['download'] = _win_path_to_bytes(dirs['download'])
else:
platform = LINUX
if os.path.isdir(_get_old_directories(LINUX)['data']) or \
os.path.isdir(_get_old_directories(LINUX)['lbryum']):
dirs = _get_old_directories(LINUX)
else:
dirs = _get_new_directories(LINUX)
default_data_dir = dirs['data']
default_lbryum_dir = dirs['lbryum']
default_download_dir = dirs['download']
ICON_PATH = 'icons' if platform is WINDOWS else 'app.icns'
def server_port(server_and_port):
server, port = server_and_port.split(':')
return server, int(port)
def server_list(servers):
return [server_port(server) for server in servers]
class Env(envparse.Env):
"""An Env parser that automatically namespaces the variables with LBRY"""
def __init__(self, **schema):
self.original_schema = schema
my_schema = {
self._convert_key(key): self._convert_value(value)
for key, value in schema.items()
}
envparse.Env.__init__(self, **my_schema)
def __call__(self, key, *args, **kwargs):
my_key = self._convert_key(key)
return super(Env, self).__call__(my_key, *args, **kwargs)
@staticmethod
def _convert_key(key):
return ENV_NAMESPACE + key.upper()
@staticmethod
def _convert_value(value):
""" Allow value to be specified as a tuple or list.
If you do this, the tuple/list must be of the
form (cast, default) or (cast, default, subcast)
"""
if isinstance(value, (tuple, list)):
new_value = {'cast': value[0], 'default': value[1]}
if len(value) == 3:
new_value['subcast'] = value[2]
return new_value
return value
TYPE_DEFAULT = 'default'
TYPE_PERSISTED = 'persisted'
TYPE_ENV = 'env'
TYPE_CLI = 'cli'
TYPE_RUNTIME = 'runtime'
FIXED_SETTINGS = {
'ANALYTICS_ENDPOINT': 'https://api.segment.io/v1',
'ANALYTICS_TOKEN': 'Ax5LZzR1o3q3Z3WjATASDwR5rKyHH0qOIRIbLmMXn2H=',
'API_ADDRESS': 'lbryapi',
'APP_NAME': APP_NAME,
'BLOBFILES_DIR': 'blobfiles',
'CRYPTSD_FILE_EXTENSION': '.cryptsd',
'CURRENCIES': {
'BTC': {'type': 'crypto'},
'LBC': {'type': 'crypto'},
'USD': {'type': 'fiat'},
},
'DB_REVISION_FILE_NAME': 'db_revision',
'ICON_PATH': ICON_PATH,
'LOGGLY_TOKEN': 'BQEzZmMzLJHgAGxkBF00LGD0YGuyATVgAmqxAQEuAQZ2BQH4',
'LOG_FILE_NAME': 'lbrynet.log',
'LOG_POST_URL': 'https://lbry.io/log-upload',
'MAX_BLOB_REQUEST_SIZE': 64 * KB,
'MAX_HANDSHAKE_SIZE': 64 * KB,
'MAX_REQUEST_SIZE': 64 * KB,
'MAX_RESPONSE_INFO_SIZE': 64 * KB,
'MAX_BLOB_INFOS_TO_REQUEST': 20,
'PROTOCOL_PREFIX': PROTOCOL_PREFIX,
'SLACK_WEBHOOK': ('nUE0pUZ6Yl9bo29epl5moTSwnl5wo20ip2IlqzywMKZiIQSFZR5'
'AHx4mY0VmF0WQZ1ESEP9kMHZlp1WzJwWOoKN3ImR1M2yUAaMyqGZ='),
'WALLET_TYPES': [LBRYUM_WALLET, LBRYCRD_WALLET],
}
ADJUSTABLE_SETTINGS = {
# By default, daemon will block all cross origin requests
# but if this is set, this value will be used for the
# Access-Control-Allow-Origin. For example
# set to '*' to allow all requests, or set to 'http://localhost:8080'
# if you're running a test UI on that port
'allowed_origin': (str, ''),
# Changing this value is not-advised as it could potentially
# expose the lbrynet daemon to the outside world which would
# give an attacker access to your wallet and you could lose
# all of your credits.
'api_host': (str, 'localhost'),
'api_port': (int, 5279),
# claims set to expire within this many blocks will be
# automatically renewed after startup (if set to 0, renews
# will not be made automatically)
'auto_renew_claim_height_delta': (int, 0),
'cache_time': (int, 150),
'data_dir': (str, default_data_dir),
'data_rate': (float, .0001), # points/megabyte
'delete_blobs_on_remove': (bool, True),
'dht_node_port': (int, 4444),
'download_directory': (str, default_download_dir),
'download_timeout': (int, 180),
'is_generous_host': (bool, True),
'announce_head_blobs_only': (bool, True),
'known_dht_nodes': (list, DEFAULT_DHT_NODES, server_list),
'lbryum_wallet_dir': (str, default_lbryum_dir),
'max_connections_per_stream': (int, 5),
'seek_head_blob_first': (bool, True),
# TODO: writing json on the cmd line is a pain, come up with a nicer
# parser for this data structure. maybe 'USD:25'
'max_key_fee': (json.loads, {'currency': 'USD', 'amount': 50.0}),
'disable_max_key_fee': (bool, False),
'min_info_rate': (float, .02), # points/1000 infos
'min_valuable_hash_rate': (float, .05), # points/1000 infos
'min_valuable_info_rate': (float, .05), # points/1000 infos
'peer_port': (int, 3333),
'pointtrader_server': (str, 'http://127.0.0.1:2424'),
'reflector_port': (int, 5566),
# if reflect_uploads is True, send files to reflector (after publishing as well as a
# periodic check in the event the initial upload failed or was disconnected part way through
'reflect_uploads': (bool, True),
'auto_re_reflect_interval': (int, 3600),
'reflector_servers': (list, [('reflector2.lbry.io', 5566)], server_list),
'run_reflector_server': (bool, False),
'sd_download_timeout': (int, 3),
'share_usage_data': (bool, True), # whether to share usage stats and diagnostic info with LBRY
'peer_search_timeout': (int, 3),
'use_auth_http': (bool, False),
'use_upnp': (bool, True),
'use_keyring': (bool, False),
'wallet': (str, LBRYUM_WALLET),
'blockchain_name': (str, 'lbrycrd_main'),
'lbryum_servers': (list, [('lbryum8.lbry.io', 50001), ('lbryum9.lbry.io', 50001)], server_list),
's3_headers_depth': (int, 96 * 10) # download headers from s3 when the local height is more than 10 chunks behind
}
class Config(object):
def __init__(self, fixed_defaults, adjustable_defaults, persisted_settings=None,
environment=None, cli_settings=None):
self._installation_id = None
self._session_id = base58.b58encode(utils.generate_id())
self._node_id = None
self._fixed_defaults = fixed_defaults
self._adjustable_defaults = adjustable_defaults
self._data = {
TYPE_DEFAULT: {}, # defaults
TYPE_PERSISTED: {}, # stored settings from daemon_settings.yml (or from a db, etc)
TYPE_ENV: {}, # settings from environment variables
TYPE_CLI: {}, # command-line arguments
TYPE_RUNTIME: {}, # set during runtime (using self.set(), etc)
}
# the order in which a piece of data is searched for. earlier types override later types
self._search_order = (
TYPE_RUNTIME, TYPE_CLI, TYPE_ENV, TYPE_PERSISTED, TYPE_DEFAULT
)
# types of data where user specified config values can be stored
self._user_specified = (
TYPE_RUNTIME, TYPE_CLI, TYPE_ENV, TYPE_PERSISTED
)
self._data[TYPE_DEFAULT].update(self._fixed_defaults)
self._data[TYPE_DEFAULT].update(
{k: v[1] for (k, v) in self._adjustable_defaults.iteritems()})
if persisted_settings is None:
persisted_settings = {}
self._validate_settings(persisted_settings)
self._data[TYPE_PERSISTED].update(persisted_settings)
env_settings = self._parse_environment(environment)
self._validate_settings(env_settings)
self._data[TYPE_ENV].update(env_settings)
if cli_settings is None:
cli_settings = {}
self._validate_settings(cli_settings)
self._data[TYPE_CLI].update(cli_settings)
def __repr__(self):
return self.get_current_settings_dict().__repr__()
def __iter__(self):
for k in self._data[TYPE_DEFAULT].iterkeys():
yield k
def __getitem__(self, name):
return self.get(name)
def __setitem__(self, name, value):
return self.set(name, value)
def __contains__(self, name):
return name in self._data[TYPE_DEFAULT]
@staticmethod
def _parse_environment(environment):
env_settings = {}
if environment is not None:
assert isinstance(environment, Env)
for opt in environment.original_schema:
if environment(opt) is not None:
env_settings[opt] = environment(opt)
return env_settings
def _assert_valid_data_type(self, data_type):
if data_type not in self._data:
raise KeyError('{} in is not a valid data type'.format(data_type))
def get_valid_setting_names(self):
return self._data[TYPE_DEFAULT].keys()
def _is_valid_setting(self, name):
return name in self.get_valid_setting_names()
def _assert_valid_setting(self, name):
if not self._is_valid_setting(name):
raise KeyError('{} is not a valid setting'.format(name))
def _validate_settings(self, data):
invalid_settings = set(data.keys()) - set(self.get_valid_setting_names())
if len(invalid_settings) > 0:
raise KeyError('invalid settings: {}'.format(', '.join(invalid_settings)))
def _assert_editable_setting(self, name):
self._assert_valid_setting(name)
if name in self._fixed_defaults:
raise ValueError('{} is not an editable setting'.format(name))
def _assert_valid_setting_value(self, name, value):
if name == "max_key_fee":
currency = str(value["currency"]).upper()
if currency not in self._fixed_defaults['CURRENCIES'].keys():
raise InvalidCurrencyError(currency)
elif name == "download_directory":
directory = str(value)
if not os.path.exists(directory):
raise NoSuchDirectoryError(directory)
def is_default(self, name):
"""Check if a config value is wasn't specified by the user
Args:
name: the name of the value to check
Returns: true if config value is the default one, false if it was specified by
the user
Sometimes it may be helpful to understand if a config value was specified
by the user or if it still holds its default value. This function will return
true when the config value is still the default. Note that when the user
specifies a value that is equal to the default one, it will still be considered
as 'user specified'
"""
self._assert_valid_setting(name)
for possible_data_type in self._user_specified:
if name in self._data[possible_data_type]:
return False
return True
def get(self, name, data_type=None):
"""Get a config value
Args:
name: the name of the value to get
data_type: if given, get the value from a specific data set (see below)
Returns: the config value for the given name
If data_type is None, get() will search for the given name in each data set, in
order of precedence. It will return the first value it finds. This is the "effective"
value of a config name. For example, ENV values take precedence over DEFAULT values,
so if a value is present in ENV and in DEFAULT, the ENV value will be returned
"""
self._assert_valid_setting(name)
if data_type is not None:
self._assert_valid_data_type(data_type)
return self._data[data_type][name]
for possible_data_type in self._search_order:
if name in self._data[possible_data_type]:
return self._data[possible_data_type][name]
raise KeyError('{} is not a valid setting'.format(name))
def set(self, name, value, data_types=(TYPE_RUNTIME,)):
"""Set a config value
Args:
name: the name of the value to set
value: the value
data_types: what type(s) of data this is
Returns: None
By default, this sets the RUNTIME value of a config. If you wish to set other
data types (e.g. PERSISTED values to save to a file, CLI values from parsed
command-line options, etc), you can specify that with the data_types param
"""
self._assert_editable_setting(name)
self._assert_valid_setting_value(name, value)
for data_type in data_types:
self._assert_valid_data_type(data_type)
self._data[data_type][name] = value
def update(self, updated_settings, data_types=(TYPE_RUNTIME,)):
for k, v in updated_settings.iteritems():
try:
self.set(k, v, data_types=data_types)
except (KeyError, AssertionError):
pass
def get_current_settings_dict(self):
current_settings = {}
for key in self.get_valid_setting_names():
current_settings[key] = self.get(key)
return current_settings
def get_adjustable_settings_dict(self):
return {
key: val for key, val in self.get_current_settings_dict().iteritems()
if key in self._adjustable_defaults
}
def save_conf_file_settings(self):
if conf_file:
path = conf_file
else:
path = self.get_conf_filename()
ext = os.path.splitext(path)[1]
encoder = settings_encoders.get(ext, False)
assert encoder is not False, 'Unknown settings format %s' % ext
with open(path, 'w') as settings_file:
settings_file.write(encoder(self._data[TYPE_PERSISTED]))
@staticmethod
def _convert_conf_file_lists(decoded):
converted = {}
for k, v in decoded.iteritems():
if k in ADJUSTABLE_SETTINGS and len(ADJUSTABLE_SETTINGS[k]) == 3:
converted[k] = ADJUSTABLE_SETTINGS[k][2](v)
else:
converted[k] = v
return converted
def initialize_post_conf_load(self):
settings.installation_id = settings.get_installation_id()
settings.node_id = settings.get_node_id()
def load_conf_file_settings(self):
if conf_file:
path = conf_file
else:
path = self.get_conf_filename()
ext = os.path.splitext(path)[1]
decoder = settings_decoders.get(ext, False)
assert decoder is not False, 'Unknown settings format %s' % ext
try:
with open(path, 'r') as settings_file:
data = settings_file.read()
decoded = self._fix_old_conf_file_settings(decoder(data))
log.info('Loaded settings file: %s', path)
self._validate_settings(decoded)
self._data[TYPE_PERSISTED].update(self._convert_conf_file_lists(decoded))
except (IOError, OSError) as err:
log.info('%s: Failed to update settings from %s', err, path)
#initialize members depending on config file
self.initialize_post_conf_load()
def _fix_old_conf_file_settings(self, settings_dict):
if 'API_INTERFACE' in settings_dict:
settings_dict['api_host'] = settings_dict['API_INTERFACE']
del settings_dict['API_INTERFACE']
if 'startup_scripts' in settings_dict:
del settings_dict['startup_scripts']
if 'upload_log' in settings_dict:
settings_dict['share_usage_data'] = settings_dict['upload_log']
del settings_dict['upload_log']
if 'share_debug_info' in settings_dict:
settings_dict['share_usage_data'] = settings_dict['share_debug_info']
del settings_dict['share_debug_info']
for key in settings_dict.keys():
if not self._is_valid_setting(key):
log.warning('Ignoring invalid conf file setting: %s', key)
del settings_dict[key]
return settings_dict
def ensure_data_dir(self):
# although there is a risk of a race condition here we don't
# expect there to be multiple processes accessing this
# directory so the risk can be ignored
if not os.path.isdir(self['data_dir']):
os.makedirs(self['data_dir'])
return self['data_dir']
def get_log_filename(self):
"""
Return the log file for this platform.
Also ensure the containing directory exists.
"""
return os.path.join(self.ensure_data_dir(), self['LOG_FILE_NAME'])
def get_api_connection_string(self):
return 'http://%s:%i/%s' % (self['api_host'], self['api_port'], self['API_ADDRESS'])
def get_ui_address(self):
return 'http://%s:%i' % (self['api_host'], self['api_port'])
def get_db_revision_filename(self):
return os.path.join(self.ensure_data_dir(), self['DB_REVISION_FILE_NAME'])
def get_conf_filename(self):
data_dir = self.ensure_data_dir()
yml_path = os.path.join(data_dir, 'daemon_settings.yml')
json_path = os.path.join(data_dir, 'daemon_settings.json')
if os.path.isfile(yml_path):
return yml_path
elif os.path.isfile(json_path):
return json_path
else:
return yml_path
def get_installation_id(self):
install_id_filename = os.path.join(self.ensure_data_dir(), "install_id")
if not self._installation_id:
if os.path.isfile(install_id_filename):
with open(install_id_filename, "r") as install_id_file:
self._installation_id = str(install_id_file.read()).strip()
if not self._installation_id:
self._installation_id = base58.b58encode(utils.generate_id())
with open(install_id_filename, "w") as install_id_file:
install_id_file.write(self._installation_id)
return self._installation_id
def get_node_id(self):
node_id_filename = os.path.join(self.ensure_data_dir(), "node_id")
if not self._node_id:
if os.path.isfile(node_id_filename):
with open(node_id_filename, "r") as node_id_file:
self._node_id = base58.b58decode(str(node_id_file.read()).strip())
if not self._node_id:
self._node_id = utils.generate_id()
with open(node_id_filename, "w") as node_id_file:
node_id_file.write(base58.b58encode(self._node_id))
return self._node_id
def get_session_id(self):
return self._session_id
# type: Config
settings = None
def get_default_env():
env_defaults = {}
for k, v in ADJUSTABLE_SETTINGS.iteritems():
if len(v) == 3:
env_defaults[k] = (v[0], None, v[2])
else:
env_defaults[k] = (v[0], None)
return Env(**env_defaults)
def initialize_settings(load_conf_file=True):
global settings
if settings is None:
settings = Config(FIXED_SETTINGS, ADJUSTABLE_SETTINGS,
environment=get_default_env())
if load_conf_file:
settings.load_conf_file_settings()
+111
View File
@@ -0,0 +1,111 @@
import logging
import random
import time
from twisted.internet import defer
from twisted.internet.task import LoopingCall
from decimal import Decimal
log = logging.getLogger(__name__)
class BlobAvailabilityTracker(object):
"""
Class to track peer counts for known blobs, and to discover new popular blobs
Attributes:
availability (dict): dictionary of peers for known blobs
"""
def __init__(self, blob_manager, peer_finder, dht_node):
self.availability = {}
self._last_mean_availability = Decimal(0.0)
self._blob_manager = blob_manager
self._peer_finder = peer_finder
self._dht_node = dht_node
self._check_popular = LoopingCall(self._update_most_popular)
self._check_mine = LoopingCall(self._update_mine)
def start(self):
log.info("Starting blob availability tracker.")
self._check_popular.start(600)
self._check_mine.start(600)
def stop(self):
log.info("Stopping blob availability tracker.")
if self._check_popular.running:
self._check_popular.stop()
if self._check_mine.running:
self._check_mine.stop()
def get_blob_availability(self, blob, timeout=None):
def _get_peer_count(peers):
have_blob = sum(1 for peer in peers if peer.is_available())
return {blob: have_blob}
d = self._peer_finder.find_peers_for_blob(blob, timeout)
d.addCallback(_get_peer_count)
return d
def get_availability_for_blobs(self, blobs, timeout=None):
dl = [self.get_blob_availability(blob, timeout) for blob in blobs if blob]
d = defer.DeferredList(dl)
d.addCallback(lambda results: [val for success, val in results if success])
return d
@property
def last_mean_availability(self):
return max(Decimal(0.01), self._last_mean_availability)
def _update_peers_for_blob(self, blob):
def _save_peer_info(blob_hash, peers):
v = {blob_hash: peers}
self.availability.update(v)
return v
d = self._peer_finder.find_peers_for_blob(blob)
d.addCallback(lambda r: [[c.host, c.port, c.is_available()] for c in r])
d.addCallback(lambda peers: _save_peer_info(blob, peers))
return d
def _get_most_popular(self):
dl = []
for (hash, _) in self._dht_node.get_most_popular_hashes(10):
encoded = hash.encode('hex')
dl.append(self._update_peers_for_blob(encoded))
return defer.DeferredList(dl)
def _update_most_popular(self):
d = self._get_most_popular()
d.addCallback(lambda _: self._set_mean_peers())
def _update_mine(self):
def _get_peers(blobs):
dl = []
for hash in blobs:
dl.append(self._update_peers_for_blob(hash))
return defer.DeferredList(dl)
def sample(blobs):
return random.sample(blobs, min(len(blobs), 10))
start = time.time()
log.debug('==> Updating the peers for my blobs')
d = self._blob_manager.get_all_verified_blobs()
# as far as I can tell, this only is used to set _last_mean_availability
# which... seems like a very expensive operation for such little payoff.
# so taking a sample should get about the same effect as querying the entire
# list of blobs
d.addCallback(sample)
d.addCallback(_get_peers)
d.addCallback(lambda _: self._set_mean_peers())
d.addCallback(lambda _: log.debug('<== Done updating peers for my blobs. Took %s seconds',
time.time() - start))
# although unused, need to return or else the looping call
# could overrun on a previous call
return d
def _set_mean_peers(self):
num_peers = [len(self.availability[blob]) for blob in self.availability]
mean = Decimal(sum(num_peers)) / Decimal(max(1, len(num_peers)))
self._last_mean_availability = mean
+2 -1
View File
@@ -15,4 +15,5 @@ class BlobInfo(object):
def __init__(self, blob_hash, blob_num, length):
self.blob_hash = blob_hash
self.blob_num = blob_num
self.length = length
self.length = length
+123 -399
View File
@@ -1,438 +1,162 @@
import logging
import os
import leveldb
import time
import json
from sqlite3 import IntegrityError
from twisted.internet import threads, defer, reactor, task
from twisted.python.failure import Failure
from lbrynet.core.HashBlob import BlobFile, TempBlob, BlobFileCreator, TempBlobCreator
from lbrynet import conf
from lbrynet.blob.blob_file import BlobFile
from lbrynet.blob.creator import BlobFileCreator
from lbrynet.core.server.DHTHashAnnouncer import DHTHashSupplier
from lbrynet.core.utils import is_valid_blobhash
from lbrynet.core.cryptoutils import get_lbry_hash_obj
log = logging.getLogger(__name__)
class BlobManager(DHTHashSupplier):
"""This class is subclassed by classes which keep track of which blobs are available
and which give access to new/existing blobs"""
def __init__(self, hash_announcer):
class DiskBlobManager(DHTHashSupplier):
def __init__(self, hash_announcer, blob_dir, storage):
"""
This class stores blobs on the hard disk,
blob_dir - directory where blobs are stored
db_dir - directory where sqlite database of blob information is stored
"""
DHTHashSupplier.__init__(self, hash_announcer)
def setup(self):
pass
def get_blob(self, blob_hash, upload_allowed, length):
pass
def get_blob_creator(self):
pass
def _make_new_blob(self, blob_hash, upload_allowed, length):
pass
def blob_completed(self, blob, next_announce_time=None):
pass
def completed_blobs(self, blobs_to_check):
pass
def hashes_to_announce(self):
pass
def creator_finished(self, blob_creator):
pass
def delete_blob(self, blob_hash):
pass
def get_blob_length(self, blob_hash):
pass
def check_consistency(self):
pass
def blob_requested(self, blob_hash):
pass
def blob_downloaded(self, blob_hash):
pass
def blob_searched_on(self, blob_hash):
pass
def blob_paid_for(self, blob_hash, amount):
pass
class DiskBlobManager(BlobManager):
"""This class stores blobs on the hard disk"""
def __init__(self, hash_announcer, blob_dir, db_dir):
BlobManager.__init__(self, hash_announcer)
self.storage = storage
self.announce_head_blobs_only = conf.settings['announce_head_blobs_only']
self.blob_dir = blob_dir
self.db_dir = db_dir
self.db = None
self.blob_type = BlobFile
self.blob_creator_type = BlobFileCreator
# TODO: consider using an LRU for blobs as there could potentially
# be thousands of blobs loaded up, many stale
self.blobs = {}
self.blob_hashes_to_delete = {} # {blob_hash: being_deleted (True/False)}
self._next_manage_call = None
self.check_should_announce_lc = None
if conf.settings['run_reflector_server']:
self.check_should_announce_lc = task.LoopingCall(self.storage.verify_will_announce_all_head_and_sd_blobs)
def setup(self):
d = threads.deferToThread(self._open_db)
d.addCallback(lambda _: self._manage())
return d
def stop(self):
if self._next_manage_call is not None and self._next_manage_call.active():
self._next_manage_call.cancel()
self._next_manage_call = None
self.db = None
return defer.succeed(True)
def get_blob(self, blob_hash, upload_allowed, length=None):
"""Return a blob identified by blob_hash, which may be a new blob or a blob that is already on the hard disk"""
# TODO: if blob.upload_allowed and upload_allowed is False, change upload_allowed in blob and on disk
if blob_hash in self.blobs:
return defer.succeed(self.blobs[blob_hash])
return self._make_new_blob(blob_hash, upload_allowed, length)
def get_blob_creator(self):
return self.blob_creator_type(self, self.blob_dir)
def _make_new_blob(self, blob_hash, upload_allowed, length=None):
blob = self.blob_type(self.blob_dir, blob_hash, upload_allowed, length)
self.blobs[blob_hash] = blob
d = threads.deferToThread(self._completed_blobs, [blob_hash])
def check_completed(completed_blobs):
def set_length(length):
blob.length = length
if len(completed_blobs) == 1 and completed_blobs[0] == blob_hash:
blob.verified = True
inner_d = threads.deferToThread(self._get_blob_length, blob_hash)
inner_d.addCallback(set_length)
inner_d.addCallback(lambda _: blob)
else:
inner_d = defer.succeed(blob)
return inner_d
d.addCallback(check_completed)
return d
def blob_completed(self, blob, next_announce_time=None):
if next_announce_time is None:
next_announce_time = time.time()
return threads.deferToThread(self._add_completed_blob, blob.blob_hash, blob.length,
time.time(), next_announce_time)
def completed_blobs(self, blobs_to_check):
return threads.deferToThread(self._completed_blobs, blobs_to_check)
def hashes_to_announce(self):
next_announce_time = time.time() + self.hash_reannounce_time
return threads.deferToThread(self._get_blobs_to_announce, next_announce_time)
def creator_finished(self, blob_creator):
logging.debug("blob_creator.blob_hash: %s", blob_creator.blob_hash)
assert blob_creator.blob_hash is not None
assert blob_creator.blob_hash not in self.blobs
assert blob_creator.length is not None
new_blob = self.blob_type(self.blob_dir, blob_creator.blob_hash, True, blob_creator.length)
new_blob.verified = True
self.blobs[blob_creator.blob_hash] = new_blob
if self.hash_announcer is not None:
self.hash_announcer.immediate_announce([blob_creator.blob_hash])
next_announce_time = time.time() + self.hash_reannounce_time
d = self.blob_completed(new_blob, next_announce_time)
else:
d = self.blob_completed(new_blob)
return d
def delete_blobs(self, blob_hashes):
for blob_hash in blob_hashes:
if not blob_hash in self.blob_hashes_to_delete:
self.blob_hashes_to_delete[blob_hash] = False
def update_all_last_verified_dates(self, timestamp):
return threads.deferToThread(self._update_all_last_verified_dates, timestamp)
def immediate_announce_all_blobs(self):
d = threads.deferToThread(self._get_all_verified_blob_hashes)
d.addCallback(self.hash_announcer.immediate_announce)
return d
def get_blob_length(self, blob_hash):
return threads.deferToThread(self._get_blob_length, blob_hash)
def check_consistency(self):
return threads.deferToThread(self._check_consistency)
def _manage(self):
from twisted.internet import reactor
d = self._delete_blobs_marked_for_deletion()
def set_next_manage_call():
self._next_manage_call = reactor.callLater(1, self._manage)
d.addCallback(lambda _: set_next_manage_call())
def _delete_blobs_marked_for_deletion(self):
def remove_from_list(b_h):
del self.blob_hashes_to_delete[b_h]
return b_h
def set_not_deleting(err, b_h):
logging.warning("Failed to delete blob %s. Reason: %s", str(b_h), err.getErrorMessage())
self.blob_hashes_to_delete[b_h] = False
return err
def delete_from_db(result):
b_hs = [r[1] for r in result if r[0] is True]
if b_hs:
d = threads.deferToThread(self._delete_blobs_from_db, b_hs)
else:
d = defer.succeed(True)
def log_error(err):
logging.warning("Failed to delete completed blobs from the db: %s", err.getErrorMessage())
d.addErrback(log_error)
return d
def delete(blob, b_h):
d = blob.delete()
d.addCallbacks(lambda _: remove_from_list(b_h), set_not_deleting, errbackArgs=(b_h,))
return d
ds = []
for blob_hash, being_deleted in self.blob_hashes_to_delete.items():
if being_deleted is False:
self.blob_hashes_to_delete[blob_hash] = True
d = self.get_blob(blob_hash, True)
d.addCallbacks(delete, set_not_deleting, callbackArgs=(blob_hash,), errbackArgs=(blob_hash,))
ds.append(d)
dl = defer.DeferredList(ds, consumeErrors=True)
dl.addCallback(delete_from_db)
return defer.DeferredList(ds)
######### database calls #########
def _open_db(self):
self.db = leveldb.LevelDB(os.path.join(self.db_dir, "blobs.db"))
def _add_completed_blob(self, blob_hash, length, timestamp, next_announce_time=None):
logging.debug("Adding a completed blob. blob_hash=%s, length=%s", blob_hash, str(length))
if next_announce_time is None:
next_announce_time = timestamp
self.db.Put(blob_hash, json.dumps((length, timestamp, next_announce_time)), sync=True)
def _completed_blobs(self, blobs_to_check):
blobs = []
for b in blobs_to_check:
if is_valid_blobhash(b):
try:
length, verified_time, next_announce_time = json.loads(self.db.Get(b))
except KeyError:
continue
file_path = os.path.join(self.blob_dir, b)
if os.path.isfile(file_path):
if verified_time > os.path.getctime(file_path):
blobs.append(b)
return blobs
def _get_blob_length(self, blob):
length, verified_time, next_announce_time = json.loads(self.db.Get(blob))
return length
def _update_blob_verified_timestamp(self, blob, timestamp):
length, old_verified_time, next_announce_time = json.loads(self.db.Get(blob))
self.db.Put(blob, json.dumps((length, timestamp, next_announce_time)), sync=True)
def _get_blobs_to_announce(self, next_announce_time):
# TODO: See if the following would be better for handling announce times:
# TODO: Have a separate db for them, and read the whole thing into memory
# TODO: on startup, and then write changes to db when they happen
blobs = []
batch = leveldb.WriteBatch()
current_time = time.time()
for blob_hash, blob_info in self.db.RangeIter():
length, verified_time, announce_time = json.loads(blob_info)
if announce_time < current_time:
batch.Put(blob_hash, json.dumps((length, verified_time, next_announce_time)))
blobs.append(blob_hash)
self.db.Write(batch, sync=True)
return blobs
def _update_all_last_verified_dates(self, timestamp):
batch = leveldb.WriteBatch()
for blob_hash, blob_info in self.db.RangeIter():
length, verified_time, announce_time = json.loads(blob_info)
batch.Put(blob_hash, json.dumps((length, timestamp, announce_time)))
self.db.Write(batch, sync=True)
def _delete_blobs_from_db(self, blob_hashes):
batch = leveldb.WriteBatch()
for blob_hash in blob_hashes:
batch.Delete(blob_hash)
self.db.Write(batch, sync=True)
def _check_consistency(self):
batch = leveldb.WriteBatch()
current_time = time.time()
for blob_hash, blob_info in self.db.RangeIter():
length, verified_time, announce_time = json.loads(blob_info)
file_path = os.path.join(self.blob_dir, blob_hash)
if os.path.isfile(file_path):
if verified_time < os.path.getctime(file_path):
h = get_lbry_hash_obj()
len_so_far = 0
f = open(file_path)
while True:
data = f.read(2**12)
if not data:
break
h.update(data)
len_so_far += len(data)
if len_so_far == length and h.hexdigest() == blob_hash:
batch.Put(blob_hash, json.dumps((length, current_time, announce_time)))
self.db.Write(batch, sync=True)
def _get_all_verified_blob_hashes(self):
blob_hashes = []
for blob_hash, blob_info in self.db.RangeIter():
length, verified_time, announce_time = json.loads(blob_info)
file_path = os.path.join(self.blob_dir, blob_hash)
if os.path.isfile(file_path):
if verified_time > os.path.getctime(file_path):
blob_hashes.append(blob_hash)
return blob_hashes
class TempBlobManager(BlobManager):
"""This class stores blobs in memory"""
def __init__(self, hash_announcer):
BlobManager.__init__(self, hash_announcer)
self.blob_type = TempBlob
self.blob_creator_type = TempBlobCreator
self.blobs = {}
self.blob_next_announces = {}
self.blob_hashes_to_delete = {} # {blob_hash: being_deleted (True/False)}
self._next_manage_call = None
def setup(self):
self._manage()
if self.check_should_announce_lc and not self.check_should_announce_lc.running:
self.check_should_announce_lc.start(600)
return defer.succeed(True)
def stop(self):
if self._next_manage_call is not None and self._next_manage_call.active():
self._next_manage_call.cancel()
self._next_manage_call = None
if self.check_should_announce_lc and self.check_should_announce_lc.running:
self.check_should_announce_lc.stop()
return defer.succeed(True)
def get_blob(self, blob_hash, upload_allowed, length=None):
def get_blob(self, blob_hash, length=None):
"""Return a blob identified by blob_hash, which may be a new blob or a
blob that is already on the hard disk
"""
if length is not None and not isinstance(length, int):
raise Exception("invalid length type: %s (%s)" % (length, str(type(length))))
if blob_hash in self.blobs:
return defer.succeed(self.blobs[blob_hash])
return self._make_new_blob(blob_hash, upload_allowed, length)
return self._make_new_blob(blob_hash, length)
def get_blob_creator(self):
return self.blob_creator_type(self)
return self.blob_creator_type(self.blob_dir)
def _make_new_blob(self, blob_hash, upload_allowed, length=None):
blob = self.blob_type(blob_hash, upload_allowed, length)
def _make_new_blob(self, blob_hash, length=None):
log.debug('Making a new blob for %s', blob_hash)
blob = BlobFile(self.blob_dir, blob_hash, length)
self.blobs[blob_hash] = blob
return defer.succeed(blob)
def blob_completed(self, blob, next_announce_time=None):
if next_announce_time is None:
next_announce_time = time.time()
self.blob_next_announces[blob.blob_hash] = next_announce_time
return defer.succeed(True)
def immediate_announce(self, blob_hashes):
if self.hash_announcer:
return self.hash_announcer.immediate_announce(blob_hashes)
raise Exception("Hash announcer not set")
def completed_blobs(self, blobs_to_check):
blobs = [b.blob_hash for b in self.blobs.itervalues() if b.blob_hash in blobs_to_check and b.is_validated()]
return defer.succeed(blobs)
@defer.inlineCallbacks
def blob_completed(self, blob, next_announce_time=None, should_announce=True):
if next_announce_time is None:
next_announce_time = self.get_next_announce_time()
yield self.storage.add_completed_blob(
blob.blob_hash, blob.length, next_announce_time, should_announce
)
# we announce all blobs immediately, if announce_head_blob_only is False
# otherwise, announce only if marked as should_announce
if not self.announce_head_blobs_only or should_announce:
reactor.callLater(0, self.immediate_announce, [blob.blob_hash])
def completed_blobs(self, blobhashes_to_check):
return self._completed_blobs(blobhashes_to_check)
def hashes_to_announce(self):
now = time.time()
blobs = [blob_hash for blob_hash, announce_time in self.blob_next_announces.iteritems() if announce_time < now]
next_announce_time = now + self.hash_reannounce_time
for b in blobs:
self.blob_next_announces[b] = next_announce_time
return defer.succeed(blobs)
return self.storage.get_blobs_to_announce(self.hash_announcer)
def creator_finished(self, blob_creator):
assert blob_creator.blob_hash is not None
assert blob_creator.blob_hash not in self.blobs
assert blob_creator.length is not None
new_blob = self.blob_type(blob_creator.blob_hash, True, blob_creator.length)
new_blob.verified = True
new_blob.data_buffer = blob_creator.data_buffer
new_blob.length = blob_creator.length
self.blobs[blob_creator.blob_hash] = new_blob
if self.hash_announcer is not None:
self.hash_announcer.immediate_announce([blob_creator.blob_hash])
next_announce_time = time.time() + self.hash_reannounce_time
d = self.blob_completed(new_blob, next_announce_time)
else:
d = self.blob_completed(new_blob)
d.addCallback(lambda _: new_blob)
return d
def count_should_announce_blobs(self):
return self.storage.count_should_announce_blobs()
def delete_blobs(self, blob_hashes):
for blob_hash in blob_hashes:
if not blob_hash in self.blob_hashes_to_delete:
self.blob_hashes_to_delete[blob_hash] = False
def get_blob_length(self, blob_hash):
def set_should_announce(self, blob_hash, should_announce):
if blob_hash in self.blobs:
if self.blobs[blob_hash].length is not None:
return defer.succeed(self.blobs[blob_hash].length)
return defer.fail(ValueError("No such blob hash is known"))
blob = self.blobs[blob_hash]
if blob.get_is_verified():
return self.storage.set_should_announce(
blob_hash, self.get_next_announce_time(), should_announce
)
return defer.succeed(False)
def get_should_announce(self, blob_hash):
return self.storage.should_announce(blob_hash)
def creator_finished(self, blob_creator, should_announce):
log.debug("blob_creator.blob_hash: %s", blob_creator.blob_hash)
if blob_creator.blob_hash is None:
raise Exception("Blob hash is None")
if blob_creator.blob_hash in self.blobs:
raise Exception("Creator finished for blob that is already marked as completed")
if blob_creator.length is None:
raise Exception("Blob has a length of 0")
new_blob = BlobFile(self.blob_dir, blob_creator.blob_hash, blob_creator.length)
self.blobs[blob_creator.blob_hash] = new_blob
next_announce_time = self.get_next_announce_time()
return self.blob_completed(new_blob, next_announce_time, should_announce)
def immediate_announce_all_blobs(self):
return self.hash_announcer.immediate_announce(self.blobs.iterkeys())
d = self._get_all_verified_blob_hashes()
d.addCallback(self.immediate_announce)
return d
def _manage(self):
from twisted.internet import reactor
def get_all_verified_blobs(self):
d = self._get_all_verified_blob_hashes()
d.addCallback(self.completed_blobs)
return d
d = self._delete_blobs_marked_for_deletion()
@defer.inlineCallbacks
def delete_blobs(self, blob_hashes):
bh_to_delete_from_db = []
for blob_hash in blob_hashes:
try:
blob = yield self.get_blob(blob_hash)
yield blob.delete()
bh_to_delete_from_db.append(blob_hash)
del self.blobs[blob_hash]
except Exception as e:
log.warning("Failed to delete blob file. Reason: %s", e)
try:
yield self.storage.delete_blobs_from_db(bh_to_delete_from_db)
except IntegrityError as err:
if err.message != "FOREIGN KEY constraint failed":
raise err
def set_next_manage_call():
logging.info("Setting the next manage call in %s", str(self))
self._next_manage_call = reactor.callLater(1, self._manage)
@defer.inlineCallbacks
def _completed_blobs(self, blobhashes_to_check):
"""Returns of the blobhashes_to_check, which are valid"""
blobs = yield defer.DeferredList([self.get_blob(b) for b in blobhashes_to_check])
blob_hashes = [b.blob_hash for success, b in blobs if success and b.verified]
defer.returnValue(blob_hashes)
d.addCallback(lambda _: set_next_manage_call())
def _get_all_verified_blob_hashes(self):
d = self.storage.get_all_blob_hashes()
def _delete_blobs_marked_for_deletion(self):
def get_verified_blobs(blobs):
verified_blobs = []
for blob_hash in blobs:
file_path = os.path.join(self.blob_dir, blob_hash)
if os.path.isfile(file_path):
verified_blobs.append(blob_hash)
return verified_blobs
def remove_from_list(b_h):
del self.blob_hashes_to_delete[b_h]
logging.info("Deleted blob %s", blob_hash)
return b_h
def set_not_deleting(err, b_h):
logging.warning("Failed to delete blob %s. Reason: %s", str(b_h), err.getErrorMessage())
self.blob_hashes_to_delete[b_h] = False
return b_h
ds = []
for blob_hash, being_deleted in self.blob_hashes_to_delete.items():
if being_deleted is False:
if blob_hash in self.blobs:
self.blob_hashes_to_delete[blob_hash] = True
logging.info("Found a blob marked for deletion: %s", blob_hash)
blob = self.blobs[blob_hash]
d = blob.delete()
d.addCallbacks(lambda _: remove_from_list(blob_hash), set_not_deleting,
errbackArgs=(blob_hash,))
ds.append(d)
else:
remove_from_list(blob_hash)
d = defer.fail(Failure(ValueError("No such blob known")))
logging.warning("Blob %s cannot be deleted because it is unknown")
ds.append(d)
return defer.DeferredList(ds)
d.addCallback(lambda blobs: threads.deferToThread(get_verified_blobs, blobs))
return d
+17 -2
View File
@@ -1,6 +1,21 @@
class DownloadOptionChoice(object):
"""A possible choice that can be picked for some option.
An option can have one or more choices that can be picked from.
"""
def __init__(self, value, short_description, long_description, bool_options_description=None):
self.value = value
self.short_description = short_description
self.long_description = long_description
self.bool_options_description = bool_options_description
class DownloadOption(object):
def __init__(self, option_types, long_description, short_description, default):
"""An option for a user to select a value from several different choices."""
def __init__(self, option_types, long_description, short_description, default_value,
default_value_description):
self.option_types = option_types
self.long_description = long_description
self.short_description = short_description
self.default = default
self.default_value = default_value
self.default_value_description = default_value_description
+121 -2
View File
@@ -10,10 +10,37 @@ class DownloadCanceledError(Exception):
pass
class DownloadSDTimeout(Exception):
def __init__(self, download):
Exception.__init__(self, 'Failed to download sd blob {} within timeout'.format(download))
self.download = download
class DownloadTimeoutError(Exception):
def __init__(self, download):
Exception.__init__(self, 'Failed to download {} within timeout'.format(download))
self.download = download
class DownloadDataTimeout(Exception):
def __init__(self, download):
Exception.__init__(self, 'Failed to download data blobs for sd hash '
'{} within timeout'.format(download))
self.download = download
class RequestCanceledError(Exception):
pass
class NegativeFundsError(Exception):
pass
class NullFundsError(Exception):
pass
class InsufficientFundsError(Exception):
pass
@@ -22,14 +49,65 @@ class ConnectionClosedBeforeResponseError(Exception):
pass
class KeyFeeAboveMaxAllowed(Exception):
pass
class InvalidExchangeRateResponse(Exception):
def __init__(self, source, reason):
Exception.__init__(self, 'Failed to get exchange rate from {}:{}'.format(source, reason))
self.source = source
self.reason = reason
class UnknownNameError(Exception):
def __init__(self, name):
Exception.__init__(self, 'Name {} is unknown'.format(name))
self.name = name
class UnknownClaimID(Exception):
def __init__(self, claim_id):
Exception.__init__(self, 'Claim {} is unknown'.format(claim_id))
self.claim_id = claim_id
class UnknownURI(Exception):
def __init__(self, uri):
Exception.__init__(self, 'URI {} cannot be resolved'.format(uri))
self.name = uri
class UnknownOutpoint(Exception):
def __init__(self, outpoint):
Exception.__init__(self, 'Outpoint {} cannot be resolved'.format(outpoint))
self.outpoint = outpoint
class InvalidName(Exception):
def __init__(self, name, invalid_characters):
self.name = name
self.invalid_characters = invalid_characters
Exception.__init__(
self, 'URI contains invalid characters: {}'.format(','.join(invalid_characters)))
class UnknownStreamTypeError(Exception):
def __init__(self, stream_type):
self.stream_type = stream_type
def __str__(self):
return repr(self.stream_type)
class InvalidStreamDescriptorError(Exception):
pass
class InvalidStreamInfoError(Exception):
def __init__(self, name):
def __init__(self, name, stream_info):
msg = '{} has claim with invalid stream info: {}'.format(name, stream_info)
Exception.__init__(self, msg)
self.name = name
self.stream_info = stream_info
class MisbehavingPeerError(Exception):
@@ -45,4 +123,45 @@ class NoResponseError(MisbehavingPeerError):
class InvalidResponseError(MisbehavingPeerError):
pass
pass
class NoSuchBlobError(Exception):
pass
class NoSuchStreamHash(Exception):
pass
class NoSuchSDHash(Exception):
"""
Raised if sd hash is not known
"""
class InvalidBlobHashError(Exception):
pass
class InvalidHeaderError(Exception):
pass
class InvalidAuthenticationToken(Exception):
pass
class NegotiationError(Exception):
pass
class InvalidCurrencyError(Exception):
def __init__(self, currency):
self.currency = currency
Exception.__init__(
self, 'Invalid currency: {} is not a supported currency.'.format(currency))
class NoSuchDirectoryError(Exception):
def __init__(self, directory):
self.directory = directory
Exception.__init__(self, 'No such directory {}'.format(directory))
+4 -1
View File
@@ -11,5 +11,8 @@ class DummyHashAnnouncer(object):
def add_supplier(self, *args):
pass
def hash_queue_size(self):
return 0
def immediate_announce(self, *args):
pass
pass
-391
View File
@@ -1,391 +0,0 @@
from StringIO import StringIO
import logging
import os
import tempfile
import threading
import shutil
from twisted.internet import interfaces, defer, threads
from twisted.protocols.basic import FileSender
from twisted.python.failure import Failure
from zope.interface import implements
from lbrynet.conf import BLOB_SIZE
from lbrynet.core.Error import DownloadCanceledError, InvalidDataError
from lbrynet.core.cryptoutils import get_lbry_hash_obj
class HashBlobReader(object):
implements(interfaces.IConsumer)
def __init__(self, write_func):
self.write_func = write_func
def registerProducer(self, producer, streaming):
from twisted.internet import reactor
self.producer = producer
self.streaming = streaming
if self.streaming is False:
reactor.callLater(0, self.producer.resumeProducing)
def unregisterProducer(self):
pass
def write(self, data):
from twisted.internet import reactor
self.write_func(data)
if self.streaming is False:
reactor.callLater(0, self.producer.resumeProducing)
class HashBlobWriter(object):
def __init__(self, write_handle, length_getter, finished_cb):
self.write_handle = write_handle
self.length_getter = length_getter
self.finished_cb = finished_cb
self.hashsum = get_lbry_hash_obj()
self.len_so_far = 0
def write(self, data):
self.hashsum.update(data)
self.len_so_far += len(data)
if self.len_so_far > self.length_getter():
self.finished_cb(self, Failure(InvalidDataError("Length so far is greater than the expected length."
" %s to %s" % (str(self.len_so_far),
str(self.length_getter())))))
else:
self.write_handle.write(data)
if self.len_so_far == self.length_getter():
self.finished_cb(self)
def cancel(self, reason=None):
if reason is None:
reason = Failure(DownloadCanceledError())
self.finished_cb(self, reason)
class HashBlob(object):
"""A chunk of data available on the network which is specified by a hashsum"""
def __init__(self, blob_hash, upload_allowed, length=None):
self.blob_hash = blob_hash
self.length = length
self.writers = {} # {Peer: writer, finished_deferred}
self.finished_deferred = None
self.verified = False
self.upload_allowed = upload_allowed
self.readers = 0
def set_length(self, length):
if self.length is not None and length == self.length:
return True
if self.length is None and 0 <= length <= BLOB_SIZE:
self.length = length
return True
logging.warning("Got an invalid length. Previous length: %s, Invalid length: %s", str(self.length), str(length))
return False
def get_length(self):
return self.length
def is_validated(self):
if self.verified:
return True
else:
return False
def is_downloading(self):
if self.writers:
return True
return False
def read(self, write_func):
def close_self(*args):
self.close_read_handle(file_handle)
return args[0]
file_sender = FileSender()
reader = HashBlobReader(write_func)
file_handle = self.open_for_reading()
if file_handle is not None:
d = file_sender.beginFileTransfer(file_handle, reader)
d.addCallback(close_self)
else:
d = defer.fail(ValueError("Could not read the blob"))
return d
def writer_finished(self, writer, err=None):
def fire_finished_deferred():
self.verified = True
for p, (w, finished_deferred) in self.writers.items():
if w == writer:
finished_deferred.callback(self)
del self.writers[p]
return True
logging.warning("Somehow, the writer that was accepted as being valid was already removed. writer: %s",
str(writer))
return False
def errback_finished_deferred(err):
for p, (w, finished_deferred) in self.writers.items():
if w == writer:
finished_deferred.errback(err)
del self.writers[p]
def cancel_other_downloads():
for p, (w, finished_deferred) in self.writers.items():
w.cancel()
if err is None:
if writer.len_so_far == self.length and writer.hashsum.hexdigest() == self.blob_hash:
if self.verified is False:
d = self._save_verified_blob(writer)
d.addCallbacks(lambda _: fire_finished_deferred(), errback_finished_deferred)
d.addCallback(lambda _: cancel_other_downloads())
else:
errback_finished_deferred(Failure(DownloadCanceledError()))
d = defer.succeed(True)
else:
err_string = "length vs expected: {0}, {1}, hash vs expected: {2}, {3}"
err_string = err_string.format(self.length, writer.len_so_far, self.blob_hash,
writer.hashsum.hexdigest())
errback_finished_deferred(Failure(InvalidDataError(err_string)))
d = defer.succeed(True)
else:
errback_finished_deferred(err)
d = defer.succeed(True)
d.addBoth(lambda _: self._close_writer(writer))
return d
def open_for_writing(self, peer):
pass
def open_for_reading(self):
pass
def delete(self):
pass
def close_read_handle(self, file_handle):
pass
def _close_writer(self, writer):
pass
def _save_verified_blob(self, writer):
pass
def __str__(self):
return self.blob_hash[:16]
def __repr__(self):
return str(self)
class BlobFile(HashBlob):
"""A HashBlob which will be saved to the hard disk of the downloader"""
def __init__(self, blob_dir, *args):
HashBlob.__init__(self, *args)
self.blob_dir = blob_dir
self.file_path = os.path.join(blob_dir, self.blob_hash)
self.setting_verified_blob_lock = threading.Lock()
self.moved_verified_blob = False
def open_for_writing(self, peer):
if not peer in self.writers:
logging.debug("Opening %s to be written by %s", str(self), str(peer))
write_file = tempfile.NamedTemporaryFile(delete=False, dir=self.blob_dir)
finished_deferred = defer.Deferred()
writer = HashBlobWriter(write_file, self.get_length, self.writer_finished)
self.writers[peer] = (writer, finished_deferred)
return finished_deferred, writer.write, writer.cancel
logging.warning("Tried to download the same file twice simultaneously from the same peer")
return None, None, None
def open_for_reading(self):
if self.verified is True:
file_handle = None
try:
file_handle = open(self.file_path, 'rb')
self.readers += 1
return file_handle
except IOError:
self.close_read_handle(file_handle)
return None
def delete(self):
if not self.writers and not self.readers:
self.verified = False
self.moved_verified_blob = False
def delete_from_file_system():
if os.path.isfile(self.file_path):
os.remove(self.file_path)
d = threads.deferToThread(delete_from_file_system)
def log_error(err):
logging.warning("An error occurred deleting %s: %s", str(self.file_path), err.getErrorMessage())
return err
d.addErrback(log_error)
return d
else:
return defer.fail(Failure(ValueError("File is currently being read or written and cannot be deleted")))
def close_read_handle(self, file_handle):
if file_handle is not None:
file_handle.close()
self.readers -= 1
def _close_writer(self, writer):
if writer.write_handle is not None:
logging.debug("Closing %s", str(self))
name = writer.write_handle.name
writer.write_handle.close()
threads.deferToThread(os.remove, name)
writer.write_handle = None
def _save_verified_blob(self, writer):
def move_file():
with self.setting_verified_blob_lock:
if self.moved_verified_blob is False:
temp_file_name = writer.write_handle.name
writer.write_handle.close()
shutil.move(temp_file_name, self.file_path)
writer.write_handle = None
self.moved_verified_blob = True
return True
else:
raise DownloadCanceledError()
return threads.deferToThread(move_file)
class TempBlob(HashBlob):
"""A HashBlob which will only exist in memory"""
def __init__(self, *args):
HashBlob.__init__(self, *args)
self.data_buffer = ""
def open_for_writing(self, peer):
if not peer in self.writers:
temp_buffer = StringIO()
finished_deferred = defer.Deferred()
writer = HashBlobWriter(temp_buffer, self.get_length, self.writer_finished)
self.writers[peer] = (writer, finished_deferred)
return finished_deferred, writer.write, writer.cancel
return None, None, None
def open_for_reading(self):
if self.verified is True:
return StringIO(self.data_buffer)
return None
def delete(self):
if not self.writers and not self.readers:
self.verified = False
self.data_buffer = ''
return defer.succeed(True)
else:
return defer.fail(Failure(ValueError("Blob is currently being read or written and cannot be deleted")))
def close_read_handle(self, file_handle):
file_handle.close()
def _close_writer(self, writer):
if writer.write_handle is not None:
writer.write_handle.close()
writer.write_handle = None
def _save_verified_blob(self, writer):
if not self.data_buffer:
self.data_buffer = writer.write_handle.getvalue()
writer.write_handle.close()
writer.write_handle = None
return defer.succeed(True)
else:
return defer.fail(Failure(DownloadCanceledError()))
class HashBlobCreator(object):
def __init__(self, blob_manager):
self.blob_manager = blob_manager
self.hashsum = get_lbry_hash_obj()
self.len_so_far = 0
self.blob_hash = None
self.length = None
def open(self):
pass
def close(self):
self.length = self.len_so_far
if self.length == 0:
self.blob_hash = None
else:
self.blob_hash = self.hashsum.hexdigest()
d = self._close()
if self.blob_hash is not None:
d.addCallback(lambda _: self.blob_manager.creator_finished(self))
d.addCallback(lambda _: self.blob_hash)
else:
d.addCallback(lambda _: None)
return d
def write(self, data):
self.hashsum.update(data)
self.len_so_far += len(data)
self._write(data)
def _close(self):
pass
def _write(self, data):
pass
class BlobFileCreator(HashBlobCreator):
def __init__(self, blob_manager, blob_dir):
HashBlobCreator.__init__(self, blob_manager)
self.blob_dir = blob_dir
self.out_file = tempfile.NamedTemporaryFile(delete=False, dir=self.blob_dir)
def _close(self):
temp_file_name = self.out_file.name
self.out_file.close()
def change_file_name():
shutil.move(temp_file_name, os.path.join(self.blob_dir, self.blob_hash))
return True
if self.blob_hash is not None:
d = threads.deferToThread(change_file_name)
else:
d = defer.succeed(True)
return d
def _write(self, data):
self.out_file.write(data)
class TempBlobCreator(HashBlobCreator):
def __init__(self, blob_manager):
HashBlobCreator.__init__(self, blob_manager)
self.data_buffer = ''
def _close(self):
return defer.succeed(True)
def _write(self, data):
self.data_buffer += data
-468
View File
@@ -1,468 +0,0 @@
from lbrynet.interfaces import IRequestCreator, IQueryHandlerFactory, IQueryHandler, ILBRYWallet
from lbrynet.core.client.ClientRequest import ClientRequest
from lbrynet.core.Error import UnknownNameError, InvalidStreamInfoError, RequestCanceledError
from bitcoinrpc.authproxy import AuthServiceProxy, JSONRPCException
from twisted.internet import threads, reactor, defer, task
from twisted.python.failure import Failure
from collections import defaultdict, deque
from zope.interface import implements
from decimal import Decimal
import datetime
import logging
import json
import subprocess
import socket
import time
import os
class ReservedPoints(object):
def __init__(self, identifier, amount):
self.identifier = identifier
self.amount = amount
class LBRYcrdWallet(object):
"""This class implements the LBRYWallet interface for the LBRYcrd payment system"""
implements(ILBRYWallet)
def __init__(self, rpc_user, rpc_pass, rpc_url, rpc_port, start_lbrycrdd=False,
wallet_dir=None, wallet_conf=None):
self.rpc_conn_string = "http://%s:%s@%s:%s" % (rpc_user, rpc_pass, rpc_url, str(rpc_port))
self.next_manage_call = None
self.wallet_balance = Decimal(0.0)
self.total_reserved_points = Decimal(0.0)
self.peer_addresses = {} # {Peer: string}
self.queued_payments = defaultdict(Decimal) # {address(string): amount(Decimal)}
self.expected_balances = defaultdict(Decimal) # {address(string): amount(Decimal)}
self.current_address_given_to_peer = {} # {Peer: address(string)}
self.expected_balance_at_time = deque() # (Peer, address(string), amount(Decimal), time(datetime), count(int),
# incremental_amount(float))
self.max_expected_payment_time = datetime.timedelta(minutes=3)
self.stopped = True
self.start_lbrycrdd = start_lbrycrdd
self.started_lbrycrdd = False
self.wallet_dir = wallet_dir
self.wallet_conf = wallet_conf
self.lbrycrdd = None
self.manage_running = False
def start(self):
def make_connection():
if self.start_lbrycrdd is True:
self._start_daemon()
logging.info("Trying to connect to %s", self.rpc_conn_string)
self.rpc_conn = AuthServiceProxy(self.rpc_conn_string)
logging.info("Connected!")
def start_manage():
self.stopped = False
self.manage()
return True
d = threads.deferToThread(make_connection)
d.addCallback(lambda _: start_manage())
return d
def stop(self):
self.stopped = True
# If self.next_manage_call is None, then manage is currently running or else
# start has not been called, so set stopped and do nothing else.
if self.next_manage_call is not None:
self.next_manage_call.cancel()
self.next_manage_call = None
d = self.manage()
if self.start_lbrycrdd is True:
d.addBoth(lambda _: self._stop_daemon())
return d
def manage(self):
logging.info("Doing manage")
self.next_manage_call = None
have_set_manage_running = [False]
def check_if_manage_running():
d = defer.Deferred()
def fire_if_not_running():
if self.manage_running is False:
self.manage_running = True
have_set_manage_running[0] = True
d.callback(True)
else:
task.deferLater(reactor, 1, fire_if_not_running)
fire_if_not_running()
return d
d = check_if_manage_running()
d.addCallback(lambda _: self._check_expected_balances())
d.addCallback(lambda _: self._send_payments())
d.addCallback(lambda _: threads.deferToThread(self._get_wallet_balance))
def set_wallet_balance(balance):
self.wallet_balance = balance
d.addCallback(set_wallet_balance)
def set_next_manage_call():
if not self.stopped:
self.next_manage_call = reactor.callLater(60, self.manage)
d.addCallback(lambda _: set_next_manage_call())
def log_error(err):
logging.error("Something went wrong during manage. Error message: %s", err.getErrorMessage())
return err
d.addErrback(log_error)
def set_manage_not_running(arg):
if have_set_manage_running[0] is True:
self.manage_running = False
return arg
d.addBoth(set_manage_not_running)
return d
def get_info_exchanger(self):
return LBRYcrdAddressRequester(self)
def get_wallet_info_query_handler_factory(self):
return LBRYcrdAddressQueryHandlerFactory(self)
def get_balance(self):
d = threads.deferToThread(self._get_wallet_balance)
return d
def reserve_points(self, peer, amount):
"""
Ensure a certain amount of points are available to be sent as payment, before the service is rendered
@param peer: The peer to which the payment will ultimately be sent
@param amount: The amount of points to reserve
@return: A ReservedPoints object which is given to send_points once the service has been rendered
"""
rounded_amount = Decimal(str(round(amount, 8)))
#if peer in self.peer_addresses:
if self.wallet_balance >= self.total_reserved_points + rounded_amount:
self.total_reserved_points += rounded_amount
return ReservedPoints(peer, rounded_amount)
return None
def cancel_point_reservation(self, reserved_points):
"""
Return all of the points that were reserved previously for some ReservedPoints object
@param reserved_points: ReservedPoints previously returned by reserve_points
@return: None
"""
self.total_reserved_points -= reserved_points.amount
def send_points(self, reserved_points, amount):
"""
Schedule a payment to be sent to a peer
@param reserved_points: ReservedPoints object previously returned by reserve_points
@param amount: amount of points to actually send, must be less than or equal to the
amount reserved in reserved_points
@return: Deferred which fires when the payment has been scheduled
"""
rounded_amount = Decimal(str(round(amount, 8)))
peer = reserved_points.identifier
assert(rounded_amount <= reserved_points.amount)
assert(peer in self.peer_addresses)
self.queued_payments[self.peer_addresses[peer]] += rounded_amount
# make any unused points available
self.total_reserved_points -= (reserved_points.amount - rounded_amount)
logging.info("ordering that %s points be sent to %s", str(rounded_amount),
str(self.peer_addresses[peer]))
peer.update_stats('points_sent', amount)
return defer.succeed(True)
def add_expected_payment(self, peer, amount):
"""Increase the number of points expected to be paid by a peer"""
rounded_amount = Decimal(str(round(amount, 8)))
assert(peer in self.current_address_given_to_peer)
address = self.current_address_given_to_peer[peer]
logging.info("expecting a payment at address %s in the amount of %s", str(address), str(rounded_amount))
self.expected_balances[address] += rounded_amount
expected_balance = self.expected_balances[address]
expected_time = datetime.datetime.now() + self.max_expected_payment_time
self.expected_balance_at_time.append((peer, address, expected_balance, expected_time, 0, amount))
peer.update_stats('expected_points', amount)
def update_peer_address(self, peer, address):
self.peer_addresses[peer] = address
def get_new_address_for_peer(self, peer):
def set_address_for_peer(address):
self.current_address_given_to_peer[peer] = address
return address
d = threads.deferToThread(self._get_new_address)
d.addCallback(set_address_for_peer)
return d
def get_stream_info_for_name(self, name):
def get_stream_info_from_value(result):
r_dict = {}
if 'value' in result:
value = result['value']
try:
value_dict = json.loads(value)
except ValueError:
return Failure(InvalidStreamInfoError(name))
if 'stream_hash' in value_dict:
r_dict['stream_hash'] = value_dict['stream_hash']
if 'name' in value_dict:
r_dict['name'] = value_dict['name']
if 'description' in value_dict:
r_dict['description'] = value_dict['description']
return r_dict
return Failure(UnknownNameError(name))
d = threads.deferToThread(self._get_value_for_name, name)
d.addCallback(get_stream_info_from_value)
return d
def claim_name(self, stream_hash, name, amount):
value = json.dumps({"stream_hash": stream_hash})
d = threads.deferToThread(self._claim_name, name, value, amount)
return d
def get_available_balance(self):
return float(self.wallet_balance - self.total_reserved_points)
def get_new_address(self):
return threads.deferToThread(self._get_new_address)
def _start_daemon(self):
if os.name == "nt":
si = subprocess.STARTUPINFO
si.dwFlags = subprocess.STARTF_USESHOWWINDOW
si.wShowWindow = subprocess.SW_HIDE
self.lbrycrdd = subprocess.Popen(["lbrycrdd.exe", "-datadir=%s" % self.wallet_dir,
"-conf=%s" % self.wallet_conf], startupinfo=si)
else:
self.lbrycrdd = subprocess.Popen(["./lbrycrdd", "-datadir=%s" % self.wallet_dir,
"-conf=%s" % self.wallet_conf])
self.started_lbrycrdd = True
tries = 0
while tries < 5:
try:
rpc_conn = AuthServiceProxy(self.rpc_conn_string)
rpc_conn.getinfo()
break
except (socket.error, JSONRPCException):
tries += 1
logging.warning("Failed to connect to lbrycrdd.")
if tries < 5:
time.sleep(2 ** tries)
logging.warning("Trying again in %d seconds", 2 ** tries)
else:
logging.warning("Giving up.")
else:
self.lbrycrdd.terminate()
raise ValueError("Couldn't open lbrycrdd")
def _stop_daemon(self):
if self.lbrycrdd is not None and self.started_lbrycrdd is True:
d = threads.deferToThread(self._rpc_stop)
return d
return defer.succeed(True)
def _check_expected_balances(self):
now = datetime.datetime.now()
balances_to_check = []
try:
while self.expected_balance_at_time[0][3] < now:
balances_to_check.append(self.expected_balance_at_time.popleft())
except IndexError:
pass
ds = []
for balance_to_check in balances_to_check:
d = threads.deferToThread(self._check_expected_balance, balance_to_check)
ds.append(d)
dl = defer.DeferredList(ds)
def handle_checks(results):
from future_builtins import zip
for balance, (success, result) in zip(balances_to_check, results):
peer = balance[0]
if success is True:
if result is False:
if balance[4] <= 1: # first or second strike, give them another chance
new_expected_balance = (balance[0],
balance[1],
balance[2],
datetime.datetime.now() + self.max_expected_payment_time,
balance[4] + 1,
balance[5])
self.expected_balance_at_time.append(new_expected_balance)
peer.update_score(-5.0)
else:
peer.update_score(-50.0)
else:
if balance[4] == 0:
peer.update_score(balance[5])
peer.update_stats('points_received', balance[5])
else:
logging.warning("Something went wrong checking a balance. Peer: %s, account: %s,"
"expected balance: %s, expected time: %s, count: %s, error: %s",
str(balance[0]), str(balance[1]), str(balance[2]), str(balance[3]),
str(balance[4]), str(result.getErrorMessage()))
dl.addCallback(handle_checks)
return dl
def _check_expected_balance(self, expected_balance):
rpc_conn = AuthServiceProxy(self.rpc_conn_string)
logging.info("Checking balance of address %s", str(expected_balance[1]))
balance = rpc_conn.getreceivedbyaddress(expected_balance[1])
logging.debug("received balance: %s", str(balance))
logging.debug("expected balance: %s", str(expected_balance[2]))
return balance >= expected_balance[2]
def _send_payments(self):
logging.info("Trying to send payments, if there are any to be sent")
def do_send(payments):
rpc_conn = AuthServiceProxy(self.rpc_conn_string)
rpc_conn.sendmany("", payments)
payments_to_send = {}
for address, points in self.queued_payments.items():
logging.info("Should be sending %s points to %s", str(points), str(address))
payments_to_send[address] = float(points)
self.total_reserved_points -= points
self.wallet_balance -= points
del self.queued_payments[address]
if payments_to_send:
logging.info("Creating a transaction with outputs %s", str(payments_to_send))
return threads.deferToThread(do_send, payments_to_send)
logging.info("There were no payments to send")
return defer.succeed(True)
def _get_wallet_balance(self):
rpc_conn = AuthServiceProxy(self.rpc_conn_string)
return rpc_conn.getbalance("")
def _get_new_address(self):
rpc_conn = AuthServiceProxy(self.rpc_conn_string)
return rpc_conn.getnewaddress()
def _get_value_for_name(self, name):
rpc_conn = AuthServiceProxy(self.rpc_conn_string)
return rpc_conn.getvalueforname(name)
def _claim_name(self, name, value, amount):
rpc_conn = AuthServiceProxy(self.rpc_conn_string)
return str(rpc_conn.claimname(name, value, amount))
def _rpc_stop(self):
rpc_conn = AuthServiceProxy(self.rpc_conn_string)
rpc_conn.stop()
self.lbrycrdd.wait()
class LBRYcrdAddressRequester(object):
implements([IRequestCreator])
def __init__(self, wallet):
self.wallet = wallet
self._protocols = []
######### IRequestCreator #########
def send_next_request(self, peer, protocol):
if not protocol in self._protocols:
r = ClientRequest({'lbrycrd_address': True}, 'lbrycrd_address')
d = protocol.add_request(r)
d.addCallback(self._handle_address_response, peer, r, protocol)
d.addErrback(self._request_failed, peer)
self._protocols.append(protocol)
return defer.succeed(True)
else:
return defer.succeed(False)
######### internal calls #########
def _handle_address_response(self, response_dict, peer, request, protocol):
assert request.response_identifier in response_dict, \
"Expected %s in dict but did not get it" % request.response_identifier
assert protocol in self._protocols, "Responding protocol is not in our list of protocols"
address = response_dict[request.response_identifier]
self.wallet.update_peer_address(peer, address)
def _request_failed(self, err, peer):
if not err.check(RequestCanceledError):
logging.warning("A peer failed to send a valid public key response. Error: %s, peer: %s",
err.getErrorMessage(), str(peer))
#return err
class LBRYcrdAddressQueryHandlerFactory(object):
implements(IQueryHandlerFactory)
def __init__(self, wallet):
self.wallet = wallet
######### IQueryHandlerFactory #########
def build_query_handler(self):
q_h = LBRYcrdAddressQueryHandler(self.wallet)
return q_h
def get_primary_query_identifier(self):
return 'lbrycrd_address'
def get_description(self):
return "LBRYcrd Address - an address for receiving payments via LBRYcrd"
class LBRYcrdAddressQueryHandler(object):
implements(IQueryHandler)
def __init__(self, wallet):
self.wallet = wallet
self.query_identifiers = ['lbrycrd_address']
self.address = None
self.peer = None
######### IQueryHandler #########
def register_with_request_handler(self, request_handler, peer):
self.peer = peer
request_handler.register_query_handler(self, self.query_identifiers)
def handle_queries(self, queries):
def create_response(address):
self.address = address
fields = {'lbrycrd_address': address}
return fields
if self.query_identifiers[0] in queries:
d = self.wallet.get_new_address_for_peer(self.peer)
d.addCallback(create_response)
return d
if self.address is None:
logging.warning("Expected a request for an address, but did not receive one")
return defer.fail(Failure(ValueError("Expected but did not receive an address request")))
else:
return defer.succeed({})
+62
View File
@@ -0,0 +1,62 @@
from decimal import Decimal
class Offer(object):
"""A rate offer to download blobs from a host."""
RATE_ACCEPTED = "RATE_ACCEPTED"
RATE_TOO_LOW = "RATE_TOO_LOW"
RATE_UNSET = "RATE_UNSET"
def __init__(self, offer):
self._state = None
self.rate = None
if isinstance(offer, Decimal):
self.rate = round(offer, 5)
elif isinstance(offer, float):
self.rate = round(Decimal(offer), 5)
if self.rate is None or self.rate < Decimal(0.0):
self.unset()
@property
def is_accepted(self):
return self._state is Offer.RATE_ACCEPTED
@property
def is_too_low(self):
return self._state is Offer.RATE_TOO_LOW
@property
def is_unset(self):
return self._state is Offer.RATE_UNSET
@property
def message(self):
if self.is_accepted:
return Offer.RATE_ACCEPTED
elif self.is_too_low:
return Offer.RATE_TOO_LOW
elif self.is_unset:
return Offer.RATE_UNSET
return None
def accept(self):
if self.is_unset or self._state is None:
self._state = Offer.RATE_ACCEPTED
def reject(self):
if self.is_unset or self._state is None:
self._state = Offer.RATE_TOO_LOW
def unset(self):
self._state = Offer.RATE_UNSET
def handle(self, reply_message):
if reply_message == Offer.RATE_TOO_LOW:
self.reject()
elif reply_message == Offer.RATE_ACCEPTED:
self.accept()
elif reply_message == Offer.RATE_UNSET:
self.unset()
else:
raise Exception("Unknown offer reply %s" % str(reply_message))
+46 -31
View File
@@ -1,24 +1,27 @@
from collections import defaultdict
import logging
import leveldb
import os
import unqlite
import time
from Crypto.Hash import SHA512
from Crypto.PublicKey import RSA
from lbrynet.core.client.ClientRequest import ClientRequest
from lbrynet.core.Error import RequestCanceledError
from lbrynet.interfaces import IRequestCreator, IQueryHandlerFactory, IQueryHandler, ILBRYWallet
from lbrynet.interfaces import IRequestCreator, IQueryHandlerFactory, IQueryHandler, IWallet
from lbrynet.pointtraderclient import pointtraderclient
from twisted.internet import defer, threads
from zope.interface import implements
from twisted.python.failure import Failure
from lbrynet.core.LBRYcrdWallet import ReservedPoints
from lbrynet.core.Wallet import ReservedPoints
log = logging.getLogger(__name__)
class PTCWallet(object):
"""This class sends payments to peers and also ensures that expected payments are received.
This class is only intended to be used for testing."""
implements(ILBRYWallet)
implements(IWallet)
def __init__(self, db_dir):
self.db_dir = db_dir
@@ -71,7 +74,7 @@ class PTCWallet(object):
def save_key(success, private_key):
if success is True:
threads.deferToThread(self.save_private_key, private_key.exportKey())
self._save_private_key(private_key.exportKey())
return True
return False
@@ -95,8 +98,8 @@ class PTCWallet(object):
def start_manage():
self.manage()
return True
d = threads.deferToThread(self._open_db)
d.addCallback(lambda _: threads.deferToThread(self.get_wallet_private_key))
d = self._open_db()
d.addCallback(lambda _: self._get_wallet_private_key())
d.addCallback(ensure_private_key_exists)
d.addCallback(lambda _: start_manage())
return d
@@ -108,14 +111,16 @@ class PTCWallet(object):
return PointTraderKeyQueryHandlerFactory(self)
def reserve_points(self, peer, amount):
"""
Ensure a certain amount of points are available to be sent as payment, before the service is rendered
"""Ensure a certain amount of points are available to be sent as
payment, before the service is rendered
@param peer: The peer to which the payment will ultimately be sent
@param amount: The amount of points to reserve
@return: A ReservedPoints object which is given to send_points once the service has been rendered
@return: A ReservedPoints object which is given to send_points
once the service has been rendered
"""
if self.wallet_balance >= self.total_reserved_points + amount:
self.total_reserved_points += amount
@@ -154,14 +159,15 @@ class PTCWallet(object):
ds = []
for peer, points in self.queued_payments.items():
if peer in self.peer_pub_keys:
d = pointtraderclient.send_points(self.private_key, self.peer_pub_keys[peer], points)
d = pointtraderclient.send_points(
self.private_key, self.peer_pub_keys[peer], points)
self.wallet_balance -= points
self.total_reserved_points -= points
ds.append(d)
del self.queued_payments[peer]
else:
logging.warning("Don't have a payment address for peer %s. Can't send %s points.",
str(peer), str(points))
log.warning("Don't have a payment address for peer %s. Can't send %s points.",
str(peer), str(points))
return defer.DeferredList(ds)
def get_balance(self):
@@ -205,22 +211,30 @@ class PTCWallet(object):
min_expected_balance = sum([a[0] for a in expected_payments if a[1] < expected_cutoff])
received_balance = 0
if self.peer_pub_keys[peer] in self.received_payments:
received_balance = sum([a[0] for a in self.received_payments[self.peer_pub_keys[peer]]])
received_balance = sum([
a[0] for a in self.received_payments[self.peer_pub_keys[peer]]])
if min_expected_balance > received_balance:
logging.warning("Account in bad standing: %s (pub_key: %s), expected amount = %s, received_amount = %s",
str(peer), self.peer_pub_keys[peer], str(min_expected_balance), str(received_balance))
log.warning(
"Account in bad standing: %s (pub_key: %s), expected amount = %s, "
"received_amount = %s",
peer, self.peer_pub_keys[peer], min_expected_balance, received_balance)
def _open_db(self):
self.db = leveldb.LevelDB(os.path.join(self.db_dir, "ptcwallet.db"))
def open_db():
self.db = unqlite.UnQLite(os.path.join(self.db_dir, "ptcwallet.db"))
return threads.deferToThread(open_db)
def save_private_key(self, private_key):
self.db.Put("private_key", private_key)
def _save_private_key(self, private_key):
def save_key():
self.db['private_key'] = private_key
return threads.deferToThread(save_key)
def get_wallet_private_key(self):
try:
return self.db.Get("private_key")
except KeyError:
def _get_wallet_private_key(self):
def get_key():
if 'private_key' in self.db:
return self.db['private_key']
return None
return threads.deferToThread(get_key)
class PointTraderKeyExchanger(object):
@@ -256,9 +270,9 @@ class PointTraderKeyExchanger(object):
def _request_failed(self, err, peer):
if not err.check(RequestCanceledError):
logging.warning("A peer failed to send a valid public key response. Error: %s, peer: %s",
err.getErrorMessage(), str(peer))
#return err
log.warning("A peer failed to send a valid public key response. Error: %s, peer: %s",
err.getErrorMessage(), str(peer))
return err
class PointTraderKeyQueryHandlerFactory(object):
@@ -277,7 +291,8 @@ class PointTraderKeyQueryHandlerFactory(object):
return 'public_key'
def get_description(self):
return "Point Trader Address - an address for receiving payments on the point trader testing network"
return ("Point Trader Address - an address for receiving payments on the "
"point trader testing network")
class PointTraderKeyQueryHandler(object):
@@ -301,15 +316,15 @@ class PointTraderKeyQueryHandler(object):
try:
RSA.importKey(new_encoded_pub_key)
except (ValueError, TypeError, IndexError):
logging.warning("Client sent an invalid public key.")
log.warning("Client sent an invalid public key.")
return defer.fail(Failure(ValueError("Client sent an invalid public key")))
self.public_key = new_encoded_pub_key
self.wallet.set_public_key_for_peer(self.peer, self.public_key)
logging.debug("Received the client's public key: %s", str(self.public_key))
log.debug("Received the client's public key: %s", str(self.public_key))
fields = {'public_key': self.wallet.encoded_public_key}
return defer.succeed(fields)
if self.public_key is None:
logging.warning("Expected a public key, but did not receive one")
log.warning("Expected a public key, but did not receive one")
return defer.fail(Failure(ValueError("Expected but did not receive a public key")))
else:
return defer.succeed({})
return defer.succeed({})
+101 -3
View File
@@ -1,6 +1,13 @@
from lbrynet.core.Strategy import get_default_strategy, OnlyFreeStrategy
from lbrynet import conf
from decimal import Decimal
class BasePaymentRateManager(object):
def __init__(self, rate):
self.min_blob_data_payment_rate = rate
def __init__(self, rate=None, info_rate=None):
self.min_blob_data_payment_rate = rate if rate is not None else conf.settings['data_rate']
self.min_blob_info_payment_rate = (
info_rate if info_rate is not None else conf.settings['min_info_rate'])
class PaymentRateManager(object):
@@ -26,4 +33,95 @@ class PaymentRateManager(object):
return self.min_blob_data_payment_rate
def record_points_paid(self, amount):
self.points_paid += amount
self.points_paid += amount
class NegotiatedPaymentRateManager(object):
def __init__(self, base, availability_tracker, generous=None):
"""
@param base: a BasePaymentRateManager
@param availability_tracker: a BlobAvailabilityTracker
@param rate: the min blob data payment rate
"""
self.base = base
self.min_blob_data_payment_rate = base.min_blob_data_payment_rate
self.points_paid = 0.0
self.blob_tracker = availability_tracker
self.generous = generous if generous is not None else conf.settings['is_generous_host']
self.strategy = get_default_strategy(self.blob_tracker,
base_price=self.base.min_blob_data_payment_rate,
is_generous=generous)
def get_rate_blob_data(self, peer, blobs):
response = self.strategy.make_offer(peer, blobs)
return response.rate
def accept_rate_blob_data(self, peer, blobs, offer):
offer = self.strategy.respond_to_offer(offer, peer, blobs)
self.strategy.update_accepted_offers(peer, offer)
return offer.is_accepted
def reply_to_offer(self, peer, blobs, offer):
reply = self.strategy.respond_to_offer(offer, peer, blobs)
self.strategy.update_accepted_offers(peer, reply)
return reply
def get_rate_for_peer(self, peer):
return self.strategy.accepted_offers.get(peer, False)
def record_points_paid(self, amount):
self.points_paid += amount
def record_offer_reply(self, peer, offer):
self.strategy.update_accepted_offers(peer, offer)
def price_limit_reached(self, peer):
if peer in self.strategy.pending_sent_offers:
offer = self.strategy.pending_sent_offers[peer]
return (offer.is_too_low and
round(Decimal.from_float(offer.rate), 5) >= round(self.strategy.max_rate, 5))
return False
class OnlyFreePaymentsManager(object):
def __init__(self, **kwargs):
"""
A payment rate manager that will only ever accept and offer a rate of 0.0,
Used for testing
"""
self.base = BasePaymentRateManager(0.0, 0.0)
self.points_paid = 0.0
self.generous = True
self.strategy = OnlyFreeStrategy()
def get_rate_blob_data(self, peer, blobs):
response = self.strategy.make_offer(peer, blobs)
return response.rate
def accept_rate_blob_data(self, peer, blobs, offer):
offer = self.strategy.respond_to_offer(offer, peer, blobs)
self.strategy.update_accepted_offers(peer, offer)
return offer.is_accepted
def reply_to_offer(self, peer, blobs, offer):
reply = self.strategy.respond_to_offer(offer, peer, blobs)
self.strategy.update_accepted_offers(peer, reply)
return reply
def get_rate_for_peer(self, peer):
return self.strategy.accepted_offers.get(peer, False)
def record_points_paid(self, amount):
self.points_paid += amount
def record_offer_reply(self, peer, offer):
self.strategy.update_accepted_offers(peer, offer)
def price_limit_reached(self, peer):
if peer in self.strategy.pending_sent_offers:
offer = self.strategy.pending_sent_offers[peer]
if offer.rate > 0.0:
return True
return False
+16 -6
View File
@@ -1,19 +1,23 @@
from collections import defaultdict
import datetime
from collections import defaultdict
from lbrynet.core import utils
# Do not create this object except through PeerManager
class Peer(object):
def __init__(self, host, port):
self.host = host
self.port = port
# If a peer is reported down, we wait till this time till reattempting connection
self.attempt_connection_at = None
# Number of times this Peer has been reported to be down, resets to 0 when it is up
self.down_count = 0
# Number of succesful connections (with full protocol completion) to this peer
self.success_count = 0
self.score = 0
self.stats = defaultdict(float) # {string stat_type, float count}
def is_available(self):
if (self.attempt_connection_at is None or
datetime.datetime.today() > self.attempt_connection_at):
if self.attempt_connection_at is None or utils.today() > self.attempt_connection_at:
return True
return False
@@ -21,10 +25,13 @@ class Peer(object):
self.down_count = 0
self.attempt_connection_at = None
def report_success(self):
self.success_count += 1
def report_down(self):
self.down_count += 1
timeout_time = datetime.timedelta(seconds=60 * self.down_count)
self.attempt_connection_at = datetime.datetime.today() + timeout_time
self.attempt_connection_at = utils.today() + timeout_time
def update_score(self, score_change):
self.score += score_change
@@ -33,4 +40,7 @@ class Peer(object):
self.stats[stat_type] += count
def __str__(self):
return self.host + ":" + str(self.port)
return '{}:{}'.format(self.host, self.port)
def __repr__(self):
return 'Peer({!r}, {!r})'.format(self.host, self.port)
+1 -1
View File
@@ -16,4 +16,4 @@ class DummyPeerFinder(object):
return defer.succeed([])
def get_most_popular_hashes(self, num_to_return):
return []
return []
+1 -1
View File
@@ -11,4 +11,4 @@ class PeerManager(object):
return peer
peer = Peer(host, port)
self.peers.append(peer)
return peer
return peer
+62
View File
@@ -0,0 +1,62 @@
from zope.interface import implementer
from decimal import Decimal
from lbrynet.interfaces import IBlobPriceModel
from lbrynet import conf
def get_default_price_model(blob_tracker, base_price, **kwargs):
return MeanAvailabilityWeightedPrice(blob_tracker, base_price, **kwargs)
class ZeroPrice(object):
def __init__(self):
self.base_price = 0.0
def calculate_price(self, blob):
return 0.0
class MeanAvailabilityWeightedPrice(object):
"""Calculate mean-blob-availability and stream-position weighted price for a blob
Attributes:
base_price (float): base price
alpha (float): constant, > 0.0 and <= 1.0, used to more highly
value blobs at the beginning of a stream.
alpha defaults to 1.0, which has a null effect
blob_tracker (BlobAvailabilityTracker): blob availability tracker
"""
implementer(IBlobPriceModel)
def __init__(self, tracker, base_price=None, alpha=1.0):
self.blob_tracker = tracker
base_price = base_price if base_price is not None else conf.settings['data_rate']
self.base_price = Decimal(base_price)
self.alpha = Decimal(alpha)
def calculate_price(self, blob):
mean_availability = self.blob_tracker.last_mean_availability
availability = self.blob_tracker.availability.get(blob, [])
index = 0 # blob.index
availability_mult = self._get_availability_multiplier(mean_availability, availability)
price = self.base_price * availability_mult / self._frontload(index)
return round(price, 5)
def _get_availability_multiplier(self, mean_availability, availability):
return Decimal(max(1, mean_availability) / Decimal(max(1, len(availability))))
def _frontload(self, index):
"""Get front-load multiplier, used to weight prices of blobs in a
stream towards the front of the stream.
At index 0, returns 1.0
As index increases, return value approaches 2.0
@param index: blob position in stream
@return: front-load multiplier
"""
return Decimal(2.0) - (self.alpha ** index)
+44 -94
View File
@@ -1,5 +1,11 @@
import logging
from zope.interface import implements
from lbrynet.interfaces import IRateLimiter
from twisted.internet import task
log = logging.getLogger(__name__)
class DummyRateLimiter(object):
@@ -10,22 +16,20 @@ class DummyRateLimiter(object):
self.total_ul_bytes = 0
self.target_dl = 0
self.target_ul = 0
self.ul_delay = 0.00
self.dl_delay = 0.00
self.next_tick = None
self.tick_call = None
def start(self):
self.tick_call = task.LoopingCall(self.tick)
self.tick_call.start(1)
def tick(self):
from twisted.internet import reactor
self.dl_bytes_this_second = 0
self.ul_bytes_this_second = 0
self.next_tick = reactor.callLater(1.0, self.tick)
def stop(self):
if self.next_tick is not None:
self.next_tick.cancel()
self.next_tick = None
if self.tick_call is not None:
self.tick_call.stop()
self.tick_call = None
def set_dl_limit(self, limit):
pass
@@ -33,12 +37,6 @@ class DummyRateLimiter(object):
def set_ul_limit(self, limit):
pass
def ul_wait_time(self):
return self.ul_delay
def dl_wait_time(self):
return self.dl_delay
def report_dl_bytes(self, num_bytes):
self.dl_bytes_this_second += num_bytes
self.total_dl_bytes += num_bytes
@@ -58,66 +56,34 @@ class RateLimiter(object):
def __init__(self, max_dl_bytes=None, max_ul_bytes=None):
self.max_dl_bytes = max_dl_bytes
self.max_ul_bytes = max_ul_bytes
self.dl_bytes_this_second = 0
self.ul_bytes_this_second = 0
self.dl_bytes_this_interval = 0
self.ul_bytes_this_interval = 0
self.total_dl_bytes = 0
self.total_ul_bytes = 0
self.next_tick = None
self.next_unthrottle_dl = None
self.next_unthrottle_ul = None
self.next_dl_check = None
self.next_ul_check = None
self.dl_check_interval = 1.0
self.ul_check_interval = 1.0
self.tick_call = None
self.tick_interval = 0.1
self.dl_throttled = False
self.ul_throttled = False
self.protocols = []
def start(self):
log.info("Starting rate limiter.")
self.tick_call = task.LoopingCall(self.tick)
self.tick_call.start(self.tick_interval)
def tick(self):
from twisted.internet import reactor
# happens once per second
if self.next_dl_check is not None:
self.next_dl_check.cancel()
self.next_dl_check = None
if self.next_ul_check is not None:
self.next_ul_check.cancel()
self.next_ul_check = None
if self.max_dl_bytes is not None:
if self.dl_bytes_this_second == 0:
self.dl_check_interval = 1.0
else:
self.dl_check_interval = min(1.0, self.dl_check_interval *
self.max_dl_bytes / self.dl_bytes_this_second)
self.next_dl_check = reactor.callLater(self.dl_check_interval, self.check_dl)
if self.max_ul_bytes is not None:
if self.ul_bytes_this_second == 0:
self.ul_check_interval = 1.0
else:
self.ul_check_interval = min(1.0, self.ul_check_interval *
self.max_ul_bytes / self.ul_bytes_this_second)
self.next_ul_check = reactor.callLater(self.ul_check_interval, self.check_ul)
self.dl_bytes_this_second = 0
self.ul_bytes_this_second = 0
self.dl_bytes_this_interval = 0
self.ul_bytes_this_interval = 0
self.unthrottle_dl()
self.unthrottle_ul()
self.next_tick = reactor.callLater(1.0, self.tick)
def stop(self):
if self.next_tick is not None:
self.next_tick.cancel()
self.next_tick = None
if self.next_dl_check is not None:
self.next_dl_check.cancel()
self.next_dl_check = None
if self.next_ul_check is not None:
self.next_ul_check.cancel()
self.next_ul_check = None
log.info("Stopping rate limiter.")
if self.tick_call is not None:
self.tick_call.stop()
self.tick_call = None
def set_dl_limit(self, limit):
self.max_dl_bytes = limit
@@ -128,28 +94,18 @@ class RateLimiter(object):
#throttling
def check_dl(self):
from twisted.internet import reactor
self.next_dl_check = None
if self.dl_bytes_this_second > self.max_dl_bytes:
self.throttle_dl()
else:
self.next_dl_check = reactor.callLater(self.dl_check_interval, self.check_dl)
self.dl_check_interval = min(self.dl_check_interval * 2, 1.0)
need_throttle = (self.max_dl_bytes is not None and
self.dl_bytes_this_interval > self.max_dl_bytes * self.tick_interval)
if need_throttle:
from twisted.internet import reactor
reactor.callLater(0, self.throttle_dl)
def check_ul(self):
from twisted.internet import reactor
self.next_ul_check = None
if self.ul_bytes_this_second > self.max_ul_bytes:
self.throttle_ul()
else:
self.next_ul_check = reactor.callLater(self.ul_check_interval, self.check_ul)
self.ul_check_interval = min(self.ul_check_interval * 2, 1.0)
need_throttle = (self.max_ul_bytes is not None and
self.ul_bytes_this_interval > self.max_ul_bytes * self.tick_interval)
if need_throttle:
from twisted.internet import reactor
reactor.callLater(0, self.throttle_ul)
def throttle_dl(self):
if self.dl_throttled is False:
@@ -175,23 +131,17 @@ class RateLimiter(object):
protocol.unthrottle_upload()
self.ul_throttled = False
#deprecated
def ul_wait_time(self):
return 0
def dl_wait_time(self):
return 0
#called by protocols
def report_dl_bytes(self, num_bytes):
self.dl_bytes_this_second += num_bytes
self.dl_bytes_this_interval += num_bytes
self.total_dl_bytes += num_bytes
self.check_dl()
def report_ul_bytes(self, num_bytes):
self.ul_bytes_this_second += num_bytes
self.ul_bytes_this_interval += num_bytes
self.total_ul_bytes += num_bytes
self.check_ul()
def register_protocol(self, protocol):
if protocol not in self.protocols:
@@ -203,4 +153,4 @@ class RateLimiter(object):
def unregister_protocol(self, protocol):
if protocol in self.protocols:
self.protocols.remove(protocol)
self.protocols.remove(protocol)
+215 -101
View File
@@ -1,77 +1,108 @@
import logging
import miniupnpc
from lbrynet.core.PTCWallet import PTCWallet
from lbrynet.core.BlobManager import DiskBlobManager, TempBlobManager
from lbrynet.core.BlobManager import DiskBlobManager
from lbrynet.dht import node
from lbrynet.database.storage import SQLiteStorage
from lbrynet.core.PeerManager import PeerManager
from lbrynet.core.RateLimiter import RateLimiter
from lbrynet.core.client.DHTPeerFinder import DHTPeerFinder
from lbrynet.core.HashAnnouncer import DummyHashAnnouncer
from lbrynet.core.server.DHTHashAnnouncer import DHTHashAnnouncer
from lbrynet.core.utils import generate_id
from lbrynet.core.PaymentRateManager import BasePaymentRateManager
from lbrynet.core.PaymentRateManager import BasePaymentRateManager, NegotiatedPaymentRateManager
from lbrynet.core.BlobAvailability import BlobAvailabilityTracker
from twisted.internet import threads, defer
log = logging.getLogger(__name__)
class LBRYSession(object):
"""This class manages all important services common to any application that uses the network:
the hash announcer, which informs other peers that this peer is associated with some hash. Usually,
this means this peer has a blob identified by the hash in question, but it can be used for other
purposes.
the peer finder, which finds peers that are associated with some hash.
the blob manager, which keeps track of which blobs have been downloaded and provides access to them,
the rate limiter, which attempts to ensure download and upload rates stay below a set maximum,
and upnp, which opens holes in compatible firewalls so that remote peers can connect to this peer."""
def __init__(self, blob_data_payment_rate, db_dir=None, lbryid=None, peer_manager=None, dht_node_port=None,
known_dht_nodes=None, peer_finder=None, hash_announcer=None,
blob_dir=None, blob_manager=None, peer_port=None, use_upnp=True,
rate_limiter=None, wallet=None):
"""
@param blob_data_payment_rate: The default payment rate for blob data
class Session(object):
"""This class manages all important services common to any application that uses the network.
the hash announcer, which informs other peers that this peer is
associated with some hash. Usually, this means this peer has a
blob identified by the hash in question, but it can be used for
other purposes.
the peer finder, which finds peers that are associated with some
hash.
the blob manager, which keeps track of which blobs have been
downloaded and provides access to them,
the rate limiter, which attempts to ensure download and upload
rates stay below a set maximum
upnp, which opens holes in compatible firewalls so that remote
peers can connect to this peer.
"""
def __init__(self, blob_data_payment_rate, db_dir=None,
node_id=None, peer_manager=None, dht_node_port=None,
known_dht_nodes=None, peer_finder=None,
hash_announcer=None, blob_dir=None,
blob_manager=None, peer_port=None, use_upnp=True,
rate_limiter=None, wallet=None,
dht_node_class=node.Node, blob_tracker_class=None,
payment_rate_manager_class=None, is_generous=True, external_ip=None, storage=None):
"""@param blob_data_payment_rate: The default payment rate for blob data
@param db_dir: The directory in which levelDB files should be stored
@param lbryid: The unique ID of this node
@param node_id: The unique ID of this node
@param peer_manager: An object which keeps track of all known peers. If None, a PeerManager will be created
@param peer_manager: An object which keeps track of all known
peers. If None, a PeerManager will be created
@param dht_node_port: The port on which the dht node should listen for incoming connections
@param dht_node_port: The port on which the dht node should
listen for incoming connections
@param known_dht_nodes: A list of nodes which the dht node should use to bootstrap into the dht
@param known_dht_nodes: A list of nodes which the dht node
should use to bootstrap into the dht
@param peer_finder: An object which is used to look up peers that are associated with some hash. If None,
a DHTPeerFinder will be used, which looks for peers in the distributed hash table.
@param peer_finder: An object which is used to look up peers
that are associated with some hash. If None, a
DHTPeerFinder will be used, which looks for peers in the
distributed hash table.
@param hash_announcer: An object which announces to other peers that this peer is associated with some hash.
If None, and peer_port is not None, a DHTHashAnnouncer will be used. If None and
peer_port is None, a DummyHashAnnouncer will be used, which will not actually announce
anything.
@param hash_announcer: An object which announces to other
peers that this peer is associated with some hash. If
None, and peer_port is not None, a DHTHashAnnouncer will
be used. If None and peer_port is None, a
DummyHashAnnouncer will be used, which will not actually
announce anything.
@param blob_dir: The directory in which blobs will be stored. If None and blob_manager is None, blobs will
be stored in memory only.
@param blob_dir: The directory in which blobs will be
stored. If None and blob_manager is None, blobs will be
stored in memory only.
@param blob_manager: An object which keeps track of downloaded blobs and provides access to them. If None,
and blob_dir is not None, a DiskBlobManager will be used, with the given blob_dir.
If None and blob_dir is None, a TempBlobManager will be used, which stores blobs in
memory only.
@param blob_manager: An object which keeps track of downloaded
blobs and provides access to them. If None, and blob_dir
is not None, a DiskBlobManager will be used, with the
given blob_dir. If None and blob_dir is None, a
TempBlobManager will be used, which stores blobs in memory
only.
@param peer_port: The port on which other peers should connect to this peer
@param peer_port: The port on which other peers should connect
to this peer
@param use_upnp: Whether or not to try to open a hole in the firewall so that outside peers can connect to
this peer's peer_port and dht_node_port
@param use_upnp: Whether or not to try to open a hole in the
firewall so that outside peers can connect to this peer's
peer_port and dht_node_port
@param rate_limiter: An object which keeps track of the amount of data transferred to and from this peer,
and can limit that rate if desired
@param rate_limiter: An object which keeps track of the amount
of data transferred to and from this peer, and can limit
that rate if desired
@param wallet: An object which will be used to keep track of expected payments and which will pay peers.
If None, a wallet which uses the Point Trader system will be used, which is meant for testing
only
@param wallet: An object which will be used to keep track of
expected payments and which will pay peers. If None, a
wallet which uses the Point Trader system will be used,
which is meant for testing only
@return:
"""
self.db_dir = db_dir
self.lbryid = lbryid
self.node_id = node_id
self.peer_manager = peer_manager
@@ -85,31 +116,39 @@ class LBRYSession(object):
self.blob_dir = blob_dir
self.blob_manager = blob_manager
self.blob_tracker = None
self.blob_tracker_class = blob_tracker_class or BlobAvailabilityTracker
self.peer_port = peer_port
self.use_upnp = use_upnp
self.rate_limiter = rate_limiter
self.external_ip = '127.0.0.1'
self.upnp_handler = None
self.upnp_redirects_set = False
self.external_ip = external_ip
self.upnp_redirects = []
self.wallet = wallet
self.dht_node_class = dht_node_class
self.dht_node = None
self.base_payment_rate_manager = BasePaymentRateManager(blob_data_payment_rate)
self.payment_rate_manager = None
self.payment_rate_manager_class = payment_rate_manager_class or NegotiatedPaymentRateManager
self.is_generous = is_generous
self.storage = storage or SQLiteStorage(self.db_dir)
def setup(self):
"""Create the blob directory and database if necessary, start all desired services"""
logging.debug("Setting up the lbry session")
log.debug("Starting session.")
if self.lbryid is None:
self.lbryid = generate_id()
if self.node_id is None:
self.node_id = generate_id()
if self.wallet is None:
from lbrynet.core.PTCWallet import PTCWallet
self.wallet = PTCWallet(self.db_dir)
if self.peer_manager is None:
@@ -124,7 +163,7 @@ class LBRYSession(object):
d.addCallback(lambda _: self._setup_dht())
else:
if self.hash_announcer is None and self.peer_port is not None:
logging.warning("The server has no way to advertise its available blobs.")
log.warning("The server has no way to advertise its available blobs.")
self.hash_announcer = DummyHashAnnouncer()
d.addCallback(lambda _: self._setup_other_components())
@@ -132,59 +171,91 @@ class LBRYSession(object):
def shut_down(self):
"""Stop all services"""
log.info('Stopping session.')
ds = []
if self.blob_tracker is not None:
ds.append(defer.maybeDeferred(self.blob_tracker.stop))
if self.dht_node is not None:
ds.append(defer.maybeDeferred(self.dht_node.stop))
ds.append(defer.maybeDeferred(self.rate_limiter.stop))
ds.append(defer.maybeDeferred(self.peer_finder.stop))
ds.append(defer.maybeDeferred(self.hash_announcer.stop))
ds.append(defer.maybeDeferred(self.wallet.stop))
ds.append(defer.maybeDeferred(self.blob_manager.stop))
if self.upnp_redirects_set is True:
if self.rate_limiter is not None:
ds.append(defer.maybeDeferred(self.rate_limiter.stop))
if self.peer_finder is not None:
ds.append(defer.maybeDeferred(self.peer_finder.stop))
if self.hash_announcer is not None:
ds.append(defer.maybeDeferred(self.hash_announcer.stop))
if self.wallet is not None:
ds.append(defer.maybeDeferred(self.wallet.stop))
if self.blob_manager is not None:
ds.append(defer.maybeDeferred(self.blob_manager.stop))
if self.use_upnp is True:
ds.append(defer.maybeDeferred(self._unset_upnp))
return defer.DeferredList(ds)
def _try_upnp(self):
logging.debug("In _try_upnp")
log.debug("In _try_upnp")
def get_free_port(upnp, port, protocol):
# returns an existing mapping if it exists
mapping = upnp.getspecificportmapping(port, protocol)
if not mapping:
return port
if upnp.lanaddr == mapping[0]:
return mapping
return get_free_port(upnp, port + 1, protocol)
def get_port_mapping(upnp, internal_port, protocol, description):
# try to map to the requested port, if there is already a mapping use the next external
# port available
if protocol not in ['UDP', 'TCP']:
raise Exception("invalid protocol")
external_port = get_free_port(upnp, internal_port, protocol)
if isinstance(external_port, tuple):
log.info("Found existing UPnP redirect %s:%i (%s) to %s:%i, using it",
self.external_ip, external_port[1], protocol, upnp.lanaddr, internal_port)
return external_port[1], protocol
upnp.addportmapping(external_port, protocol, upnp.lanaddr, internal_port,
description, '')
log.info("Set UPnP redirect %s:%i (%s) to %s:%i", self.external_ip, external_port,
protocol, upnp.lanaddr, internal_port)
return external_port, protocol
def threaded_try_upnp():
if self.use_upnp is False:
logging.debug("Not using upnp")
log.debug("Not using upnp")
return False
u = miniupnpc.UPnP()
num_devices_found = u.discover()
if num_devices_found > 0:
self.upnp_handler = u
u.selectigd()
external_ip = u.externalipaddress()
if external_ip != '0.0.0.0':
if external_ip != '0.0.0.0' and not self.external_ip:
# best not to rely on this external ip, the router can be behind layers of NATs
self.external_ip = external_ip
if self.peer_port is not None:
u.addportmapping(self.peer_port, 'TCP', u.lanaddr, self.peer_port, 'LBRY peer port', '')
if self.dht_node_port is not None:
u.addportmapping(self.dht_node_port, 'UDP', u.lanaddr, self.dht_node_port, 'LBRY DHT port', '')
self.upnp_redirects_set = True
if self.peer_port:
self.upnp_redirects.append(
get_port_mapping(u, self.peer_port, 'TCP', 'LBRY peer port')
)
if self.dht_node_port:
self.upnp_redirects.append(
get_port_mapping(u, self.dht_node_port, 'UDP', 'LBRY DHT port')
)
return True
return False
def upnp_failed(err):
logging.warning("UPnP failed. Reason: %s", err.getErrorMessage())
log.warning("UPnP failed. Reason: %s", err.getErrorMessage())
return False
d = threads.deferToThread(threaded_try_upnp)
d.addErrback(upnp_failed)
return d
def _setup_dht(self):
# the callback, if any, will be invoked once the joining procedure
# has terminated
def join_dht(self, cb=None):
from twisted.internet import reactor
logging.debug("Starting the dht")
def match_port(h, p):
return h, p
def join_resolved_addresses(result):
addresses = []
for success, value in result:
@@ -192,54 +263,97 @@ class LBRYSession(object):
addresses.append(value)
return addresses
def start_dht(addresses):
self.dht_node.joinNetwork(addresses)
self.peer_finder.run_manage_loop()
self.hash_announcer.run_manage_loop()
return True
@defer.inlineCallbacks
def join_network(knownNodes):
log.debug("join DHT using known nodes: " + str(knownNodes))
result = yield self.dht_node.joinNetwork(knownNodes)
defer.returnValue(result)
ds = []
for host, port in self.known_dht_nodes:
d = reactor.resolve(host)
d.addCallback(match_port, port)
d.addCallback(lambda h: (h, port)) # match host to port
ds.append(d)
self.dht_node = node.Node(udpPort=self.dht_node_port, lbryid=self.lbryid,
externalIP=self.external_ip)
dl = defer.DeferredList(ds)
dl.addCallback(join_resolved_addresses)
dl.addCallback(join_network)
if cb:
dl.addCallback(cb)
return dl
def _setup_dht(self):
log.info("Starting DHT")
def start_dht(join_network_result):
self.hash_announcer.run_manage_loop()
return True
self.dht_node = self.dht_node_class(
udpPort=self.dht_node_port,
node_id=self.node_id,
externalIP=self.external_ip,
peerPort=self.peer_port
)
self.peer_finder = DHTPeerFinder(self.dht_node, self.peer_manager)
if self.hash_announcer is None:
self.hash_announcer = DHTHashAnnouncer(self.dht_node, self.peer_port)
dl = defer.DeferredList(ds)
dl.addCallback(join_resolved_addresses)
dl.addCallback(start_dht)
return dl
self.dht_node.startNetwork()
# pass start_dht() as callback to start the remaining components after joining the DHT
return self.join_dht(start_dht)
def _setup_other_components(self):
logging.debug("Setting up the rest of the components")
log.debug("Setting up the rest of the components")
if self.rate_limiter is None:
self.rate_limiter = RateLimiter()
if self.blob_manager is None:
if self.blob_dir is None:
self.blob_manager = TempBlobManager(self.hash_announcer)
raise Exception(
"TempBlobManager is no longer supported, specify BlobManager or db_dir")
else:
self.blob_manager = DiskBlobManager(self.hash_announcer, self.blob_dir, self.db_dir)
self.blob_manager = DiskBlobManager(
self.hash_announcer, self.blob_dir, self.storage
)
self.rate_limiter.tick()
d1 = self.blob_manager.setup()
d2 = self.wallet.start()
return defer.DeferredList([d1, d2], fireOnOneErrback=True)
if self.blob_tracker is None:
self.blob_tracker = self.blob_tracker_class(
self.blob_manager, self.peer_finder, self.dht_node
)
if self.payment_rate_manager is None:
self.payment_rate_manager = self.payment_rate_manager_class(
self.base_payment_rate_manager, self.blob_tracker, self.is_generous
)
self.rate_limiter.start()
d = self.storage.setup()
d.addCallback(lambda _: self.blob_manager.setup())
d.addCallback(lambda _: self.wallet.start())
d.addCallback(lambda _: self.blob_tracker.start())
return d
def _unset_upnp(self):
log.info("Unsetting upnp for session")
def threaded_unset_upnp():
u = self.upnp_handler
if self.peer_port is not None:
u.deleteportmapping(self.peer_port, 'TCP')
if self.dht_node_port is not None:
u.deleteportmapping(self.dht_node_port, 'UDP')
self.upnp_redirects_set = False
u = miniupnpc.UPnP()
num_devices_found = u.discover()
if num_devices_found > 0:
u.selectigd()
for port, protocol in self.upnp_redirects:
if u.getspecificportmapping(port, protocol) is None:
log.warning(
"UPnP redirect for %s %d was removed by something else.",
protocol, port)
else:
u.deleteportmapping(port, protocol)
log.info("Removed UPnP redirect for %s %d.", protocol, port)
self.upnp_redirects = []
return threads.deferToThread(threaded_unset_upnp)
d = threads.deferToThread(threaded_unset_upnp)
d.addErrback(lambda err: str(err))
return d
+106
View File
@@ -0,0 +1,106 @@
import logging
import shutil
import tempfile
from twisted.internet import defer, threads, reactor
from lbrynet.blob import BlobFile
from lbrynet.core.BlobManager import DiskBlobManager
from lbrynet.core.HashAnnouncer import DummyHashAnnouncer
from lbrynet.core.RateLimiter import DummyRateLimiter
from lbrynet.core.PaymentRateManager import OnlyFreePaymentsManager
from lbrynet.core.PeerFinder import DummyPeerFinder
from lbrynet.core.client.BlobRequester import BlobRequester
from lbrynet.core.client.StandaloneBlobDownloader import StandaloneBlobDownloader
from lbrynet.core.client.ConnectionManager import ConnectionManager
log = logging.getLogger(__name__)
class SinglePeerFinder(DummyPeerFinder):
def __init__(self, peer):
DummyPeerFinder.__init__(self)
self.peer = peer
def find_peers_for_blob(self, blob_hash, timeout=None, filter_self=False):
return defer.succeed([self.peer])
class BlobCallback(BlobFile):
def __init__(self, blob_dir, blob_hash, timeout):
BlobFile.__init__(self, blob_dir, blob_hash)
self.callback = defer.Deferred()
reactor.callLater(timeout, self._cancel)
def _cancel(self):
if not self.callback.called:
self.callback.callback(False)
def save_verified_blob(self, writer):
result = BlobFile.save_verified_blob(self, writer)
if not self.callback.called:
self.callback.callback(True)
return result
class SingleBlobDownloadManager(object):
def __init__(self, blob):
self.blob = blob
def needed_blobs(self):
if self.blob.verified:
return []
else:
return [self.blob]
def get_head_blob_hash(self):
return self.blob.blob_hash
class SinglePeerDownloader(object):
def __init__(self):
self._payment_rate_manager = OnlyFreePaymentsManager()
self._announcer = DummyHashAnnouncer()
self._rate_limiter = DummyRateLimiter()
self._wallet = None
self._blob_manager = None
def setup(self, wallet, blob_manager=None):
if not self._wallet:
self._wallet = wallet
if not self._blob_manager:
self._blob_manager = blob_manager
@defer.inlineCallbacks
def download_blob_from_peer(self, peer, timeout, blob_hash, blob_manager):
log.debug("Try to download %s from %s", blob_hash, peer.host)
blob_manager = blob_manager
blob = BlobCallback(blob_manager.blob_dir, blob_hash, timeout)
download_manager = SingleBlobDownloadManager(blob)
peer_finder = SinglePeerFinder(peer)
requester = BlobRequester(blob_manager, peer_finder, self._payment_rate_manager,
self._wallet, download_manager)
downloader = StandaloneBlobDownloader(blob_hash, blob_manager, peer_finder,
self._rate_limiter, self._payment_rate_manager,
self._wallet, timeout=timeout)
info_exchanger = self._wallet.get_info_exchanger()
connection_manager = ConnectionManager(downloader, self._rate_limiter, [requester],
[info_exchanger])
connection_manager.start()
result = yield blob.callback
if not result:
log.debug("Failed to downloaded %s from %s", blob_hash[:16], peer.host)
yield connection_manager.stop()
defer.returnValue(result)
@defer.inlineCallbacks
def download_temp_blob_from_peer(self, peer, timeout, blob_hash):
tmp_dir = yield threads.deferToThread(tempfile.mkdtemp)
tmp_blob_manager = DiskBlobManager(self._announcer, tmp_dir, tmp_dir)
try:
result = yield self.download_blob_from_peer(peer, timeout, blob_hash, tmp_blob_manager)
finally:
yield tmp_blob_manager.stop()
yield threads.deferToThread(shutil.rmtree, tmp_dir)
defer.returnValue(result)
+152
View File
@@ -0,0 +1,152 @@
from zope.interface import implementer
from decimal import Decimal
from lbrynet import conf
from lbrynet.interfaces import INegotiationStrategy
from lbrynet.core.Offer import Offer
from lbrynet.core.PriceModel import MeanAvailabilityWeightedPrice, ZeroPrice
def get_default_strategy(blob_tracker, **kwargs):
return BasicAvailabilityWeightedStrategy(blob_tracker, **kwargs)
class Strategy(object):
"""
Base for negotiation strategies
"""
implementer(INegotiationStrategy)
def __init__(self, price_model, max_rate, min_rate, is_generous=None):
self.price_model = price_model
self.is_generous = (
is_generous if is_generous is not None else conf.settings['is_generous_host'])
self.accepted_offers = {}
self.pending_sent_offers = {}
self.offers_sent = {}
self.offers_received = {}
self.max_rate = max_rate or Decimal(self.price_model.base_price * 50)
self.min_rate = Decimal(min_rate)
def _make_rate_offer(self, rates, offer_count):
return NotImplementedError()
def _get_response_rate(self, rates, offer_count):
return NotImplementedError()
def make_offer(self, peer, blobs):
offer_count = self.offers_sent.get(peer, 0)
self._add_offer_sent(peer)
if peer in self.accepted_offers:
# if there was a previous accepted offer, use that
offer = self.accepted_offers[peer]
if peer in self.pending_sent_offers:
del self.pending_sent_offers[peer]
elif offer_count == 0 and self.is_generous:
# Try asking for it for free
offer = Offer(Decimal(0.0))
self.pending_sent_offers.update({peer: offer})
else:
rates = [self.price_model.calculate_price(blob) for blob in blobs]
price = self._make_rate_offer(rates, offer_count)
offer = Offer(price)
self.pending_sent_offers.update({peer: offer})
return offer
def respond_to_offer(self, offer, peer, blobs):
offer_count = self.offers_received.get(peer, 0)
self._add_offer_received(peer)
rates = [self.price_model.calculate_price(blob) for blob in blobs]
price = self._get_response_rate(rates, offer_count)
if peer in self.accepted_offers:
offer = self.accepted_offers[peer]
elif offer.rate == 0.0 and offer_count == 0 and self.is_generous:
# give blobs away for free by default on the first request
offer.accept()
self.accepted_offers.update({peer: offer})
elif offer.rate >= price:
offer.accept()
self.accepted_offers.update({peer: offer})
else:
offer.reject()
if peer in self.accepted_offers:
del self.accepted_offers[peer]
return offer
def update_accepted_offers(self, peer, offer):
if not offer.is_accepted and peer in self.accepted_offers:
del self.accepted_offers[peer]
if offer.is_accepted:
self.accepted_offers.update({peer: offer})
self.pending_sent_offers.update({peer: offer})
def _add_offer_sent(self, peer):
turn = self.offers_sent.get(peer, 0) + 1
self.offers_sent.update({peer: turn})
def _add_offer_received(self, peer):
turn = self.offers_received.get(peer, 0) + 1
self.offers_received.update({peer: turn})
def _bounded_price(self, price):
price_for_return = Decimal(min(self.max_rate, max(price, self.min_rate)))
return price_for_return
class BasicAvailabilityWeightedStrategy(Strategy):
"""Basic strategy to target blob prices based on supply relative to mean supply
Discount price target with each incoming request, and raise it
with each outgoing from the modeled price until the rate is
accepted or a threshold is reached
"""
implementer(INegotiationStrategy)
def __init__(self, blob_tracker, acceleration=1.25,
deceleration=0.9, max_rate=None,
min_rate=0.0,
is_generous=None,
base_price=0.0001, alpha=1.0):
price_model = MeanAvailabilityWeightedPrice(
blob_tracker, base_price=base_price, alpha=alpha)
Strategy.__init__(self, price_model, max_rate, min_rate, is_generous)
self._acceleration = Decimal(acceleration) # rate of how quickly to ramp offer
self._deceleration = Decimal(deceleration)
def _get_mean_rate(self, rates):
mean_rate = Decimal(sum(rates)) / Decimal(max(len(rates), 1))
return mean_rate
def _premium(self, rate, turn):
return rate * (self._acceleration ** Decimal(turn))
def _discount(self, rate, turn):
return rate * (self._deceleration ** Decimal(turn))
def _get_response_rate(self, rates, offer_count):
rate = self._get_mean_rate(rates)
discounted = self._discount(rate, offer_count)
rounded_price = round(discounted, 5)
return self._bounded_price(rounded_price)
def _make_rate_offer(self, rates, offer_count):
rate = self._get_mean_rate(rates)
with_premium = self._premium(rate, offer_count)
rounded_price = round(with_premium, 5)
return self._bounded_price(rounded_price)
class OnlyFreeStrategy(Strategy):
implementer(INegotiationStrategy)
def __init__(self, *args, **kwargs):
price_model = ZeroPrice()
Strategy.__init__(self, price_model, 0.0, 0.0, True)
def _get_mean_rate(self, rates):
return 0.0
def _get_response_rate(self, rates, offer_count):
return 0.0
def _make_rate_offer(self, rates, offer_count):
return 0.0
Loaded 100 of 314 files, more files were not shown because too many files have changed in this diff. Show more