facebook / facebook-ruby-business-sdk

Ruby SDK for Meta Marketing API
https://developers.facebook.com/docs/business-sdk
Other
209 stars 160 forks source link

`::UploadIO` is deprecated #206

Closed amomchilov closed 8 months ago

amomchilov commented 11 months ago

Which SDK version are you using?

17.0.2

What's the issue?

constant ::UploadIO is deprecated

Steps/Sample code to reproduce the issue

Load the gem with a bundle that has multipart-post locked to version 2.2.0 or greater.

Observed Results:

A warning is emitted on this line, where the ::UploadIO constant is accessed:

https://github.com/facebook/facebook-ruby-business-sdk/blob/2ed193d1e78a375799c519be42fecc88c6c1d354/lib/facebook_ads/videos/video_io.rb#L22

Expected Results:

For there to be no warning.

I think all we need here is to switch to away from the "alias" and to the real constant:

-  class VideoIO < ::UploadIO
+  class VideoIO < Multipart::Post::UploadIO
stcheng commented 8 months ago

resolved :)