<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <p>In the staff interface, go to System > Manage Controlled Value
      Lists. Then select "Name Rule (name_rule)" from the List Name
      drop-down. If that list doesn't have a value of "local", or that
      value has been suppressed, that could be the cause of your
      problem.</p>
    <p>The issue is that creating system users also creates an
      (unpublished) agent record. So, if you've suppressed local rules
      for the naming of persons in your metadata, it'll won't be able to
      create the agent, so it won't be able to create the user either.</p>
    <p>Andrew.</p>
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 22/11/2022 11:22, Philip Webster
      wrote:<br>
    </div>
    <blockquote type="cite" cite="mid:00a601d8fe64$c6ae3540$540a9fc0$@sheffield.ac.uk">
      
      <meta name="Generator" content="Microsoft Word 15 (filtered
        medium)">
      <style>@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}@font-face
        {font-family:"Helvetica Neue";
        panose-1:0 0 0 0 0 0 0 0 0 0;}@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}@font-face
        {font-family:"Segoe UI Symbol";
        panose-1:2 11 5 2 4 2 4 2 2 3;}p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}code
        {mso-style-priority:99;
        font-family:"Courier New";}span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri",sans-serif;
        color:windowtext;}.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri",sans-serif;
        mso-fareast-language:EN-US;}div.WordSection1
        {page:WordSection1;}</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
      <div class="WordSection1">
        <p class="MsoNormal">Hi,<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">I’m the admin for ArchivesSpace at the
          University of Sheffield, in the UK. We’ve had ArchivesSpace
          since version 2.7, and we currently run 2.8.1 with plans to
          move to 3.2.0 within the next month.<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">During our initial setup and launch, a
          number of user accounts were created for our permanent
          archival, metadata and technical staff. Since then we have had
          two new members of staff who qualified for ArchivesSpace
          accounts on our local system.<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">Unfortunately, it hasn’t been possible to
          create these accounts due to an issue in the staff user
          interface. I have populated the fields on the user form, and
          this is always done using the ‘admin’ account. When the form
          is submitted, the response is as follows:<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p style="margin:0cm"><span style="font-size:10.5pt;font-family:"Helvetica
            Neue",serif;color:#A94442">Invalid value 'local'. Must
            be one of 'ISAAR (CPF) and NCA Rules'<o:p></o:p></span></p>
        <p style="mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:15.0pt;margin-left:0cm"><span style="font-size:10.5pt;font-family:"Helvetica
            Neue",serif;color:#A94442">User not created<o:p></o:p></span></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">Looking at the logs, I see that the
          frontend is sending the following data to the server (response
          lines are also shown, sensitive information redacted):<o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:11.671710 #98122]  INFO -- : Started
              POST "/users" for REDACTED-IP at 2022-11-17 17:45:11 +0000</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:11.822783 #98122]  INFO -- : Processing
              by UsersController#create as HTML</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:11.823274 #98122]  INFO -- :  
              Parameters: {"utf8"=>"</span></code><code><span style="font-size:10.0pt;font-family:"Segoe UI
              Symbol",sans-serif">✓</span></code><code><span style="font-size:10.0pt;font-family:Consolas">",
              "authenticity_token"=>"REDACTED",
              "user"=>{"lock_version"=>"",
              "username"=>"testuser_t", "name"=>"testuser",
              "email"=><a class="moz-txt-link-abbreviated" href="mailto:dummy@sheffield.ac.uk">dummy@sheffield.ac.uk</a>,
              "first_name"=>"test", "last_name"=>"user",
              "telephone"=>"", "title"=>"",
              "department"=>"Library", "additional_contact"=>"",
              "password"=>"[FILTERED]",
              "confirm_password"=>"[FILTERED]",
              "is_active_user"=>"1"}}</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">D,
              [2022-11-17T17:45:12.171371 #98122] DEBUG -- :
              Thread-3254: POST /users?repo_id=2&password=[FILTERED]
              [session: #<Session:REDACTED @store={:user=>"admin",
              :login_time=>2022-11-17 17:15:54 +0000,
              :expirable=>true}, @system_mtime=2022-11-17 17:44:46
              UTC, @id="REDACTED">]</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">D,
              [2022-11-17T17:45:12.185350 #98122] DEBUG -- :
              Thread-3254: Post-processed params:
              {"password"=>"[FILTERED]",
              "user"=>#<JSONModel(:user)
              {"username"=>"testuser_t", "name"=>"testuser",
              "email"=><a class="moz-txt-link-abbreviated" href="mailto:dummy@sheffield.ac.uk">dummy@sheffield.ac.uk</a>,
              "first_name"=>"test", "last_name"=>"user",
              "department"=>"Library", "is_active_user"=>true,
              "is_admin"=>false, "jsonmodel_type"=>"user",
              "groups"=>[]}>}</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">D,
              [2022-11-17T17:45:12.252354 #98122] DEBUG -- :
              Thread-3254: Responded with [400,
              {"Content-Type"=>"application/json",
              "Cache-Control"=>"private, must-revalidate, max-age=0",
              "Content-Length"=>"424"}, ["{\"error\":{\"rules\":[\"<span style="background:yellow;mso-highlight:yellow">Invalid
                value 'local'.  Must be one of: ISAAR (CPF) and NCA
                Rules\</span>"]},\"warning\":{},\"invalid_object\":\"#<JSONModel(:name_person)
              {</span></code><code><span style="font-family:Consolas">\\\"primary_name\\\"=>\\\"testuser</span></code><code><span style="font-size:10.0pt;font-family:Consolas">\\\", </span></code><code><span style="font-family:Consolas">\\\"source\\\"=>\\\"local\\\</span></code><code><span style="font-size:10.0pt;font-family:Consolas">", </span></code><code><span style="font-family:Consolas">\\\"rules\\\"=>\\\"<span style="background:yellow;mso-highlight:yellow">local</span>\\\</span></code><code><span style="font-size:10.0pt;font-family:Consolas">", </span></code><code><span style="font-family:Consolas">\\\"name_order\\\"=>\\\"direct\\\</span></code><code><span style="font-size:10.0pt;font-family:Consolas">", </span></code><code><span style="font-family:Consolas">\\\"sort_name_auto_generate\\\"=>true</span></code><code><span style="font-size:10.0pt;font-family:Consolas">, </span></code><code><span style="font-family:Consolas">\\\"use_dates\\\"=</span></code><code><span style="font-size:10.0pt;font-family:Consolas">>[], </span></code><code><span style="font-family:Consolas">\\\"authorized\\\"=>true</span></code><code><span style="font-size:10.0pt;font-family:Consolas">... in 83ms</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.307673 #98122]  INFO -- :   Rendering
              users/new.html.erb within layouts/application</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.383514 #98122]  INFO -- :   Rendered
              shared/_breadcrumb.html.erb (38.6ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.385550 #98122]  INFO -- :   Rendered
              users/_toolbar.html.erb (0.3ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.434052 #98122]  INFO -- :   Rendered
              shared/_flash_messages.html.erb (31.9ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.434746 #98122]  INFO -- :   Rendered
              shared/_form_messages.html.erb (33.4ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.639900 #98122]  INFO -- :   Rendered
              users/_form.html.erb (232.9ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.645463 #98122]  INFO -- :   Rendered
              users/new.html.erb within layouts/application (329.1ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.769050 #98122]  INFO -- :   Rendered
              shared/_header_user.html.erb (69.8ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.777940 #98122]  INFO -- :   Rendered
              shared/_header_global.html.erb (87.0ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:12.781522 #98122]  INFO -- :   Rendered
              site/_branding.html.erb (0.5ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:13.045561 #98122]  INFO -- :   Rendered
              shared/_advanced_search.html.erb (25.5ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:13.105096 #98122]  INFO -- :   Rendered
              shared/_header_repository.html.erb (322.2ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:13.110247 #98122]  INFO -- :   Rendered
              site/_footer.html.erb (0.5ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:13.139762 #98122]  INFO -- :   Rendered
              shared/_templates.html.erb (24.2ms)</span></code><o:p></o:p></p>
        <p><code><span style="font-size:10.0pt;font-family:Consolas">I,
              [2022-11-17T17:45:13.167381 #98122]  INFO -- : Completed
              200 OK in 1343ms (Views: 857.1ms)</span></code><o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">I’ve tested this on a dev server with a
          backup of our production database, with the ArchivesSpace code
          replaced with stock builds of 2.8.1 and 3.2.0 from GitHub,
          using a near-default config that only had the changes
          necessary to allow connection to MySQL and to specify the
          PUI/SUI URLs. In these cases the problem still occurs.<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">I have also tried dropping the entire
          database and created a fresh set of tables (without data)
          using the database setup script. This seems to work. Thus I
          conclude that something in the database affects the operation
          of the user creation component, and this is independent from
          the config file or code.<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">The key issue is that a value of ‘local’ is
          being passed, and the error message is telling me that it
          should instead <code><span style="font-size:10.0pt;font-family:Consolas">"Must be one
              of: ISAAR (CPF) and NCA Rules”.</span></code><o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">What do I need to do to get rid of the
          ‘local’ value that is being passed and to get the correct
          value instead?<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">Regards,<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">Philip Webster<o:p></o:p></p>
        <p class="MsoNormal">The University Library<o:p></o:p></p>
        <p class="MsoNormal">University of Sheffield<o:p></o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal"><o:p> </o:p></p>
      </div>
      <br>
      <fieldset class="moz-mime-attachment-header"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
Archivesspace_Users_Group mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Archivesspace_Users_Group@lyralists.lyrasis.org">Archivesspace_Users_Group@lyralists.lyrasis.org</a>
<a class="moz-txt-link-freetext" href="http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group">http://lyralists.lyrasis.org/mailman/listinfo/archivesspace_users_group</a>
</pre>
    </blockquote>
  </body>
</html>