POST
|
yes propy.bat works as well. Forgot to mention that I have activated my clone env and then use the alias in bash.
... View more
02-18-2022
10:04 AM
|
0
|
0
|
2429
|
POST
|
Hi Gary, One way that I use is to define an alias in ".bashrc" file for python3 interpreter. If you have a clone python environment point the alias to that python env. alias python3='C:/Users/asharaf/AppData/Local/ESRI/conda/envs/arcgispro-py3-clone/python.exe' and then in bash use python3 command. Let me know if it works in your environment.
... View more
02-18-2022
09:49 AM
|
0
|
7
|
2432
|
POST
|
that is correct. providerGroupName returns None. another way to get the providerGroupName using SAML is: - get the group id using groupid properties - build this url: group_url = f"https://portal_url/webadaptor/sharing/rest/community/groups/{group_id}" - using urllib find the ProviderGroupName tag value from response.
... View more
01-27-2022
11:08 AM
|
1
|
0
|
808
|
POST
|
- what is the output of arcpy.env.scratchFolder when you run it with arcgis server service account? - haven't you missed a single quote in the WHERE clause?
... View more
01-26-2022
01:06 PM
|
0
|
0
|
789
|
IDEA
|
I talked to esri support and the Enhancement is in Product plan.
... View more
01-21-2022
09:33 AM
|
0
|
0
|
575
|
POST
|
and this is the bug's information: https://my.esri.com/#/support/bugs/BUG-000145120
... View more
01-20-2022
08:19 AM
|
0
|
0
|
1107
|
POST
|
do you need a modified sddraft as an output file? Can you use this? out_file=r"C:\Users\arcgis\out.sddraft"
... View more
01-19-2022
10:23 AM
|
0
|
1
|
725
|
POST
|
use xml.dom.minidom instead. This is code snippet I used to modify the service definition file. You can tweak it based on your needs. import xml.dom.minidom as dom
doc = dom.parse(sddraft_output_filename)
# Find all elements named TypeName. This is where the server object extension
# (SOE) names are defined.
typeNames = doc.getElementsByTagName('TypeName')
for typeName in typeNames:
# Get the TypeName we want to enable.
if typeName.firstChild.data == "FeatureServer":
extension = typeName.parentNode
for extElement in extension.childNodes:
# Enable Feature Access.
if extElement.tagName == 'Enabled':
extElement.firstChild.data = 'true'
# Output to a new sddraft.
sddraft_mod_xml = service + '_mod_xml' + '.sddraft'
sddraft_mod_xml_file = os.path.join(sddraft_folder, sddraft_mod_xml)
f = open(sddraft_mod_xml_file, 'w')
doc.writexml(f)
f.close()
... View more
01-19-2022
09:30 AM
|
0
|
1
|
729
|
POST
|
we had same issue with orphan lock and the following workaround from Esri Support fixed it. Make sure you have a full backup before applying any change. First (if possible), we may just need to restart SQL Server and see if the orphan locks disappear. If you want to test restarting server, you will need to right click the Instance in SSMS > Restart. Please keep in mind restarting server may affect users who are connected and editing at the time. Please capture a full back up in SSMS. It is important to have the backup created before attempting to truncate the 'table_locks' table. After our first compression, we can verify if the the orphan records are still appearing in the 'SDE_table_locks' table. Additionally, the' SDE_layer_locks', 'SDE_obect_locks', and SDE_state_locks' should be empty. Next, we can attempt to truncate the 'SDE_table_locks' table. After running the query in SSMS, we can verify if the orphan locks are still appearing within the ArcGIS Administration Dialog. Please note: verify all services are stopped (if applicable) and that no users are connected or editing before running the query. TRUNCATE TABLE sde.SDE_table_locks; Afterwards, attempt to compress the geodatabase again and see if our end_state_count is now 1 within the Compress_Log table. Reference Image:
... View more
12-22-2021
12:54 PM
|
0
|
1
|
2453
|
POST
|
why updateConnectionProperties on aprx file (not lyr) didn't work? in your code print(lyr) in the for loop to see which lyr is making problem. I am guessing it doesn't like Esri basemap layers.
... View more
12-22-2021
10:13 AM
|
0
|
1
|
1888
|
POST
|
i can't reproduce the error. Maybe a re-install will fix it. my test was on ArcGIS Pro 2.9 and ArcGIS module 1.9.1.
... View more
12-22-2021
09:36 AM
|
0
|
0
|
2040
|
DOC
|
by "clone 2.7" I mean install virtualenv on default python2.x and create a new venv: C:\Python27\ArcGISx6410.8\python.exe -m virtualenv py27-clone-108 and then copying PTH files to the new venv folder and then activate it. It works on my machine.
... View more
12-22-2021
09:29 AM
|
0
|
0
|
9900
|
DOC
|
I don't see a major benefit of having python 2.x in pycharm terminal but you can do it with the following workflow. 1- clone python 2.7 environment 2- in the Pycharm terminal path enter: C:\Windows\System32\cmd.exe /k "C:\Python27\envs\py27-clone-1081\Scripts\activate.bat" then your Terminal would be like this:
... View more
12-21-2021
05:10 PM
|
0
|
0
|
9914
|
POST
|
As Dan mentioned this function should work. def remap_arcgis_pro(source_aprx, target_aprx, source_sde_conn, target_sde_conn):
arcpy.AddMessage("Remapping ArcGIS Pro...")
aprx = arcpy.mp.ArcGISProject(source_aprx)
aprx.updateConnectionProperties(current_connection_info=source_sde_conn,
new_connection_info=target_sde_conn)
aprx.saveACopy(target_aprx)
return target_aprx
... View more
12-21-2021
04:43 PM
|
2
|
5
|
1925
|
Title | Kudos | Posted |
---|---|---|
1 | 07-20-2023 01:51 PM | |
1 | 06-27-2023 10:32 PM | |
1 | 10-26-2022 03:52 PM | |
1 | 03-17-2022 03:42 PM | |
4 | 06-16-2022 04:31 PM |
Online Status |
Offline
|
Date Last Visited |
Thursday
|