<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>room01</author_name>
  <author_url>https://blog.hatena.ne.jp/room01/</author_url>
  <blog_title>こーひーエンジニアブログ</blog_title>
  <blog_url>https://konprogrammer.hatenablog.com/</blog_url>
  <categories>
    <anon>python</anon>
  </categories>
  <description>環境 Windows10 Python 3.8.1 コード # テキストファイルを読み込む src = open(filename, &quot;r&quot;, ).read() エラー内容 UnicodeDecodeError: 'cp932' codec can't decode byte 0x85 in position : illegal multibyte sequence python3の文字エンコーディングはUTF-8でWindowsはcp932のためエラーとなるようです。 解決策 encodingを指定します。 src = open(filename, &quot;r&quot;, encoding=&quot;utf-8&quot;…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fkonprogrammer.hatenablog.com%2Fentry%2F2020%2F02%2F11%2F210559&quot; title=&quot;Python3のopenでUnicodeDecodeError: &amp;#39;cp932&amp;#39; codec can&amp;#39;t decode byte 0x85 in position : illegal multibyte sequenceが出たときの覚書 - こーひーエンジニアブログ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2020-02-11 21:05:59</published>
  <title>Python3のopenでUnicodeDecodeError: 'cp932' codec can't decode byte 0x85 in position : illegal multibyte sequenceが出たときの覚書</title>
  <type>rich</type>
  <url>https://konprogrammer.hatenablog.com/entry/2020/02/11/210559</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
