luckylittle / dzone-refcardz-downloader

Downloads all refcardz from https://dzone.com/refcardz
MIT License
19 stars 3 forks source link

gocolly dependencies failing #4

Open srinisubra opened 5 years ago

srinisubra commented 5 years ago

Hi there, first of a ll, thank you for sharing the code. I am new to GO and trying to use your dzone-refcardz-downloader. Trying to install gocolly by issuing go get -u -v github.com/gocolly/colly/...

But getting the below error. Do you have any suggestion?

github.com/jawher/mow.cli (download) github.com/gocolly/colly

github.com/gocolly/colly

src/github.com/gocolly/colly/colly.go:502: parsedURL.Hostname undefined (type url.URL has no field or method Hostname) src/github.com/gocolly/colly/colly.go:549: req.GetBody undefined (type http.Request has no field or method GetBody) src/github.com/gocolly/colly/colly.go:556: req.GetBody undefined (type http.Request has no field or method GetBody) src/github.com/gocolly/colly/colly.go:563: req.GetBody undefined (type http.Request has no field or method GetBody) src/github.com/gocolly/colly/colly.go:568: req.GetBody undefined (type http.Request has no field or method GetBody) src/github.com/gocolly/colly/colly.go:569: undefined: http.NoBody src/github.com/gocolly/colly/colly.go:570: req.GetBody undefined (type http.Request has no field or method GetBody) src/github.com/gocolly/colly/colly.go:570: undefined: http.NoBody src/github.com/gocolly/colly/colly.go:1154: req.URL.Hostname undefined (type *url.URL has no field or method Hostname)

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

Smartphone (please complete the following information):

Additional context Add any other context about the problem here.

steffi1 commented 1 year ago

What I've done here so far as to

go mod init github.com/luckylittle/dzone-refcardz-downloader (this generates go.mod) go get (downloads the referenced packages/modules) go run main.go .

then when this is down you'll have a downloads file with .pdf files however those .pdf files are all the same size and only contain html.