Arc Forumnew | comments | leaders | submitlogin
1 point by akkartik 4287 days ago | link | parent | on: After i changed something

Have you made any changes to news.arc? Mail me the output of this command, and I'll help you with the merge.

  $ git diff lib/news.arc
1 point by tvvocold 4287 days ago | link | parent | on: After i changed something

when i git pull i got

  error: Your local changes to the following files would be overwritten by merge:
    lib/news.arc
  Please, commit your changes or stash them before you can merge.
  Aborting
1 point by akkartik 4287 days ago | link | parent | on: After i changed something

arc-openshift installs anarki: https://github.com/shader/arc-openshift/blob/fa9def061/.open...

Just cd into the arc directory ($OPENSHIFT_DATA_DIR/arc, but I'm not sure how to deduce OPENSHIFT_DATA_DIR) and run:

  $ git pull
2 points by tvvocold 4288 days ago | link | parent | on: After i changed something

Openshift gear will goes idle after 24 hours of inactivity,so i use uptimerobot.com to ping the server every 5 min,it will make other apps (i created) goes well ,but the arc.news always goes down every 2 or 3 days.

btw, here is akkartik's way: http://arclanguage.org/item?id=18910

1 point by tvvocold 4288 days ago | link | parent | on: After i changed something

thx,cool!

btw,i use https://github.com/shader/arc-openshift for openshift env,(not the https://github.com/arclanguage/anarki) how could i update it?

3 points by akkartik 4290 days ago | link | parent | on: After i changed something

I've updated the repository to make this easier. There's now a script called run-news to bring up the HN server.

  $ git pull
Now you should be able to run your server in a loop like this:

  $ while true; do ./run-news; sleep 5; done
Let me know if you run into trouble with this. I'll be around and more responsive for the next few days.

More notes, just for future reference:

1. run-news provides an interactive prompt, so you can make changes to the server without needing to restart it. Just remember to also modify news.arc otherwise your changes will be lost when the server dies next.

2. The sleep above is to help exit the server. If you quit the server as usual it'll just come up again. To bring it down, hit ctrl-c twice in succession.

3. I also fixed up the readme, which was abysmally out of date. Sorry about that.

2 points by shader 4291 days ago | link | parent | on: After i changed something

I have noticed that the server seems to go down after extended amounts of time, but I haven't figured out the source of the problem.

If anyone comes up with a permanent solution, I would be happy to include it though.

1 point by akkartik 4291 days ago | link | parent | on: After i changed something

First create a way to have arc automatically run (nsv) on startup. Then you can say this (assuming your shell is bash):

  $ while true; do arc server.arc; done
Now anytime your server dies it'll just come back up.
1 point by tvvocold 4291 days ago | link | parent | on: After i changed something

the reason maybe too much people came in , when i post a arc link to other website then i cannnot open arc site.
1 point by tvvocold 4291 days ago | link | parent | on: After i changed something

sure,then?
1 point by akkartik 4292 days ago | link | parent | on: After i changed something

Can you login to the server?
1 point by tvvocold 4292 days ago | link | parent | on: After i changed something

nice! but how to add a loop bash in openshift?
1 point by akkartik 4292 days ago | link | parent | on: After i changed something

Back when I ran an arc service I noticed it ran out of memory every few days. So I'd run the server in a loop on my shell, immediately restarting it if it died.
2 points by tvvocold 4293 days ago | link | parent | on: After i changed something

1,https://github.com/shader/arc-openshift is what i use in openshift

2,http://arclanguage.org/item?id=18840 i followed this and server works.

3,i only got openshift's log http://p.fdzh.org/paste/9jBPxB14

4,i donnot really know,after some days (maybe 5 or less) the server broken and could loaded,i think maybe the ab test from somebody?

ps:when server goes down i need to kill -9 the 80 port's pid and then restart app,but few days later it will happen again.

thx btw.

3 points by zck 4294 days ago | link | parent | on: After i changed something

I haven't been running the server in a while, but I have a few thoughts.

First, what version of anarki did you start with?

What were the edits you made? Does it work if you start the server without your changes?

What happens in the log before the errors?

What do you have to do to get the errors to occur? Is it upon server startup, or is it when you load a page in your browser, or try to register a user?


Thank you. I would say the things to note would be defalias, ssyntax (in experimental), and how I used packages to redefine the standard procedures.

Malisper, I like your approach. Even thought to do something similar myself. Thank you!

I'm not sure but you might want to check your .sbclrc file for anything weird and make sure you have the latest version of asdf.

Other than that, the only thing I can suggest is opening a question on Stack Overflow.


I get this error when running from the Clamp directory:

  $ sbcl
  * (require :asdf)
  NIL
  * (require :clamp)
  ASDF could not load clamp because
  Error while trying to load definition for system clamp from pathname
  ~/Clamp/clamp.asd:
     The name "ASDF-USER" does not designate any package..

  debugger invoked on a LOAD-SYSTEM-DEFINITION-ERROR in thread
  #<THREAD "initial thread" RUNNING {1002998F33}>:
    Error while trying to load definition for system clamp from pathname
    ~/Clamp/clamp.asd:
       The name "ASDF-USER" does not designate any package.

  Type HELP for debugger help, or (SB-EXT:QUIT) to exit from SBCL.

  restarts (invokable by number or by possibly-abbreviated name):
    0: [RETRY                                 ] Retry EVAL of current toplevel form.
    1: [CONTINUE                              ] Ignore error and continue loading file "~/Clamp/clamp.asd".
    2: [ABORT                                 ] Abort loading file "~/Clamp/clamp.asd".
    3: [REINITIALIZE-SOURCE-REGISTRY-AND-RETRY] Retry finding system clamp after
                                                reinitializing the
                                                source-registry.
    4:                                          Exit debugger, returning to top
                                                level.

  ((FLET #:LAMBDA2286 :IN ASDF::LOAD-SYSDEF)
   #<SB-KERNEL:SIMPLE-PACKAGE-ERROR "The name ~S does not designate any package."
     {10049EB763}>)
  0]

All you need is asdf 3.1.2 or later and Clamp has to be somewhere in your ~/common-lisp/ directory. Once you do that, just use (require :asdf) and (require :clamp).

I'll just include a reference to this[0] in the readme.

[0] http://common-lisp.net/project/asdf/asdf/Quick-start-summary...


Remind me, how does one install an asd package? :) Might be worth including in the Readme.

No, it's not a full compiler. It's different in a crucial respect: things it doesn't understand get passed straight out. This allows me to do most things as macros, just like you. More information: http://arclanguage.org/item?id=12814

I haven't dug into it yet, but I suspect the crucial difference might be your use of packages, which is more in line with Common Lisp idioms.


It looks like we took two completely different approaches. You implemented a wart->CL compiler (wt-transform), while I just wrote all of the Arc utilities in Common Lisp and shadowed some built in procedures/macros.

Your approach probably winds (wound?) up being much more flexible in the long run.


Very nice. You've been working on this since April?! Sorry I didn't notice until now.

I'll take a closer look in a few hours, but you might be interested in the tests from the old, lisp version of wart: https://github.com/akkartik/wart/tree/sbcl. It hadn't diverged very much at that point. Feel free to use it as you like.

1 point by akkartik 4325 days ago | link | parent | on: Shader:plz help

Yup. Does that work?
1 point by akkartik 4325 days ago | link | parent | on: Shader:plz help

https://news.ycombinator.com/item?id=4007232
1 point by zck 4325 days ago | link | parent | on: Sorry

Hear, hear. Even if we gift-wrapped a tarball of new code^1 , it wouldn't get on the server that runs this forum.

[1] tar -czf --include-bow new-arc.tgz arc/

3 points by rocketnia 4325 days ago | link | parent | on: Sorry

Let's please let this thread rest. Even if someone feels they have valuable and relevant things to say, this isn't a good starting point to have those discussions. It's too unfocused and hostile already.
1 point by SteveGraham 4325 days ago | link | parent | on: Sorry

Okay.

To what do you object and what do you want to see and when will you be submitting the changes?

2 points by rocketnia 4327 days ago | link | parent | on: How to install racket in fedora20?

When you're on http://racket-lang.org/download/ and you select a Linux version to download, this note appears at the bottom of the page:

  Note about the Linux installers: if you don't see an option for your
  particular platform, try other Linux installers, starting from similar
  ones. Very often, a build on one Linux variant will work on others
  too.
It's too bad this note doesn't appear before you choose one, huh? :) For what it's worth, I've installed Racket on other versions of Linux two or three times, and I haven't noticed any problems.
More