Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Undefined Cron.Parse #133

Closed
domgolonka opened this issue Jul 18, 2019 · 6 comments
Closed

Undefined Cron.Parse #133

domgolonka opened this issue Jul 18, 2019 · 6 comments

Comments

@domgolonka
Copy link

web_1        | 2019/07/18 18:57:31 ERROR    ▶ 0003 Failed to build the application: # github.com/domgolonka/goexchange/vendor/github.com/gocraft/work
web_1        | vendor/github.com/gocraft/work/worker_pool.go:170:19: undefined: cron.Parse
web_1        | # github.com/domgolonka/goexchange/vendor/github.com/kataras/iris/view
web_1        | vendor/github.com/kataras/iris/view/django.go:225:27: pongo2.RegisterTag(tagName, fn) used as value
web_1        | vendor/github.com/kataras/iris/view/django.go:253:19: undefined: pongo2.NewLocalFileSystemLoader
web_1        | vendor/github.com/kataras/iris/view/django.go:258:22: too many arguments in call to pongo2.NewSet
web_1        | vendor/github.com/kataras/iris/view/django.go:311:22: too many arguments in call to pongo2.NewSet
web_1        | 	have (string, *tDjangoAssetLoader)
web_1        | 	want (string)

I am having trouble with DEP in my docker container when trying to call Work.

@drauschenbach
Copy link

drauschenbach commented Jul 24, 2019

I hacked a workaround in my Gopkg.toml with this:

[[constraint]]
  name = "github.com/gocraft/work"
  version = "v0.5.1"

[[override]]
  name = "github.com/robfig/cron"
  version = "v1.2.0"

@nhaancs
Copy link

nhaancs commented Sep 21, 2019

I hacked a workaround in my Gopkg.toml with this:

[[constraint]]
  name = "github.com/gocraft/work"
  version = "v0.5.1"

[[override]]
  name = "github.com/robfig/cron"
  version = "v1.2.0"

Thanks, that's work, do you know the reason why? @drauschenbach

@drauschenbach
Copy link

@nhaancs sorry no I can't remember, it was too long ago.

@brianmalachiarts
Copy link

I had to track this down too. They released v3 of robfig/cron in June 2019, and it's backwards incompatible with v1 and v2. If your project just runs a go get to use the latest version you'll run into this error. The latest tag to use is the one above, v1.2.0.

They put v3 upgrade tips in the robfig/cron README; maybe someday we can update the work library.

@mitchrodrigues
Copy link
Contributor

This has been driving me absolutely crazy and tired of working around this on our CI so figured id push a PR instead of complaining lol.

hoffoo pushed a commit that referenced this issue Dec 9, 2019
* Get rid of the cron.Parse error

* Fix tests
@hoffoo hoffoo closed this as completed Dec 12, 2019
@caldempsey
Copy link
Contributor

This may have resurfaced. Your latest commit causes worker_pool.go:183:22: undefined: cron.SecondOptional

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants