Closed UlfNorell closed 10 years ago
From nils.anders.danielsson on April 23, 2011 01:42:05
Can you please provide more detailed information?
Status: InfoNeeded
From denghao8...@gmail.com on April 23, 2011 04:50:56
GHCi, version 7.0.3: http://www.haskell.org/ghc/ :? for help Loading package ghc-prim ... linking ... done. Loading package integer-gmp ... linking ... done. Loading package base ... linking ... done. Loading package ffi-1.0 ... linking ... done. Prelude> :set -package Agda-2.2.10 package flags have changed, resetting and loading new packages... Loading package extensible-exceptions-0.1.1.2 ... linking ... done. Loading package transformers-0.2.2.0 ... linking ... done. Loading package mtl-2.0.1.0 ... linking ... done. Loading package old-locale-1.0.0.2 ... linking ... done. Loading package time-1.2.0.3 ... linking ... done. Loading package random-1.0.0.3 ... linking ... done. Loading package array-0.3.0.2 ... linking ... done. Loading package containers-0.4.0.0 ... linking ... done. Loading package pretty-1.0.1.2 ... linking ... done. Loading package template-haskell ... linking ... done. Loading package QuickCheck-2.4.0.1 ... linking ... done. Loading package bytestring-0.9.1.10 ... linking ... done. Loading package binary-0.5.0.2 ... linking ... done. Loading package filepath-1.2.0.0 ... linking ... done. Loading package old-time-1.0.0.6 ... linking ... done. Loading package unix-2.4.2.0 ... linking ... done. Loading package directory-1.1.0.0 ... linking ... done. Loading package terminfo-0.3.1.3 ... linking ... done. Loading package utf8-string-0.3.6 ... linking ... done. Loading package haskeline-0.6.4.0 ... linking ... done. Loading package process-1.0.1.5 ... linking ... done. Loading package haskell98-1.1.0.1 ... linking ... done. Loading package cpphs-1.11 ... linking ... done. Loading package haskell-src-exts-1.9.6 ... linking ... done. Loading package syb-0.2.2 ... linking ... done. Loading package xhtml-3000.2.0.1 ... linking ... done. Loading package zlib-0.5.3.1 ... linking ... done. Loading package Agda-2.2.10 ... linking ... done. Prelude> ioTCM "/Users/dh/agda/monoid.agda" (Just "/tmp/emacs/agda2-mode229QGC") ( cmd_load "/Users/dh/agda/monoid.agda" ["."] )
From denghao8...@gmail.com on April 23, 2011 05:26:05
I forget to mention that I'm using agda 2.2.8
MacBookAir:~ dh$ agda -V Agda version 2.2.8
From nils.anders.danielsson on April 23, 2011 12:22:26
The Emacs mode should insert the command
:mod + Agda.Interaction.GhciTop
before the call to cmd_load. Can you debug the Emacs Lisp code, please?
What I would like to know is why the penultimate line of agda2-restart ((agda2-call-ghci ":mod +" agda2-toplevel-module)) is not executed properly.
From denghao8...@gmail.com on April 24, 2011 02:34:51
I found the problem . I'm mixing agda 2.2.8 and agda-mode 2.2.10
It's confusing that cabal install agda only install agda-mode, and you have to do cabal install agda-executable.
Is it really necessary to split it in two haskell packages ?
Regards. Hao Deng
From nils.anders.danielsson on April 24, 2011 04:21:04
I found the problem . I'm mixing agda 2.2.8 and agda-mode 2.2.10
I don't see how this can cause the symptoms you reported. The agda executable is not used by the Emacs mode.
It's confusing that cabal install agda only install agda-mode, and you have to do cabal install agda-executable.
Is it really necessary to split it in two haskell packages ?
Cabal does not fully support packages containing both libraries and executables: http://hackage.haskell.org/trac/hackage/ticket/656
Status: WontFix
From denghao8...@gmail.com on April 24, 2011 04:56:10
Thanks nils.anders.danielsson for the time and effort.
Here is the situation: I installed agda 2.2.8 a long time ago.
then yesterday, cabal install agda , which upgrade agda-mode to 2.2.10, but left agda in 2.2.8 then above problem appears.
after cabal install agda-executable , everything is fine.
Happy agdaing!
From denghao8...@gmail.com on April 24, 2011 17:03:00
I'm able to reproduce the bug after a restart. In fact , the above error is not the first error. The first error is following, which I failed to mention before.
Loading /Users/dh/.viper...done Loading /Users/dh/haskellmode-emacs/haskell-site-file.el (source)...done Loading /Users/dh/ProofGeneral-4.0/ProofGeneral/generic/proof-site.el (source)...done Loading /Users/dh/.cabal/share/Agda-2.2.10/emacs-mode/agda2.el (source)...done For information about GNU Emacs and the GNU system, type C-h C-a. Loading quail/latin-ltx...done Starting GHCi process `ghci'. (No changes need to be saved) File mode specification error: (file-error "Opening output file" "No such file or directory" "/tmp/emacs/agda2-mode1639iL")
so after I manually mkdir /tmp/emacs
and restart emacs , everything is fine.
so the question is : did you created /tmp/emacs ? do you have access right to create a fold at /tmp/ ?
From nils.anders.danielsson on April 25, 2011 14:58:45
The Emacs mode creates temporary files in the directory specified by the variable "temporary-file-directory". If this variable points to a non-existent directory, then I am not surprised if things go wrong.
You may want to modify this variable:
M-x customize-variable RET temporary-file-directory RET
From denghao8...@gmail.com on April 23, 2011 02:28:07
The problem : Here is the ghci buffer after load agda :
Prelude> ioTCM "/Users/dh/agda/1.agda" Nothing ( cmd_write_highlighting_info "/Users/dh/agda/1.agda" "/tmp/emacs/agda2-mode533g4u" )