fredwu / crawler

A high performance web crawler / scraper in Elixir.
939 stars 91 forks source link

** (ArgumentError) invalid syntax, only "retry", "after" and "else" are permitted #18

Closed simonbowen closed 6 years ago

simonbowen commented 6 years ago

It seems as though by updating the ElixirRetry package it has introduced an issue. I cannot add this project to my mix.exs and run

iex -S mix

without receiving this error

== Compilation error in file lib/crawler/fetcher/retrier.ex ==
** (ArgumentError) invalid syntax, only "retry", "after" and "else" are permitted
    expanding macro: Retry.retry/2
    lib/crawler/fetcher/retrier.ex:25: Crawler.Fetcher.Retrier.perform/2
    (elixir) lib/kernel/parallel_compiler.ex:198: anonymous fn/4 in Kernel.ParallelCompiler.spawn_workers/6
fredwu commented 6 years ago

This is already fixed in fedd5a0c27b345d1db5061304c9b7fdcdfea887c. If you are using the released version you can lock ElixirRetry to v0.9. :)

kdiogenes commented 5 years ago

@fredwu I don't understand your instructions. I tried to add {:retry, "0.9.0"} and {:retry, "0.9.1"}, but still getting the same error. Can you give more direct instructions? Thanks!

kdiogenes commented 5 years ago

I used {:crawler, github: "fredwu/crawler"} and now it's compile successful.