pyenv-installer VS yapf

Compare pyenv-installer vs yapf and see what are their differences.

pyenv-installer

This tool is used to install `pyenv` and friends. (by pyenv)

yapf

A formatter for Python files (by google)
Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
pyenv-installer yapf
17 21
3,838 13,617
0.9% 0.4%
3.7 8.3
10 months ago 9 days ago
Shell Python
MIT License Apache License 2.0
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

pyenv-installer

Posts with mentions or reviews of pyenv-installer. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-07-08.
  • pyenv - manage python versions
    2 projects | dev.to | 8 Jul 2023
    To install it make sure that all prerequisites are met. Then use the pyenv-installer project like this to get the tool installed:
  • Your own Stable Diffusion endpoint with AWS SageMaker
    7 projects | dev.to | 13 Oct 2022
    For python, it's recommended to use pyenv, which allows you to install several versions of python at the same time with simple commands like this: pyenv install 3.9.13
  • Zellij: A terminal workspace with batteries included
    9 projects | news.ycombinator.com | 12 Aug 2022
    Please don't contribute worthless and irrelevant comments like this. As you doubtless well know, piping from curl into bash is something that a large subset of respected programmers think is reasonable, and another rather tedious subset do not. For example, the entire Rust community clearly has a consensus that it's reasonable: https://rustup.rs/ As does homebrew https://brew.sh/ and pyenv https://github.com/pyenv/pyenv-installer#install to name whatever came to my mind in 30s thought.

    Since the debate has such large numbers on both sides, your individual opinion on it is neither interesting nor germane.

  • Cómo instalar y crear un entorno virtual con pyenv en ubuntu 22.04 LTS
    2 projects | dev.to | 8 Jul 2022
  • Pytest is failing on GitHub Actions but succeeds locally
    3 projects | /r/learnprogramming | 8 May 2022
    name: Test, build and release # whenever a branch or commit is pushed on: [push] jobs: # use pytest test: # used to ensure testing is done right env: DEVELOPMENT: '1' runs-on: ubuntu-latest # to avoid using old sqlite version container: image: debian:latest options: --user root steps: # check out repo - uses: actions/checkout@v2 # prevent from asking user for input - run: export DEBIAN_FRONTEND=noninteractive # install recommended tools for building Python - run: apt -q update - run: apt -q install make build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm libncursesw5-dev xz-utils tk-dev libxml2-dev libxmlsec1-dev libffi-dev liblzma-dev git sqlite3 -y - run: apt -q upgrade -y # install pyenv - run: curl -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash - run: exec $SHELL - run: ~/.pyenv/bin/pyenv update # install and set up required Python - run: ~/.pyenv/bin/pyenv install 3.10.2 - run: ~/.pyenv/bin/pyenv virtualenv 3.10.2 npbc - run: ~/.pyenv/bin/pyenv local 3.10.2/envs/npbc # print version info (debugging) - run: ~/.pyenv/shims/python -V - run: ~/.pyenv/shims/python -c "import sqlite3; print(sqlite3.version)" # install pip packages - run: ~/.pyenv/shims/pip install -r requirements.txt pytest # run test - run: ~/.pyenv/shims/pytest -vv
  • Managing multiple versions of Python using pyenv and virtualenvwrapper
    2 projects | dev.to | 5 Nov 2021
    curl -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash
  • Trying to install python 3.8.5 on ubuntu 18.04
    4 projects | /r/ansible | 7 Jun 2021
    --- - name: Configure server. hosts: pyenv2 vars: python3_tmpdir: "~/python3" python3_command: python3 python3_bashrc: "{{ ansible_user_dir}}/.bash_profile" python3_local: "{{ ansible_user_dir}}/.local/bin" pre_tasks: - name: update apt become: yes apt: update_cache=yes cache_valid_time=7200 tasks: - name: Install requirements for package install become: yes package: name: - python3-pip - python3-virtualenv - python3-dev - virtualenv state: present - name: Install system packages required for pyenv become: yes package: name: - curl - gcc - git - libbz2-dev - libreadline-dev - libssl-dev - libsqlite3-dev - make - zlib1g-dev state: present - name: Install Python using pyenv environment: PATH: "{{ ansible_env.PATH }}:{{ ansible_user_dir }}/.pyenv/bin" block: - name: Create download directory file: path: "{{ python3_tmpdir }}" state: directory mode: 0700 changed_when: false # tmpdir role removes directory automatically - name: Download pyenv installer get_url: url: https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer dest: "{{ python3_tmpdir }}" changed_when: false # temporary directory is removed when play ends - name: Run pyenv installer command: "bash pyenv-installer" args: chdir: "{{ python3_tmpdir }}" creates: "{{ ansible_user_dir }}/.pyenv" - name: Update login file blockinfile: path: "{{ python3_bashrc }}" create: true block: | export PATH="{{ ansible_user_dir }}/.pyenv/bin:$PATH" eval "$(pyenv init -)" eval "$(pyenv virtualenv-init -)" mode: 0644 - name: Update pyenv command: pyenv update - name: Install Python block: - name: Install Python command: "pyenv install 3.8.5" args: creates: "{{ ansible_user_dir }}/.pyenv/versions/3.8.5" - name: Execute pyenv rehash command: "pyenv rehash" - name: Define python3 command set_fact: # can't rely on changes to $PATH yet python3_command: "{{ ansible_user_dir }}/.pyenv/shims/{{ python3_command }}"
    4 projects | /r/ansible | 7 Jun 2021
    - name: Install requirements for package install become: true package: name: - python3-pip - python3-virtualenv - python3-dev - virtualenv state: present - name: Install system packages required for pyenv become: true package: name: - curl - gcc - git - libbz2-dev - libreadline-dev - libssl-dev - libsqlite3-dev - make - zlib1g-dev state: present - name: Install Python using pyenv environment: PATH: "{{ ansible_env.PATH }}:{{ ansible_user_dir }}/.pyenv/bin" block: - name: Create download directory file: path: "{{ python3_tmpdir }}" state: directory mode: 0600 changed_when: false # tmpdir role removes directory automatically - name: Install pyenv block: - name: Download pyenv installer get_url: url: https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer dest: "{{ python3_tmpdir }}" changed_when: false # temporary directory is removed when play ends - name: Run pyenv installer command: "bash pyenv-installer" args: chdir: "{{ python3_tmpdir }}" creates: "{{ ansible_user_dir }}/.pyenv" - name: Update login file blockinfile: path: "{{ python3_bashrc }}" create: true block: | export PATH="{{ ansible_user_dir }}/.pyenv/bin:$PATH" eval "$(pyenv init -)" eval "$(pyenv virtualenv-init -)" mode: 0644 - name: Update pyenv command: pyenv update - name: Install Python block: - name: Install Python command: "pyenv install 3.8.5" args: creates: "{{ ansible_user_dir }}/.pyenv/versions/3.8.5" - name: Execute pyenv rehash command: "pyenv rehash" - name: Define python3 command set_fact: # can't rely on changes to $PATH yet python3_command: "{{ ansible_user_dir }}/.pyenv/shims/{{ python3_command }}"
  • Upgrade to Python 3.8
    2 projects | /r/openSUSE | 1 May 2021
    Then, well just run the installer script provided by the devs: curl -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash Note: Always inspect the code of shell scripts before running them
  • Installing tensorflow with gpu makes me want to blow my brains out
    3 projects | /r/tensorflow | 28 Dec 2020
    I personally have been having a lot of fun with pyenv these days which allows you to set a different python version to any given folder auto-magically, just by being in it. Of course from there you're using pip.

yapf

Posts with mentions or reviews of yapf. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-03-18.
  • Enhance Your Project Quality with These Top Python Libraries
    16 projects | dev.to | 18 Mar 2024
    YAPF (Yet Another Python Formatter): YAPF takes a different approach in that it’s based off of ‘clang-format’, a popular formatter for C++ code. YAPF reformats Python code so that it conforms to the style guide and looks good.
  • Why is Prettier rock solid?
    13 projects | news.ycombinator.com | 19 Feb 2024
    I think I agree about the testing and labor of complicated translation rules.

    But it doesn't appear that almost every pretty printer uses the Wadler pretty printing paper. It seems like MOST of them don't?

    e.g. clang-format is one of the biggest and best, and it has a model that includes "unwrapped lines", a "layouter", a line break cost function, exhaustive search with memoization, and Dijikstra's algorithm:

    https://llvm.org/devmtg/2013-04/jasper-slides.pdf

    The YAPF Python formatter is based on this same algorithm - https://github.com/google/yapf

    The Dart formatter used a model of "chunks, rules, and spans"

    https://journal.stuffwithstuff.com/2015/09/08/the-hardest-pr...

    It almost seems like there are 2 camps -- the functional algorithms for functional/expression-based languages, and other algorithms for more statement-based languages.

    Though I guess Prettier/JavaScript falls on the functional side.

    I just ran across this survey on lobste.rs and it seems to cover the functional pretty printing languages influenced by Wadler, but functional style, but not the other kind of formatter ("Google" formatters perhaps)

    https://arxiv.org/pdf/2310.01530.pdf

  • A Tale of Two Kitchens - Hypermodernizing Your Python Code Base
    31 projects | dev.to | 12 Nov 2023
    To get all your code into a consistent format the next step is to run a formatter. I recommend black, the well-known uncompromising code formatter, which is the most popular choice. Alternatives to black are autoflake, prettier and yapf, if you do not agree with blacks constraints.
  • Front page news headline scraping data engineering project
    3 projects | /r/dataengineering | 13 May 2023
    Use yapf to format code -> https://github.com/google/yapf
  • Not sure if this is the worst or most genius indentation I've seen
    4 projects | /r/ProgrammerHumor | 6 Mar 2023
    https://github.com/google/yapf has configs, do ctrl+f SPLIT_COMPLEX_COMPREHENSION in the readme
  • Google Python Style Guide
    6 projects | news.ycombinator.com | 11 Feb 2023
  • Enable hyphenation only for code blocks
    2 projects | /r/LaTeX | 6 Jan 2023
    Only as recommendation: If the lines of the source code (here: you C code you aim to document) are kept short, in manageable bytes (similar to entries parser.add_argument in Clark's "Tiny Python Projects", example seldomly pass beyond the frequently recommended threshold of 80 characters/line), reporting with listings becomes easier (equally, the reading of the difference logs/views by git and vimdiff), than with lines of say 120 characters per line. Though we no longer are constrained to 80 characters per line by terminals/screens and punch cards (when Fortran still was FORTRAN), this is a reason e.g., yapf for Python allows you to choose between 4 spaces/indentation (PEP8 style), or 2 spaces/indentation (Google style).
  • Which code formatter do you use?
    3 projects | /r/Python | 21 Dec 2022
    YAPF. Black would have been fine too but I absolutely need tabs, not spaces, and Black won't do that. (Why tabs? Because they make my proportional font work better.)
  • Automatically rearranging Python code?
    3 projects | /r/learnpython | 24 May 2022
  • From Python to Dart - Day 2, Meet the dart CLI
    7 projects | dev.to | 7 Mar 2022
    When working with several people on one project, it is very often necessary to use a single style of code design, writing comments, using variable names, etc. In the Python world, we use linters flake8, various formatters (black, yapf, autopep8) and mypy for type checking. How can Dart help meet these challenges?

What are some alternatives?

When comparing pyenv-installer and yapf you can also consider the following projects:

black - The uncompromising Python code formatter

isort - A Python utility / library to sort imports.

flake8

autopep8 - A tool that automatically formats Python code to conform to the PEP 8 style guide.

awesome-python-typing - Collection of awesome Python types, stubs, plugins, and tools to work with them.

pyright - Static Type Checker for Python

pyenv - Simple Python version management

vim-sleuth - sleuth.vim: Heuristically set buffer options

pycodestyle - Simple Python style checker in one Python file

prettier - Prettier is an opinionated code formatter.

yolov4-deepsort - Object tracking implemented with YOLOv4, DeepSort, and TensorFlow.