Stub-only package containing type information for pydub
Project description
pydub-stubs
Pydub version: 0.24.1
pydub-stubs
provides type information for Pydub.
Only the public interface is guaranteed to be typed.
pip install pydub-stubs
Aniticipated Questions
Q: Why is AudioSegment.some_effect(...)
missing?
TL;DR: Import it as a function from pydub.effects
.
Pydub dynamically adds certain functions to AudioSegment
at runtime.
This is easy to type, but impossible to be 100% safe about.
A great example of why this can is difficult is pydub.scipy_effects
,
which registers two effects that are named identically to those in
pydub.effects
, but have different signatures. Importing this module
will override the previous effects, so now the signatures are wrong.
Q: What's that version number?
major.minor.patch.stubs
, where major/minor/patch are the latest
supported Pydub version. The stubs version being last means pinning
to a specific Pydub version will always get the latest stubs available.
Q: What is Metadata
and PartialMetadata
?
These are dictionaries that were originally used when creating an
AudioSegment. Metadata
and PartialMetadata
do not exist at runtime.
Using these is no longer recommended, but they're still supported and
used internally. You can use the channels
, frame_rate
, and
sample_rate
keyword arguments.
Changelog
Version 0.24.1.7
-
Add
AudioSegment._spawn
(again)
This was accidentally removed in an earlier version. -
Improve
pydub.effects.invert_phase
This is technically less accurate as(0, 0)
is equivalent to(0, 1)
.
Previous versions
Version 0.24.1.6
- Remove testing symbols from
pydub.audio_segment
Version 0.24.1.5
- Fix
AudioSegment.export
First param is namedout_f
and isn't required.
Version 0.24.1.4
-
Improved signature of
AudioSegment.from_file
The keyword arguments for raw/PCM audio don't requireformat
to be set to eitherraw
orpcm
. -
Fix package exports
ExportsAudioSegment
from__init__.py
.
Version 0.24.1.3
- Fixed overloads of
AudioSegment.fade
Exactly two ofstart
,end
, andduration
must be given.
Version 0.24.1.2
-
Improved
AudioSegment.fade
Changed to use overloads to prevent invalid method calls. -
Improved
AudioSegment.from_mono_audiosegments
Use a positional-only parameter to ensure there's at least 1 argument.
Version 0.24.1.1
-
Fixed
AudioSegment.__init__
Use overloads to model correct parameters. -
Fixed
AudioSegment._spawn
Parameteroverrides
accepts a partial dictionary. -
Fixed
pydub.scipy_effects.high_pass_filter
Parameterorder
should beint
, notfloat
.
Version 0.24.1.0
Released
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for pydub_stubs-0.24.1.7-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8a91f9e218e89d97e8d156690dfae07d06740fb4cc6326e2d1f66600f39ec1a0 |
|
MD5 | ddf303eaa30f82e932eacc24c0b214f8 |
|
BLAKE2b-256 | d7d2c06405dc1e4914aa5eebbbc76dd54cf676f93324355d4f6529845c282b7b |