weaviate-ruby icon indicating copy to clipboard operation
weaviate-ruby copied to clipboard

Suddenly ruby error when using client

Open 1000paces opened this issue 2 years ago • 6 comments

A recent update to the graphql gem (version 2.1.x) results in this ruby error:
"undefined method []' for nil:NilClass"`

I tracked it back to the graphql-client at this path: graphql-client-0.18.0/lib/graphql/client/query_typename.rb:28:in add_typename'",`

Seems that @types is nil. This works fine in graphql versions 2.0.x. I'm not sure this is a problem in weaviate-ruby, but I thought I'd start there. The client works fine for some things (schemas, adding data) but you can't use get or aggs.

1000paces avatar Oct 18 '23 16:10 1000paces

@1000paces Is this the error you're experiencing? https://github.com/github/graphql-client/issues/310

andreibondarev avatar Oct 18 '23 19:10 andreibondarev

Yes, that looks like exactly the same issue.

-Ron On Oct 18, 2023 at 12:07 PM -0700, Andrei Bondarev @.***>, wrote:

@1000paces Is this the error you're experiencing? github/graphql-client#310 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.Message ID: @.***>

1000paces avatar Oct 18 '23 20:10 1000paces

Yes, that looks like exactly the same issue. -Ron On Oct 18, 2023 at 12:07 PM -0700, Andrei Bondarev @.>, wrote: @1000paces Is this the error you're experiencing? github/graphql-client#310 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.Message ID: @.>

Yeah, I'm waiting for the gem to be fixed.

andreibondarev avatar Oct 18 '23 20:10 andreibondarev

Ok great. I locked out Gemfile to 2.0.x, so we are in business again.

Thanks for the quick reply!

-Ron

On Wed, Oct 18, 2023 at 1:37 PM Andrei Bondarev @.***> wrote:

Yes, that looks like exactly the same issue. … <#m_3990516116047390163_> -Ron On Oct 18, 2023 at 12:07 PM -0700, Andrei Bondarev @.>, wrote: @1000paces https://github.com/1000paces Is this the error you're experiencing? github/graphql-client#310 https://github.com/github/graphql-client/issues/310 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.Message ID: @.>

Yeah, I'm waiting for the gem to be fixed.

— Reply to this email directly, view it on GitHub https://github.com/andreibondarev/weaviate-ruby/issues/37#issuecomment-1769283026, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABD32UNNHQS4MZJCHBPTRTYAA4X3AVCNFSM6AAAAAA6F2XX7CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONRZGI4DGMBSGY . You are receiving this because you were mentioned.Message ID: @.***>

-- Ron Miles

@.*** 413.329.4277

1000paces avatar Oct 18 '23 20:10 1000paces

@1000paces If you need an immediate fix you can do something like this in your application.

andreibondarev avatar Oct 23 '23 23:10 andreibondarev

Thanks! I have it locked on the old version that worked and I'm watching github for updates. Your solution is probably better though, so I'll check into it

On Mon, Oct 23, 2023 at 4:09 PM Andrei Bondarev @.***> wrote:

@1000paces https://github.com/1000paces If you need an immediate fix you can do something like this https://github.com/andreibondarev/langchainrb/blob/main/Gemfile#L17 in your application.

— Reply to this email directly, view it on GitHub https://github.com/andreibondarev/weaviate-ruby/issues/37#issuecomment-1776166915, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABD32UMXBG7ZEWZYWJLTMLYA32KPAVCNFSM6AAAAAA6F2XX7CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONZWGE3DMOJRGU . You are receiving this because you were mentioned.Message ID: @.***>

-- Ron Miles

@.*** 413.329.4277

1000paces avatar Oct 23 '23 23:10 1000paces

@1000paces I believe this issue has been fixed.

andreibondarev avatar Aug 14 '24 18:08 andreibondarev