diff --git a/DEPRECATED.md b/DEPRECATED.md index 772b428c0..c4064cc76 100644 --- a/DEPRECATED.md +++ b/DEPRECATED.md @@ -4,6 +4,12 @@ These features are deprecated, which means they are no longer maintained and will go away in a future major version of Augur. They are currently still available for backwards compatibility, but should not be used in new code. +## `augur filter --metadata-chunk-size` + +*Deprecated in version X.X.X. Planned for removal in September 2024 or after.* + +FIXME: add description here + ## `augur parse` preference of `name` over `strain` as the sequence ID field *Deprecated in February 2024. Planned to be reordered June 2024 or after.* diff --git a/augur/filter/__init__.py b/augur/filter/__init__.py index 190465dbe..f3cbc674b 100644 --- a/augur/filter/__init__.py +++ b/augur/filter/__init__.py @@ -18,7 +18,7 @@ def register_arguments(parser): input_group.add_argument('--metadata', required=True, metavar="FILE", help="sequence metadata") input_group.add_argument('--sequences', '-s', help="sequences in FASTA or VCF format") input_group.add_argument('--sequence-index', help="sequence composition report generated by augur index. If not provided, an index will be created on the fly.") - input_group.add_argument('--metadata-chunk-size', type=int, default=100000, help="maximum number of metadata records to read into memory at a time. Increasing this number can speed up filtering at the cost of more memory used.") + input_group.add_argument('--metadata-chunk-size', help="[DEPRECATED] Previously used to specify maximum number of metadata records to read into memory at a time. This no longer has an effect.") input_group.add_argument('--metadata-id-columns', default=DEFAULT_ID_COLUMNS, nargs="+", help="names of possible metadata columns containing identifier information, ordered by priority. Only one ID column will be inferred.") input_group.add_argument('--metadata-delimiters', default=DEFAULT_DELIMITERS, nargs="+", help="delimiters to accept when reading a metadata file. Only one delimiter will be inferred.") diff --git a/augur/filter/validate_arguments.py b/augur/filter/validate_arguments.py index 866989303..08806f66d 100644 --- a/augur/filter/validate_arguments.py +++ b/augur/filter/validate_arguments.py @@ -1,4 +1,5 @@ from augur.errors import AugurError +from augur.io.print import print_err from augur.io.vcf import is_vcf as filename_is_vcf @@ -16,6 +17,9 @@ def validate_arguments(args): args : argparse.Namespace Parsed arguments from argparse """ + if args.metadata_chunk_size: + print_err("WARNING: --metadata-chunk-size is no longer necessary and will be removed in a future version.") + # Don't allow sequence output when no sequence input is provided. if args.output and not args.sequences: raise AugurError("You need to provide sequences to output sequences.")