並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 45件

新着順 人気順

python inline if none elseの検索結果1 - 40 件 / 45件

  • IAM ロールで 100 連鎖してみた | DevelopersIO

    俺達はいつまでも立ち尽くし見つめていた━━━ 数多の IAM ロールが移ろうように連鎖していく、そのさまを。 コンバンハ、「 IAM ロールはお面」おじさんです。 この世で最も大切なもの、それは繋がりであり、そして連なりですよね。 ということで、早速 IAM ロールで 10 連鎖してみました。 いや、せっかくなので 100 連鎖くらい行ってみましょうか。そうしましょう。興奮してきたな。 まとめ IAM ロールはそんな連鎖させるようなもんじゃない。 手始めに IAM ロールを 101 個作ろう 早速、 100 連鎖のために IAM ロールを 101 個作ります。 「 100 連鎖なのに 101 個なの?」と思うかもしれませんが、ヤマタノオロチの「股(首と首の間)」は 7 個しかありませんよね。(「岐」は 8 個あるんですけどね。)それと同じです。 101 個くらいの数なら「温かみのある手作業

      IAM ロールで 100 連鎖してみた | DevelopersIO
    • Writing a C compiler in 500 lines of Python

      A few months ago, I set myself the challenge of writing a C compiler in 500 lines of Python1, after writing my SDF donut post. How hard could it be? The answer was, pretty hard, even when dropping quite a few features. But it was also pretty interesting, and the result is surprisingly functional and not too hard to understand! There's too much code for me to comprehensively cover in a single blog

      • LogLog Games

        The article is also available in Chinese. Disclaimer: This post is a very long collection of thoughts and problems I've had over the years, and also addresses some of the arguments I've been repeatedly told. This post expresses my opinion the has been formed over using Rust for gamedev for many thousands of hours over many years, and multiple finished games. This isn't meant to brag or indicate su

        • RubyのGVLを消し去りたいあなたへ(翻訳)|TechRacho by BPS株式会社

          概要 原著者の許諾を得て翻訳・公開いたします。 英語記事: So You Want To Remove The GVL? | byroot’s blog 原文公開日: 2025/01/29 原著者: byroot -- Railsコアコミッター、Rubyコミッターであり、ShopifyのRuby/Railsインフラチームのシニアスタッフエンジニアです 日本語タイトルは内容に即したものにしました。 GVLは「グローバルVMロック」の略ですが、「ジャイアントVMロック」とされることもあります。 参考: Rubyの(グローバル)VMロックをトレースする(翻訳) 参考: スレッド (Ruby 3.4 リファレンスマニュアル) 私がやりたいのは、Pitchforkに関する記事を書いて、これがどんな理由でできたのか、なぜ現在のような形になったのか、そして今後どうなるのかについて説明することです。しかし

            RubyのGVLを消し去りたいあなたへ(翻訳)|TechRacho by BPS株式会社
          • Rewriting the Ruby parser

            At Shopify, we have spent the last year writing a new Ruby parser, which we’ve called YARP (Yet Another Ruby Parser). As of the date of this post, YARP can parse a semantically equivalent syntax tree to Ruby 3.3 on every Ruby file in Shopify’s main codebase, GitHub’s main codebase, CRuby, and the 100 most popular gems downloaded from rubygems.org. We recently got approval to merge this work into C

              Rewriting the Ruby parser
            • Changing std::sort at Google’s Scale and Beyond

              TL;DR; We are changing std::sort in LLVM’s libcxx. That’s a long story of what it took us to get there and all possible consequences, bugs you might encounter with examples from open source. We provide some benchmarks, perspective, why we did this in the first place and what it cost us with exciting ideas from Hyrum’s Law to reinforcement learning. All changes went into open source and thus I can

                Changing std::sort at Google’s Scale and Beyond
              • March 2025 (version 1.99)

                Update 1.99.1: The update addresses these security issues. Update 1.99.2: The update addresses these issues. Update 1.99.3: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the March 2025 release of Visual Studio Code. There are many updates in this version that we hope you'll like, some of the key highligh

                  March 2025 (version 1.99)
                • Amazon ECS deployment circuit breaker のご紹介 | Amazon Web Services

                  Amazon Web Services ブログ Amazon ECS deployment circuit breaker のご紹介 ※日本語字幕の表示には、設定 → 字幕 → 自動翻訳 → 日本語をご選択ください EC2 および Fargate コンピュートタイプ用の Amazon ECS deployment circuit breaker をパブリックプレビューで発表しました。この機能により、Amazon ECS をご利用のお客様は、手動での作業を行うことなく、不健全なサービスデプロイを自動的にロールバックできるようになります。これにより、お客様は失敗したデプロイを迅速に発見できるようになり、失敗したタスクのためにリソースが消費されたり、デプロイが無期限に遅延したりすることを心配する必要がなくなります。 以前は、Amazon ECS でデプロイメントタイプにローリングアップデートを使

                    Amazon ECS deployment circuit breaker のご紹介 | Amazon Web Services
                  • Kalyn: a self-hosting compiler for x86-64

                    Over the course of my Spring 2020 semester at Harvey Mudd College, I developed a self-hosting compiler entirely from scratch. This article walks through many interesting parts of the project. It’s laid out so you can just read from beginning to end, but if you’re more interested in a particular topic, feel free to jump there. Or, take a look at the project on GitHub. Table of contents What the pro

                    • Performance of WebAssembly runtimes in 2023

                      Using libsodium in a web browser has been possible since 2013, thanks to the excellent Emscripten project. Since then, WebAssembly was introduced. A more efficient way to run code not originally written in JavaScript in a web browser. And libsodium added first-class support for WebAssembly in 2017. On web browsers supporting it, and in allowed contexts allowing it, that gave a nice speed boost. Li

                      • 0.8.0 Release Notes ⚡ The Zig Programming Language

                        Tier 4 Support § Support for these targets is entirely experimental. If this target is provided by LLVM, LLVM may have the target as an experimental target, which means that you need to use Zig-provided binaries for the target to be available, or build LLVM from source with special configure flags. zig targets will display the target if it is available. This target may be considered deprecated by

                        • So You Want To Remove The GVL?

                          I want to write a post about Pitchfork, explaining where it comes from, why it is like it is, and how I see its future. But before I can get to that, I think I need to share my mental model on a few things, in this case, Ruby’s GVL. For quite a long time, it has been said that Rails applications are mostly IO-bound, hence Ruby’s GVL isn’t that big of a deal and that has influenced the design of so

                          • Rustacean のための F# 入門

                            また、 F# の decimal 型は Rust には標準で存在しませんが、 5m という書き方をします。 数字の間に _ を入れて読みやすくすることができるのも同様です。 let num = 8_000_000; その他の型について ... F# の char は Rust の char に似ていますが、 前者が UTF-16 なのに対し、 Rust の char は UTF-32 で常に 4bytes です。これは、 Rust とは違い、 char の配列がほぼそのまま string として扱えることを示しています。 Rust の unit と F# の unit は両方とも () で表され、役割も同じです。 文字列型に関しては Rust には色々あるので、簡単な比較はできませんが、 string は immutable な char の配列で、 mutable に扱いたい場合は St

                              Rustacean のための F# 入門
                            • 0.10.0 Release Notes ⚡ The Zig Programming Language

                              Tier 4 Support § Support for these targets is entirely experimental. If this target is provided by LLVM, LLVM may have the target as an experimental target, which means that you need to use Zig-provided binaries for the target to be available, or build LLVM from source with special configure flags. zig targets will display the target if it is available. This target may be considered deprecated by

                              • Cursor はどこが GitHub Copilot より優れているのか(独自機能Docsの実力) - GMOインターネットグループ グループ研究開発本部

                                D.M. です。 AI 搭載で話題の IDE である Cursor について、 GitHub Copilot と比べた場合の利点を掘り下げてみます。 結論ファースト ・現段階では一長一短。Cursor にしかない機能もあれば、 GitHub Copilotにしかない機能もある。 → 特に Cursor の Docs は独自機能(GitHub Cipolotにはない) ・両方併用できる。 ・Cursor のAI自動プログラミングスキルは既存の「GPT-4」と同等(ただ、モデルを変更できる) 簡単な単発バッチ処理は高速で実装できる。 複雑化すると100点は難しい。 現段階では、AIに全部書かせるのではなく、補助ツールとしてとらえるほうが効果的。 導入編:Cursorとは AI がプログラミングしてくれる時代 2022年11月にChatGPTが発表されて以降、 LLM は簡単なプログラミングが可

                                • Rust 1.53を早めに深掘り - OPTiM TECH BLOG

                                  こんにちは、R&Dチームの齋藤(@aznhe21)です。 今日はオプティムの創立記念パーティーがオンラインで行われます。 オプティムは2000/6/8に設立され、去年は20周年の節目であったにも関わらず生憎の時制で大きく祝えませんでしたが、 今年は準備も万全、盛大にお祝いしたいと思います。 さて、本日、日本時間6/18(金)、Rust 1.53がリリースされました。 この記事ではRust 1.53での変更点を詳しく紹介します。 6/18は京大の前身・京都帝国大学創立の日 ピックアップ 識別子にASCII以外の文字も使えるようになった ORパターンが使えるようになった 配列にIntoIteratorが実装された 安定化されたAPIのドキュメント AtomicBool::fetch_update サンプル AtomicPtr::fetch_update サンプル BTreeMap::retai

                                    Rust 1.53を早めに深掘り - OPTiM TECH BLOG
                                  • prompts.chat

                                    Welcome to the “Awesome ChatGPT Prompts” repository! While this collection was originally created for ChatGPT, these prompts work great with other AI models like Claude, Gemini, Hugging Face Chat, Llama, Mistral, and more. ChatGPT is a web interface created by OpenAI that provides access to their GPT (Generative Pre-trained Transformer) language models. The underlying models, like GPT-4o and GPT-o

                                    • Transformer models: an introduction and catalog — 2023 Edition

                                      Transformer models: an introduction and catalog — 2023 Edition January 16, 2023 52 minute read This post is now an ArXiV paper that you can print and cite. Update 05/2023 Another pretty large update after 4 months. I was invited to submit the article to a journal, so I decided to enlist some help from some LinkedIn colleages and completely revamp it. First off, we added a whole lot of new models,

                                        Transformer models: an introduction and catalog — 2023 Edition
                                      • Rust on MIPS64 Windows NT 4.0

                                        Introduction Some part of me has always been fascinated with coercing code to run in weird places. I scratch this itch a lot with my security research projects. These often lead me to writing shellcode to run in kernels or embedded hardware, sometimes with the only way being through an existing bug. For those not familiar, shellcode is honestly hard to describe. I don’t know if there’s a very form

                                          Rust on MIPS64 Windows NT 4.0
                                        • August 2021 (version 1.60)

                                          Join a VS Code Dev Days event near you to learn about AI-assisted development in VS Code. Update 1.60.1: The update addresses these issues. Update 1.60.2: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the August 2021 release of Visual Studio Code. There are many updates in this version that we hope you w

                                            August 2021 (version 1.60)
                                          • o1 pro + AIエンジニアにチャットで指示しながら、研究的なことをさせてみる |Kan Hatakeyama

                                            はじめに自律的にプログラミングをしてくれるAIエンジニアをいい感じに動かせるようになってきたので、今日はChatGPT + devinで研究的なことをさせてみます。 自動研究といえば、昨年の夏に話題になった、Sakana AIのAIサイエンティストが有名です。 ただ、研究のネタを考えるのはまだあまり得意でない気がしたので、今回は適宜、そこはスマホで指示を出しながら、human in the loopで進めていきます。 最初のセットアップを除いて、チャットをするだけで、基本的な研究作業をこなせそう感じでした。 下準備: リポジトリを作ってdevinに登録するはじめに、パソコンを使って設定をします。このセクションの作業以降は、スマホがあればOKです。 githubでレポジトリを作り、一つだけ、開発方針に関するファイルを作っておきます。 DevelopmentPolycy.md 開発、コメントな

                                              o1 pro + AIエンジニアにチャットで指示しながら、研究的なことをさせてみる |Kan Hatakeyama
                                            • Sayonara, C++, and hello to Rust!

                                              This past May, I started a new job working in Rust. I was somewhat skeptical of Rust for a while, but it turns out, it really is all it’s cracked up to be. As a long-time C++ programmer, and C++ instructor, I am convinced that Rust is better than C++ in all of C++’s application space, that for any new programming project where C++ would make sense as the programming language, Rust would make more

                                              • October 2025 (version 1.106)

                                                Version 1.106 is now available! Read about the new features and fixes from October. Release date: November 12, 2025 Update 1.106.1: The update addresses these issues Update 1.106.2: The update addresses these issues Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the October 2025 release of Visual Studio Code. This release brings significan

                                                  October 2025 (version 1.106)
                                                • A 2025 Survey of Rust GUI Libraries

                                                  I did this in 2020 and then again in 2021, but I’m in the mood to look around again. Let’s look through Are We GUI Yet? and see what’s up these days. The task today is to have a text label and an input field that can change the text in the label. In React, for example, this is basically free: const Demo = () => { let [state, setState] = useState("Hello, world!"); return ( <div> <p>{state}</p> <inp

                                                  • What's New in Emacs 28.1?

                                                    Try Mastering Emacs for free! Are you struggling with the basics? Have you mastered movement and editing yet? When you have read Mastering Emacs you will understand Emacs. It’s that time again: there’s a new major version of Emacs and, with it, a treasure trove of new features and changes. Notable features include the formal inclusion of native compilation, a technique that will greatly speed up y

                                                    • Type Parameters Proposal

                                                      Ian Lance Taylor Robert Griesemer August 20, 2021 StatusThis is the design for adding generic programming using type parameters to the Go language. This design has been proposed and accepted as a future language change. We currently expect that this change will be available in the Go 1.18 release in early 2022. AbstractWe suggest extending the Go language to add optional type parameters to type an

                                                      • Scala3の新機能紹介 - Adwaysエンジニアブログ

                                                        こんにちは、おかむです。 開発開始から8年。28,000件のコミット、7400件のPR、4100件のClosed issue… 5/14に、とうとうScala3.0.0がリリースされました。 Scala3では、最新の型理論とScala2での経験が反映されています。 Easy to use, learn, and scale 移行や学習のためのドキュメント、Scala3の新しいマクロの解説など、各種ドキュメントの充実化も行われています。 今回はScala3の新しい要素について紹介していきます。 ちなみにすべては紹介しきれないので大きめの機能に絞っています。 新しい文法 New Control Syntax (新しい制御構文) Optional Braces (括弧の省略) 型システム Intersection Type (交差型) Union Type (共用体型) Type Lambda

                                                          Scala3の新機能紹介 - Adwaysエンジニアブログ
                                                        • bytecode interpreters for tiny computers ⁑ Dercuano

                                                          Introduction: Density Is King (With a Tiny VM) I've previously come to the conclusion that there's little reason for using bytecode in the modern world, except in order to get more compact code, for which it can be very effective. So, what kind of a bytecode engine will give you more compact code? Suppose I want a bytecode interpreter for a very small programming environment, specifically to minim

                                                          • Gregory Szorc's Digital Home | Rust is for Professionals

                                                            A professional programmer delivers value through the authoring and maintaining of software that solves problems. (There are other important ways for professional programmers to deliver value but this post is about programming.) Programmers rely on various tools to author software. Arguably the most important and consequential choice of tool is the programming language. In this post, I will articul

                                                            • Plan 9 Desktop Guide

                                                              PLAN 9 DESKTOP GUIDE INDEX What is Plan 9? Limitations and Workarounds Connecting to Other Systems VNC RDP SSH 9P Other methods Porting Applications Emulating other Operating Systems Virtualizing other Operating Systems Basics Window Management Copy Pasting Essential Programs Manipulating Text in the Terminal Acme - The Do It All Application Multiple Workspaces Tiling Windows Plumbing System Admin

                                                              • May 2023 (version 1.79)

                                                                Update 1.79.1: The update addresses this security issue. Update 1.79.2: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the May 2023 release of Visual Studio Code. There are many updates in this version that we hope you'll like, some of the key highlights include: Read-only mode - Mark specific files and f

                                                                  May 2023 (version 1.79)
                                                                • Writing Pong in Rust for my OS Written in Rust – Stephen Marz

                                                                  This post is part of a larger effort you can view over here: https://osblog.stephenmarz.com. Pong being played on my custom, RISC-V OS in Rust! Video Contents OverviewApplication Programmer’s Interface (API)Starting RoutinesSystem CallsDrawing PrimitivesEvent HandlingStart Our GameGame LoopPLAY Overview We last left off writing a graphics driver and an event driver for our operating system. We als

                                                                  • What's that touchscreen in my room?

                                                                    2024-01-20 Discussion on HackerNews and Lobsters. Roughly a year ago I moved into my new apartment. One of the reasons I picked this apartment was age of the building. The construction was finished in 2015, which ensured pretty good thermal isolation for winters as well as small nice things like Ethernet ports in each room. However, there was one part of my apartment that was too new and too smart

                                                                    • 開発生産性があがる生成AIを使った開発ツールの紹介 | CyberAgent Developers Blog

                                                                      これはCyberAgent Developers Advent Calendar 2023の13日目の記事です よければ他の記事も見てみてください はじめに Developer Productivity室(DP室)のuncle__koです。 DP室ではサイバーエージェントグループにおける事業開発の開発生産性(主にソフトウェアデリバリー領域)を大きく前進させるための開発に従事してます。 OpenAI社が2022年11月30日に公開したChatGPTを皮切りに、いまでは生成AIを聞かない日はないムーブメントになっているかと思います。 ChatGPTやGitHub Copilotの登場によって、日々の開発業務もかなり効率的に生産性が上がっていることかと思います。 今回は生成AI x Developer Productivityをテーマに、開発生産性があがりそうな、個人的に気になっている生成AIを

                                                                        開発生産性があがる生成AIを使った開発ツールの紹介 | CyberAgent Developers Blog
                                                                      • cuneicode, and the Future of Text in C

                                                                        Following up from the last post, there is a lot more we need to cover. This was intended to be the post where we talk exclusively about benchmarks and numbers. But, I have unfortunately been perfectly taunted and status-locked, like a monster whose “aggro” was pulled by a tank. The reason, of course, is due to a few folks taking issue with my outright dismissal of the C and C++ APIs (and not showi

                                                                          cuneicode, and the Future of Text in C
                                                                        • Introduction - PyO3 user guide

                                                                          Press ← or → to navigate between chapters Press S or / to search in the book Press ? to show this help Press Esc to hide this help The PyO3 user guide Welcome to the PyO3 user guide! This book is a companion to PyO3's API docs. It contains examples and documentation to explain all of PyO3's use cases in detail. The rough order of material in this user guide is as follows: Getting started Wrapping

                                                                          • 地面を見下ろす少年の足蹴にされる私

                                                                            Contracts提案(P2900R14)がC++26に向けて採択され、C++26では契約プログラミング機能を言語サポートの下で実践できるようになります。この記事は、その契約プログラミング機能の一部として導入されている違反ハンドラというものについてのお話です。 契約プログラミング機能における違反ハンドラの概要 ユーザー定義違反ハンドラ std::contracts::contract_violation より一般的な利用 外部ツールの共通コールバック機構として 実行時エラーハンドリングのコールバック機能として(P3290R2) プロファイル機能の実行時検査におけるコールバックとして(P3081R0) 未定義動作の実行時ハンドリング機能として(P3100R0, P3229R1, P3205R0) 参考文献 契約プログラミング機能における違反ハンドラの概要 C++26の契約プログラミング機能は

                                                                              地面を見下ろす少年の足蹴にされる私
                                                                            • ECS内のインスタンスを自動ドレイニングするシステム構築 ~ ECS を使う上で外せないステータス 、ドレイニング~ - ヘヴィメタル・エンジニアリング

                                                                              はじめに よくAWSに触れるものです。 AWSにはElastic Container Service(以下ECS)と呼ばれるフルマネージド型のコンテナオーケストレーションサービスがあります。 ECSはEC2インスタンス or Fargate上にコンテナをスケーラブルに配置、管理、監視できるサービスで、比較的扱いやすいサービスです。 そんなECSですがコンテナのライフサイクルやEC2を使う場合は配置、サービス(ECS特有の用語)によるタスクスケーリングなどはそれなりの知識が必要なのも事実です。 今回はそんなコンテナのライフサイクルに関連して、ドレイニングについて解説 & そのドレイニングを用いた安全なインスタンスの終了のさせ方を解説していきたいと思います。 ドレイニングについて EC2のライフサイクルは複数あります。 こちらの公式ドキュメントに図が載っています。 docs.aws.amazo

                                                                                ECS内のインスタンスを自動ドレイニングするシステム構築 ~ ECS を使う上で外せないステータス 、ドレイニング~ - ヘヴィメタル・エンジニアリング
                                                                              • XBRL から財務諸表を抽出する | sasakiy84.net

                                                                                概要 arelle の使い方を示しつつ、XBRL からきちんとリンクファイルを使って階層構造をとってきて、それに対応するインスタンスを取得する方法を示す。 どちらかといえば、経済学徒ではなく、エンジニア寄りのバックグラウンドを持つ人向けに書いている。 背景 最近、財務諸表の勉強をしていて、いろんな企業の財務諸表を一括で見たいと思った。 読んでいた解説が、財務諸表を視覚化して説明するタイプのものだったので、会計データをとってきて、それを D3.js で描画することを考えた。 結果、作成した財務諸表可視化アプリの方はある程度できていて、以下のリンクから閲覧できる。 https://financial-statements-visualization.sasakiy84.net/ sasakiy84/xbrl-extractor (XBRL 抽出コード) ただし、まだ少し大きめのバグが残っていた

                                                                                  XBRL から財務諸表を抽出する | sasakiy84.net
                                                                                • I wish Asciidoc was more popular • pdx.su

                                                                                  I've been using Markdown for a long time, and have grown accustomed to it. It has various quirks, features, and oddities, but what doesn't. But recently I decided to take a look at Asciidoc, a Markdown "competetor". I found it a great little document toolchain, but it won't replace Markdown. Both Asciidoc and Markdown allow you to write text based content using a simplified markup syntax. Instead