There appears to be no max length for usernames

A customer asked "How long can you make a GL username?" - https://gitlab.zendesk.com/agent/tickets/84963

I attempted to just make a super long one for fun vs. verifying the limit in code:

Processing by RegistrationsController#create as HTML
  Parameters: {"utf8"=>"✓", "authenticity_token"=>"[FILTERED]", "new_user"=>{"name"=>"testing name", "username"=>"howlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitit", "email"=>"testing3@password.example.org", "email_confirmation"=>"testing3@password.example.org", "password"=>"[FILTERED]"}}
Redirected to 
Completed 500 Internal Server Error in 364ms (ActiveRecord: 6.7ms | Elasticsearch: 0.0ms)

NoMethodError (undefined method `users_url' for #<RegistrationsController:0x00007f8877d61f80>
Did you mean?  user_url):
  app/controllers/registrations_controller.rb:18:in `create'
  lib/gitlab/i18n.rb:47:in `with_locale'
  lib/gitlab/i18n.rb:53:in `with_user_locale'
  app/controllers/application_controller.rb:349:in `set_locale'
  lib/gitlab/middleware/multipart.rb:93:in `call'
  lib/gitlab/request_profiler/middleware.rb:14:in `call'
  lib/gitlab/jira/middleware.rb:15:in `call'
  lib/gitlab/middleware/go.rb:17:in `call'
  lib/gitlab/etag_caching/middleware.rb:11:in `call'
  lib/gitlab/middleware/read_only.rb:30:in `call'
  lib/gitlab/request_context.rb:18:in `call'
  lib/gitlab/metrics/requests_rack_middleware.rb:27:in `call'

We just 500 vs. showing the limit. I looked in the user model and didn't see anything. I was also able to make a user with the following username howlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitithowlongcanImakeausernamewhatisthelimititisprobabablyprettylongrightIthinksowillIhitit so 170 characters works, but not sure how much longer breaks. I spent more than 15 minutes fighting with the API on my test instance to try and auto-generate users to find the max. I'm sure a Dev can whip it up.

Assignee Loading
Time tracking Loading