Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
4bb9700
.github/workflows/tests: Enable ECL tests.
Ambrevar May 23, 2023
cba51bd
package: Fix typo in *debug-on-error* docstring.
Ambrevar Apr 27, 2023
f7e959c
package: Add lpara nickname.
Ambrevar Apr 27, 2023
945c7ca
Replace Calispel with Lparallel.
Ambrevar Apr 28, 2023
ae6c737
gitmodules: Remove Calispel.
Ambrevar Apr 28, 2023
fc0a2a1
prompter.asd: Remove Calispel.
Ambrevar Apr 28, 2023
ffab73e
tests: Move to Lparallel API.
Ambrevar Apr 28, 2023
2bc0a42
README: Add Roadmap section.
Ambrevar Apr 28, 2023
92ffdb8
Fix performance issue.
Ambrevar May 23, 2023
d69f18e
Fix missing documentation for attribute-value and attributes-values.
Ambrevar May 23, 2023
2b2a404
Fix ECL support.
Ambrevar May 23, 2023
99f7935
tests: Remove spurious extra destroy.
Ambrevar May 25, 2023
b83932f
Nullify kernels on destroy.
Ambrevar May 25, 2023
08fb44c
tests: Clean up sources after use.
Ambrevar May 25, 2023
3445883
tests: Destroy prompter even on error.
Ambrevar May 25, 2023
ba1de7c
tests: Increase timeout for slow ECL.
Ambrevar May 25, 2023
95af8fa
tests: Fix error-handling test.
Ambrevar May 25, 2023
2e1d708
Remove outdated comment.
Ambrevar May 31, 2023
77d33f5
Re-allow interrupting prompters (with Lparallel this time).
Ambrevar May 31, 2023
207f0b6
Use define-generic wherever possible.
Ambrevar Jun 1, 2023
2212cd1
Simplify initial-suggestions assignment.
Ambrevar Jun 1, 2023
9bc8663
Use etypecase instead of manual type check.
Ambrevar Jun 1, 2023
32bff8c
Clarify comment on why we may need a new kernel for attributes.
Ambrevar Jun 1, 2023
eb17b97
Bind processed suggestion properly.
Ambrevar Jun 1, 2023
66a3cc3
Fix result-channel type and docstring.
Ambrevar Jun 1, 2023
de9419c
Use return-from instead of manual block creation.
Ambrevar Dec 18, 2023
240e5fa
Move source prompter setting from `make' to `initialize-instance :aft…
Ambrevar Jun 1, 2023
b587432
Add `kernel' reader for `source'.
Ambrevar Jun 1, 2023
ddc2661
tests: Remove obsolete thread management.
Ambrevar Jun 1, 2023
3e66e98
Fix some docstrings and comments.
Ambrevar Jun 2, 2023
235b350
Rename result-channel to `result' and add blocking accessor.
Ambrevar Jun 6, 2023
2d9a6b6
Fix attributes-non-default docstring.
Ambrevar Jun 8, 2023
d59ee46
Support extraneous elements in attributes.
Ambrevar Jun 8, 2023
95a7f32
Start computing attribute values immediately.
Ambrevar Jun 8, 2023
10eb145
Use attribute-value in attribute-default.
Ambrevar Jun 8, 2023
eb15787
Add attribute-options and attributes-options.
Ambrevar Jun 8, 2023
44d442e
Fix kill right kernel in source' `destroy'.
Ambrevar Jun 8, 2023
9d53101
Fix-wait for interrupted result future.
Ambrevar Dec 18, 2023
096d388
Export attribute-key and attributes-keys.
Ambrevar Jun 9, 2023
b4d5c7d
Fix ready-p documentation and remove writer.
Ambrevar Jun 26, 2023
27dce4c
Replace update-notifier with update-hook.
Ambrevar Jun 26, 2023
e69eeec
gitmodules: Add nhooks.
Ambrevar Jun 26, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,14 @@ jobs:
name: ${{ matrix.lisp }} on ${{ matrix.os }}
strategy:
matrix:
lisp: [sbcl-bin]
os: [ubuntu-latest]
# Use ccl-bin/1.12.1 instead of 'ccl' because of
# https://github.com/roswell/roswell/issues/534.
# TODO: Revert when Roswell is functional again.
lisp: [sbcl-bin, ccl-bin/1.12.1, ecl/21.2.1]
rosargs: [dynamic-space-size=3072]
os: [ubuntu-latest, macos-latest] # try windows-latest when we understand commands to install Roswell on it

# run the job on every combination of "lisp" and "os" above
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change goes beyond the scope of the PR, so I'd kindly ask to remove it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

Copy link
Contributor Author

@Ambrevar Ambrevar Dec 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR changes thread management and one of the important features is to do it properly. This could be highlighted by the tests initially not working properly on ECL and macOS. Hence the need to restore the matrix to a wider state.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It must be acknowledged that you find that an alternative CI design amounts to higher quality standards. I'd suggest having that exchange elsewhere (for instance, an issue). I consider that this PR is not the right context.

The current design of the CI was the product of thoughtful joint discussions with @jmercouris. Seeing a change of strategy without prior notice or discussion and within another context seems to lack some cordiality. I think we all have a vested interested in respecting each other's perspectives and reaching an amenable outcome for all.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Ambrevar can you please put it in another, separate PR?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done in #37.

runs-on: ${{ matrix.os }}

steps:
Expand Down
16 changes: 4 additions & 12 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,6 @@
path = _build/symbol-munger
url = https://github.com/AccelerationNet/symbol-munger
shallow = true
[submodule "_build/calispel"]
path = _build/calispel
url = https://github.com/hawkir/calispel
shallow = true
[submodule "_build/cl-jpl-util"]
path = _build/cl-jpl-util
url = https://github.com/hawkir/cl-jpl-util
shallow = true
[submodule "_build/cl-containers"]
path = _build/cl-containers
url = https://github.com/gwkkwg/cl-containers
Expand Down Expand Up @@ -170,11 +162,11 @@
path = _build/trivial-package-local-nicknames
url = https://github.com/phoe/trivial-package-local-nicknames
shallow = true
[submodule "_build/jpl-queues"]
path = _build/jpl-queues
url = https://gitlab.common-lisp.net/nyxt/jpl-queues.git
shallow = true
[submodule "_build/mt19937"]
path = _build/mt19937
url = https://gitlab.common-lisp.net/nyxt/mt19937
shallow = true
[submodule "_build/nhooks"]
path = _build/nhooks
url = https://github.com/atlas-engineer/nhooks
shallow = true
5 changes: 5 additions & 0 deletions README.org
Original file line number Diff line number Diff line change
Expand Up @@ -56,3 +56,8 @@ Non-exhaustive list of features:
- Marks actions (event-driven on marks change).
- Current suggestion actions (event-driven on current suggestion change).
- Automatically return the prompt when narrowed down to a single suggestion.

* Roadmap

- Benchmark.
See if setting task priorities with Lparallel helps performance.
1 change: 0 additions & 1 deletion _build/calispel
Submodule calispel deleted from e9f2f9
1 change: 0 additions & 1 deletion _build/cl-jpl-util
Submodule cl-jpl-util deleted from 0311ed
1 change: 0 additions & 1 deletion _build/jpl-queues
Submodule jpl-queues deleted from b774d2
1 change: 1 addition & 0 deletions _build/nhooks
Submodule nhooks added at 857908
21 changes: 13 additions & 8 deletions package.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,15 @@

(uiop:define-package :prompter
(:use :common-lisp)
(:import-from :nclasses #:define-class)
(:import-from :nclasses #:define-class #:define-generic)
(:import-from :serapeum #:export-always))
(in-package prompter)

(eval-when (:compile-toplevel :load-toplevel :execute)
(trivial-package-local-nicknames:add-package-local-nickname :alex :alexandria)
(trivial-package-local-nicknames:add-package-local-nickname :sera :serapeum))
(trivial-package-local-nicknames:add-package-local-nickname :sera :serapeum)
(trivial-package-local-nicknames:add-package-local-nickname :lpara :lparallel)
(trivial-package-local-nicknames:add-package-local-nickname :lpara.queue :lparallel.queue))

(defmacro define-function (name args &body body)
"Eval ARGS then define function over the resulting lambda list.
Expand All @@ -21,6 +23,13 @@ All ARGS are declared as `ignorable'."
lambda-list-keywords)))
,@body)))

(defun slot-names (class-specifier)
;; TODO: `slot-names' or `direct-slot-names'?
#-ecl
(mopu:slot-names class-specifier)
#+ecl
(mapcar #'c2mop:slot-definition-name (c2mop:class-slots (find-class class-specifier))))

(defun initargs (class-specifier)
"Return CLASS-SPECIFIER initargs as symbols (not keywords)."
(delete nil
Expand All @@ -29,11 +38,7 @@ All ARGS are declared as `ignorable'."
(symbol-name
(first (getf (mopu:slot-properties class-specifier slot) :initargs)))
(symbol-package class-specifier)))
;; TODO: `slot-names' or `direct-slot-names'?
#-ecl
(mopu:slot-names class-specifier)
#+ecl
(mapcar #'c2mop:slot-definition-name (c2mop:class-slots (find-class 'prompter))))))
(slot-names class-specifier))))

(defun exported-p (sym)
(eq :external
Expand All @@ -46,4 +51,4 @@ All ARGS are declared as `ignorable'."
(export-always '*debug-on-error*)
(defvar *debug-on-error* nil
"When non-nil, the Lisp debugger is invoked when a condition is raised.
Otherwise all errors occuring in threads are demoted to warnings.")
Otherwise all errors occurring in threads are demoted to warnings.")
Loading