Started getting: Failed to normalize URL string. Returning in =

Hi all,

I have a system that posts my builds my blog and pushes it live whenever I make a change. On travis where the build happens it uses the latest version of hugo (it does a go get -v ) and today I noticed that I get “Failed to normalize URL string. Returning in = “2017-3-predictions-for-the-web-and-platforms.html”” for every markdown file, where as yesterday I didn’t get any issues.

My loacl version was 0.17. and I just upgraded it to 0.19 and I am having trouble working out the issues and if I can fix it, or if I should wait for master to update.

Travis build: (error happens in here)
Repo for my blog: in case someone can spot something I am doing wrong.

Out of curiosity, I tested your site – builds fine here.

Which means, I guess, that your installation method is faulty. We should update the docs about this, maybe, but doing any go get hugo cannot be “trusted” 100% anymore (you may get a too new version of a library) – Hugo now manages its dependencies.

I should add that I just updated my hugo version like an hour (or ago) and also are getting lots of “Failed to normalized URL string” errors also.

Everything seem to work okay with my old version. Since I started with Hugo more frequently again, I figure I should update the tool.

Today, I faced the same problem. Use the govendor tool to fetch the correct versions of Hugo’s dependencies.

Yep. As of today, I am getting the “Failed to normalize URL string” error.

My Travis build was passing yesterday, and failing today.

Here is the result of my build:

I am seeing the same thing.

Can build locally on version v0.18.1

Using go get -u -v on my travis CI build with version v0.19-DEV fails with error ERROR 2017/01/07 01:57:34 Failed to normalize URL string. Returning in = “/”.

I met the same problem in travisCI building, following is my solution:

Modify the .travis.yml file:


    - go get -u -v
    - hugo


    - go get -u -v
    - go get -u -v
    - cd $GOPATH/src/ && govendor sync && go install

    - cd $HOME/gopath/src/ && hugo

Hope this will help you.


Note that if you don’t need the shiniest new Hugo features, doing something like this may give you a more stable build:

Thanks. I faced the same problem on 0.19 DEV and installing govendor and running govendor sync helped.

All seems fine, except:

$ go get -d -t -u
$ go get -d -t -u
$ go build -a -i
$ go install
$ cd $GOPATH/src/
$ git status
On branch master
Your branch is up-to-date with 'origin/master'.
nothing to commit, working directory clean
$ govendor sync
$ git diff

is giving me:

diff --git a/vendor/vendor.json b/vendor/vendor.json
index f397393..52fe78a 100644
--- a/vendor/vendor.json
+++ b/vendor/vendor.json
@@ -257,7 +257,7 @@
                        "revisionTime": "2016-12-08T18:21:42Z"
-                       "checksumSHA1": "J7o9HQd7rg294kEa7P2fllTsArs=",
+                       "checksumSHA1": "WASQjQVYHiVtAOxvRbl6I23etGE=",
                        "path": "",
                        "revision": "56a7ecbeb18dde53c6db4bd96b541fd9741b8d44",
                        "revisionTime": "2016-12-24T17:25:03Z"

Supposedly, in my next commit, I shouldn’t include this change. Instead, what should I do?

P.S. I’m on the master branch:

$ git status --short --branch
## master...origin/master
 M vendor/vendor.json

$ git log -n 1 --oneline
d6000a2  all: Refactor to nonglobal template handling

EDIT: @bep answered here.