This is a public chat log generated from the #semsol IRC channel.
09:10:15
bengee: shouldn't 'DELETE { ?s ?p ?o }' delete all triples in the store?
09:10:26
bengee: can you explain how $store->insert($doc, $g) works? $store->insert('file.ttl', '<main>') on empty store doesn't work, though from what I understood it should
09:11:19
you may need DELETE {?s ?p ?o} WHERE {?s ?p ?o}
09:12:17
and $store->insert($actual_doc, "http://...")
09:13:07
bengee: so the $astual_doc part I got right?
09:13:12
no
09:13:19
a doc, not a filename
09:13:29
so a file pointer?
09:13:34
doc can be an ARC structure, or a string
09:13:44
aah
09:13:49
rdf/xml, or turtle etc
09:14:13
I tried arc structure but that didnt work - because of the graph I suppose
09:14:39
the graph: what if I need this relatively to my script - it isn't fixed uri thing
09:15:10
it'll always be stored as absolute URI
09:17:08
anyway I am quite confused what URIs should I use for my graph names... it is just a script... for normal uris in the graphs I use <#somthing> (if it's not defined in any voc) I hope that's right
09:17:40
yep, that should work
09:18:27
so can I somehow pass relative graph uri to insert()?
09:18:40
not sure
09:20:23
how does it store the quads when you just use "something"? I'm not sure if insert() auto-generates a full uri
09:20:55
what about using 'http://this/graphname'? the uri is only used internaly by arc or not so it should be ok, or not?
09:21:30
(wondering if the uri must make sense)
09:21:48
you can always check what ends up in the store by doing a query("SELECT * WHERE {GRAPH ?g {?s ?p ?o}}")
09:22:12
arc doesn't really care if graph (or other) URIs make sense
09:22:21
you can also use urn:
09:22:51
or make up your own protocol local:myapp:foo
09:23:44
ok, I better use that I think
15:16:04
bengee: I am having problems with LOADing graphs... error: | ['0'] = String(131) "Socket error: Could not connect to "http://www.w3.org/2000/01/rdf-schema" (proxy: 0) in ARC2_Reader via ARC2_StoreLoadQueryHandler"
15:16:08
| ['1'] = String(76) "missing stream in "getFormat" via ARC2_Reader via ARC2_StoreLoadQueryHandler"
15:16:11
| ['2'] = String(95) "No loader available for "http://www.w3.org/2000/01/rdf-schema#": in ARC2_StoreLoadQueryHandler"
15:16:17
bengee: any idea what this might be?
15:16:46
the http connection failed
15:19:14
any idea what setup normally should work?
15:19:36
arc uses fsockopen
15:21:05
can you do fsockopen("www.w3.org", 80); w/o problems?
15:22:08
Unable to find the socket transport "http" - did you forget to enable it when you configured PHP? (0)
15:22:21
ok, will look into my php config
15:22:22
ah
15:24:40
wondering if that is another php5 thing
15:26:03
you didn't have the "http" in the first parameter of fsockopen, did you?
15:27:59
yes
15:28:19
trying http://www.w3.org/2002/07/owl#
15:28:58
the 1st fsockopen argument should be just "w3.org" (or "www.w3.org"), i.e. no protocol
15:30:15
hm, then I get php_network_getaddresses: getaddrinfo failed: Name or service not known
15:31:07
ah, maybe the system can't resolve the domain name, then
15:35:12
hmm I have no idea how to fix this
15:39:13
seems related: http://bugs.php.net/bug.php?id=11058
15:40:27
that is almost 8 years old... Im sure someone would fix it by now if it was a bug
15:40:53
which php version are you using?
15:41:41
or RH9 perhaps?
15:42:10
5.2.9
15:42:32
then it's probably some OS configuration thing
15:53:06
bengee: I was advised to use http://cz2.php.net/manual/en/function.file-get-contents.php instead of fsockopen
15:54:27
ok, for arc you'll need fsockopen, though
15:55:23
why is fsockopen necessary?
15:55:49
it supports post, and gives access to http headers
15:56:04
and streaming
16:08:29
did testing with similar code what arc uses: http://codepad.org/q993fKod weird
16:12:37
odd indeed
16:13:19
bengee: could you please paste what you have in "Registered Stream Socket Transports" field in phpinfo()?
16:15:40
tcp, udp, unix, udg, ssl, sslv3, sslv2, tls
16:15:50
but tcp should be sufficient
16:16:11
mine is same
16:16:29
php 5.2.5 here
16:22:05
bengee: $s = @fsockopen($parts['host'], 80); #ojirio $parts['port']);
16:22:49
bengee: this is what I changed ARC2_Reader.php line 170 to and it works
16:23:49
oh, cool. then it'll be fixable
16:24:25
could you paste a print_r($parts)
16:24:46
the system should auto-set the port to 80 if it's empty
16:25:06
Array ( [scheme] => http [host] => www.w3.org [path] => /2002/07/owl [port] => 80 ) Array ( [scheme] => http [host] => www.w3.org [path] => /2000/01/rdf-schema [port] => 80 )
16:25:47
hm, that makes no senses, then
16:25:53
gtg now, will be here at night maybe, tomorrow a bit and at night
16:26:02
yeah it does not, weird
17:33:11
bengee: ARC is fine, no need for changes... the bug was somewhere in my configuration of php
17:33:26
phew, good
17:33:40
bengee: might have been that I had short tags turned off
17:34:07
let's hope it stays away. non-reproduceable bugs are even worse than fix ones
