ashrafhasson
Problems with spacemacs credo and dogma
Hi there,
I’m using credo and dogma in my elixir 1.8 project and spacemacs is giving a hard time where it gives me the following error:
Error from syntax checker elixir-dogma: JSON readtable error: 61
I understand that dogma is not required for elixir 1.6+ so I tried to remove and I get the following crash in spacemacs whenever flycheck tries to run in a buffer:
Suspicious state from syntax checker elixir-credo: Flycheck checker elixir-credo returned non-zero exit code 1, but its output contained no errors: =SUPERVISOR REPORT==== 8-Feb-2019::10:05:36.301437 ===
supervisor: {local,'Elixir.Logger.Supervisor'}
errorContext: start_error
reason: noproc
offender: [{pid,undefined},
{id,'Elixir.Logger.ErrorHandler'},
{mfargs,
{'Elixir.Logger.Watcher',watcher,
[error_logger,'Elixir.Logger.ErrorHandler',
{true,false,500},
link]}},
{restart_type,permanent},
{shutdown,5000},
{child_type,worker}]
=CRASH REPORT==== 8-Feb-2019::10:05:36.301346 ===
crasher:
initial call: Elixir.Logger.Watcher:init/1
pid: <0.89.0>
registered_name: []
exception exit: noproc
in function gen:do_for_proc/2 (gen.erl, line 228)
in call from gen_event:rpc/2 (gen_event.erl, line 239)
in call from 'Elixir.Logger.Watcher':init/1 (lib/logger/watcher.ex, line 66)
in call from gen_server:init_it/2 (gen_server.erl, line 374)
in call from gen_server:init_it/6 (gen_server.erl, line 342)
ancestors: ['Elixir.Logger.Supervisor',<0.83.0>]
message_queue_len: 0
messages: []
links: [<0.84.0>]
dictionary: []
trap_exit: false
status: running
heap_size: 376
stack_size: 27
reductions: 253
neighbours:
=CRASH REPORT==== 8-Feb-2019::10:05:36.323862 ===
crasher:
initial call: application_master:init/4
pid: <0.82.0>
registered_name: []
exception exit: {{shutdown,
{failed_to_start_child,'Elixir.Logger.ErrorHandler',
noproc}},
{'Elixir.Logger.App',start,[normal,[]]}}
in function application_master:init/4 (application_master.erl, line 138)
ancestors: [<0.81.0>]
message_queue_len: 1
messages: [{'EXIT',<0.83.0>,normal}]
links: [<0.81.0>,<0.43.0>]
dictionary: []
trap_exit: true
status: running
heap_size: 376
stack_size: 27
reductions: 193
neighbours:
=INFO REPORT==== 8-Feb-2019::10:05:36.326731 ===
application: logger
exited: {{shutdown,
{failed_to_start_child,'Elixir.Logger.ErrorHandler',noproc}},
{'Elixir.Logger.App',start,[normal,[]]}}
type: temporary
** (Version.InvalidRequirementError) ~> 1.0
(elixir) lib/version.ex:159: Version.match?/3
(mix) lib/mix/local.ex:100: Mix.Local.check_elixir_version_in_ebin/1
(elixir) lib/enum.ex:651: Enum."-each/2-lists^foreach/1-0-"/2
(elixir) lib/enum.ex:651: Enum.each/2
(mix) lib/mix/local.ex:50: Mix.Local.append_archives/0
(mix) lib/mix/cli.ex:8: Mix.CLI.main/1
Try installing a more recent version of elixir-credo, and please open a bug report if the issue persists in the latest release. Thanks!
Any idea on how to get over this, please?
Marked As Solved
axelson
Hmmm, how is elixir installed? Maybe spacemacs is picking up a global installation of Elixir that is different than the version you are getting at the command line.
Also Liked
ashrafhasson
mix credo runs fine! It’s just when run in Spacemacs that I get the errors mentioned.
NobbZ
Which version of elixir and erlang are you running exactly?
This looks like some known bugs that pop up here every now and then and depend on the exact versions of erlang and elixir.
ashrafhasson
I should have included this in my original post! ![]()
Erlang/OTP 21 [erts-10.2] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] [hipe]
Elixir 1.8.1 (compiled with Erlang/OTP 21)
Emacs 26.1
Spacemacs 0.200.13
also, I’m using the following credo and dogma in my mix.exs:
{:credo, “~> 1.0.0”, only: [:dev, :test], runtime: false},
{:dogma, “~> 0.1”, only: [:dev]}
Thanks!
Popular in Questions
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #advent-of-code
- #elixirconf-us
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #performance









