Project

Profile

Help

Bug #2836

closed

No transmission filter available for xsl:copy-of

Added by Michael Kay about 8 years ago. Updated about 7 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Streaming
Sprint/Milestone:
-
Start date:
2016-07-12
Due date:
% Done:

100%

Estimated time:
Legacy ID:
Applies to branch:
9.7, trunk
Fix Committed on Branch:
9.7, trunk
Fixed in Maintenance Release:
Platforms:

Description

See https://saxonica.plan.io/boards/3/topics/6475

Added to W3C test suite as si-copy-of-801

Actions #1

Updated by Michael Kay about 8 years ago

This seems similar to problems we've seen before. The apply-templates select expression is a FilterExpression, and the streaming adjunct for a FilterExpression is an instance of TransmissionAdjunct. The ApplyTemplatesAdjunct therefore expects the ItemFeed for the expression to be a TransmissionFlow, but this is not the case here because the selected nodes have been grounded by calling copy-of.

In the case of a LetExpression we solved this by having two different Adjunct classes depending on whether the nodes were grounded or not. But I've always felt that was a rather ad-hoc solution and the problem was more general.

In the case of ForEachAdjunct, IterateAdjunct, and ForEachGroupAdjunct, the getWatchMaker() method does this:

    // If the select expression is grounded (but consuming), return null; so we end up with a Feed rather than a Watch.

    if (select.getPosture() == Posture.GROUNDED) {

        return null;

    }

but this is missing from ApplyTemplatesAdjunct. I'll give it a try.

Actions #2

Updated by Michael Kay about 8 years ago

The above change turned out to be necessary but not sufficient.

The code for handling apply-templates with a grounded (but consuming) selection isn't currently handling xsl:with-param, so this needed to be fixed as well.

Actions #3

Updated by Michael Kay about 8 years ago

  • Status changed from New to Resolved
  • Applies to branch 9.7, 9.8 added
  • Fix Committed on Branch 9.7, 9.8 added

Patch committed on the 9.7 and 9.8 branches.

Actions #4

Updated by O'Neil Delpratt about 8 years ago

  • % Done changed from 0 to 100
  • Fixed in Maintenance Release 9.7.0.7 added

Bug fix applied in the Saxon 9.7.0.7 maintenance release.

Actions #5

Updated by O'Neil Delpratt about 8 years ago

  • Status changed from Resolved to Closed
Actions #6

Updated by O'Neil Delpratt about 7 years ago

  • Applies to branch trunk added
  • Applies to branch deleted (9.8)
Actions #7

Updated by O'Neil Delpratt about 7 years ago

  • Fix Committed on Branch trunk added
  • Fix Committed on Branch deleted (9.8)

Please register to edit this issue

Also available in: Atom PDF