Error 500 when creating epic: null value in column "state" violates not-null constraint

On my EE master, I uploaded a new EEP license and then tried to create an epic but failed:

Started POST "/groups/twitter/-/epics" for 127.0.0.1 at 2017-12-30 13:31:37 -0800
  Group Load (0.6ms)  SELECT  "namespaces".* FROM "namespaces" INNER JOIN "routes" ON "routes"."source_id" = "namespaces"."id" AND "routes"."source_type" = $1 WHERE "namespaces"."type" IN ('Group') AND ((LOWER(routes.path) = LOWER('twitter')))  ORDER BY (CASE WHEN  routes.path = 'twitter' THEN 0 ELSE 1 END) LIMIT 1  [["source_type", "Namespace"]]
Processing by Groups::EpicsController#create as JSON
  Parameters: {"title"=>"test-epic", "group_id"=>"twitter", "epic"=>{"title"=>"test-epic"}}
  User Load (0.2ms)  SELECT  "users".* FROM "users" WHERE "users"."id" = $1  ORDER BY "users"."id" ASC LIMIT 1  [["id", 1]]
  Identity Exists (0.1ms)  SELECT  1 AS one FROM "identities" WHERE "identities"."user_id" = $1 AND (provider LIKE 'ldap%' AND extern_uid IS NOT NULL) LIMIT 1  [["user_id", 1]]
  CACHE (0.1ms)  SELECT  "namespaces".* FROM "namespaces" INNER JOIN "routes" ON "routes"."source_id" = "namespaces"."id" AND "routes"."source_type" = $1 WHERE "namespaces"."type" IN ('Group') AND ((LOWER(routes.path) = LOWER('twitter')))  ORDER BY (CASE WHEN  routes.path = 'twitter' THEN 0 ELSE 1 END) LIMIT 1  [["source_type", "Namespace"]]
  License Load (0.3ms)  SELECT  "licenses".* FROM "licenses"  ORDER BY "licenses"."id" DESC LIMIT 1
   (0.1ms)  BEGIN
   (0.2ms)  SELECT MAX("epics"."iid") FROM "epics" WHERE "epics"."group_id" = $1  [["group_id", 4]]
  SQL (0.8ms)  INSERT INTO "epics" ("title", "group_id", "author_id", "iid", "created_at", "updated_at", "title_html", "description_html", "cached_markdown_version") VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9) RETURNING "id"  [["title", "test-epic"], ["group_id", 4], ["author_id", 1], ["iid", 1], ["created_at", "2017-12-30 21:31:37.371502"], ["updated_at", "2017-12-30 21:31:37.371502"], ["title_html", "test-epic"], ["description_html", ""], ["cached_markdown_version", 3]]
   (0.1ms)  ROLLBACK
Completed 500 Internal Server Error in 18ms (ActiveRecord: 1.9ms | Elasticsearch: 0.0ms)

PG::NotNullViolation - ERROR:  null value in column "state" violates not-null constraint
DETAIL:  Failing row contains (4, 1, test-epic, test-epic, null, , 1, 4, null, null, null, 3, 2017-12-30 21:31:37.371502+00, 2017-12-30 21:31:37.371502+00).
:
  peek-pg (1.3.0) lib/peek/views/pg.rb:26:in `exec_prepared'
  activerecord (4.2.10) lib/active_record/connection_adapters/postgresql_adapter.rb:602:in `block in exec_cache'
  activerecord (4.2.10) lib/active_record/connection_adapters/abstract_adapter.rb:484:in `block in log'
  activesupport (4.2.10) lib/active_support/notifications/instrumenter.rb:20:in `instrument'
  activerecord (4.2.10) lib/active_record/connection_adapters/abstract_adapter.rb:478:in `log'
  activerecord (4.2.10) lib/active_record/connection_adapters/postgresql_adapter.rb:601:in `exec_cache'
  activerecord (4.2.10) lib/active_record/connection_adapters/postgresql_adapter.rb:585:in `execute_and_clear'
  activerecord (4.2.10) lib/active_record/connection_adapters/postgresql/database_statements.rb:160:in `exec_query'
  activerecord (4.2.10) lib/active_record/connection_adapters/postgresql/database_statements.rb:192:in `exec_insert'
  activerecord (4.2.10) lib/active_record/connection_adapters/abstract/database_statements.rb:108:in `insert'
  activerecord (4.2.10) lib/active_record/connection_adapters/abstract/query_cache.rb:14:in `insert'
  activerecord (4.2.10) lib/active_record/relation.rb:64:in `insert'
  activerecord (4.2.10) lib/active_record/persistence.rb:524:in `_create_record'
  activerecord (4.2.10) lib/active_record/counter_cache.rb:139:in `_create_record'
  config/initializers/active_record_locking.rb:12:in `_create_record'
  activerecord (4.2.10) lib/active_record/attribute_methods/dirty.rb:133:in `_create_record'
  activerecord (4.2.10) lib/active_record/callbacks.rb:306:in `block in _create_record'
  activesupport (4.2.10) lib/active_support/callbacks.rb:117:in `call'
Edited Dec 30, 2017 by Stan Hu
Assignee Loading
Time tracking Loading