|
POST
|
I am trying to wrap some Python 2 code into Python 3 but having trouble getting the process to work correctly. From ArcGIS Pro, I'm running a custom GP tool with the following code as its script. My goal is to run my Python 2 code (stored in a separate script) against a series of MXDs in order to list the data source for each layer or table. In my case, doing it this way yields no results. The code runs in about 2 seconds and then terminates. Any ideas? PYTHON 3 SCRIPT (WRAPPER) import subprocess, os, winreg, sys, arcpy try: arcpy.AddMessage("Finding Python 2.7 installation directory...") hKey = winreg.OpenKey(winreg.HKEY_LOCAL_MACHINE, "SOFTWARE\\WOW6432Node\\Python\\PythonCore\\2.7\\InstallPath") result = winreg.QueryValueEx(hKey, "")[0] except: arcpy.AddWarning("Python 2.7 installation directory was not found.") arcpy.AddError("Script failed.") sys.exit() if os.path.exists(result + "\\python.exe"): arcpy.AddMessage("Launching Python 2.7 executable...") CREATE_NO_WINDOW = 0x8000000 process = subprocess.Popen([result + "\\python.exe", "C:\\temp\\python\\ListMXDDataSources.py"], stdout=subprocess.PIPE, stderr=subprocess.PIPE, creationflags = CREATE_NO_WINDOW, shell=True, stdin=None) stdout, stderr = process.communicate() arcpy.AddMessage('{}'.format(stdout.decode("utf-8"))) arcpy.AddWarning('{}'.format(stderr.decode("utf-8"))) PYTHON 2 SCRIPT import arcpy, glob rootDirectory = 'C:/temp' fileExtension = '.mxd' def main(): for f in glob.glob(rootDirectory + '/*' + fileExtension): mxd = arcpy.mapping.MapDocument(f) for df in arcpy.mapping.ListDataFrames(mxd, ''): for lyr in arcpy.mapping.ListLayers(mxd, '', df): if not lyr.isGroupLayer: if lyr.isRasterLayer: print "Raster Layer, {}".format(lyr) elif lyr.isFeatureLayer: print "Feature Layer, {}, {}".format(lyr, lyr.serviceProperties) else: print "Layer, {}".format(lyr) for tbl in arcpy.mapping.ListTableViews(mxd, '', df): print "Table, {}".format(tbl.dataSource) if __name__ == '__main__': main()
... View more
12-26-2019
11:58 AM
|
2
|
28
|
20358
|
|
POST
|
I have upgraded ArcGIS Enterprise from 10.6 to 10.7.1 recently and noticed that the Portal items are somehow corrupted upon completion of the upgrade. The items have no title or thumbnail. The item properties page just spins and never actually comes up, and opening the item properties from the Sharing Rest site gives a 500 error. Most of these items are map services that reside on the federated Hosting server. Reindexing the content did not help. From within ArcGIS Server, I can see that the map services are behaving just fine. The issue is with the Portal items themselves. Has anyone else experienced this issue or anything similar?
... View more
12-12-2019
03:17 PM
|
2
|
3
|
1385
|
|
POST
|
Jonathan per another post of yours, the following bug is the explanation behind the issue I'm seeing. BUG-000122935 - Unable to create a site or initial administrator account for Portal for ArcGIS 10.7 on a single core machine. I added more cores to our single-core machines and the error went away.
... View more
12-05-2019
12:58 PM
|
0
|
0
|
3684
|
|
POST
|
Adding additional cores to our single-core virtual machines resolved this error for us as Jonathan Quinn suggests via the aforementioned bug.
... View more
12-05-2019
12:54 PM
|
0
|
0
|
2291
|
|
POST
|
I am seeing this exact same error but my servers only contain one NIC and one IP address. Nothing I do will allow the second machine to join the existing Portal. I'm using version 10.7.1.
... View more
12-05-2019
08:18 AM
|
0
|
3
|
3684
|
|
POST
|
I have successfully upgraded my Portal from 10.6.0 to 10.7.1, after which I receive the popup message shown below. I have looked around under the Organization > Settings section of Portal but I am unable to find anything related to "upgrading" the Living Atlas content. Nothing under the 'Items' or 'ArcGIS Online' subsections, and also nothing of relevance under the Portal admin application. Does anyone know how to actually "upgrade" the Living Atlas Content as the popup below suggests?
... View more
12-04-2019
07:38 PM
|
0
|
0
|
666
|
|
POST
|
I'm trying to restore from a backup that was taken from the same environment. Right now, the backup location is set to C:\TEMP but I tried it also using a UNC share path. Same results.
... View more
09-05-2019
02:41 PM
|
0
|
1
|
3631
|
|
POST
|
Verified permissions. Full control for my service account in both directories. Yes, I’m launching this from an admin command prompt.
... View more
09-04-2019
04:42 PM
|
0
|
5
|
3631
|
|
POST
|
When attempting to import a backup using the WEBGISDR tool, I am receiving the error below when it attempts to restore the datastore: Attempt to configure data store failed.. Extended error message: Failed to grant file permission I have double checked the share and NTFS permissions for all directories specified in my properties file. I have tried importing the backup using a shared path and a local path. This is a single-server, development environment with ArcGIS 10.6.0 on Windows 2016. Have a look at the screenshot, too. Has anyone experienced this error before?
... View more
09-04-2019
03:31 PM
|
0
|
7
|
3873
|
|
POST
|
Thanks for replying, Earl. I gave my DB user the db_datareader role but that did not change the behavior. I also tried with db_owner role too, but no luck. After speaking with some folks at Esri last week while at the PUG conference, it looks like they are going to get a case open to troubleshoot this issue and potentially update the documentation (for this version and for previous versions of Insights). The feeling I'm getting, from seeing their reaction to the application behavior, is that we could be looking at at least one bug. I noted a few other issues while talking with them that I did not mention as part of this thread. For example, when updating the relational data store types within the ArcGIS Admin endpoint, Insights does not reflect the changes nor does the corresponding .DAT file get updated on the file system. I'll update again when I have more information.
... View more
05-21-2019
05:45 AM
|
0
|
1
|
1662
|
|
POST
|
According to the Esri documentation, this error is specific to SAP Hana. See below.
... View more
05-15-2019
05:57 AM
|
0
|
1
|
1662
|
|
POST
|
Has anyone been able to get a SQL Server database connection to work in Insights for ArcGIS 3.2.x ? I had no issues connecting to SQL Server databases in version 3.0 and 3.1 (I tried in 3.2.0 and 3.2.1, although 3.2.0 is the only supported version of Insights on my 10.6.1 platform), but after upgrading to version 3.2.x my SQL Server connections stopped working. I also tried re-creating the connections altogether, and even re-installing from scratch after a clean uninstall and file system cleanup. The error I am getting is "Something went wrong. Verify your connection properties, or click here to troubleshoot this" which is actually supposed to be a Hana-specific error within Insights according to this article despite the fact that I'm trying to create a SQL Server connection. This seems like a bug and, if so, a pretty bad one. It is almost as if 3.2.x was never tested against SQL Server. Surely someone would have seen this issue before that version of the software was released. I have even tried re-uploading the JDBC drivers and re-associating their file upload with the respective SQL Server platform under the "Data" section of the ArcGIS Server Admin application. No luck. Connections work fine for Oracle, though. Environment: Portal for ArcGIS 10.6.1 (with 4+ patches) ArcGIS Server 10.6.1 (with 15+ patches) ArcGIS Data Store 10.6.1 Windows Server 2012 R2 SQL Server 2014 SP2 with 10.6.1 Enterprise Geodatabase Side note regarding Oracle database connectivity: In Insights version 3.1, I was unable to connect to an Oracle 11g database (I think the system requirements indicate that only 12c is supported). Strangely enough, in version 3.2.x, I am able to connect to an Oracle 11g database. I'm not sure if this is intended or not.
... View more
05-14-2019
04:19 PM
|
0
|
7
|
2305
|
|
POST
|
I am looking for code (or samples) that would enhance the existing out-of-the-box Draw widget. The functionality I'm aiming for is similar to that found within SnagIt (or some other screenshot tool) where a user could generate callouts that contain custom text. The idea behind this is to have the callout become an additional type of graphic available within the Draw widget alongside rectangle, square, circle, etc. The screenshot/mockup below was provided by one of our users.
... View more
05-07-2019
06:46 AM
|
0
|
1
|
790
|
|
POST
|
The documentation is ambiguous as to where the installation needs to occur, in my opinion. Installing Insights on either the Portal machine OR the Hosting server is not enough. The truth is, Insights needs to be installed in BOTH places: (1) Portal for ArcGIS, and (2) ArcGIS Server (Hosting server). This is assuming your have Portal and ArcGIS Server (Hosting server) on separate machines. As mentioned above, if you are running multiple servers for Portal and/or multiple machines for ArcGIS Server, then the installation needs to occur in all of those places.
... View more
04-15-2019
07:44 AM
|
0
|
0
|
509
|
|
POST
|
Mark, we tested the Beta version and you're right.... it seems to address the observations I presented above. It behaves much better and much more like what we'd expect from a mobile navigation app. Thank you for pointing us in that direction. What is Esri's timeline for replacing the existing Navigator with the current Beta version?
... View more
04-10-2019
12:23 PM
|
0
|
2
|
830
|
| Title | Kudos | Posted |
|---|---|---|
| 2 | 04-05-2014 04:11 PM | |
| 1 | 02-19-2014 11:03 AM | |
| 1 | 04-07-2014 12:32 PM | |
| 1 | 04-03-2019 01:46 PM | |
| 1 | 03-31-2021 04:44 PM |
| Online Status |
Offline
|
| Date Last Visited |
07-13-2025
07:13 PM
|