From hotfigs at gmail.com Wed Aug 1 16:55:59 2007 From: hotfigs at gmail.com (Geoff Smith) Date: Wed, 1 Aug 2007 17:55:59 +0100 Subject: [Developers] Safari crash Message-ID: Hi! Has anyone got mjt working with safari? It is crashing when i call mjt.run, even for the "running mjt version..." example. Freebase seems to work fine, although there is a warning saying that safari is not fully supported. Any suggestions? Cheers, Geoff -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.freebase.com/pipermail/developers/attachments/20070801/e03dd56e/attachment.htm From nix at metaweb.com Wed Aug 1 17:51:10 2007 From: nix at metaweb.com (Nick Thompson) Date: Wed, 01 Aug 2007 10:51:10 -0700 Subject: [Developers] Safari crash In-Reply-To: References: Message-ID: <46B0C80E.2040805@metaweb.com> i believe that 0.4 ran on safari, i thought i had done a quick test of 0.5 but apparently not - thanks for the report! zak stein has found that the most recent beta of safari 3 works with mjt, but i hope to get safari 2 working as well. i don't have access to a mac today but i'll do ye olde binary search for the crash point tomorrow. nick Geoff Smith wrote: > Hi! > > Has anyone got mjt working with safari? It is crashing when i call > mjt.run, even for the "running mjt version..." example. Freebase seems > to work fine, although there is a warning saying that safari is not > fully supported. > > Any suggestions? > > Cheers, > > Geoff > > > ------------------------------------------------------------------------ > > _______________________________________________ > Developers mailing list > Developers at freebase.com > http://lists.freebase.com/mailman/listinfo/developers From al at metaweb.com Fri Aug 3 00:55:49 2007 From: al at metaweb.com (Alexander Marks) Date: Thu, 2 Aug 2007 20:55:49 -0400 (EDT) Subject: [Developers] Fictional Character Race vs Species Message-ID: <682673.15951186102549670.JavaMail.root@h00215> Dear fictional people: Since the distinction between Character Race and Character Species is pretty unclear, tends to vary by Fictional Universe, and was resulting in some strange data patterns, we have decided to eliminate Character Race entirely. We are considering renaming Character Species to something like "Character Race or Species". If you care about this, please post your thoughts on the Fictional Universe domain discussion page. Al From will at hamstersoup.com Sat Aug 4 16:06:58 2007 From: will at hamstersoup.com (Will Moffat) Date: Sat, 4 Aug 2007 18:06:58 +0200 Subject: [Developers] cursors, limits, MJT and chocolates In-Reply-To: <444718DB-70B7-47D2-BA74-7A4BC1D1FB22@metaweb.com> References: <2f665fe20707090656k53583244y47e6ecb94c7b5bfd@mail.gmail.com> <444718DB-70B7-47D2-BA74-7A4BC1D1FB22@metaweb.com> Message-ID: <2f665fe20708040906x1bb6f7e6h5a085a8252deb2ed@mail.gmail.com> Hi, I've updated Darin's great example of MQL cursors in MJT to use incremental queries rather than requiring page reloads. It's on my blog: http://hamstersoup.wordpress.com/ regards, --Will On 7/9/07, Darin Wilson wrote: > > Extra Belgian chocolates if somebody has an example of using the > > cursor feature with MJT. > > That's some good incentive. ;-) > > Below is a crude example. Cursors aren't in the official MJT docs, so > I discovered this method by looking at the mjt source. Some of the > implementation details could change (and Nix please correct me if > this is not the right way to do this). From fabricio at gmail.com Sun Aug 5 22:09:44 2007 From: fabricio at gmail.com (Fabricio Zuardi) Date: Sun, 5 Aug 2007 15:09:44 -0700 Subject: [Developers] reordering history Message-ID: <90e9b0bc0708051509k6fd590cfu589fc0d87c613296@mail.gmail.com> Hi, I am new to freebase, and this is probably a stupid question, but since on the page history there is no log of reordering of values, my question is: - do freebase keeps track of all reordering changes? - if so, how can I retrieve it using MQL? thanks! -- Fabricio From kurt at metaweb.com Sun Aug 5 22:45:06 2007 From: kurt at metaweb.com (Kurt Bollacker) Date: Sun, 5 Aug 2007 15:45:06 -0700 Subject: [Developers] reordering history In-Reply-To: <90e9b0bc0708051509k6fd590cfu589fc0d87c613296@mail.gmail.com> References: <90e9b0bc0708051509k6fd590cfu589fc0d87c613296@mail.gmail.com> Message-ID: <20070805224506.GB22305@metaweb.com> On Sun, Aug 05, 2007 at 03:09:44PM -0700, Fabricio Zuardi wrote: > Hi, > > I am new to freebase, and this is probably a stupid question, but > since on the page history there is no log of reordering of values, my > question is: You questions are not stupid at all. In fact, they are very relevant to MQL, and you have not missed something obvious. > - do freebase keeps track of all reordering changes? Deep in the bowels of the database, yes. All changes are tracked. > - if so, how can I retrieve it using MQL? In most normal cases this is not currently supported by MQL. This is why the history page can't show it, as it uses MQL like every other app in Freebase. It is possible to get some of the history through clever examination of the timestamps and history for a set of properties but this is probably too painful for most purposes. We are aware of this as a missing feature, but since the ordering history information is in the database, when/if support is added to MQL, the history should be viewable retroactive to the beginning. Someone else may be able to give you more details. Hope that helps... Kurt :-) From markce at btclick.com Mon Aug 6 09:25:14 2007 From: markce at btclick.com (Mark CE) Date: Mon, 06 Aug 2007 10:25:14 +0100 Subject: [Developers] coldfusion Message-ID: <200708060934.HMR90732@c2bthomr03.btconnect.com> Hello there, Has anyone successfully retrieved a query result from Freebase using Coldfusion CFHTTP? Or know of a reason why mine would return a 400 error? HTTP/1.0 400 Bad Request X-Metaweb-Cost: dt=0.001, nreqs=0 Date: Fri, 03 Aug 2007 16:10:49 GMT X-Metaweb-TID: cache;cache01.p01.sfo1:8101;2007-08-03T16:10:49Z;0002 Server: Apache/2.0.58 Vary: Accept-Encoding Cache-Control: no-cache Content-Type: applic If instead of CFHTTP I get my coldfusion code to output the URL to the page; I copy and paste into the address bar, I get a 200 response... and the query results I would expect. Working code samples gratefully received!!! Thanks Mark CE ---------- Mark Christian-Edwards markce at btclick.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.freebase.com/pipermail/developers/attachments/20070806/e23c2926/attachment.htm From will at hamstersoup.com Mon Aug 6 09:54:08 2007 From: will at hamstersoup.com (Will Moffat) Date: Mon, 6 Aug 2007 11:54:08 +0200 Subject: [Developers] coldfusion In-Reply-To: <200708060934.HMR90732@c2bthomr03.btconnect.com> References: <200708060934.HMR90732@c2bthomr03.btconnect.com> Message-ID: <2f665fe20708060254l3b33e573wd99890050c8d7b71@mail.gmail.com> Hi Mark, > Or know of a reason why mine would return a 400 error? Maybe you haven't sent your 'metaweb-user' cookie? See http://hamstersoup.wordpress.com/2007/07/05/freebase-api-cookie-test/ for tips on how to find your cookie and test it regards, --Will From will at hamstersoup.com Mon Aug 6 12:03:50 2007 From: will at hamstersoup.com (Will Moffat) Date: Mon, 6 Aug 2007 14:03:50 +0200 Subject: [Developers] coldfusion In-Reply-To: <200708061120.HJJ78891@c2bthomr04.btconnect.com> References: <200708060934.HMR90732@c2bthomr03.btconnect.com> <2f665fe20708060254l3b33e573wd99890050c8d7b71@mail.gmail.com> <200708061120.HJJ78891@c2bthomr04.btconnect.com> Message-ID: <2f665fe20708060503i45b750b2w8066ba84c1b2ff13@mail.gmail.com> Hi Mark (with developers back in CC because I'm not a Cold Fusion guru) Can you compare the actual HTTP requests and responses? Using Firebug you can see what a successful query looks like in Firefox. CF Server Monitor or Ethereal will let you see your unsuccessful CF query. > This is really frustrating because until I can get a response using CFHTTP, > I can't try developing anything. I feel your pain. Cookie authentication takes the fun out of programming :-( They should be going away sometime :-) Good luck, --Wil On 8/6/07, Mark CE wrote: > > > Thanks Will, > > I am trying to pass the cookie, maybe I'm not encoding it right. > Here's my CF code: > > method="POST" result="objGet"> > > type="COOKIE"> > > > Response is: "authentication required" > > > This is really frustrating because until I can get a response using CFHTTP, > I can't try developing anything. > > Mark > > From markce at btclick.com Mon Aug 6 17:46:00 2007 From: markce at btclick.com (Mark CE) Date: Mon, 06 Aug 2007 18:46:00 +0100 Subject: [Developers] coldfusion In-Reply-To: <8037c20b0708060834l5b1e5b6bia782c1ebb56db559@mail.gmail.co m> References: <200708060934.HMR90732@c2bthomr03.btconnect.com> <8037c20b0708060834l5b1e5b6bia782c1ebb56db559@mail.gmail.com> Message-ID: <200708061747.DCZ07065@c2bthomr14.btconnect.com> Don't worry I have tried both POST and GET, many times now! Two crappy CF templates attached (testme.cfm which calls testme2.cfm). I am not familiar with this list; if it doesn't accept attachments and I should be including the code in the body of this email, I guess I'll find out when my message comes back. Needless to say, the cookie-getting function does work and successfully returns the two cookies: metaweb-user and metaweb-user-info. ----------------------- Originally I wasn't deserialising the JSON response so hence the unhelpful error message. Now the response is: code: /api/status/error/input/invalid message: authentication required ---------------------- Thanks again Mark At 16:34 06/08/2007, you wrote: >In addition to the cookie requirement, you probably need to do your >cfhttp call as a POST, cfhttp is a GET by default. If that doesn't >work post your cfhttp code here to the list. > >On 8/6/07, Mark CE wrote: > > > > > > Hello there, > > Has anyone successfully retrieved a query result from Freebase using > > Coldfusion CFHTTP? > > Or know of a reason why mine would return a 400 error? > > > > HTTP/1.0 400 Bad Request X-Metaweb-Cost: dt=0.001, nreqs=0 Date: Fri, 03 > > Aug 2007 16:10:49 GMT X-Metaweb-TID: > > cache;cache01.p01.sfo1:8101;2007-08-03T16:10:49Z;0002 > > Server: Apache/2.0.58 Vary: Accept-Encoding Cache-Control: no-cache > > Content-Type: applic > > > > If instead of CFHTTP I get my coldfusion code to output the URL to the > > page; I copy and paste into the address bar, I get a 200 > response... and the > > query results I would expect. > > > > Working code samples gratefully received!!! > > Thanks > > Mark CE > > > > > > > > ________________________________ > > Mark Christian-Edwards > > markce at btclick.com > > > > > > > > > > _______________________________________________ > > Developers mailing list > > Developers at freebase.com > > http://lists.freebase.com/mailman/listinfo/developers > > > > > > > >-- >No virus found in this incoming message. >Checked by AVG Free Edition. >Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: >05/08/2007 16:16 -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.freebase.com/pipermail/developers/attachments/20070806/798e717c/attachment.htm -------------- next part -------------- Metaweb Query Editor
QueryResult

QueryResult

---> -------------- next part -------------- -------------- next part -------------- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 16:16 From ninjascience at gmail.com Mon Aug 6 20:53:46 2007 From: ninjascience at gmail.com (Ryan Miller) Date: Mon, 6 Aug 2007 13:53:46 -0700 Subject: [Developers] coldfusion In-Reply-To: <200708061747.DCZ07065@c2bthomr14.btconnect.com> References: <200708060934.HMR90732@c2bthomr03.btconnect.com> <8037c20b0708060834l5b1e5b6bia782c1ebb56db559@mail.gmail.com> <200708061747.DCZ07065@c2bthomr14.btconnect.com> Message-ID: <8037c20b0708061353s3479ed25sc18c25e9ceb99b8b@mail.gmail.com> from what I can tell you're trying to do an HTTP POST to the freebase site with your username and password sent as POST variables, getting the metaweb-user cookie out of that response, than using that to do your mql POST. Why not just lookup your metaweb-user cookie value out of your browser and hard-code into your app? When I tried your code the first POST that should return the cookie doesn't, so if you want to keep going this route, concentrate there. Make sure your sending the vars under the right names (including case), and fake the user-agent string to a common browser. On 8/6/07, Mark CE wrote: > > > Don't worry I have tried both POST and GET, many times now! > > Two crappy CF templates attached (testme.cfm which calls testme2.cfm). I > am not familiar with this list; if it doesn't accept attachments and I > should be including the code in the body of this email, I guess I'll find > out when my message comes back. > > Needless to say, the cookie-getting function does work and successfully > returns the two cookies: > metaweb-user and metaweb-user-info. > > ----------------------- > Originally I wasn't deserialising the JSON response so hence the unhelpful > error message. > Now the response is: > > code: /api/status/error/input/invalid > message: authentication required > ---------------------- > > Thanks again > Mark > > > > At 16:34 06/08/2007, you wrote: > > > In addition to the cookie requirement, you probably need to do your > cfhttp call as a POST, cfhttp is a GET by default. If that doesn't > work post your cfhttp code here to the list. > > On 8/6/07, Mark CE wrote: > > > > > > Hello there, > > Has anyone successfully retrieved a query result from Freebase using > > Coldfusion CFHTTP? > > Or know of a reason why mine would return a 400 error? > > > > HTTP/1.0 400 Bad Request X-Metaweb-Cost: dt=0.001, nreqs=0 Date: Fri, 03 > > Aug 2007 16:10:49 GMT X-Metaweb-TID: > > cache;cache01.p01.sfo1:8101;2007-08-03T16:10:49Z;0002 > > Server: Apache/2.0.58 Vary: Accept-Encoding Cache-Control: no-cache > > Content-Type: applic > > > > If instead of CFHTTP I get my coldfusion code to output the URL to the > > page; I copy and paste into the address bar, I get a 200 response... and > the > > query results I would expect. > > > > Working code samples gratefully received!!! > > Thanks > > Mark CE > > > > > > > > ________________________________ > > Mark Christian-Edwards > > markce at btclick.com > > > > > > > > > > _______________________________________________ > > Developers mailing list > > Developers at freebase.com > > http://lists.freebase.com/mailman/listinfo/developers > > > > > > > > -- > No virus found in this incoming message. > Checked by AVG Free Edition. > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 > 16:16 > > > No virus found in this outgoing message. > Checked by AVG Free Edition. > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 > 16:16 > > > From niallo at metaweb.com Tue Aug 7 00:07:53 2007 From: niallo at metaweb.com (Niall O'Higgins) Date: Mon, 6 Aug 2007 17:07:53 -0700 Subject: [Developers] Weekly sandbox data refresh Message-ID: <20070807000753.GB27446@digdug.inet> Hi, Weekly refresh of data on http://sandbox.freebase.com happening over the next few minutes. -- Niall O'Higgins Software Engineer Metaweb Technologies, Inc. From niallo at metaweb.com Tue Aug 7 00:37:50 2007 From: niallo at metaweb.com (Niall O'Higgins) Date: Mon, 6 Aug 2007 17:37:50 -0700 Subject: [Developers] Weekly sandbox data refresh In-Reply-To: <20070807000753.GB27446@digdug.inet> References: <20070807000753.GB27446@digdug.inet> Message-ID: <20070807003750.GD27446@digdug.inet> Done. On Mon, Aug 06, 2007 at 05:07:53PM -0700, Niall O'Higgins wrote: > Hi, > > Weekly refresh of data on http://sandbox.freebase.com happening over the next > few minutes. > > -- > Niall O'Higgins > Software Engineer > Metaweb Technologies, Inc. > _______________________________________________ > Developers mailing list > Developers at freebase.com > http://lists.freebase.com/mailman/listinfo/developers -- Niall O'Higgins Software Engineer Metaweb Technologies, Inc. From ninjascience at gmail.com Tue Aug 7 03:48:14 2007 From: ninjascience at gmail.com (Ryan Miller) Date: Mon, 6 Aug 2007 20:48:14 -0700 Subject: [Developers] coldfusion In-Reply-To: <8037c20b0708061353s3479ed25sc18c25e9ceb99b8b@mail.gmail.com> References: <200708060934.HMR90732@c2bthomr03.btconnect.com> <8037c20b0708060834l5b1e5b6bia782c1ebb56db559@mail.gmail.com> <200708061747.DCZ07065@c2bthomr14.btconnect.com> <8037c20b0708061353s3479ed25sc18c25e9ceb99b8b@mail.gmail.com> Message-ID: <8037c20b0708062048h7761c7dbva46bb876e5044dde@mail.gmail.com> Mark, I was playing with the MQL Write services this afternoon and saw their example of using the login API, what you were tryin to do with the first http post in your code. After messing around I figured out that the username needs to be your email address. I also used a chttp param to specify the content type. The returned content is a JSON string but CF turns it into a Java ByteArrayOutputStream. Just use it's toString() method to see if the login succeeds (metaweb always returns a 200 status, even if the login fails, you need to inspect the JSON string to know if it succeeded. On 8/6/07, Ryan Miller wrote: > from what I can tell you're trying to do an HTTP POST to the freebase > site with your username and password sent as POST variables, getting > the metaweb-user cookie out of that response, than using that to do > your mql POST. Why not just lookup your metaweb-user cookie value out > of your browser and hard-code into your app? When I tried your code > the first POST that should return the cookie doesn't, so if you want > to keep going this route, concentrate there. Make sure your sending > the vars under the right names (including case), and fake the > user-agent string to a common browser. > > On 8/6/07, Mark CE wrote: > > > > > > Don't worry I have tried both POST and GET, many times now! > > > > Two crappy CF templates attached (testme.cfm which calls testme2.cfm). I > > am not familiar with this list; if it doesn't accept attachments and I > > should be including the code in the body of this email, I guess I'll find > > out when my message comes back. > > > > Needless to say, the cookie-getting function does work and successfully > > returns the two cookies: > > metaweb-user and metaweb-user-info. > > > > ----------------------- > > Originally I wasn't deserialising the JSON response so hence the unhelpful > > error message. > > Now the response is: > > > > code: /api/status/error/input/invalid > > message: authentication required > > ---------------------- > > > > Thanks again > > Mark > > > > > > > > At 16:34 06/08/2007, you wrote: > > > > > > In addition to the cookie requirement, you probably need to do your > > cfhttp call as a POST, cfhttp is a GET by default. If that doesn't > > work post your cfhttp code here to the list. > > > > On 8/6/07, Mark CE wrote: > > > > > > > > > Hello there, > > > Has anyone successfully retrieved a query result from Freebase using > > > Coldfusion CFHTTP? > > > Or know of a reason why mine would return a 400 error? > > > > > > HTTP/1.0 400 Bad Request X-Metaweb-Cost: dt=0.001, nreqs=0 Date: Fri, 03 > > > Aug 2007 16:10:49 GMT X-Metaweb-TID: > > > cache;cache01.p01.sfo1:8101;2007-08-03T16:10:49Z;0002 > > > Server: Apache/2.0.58 Vary: Accept-Encoding Cache-Control: no-cache > > > Content-Type: applic > > > > > > If instead of CFHTTP I get my coldfusion code to output the URL to the > > > page; I copy and paste into the address bar, I get a 200 response... and > > the > > > query results I would expect. > > > > > > Working code samples gratefully received!!! > > > Thanks > > > Mark CE > > > > > > > > > > > > ________________________________ > > > Mark Christian-Edwards > > > markce at btclick.com > > > > > > > > > > > > > > > _______________________________________________ > > > Developers mailing list > > > Developers at freebase.com > > > http://lists.freebase.com/mailman/listinfo/developers > > > > > > > > > > > > > > -- > > No virus found in this incoming message. > > Checked by AVG Free Edition. > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 > > 16:16 > > > > > > No virus found in this outgoing message. > > Checked by AVG Free Edition. > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 > > 16:16 > > > > > > > From markce at btclick.com Tue Aug 7 09:09:25 2007 From: markce at btclick.com (Mark CE) Date: Tue, 07 Aug 2007 10:09:25 +0100 Subject: [Developers] coldfusion CFHTTP COOKIE "authentication required" In-Reply-To: <8037c20b0708062048h7761c7dbva46bb876e5044dde@mail.gmail.co m> References: <200708060934.HMR90732@c2bthomr03.btconnect.com> <8037c20b0708060834l5b1e5b6bia782c1ebb56db559@mail.gmail.com> <200708061747.DCZ07065@c2bthomr14.btconnect.com> <8037c20b0708061353s3479ed25sc18c25e9ceb99b8b@mail.gmail.com> <8037c20b0708062048h7761c7dbva46bb876e5044dde@mail.gmail.com> Message-ID: <200708071010.CRZ11591@c2bthomr09.btconnect.com> changed the email subject to make it more specific I used your "toString" extraction into my code and the result does come back as "Login Succeeded", so I still think the problem is in what I'm posting to the mqlread service. In fact the login call returns a success with my plain user name; so apparently email is not necessary. In fact I have also hard-coded (copied & pasted) the metaweb-user cookie from my browser session into the cookie param for the mqlread call; same 400 problem. What I would be really keen to have is an example of working code for this part: I have tried adding this: but it makes no difference. I have also tried the request with the "q" cfhttpparam on its own without the cookie. And with the cookie cfhttpparam on its own without the q parameter. And with a dummy param, leaving out both q and cookie. Same result every time. One potential problem is that my cookie has a "#" in it. I resolved this by replacing it with "##" which is the usual practice for escaping "#" in CF. Mark CE At 04:48 07/08/2007, Ryan Miller wrote: >Mark, > >I was playing with the MQL Write services this afternoon and saw their >example of using the login API, what you were tryin to do with the >first http post in your code. After messing around I figured out that >the username needs to be your email address. I also used a chttp >param to specify the content type. The returned content is a JSON >string but CF turns it into a Java ByteArrayOutputStream. Just use >it's toString() method to see if the login succeeds (metaweb always >returns a 200 status, even if the login fails, you need to inspect the >JSON string to know if it succeeded. > > > value="application/x-www-form-urlencoded" type="header" /> > type="formfield" /> > > > > > >On 8/6/07, Ryan Miller wrote: > > from what I can tell you're trying to do an HTTP POST to the freebase > > site with your username and password sent as POST variables, getting > > the metaweb-user cookie out of that response, than using that to do > > your mql POST. Why not just lookup your metaweb-user cookie value out > > of your browser and hard-code into your app? When I tried your code > > the first POST that should return the cookie doesn't, so if you want > > to keep going this route, concentrate there. Make sure your sending > > the vars under the right names (including case), and fake the > > user-agent string to a common browser. > > > > On 8/6/07, Mark CE wrote: > > > > > > > > > Don't worry I have tried both POST and GET, many times now! > > > > > > Two crappy CF templates attached (testme.cfm which calls > testme2.cfm). I > > > am not familiar with this list; if it doesn't accept attachments and I > > > should be including the code in the body of this email, I guess I'll find > > > out when my message comes back. > > > > > > Needless to say, the cookie-getting function does work and successfully > > > returns the two cookies: > > > metaweb-user and metaweb-user-info. > > > > > > ----------------------- > > > Originally I wasn't deserialising the JSON response so hence > the unhelpful > > > error message. > > > Now the response is: > > > > > > code: /api/status/error/input/invalid > > > message: authentication required > > > ---------------------- > > > > > > Thanks again > > > Mark > > > > > > > > > > > > At 16:34 06/08/2007, you wrote: > > > > > > > > > In addition to the cookie requirement, you probably need to do your > > > cfhttp call as a POST, cfhttp is a GET by default. If that doesn't > > > work post your cfhttp code here to the list. > > > > > > On 8/6/07, Mark CE wrote: > > > > > > > > > > > > Hello there, > > > > Has anyone successfully retrieved a query result from Freebase using > > > > Coldfusion CFHTTP? > > > > Or know of a reason why mine would return a 400 error? > > > > > > > > HTTP/1.0 400 Bad Request X-Metaweb-Cost: dt=0.001, nreqs=0 > Date: Fri, 03 > > > > Aug 2007 16:10:49 GMT X-Metaweb-TID: > > > > cache;cache01.p01.sfo1:8101;2007-08-03T16:10:49Z;0002 > > > > Server: Apache/2.0.58 Vary: Accept-Encoding Cache-Control: no-cache > > > > Content-Type: applic > > > > > > > > If instead of CFHTTP I get my coldfusion code to output the > URL to the > > > > page; I copy and paste into the address bar, I get a 200 > response... and > > > the > > > > query results I would expect. > > > > > > > > Working code samples gratefully received!!! > > > > Thanks > > > > Mark CE > > > > > > > > > > > > > > > > ________________________________ > > > > Mark Christian-Edwards > > > > markce at btclick.com > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > Developers mailing list > > > > Developers at freebase.com > > > > http://lists.freebase.com/mailman/listinfo/developers > > > > > > > > > > > > > > > > > > > > -- > > > No virus found in this incoming message. > > > Checked by AVG Free Edition. > > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release > Date: 05/08/2007 > > > 16:16 > > > > > > > > > No virus found in this outgoing message. > > > Checked by AVG Free Edition. > > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: > 05/08/2007 > > > 16:16 > > > > > > > > > > > > > > >-- >No virus found in this incoming message. >Checked by AVG Free Edition. >Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: >05/08/2007 16:16 -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.freebase.com/pipermail/developers/attachments/20070807/8990aa2f/attachment.htm -------------- next part -------------- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 16:16 From ninjascience at gmail.com Tue Aug 7 16:38:10 2007 From: ninjascience at gmail.com (Ryan Miller) Date: Tue, 7 Aug 2007 09:38:10 -0700 Subject: [Developers] coldfusion CFHTTP COOKIE "authentication required" In-Reply-To: <200708071010.CRZ11591@c2bthomr09.btconnect.com> References: <200708060934.HMR90732@c2bthomr03.btconnect.com> <8037c20b0708060834l5b1e5b6bia782c1ebb56db559@mail.gmail.com> <200708061747.DCZ07065@c2bthomr14.btconnect.com> <8037c20b0708061353s3479ed25sc18c25e9ceb99b8b@mail.gmail.com> <8037c20b0708062048h7761c7dbva46bb876e5044dde@mail.gmail.com> <200708071010.CRZ11591@c2bthomr09.btconnect.com> Message-ID: <8037c20b0708070938t68204139pfd4f652128f01032@mail.gmail.com> Mark, Bad news, CF automatically urlencodes the cookie which makes it unrecognizable to freebase's api service. Why they do this I have no idea, it's about the worst thing I've ever seen in CF. Yes, there is an attribute for "encoded" but it is ignored on Cookie types. The good news is there is a workaround. Be sure you're getting just the values out of the login response cookie. back as "Login Succeeded", so I still think the problem is in what I'm > posting to the mqlread service. In fact the login call returns a success > with my plain user name; so apparently email is not necessary. > > In fact I have also hard-coded (copied & pasted) the metaweb-user cookie > from my browser session into the cookie param for the mqlread call; same 400 > problem. > > What I would be really keen to have is an example of working code for this > part: > > method="POST"> > type="FORMFIELD"> > value="A|u_mycookie|g_...etc...Kug" type="COOKIE"> > > > I have tried adding this: > value="application/x-www-form-urlencoded" type="header" /> > but it makes no difference. > > I have also tried the request with the "q" cfhttpparam on its own without > the cookie. > And with the cookie cfhttpparam on its own without the q parameter. > And with a dummy param, leaving out both q and cookie. > > Same result every time. > > One potential problem is that my cookie has a "#" in it. > I resolved this by replacing it with "##" which is the usual practice for > escaping "#" in CF. > > > Mark CE > > > At 04:48 07/08/2007, Ryan Miller wrote: > > > Mark, > > I was playing with the MQL Write services this afternoon and saw their > example of using the login API, what you were tryin to do with the > first http post in your code. After messing around I figured out that > the username needs to be your email address. I also used a chttp > param to specify the content type. The returned content is a JSON > string but CF turns it into a Java ByteArrayOutputStream. Just use > it's toString() method to see if the login succeeds (metaweb always > returns a 200 status, even if the login fails, you need to inspect the > JSON string to know if it succeeded. > > method="POST"> > value="application/x-www-form-urlencoded" type="header" /> > /> > > > > > > On 8/6/07, Ryan Miller wrote: > > from what I can tell you're trying to do an HTTP POST to the freebase > > site with your username and password sent as POST variables, getting > > the metaweb-user cookie out of that response, than using that to do > > your mql POST. Why not just lookup your metaweb-user cookie value out > > of your browser and hard-code into your app? When I tried your code > > the first POST that should return the cookie doesn't, so if you want > > to keep going this route, concentrate there. Make sure your sending > > the vars under the right names (including case), and fake the > > user-agent string to a common browser. > > > > On 8/6/07, Mark CE wrote: > > > > > > > > > Don't worry I have tried both POST and GET, many times now! > > > > > > Two crappy CF templates attached (testme.cfm which calls testme2.cfm). > I > > > am not familiar with this list; if it doesn't accept attachments and I > > > should be including the code in the body of this email, I guess I'll > find > > > out when my message comes back. > > > > > > Needless to say, the cookie-getting function does work and > successfully > > > returns the two cookies: > > > metaweb-user and metaweb-user-info. > > > > > > ----------------------- > > > Originally I wasn't deserialising the JSON response so hence the > unhelpful > > > error message. > > > Now the response is: > > > > > > code: /api/status/error/input/invalid > > > message: authentication required > > > ---------------------- > > > > > > Thanks again > > > Mark > > > > > > > > > > > > At 16:34 06/08/2007, you wrote: > > > > > > > > > In addition to the cookie requirement, you probably need to do your > > > cfhttp call as a POST, cfhttp is a GET by default. If that doesn't > > > work post your cfhttp code here to the list. > > > > > > On 8/6/07, Mark CE wrote: > > > > > > > > > > > > Hello there, > > > > Has anyone successfully retrieved a query result from Freebase > using > > > > Coldfusion CFHTTP? > > > > Or know of a reason why mine would return a 400 error? > > > > > > > > HTTP/1.0 400 Bad Request X-Metaweb-Cost: dt=0.001, nreqs=0 Date: > Fri, 03 > > > > Aug 2007 16:10:49 GMT X-Metaweb-TID: > > > > > cache;cache01.p01.sfo1:8101;2007-08-03T16:10:49Z;0002 > > > > Server: Apache/2.0.58 Vary: Accept-Encoding Cache-Control: no-cache > > > > Content-Type: applic > > > > > > > > If instead of CFHTTP I get my coldfusion code to output the URL to > the > > > > page; I copy and paste into the address bar, I get a 200 response... > and > > > the > > > > query results I would expect. > > > > > > > > Working code samples gratefully received!!! > > > > Thanks > > > > Mark CE > > > > > > > > > > > > > > > > ________________________________ > > > > Mark Christian-Edwards > > > > markce at btclick.com > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > Developers mailing list > > > > Developers at freebase.com > > > > > http://lists.freebase.com/mailman/listinfo/developers > > > > > > > > > > > > > > > > > > > > -- > > > No virus found in this incoming message. > > > Checked by AVG Free Edition. > > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: > 05/08/2007 > > > 16:16 > > > > > > > > > No virus found in this outgoing message. > > > Checked by AVG Free Edition. > > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: > 05/08/2007 > > > 16:16 > > > > > > > > > > > > > > > -- > No virus found in this incoming message. > Checked by AVG Free Edition. > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 > 16:16 > > > No virus found in this outgoing message. > Checked by AVG Free Edition. > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 > 16:16 > > From markce at btclick.com Tue Aug 7 19:31:09 2007 From: markce at btclick.com (Mark CE) Date: Tue, 07 Aug 2007 20:31:09 +0100 Subject: [Developers] coldfusion CFHTTP COOKIE "authentication required" In-Reply-To: <8037c20b0708070938t68204139pfd4f652128f01032@mail.gmail.co m> References: <200708060934.HMR90732@c2bthomr03.btconnect.com> <8037c20b0708060834l5b1e5b6bia782c1ebb56db559@mail.gmail.com> <200708061747.DCZ07065@c2bthomr14.btconnect.com> <8037c20b0708061353s3479ed25sc18c25e9ceb99b8b@mail.gmail.com> <8037c20b0708062048h7761c7dbva46bb876e5044dde@mail.gmail.com> <200708071010.CRZ11591@c2bthomr09.btconnect.com> <8037c20b0708070938t68204139pfd4f652128f01032@mail.gmail.com> Message-ID: <200708071941.DDC30340@c2bthomr14.btconnect.com> Brilliant, Ryan, that's sorted it; goodbye to "authentication required" error. On with "Type /type/object does not have property query" ! ...solved by passing this: {"query": [{ etc }]} instead of: {"qname": {"query": [{ etc }]} } ...and I have results!!! At 17:38 07/08/2007, Ryan Miller wrote: >Mark, > >Bad news, CF automatically urlencodes the cookie which makes it >unrecognizable to freebase's api service. Why they do this I have no >idea, it's about the worst thing I've ever seen in CF. Yes, there is >an attribute for "encoded" but it is ignored on Cookie types. The >good news is there is a workaround. > >value="metaweb-user=#metaWebUserValue#;metaweb-user-info:#metaWebUserInfoValue#" >encoded="no" /> > >Be sure you're getting just the values out of the login response cookie. > > > > > > back as "Login Succeeded", so I still think the problem is in what I'm > > posting to the mqlread service. In fact the login call returns a success > > with my plain user name; so apparently email is not necessary. > > > > In fact I have also hard-coded (copied & pasted) the metaweb-user cookie > > from my browser session into the cookie param for the mqlread > call; same 400 > > problem. > > > > What I would be really keen to have is an example of working code for this > > part: > > > > > method="POST"> > > > type="FORMFIELD"> > > > value="A|u_mycookie|g_...etc...Kug" type="COOKIE"> > > > > > > I have tried adding this: > > > value="application/x-www-form-urlencoded" type="header" /> > > but it makes no difference. > > > > I have also tried the request with the "q" cfhttpparam on its own without > > the cookie. > > And with the cookie cfhttpparam on its own without the q parameter. > > And with a dummy param, leaving out both q and cookie. > > > > Same result every time. > > > > One potential problem is that my cookie has a "#" in it. > > I resolved this by replacing it with "##" which is the usual practice for > > escaping "#" in CF. > > > > > > Mark CE > > > > > > At 04:48 07/08/2007, Ryan Miller wrote: > > > > > > Mark, > > > > I was playing with the MQL Write services this afternoon and saw their > > example of using the login API, what you were tryin to do with the > > first http post in your code. After messing around I figured out that > > the username needs to be your email address. I also used a chttp > > param to specify the content type. The returned content is a JSON > > string but CF turns it into a Java ByteArrayOutputStream. Just use > > it's toString() method to see if the login succeeds (metaweb always > > returns a 200 status, even if the login fails, you need to inspect the > > JSON string to know if it succeeded. > > > > > method="POST"> > > > value="application/x-www-form-urlencoded" type="header" /> > > type="formfield" > > /> > > > > > > > > > > > > On 8/6/07, Ryan Miller wrote: > > > from what I can tell you're trying to do an HTTP POST to the freebase > > > site with your username and password sent as POST variables, getting > > > the metaweb-user cookie out of that response, than using that to do > > > your mql POST. Why not just lookup your metaweb-user cookie value out > > > of your browser and hard-code into your app? When I tried your code > > > the first POST that should return the cookie doesn't, so if you want > > > to keep going this route, concentrate there. Make sure your sending > > > the vars under the right names (including case), and fake the > > > user-agent string to a common browser. > > > > > > On 8/6/07, Mark CE wrote: > > > > > > > > > > > > Don't worry I have tried both POST and GET, many times now! > > > > > > > > Two crappy CF templates attached (testme.cfm which calls > testme2.cfm). > > I > > > > am not familiar with this list; if it doesn't accept attachments and I > > > > should be including the code in the body of this email, I guess I'll > > find > > > > out when my message comes back. > > > > > > > > Needless to say, the cookie-getting function does work and > > successfully > > > > returns the two cookies: > > > > metaweb-user and metaweb-user-info. > > > > > > > > ----------------------- > > > > Originally I wasn't deserialising the JSON response so hence the > > unhelpful > > > > error message. > > > > Now the response is: > > > > > > > > code: /api/status/error/input/invalid > > > > message: authentication required > > > > ---------------------- > > > > > > > > Thanks again > > > > Mark > > > > > > > > > > > > > > > > At 16:34 06/08/2007, you wrote: > > > > > > > > > > > > In addition to the cookie requirement, you probably need to do your > > > > cfhttp call as a POST, cfhttp is a GET by default. If that doesn't > > > > work post your cfhttp code here to the list. > > > > > > > > On 8/6/07, Mark CE wrote: > > > > > > > > > > > > > > > Hello there, > > > > > Has anyone successfully retrieved a query result from Freebase > > using > > > > > Coldfusion CFHTTP? > > > > > Or know of a reason why mine would return a 400 error? > > > > > > > > > > HTTP/1.0 400 Bad Request X-Metaweb-Cost: dt=0.001, nreqs=0 Date: > > Fri, 03 > > > > > Aug 2007 16:10:49 GMT X-Metaweb-TID: > > > > > > > cache;cache01.p01.sfo1:8101;2007-08-03T16:10:49Z;0002 > > > > > Server: Apache/2.0.58 Vary: Accept-Encoding Cache-Control: no-cache > > > > > Content-Type: applic > > > > > > > > > > If instead of CFHTTP I get my coldfusion code to output the URL to > > the > > > > > page; I copy and paste into the address bar, I get a 200 > response... > > and > > > > the > > > > > query results I would expect. > > > > > > > > > > Working code samples gratefully received!!! > > > > > Thanks > > > > > Mark CE > > > > > > > > > > > > > > > > > > > > ________________________________ > > > > > Mark Christian-Edwards > > > > > markce at btclick.com > > > > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > > Developers mailing list > > > > > Developers at freebase.com > > > > > > > http://lists.freebase.com/mailman/listinfo/developers > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > No virus found in this incoming message. > > > > Checked by AVG Free Edition. > > > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: > > 05/08/2007 > > > > 16:16 > > > > > > > > > > > > No virus found in this outgoing message. > > > > Checked by AVG Free Edition. > > > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: > > 05/08/2007 > > > > 16:16 > > > > > > > > > > > > > > > > > > > > > > > -- > > No virus found in this incoming message. > > Checked by AVG Free Edition. > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 > > 16:16 > > > > > > No virus found in this outgoing message. > > Checked by AVG Free Edition. > > Version: 7.5.476 / Virus Database: 269.11.6/938 - Release Date: 05/08/2007 > > 16:16 > > > > > > > >-- >No virus found in this incoming message. >Checked by AVG Free Edition. >Version: 7.5.476 / Virus Database: 269.11.8/940 - Release Date: >06/08/2007 16:53 -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.5.476 / Virus Database: 269.11.8/940 - Release Date: 06/08/2007 16:53 From nix at metaweb.com Tue Aug 7 20:15:32 2007 From: nix at metaweb.com (Nick Thompson) Date: Tue, 07 Aug 2007 13:15:32 -0700 Subject: [Developers] mjt 0.5.1 released Message-ID: <46B8D2E4.20507@metaweb.com> This is a bugfix release. The ``dist/mjt-0.5/mjt.js`` path now points to 0.5.1, so there is no need to update your scripts. Mjt now works with Safari 2. Known bugs on Safari 2: - unicode characters from the freebase service aren't rendered properly - this should be fixed in the service soon. Autosuggest developments: - Zak Stein provided patches to make the autosuggest example work with IE6. - Will Moffat provided code for an onchange event so you can display more info about the currently highlighted choice. - works on safari but some of the styles look ugly and the arrow keys don't work. New comments page: - Chris Maden has built an improved "recent comments" viewer. Enjoy, and keep those bug reports coming... nick From brendan at metaweb.com Tue Aug 7 23:18:40 2007 From: brendan at metaweb.com (brendan neutra) Date: Tue, 07 Aug 2007 16:18:40 -0700 Subject: [Developers] /architecure/structure schema addition-change In-Reply-To: <46B8D2E4.20507@metaweb.com> References: <46B8D2E4.20507@metaweb.com> Message-ID: <46B8FDD0.4030208@metaweb.com> Hi all, Currently an instance of /architecture/structure has a simple property "Owner" with an expected type /architecture/architectural_structure_owner This was somewhat short-sighted. I'd like to propose pointing to a compound value type (CVT) instead that would include: - the owner (as above) - the structure (as a reverse property) - start date (datetime) - stop date (datetime) This would allow us to model not just who owned it but when they owned it and perhaps other information in the future, such as details about the transaction that might be interesting from a real-estate context. For now I will leave the current owner property in place. I'd like to eventually make this schema enhancement, migrate the existing links and hide the old property in the freebase UI so it won't be used anymore. Any objections? (I won't do this right away) thanks, Brendan (/architecture admin) From markce at btclick.com Wed Aug 8 15:08:55 2007 From: markce at btclick.com (Mark CE) Date: Wed, 08 Aug 2007 16:08:55 +0100 Subject: [Developers] query syntax problem In-Reply-To: <46B8FDD0.4030208@metaweb.com> References: <46B8D2E4.20507@metaweb.com> <46B8FDD0.4030208@metaweb.com> Message-ID: <200708081509.HJS00895@c2bthomr04.btconnect.com> Hi all, I'm having a problem with some really basic query syntax. To me the location/country type definition looks as though it includes a "contains" property. So I want everything that the country "United Kingdom" contains: { "query": [{ "id": null, "name": "United Kingdom", "type": "/location/country", "contains": [] }] } But the message is returned: " Type /location/country does not have property contains " What am I doing wrong? Thanks -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.5.476 / Virus Database: 269.11.8/940 - Release Date: 06/08/2007 16:53 From will at hamstersoup.com Wed Aug 8 15:17:34 2007 From: will at hamstersoup.com (Will Moffat) Date: Wed, 8 Aug 2007 17:17:34 +0200 Subject: [Developers] query syntax problem In-Reply-To: <200708081509.HJS00895@c2bthomr04.btconnect.com> References: <46B8D2E4.20507@metaweb.com> <46B8FDD0.4030208@metaweb.com> <200708081509.HJS00895@c2bthomr04.btconnect.com> Message-ID: <2f665fe20708080817p6f8396ere5d1648f11c4fa38@mail.gmail.com> Hi Mark, If you look at the schema for type /location/country you will see that the "contains" property is actually an included property of type /location/location http://freebase.com/view/schema?id=%2Flocation%2Fcountry So you need to give the full reference for "contains": { "query":[{ "/location/location/contains":[], "id":null, "name":"United Kingdom", "type":"/location/country" }] } regards, --Will On 8/8/07, Mark CE wrote: > > Hi all, > I'm having a problem with some really basic query syntax. > > To me the location/country type definition looks as though it > includes a "contains" property. > So I want everything that the country "United Kingdom" contains: > > { > "query": [{ > "id": null, > "name": "United Kingdom", > "type": "/location/country", > "contains": [] > }] > } > > But the message is returned: " Type /location/country does not have > property contains " > > What am I doing wrong? > Thanks > > > -- > No virus found in this outgoing message. > Checked by AVG Free Edition. > Version: 7.5.476 / Virus Database: 269.11.8/940 - Release Date: 06/08/2007 16:53 > > > _______________________________________________ > Developers mailing list > Developers at freebase.com > http://lists.freebase.com/mailman/listinfo/developers > From hotfigs at gmail.com Wed Aug 8 15:37:42 2007 From: hotfigs at gmail.com (Geoff Smith) Date: Wed, 8 Aug 2007 16:37:42 +0100 Subject: [Developers] mjt firefox attempting to load img src Message-ID: Hi, I've noticed that firefox (maybe other browsers too - i've not checked) attempts to load and image in this type of structure: It attempts to load a file called ${o.src}... I would have thought the display:none would have taken care of that, guess not. The solution is to use mjt.src instead of just src. I thought I would point it out as this kind of thing could easily not be noticed - it makes the page load more slowly and hits the server unnecessarily. I also have a question, are there other attributes which could cause similar performance problems? I.e. could using class instead of mjt.class cause the browser to do some unnecessary work when it loads the page? Thanks! Geoff -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.freebase.com/pipermail/developers/attachments/20070808/ce87fbc4/attachment.htm From nix at metaweb.com Wed Aug 8 19:30:50 2007 From: nix at metaweb.com (Nick Thompson) Date: Wed, 08 Aug 2007 12:30:50 -0700 Subject: [Developers] mjt firefox attempting to load img src In-Reply-To: References: Message-ID: <46BA19EA.1040706@metaweb.com> Geoff Smith wrote: > I've noticed that firefox (maybe other browsers too - i've not checked) > attempts to load and image in this type of structure: ... > yes, good tip - if you have a tag like the browser will treat it literally and try to fetch an image before mjt gets a chance to substitute in the real url. mjt.src="$some_expression" will hide the src attribute from the browser until mjt expands it. you may still want to include a src="#" attribute with your img tag so that it validates as xhtml. the src= will be overridden by the mjt.src="..." when the template is expanded. the other place where mjt.src= comes in useful is with the