.split()
output seems not recognised by .transpose()
#4074
Replies: 3 comments 1 reply
-
Of note, adding ch2 = Channel.of(["D", "E_F"])
ch2.map({it -> [it[0], it[1].split("_").toList()]}).transpose().view() yields N E X T F L O W ~ version 23.04.1
Launching `transpose-test.nf` [insane_mirzakhani] DSL2 - revision: 28f818061d
[D, E]
[D, F] |
Beta Was this translation helpful? Give feedback.
-
This is not a bug, as you probably noticed with your second comment. The ch1 = Channel.of(["A", ["B", "C"]])
ch1.map { println it[1].getClass() }
ch2 = Channel.of(["D", "E_F"])
ch2.map { it -> [it[0], it[1].split("_")] }.map { println it[1].getClass() } The output of the snippet above is: N E X T F L O W ~ version 23.06.0-edge
Launching `foo.nf` [agitated_hilbert] DSL2 - revision: d5e6b1ed25
class java.util.ArrayList
class [Ljava.lang.String; If you apply a |
Beta Was this translation helpful? Give feedback.
-
Hi @ktpolanski , the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Bug report
Expected behavior and actual behavior
Performing a
.map()
which includes a.split()
on one of theit
components seems to create a form of data that does not get picked up and expanded by a subsequent.transpose()
.Steps to reproduce the problem
Program output
Environment
GNU bash, version 4.4.20(1)-release (x86_64-pc-linux-gnu)
Beta Was this translation helpful? Give feedback.
All reactions