Skip to content
This repository has been archived by the owner on Jan 4, 2023. It is now read-only.

Illegal value '[' #96

Closed
lopezator opened this issue Jun 19, 2019 · 21 comments
Closed

Illegal value '[' #96

lopezator opened this issue Jun 19, 2019 · 21 comments
Labels
bug Something isn't working

Comments

@lopezator
Copy link

lopezator commented Jun 19, 2019

We have defined some extra properties:

// API tags applied at the message level
extend google.protobuf.FieldOptions {
    mycompany.api.ResourceName resource_name = 818181;
}

And make use of them like this:

message MyMessage {
    string name = 1 [
        (mycompany.api.resource_name) = {
            any: [
                "some/*/format/*",
                "other/*/format/*"
            ]
        }
    ];
}

Given these protos, when importing them, BloomRPC throws this error:

illegal value '[' (/Users/myuser/go/src/gitlab.mycompany.com/my-apis/spec/mycompany/myproject/myfolder/v1/myproto.proto, line 100)

The only workaround I found is just dropping that part.

message MyMessage {
    string name = 1;
}
@fenos
Copy link
Contributor

fenos commented Jun 24, 2019

@lopezator Hi,
I will have a look at this, but it sounds like some sort of limitation of protobuf.js parser.

I'll let you know once i've got some more information

@lopezator
Copy link
Author

If it were the case, maybe we should move the issue there.

Thanks @fenos!

@glerchundi
Copy link

@fenos bitten by the same, I tried to create my own dev workspace in order to see if the problem comes from protobuf-js but the steps on the CONTRIBUTING part of the README didn't work for me. Did you have time to look at this or anything I can do to push this forward?

@fenos
Copy link
Contributor

fenos commented Jul 2, 2019

@glerchundi i haven't look this yet, i'm fairy busy at the moment, but i'll get to this asap

@glerchundi
Copy link

No rush, thanks for keeping us updated!

@nickrobinson
Copy link

Running into the same issue with Version 1.4.1 (1.4.1.145)

@fenos
Copy link
Contributor

fenos commented Feb 13, 2020

Unfortunately this is a limitation of protobufjs parser, you can read more information here.

#115

I'll try to make it work in a different way in future releases if the PR doesn't get merged

@fenos fenos added the protobuf.js/unsupported Unsupported feature of the underline Protobuf.js parser label Feb 13, 2020
@dharmjit
Copy link

Hi, facing the same issue. Any update.

@jackielii jackielii added bug Something isn't working and removed protobuf.js/unsupported Unsupported feature of the underline Protobuf.js parser labels Nov 11, 2020
@mkfsn
Copy link

mkfsn commented Apr 16, 2021

Hi folks, it seems like protobufjs/protobuf.js#1256 has been merged and released, do you have any update about this issue?

@mcopjan
Copy link

mcopjan commented Apr 19, 2021

any update on this please? ^^

@mcopjan
Copy link

mcopjan commented Apr 29, 2021

@fenos ?

@wolfogre
Copy link

Same problem when using protoc-gen-validate, any update?

DomainKind kind = 11 [(validate.rules).enum = {in: [1,2,3]}];

image

@monotone
Copy link

@fenos
facing the same problem

@CyborgMaster
Copy link

Now that protobufjs/protobuf.js#1256 has been merged, it feels like the only change should be updating the package.json file. I tried to do it myself and could figure out how to get the dev environment up and running. Anyone else want to take a crack on it? Hopefully a one line change.

@monotone
Copy link

monotone commented Oct 15, 2021

it already so long for this issue. I not good at about JS, and tried upgrade failed. Someone else could do it ?

@codewithrajranjan
Copy link

Any update of this

@kos-maverik
Copy link

Facing the same problem, is there any update on this?

@darewreck54
Copy link

Any updates on this?

@akalittle
Copy link

akalittle commented Aug 8, 2022

Any updates on this? Still facing the problem by the version 1.5.3

@wuqinqiang
Copy link

Any updates on this?

facing the same problem.😂

@M-Kepler
Copy link

M-Kepler commented Jan 2, 2023

Any updates on this?

facing the same problem too.

@allan2 allan2 closed this as not planned Won't fix, can't repro, duplicate, stale Jan 4, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests