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

IDを渡すべきところにannictIdを渡すとサーバエラーになる #3839

Closed
shimbaco opened this issue May 24, 2020 · 2 comments
Closed

Comments

@shimbaco
Copy link
Member

エラーになるクエリ:

mutation {
  updateStatus(input:{state: WATCHING, workId: 615}) { # 本来は ID を渡さないといけない
    clientMutationId
  }
}

https://sentry.io/organizations/annict/issues/1686226774

エラー内容
ArgumentError: invalid base64
  from <internal:pack>:281:in `unpack1'
  from base64.rb:74:in `strict_decode64'
  from graphql/schema/base_64_bp.rb:24:in `urlsafe_decode64'
  from graphql/schema/unique_within_type.rb:31:in `decode'
  from app/models/application_record.rb:11:in `find_by_graphql_id'
  from active_record/relation/delegation.rb:66:in `block in find_by_graphql_id'
  from active_record/relation.rb:407:in `block in scoping'
  from active_record/relation.rb:784:in `_scoping'
  from active_record/relation.rb:407:in `scoping'
  from active_record/relation/delegation.rb:66:in `find_by_graphql_id'
  from app/graphql/mutations/update_status.rb:13:in `resolve'
  from graphql/schema/resolver.rb:95:in `public_send'
  from graphql/schema/resolver.rb:95:in `block (3 levels) in resolve_with_support'
  from graphql/schema.rb:114:in `after_lazy'
  from graphql/schema/resolver.rb:83:in `block (2 levels) in resolve_with_support'
  from graphql/schema.rb:114:in `after_lazy'
  from graphql/schema/resolver.rb:76:in `block in resolve_with_support'
@shimbaco shimbaco transferred this issue from another repository Feb 13, 2021
@shimbaco
Copy link
Member Author

graphql gemをアップデートして rmosolgo/graphql-ruby#3179 を取り込めば直る。

@shimbaco
Copy link
Member Author

直るというか、それっぽいエラーメッセージをクライアントに返すようになり、サーバエラーは発生しなくなる。

@shimbaco shimbaco transferred this issue from annict/annict-archived Jan 28, 2023
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