Subscribe

2016-06-02 Thread C K Kashyap

Re: Making json.l parse floating point

2019-03-28 Thread C K Kashyap
Thans Alex, Regarding the (local) - I'll take a look if I can produce a Pull Request with the fix. I wonder though if it has anything to do with the "problem with namespace" mentioned under the "Usage" section of https://github.com/aw/picolisp-json Regards, Kashyap On Wed, Mar 27, 2019 at 11:51

Request for review of my string to float function

2019-03-30 Thread C K Kashyap
Hi, While working on the json library I had to write a string to float function. In a list of characters when I encounter a digit, I'd like to go over the rest of the list and consume all the digits (and possibly a period) that form a number. I'd appreciate some feedback from a Lispiness and

Re: Making json.l parse floating point

2019-03-30 Thread C K Kashyap
Looks like this PR was closed. Shouldn't we iterate and get this fixed. I am happy to update the PR. Regards, Kashyap On Sat, Mar 30, 2019 at 4:32 AM Alexander Burger wrote: > On Sat, Mar 30, 2019 at 10:51:44AM +, Alexander Williams wrote: > >

Re: Request for review of my string to float function

2019-03-30 Thread C K Kashyap
Thanks Alex, Sorry ... I was distracted exploring vip :) ... I like the rule - "In PicoLisp a shorter program is also faster" :) What I take away is this. Whether it is 1 byte or 32 per character, one will have to consider a case when the whole file does not fit in memory (although a factor of

Re: Request for review of my string to float function

2019-03-30 Thread C K Kashyap
Thank you so much Alex, I just love this - #-> (and (= "." (car Lst)) (on P)) :) The sample you shared certainly looks more elegant. I have a follow up question though - we seem to do 3 iterations in it, the main one, one for length and one for member. Coming to think of it, given my scenario,

Re: Making json.l parse floating point

2019-03-28 Thread C K Kashyap
Super that works like a charm ... I'll create a PR :) On Thu, Mar 28, 2019 at 7:56 AM Alexander Burger wrote: > Hi Kashyap, > > > Regarding the (local) - I'll take a look if I can produce a Pull Request > > with the fix. I wonder though if it has anything to do with the "problem > > with

Making json.l parse floating point

2019-03-27 Thread C K Kashyap
Hi, I am trying to write a script to parse data from IEX ( https://iextrading.com/developer/docs/) - naturally, the stock quotes are in floating point numbers. I made a tiny change to support floating point (to be used with scaling that is). I wanted to get it reviewed to confirm if I am not

Re: Another newbie question

2019-02-25 Thread C K Kashyap
Super - got it. I am getting so excited as I inch towards "understanding" the whole thing! On Sun, Feb 24, 2019 at 10:47 PM Alexander Burger wrote: > Hi Kashyap, > > > I was trying to follow through what happens when I run (de f (x y) (+ x > y)) > > using printf debugging in minipicolisp. > > >

Re: A possible way to build for windows

2019-02-25 Thread C K Kashyap
I may have a trick to make things easier! As a first step to validate the idea this is what I tried - I took the x86-64.linux.base.s and removed the definition of doDe (this was a random choice). I added the definition of doDe in another assembly (extra.nasm) in nasm syntax - global doDe extern

Quick comments

2019-03-01 Thread C K Kashyap
Hi, I've been hacking on PicoLisp in the last couple of days and I noticed a couple of things that I have to say it out (the bliss is too hard to keep inside)! The sense of liberation I feel every time I am able to go look into the source "all the way down" is simply amazing. I've attempted to

Question about assembly in x86-64.l

2019-03-03 Thread C K Kashyap
Hi, I've made some progress with targeting nasm assembler - https://github.com/ckkashyap/picoLisp/tree/nasm/src64. I am a little confused by x86-64.l:776 (prinst "lea" "(5f-5b)(%r11)" "%r11") ) I don't see any any "5:" following this so what is the idea of using "5f" ? Regards, Kashyap

Re: A possible way to build for windows

2019-02-26 Thread C K Kashyap
can > avoid HTTP altogether. > > Regards, > Joe > > > > On Sun, Feb 24, 2019 at 9:50 PM C K Kashyap wrote: > >> Hi, >> I have been considering the idea of getting picolisp to run on windows >> (without a heavy weight setup - cygwin/mingw) for a while no

A possible way to build for windows

2019-02-24 Thread C K Kashyap
Hi, I have been considering the idea of getting picolisp to run on windows (without a heavy weight setup - cygwin/mingw) for a while now. What if I try and target nasm instead of gnu assembler? That should work. Regarding the POSIX dependency, I think it should be a matter of making all the

Another newbie question

2019-02-24 Thread C K Kashyap
Hi, I was trying to follow through what happens when I run (de f (x y) (+ x y)) using printf debugging in minipicolisp. If I understand correctly, "de" is read in at io.c:385 if (x = isIntern(tail(y), Intern)) However, what I am having some trouble understanding is - when does the mapping to

Re: Question about assembly in x86-64.l

2019-03-05 Thread C K Kashyap
? Regards, Kashyap On Mon, Mar 4, 2019 at 6:50 AM Alexander Burger wrote: > On Sun, Mar 03, 2019 at 09:39:24PM -0800, C K Kashyap wrote: > > I've made some progress with targeting nasm assembler - > > This is a good thing, but what would seem a lot more feasible to me is > targ

Re: Question about assembly in x86-64.l

2019-03-05 Thread C K Kashyap
Hi Alex, I'll need some help understanding the PIC code a bit - can you please give an example in the generated picolisp assembly that relies on position dependent code? Regards, Kashyap On Tue, Mar 5, 2019 at 10:28 AM Alexander Burger wrote: > > Btw ... just want to double check here - there

Need some help with understanding the type predicates in MiniPicoLisp

2019-02-22 Thread C K Kashyap
Hi, I am having some trouble understanding the predicates and would really appreciate some explanation. /* Predicates */ #define isNil(x)((x)==Nil) #define isTxt(x)(num(x)&1) #define isNum(x)(num(x)&2) #define isSym(x)(num(x)) #define isSymb(x)

Re: Need some help with understanding the type predicates in MiniPicoLisp

2019-02-23 Thread C K Kashyap
Ah!!! ... got it. Thanks Alex.

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-16 Thread C K Kashyap
AM Alfonso Villén wrote: > Hi Kashyap, > > it's also possible that the OpenGL drivers simply don't support OpenGL 3.3 > core profile, or that there's no OpenGL support at all... > > Am Sa., 16. März 2019 um 05:25 Uhr schrieb C K Kashyap < > ckkash...@gmail.com>: &g

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-16 Thread C K Kashyap
, 2019 at 8:13 AM C K Kashyap wrote: > Hi Alfonso, > Getting to work with SDL was on my TODO anyway - so it's my pleasure to > test it out :) and Thank you! > > I'll dig further - since it's docker, it's still Linux (ubuntu in my case) > ... I am optimistic since it worked on

Re: A good way to write an api server

2019-03-14 Thread C K Kashyap
The dbapp is essentially from here - https://picolisp.com/wiki/?mindbgui and it seems to run fine. I tried strace on httpGate and got this - looks like httpGate needs IPv6 and docker supports IPv6 only for Linux hosts and I am running my stuff on a

Re: A good way to write an api server

2019-03-14 Thread C K Kashyap
And things worked just fine when I tried on WSL :) .. so it must be the ipv6 issue on docker. Regards, Kashyap On Thu, Mar 14, 2019 at 5:55 AM C K Kashyap wrote: > The dbapp is essentially from here - https://picolisp.com/wiki/?mindbgui > and it seems to run fine. > > I tried strace

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-17 Thread C K Kashyap
Hey Alfonso, I tried the new demo 4 and got the same result - "Could not create GL context" -- Error creating OpenGL context: Regards, Kashyap On Sun, Mar 17, 2019 at 4:21 AM Alfonso Villén wrote: > Hello Kashyap, > > you're doing some serious work to make everything run under Docker, thank

Re: A good way to write an api server

2019-03-14 Thread C K Kashyap
Looks like it. I just tested on docker on windows and that does not work either. Fortunately it works on a linux VM on Azure. Since getting it to run on docker would be a really nice to have - would it be too hard to have a IPv4 flavor of httpGate? Oh yes, IPv4 is quite alive and kicking - I

json.l fails to load on pil 64

2019-03-14 Thread C K Kashyap
Hi, I get this error when I try to load json.l from https://github.com/aw/picolisp-json/blob/master/json.l [json.l:53] !? (de json-count-brackets (Str) (let Json_stack NIL (mapc '((N) (if (or (= "{" N) (= "[" N)) (push 'Json_stack N) (case N ("]" (let R (pop 'Json_stack) (unless (= "[" R)

Re: json.l fails to load on pil 64

2019-03-14 Thread C K Kashyap
cool...thanks Abel Regards, Kashyap On Thu, Mar 14, 2019 at 12:38 PM Abel Normand wrote: > Hello. > > This error related to namespaces feature in json.l. easy workaround: when > run pil, set env PIL_NAMESPACES=false before pil. This should fix your > issue, you can actually find this solution

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-17 Thread C K Kashyap
I do not have access to a linux host currently. If you could just give this a try on Docker on linux that would be great - if not anything, it will give you first hand view of the issue. All you need to do is install Docker (on your Linux box) and run the image. docker run -it --rm

Re: A good way to write an api server

2019-03-11 Thread C K Kashyap
r > actually with a slow/non-responding HTTP server. > (With this "trick" I surprised seasoned network experts at multiple > occasions. :-/ ) > > Best regards, > beneroth > > Am 2019-03-12 03:15, schrieb C K Kashyap: > > Hi, > > What's a good way to bring u

Re: Trouble following the intern logic in minipicolisp

2019-03-11 Thread C K Kashyap
Got it! Regards, Kashyap On Mon, Mar 11, 2019 at 4:23 AM Alexander Burger wrote: > Hi Kashyap, > > > Another clarification - I was looking at the implementation of consName > > After this assignment, p points to the CDR of the cell - > >p = symPtr(p); > > Correct. > > > > However, this

A good way to write an api server

2019-03-11 Thread C K Kashyap
Hi, What's a good way to bring up an API server in PicoLisp? The example give here - https://rosettacode.org/wiki/Hello_world/Web_server#PicoLisp does not seem to provide an opportunity to handle GET/POST parameters. And I do not want to use the GUI framework. The example here is too low level

Re: Trouble following the intern logic in minipicolisp

2019-03-10 Thread C K Kashyap
Thanks Alex, Another clarification - I was looking at the implementation of consName After this assignment, p points to the CDR of the cell - p = symPtr(p); However, this assignment assigns to ((p)->car) val(p) = n; I figured out what's happening is equivalent of *(word*)p = val?:p;

Re: Hashtable

2019-03-13 Thread C K Kashyap
Oh ... it just occurred to me that you probably meant this - https://software-lab.de/doc/tut.html#db ? On Wed, Mar 13, 2019 at 9:12 AM C K Kashyap wrote: > Hi Alex, > I was looking up hashtable in picolisp and ran into this thread - > https://www.mail-archive.com/picolisp@softwa

Re: Hashtable

2019-03-13 Thread C K Kashyap
Thanks Alex, Just to I get the reasoning right - so for small and medium volume, a list and binary tree would suffice and for larger data volume a DB is recommended. And perhaps combined with DB on a ramdrive, it could very well substitute for anything traditionally thought of as hashtable

Re: Hashtable

2019-03-13 Thread C K Kashyap
Got it! Regards, Kashyap On Wed, Mar 13, 2019 at 10:16 AM Alexander Burger wrote: > On Wed, Mar 13, 2019 at 09:56:25AM -0700, C K Kashyap wrote: > > Just to I get the reasoning right - so for small and medium volume, a > list > > and binary tree would suffice and for large

Hashtable

2019-03-13 Thread C K Kashyap
Hi Alex, I was looking up hashtable in picolisp and ran into this thread - https://www.mail-archive.com/picolisp@software-lab.de/msg00140.html In it, you've mentioned "build some database structure." Is there a simple sample for reference for such a structure? Regards, Kashyap

Trouble following the intern logic in minipicolisp

2019-03-08 Thread C K Kashyap
Hi, I am having some trouble following what's going on in the in the intern logic. It took me some time to realize that Intern[2] was essentially forming the node of a binary tree :) What's the purpose of the tables - Ascii6 and Ascii7? I tried looking for a writeup on string/symbol

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-18 Thread C K Kashyap
Could you try enabling TCP in you X server please? On Mon, Mar 18, 2019 at 9:29 AM C K Kashyap wrote: > Oh!!! ... It assumes communication over TCP port 6000! ... Linux by > default uses unix socket I think - which is not TCP. > > On Mon, Mar 18, 2019 at 7:50 AM wrote: > &

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-18 Thread C K Kashyap
Oh!!! ... It assumes communication over TCP port 6000! ... Linux by default uses unix socket I think - which is not TCP. On Mon, Mar 18, 2019 at 7:50 AM wrote: > Hello Kashyap, > > the Docker image starts, but when I run the command "run-alfonso- > sdl.sh" I get the following error: > > error:

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-18 Thread C K Kashyap
Excellent news :) ... that means that image itself has everything that's needed (atleast for demos 1 to 13). It maybe just a matter of tweaking the X server settings on my mac - adding OpenGL 3.3 support perhaps ... I'll look. Docker in general would be slower than host because of virtualization.

Re: PilBox build without Gradle and Android Studio

2019-03-18 Thread C K Kashyap
Congratulations Alex!!! Not needing Android Studio can only mean good :) Regards, Kashyap On Mon, Mar 18, 2019 at 11:31 AM Alexander Burger wrote: > Hi all, > > finally I managed to build PilBox (and also PentiKeyboard for that matter) > without the bloated Android Studio, IDE and Gradle.

Re: PilBox build without Gradle and Android Studio

2019-03-19 Thread C K Kashyap
Quick question about getting apps into Android - I see an option to download in the settings page. Can that download over http? That would be really convenient if it does. Combined with ngrok , I can easily expose a directory on my machine and get my application zip onto my

General Lisp questions

2019-03-19 Thread C K Kashyap
Hi Alex, Is LISP indeed List Integer and Symbol Processing? According to a lot of places on the web it seems to be just List Processing. What is the history behind the names CAR and CDR? Regards, Kashyap

Re: PilBox build without Gradle and Android Studio

2019-03-19 Thread C K Kashyap
> > You mean the settings page in PilBox? This is indeed the easiest way, just > type > a name like "radio" or "browser" and hit the Download button. > Yes, the settings page in PilBox - Cool, I was able to download the apps - I tried the browser and calc. However, it looks like I may not be able

Re: General Lisp questions

2019-03-19 Thread C K Kashyap
Thanks Alex and Yiogros, Incidentally I had "skip seen" the video before but I missed the CAR/CDR explanation at 29:00 :) ... Feels good to know it finally! Regards, Kashyap On Tue, Mar 19, 2019 at 6:53 AM Yiorgos [George] Adamopoulos < yiorgos.adamopou...@gmail.com> wrote: > On Tue, Mar 19,

Re: PilBox build without Gradle and Android Studio

2019-03-19 Thread C K Kashyap
Thanks Alex, On my Android phone I cant seem to share to PilBox ... It gives me all kinds of apps such as WhatApp, email etc ...not PilBox. Could you please confirm if https://play.google.com/store/apps/details?id=com.termux is the right termux? Regards, Kashyap On Tue, Mar 19, 2019 at 9:17 AM

Re: A good way to write an api server

2019-03-12 Thread C K Kashyap
Cool...thanks Alex. Regards, Kashyap On Tue, Mar 12, 2019 at 7:42 AM Alexander Burger wrote: > Hi Kashyap, > > > 1. Is there a way I could restrict the server from navigating to a > > different port? I run the app on docker and it requires explicit mapping > of > > the ports in advance :( > >

Re: A good way to write an api server

2019-03-12 Thread C K Kashyap
Thanks Alex, I tried the demo app (pretty cool) and I have a couple questions - 1. Is there a way I could restrict the server from navigating to a different port? I run the app on docker and it requires explicit mapping of the ports in advance :( 2. How do I know the "number" of the field to

Re: A good way to write an api server

2019-03-14 Thread C K Kashyap
As expected, it was rather trivial to copy over gatePort and gateConnect from PicoLisp 3.0.7 and I have httpGate working in docker!!! I have the code here - https://github.com/ckkashyap/picoLisp/blob/contrib/src/httpGate.c :) Regards, Kashyap On Thu, Mar 14, 2019 at 10:16 AM C K Kashyap wrote

Re: A good way to write an api server

2019-03-13 Thread C K Kashyap
264:~/picoLisp# telnet localhost 3000 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. GET / HTTP/1.1 Connection closed by foreign host. I tried the "names" approach too but it did not work for me. Regards, Kashyap On Tue, Mar 12, 2019 at 8:21 AM C K Kashyap wrot

Re: A good way to write an api server

2019-03-15 Thread C K Kashyap
connection refused! If I manually start the app that it works. Isn't httpGate supposed to start the app if it is not already running? regards, Kashyap On Thu, Mar 14, 2019 at 7:05 PM C K Kashyap wrote: > As expected, it was rather trivial to copy over gatePort and gateConnect > from PicoLisp

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-15 Thread C K Kashyap
Great news ... cant wait to try it out on docker + xserver On Fri, Mar 15, 2019 at 7:41 PM wrote: > Works on FreeBSD too, if I make this change: > > $ git diff | cat > diff --git a/sdl/findlib.l b/sdl/findlib.l > index 20371af..f532cb8 100644 > --- a/sdl/findlib.l > +++ b/sdl/findlib.l > @@

Re: SDL2 and OpenGL 3.0+ on Picolisp 64bit (Linux)

2019-03-15 Thread C K Kashyap
one of the demos run - libGL error: No matching fbConfigs or visuals found and libGL error: failed to load driver: swrast Since it runs on Docker + XMing on windows, I am guessing it must be the XQuartz that has some quirks that it causes not to work. Regards, Kashyap On Fri, Mar 15, 2019 at

Re: A good way to write an api server

2019-03-15 Thread C K Kashyap
AM C K Kashyap wrote: > Looks like in my excitement I had completely dropped the name lookup logic > while introducing the IPv4 logic from the past :) > I'll fix it. > > On Fri, Mar 15, 2019 at 12:23 AM Alexander Burger > wrote: > >> Hi Kashyap, >> >> >

Re: Trouble following the intern logic in minipicolisp

2019-03-09 Thread C K Kashyap
Got it. Thanks Alex. I was going to ask this later when I got to it, but since you mentioned I am curious though ... how's hash table implemented without array? Regards, Kashyap On Fri, Mar 8, 2019 at 11:02 PM Alexander Burger wrote: > Hi Kashyap, > > > I am having some trouble following

Subscribe

2019-02-10 Thread C K Kashyap

Internal structures document

2019-02-08 Thread C K Kashyap
Hi, I noticed that the internal structures document is for 64 bit Picolisp. Is there a similar document for 32 bit? Regards, Kashyap

Re: Internal structures document

2019-02-08 Thread C K Kashyap
Of course :) Thanks Alex! Regards, Kashyap On Fri, Feb 8, 2019 at 10:44 PM Alexander Burger wrote: > Hi Kashyap, > > On Fri, Feb 08, 2019 at 06:55:40PM -0800, C K Kashyap wrote: > > I noticed that the internal structures document is for 64 bit Picolisp. > Is > > there a

picolisp on windows

2019-02-03 Thread C K Kashyap
Hi, I'd like to use picolisp built on MSVC. I am planning to start trying to compile miniPicoLisp (it should really be nano :) ) using MSVC. I was wondering if anyone has already done this. MinGW does not quit work for me (I don't have strong technical reasons for this). WSL does not work for

Re: picolisp on windows

2019-02-03 Thread C K Kashyap
nstall and I've been using it for years, but the newer '64 should > work the same way. > > Cheers, > rcs > > On Sun, Feb 3, 2019 at 9:55 PM C K Kashyap wrote: > >> Hi, >> >> I'd like to use picolisp built on MSVC. I am planning to start trying to >> c

Re: picolisp on windows

2019-02-05 Thread C K Kashyap
*(Windows)* > > java -DPID=42 -cp .:tmp:picolisp.jar PicoLisp lib.l *(Linux)* > > On Windows the Oracle JRE/JDK works fine. On Linux for openjdk 8 these > packages are needed: *openjdk-8-jdk, openjdk-8-jdk-headerless, > openjdk-8-jre, openjdk-8-jre-headerless*. > > Regards, &

Re: picolisp on windows

2019-02-05 Thread C K Kashyap
Oops, I should have looked more closely. I do see the .src files :) Thanks! On Tue, Feb 5, 2019 at 6:07 AM Alexander Burger wrote: > Hi Kashyap, > > > Anyway, I could not find the java sources - I could only find the > compiled > > jar file. Are the java sources available? > > They are in fact

Re: picolisp on windows

2019-02-04 Thread C K Kashyap
Hi Alex, I wonder if libuv can substitute for POSIX? Has there been any work in that direction? Regards, Kashyap On Sun, Feb 3, 2019 at 11:47 PM Alexander Burger wrote: > On Sun, Feb 03, 2019 at 10:25:13PM -0500, r cs wrote: > > I've personally built PicoLisp under MinGW-32 on Windows 7, copied

Database question

2019-04-14 Thread C K Kashyap
Hi, Is the builtin database in picolisp tied to OOP? The documentation seems to indicate it. Is there a way I could use the DB to just accrue immutable facts (just like Clojure Datomic works)? Is there a non-OOP sample that I could use as a starting point? Regards, Kashyap

Re: Database question

2019-04-16 Thread C K Kashyap
(commit))) (de kv-get (k) (val (get *DB k))) Regards, Kashyap On Sun, Apr 14, 2019 at 1:58 PM C K Kashyap wrote: > Thanks Alex! > Regards, > Kashyap > > On Sun, Apr 14, 2019 at 1:20 PM Alexander Burger > wrote: > >> On Sun, Apr

Re: Database question

2019-04-16 Thread C K Kashyap
(new T) > > (set nv v) > > (put *DB k nv) > > (commit))) > > > > > (de kv-get (k) > > (val (get *DB k))) > > > > > > > > Regards, > > Kashyap > > > > > &

PicoLisp on Azure

2019-04-14 Thread C K Kashyap
Hi all, I've created a webapp using web.l and deployed it to Azure!!! I used Azure's docker feature so it's really not a big deal but it is cool to see it working. I'll write up the instructions and share in a bit. The docker image is here -

Re: Hashtable

2019-03-13 Thread C K Kashyap
Thanks Rick, Regards, Kashyap On Wed, Mar 13, 2019 at 1:04 PM wrote: > Hello Kashyap, > > While not particularly idiomatic, there is some application code here that > uses idx, hash and friends which may be of some help, by way of example. > Not recommending this for your use, just “yet another

Re: A good way to write an api server

2019-03-15 Thread C K Kashyap
Looks like in my excitement I had completely dropped the name lookup logic while introducing the IPv4 logic from the past :) I'll fix it. On Fri, Mar 15, 2019 at 12:23 AM Alexander Burger wrote: > Hi Kashyap, > > > So I was able to successfully run httpGate and the server - using > httpGate > >

Re: Review request for my JSON parsing implementation

2019-05-12 Thread C K Kashyap
t Type *Scl)) > ((= "-" Type) (if (num? (car *Json)) (format (pack "-" (pop > '*Json))) (json-iterate-object))) > ((= 'true Type) 'true) > ((= 'false Type) 'false) > > > -- Try that against my latest git commit to > https://g

Re: A quick way to write an http endpoint to handle post body

2019-05-24 Thread C K Kashyap
Okay, I have it done finally. I've successfully built a "bot" that talks the "Azure Bot" protocol - Please take a look at http://ckkvm.westus2.cloudapp.azure.com:8080/ which presents a chat UI. It's a glorified REPL at this point :) I've attache the bot code. The protocol is really simple.

PicoLisp is done

2019-05-27 Thread C K Kashyap
Hi all, I remember reading in doc or the mailing list where Alex mentioned that "PicoLisp is done". To me it seems like a unique distinguishing feature of PicoLisp :) Can someone please point me to it? Regards, Kashyap

Re: A quick way to write an http endpoint to handle post body

2019-05-27 Thread C K Kashyap
Thanks Alex! On Sat, May 25, 2019 at 12:06 AM Alexander Burger wrote: > Hi Kashyap, > > > I have it done finally. I've successfully built a "bot" that talks the > > "Azure Bot" protocol - > > Please take a look at http://ckkvm.westus2.cloudapp.azure.com:8080/ > which > > presents a chat UI.

Re: PicoLisp is done

2019-05-27 Thread C K Kashyap
tml > > Regards, > beneroth > > Am 2019-05-27 18:56, schrieb C K Kashyap: > > Hi all, > > I remember reading in doc or the mailing list where Alex mentioned > > that "PicoLisp is done". To me it seems like a unique distinguishing > > feature of PicoLisp :)

Portable graphics in PicoLisp

2019-06-02 Thread C K Kashyap
Hi all, Rendering graphics is a requirement that I keep running into. While HTML5/Canvas is perhaps the most portable way to render graphics today but you have to submit to the restrictions imposed by Javascript in a browser :( . You could escape it by doing the graphics logic in a server and then

Database file format

2019-05-28 Thread C K Kashyap
Hi, Is there documentation about the file format of the database file in PicoLisp? I am looking at the possibility of using it for the tripple store . Regards, Kashyap

Re: Database file format

2019-05-28 Thread C K Kashyap
Thank you Guido and Andreas. Regards, Kashyap On Tue, May 28, 2019 at 4:43 PM wrote: > Hi Kashyap > > > Is there documentation about the file format of the database file > > See file @doc64/structures within the picolisp directory. > There are the picolisp VM internals described, including

Re: A question about scaling picolisp webapp

2019-06-07 Thread C K Kashyap
Hi, If an OS instance can only run N picolisp processes. What would be the strategy to serve more than N concurrent clients? Regards, Kashyap On Fri, Jun 7, 2019 at 12:12 AM Alexander Burger wrote: > Hi Kashyap, > > > If I understand correctly, picolisp web app forks a process to handle the > >

Re: A question about scaling picolisp webapp

2019-06-07 Thread C K Kashyap
Hi Alex, This is the definition of loadbalancing from https://www.nginx.com/resources/glossary/load-balancing/ nginx is a popularly used as a loadbalancer - while this is an L7(application layer from OSI) load balancer, the term loadbalancer can be used for other layers too. A load balancer

Re: A question about scaling picolisp webapp

2019-06-07 Thread C K Kashyap
Thanks Alex, I see, so if app0, app1 and app2 are on different machines and say the first request from the client hits app0, and app0 forks a process to handle the session with the client. I presume that the subsequent requests from the client would somehow be routed to app0 - correct? if so,

A question about scaling picolisp webapp

2019-06-06 Thread C K Kashyap
Hi, I am guilty of not having delved into the picolisp application framework much but I'd appreciate it very much if I could get an answer to this question. If I understand correctly, picolisp web app forks a process to handle the requests from a browser session. httpGate can route the subsequent

Re: A question about scaling picolisp webapp

2019-06-08 Thread C K Kashyap
Got it. This all makes perfect sense! Thanks Alex. Regards, Kashyap On Sat, Jun 8, 2019 at 12:03 AM Alexander Burger wrote: > Hi Kashyap, > > > I see, so if app0, app1 and app2 are on different machines and say the > > first request from the client hits app0, and app0 forks a process to >

Re: Portable graphics in PicoLisp

2019-06-03 Thread C K Kashyap
Thanks Alex ... I could not run osm.l but I tried the sample from here - https://picolisp.com/wiki/?canvasdrawing and it worked like a charm. I had been putting off the HTML app in PicoLisp for a while .. now that I understand PicoLisp more, perhaps I can relook at it. Regards, Kashyap On Mon,

Re: Portable graphics in PicoLisp

2019-06-03 Thread C K Kashyap
Found it :) https://software-lab.de/picoLisp.tgz And it worked! now I know where you live :) On Mon, Jun 3, 2019 at 12:34 PM C K Kashyap wrote: > Hey Alex, > Where do I get the latest version from? > What I have is https://software-lab.de/picoLisp-18.12.tgz. > Regard

Re: Portable graphics in PicoLisp

2019-06-03 Thread C K Kashyap
Hey Alex, Where do I get the latest version from? What I have is https://software-lab.de/picoLisp-18.12.tgz. Regards, Kashyap On Mon, Jun 3, 2019 at 12:14 PM Alexander Burger wrote: > On Mon, Jun 03, 2019 at 11:51:27AM -0700, C K Kashyap wrote: > > Oops .. I meant to attach s

Creating slides in Picolisp

2019-06-22 Thread C K Kashyap
Hi all, I'd like to create HTML presentation slides using picolisp - is there any prior implementation that I can leverage for this? I am looking to be able to generate diagrams (using canvas) mixed with text in my slides. Regards, Kashyap

Re: Creating slides in Picolisp

2019-06-22 Thread C K Kashyap
Oh ... perhaps I was overthinking ... I think this takes me most of the way - (allowed () "!work" "@lib.css" ) (load "@lib/http.l" "@lib/xhtml.l" "@lib/form.l") (de work () (html 0 "slides" "@lib.css" NIL ( NIL "Slide 1") ( NIL

Padding numbers with space

2019-06-10 Thread C K Kashyap
Hi, I noticed that "pad" pads number with 0 prefix. What would be a good way to use space instead? I was about to copy the definition of pad (which is so nice to look at) from lib/misc and edit it but was wondering if a "temporary patching" (if that is a thing) would be better? Regards, Kashyap

Re: Padding numbers with space

2019-06-10 Thread C K Kashyap
ofcourse!!! ... thanks Alex. Regards, Kashyap On Mon, Jun 10, 2019 at 7:01 AM Alexander Burger wrote: > Hi Kashyap, > > > I noticed that "pad" pads number with 0 prefix. What would be a good way > to > > use space instead? > > There is already a function: 'align' :) > >: (pad 5 3) >->

Re: Review request for my JSON parsing implementation

2019-05-09 Thread C K Kashyap
pt a list of special words to look for in the call to echo. Is this the right approach? On Wed, May 8, 2019 at 7:25 AM C K Kashyap wrote: > Perfect - It is pure bliss to see such concise code. > Regards, > Kashyap > > On Wed, May 8, 2019 at 6:59 AM Alexander Burger > wr

Waiting for a forked child to finish

2019-05-11 Thread C K Kashyap
Hi, How can I wait for a forked child to finish in picoLisp? Regards, Kashyap

Re: Waiting for a forked child to finish

2019-05-11 Thread C K Kashyap
Super! .. thanks Alex! On Sat, May 11, 2019 at 1:17 PM Alexander Burger wrote: > On Sat, May 11, 2019 at 12:26:30PM -0700, C K Kashyap wrote: > > I am trying to download a bunch of URLs in parallel and wait until all > the > > downloads have finished before proceeding. C

Re: Waiting for a forked child to finish

2019-05-11 Thread C K Kashyap
Thanks Alex, I am trying to download a bunch of URLs in parallel and wait until all the downloads have finished before proceeding. Calling (kill Pid 0) seems reasonable. Regards, Kashyap On Sat, May 11, 2019 at 11:24 AM Alexander Burger wrote: > Hi Kashyap, > > > How can I wait for a forked

Re: A quick way to write an http endpoint to handle post body

2019-05-18 Thread C K Kashyap
Super! ... almost what I was looking for I mean one minor fix is that I have to call a (line) after (read) to read up the newline after the content length. Also, I need to figure out how to capture the body do I do a pipe? Regards, Kashyap On Sat, May 18, 2019 at 11:53 AM Alexander

Re: A quick way to write an http endpoint to handle post body

2019-05-18 Thread C K Kashyap
gth: " (length Output) "^M^J^M") (prinl Output))) (bye) )) (close *Sock) ) Regards, Kashyap On Sat, May 18, 2019 at 3:43 PM C K Kashyap wrote: > Super! ... almost what I was looking for I mean one minor fix is that > I have to call a (line) after (read)

Re: A quick way to write an http endpoint to handle post body

2019-05-18 Thread C K Kashyap
Thanks Alex, Although, I need a way to get raw access to the body (it happens to be json payload). I do not have control of the client code :( Regards, Kashyap On Sat, May 18, 2019 at 9:53 AM Alexander Burger wrote: > Hi Kashyap, > > > I need a sample to handle HTTP post. All I need to do is

Re: A quick way to write an http endpoint to handle post body

2019-05-18 Thread C K Kashyap
, Kashyap On Sat, May 18, 2019 at 9:55 AM C K Kashyap wrote: > Thanks Alex, > Although, I need a way to get raw access to the body (it happens to be > json payload). I do not have control of the client code :( > Regards, > Kashyap > > > On Sat, May 18, 2019 at 9:53 AM Alexander

A quick way to write an http endpoint to handle post body

2019-05-18 Thread C K Kashyap
Hi Alex et al, I need a sample to handle HTTP post. All I need to do is listen for HTTP post request, read the payload in the body and respond. Before you get tempted to say a variation of RTFM - let me say that I promise to share an interesting demo once I have that :) Regards, Kashyap

Re: Review request for my JSON parsing implementation

2019-05-10 Thread C K Kashyap
Thanks Alex, "apply" is what I was looking for :) Interestingly sub? also seems to work like member? for list of chars - but member? is clearly the appropriate one. I think trim is required because this is valid {"K1": 10 , "K2": 20} Regarding the download logic - the idea is to cache the

Re: How do I read HTTP body while using web.l

2019-05-15 Thread C K Kashyap
Hey Alex, While my question was about the server side - it is super cool to learn about "ssl" - although I am curious - was there a reason why "POST" was left out of it? Also I agree about the point of parsing a program generated JSON looks like an overkill is many cases. Hey Andreas - I dont

  1   2   3   4   >