Changeset 9739 for main/waeup.kofa/trunk
- Timestamp:
- 29 Nov 2012, 18:46:54 (12 years ago)
- Location:
- main/waeup.kofa/trunk/src/waeup/kofa
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/browser/batchprocessing.txt
r9589 r9739 153 153 >>> browser.getControl(name='query').value = "zope.mgr" 154 154 >>> browser.getControl('Search').click() 155 >>> 'zope.mgr : Batch processing finished: OK' in browser.contents155 >>> 'zope.mgr - processed' in browser.contents 156 156 True 157 >>> 'Mode: create' in browser.contents158 True159 160 >>> browser.getControl(name='query').value = "finished"161 >>> browser.getControl('Search').click()162 >>> 'zope.mgr: Batch processing finished: OK' in browser.contents163 True164 >>> 'Mode: create' in browser.contents165 False166 157 167 158 -
main/waeup.kofa/trunk/src/waeup/kofa/utils/batching.py
r9734 r9739 244 244 if logger is None: 245 245 return 246 status = 'OK' 247 if warnings > 0: 248 status = 'FAILED' 249 logger.info("-" * 20) 250 logger.info("%s: Batch processing finished: %s" % (user, status)) 251 logger.info("%s: Source: %s" % (user, path)) 252 logger.info("%s: Mode: %s" % (user, mode)) 253 logger.info("%s: User: %s" % (user, user)) 254 if warnings > 0: 255 logger.info("%s: Failed datasets: %s" % ( 256 user, os.path.basename(fail_path))) 257 logger.info("%s: Processing time: %0.3f s (%0.4f s/item)" % ( 258 user, timedelta, timedelta/(num or 1))) 259 logger.info("%s: Processed: %s lines (%s successful/ %s failed)" % ( 260 user, num, num - warnings, warnings 261 )) 262 logger.info("-" * 20) 246 logger.info( 247 "processed: %s, %s mode, %s lines (%s successful/ %s failed), " 248 "%0.3f s (%0.4f s/item)" % ( 249 path, mode, num, num - warnings, warnings, 250 timedelta, timedelta/(num or 1))) 263 251 return 264 252 -
main/waeup.kofa/trunk/src/waeup/kofa/utils/batching.txt
r9706 r9739 277 277 278 278 >>> print open('stoneville.log').read() 279 -------------------- 280 Bob: Batch processing finished: OK 281 Bob: Source: newcomers.csv 282 Bob: Mode: create 283 Bob: User: Bob 284 Bob: Processing time: ... s (... s/item) 285 Bob: Processed: 4 lines (4 successful/ 0 failed) 286 -------------------- 279 processed: newcomers.csv, create mode, 4 lines (4 successful/ 0 failed), ... s (... s/item) 280 287 281 288 282 We cleanup the temporay dir created by doImport(): … … 306 300 307 301 >>> print open('stoneville.log').read() 308 -------------------- 309 ... 310 -------------------- 311 Bob: Batch processing finished: FAILED 312 Bob: Source: newcomers.csv 313 Bob: Mode: create 314 Bob: User: Bob 315 Bob: Failed datasets: newcomers.pending.csv 316 Bob: Processing time: ... s (... s/item) 317 Bob: Processed: 4 lines (0 successful/ 4 failed) 318 -------------------- 302 processed: newcomers.csv, create mode, 4 lines (4 successful/ 0 failed), ... s (... s/item) 303 processed: newcomers.csv, create mode, 4 lines (0 successful/ 4 failed), ... s (... s/item) 304 319 305 320 306 This time a new file was created, which keeps all the rows we could not -
main/waeup.kofa/trunk/src/waeup/kofa/utils/tests/test_batching.py
r9726 r9739 218 218 """ 219 219 >>> print log_contents 220 -------------------- 221 Bob: Batch processing finished: OK 222 Bob: Source: /.../newcomers.csv 223 Bob: Mode: create 224 Bob: User: Bob 225 Bob: Processing time: ... s (... s/item) 226 Bob: Processed: 4 lines (4 successful/ 0 failed) 227 -------------------- 220 processed: /.../newcomers.csv, create mode, 4 lines (4 successful/ 0 failed), ... s (... s/item) 228 221 229 222 """
Note: See TracChangeset for help on using the changeset viewer.