Arc Forumnew | comments | leaders | submitlogin
Anarki tut: urexample fails
1 point by globalrev 6089 days ago | 7 comments
arc> (defopl urexample req (let user (get-user req) (urform user req (do (prn "Set-cookie: mycook=" (alref (req 'args) "foo")) "uexample") (prn "Enter value:") (input 'foo) (submit))))

(defopl uexample req (prn "User " (get-user req)) (br) (prn "Cookies " (req 'cooks))) #<procedure:gs1987> arc> #<procedure:gs1994> arc> . . ac.scm::28651: open-output-file: cannot open output file: "C:/tmp/shashd39M2tCqX6" (The system cannot find the path specified.; errno=3)

on wVista. i come to the you must be logged in to do that, which i shouldnt right? and then i get logged in but nothing happens.



1 point by absz 6088 days ago | link

I'm not sure about the problem (at a guess, it's the forward slashes instead of backslashes in the Windows pathname), but I do have a formatting tip. To format code as code, surround it by blank lines, and then indent each line by two spaces. This will result in code being rendered in a monospaced font with whitespace (including returns) preserved.

-----

1 point by schtog 6088 days ago | link

where is this pathname then that might have to be changed?

-----

1 point by absz 6088 days ago | link

In the output:

  open-output-file: cannot open output file: "C:/tmp/shashd39M2tCqX6"
It looks like the official arc2 distribution is being used here, which isn't smart about pathnames, so something in arc.arc, ac.scm, or something like that is just blindly using /s. If the Anarki is being used, then this bug should have been fixed. But as I said, I have a Mac, so I'm really just guessing here.

-----

3 points by kens 6088 days ago | link

You might try "mkdir C:\tmp"

-----

1 point by globalrev 6087 days ago | link

im using vista and anarki.

downloaded anarki like 2 weeks ago and havent fetched a new version since.

-----

1 point by almkglor 6088 days ago | link

Hmm. It's the /tmp/ thing. I'll try to look into this maybe 9-10 hours from now, unless someone beats me to it.

-----

1 point by globalrev 6088 days ago | link

should i even get the loginform?

-----