[COMPASS-4205] Export to CSV and JSON fails Created: 12/Mar/20  Updated: 29/Oct/23  Resolved: 16/Mar/20

Status: Closed
Project: Compass
Component/s: Import/Export
Affects Version/s: 1.21.0
Fix Version/s: 1.21.0, 1.21.2

Type: Bug Priority: Blocker - P1
Reporter: Massimiliano Marcon Assignee: Lucas Hrabovsky (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Screenshot 2020-03-16 10.51.25.png     PNG File image-2020-03-12-11-49-15-953.png    
Issue Links:
Related
related to COMPASS-4214 Export not working at 1.20.5 Closed
Sprint: Iteration Yak

 Description   

When I try to export a collection to JSON or CSV the export fails.

Can reproduce it 100% of the times with test.users in compass-data-sets.

Console error:

mongodb-compass-import-export:export error running export pipeline +148ms MongoError: Cursor session id (4b9325ce-1dca-412c-9539-7ea93818f1cd - guuhozH9obMVxoERLdtfi+bysD912meoDW6Z4kaH9l0=) is not the same as the operation context's session id (none)
    at MessageStream.messageHandler (/Applications/MongoDB Compass Beta.app/Contents/Resources/app.asar/node_modules/mongodb/lib/cmap/connection.js:261:20)
    at MessageStream.emit (events.js:200:13)
    at processIncomingData (/Applications/MongoDB Compass Beta.app/Contents/Resources/app.asar/node_modules/mongodb/lib/cmap/message_stream.js:144:12)
    at MessageStream._write (/Applications/MongoDB Compass Beta.app/Contents/Resources/app.asar/node_modules/mongodb/lib/cmap/message_stream.js:42:5)
    at doWrite (_stream_writable.js:417:12)
    at writeOrBuffer (_stream_writable.js:401:5)
    at MessageStream.Writable.write (_stream_writable.js:301:11)
    at TLSSocket.ondata (_stream_readable.js:713:22)
    at TLSSocket.emit (events.js:200:13)
    at addChunk (_stream_readable.js:294:12)

A user also reported this other error when exporting to CSV but I could not reproduce it:

Cannot run getMore on cursor 1998783333627462641, which was created in session a7a167f1-dac6-4fd4-9000-cfd2b3270274 - 47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU=, without an lsid

I imported the collection he was trying to export as test.stocks in compass-data-sets.



 Comments   
Comment by Githook User [ 17/Mar/20 ]

Author:

{'email': 'hrabovsky.lucas@gmail.com', 'name': 'Lucas Hrabovsky', 'username': 'imlucas'}

Message: fix(export): COMPASS-4205: fixup JSON output formatter (#1920)

Comment by Githook User [ 17/Mar/20 ]

Author:

{'name': 'Lucas Hrabovsky', 'username': 'imlucas', 'email': 'hrabovsky.lucas@gmail.com'}

Message: fix(export): COMPASS-4205: fixup JSON output formatter (#1920)

Comment by Githook User [ 16/Mar/20 ]

Author:

{'name': 'Lucas Hrabovsky', 'username': 'imlucas', 'email': 'hrabovsky.lucas@gmail.com'}

Message: fix(export): COMPASS-4205: fixup JSON output formatter
Branch: fix-json-export-formatter
https://github.com/mongodb-js/compass/commit/9bbb4dcd271d59cc366fec2bd663bbbdf3567a85

Comment by Lucas Hrabovsky (Inactive) [ 16/Mar/20 ]

https://github.com/mongodb-js/compass/pull/1919

Generated at Wed Feb 07 22:35:35 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.