by shigemk2

当面は技術的なことしか書かない

Python

pyenv 1.2.24.1

Updated CHANGELOG.MD to reflect latest changes at v1.2.24 Fixed pyenv---version to display the correct pyenv version github.com

pyenv v1.2.23

github.com python-build: Add CPython v3.7.10 (#1738) python-build: Add CPython v3.6.13 (#1817) python-build: Add PyPy 3.7-c-jit-latest (#1812) python-build: Add PyPy 3.7 (#1718, #1726, #1780) python-build: Add miniconda3 4.9.2 (#1763) pyth…

pypa/wheel pull 386

homebrewでawscliとかfish(の中のsphinx-doc)をインストールするときにmacosx_libfile.pyのところでAssertionErrorになってた MacOSのOSバージョンをチェックする箇所でエラーになってたっぽい。 この修正がwheelに取り込まれたことで、awscliやfishがちゃん…

Python 3.9.1

12/11リリース予定。今rc1 www.python.org 3.9.1にBigSurとM1対応が入る。 docs.python.org

pyenv v1.2.21

Pythonもろもろ追加。 github.com

python-tabulate

なんかよくわからないなgithub/asciiで改行がおかしくなるのはマークダウンテーブルで改行が観念できないからだろうか。 >>> from tabulate import tabulate >>> table = [["Sun",696000,1989100000],["Earth",6371,5973.6], ... ["Moon",1737,73.5],["Mars"…

cli_helpers

>>> from cli_helpers import tabular_output >>> data = [[1, 'Asgard', True], [2, 'Camelot', False], [3, 'El Dorado', True]] >>> headers = ['id', 'city', 'visited'] >>> [print(test) for test in tabular_output.format_output(data, headers, for…

TabularOutputFormatterのformat_name

改行 GitHub - dbcli/cli_helpers: Python helpers for common CLI tasks >>> from cli_helpers.tabular_output import TabularOutputFormatter >>> headers = ('day', 'temperature') >>> data = enumerate(('87\n87', '80', '79'), 1) >>> formatter = Tab…

pyenv 1.2.20

Release v1.2.20 · pyenv/pyenv · GitHub

pyenv 1.2.18

Release v1.2.18 · pyenv/pyenv · GitHub エラー修正とopenssl更新

pyenv v1.2.17

python-build: Add CPython 3.8.2 python-build: Add CPython 3.7.7 (#1553) python-build: Add Miniconda versions newer than 4.3.30 (#1361) python-build: Add Micropython 1.12 (#1542) python-build: Add Add CPython 3.9.0a4 pyenv: Fix sed illegal …

Redash 8 Python 3

Redash8だけど、コミットログを見る限りではPython3対応はまだ入っていないぽい。Dockerから8のイメージをpullしてきたけど、コンテナ内のPythonは2だった。 Docker Hub

Python emoji

素のPythonじゃsyntax errorになるから >> import emoji >> print(emoji.emojize('Python is :thumbs_up:')) Python is >> print(emoji.emojize('Python is :thumbsup:', use_aliases=True)) Python is >> print(emoji.demojize('Python is ')) Python is …

Python replace

string.replace(old, new, count) Python String | replace() - GeeksforGeeks

slack-cli

pipで入れられる。homebrewはしらない。 初実行時にレガシートークンが聞かれるのでそれを入力してつかう。トークンの場所は、helpで確認できる。 $ slack-cli -d general "Hello everyone!" https://pypi.org/project/slack-cli/

pandas PR 27899

PRクローズの原因は、想像以上にファイルI/O系のメソッドが多く、すべてのI/Oメソッドのパラメータに対応するのが非常に困難であったこと。 だから、コア開発者の間でも意見が割れに割れて、最終的にはクローズになった。 (時差とかの関係でPRの進捗が進まな…

pandas-dev PR 27899

概ね賛成 でもread_csvも変更かけてほしい ああレビューが拡散していく

pandas pull 27899 日記

openの引数は今のPython3で8つある うちいまのPandasが対応しているのは5つ(といってもerrorsはユーザーからは弄れない) 全部対応しきれないからドキュメント書くだけで良くない?という啓示 Built-in Functions — Python 3.7.4 documentation

sphinx versionadded

こういう書き方をすると """ Make box plots from DataFrameGroupBy data. Parameters ---------- grouped : Grouped DataFrame subplots : bool * ``False`` - no subplots will be used * ``True`` - create a subplot for each group column : column nam…

PyAthena

Redashで使われているAthenaのPythonパッケージ。 PyAthena · PyPI

pytest 細かく

# ファイルごと pytest -v pandas/tests/io/formats/test_to_csv.py # クラスごと pytest -v pandas/tests/io/formats/test_to_csv.py::TestToCSV # メソッドごと pytest -v pandas/tests/io/formats/test_to_csv.py::TestToCSV::test_to_csv_file_object_wi…

Pythonのcodesのエラーハンドリングオプション一覧

Pythonのcodesのエラーハンドリングオプション一覧。 strict UnicodeError例外を出す ignore おかしなデータが来ても無視する replace おかしなデータが来たら?に置換する あとの置換方法はXML文字とかバックスラッシュエスケープ文字とかだけど、backslashr…

codes.openのerrors

codes.openのerrors strict デフォルト UnicodeErrorを発生させる ignore おかしなデータが来ても無視する replace おかしなデータが来たら?とか適当な文字に変換する codecs — Codec registry and base classes — Python 3.7.4 documentation

pandas pull request template

テストしろ flake8しろ blackしろ コードレビュー ソースコード自動生成

click.UsageError

使い方間違ってる、的なのを明示したいときの例外。 API — Click Documentation (7.x)

pandas Issue投げポイント

Issue投げてね Issueめちゃくちゃ多くてチェックするのしんどいから他に似たような内容のIssueがないか探してね バージョンを最新版にしてもう一度試してね pd.show_versions() の結果を貼っつけてね

RundeckRun

This is a lightweight wrapper written in Python to interact with the Rundeck API. It uses the awesome requests library. なんだけどコードみたらAPIのバージョンが11とかなので、実行中ジョブのリストなどは使えない… RundeckRun — RundeckRun 0.2.2 …

pyenv v1.2.13

アップデート後のpyenv rehashを忘れない python-build: Add CPython 3.7.4 python-build: Add CPython 3.6.9 Release v1.2.13 · pyenv/pyenv · GitHub

PyGitHub get_issues

Issueの情報を取得する。sinceがあってuntilがないのは、公式のAPIにuntilがないから。あとsinceは更新日時基準。 Repository — PyGithub 1.43.7 documentation Issues | GitHub Developer Guide GITHUB_TOKEN="xxxxxxxxxxxxxxxxxxxxxxxxxxxxx" g = Github(G…

pandas read_json

pandas read_json pandasでJSONを読み込むアレ。 pandas.read_json — pandas 0.24.2 documentation