You've stumbled on an error, Message
Hi I'm trying to integrate our SVN server with lighthouse (using bash because I want to) I've got to a point where executing the below command is generating a message saying "It looks like you've stumbled on an error. We've been notified of the problem."
Unfortunately this doesn't help me identify the problem with my curl command, the command is below (I've removed my api key and project and replaced them with place holders)
curl -H "Content-Type:application/xml" -H "X-LighthouseToken:[[MY API TOKEN]]" -d "body= user committed changeset [1]initial /body>A branches/ A tags/ A trunk/12011-04-13T10:26:58+0100" http://saviio.lighthouseapp.com/projects/[[myproject]]/changesets.xml
A second question would be do you have any documentation listing the API functionality (once this is sorted I want to integrate it with our website to automagically generate tickets on errors)
Discussions are closed to public comments.
If you need help with Lighthouse please
start a new discussion.
Keyboard shortcuts
Generic
| ? | Show this help |
|---|---|
| ESC | Blurs the current field |
Comment Form
| r | Focus the comment reply box |
|---|---|
| ^ + ↩ | Submit the comment |
You can use Command ⌘ instead of Control ^ on Mac
1 Posted by Micheal Wilkins... on 22 Jun, 2011 03:32 PM
Ok so my <'s all got stripped now i'm sad
I'll try again
curl -H "Content-Type:application/xml" -H "X-LighthouseToken:[[MY API TOKEN]]" -d "body=<changeset> <title>[[USER]] committed changeset [1]</title><body>initial import</body><changes>A branches/ A tags/ A trunk/</changes><revision>1</revision><changed-at type='datetime'>2011-04-13T10:26:58+0100</changed-at></changeset>" http://saviio.lighthouseapp.com/projects/[[MY PROJECT ID]]/changesets.xml2 Posted by Nicole on 22 Jun, 2011 03:54 PM
At first look you're missing POST in your command. Curl defaults to GET. Our API documentation is here. We have a specific section on integration with source control management as well.
Take a look at the documents and then your command format and let us know if you have any questions.
Thanks,
Nicole
3 Posted by Micheal Wilkins... on 22 Jun, 2011 08:52 PM
Thanks for that Nicole, that helped me get more meaningful errors back from
your api, meaning I now have a fully working bash based svn > lighthouse
post commit hook
On 22 June 2011 16:54, Nicole Ramsey <
[email blocked]> wrote:
4 Posted by Micheal Wilkins... on 23 Jun, 2011 01:02 PM
it was working, now, no longer
My new curl command is
`curl -X POST -H 'Content-Type:application/xml' -H 'X-LighthouseToken:[[API TOKEN]]' -d 'body=<changeset>
<title>Email committed changeset [59]</title>
<body>Fixed exceptions being caused by refactor of terms (see commit 58)</body>
<changes type="yaml">---
- - D
- trunk/application/models/Database/Organisationlimits.php
- - M
- trunk/application/models/Database/Organisations.php
- - A
- trunk/application/models/Database/Subscriptionlimits.php
- - M
- trunk/application/views/scripts/admin/organisations.phtml
</changes>
<revision>59</revision>
<changed-at type="datetime">2011-06-23T13:06:59+0100</changed-at>
</changeset>' http://saviio.lighthouseapp.com/projects/[[PROJECT ID]]/changesets.xml`
That Changes are setout as that is how the API says they should be setout although I have also tried
<changes type="yaml">---
- D trunk/application/models/Database/Organisationlimits.php
- M trunk/application/models/Database/Organisations.php
- A trunk/application/models/Database/Subscriptionlimits.php
- M trunk/application/views/scripts/admin/organisations.phtml
</changes>
as per the docs
5 Posted by Micheal Wilkins... on 23 Jun, 2011 01:37 PM
Ok I figured it out, it was to do with spaces in the changeset array
6 Posted by Nicole on 23 Jun, 2011 02:40 PM
Michael -
Just let us know if you have more questions and we'll be happy to answer them.
Thanks,
Nicole
Nicole closed this discussion on 23 Jun, 2011 02:40 PM.