Hi all,
I’ve been having issues with ProductSet-Reader and was lead down a rabbit-hole by claude. I’ve seen mention of similar issues from almost 10 years ago here but nothing seems to help.
The issue: ProductSet-Reader reports success (logs done., no warnings or errors at the node itself) but doesn’t actually hand off a usable source product to whatever comes next in the graph. Every downstream operator I’ve tried fails with the same error:
org.esa.snap.core.gpf.OperatorException: Operator '<OpName>': Mandatory source product (field 'sourceProduct') not set.
I’ve confirmed this is not specific to any one downstream operator — I tested Write, Subset, and TOPSAR-Split directly after ProductSet-Reader in turn, and all three fail identically. So it seems to be something in how ProductSet-Reader itself hands off its output within the graph, rather than anything about the operator that follows it.
Minimal repro:
xml
<graph id="Graph">
<version>1.0</version>
<node id="ProductSet-Reader">
<operator>ProductSet-Reader</operator>
<parameters class="com.bc.ceres.binding.dom.XppDomElement">
<fileList>/path/to/your_file.zip</fileList>
</parameters>
</node>
<node id="Subset">
<operator>Subset</operator>
<sources>
<sourceProduct refid="ProductSet-Reader"/>
</sources>
<parameters class="com.bc.ceres.binding.dom.XppDomElement">
</parameters>
</node>
<node id="Write">
<operator>Write</operator>
<sources>
<sourceProduct refid="Subset"/>
</sources>
<parameters class="com.bc.ceres.binding.dom.XppDomElement">
<file>/tmp/test_output</file>
<formatName>BEAM-DIMAP</formatName>
</parameters>
</node>
</graph>
Run with gpt graph.xml -e, and it fails at the Subset node with the “Mandatory source product not set” error, even though ProductSet-Reader logged as complete just before it.
What I’ve ruled out:
-
File path issues (tested with symlinks and direct paths)
-
fileListformatting (tested plain string and comma-separated, per the schema fromgpt ProductSet-Reader -h) -
<sources/>presence/absence on the reader node -
SNAP version — reproduces identically on SNAP 12.0.0 and SNAP 13.0.0
-
GUI vs CLI — reproduces in both the Graph Builder and via
gpt -
Operator-specific quirks — same failure with
Write,Subset, andTOPSAR-Split
Also worth noting: while cross-checking with a different product type (Sentinel-2), ProductSet-Reader in the GUI Graph Builder froze entirely rather than erroring — possibly a related instability in the same operator, though a different symptom.
Why I’m posting this here: I found two older threads describing what looks like the exact same problem:
-
https://forum.step.esa.int/t/cannot-use-product-set-reader-in-graph-builder/1529 (2016)
-
https://forum.step.esa.int/t/gpt-error-productset-reader-please-add-a-source-product/11305 (2018, reproduced independently across SNAP 5.0.0, 6.0.0, and 6.0.4)
Using Read instead of ProductSet-Reader for a single-file works fine but it’s not really a solution I’m happy with.
Maybe I’ve missed something when going through the forum so apologies if that’s the case.
Thanks!