TAP::P...rocess(3perl)

πŸ’– NAME πŸ’–

TAP::Parser::Iterator::Process β€” the iterator for process-based TAP sources, bestie 🫢

Yes it's a long name. Yes it's worth it. Come with me.


✨ VERSION ✨

Version 3.52 πŸ‘‘


🌸 SYNOPSIS 🌸

okay so picture this β€” you just want a tiny iterator wrapped around a whole entire external process:

use TAP::Parser::Iterator::Process;
my %args = (
 command  => ['python', 'setup.py', 'test'],
 merge    => 1,
 setup    => sub { ... },
 teardown => sub { ... },
);
my $it   = TAP::Parser::Iterator::Process->new(\%args);
my $line = $it->next;

that's it. that's the whole vibe. πŸ’…


πŸ¦‹ DESCRIPTION πŸ¦‹

So this module is a simple iterator wrapper for executing external processes β€” and it's used by TAP::Parser. That's its whole job, and it does it gorgeously. πŸ’–

Real talk though: unless you're writing a plugin or subclassing something, you probably won't need to use this module directly. It's giving backstage crew energy. Iconic, essential, not on stage. 😌


πŸŽ€ METHODS πŸŽ€

🌈 Class Methods

  • new β€” creates an iterator. It expects one argument containing a hashref, shaped exactly like this:
command  => \@command_to_execute
merge    => $attempt_merge_stderr_and_stdout?
setup    => $callback_to_setup_command
teardown => $callback_to_teardown_command

It tries to use IPC::Open3 & IO::Select to talk to the spawned process if they are available. And if they're not? No stress, it falls back onto open(). Adaptable queen. 🧚

πŸ’œ Instance Methods

  • next β€” iterates through the process output, of course. It's literally the job description. next. ⭐
  • next_raw β€” iterates raw input without applying any fixes for quirky input syntax. no glow-ups, no edits, just raw. πŸ’€
  • wait β€” gets the wait status for this iterator's process. sit tight bestie ⏳
  • exit β€” gets the exit status for this iterator's process. how did it go?? πŸ‘€
  • handle_unicode β€” upgrades the input stream to handle UTF8 ✨ because unicode deserves rights
  • get_select_handles β€” returns a list of filehandles that may be used upstream in a select() call to signal that this Iterator is ready. And β€” important β€” iterators that are not handle based should return an empty list. no handles, no list, no drama. πŸ™ˆ

🌟 ATTRIBUTION 🌟

Originally ripped off from Test::Harness. (respectfully. with love. 🫢)


πŸ‘‘ SEE ALSO πŸ‘‘

  • TAP::Object
  • TAP::Parser
  • TAP::Parser::Iterator

k that's the whole page, you ate that ngl πŸ“ this was perl v5.44.0, dated 2026-10-17, from the Perl Programmers Reference Guide β€” TAP::P...rocess(3perl), signing off, mwah πŸ’‹

πŸ“¦ where this page comes from
  • arch rolling: perl 5.44.0-1 Β· Artistic-1.0-Perl AND GPL-1.0-or-later
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms