<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">And maybe send the resulting XML or at least diffs of the two.<div class="">( Guessing that there might be a mismatch of file encoding and xml encoding declaration. ) </div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Mar 27, 2020, at 3:02 PM, Mayo, Dave <<a href="mailto:dave_mayo@harvard.edu" class="">dave_mayo@harvard.edu</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="WordSection1" style="page: WordSection1; caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 16px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;"><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">Can you be more precise about what “directly from the archivesspace” means? What page (URL) and control on the page you’re using to generate this? I want to make sure it’s the same code path in both cases.<br class=""><br class="">Also, when you say “locally,” do you just mean the script is running locally against the same ASpace instance, or is it a different ASpace instance from the one where you’re getting correct results?<o:p class=""></o:p></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">--<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">Dave Mayo (he/him)<o:p class=""></o:p></div></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">Senior Digital Library Software Engineer<br class="">Harvard University > HUIT > LTS<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><o:p class=""> </o:p></div><div style="border-style: solid none none; border-top-width: 1pt; border-top-color: rgb(181, 196, 223); padding: 3pt 0in 0in;" class=""><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><b class=""><span style="font-size: 12pt;" class="">From:<span class="Apple-converted-space"> </span></span></b><span style="font-size: 12pt;" class=""><<a href="mailto:archivesspace_users_group-bounces@lyralists.lyrasis.org" style="color: rgb(149, 79, 114); text-decoration: underline;" class="">archivesspace_users_group-bounces@lyralists.lyrasis.org</a>> on behalf of "Kennedy, Nancy" <<a href="mailto:KennedyN@si.edu" style="color: rgb(149, 79, 114); text-decoration: underline;" class="">KennedyN@si.edu</a>><br class=""><b class="">Reply-To:<span class="Apple-converted-space"> </span></b>Archivesspace Users Group <<a href="mailto:archivesspace_users_group@lyralists.lyrasis.org" style="color: rgb(149, 79, 114); text-decoration: underline;" class="">archivesspace_users_group@lyralists.lyrasis.org</a>><br class=""><b class="">Date:<span class="Apple-converted-space"> </span></b>Friday, March 27, 2020 at 1:41 PM<br class=""><b class="">To:<span class="Apple-converted-space"> </span></b>"Archivesspace Users Group (<a href="mailto:archivesspace_users_group@lyralists.lyrasis.org" style="color: rgb(149, 79, 114); text-decoration: underline;" class="">archivesspace_users_group@lyralists.lyrasis.org</a>)" <<a href="mailto:archivesspace_users_group@lyralists.lyrasis.org" style="color: rgb(149, 79, 114); text-decoration: underline;" class="">archivesspace_users_group@lyralists.lyrasis.org</a>><br class=""><b class="">Subject:<span class="Apple-converted-space"> </span></b>[Archivesspace_Users_Group] EAD via API - character problem<o:p class=""></o:p></span></div></div><div class=""><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><o:p class=""> </o:p></div></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">Hi all –<span class="Apple-converted-space"> </span><o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">Today I noticed that if I export an EAD with “Yin-Hsü” directly from the archivesspace, my EAD results carry through with the correct encoding. <o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""> <o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">But, when I export locally via the API, I end up with “Yin-Hs<span style="font-family: "MS Gothic";" class="">端</span>”. I’m using python 3.7.4, via local windows machine. I’ve tried both archivessnake and just using requests, but I still end up with<span class="Apple-converted-space"> </span><span style="font-family: "MS Gothic";" class="">端.</span><o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: "MS Gothic";" class=""> </span><o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">Suggestions? Here’s what I’m doing via asnake:<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""> <o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; text-indent: 0.5in;" class="">export_options = '?include_daos=true&?include_unpublished=false&?numbered_cs=false'<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; text-indent: 0.5in;" class="">for i in resource_ids:<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif; text-indent: 0.5in;" class="">ead = client.get(repo['uri']<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; text-indent: 0.5in;" class=""> +'/resource_descriptions/'+str(i)+'.xml'<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; text-indent: 0.5in;" class=""> + export_options).text<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""> <o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">Nancy Kennedy<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">Smithsonian Institution<o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><a href="mailto:kennedyn@si.edu" style="color: rgb(149, 79, 114); text-decoration: underline;" class="">kennedyn@si.edu</a><o:p class=""></o:p></div><div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""> <o:p class=""></o:p></div></div><span style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 16px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">_______________________________________________</span><br style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 16px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><span style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 16px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">Archivesspace_Users_Group mailing list</span><br style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 16px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><a href="mailto:Archivesspace_Users_Group@lyralists.lyrasis.org" style="color: rgb(149, 79, 114); text-decoration: underline; font-family: Menlo-Regular; font-size: 16px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">Archivesspace_Users_Group@lyralists.lyrasis.org</a><br style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 16px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><a href="http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group" style="color: rgb(149, 79, 114); text-decoration: underline; font-family: Menlo-Regular; font-size: 16px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" class="">http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group</a></div></blockquote></div><br class=""></div></div></body></html>