Azure / Azure/MachineLearningNotebooks

azureml.data.azure_storage_datastore upload_files() does not set mime type when uploading to storage container static website.

オープン
#1,610 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
Jupyter Notebook
スター
4.4k
フォーク
2.6k
PR マージ指標
30日以内にマージされた PR はありません

説明

Uploading files to the designated $web container using the python sdk upload_files() command to a blob storage static website does not correctly set the mime type to "text/html" for files with .html suffixes. See https://docs.microsoft.com/en-us/python/api/azureml-core/azureml.data.azure_storage_datastore.azureblobdatastore?view=azure-ml-py#upload-src-dir--target-path-none--overwrite-false--show-progress-true-

This should be done automatically on upload as mentioned in https://docs.microsoft.com/en-us/azure/storage/blobs/storage-blob-static-website-how-to?tabs=azure-cli

The work-around is to manually set content type in the Storage Explorer, to programmatically use the Python SDK `set_http_headers(content_settings=None, **kwargs)`

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

調査の方向性

Python SDK の azureblobdatastore にある upload_files() エントリポイントから始め、issue にリンクされている静的 Web サイトのドキュメントと動作を比較します。set_http_headers() の回避策を確認し、.html ファイルを $web コンテナーにアップロードすると content type が text/html になることを検証します。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
azure, python
領域
cloud
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。