並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 99件

新着順 人気順

python check if variable not noneの検索結果1 - 40 件 / 99件

  • Command Line Interface Guidelines

    Contents Command Line Interface Guidelines An open-source guide to help you write better command-line programs, taking traditional UNIX principles and updating them for the modern day. Authors Aanand Prasad Engineer at Squarespace, co-creator of Docker Compose. @aanandprasad Ben Firshman Co-creator Replicate, co-creator of Docker Compose. @bfirsh Carl Tashian Offroad Engineer at Smallstep, first e

      Command Line Interface Guidelines
    • Ubuntu 24.04 LTS サーバ構築手順書

      0 issue "letsencrypt.org" 0 issuewild "letsencrypt.org" 0 iodef "mailto:yourmail@example.jp" §OS再インストール 初期設定で期待通りの設定ができていない場合は、OSの再インストールをする。 さくらVPSのコントロールパネルから、OSを再インストールするサーバを選ぶ。 www99999ui.vs.sakura.ne.jp §OSのインストール操作 Ubuntu 24.04 LTS を選ぶ。 OSインストール時のパケットフィルタ(ポート制限)を無効にして、ファイアウォールは手動で設定することにする。 初期ユーザのパスワードに使える文字が制限されているので、ここでは簡単なパスワードにしておき、後ですぐに複雑なパスワードに変更する。 公開鍵認証できるように公開鍵を登録しておく。 §秘密鍵と公開鍵の作成 ク

        Ubuntu 24.04 LTS サーバ構築手順書
      • OpenAI API ドキュメント 日本語訳|#2 GET STARTED 後編|ゑぐみかるちゃあ

        OpenAI API ドキュメントの日本語訳をこちらでまとめます。文字量の多いドキュメントなので、セクションごとに記事を分割しています。 今回は「GET STARTED 」のセクションからLibraries 、Models、TutorialsそしてUsage policiesを抜粋した後編です。 基本 DeepLで翻訳して、気になるところだけ書き換えています(ほぼ気になるところがないのが、DeepLのすごいところ)。原文との突き合わせができるようにはじめに原文を入れてますので、間違いなど見つけられましたら、ぜひご指摘ください。ご指摘箇所は随時反映させていただきます。 原文のリンクが有効になってますので、それぞれ必要な場合は原文リンクの方を参照ください。 前回のおさらいはこちら Python library|Python ライブラリWe provide a Python library, w

          OpenAI API ドキュメント 日本語訳|#2 GET STARTED 後編|ゑぐみかるちゃあ
        • research!rsc: Coroutines for Go

          This post is about why we need a coroutine package for Go, and what it would look like. But first, what are coroutines? Every programmer today is familiar with function calls (subroutines): F calls G, which stops F and runs G. G does its work, potentially calling and waiting for other functions, and eventually returns. When G returns, G is gone and F continues running. In this pattern, only one fu

          • NETGEAR社製ルーターにおける認証不要の任意コード実行の技術的解説(PSV-2022-0044) - GMO Flatt Security Blog

            ※本記事は先立って公開された英語版記事を翻訳し、日本語圏の読者向けに一部改変したものです。 画像出典: https://www.netgear.com/business/wifi/access-points/wac124/ はじめに こんにちは、株式会社Flatt Securityのstypr(@stereotype32)です。 一昨年、日本のOSS製品で発見された0day脆弱性に関する技術解説をブログに書きました。 それ以来、私は様々な製品に多くの脆弱性を発見してきました。残念ながら私が見つけたバグのほとんどはすぐに修正されなかったので、今日まで私が見つけた、技術的に興味深い脆弱性の情報を共有する機会がありませんでした。 本記事では、NETGEAR社のWAC124(AC2000)ルーターにおいて、様々な脆弱性を発見し、いくつかの脆弱性を連鎖させて、前提条件なしに未認証ユーザーの立場からコ

              NETGEAR社製ルーターにおける認証不要の任意コード実行の技術的解説(PSV-2022-0044) - GMO Flatt Security Blog
            • GPT in 60 Lines of NumPy | Jay Mody

              January 30, 2023 In this post, we'll implement a GPT from scratch in just 60 lines of numpy. We'll then load the trained GPT-2 model weights released by OpenAI into our implementation and generate some text. Note: This post assumes familiarity with Python, NumPy, and some basic experience with neural networks. This implementation is for educational purposes, so it's missing lots of features/improv

              • Amazon Linux 2023がGAされました | DevelopersIO

                抜粋 : Release cadence - Amazon Linux 2023 メジャーリリースとマイナーリリースの内容は以下AWS公式ドキュメントに記載されています。メジャーリリース時には互換性があるか十分に検証した上でアップデートしましょう。 Major version release— Includes new features and improvements in security and performance across the stack. The improvements might include major changes to the kernel, toolchain, Glib C, OpenSSL, and any other system libraries and utilities. Major releases of Amazon Linux ar

                  Amazon Linux 2023がGAされました | DevelopersIO
                • Dear Rubyists: Shopify Isn’t Your Enemy

                  I’ve been meaning to write a post about my perspective on Open Source and corporate entities. I already got the rough outline of it; however, I’m suffering from writer’s block, but more importantly, the whole post is a praise of how Shopify engages with Open Source communities. Hence, given the current climate, I don’t think I could publish it without addressing the elephant in the room first anyw

                  • 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

                    • Modern Emacs Typescript Web (React) Config with lsp-mode, treesitter, tailwind, TSX & more - Ovi Stoica

                      Table of Contents Introduction Part 1: Treesitter for Typescript & TSX LSP Support Completion setup Linter setup LSP Setup Eslint (Optional) Tailwind LSP Server LSP Performance Emacs LSP Booster Structural editing Formatting buffers with Prettier Other resources Conclusion Introduction I've worked within the JS ecosystem for the past 8 years using editors like Webstorm and VSCode, I started using

                      • ChatGPT Retrieval Pluginに任意のベクトル検索エンジンProviderを実装する - エムスリーテックブログ

                        Overview エムスリーエンジニアリンググループ AI・機械学習チームでソフトウェアエンジニアをしている中村(po3rin) です。検索とGoが好きです。 エムスリーではChatGPTの可能性にいち早く注目して活用を検討している段階ですが、本格的なデータ投入にはまだ懸念もあり、セキュリティチームと検討を進めている段階です。 そんな中で個人または組織のドキュメントのセマンティック検索と取得を可能にするChatGPTプラグイン「ChatGPT Retrieval Plugin」が登場しました。 github.com 情報検索好きとしては黙っていられず、外部公開用のエムスリーAI・機械学習チームのメンバー紹介ドキュメントを使ってローカルで試してみました。 # 用意したドキュメント 中村弘武は東京都在住で、エムスリーという企業で働いでいます。 エムスリーの検索基盤を主に担当しています。また、書

                          ChatGPT Retrieval Pluginに任意のベクトル検索エンジンProviderを実装する - エムスリーテックブログ
                        • 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

                          • 第752回 RISC-VのシングルボードコンピューターであるVisionFive 2を使ってみる | gihyo.jp

                            今回はStarFive Technology製のRISC-Vシングルボードコンピューター(SBC)であるVisionFive 2にDebianをインストールして、その性能を計測してみましょう。 RISC-VとVisionFive 2 RISC-V(りすく・ふぁいぶ)は今もっとも熱い命令セットアーキテクチャーです。2010年頃に生まれたRISC-Vは、オープンな規格という強みを活かしてどんどんエコシステムを構築し、今では様々な企業がRISC-Vに本格的に手を出す状況になっています。AMD64/Intel 64やARMには性能も普及度合いもまだまだ及びませんが、今の勢いを維持できれば近い将来その状況は変わってくるでしょう。 本連載でも2018年ぐらいから、RISC-Vの記事を何度か取り上げていました。 第505回:「オープン規格の新しい命令セットアーキテクチャRISC-V入門 ツールチェインを

                              第752回 RISC-VのシングルボードコンピューターであるVisionFive 2を使ってみる | gihyo.jp
                            • Memory Allocation

                              One thing that all programs on your computer have in common is a need for memory. Programs need to be loaded from your hard drive into memory before they can be run. While running, the majority of what programs do is load values from memory, do some computation on them, and then store the result back in memory. In this post I'm going to introduce you to the basics of memory allocation. Allocators

                                Memory Allocation
                              • Snowflakeの力を引き出すためのdbtを活用したデータ基盤開発の全貌 - CARTA TECH BLOG

                                当記事は、dbtのカレンダー | Advent Calendar 2023 - Qiita の23日目の記事です。 こんにちは、株式会社CARTA MARKETING FIRMのデータエンジニア、@pei0804です。データエンジニアリングのほか、組織運営やデータエンジニア育成にも携わっています。 本記事では、Snowflakeを中心とした当社のデータ基盤「Vision」と、その中核であるdbtの利用について深掘りします。dbtを活用することで、SQLのみでデータパイプラインを効率的に構築し、作業の効率化を図っています。 dbt導入の詳しい導入背景は以下のスライドでご覧いただけます:広告レポーティング基盤に、dbtを導入したら別物になった話 / tokyo-dbt-meetup-4 - Speaker Deck。 私たちのチームでは、ビジネスに直接価値を提供しているdbtモデルの開発はプロ

                                  Snowflakeの力を引き出すためのdbtを活用したデータ基盤開発の全貌 - CARTA TECH BLOG
                                • 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
                                  • How to create a Python package in 2022

                                    Photo by Claudio Schwarz on Unsplash. How to create a Python package? In order to create a Python package, you need to write the code that implements the functionality you want to put in your package, and then you need to publish it to PyPI. That is the bare minimum. Nowadays, you can also set up a variety of other things to make your life easier down the road: continuous testing of your package;

                                      How to create a Python package in 2022
                                    • Announcing TypeScript 5.2 - TypeScript

                                      Today we’re excited to announce the release of TypeScript 5.2! If you’re not familiar with TypeScript, it’s a language that builds on top of JavaScript by making it possible to declare and describe types. Writing types in our code allows us to explain intent and have other tools check our code to catch mistakes like typos, issues with null and undefined, and more. Types also power TypeScript’s edi

                                        Announcing TypeScript 5.2 - TypeScript
                                      • 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)
                                        • AST vs. Bytecode: Interpreters in the Age of Meta-Compilation

                                          233 AST vs. Bytecode: Interpreters in the Age of Meta-Compilation OCTAVE LAROSE, University of Kent, UK SOPHIE KALEBA, University of Kent, UK HUMPHREY BURCHELL, University of Kent, UK STEFAN MARR, University of Kent, UK Thanks to partial evaluation and meta-tracing, it became practical to build language implementations that reach state-of-the-art peak performance by implementing only an interprete

                                          • Announcing TypeScript 5.2 RC - TypeScript

                                            Today we’re excited to announce our Release Candidate of TypeScript 5.2! Between now and the stable release of TypeScript 5.2, we expect no further changes apart from critical bug fixes. To get started using the RC, you can get it through NuGet, or through npm with the following command: npm install -D typescript@rc Here’s a quick list of what’s new in TypeScript 5.2! using Declarations and Explic

                                              Announcing TypeScript 5.2 RC - TypeScript
                                            • April 2022 (version 1.67)

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

                                                April 2022 (version 1.67)
                                              • May 2025 (version 1.101)

                                                Release date: June 12, 2025 Security update: The following extension has security updates: ms-python.python. Update 1.101.1: The update addresses these issues. Update 1.101.2: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the May 2025 release of Visual Studio Code. There are many updates in this version

                                                  May 2025 (version 1.101)
                                                • Parsing SQL - Strumenta

                                                  The code for this tutorial is on GitHub: parsing-sql SQL is a language to handle data in a relational database. If you worked with data you have probably worked with SQL. In this article we will talk about parsing SQL. It is in the same league of HTML: maybe you never learned it formally but you kind of know how to use it. That is great because if you know SQL, you know how to handle data. However

                                                    Parsing SQL - Strumenta
                                                  • Implementing Logic Programming

                                                    Most of my readers are probably familiar with procedural programming, object-oriented programming (OOP), and functional programming (FP). The majority of top programming languages on all of the language popularity charts (like TIOBE) support all three to some extent. Even if a programmer avoided one or more of those three paradigms like the plague, they’re likely at least aware of them and what th

                                                      Implementing Logic Programming
                                                    • Building a Toy Programming Language in Python

                                                      I thought it would be fun to go outside of my comfort zone of web development topics and write about something completely different and new, something I have never written about before. So today, I'm going to show you how to implement a programming language! The project will parse and execute programs written in a simple language I called my (I know it's a lame name, but hey, it is "my" language).

                                                        Building a Toy Programming Language in Python
                                                      • 開発品質とDeveloper eXperienceを高めるコンテナ開発環境のご紹介 (Python) - ABEJA Tech Blog

                                                        はじめに こんにちは 2023年1月に入社し、システム開発グループでエンジニアをしてる春名です。 私の所属しているシステム開発グループでは、開発初期の環境構築をより効率的に行うための活動に取り組んでいます。 今回はそのうちの一つである、Pythonでコンテナ開発をする環境を構築した内容をご紹介します。 なぜコンテナ開発環境かと言いますと、単にAWSのECSやGoogle CloudのCloud Runを使ってデリバリーする案件が多いからです。 より使用頻度の高い開発環境を整備し、テンプレート化しておくことで開発の効率化に活用しています。 目次 はじめに 目次 今回作成する環境 Poetryによるプロジェクトの作成 Poetryのインストール プロジェクトの作成 poetryの設定 .gitignoreの作成 依存関係の追加 FastAPI Ruff / Black / mypy / pyt

                                                          開発品質とDeveloper eXperienceを高めるコンテナ開発環境のご紹介 (Python) - ABEJA Tech Blog
                                                        • Python's "Type Hints" are a bit of a disappointment to me

                                                          blog - git - desktop - images - contact Python's "Type Hints" are a bit of a disappointment to me 2022-04-21 Preface You are reading version 2.0 of this blog post. I've incorporated some feedback I got into this revised version. Introduction Over the course of several Python 3.x versions, "type hints" were introduced. You can now annotate functions: def greeting(name: str) -> str: return 'Hello '

                                                          • 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

                                                            • February 2021 (version 1.54)

                                                              Join a VS Code Dev Days event near you to learn about AI-assisted development in VS Code. Update 1.54.1: The update addresses an issue with an extension dependency. Update 1.54.2: The update addresses these issues. Update 1.54.3: The update addresses this issue. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the February 2021 release of Vi

                                                                February 2021 (version 1.54)
                                                              • Examples of floating point problems

                                                                January 13, 2023 Hello! I’ve been thinking about writing a zine about how things are represented on computers in bytes, so I was thinking about floating point. I’ve heard a million times about the dangers of floating point arithmetic, like: addition isn’t associative (x + (y + z) is different from (x + y) + z) if you add very big values to very small values, you can get inaccurate results (the sma

                                                                • 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

                                                                  • Advent of Code on the Nintendo DS

                                                                    It is December. That means annoying Christmas things are everywhere, including but not limited to the annual programming semi-competition known as Advent of Code. The problem with Advent of Code is that it is a waste of time. Most of the puzzles are in the realm of either string processing (somewhat applicable to programming), logic puzzles (not really applicable to most programming), or stupid go

                                                                    • How a simple Linux kernel memory corruption bug can lead to complete system compromise

                                                                      In this case, reallocating the object as one of those three types didn't seem to me like a nice way forward (although it should be possible to exploit this somehow with some effort, e.g. by using count.counter to corrupt the buf field of seq_file). Also, some systems might be using the slab_nomerge kernel command line flag, which disables this merging behavior. Another approach that I didn't look

                                                                      • 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

                                                                        • My thoughts on writing a Minecraft server from scratch (in Bash)

                                                                          My thoughts on writing a Minecraft server from scratch (in Bash) For the past year or so, I've been thinking about writing a Minecraft server in Bash as a thought excercise. I once tried that before with the Classic protocol (the one from 2009), but I quickly realized there wasn't really a way to properly parse binary data in bash. Take the following code sample: function a() { read -n 2 uwu echo

                                                                          • ​Getting Started with Python

                                                                            Python is a powerful programming language that provides many packages that we can use. Using the versatile Python programming language, we can develop the following: AutomationDesktop applicationAndroidWebIoT home automationData Science and the list goes on.In this article, our primary focus will be knowing how to start learning Python and the essentials required to be a data scientist. Below is t

                                                                              ​Getting Started with Python
                                                                            • 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

                                                                              • Python behind the scenes #13: the GIL and its effects on Python multithreading

                                                                                As you probably know, the GIL stands for the Global Interpreter Lock, and its job is to make the CPython interpreter thread-safe. The GIL allows only one OS thread to execute Python bytecode at any given time, and the consequence of this is that it's not possible to speed up CPU-intensive Python code by distributing the work among multiple threads. This is, however, not the only negative effect of

                                                                                • Announcing TypeScript 5.2 Beta - TypeScript

                                                                                  Today we are excited to announce the availability of TypeScript 5.2 Beta. To get started using the beta, you can get it through NuGet, or through npm with the following command: npm install -D typescript@beta Here’s a quick list of what’s new in TypeScript 5.2! using Declarations and Explicit Resource Management Decorator Metadata Named and Anonymous Tuple Elements Easier Method Usage for Unions o

                                                                                    Announcing TypeScript 5.2 Beta - TypeScript