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

VSCode Extension: @@unique is not supported yet #212

Closed
do4gr opened this issue Nov 7, 2019 · 3 comments · Fixed by prisma/language-tools#32
Closed

VSCode Extension: @@unique is not supported yet #212

do4gr opened this issue Nov 7, 2019 · 3 comments · Fixed by prisma/language-tools#32
Assignees
Milestone

Comments

@do4gr
Copy link
Member

do4gr commented Nov 7, 2019

The Linter incorrectly warns when using @@unique.

model User {
    id Int @id
    firstname String
    lastname String
    @@unique([firstname, lastname], name: "test")
}
@matthewmueller
Copy link
Contributor

matthewmueller commented Nov 21, 2019

Investigated the VSCode extension and this error is due to errors coming back from:

prisma-fmt --lint --no_env_errors < schema.prisma

in: https://github.com/prisma/prisma-engine/blob/master/prisma-fmt/src/main.rs

Error

[{"start":75,"end":81,"text":"Attribute not known: \"@unique\"."}]

@matthewmueller matthewmueller transferred this issue from prisma/language-tools Nov 21, 2019
@janpio janpio changed the title @@unique is not supported yet VSCode Extension: @@unique is not supported yet Nov 21, 2019
@janpio janpio added this to the Preview 18 milestone Nov 22, 2019
@mavilein
Copy link
Member

mavilein commented Dec 2, 2019

This is not working in the extension as it is using an outdated URL for download. The right URL can be found in the binaries spec.
We should also make sure to bump the plugin version on each release to make sure that users always use a recent version of the prisma-fmt binary.

@matthewmueller
Copy link
Contributor

matthewmueller commented Dec 3, 2019

Nice debugging! This is now fixed in the 0.0.16 VSCode extension

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.

6 participants