[ 
https://issues.apache.org/jira/browse/TINKERPOP-1972?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16638804#comment-16638804
 ] 

stephen mallette commented on TINKERPOP-1972:
---------------------------------------------

hmm - at least you pinpointed the problem. java seems to generate this bytecode 

{code}
{
        "@type": "g:Bytecode",
        "@value": {
                "step": [
                        ["inject", {
                                "@type": "g:Int32",
                                "@value": 1
                        }],
                        ["choose", {
                                "@type": "g:Bytecode",
                                "@value": {
                                        "step": [
                                                ["is", {
                                                        "@type": "g:Int32",
                                                        "@value": 1
                                                }]
                                        ]
                                }
                        }, {
                                "@type": "g:Bytecode",
                                "@value": {
                                        "step": [
                                                ["constant", {
                                                        "@type": "g:Int32",
                                                        "@value": 10
                                                }],
                                                ["fold"]
                                        ]
                                }
                        }, {
                                "@type": "g:Bytecode",
                                "@value": {
                                        "step": [
                                                ["fold"]
                                        ]
                                }
                        }]
                ]
        }
}
{code}

which seems to match what you said is working after you edit the file above 
(i.e. remove the embedded list in the argument for {{inject()}}). I tried to 
dig into it futher but I can't say I follow where that problem is originating 
from yet. you say it's something "general" but is the problem general to 
serialization or bytecode construction or did you not get that far? 

> inject() tests are throwing exceptions in .NET GLV tests
> --------------------------------------------------------
>
>                 Key: TINKERPOP-1972
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1972
>             Project: TinkerPop
>          Issue Type: Bug
>          Components: dotnet
>    Affects Versions: 3.2.9
>            Reporter: stephen mallette
>            Assignee: stephen mallette
>            Priority: Minor
>
> New GLV tests were added in TINKERPOP-1963 and are generating this error:
> {code}
> Failures:
> 1) g_injectX1X_chooseXisX1X__constantX10Xfold__foldX: Failed
> System.NotSupportedException: Type is not supported.
>    at System.Array.InternalCreate(Void* elementType, Int32 rank, Int32* 
> pLengths, Int32* pLowerBounds)
>    at System.Array.CreateInstance(Type elementType, Int32 length)
>    at 
> Gremlin.Net.IntegrationTest.Gherkin.TraversalEvaluation.TraversalParser.BuildParameters(MethodInfo
>  method, Token token, IDictionary`2& genericParameterTypes) in 
> /home/smallette/git/apache/incubator-tinkerpop/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gherkin/TraversalEvaluation/TraversalParser.cs:line
>  268
>    at 
> Gremlin.Net.IntegrationTest.Gherkin.TraversalEvaluation.TraversalParser.GetTraversalFromTokens(IList`1
>  tokens, GraphTraversalSource g, IDictionary`2 contextParameterValues, String 
> traversalText) in 
> /home/smallette/git/apache/incubator-tinkerpop/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gherkin/TraversalEvaluation/TraversalParser.cs:line
>  90
>    at 
> Gremlin.Net.IntegrationTest.Gherkin.TraversalEvaluation.TraversalParser.GetTraversal(String
>  traversalText, GraphTraversalSource g, IDictionary`2 contextParameterValues) 
> in 
> /home/smallette/git/apache/incubator-tinkerpop/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gherkin/TraversalEvaluation/TraversalParser.cs:line
>  62
>    at 
> Gremlin.Net.IntegrationTest.Gherkin.CommonSteps.TranslateTraversal(String 
> traversalText) in 
> /home/smallette/git/apache/incubator-tinkerpop/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gherkin/CommonSteps.cs:line
>  101
> 2) g_injectX2X_chooseXisX1X__constantX10Xfold__foldX: Failed
> System.NotSupportedException: Type is not supported.
>    at System.Array.InternalCreate(Void* elementType, Int32 rank, Int32* 
> pLengths, Int32* pLowerBounds)
>    at System.Array.CreateInstance(Type elementType, Int32 length)
>    at 
> Gremlin.Net.IntegrationTest.Gherkin.TraversalEvaluation.TraversalParser.BuildParameters(MethodInfo
>  method, Token token, IDictionary`2& genericParameterTypes) in 
> /home/smallette/git/apache/incubator-tinkerpop/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gherkin/TraversalEvaluation/TraversalParser.cs:line
>  268
>    at 
> Gremlin.Net.IntegrationTest.Gherkin.TraversalEvaluation.TraversalParser.GetTraversalFromTokens(IList`1
>  tokens, GraphTraversalSource g, IDictionary`2 contextParameterValues, String 
> traversalText) in 
> /home/smallette/git/apache/incubator-tinkerpop/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gherkin/TraversalEvaluation/TraversalParser.cs:line
>  90
>    at 
> Gremlin.Net.IntegrationTest.Gherkin.TraversalEvaluation.TraversalParser.GetTraversal(String
>  traversalText, GraphTraversalSource g, IDictionary`2 contextParameterValues) 
> in 
> /home/smallette/git/apache/incubator-tinkerpop/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gherkin/TraversalEvaluation/TraversalParser.cs:line
>  62
>    at 
> Gremlin.Net.IntegrationTest.Gherkin.CommonSteps.TranslateTraversal(String 
> traversalText) in 
> /home/smallette/git/apache/incubator-tinkerpop/gremlin-dotnet/test/Gremlin.Net.IntegrationTest/Gherkin/CommonSteps.cs:line
>  101
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to