« first day (887 days earlier)      last day (2893 days later) » 
00:00 - 23:0023:00 - 00:00

12:13 AM
@HostileFork what's that about?
@RebolBot bot-source for @grahamchiu
 
@GrahamChiu RebolBot Source @for
 
@RebolBot bot-source for grahamchiu
 
@GrahamChiu RebolBot Source @grahamchiu
 
posted on April 04, 2013 by mmcghan

[Wish] Editing the document "Writing a Network Scheme for Rebol 3" by Graham Chiu sparked my interest in clearing up confusing terminology. "Port!" is used differently in Rebol than in TCP terminology, and sometimes interchangeably to mean "Port number". It took me personally a fairly long while when first learning about Internet conventions to realize that an Internet "port" wasn't some kind

 
12:33 AM
@mmcghan it would be a BIG change!
 
@GrahamChiu But is that a bad thing?
 
My preference I think is to name the sub-port, or conn, to tcp-port to make things explicit
ie. adopt a standard notation
 
@GrahamChiu It seemed like a good idea to me and R3/Backward can take care of it. Also, URL! is a misnomer, it should be URI!. And calling these "network schemes" instead of "URI schemes" is really bucking public understanding.
As one can choose to go over a network, or not.
 
Even revolutionaries have their set-way!s
All of Rebol's documentation is around port handling ... does it make it clearer to call it a connector as in Java or whatever?
 
@GrahamChiu From my own experience of an R3 "port" (groan) I feel we've proven that R2 code will simply not work unmodified, for reasons big and small. Getting in line with accepted Internet terminology instead of being different for the sake of different is probably the least of the concerns. R3/Backward will ease this form of pain, while other pains will require drinking large amounts of "port" (or liquor of your choice)
 
12:40 AM
I suspect that it was chosen as being short and sweet ..
Was Java even around when Rebol was invented?
 
And if a new person doesn't understand it, and if I look at it to try and explain it and go "wow, no...I've never looked at this stuff before myself...this is actually really confusing" then it just strikes me that some of this stuff needs to get fixed before less accommodating audiences try to grok it.
 
if you make it too clear, you might get too many people understanding rebol
@rebolbot bot-source @grahamchiu
 
@GrahamChiu RebolBot Source @grahamchiu
 
12:59 AM
posted on April 04, 2013 by Ladislav

[Comment] "This can probably be solved by fixing DECODE-URL." - this *provably* can't be solved by "fixing" DECODE-URL in any way.

 
1:10 AM
@HostileFork we don't call them network schemes, we just call them schemes. Only the schemes that implement network protocols are called network schemes :)
@GrahamChiu Java was around before Rebol was released, but Carl was purportedly in the process of inventing Rebol a bit before Java was released, even back when it was still called "Oak".
 
@BrianH Well, what if we throw URI in there? "URI scheme" as the general concept... "network URI scheme", "database URI scheme", etc etc?
Scheme being the name of a programming language related to LISP being an additional liability of using the word that way in Rebol.
I don't know if I like or dislike the word "scheme" being used here, and my indifference to it means it's not a battle I'd pick, other than thinking it clearer to mention that it's used on URIs.
 
@HostileFork I agree that uri! is a more accurate name than url!, but "scheme" just refers to the part before the initial colon, and is more often used by the Rebol community to refer to the port handler code associated with that character string, rather than to the url! itself.
@HostileFork given that we can't rename the url! type to uri! there is no reason to refer to URIs at all, it would just confuse people. Just call it a "scheme" and consider it a jargon term.
 
@BrianH I actually didn't know that "scheme" was a standard term for the part before the colon that was accepted terminology, in which case these are actually "URI Scheme Handlers" or somesuch. And why can't URL! be renamed and accommodated by R3/Backward?
 
posted on April 04, 2013 by BrianH

[Comment] No, I still want LOAD to be scheme-independent. As mentioned in #2014, with the right internal representation of the url! type, an internal representation that was logically composed of codepoints instead of octets, then LOAD could handle characters outside of the ASCII range pretty easily. That logical representation could have a UTF-8 physical representation internally, if you like.

posted on April 04, 2013 by BrianH

[Comment] Agreed, the internal treatment of url! values by LOAD and the other url! manipulation functions would need to be changed first, because url! values are getting corrupted long before DECODE-URL ever sees them. Once those other functions are fixed, and possibly a new internal model for the url! type is chosen (see #2014), then DECODE-URL can be fixed to work on the new url! data model.

 
@HostileFork because the URI vs. URL distinction is not considered to be important by the vast majority of developers, only by the W3C types. Everyone else just calls them URLs, and any mention of URIs either confuses or annoys them, or both.
 
1:22 AM
@BrianH Well, I guess. All right then "URL Scheme Handlers"
 
scheme refers to the object, handlers and associated functions that implement a protocol of some sort
 
@GrahamChiu unfortunately it is also used to refer to the name of that collection of stuff.
 
@GrahamChiu Hrrrm. I dunno. I guess I see the perspective but this is non obvious. I imagine many people who would be interested in implementing or using this stuff wouldn't know the technical term for the thing before the colon (I always called it "the protocol" and I'd probably call these "URI protocol handlers" if asked to name them myself, and hadn't looked it up on Wikipedia just now)
I can accept "URL scheme handler" as it's formally accurate, but I will predict that "here's how to 'write a scheme in Rebol'" is going to require a lot of sub-definitions to understand.
I don't really think this has to do with the naming of variables or anything. %redis-scheme.r3 is a fine name for a file, but I'd prefer more precision in documentation so it is comprehensible.
 
what did you get from wikipedia?
 
@GrahamChiu That there is consensus or formalism that they call the part before the colon the "URI scheme" (or even more precisely the "URI scheme name"). Apparently my understanding of the consensus on calling this the "protocol" is just out of date.
Aaaaand I thought it was garbage and ignored it for several years thereafter.
 
1:35 AM
so our schemes are URI scheme implementations
Back to poor old rebolbot crashing and burning on the tryrebol web server errors, I think I should just use a very simple tcp request to do the evaluation, and not use Gabriele's http scheme
 
@GrahamChiu sounds about right. Except we aren't fully compliant with the URI standards, and probably shouldn't be (see the recent ticket discussions about the issue). We're better off just being mostly compliant.
 
@GrahamChiu Well, again getting technical about all of this you've got "URI scheme handler implementations". I would say that a decent compromise for the general thing to say call them "URL Scheme Handlers", then "Network URL Scheme Handler" and "Redis URL Scheme Handler" as proposed above. To repeat myself again, I don't think this needs to affect the naming in the code. Contract as you will... we write things like foo: 10 not foo-integer: 10. Separate issue.
 
1:55 AM
I read in the news that Google is going to fork webkit and wants to remove 4.5M LOC in this way. Perhaps we also need to try harder :)
 
posted on April 04, 2013 by BrianH

[Comment] Rebol is not a pre-1.0 product, it's a pre-3.0 product. There are a lot of very practical reasons that we can't change the name of a datatype that has existed for more than a decade. In general, we can only change the names of new datatypes that were added in 3.0, and that is only until 3.0 comes out of alpha, at which even those names will be set. I can refer you to the other reject

 
2:31 AM
Dangit, CureCode keeps corrupting my comments.
 
@BrianH Well, let me give what I think is a good reason for wanting to call things as URIs, especially when they are strictly that, rather than URLs. Rebol is all about data manipulation and data access. More and more of the data "out there" will be accessed in a way that won't necessarily specify the location of the 'resource' as is done with a URL.
The ISBN scheme comes to mind, but really a URI with a scheme specifier is about identifying (the I in URI) the data you're interested in, uniquely. The method of retrieval (the protocol), and the exact location, is irrelevant in many cases and will be even more so in coming years because of the way data is being served by the 'cloud'.
So, it's quite inappropriate to call something a resource 'locator' when it is not that at all.
You're just saying "this is the data I care about, but you can get it for me from whereever".
 
It doesn't matter. We can't change the type name anyway, even if we wanted to.
 
posted on April 04, 2013 by BrianH

[Comment] Note that if LOAD decodes percent encoding the way it does now for ASCII characters, it causes problems later on in schemes which can't tell URL syntax characters that were originally percent-encoded to be used as data, from ones that weren't percent-encoded and thus should be treated as syntax. We would need some kind of internal escaping of the problematic characters, so they can be

posted on April 04, 2013 by BrianH

[Comment] This ticket is related to #482 and #1983, or perhaps a combination of the two.

 
 
1 hour later…
3:51 AM
I can't believe what I am reading. Guys, If you are going to rename ports, I will kill you :-)))
Ports are not related to networking only. Those are ariginating from Amiga times, where each app could have so called Arexx ports, allowing to interface with other apps. So - we are the standard and should care less, what other world relates ports to, if the outer world is full of idiots, not getting a grasp, after 30 years of Amiga's existance, what the feature might be useful for :-)
 
how were Arexx ports implemented?
 
I don't rember exactly. What I remembe is, that you could just link one library to your app, and it allowed your app to expose an Arexx port, and be scripted. The world is still missing on this big feature imo. Then your app defined set of commands, and its link to internal functions. It allowed stuff like starting a Mac emulator, starting Photoshop in there, issuing it few images for processing, doing something with the result, etc. Simply something like a command interface.
 
I agree on the port! name being appropriate.
 
IMO Carl wanted to achieve something similar with his Rebol/Services intitiative, in a broader sense ...
As for me - port relates to kind of "portal" ... a cross universe gate, where you simply don't precisely know, what is on the other side. So I open an encryption port, throw in (insert) some data, and wait for the result. The name is more than appropriate for me, it just needs some more broader explanation in the docs imo ...
 
4:41 AM
@pekr ImageFX over Arexx would have been more likely than Photoshop via a mac emulator (Shapeshifter?). Arexx was very handy. I remember scripting a function for Final Writer to allow me to launch and use ProCalc to insert tables as eps files.
 
4:58 AM
@BrianH, if a top level script uses a Needs: header referencing a module by name (as opposed to a file name), is there a way to set the default-suffix to be used when importing the module if you don't want to set the default in rebol.r? Obviously you can't set it in the top level script because the headers are processed before any body code.
 
5:32 AM
@RebolBot version
 
@GrahamChiu 0.0.28 5-Apr-2013
 
@GrahamChiu, let me know if you're making additional bot changes past 0.0.27 so I can incorporate them
heh
 
since the tryrebol server is the one thing that consistently kills the bot due to rebol3's inability to trap the http errors, I'm replacing the http read with a minimalistic tcp read
 
you're using that now?
in 0.0.28?
 
yes
 
5:41 AM
k, when you're satisfied with it, don't forget to commit and ping me
 
I'm not entirely happy with the way that server errors like 500 and the like cause error! s
afterall, there's no tcp networking error .. it's a server error ..
maybe this needs to be rethought out
 
this what?
 
the way the http scheme responds to errors
 
@Adrian you forgot the module-paths setting - you are meant to set that too, not leave it at its default. I'm afraid the answer is "don't do that". If you need to do stuff like that and don't want to use rebol.r for what it was designed for, compile your own version of R3 that has the settings you want. Or use import at the top level after you set your settings, instead of Needs. The import function works just fine in scripts.
 
I'm just thinking of people that might want to use the bot - would like to minimize the things they need to set up.
I didn't forget the module-paths
 
5:45 AM
@rebolbot do read rebol.com
 
; Brought to you by: tryrebol.esperconsultancy.nl
>> read rebol.com
 
Yeah, I could use import at the top level even for a non-dynamic module, but it looks neater with Needs.
 
@rebolbot do print copy/part read rebol.com 150
 
; Brought to you by: tryrebol.esperconsultancy.nl
>> print copy/part read rebol.com 150
#{
3C21646F63747970652068746D6C3E0A3C68746D6C3E3C686561643E0A3C6D65
7461206E616D653D2267656E657261746F722220636F6E74656E743D22524542
4F4C205749502057696B69222F3E0A3C6D657461206E616D653D226461746522
20636F6E74656E743D2233312D4D61722D323031332F343A30323A30332D373A
3030222F3E0A3C6D657461206E616D653D227265626F
}
 
For now, I use the file name in the top-level Needs:
 
5:46 AM
@rebolbot do print to string! copy/part read rebol.com 150
 
; Brought to you by: tryrebol.esperconsultancy.nl
>> print to string! copy/part read rebol.com 150
<!doctype html>
<html><head>
<meta name="generator" content="REBOL WIP Wiki"/>
<meta name="date" content="31-Mar-2013/4:02:03-7:00"/>
<meta name="rebo
 
now, don't you think 'read should return everything the server responds with?
Including the 200 OK and all the headers?
 
@Adrian well, in scripts, import works just fine. That is what it is designed for, especially at the top level. For that matter, import of a block calls do-needs. You don't really have to use the Needs header in scripts most of the time. The module system was designed to make Needs less necessary in general. You usually only use it in modules, and then just for importing private modules. Most of your app's modules are loaded ahead of time at the top level.
 
@GrahamChiu I guess this is where you need to consider the most common use when using it for HTTP. It should return headers with a refinement, since that need seems less common.
 
@rebolbot do help read
 
5:49 AM
; Brought to you by: tryrebol.esperconsultancy.nl
>> help read
USAGE:
    READ source /part length /seek index /string /lines

DESCRIPTION:
    Read from a file, URL, or other port.
    READ is an action value.

ARGUMENTS:
    source (port! file! url! block!)

REFINEMENTS:
    /part -- Partial read a given number of units (source relative)
        length (number!)
    /seek -- Read from a specific position (source relative)
        index (number!)
    /string -- Convert UTF and line terminators to standard text string
 
as you can see, no suitable refinement
 
sure - CC wish?
 
@Adrian that is a good approach, especially if that file makes those settings changes.
 
the issue is trying to remove refinements from the port actors rather than adding to them :)
 
@GrahamChiu that is what query is for.
 
5:52 AM
@BrianH And what do you think of using armed errors to exit from deep inside the http scheme?
 
In erroneous conditions, I'm all for it. For non-erroneous conditions, we have other non-local return methods.
 
and what constitutes an erroneous condition?
a 404 ?
a 503?
 
When something goes wrong. A 404 might be such a case.
Are you rewriting the HTTP scheme? If so, yay!
 
@BrianH no, not at all
in the R2 http scheme, if you hit a 503, you got an error. Now if the server returned an explanation for the eg. Amazon API error in the body content, you could not retrieve it
I think the same thing happens with R3
 
In general we are trying to only use errors in more definitely erroneous conditions. That makes errors a better diagnostic tool, and less of a burden. The official policy is that errors should be your friends, that they should stop execution when you really want it stopped. That means not triggering errors in arguably non-erroneous conditions. However, that case sounds like an error.
 
5:59 AM
@BrianH what sort of error?
 
An access error, I'd think. I'd have to review the collection to choose which one.
You get access errors in similar situations with files. It seems analogous.
 
with http api errors, you want the information which you're given as to what went wrong
 
But I'd have to review the code to be sure, and see what counts as best practices nowadays.
BBL, must sleep.
 
@GrahamChiu HTTP errors are really status codes and don't necessarily indicate the 'end of the road' in attempting to communicate with that server. You'll probably get useful re-try information along with the 5xx status codes.
 
@Adrian Yes, I'd agree. So, making one go thru the hoops to get that data seems wrong
 
6:07 AM
What might be useful is for some specified status codes to return an error, but don't treat them as such otherwise.
 
should 'read return a string? Maybe the scheme should construct an object and return that instead
 
This is because at the knowledge of whether to treat a status code as an error lies at the level of the application, not the scheme handler.
 
so, unless there has been an actual networking error, the scheme should return the data it gets
 
yup
 
now to convince the rest of the rebol community :)
 
6:10 AM
@GrahamChiu what do you see the object being composed of?
 
a header object and a content object
and server response object
 
You've already got access to the headers, though, no?
 
dunno
 
how do you get a status with the current implementation?
this also must be available
 
if there's no error, it's a 200 :)
 
6:14 AM
hmm, has to be more to it than that
 
otherwise you get an armed error with the information
 
there are different 2xx codes, for example
what if you're interested in which one you got?
 
pass
 
Can't believe Gabriele didn't think of this
he must have - I guess it's easy enough to look at the code
 
the http scheme is complicated .. perhaps he has
'read is meant as an atomic operation which gives you only the content
if you want more, I think you need to setup your own async handler
 
6:23 AM
@GrahamChiu so the response code is not saved by numeric value, but by equivalent name such as 'ok for 2xx codes or 'see-other for a 303. The 2xx could be further refined. These literal codes are saved under port/state/info/response-parsed.
 
if you do an atomic read, you won't get that information
 
6:50 AM
@rebolbot version
 
@GrahamChiu 0.0.29 5-Apr-2013
 
HTTP/1.1 200 OK
Date: Fri, 05 Apr 2013 06:51:45 GMT
Server: Apache
Last-Modified: Sat, 08 Oct 2011 18:14:02 GMT
Accept-Ranges: bytes
Content-Length: 14137
Connection: close
Content-Type: text/html

<!doctype html>
<html><head>
<meta name="generator" content="REBOL WIP Wiki"/>
<meta name="date" content="8-Oct-2011/11:14:02-7:00"/>
<meta name="rebol-version" content="2.100.97.4.2"/>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/>
<meta http-equiv="Pragma" content="no-cache" />
 
HTTP/1.0 200 OK
Content-Type: text/html; charset=UTF-8
Expires: Fri, 05 Apr 2013 06:55:42 GMT
Date: Fri, 05 Apr 2013 06:55:42 GMT
Cache-Control: private, max-age=0
Last-Modified: Mon, 25 Mar 2013 17:28:55 GMT
ETag: "ed437d1a-ec45-4e31-8733-ba2891861566"
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Server: GSE

<!DOCTYPE html>
<html b:version='2' class='v2' dir='ltr' xmlns='http://www.w3.org/1999/xhtml' xmlns:b='http://www.google.com/2005/gml/b' xmlns:data='http://www.google.com/2005/gml/data' xmlns:expr='http://www.google.com/2005/gml/expr'>
 
6:56 AM
Guess there's a text limit on a post
@RebolBot bot-source for @grahamchiu
 
@GrahamChiu RebolBot Source @grahamchiu
 
@rebolbot version
 
@GrahamChiu 0.0.29 5-Apr-2013
 
7:19 AM
@GrahamChiu, do you have anything against me moving the key shortcut handling in process-bot-cmd into the dialect rules?
 
@Adrian those are legacy commands ...
 
don't want to keep them?
 
well, if you can keep them .. okay with me
 
might be easier for some people to remember them
k, I'll keep 'em
 
7:35 AM
posted on April 05, 2013 by fork

[Comment] Okay, rant time. I don't personally know about connector, as a name. It's unabbreviated from "conn" in Grant's paper and that's a kind of arbitrary reason to pick it, without study of how it's used in other languages (I don't offhand know of an established meaning). But I agree that "port" will likely contribute to repeated misunderstandings and therefore lost opportunities. This

 
7:56 AM
posted on April 05, 2013 by bitsoma

[Comment] This comment has nothing to do with the topic itself, but I feel I need to say this anyway as a long time Rebol 2 user: @fork: +100

 
8:35 AM
posted on April 05, 2013 by Ladislav

[Comment] Hmm, how exactly is #1983 related?

posted on April 05, 2013 by fork

[Comment] @bitsoma thanks... In the meantime, @DocKimbel sent me a good argument that it's common Internet usage that broke from the more general CS traditions. If you don't start from the Berkeley sockets article on Wikipedia, but rather start from their definition of "Port (Computer Networking)", it supports Rebol's usage: http://en.wikipedia.org/wiki/Port_(computer_networking) (For that

 
8:50 AM
@HostileFork, well I've started to use tcp-port as the internal variable name to refer to what others call sub-port or whatever.
 
posted on April 05, 2013 by rebolek

[Comment] I guess it should be http://curecode.org/rebol3/ticket.rsp?id=1986 ?

 
9:18 AM
@rebolek - thanks for straightening it out
@rebolek - just a note, in CC you can use just #1986 to refer to other tickets, no need to use full URL
 
@HostileFork Thanks for upvoting me! I am in now :-)
 
@Ladislav Thanks, I was wondering how you did it. :)
 
@rebolbot faq for arie
 
@GrahamChiu StackOverflow Chat FAQ @arie
 
@Arie should tell you how to change your avatar image
 
9:39 AM
Just changed my avatar and profile!
 
@Arie takes 30 mins or more for the avatar to change across the network
 
@GrahamChiu Ah, i was already searching the web for that. Thx!
 
@Arie it's in our faq but perhaps doesn't give you an idea of how long it can take ..
 
 
3 hours later…
12:54 PM
posted on April 05, 2013 by abolka

[Comment] A port! in Rebol is used for much more than networking. It is really more like an interface to a multitude of other systems; and therefore, in usage, much closer to the other common concept of port: https://en.wikipedia.org/wiki/Computer_port_(hardware) (Think: USB port, printer port, display port, ...) In Rebol, we have TCP ports, DNS ports, event ports, file ports, the system por

 
1:36 PM
@GrahamChiu Do you have an easily reproducible case for Rebolbot crashing on HTTP errors?
 
 
2 hours later…
3:57 PM
@GrahamChiu @earl, are you guys OK with moving the bot code to be a proper repo under rebolsource after I'm done with the modularization?
I really feel this could be a great PR thing for Rebol. I have plans...
 
@Arie Heya Arie... glad you can chat now! When you're around write a note, and we can pitch to you why we sit around debating these languages all day and/or night. :-) RebolBot helps us with demonstrating code samples online... (Rebol 3 alpha recently became open source in December, and that's caused a community push to get involved in design decisions to "finish it", and to cohere with the design of another newer variant called Red.)
@Bracketworks Welcome, and hey that's a neat avatar! See my note to @arie about when you're around and interested, we an show you some Rebol stuff if you're not already a user...
 
@HostileFork I don't see @Bracketworks - what was his avatar?
 
@Adrian Shows as last avatar in the list for me, faded from inactivity: http://stackoverflow.com/users/409279/bracketworks
 
weird that the list of users is not the same for everyone
 
@Adrian Refreshed the page and its gone...some sort of bug in the chat client I guess.
 
4:23 PM
@Adrian I don't think Graham's repo is particularly improper :)
 
well, it's not really a repo dedicated to the bot - the source is in a scripts directory under the Rebol3 repo in his account
When I'm done, there will be a bunch of files.
It deserves a full repo, IMO.
And, I'm hoping, it will become a community maintained project.
But it's up to Graham - though with the Apache 2 license, I could do a hostile fork. Mwahahaaha!
 
Ah, I see.
 
Would you see a move like I proposed to be 'polluting' the rebolsource profile?
 
4:38 PM
Besides redis://, what are some other common unusual scheme strings that are out there for which people have written "URL Scheme Handlers"? (I'm going to argue for this terminology.)
 
@Adrian No. Currently see neither strong pros nor strong cons :)
@HostileFork You want a list of "uncommon" Rebol schemes?
 
@earl Doesn't have to be a long list, just a couple you know offhand...the most popular ones people are using, I guess.
 
R2:
>> words-of system/schemes
== [default Finger Whois Daytime SMTP ESMTP POP IMAP HTTP FTP NNTP]
R3:
>> words-of system/schemes
== [system console callback file dir event dns tcp clipboard http]
Graham's protocol implementations:
(daytime, dns, fax (hylafax ftp), http, imap, jdbcbridge, sl4a, smtp, time)
FastCGI for R2 has been implemented as a scheme, IIRC.
ODBC as well.
Nenad has written MySQL, PostgreSQL, LDAP, NTLM, and async call schemes. (softinnov.org)
@rgchris' QuarterMaster framework has a FS abstraction scheme (called roughcut, IIRC).
I also seem to remember pure-Rebol SQL RDBMS impls based on schemes.
Here's a query for scheme implementations in the rebol.org script library: rebol.org/search.r?find=net-install
(sql, encryption, sqlite, dns, paradox, rcon, snmp, telnet)
 
5:03 PM
@rgchris, are you around?
 
@Adrian Gabriele quit the R3 project for unrelated reasons long before he finished the HTTP scheme.
 
@BrianH Well, that was meant to be taken as "I'm sure he thought of those issues.." rather than "How could he not consider those issues...". Wasn't supposed to be accusatory.
 
@Adrian just FYI :)
 
@rebolbot do words-of system/schemes
 
; Brought to you by: tryrebol.esperconsultancy.nl
>> words-of system/schemes
== [system console callback file dir event dns tcp clipboard http]
 
5:12 PM
Thanks @earl...
 
@GrahamChiu, it sounds like read and write of the HTTP scheme are not making a sufficient distinction between the behavior of the url action and the open port action. When working on a url! they should just return the data if they can, and trigger an error if they can't - URL actions are supposed to be high-level. The error triggered should include as an argument which result code was the error. The open port behavior should be more flexible.
 
There is a timer scheme which is not enabled yet
 
posted on April 05, 2013 by BrianH

[Comment] Fork, the problem isn't the TYPE?/word function in particular, it is what that function does, which is return a word that corresponds to a datatype value. It can only return one word, and that word becomes the primary name of the datatype. I can show you the type of code that requires word comparison rather than datatype comparison, and such code can't necessarily be rewritten in some

 
5:28 PM
@earl HTTP errors occur once a week or less so hard to reproduce without a server that can create errors on demand
 
@GrahamChiu What type of errors do you need?
 
500s
I found yesterday that tryrebol bans you if you send a malformed user agent
I'm on my N7 at present
 
@GrahamChiu You can set this test server to return arbitrary codes - posttestserver.com
 
@RebolBot find source bot
 
5:37 PM
@earlbot test
@GrahamChiu doesn't crash for me with a simple 500 error from the remote-execution site
 
I wasn't able to reproduce the crashes
 
HTTP/1.1 500 Internal Server Error
Date: Fri, 05 Apr 2013 17:51:04 GMT
Server: Apache/2.2.9
Connection: close
Content-Type: text/plain

This is a forced internal server error.
 
5:59 PM
@earl do you see any reason why in the bot source a http error can cause a crash?
 
@GrahamChiu Nothing obvious, no.
 
@Ladislav, I am having to make edits to comments in issue.cc/r3/2014 to respond to your new arguments, since you deleted or changed your old arguments. Bear with me for a moment. We are more in agreement than you might think.
 
This seems to be fixed in r3/droid issue.cc/r3/1918
 
6:16 PM
@GrahamChiu, you didn't comment on the bot repo suggestion...
 
6:27 PM
@BrianH If you want to test it, have a look at gist.github.com/ladislav/5319674
Here are some test results:

> mold-url load-url "http://a.b.c/d?e=f%26&g=č"
== "http://a.b.c/d?e=f%26&g=č"

>> mold-url load-url "http://a.b.c/d?e=f%26&g=h"
== "http://a.b.c/d?e=f%26&g=h"

>> mold-url load-url "file://program%20files"
== "file://program%20files"

>> mold-url load-url "http://a.b.c/d?e=f%26&g=%c4%8d"
== "http://a.b.c/d?e=f%26&g=č"
 
@Ladislav there are two separate issues. My new comments will make that clear. Wait until I finish.
 
BTW, I think that the above "internal format" can be called "escape-free"
 
Wait, I have another model in mind that would be better.
 
In addition to being "escape free" it is also a "total format" in that it does not have any "invalid content" cases
which means that it "automatically" maintains consistency
 
6:47 PM
Not done yet.
 
@earl, do you have a link to github's Rebol syntax coloring handy? I can't seem to find where you gave it out some time ago. Getting tired of seeing the colouring broken by <= (prot-http shows this too). I'll try to submit a fix.
 
@Adrian Here's a patch fixing the immediate issue: gist.github.com/earl/b01575374678f00651d9
 
yeah, but didn't you have a link to the file GitHub's using?
so you've submitted a pull request and they haven't accepted yet?
 
No, I didn't yet get around to test it further or submit the fix.
 
k
 
6:51 PM
If you find some time to do so, I'd be more than happy if you could take it from here :)
Just in case, here's a direct link to the Rebol lexer used in Pygments: bitbucket.org/birkenfeld/pygments-main/src/…
 
I'll do it once I'm done with the bot changes. Should be done, hopefully, later today.
 
The problem, as far as I can see, is that the "tag" rules are too eager, and match before the "word" rules.
So <= is matched as tag instead of as word, and the tag rule runs on for a while trying to match to the tag end.
 
yeah, that looks like the explanation
 
Maybe a more proper fix would be to make the tag rules less aggressive. But the above fix was easier :)
 
OK, @Ladislav, I've changed one comment, my second on the ticket. Look at that comment and tell me what you think.
BBL, going to a meeting.
 
6:56 PM
@earl Have you seen any instances where, other than for the <= case, the rule is too aggressive?
 
@Adrian No, but I haven't really investigated this.
 
7:23 PM
@Adrian all of the arrow-based words are special cases, not part of the regular word recognition syntax.
 
@BrianH are you talking about GitHub's regex rules here?
 
@Adrian The TRANSCODE rules. If Github's rules don't have the same precedence, they should be fixed.
 
the problem seems to be that <= looks to be the beginning of a tag match as far as github's regexes are concerned
 
The problem might be that Github is using regex, if it is. It's harder to specify proper precedence in regex.
 
it is using regex
@earl gave the link to his proposed patch, above
 
7:36 PM
@Ladislav, I am now editing my third comment to make it make the same point about LOAD and such not needing to be scheme-specific, instead explaining where the scheme-specific behavior should go.
Added one more paragraph to the second comment, to make it clear that the other behavioral characteristics of the escaping model would apply to internal percent encoding too if we decided to keep that.
 
7:53 PM
@Adrian in body, not yet in mind.
 
just woke up? :-)
@rgchris I was going to ask what you thought of the idea of making your RSS script a bot module. This would not necessarily be the one we actually use here, but it would be another good example of what the bot could do.
 
@earl @HostileFork Roughcut is a flat-file Active Record implementation (I have a similar scheme built on top of MySQL); WRT is an abstracted filesystem designed for controlled access to the actual filesystem.
@Adrian just completed a 30hr trip from Arran to Philly :)
 
Btw, @rgchris, I would do the work - just need to be pointed to the right source.
30 hours? Are you nuts?
You sat on your butt for that long?
 
@Adrian By way of Manchester. One sleep there...
 
@Ladislav, done with the third comment. Take a look. I'm almost to the point where it would make sense to compare to your test implementation of the model.
 
8:01 PM
@Adrian How do you envision it working? The RSS reader for StackOverflow is here: reb4.me/r3/so-answers
 
well, the bot already does a periodic check, it could do one for RSS feeds as well
and insert directly as a message, bypassing the chat's RSS feature
This would, eventually, be more useful in a chat system that doesn't have the RSS feeds integrated.
 
The SO script should be enough of a pointer for working with RSS/Atom, the other RSS feeds are based on loading JSON or Rebol source.
For example, CureCode is based on this feed: curecode.org/rebol3/feed.rsp?prj=1
 
k, thanks
 
Wait, that's not right—CureCode is XML.
Get the updates from the XML:
require %markup/xml.r
feed: load-xml/dom curecode.org/rebol3/feed.rsp?prj=1
items: feed/get-by-tag <item>
remove-each item items [
    not find item/get <title> "Added"
]
clear skip items 10
tickets: unique collect [
    foreach item items [
        keep to-integer find/tail item/get <link> "?id="
    ]
]
 
@DocKimbel, I had a lot of trouble writing comment 3777 here: issue.cc/r3/2013 - CC kept corrupting the percent encoding. I got it to a point where it looks correct now, but if I edited that comment it would be corrupt again. It looks like the comment is getting corrupted by both url-decoding and HTML entity decoding, in both cases unnecessary.
 
8:19 PM
@rgchris what/where is xml.r?
 
It's AltXML (sorry, renamed within my QM setup).
Don't (yet?) have an equivalent of the Universal Feed Parser, each feed is loaded and processed ad hoc.
 
@Brian Could you cross-post it to !Curecode channel in AltMe please, so I can keep track of it?
 
@DocKimbel will do. And I'll check the code later to see if I can figure out the real problem.
Appropriately enough, that ticket is related to a similar problem in R3 itself :(
 
If there's both url-decoding and HTML entity decoding for comments, there must be a reason (but can't remember it without going through the code).
BTW, I'm moving tomorrow to a new place, on the shore, 120km from here, beautiful seasight and much faster Internet access (ADSL, rather than Wimax currently, at least, I should be still be connected even when it's raining).
 
8:36 PM
Well, if the form submission of the comment is url-encoded, then the % two hex digit sequences in the data itself should be escaped in the original submission. However, it looks like the url-encoding is being decoded again at some point. And it looks like the decoding of HTML entities is happening in the browser itself, suggesting that actual entities aren't being escaped properly at some point.
 
@DocKimbel Sounds very nice :)
@rgchris Did you happen to try your OAuth impl against Github yet?
 
@earl It is! :-) Will post a photo or two once installed.
@BrianH the % two hex digit sequences in the data itself should be escaped in the original submission That's probably the cause of the issue.
 
Just guessing, haven't seen the code yet :)
 
@BrianH Given the time you're spending on CC, by now, you probably know it better than me. ;-)
I've haven't used it since I've quit Softinnov, 2 years ago.
 
Done some web development before, these are just guesses based on seeing problems like this in other web projects. But you're right, I've probably generated a lot of usage data :)
 
8:48 PM
Quick question: if I want a http:// port to be opened immediately with make port! (or whatever), how is it again that I ask it to already be connected at the time of creation?
 
@HostileFork Want to try a reformulation?
 
@earl Um, a reformulation of my question? Well Graham says that open http://google.com doesn't immediately return a connected port, and nothing's gone over the network yet. If you want to actually connect you have to then call open on the PORT! that the first call returned. Then he says you can override this with a spec block. How would I write that one line.
 
@HostileFork For the current HTTP implementation, you can't even force the TCP subport to connect with a second open.
 
@earl If you could, how would you? What's the convention for writing that one line, even if it won't work right now?
 
@HostileFork No convention, yet, really. For TCP you'd write something like:
p: open open tcp://1.2.3.4:5678
 
8:58 PM
@earl Okay, so something like make port! [url: http://google.com connected: true] does not now exist as a convention for TCP schemes and there is no plan for this convention which scheme authors would accept the names "url" and "connected"?
 
@HostileFork Wouldn't do that with URL, as make port! is a datatype constructor that already requires a specific format. connect could be useful, though.
But if you already use a port constructor, the second open would probably be more natural anyway:
open make port! [scheme: 'http host: "google.com"]
But maybe that would need two opens as well, let me check.
 
Where is the format of make port! documented?
 
@RebolBot do ? system/standard/port-spec
 
; Brought to you by: tryrebol.esperconsultancy.nl
>> ? system/standard/port-spec-head
SYSTEM/STANDARD/PORT-SPEC-HEAD is an object of value:
   title           none!     none
   scheme          none!     none
   ref             none!     none
   path            none!     none
 
@RebolBot do ? system/standard/port-spec-net
 
9:06 PM
; Brought to you by: tryrebol.esperconsultancy.nl
>> ? system/standard/port-spec-net
SYSTEM/STANDARD/PORT-SPEC-NET is an object of value:
   title           none!     none
   scheme          none!     none
   ref             none!     none
   path            none!     none
   host            none!     none
   port-id         integer!  80
 
Okay. But if you throw more stuff in there, the scheme can use it. So http could add "connect"
 
Yes. And the make port! spec is dispatched through an intrinsic, so we could adapt that as well:
 
Okay. I see. Sort of. Thanks...
 
When you call make port!, during the internal processing the above Rebol code is called as well.
 
@earl No, I've not. Hopefully it'll be plain sailing :)
 
9:12 PM
Okay, so the minimum I have to provide to create a port is something like make port! [scheme: 'foo]. The rest is convention.
 
@HostileFork Yes.
 
And that also requires that a foo scheme be registered and loaded in.
 
And for this minimum, you could also do make port! 'foo.
 
Got it
 
But we could relax the make-port* intrinsic to accept a block! with an url field as well, and extract the scheme from the url. (This supplants my earlier statement, that we can't easily change the format for make port!.)
 
9:16 PM
@DocKimbel Not really an endorsement, but I've been using my Instagram account for getting one or two snaps up quickly. Flickr dump comes after...
@earl Looks like it is OAuth 2—may take more than 5mins to set up...
 
@rgchris Does your code support OAuth 2 in principle?
 
@rgchris Beautiful photos Chris! When I saw this one, that music started playing in my head...:-)
 
9:56 PM
@earl I believe the same principles are involved, I'm not certain what the differences are. Was OAuth 2 standardised?
Looking at the GitHub API some differences are notable, but it'd be a good site to get working.
@DocKimbel :) Thks!
 
@Ladislav OK, I can check your proposal now. It seems to be missing some functions. I'll see what I can do to fill them in.
 
10:11 PM
@Adrian I use this definition for tags: reb4.me/r/rebol#Tag
 
@rgchris I think OAuth 2 is actually the version that was supposed to be standardised.
 
@earl did it settle? I thought there were some issues...
 
It's also used by Google's APIs.
@rgchris No idea, honestly.
 
@rgchris the problem is with regex scanning for github syntax colouring
 
@earl Ah well, something to look into. Or do GitHub (then Google) and see if it works elsewhere.
 
10:51 PM
@Adrian I don't know the pros and cons of your proposal. One thing for sure, I'm not familiar with the pull/push etc of git!
 
well, you already have the script on github, but it should just be in it's own repo now that it's gonna take off :-)
i.e. not just be one file in a sub-dir of the Rebol3 repo
We could both be owners of that repo in case things need to be done and one or the other isn't around. Don't worry though, wrt github proficiency - I'm not an expert by any means, so you're not alone.
 
@Adrian Well, go ahead then :)
As long as I don't have too much work to do!
@Adrian BTW, I have seen no signs of interest for the bot outside our group here
 
k - if @earl is opposed to putting it under the rebolsource user I'll just create a new profile
There are a few reasons for it not having gotten more interest, I think.
- the script, as it is now still requires too much setup to get going (the screencast and modularization should help)
With the base script being so small now, people shouldn't find it overwhelming. Also, they can look at the individual command modules and create similar ones based off of these.
 
00:00 - 23:0023:00 - 00:00

« first day (887 days earlier)      last day (2893 days later) »