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

Confusing error message: Type validations failed for handle ...: could not guarantee viariable ~ meets read requirements... #7121

Open
shans opened this issue Apr 26, 2021 · 0 comments

Comments

@shans
Copy link
Contributor

shans commented Apr 26, 2021

(from b/170756456)

The following error is difficult to understand as a manifest author. What am I supposed to look for to resolve the error? Some kind of hint as to what to do would be helpful.

Type validations failed for handle 'create 'permissions'': could not guarantee 
variable ~ meets read requirements PermissionStates {recordAudio: Boolean} with 
write guarantees PermissionState {recordAudio: Boolean}

Amalgamated manifest:

schema AudioBuffer
  timestamp: Instant
  length: Int
  base64Data: Text

schema PermissionState
  recordAudio: Boolean

@ingress
particle AudioSensor in '.AudioSensor'
  permissions: reads PermissionStates{recordAudio: Boolean}
  audio: writes AudioBuffer

@ingress
particle PermissionSensor in '.PermissionSensor'
  permissions: writes PermissionState

@arcId('sensing')
recipe Sensing
  permissions: create 'permissions'
  audio: create 'audio-signals'

  AudioSensor
    permissions: permissions
    audio: audio

  PermissionSensor
    permissions: permissions
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

1 participant