Commit Graph

2324 Commits

Author SHA1 Message Date
Fabio Erculiani 89ac49fc63 entropy.tools: remove deprecated functions 2009-05-15 19:35:35 +02:00
Fabio Erculiani d80f2ebd74 entropy.tools: effectively move compressTarBz2 to compress_tar_bz2 2009-05-15 19:35:04 +02:00
Fabio Erculiani d412435c2a entropy.tools + smart: rename compressTarBz2 to compress_tar_bz2 and update smart app tools 2009-05-15 19:33:57 +02:00
Fabio Erculiani aeca2ace65 entropy.tools: fix compressTarBz2 2009-05-15 19:33:18 +02:00
Fabio Erculiani 61b05e72d6 unit testing: add entropy.transceivers unit test module 2009-05-15 18:14:13 +02:00
Fabio Erculiani 43c94a6507 unit testing: append correct sys.path to every test class 2009-05-15 13:43:31 +02:00
Fabio Erculiani 31bf6773af unit testing, add entropy.misc tests (specifically Lifo class test) 2009-05-15 13:43:05 +02:00
Fabio Erculiani 02034aaa39 entropy.misc: Lifo, improve performance
Dictionary counter is generally not needed thanks to max() and
thread-safety is now left to developer.
2009-05-15 13:29:07 +02:00
Fabio Erculiani f93a86208b entropy.server: implement branch flushback logic
Generally, when starting a new branch packages are not copied over
to avoid wasting disk space. So, old packages will be still pulled
in from old branch directories (under packages/). This commit adds
a function that automatically flush back old-branch packages into
the current one.
Let's say we have just bumped our repo from branch 1 to branch 2.
We have 3 packages into it that are still placed inside /packages/1.
Everything works until we decide to drop support from branch 1, in
this case, we would have to rebuild all these packages wasting a lot
of time. With "flushback" this is done automatically without touching
packages integrity.
2009-05-15 10:11:30 +02:00
Fabio Erculiani eee6438980 entropy.server.interfaces.mirrors: change args on _sync_run_download_queue
_sync_run_download_queue accepted a list of tuples of size 2, there is
no need for such complex input since it just needs a plain path list.
Moreover, appending some code style updates too
2009-05-14 19:36:13 +02:00
Fabio Erculiani c429d8c71c entropy.server.interfaces.mirrors: code style update 2009-05-14 19:31:03 +02:00
Fabio Erculiani 1cf75a57dd entropy.transceivers: urlFetcher class becomes UrlFetcher 2009-05-14 18:06:52 +02:00
Fabio Erculiani 51280ef68f entropy.client.interfaces.package: remove unused install step "showmessages" 2009-05-14 09:05:30 +02:00
Fabio Erculiani 51204fd173 entropy: remove gentoo-compat option, always enabled 2009-05-14 09:04:37 +02:00
Fabio Erculiani bc6cc73b43 entropy.client.interfaces.package: rename gentoo references to spm 2009-05-14 08:51:43 +02:00
Fabio Erculiani 3e1c336122 entropy.client: fix typo in __remove_package_from_gentoo_database when calling Spm.search_keys 2009-05-14 08:48:18 +02:00
Fabio Erculiani dd7aaaff3c entropy.client: on repository update, during db sync, catch DatabaseError exceptions too 2009-05-14 08:46:00 +02:00
Fabio Erculiani e5d867d98a entropy.client: code style update 2009-05-13 12:12:56 +02:00
Fabio Erculiani 5e0d8ea04a entropy.client: only update Portage world file when install source is user 2009-05-13 12:10:22 +02:00
Fabio Erculiani 96a63525eb entropy.client: make world file and portage db handling more atomic on removal 2009-05-13 12:05:11 +02:00
Fabio Erculiani 88e4612415 entropy.client: Portage world file handling fixes
Portage world file handling was broken, causing portage to wtf all
the time. This commit fixes it for the joy of wolfden (old man).
2009-05-13 11:52:33 +02:00
Fabio Erculiani 5212c9e96d entropy.client.misc.FileUpdates: encode CONFIG_PROTECT path with fs encoding 2009-05-12 19:01:48 +02:00
Fabio Erculiani f2cc4e1d91 entropy.client: handle bogus entries on _lookup_library_breakages 2009-05-12 17:23:06 +02:00
Fabio Erculiani 55e96d0050 unit testing: add some misc test scripts 2009-05-12 16:58:47 +02:00
Fabio Erculiani 0e8d1c304c entropy.client: fix unreferenced variable, my fault 2009-05-12 16:41:05 +02:00
Fabio Erculiani 4eefede7c6 entropy.Client: rework calculate_world_updates when using ignore-spm-downgrades
So we have several nasty issues when using ignore-spm-downgrades here.
First of all, calculate_world_updates should get the setting directly from
SystemSettings instead of bugging developer asking for it.
Secondly, calculate_world_updates should return a 4D tuple, also containing
the matches ignored when ignore-spm-downgrades is enabled.
Moreover, Spritz packages.py getPackageItem featured an unused argument,
which has been dropped.

I know this commit is a bitch because we are talking about changing API
and affecting several files at once.
2009-05-12 14:14:02 +02:00
Fabio Erculiani ca8129af60 entropy.server.interfaces: move_packages, make supa-sure that queue
does not contain dupies
2009-05-10 17:04:41 +02:00
Fabio Erculiani a97e726622 entropy.transceivers: implement support for FtpInterface.get_file_md5 in FtpServerHandler
The aim is to make php handlers not always required when there is a FTP
server that supports "SITE MD5" commands (like proftpd with mod_md5).
This commit makes FtpServerHandler able to handle such feature and avoid
using any other external hook. If server support is found, this verification
is enough. If support is broken, FtpServerHandler will try to fallback to
previously supported features, if enabled (use_handlers variable).
Moreover, FtpServerHandler now makes use of entropy.tools.is_valid_md5
instead of just checking if provided strings are long 32 chars.
2009-05-10 16:29:30 +02:00
Fabio Erculiani d18be0cfec entropy.tools: new function is_valid_md5 (self explanatory) 2009-05-10 16:23:56 +02:00
Fabio Erculiani faafaa1b0c entropy.transceivers: FtpInterface add method get_file_md5.
Proftpd server with mod_md5 supports SITE MD5 <filepath> that actually
retrieves the md5 hash of the provided filepath.
This commit add support for it. The aim is trying to use SITE MD5 instead
if available instead of using crappy php hooks that in our world are called
"repository handlers".
2009-05-10 13:46:11 +02:00
Fabio Erculiani 9669e7683f entropy.server.interface: when move_packages is done, always run dependencies test 2009-05-09 13:43:10 +02:00
Fabio Erculiani f5d8f12bb2 entropy.server.interfaces: move_packages, fine tune output 2009-05-09 13:27:45 +02:00
Fabio Erculiani 6d68012f67 entropy.qa: _get_deep_dependency_list, always discard -1 in returning set 2009-05-09 13:27:20 +02:00
Fabio Erculiani 70e9eb4f7d entropy.server.interfaces: fine tune output on move_packages 2009-05-09 13:22:59 +02:00
Fabio Erculiani 0a4333886f entropy.db: rename WriteLock to __write_mutex 2009-05-09 12:49:28 +02:00
Fabio Erculiani 844c40f05e entropy.client.interfaces.methods: do not clear SystemSettings when running in dry-run mode 2009-05-07 17:31:38 +02:00
Fabio Erculiani 5582fd2efd SystemSettings: move live package masking metadata to persistent settings 2009-05-07 17:30:28 +02:00
Fabio Erculiani 6b71cb80c0 entropy server: move_packages, add new argument pull_deps
This option will allow repository packages move/copy pulling in all
the dependencies of every package selected.
2009-05-07 14:12:10 +02:00
Fabio Erculiani 6287413522 QA interface: improve _get_deep_dependency_list method 2009-05-07 14:11:37 +02:00
Fabio Erculiani c7a0d62879 entropy.db: improve utf8 and str input support of insertLicenses 2009-05-05 05:59:13 +02:00
Fabio Erculiani e7ca06ce96 unit testing, db: add test for insertLicenses with str input 2009-05-04 17:41:55 +02:00
Fabio Erculiani 8669bec923 entropy.db: insertLicenses, add support for both unicode and str input 2009-05-04 17:41:26 +02:00
Fabio Erculiani 908a50f1f1 entropy.client.interfaces.package: fix __update_available_cache
__update_available_cache wasn't working correctly: available cache
was not updated correctly, causing get_available_packages returning
wrong information when cached.
2009-05-04 00:24:00 +02:00
Fabio Erculiani 1a90a00f25 entropy.client.interfaces.fetch: set/unset default mirror to MirrorStatus 2009-05-03 23:55:36 +02:00
Fabio Erculiani b04cbc6d9a entropy.client.mirrors.StatusInterface: add two new methods.
Add set_working_mirror and add_failing_working_mirror methods with
the aim of increasing the usefulness of the class.
2009-05-03 23:40:28 +02:00
Fabio Erculiani 1599a3ae30 transceivers: avoid showing negative data transfers 2009-05-03 18:57:21 +02:00
Fabio Erculiani 7c1c69df13 entropy.client.interfaces.trigger: fix ebuild postinstall and preinstall trigger when merge_from mode is used 2009-05-03 15:29:23 +02:00
Fabio Erculiani 7dae8b0bde entropy.client.interfaces.dep: fix generate_dependency_tree
On some circumstances, post dependencies got a deplevel of 0, which
was overwritten by conflicts data. This patch fix the issue by
making deplevels >= 0 to always start from 1, leaving deplevel = 0
to conflicting packages.

Moreover, this patch improve generate_dependency_tree performance.
2009-05-03 14:57:20 +02:00
Fabio Erculiani 2c3f9fe24a entropy.db: skip tables that cannot be dropped on initializeDatabase 2009-05-02 18:12:14 +02:00
Fabio Erculiani 615d4cac1b entropy.client.interfaces.Client: properly fill validRepositories
When repo_validation is False, validRepositories list was not filled
properly on __init__. This commit fixes the issue.
2009-04-30 11:21:10 +02:00