Commit Graph

741 Commits

Author SHA1 Message Date
Arvid Norberg a34ce0278e add write_resume_data() function (#1776)
add write_resume_data() function. Make resume data alert use an add_torrent_params object
2017-03-05 09:31:28 -05:00
arvidn 081365fbcf merge RC_1_1 into master 2017-02-26 00:48:12 -05:00
Alden Torres 97c8d0486c fixing sign-conversion warnings, part 21, file_flags (#1750)
fixing sign-conversion warnings, part 21, file_flags
2017-02-25 19:06:31 -05:00
arvidn 2258b53d87 in python binding, make announce_entry::last_error a dict instead of error_code 2017-02-24 22:22:48 -05:00
arvidn 3b359abc14 add pickle support to error_code python binding 2017-02-22 07:50:08 -05:00
Calum Lind 0e500978cd Add a python bindings test for pickling trackers
* If ae.last_error (lt.error_code) is not converted in bindings to a dict
 then pickling the trackers with fail.
2017-02-22 07:50:08 -05:00
sledgehammer_999 9bb420b074 Move include into implementation instead(from #1703). 2017-02-21 20:19:53 -05:00
arvidn 6d40d3a167 bump version number 2017-02-20 12:43:34 -05:00
arvidn 2c51c59327 merge RC_1_1 into master 2017-02-18 13:29:12 -05:00
arvidn 799cd8163b fix python binding of create_torrent 2017-02-17 07:45:43 -05:00
arvidn 3ffa3f2a08 merged RC_1_1 into master 2017-02-17 00:35:49 -05:00
Arvid Norberg 116802fcdf update tuning documentation (#1717)
update tuning documentation and make the stats header be posted when logging is disabled (if stats_notifications are enabled)
2017-02-16 07:03:43 -05:00
arvidn cbd1c26a11 fix ABI compatibility issue introduced with preformatted entry type 2017-02-12 20:42:30 -05:00
arvidn 21c9a493f6 fix master build 2017-02-12 08:33:25 -05:00
arvidn 5971818969 merge RC_1_1 into master 2017-02-12 02:24:14 -05:00
arvidn db32618c39 system_clock fix 2017-02-11 08:07:43 -05:00
Calum Lind 4492cada4a Backport time_point to python convertor. Fix bindings returning invalid date from time_point convertor 2017-02-11 08:07:43 -05:00
Calum Lind de30f357b3 Add missing announce_entry properties to python bindings
Fix and refactor the announce_entry class
 - Removed verified from torrent_handle dict to announce_entry as it's read-only.
 - Changed source and send_stats to read_write properties.
 - Switched trivial type properties to using read_only or read_write.
2017-02-11 08:07:43 -05:00
arvidn cc9f40bff9 if brew fails on travis, retry automatically 2017-02-10 18:56:03 -05:00
Arvid Norberg 9e4045ed42 use 32 bit time points in torrent (#1662)
use 32 bit time points in torrent and add some slack to time point comparisons in python test
2017-02-05 19:18:06 -05:00
arvidn 381defab05 merged RC_1_1 into master 2017-02-05 12:51:48 -05:00
arvidn 7ff4f56ae2 add function to get default settings 2017-02-05 11:31:43 -05:00
Falcosc a9d6d54111 fix multible torrent status timer bugs related to move time (#1492)
fix last_upload and last_download overflow after 9 hours in past. change last_upload, last_download, finished_time,  resume, upload_mode_time to time_point and duration
2017-02-04 13:34:14 -05:00
arvidn 95c8c1de0f fix build 2017-01-28 21:26:46 -05:00
arvidn 6b91adab6a merged RC_1_1 into master 2017-01-28 14:36:23 -05:00
Arvid Norberg 7285813449 fix merge issue in python endpoint converter (#1625)
fix merge issue in python endpoint converter
2017-01-25 23:42:26 -05:00
Falcosc c979802ce9 add check and test for torrent parameter (#1541)
add test and fix for add_torrent_params python binding
2017-01-24 09:26:11 -05:00
Falcosc 32e0028e32 Fix python client (#1512)
extend python test to include examples. add piece index and block index python bindings
2017-01-24 08:50:36 -05:00
arvidn 62db98ca09 add missing min_memory_usage() and high_performance_seed() settings presets to python 2017-01-24 01:34:05 -05:00
arvidn 173951ec7f merged RC_1_1 into master 2017-01-21 02:28:29 -05:00
Calum Lind d32ed4b9de Fixup python code in bindings to pass PEP8 codestyle
* Passes Flake8 default settings.
 * Tabs replace spaces
 * Ensure print_function available for python2
2017-01-21 00:21:54 -05:00
arvidn 27001750a4 add python binding for generate_fingerprint 2017-01-16 14:27:02 -05:00
Calum Lind 748c6e0da0 Fix debug flags and add option to python build
* The '-g' flag are being passed in by CXXFLAGS and CFLAGS so ensure
   that debugging builds are actually off by adding '-g0' to DEBUG_FLAGS.
 * Add DEBUG_FLAGS to Python compiler options.
2017-01-16 13:41:37 -05:00
Calum Lind fc3eae8e9b [#1561] Silence deprecated warnings in Python bindings 2017-01-16 13:41:37 -05:00
arvidn 450a8fb170 fix add_torrent_params field in add_torrent_alert. include more fields in dict -> add_torrent_param converter for add_torrent/async_add_torrent 2017-01-16 11:37:17 -05:00
Arvid Norberg d4672f41ba fix python binding issue with string_view (#1560)
fix python binding issue with string_view
2017-01-15 14:42:22 -05:00
arvidn 934c58a816 merged RC_1_1 into master 2017-01-15 00:45:17 -05:00
Calum Lind de499310f5 [#1217] Fix RuntimeWarning registering pointer with Python
This fix checks for existing registered pointers for alert so that Boost
does not output the following warning when importing libtorrent in Python:

> RuntimeWarning: to-Python converter for boost::shared_ptrlibtorrent::alert already registered; second conversion method ignored.
2017-01-14 22:41:38 -05:00
Calum Lind 9b30d09099 [#1543] Fix missing C++11 flag for building python bindings
* Extract the flags from CXX and put into CXXFLAGS which is
   passed into setup.py extra_compile_args.
 * Remove now redundant os.environ test in setup.py
2017-01-14 19:30:25 -05:00
arvidn febcbbf17c fix make_torrent.py to not use deprecated functions 2017-01-14 16:04:01 -05:00
arvidn ea6e29d23f fix python binding time_point conversion 2016-12-31 12:33:50 -05:00
arvidn 8800cae585 fix msvc-warning in python binding 2016-12-31 02:01:29 -05:00
arvidn 4f89b397b1 fix python build 2016-12-29 15:06:56 -08:00
arvidn 59b322bc79 merged RC_1_1 into master 2016-12-29 08:54:28 -08:00
Arvid Norberg f1e34dfbd5 remove long-standing deprecated filter_pieces functions (#1457)
remove long-standing deprecated filter_pieces functions
2016-12-27 12:42:23 -08:00
arvidn eb5b0e9897 fix another c++98 issue 2016-12-24 11:27:58 -08:00
arvidn fa7846d1fd fix c++98 build 2016-12-24 08:40:49 -08:00
Arvid Norberg a6de426d1e add file_status to python binding (#1448)
add more missing functions to python bindings
2016-12-23 13:57:10 -08:00
arvidn 3f612d7e99 cleaning up of left-overs from torrent eviction functionality 2016-12-23 06:06:59 -05:00
arvidn 820fd29bff add missing session stats functions to python bindings 2016-12-23 06:06:44 -05:00
Arvid Norberg 3f1084d63d strengthened type safety in handling of piece and file indices (#1409)
strengthened type safety in handling of piece and file indices
2016-12-22 10:42:33 -05:00
arvidn a2c4e7490e merged RC_1_1 into master 2016-12-20 01:16:13 -05:00
arvidn a39f3714b2 fix python build with CC/CXX environment 2016-12-08 18:39:43 -05:00
arvidn 864fcfaced initialize piece priorities to 4 2016-12-04 18:36:45 -05:00
Alden Torres d5c4cd7280 fixed sign-compare warnings and some refactor (#1354)
fixed sign-compare warnings and some refactor. make sequence_number backed by std::int64_t
2016-11-27 08:46:53 -05:00
AllSeeingEyeTolledEweSew 3abecd2546 Cast cached_piece_info::kind to int. 2016-11-26 11:06:49 -05:00
Arvid Norberg 54f052a97b allocation slot type (#1352)
use a specialized type for allocation slot indices
2016-11-26 03:09:01 -05:00
arvidn b3c3c2aae6 merged RC_1_1 into master 2016-11-24 07:40:32 -05:00
AllSeeingEyeTolledEweSew c5f1c07a87 Bind cache_status::pieces. (#1323)
expose cache_status::pieces in python binding
2016-11-22 18:38:45 -05:00
arvidn 13f9c11078 fix python binding 2016-11-14 00:43:59 -05:00
arvidn ef1c241647 merged RC_1_1 into master 2016-11-13 21:54:09 -05:00
Arvid Norberg a7dcdf30ef cleanup and fixes to python bindings (#1317) 2016-11-13 20:52:56 -05:00
arvidn c9333849e6 deprecate relative times in torrent_status, replaced by std::chrono::time_point 2016-11-12 17:37:10 -05:00
arvidn ab6940d560 back-port python binding patch to expose cache_flushed_alert 2016-11-11 01:06:23 -05:00
All Seeing Eye Tolled Ewe Sew d69773c9e0 Add python bindings for cache_flushed_alert. 2016-11-10 19:58:47 -05:00
arvidn 583082a3a0 merged RC_1_1 into master 2016-11-09 19:53:55 -05:00
arvidn 19a5d9f989 add proxy_type_t to python binding 2016-11-05 11:37:14 -04:00
arvidn 2a999e1ea7 merge RC_1_1 into master 2016-11-03 23:58:35 -04:00
arvidn 98549a7c13 deprecated session_settings API has been removed. remove it from the test 2016-11-03 23:12:07 -04:00
arvidn 2d1ce777f5 fix python exception 2016-11-03 22:30:48 -04:00
arvidn d91f6f8c05 merged RC_1_1 into master 2016-11-03 01:19:38 -04:00
Arvid Norberg 11856d64e9 treat an unknown key in a settings_pack as an error in python (#1287) 2016-11-03 01:01:48 -04:00
arvidn c1fbd31bf1 make deprecation ifdefs more uniform 2016-11-02 23:40:48 -04:00
Arvid Norberg 4ba0151cb9 documentation fixes (#1274) 2016-10-29 22:56:46 -04:00
Alden Torres 877a47e03b fix deprecated warning with msvc (#1265)
fix deprecated warning with msvc
2016-10-27 18:09:14 -04:00
arvidn 500bb24dba merged RC_1_1 into master 2016-10-26 23:30:58 -04:00
Alden Torres 6751a1eeb1 removed spaces in template types and more c++11 auto/loop refactor 2016-10-26 00:08:00 -04:00
Arvid Norberg 61af222d92 add utility function for generating peer ID fingerprint (#1249)
add utility function for generating peer ID fingerprint
2016-10-25 08:03:26 -04:00
arvidn b1e22e6183 merged RC_1_1 into master 2016-10-20 00:36:54 -04:00
Alden Torres ded3ed6abf refactor in alert types to use more const fields and more clear API (#1222)
refactor in alert types to use more const fields and more clear API
2016-10-19 01:32:15 -04:00
arvidn 344eedb969 add python scrape_tracker test 2016-10-15 21:29:01 -04:00
Arvid Norberg c18c12a144 remove ghost torrent/torrent eviction feature. (#1214)
remove ghost torrent/torrent eviction feature. It was very complex and did not solve the problem very well
2016-10-15 13:32:59 -04:00
arvidn 1c89fcda48 merge RC_1_1 into master 2016-10-08 14:17:51 -04:00
Arvid Norberg 7a52a285a1 back-port error_code cleanup from master (#1173)
back-port error_code cleanup from master
2016-10-03 16:32:40 -07:00
Arvid Norberg cebd976cc2 fix error_code vs. error_condition traits (#1169)
fix error_code vs. error_condition traits. deprecate get_*_category(), instead use *_category()
2016-10-02 12:27:50 -07:00
minus ab846d2d31 fixed python scrape_tracker arguments (#1160) 2016-09-27 23:22:06 -04:00
Arvid Norberg f712caa80d deprecate send_stats property on trackers (since lt_tracker extension has been removed) (#1125) 2016-09-21 16:54:49 -07:00
Arvid Norberg 3e7e806a77 deprecate old session_settings API (use settings_pack instead) (#1117)
deprecate old session_settings API (use settings_pack instead)
2016-09-20 23:49:23 -07:00
Alden Torres 3faa771843 removed use of boost::bind and boost::scoped_array (#1053) 2016-09-01 09:43:53 -04:00
Arvid Norberg 5f5589d137 deprecate and remove remote_dl_rate feature (#1051)
deprecate and remove remote_dl_rate feature
2016-09-01 09:43:08 -04:00
Alden Torres bf0008933a refactor to use std::shared_ptr with peer_connection, core and tests (#1050) 2016-08-31 21:42:18 -04:00
Alden Torres 2ac45d17ef ed25519 api refactor (#1041) 2016-08-30 02:37:51 -04:00
Arvid Norberg c7eb76593c deprecate torrent priority (#1032)
deprecate torrent priority
2016-08-26 12:37:23 -04:00
Alden Torres 73d6ba6ae3 using span in torrent_handle and no optional in torrent_info (#1023) 2016-08-22 11:02:51 -04:00
arvidn 74fc0fae9d merged RC_1_1 into master 2016-08-21 16:28:49 -04:00
Arvid Norberg 80e5ce9b32 add a default DHT bootstrap node when it's enabled on session startup (#1008)
make the dht bootstrap nodes part of settings_pack instead, to make it possible to set them on startup. and add default
2016-08-21 12:15:19 -04:00
Alden Torres bb388563b3 refactor to use torrent_info with std::shared_ptr (#1006) 2016-08-17 17:26:35 -04:00
arvidn e247473b86 bump version number 2016-08-13 07:12:23 -04:00
Arvid Norberg e36e5efaba use boost::string_ref (#996)
use boost::string_ref/boost::string_view in various parts of the code, in file_storage, some file functions and in bdecode.
2016-08-13 07:04:53 -04:00
Arvid Norberg 30873e9c91 build python bindings with autotools on travis (#991)
build python bindings with autotools on travis
2016-08-10 14:20:15 -04:00
Arvid Norberg 1229491e5e back-port python3 fix 2016-08-10 07:28:13 -04:00
Arvid Norberg 330e683d13 fix bindings for python3 (#994)
fix bindings for python3
2016-08-10 07:26:02 -04:00
arvidn d03fdf77f4 make python test compatible with python 3 2016-08-07 19:11:27 -04:00
arvidn 42b3fbe20a merged RC_1_1 into master 2016-08-07 17:23:40 -04:00
Calum Lind 6c0f4cc082 Fix reoccurrence of py bindings -Wstrict-prototype warning (#959)
* Recent commit df368c2d15 has allowed the -Wstrict-prototype flag to
once again be passed to gcc so this fix removes all occurrences not just from 'OPT'.
2016-07-27 19:19:24 -04:00
Arvid Norberg 69f82c5274 add support for entry::preformatted to python binding (#952) 2016-07-27 00:15:26 -04:00
Alden Torres 7caa99d6f1 __cplusplus cleanup (#951)
cleanup
2016-07-26 18:30:19 -04:00
arvidn 680a09cfa5 merged RC_1_1 into master 2016-07-26 02:14:58 -04:00
Arvid Norberg 118d06b780 remove deprecated extensions lt_trackers and metadata_transfer (#941) 2016-07-24 23:39:56 -04:00
Arvid Norberg 6370d5bc81 deprecate lt_trackers extension (#940)
deprecate lt_trackers extension
2016-07-24 23:37:03 -04:00
Arvid Norberg 9c2325ff6b modernize and improve type-safety of the DHT put implementation and test (#929)
modernize and improve type-safety of the DHT put implementation and tests. use unique_ptr instead of malloc for dht put items.
2016-07-23 15:57:04 -07:00
Arvid Norberg f05fad0d41 remove load_asnum_db and load_country_db from python bindings (#930) 2016-07-21 18:10:29 -07:00
Alden Torres 7446a88425 version to 1.2 (#924)
update version to 1.2
2016-07-20 11:29:24 -07:00
arvidn 47d7c92fd4 merged RC_1_1 into master 2016-07-17 07:19:15 -07:00
arvidn c0d7650926 add default argument to python binding for post_torrent_updates 2016-07-16 19:23:23 -07:00
Arvid Norberg a740a49fd6 modernize misc (#898)
modernize misc
2016-07-10 07:34:45 -04:00
Arvid Norberg 48298e1670 modernize use nullptr (python binding) (#896) 2016-07-09 22:36:14 -04:00
Arvid Norberg eeb91cb803 Reduce appveyor builds 1.1 (#883)
reduce the number of times libtorrent is built on appveyor and travis
2016-07-05 11:25:31 -04:00
Arvid Norberg 66416963eb fix python binding linking on msvc (#878) 2016-07-03 23:30:52 -04:00
Arvid Norberg 21c1540ace clean up natpmp and upnp logging (#842)
clean up natpmp and upnp logging. remove custom logging macro and use regular logging via alerts. honor TORRENT_DISABLE_LOGGING
2016-06-23 01:23:59 -04:00
Arvid Norberg 717ed8bd3b Msvc warnings (#822)
fix msvc warnings in python bindings and simulations
2016-06-18 19:24:27 -04:00
Arvid Norberg ed077c8358 use cstdint intead of boost/cstdint.hpp (#833)
use cstdint intead of boost/cstdint.hpp
2016-06-18 14:01:38 -04:00
arvidn 4b186130e6 fix merge 2016-06-14 21:16:28 -04:00
arvidn 42c6376d5c another python binding fix 2016-06-14 20:16:04 -04:00
arvidn f01ac8f86c fix announce_entry python binding 2016-06-14 20:10:18 -04:00
Alden Torres 42a9022065 Refactor of listen alerts for separated fields address and port (#778)
Refactor of listen alerts for separated fields address and port
2016-06-02 22:38:56 -04:00
Arvid Norberg 748af6eec1 general cleanup. remove valgrind markup, log_hash_failures and C headers (#752)
general cleanup. remove valgrind markup, log_hash_failures and C headers
2016-05-23 08:15:39 -04:00
Arvid Norberg cf3c95702b Peer blocked alert (#747)
make peer_blocked_alert derive from peer_alert
2016-05-22 19:56:14 -04:00
Arvid Norberg b4e11a06c0 attempt to get GCC 5 in travis (#744)
use GCC 5 in travis
2016-05-21 16:23:15 -04:00
Arvid Norberg 1edf47a64f Travis build once (#739)
build libtorrent once on travis
2016-05-20 01:32:32 -04:00
Arvid Norberg c16c612eae fix python build on appveyor (#736)
fix python build on appveyor
2016-05-17 01:04:12 -04:00
Arvid Norberg 1e7e01c671 transition to system_error as the exception type (#730)
transition to system_error as the exception type
2016-05-15 00:33:06 -04:00
Arvid Norberg 167cbe74b5 made alerts move-only and remove dispatch function and other deprecated alert functions requiring alert to be copyable (#721) 2016-05-13 08:19:44 -04:00
arvidn fc4cc9e7ee make the cached current time thread-safe 2016-05-01 08:50:23 -04:00
Steven Siloti ff0675e64e use standard array container (#676) 2016-04-30 23:10:47 -04:00
Arvid Norberg 4e97bf556c use override and final keywords (unconditionally) (#668)
use override and final keywords instead of macros.
2016-04-30 11:05:54 -04:00
arvidn 36a5a11ee2 merge fix 2016-04-29 23:34:25 -04:00
Arvid Norberg f0d95f5e3e remove RSS feature (#662)
remove RSS feature
2016-04-29 15:54:21 -04:00
Arvid Norberg 46b33f920b remove explicit cache feature (#661)
remove explicit cache feature
2016-04-29 02:32:00 -04:00
Arvid Norberg 10ec0234a7 remove resolve-country feature (#656) 2016-04-28 08:20:47 -04:00
Arvid Norberg 80710abcbf fix python dictionary to settings_pack conversion bug (#652) 2016-04-27 12:28:22 -04:00
Arvid Norberg 97bdb4ba25 don't support c++98 anymore. build bt-get and bt-get2 by default (which require C++11). simplify address-model configuration in appveyor script. enable msvc-14 builds. use boost 1.59 on appveyor (#618) 2016-04-24 09:17:58 -04:00
arvidn eaf7cb329f fix python binding merge issue 2016-04-22 01:34:48 -04:00
arvidn 04a3c04075 merged RC_1_1 into master 2016-04-20 08:08:05 -04:00
Alden Torres 0fddd403b2 Better api for peers() method in dht_get_peers_reply_alert (#628) 2016-04-19 16:16:51 -04:00
arvidn d090bec242 fix python binding test 2016-04-16 22:41:43 -04:00
Steven Siloti e4fd45e109 fix the fix for python binding backwards compat
f409a5ab caused session.settings to return a setting pack dict rather than the
1.0 compatibile session_settings class.
2016-04-16 13:03:54 -07:00
arvidn c1fbac7fd3 fix python binding for python 3 2016-04-15 18:40:46 -04:00
arvidn 249dff6014 make dht_get_peers_reply_alert::peers a function in python binding 2016-04-15 00:53:02 -04:00
arvidn d84a38fdf2 improve converters for add_torrent_params 2016-04-15 00:48:47 -04:00