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

Quill should label Option#get Query error as Quill #990

Closed
benpence opened this issue Dec 10, 2017 · 2 comments · Fixed by #2634
Closed

Quill should label Option#get Query error as Quill #990

benpence opened this issue Dec 10, 2017 · 2 comments · Fixed by #2634

Comments

@benpence
Copy link
Contributor

I'm embarrassed to admit that I originally filed this against the wrong Quill project:
slab/quill#1854

Version: 2.0.0 I think
Module: `quill-core

Expected behavior

[error][quill] MyClass.scala:362:29: Option.get is not supported since it's an unsafe operation. Use `forall` or `exists` instead.
[error][quill]           .sortBy(-_._3.get)(Ord.descNullsLast)
[error][quill]                             ^
[error][quill] MyClass.scala:362:18: type mismatch;
[error][quill]  found   : MyClass.this.context.Query[(String, Option[Long], Option[Long])]
[error][quill]  required: MyClass.this.context.Quoted[MysqlHistoryStore.this.context.Query[?]]
[error][quill]           .sortBy(-_._3.get)(Ord.descNullsLast)
[error][quill]                  ^

Actual behavior

[error] MyClass.scala:362:29: Option.get is not supported since it's an unsafe operation. Use `forall` or `exists` instead.
[error]           .sortBy(-_._3.get)(Ord.descNullsLast)
[error]                             ^
[error] MyClass.scala:362:18: type mismatch;
[error]  found   : MyClass.this.context.Query[(String, Option[Long], Option[Long])]
[error]  required: MyClass.this.context.Quoted[MysqlHistoryStore.this.context.Query[?]]
[error]           .sortBy(-_._3.get)(Ord.descNullsLast)
[error]                  ^

@getquill/maintainers

@mosyp mosyp added the question label Dec 11, 2017
@mosyp
Copy link
Collaborator

mosyp commented Dec 11, 2017

Quill is not a sbt plugin, but macros-based library hence I doubt we can change sbt output this way. @fwbrasil Please advise.

@fwbrasil
Copy link
Collaborator

Yeah, we can’t put the text at this position. I think it’s still valuable to prefix all error messages with “Quill”.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants