protocolbuffers / protocolbuffers/protobuf-javascript

ES3 protobuf - getRepeatedWrapperField & wrapRepeatedField_

Open
#24 6 comments 0 reactions 1 assignee View on GitHub

@shaod2 is already working on this.

Since Oct 22, 2020.

javascript P3 port-fix triaged
Dominant language
JavaScript
Stars
471
Forks
91
Avg merge
3h 57m
Merged PRs (30d)
2

Description

I am trying to run protbuf serialization for JScript app that runs in a window scripting host runtime (WSH) on window. The JScript seems to based on a very old version of Ecmascript.

I webpacked my app code and ran into following error

"length is null or not an object"

for this line

for (var d = jspb.Message.getRepeatedField(a, c), e = [], f = 0; f < d.length; f++)

This seeems to be happening inside wrapRepeatedField_ function from a getRepeatedWrapperField call.

The same webpacked application code runs perfectly fine on chrome browser. So I am suspecting an issue either with missing polyfills because of which the message was not initialized properly.

I would appreciate any hints on how I could make this work on this old JScript runtime.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.