1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Azure Storage Blobs を Unity 2021 で使用する際の注意点

Posted at

発生する問題

Unity 2020 を使用しているプロジェクトで Azure Storage Blobs を使っていたのですが、Unity 2021 にアップデートした時に以下のようなエラーが発生しました。

Exception : TypeInitializationException
Root Exception : NotImplementedException
Message : The method or operation is not implemented.

Unity フォーラムでも同じようなエラーが発生している人がいました。

この NotImplementedException エラーは Unity が使用している .NET のバージョンと NuGet で取得できるライブラリのバージョンが一致していないのが原因です。

ちなみに Unity 2020 では以下のバージョンを利用していました。

Azure.Core : ver.1.19.0
Azure.Storage.Blobs : ver.12.10.0
Azure.Storage.Common : ver.12.9.0

解決方法

NuGet で Azure.Storage.Blobs をインストールすると Azure.Corever.1.19.0 が依存関係でインストールされるのですが、これが Unity と相性が悪かったので以下のようにしました。

Azure.Core : ver.1.21.0
Azure.Storage.Blobs : ver.12.10.0
Azure.Storage.Common : ver.12.9.0

これで無事に Unity で Azure.Storage.Blobs を利用することができました。

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?