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

Core libraries need to be imported manually #198

Closed
dschrempf opened this issue Oct 21, 2021 · 4 comments · Fixed by #231
Closed

Core libraries need to be imported manually #198

dschrempf opened this issue Oct 21, 2021 · 4 comments · Fixed by #231

Comments

@dschrempf
Copy link

Solutions using functions such as seq-filter, or string-empty-p succeed locally but fail in the browser because the libraries are not automatically imported (required). Which libraries are imported by default?

fapdash added a commit to fapdash/exercism--emacs-lisp that referenced this issue Oct 21, 2022
- split up into different sections, accommodate people just starting
  out with Emacs a bit more
- add installation instructions for starter kits
- add Doom Emacs starter kit for people switching from vim
- reference style guide and coding conventions

closes exercism#198
works on exercism#18 (exercism#18 (comment))
@fapdash
Copy link
Contributor

fapdash commented Oct 21, 2022

@dschrempf I recommend installing Flycheck, which will inform you if you have to require additional packages.
The error to look out for is the function ‘the-function’ is not known to be defined..

I added instructions on how to set up Flycheck in #231.

@dschrempf
Copy link
Author

I do use flycheck in my Emacs setup, but it didn't warn me for these functions, I guess because they are loaded in my setup but not in the browser one.

Not sure if this issue can be solved in a satisfying way, because the local setup will always differ from the one in the browser. I think it would help if we provide the exact features that are loaded in the browser version.

@fapdash
Copy link
Contributor

fapdash commented Oct 21, 2022

Mh, weird, in my setup flycheck complains as soon as I remove the require statement from the solution file and the respective package is loaded into my Emacs.

I think it's fair to assume that no package is loaded in the browser version, so only functions defined in the C code should be available by default? Will have to investigate more..

@ErikSchierboom
Copy link
Member

This is how we build the emacs lisp test runner: https://github.com/exercism/emacs-lisp-test-runner/blob/main/Dockerfile
If there are common packages that students often used, it's totally reasonable to add them to that file.

Maybe you two could discuss which packages would make sense to include?

ErikSchierboom pushed a commit that referenced this issue Oct 26, 2022
* Improve "Learning Emacs Lisp" doc

- split up into different sections, accommodate people just starting
  out with Emacs a bit more
- add installation instructions for starter kits
- add Doom Emacs starter kit for people switching from vim
- reference style guide and coding conventions

closes #198
works on #18 (#18 (comment))

* Minor fixes from proof reading
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

Successfully merging a pull request may close this issue.

3 participants