ATLAS Offline Software
diff_pool_files.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
2 
3 # @file PyUtils.scripts.diff_pool_files
4 # @purpose check that 2 POOL files have same content (containers and sizes).
5 # @author Sebastien Binet
6 # @date February 2010
7 
8 __doc__ = "diff two POOL files (containers and sizes)"
9 __author__ = "Sebastien Binet"
10 
11 
12 
13 import PyUtils.acmdlib as acmdlib
14 
15 @acmdlib.command(name='diff-pool')
16 @acmdlib.argument('old',
17  help='path to the reference POOL file to analyze')
18 @acmdlib.argument('new',
19  help='path to the POOL file to compare to the reference')
20 @acmdlib.argument('-v', '--verbose',
21  action='store_true',
22  default=False,
23  help="""Enable verbose printout""")
24 def main(args):
25  """diff two POOL files (containers and sizes)"""
26 
27  import os.path as osp
28  old = osp.expandvars(osp.expanduser(args.old))
29  new = osp.expandvars(osp.expanduser(args.new))
30 
31  import PyUtils.PoolFile as PF
32  diff = PF.DiffFiles(refFileName = old,
33  chkFileName = new,
34  verbose = args.verbose)
35  diff.printSummary()
36  return diff.status()
python.scripts.diff_pool_files.main
def main(args)
Definition: diff_pool_files.py:24