Skip to content

Compilation hang with Sparrow-ipc #463

@Alex-PLACET

Description

@Alex-PLACET

With this following snippet, the compilant hang in JupyterLite with xeus cpp.

you need these libraries from emscripten-forge:

  • sparrow
  • sparrow-ipc
// --- sparrow (columnar data model) ---
#include <sparrow/record_batch.hpp>
#include <sparrow/primitive_array.hpp>
#include <sparrow/variable_size_binary_array.hpp>

// --- sparrow-ipc (IPC serialization) ---
#include <sparrow_ipc/memory_output_stream.hpp>
#include <sparrow_ipc/serializer.hpp>
// --- Standard library ---
#include <iostream>
#include <vector>
#include <string>


namespace sp     = sparrow;
namespace sp_ipc = sparrow_ipc;

std::vector<sp::record_batch> batches;
// record_batch is move-only — copy via reconstruction
batches.push_back(sp::record_batch(
    {{"id",   sp::array(sp::primitive_array<int32_t>({10, 20, 30, 40, 50}))},
     {"temp", sp::array(sp::primitive_array<double>({36.6, 37.1, 38.0, 36.9, 37.4}))},
     {"name", sp::array(sp::string_array(std::vector<std::string>{"Alice","Bob","Charlie","Diana","Eve"}))}}
));


std::vector<uint8_t> stream_buf;               // destination buffer
sp_ipc::memory_output_stream stream(stream_buf);
sp_ipc::serializer ser(stream);
ser << batches << sp_ipc::end_stream;

ping @anutosh491

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions