1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

python script throws errors while run on the toolbox

Discussion in 'Geography' started by user10389994, Oct 8, 2018.

  1. user10389994

    user10389994 Guest

    When on custom toolbox it throws errors often while in arcpy it works normally.


    ERROR 000732: Input Features: Dataset ASTENOT_lines does not exist or is not supported

    If I close and open ArcMap it then works but if I use the Arcpy it shows that error again.

    Maybe it has to do with background processes?

    Also it shows errors other than 00732. Like: When doing this:


    ExecuteError: Failed to execute. Parameters are not valid.

    While the same script in Arcpy works ok.

    Why is this happening?


    rf= arcpy.GetParameterAsText(0)

    arcpy.env.workspace = r"C:\\Users\user\\Desktop\\201SimplLines\\" +rf+"\\ASTENOT"
    for fc in arcpy.ListFeatureClasses():

    import arcpy.cartography as CA
    CA.CollapseDualLinesToCenterline("ASTENOT_lines",'centerline',30,3) #2

    Login To add answer/comment

Share This Page