phabulous icon indicating copy to clipboard operation
phabulous copied to clipboard

invalid character '<' looking for beginning of value

Open dangfan opened this issue 10 years ago • 7 comments

2015/11/14 11:21:02 Panic recovery -> invalid character '<' looking for beginning of value
/usr/local/Cellar/go/1.5.1/libexec/src/runtime/panic.go:423 (0x42a9e9)
/Users/etcinit/go/src/github.com/etcinit/phabulous/app/controllers/feed.go:34 (0x5110dc)
/Users/etcinit/go/src/github.com/etcinit/phabulous/app/controllers/feed.go:26 (0x51265a)
/Users/etcinit/go/src/github.com/gin-gonic/gin/context.go:95 (0x512b2a)
/Users/etcinit/go/src/github.com/gin-gonic/gin/logger.go:56 (0x523fd1)
/Users/etcinit/go/src/github.com/gin-gonic/gin/context.go:95 (0x512b2a)
/Users/etcinit/go/src/github.com/gin-gonic/gin/recovery.go:43 (0x524b31)
/Users/etcinit/go/src/github.com/gin-gonic/gin/context.go:95 (0x512b2a)
/Users/etcinit/go/src/github.com/gin-gonic/gin/gin.go:294 (0x519582)
/Users/etcinit/go/src/github.com/gin-gonic/gin/gin.go:275 (0x5191b7)
/usr/local/Cellar/go/1.5.1/libexec/src/net/http/server.go:1862 (0x5d05be)
/usr/local/Cellar/go/1.5.1/libexec/src/net/http/server.go:1361 (0x5cdbfe)
/usr/local/Cellar/go/1.5.1/libexec/src/runtime/asm_amd64.s:1696 (0x45bf01)

dangfan avatar Nov 14 '15 03:11 dangfan

Is you Phabricator instance returning HTML somehow while connecting through conduit?

etcinit avatar Nov 25 '15 03:11 etcinit

I ran into this problem as well. A simple update to the config file fixed it for me. In the legacy branch, the api setting looked like this: https://phab.domain.com/api/, in the new Go version, the api setting looks like https://phab.domain.com. If you're upgrading from the old version, be sure to take the /api off the end of your URL.

glugy avatar Dec 04 '15 17:12 glugy

:+1:

etcinit avatar Dec 07 '15 06:12 etcinit

Sorry how can I solved this problem?

alanmoment avatar Jan 17 '16 14:01 alanmoment

I would make sure I'm using a recent version of Phabricator and Phabulous 2.3.

etcinit avatar Jan 20 '16 03:01 etcinit

Thanks, Its work now. But I also want to ask. I'm setup notice to other channel. But just channels: feed can be work?

channels:
  # The feed channel is where Phabulous will post every feed event to this
  # channel. Leave it blank to disable this feature.
  feed: '#phabricator'

  # You can map repositories to a channel. This will send feed events regarding
  # commits and revisions to the specified channel.
  repositories:
    CALLSIGN: '#channel'
    OTHERCALLSIGN: '#otherchannel'  

And response error message

DEBU[0352] epoch=1453426892&storyAuthorPHID=PHID-USER-o4uiqcwoxllohbauupca&storyData%5BobjectPHID%5D=PHID-TASK-g5vjgdqey5ju62hkzu2i&storyData%5BtransactionPHIDs%5D%5BPHID-XACT-TASK-3tkzwwkvzkuzlxh%5D=PHID-XACT-TASK-3tkzwwkvzkuzlxh&storyData%5BtransactionPHIDs%5D%5BPHID-XACT-TASK-c6j4abrvgfuzyr5%5D=PHID-XACT-TASK-c6j4abrvgfuzyr5&storyData%5BtransactionPHIDs%5D%5BPHID-XACT-TASK-fkd2gaqu3z5wgkn%5D=PHID-XACT-TASK-fkd2gaqu3z5wgkn&storyData%5BtransactionPHIDs%5D%5BPHID-XACT-TASK-nbxoasebpog4zmq%5D=PHID-XACT-TASK-nbxoasebpog4zmq&storyData%5BtransactionPHIDs%5D%5BPHID-XACT-TASK-p2jkartsu4s6bpq%5D=PHID-XACT-TASK-p2jkartsu4s6bpq&storyData%5BtransactionPHIDs%5D%5BPHID-XACT-TASK-uwqeq6e5glxdg4i%5D=PHID-XACT-TASK-uwqeq6e5glxdg4i&storyData%5BtransactionPHIDs%5D%5BPHID-XACT-TASK-vy6ytin2dcu7vsb%5D=PHID-XACT-TASK-vy6ytin2dcu7vsb&storyID=71&storyText=alan+created+T6%3A+html+template.&storyType=PhabricatorApplicationTransactionFeedStory 
2016/01/22 13:49:57 Panic recovery -> json: cannot unmarshal array into Go value of type responses.PHIDQueryResponse
/home/alan/.gvm/gos/go1.4/src/runtime/panic.go:387 (0x413598)
    gopanic: reflectcall(unsafe.Pointer(d.fn), deferArgs(d), uint32(d.siz), uint32(d.siz))
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/etcinit/phabulous/app/controllers/feed.go:49 (0x51e248)
    (*FeedController).postReceive: panic(err)
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/etcinit/phabulous/app/controllers/feed.go:29 (0x51f911)
    postReceive).fm: front.POST("/receive", f.postReceive)
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/gin-gonic/gin/context.go:95 (0x51fe30)
    (*Context).Next: c.handlers[c.index](c)
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/gin-gonic/gin/logger.go:56 (0x5307c2)
    func.007: c.Next()
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/gin-gonic/gin/context.go:95 (0x51fe30)
    (*Context).Next: c.handlers[c.index](c)
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/gin-gonic/gin/recovery.go:43 (0x5311a2)
    func.009: c.Next()
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/gin-gonic/gin/context.go:95 (0x51fe30)
    (*Context).Next: c.handlers[c.index](c)
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/gin-gonic/gin/gin.go:294 (0x526493)
    (*Engine).handleHTTPRequest: context.Next()
/home/alan/.gvm/pkgsets/go1.4/global/src/github.com/gin-gonic/gin/gin.go:275 (0x526167)
    (*Engine).ServeHTTP: engine.handleHTTPRequest(c)
/home/alan/.gvm/gos/go1.4/src/net/http/server.go:1703 (0x5cc5fa)
    serverHandler.ServeHTTP: handler.ServeHTTP(rw, req)
/home/alan/.gvm/gos/go1.4/src/net/http/server.go:1204 (0x5c9e77)
    (*conn).serve: serverHandler{c.server}.ServeHTTP(w, w.req)
/home/alan/.gvm/gos/go1.4/src/runtime/asm_amd64.s:2232 (0x43d8c1)
    goexit:

alanmoment avatar Jan 21 '16 14:01 alanmoment

In my case, this invalid character '<' looking for beginning of value was because Phabricator was returning 401 Unauthorized errors (with HTML in them). FYI. Might wanna be more explicit about non-200 responses like this from Phab.

jaapdeheer avatar Sep 20 '17 15:09 jaapdeheer