.. image:: https://img.shields.io/pypi/v/beets.svg
    :target: https://pypi.python.org/pypi/beets

.. image:: https://img.shields.io/codecov/c/github/beetbox/beets.svg
    :target: https://codecov.io/github/beetbox/beets

.. image:: https://github.com/beetbox/beets/workflows/ci/badge.svg?branch=master
    :target: https://github.com/beetbox/beets/actions

.. image:: https://repology.org/badge/tiny-repos/beets.svg
    :target: https://repology.org/project/beets/versions

beets
=====

Beets is the media library management system for obsessive music geeks.

The purpose of beets is to get your music collection right once and for all.
It catalogs your collection, automatically improving its metadata as it goes.
It then provides a bouquet of tools for manipulating and accessing your music.

Here's an example of beets' brainy tag corrector doing its thing::

  $ beet import ~/music/ladytron
  Tagging:
      Ladytron - Witching Hour
  (Similarity: 98.4%)
   * Last One Standing      -> The Last One Standing
   * Beauty                 -> Beauty*2
   * White Light Generation -> Whitelightgenerator
   * All the Way            -> All the Way...

Because beets is designed as a library, it can do almost anything you can
imagine for your music collection. Via `plugins`_, beets becomes a panacea:

- Fetch or calculate all the metadata you could possibly need: `album art`_,
  `lyrics`_, `genres`_, `tempos`_, `ReplayGain`_ levels, or `acoustic
  fingerprints`_.
- Get metadata from `MusicBrainz`_, `Discogs`_, and `Beatport`_. Or guess
  metadata using songs' filenames or their acoustic fingerprints.
- `Transcode audio`_ to any format you like.
- Check your library for `duplicate tracks and albums`_ or for `albums that
  are missing tracks`_.
- Clean up crufty tags left behind by other, less-awesome tools.
- Embed and extract album art from files' metadata.
- Browse your music library graphically through a Web browser and play it in any
  browser that supports `HTML5 Audio`_.
- Analyze music files' metadata from the command line.
- Listen to your library with a music player that speaks the `MPD`_ protocol
  and works with a staggering variety of interfaces.

If beets doesn't do what you want yet, `writing your own plugin`_ is
shockingly simple if you know a little Python.

.. _plugins: https://beets.readthedocs.org/page/plugins/
.. _MPD: https://www.musicpd.org/
.. _MusicBrainz music collection: https://musicbrainz.org/doc/Collections/
.. _writing your own plugin:
    https://beets.readthedocs.org/page/dev/plugins.html
.. _HTML5 Audio:
    https://html.spec.whatwg.org/multipage/media.html#the-audio-element
.. _albums that are missing tracks:
    https://beets.readthedocs.org/page/plugins/missing.html
.. _duplicate tracks and albums:
    https://beets.readthedocs.org/page/plugins/duplicates.html
.. _Transcode audio:
    https://beets.readthedocs.org/page/plugins/convert.html
.. _Discogs: https://www.discogs.com/
.. _acoustic fingerprints:
    https://beets.readthedocs.org/page/plugins/chroma.html
.. _ReplayGain: https://beets.readthedocs.org/page/plugins/replaygain.html
.. _tempos: https://beets.readthedocs.org/page/plugins/acousticbrainz.html
.. _genres: https://beets.readthedocs.org/page/plugins/lastgenre.html
.. _album art: https://beets.readthedocs.org/page/plugins/fetchart.html
.. _lyrics: https://beets.readthedocs.org/page/plugins/lyrics.html
.. _MusicBrainz: https://musicbrainz.org/
.. _Beatport: https://www.beatport.com

Install
-------

You can install beets by typing ``pip install beets`` or directly from Github (see details `here`_).
Beets has also been packaged in the `software repositories`_ of several
distributions. Check out the `Getting Started`_ guide for more information.

.. _here: https://beets.readthedocs.io/en/latest/faq.html#run-the-latest-source-version-of-beets
.. _Getting Started: https://beets.readthedocs.org/page/guides/main.html
.. _software repositories: https://repology.org/project/beets/versions

Contribute
----------

Thank you for considering contributing to ``beets``! Whether you're a
programmer or not, you should be able to find all the info you need at
`CONTRIBUTING.rst`_.

.. _CONTRIBUTING.rst: https://github.com/beetbox/beets/blob/master/CONTRIBUTING.rst

Read More
---------

Learn more about beets at `its Web site`_. Follow `@b33ts`_ on Mastodon for
news and updates.

.. _its Web site: https://beets.io/
.. _@b33ts: https://fosstodon.org/@beets

Contact
-------
* Encountered a bug you'd like to report? Check out our `issue tracker`_!
    * If your issue hasn't already been reported, please `open a new ticket`_
      and we'll be in touch with you shortly.
    * If you'd like to vote on a feature/bug, simply give a :+1: on issues
      you'd like to see prioritized over others.
* Need help/support, would like to start a discussion, have an idea for a new
  feature, or would just like to introduce yourself to the team? Check out
  `GitHub Discussions`_!

.. _GitHub Discussions: https://github.com/beetbox/beets/discussions
.. _issue tracker: https://github.com/beetbox/beets/issues
.. _open a new ticket: https://github.com/beetbox/beets/issues/new/choose

Authors
-------

Beets is by `Adrian Sampson`_ with a supporting cast of thousands.

.. _Adrian Sampson: https://www.cs.cornell.edu/~asampson/


.. image:: https://media.charlesleifer.com/blog/photos/peewee3-logo.png

peewee
======

Peewee is a simple and small ORM. It has few (but expressive) concepts, making it easy to learn and intuitive to use.

* a small, expressive ORM
* python 2.7+ and 3.4+
* supports sqlite, mysql, mariadb, postgresql and cockroachdb
* tons of `extensions <http://docs.peewee-orm.com/en/latest/peewee/playhouse.html>`_

New to peewee? These may help:

* `Quickstart <http://docs.peewee-orm.com/en/latest/peewee/quickstart.html#quickstart>`_
* `Example twitter app <http://docs.peewee-orm.com/en/latest/peewee/example.html>`_
* `Using peewee interactively <http://docs.peewee-orm.com/en/latest/peewee/interactive.html>`_
* `Models and fields <http://docs.peewee-orm.com/en/latest/peewee/models.html>`_
* `Querying <http://docs.peewee-orm.com/en/latest/peewee/querying.html>`_
* `Relationships and joins <http://docs.peewee-orm.com/en/latest/peewee/relationships.html>`_

Examples
--------

Defining models is similar to Django or SQLAlchemy:

.. code-block:: python

    from peewee import *
    import datetime

    db = SqliteDatabase('my_database.db')

    class BaseModel(Model):
        class Meta:
            database = db

    class User(BaseModel):
        username = CharField(unique=True)

    class Tweet(BaseModel):
        user = ForeignKeyField(User, backref='tweets')
        message = TextField()
        created_date = DateTimeField(default=datetime.datetime.now)
        is_published = BooleanField(default=True)

Connect to the database and create tables:

.. code-block:: python

    db.connect()
    db.create_tables([User, Tweet])

Create a few rows:

.. code-block:: python

    charlie = User.create(username='charlie')
    huey = User(username='huey')
    huey.save()

    # No need to set `is_published` or `created_date` since they
    # will just use the default values we specified.
    Tweet.create(user=charlie, message='My first tweet')

Queries are expressive and composable:

.. code-block:: python

    # A simple query selecting a user.
    User.get(User.username == 'charlie')

    # Get tweets created by one of several users.
    usernames = ['charlie', 'huey', 'mickey']
    users = User.select().where(User.username.in_(usernames))
    tweets = Tweet.select().where(Tweet.user.in_(users))

    # We could accomplish the same using a JOIN:
    tweets = (Tweet
              .select()
              .join(User)
              .where(User.username.in_(usernames)))

    # How many tweets were published today?
    tweets_today = (Tweet
                    .select()
                    .where(
                        (Tweet.created_date >= datetime.date.today()) &
                        (Tweet.is_published == True))
                    .count())

    # Paginate the user table and show me page 3 (users 41-60).
    User.select().order_by(User.username).paginate(3, 20)

    # Order users by the number of tweets they've created:
    tweet_ct = fn.Count(Tweet.id)
    users = (User
             .select(User, tweet_ct.alias('ct'))
             .join(Tweet, JOIN.LEFT_OUTER)
             .group_by(User)
             .order_by(tweet_ct.desc()))

    # Do an atomic update (for illustrative purposes only, imagine a simple
    # table for tracking a "count" associated with each URL). We don't want to
    # naively get the save in two separate steps since this is prone to race
    # conditions.
    Counter.update(count=Counter.count + 1).where(Counter.url == request.url)

Check out the `example twitter app <http://docs.peewee-orm.com/en/latest/peewee/example.html>`_.

Learning more
-------------

Check the `documentation <http://docs.peewee-orm.com/>`_ for more examples.

Specific question? Come hang out in the #peewee channel on irc.libera.chat, or post to the mailing list, http://groups.google.com/group/peewee-orm . If you would like to report a bug, `create a new issue <https://github.com/coleifer/peewee/issues/new>`_ on GitHub.

Still want more info?
---------------------

.. image:: https://media.charlesleifer.com/blog/photos/wat.jpg

I've written a number of blog posts about building applications and web-services with peewee (and usually Flask). If you'd like to see some real-life applications that use peewee, the following resources may be useful:

* `Building a note-taking app with Flask and Peewee <https://charlesleifer.com/blog/saturday-morning-hack-a-little-note-taking-app-with-flask/>`_ as well as `Part 2 <https://charlesleifer.com/blog/saturday-morning-hacks-revisiting-the-notes-app/>`_ and `Part 3 <https://charlesleifer.com/blog/saturday-morning-hacks-adding-full-text-search-to-the-flask-note-taking-app/>`_.
* `Analytics web service built with Flask and Peewee <https://charlesleifer.com/blog/saturday-morning-hacks-building-an-analytics-app-with-flask/>`_.
* `Personalized news digest (with a boolean query parser!) <https://charlesleifer.com/blog/saturday-morning-hack-personalized-news-digest-with-boolean-query-parser/>`_.
* `Structuring Flask apps with Peewee <https://charlesleifer.com/blog/structuring-flask-apps-a-how-to-for-those-coming-from-django/>`_.
* `Creating a lastpass clone with Flask and Peewee <https://charlesleifer.com/blog/creating-a-personal-password-manager/>`_.
* `Creating a bookmarking web-service that takes screenshots of your bookmarks <https://charlesleifer.com/blog/building-bookmarking-service-python-and-phantomjs/>`_.
* `Building a pastebin, wiki and a bookmarking service using Flask and Peewee <https://charlesleifer.com/blog/dont-sweat-small-stuff-use-flask-blueprints/>`_.
* `Encrypted databases with Python and SQLCipher <https://charlesleifer.com/blog/encrypted-sqlite-databases-with-python-and-sqlcipher/>`_.
* `Dear Diary: An Encrypted, Command-Line Diary with Peewee <https://charlesleifer.com/blog/dear-diary-an-encrypted-command-line-diary-with-python/>`_.
* `Query Tree Structures in SQLite using Peewee and the Transitive Closure Extension <https://charlesleifer.com/blog/querying-tree-structures-in-sqlite-using-python-and-the-transitive-closure-extension/>`_.


.. raw:: html

Introduction
=============

Pysheeet was created with intention of collecting python code snippets for
reducing coding hours and making life easier and faster. Any contributions are welcome.
Please feel free to fork and send a pull request to this project.

What’s New In Python 3
======================

This part only provides a quick glance at some important features in Python 3.
If you're interested in all of the most important features, please read the
official document, `What’s New in Python <https://docs.python.org/3/whatsnew/index.html>`_.

- `New in Python3 <docs/notes/python-new-py3.rst>`_

Cheat Sheet
===========

- `Code Style <docs/notes/python-code-style.rst>`_
- `From Scratch <docs/notes/python-basic.rst>`_
- `Future <docs/notes/python-future.rst>`_
- `Unicode <docs/notes/python-unicode.rst>`_
- `List <docs/notes/python-list.rst>`_
- `Set <docs/notes/python-set.rst>`_
- `Dictionary <docs/notes/python-dict.rst>`_
- `Heap <docs/notes/python-heap.rst>`_
- `Function <docs/notes/python-func.rst>`_
- `Class <docs/notes/python-object.rst>`_
- `Generator <docs/notes/python-generator.rst>`_
- `Typing <docs/notes/python-typing.rst>`_
- `Time <docs/notes/python-date.rst>`_
- `File <docs/notes/python-io.rst>`_
- `Operating System <docs/notes/python-os.rst>`_

Advanced Cheat Sheet
====================

- `Regular expression <docs/notes/python-rexp.rst>`_
- `Socket <docs/notes/python-socket.rst>`_
- `Asyncio <docs/notes/python-asyncio.rst>`_
- `Concurrency <docs/notes/python-concurrency.rst>`_
- `Sqlalchemy <docs/notes/python-sqlalchemy.rst>`_
- `Security <docs/notes/python-security.rst>`_
- `SSH <docs/notes/python-ssh.rst>`_
- `Tests <docs/notes/python-tests.rst>`_
- `C Extensions <docs/notes/python-c-extensions.rst>`_

Appendix
=========

- `Why does Decorator Need @wraps <docs/appendix/python-decorator.rst>`_
- `A Hitchhikers Guide to Asynchronous Programming <docs/appendix/python-concurrent.rst>`_
- `Asyncio behind the Scenes <docs/appendix/python-asyncio.rst>`_
- `PEP 572 and the walrus operator <docs/appendix/python-walrus.rst>`_
- `Python Interpreter in GNU Debugger <docs/appendix/python-gdb.rst>`_

PDF Version
============

`pdf`_

.. _pdf: https://media.readthedocs.org/pdf/pysheeet/latest/pysheeet.pdf

How to run the server
=======================

.. code-block:: bash

    $ virtualenv venv
    $ . venv/bin/activate
    $ pip install -r requirements.txt
    $ make
    $ python app.py

    # URL: localhost:5000


[![Logo](docs/img/Logo.png)](https://ajenti.org/)

Ajenti is a Linux & BSD modular server admin panel. Ajenti 2 provides a new interface and a better architecture, developed with [Python3](https://www.python.org/) and [AngularJS](https://angularjs.org/).

----

# Feature highlights

* **Easy installation** : Ajenti 2 can be easy installed [with pip and the provided script](https://docs.ajenti.org/en/latest/man/install.html#installing).

* **Existing configuration** : Picks up your current configuration and works on your existing system as-is, without any preparation.

* **Caring** : Does not overwrite your config files, options and comments. All changes are non-destructive.

* **Batteries included** : Includes lots of plugins for system and software configuration, monitoring and management.

* **Extensible** : Ajenti 2 is easily extensible using Python. Plugin development is a quick and pleasant with Ajenti APIs. [Write your first plugin](https://docs.ajenti.org/en/latest/dev/intro.html#your-first-plugin).

* **Modern** : Pleasant to look at, satisfying to click and accessible anywhere from tablets and mobile.

* **Lightweight** : Small memory footprint and CPU usage. Runs on low-end machines, wall plugs, routers and so on.

----

# Screenshots

See https://ajenti.org for more information

----

# Contributors ✨

Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):

Kientz Arnaud
💻

Dmitry Zamaruev
💻

Ivlev Denis
💻

Valentin Bryukhanov
💻

Konstantin Stepanov
💻

Alex Raeder
💻

Alexander Stefanov
💻

Markus M. May
💻

Artsiomi Silivonchyk
💻

Ilya Voronin
💻

Xéfir Destiny
💻

Martin Ellis
💻

Alex Kucherenko
💻

Luis Salazar
💻

Miguel Gonzalez
💻

Joseph Wang
💻

Pablo Albornoz
💻

Praveen Baratam
💻

Andreas Till
💻

Roman
💻

Prajjwal Nijhara
💻

Julian B
💻

Catriel Müller
💻

Kim
💻

Daniel Schulz
💻

dendilz
💻

This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!

# Contributing

Helpers are welcome ! There are many ways to help in Ajenti Project :

  * [Translations](https://docs.ajenti.org/en/latest/man/contributing.html)
  * [Plugin development](https://docs.ajenti.org/en/latest/dev/intro.html)
  * [Core development](https://docs.ajenti.org/en/latest/dev/intro-core.html)

## Roadmap

Actually big changes are planned and under development. A global roadmap is :

  * <s>Migrating to Python3
  * Migrating to [python-socketio](https://github.com/miguelgrinberg/python-socketio)
  * Implement better API REST with @get, @post ... decorators</s>
  * Migrating from AngularJS to Angular 13 (work in progress):
      * plugins core and dashboard are almost done, but there's a lot of work to migrate all other plugins.
      * This work take actually place in the branch [ajenti-3-dev](https://github.com/ajenti/ajenti/tree/ajenti-3-dev) and the new plugins are stored in the directory [plugins-new](https://github.com/ajenti/ajenti/tree/ajenti-3-dev/plugins-new)
      * The documentation is located at https://docs.ajenti.org/en/ajenti-3-dev/index.html
  * Add a lot of new plugins: once the migration to Angular done, we can add a lot of plugins to manage services on the server ( like apache2, nginx, postfix, etc ... ).
  * Migrating to [asyncio](https://docs.python.org/3/library/asyncio.html): concept tested, but migration not really started.


Welcome to Read the Docs
========================

|build-status| |docs| |coverage|

Purpose
-------

`Read the Docs`_ hosts documentation for the open source community.
It supports many documentation tools
(e.g. Sphinx_ docs written with reStructuredText_, MkDocs_ docs written with markdown_, among others),
and can pull Git_ repositories.
Then we build documentation and host it for you.
Think of it as *Continuous Documentation*, or Docs as Code.

.. _Read the docs: https://readthedocs.org/
.. _Sphinx: http://www.sphinx-doc.org/
.. _reStructuredText: http://www.sphinx-doc.org/en/master/usage/restructuredtext/basics.html
.. _Git: http://git-scm.com/
.. _MkDocs: https://www.mkdocs.org/
.. _markdown: https://daringfireball.net/projects/markdown/

Documentation for Read the Docs
-------------------------------

You will find complete documentation for setting up your project at `the Read the Docs site`_.

.. _the Read the Docs site: https://docs.readthedocs.io/

Get in touch
------------

You can find information about getting in touch with Read the Docs at our
`Contribution page <https://docs.readthedocs.io/en/latest/contribute.html#get-in-touch>`_.

Contributing
------------

You can find information about contributing to Read the Docs at our
`Contribution page <https://docs.readthedocs.io/en/latest/contribute.html>`_.

Quickstart for GitHub hosted projects
-------------------------------------

By the end of this quickstart, you will have a new project automatically updated when you push to GitHub.

#. Create an account on `Read the Docs`_ by signing up with GitHub.

#. When prompted on GitHub, give access to your account.

#. Log in and click on "Add project".

#. Start typing the name of your repository and select it from the list,
   and click "Continue".

#. Change any information if desired and click "Next".

#. All done.  Commit away and your project will auto-update.

.. |build-status| image:: https://circleci.com/gh/readthedocs/readthedocs.org.svg?style=svg
    :alt: build status
    :target: https://circleci.com/gh/readthedocs/readthedocs.org

.. |docs| image:: https://readthedocs.org/projects/docs/badge/?version=latest
    :alt: Documentation Status
    :scale: 100%
    :target: https://docs.readthedocs.io/en/latest/?badge=latest

.. |coverage| image:: https://codecov.io/gh/readthedocs/readthedocs.org/branch/main/graph/badge.svg
    :alt: Test coverage
    :scale: 100%
    :target: https://codecov.io/gh/readthedocs/readthedocs.org

License
-------

`MIT`_ © 2010 Read the Docs, Inc. & contributors

.. _MIT: LICENSE


# ClusterFuzz

[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/google/clusterfuzz/badge)](https://api.securityscorecards.dev/projects/github.com/google/clusterfuzz)

ClusterFuzz is a scalable [fuzzing](https://en.wikipedia.org/wiki/Fuzzing)
infrastructure that finds security and stability issues in software.

Google uses ClusterFuzz to fuzz all Google products and as the fuzzing
backend for [OSS-Fuzz].

ClusterFuzz provides many features which help seamlessly integrate fuzzing into
a software project's development process:
- Highly scalable. Can run on any size cluster (e.g. OSS-Fuzz instance runs on
  100,000 VMs).
- Accurate deduplication of crashes.
- Fully automatic bug filing, triage and closing for various issue trackers
  (e.g. [Monorail], [Jira]).
- Supports multiple [coverage guided fuzzing engines]
  ([libFuzzer], [AFL], [AFL++] and [Honggfuzz])
  for optimal results (with [ensemble fuzzing] and [fuzzing strategies]).
- Support for [blackbox fuzzing].
- Testcase minimization.
- Regression finding through [bisection].
- Statistics for analyzing fuzzer performance, and crash rates.
- Easy to use web interface for management and viewing crashes.
- Support for various authentication providers using [Firebase].

## Overview

## Documentation
You can find detailed documentation [here](https://google.github.io/clusterfuzz).

## Trophies
As of February 2023, ClusterFuzz has found ~27,000 bugs in Google (e.g. [Chrome]). Additionally, ClusterFuzz has helped identify and fix over [8,900] vulnerabilities and [28,000] bugs across [850] projects integrated with [OSS-Fuzz].

## Getting Help
You can [file an issue](https://github.com/google/clusterfuzz/issues/new) to ask
questions, request features, or ask for help.

## Staying Up to Date
We will use [clusterfuzz-announce(#)googlegroups.com](https://groups.google.com/forum/#!forum/clusterfuzz-announce) to make announcements about ClusterFuzz.

## ClusterFuzzLite
For a more lightweight version of ClusterFuzz that runs on CI/CD
systems, check out [ClusterFuzzLite](http://github.com/google/clusterfuzzlite).

[Chrome]: https://bugs.chromium.org/p/chromium/issues/list?can=1&q=label%3AClusterFuzz+-status%3AWontFix%2CDuplicate
[8,900]: https://bugs.chromium.org/p/oss-fuzz/issues/list?q=status%3AFixed%2CVerified%20Type%3DBug-Security&can=1
[28,000]: https://bugs.chromium.org/p/oss-fuzz/issues/list?q=status%3AFixed%2CVerified%20Type%3DBug&can=1
[850]: https://github.com/google/oss-fuzz/tree/master/projects
[OSS-Fuzz]: https://github.com/google/oss-fuzz
[Monorail]: https://opensource.google.com/projects/monorail
[Jira]: https://www.atlassian.com/software/jira
[bisection]: https://en.wikipedia.org/wiki/Bisection_(software_engineering)
[Firebase]: https://firebase.google.com/docs/auth
[libFuzzer]: http://llvm.org/docs/LibFuzzer.html
[AFL]: https://github.com/google/AFL
[AFL++]: https://github.com/AFLplusplus/AFLplusplus
[Honggfuzz]: https://github.com/google/honggfuzz
[blackbox fuzzing]: https://google.github.io/clusterfuzz/setting-up-fuzzing/blackbox-fuzzing/
[coverage guided fuzzing engines]: https://google.github.io/clusterfuzz/setting-up-fuzzing/libfuzzer-and-afl/
[fuzzing strategies]: https://i.blackhat.com/eu-19/Wednesday/eu-19-Arya-ClusterFuzz-Fuzzing-At-Google-Scale.pdf#page=27
[ensemble fuzzing]: https://www.usenix.org/system/files/sec19-chen-yuanliang.pdf