Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regression after upgrade of Axios v0.27.1 to v1.6 #304

Closed
hoijnet opened this issue Jul 20, 2024 · 0 comments
Closed

Regression after upgrade of Axios v0.27.1 to v1.6 #304

hoijnet opened this issue Jul 20, 2024 · 0 comments
Labels
bug Something isn't working triage issue to be triage

Comments

@hoijnet
Copy link
Contributor

hoijnet commented Jul 20, 2024

Describe the bug
The axios library upgrade caused a regression where CSV formData could no longer be processed correctly in Node.JS, with an error thrown.

To Reproduce
Run a WOQL query in the javascript client that uploads a CSV file:

const result = await client.query(
        WOQL.and(
            WOQL.get(
                WOQL.as('Name', 'v:Name')
                    .as('Manager', 'v:Manager')
                    .as('Title', 'v:Title')
            ).post("Employees.csv"),
        )
    )

Expected behavior
Return correct bindings.

Error logs

Error: API Error api:message Type error for null which should be dict api:status api:failure Code: 400 url: http://localhost:6363/api/woql/admin/GettingStartedDB/local/branch/main
at Object.apiErrorFormatted (/home/hoijnet/code/dfrnt/terminusdb-client-js/lib/errorMessage.js:95:13)
at /home/hoijnet/code/dfrnt/terminusdb-client-js/lib/dispatchRequest.js:227:30
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async runQuery (/home/hoijnet/code/dfrnt/tuscli/examples/woql/content/emp.js:30:20) {
data: {
'api:message': 'Type error for null which should be dict',
'api:status': 'api:failure',
'system:witnesses': [
{
'@type': 'vio:ViolationWithDatatypeObject',
'vio:literal': null,
'vio:message': 'Type error for null which should be dict',
'vio:type': 'dict'
}
]
},
status: 400
}

System information (please complete the following information):

  • OS: Ubuntu
  • NodeJS 18
  • terminus-client 10.0.33
@github-actions github-actions bot added bug Something isn't working triage issue to be triage labels Jul 20, 2024
hoijnet added a commit to hoijnet/terminusdb-client-js that referenced this issue Jul 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage issue to be triage
Projects
None yet
Development

No branches or pull requests

1 participant