Re: [Factor-talk] Startup time
You could also set up factor as a local web server, and send bash requests to it through a web page, and it would be able to accomplish them locally (or remotely) and report you the results. It would be a quick round-trip cycle with great feedback and the ability to bookmark commands. On Sun, Jan 29, 2017 at 1:39 PM,wrote: > On 2017-01-29 16:20, John Benediktsson wrote: > > It would be nice to improve startup time. I imagine some low hanging > > fruits if we looked deeply into it. I'll make a note to get that on my > > list, unless someone looks into it sooner. > > > > > > > >> On Jan 28, 2017, at 2:25 PM, pet...@riseup.net wrote: > >> > >> I spend a lot of time writing small scripts, often in bash. That is > >> becoming a more and more painful task as bash is a nice-enough > >> language > >> on the first look but in the end it seems to go out of it's way to > >> trip > >> you up with every character you type. I don't mean to rant, I know > >> it's > >> an old language that has to keep a lot of backward compatibility and > >> it > >> actually still serves very well for what it was designed for, as long > >> as > >> your script stays <100 lines. Still, there's a lot to be desired. > >> > >> Factor is a cool language, it's very expressive, mature, has a lot of > >> libraries and has all sorts of tricks up its sleaves to bend it to > >> your > >> will (much like lisp in that regard). It would be a fun experiment to > >> write a library or EDSL (embedded DSL) for bash-like scripting. > >> However > >> there's a bone to be picked: > >> > >> $ time bash -c '' > >> bash -c '' 0.00s user 0.00s system 94% cpu 0.004 total > >> > >> $ time factor-vm -e='' > >> factor-vm -e='' 0.12s user 0.05s system 99% cpu 0.178 total > >> > >> I know one can create a custom image and maybe cut down on the startup > >> a > >> bit, but my question is - would it be possible to cut it down to > >> bash's > >> startup time *and* still have all the necessary vocabularies in it? I > >> don't want to know the startup time with a small image that has like > >> nothing in it, I can quickly test that myself. I'd need help to answer > >> - > >> if you imagine the use case I'm talking about, include all the vocabs > >> that use case would need and make all other possible optimizations (if > >> there are) without sacrificing too much, can the startup reach similar > >> times? > >> > >> -- > >> > >> Peter Nagy > >> > >> > >> > -- > >> Check out the vibrant tech community on one of the world's most > >> engaging tech sites, SlashDot.org! http://sdm.link/slashdot > >> ___ > >> Factor-talk mailing list > >> Factor-talk@lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/factor-talk > > > > > -- > > Check out the vibrant tech community on one of the world's most > > engaging tech sites, SlashDot.org! http://sdm.link/slashdot > > ___ > > Factor-talk mailing list > > Factor-talk@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/factor-talk > > Hi John, > > you think you can reach similar startup times? That would be really > cool. I guess your todo list is rather long though. > > As a side note, are there other concatenative languages you know I could > look at? > > -- > >Peter Nagy > > > > -- > Check out the vibrant tech community on one of the world's most > engaging tech sites, SlashDot.org! http://sdm.link/slashdot > ___ > Factor-talk mailing list > Factor-talk@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/factor-talk > -- Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] PDF
As web is central to everything I do, and all reporting and most UI now accomplished through basically identical HTML generation, you may consider a HTML to PDF conversion utility, for example http://wkhtmltopdf.org/ On Tue, Dec 20, 2016 at 8:35 AM, John Benediktssonwrote: > The PDF stream writer works pretty well for what I wanted it for, allowing > you to output using our formatted stream protocol (e.g. ``stream-format``) > with font sizes and colors etc. specified. The main entry point for that > is ``with-pdf-writer``, then when the quotation (which should print / write > / format stuff output) finishes the object on the stack is the pdf, which > would need to be written to file something like: > > [ ... ] with-pdf-writer pdf>string > /path/to/output.pdf utf8 set-file-contents > > It doesn't currently support things like setting page numbers and header > and footers, and table support could be a bit better, but the building > blocks are there if you wanted to. > > If that doesn't provide what you need, other ideas are to wrap the many > PDF libraries available in many other languages. > > Best, > John. > > On Tue, Dec 20, 2016 at 6:23 AM, Jon Harper > wrote: > >> Hi, >> there is http://docs.factorcode.org/content/vocab-pdf.html and its >> children. >> >> I haven't used it, but it is for example used to generate the docs in pdf >> using pdf streams. >> >> Jon >> >> >> Le 20 déc. 2016 08:39, "Alexander Ilin" a écrit : >> >> Hello! >> >> Is there a way to generate PDF documents from within Factor? >> >> ---=--- >> Александр >> >> >> -- >> Developer Access Program for Intel Xeon Phi Processors >> Access to Intel Xeon Phi processor-based developer platforms. >> With one year of Intel Parallel Studio XE. >> Training and support from Colfax. >> Order your platform today.http://sdm.link/intel >> ___ >> Factor-talk mailing list >> Factor-talk@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/factor-talk >> >> >> >> >> -- >> Developer Access Program for Intel Xeon Phi Processors >> Access to Intel Xeon Phi processor-based developer platforms. >> With one year of Intel Parallel Studio XE. >> Training and support from Colfax. >> Order your platform today.http://sdm.link/intel >> ___ >> Factor-talk mailing list >> Factor-talk@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/factor-talk >> >> > > > -- > Developer Access Program for Intel Xeon Phi Processors > Access to Intel Xeon Phi processor-based developer platforms. > With one year of Intel Parallel Studio XE. > Training and support from Colfax. > Order your platform today.http://sdm.link/intel > ___ > Factor-talk mailing list > Factor-talk@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/factor-talk > > -- Developer Access Program for Intel Xeon Phi Processors Access to Intel Xeon Phi processor-based developer platforms. With one year of Intel Parallel Studio XE. Training and support from Colfax. Order your platform today.http://sdm.link/intel___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] DOS Encoding
Are you talking about the characters that used to be used in character based windows apps? LIke on this page from 179-218 or so? https://en.wikipedia.org/wiki/Code_page_437 On Wed, Oct 26, 2016 at 3:52 PM, John Benediktssonwrote: > does it work to just use binary and then do ``>string``? > > On Wed, Oct 26, 2016 at 2:55 PM, Alexander Ilin wrote: > >> Hello! >> >> I'd like to parse some log-files created by an old-style DOS program. >> They contain pseudographics characters for drawing frames and tables. >> Technically, that's not ASCII, but a superset with all 8 bits used. >> Do we have an 8-bit encoding that would support that? I took a look at >> the basis\io\encodings\8-bit\ folder, but among those latin1-latin10 >> encodings nothing screams "DOS Pseudographics". >> >> A little guidance here, anyone? >> >> ---=--- >> Александр >> >> >> >> -- >> The Command Line: Reinvented for Modern Developers >> Did the resurgence of CLI tooling catch you by surprise? >> Reconnect with the command line and become more productive. >> Learn the new .NET and ASP.NET CLI. Get your free copy! >> http://sdm.link/telerik >> ___ >> Factor-talk mailing list >> Factor-talk@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/factor-talk >> >> > > > -- > The Command Line: Reinvented for Modern Developers > Did the resurgence of CLI tooling catch you by surprise? > Reconnect with the command line and become more productive. > Learn the new .NET and ASP.NET CLI. Get your free copy! > http://sdm.link/telerik > ___ > Factor-talk mailing list > Factor-talk@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/factor-talk > > -- The Command Line: Reinvented for Modern Developers Did the resurgence of CLI tooling catch you by surprise? Reconnect with the command line and become more productive. Learn the new .NET and ASP.NET CLI. Get your free copy! http://sdm.link/telerik___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Desperate UI help
Also consider having your ui consist of an embedded web browser that browses to itself. Factor serves web pages and can, IIRC, embed a web browser under its control that browses to localhost. On Sat, Feb 21, 2015 at 4:08 PM, John Benediktsson mrj...@gmail.com wrote: Hi Mark, The UI is a cross-platform interface built on OpenGL and we haven't implemented cross-platform popups or modal dialogs. The current popups are rendered into the window. However, we support on each platform calling any of the native UI's. So basically anything you can create on the native interface is available from within Factor, just not wrapped nicely and made available for cross-platform use. So basically, is there a way to call the native UI directly to solve your issue? Thanks, John, On Feb 21, 2015, at 3:57 PM, Mark Green m...@antelope.nildram.co.uk wrote: Hi, Most problems can render outside of their window if needed for a menu. For example, try shrinking your web browser window vertically so that only one line or so of the web page is visible, then right-clicking in the visible space. Mark -- Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631iu=/4140/ostg.clktrk ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631iu=/4140/ostg.clktrk ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631iu=/4140/ostg.clktrk___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Cookbook and Learning
construct a hello visitor web page construct a hello visitor gui Use factor ide as best rpm calculator ever! On Mon, Jun 17, 2013 at 1:29 PM, Loryn Jenkins lor...@gmail.com wrote: Graham What type of tutorials would you find useful? Loryn Jenkins On Mon, Jun 17, 2013 at 10:34 PM, graham telfer gakouse...@hotmail.comwrote: The lack of tutorials for Factor is a major bugbear. I have found The Rosetta Code site very useful because you can compare Factor code with a language you already know for many different problems. Chapter 4 of Thinking Forth is also useful because it has a lot of good advice about factoring code. -- This SF.net email is sponsored by Windows: Build for Windows Store. http://p.sf.net/sfu/windows-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- This SF.net email is sponsored by Windows: Build for Windows Store. http://p.sf.net/sfu/windows-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- This SF.net email is sponsored by Windows: Build for Windows Store. http://p.sf.net/sfu/windows-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] teaching
I know that learning Forth, and Learning Forth by Leo Brodie, was the most important part of my self education in the 80s. And Factor has made me think more clearly, even as I program in C# for my day job, and javascript for my node projects. On Tue, Apr 9, 2013 at 7:39 AM, Alexander Mueller ddo...@gmail.com wrote: dunnoh, trying to switch to factor as a language in a curriculum would imply reordering the courses. for university i'd say it's possible but not easily so because you'd need to change the sequence in which things are taught imho - so you have a gentle introduction (explain everything you'd need to learn in theoretical informatics first before going dipping into practical informatics since you can't really go concurrently). i would say though that the migration cost would be too high (too much trouble for not much gain) - i wouldn't be able to say what advantage there would be compared to using python/haskell/scheme/... besides that i like the syntax alot more. for school i'd say it might lack some tools so you can just throw kids at computers and hope that some grok it. On Tue, Apr 9, 2013 at 1:12 AM, Leonard P leonard14...@gmail.com wrote: Stacks, objects, collections, continuations, higher-order functions ... Anyone else think that Factor would make an ideal language for teaching CS? -- Precog is a next-generation analytics platform capable of advanced analytics on semi-structured data. The platform includes APIs for building apps and a phenomenal toolset for data science. Developers can use our toolset for easy data analysis visualization. Get a free account! http://www2.precog.com/precogplatform/slashdotnewsletter ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Precog is a next-generation analytics platform capable of advanced analytics on semi-structured data. The platform includes APIs for building apps and a phenomenal toolset for data science. Developers can use our toolset for easy data analysis visualization. Get a free account! http://www2.precog.com/precogplatform/slashdotnewsletter ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Precog is a next-generation analytics platform capable of advanced analytics on semi-structured data. The platform includes APIs for building apps and a phenomenal toolset for data science. Developers can use our toolset for easy data analysis visualization. Get a free account! http://www2.precog.com/precogplatform/slashdotnewsletter___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] a script
Also, to save you some typing, try this syntax: http://docs.factorcode.org/content/word-qw%7B,qw.html USE: qw qw{ DTEGY EONGY RWEO } list On Sat, Mar 16, 2013 at 8:14 AM, Alex Vondrak ajvond...@gmail.com wrote: On Sat, Mar 16, 2013 at 6:05 AM, Fox McCloud starfox...@gmail.com wrote: Wondering if one stock symbol is typed incorrectly. Is there a way to determine the specific value in a sequence on which map fails? In the UI listener, clicking the Traceback button on top of an error dialog will let you see the data call stacks at the time of the error. In the command-line listener, type `:s` and `:c` to see the data calls stacks, respectively. Here, call stack isn't even a Factor-specific concept: it's just like the stack trace you'd get from most other languages. In the interest of teaching a man to fish, I won't point out the issue you're having, but it becomes pretty obvious when you take a look. Your hunch is on the right track. :) Hope that helps, --Alex Vondrak -- Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_mar ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_mar___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Out of memory error
In a way, too many possible culprits mask each other. I remember a problem like this that I solved by reducing the amount of memory so the problem would show quickly, then testing small things in isolation and volume. Pick a subset of tests and run them multiple times at low memory until it fails or becomes clear it won't. Rinse and repeat. On Sat, Aug 25, 2012 at 10:19 AM, Alexander J. Vondrak ajvond...@csupomona.edu wrote: Okay, so still no luck: - Tried skipping tools.deploy tests (just yanked deploy-tests.factor out of the 0.95 source tree before `load-all test-all`), still crashed. - Tried skipping extra/ with `resouce:core load-root resource:basis load-root test-all`, still crashed. - Tried doubling the sizes of the GC generations (./factor -young=2 -aging=4 -tenured=1600) to no avail. - No particular vocabulary seems to be tripping it off, as verified by doing the above with ``` \ run-test-file [ [ dup ~/Desktop/tests utf8 [ print ] with-file-appender ] prepend ] annotate ``` and having them crash at different vocabs. The few times I managed to catch a glimpse of the factor process running in top, the memory usage just seemed to creep up to its ceiling as more and more tests were run until it finally aborted. It didn't use to do this (even very recently), which is what made me think it was something to do with my machine just being b0rked. I've had weird bugs crop up from time to time using Debian, so it's not unprecedented. I've been procrastinating setting up an Arch install on this machine, so maybe this is as good a reason as any to get around to that... Any other experiments I should try? Thanks for the help, --Alex Vondrak From: John Benediktsson [mrj...@gmail.com] Sent: Friday, August 24, 2012 6:54 PM To: factor-talk@lists.sourceforge.net Cc: factor-talk@lists.sourceforge.net Subject: Re: [Factor-talk] Out of memory error It might be worth only loading and testing vocabularies in core and basis, to see if GVN works? On Aug 24, 2012, at 6:50 PM, Alexander J. Vondrak ajvond...@csupomona.edu wrote: It seems to fail soon after the tools.deploy tests. I tried at one point disabling those, but I think it still crashed. I should check again... From: Doug Coleman [doug.cole...@gmail.com] Sent: Friday, August 24, 2012 6:44 PM To: factor-talk@lists.sourceforge.net Subject: Re: [Factor-talk] Out of memory error 8gb outta be enough for anybody. But It's not, I guess. Try with more RAM or patch the part that grows to only grow to as much as you have. Maybe something is using way too much On Aug 24, 2012 6:01 PM, Alexander J. Vondrak ajvond...@csupomona.edu mailto:ajvond...@csupomona.edu wrote: Hey all, Mini-update: got the unit tests for the global value numbering pass more up-to-snuff awhile ago (it's like test-driven development in reverse!). Still seems like I should be doing more to test the new capabilities, but I'm not sure if I could do much more than what's there. My efforts as of late have been focused on some GVN improvements. But for the past way-too-long, I thought I had broken something catastrophic because `load-all test-all` would invariably crash the listener with an out of memory error: Out of memory Nursery: Start=831c, size=10, end=832c Aging: Start=82fc, size=20, end=831c Tenured: Start=50c8, size=3214, end=82dc Cards:base=b44d0008, size=326800 Aborted After a lot of very slow debugging (them's the breaks when running all the unit tests, I guess) that was ultimately fruitless, I finally tried out Factor 0.95 straight from the build farm---none of my changes, no .git, just a clean download of the linux-x86-32 tarchive. And, what do you know, `load-all test-all` still crashes with the same error. It hadn't done that before, so I think the issue may be an intervening OS update I did. I'm running a fully up-to-date Debian testing, kernel 3.2.0-3-686-pae. 1) Can anyone reproduce this error? Or is my machine just that jacked up? I'd be happy to provide other diagnostic info, if it'd help. 2) Any coping mechanisms? I considered just throwing a bunch of memory at it with command line switches (-young=, -aging=, -tenured=, etc.), but wasn't really sure how much would do the trick, since it just started crashing like this out of the blue anyway. Thanks, --Alex Vondrak -- Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats.
Re: [Factor-talk] Stack Depth
How do you know the optimizing compiler does or doesn't perform one additional read/write when the result goes to 'the' stack instead of going to a different data structure? I couldn't build a compiler, but I think the registers are being used at times, and that the stack is a metaphor. Factor certainly is written better than simply treating each word as a jump, which early forths did, before inlining. It may be fewer ops to do it the first way rather than the second, as the second actually contains the first, plus the temp storage of cut pieces pre-pan. On Sat, Jul 7, 2012 at 2:03 AM, graham telfer gakouse...@hotmail.comwrote: -- Thanks to everybody who gave me suggestions about the stack. I'd like to add a final comment about why I think the stack is useful in this case. Imagine you are going to chop up a carrot to cook it. There are 2 ways you might go about the job: the first is to cut off a piece and then turn and put it into the pan ready to cook. Keep doing this, cutting one piece at a time, turning and putting each piece of carrot into the pan until there is no carrot left. The second way is to cut the carrot into pieces and then put all of the pieces into the pan as a single operation. I see the second way as analagous to using the stack. Do all the dividing then put all the values into the data structure as a single operation. I do not see this as using the stack as a data structure; just a convenient holding pen. -- Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Factor image snapshots
This seems similar to having a bookmark 'url' interface into the gui, that contains enough information to restore state, or has a key to something that has that extra info about what data are current. And that seems like enough of a good thing to want in and of itself. It also seems similar to any undo functionality (restart and run commands to n-1) , also a good enough thing to want by itself. Could one solution logging certain calls bring all three benefits? Snapshot + command line interface + undo? On Sun, Mar 20, 2011 at 11:03 PM, Andrey Onymov anonym...@gmail.com wrote: On Mon, 21 Mar 2011 10:34:21, Slava Pestov wrote: The problem with snapshotting the state of the UI with all open windows and gadgets is that it gets really tricky for gadgets with associated native resources, like fonts, vertex buffers, textures, and so on. Squeak doesn't run into this difficulty because it renders to a framebuffer and implements everything itself... Slava On Mon, 21 Mar 2011 16:46, Joe Groff wrote: Resuming an entire program is tricky. While the Factor VM knows how to freeze the Factor heaps and thaw and revive them, on its own, it doesn't know how to recreate the UI resources, network connections, and other externalities a real program depends on. Programs can register startup hooks to perform these sorts of (re)initialization tasks, but it's not automatic. A program in Factor could potentially support a full resume, if all its libraries properly register startup hooks to recreate their external dependencies, and the program saved a continuation object to be resumed from the saved image. -Joe So, basically, you'd need ability to set up a hook that fires when building a snapshot and saves another hook to restore the state on restart (and support for this in all the libs, of course). Quite a hassle to implement. And anyways, start-up times for image with all dependencies compiled in is quite low, so wouldn't it be easier to implement some common framework for state persist/restore on applications level? -- Colocation vs. Managed Hosting A question and answer guide to determining the best fit for your organization - today and in the future. http://p.sf.net/sfu/internap-sfd2d ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Enable your software for Intel(R) Active Management Technology to meet the growing manageability and security demands of your customers. Businesses are taking advantage of Intel(R) vPro (TM) technology - will your software be a part of the solution? Download the Intel(R) Manageability Checker today! http://p.sf.net/sfu/intel-dev2devmar___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Factor image snapshots
Would annotations be a reasonable place to implement some level of call recording? On Mon, Mar 21, 2011 at 2:20 PM, Jim mack j...@less2do.com wrote: This seems similar to having a bookmark 'url' interface into the gui, that contains enough information to restore state, or has a key to something that has that extra info about what data are current. And that seems like enough of a good thing to want in and of itself. It also seems similar to any undo functionality (restart and run commands to n-1) , also a good enough thing to want by itself. Could one solution logging certain calls bring all three benefits? Snapshot + command line interface + undo? On Sun, Mar 20, 2011 at 11:03 PM, Andrey Onymov anonym...@gmail.comwrote: On Mon, 21 Mar 2011 10:34:21, Slava Pestov wrote: The problem with snapshotting the state of the UI with all open windows and gadgets is that it gets really tricky for gadgets with associated native resources, like fonts, vertex buffers, textures, and so on. Squeak doesn't run into this difficulty because it renders to a framebuffer and implements everything itself... Slava On Mon, 21 Mar 2011 16:46, Joe Groff wrote: Resuming an entire program is tricky. While the Factor VM knows how to freeze the Factor heaps and thaw and revive them, on its own, it doesn't know how to recreate the UI resources, network connections, and other externalities a real program depends on. Programs can register startup hooks to perform these sorts of (re)initialization tasks, but it's not automatic. A program in Factor could potentially support a full resume, if all its libraries properly register startup hooks to recreate their external dependencies, and the program saved a continuation object to be resumed from the saved image. -Joe So, basically, you'd need ability to set up a hook that fires when building a snapshot and saves another hook to restore the state on restart (and support for this in all the libs, of course). Quite a hassle to implement. And anyways, start-up times for image with all dependencies compiled in is quite low, so wouldn't it be easier to implement some common framework for state persist/restore on applications level? -- Colocation vs. Managed Hosting A question and answer guide to determining the best fit for your organization - today and in the future. http://p.sf.net/sfu/internap-sfd2d ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Enable your software for Intel(R) Active Management Technology to meet the growing manageability and security demands of your customers. Businesses are taking advantage of Intel(R) vPro (TM) technology - will your software be a part of the solution? Download the Intel(R) Manageability Checker today! http://p.sf.net/sfu/intel-dev2devmar___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] sqlite-error #21 - Library used incorrectly
and the sqlite3.dll is in the factor exe folder? On Wed, Jan 5, 2011 at 10:52 PM, Otoburb otob...@gmail.com wrote: Hi, I've been trying to go through malu's factor-blog-gitutorial[1] and I'm at commit 3e91728fd6b2021fc11d, where I should be able to at least show the list of recent posts and create new posts. Using the following instructions in the listener, I keep running into a 500 error from Furnace. USING: blog db db.sqlite http.server namespaces threads ; blog main-responder set-global [ blog.db sqlite-db [ 8080 httpd ] with-db ] in-thread When I look into the http log (logs/http.server/1.log), it showed the following errors: [2011-01-06T01:15:32-05:00] ERROR do-request: sqlite-error [] ERROR do-request: n 21 [] ERROR do-request: string Library used incorrectly I sprinkled debug log-messages throughout the code and saw that the problem occurs when attempting to execute select-tuples within the page-action init quotation, specifically a problem with the recent-posts word. The particular code fragments (with debug log messages removed): : recent-posts ( num -- posts ) f post query swap limit created_at desc order select-tuples ; : recent-posts-action ( -- action ) page-action [ 5 recent-posts posts set-value ] init { blog recent-posts } template ; Executing the recent-posts word from the listener: ( scratchpad ) blog.db sqlite-db [ 5 recent-posts ] with-db ... returns a proper result (either an empty array, or a result, depending on whether I entered a post or not previously). I thought that the problem might be the gitutorial, so I went and tried to launch webapps.blogs since they seem rather similar. In the listener, I typed the following: ( scratchpad ) temp.db sqlite-db [ blogs main-responder set-global 8080 httpd ] with-db However, this resulted in the same error in the http log. With additional debug messages in webapps.blogs, I was able to narrow down the issue in a similar place. In this case, the problem occurs when the select-tuples is called within the list-posts word. Checking basis/db/sqlite/ffi/ffi.factor shows the CONSTANT: SQLITE_MISUSE 21 ! Library used incorrectly line. Since that seemed like a sqlite3.dll lib throwing an error, I ran db.sqlite test in the listener and all of the unit tests passed. I'm hoping it's just the way that I'm setting up the environment or perhaps misusing with-db. At the limit of my Factor capabilities trying to figure this out. Further information if required: - Factor win32-2010-12-27 - sqlite3 version 3.7.4 Thanks, Dave -- Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Learn how Oracle Real Application Clusters (RAC) One Node allows customers to consolidate database storage, standardize their database environment, and, should the need arise, upgrade to a full multi-node Oracle RAC database without downtime or disruption http://p.sf.net/sfu/oracle-sfdevnl___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Is this expected behavior?
USING: accessors classes generic kernel sequences tools.test ; IN: test MIXIN: power1 MIXIN: power2 TUPLE: dad ; TUPLE: bro1 dad ; TUPLE: bro2 dad ; INSTANCE: dad power1 INSTANCE: bro2 power2 GENERIC: content ( tpl -- str ) M: power1 content ( tpl -- str ) class name power1 append ; M: power2 content ( tpl -- str ) class name power2 append ; { bro2 power2 } [ bro2 new content ] unit-test I haven't figured out how to debug/step into inheritance chains/method order choosing. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Is this expected behavior?
Thank you so much! I kept thinking of this as a chain with hierarchy and missed that bro2 was an equal member of both. (Plus, old parts of my brain still thinks instance means the in memory instantiation of a class). On Thu, Dec 16, 2010 at 5:54 PM, Joe Groff arc...@gmail.com wrote: On Dec 16, 2010, at 10:28 PM, Jim mack wrote: I haven't figured out how to debug/step into inheritance chains/method order choosing. bro2 is both a member of power1 (through dad) and power2. There's no hierarchical relationship implied between power1 and power2 (both classes are open union classes and neither class is necessarily a subset of the other), so when you invoke content on a bro2, it's ambiguous as to whether the power1 or power2 method should be called. In ambiguous cases, the union/mixin dispatch currently dispatches on the first asciibetical class for which it finds a method, in this case power1. To get the behavior you want, you need to make power2 a member of power1, thereby mirroring the tuple inheritance hierarchy in the mixin hierarchy: MIXIN: power1 MIXIN: power2 TUPLE: dad ; TUPLE: bro1 dad ; TUPLE: bro2 dad ; INSTANCE: power2 power1 INSTANCE: dad power1 INSTANCE: bro2 power2 Since power2 is now explicitly a subset of power1 it will be treated as more specific, and power2 methods will override power1 methods. -Joe -- Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Using tuple inheritance, mixins gives me results I don't understand and lack the skills to debug/fix.
I read that and experimented enough to learn my mixin expectations from Ruby didn't serve me :) But, in my pasted code, I only defined dispatch methods for the mixins. Are you saying that the tuples can't be related by inheritance at all? Thanks, Jim On Wed, Dec 15, 2010 at 5:53 PM, Joe Groff arc...@gmail.com wrote: On Dec 16, 2010, at 6:52 AM, Jim mack wrote: Teaser: 4 tuple 'brothers' each have distinct mixin. Mixins have generic words. Tuples do not have any generic words defined. Out of six calls through tuples, two trigger the wrong mixin. Inheritance and mixin dispatch don't mix. Try using a pure mixin hierarchy instead to get the behavior you expect—make a mixin hierarchy mirroring your tuple hierarchy, and have the child mixin classes be members of the parent mixin classes. -Joe -- Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Using tuple inheritance, mixins gives me results I don't understand and lack the skills to debug/fix.
The code: http://paste.factorcode.org/paste?id=2075 The tests revealing problems or my misunderstanding of expectations: http://paste.factorcode.org/paste?id=2076 -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Git patch
Thanks. I'll repeat my clone/upstream/modify/push experiment until I see what I'm doing wrong. :( On Sun, Dec 5, 2010 at 3:37 AM, Samuel Tardieu s...@rfc1149.net wrote: 2010/12/5 Jim mack j...@less2do.com Growing circulars had a problem pushing once rotated, so here's my attempt. I had trouble updating the read only seq slot, and expect there's a better way than my cheat, but it's beyond me for now.. It includes the test proving the need. This is my first attempt to fix anything, so please let me know what to do better. I tried forking a private repos and pushing to it, but got this and don't have time to monkey much more. fatal: bad object 541390b56187b99df4da5716b6987f9c051babe1 error: pack-objects died with strange error error: failed to push some refs to 'g...@github.com: jimmack1963/factor.git' and 20 min of google browsing didn't answer, so, here it is by email, which I think others have used recently. Jim, I fixed whitespace issues in your commit and set your name and email address: https://github.com/samueltardieu/factor/commit/c8b699a232e2baddefba643e84a8f790e7dc47cd If it looks right to you, slava can pull from git://github.com/samueltardieu/factor.git for-slava to get this change if he hasn't got it yet. Sam -- What happens now with your Lotus Notes apps - do you make another costly upgrade, or settle for being marooned without product support? Time to move off Lotus Notes and onto the cloud with Force.com, apps are easier to build, use, and manage than apps on traditional platforms. Sign up for the Lotus Notes Migration Kit to learn more. http://p.sf.net/sfu/salesforce-d2d ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- What happens now with your Lotus Notes apps - do you make another costly upgrade, or settle for being marooned without product support? Time to move off Lotus Notes and onto the cloud with Force.com, apps are easier to build, use, and manage than apps on traditional platforms. Sign up for the Lotus Notes Migration Kit to learn more. http://p.sf.net/sfu/salesforce-d2d___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Git patch
Hi, Growing circulars had a problem pushing once rotated, so here's my attempt. I had trouble updating the read only seq slot, and expect there's a better way than my cheat, but it's beyond me for now.. It includes the test proving the need. This is my first attempt to fix anything, so please let me know what to do better. I tried forking a private repos and pushing to it, but got this and don't have time to monkey much more. fatal: bad object 541390b56187b99df4da5716b6987f9c051babe1 error: pack-objects died with strange error error: failed to push some refs to 'g...@github.com:jimmack1963/factor.git' and 20 min of google browsing didn't answer, so, here it is by email, which I think others have used recently. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. commit-8f434fb Description: Binary data -- What happens now with your Lotus Notes apps - do you make another costly upgrade, or settle for being marooned without product support? Time to move off Lotus Notes and onto the cloud with Force.com, apps are easier to build, use, and manage than apps on traditional platforms. Sign up for the Lotus Notes Migration Kit to learn more. http://p.sf.net/sfu/salesforce-d2d___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Win XP pro 32 bit running furnace got this error
I'd be glad to help debug further if there is any more info needed. C:\factor\work..\factor Loading C:\Documents and Settings\jmack/factor-rc Error in thread 1617 (Thread, [ ~array~ set-datastack 80 httpd ]): winsock-exception n -1 string Unknown error 0x (U) Quotation: [ set-namestack init-catchstack self quot call - stop ] (O) Word: start-server (O) Word: set-servers (O) Word: (make-servers) (O) Word: server (O) Method: M\ object (server) (O) Word: winsock-return-check (O) Word: winsock-exception (O) Method: M\ object throw (U) Quotation: [ 63 special-object error-thread set-global continuation - error-continuation set-global [ original-error set-global ] [ rethrow ] bi ] You have triggered a bug in Factor. Please report. error: 16 arg 1: 108 arg 2: f Starting low level debugger... Basic commands: q-- continue executing Factor - NOT SAFE im -- save image to fep.image x-- exit Factor Advanced commands: d addr count -- dump memory u addr -- dump object at tagged addr . addr -- print object at tagged addr t-- toggle output trimming s r -- dump data, retain stacks .s .r .c -- print data, retain, call stacks e-- dump environment g-- dump generations data -- data heap dump words-- words dump tuples -- tuples dump refs addr -- find data heap references to object push addr -- push object on data stack - NOT SAFE code -- code heap dump READY -- Increase Visibility of Your 3D Game App Earn a Chance To Win $500! Tap into the largest installed PC base get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Emacs/FUEL; web server; sqlite installation for Factor
On Wed, Nov 24, 2010 at 2:04 AM, Shaping shap...@charter.net wrote: Jim, does your web-server example work for you? The example you posted failed for me during init-db. init-db successfully creates the user adhoc subdirectory, and then fails shortly after this, but I could not determine with the walker the exact problem. The stack trace I posted showed a call-effect-unsafe problem. I do not know what this means. Is there a special procedure for installing the sqlite3.* files? I am assuming not. I put them in the Factor working directory. I did this based on your original instructions in your first posting on the web server. I have noticed your asking this, but don't have an answer for you on Windows. We've already covered where to get the dlls from, and where to put them - your factor home folder. From that point all the sqlite attempts worked for me. I am more of an end user than many of these other guys on here, so I don't have any answers. I once learned everything I could about any computer I had, but gave that up several platforms ago - I never seemed to use the info, there isn't room any more, etc. My suspicion is that there is some kind of permission problem, or a 64 bit issue. Do you have another MS machine you can play on to test this? I switch back and forth between mac and windows and often get clues from that. Maybe you could get past this awkward learning period by booting to linux and playing there, using the built in emacs editor. Then, gradually shift to windows - then you know you're doing it 'right' and the only issue is the platform. I do this for all my open source work. I have learned some walker/debugger tricks. One that may have already occurred to you is to use a grep tool to find likely places for something to happen, put a B in the source every where (maybe with some kind of marking/numbering system like name of proc drop to help you know where you are). -- Increase Visibility of Your 3D Game App Earn a Chance To Win $500! Tap into the largest installed PC base get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] factor self modify source
http://paste.factorcode.org/paste?id=2056 I think too many would be irritated by the clipboard changing, so perhaps this should be opt-in, so I'm not thinking this is a submission, but it may be interesting to some. I find it useful. D On Mon, Nov 22, 2010 at 11:32 PM, Joe Groff arc...@gmail.com wrote: On Tue, Nov 23, 2010 at 12:46 PM, Jim mack j...@less2do.com wrote: When you activate auto use, and get told the correct USING: clause, I think I'd like to either type a word or have a setting that updates the source file. I am close to being able to implement this myself (although I wouldn't mind any amount of direction) I see. As you mentioned, it's possible to conflict with unsaved changes when updating files directly from Factor. You could definitely add some code updating tools that had to be manually applied, because a user would then have to explicitly coordinate their saving and updating actions. Automatic modification would be dangerous. -Joe -- Increase Visibility of Your 3D Game App Earn a Chance To Win $500! Tap into the largest installed PC base get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Increase Visibility of Your 3D Game App Earn a Chance To Win $500! Tap into the largest installed PC base get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Emacs/FUEL
There's an argument to be had for sticking to what you already use and love, and making that work better. I personally tried a few, and had used the sci editor in the past on windows, but gravitated back to my editpadpro. I then found ways to get an imperfect syntax highlighter going - they provide a regular expr tool interface and now it handles nested [ {, highlights the first word after a : at the beginning of line, pulls attention to strings, and bolds out the operators like cleave and bi that are so common. That was enough to get it out of the way for now. I did just find out how to get a clickable link to the offending file when an autouse triggers an additional file, and that's made things more fun as well. Did you know that if you're in the error browser, clicking a particular error will focus you to that line in some editors, editpadpro included? You can try it for free; I've been using it since it was made. http://www.editpadpro.com/ On Tue, Nov 23, 2010 at 5:05 AM, Joe Groff arc...@gmail.com wrote: On Tue, Nov 23, 2010 at 5:40 PM, Shaping shap...@charter.net wrote: ErgoEmacs is too slow. I've uninstalled it and I'm going back to regular Emacs 23.2. The problem is that the scroll-wheel dynamic is very sluggish--unusable really. I think Jim noticed this earlier. I did not notice the problem until I had a need to page/scroll down in my larger files. Before I reinstall Emacs, is there any other option for Factor-editor integration with color and formatting on Windows? I like the REPL integration very much, but will do without it, if I can have a normal Windows keyboard binding, like Notepad++'s . The vocab for Notepadpp looks like it provides only an ability to launch the editor. Nothing is as fully developed as FUEL. You can try using the TextMate plugin with the e text editor from http://www.e-texteditor.com/, which is compatible with TextMate bundles. Its syntax highlighting should work out of the box, but the REPL interaction support relies on MacOS X's Services feature and would have to be ported to use another communication mechanism to interact with Factor on Windows. -Joe -- Increase Visibility of Your 3D Game App Earn a Chance To Win $500! Tap into the largest installed PC base get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Increase Visibility of Your 3D Game App Earn a Chance To Win $500! Tap into the largest installed PC base get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] factor self modify source
I don't use fuel/emacs, and so have a few steps when presented with a new USING: clause. Has anyone tried but discarded the thought of a word to update the code after a restart, for those of us with less than perfect editor integration? Is there a concern outside of overwriting changes in progress? Press F2 in the graphical listener (or type refresh-all in the terminal listener) and any changed source files will be reloaded. Is that what you had in mind? When you activate auto use, and get told the correct USING: clause, I think I'd like to either type a word or have a setting that updates the source file. I am close to being able to implement this myself (although I wouldn't mind any amount of direction) Check out Doug's annotations vocab. ( scratchpad ) USE: annotations ( scratchpad ) : foo ( x y -- z ) !TODO handle divide by zero / ; ( scratchpad ) TODOs. Computing usage index... done IN: scratchpad : foo ( x y -- z ) -Joe THANKS! I knew it. -- Increase Visibility of Your 3D Game App Earn a Chance To Win $500! Tap into the largest installed PC base get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] How do I construct a sequence from valuesonthestack
Thank you! The way I was thinking about it, it wouldn't compile, thinking | took precedence. On Wed, Nov 17, 2010 at 6:06 PM, Chris Double chris.dou...@double.co.nzwrote: On Thu, Nov 18, 2010 at 1:53 PM, Jim mack j...@less2do.com wrote: ws = | \t = [[ string whitespace boa ]] Change this to: ws = ( | \t) = [[ string whitespace boa ]] In the first case the = is binding to the \t part of the clause. Chris. -- http://www.bluishcoder.co.nz -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] loading of webapps.site-watcher
We can't seem to get the below simple high level db-tuple example going, which may be easier to debug if it is sqlite problem. Shaping, this prints a folder to 'Look in:'. Does it actually create that folder? If not, we have a permissions problem, perhaps. A file called adhoc.sqlite should appear upon execution of init-db, or nothing further can work, so please remind me of the results of the above two expectations. USING: db.types db.tuples db.sqlite io.directories fry db calendar ; TUPLE: entity id author date content ; entity entity { { id ID INTEGER +db-assigned-id+ } { author AUTHOR { VARCHAR 256 } +not-null+ } ! uid { date DATE TIMESTAMP +not-null+ } { content CONTENT TEXT +not-null+ } } define-persistent : blog-db ( -- db ) adhoc home prepend-path [ make-directories ] [ adhoc.sqlite append-path ] bi sqlite-db ; : with-blog-data ( quot -- ) '[ blog-db _ with-db ] call ; inline : init-db ( -- ) [ entity ensure-table ] with-blog-data ; adhoc home prepend-path Look in: prepend . init-db entity new Jim author now date blog entry content [ insert-tuple ] with-blog-data entity new Shaping author now date blog entry reply content [ insert-tuple ] with-blog-data [ entity new select-tuples ] with-blog-data [ select * from entity order by author sql-query ] with-blog-data -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] How do I construct a sequence from valuesonthestack
I'm having trouble with ! Is there some combination of ![a-zA-Z0-9]+ that will match white-space or punctuation? On Wed, Nov 17, 2010 at 4:33 PM, Jeff C. Britton j...@iteris.com wrote: Thanks, I like this. I will need to look into PEG. --Jeff -Original Message- From: Chris Double [mailto:chris.dou...@double.co.nz] Sent: Wednesday, November 17, 2010 4:09 PM To: factor-talk@lists.sourceforge.net Subject: Re: [Factor-talk] How do I construct a sequence from valuesonthestack On Thu, Nov 18, 2010 at 12:52 PM, Jeff C. Britton j...@iteris.com wrote: I have a string that I want to match against a regular expression. However, group capture is not supported :( Here's an approach using peg.ebnf. You'll also need math.parser for 'stringnumber' and peg for 'ignore'. EBNF: parse-line digits = [0-9]+ = [[ string stringnumber ]] part1 = digits:a : digits:b = [[ { a b } ]] ws = | \t , = , = [[ drop ignore ]] any6 = . . . . . . = [[ string ]] part2 = approach | detect part3 = any | down part4 = presence | extension | delay | pulse | etc line = part1 ws* , any6 , part2 , part3 , part4 , digits , digits , digits , digits , presence , digits , presence , digits ;EBNF 1:0,z1,approach,any,presence,0,1,1,0,presence,0,presence,0 parse-line Chris. -- http://www.bluishcoder.co.nz -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] How do I construct a sequence from valuesonthestack
TUPLE: digits text ; TUPLE: punc text ; TUPLE: upper text ; TUPLE: lower text ; TUPLE: whitespace text ; EBNF: categorize digits = [0-9]+ = [[ string digits boa ]] lower = [a-z]+ = [[ string lower boa ]] upper = [A-Z]+ = [[ string upper boa ]] punc = [!-/:-...@[-`{-~]+ = [[ string punc boa ]] ws = | \t = [[ string whitespace boa ]] line = (ws|digits|lower|upper|punc)+ ;EBNF 'Jim Mack.' categorize V{ T{ punc { text ' } } T{ upper { text J } } T{ lower { text im } } T{ upper { text M } } T{ lower { text ack } } T{ punc { text .' } } } Please, how do I get the ws to function the way the other char sets do? -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Integrating Browser functionality into Listener: John Benediktsson's Syntax Highlighting
I'm puzzled by the stuff inside the stack-effect syntax: ( -- ). I thought that the tokens on either side of the -- are just dummy variables representing, on the one hand, *strictly* the *number of input arguments and the number of results*, and, on the other, *loosely* the types of those arguments and results. I must not have the right idea. How can per-stack-position type-integrity be enforced if this is so? For the most part they are dumb, but within the desire for some convention. Use the predicates if you feel something is out of control and the stack isn't in the right order. If you want something to work from the class or an instance, you will see conversion at time. TUPLE: jim ; ERROR: not-jim x ; : only-clones ( x -- x ) dup jim? [ not-jim ] unless ; ! try each seperately jim only-clones jim new only-clones jim only-clones This seems to be the kind of type checking you are looking for. It's a little, in a stockyard, like checking each cow for cowness as it walks around, rather than as it was admitted. Maybe use it in the beginning, but sooner or later trust your own code more -- ( scratchpad ) : foo ( x quot: ( x -- ) -- ) call ; inline ( scratchpad ) : bar ( x y -- ) [ + . ] foo ; ! bar should cause an Input quotation to foo doesn't match its expected effect error -- I don't understand above what quot: and more generally what x quot: ( x -- ) as the before-effect of foo is doing. The colon on the right side of quot: is confusing me, because I am trying to read RPN, left to right. This syntax makes me want to reverse my reading direction for that expression. I can't find any info in Browser on quot:. If the word declares a polymorphic effect (using ..a style stack variables to represent a variable number of values), the arities of the stack variables will be unified, and an error raised if unification fails: Does Unification mean arities of stack variables are determined to be equal? There is a section in Browser called Stack effect checking. What should I read besides this to understand the full significance of the stack-effect syntax, what it can do and not do, and how it affects compiler behavior? -- ( scratchpad ) \ if see : if ( ..a ? true: ( ..a -- ..b ) false: ( ..a -- ..b ) -- ..b ) ? call ; ( scratchpad ) : bas ( x y z? -- ) [ + ] [ neg ] if ; ! bas should cause an Input quotations to “if” don't match their expected effects error -- I'm not understanding the English in the comment above. Ditto for the similar comment above. The quotes are matched, but I cannot make any sense of it. If a higher-order word declares no stack effect for its quotation arguments, the overall stack effect of the caller will still be checked when the body of the higher-order word and its arguments have been inlined. That makes sense, but I need to study a full description of the stack-effect syntax and it ramifications for thinking about the effects of higher-order words. Shaping -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] What should I call to issue [ 8080 httpd ] in-thread again, after closing factor reopening?
You called it on the nose - I was thinking I could rely on screen, and that when it closed, everything it ran closed. I will adopt dtach, thanks. On Mon, Nov 15, 2010 at 2:40 PM, Aaron Bull Schaefer aa...@elasticdog.comwrote: On Mon, Nov 15, 2010 at 2:26 PM, Jim mack j...@less2do.com wrote: Newbie question: I have been using screen to start factor listener. Is there any way a factor listener could keep going, and yet not show as a detached screen? I had assumed not, so had been relying on the presence of a screen running factor as my test of factor already running. Now maybe I'll learn how to use ps better. :) Are you saying that ps u | grep factor isn't showing your actual factor process? It should be there, even if it was run under screen and subsequently detached. On my Linux machine, I alias factor to dtach -n /tmp/factor.sock factor. It's a similar solution to just using screen, but dtach has a slightly different use case [1]. The main advantage dtach has over just backgrounding the process with factor is that it won't be tied to your terminal session. [1] http://dtach.sourceforge.net/ -- Aaron Bull Schaefer http://elasticdog.com/ -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] need help with slices
T{ slice f 0 2 ab,cd } string Remember that each, map, first will all work - but in this case work on the char values not little one char strings. On Tue, Nov 16, 2010 at 12:16 PM, Jeff C. Britton j...@iteris.com wrote: T{ slice f 0 2 ab,cd } -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] How do I construct a sequence from values on thestack
[ ] each On Tue, Nov 16, 2010 at 6:56 PM, Jeff C. Britton j...@iteris.com wrote: Thanks, but now I want to do the reverse. Stack Top Some WordNew Stack Top { 2 4 8 16 32 } ?32 16 8 4 2 -Original Message- From: Chris Double [mailto:chris.dou...@double.co.nz] Sent: Tuesday, November 16, 2010 6:01 PM To: factor-talk@lists.sourceforge.net Subject: Re: [Factor-talk] How do I construct a sequence from values on thestack On Wed, Nov 17, 2010 at 2:56 PM, Jeff C. Britton j...@iteris.com wrote: What word do I need? There are worlds like 1array, 2array, 3array and 4array to produce an array from that many items on the stack. There is also 'narray' which is a generalisation of these for any number. eg: 2 4 8 16 32 4 narray = { 2 4 8 16 } Chris. -- http://www.bluishcoder.co.nz -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] What should I call to issue [ 8080 httpd ] in-thread again, after closing factor reopening?
Thank you! I was looking at this more as a potential regression in factor, but I think it more productive to look at it as my noobieness on *nx. On Mon, Nov 15, 2010 at 10:32 AM, Jeff C. Britton j...@iteris.com wrote: See pitfall #3 in this link http://www.ibm.com/developerworks/linux/library/l-sockpit/ I cannot help with applying this knowledge to the Factor API. --Jeff -- *From:* Jim mack [mailto:j...@less2do.com] *Sent:* Sunday, November 14, 2010 11:56 AM *To:* factor-talk@lists.sourceforge.net *Subject:* [Factor-talk] What should I call to issue [ 8080 httpd ] in-thread again, after closing factor reopening? reopening factor, then calling to [ 8080 httpd ] in-thread is now throwing this kind of an error [2010-11-14T19:53:33Z] NOTICE start-accept-loop: T{ inet6 f :: 8080 } [2010-11-14T19:53:33Z] NOTICE start-accept-loop: T{ inet4 f 0.0.0.0 8080 } [2010-11-14T19:53:33Z] ERROR start-accept-loop: Unix system call E2809CbindE2809D failed: [] ERROR start-accept-loop: Address already in use (98) [] ERROR start-accept-loop: It was called with the following arguments: [] ERROR start-accept-loop: 18 [] ERROR start-accept-loop: S{ sockaddr-in6 f 10 36895 0 ~uchar-array~ 0 } [] ERROR start-accept-loop: 28 [2010-11-14T19:53:33Z] ERROR start-accept-loop: Unix system call E2809CbindE2809D failed: [] ERROR start-accept-loop: Address already in use (98) [] ERROR start-accept-loop: It was called with the following arguments: [] ERROR start-accept-loop: 18 [] ERROR start-accept-loop: S{ sockaddr-in f 2 36895 0 0 } [] ERROR start-accept-loop: 16 I am on latest stable release binaries, ubuntu 10.4 lts, linode. I am leaving the listener open in a screen. I thought I went through months of this kind of deployment successfully, where I would just git pull in the work folder, close restart factor + my vocab, and it would serve the updated page. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Git
Someone please check the following statements for accuracy: A == remote repo B == local repo C == local working directory including by definition the local repo (.git directory) 1) *clone* copies compressed files from a remote repo to a local repo,creates remote-tracking branches for each branch in the remote repository, and creates and *checks out* an initial branch forked from the cloned repository’s currently active branch. A - B - C. 2) *checkout* updates files in the working directory to match the version in the specified branch of the repo. By default, the current branch is set to the specified branch. B - C. 3) *fetch* only copies compressed files from a remote repo to a local repo. A - B. 3) *pull* *fetches* and then *merges* the fetched code into the current branch. A - B. No check-out is done; so how does the repo code get into the working directory (C)? In practice, I think our factor.cmd does a pull that puts code in the working directory, which is where the compiler goes for its source during the build. So this is not clear to me. Perhaps I don't understand what *merge* means. Pull performs A B, B C. When I work with my own hosted git repos, github, I either do pushes or pulls exclusively, and no other commands. 5) *merge* replays changes from a specified branch into the current branch. The changes are those resulting from commits in the specified branch since it diverged from the current branch. This looks like a local, repo-only operation: B - B. I think it's B' - B, then B - C 4) *push* copies compressed files from a local repo to a remote one, to update it. B - A -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] What should I call to issue [ 8080 httpd ] in-thread again, after closing factor reopening?
Will do. To get going, I had been running as root (which I know is bad, but I could get it working) I am now trying to start using port forwarding, so I'll try to make sure that isn't what's causing this. Newbie question: I have been using screen to start factor listener. Is there any way a factor listener could keep going, and yet not show as a detached screen? I had assumed not, so had been relying on the presence of a screen running factor as my test of factor already running. Now maybe I'll learn how to use ps better. :) On Mon, Nov 15, 2010 at 2:21 PM, Doug Coleman doug.cole...@gmail.comwrote: Except, Factor already sets the REUSE flag with setsockopt. So maybe you have a Factor running in the background? Can you make a test case? Doug On Nov 15, 2010, at 2:01 PM, Jim mack wrote: Thank you! I was looking at this more as a potential regression in factor, but I think it more productive to look at it as my noobieness on *nx. On Mon, Nov 15, 2010 at 10:32 AM, Jeff C. Britton j...@iteris.com wrote: See pitfall #3 in this link http://www.ibm.com/developerworks/linux/library/l-sockpit/ I cannot help with applying this knowledge to the Factor API. --Jeff -- *From:* Jim mack [mailto:j...@less2do.com] *Sent:* Sunday, November 14, 2010 11:56 AM *To:* factor-talk@lists.sourceforge.net *Subject:* [Factor-talk] What should I call to issue [ 8080 httpd ] in-thread again, after closing factor reopening? reopening factor, then calling to [ 8080 httpd ] in-thread is now throwing this kind of an error [2010-11-14T19:53:33Z] NOTICE start-accept-loop: T{ inet6 f :: 8080 } [2010-11-14T19:53:33Z] NOTICE start-accept-loop: T{ inet4 f 0.0.0.0 8080 } [2010-11-14T19:53:33Z] ERROR start-accept-loop: Unix system call E2809CbindE2809D failed: [] ERROR start-accept-loop: Address already in use (98) [] ERROR start-accept-loop: It was called with the following arguments: [] ERROR start-accept-loop: 18 [] ERROR start-accept-loop: S{ sockaddr-in6 f 10 36895 0 ~uchar-array~ 0 } [] ERROR start-accept-loop: 28 [2010-11-14T19:53:33Z] ERROR start-accept-loop: Unix system call E2809CbindE2809D failed: [] ERROR start-accept-loop: Address already in use (98) [] ERROR start-accept-loop: It was called with the following arguments: [] ERROR start-accept-loop: 18 [] ERROR start-accept-loop: S{ sockaddr-in f 2 36895 0 0 } [] ERROR start-accept-loop: 16 I am on latest stable release binaries, ubuntu 10.4 lts, linode. I am leaving the listener open in a screen. I thought I went through months of this kind of deployment successfully, where I would just git pull in the work folder, close restart factor + my vocab, and it would serve the updated page. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev
Re: [Factor-talk] Furnace on Windows
the work repository is a separate git base from the larger code base. When you are in factor\work, git knows about your personal repository (assuming you have one set up) but when you are in factor, it knows about where you cloned from, but will ignore work as that's a personal distribution. On Sun, Nov 14, 2010 at 12:17 AM, Shaping shap...@charter.net wrote: I only know the command line so I'll give you command line tips and you can translate them to equivalent GUI commands. 1) Clone the factor respository git clone git://factorcode.org/git/factor.git 2) In this repository you make your own changes, including adding stuff to the work directory, editing files, etc. Now you want to save those in git so you can update safely. git add work/my-new-vocab/* git add any-other-new-files The problem: what if I have editing existing files, and there are no new files in the vocab root directories, only changed existing files? got commit -m This is a message describing my changes 3) Now you want to retrieve the latest changes from the factor repository: git fetch origin Oops. I did not do the last line of (2) before I did (3). I can identify the menu item for (3). It reads the same. I cannot identifiy an add menu item, except under the Remote menu, which I don't think is what we want here. Nothing is apparently any different in my repo, for having done the fetch. Does the fetched delta show up the same way my own edits do. Maybe not. If so, that would explain why I don't see them in Unstaged changes (which are just my manually created mods?). 4) Note that step (3) only retrieved the changes. It has made no changes to your actual physical source code. To update that, assuming you've done (2): git rebase origin/master Replace 'origin/master' with 'origin/clean-...' or whatever branch you are using from the factor repository. Probably master as that's the default. If there is a clash between your changes and the factor repository you'll get the chance to edit your changes and fix the clash. You can then do: git add ...file-containing-fixes git rebase --continue Or, if you are panicing, you can abort the rebase and be back to just a repository with your changes: git rebase --abort These steps will ensure that your changes always are based on top of the latest factor repository changes That's what I want, but I don't see the mapping yet to the menu items. I'll look around for the GUI help. The default help doesn't mention the GUI, only the command line. , making it easy to use 'git log' and friends to see what your changes are, and to contribute them back to factor one day. I just realized that work does not show in my Unstaged Changes. Does anyone here use Git GUI on Windows? ... Apparently, adding (or almost adding) is the act of moving from the U nstaged to the Staged Changes (Will Commit) box. This publishes to my clone, not to the original repo I cloned, correct? ... Why doesn't my work directory show in Unstaged Changes? There is plenty of new work there. ... So I'm not sure how to do (2) yet. Shaping -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A
Re: [Factor-talk] Furnace on Windows
There's a lot going on, so context is difficult here, but I was trying to go back in time before you made changes, and suggest when working on Factor main code, you make changes *in a branch,* sync with the larger community in the main trunc, not a branch, then integrate your stuff by merging from that branch into the main trunk. Not everyone works the same way, and the regular contributors who are sure of their work may have shortcuts for their preferences. I didn't see much discussion over the strategy, which may help understand things like fetch/pull in context. On Sun, Nov 14, 2010 at 1:01 AM, Shaping shap...@charter.net wrote: the work repository is a separate git base from the larger code base. I know. This is the result of the cloning. When you are in factor\work, git knows about your personal repository (assuming you have one set up) but when you are in factor, it knows about where you cloned from, but will ignore work as that's a personal distribution. I know. I'm concerned about possible collisions with modified stock code. I think the point Chris is making in his step 2 is that these changes need to be committed, first, but he did not mention old directories , only new ones. Shaping. On Sun, Nov 14, 2010 at 12:17 AM, Shaping shap...@charter.net wrote: I only know the command line so I'll give you command line tips and you can translate them to equivalent GUI commands. 1) Clone the factor respository git clone git://factorcode.org/git/factor.git 2) In this repository you make your own changes, including adding stuff to the work directory, editing files, etc. Now you want to save those in git so you can update safely. git add work/my-new-vocab/* git add any-other-new-files The problem: what if I have editing existing files, and there are no new files in the vocab root directories, only changed existing files? got commit -m This is a message describing my changes 3) Now you want to retrieve the latest changes from the factor repository: git fetch origin Oops. I did not do the last line of (2) before I did (3). I can identify the menu item for (3). It reads the same. I cannot identifiy an add menu item, except under the Remote menu, which I don't think is what we want here. Nothing is apparently any different in my repo, for having done the fetch. Does the fetched delta show up the same way my own edits do. Maybe not. If so, that would explain why I don't see them in Unstaged changes (which are just my manually created mods?). 4) Note that step (3) only retrieved the changes. It has made no changes to your actual physical source code. To update that, assuming you've done (2): git rebase origin/master Replace 'origin/master' with 'origin/clean-...' or whatever branch you are using from the factor repository. Probably master as that's the default. If there is a clash between your changes and the factor repository you'll get the chance to edit your changes and fix the clash. You can then do: git add ...file-containing-fixes git rebase --continue Or, if you are panicing, you can abort the rebase and be back to just a repository with your changes: git rebase --abort These steps will ensure that your changes always are based on top of the latest factor repository changes That's what I want, but I don't see the mapping yet to the menu items. I'll look around for the GUI help. The default help doesn't mention the GUI, only the command line. , making it easy to use 'git log' and friends to see what your changes are, and to contribute them back to factor one day. I just realized that work does not show in my Unstaged Changes. Does anyone here use Git GUI on Windows? ... Apparently, adding (or almost adding) is the act of moving from the Unstaged to the Staged Changes (Will Commit) box. This publishes to my clone, not to the original repo I cloned, correct? ... Why doesn't my work directory show in Unstaged Changes? There is plenty of new work there. ... So I'm not sure how to do (2) yet. Shaping -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework.
Re: [Factor-talk] linode memory problem
I'm running ubuntu 10.4 lts, and just refreshed factor rebuilt using the ./build-support/factor.sh update method at about 10pm Saturday. The last time I build was 2 months ago, and the code has changed, but runs on both pc mac using the binary downloads as recent as a week ago. On Sun, Nov 14, 2010 at 12:05 AM, Jim mack j...@less2do.com wrote: How do I go about starting to think about this: ( scratchpad - auto ) Out of memory Nursery: Start=b6c8, size=10, end=b6d8 Aging: Start=b6a8, size=20, end=b6c8 Tenured: Start=b088, size=600, end=b688 Cards:base=b080a008, size=65400 r...@blogtation:/usr/factor# It's on the smallest linode, using port forwarding, trying to run from the factor listener in a screen session. I'm a unix noobie. The website got launched fine, but the first few seconds of interacting with it failed. I looked in doc for the word memory, is room. detailed enough? Does anything suggest itself? I am using ajax with polling every 500 ms but only one user in what you could think of as a chat app. room. == Data heap == - Nursery space Size: 1,024 KB Occupied: 133 KB Free: 890 KB - Aging space Size: 2,048 KB Occupied: 194 KB Free: 1,853 KB - Tenured space Size: 98,304 KB Occupied: 60,667 KB Total free: 37,636 KB Contiguous free: 37,626 KB Free block count: 116 - Miscellaneous buffers Card array: 405 KB Deck array: 0 KB Mark stack: 16 KB == Code heap == Size: 65,536 KB Occupied: 10,131 KB Total free: 55,404 KB Contiguous free: 55,401 KB Free block count: 59 Optimized code: 42096 blocks 6,886 KB Unoptimized code: 30440 blocks 2,737 KB Inline caches:3363 blocks 507 KB Profiling stubs: 0 blocks 0 KB ( scratchpad - auto ) -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace on Windows
There is a subfolder in my work folder called .git This is what I think of as the repository. When you do a git add or commit, it's going between these two places. When you do a clone, push, pull, or fetch you're going to some remote place as well. On Sun, Nov 14, 2010 at 3:45 PM, Shaping shap...@charter.net wrote: Yes. By directory below is meant place of the repo, whether a local place or a remote one. Shaping -Original Message- From: William Tanksley, Jr [mailto:wtanksle...@gmail.com] Sent: 2010-November-14, 17:42 To: factor-talk@lists.sourceforge.net Subject: Re: [Factor-talk] Furnace on Windows Shaping shap...@charter.net wrote: If you have a personal git host somewhere, and there are free ones, try making two clones of the same little folder I thought one clones only a repo. Every working directory cloned from a repo is itself a repo. This is why git is a decentralized and distributed version control system, as opposed to CVS and Subversion, both of which are centralized. Shaping -Wm -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace on Windows
On Sun, Nov 14, 2010 at 2:45 PM, Shaping shap...@charter.net wrote: There's a lot going on, so context is difficult here, but I was trying to go back in time before you made changes, and suggest when working on Factor main code, you make changes *in a branch,* sync sync means to resolve conflicting changes? I am reading the Git documentation from beginning to end, now, and haven't come across the term yet. Git is sending around deltas with enough clues to usually accurately modify things, and it does a good job. Only rarely are the changes overlapping enough to need you to resolve conflicting changes. with the larger community in the main trunc, not a branch, then integrate your stuff by merging from that branch into the main trunk. Not everyone works the same way, and the regular contributors who are sure of their work may have shortcuts for their preferences. I didn't see much discussion over the strategy, which may help understand things like fetch/pull in context. I don't want to publish my changes anytime soon, only distinguish them from released clean-branch code, so that I can track both. If you get tired of so much standing in your way of going forward, consider doing manual things with these files, old-school (rename/move them, checkout so you have latest, copy back over). I get the sense there are a lot of formalities standing in the way of your having more fun with the actual code at hand. Factor is wonderful, I love it with a *passion*. I hope you find time to discover that amid all the font changing and source code system learning. Shaping On Sun, Nov 14, 2010 at 1:01 AM, Shaping shap...@charter.net wrote: the work repository is a separate git base from the larger code base. I know. This is the result of the cloning. When you are in factor\work, git knows about your personal repository (assuming you have one set up) but when you are in factor, it knows about where you cloned from, but will ignore work as that's a personal distribution. I know. I'm concerned about possible collisions with modified stock code. I think the point Chris is making in his step 2 is that these changes need to be committed, first, but he did not mention old directories , only new ones. Shaping. On Sun, Nov 14, 2010 at 12:17 AM, Shaping shap...@charter.net wrote: I only know the command line so I'll give you command line tips and you can translate them to equivalent GUI commands. 1) Clone the factor respository git clone git://factorcode.org/git/factor.git 2) In this repository you make your own changes, including adding stuff to the work directory, editing files, etc. Now you want to save those in git so you can update safely. git add work/my-new-vocab/* git add any-other-new-files The problem: what if I have editing existing files, and there are no new files in the vocab root directories, only changed existing files? got commit -m This is a message describing my changes 3) Now you want to retrieve the latest changes from the factor repository: git fetch origin Oops. I did not do the last line of (2) before I did (3). I can identify the menu item for (3). It reads the same. I cannot identifiy an add menu item, except under the Remote menu, which I don't think is what we want here. Nothing is apparently any different in my repo, for having done the fetch. Does the fetched delta show up the same way my own edits do. Maybe not. If so, that would explain why I don't see them in Unstaged changes (which are just my manually created mods?). 4) Note that step (3) only retrieved the changes. It has made no changes to your actual physical source code. To update that, assuming you've done (2): git rebase origin/master Replace 'origin/master' with 'origin/clean-...' or whatever branch you are using from the factor repository. Probably master as that's the default. If there is a clash between your changes and the factor repository you'll get the chance to edit your changes and fix the clash. You can then do: git add ...file-containing-fixes git rebase --continue Or, if you are panicing, you can abort the rebase and be back to just a repository with your changes: git rebase --abort These steps will ensure that your changes always are based on top of the latest factor repository changes That's what I want, but I don't see the mapping yet to the menu items. I'll look around for the GUI help. The default help doesn't mention the GUI, only the command line. , making it easy to use 'git log' and friends to see what your changes are, and to contribute them back to factor one day. I just realized that work does not show in my Unstaged Changes. Does anyone here use Git GUI on Windows? ... Apparently, adding (or almost adding) is the act of moving from the Unstaged to the Staged Changes (Will Commit) box. This publishes to my clone, not to the original
Re: [Factor-talk] Furnace
I think you may not have sqlite installed. http://www.sqlite.org/download.html precompiled binaries for ms go in your factor folder for ease. I have a sqlite3.def, .dll, .exe. When I hide those, I get the image refers to a library or symbol that was not found at load time which is a reasonable give-away. Maybe it gets closer for me because I do so much open source dev on my ms box. On Sat, Nov 13, 2010 at 12:33 AM, Shaping shap...@charter.net wrote: I just tried the part from TUPLE: to init-db and it worked on both mac and pc. Was this an error message? What did you do exactly to test it? I trying to find all the needed vocabs one step at a time. So far I've added two vocabs to the USES statement, and I have remaining this error: The image refers to a library or symbol that was not found at load time What is your context (USE:, USING:, etc) for setup and testing? Shaping ! This is a self contained test of creating a sqlite db. Click on autouse, paste enter. TUPLE: entity id author date content ; entity entity { { id ID INTEGER +db-assigned-id+ } { author AUTHOR { VARCHAR 256 } +not-null+ } ! uid { date DATE TIMESTAMP +not-null+ } { content CONTENT TEXT +not-null+ } } define-persistent : blog-db ( -- db ) adhoc home prepend-path [ make-directories ] [ blogs.sqlite append-path ] bi sqlite-db ; : with-blog-data ( quot -- ) '[ blog-db _ with-db ] call ; inline : init-db ( -- ) [ entity ensure-table ] with-blog-data ; adhoc home prepend-path Look in: prepend . init-db -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! *http://p.sf.net/sfu/dell-eql-dev2dev*http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list *factor-t...@lists.sourceforge.net* Factor-talk@lists.sourceforge.net *https://lists.sourceforge.net/lists/listinfo/factor-talk*https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace
Shaping, I apologize for being lazy before: I usually work from an environment where many things are already loaded. I also kept starting from what I sent, not what you had evolved it into. I have no idea where run-fac came from. There is a run-factor word in the tools.deploy.backend vocab, but This time I went to the minimal install, added some things to the USING clause, and made sure it works from a downloaded state. Here is the code for a tuple example that works: USING: db.types db.tuples db.sqlite io.directories fry db calendar ; TUPLE: entity id author date content ; entity entity { { id ID INTEGER +db-assigned-id+ } { author AUTHOR { VARCHAR 256 } +not-null+ } ! uid { date DATE TIMESTAMP +not-null+ } { content CONTENT TEXT +not-null+ } } define-persistent : blog-db ( -- db ) adhoc home prepend-path [ make-directories ] [ adhoc.sqlite append-path ] bi sqlite-db ; : with-blog-data ( quot -- ) '[ blog-db _ with-db ] call ; inline : init-db ( -- ) [ entity ensure-table ] with-blog-data ; adhoc home prepend-path Look in: prepend . init-db entity new Jim author now date blog entry content [ insert-tuple ] with-blog-data entity new Shaping author now date blog entry reply content [ insert-tuple ] with-blog-data [ entity new select-tuples ] with-blog-data [ select * from entity order by author sql-query ] with-blog-data -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace on Windows
Thanks! I finally had time to figure out why it was failing for me - concatenative.factor was assigning a port to secure. : concatenative-website-server ( -- threaded-server ) http-server factor-secure-config secure-config 8080 insecure os winnt? [ 8431 secure ] unless ; -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace on Windows
From http://concatenative.org/wiki/view/Factor/Building%20Factor Building and updating Factor the easy way Once you have a GIT checkout of the Factor source tree, you can use the build-support/factor.sh utility to check for updates, and build Factor: ./build-support/factor.sh update This utility automatically updates your repository, rebuilds the Factor VM, downloads the latest boot image, and bootstrapshttp://concatenative.org/wiki/view/Bootstrap Factor. This utility will work on Windows if Cygwin is installed. However, if Cygwin is not installed, you can still build Factor using the directions below. I don't build on windows, but from my unix host this seems to work like a charm. On Sat, Nov 13, 2010 at 8:42 PM, Shaping shap...@charter.net wrote: I have a Windows clean-branch check-out from about two weeks ago. Slava, your new changes are in only websites.concatenative? I'm studying the Git help on updating a repository (repository branch?). file:///C:/Program%20Files%20(x86)/Git% 201.7.3.1/doc/git/html/user-manual.ht ml#Updating-a-repository-With-git-fetch I use Git GUI (not the command window), and guess that command git fetch is the same as the Remote= Fetch From = origin. I did that and got what maybe the deltas (not sure): From git://factorcode.org/git/factor f0e8593..dbfade1 clean-freebsd-x86-32 - origin/clean-freebsd-x86-32 f0e8593..dbfade1 clean-freebsd-x86-64 - origin/clean-freebsd-x86-64 ace41a6..dbfade1 clean-linux-x86-32 - origin/clean-linux-x86-32 f0e8593..dbfade1 clean-linux-x86-64 - origin/clean-linux-x86-64 f0e8593..9948004 clean-macosx-x86-32 - origin/clean-macosx-x86-32 f0e8593..9948004 clean-macosx-x86-64 - origin/clean-macosx-x86-64 f0e8593..dbfade1 clean-openbsd-x86-32 - origin/clean-openbsd-x86-32 f0e8593..9948004 clean-openbsd-x86-64 - origin/clean-openbsd-x86-64 5cc7ac4..0939515 clean-winnt-x86-32 - origin/clean-winnt-x86-32 f0e8593..9948004 clean-winnt-x86-64 - origin/clean-winnt-x86-64 f0e8593..f6a562a master - origin/master Hitting F5 in the Git GUI, though, doesn't show any changes in my repo directories; so that command must not be doing what I suppose it is. If you have work in progress in several vocab directories (shown in Unstaged Changes), how do you protect those from possible overwrite, before you commit them? My 'work' directory work is always safe, but not so for the other directories. Another possibility is to check-out again the same Tracking Branch, but this may not be necessary. I am just now reading all of the Git Help starting from the beginning, but I thought I would seek a few basic guidelines here, as well, so that I could update my repo now, and test the web stuff. I suspect most Git users do mostly the same four or five operations, repeatedly, to maintain their repo. Shaping -Original Message- From: Slava Pestov [mailto:sl...@factorcode.org] Sent: 2010-November-13, 18:34 To: factor-talk@lists.sourceforge.net Subject: [Factor-talk] Furnace on Windows Hi all, I've fixed Furnace to work when SSL is not available, so it should work on Windows now. Try this for example: USE: websites.concatenative init-testing start-website Then navigate to http://localhost:8080. Slava -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more!
Re: [Factor-talk] Furnace
Shaping, Somehow I'm missing context. When/where did you see run-fac? I just tried the part from TUPLE: to init-db and it worked on both mac and pc. Was this an error message? On Fri, Nov 12, 2010 at 12:26 AM, Shaping shap...@charter.net wrote: Jim, can you give me more context for the bits below? I cannot find a definition for run-fac. Shaping *From:* Jim mack [mailto:j...@less2do.com] *Sent:* 2010-November-08, 12:11 *To:* factor-talk@lists.sourceforge.net *Subject:* Re: [Factor-talk] Furnace ! This is a self contained test of creating a sqlite db. Click on autouse, paste enter. TUPLE: entity id author date content ; entity entity { { id ID INTEGER +db-assigned-id+ } { author AUTHOR { VARCHAR 256 } +not-null+ } ! uid { date DATE TIMESTAMP +not-null+ } { content CONTENT TEXT +not-null+ } } define-persistent : blog-db ( -- db ) adhoc home prepend-path [ make-directories ] [ blogs.sqlite append-path ] bi sqlite-db ; : with-blog-data ( quot -- ) '[ blog-db _ with-db ] call ; inline : init-db ( -- ) [ entity ensure-table ] with-blog-data ; adhoc home prepend-path Look in: prepend . init-db -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Factor GUI
Well, when you're doing development, any web page is an example as you're running locally. The jump would be to compile it as a stand-alone. I was impressed how easily we have an http server. Compare that to configuring IIS to run ASP pages, and I want to barf. (Yes, I know that's not apples to apples, but often I just want the core of the apple!) If you want to follow the path of least resistance, try getting the calculator running then modify from there. Next, compare to the blog webapp and try to run it from the same 'run-calculator' type word. Blogs should teach you enough about chloe to decide if you like it or not. Using fhtml templates is like php development. Play with it: : fhtml-file ( fname -- str ) fhtml [ call-template ] with-string-writer ; I never have understood the exact difference between dispatcher and responder, but somehow still can get things working. You'll probably need to know about db-tuples, although you can do quite a bit keeping objects in memory. Although the web page is stateless, global variables in factor are available because there's only one instance running all requests. You can also temporarily violate best practices and save whatever you want in the session, then come back later and make it more able to run from anywhere if you need. On Thu, Nov 11, 2010 at 11:11 PM, Shaping shap...@charter.net wrote: What is currently the best example/demo involving a locally running web-server serving HTML pages? I need to get more deeply into HTML 5 and CSS 3, anyway. Shaping *From:* Jim mack [mailto:j...@less2do.com] *Sent:* 2010-November-11, 13:29 *To:* factor-talk@lists.sourceforge.net *Subject:* Re: [Factor-talk] Factor GUI Don't ignore the possibility of deploying as a local http server and having a local webapp. The server would be on the box, so it could do things locally, call COM, access clipboard. It's how I'm trying to do things, and works cross-platform, and is only limited by your html/css skills. On Thu, Nov 11, 2010 at 1:35 AM, Shaping shap...@charter.net wrote: I would still like to convince my sup that Factor is the way to go, and he'll want the latest and greatest Windows 7 GUI, eventually. So my next question is: Has anyone undertaken the task of making a more up-to-date looking set of widgets for Factor to use when creating GUI apps, even if those widgets/gadgets will not be used in the dev-environ itself? The widget styles for the Factor UI itself are just images, stored in basis/ui/gadgets/theme. Reskinning is a simple matter of replacing those images. But for end-user applications, you don't necessarily have to stick with the Factor UI's widgets. Since you're only targeting Windows, you can use the native Win32 APIs, or some other UI toolkit library. Yes, I was referring to the Win32 APIs. Is anyone working on this now? This is not the best strategy, anyway, if a broad deployment is the objective. The current Factor style reminds me of the Motif style. Shaping -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql
Re: [Factor-talk] Factor GUI
Thank you. On Fri, Nov 12, 2010 at 9:15 AM, Jon Harper jon.harpe...@gmail.com wrote: I never have understood the exact difference between dispatcher and responder, but somehow still can get things working. A responder is any tuple that implements the call-responder* generic word. A dispatcher is a responder. Its call-responder* implementation is to dispatch the request to its responders. Jon -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Help Browser slow
For what it's worth, I've not had the bug, but I usually browse over the internet docs. I like having multiple tabs open as I explore laterally. And, my mac doesn't seem to slow down using help, but my xp has for the last 8 months over multiple versions. On Fri, Nov 12, 2010 at 11:55 AM, Jeff C. Britton j...@iteris.com wrote: It is slow after a fresh install. The browser appears to do some kind of caching, so going to some pages is only slow the first time. Unfortunately, this caching seems to be lost upon restart. I get this occasionally You have triggered a bug in Factor. Please report. error: 16 arg 1: 44 arg 2: f Starting low level debugger... Most recently when pressing the Back button. --Jeff -- *From:* Jim mack [mailto:j...@less2do.com] *Sent:* Thursday, November 11, 2010 9:16 PM *To:* factor-talk@lists.sourceforge.net *Subject:* Re: [Factor-talk] Help Browser slow I first noticed this on xp once I had loaded a few libraries, usually furnace. Does the fresh exe seems reasonable? On Thu, Nov 11, 2010 at 5:17 PM, Jeff C. Britton j...@iteris.com wrote: On Windows XP the Browser that is opened upon clicking Help in the listener is painfully slow. For example, I clicked on Vocabulary tags, and a couple of minutes went by before the tags appeared. I then clicked on collections and another couple of minutes went by before the collections appeared. Is this normal? -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Docs and other topics
1) A google search: site:http://docs.factorcode.org/ [ ] each often finds what I'm looking for in the details, rather than as a topic/word. 2) I generate the docs html locally using a word provided and use a grep tool. USE: help.html load-all generate-help will make it in factor\temp\docs. I move it out of there. Lots of files. This is where one would generate the PDF as well. 3) I use a grep tool on the source itself, because that includes the code that generates the documents. On Thu, Nov 11, 2010 at 3:09 AM, Balazs Toth balazs...@gmail.com wrote: Hi, I don't know if my previous mail reached the list or not, but let me ask you once again: - is there some accumulated, readable documentation of Factor somewhere? Or at least a cheat sheet about the various features of the language? The help system is really nice and sufficient as it is if someone already knows what he is looking for. - in another thread you are talking about the UI and the adaptation of the system by someones supervisor. I would like to adapt the language as a supervisor, but cannot do that because of its unreal learning curve and lack of a handbook. - is Factor anywhere already used commercially? Is the making of the language financially efficient or only a side project currently for you Slava? About how reliable are the various features one can read about in the help? Thanks, Balazs -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Factor GUI
Don't ignore the possibility of deploying as a local http server and having a local webapp. The server would be on the box, so it could do things locally, call COM, access clipboard. It's how I'm trying to do things, and works cross-platform, and is only limited by your html/css skills. On Thu, Nov 11, 2010 at 1:35 AM, Shaping shap...@charter.net wrote: I would still like to convince my sup that Factor is the way to go, and he'll want the latest and greatest Windows 7 GUI, eventually. So my next question is: Has anyone undertaken the task of making a more up-to-date looking set of widgets for Factor to use when creating GUI apps, even if those widgets/gadgets will not be used in the dev-environ itself? The widget styles for the Factor UI itself are just images, stored in basis/ui/gadgets/theme. Reskinning is a simple matter of replacing those images. But for end-user applications, you don't necessarily have to stick with the Factor UI's widgets. Since you're only targeting Windows, you can use the native Win32 APIs, or some other UI toolkit library. Yes, I was referring to the Win32 APIs. Is anyone working on this now? This is not the best strategy, anyway, if a broad deployment is the objective. The current Factor style reminds me of the Motif style. Shaping -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Help Browser slow
I first noticed this on xp once I had loaded a few libraries, usually furnace. Does the fresh exe seems reasonable? On Thu, Nov 11, 2010 at 5:17 PM, Jeff C. Britton j...@iteris.com wrote: On Windows XP the Browser that is opened upon clicking Help in the listener is painfully slow. For example, I clicked on Vocabulary tags, and a couple of minutes went by before the tags appeared. I then clicked on collections and another couple of minutes went by before the collections appeared. Is this normal? -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace, XStreams (PEGs) and some observations about Factor
Maybe the dsl aspect could be viewed as applying a layer of sugar to the stack based workhorse. You could easily have 'adjectives' that accumulate into a variable, not on the stack, then a noun word that takes those options and does the work. This is how I accumulate attributes for the HTML elements, and it feels like a dsl: Save button submit org id form +content button puts save into an attribute variable submit uses (and clears) that variable, appends to the working collection id puts org in the same place that button put things before form uses the all-id variable to set attributes as it wraps what's on the stack +content puts it away somewhere. This, I think, works fine for a dsl. It also works fine if the 'attribute value' is a field of an object on the stack, and the stack throughout this is ( page-assembly current-chunk xx -- page-assembly current-chunk ) or sometimes going down to ( page-assembly current-chunk -- page-assembly ) Using vocabularies, you could even keep an internal and an external version of the word, where the stack one works faster, the other is the DSL. -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace
! This is a self contained test of creating a sqlite db. Click on autouse, paste enter. TUPLE: entity id author date content ; entity entity { { id ID INTEGER +db-assigned-id+ } { author AUTHOR { VARCHAR 256 } +not-null+ } ! uid { date DATE TIMESTAMP +not-null+ } { content CONTENT TEXT +not-null+ } } define-persistent : blog-db ( -- db ) adhoc home prepend-path [ make-directories ] [ blogs.sqlite append-path ] bi sqlite-db ; : with-blog-data ( quot -- ) '[ blog-db _ with-db ] call ; inline : init-db ( -- ) [ entity ensure-table ] with-blog-data ; adhoc home prepend-path Look in: prepend . init-db -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace
The current furnace paradigm has you creating many actions, then sending quots to slots in them. I've been working on something where the page uses a tuple and generics to process render itself, and a router determines which tuple to start with. This all happens through a single action. So the crud operations for an object all descend from a general object tuple page, giving lots of places for overriding behavior. The idea sounds well-factored. Thanks. It's been fun and a great way to learn. On the other hand, you can't give your html to a designer to have them make it prettier. I'm not trying to make an argument that it's better, it just fits how I think. It's also not ready for prime time, but you asked, so I answered :) A further squirrely thing I'm doing is generating the HTML unobtrusive JS What is unobtrusive JavaScript? The dom events aren't coded within the html but require a javascript call to hook in. I maintain a few javascript queues during the build process, add a request when I reneder the html for the object, then insert the queue contents into the page at the appropriate time - some to the page load event, some in the head, some at the end of the document. along the way, rather than having any page artifacts that get parsed (chloe) or filled (fhtml). And I've written words to add to and reuse the tuple slot meta data. This is the html/form generation for a subset of fields in the tuple: content-edit-fields Org Information HTML LEGEND + org-fields all-id FIELDSET BR Save button submit+ org all-id form yields: *http://paste.factorcode.org/paste?id=2044*http://paste.factorcode.org/paste?id=2044 I saved down the form and dropped it on Chrome and saw a reasonable 4-field form in a group box with a save button below the group box. How do I learn more about this scheme and what you have in mind for it? Is there a blog describing the idea in more detail? I am still very much a newbie here, crippled by my lack of formal CS training - I barely understand most of the conversations :) A lot of it was written before I knew what I now know, and I am trying to get an actual project launched before I have time to go back and make it non-embarrassing. I also would like to pay my dues by helping with existing documentation and examples, rather than adding yet another approach to an already large body of library code. Sadly, I still haven't built factor on my daily (work) xp pc. You may be an inspiration for that. In context, I thought I was mentioning it after I had counseled you to try a factor code-compile-test cycle that wasn't perfectly what you desired to just get going and have fun. I just didn't want you to think I was trying to shut down non-orthodox ideas - factor to me represents just the opposite. Which I remember as a problem with forth - everyone did everything their own way and reinvented many wheels, so it was too hard to get started for a casual person. Shaping -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] ErgoEmacs installation on Windows 7 64-bit; Factor-editor integration
Congratulations. Sorry I wasn't able to help more. I gave up on ergoEmacs, maybe a little quickly, after a feeling it was dramatically slower than the emacs I had compiled. On Sun, Nov 7, 2010 at 4:06 AM, Shaping shap...@charter.net wrote: Jim/all: I got Factor working with ErgoEmacs. I'll report the details after I sleep. Shaping *From:* Shaping [mailto:shap...@charter.net] *Sent:* 2010-November-07, 02:34 *To:* factor-talk@lists.sourceforge.net *Subject:* Re: [Factor-talk] ErgoEmacs installation on Windows 7 64-bit; Factor-editor integration Jim, I'm using the installer from http://ergoemacs.org/ I'm not building Emacs. The original Emacs is horribly unergonomic. Powerful as it can be as a center for all user action on a PC, it's a little embarrassing for its keyboard bindings, as the creators of ErgoEmacs have amply explained. I want to stick with ErgoEmacs or switch to some other editor. Suggestions anyone? Jim, did you get your ErgoEmacs install to work with Factor? When I open ErgoEmacs, it does its initialization. Clicking on the edit field at the bottom, immediately after initialization opens a pane in the bottom half of the window and shows all that was done: Loading c:/Program Files (x86)/ErgoEmacs 1.8.1/site-lisp/../ergoemacs/init... Loading ergoemacs-keybindings/ergoemacs-mode... Loading functions...done Loading ergoemacs-unbind...done Loading ergoemacs-layout-us...done Loading ergoemacs-keybindings/ergoemacs-mode...done Loading init_load_packages... Loading haskell-mode-2.7.0/haskell-site-file...done (((fundamental-mode . minibuffer-complete-and-exit) . 2) ((fundamental-mode . execute-extended-command) . 3) ((Info-mode . Info-mouse-follow-nearest-node) . 1) ((Info-mode . mouse-drag-region) . 1) ((Info-mode . mwheel-scroll) . 22) ((Info-mode . info-emacs-manual) . 1) ((fundamental-mode . self-insert-command) . 76) ((fundamental-mode . shell-command) . 2) ((fundamental-mode . mwheel-scroll) . 54) ((fundamental-mode . delete-backward-char) . 12) ((fundamental-mode . kill-region) . 3) ((fundamental-mode . mouse-set-point) . 7) ((fundamental-mode . mouse-drag-region) . 20) ((fundamental-mode . minibuffer-complete-word) . 3) ((fundamental-mode . set-background-color) . 4) ((fundamental-mode . backward-char) . 5) ((fundamental-mode . delete-char) . 1) ((fundamental-mode . cua--prefix-override-handler) . 2) ((fundamental-mode . cua-copy-region) . 2) ((fundamental-mode . scroll-bar-toolkit-scroll) . 103)) Loading init_load_packages...done Loading init_version...done Loading init_functions...done Loading init_settings...done Loading c:/Program Files (x86)/ErgoEmacs 1.8.1/ergoemacs/init_aliases.el (source)...done Loading init_keybinding...done Loading init_mouse...done Loading init_clean_menus...done Loading c:/ErgoEmacs 1.8.1/.emacs.d/.recentf...done Cleaning up the recentf list...done (0 removed) server-ensure-safe-dir: The directory `~/.emacs.d/server' is unsafe Above there is no mention of loading a file called .emacs, although you may wonder whether Loading init_load_packages or init-functions or init_settings is a kind of synonym for the stuff in .emacs. Apparently not. I can press M-a, type set-back-ground color, press Enter, type grey, press Enter, and see the background change to grey, as expected. I entered the same command (set-background-color grey) into my .emacs file, saved it, opened ErgoEmacs, and saw no color change. I conclude that the init file is not being loaded. I checked the file for only LF line-end termination, too. It is correct. Turns out that the *user's* HOME variable is the one to be used. I set my HOME to C:\Users\username. There is a long discussion about the correctness of this choice: http://groups.google.com/group/ergoemacs/browse_thread/thread/7699b73df70005ed Note that the first posting in the above thread say that .emacs is loaded from the place where HOME points. I placed my .emacs file there in C:\Users\username; my HOME variable points to the same place. My init file does not load when ErgoEmacs is launched. I must be missing something. I was hoping to do some Factor this weekend. That may not happen. Has anyone experience with E-TextEditor (sometimes called just E)? It seems to be a Windows-based TextMate work-alike. Is anyone any working on non-Emacs REPL-base editor integration for Factor? Shaping *From:* Jim mack [mailto:j...@less2do.com] *Sent:* 2010-November-06, 19:54 *To:* factor-talk@lists.sourceforge.net *Subject:* Re: [Factor-talk] ErgoEmacs init file not loading Shaping, I don't remember the order I did these things in, but here are some artifacts I can find. User variable HOME set to c:\emacs System variable HOME set to C:\documents and settings\jmack nothing in registry at HKCU\SOFTWARE\GNU\ .emacs file at c:\emacs. Make sure not to use a windows
Re: [Factor-talk] load-all
I understand what you're trying to do by your other posts, and I'm not sophisticated enough to help, but I thought I should mention this, even if it is short of perfect: I almost always keep http://docs.factorcode.org/open and really enjoy its clickable definitions, plus the ability to control-click and get multiple tabs for later browsing while still following the current chain of interest. And, bookmarking for later access. Further, Google can help you find things within the source if you google site:http://docs.factorcode.org/ some term. I'm not trying to imply you should stop your search for what you feel is perfection; merely sharing my 20/80% solutions. I personally have gone far off road with the website framework furnace, because Factor gives us so much power to do it as we wish it could be done. On Sun, Nov 7, 2010 at 4:43 PM, Shaping shap...@charter.net wrote: I did a load-All in the Factor listener. After all words were loaded, I had four errors involving use of deprecated words: resource:extra/24-game/24-game.factor: 13 Asset: some-rots The definition of some-rots uses these deprecated words: spin resource:extra/calendar/holidays/holidays.factor: 17 Asset: POSTPONE: HOLIDAY-NAME: The definition of POSTPONE: HOLIDAY-NAME: uses these deprecated words: spin resource:extra/math/finance/finance.factor: 17 Asset: ema The definition of ema uses these deprecated words: spin resource:extra/trees/avl/avl.factor: 138 Asset: (avl-delete) The definition of (avl-delete) uses these deprecated words: tuck Are we supposed to keep after and fix stuff like this? I know these are minor problems, but I think I will be loading everything from now on, in order to learn more quickly about all vocabularies. I'm trying to tread my Factor as I would a fully loaded Smalltalk image. Shaping -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Furnace; Emacs
We're hampered by not having a secure connection in windows. Slava did some things to make it better, but it hasn't worked yet and I haven't had time to track down why. I feel bad I haven't given him any feedback yet after he did this for me. That being said, here's some fixes to \extra\webapps\blogs that make it work up to a point: http://paste.factorcode.org/paste?id=2043 The comments I've added at the end may help you get started to where you can see the main menu. Hope that helps a little. The current furnace paradigm has you creating many actions, then sending quots to slots in them. I've been working on something where the page uses a tuple and generics to process render itself, and a router determines which tuple to start with. This all happens through a single action. So the crud operations for an object all descend from a general object tuple page, giving lots of places for overriding behavior. I'm not trying to make an argument that it's better, it just fits how I think. It's also not ready for prime time, but you asked, so I answered :) A further squirrely thing I'm doing is generating the HTML unobtrusive JS along the way, rather than having any page artifacts that get parsed (chloe) or filled (fhtml). And I've written words to add to and reuse the tuple slot meta data. This is the html/form generation for a subset of fields in the tuple: content-edit-fields Org Information HTML LEGEND + org-fields all-id FIELDSET BR Save button submit+ org all-id form yields: http://paste.factorcode.org/paste?id=2044 -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] ErgoEmacs init file not loading
Shaping, I don't remember the order I did these things in, but here are some artifacts I can find. User variable HOME set to c:\emacs System variable HOME set to C:\documents and settings\jmack nothing in registry at HKCU\SOFTWARE\GNU\ .emacs file at c:\emacs. Make sure not to use a windows editor on it, unless it has settings for unix cr stripping. c:\emacs .emacs.d init.txt emacs-23.1 INSTALL bin\runemacs.exe C:\emacs\emacs-23.1\bin\runemacs.exe is where it built itself to using make. INSTALL contains the instructions I followed: 1. Make sure your system has at least 120 MB of free disk space. 2a. `cd' to the directory where you unpacked Emacs and invoke the `configure' script: ./configure 5. Invoke the `make' program: make 6. If `make' succeeds, it will build an executable program `emacs' in the `src' directory. You can try this program, to make sure it works: src/emacs -q 7. Assuming that the program `src/emacs' starts and displays its opening screen, you can install the program and its auxiliary files into their installation directories: make install As a complete newbie, I did everything exactly as specified, and made no assumptions. I had previously had ruby running on this xp 32 box, had installed git. Has emacs ever been able to start, or is this a case where emacs starts but integration through fuel to factor is the issue? C:\Program Files\ErgoEmacs\ergoEmacs.exe also runs for me, does not contain any .emacs files itself. It may be that my going with a seeming convention of c:\emacs as the base for the gnu emacs was what helps the defaults keep together? On Sat, Nov 6, 2010 at 3:59 PM, Shaping shap...@charter.net wrote: Hi Jim. I'm trying to use ErgoEmacs, but I cannot get it working either on Windows 7 64-bit. The contents of my .emacs file: (load-file F:\media\repositories\factor\misc\fuel\fu.el) (setq fuel-listener-factor-binary F:\media\repositories\factor (setq fuel-listener-factor-image F:\media\repositories\factor (set-background-color cornsilk) These lines are gleaned from the readme file that comes with the FUEL vocab. The contents don't matter now because the file is not being loaded by Emacs or ErgoEmacs. I saved the .emacs file in the ErgoEmacs install directory, in the bin subdirectory, in .emacs.d and in .emac.s/server. The .emacs.d directory is the only non-installation directory the installer creates. When ErgoEmacs launches for the first time, the status bar says The directory '~/.emacs.d/server is unsafe. 1. If the environment variable HOME is set, use the directory it indicates. 2. If the registry entry HKCU\SOFTWARE\GNU\Emacs\HOME is set, use the directory it indicates. 3. If the registry entry HKLM\SOFTWARE\GNU\Emacs\HOME is set, use the directory it indicates. Not recommended, as it results in users sharing the same HOME directory. 4. If C:\.emacs exists, then use C:/. This is for backward compatibility, as previous versions defaulted to C:/ if HOME was not set. 5. Use the user's AppData directory, usually a directory called Application Data under the user's profile directory, the location of which varies according to Windows version and whether the computer is part of a domain. This bit above seems thorough, but does not help with Emacs or ErgoEmacs. Where did you place your .emacs file. Did you need to create a HOME environment variable? Shaping *From:* Jim mack [mailto:j...@less2do.com] *Sent:* 2010-November-05, 03:42 *To:* factor-talk@lists.sourceforge.net *Subject:* Re: [Factor-talk] Working style; default font; preferred text styler with REPL I got gnu emacs working on my xp laptop by following these instructions, http://www.gnu.org/software/emacs/windows/ntemacs.html and the ones on the factor website: http://www.gnu.org/software/emacs/windows/ntemacs.html. I was able to get it to call factor compile, and to update my source file's USING: as I added words. Then, I played around with ergo emacs, and screwed everything up, and ran out of time. I'm a newbie, just thought that piece of info would be confirmation that it's possible. Jim -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living
Re: [Factor-talk] Working style; default font; preferred text styler with REPL
I got gnu emacs working on my xp laptop by following these instructions, http://www.gnu.org/software/emacs/windows/ntemacs.html and the ones on the factor website: http://www.gnu.org/software/emacs/windows/ntemacs.html. I was able to get it to call factor compile, and to update my source file's USING: as I added words. Then, I played around with ergo emacs, and screwed everything up, and ran out of time. I'm a newbie, just thought that piece of info would be confirmation that it's possible. Jim -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Working style; default font; preferred text styler with REPL
also look for Integration with Emacs in the article index (a link from home in the browser) On Fri, Nov 5, 2010 at 1:41 AM, Jim mack j...@less2do.com wrote: I got gnu emacs working on my xp laptop by following these instructions, http://www.gnu.org/software/emacs/windows/ntemacs.html and the ones on the factor website: http://www.gnu.org/software/emacs/windows/ntemacs.html. I was able to get it to call factor compile, and to update my source file's USING: as I added words. Then, I played around with ergo emacs, and screwed everything up, and ran out of time. I'm a newbie, just thought that piece of info would be confirmation that it's possible. Jim -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book Blueprint to a Billion shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Windows web development problem getting around HTTPS
Thank you, Slava. I'd volunteer but it's above my paygrade. I hope to contribute to the doc/tutorial effort once my current project gets launched. Jim On Sun, Oct 24, 2010 at 3:55 PM, Slava Pestov sl...@factorcode.org wrote: Hi Jim, Until I or someone else gets SSL working for Windows, the sensible thing is probably for Furnace to not require https for logins on Windows. I've pushed a patch with this change. The reason we don't support OpenSSL on Windows is that it doesn't support non-blocking IO there. On Unix, its relatively easy to use OpenSSL with a non-blocking descriptor. On Windows it is still possible, but it requires the use of a lower-level API where you marshall encrypted data in and out of buffers yourself before handing it off to the I/O subsystem. If anyone wants to take this project on, it would be great. Let me know and I'll give pointers. Slava On Sat, Oct 23, 2010 at 3:07 PM, Jim mack j...@less2do.com wrote: Hi, Factor doc says that secure sockets is not supported: http://docs.factorcode.org/content/article-io.sockets.secure.html I've tried installing the now 1.0 http://www.openssl.org/ for windows, and it hasn't 'magically' started working. I'm out of my depth here, and may be using the wrong terms/ideas. I'd like to use the code like 'blogs' in webapps. It works fine on my Mac, but I have to spend my day in Windows, and I think you have that user group very well supported in general. My first desire would be to know where to temporarily stub out the secure stuff so I can have fake security on windows until I test on mac post the real stuff to linode. If I can't stub the security, I would like to be to be able to fake an authorized login. The code is far beyond me at this time - it's a clear symbol 'logged-in-user' I need to set, but I seem to need to do this in some kind of context. I keep running into continuation/realm errors, and I'm not understanding what context I need to start before setting the auth variables that actually store the stuff. I've tried sending a user tuple to successful-login from my own code, but run into some kind of continuation/realm mismatch (it tries to end something I didn't know to start). I tried setting logged-in-user in my own code, but have a context problem, because when the blogs code tries to get it, it's null, or I get a stack overflow error. I've made my own auth routines to work in http just to get going, and I can make some calls to responders like blogs, but sooner or later something expects furnace's auth to be set correctly. Can someone help point me to a way to subvert this, or authoritatively tell me I can't? :) Thanks. -- Jim -- Nokia and ATT present the 2010 Calling All Innovators-North America contest Create new apps games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Nokia and ATT present the 2010 Calling All Innovators-North America contest Create new apps games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Nokia and ATT present the 2010 Calling All Innovators-North America contest Create new apps games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Windows web development problem getting around HTTPS
Hi, Factor doc says that secure sockets is not supported: http://docs.factorcode.org/content/article-io.sockets.secure.html I've tried installing the now 1.0 http://www.openssl.org/ for windows, and it hasn't 'magically' started working. I'm out of my depth here, and may be using the wrong terms/ideas. I'd like to use the code like 'blogs' in webapps. It works fine on my Mac, but I have to spend my day in Windows, and I think you have that user group very well supported in general. My first desire would be to know where to temporarily stub out the secure stuff so I can have fake security on windows until I test on mac post the real stuff to linode. If I can't stub the security, I would like to be to be able to fake an authorized login. The code is far beyond me at this time - it's a clear symbol 'logged-in-user' I need to set, but I seem to need to do this in some kind of context. I keep running into continuation/realm errors, and I'm not understanding what context I need to start before setting the auth variables that actually store the stuff. I've tried sending a user tuple to successful-login from my own code, but run into some kind of continuation/realm mismatch (it tries to end something I didn't know to start). I tried setting logged-in-user in my own code, but have a context problem, because when the blogs code tries to get it, it's null, or I get a stack overflow error. I've made my own auth routines to work in http just to get going, and I can make some calls to responders like blogs, but sooner or later something expects furnace's auth to be set correctly. Can someone help point me to a way to subvert this, or authoritatively tell me I can't? :) Thanks. -- Jim -- Nokia and ATT present the 2010 Calling All Innovators-North America contest Create new apps games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] The image refers to a library or symbol that was not found at load time
Until you get a better answer, I had this problem until I installed sqlite3. This was on windows :( but is worth checking. 2010/10/5 Damian Dobroczyński qoo...@gmail.com -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi list! I've tried to compile and run factor from git repository on my new machine (Kubuntu 10.04). Unfortunaltely it does not work. When trying to run it I'm obtaining: The image refers to a library or symbol that was not found at load time which apparently wants to tell me that some shared library is missing. Could you tell me what libraries are required to run factor vanilla image? D. -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkyrPiAACgkQWPXp0gyuOusO3wCfbcQ3GM4BKGxLy0wv0KwK5BNQ yKcAn1/yuvg2+GPTZUTapU3V38NOl5PO =ruxJ -END PGP SIGNATURE- -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today. http://p.sf.net/sfu/beautyoftheweb ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today. http://p.sf.net/sfu/beautyoftheweb___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Newbie question about handbook
The simplest way of describing the pure stack effects of if, for a situation like this: t [ ] [ ] if would be ( ? quot quot -- ) You could write : example ( ? quot quot -- ) if ; inline t [ ] [ ] example ( The idea of inline is beyond my ability to explain. I add it, like a monkey, every time I see a compilation error like Cannot apply “if” to an input parameter of a non-inline word) Inside the quotation could be stuff that doesn't actually do anything to the stack. I think of the syntax you're asking about as trying to be more visually descriptive for a new user, and it's making the point that the most common use case would be to transform some thing(s) that are on the stack, conditionally. So, I think ..a could be thought of as the precondition of the stack before if's parameters and ..b could be the stack condition after either path. This includes the idea of there being no stack as well. The inner parenthetical groups describe the expected stack effect of each branch of condition execution, and try to explain that it transforms the stack. This syntax is not trying to imply any comment about the depth of the stack. Jim On Sat, Sep 18, 2010 at 6:23 AM, Fabian Boucsein fabian.boucs...@googlemail.com wrote: Thanks for your answer Anton. But what does the ..a exactly mean? It is a stack effect row variable? Is there a connection with the number of arguements it stands for? Greetings, Fabian Anton Gorenko schrieb: if '?' is t, not '..a'. http://docs.factorcode.org/content/article-effects.html http://docs.factorcode.org/content/article-effects-variables.html 'true' and 'false' quotations have same stack effects, they take 'a' (a = 0) values from the stack and leave 'b' (b = 0) values on the stack. So '3 2 t [ + ] [ - ] if' is correct ('true' and 'false' have ( x x -- x ) stack effect, 'if' has ( x x ? true: ( x x -- x ) false: ( x x -- x ) -- x ) stack effect in this case), but '3 2 t [ + + ] [ - ] if', '3 t [ + ] [ - ] if', '3 2 t [ + ] [ 1 ] if', etc. are incorrect. 2010/9/18 Fabian Boucsein fabian.boucs...@googlemail.com: Hello Factor mailing list, i try to understand the definition of if in the factor handbook: if ( ..a ? true: ( ..a -- ..b ) false: ( ..a -- ..b) -- ..b) I read if ..a is true execute the true codeblock else the false block which is quite clear but what does the last ..b stands for? Thanks for your help. Fabian -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Something like outputarray, but less smart?
Hi, Kyle. You're famous to me from Delphi, and I also benefited from your writeup on using Git on windows. Welcome to Factor. I've been searching for a home since Delphi's decline in market share, and this seems to be it for me; hope you have fun here. The community is great (I mean, a four minute delay on your answer???). On Wed, Aug 25, 2010 at 6:36 PM, Slava Pestov sl...@factorcode.org wrote: Hi Kyle, One approach is to use with-datastack. Here anything goes: ( scratchpad - auto ) { } [ 10 iota [ ] each ] with-datastack . { 0 1 2 3 4 5 6 7 8 9 } However a better approach might be to use something like 'make' where you explicitly call , with each element to add it in: ( scratchpad - auto ) [ 10 iota [ , ] each ] { } make . { 0 1 2 3 4 5 6 7 8 9 } If you tell us what you're trying to achieve (instead of just how you're trying to achieve it), someone might be able to suggest a better approach. Slava On Wed, Aug 25, 2010 at 6:32 PM, Kyle Cordes k...@kylecordes.com wrote: Factor gurus, Could anyone kindly point me toward something similar to outputarray, but which doesn't infer the array size (and thus can't fail because of trouble so inferring), but which rather just catches the results of the quotation (whatever size it happens to be) and makes that an array? I have looked at the docs quite a lot, and haven't been able to figure this out. -- Kyle Cordes http://kylecordes.com -- Sell apps to millions through the Intel(R) Atom(Tm) Developer Program Be part of this innovative community and reach millions of netbook users worldwide. Take advantage of special opportunities to increase revenue and speed time-to-market. Join now, and jumpstart your future. http://p.sf.net/sfu/intel-atom-d2d ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Sell apps to millions through the Intel(R) Atom(Tm) Developer Program Be part of this innovative community and reach millions of netbook users worldwide. Take advantage of special opportunities to increase revenue and speed time-to-market. Join now, and jumpstart your future. http://p.sf.net/sfu/intel-atom-d2d ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Sell apps to millions through the Intel(R) Atom(Tm) Developer Program Be part of this innovative community and reach millions of netbook users worldwide. Take advantage of special opportunities to increase revenue and speed time-to-market. Join now, and jumpstart your future. http://p.sf.net/sfu/intel-atom-d2d___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] FUEL listener running web page
Hi, I've got FUEL working w/listener, on Mac, factor version = yesterday's binaries. I'm launching a furnace website. If I launch it from Factor listener directly, it executes but locks the listener, and I have to restart it. (Once I've restarted it, I can modify source, hit F2 and the website reflects those changes, and if I call the launching word again, it no longer locks the listener - only the first time.) If this seems just too weird, see my explanation below. If I launch from aquamacs, the same thing happens, but I don't know how to restart the listener. If I launch it from aquamacs listener in a thread, it serves the website but I don't know how to get it to refresh its code. Is there a way to work interactively whereby C-c C-r will update my website's code, just as I can do in the factor listener? Thanks, Jim What's launching the website, in case I'm causing this problem: : 4eyes-web ( -- ) [ route-and-return ] to: trick-to-get-reloading 4eyes [ 4eyes-responder 4eyes-db alloy init-4eyes-dbs main-responder set-global 8080 httpd ] with-logging ; It probably isn't important, but just in case, I know it's non standard and I have my doubts I'd try it again, but I use one action and have it parse the request's url params to decide what to do, from within the display slot, and that's what trick-to-get-reloading is. Until I did this, I didn't seem to get the website code refreshed just by hitting F2, unless I directly called 4eyes-web again (it was early in my learning curve, so maybe I just got something wrong, but it's working). -- This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] http.factor: cookie sometimes returns non resizable collection
Sorry, I don't build from source on my windows laptop, so here's a manual fix: http.factor : parse-cookie ( string -- seq ) ] { } make ; needs to be: ] V{ } make ; the test on put-cookie doesn't have it parsing a request. Writing that test is beyond me at the moment. This does break 4 existing tests that hardcode a cookie result of { }. This may apply to parse-set-cookie as well, but I didn't test this. Detail of Problem: Trying to use put-cookie, stepped as far as the final push, the inspector showed a stack T{ request ...} T{ cookie ... } { ~cookie~ ~cookie~ ~cookie~ } and push fails with Sequence index out of bounds index 3 seq { ~cookie~ ~cookie~ ~cookie~ } URL http://localhost/abc; (U) Quotation: [ set-namestack init-catchstack self quot call - stop ] (O) Word: handle-client (O) Method: M\ http-server handle-client* (O) Word: do-request (O) Method: M\ sessions call-responder* (O) Word: handle-get (U) Quotation: [ 2dup [ ~quotation~ dip dup terminated? ~quotation~ ~quotation~ if ] 2dip - rot [ 2drop ] [ wrong-values ] if ] (U) Quotation: [ [ ~quotation~ dip dip ] dip - dup terminated? [ 2drop f ] [ dup in length swap out length check-datastack ] if ] (U) Quotation: [ swap [ call ] dip - ] Word: dip (O) Word: route-and-return (O) Word: (route-and-return) (U) Quotation: [ set-password-for-machine - f ] (U) Quotation: [ [ request get ] dip pkey put-cookie - drop ] (U) Quotation: [ [ break name dupd get-cookie ~quotation~ when* ] keep over cookies push - ] (O) Method: M\ sequence set-nth (O) Word: bounds-error (O) Method: M\ object throw (U) Quotation: [ 63 special-object error-thread set-global continuation - error-continuation set-global rethrow ] -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] http.factor: cookie sometimes returns non resizable collection
On further thought, probably I'm incorrect in trying to set a cookie in the request, rather than the response. Sorry :) On Sun, Jul 18, 2010 at 1:56 PM, Jim mack j...@less2do.com wrote: Sorry, I don't build from source on my windows laptop, so here's a manual fix: http.factor : parse-cookie ( string -- seq ) ] { } make ; needs to be: ] V{ } make ; the test on put-cookie doesn't have it parsing a request. Writing that test is beyond me at the moment. This does break 4 existing tests that hardcode a cookie result of { }. This may apply to parse-set-cookie as well, but I didn't test this. Detail of Problem: Trying to use put-cookie, stepped as far as the final push, the inspector showed a stack T{ request ...} T{ cookie ... } { ~cookie~ ~cookie~ ~cookie~ } and push fails with Sequence index out of bounds index 3 seq { ~cookie~ ~cookie~ ~cookie~ } URL http://localhost/abc; (U) Quotation: [ set-namestack init-catchstack self quot call - stop ] (O) Word: handle-client (O) Method: M\ http-server handle-client* (O) Word: do-request (O) Method: M\ sessions call-responder* (O) Word: handle-get (U) Quotation: [ 2dup [ ~quotation~ dip dup terminated? ~quotation~ ~quotation~ if ] 2dip - rot [ 2drop ] [ wrong-values ] if ] (U) Quotation: [ [ ~quotation~ dip dip ] dip - dup terminated? [ 2drop f ] [ dup in length swap out length check-datastack ] if ] (U) Quotation: [ swap [ call ] dip - ] Word: dip (O) Word: route-and-return (O) Word: (route-and-return) (U) Quotation: [ set-password-for-machine - f ] (U) Quotation: [ [ request get ] dip pkey put-cookie - drop ] (U) Quotation: [ [ break name dupd get-cookie ~quotation~ when* ] keep over cookies push - ] (O) Method: M\ sequence set-nth (O) Word: bounds-error (O) Method: M\ object throw (U) Quotation: [ 63 special-object error-thread set-global continuation - error-continuation set-global rethrow ] -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] getting the ip of this system
USING: io.launcher io.files.temp ; Windows: process ipconfig command ip.txt temp-file stdout try-process puts ipconfig results to file to the temp directory. Try: ip.txt temp-file Mac process ifconfig command ip.txt temp-file stdout try-process On Sat, Jul 17, 2010 at 3:03 AM, Ben Schlingelhof b...@benseins.de wrote: Hi there, anybody know how I can get the (DHCP-provided) IP-Address of the current system? I've tried f 8000 inet resolve-host but it only gives me 0.0.0.0, not too useful. Ben -- Ben Schlingelhof benseins.de -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] getting the ip of this system
Better: process os windows? ipconfig ifconfig ? command ascii process-reader stream-lines gives you a sequence. On Sat, Jul 17, 2010 at 10:55 AM, Jim mack j...@less2do.com wrote: USING: io.launcher io.files.temp ; Windows: process ipconfig command ip.txt temp-file stdout try-process puts ipconfig results to file to the temp directory. Try: ip.txt temp-file Mac process ifconfig command ip.txt temp-file stdout try-process On Sat, Jul 17, 2010 at 3:03 AM, Ben Schlingelhof b...@benseins.de wrote: Hi there, anybody know how I can get the (DHCP-provided) IP-Address of the current system? I've tried f 8000 inet resolve-host but it only gives me 0.0.0.0, not too useful. Ben -- Ben Schlingelhof benseins.de -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Regexp problem?
jim123 R/ [0-2]/ x re-replace works jim123 R/ [0-2]*/ x re-replace bombs factor. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] information request about ui part
Not to speak against the gui, I just want to weigh in by mentioning that factor can host a website locally as well. You can deploy an executable, stripped down compiled factor that serves some local ip port, then the user just browses to it. On Fri, Jul 16, 2010 at 7:38 AM, Kobi Lurie k_lu...@gbrener.org.il wrote: Hey guys, I'm looking to do more serious 'factor'ing, and want to build a complete app. But the documentation for the gui part, is very limited. (I also like the portable nature of the gui and that it looks the same - and would like to create something) Are there any tutorials I missed, or that you're in the middle of? can I ask questions here, as I'm unpuzzling this? on a related note, the rebol gui was the easiest/cutest I saw. Does the factor base lack gui applications because of a limitation or poor api of gadgets, or simply no interest yet? I'm very interested to have atleast some initial basis to build upon, and feel that it's a shame to switch languages just because of a library. factor code is nice and simple imo. Welcoming any info and comments, Kobi -- China: stop persecuting Falun Gong! http://faluninfo.net URGENT: Innocent people are being persecuted for their belief inside Communist China. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Anyone experienced with websockets as a Factor server?
I'm not good enough to implement this from the ruby code. Has anyone given it a thought? -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] namespaces
When rendering an fhtml page within the furnace.alloy framework, I am trying to get to the same namespace that the listener is in. In other words, I expected to use set in the listener, then get (on the same key) in the fhtml page, but it returns f. I see that the page has a namestack 11 deep, my listener's is 4. I think I understand cset and cget, sset and sget, and html forms' set-value and value, but am trying for something a little more global but not quite global-global. Is the 4th namespace when in listener unreachable from the furnace.alloy namestack? -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] namespaces
Thanks, Slava Would the responder then have a namespace in common among HTTP threads using an explicit bind? Sure, thanks. Mostly I was trying to take advantage of the 'look in a chain of assocs until you find it' functionality, and thought I could do so with a combination of make-assoc and bind fairly cheaply. I had a list of general replacements, and specific ones, and ones that change rapidly, and thought that chaining would be 'better' than cloning adding specifics each time. One of the reasons I was drawn to Factor for web is that I understood it to have less startup costs - it's always in memory, etc. I am doing a local (desktop) website that will have a lot of quick interaction, and didn't want to save/load all of it each ping. So I keep it in global memory, serializing to disk after n changes. Please feel free to point me in some direction if this seems foolish. The only odd problem I've had so far, that I don't have pinned down enough to report, is that occasionally chrome and firefox on an xp box where I do most development (day job) will clearly be interacting with a different webserver. Usually I've been in both, correctly interacting, then make some change (or possibly have a crash). I'll restart factor the primary browser (usually chrome) and it initializes properly, but the other browser (usually ff), which was open all along, still retains the old in-mem data. I can interact with it successfully, and it is clearly the version from before the factor restart, but task manager does not list factor. I can even close all ff windows and restart ff and still have this happening, although as I type that I realize I didn't check the task manager to make sure some hidden ff process wasn't keeping it open. Once I even tried gradually killing random processes until I found the culprit. I killed all for me, most for system, when I killed one I shouldn't have. But throughout, I had a responsive web server in the other browser. This has happened across many factor builds since mid November, but I can't swear to you the first time I saw it. Jim On Sat, Jul 10, 2010 at 4:32 AM, Slava Pestov sl...@factorcode.org wrote: Hi Jim, Every thread has its own namestack. The listener runs in its own thread and so does every HTTP request. So dynamic variables are not the right abstraction here unfortunately. What you should do instead is have the furnace action set form values with set-value, and access those values from the fhtml template. The best way to save a value between invocations of an action is to persist it in a database, because then your web app will support transparent fail-over. Another good approach is to subclass the dispatcher responder and store them in there, and add your actions to the dispatcher as well. If you're interested I'll write up an example of this pattern. Slava On Sat, Jul 10, 2010 at 4:21 AM, Jim mack j...@less2do.com wrote: When rendering an fhtml page within the furnace.alloy framework, I am trying to get to the same namespace that the listener is in. In other words, I expected to use set in the listener, then get (on the same key) in the fhtml page, but it returns f. I see that the page has a namestack 11 deep, my listener's is 4. I think I understand cset and cget, sset and sget, and html forms' set-value and value, but am trying for something a little more global but not quite global-global. Is the 4th namespace when in listener unreachable from the furnace.alloy namestack? -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored
Re: [Factor-talk] namespaces
Thanks very much! I can't reproduce it yet, but am trying. One thing I forgot to mention: I can still interact with website in one browser while factor itself has closed and task manager doesn't list any factor instances, a vital fact... :) On Sat, Jul 10, 2010 at 1:12 PM, Slava Pestov sl...@factorcode.org wrote: On Sat, Jul 10, 2010 at 2:25 PM, Jim mack j...@less2do.com wrote: Thanks, Slava Would the responder then have a namespace in common among HTTP threads using an explicit bind? Sure, thanks. That's one option, yes, or you can store the data in the responder directly. It takes a bit of boilerplate at the moment, perhaps at some point in the future it can be streamlined: TUPLE: my-web-app dispatcher data ; : my-web-app ( -- responder ) my-web-app new-dispatcher blah-action blah add-responder ... ; M: my-web-app call-responder* [ my-web-app set ] [ call-next-method ] bi ; Then your action can do my-web-app get data Of course you can name your slots anything, not just 'data'. Mostly I was trying to take advantage of the 'look in a chain of assocs until you find it' functionality, and thought I could do so with a combination of make-assoc and bind fairly cheaply. I had a list of general replacements, and specific ones, and ones that change rapidly, and thought that chaining would be 'better' than cloning adding specifics each time. If you have a sequence of assocs, you can search for a key using the 'assoc-stack' word. This is the word that is used to implement 'get'. The only odd problem I've had so far, that I don't have pinned down enough to report, is that occasionally chrome and firefox on an xp box where I do most development (day job) will clearly be interacting with a different webserver. Usually I've been in both, correctly interacting, then make some change (or possibly have a crash). I'll restart factor the primary browser (usually chrome) and it initializes properly, but the other browser (usually ff), which was open all along, still retains the old in-mem data. I can interact with it successfully, and it is clearly the version from before the factor restart, but task manager does not list factor. I can even close all ff windows and restart ff and still have this happening, although as I type that I realize I didn't check the task manager to make sure some hidden ff process wasn't keeping it open. This sounds like a problem in http.server's handling of cache control headers. A couple of people have reported similar issues in the past on the Factor web site. Let me know if you find a test case. Slava -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] how to stub/mock existing words
I'm writing unit-tests and I need to change the behavior of a word. It's something I didn't write myself so it doesn't lend itself to generics. What is the syntax for changing what executes? Forth allows you to change the cfa or something (long time ago, blurry memory). If I just redefine the word within the test, is there any danger something will use the prior version rather than my new definition? I'm thinking of macros, but don't really know anything :) -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- ThinkGeek and WIRED's GeekDad team up for the Ultimate GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the lucky parental unit. See the prize list and enter to win: http://p.sf.net/sfu/thinkgeek-promo___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] A newbie with some questions
Well, I am not qualified to comment (or even follow) a majority of this discussion, but I may have some useful input re: QNX is POSIX compliant, but the graphical UI (Photon) may be a problem. Factor out of the box provides an HTTP web server that you can run locally for machine interaction, and browse to for UI control. I have been pursuing this approach in my projects, and it works well. Jim -- ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Factor educational tools
While we're on the subject, does anyone know a cheap hosting site that allows you to run custom executables? I use dreamhost and haven't asked them to host factor yet, but remember trying to use Ruby in the early days and it took them a while to get going. On Sun, Mar 28, 2010 at 4:20 AM, Henrik Huttunen henrik.huttu...@gmail.comwrote: Thanks :) Unfortunately I probably didn't include that option when I paid my service and I cannot seem to locate a place where I could add DNS management service. But I hope it doesn't bother anyone how it is setup at the moment (redirecting to different url, that is). I will probably someday buy virtual environment for that domain. Maybe then it's time setup everything properly. If there is no easy solution, I'll put my effort into the content, for the time being. - Henrik If you have access to the zone file and a static ip to point at, you can add something like this to it: @ 10800 IN A openeducational-ip4 factor 10800 IN A factoredu-ip4 * 10800 IN A openeducational-ip4 This will keep the masking effect without all that funny frame business. The factor line is only neccessary if you want the factor subdomain at another IP. I did this to my first domain just the other day, so I apologize if I there are any mistakes. -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Factor educational tools
Thanks On Sun, Mar 28, 2010 at 11:35 AM, Joe Groff arc...@gmail.com wrote: On Mar 28, 2010, at 2:32 AM, Henrik Huttunen wrote: Thanks for your feedback, Joe. It should be fixed now. It works now, Henrik. Really cool stuff. -Joe -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] *-in-c-type-name
I've been working with the ODBC code with this change for a few months now: TYPEDEF: short* SQLSMALLINT* but am not knowledgeable enough why it would be wrong. It was early in my Factor learning process, and I can't swear I tested every data type. On Mon, Mar 15, 2010 at 12:05 PM, Joe Groff arc...@gmail.com wrote: On Mar 15, 2010, at 6:18 AM, Ben Schlingelhof wrote: Hi there, I've tried to use the odbc-vocab in the newest factor source. I get this interesting error: 17: TYPEDEF: void* SQLSMALLINT* ^ *-in-c-type-name You're correct. Pointers no longer need to be (or can be) typedef-ed separately from their underlying types. If you want to define an opaque C type (that is, one which is valid as a pointer type but not as a value type), you can use C-TYPE: . Generic word underlying does not define a method for the string class. Dispatching on object: DSN=TEST_DSN I bet this is because of a recent change in string handling in the FFI. While parameters with a char* pointer type used to be treated specially and would automatically convert Factor strings to C strings and back, this is no longer the case. A separate type, c-string, is now used to automatically convert strings in the FFI. This is discussed in the C strings article of the FFI docs: http://docs.factorcode.org/content/article-c-strings.html The fix for odbc will probably be to update some parameters that take char* parameters (or typedefs thereof) to now take c-string parameters. -Joe -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] MS-SQL
I have reworked everything but the translation of dates and will post a copy shortly. I didn't want to do so incomplete, but no reason for you to redo that work. ffi: http://paste.factorcode.org/paste?id=1572 lib: http://paste.factorcode.org/paste?id=1573 odbc main: http://paste.factorcode.org/paste?id=1574 It was one of the first things I did in factor, so I expect it could be better ;( and don't have git capability where I am right now. Jim On Wed, Mar 10, 2010 at 6:52 AM, Ben Schlingelhof ben.schlingel...@googlemail.com wrote: Thanks, everyone. I'll have a look at the odbc-port. On Wed, Mar 10, 2010 at 14:11, Chris Double chris.dou...@double.co.nz wrote: On 03/11/2010 12:25 AM, Paul Moore wrote: Hmm, looks like I may have been wrong. I was working from http://www.bluishcoder.co.nz/2007/01/odbc-interface-for-factor.html but that looks like it's out of date as I can't find anything in the current factor codebase. It's in 'unmaintained/odbc' in the source distribution (the git repository). It shouldn't take much effort to get it working again for someone new to factor. Chris. -- http://bluishcoder.co.nz -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Ben Schlingelhof benseins.de -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] MS-SQL
Also, wanted to get the db.tuples working with this, but kept getting stuck. On Wed, Mar 10, 2010 at 8:11 AM, Jim mack j...@less2do.com wrote: I have reworked everything but the translation of dates and will post a copy shortly. I didn't want to do so incomplete, but no reason for you to redo that work. ffi: http://paste.factorcode.org/paste?id=1572 lib: http://paste.factorcode.org/paste?id=1573 odbc main: http://paste.factorcode.org/paste?id=1574 It was one of the first things I did in factor, so I expect it could be better ;( and don't have git capability where I am right now. Jim On Wed, Mar 10, 2010 at 6:52 AM, Ben Schlingelhof ben.schlingel...@googlemail.com wrote: Thanks, everyone. I'll have a look at the odbc-port. On Wed, Mar 10, 2010 at 14:11, Chris Double chris.dou...@double.co.nz wrote: On 03/11/2010 12:25 AM, Paul Moore wrote: Hmm, looks like I may have been wrong. I was working from http://www.bluishcoder.co.nz/2007/01/odbc-interface-for-factor.html but that looks like it's out of date as I can't find anything in the current factor codebase. It's in 'unmaintained/odbc' in the source distribution (the git repository). It shouldn't take much effort to get it working again for someone new to factor. Chris. -- http://bluishcoder.co.nz -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Ben Schlingelhof benseins.de -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Vocab for comparing complex data types
Thanks! Never thought to look at that. I did get something going with the lcs library, but this may be better. On Sun, Feb 21, 2010 at 10:44 AM, Kobi Lurie k_lu...@gbrener.org.il wrote: On 21/2/2010 16:28, Jim mack wrote: I have some complicated datastructure, mixing containers tuples, like an ast. I would like to get a report on what's different between two of them, say for a test. Is there an existing vocab for that? It won't need to be fast. My first thought was to get the prettyprint representations, then diff through an external tool. Hi Jim, do you know of mirrors? I'm not sure if that's what you mean, but maybe something like this: : obj-diff ( big small -- diff ) [ mirror alist ] bi@ swap diff ; TUPLE: xyz x y z ; xyz new 4 z 2 x xyz new 3 x --- Data stack: T{ xyz f 2 f 4 } T{ xyz f 3 f f } ( scratchpad - auto ) obj-diff . { { x 3 } { z f } } Best Regards, Kobi -- China: stop persecuting Falun Gong! http://faluninfo.net URGENT: Innocent people are being persecuted for their belief inside Communist China. -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Download Intel#174; Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Factor addins to editpad, editpadpro
You can download use by going to options/configure file types, and set up a factor file type. These help on the Syntax Navigation tab. It will give you a quick navigate tab with all the words listed alphabetically by parser word, and lists INCLUDING files. Handles nesting of [ and { 4 deep. I didn't get every element, so if you have any special requests, I would be glad to upgrade. http://www.editpadpro.com/cgi-bin/cscslist3.pl?focus=261 http://www.editpadpro.com/cgi-bin/cscslist3.pl?focus=261 http://www.editpadpro.com/cgi-bin/fnslist.pl?focus=65 -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- SOLARIS 10 is the OS for Data Centers - provides features such as DTrace, Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW http://p.sf.net/sfu/solaris-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] slide-rule
Oh, sorry, I misunderstood something a while back. I thought this was a process to take a few inputs and generate a gcode file that ran some kind of machine process to produce it, but I see where you mention wanting to present a graphic simulation. Doesn't this type of input to a milling machine have its own visualizer? On Fri, Feb 5, 2010 at 1:10 PM, Hugh Aguilar hughaguila...@yahoo.comwrote: -- *From:* Jim mack j...@less2do.com *To:* factor-talk@lists.sourceforge.net *Sent:* Wed, February 3, 2010 10:02:50 PM *Subject:* Re: [Factor-talk] slide-rule I am just getting started in Factor, and am partially drawn to the ability to do cross platform GUI development, but I thought I should mention a cool ability to ship a self-contained HTTP server using their easy to use furnace library. It could launch a browser to itself on startup and produce the output format file locally. If you already do web programming it shouldn't be much of a learning curve. I have never done any GUI programming or web programming, so either approach would represent new ground for me. I am somewhat dubious of the idea of a browser/server, as there is a lot of data to work with. I could be wrong, considering that I've never done this, but my understanding of the browser/server idea is that the program running on the browser is dealing with a very small amount of data such as the fields in a data-entry form. Perhaps it would help if I explained how my slide-rule program works: It is a three-stage process: 1.) I have words such as D-scale, A-scale, etc., that each generate a linked-list representing the scale. Each node is a MARK: list w field .kind\ the kind of mark this is (TNY, SML, MID, BIG or XTR) f field .n \ the numeric value of the mark (corresponds to .LABEL) f field .dist \ derived from N and measured in Lunits (distance from left edge) w field .orientation \ the direction of the label in relation to the mark w field .label\ the hstr of the label if there is a label constant mark \ If .ORIENTATION is N/A, then there is no label and .LABEL is irrelevant. \ The DIST value is nominally in the range [0,1], although it might extend over the edge slightly. 2.) I convert these MARK lists into SHAPE lists. These contain absolute coordinates (in inches) of all the marks and labels on a particular face of the slide-rule. Each node is a SHAPE: list p field .src p field .dst w field .siz w field .txt constant shape \ a text string or a line segment \ The P fields are .X and .Y pairs. \ If the .SIZ field is a KIND (TNY, SML, MID, BIG or XTR), then the shape is a text string. \ The .SRC field is the lower-left corner and the .DST field is not used. \ If the .SIZ field is N/A, then the shape is a line segment. \ The .SRC and .DST fields are the endpoints. 3.) I convert the SHAPE lists into gcode. All the information in each SHAPE node gets etched with G01 commands, and I also pick up the tool and move it with a G00 command from each element to the next. The Factor program would be the same as the Forth except that I will use sequences rather than linked lists, as linked lists are apparently not idiomatic in Factor. The GUI would allow the user to drag-and-drop the scales into place to construct the slide-rule, and would also allow the user to simulate the use of the slide-rule by moving the slide and the cursor to and fro on the constructed slide-rule. There would have to be an alternative #3 step above that generates some kind of graphical image rather than gcode. Does Factor have the ability to display SVG on the screen? Or would I need to generate some other kind of graphical image? If Factor has support for displaying graphical images (of any kind) on the screen, then I think the whole thing would be best written in Factor as a GUI program. If Factor can't do this, then it might be better to have the Factor program generate SVG on the server side, and then write a JavaScript program to run in a browser and display the SVG images. -- The Planet: dedicated and managed hosting, cloud storage, colocation Stay online with enterprise data centers and the best network in the business Choose flexible plans and management services without long-term contracts Personal 24x7 support from experience hosting pros just a phone call away. http://p.sf.net/sfu/theplanet-com ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going
Re: [Factor-talk] Not getting MACRO:
Got it working, thanks. 2010/1/15 Philipp Brüschweiler ble...@gmail.com Am Thu, 14 Jan 2010 23:17:04 -0800 schrieb Jim mack j...@less2do.com: Hi. Can you please help me understand why the final line here results in a stack underflow? USING: accessors arrays kernel locals present select8.html classes.tuple sequences prettyprint fry macros nested-comments combinators ; TUPLE: testing id firstname lastname age ; : testing ( id fn ln age -- tpl ) testing boa ; : testdata ( -- tpl ) 1 jim mack 46 testing ; : testing-schema ( -- seq ) { { First Name [ firstname ] } { Last Name [ lastname ] } { Age [ age ] } } ; : non-macro-way ( tpl -- ) { [ First Name write firstname print ] [ Last Name write lastname print ] [ Age write age present print ] } cleave ; testdata non-macro-way ! using fry testdata { } clone testing-schema [ first2 '[ _ write @ present print ] suffix ] each cleave MACRO: easier ( alist -- ) { } clone swap [ first2 '[ _ write @ present print ] suffix ] each cleave ; : fancyprint ( tpl -- ) testing-schema easier ; inline testdata fancyprint ! stack underflow Hi Jim If I understand you correctly, your intent is that fancyprint will be the same as non-macro-way, just with dynamically generated code. If so, your problem is that you don't generate a quotation as output of the macro, specifically the call to cleave gets executed at parse time. Here's a correct version (with { } clone swap [ .. suffix ] each simplified to map): MACRO: easier ( alist -- ) [ first2 '[ _ write @ present print ] ] map '[ _ cleave ] ; For fancyprint to work, you have to declare testing-schema inline, make a CONSTANT: out of it or directly write the alist into fancyprint. Cheers -- Throughout its 18-year history, RSA Conference consistently attracts the world's best and brightest in the field, creating opportunities for Conference attendees to learn about information security's most important issues through interactions with peers, luminaries and emerging and established companies. http://p.sf.net/sfu/rsaconf-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Throughout its 18-year history, RSA Conference consistently attracts the world's best and brightest in the field, creating opportunities for Conference attendees to learn about information security's most important issues through interactions with peers, luminaries and emerging and established companies. http://p.sf.net/sfu/rsaconf-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Not getting MACRO:
Hi. Can you please help me understand why the final line here results in a stack underflow? USING: accessors arrays kernel locals present select8.html classes.tuple sequences prettyprint fry macros nested-comments combinators ; TUPLE: testing id firstname lastname age ; : testing ( id fn ln age -- tpl ) testing boa ; : testdata ( -- tpl ) 1 jim mack 46 testing ; : testing-schema ( -- seq ) { { First Name [ firstname ] } { Last Name [ lastname ] } { Age [ age ] } } ; : non-macro-way ( tpl -- ) { [ First Name write firstname print ] [ Last Name write lastname print ] [ Age write age present print ] } cleave ; testdata non-macro-way ! using fry testdata { } clone testing-schema [ first2 '[ _ write @ present print ] suffix ] each cleave MACRO: easier ( alist -- ) { } clone swap [ first2 '[ _ write @ present print ] suffix ] each cleave ; : fancyprint ( tpl -- ) testing-schema easier ; inline testdata fancyprint ! stack underflow -- Throughout its 18-year history, RSA Conference consistently attracts the world's best and brightest in the field, creating opportunities for Conference attendees to learn about information security's most important issues through interactions with peers, luminaries and emerging and established companies. http://p.sf.net/sfu/rsaconf-dev2dev___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] sqlite query obtaining column titles
A few sqlite confusions, all bundled together. I am having so much fun learning factor, it's keeping me up at night, which hasn't happened to me for a long time. THANKS! 0) When I try to step through #3 below, trying to see the code that is appending the result row to the result set, the walker doesn't reveal the magic. I see a vector with the rows in it on the stack and/or retain stack, but can't figure out what word puts them there. I suspect it has something to do with the continuation c word, but haven't grokked that yet. Can someone shed some light? 1) Main, underlying goal: I want to get the column headings returned after a sqlite query is run. I know how to use PRAGMA to get the def of a table, but I need to process ad-hoc queries (on an intranet from secure users). I managed to do this for ODBC by capturing the column structure as it's processed for the first row, but can't find the equivalent in the sqlite library. Below is what I've tried, please point out where I've gone wrong. 2) I see row-column, which says it takes a result set and a column index. I tried sticking this into advance-row, but don't get what I expect. When I step through #3 below, row-column returns a 0. 3) M: sqlite-result-set advance-row ( result-set -- ) B dup 0 row-column drop ! trying to apply row-column in a place it should be valid, but only get a 0 dup handle sqlite-next has-more? drop ; 4) I tried decomposing the words along the way to get a good result-set data structure that row-column could work against, but keep striking out: 5) select tbl_name from sqlite_master where type = 'table' [ f f simple-statement [ query-results ] with-disposal ] with-sample-db results in: T{ sqlite-result-set { sql select tbl_name from sqlite_master where type = 'table' } { handle ALIEN: 1001b1e48 } { has-more? t } } 6) which will get me a sqlite-result-set, but I can't figure out how to use it: the results from #5 above, when I execute #columns on it, I get 65536000, which isn't right. Any light you can shed is greatly appreciated! -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Return on Information: Google Enterprise Search pays you back Get the facts. http://p.sf.net/sfu/google-dev2dev ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] debug furnace app
One thing I love about Factor is you can run words against the stack at any depth of code and figure out what's going on. How could this be done to simulate/test what a furnace action does, or maybe the responder as a whole? Also, is there a log being autowritten, for each responder? Thanks in advance! -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
[Factor-talk] Conversion ODBC help questions
Hi, New to factor, did some forth long time ago. Converting unmaintained\odbc.factor for use on Windows. Am using the binary factor deploy for now. 1) CHAR: \space string is missing \space. a) Of course CHAR: 32 string works, but it seems we avoid this. What is better way? b) Closest I can come is command-writer.factor, which has a CHAR: space write1. I can't figure out where space is defined. I think I looked (but obviously missed it) in each file in USING: io io.crlf kernel math.parser sequences strings interpolate locals ; and browser is not helpful. What techniques are there to start from command-writer find out where it thinks it's getting the word from? 2) finding conflicts for TYPEDEF: short XXX. a) says between alien.c-types sequences b) I read the latter should win in USING: but this doesn't seem to apply c) I read syntax alien.c-types xxx would help, but can't find that article now, and couldn't figure out exact syntax at the time. d) I actually fixed by moving to an ffi folder so it didn't have any code requiring sequences, which may be correct, but I'd like to understand c) or whatever name conflict resolution there is. 3) Use of r r a) I remember this from forth, but it seems to be stamped out, and may even by a religious argument? b) As a quick and ugly, I implemented this as SYMBOL: fakestack : init-fake-stack ( -- ) 8 vector fakestack set ; : r ( n -- ) fakestack get push ; : r ( -- n ) fakestack get pop ; init-fake-stack which may be safe, because there's no call of another routine that uses r from the first r to the last r. In a few routines, I changed to :: and used named locals. I switched to the above when one routine (odbc-describe-column) put 6 elements on the return stack. I first tried solving this as a tuple, but then thought of the trick, and wanted to learn how to implement it. c) is there a better temp stack technique? d) please don't suggest other rewrites of odbc-describe-column, I will eventually come back to it. Thanks! -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk
Re: [Factor-talk] Conversion ODBC help questions
Thanks, Joe. If you look at the docs for CHAR: ( http://docs.factorcode.org/content/word-CHAR__colon__%2Csyntax.html ), it says CHAR: takes a literal character, an escape code, or a Unicode character name. «CHAR: space» is using the Unicode character name for the space character. The Unicode character data is read from basis/unicode/data/UnicodeData.txt when the Unicode library is compiled. I had thought that almost every word was compiled by source that I'd find in the USING: clause ( or recursively up). Is this how the UnicodeData.txt is loaded? I tried calling space itself in listener, to no avail, now I see CHAR: space works, which I didn't think of as possible unless it could interpret 'space' itself. space namechar-hook of course answers that. I'll keep infix notation in mind in the future. ... That's how it used to be, but we've since implemented a more robust namespacing scheme documented in the article I linked you from my first email. Could you tell us where you read that from in the docs so we can update them? I think it was from an archived newsgroup site. c) I read syntax alien.c-types xxx would help, but can't find that article now, and couldn't figure out exact syntax at the time. Not sure where you got that from. is just used for parse-time evaluation. Again, if you could point out where in the docs you read this so we can clarify it for future new users, that'd be helpful. Again, archived newsgroups. I may even have seen something like: «FROM: alien.c-types = short ;» and thought it was some usage of rather than a quotation device 3) Use of r r c) is there a better temp stack technique? The temporary stack in Factor has been relegated to an implementation detail. The dip combinators ( http://docs.factorcode.org/content/article-retainstack-combinators.html ) are the preferred way in Factor for temporarily stashing values, since they enforce balanced use of the temporary stack and tend to be more readable. Am favorably impressed with combinators, although they many of them aren't easy yet. The only typo I've found so far is in the IRC info, for which I was a noob, but irc.ui run from http://concatenative.org/wiki/view/Concatenative%20IRC%20channel fails for the precompiled image I'm using. Joe, are you involved with Crystal reports? -Joe -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july ___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk -- Jim I'm for extending the working Medicare program for our seniors all the way back to contraception, so Americans can concentrate on living their lives without fear of changing a job, going bankrupt from deductibles or fighting HMO bureaucracy. -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july___ Factor-talk mailing list Factor-talk@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/factor-talk