Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong type argument error #9

Closed
DonyorM opened this issue Jan 18, 2017 · 15 comments
Closed

Wrong type argument error #9

DonyorM opened this issue Jan 18, 2017 · 15 comments

Comments

@DonyorM
Copy link

DonyorM commented Jan 18, 2017

When I tried running this in Spacemacs I got the following error when using the C-c s t p command:

(wrong-type-argument char-or-string-p nil)
  write-resp-val-to-buf(nil #<buffer *sayid-traced*>)
  sayid-setup-buf(nil t nil)
  sayid-req-insert-meta-ansi(("op" "sayid-show-traced" "ns" nil))
  sayid-show-traced()
  sayid-trace-ns-by-pattern()
  call-interactively(sayid-trace-ns-by-pattern nil nil)
  command-execute(sayid-trace-ns-by-pattern)

I was using the newest development version (develop branch) with the default clojure layer. Sayid was added as an additional package using a melpa recipe from github:

(sayid :location (recipe :fetcher github :repo bpiel/sayid :files ("src/el/*.el")))

How should I fix this?

@bpiel
Copy link
Collaborator

bpiel commented Jan 18, 2017

Do you have cider connected to nrepl?

@DonyorM
Copy link
Author

DonyorM commented Jan 18, 2017

I did, I used cider-jack-in

@bpiel
Copy link
Collaborator

bpiel commented Jan 18, 2017

@zane have you gotten sayid working with spacemacs at all? thanks

@DonyorM
Copy link
Author

DonyorM commented Jan 18, 2017

@bpiel Seems to be working now. Not sure what was going, sorry to bother you. Maybe I just needed to restart emacs (I thought I did that).

@DonyorM DonyorM closed this as completed Jan 18, 2017
@bpiel
Copy link
Collaborator

bpiel commented Jan 18, 2017

@DonyorM No problem. I like hearing that sayid is being used (or attempted) and appreciate having an official report of it working with spacemacs. thanks

@DonyorM
Copy link
Author

DonyorM commented Jan 18, 2017

@bpiel I'm working on integrating it with the clojure layer. Not working perfectly yet, I may be back later :)

@bpiel
Copy link
Collaborator

bpiel commented Jan 18, 2017

@DonyorM Keep the issues coming. Thanks for your interest and effort.

@DonyorM
Copy link
Author

DonyorM commented Jan 18, 2017

Ok I figured out the original error. On my own project (which has only one namespace) it seems to trace fine. However, if I try and trace the contrived example (either with a wildcard or without) it gives the error I said above. I have no idea why.

@DonyorM DonyorM reopened this Jan 18, 2017
@bpiel
Copy link
Collaborator

bpiel commented Jan 18, 2017

@DonyorM that is weird. Do you get any exception output from the repl? I'll think about how to tackle this.

@DonyorM
Copy link
Author

DonyorM commented Jan 18, 2017

I am actually, I didn't notice that. It says

FAIL in (test1) (machine_test.clj:23)
expected: (= (-> test-vending-machine (m/insert-coin :quarter) (m/insert-coin :dime) (m/insert-coin :nickel) (m/insert-coin :penny) (m/press-button :a1)) expected-vending-machine)
  actual: (not (= {:inventory {:a1 {:name :taco, :price 0.85, :qty 9}}, :coins-inserted [], :coins-returned [:quarter :quarter :nickel], :dispensed {:name :taco, :price 0.85, :qty 10}, :err-msg nil} {:inventory {:a1 {:name :taco, :price 0.85, :qty 10}}, :coins-inserted [:quarter :dime :nickel :penny], :coins-returned [], :dispensed nil, :err-msg true}))

However, I get the same error when I try to trace the functions in the non-test namespace (contrived-example.machine) I get the same emacs error, but no output on the repl. It may not be related

@bpiel
Copy link
Collaborator

bpiel commented Jan 18, 2017

@DonyorM How are you including sayid in the clj project? Is it in your profiles.clj? The contrived-example project doesn't include it directly (in project.clj), so maybe sayid isn't loaded at all?

@DonyorM
Copy link
Author

DonyorM commented Jan 19, 2017

That would do it. Sorry I for some reason didn't think to check if it was loaded in the project. I'll add that and try it again, though I imagine that's the issue.

A better error message for this situation would be very helpful, if that's possible (I don't know elisp at all).

@bpiel
Copy link
Collaborator

bpiel commented Jan 19, 2017

There should definitely be a better error message.

@bpiel
Copy link
Collaborator

bpiel commented Jan 19, 2017

Made an issue
#11

@DonyorM
Copy link
Author

DonyorM commented Jan 20, 2017

Confirmed the issue was the missing sayid plugin in the project.

@DonyorM DonyorM closed this as completed Jan 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants