elixir-protobuf / protobuf

A pure Elixir implementation of Google Protobuf.
https://hexdocs.pm/protobuf/readme.html
MIT License
823 stars 143 forks source link

Error when parsing services without an explicit package name. #29

Closed obmarg closed 6 years ago

obmarg commented 6 years ago

Similar to #27 - I'm getting a crash when I try to compile the following proto file:

syntax = "proto3";

message RenderRequest {
}

message RenderResult {
    string html = 1;
}

service ElmRender {
    rpc Render(RenderRequest) returns (RenderResult);
}

If I add package elm_render; it works fine.

tony612 commented 6 years ago

Try updating to the latest version? On Sat, 3 Mar 2018 at 20:47 Graeme Coupar notifications@github.com wrote:

Similar to #27 https://github.com/tony612/protobuf-elixir/issues/27 - I'm getting a crash when I try to compile the following proto file:

syntax = "proto3"; message RenderRequest { } message RenderResult { string html = 1; } service ElmRender { rpc Render(RenderRequest) returns (RenderResult); }

If I add package elm_render; it works fine.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/tony612/protobuf-elixir/issues/29, or mute the thread https://github.com/notifications/unsubscribe-auth/ABMhG9HOfBiVMKF9brH321x9qpQClL2Fks5tapD6gaJpZM4Sa6DD .

obmarg commented 6 years ago

@tony612 I'm seeing this with 0.5.3, which I believe is the latest version?

tony612 commented 6 years ago

I see. I’ll look into this later.

tony612 commented 6 years ago

@obmarg Could you verify if this problem has been fixed on master?

obmarg commented 6 years ago

@tony612 are there any instructions for running from a non-release? I only know how to run w/ an escript installed from hex.

tony612 commented 6 years ago

@obmarg mix escript.install github tony612/protobuf-elixir. You can view doc via mix help escript.install

tony612 commented 6 years ago

If it works, I can release a new version.

obmarg commented 6 years ago

@tony612 thanks - I'll try and test that tonight when I get home

obmarg commented 6 years ago

@tony612 looks like your fix worked. thanks a lot!