Photo metadata is nil until after AR callbacks have run
@tommyg-cld がすでに取り組んでいます。
2023年5月9日 から。
評価
この issue はまだ評価されていません。
説明
Describe the bug in a sentence or two.
I'm trying to extract colors from an uploaded image, following the docs on utilizing cloudinary_transformation and an after_save on the model. Unfortunately, metadata seems to always be nil. Once the after_save callback has finished, then source.metadata is populated. This seems like a misplaced lifecycle callback or something.
Issue Type (Can be multiple)
- Build - Cannot install or import the SDK
- Performance - Performance issues
- Behaviour - Functions are not working as expected (such as generate URL)
- Documentation - Inconsistency between the docs and behaviour
- Other (Specify)
Steps to reproduce
class PhotoUploader < CarrierWave::Uploader::Base
include Cloudinary::CarrierWave
cloudinary_transformation image_metadata: true, colors: true
end
class Photo < ApplicationRecord
mount_uploader :source, PhotoUploader
after_save :extract_colors
def extract_colors
# `source.metadata` is `nil`
end
end
Environment and Libraries (fill in the version numbers)
- Cloudinary Ruby SDK version - 1.23.0
- Ruby Version - 3.1.2
- Rails Version - 7.0.4
- Carrierwave - 2.2.2
- 主要言語
- Ruby
- スター
- 420
- フォーク
- 282
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
cloudinary/cloudinary_gem のほかの issue
-
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
cloudinary/cloudinary_gem#597 · コメント 1 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 52/100
cloudinary/cloudinary_gem#591 · コメント 3 件 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
cloudinary/cloudinary_gem#582 · コメント 1 件 ·
-
404's when fetching .eml files (from Action Mailbox)再び着手できるかも @rnamba-cloudinary が 400 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 30/100
cloudinary/cloudinary_gem#581 · コメント 1 件 ·
-
BlobKey, MirrorService and Sidekiq 8 are incompatible再び着手できるかも @const-cloudinary が 541 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
cloudinary/cloudinary_gem#573 · コメント 3 件 · 担当者 1 名 ·
cloudinary/cloudinary_gem の issue をすべて見る
似ている issue
-
area: ci benchmark build developer-experience difficulty: easy dx enhancement github-actions good first issue hacktoberfest help wanted performance quality rank: 8 kyu ruby tech: ruby
難易度 1/5 1時間未満 初心者へのやさしさ 82/100
flisk-sh/flisk-labs#22 ·
-
1.severity: security
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
メンテナーはふだん 1 日以内に返信
-
15-minutes 5-minutes algorithm any-language beginner-friendly c cpp csharp easy go good first issue hacktoberfest help wanted java javascript kotlin python rust swift typescript
難易度 1/5 1時間未満 初心者へのやさしさ 68/100
Huerte/algo-solutions-python#260 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
internal
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
Kong/developer.konghq.com#8080 ·
メンテナーはふだん 1 日以内に返信