Hi Greg, Another small patch for cleanup_datasets.py, that makes the output messages slightly more informative. The changes are: 1. If a dataset is skipped (because it's shared/cloned and was already process), no message is printed at all. 2. If a dataset can not be deleted because it is shared, and one instance is not marked as "deleted", a proper message is printed. 3. If a dataset has metadata files, the message is changed depending on "info_only" and "remove_from_disk" flags. 4. The final summary message is slightly changed. The main goal is for the "delete_datasets.sh" script (with "-i" or without) to display exactly what's going on. comments are welcomed, -gordon Example of items 1,2: Without patch: ===== ... ######### Processing dataset id: 1782 ######### Processing dataset id: 1782 ######### Processing dataset id: 1782 ######### Processing dataset id: 1783 Dataset 1783 will be deleted (without 'info_only' mode) ######### Processing dataset id: 1801 Dataset 1801 will be deleted (without 'info_only' mode) ====== Which shows that dataset 1782 seems to be processed three times, but still not deleted, without giving a reason. With this patch, the output will be: ====== ######### Processing dataset id: 1782 Dataset is not deletable (shared between multiple histories/libraries, at least one is not deleted) ######### Processing dataset id: 1783 Dataset 1783 will be deleted (without 'info_only' mode) ######### Processing dataset id: 1801 Dataset 1801 will be deleted (without 'info_only' mode) ====== Example of item 3: Without patch: ========== ######### Processing dataset id: 1404 The following metadata files attached to associations of Dataset '1404' have been purged: /localdata1/galaxy/database_prod/files/_metadata_files/000/metadata_102.dat Dataset 1404 will be deleted (without 'info_only' mode) ========== With patch: ========== ######### Processing dataset id: 1404 The following metadata files attached to associations of Dataset '1404' will be marked as deleted (without 'info_only' mode): /localdata1/galaxy/database_prod/files/_metadata_files/000/metadata_102.dat Dataset 1404 will be deleted (without 'info_only' mode) =========== Example of item 4: Without patch: ==== Examined 606 datasets, marked 589 as deleted and purged 595 dataset instances ==== With patch: === Examined 606 datasets, marked 589 datasets and 595 dataset instances (HDA) as deleted ===
Hello Assaf, Thanks very much for the patch - I've applied it in change set 5788:b2f7abd50f6a Greg On Jul 12, 2011, at 3:18 PM, Assaf Gordon wrote:
Hi Greg,
Another small patch for cleanup_datasets.py, that makes the output messages slightly more informative.
The changes are: 1. If a dataset is skipped (because it's shared/cloned and was already process), no message is printed at all. 2. If a dataset can not be deleted because it is shared, and one instance is not marked as "deleted", a proper message is printed. 3. If a dataset has metadata files, the message is changed depending on "info_only" and "remove_from_disk" flags. 4. The final summary message is slightly changed.
The main goal is for the "delete_datasets.sh" script (with "-i" or without) to display exactly what's going on.
comments are welcomed, -gordon
Example of items 1,2: Without patch: ===== ... ######### Processing dataset id: 1782 ######### Processing dataset id: 1782 ######### Processing dataset id: 1782 ######### Processing dataset id: 1783 Dataset 1783 will be deleted (without 'info_only' mode) ######### Processing dataset id: 1801 Dataset 1801 will be deleted (without 'info_only' mode) ======
Which shows that dataset 1782 seems to be processed three times, but still not deleted, without giving a reason.
With this patch, the output will be: ====== ######### Processing dataset id: 1782 Dataset is not deletable (shared between multiple histories/libraries, at least one is not deleted) ######### Processing dataset id: 1783 Dataset 1783 will be deleted (without 'info_only' mode) ######### Processing dataset id: 1801 Dataset 1801 will be deleted (without 'info_only' mode) ======
Example of item 3: Without patch: ========== ######### Processing dataset id: 1404 The following metadata files attached to associations of Dataset '1404' have been purged: /localdata1/galaxy/database_prod/files/_metadata_files/000/metadata_102.dat Dataset 1404 will be deleted (without 'info_only' mode) ==========
With patch: ========== ######### Processing dataset id: 1404 The following metadata files attached to associations of Dataset '1404' will be marked as deleted (without 'info_only' mode): /localdata1/galaxy/database_prod/files/_metadata_files/000/metadata_102.dat Dataset 1404 will be deleted (without 'info_only' mode) ===========
Example of item 4: Without patch: ==== Examined 606 datasets, marked 589 as deleted and purged 595 dataset instances ====
With patch: === Examined 606 datasets, marked 589 datasets and 595 dataset instances (HDA) as deleted ===
<galaxy_cleanup_delete_dataset_messages.patch>___________________________________________________________ Please keep all replies on the list by using "reply all" in your mail client. To manage your subscriptions to this and other Galaxy lists, please use the interface at:
Greg Von Kuster Galaxy Development Team greg@bx.psu.edu
participants (2)
-
Assaf Gordon
-
Greg Von Kuster