本文介绍了这种流体错误意味着什么? 100次迭代后找不到唯一的路径段的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在订单查看页面上收到此错误:

I get this error on an order review page:

    Exception while rendering
    checkout<TYPO3.Neos:Page>/
    body<TYPO3.TypoScript:Template>/
    content/
    main<TYPO3.Neos:PrimaryContent>/
    default<TYPO3.TypoScript:Matcher>/
    element<TYPO3.Neos:ContentCollection>/
    itemRenderer<TYPO3.Neos:ContentCase>/
    default<TYPO3.TypoScript:Matcher>/
    element<SeeThroughWeb.Shop:ShopOrderReview>:
    No unique path segment could be found after 100 iterations. (201409261654538b6e30)

任何想法为什么或这意味着什么?顺便说一句,我在另一个站点上使用了相同的模板,并且在那里没有得到这样的错误.我正在使用Flow 2.1和Neos .99.谢谢

Any idea why or what it means? BTW, I use the same template on another site and get no such error there. I am using Flow 2.1 and Neos .99 .Thanks

方法声明为:

     /**
     * A new form to fill shipping address
     *
     * @param \SeeThroughWeb\Shop\Domain\Model\Address $address List of address
     * @param integer $changeAddress
     * @return void
     */
    public function shippingAddressAction(\SeeThroughWeb\Shop\Domain\Model\Address $address = NULL, $changeAddress = 0) {  

这是我在下面的评论中引用的模板部分的完整列表:

and here is a fuller listing of the template section referenced in my comment below:

<f:for each="{addresses}" as="address">
    <li>
    <f:link.action action="shippingAddress" arguments="{address: address}">{address.title}</f:link.action>
    </li>
</f:for>

在同一页面上发生类似错误,似乎与地址变量以某种方式有关:

A similar error ont he same page, seems to be related tot he address variable somehow:

14-11-05 17:18:27  CRITICAL  Fluid                Uncaught exception #1316441798: No unique path segment could be found after 100 iterations. - See also: 201411051718246a61dd.txt
    previousException => Uncaught exception #1316441798 in line 198 of /home/thebigcarrot/domains/shop.thebigcarrot.ca/public_html/releases/20131219160416/Data/Temporary/Development/Cache/Code/Flow_Object_Classes/TYPO3_Flow_Mvc_Routing_IdentityRoutePart.php: No unique path segment could be found after 100 iterations.

,异常日志如下:

Uncaught exception #1316441798: No unique path segment could be found after 100 iterations.

80 TYPO3\Fluid\ViewHelpers\Link\ActionViewHelper_Original::render("editOrderAddressForAdmin", array|2|, "OrderManagement", NULL, NULL, "", "", array|0|, FALSE, array|0|, FALSE)
79 call_user_func_array(array|2|, array|11|)
78 TYPO3\Fluid\Core\ViewHelper\AbstractViewHelper::callRenderMethod()
77 TYPO3\Fluid\Core\ViewHelper\AbstractViewHelper::initializeArgumentsAndRender()
76 TYPO3\Fluid\Core\Parser\SyntaxTree\ViewHelperNode_Original::evaluate(TYPO3\Fluid\Core\Rendering\RenderingContext)
75 TYPO3\Fluid\Core\Parser\SyntaxTree\AbstractNode::evaluateChildNodes(TYPO3\Fluid\Core\Rendering\RenderingContext)
74 TYPO3\Fluid\Core\ViewHelper\AbstractViewHelper::renderChildren()
73 TYPO3\Fluid\ViewHelpers\SectionViewHelper_Original::render()
72 call_user_func_array(array|2|, array|0|)
71 TYPO3\Fluid\Core\ViewHelper\AbstractViewHelper::callRenderMethod()
70 TYPO3\Fluid\Core\ViewHelper\AbstractViewHelper::initializeArgumentsAndRender()
69 TYPO3\Fluid\Core\Parser\SyntaxTree\ViewHelperNode_Original::evaluate(TYPO3\Fluid\Core\Rendering\RenderingContext)

editOrderAddressForAdmin的声明如下:

The declaration of editOrderAddressForAdmin looks like this:

/**
     * Edit order address for admin
     *
     * @param \SeeThroughWeb\Shop\Domain\Model\Address $address  
     * @param integer $shipping
     * @Flow\IgnoreValidation("$address")
     * @return void
     */
    public function editOrderAddressForAdminAction(\SeeThroughWeb\Shop\Domain\Model\Address $address  , $shipping = 0) {

        $this->view->assign('address', $address);
        $this->view->assign('shipping', $shipping);
        $countryAndStates = $this->taxZoneService->getCountryAndStates();
        $this->view->assign('countries', $countryAndStates['country']);
        $this->view->assign('states', $countryAndStates['state']);
    }

在模板中,我可以通过注释以下行来避免出现异常:

In the template I can avoid the exception by commenting out the following line:

 <f:link.action action="editOrderAddressForAdmin" controller="OrderManagement" arguments="{address: order.shippingAddress, shipping: 1}" >
                        <div class="editOrderDetails">(edit)</div>
                    </f:link.action>

同样,它是一个涉及地址对象的链接.

So again its a link that involves an address object.

推荐答案

问题出在地址参数中.我想您可能为shippingAddressAction()的地址参数定义了错误的类型,例如@param \My\Package\..\wrongType $address.第二件事可能与Routes.yaml有关-例如,routeParts ..中的错误.不是uriPattern中使用的唯一属性,或者那里的objectType再次错误.您还可以在shippingAddressAction()中添加@Flow \ IgnoreValidation("$ address")-并检查会发生什么,请查看 http://docs.typo3.org/flow/TYPO3FlowDocumentation/TheDefinitiveGuide/PartII/Validation.html

Problem lies in address argument.. I guess you may have wrong type defined for address argument for shippingAddressAction().. sth like @param \My\Package\..\wrongType $address. Second thing might be related to Routes.yaml - for example error in routeParts.. not unique property used in uriPattern or again wrong objectType there..You can also add @Flow\IgnoreValidation("$address") in shippingAddressAction() - and check what happens, look at the bottom of http://docs.typo3.org/flow/TYPO3FlowDocumentation/TheDefinitiveGuide/PartII/Validation.html

这篇关于这种流体错误意味着什么? 100次迭代后找不到唯一的路径段的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-03 12:54