@@ -24,7 +24,7 @@ def path_resolver(path):
2424
2525 parent_clause = path_relations .get_clause_from_path (path )
2626 if not parent_clause :
27- logging .debug ("Path [%s] does not exist for split." , path )
27+ # logging.debug("Path [%s] does not exist for split.", path)
2828 raise GdNotFoundError ()
2929
3030 return (parent_clause [CLAUSE_ENTRY ], parent_clause )
@@ -93,12 +93,7 @@ def remove_entry_recursive(self, entry_id, is_update=False):
9393 else :
9494 stat_files += 1
9595
96- try :
97- result = self .__remove_entry (current_entry_id , is_update )
98- except :
99- self .__log .debug ("Could not remove entry with ID [%s] "
100- "(recursive)." , current_entry_id )
101- raise
96+ result = self .__remove_entry (current_entry_id , is_update )
10297
10398 removed [current_entry_id ] = True
10499
@@ -356,8 +351,8 @@ def register_entry(self, normalized_entry):
356351
357352 entry_id = normalized_entry .id
358353
359- self .__log .debug ("Registering entry with ID [%s] within path-"
360- "relations." , entry_id )
354+ # self.__log.debug("Registering entry with ID [%s] within path-"
355+ # "relations.", entry_id)
361356
362357 if self .is_cached (entry_id , include_placeholders = False ):
363358# self.__log.debug("Entry to register with ID [%s] already "
@@ -464,28 +459,28 @@ def register_entry(self, normalized_entry):
464459 return entry_clause
465460
466461 def __load_all_children (self , parent_id ):
467- self .__log .debug ("Loading children under parent with ID [%s]." ,
468- parent_id )
462+ # self.__log.debug("Loading children under parent with ID [%s].",
463+ # parent_id)
469464
470465 with PathRelations .rlock :
471466 children = drive_proxy ('list_files' , parent_id = parent_id )
472467
473468 child_ids = [ ]
474469 if children :
475- self .__log .debug ("(%d) children returned and will be "
476- "registered." , len (children ))
470+ # self.__log.debug("(%d) children returned and will be "
471+ # "registered.", len(children))
477472
478473 for child in children :
479474 self .register_entry (child )
480475
481- self .__log .debug ("Looking up parent with ID [%s] for all-"
482- "children update." , parent_id )
476+ # self.__log.debug("Looking up parent with ID [%s] for all-"
477+ # "children update.", parent_id)
483478
484479 parent_clause = self .__get_entry_clause_by_id (parent_id )
485480
486481 parent_clause [4 ] = True
487482
488- self .__log .debug ("All children have been loaded." )
483+ # self.__log.debug("All children have been loaded.")
489484
490485 return children
491486
@@ -494,7 +489,7 @@ def get_children_from_entry_id(self, entry_id):
494489 entry-ID.
495490 """
496491
497- self .__log .debug ("Getting children under entry with ID [%s]." ,entry_id )
492+ # self.__log.debug("Getting children under entry with ID [%s].",entry_id)
498493
499494 with PathRelations .rlock :
500495 entry_clause = self .__get_entry_clause_by_id (entry_id )
@@ -523,8 +518,8 @@ def get_children_from_entry_id(self, entry_id):
523518 self .__log .error (message )
524519 raise Exception (message )
525520
526- self .__log .debug ("(%d) children found." ,
527- len (entry_clause [CLAUSE_CHILDREN ]))
521+ # self.__log.debug("(%d) children found.",
522+ # len(entry_clause[CLAUSE_CHILDREN]))
528523
529524 return entry_clause [CLAUSE_CHILDREN ]
530525
@@ -540,7 +535,7 @@ def get_children_entries_from_entry_id(self, entry_id):
540535
541536 def get_clause_from_path (self , filepath ):
542537
543- self .__log .debug ("Getting clause for path [%s]." , filepath )
538+ # self.__log.debug("Getting clause for path [%s].", filepath)
544539
545540 with PathRelations .rlock :
546541 path_results = self .find_path_components_goandget (filepath )
@@ -550,7 +545,7 @@ def get_clause_from_path(self, filepath):
550545 return None
551546
552547 entry_id = path_results [0 ][- 1 ]
553- self .__log .debug ("Found entry with ID [%s]." , entry_id )
548+ # self.__log.debug("Found entry with ID [%s].", entry_id)
554549
555550 # Make sure the entry is more than a placeholder.
556551 self .__get_entry_clause_by_id (entry_id )
@@ -567,8 +562,8 @@ def find_path_components_goandget(self, path):
567562 previous_results = []
568563 i = 0
569564 while 1 :
570- self .__log .debug ("Attempting to find path-components (go and "
571- "get) for path [%s]. CYCLE= (%d)" , path , i )
565+ # self.__log.debug("Attempting to find path-components (go and "
566+ # "get) for path [%s]. CYCLE= (%d)", path, i)
572567
573568 # See how many components can be found in our current cache.
574569
@@ -626,8 +621,9 @@ def find_path_components_goandget(self, path):
626621
627622 filenames_phrase = ', ' .join ([ candidate .id for candidate
628623 in children ])
629- self .__log .debug ("(%d) candidate children were found: %s" ,
630- len (children ), filenames_phrase )
624+
625+ # self.__log.debug("(%d) candidate children were found: %s",
626+ # len(children), filenames_phrase)
631627
632628 i += 1
633629
@@ -651,7 +647,7 @@ def __find_path_components(self, path):
651647 return self .path_cache [path ]
652648
653649 with PathRelations .rlock :
654- self .__log .debug ("Locating entry information for path [%s]." , path )
650+ # self.__log.debug("Locating entry information for path [%s].", path)
655651 root_id = AccountInfo .get_instance ().root_id
656652
657653 # Ensure that the root node is loaded.
@@ -668,9 +664,9 @@ def __find_path_components(self, path):
668664 child_filename_to_search_fs = utility . \
669665 translate_filename_charset (path_parts [i ])
670666
671- self .__log .debug ("Checking for part (%d) [%s] under parent "
672- "with ID [%s]." ,
673- i , child_filename_to_search_fs , entry_ptr )
667+ # self.__log.debug("Checking for part (%d) [%s] under parent "
668+ # "with ID [%s].",
669+ # i, child_filename_to_search_fs, entry_ptr)
674670
675671 current_clause = self .entry_ll [entry_ptr ]
676672
@@ -752,20 +748,20 @@ def __get_entries_to_update(self, requested_entry_id):
752748 parent_ids = drive_proxy ('get_parents_containing_id' ,
753749 child_id = requested_entry_id )
754750
755- self .__log .debug ("Found (%d) parents." , len (parent_ids ))
751+ # self.__log.debug("Found (%d) parents.", len(parent_ids))
756752
757753 affected_entries = [ requested_entry_id ]
758754 considered_entries = { }
759755 max_readahead_entries = Conf .get ('max_readahead_entries' )
760756 for parent_id in parent_ids :
761- self .__log .debug ("Retrieving children for parent with ID [%s]." ,
762- parent_id )
757+ # self.__log.debug("Retrieving children for parent with ID [%s].",
758+ # parent_id)
763759
764760 child_ids = drive_proxy ('get_children_under_parent_id' ,
765761 parent_id = parent_id )
766762
767- self .__log .debug ("(%d) children found under parent with ID [%s]." ,
768- len (child_ids ), parent_id )
763+ # self.__log.debug("(%d) children found under parent with ID [%s].",
764+ # len(child_ids), parent_id)
769765
770766 for child_id in child_ids :
771767 if child_id == requested_entry_id :
@@ -817,15 +813,15 @@ def __do_update_for_missing_entry(self, requested_entry_id):
817813 for entry_id , entry in retrieved .iteritems ():
818814 path_relations .register_entry (entry )
819815
820- self .__log .debug ("(%d) entries were loaded." , len (retrieved ))
816+ # self.__log.debug("(%d) entries were loaded.", len(retrieved))
821817
822818 return retrieved
823819
824820 def fault_handler (self , resource_name , requested_entry_id ):
825821 """A requested entry wasn't stored."""
826822
827- self .__log .debug ("EntryCache has faulted on entry with ID [%s]." ,
828- requested_entry_id )
823+ # self.__log.debug("EntryCache has faulted on entry with ID [%s].",
824+ # requested_entry_id)
829825
830826 retrieved = self .__do_update_for_missing_entry (requested_entry_id )
831827
0 commit comments