Hello, I try to update a metadata for a feature layer using an existing xml file in NAP format.
from arcgis.gis import GIS
portal = GIS(url = "https://my_url/portal/sharing/rest/", username="my_username", password="my_password")
m = portal.content.get("6da6a005f3094d9a8ad9f4765dac8bd2")
l=m.layers[0]
r = l.update_metadata("metadata.xml")
But I get an exception raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0) when it gets to update_metadata function.
is it possible to update layers metadata with nap in portal?
Hi,
Are you referencing the path to the "metadata.xml" correct? Have you tried using a full path the to file, eg. "C:\path\to\folder\metadata.xml"