From whjackson at gmail.com Sat Dec 14 23:05:50 2013 From: whjackson at gmail.com (Whitney Jackson) Date: Sat, 14 Dec 2013 16:05:50 -0600 Subject: [Rprotobuf-yada] can't assign raw to field of type bytes Message-ID: I've run into an issue where I can't assign raw values to RProtoBuf fields of type bytes. See the following proto and R files for an example. test.proto: http://pastebin.com/0n4dcYV7 test.R: http://pastebin.com/1C3KBVqh >From what I can tell, only R character vectors of length 1 can be assigned to bytes fields. That seems like a bug since protobuf bytes fields are meant to hold arbitrary bytes and R character vectors aren't (null chars are prohibited for example). I'd appreciate any advise that anyone might have. Thanks, Whitney -------------- next part -------------- An HTML attachment was scrubbed... URL: From mstokely at google.com Sun Dec 15 00:15:15 2013 From: mstokely at google.com (Murray Stokely) Date: Sat, 14 Dec 2013 15:15:15 -0800 Subject: [Rprotobuf-yada] can't assign raw to field of type bytes In-Reply-To: References: Message-ID: On Dec 14, 2013 2:05 PM, "Whitney Jackson" wrote: > I've run into an issue where I can't assign raw values to RProtoBuf fields > of type bytes. See the following proto and R files for an example. > > test.proto: http://pastebin.com/0n4dcYV7 > test.R: http://pastebin.com/1C3KBVqh > > From what I can tell, only R character vectors of length 1 can be assigned > to bytes fields. That seems like a bug since protobuf bytes fields are > meant to hold arbitrary bytes and R character vectors aren't (null chars > are prohibited for example). > > I'd appreciate any advise that anyone might have. > What version of RProtoBuf are you using? Your example works fine on the version I am using, but that may include some fixes we haven't yet pushed to CRAN. If the latest version from CRAN still has this problem, can you try the latest version from R-Forge? I'll add a unit test to runit.bytes.R for this behavior. - Murray -------------- next part -------------- An HTML attachment was scrubbed... URL: From murray at stokely.org Sun Dec 15 01:47:24 2013 From: murray at stokely.org (Murray Stokely) Date: Sat, 14 Dec 2013 16:47:24 -0800 Subject: [Rprotobuf-yada] can't assign raw to field of type bytes In-Reply-To: References: Message-ID: Actually I see that I had a local change that was not submitted even to r-forge that fixes this issue. I've just submitted it, added more tests, and I think we are nearly ready to roll a 0.3.2 release onto CRAN. In the mean time, could you please try installing it from the latest version on R-Forge : install.packages("HistogramTools", repos = "http://R-Forge.R-project.org"). - Murray On Sat, Dec 14, 2013 at 3:15 PM, Murray Stokely wrote: > On Dec 14, 2013 2:05 PM, "Whitney Jackson" wrote: > >> I've run into an issue where I can't assign raw values to RProtoBuf >> fields of type bytes. See the following proto and R files for an example. >> >> test.proto: http://pastebin.com/0n4dcYV7 >> test.R: http://pastebin.com/1C3KBVqh >> >> From what I can tell, only R character vectors of length 1 can be >> assigned to bytes fields. That seems like a bug since protobuf bytes fields >> are meant to hold arbitrary bytes and R character vectors aren't (null >> chars are prohibited for example). >> >> I'd appreciate any advise that anyone might have. >> > > What version of RProtoBuf are you using? Your example works fine on the > version I am using, but that may include some fixes we haven't yet pushed > to CRAN. > > If the latest version from CRAN still has this problem, can you try the > latest version from R-Forge? > > I'll add a unit test to runit.bytes.R for this behavior. > > - Murray > > _______________________________________________ > Rprotobuf-yada mailing list > Rprotobuf-yada at lists.r-forge.r-project.org > https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rprotobuf-yada > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mstokely at google.com Sun Dec 15 01:56:43 2013 From: mstokely at google.com (Murray Stokely) Date: Sat, 14 Dec 2013 16:56:43 -0800 Subject: [Rprotobuf-yada] can't assign raw to field of type bytes In-Reply-To: References: Message-ID: Oops that should be : install.packages("RProtoBuf", repos = "http://R-Forge.R-project.org"). On Sat, Dec 14, 2013 at 4:47 PM, Murray Stokely wrote: > Actually I see that I had a local change that was not submitted even to > r-forge that fixes this issue. > > I've just submitted it, added more tests, and I think we are nearly ready > to roll a 0.3.2 release onto CRAN. In the mean time, could you please try > installing it from the latest version on R-Forge : > > install.packages("HistogramTools", repos = "http://R-Forge.R-project.org > "). > > - Murray > > > On Sat, Dec 14, 2013 at 3:15 PM, Murray Stokely wrote: > >> On Dec 14, 2013 2:05 PM, "Whitney Jackson" wrote: >> >>> I've run into an issue where I can't assign raw values to RProtoBuf >>> fields of type bytes. See the following proto and R files for an example. >>> >>> test.proto: http://pastebin.com/0n4dcYV7 >>> test.R: http://pastebin.com/1C3KBVqh >>> >>> From what I can tell, only R character vectors of length 1 can be >>> assigned to bytes fields. That seems like a bug since protobuf bytes fields >>> are meant to hold arbitrary bytes and R character vectors aren't (null >>> chars are prohibited for example). >>> >>> I'd appreciate any advise that anyone might have. >>> >> >> What version of RProtoBuf are you using? Your example works fine on the >> version I am using, but that may include some fixes we haven't yet pushed >> to CRAN. >> >> If the latest version from CRAN still has this problem, can you try the >> latest version from R-Forge? >> >> I'll add a unit test to runit.bytes.R for this behavior. >> >> - Murray >> >> _______________________________________________ >> Rprotobuf-yada mailing list >> Rprotobuf-yada at lists.r-forge.r-project.org >> >> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rprotobuf-yada >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From whjackson at gmail.com Sun Dec 15 16:19:33 2013 From: whjackson at gmail.com (Whitney Jackson) Date: Sun, 15 Dec 2013 09:19:33 -0600 Subject: [Rprotobuf-yada] can't assign raw to field of type bytes In-Reply-To: References: Message-ID: Thanks for the help! Sadly, I'm still seeing the error: "cannot set non-repeated field to vector of length > 1" According to sessionInfo() I'm now running RProtoBuf_0.3.1.1 On Sat, Dec 14, 2013 at 6:56 PM, Murray Stokely wrote: > Oops that should be : > > install.packages("RProtoBuf", repos = "http://R-Forge.R-project.org"). > > > > On Sat, Dec 14, 2013 at 4:47 PM, Murray Stokely wrote: > >> Actually I see that I had a local change that was not submitted even to >> r-forge that fixes this issue. >> >> I've just submitted it, added more tests, and I think we are nearly ready >> to roll a 0.3.2 release onto CRAN. In the mean time, could you please try >> installing it from the latest version on R-Forge : >> >> install.packages("HistogramTools", repos = "http://R-Forge.R-project.org >> "). >> >> - Murray >> >> >> On Sat, Dec 14, 2013 at 3:15 PM, Murray Stokely wrote: >> >>> On Dec 14, 2013 2:05 PM, "Whitney Jackson" wrote: >>> >>>> I've run into an issue where I can't assign raw values to RProtoBuf >>>> fields of type bytes. See the following proto and R files for an example. >>>> >>>> test.proto: http://pastebin.com/0n4dcYV7 >>>> test.R: http://pastebin.com/1C3KBVqh >>>> >>>> From what I can tell, only R character vectors of length 1 can be >>>> assigned to bytes fields. That seems like a bug since protobuf bytes fields >>>> are meant to hold arbitrary bytes and R character vectors aren't (null >>>> chars are prohibited for example). >>>> >>>> I'd appreciate any advise that anyone might have. >>>> >>> >>> What version of RProtoBuf are you using? Your example works fine on the >>> version I am using, but that may include some fixes we haven't yet pushed >>> to CRAN. >>> >>> If the latest version from CRAN still has this problem, can you try the >>> latest version from R-Forge? >>> >>> I'll add a unit test to runit.bytes.R for this behavior. >>> >>> - Murray >>> >>> _______________________________________________ >>> Rprotobuf-yada mailing list >>> Rprotobuf-yada at lists.r-forge.r-project.org >>> >>> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rprotobuf-yada >>> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From whjackson at gmail.com Sun Dec 15 16:47:20 2013 From: whjackson at gmail.com (Whitney Jackson) Date: Sun, 15 Dec 2013 09:47:20 -0600 Subject: [Rprotobuf-yada] can't assign raw to field of type bytes In-Reply-To: References: Message-ID: I just installed the latest and greatest (r547) from svn and it works now. I'll upgrade from CRAN whenever 0.3.2 is available there. Thanks for fixing this! On Sun, Dec 15, 2013 at 9:19 AM, Whitney Jackson wrote: > Thanks for the help! Sadly, I'm still seeing the error: > > "cannot set non-repeated field to vector of length > 1" > > According to sessionInfo() I'm now running RProtoBuf_0.3.1.1 > > > On Sat, Dec 14, 2013 at 6:56 PM, Murray Stokely wrote: > >> Oops that should be : >> >> install.packages("RProtoBuf", repos = "http://R-Forge.R-project.org"). >> >> >> >> On Sat, Dec 14, 2013 at 4:47 PM, Murray Stokely wrote: >> >>> Actually I see that I had a local change that was not submitted even to >>> r-forge that fixes this issue. >>> >>> I've just submitted it, added more tests, and I think we are nearly >>> ready to roll a 0.3.2 release onto CRAN. In the mean time, could you >>> please try installing it from the latest version on R-Forge : >>> >>> install.packages("HistogramTools", repos = "http://R-Forge.R-project.org >>> "). >>> >>> - Murray >>> >>> >>> On Sat, Dec 14, 2013 at 3:15 PM, Murray Stokely wrote: >>> >>>> On Dec 14, 2013 2:05 PM, "Whitney Jackson" wrote: >>>> >>>>> I've run into an issue where I can't assign raw values to RProtoBuf >>>>> fields of type bytes. See the following proto and R files for an example. >>>>> >>>>> test.proto: http://pastebin.com/0n4dcYV7 >>>>> test.R: http://pastebin.com/1C3KBVqh >>>>> >>>>> From what I can tell, only R character vectors of length 1 can be >>>>> assigned to bytes fields. That seems like a bug since protobuf bytes fields >>>>> are meant to hold arbitrary bytes and R character vectors aren't (null >>>>> chars are prohibited for example). >>>>> >>>>> I'd appreciate any advise that anyone might have. >>>>> >>>> >>>> What version of RProtoBuf are you using? Your example works fine on >>>> the version I am using, but that may include some fixes we haven't yet >>>> pushed to CRAN. >>>> >>>> If the latest version from CRAN still has this problem, can you try the >>>> latest version from R-Forge? >>>> >>>> I'll add a unit test to runit.bytes.R for this behavior. >>>> >>>> - Murray >>>> >>>> _______________________________________________ >>>> Rprotobuf-yada mailing list >>>> Rprotobuf-yada at lists.r-forge.r-project.org >>>> >>>> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rprotobuf-yada >>>> >>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From edd at debian.org Sun Dec 15 16:49:05 2013 From: edd at debian.org (Dirk Eddelbuettel) Date: Sun, 15 Dec 2013 09:49:05 -0600 Subject: [Rprotobuf-yada] can't assign raw to field of type bytes In-Reply-To: References: Message-ID: <21165.53105.677755.511253@max.nulle.part> On 15 December 2013 at 09:47, Whitney Jackson wrote: | I just installed the latest and greatest (r547) from svn?and it works now. | I'll upgrade from CRAN whenever 0.3.2 is available there.?Thanks for fixing | this! Awesome. Thanks for confirming. This one should go out later today and hit CRAN by the morning. Dirk -- Dirk Eddelbuettel | edd at debian.org | http://dirk.eddelbuettel.com