edf2csv 0.7.83 → 0.7.84

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.js CHANGED
@@ -18,7 +18,7 @@ import process from 'node:process';
18
18
  import { EdfError } from './edf/errors.js';
19
19
  import { EdfFile } from './edf/reader.js';
20
20
  import { buildPlan, withoutFileRateWarning } from './convert/plan.js';
21
- import { ConversionError, USAGE_ERROR_CODES, auditStdout, convert, defaultOutputDir, durationDiagnostics, requestedAnnotationWindow, stdoutRefusal, } from './convert/run.js';
21
+ import { ConversionError, USAGE_ERROR_CODES, auditStdout, convert, defaultOutputDir, durationDiagnostics, requestedAnnotationWindow, noSignalFile, stdoutRefusal, } from './convert/run.js';
22
22
  import { ChannelSelectionError } from './convert/channels.js';
23
23
  // Shared with the library so a bad option is the same error whichever way it arrived.
24
24
  import { OptionError } from './convert/options.js';
@@ -867,6 +867,19 @@ async function showInfo(input, shared, asJson, jsonIndent, batch = false, toStdo
867
867
  from: plan.range.startSeconds,
868
868
  to: plan.range.endSeconds,
869
869
  }));
870
+ /*
871
+ And the warning about the signal file this conversion would not write.
872
+
873
+ `--info` prints one accurate line about it in the report body — "Would write
874
+ channels.csv and no signal data" — and raised nothing, so the one mode whose purpose is
875
+ to say what a conversion will do carried a shorter warning list than the conversion did.
876
+ `--info --strict` is documented as a cheap way to screen a directory before converting
877
+ it, and on a recording of nothing but annotations it reported one warning where the
878
+ conversion reports two.
879
+ */
880
+ const missing = noSignalFile(file, plan);
881
+ if (missing)
882
+ plan.diagnostics.push(missing);
870
883
  if (toStdout) {
871
884
  const refusal = stdoutRefusal(file, plan);
872
885
  if (refusal) {