graph-gophers / dataloader

Implementation of Facebook's DataLoader in Golang
MIT License
1.21k stars 75 forks source link

Go Modules Support #65

Closed AttilaTheFun closed 4 years ago

AttilaTheFun commented 4 years ago

Right now I can technically use this library with projects using go modules, but because it doesn't have a go module initialized, we see:

github.com/graph-gophers/dataloader v5.0.0+incompatible

I'm not sure if all the semver / module guarantees are properly respected for non-module-based projects. Could I add go.mod / go.sum files to the repo? Happy to open a PR. I could also fork the repo and keep them in my fork if you prefer.

tonyghita commented 4 years ago

I think this is a good idea. It's a bit more complicated for any module above version 1.0, and unfortunately we had quite a few API changes after the initial version.

I'll be happy to accept a PR to initialize this Go module. I'll do a bit of reading as well ton ensure the changes work well for any consumers: https://github.com/golang/go/wiki/Modules#releasing-modules-v2-or-higher

AttilaTheFun commented 4 years ago

@tonyghita - Joost beat me to it - would you be open accepting their PR?