TraktorBuddy


NameTraktorBuddy JSON
Version 1.3.0 PyPI version JSON
download
home_pageNone
SummaryA helping hand for managing Traktor collections.
upload_time2024-08-18 16:50:18
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseNone
keywords dj traktor
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Traktor Buddy

[![GPL-v3.0](https://img.shields.io/badge/license-GPL--3.0-orange)](https://spdx.org/licenses/GPL-3.0-or-later.html) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/TraktorBuddy.svg)](https://python.org) [![PyPI - Version](https://img.shields.io/pypi/v/TraktorBuddy.svg)](https://pypi.org/project/TraktorBuddy)

A helping hand for managing **Traktor** collections.

### Installation

**Traktor Buddy** is a pure Python project. It requires at least [Python](https://python.org) 3.8.

You can install **Traktor Buddy** by typing the following in a terminal window:

```console
pip install TraktorBuddy
```

### Usage from the command line

**Traktor Buddy** supports various commands, sometimes with one or more extra arguments:

```console
tktbud <options> command <arguments> <path>
```

The following commands are supported:

```console
help <topic>       - Show a help message. topic is optional (use 'help topics' for a list).
version            - Print the current version.
tag <arguments>    - Add or remove tags (use 'help tag' for a list of arguments).
fix <arguments>    - Fix various things (use 'help fix' for a list of arguments).
purge              - Purge all collection backups apart from the most recent one.
listen             - Listen to tracks playing on Traktor and print info about them.
```

The following options are supported:

```console
--test/-t          - Run in test mode. Affected tracks are printed out. No changes are saved.
--debug/-d         - Enable extra debugging information.
--verbose/-c       - Enable verbose mode.
--only=filter      - Only apply commands to some type of tracks.
```

If `path` is provided then the action is only applied to the track contained in the Playlist/Folder at that path. Paths are `/` separated, i.e. `'/Folder1/Folder2/Playlist'`. Use `'\ '` for spaces. If no `path` is provided then then action is applied to **ALL** tracks in the collection.

### Always keep backups

**Traktor Buddy** creates a backup of your collection in the `Backup` folder of **Traktor** before modifying anything but it's best to have your own too just in case. Make sure to backup the entire **Traktor** folder, i.e. ` ~/Documents/Native Instruments/Traktor 3.11.1` on macOS for example.

Also, it's a good idea to run commands with the `-t` option first (which means test mode) to make sure you understand how many tracks are affected/modified (you can use verbose mode to print track information). Finally, it's also a good idea to test your command on a small playlist of tracks first before applying it to your entire collection.

### Tagging

Tags are words used to add custom properties or information to tracks. They can then be used to sort tracks more efficiently in smart playlists.

Tags are either single word, which describe a on/off type of value, or can use a `name:value` format which allows for sorting tracks based on a given value.

Most people will use playlists for sorting tracks in their collections but doing this requires manual upkeep. If you wanted to automatically sort your tracks based on, for example, the spot at which those tracks work in your set, you could add tags like `settime:early`,  `settime:late`, etc.. and create smart playlists in **Traktor** that automatically filter for `Comments2 contains settime:early`.

Another example is, since **Traktor** doesn't let you create smart playlists based on Playlist membership, you can tag all the tracks in a playlist and then create smart playlists to filter tracks that are in a given playlist and other criterias.

The possibilities are endless.

Tags are added to the `comments2` field in **Traktor**'s database. If you already have information in these fields it will not be deleted but the tag will be appended to it. If you delete a tag, it may also delete information that happens to use the same word. Be careful.

Most tagging commands are self-explanatory, allowing you to `add`, `delete` or `rename` a tag.

One slightly more obscure command is `tag years` which will automatically create a `Year` tag for all tracks that have a release date available. For example if a track was released on 3/5/2015 then the tag `Year:2015` will be added to the track if it's not already present.

This allows you to then easily sort tracks by year in smart playlists.

You can add the `--only` option to target only a certain type of tracks. `--only=tracks` will apply the tag only to regular tracks and not stem files while --only=stems` will apply the tag only to stem files.

### Fix commands

These commands can be used to fix things in your **Traktor** collection. Each command is very specific to one issue and only performs that one function.

##### fix labels

Some DJ software store record label information in the `grouping` field of the music file. If a track is missing its record label, this will look for it in the `grouping` field of the music file and if found will update the record label for that track.

##### fix itunes

This removes any `ITUNES` elements in the track's information. This element was used by **Traktor** to sync your tracks with your local iTunes collection.

##### fix coverart

If a track has a covert art cache entry in its information which does not exists anymore in **Traktor**'s cover art cache, this removes the cache entry information and touches (i.e. updates the modification date) the track's music file to force **Traktor** to reload the coverart from the file.

You can then simply load the track on a deck or check your database consistency and cover art will be read again and updated from the music file.

##### fix covercache

Goes thru **Traktor**'s cover art cache and deletes any file that is no longer being used by your track collection.

### Usage as a module

You can use **Traktor Buddy** in your own **Python** scripts to read and modify **Traktor** collections.

```
import TraktorBuddy

collection = TraktorBuddy.Collection()

for track in collection.tracks():
    print(track.title())
```

The module exposes classes for **Collection**, **Folder**, **Playlist**, **Track** or **Listener** for example. Full documentation will come later but the source code for those classes should make their interface fairly obvious.

### Listening to Traktor

You can use the `listen` command or the `Listener` class in the module to get updates on each Track that **Traktor** is playing.

For this to work on **Traktor**'s end you need to configure the broadcasting panel in settings:

* Set proxy server to `none`.
* Set server path to `localhost`.
* Set the port to `8000`.
* Set the mount path to `/`.
* Leave the password empty.
* Select the lowest frequency and bitrate for format since we won't be using the audio.

Now start `tktbud` or your own app in listening mode and then turn **Traktor**'s broadcasting on in the audio recorder panel (the little antenna). If everything works correctly the blue broadcasting light should stay on and you are ready to receive updates.

**Traktor** sends a new track update when a track is marked as played. This length of time before this happen can be set via the `Play Count` setting in the transport section of the settings,

### License

**Traktor Buddy** is distributed under the terms of the [GPLv3.0](https://spdx.org/licenses/GPL-3.0-or-later.html) or later license.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "TraktorBuddy",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "dj, traktor",
    "author": null,
    "author_email": "Didier Malenfant <didier@malenfant.net>",
    "download_url": "https://files.pythonhosted.org/packages/36/74/ee6340e3c8154d8c13810e92d916f7b2a4b86f7d34c7cbb7ed09686f0221/traktorbuddy-1.3.0.tar.gz",
    "platform": null,
    "description": "# Traktor Buddy\n\n[![GPL-v3.0](https://img.shields.io/badge/license-GPL--3.0-orange)](https://spdx.org/licenses/GPL-3.0-or-later.html) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/TraktorBuddy.svg)](https://python.org) [![PyPI - Version](https://img.shields.io/pypi/v/TraktorBuddy.svg)](https://pypi.org/project/TraktorBuddy)\n\nA helping hand for managing **Traktor** collections.\n\n### Installation\n\n**Traktor Buddy** is a pure Python project. It requires at least [Python](https://python.org) 3.8.\n\nYou can install **Traktor Buddy** by typing the following in a terminal window:\n\n```console\npip install TraktorBuddy\n```\n\n### Usage from the command line\n\n**Traktor Buddy** supports various commands, sometimes with one or more extra arguments:\n\n```console\ntktbud <options> command <arguments> <path>\n```\n\nThe following commands are supported:\n\n```console\nhelp <topic>       - Show a help message. topic is optional (use 'help topics' for a list).\nversion            - Print the current version.\ntag <arguments>    - Add or remove tags (use 'help tag' for a list of arguments).\nfix <arguments>    - Fix various things (use 'help fix' for a list of arguments).\npurge              - Purge all collection backups apart from the most recent one.\nlisten             - Listen to tracks playing on Traktor and print info about them.\n```\n\nThe following options are supported:\n\n```console\n--test/-t          - Run in test mode. Affected tracks are printed out. No changes are saved.\n--debug/-d         - Enable extra debugging information.\n--verbose/-c       - Enable verbose mode.\n--only=filter      - Only apply commands to some type of tracks.\n```\n\nIf `path` is provided then the action is only applied to the track contained in the Playlist/Folder at that path. Paths are `/` separated, i.e. `'/Folder1/Folder2/Playlist'`. Use `'\\ '` for spaces. If no `path` is provided then then action is applied to **ALL** tracks in the collection.\n\n### Always keep backups\n\n**Traktor Buddy** creates a backup of your collection in the `Backup` folder of **Traktor** before modifying anything but it's best to have your own too just in case. Make sure to backup the entire **Traktor** folder, i.e. ` ~/Documents/Native Instruments/Traktor 3.11.1` on macOS for example.\n\nAlso, it's a good idea to run commands with the `-t` option first (which means test mode) to make sure you understand how many tracks are affected/modified (you can use verbose mode to print track information). Finally, it's also a good idea to test your command on a small playlist of tracks first before applying it to your entire collection.\n\n### Tagging\n\nTags are words used to add custom properties or information to tracks. They can then be used to sort tracks more efficiently in smart playlists.\n\nTags are either single word, which describe a on/off type of value, or can use a `name:value` format which allows for sorting tracks based on a given value.\n\nMost people will use playlists for sorting tracks in their collections but doing this requires manual upkeep. If you wanted to automatically sort your tracks based on, for example, the spot at which those tracks work in your set, you could add tags like `settime:early`,  `settime:late`, etc.. and create smart playlists in **Traktor** that automatically filter for `Comments2 contains settime:early`.\n\nAnother example is, since **Traktor** doesn't let you create smart playlists based on Playlist membership, you can tag all the tracks in a playlist and then create smart playlists to filter tracks that are in a given playlist and other criterias.\n\nThe possibilities are endless.\n\nTags are added to the `comments2` field in **Traktor**'s database. If you already have information in these fields it will not be deleted but the tag will be appended to it. If you delete a tag, it may also delete information that happens to use the same word. Be careful.\n\nMost tagging commands are self-explanatory, allowing you to `add`, `delete` or `rename` a tag.\n\nOne slightly more obscure command is `tag years` which will automatically create a `Year` tag for all tracks that have a release date available. For example if a track was released on 3/5/2015 then the tag `Year:2015` will be added to the track if it's not already present.\n\nThis allows you to then easily sort tracks by year in smart playlists.\n\nYou can add the `--only` option to target only a certain type of tracks. `--only=tracks` will apply the tag only to regular tracks and not stem files while --only=stems` will apply the tag only to stem files.\n\n### Fix commands\n\nThese commands can be used to fix things in your **Traktor** collection. Each command is very specific to one issue and only performs that one function.\n\n##### fix labels\n\nSome DJ software store record label information in the `grouping` field of the music file. If a track is missing its record label, this will look for it in the `grouping` field of the music file and if found will update the record label for that track.\n\n##### fix itunes\n\nThis removes any `ITUNES` elements in the track's information. This element was used by **Traktor** to sync your tracks with your local iTunes collection.\n\n##### fix coverart\n\nIf a track has a covert art cache entry in its information which does not exists anymore in **Traktor**'s cover art cache, this removes the cache entry information and touches (i.e. updates the modification date) the track's music file to force **Traktor** to reload the coverart from the file.\n\nYou can then simply load the track on a deck or check your database consistency and cover art will be read again and updated from the music file.\n\n##### fix covercache\n\nGoes thru **Traktor**'s cover art cache and deletes any file that is no longer being used by your track collection.\n\n### Usage as a module\n\nYou can use **Traktor Buddy** in your own **Python** scripts to read and modify **Traktor** collections.\n\n```\nimport TraktorBuddy\n\ncollection = TraktorBuddy.Collection()\n\nfor track in collection.tracks():\n    print(track.title())\n```\n\nThe module exposes classes for **Collection**, **Folder**, **Playlist**, **Track** or **Listener** for example. Full documentation will come later but the source code for those classes should make their interface fairly obvious.\n\n### Listening to Traktor\n\nYou can use the `listen` command or the `Listener` class in the module to get updates on each Track that **Traktor** is playing.\n\nFor this to work on **Traktor**'s end you need to configure the broadcasting panel in settings:\n\n* Set proxy server to `none`.\n* Set server path to `localhost`.\n* Set the port to `8000`.\n* Set the mount path to `/`.\n* Leave the password empty.\n* Select the lowest frequency and bitrate for format since we won't be using the audio.\n\nNow start `tktbud` or your own app in listening mode and then turn **Traktor**'s broadcasting on in the audio recorder panel (the little antenna). If everything works correctly the blue broadcasting light should stay on and you are ready to receive updates.\n\n**Traktor** sends a new track update when a track is marked as played. This length of time before this happen can be set via the `Play Count` setting in the transport section of the settings,\n\n### License\n\n**Traktor Buddy** is distributed under the terms of the [GPLv3.0](https://spdx.org/licenses/GPL-3.0-or-later.html) or later license.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A helping hand for managing Traktor collections.",
    "version": "1.3.0",
    "project_urls": {
        "Bug Tracker": "https://codeberg.org/DidierMalenfant/TraktorBuddy/issues",
        "Source Code": "https://codeberg.org/DidierMalenfant/TraktorBuddy"
    },
    "split_keywords": [
        "dj",
        " traktor"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "5f94e79d0e6b75625d93f2338f0423f9538337d7f0d563cf43b210ce5d691301",
                "md5": "dcb9c8c40ac8af682177cb2e77bf15ea",
                "sha256": "96c88b247df9cae1441ad3263e790e0a97f6f14d021e81543fba64780e1a1a4d"
            },
            "downloads": -1,
            "filename": "traktorbuddy-1.3.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "dcb9c8c40ac8af682177cb2e77bf15ea",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 29745,
            "upload_time": "2024-08-18T16:50:20",
            "upload_time_iso_8601": "2024-08-18T16:50:20.747968Z",
            "url": "https://files.pythonhosted.org/packages/5f/94/e79d0e6b75625d93f2338f0423f9538337d7f0d563cf43b210ce5d691301/traktorbuddy-1.3.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "3674ee6340e3c8154d8c13810e92d916f7b2a4b86f7d34c7cbb7ed09686f0221",
                "md5": "ee7d9bcabb5993ff75a9c8a79aec0361",
                "sha256": "5dd2123bd31916eeedcfe20c2b32bf3eadf51f65ef38a2ef0108aff0ad35905a"
            },
            "downloads": -1,
            "filename": "traktorbuddy-1.3.0.tar.gz",
            "has_sig": false,
            "md5_digest": "ee7d9bcabb5993ff75a9c8a79aec0361",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 18141,
            "upload_time": "2024-08-18T16:50:18",
            "upload_time_iso_8601": "2024-08-18T16:50:18.707427Z",
            "url": "https://files.pythonhosted.org/packages/36/74/ee6340e3c8154d8c13810e92d916f7b2a4b86f7d34c7cbb7ed09686f0221/traktorbuddy-1.3.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-08-18 16:50:18",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": true,
    "codeberg_user": "DidierMalenfant",
    "codeberg_project": "TraktorBuddy",
    "lcname": "traktorbuddy"
}
        
Elapsed time: 0.50019s