CodeStats.CacheXP model does not exists
The model CodeStats.CacheXP
does not exists, when receiving a pulse i got an exception:
** (exit) an exception was raised:
** (UndefinedFunctionError) function CodeStats.CachedXP.__schema__/1 is undefined (module CodeStats.CachedXP is not available)
CodeStats.CachedXP.__schema__(:primary_key)
(ecto) lib/ecto/changeset/relation.ex:361: Ecto.Changeset.Relation.primary_keys!/1
(ecto) lib/ecto/changeset/relation.ex:125: Ecto.Changeset.Relation.change/3
(ecto) lib/ecto/repo/schema.ex:426: anonymous fn/4 in Ecto.Repo.Schema.surface_changes/4
(elixir) lib/enum.ex:1623: Enum."-reduce/3-lists^foldl/2-0-"/3
(ecto) lib/ecto/repo/schema.ex:413: Ecto.Repo.Schema.surface_changes/4
(ecto) lib/ecto/repo/schema.ex:170: Ecto.Repo.Schema.do_insert/4
(code_stats) web/controllers/pulse_controller.ex:127: CodeStats.PulseController.get_or_create_language/1
(code_stats) web/controllers/pulse_controller.ex:99: CodeStats.PulseController.create_xp/3
(code_stats) web/controllers/pulse_controller.ex:86: anonymous fn/2 in CodeStats.PulseController.create_xps/2
(elixir) lib/enum.ex:1184: Enum."-map/2-lists^map/1-0-"/2
(code_stats) web/controllers/pulse_controller.ex:84: CodeStats.PulseController.create_xps/2
(code_stats) web/controllers/pulse_controller.ex:30: CodeStats.PulseController.add/2
(code_stats) web/controllers/pulse_controller.ex:1: CodeStats.PulseController.action/2
(code_stats) web/controllers/pulse_controller.ex:1: CodeStats.PulseController.phoenix_controller_pipeline/2
(code_stats) lib/code_stats/endpoint.ex:1: CodeStats.Endpoint.instrument/4
(code_stats) lib/phoenix/router.ex:261: CodeStats.Router.dispatch/2
(code_stats) web/router.ex:1: CodeStats.Router.do_call/2
(code_stats) lib/code_stats/endpoint.ex:1: CodeStats.Endpoint.phoenix_pipeline/1
(code_stats) lib/plug/debugger.ex:93: CodeStats.Endpoint."call (overridable 3)"/2
I believe the source is: https://github.com/Nicd/code-stats/blob/master/web/models/language.ex#L8