isso-comments / isso

a Disqus alternative
https://isso-comments.de
MIT License
5.03k stars 440 forks source link

Can't Get Isso Working Locally with SimpleHTTPServer (via Fabric) #162

Closed tohuw closed 8 years ago

tohuw commented 9 years ago

I've used isso in the past and have managed to make it work fine, but I've started a new dev/test process using Fabric as opposed to a local nginx. I like it, but as a side effect, I can't seem to get isso to work anymore. I can see the form, but submitting only returns HTTP 400 (bad request)

I'm using a copy of the demo HTML file provided in this repo, with the sole change being to modify the source of the script to http://localhost:8001; the same setting as in my isso cfg.

The isso log provides nothing helpful - it simply states it connected to localhost:8000, which is indeed the SimpleHTTPServer Fabric spawns.

My cfg is below, and an inspection of the headers is after that - please let me know what else I can provide.

[general]
dbpath = /Users/tohuw/Projects/tohuwnet/comments/isso-comments.db
host =
    http://localhost:8000
max-age = 1h
log-file = /usr/local/var/log/isso.log

[server]
listen = http://127.0.0.1:8001
reload = on
profile = off

[moderation]
enabled = false
purge-after = 60d

[guard]
enabled = false
ratelimit = 2
direct-reply =
reply-to-self = false

[markup]
options = strikethrough, superscript, autolink
allowed-elements =
allowed-attributes =

REQUEST HEADERS
Request URL:    http://localhost:8001/new?uri=%2Fissotest.html
Request Method:     POST
Status Code:    HTTP/1.0 400 BAD REQUEST
Request Headers 12:13:05.000
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:37.0) Gecko/20100101 Firefox/37.0
Referer:    http://localhost:8000/issotest.html
Pragma: no-cache
Origin: http://localhost:8000
Host:   localhost:8001
DNT:    1
Content-Type:   application/json; charset=UTF-8
Content-Length: 71
Connection: keep-alive
Cache-Control:  no-cache
Accept-Language:    en-US,en;q=0.5
Accept-Encoding:    gzip, deflate
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8

RESPONSE HEADERS
Server: Werkzeug/0.10.1 Python/2.7.9
Date:   Mon, 09 Feb 2015 17:13:05 GMT
Content-Type:   text/html
Content-Length: 142
Access-Control-Expose-Headers:  X-Set-Cookie, Date
access-control-allow-origin:    http://localhost:8000
access-control-allow-methods:   HEAD, GET, POST, PUT, DELETE
access-control-allow-headers:   Origin, Referer, Content-Type
Access-Control-Allow-Credentials:   true
posativ commented 9 years ago

Is there some content in the response body? You are running both, Python's SimpleHTTPServer and Isso on the same (local)host?