Select to view content in your preferred language

Tool works fine when I use it normally, but configured into Arcpy throws licensing error

970
6
Jump to solution
04-17-2023 07:25 PM
AFackler_NAPSG
Occasional Contributor

I am building a relatively simple python script to run a Geotagged Photo to Point tool, then run a few field calculations to add on some extra data. I managed to get the field calculations working, however, the Geotagged Photo to Point tool is giving me some problems.

When I run the tool on its own in the geoprocessing pane, it runs without issues. I also have ran it without problems in Modelbuilder. However, when I try to run it off Arcpy, I am greeted with the error 000824: The tool is not licensed. I have the advanced license and several extensions, but it baffles me why I can run it normally but not through Arcpy. 

Below is my code sample so yall can pick it apart as needed. Thanks!

import arcpy
from sys import argv
InputFolder = arcpy.GetParameterAsText(0)
OutputFeatureClass = arcpy.GetParameterAsText(1)
arcpy.AddMessage("Running Geotagged Photos to Points")
# Geotagged Photos to Points
arcpy.management.GeoTaggedPhotosToPoints(InputFolder, OutputFeatureClass, 
None, "ONLY_GEOTAGGED", "ADD_ATTACHMENTS")

 

0 Kudos
1 Solution

Accepted Solutions
AFackler_NAPSG
Occasional Contributor

The issue here was that Pro needed an update. After updating to 3.1.1 it's working fine. Thanks all for your support

View solution in original post

0 Kudos
6 Replies
DanPatterson
MVP Esteemed Contributor

Is this a locally installed version of Pro?

See licensing

CheckProduct—ArcGIS Pro | Documentation

to see what it returns within and outside of a Pro session

 


... sort of retired...
0 Kudos
AFackler_NAPSG
Occasional Contributor

Not sure how exactly to run that tool, but Pro is locally installed version 3.0.3

0 Kudos
Luke_Pinner
MVP Regular Contributor

@AFackler_NAPSG wrote:

Not sure how exactly to run that tool, but Pro is locally installed version 3.0.3


Example at the bottom of the page Dan linked to.

0 Kudos
AFackler_NAPSG
Occasional Contributor

Running the tool like the example, I get "ArcGIS for Desktop Advanced license not available" which I know is wrong because I triple-checked that I have the advanced license (screenshot below). When I run arcpy.CheckProduct("arcinfo") as is in the python window, I get the message 'AlreadyInitialized'. Another development, when I run the tool from the Python window after copying the python command from the geoprocessing pane it runs fine.

AFackler_NAPSG_0-1681852635068.png

 

0 Kudos
DanPatterson
MVP Esteemed Contributor

If you have a local install and your license is only controlled by you and not an organization, I would contact tech support since I can't find anything on the publically available support site.

I have never had an issue with licensing, regardless where I run scripts or code (notebooks, python window, spyder IDE etc).

 


... sort of retired...
0 Kudos
AFackler_NAPSG
Occasional Contributor

The issue here was that Pro needed an update. After updating to 3.1.1 it's working fine. Thanks all for your support

0 Kudos