All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
0.11.5 (2026-03-13)
- correctly format multiple if/elif blocks with Snakemake keywords [closes #239] (a3ecda2)
- correctly format run blocks with multiple comments [closes #196] (f6a0387)
- report warning line numbers based on formatted output [closes #241]. (b249a95)
0.11.4 (2026-02-09)
- handle interspersed comments (#193) and complex shell expressions (#129) (5db51bc)
- preserve comment indentation in run blocks (#267) (5fc754d)
0.11.3 (2026-01-22)
0.11.2 (2025-09-04)
- f-string conversion specifier spacing issue (db6427a)
0.11.1 (2025-08-31)
0.11.0 (2025-03-21)
- adapt to Snakemake 8 and 9 (add inputflags, outputflags, storage directive support, remove version and subworkflow directive support) (4709fcf)
- add support for inputflags and outputflags (dab68fa)
0.10.3 (2025-03-14)
0.10.2 (2024-05-08)
0.10.1 (2024-04-15)
- correctly find config file after updating min. black to v24.3 (0f20494)
- don't add spacing between consencutive braces in string [closes #222] (2d28922)
0.10.0 (2024-01-31)
- update to black v24 (cbc6e2f)
0.9.0 (2024-01-09)
- update black, which bumps min. req. python
- don't add space between string and comma [python3.12 f-string tokenize] (18e9874)
- don't remove double braces in f-strings in rule directives [closes #207] (8b47454)
- handle python3.12 f-string tokenization [closes #210] (b7e0e47)
- improve handling of indenting in shell directive [#186] (105e856)
- update black, which bumps min. req. python (022d6ab)
- correct version for next release (f28c08d)
0.8.5 (2023-10-04)
0.8.4 (2023-04-04)
0.8.3 (2023-03-15)
- handle decorators after snakecode (#185) (32d6c53)
- raise error on empty named param (#183) (b5aa660)
0.8.2 (2023-03-08)
- add .template to default excludes (610762f)
- dont raise NotAnIdentifier function (#179) (932df73)
- only show diff for changed files (7b35c16)
0.8.1 (2023-02-02)
- collate consecutive directives after if block [#172] (cbe88c7)
- comments causing indenting issues [#169] (#5) (e736235)
- indenation of line-wrapped code [#171] (#7) (f524574)
- updated
blackto version^23.1.0(5462512)
0.8.0 (2022-12-19)
- add support for resource_scopes directive (67fb11b)
- add support for resource_scopes directive (514192a)
- 159 (1423e6b)
- indentation issues from #124 (399ec55)
- relax importlib_metadata version pin [#162] (49b4f02)
- relax importlib_metadata version pin [#162] (ab91f9f)
0.7.0 (2022-11-08)
- add support for new exclude expressions in use rule statements (9f03019)
- do not align the inside of multiline strings [#123]] (bb4aabf)
- don't format r-strings [#123] (bcc5371)
- formatting of triple quoted strings [#152] (764e11d)
- line spacing after snakemake keyword (beca978)
0.6.1 (2022-06-13)
- Support for
retrieskeyword [#145] - thanks @maarten-k
- Keyword argument lambdas are now allowed inside rules [#135]
- Improve reported line number in Snakefile when black fails to parse [#127]
- Better handling of snakemake code inside nested if-else statements with comments at differing indentation levels [#126] - a HUGE thank you to @siebrenf for testing
0.6.0 (2022-03-03)
- Support for
template_enginekeyword. This requires bumping our minimum python version to 3.7 to allow for snakemake v7.
- Support for
prefixanddefault_targetkeywords [#131]
- Updated snakemake dependency to ^6.15.0
- Updated black dependency to stable version (v22.1.0). See the release changes for details of style changes. This also required updating click to v8.0.0.
- Fix edge case for keywords inside Python if/else (#115)
- No longer raise error if multiple keywords have the same name (e.g.
rule aused twice)
- Collapsing of multi-line strings does not cause syntax error now [#118]
- Version detection adapts to python version
- Single-quoted multi-line strings are now supported [#121]
- Missing
handoverrule keyword that was added insnakemakev6.2.0
- Upgraded minimum
blackversion to 21.7b0 [#116] (@jalaziz)
- Three parsing-related bugs:
- Add support for multiple anonymous rules, as per snakemake grammar ([#103][103])
- Newline bug in
usesyntax (#106)
- Support for module syntax:
modulekeyword anduse rulesyntax (#99) - Support for
containerizedkeyword
- Updated snakemake dependency to ^6.0.0 (#99)
- Support nested python code following python/snakemake nested code (#96)
Dockerfilehas been removed as the biocontainers images are smaller and some recent changes to thecryptographydependency require Rust to be installed (on Alpine) which further bloats our DockerHub image.
- Update click, toml and black (major version) to latest releases (@jlewis91) [#97]
- Remove use of a Python 3.8-only
loggingmodule feature (#89) - Update Python support to ^3.6.1 due to use of
typingmoduleNamedTuples - Better support for python/snakemake interspersed code (#91; #93)
- Documentation for integration with Visual Studio Code (#80; thanks @austinkeller)
- Issue warnings for comment-related formatting (#85)
- File-specific logging: warnings and errors during reformatting now automatically refer to the raising source file.
Better comment-related formatting (#85; thanks @dlaehnemann):
- PEP8 inline comment formatting: use 2 spaces
- Comments above keywords stay untouched
- Inline comments in inline-formatted keywords get relocated above keyword
pre-commithook integration (@jfear)
- Proper indentation of nested if/else python code mixed with snakemake keywords [#78]
- Vim plugin imports:
snakefmtandblackmodule imports raise distinct errors (@dcroote)
- Add a vim plugin to
snakefmt[#62] and instructions to use it - New searching for project configuration. Used to look for
pyproject.tomlin current working directory, now recursively search for it in directories of formatted file(s).
blackconfig was not being used if it did not contain[tool.snakefmt][#73]- better handling of
black.FileModeparams [#73]
- new
scattergatherdirective to the grammar [#74]
- repeated top-level, single-parameter keywords get placed on consecutive lines [#67]
- allow
--checkand--diffto be used together [#68]
- dedented comments were being tied to previous indented context in
rundirective [#61] - single version sourcing from pyproject.toml was failing on
pip installed distributions [#65]. Fixed by using importlib_metadata.
- Add parsing support for format and raw (f/r) triple-quoted strings [#59].
- Version was not correctly updated in 0.1.2.
This release will potentially produce different output to previous versions. Previously,
when passing code to black for formatting, we were not allowing for the indentation
level of the code. For example, if a line has an indentation level of two and the code
is 40 character long, the line is 48 characters long. However, we were only passing the
40 characters of code to black meaning, in the running example, if you had set
--line-length 45 the line would not have been formatted. This behaviour is now fixed.
- When passing code to
black, reduce the line length by the indentation level.
- f-strings with triple quotes are now correctly handled [#55]
- First release - so everything you see is new!