12345678910111213141516171819202122232425262728293031323334353637383940 |
- import logging
- import re
- def check_db_metadata(loader, loader_prev):
- for each in loader.iterate_properties():
- prev = loader_prev.get_property(each.name)
- if prev != each.value:
- logging.warn("Previous data file has got different metadata:")
- logging.warn(" - identification of change trends can be not reliable")
- logging.warn(" - use 'info' tool to view more details")
- return 1
- return 0
- def preprocess_path(path):
- path = re.sub(r'''[\\]+''', "/", path)
- logging.info("Processing: " + path)
- return path
- def report_bad_path(path):
- logging.error("Specified path '" + path + "' is invalid: not found in the database records.")
-
-
|