Common migration problems¶ If you have followed the recommendation to make sure your code runs without warnings with python2.7 -3 many of the simpler errors you can get now will be avoided, such as having variable names that are Python 3 keywords and other easy fixes. You will also have avoided one of the more subtle errors, that integer division now can return a float. There is still a range of c
質問 1: Python 自体の多言語化について ロケールやエンコーディングに関するサポートが充実してきた一方で、Python本体の多言語化、つまりメッセージカタログやヘルプをローカライズする仕組みはなく、非英語圏のユーザがPythonを学び、使いこなす上で障壁の一つになっていると思います。Python自体の多言語化について、現在どのような構想をお持ちですか? 大阪府 whosaysni さん 回答 1 これはとてもおもしろい質問ですね。私は自分自身では英語の使用に関して快適に感じ(過ぎ :-)ているので、Google+ で人々の意見を聞いてみました。そこで、この問題には様々な見方があることがわかりました。1 番極端な反応は「全ての人間が英語を習うべきである。」というものでした。言うまでもなく、私はこの意見に反対します!それは母国語やその書き方が英語に似ている人々にとっては簡単でしょうが(
Python 3 からは一部の関数がイテレータを返すよう変更になったということなので、この機会にPython3を触りつつitertoolsモジュールについてひととおり学んでみた。 主に参考にしたのは9.7. itertools — 効率的なループ実行のためのイテレータ生成関数 — Python 2.6ja2 documentation。そのため添えてあるメモは基本的にpython2.6が前提。2.7や3.2で追加されたり変更された点があればその旨を適宜書いてあります。 print関数について 今回はPython3.2であれこれしたのでprint関数を使ってます。Python2.6以降で print("", end=" ") みたいなのを使うには from __future__ import print_function とする必要があります。 バージョン毎のメソッドの実装状況 それぞれのバ
はてなグループの終了日を2020年1月31日(金)に決定しました 以下のエントリの通り、今年末を目処にはてなグループを終了予定である旨をお知らせしておりました。 2019年末を目処に、はてなグループの提供を終了する予定です - はてなグループ日記 このたび、正式に終了日を決定いたしましたので、以下の通りご確認ください。 終了日: 2020年1月31日(金) エクスポート希望申請期限:2020年1月31日(金) 終了日以降は、はてなグループの閲覧および投稿は行えません。日記のエクスポートが必要な方は以下の記事にしたがって手続きをしてください。 はてなグループに投稿された日記データのエクスポートについて - はてなグループ日記 ご利用のみなさまにはご迷惑をおかけいたしますが、どうぞよろしくお願いいたします。 2020-06-25 追記 はてなグループ日記のエクスポートデータは2020年2月28
2011年8月27日(土)に、産業技術大学院大学にて「PyCon JP 2011」が開催されました。本記事では、同カンファレンスに参加した筆者が、PyCon JP 2011のセッションについて2回に渡ってレポートします。前編ではおもに午前中のセッションの模様をお届けします。なおスペースの都合上、筆者の気になったセッションを選んでお伝えします。 PyCon JPとは? PyCon JPは、アメリカやヨーロッパをはじめとした10ヵ国以上で行われているPythonのカンファレンス、PyConの日本版です。日本各地のPythonistaはもちろん、台湾、そしてフランスなど海外からも参加者が訪れました。 参加前 筆者は参加前にguidebookをiPhoneにインストールし、それを使って自分オリジナルのスケジュールを組んで参加しました。これは全体のスケジュールから自分の見たい講演をセレクトすることで
ええと、タイトルそのままなのですが。 どうもこの前(2011年5月)の仕様変更により、MacPorts の python_select が使えなくなったようです(正確には xxx_select(xxx には言語が入る)全般のようですが、python_select 以外使ったことないのでこの点は他に譲ります)。 ちょっとハマってしまって小一時間無駄にしてしまったので、同じような MacPorts ユーザのためにメモしておきます。MacPorts のバージョンは、1.9.2 です。 *python_select おさらい ちなみに python_select というのは、python を複数インストールしているときに、使用するバージョンを切り替えてくれる有り難いツールのことですね。例えば、普段 Python 2.6 を使っている人が Google App Engine の開発用に Python
February, 2011 The promises of Google App Engine are extremely seductive. Free initial setup costs. Easy APIs to a data store, memcached, urlfetch, task queue, image processing, and more. Unlimited scalability on Google's infrastructure, priced exactly to what you consume. It was for all these reasons that I had launched around 10 separate apps on GAE prior to launching what would become my final
みんなのIoT/みんなのPythonの著者。二子玉近く160平米の庭付き一戸建てに嫁/息子/娘/わんこと暮らしてます。月間1000万PV/150万UUのWebサービス運営中。 免責事項 プライバシーポリシー Pythonには「後方互換性を大切にする」というモットーがあって,時にはそれが裏目に出ることがある。PythonでWebにリクエストを送る時の手法は,目的に応じて複数存在するが,これも後方互換性を守るがために起こっている現象といえる。当初はシンプルな機能を持つモジュールが利用されていて,その後より高度な機能を持つモジュールが追加されたのだが,後方互換性を守るために古いモジュールが残されているのだ。 たとえば,普通にhtppでGETリクエストを送って結果を取得するなら簡単で from urllib import urlopen src = urlopen('http://www.exam
written on January 22, 2011 For web applications the safest bet currently is to stick with Python 2.x even for new projects. For the simple reason that right now we don’t have enough supporting libraries for Python 3 yet and porting some of them over is a huge step. But with all the people telling one that it’s hard and painful to upgrade to Python 3, how does one make this upgrade easier? For hig
Functional Programming HOWTO¶ Author: A. M. Kuchling Release: 0.32 In this document, we’ll take a tour of Python’s features suitable for implementing programs in a functional style. After an introduction to the concepts of functional programming, we’ll look at language features such as iterators and generators and relevant library modules such as itertools and functools. Introduction¶ This section
Introduction lxml is a Pythonic binding for the libxml2 and libxslt libraries. It is unique in that it combines the speed and feature completeness of these libraries with the simplicity of a native Python API, mostly compatible but superior to the well-known ElementTree API. See the introduction for more information about background and goals. Some common questions are answered in the FAQ. This pa
The Explorer Mixins considered harmful/1 by Michele Simionato January 1, 2009 Summary A mixin is a collection of methods that can be injected into a class. The mixin technique consists in building classes by composing reusable mixins. The advantages and disadvantages of the technique are very much debated. I will focus on the negative aspects. The idea of creating classes by composing reusable col
こんにちは、Python 会の。。。思いつきませんでした。初 "Python Web フレームワーク アドベントカレンダー2010" に参加させていただくことになりました。よろしくおねがいします。アドベントカレンダー参加者のブログは cielquis.net に綺麗にまとめられていますよ。 ごめんなさい。Web アプリケーションフレームワークの作成なんて 1 日じゃむりぽ><。メインで使ってるフレームワークは、Django か webapp ぐらい。。。最近 dis られてるので、Django 記事書くのもあれだ・・・。 ということで本題です。Python は WSGI (Web Server Gateway Interface) という Web アプリケーションと Web サーバ間の共通インターフェースがあります。そのインターフェースを実装したオブジェクトは、Web アプリケーションとし
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く