How to run Data Reviewer outside of ArcMap

11-07-2017 05:19 AM
by Anonymous User
Not applicable

I am trying to schedule the automation of a Data Reviewer batch job that I can run from a standalone script using task scheduler.  My goal is to run a batch job nightly.  When I run my script in the interactive python window in ArcMap everything works fine.  However when I try to run the same script in IDLE I get this error:

Traceback (most recent call last):
File "M:\GisData\Depts\StormH2O\Python\", line 29, in <module>
arcpy.CreateReviewerSession_Reviewer(reviewer_gdb, Session_Name, None, None, 'STORE_GEOMETRY', 'Python_Editor', None)
AttributeError: 'module' object has no attribute 'CreateReviewerSession_Reviewer'

Is it possible to run Data Reviewer outside of ArcMap?

# -*- coding: utf-8 -*- 

# Import modules
import arcpy
import datetime

i =

# Name:
# Description: Creates a reviewer session in a geodatabase
# Author: Esri
# Date: May 2015

# check out a data reviewer extension license

# path to a workspace
reviewer_gdb = "M:\GisData\Depts\StormH2O\Data_Reviewer\Data_Reviewer.gdb"

# Execute the Create Reviewer Session tool. Do not specify a template session and set the duplicate checking and store geometry parameters.
# Session User Name parameter is not supplied so it will be set to the logged in user name.
# Session Version parameter is not supplied so it will be set to the Default version.

Session_Name = ("%s.%s.%s" % (i.year, i.month,

arcpy.CreateReviewerSession_Reviewer(reviewer_gdb, Session_Name, None, None, 'STORE_GEOMETRY', 'Python_Editor', None)

Session_ID = ""

Path_To_Table = "M:\GisData\Depts\StormH2O\Data_Reviewer\Data_Reviewer.gdb\GDB_REVSESSIONTABLE"

CURSOR = arcpy.SearchCursor(Path_To_Table, ['SESSIONID', 'SESSIONNAME'])
for row in CURSOR:
    Session_ID = row.getValue("SESSIONID")

# Path to the tutorial reviewer workspace
rev_workspace = "M:\GisData\Depts\StormH2O\Data_Reviewer\Data_Reviewer.gdb"

# path to the tutorial batch job file
batch_job_file = "M:\GisData\Depts\StormH2O\Data_Reviewer\Contains_both_ways.rbj"

# session - must exist before executing this script.
session = "Session %d : %s"%(Session_ID,Session_Name)

# path to the tutorial production workspace - this contains the data to validate
prod_workspace = "M:\GisData\Depts\StormH2O\Python\Detect_Change\Comparison_Workspace\Comparison_Workspace.gdb"

# execute the batch job
arcpy.ExecuteReviewerBatchJob_Reviewer(rev_workspace, session, batch_job_file, prod_workspace, None, None, None)

# check in the data reviewer extension
Tags (2)
1 Reply
Occasional Contributor II

I had the same issue, and I found that having the background geoprocessing 64-bit patch installed is not compatible with Data Reviewer Arcpy functions. My solution was to run Python routines with DR Arcpy functions from a machine that has 32-bit Python installed, not 64 bit. 

Background Geoprocessing (64-bit)—Help | ArcGIS Desktop 

0 Kudos