- May 29, 2013
-
-
Alejandro R Sedeño authored
-
- Apr 06, 2013
-
-
Scott McKay authored
-
- Mar 16, 2013
-
-
Alejandro R Sedeño authored
Fixes the bug tickled by the tests in this commit's parent.
-
- Feb 28, 2013
-
-
Scott McKay authored
-
Scott McKay authored
-
- Dec 09, 2012
-
-
Scott McKay authored
-
- Nov 27, 2012
-
-
Ben Wagner authored
* Previously, if a field in a .proto file referenced a message in another proto file using a different lisp package, the cl-protobufs library would silently fail to serialize the field. A similar problem would occur if a message defined later in the file used the lisp_name option to override the name generated by cl-protobufs. This change fixes these issues and others. * Add conditions that are signaled when encountering an undefined type. * Delay assigning lisp classes/types to fields and methods until all possible forward references have been parsed. * This allows the class slot to be unbound, so check for that case in print-object methods. * Add a test for forward references to messages that override the lisp name. * Add a test for references to messages and enums defined in another proto file with a different lisp package. * Change color-wheel-stability test, because it used "string" as the input type for an rpc, which seems to be disallowed (although I haven't found this documented anywhere). * Signal errors during parsing for undefined types. * Add a test for these errors. Add assert-error macro to qtest. * Signal a condition if we are unable to find the definition for a field's type during serialization, deserialization, determining an object's serialized size, printing text format, parsing text format, or generating code for one of the above. * Remove logic in find-qualified-name that indirects through lisp packages. Proto packages and lisp packages do not necessarily map 1-to-1. * Always use the schema's lisp package for any symbols generated when parsing proto files. * When generating lisp code using write-schema-as, set the package to the package used in the generated file, so that ~s will print the package prefix in the correct circumstances. * Remove broken proto1 "streams" parsing ("returns" comes before "streams" in every example I've found); replace with proto2 syntax. * In process-imports, the call to find-schema using a pathname was not giving the expected result. Sidestep this issue by using the same logic to find the schema as is used earlier in the function.
-
- Nov 26, 2012
-
-
Shaun Morris authored
-
- Sep 18, 2012
-
-
Scott McKay authored
Testing : precheckin --full --strict-errors Reviewer: Fare JTB impact: No Ops impact: No Change to config : No Change to XML schema : No Change to DB schema : No Change to transport (timeouts, headers) : No Any change (or new use) of OAQs : No Change to inter-component transactions : No Depends on any other checkin / bug : No Tests that will verify: The CL-Protobufs tests Description: The unoptimized serialization code was slower than it needed to be and was a Niagara falls of consing. The problem is that (map () (curry ...)) is poorly optimized, which is a shame because it's such a nice coding style. :-P The fix is to replace 'map' with iteration (sigh) in a few critical places. - Add 'doseq', which chooses between 'dolist' or 'dovector'. - Make 'serialize-object', 'deserialize-object' and 'object-size' use 'doseq' instead of using 'map'. - Ditto for 'print-text-format'. - Fix the 'serialize-packed' and 'packed-size' optimizers to use 'dolist' or 'dovector' based on whether the field is a vector field. This makes the optimized code faster, too. - Make the optimized serializer generators pass in 'vectorp' so that the wire-format optimizers can do a better job. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/libs/cl-protobufs@562921 f8382938-511b-0410-9cdd-bb47b084005c
-
- Sep 12, 2012
-
-
Scott McKay authored
Testing : precheckin --full --strict-errors Reviewer: Sergey V, Shaun M JTB impact: No Ops impact: No Change to config : No Change to XML schema : No Change to DB schema : No Change to transport (timeouts, headers) : No Any change (or new use) of OAQs : No Change to inter-component transactions : No Depends on any other checkin / bug : No Tests that will verify: The CL-Protobufs tests Description: I had made a "policy decision" that the package created by importing a .proto file would (:use :common-lisp). In practice, this turned out to be a mistake. Sergey suggested a fix that I think is correct, so in it goes. Shaun noticed that the optimized 'serialize-object' and 'object-size' methods didn't quite implement what they were supposed to for optional boolean fields whose value was never supplied. Fix the optimized methods to implement the same (correct) semantics as the unoptimized ones. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/libs/cl-protobufs@561714 f8382938-511b-0410-9cdd-bb47b084005c
-
- Aug 31, 2012
-
-
Scott McKay authored
Testing : precheckin --full --strict-errors Reviewer: Fare (please) JTB impact: No Ops impact: No Change to config : No Change to XML schema : No Change to DB schema : No Change to transport (timeouts, headers) : No Any change (or new use) of OAQs : No Change to inter-component transactions : No Depends on any other checkin / bug : No Tests that will verify: The CL-Protobufs tests Description: Add type aliases to CL-Protobufs. It's a Lisp-only feature that allows you define a new Protobufs type in terms of a Lisp type, a serializer and a deserializer. - Add a new model class, 'protobuf-type-alias'. - Extend schemas and messages so that they can hold a set of type aliases; add 'find-type-alias'. - Add 'define-type-alias'. - Factor out 'lisp-type-to-protobuf-type' from 'clos-type-to-protobuf-type', I need it for the 'define-type-alias' macro. - Fix the schema printer to print 'define-type-alias' for .lisp schemas, and to add a comment describing the type alias in .proto schemas. - Extend the wire format (de)serializer to know about type aliases; it just (de)serializes the Lisp type as the Protobufs primitive type using the provided (de)serializer functions. There's zero cost to this if you don't use aliases. - Update the optimized serialization generation. - Similarly extend the text format (de)serializer to know about type aliases. - Change an example to use a type alias for 'date'. - Update the documentation. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/libs/cl-protobufs@559861 f8382938-511b-0410-9cdd-bb47b084005c
-
- Aug 29, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/libs/cl-protobufs@559563 f8382938-511b-0410-9cdd-bb47b084005c
-
- Jun 20, 2012
-
-
Scott McKay authored
- Make the 'find-xxx' support searching "relative to" another namespace. - There was a bug in the non-optimized deserializer when deserializing a repeated slot into a vector; create a stretchy vector on demand if it's needed. - 'define-extends' should wrap 'eval-when' around the generated 'defsetf' forms so that they are visible at compile time. - Fix a formatting bug in the export list in the Lisp printer. - Straighten of the ASDF declaration for the tests. - Add the Protobufs test suite to QRes, to keep things honest. Passes 'precheckin' with the new Protobufs unit tests in place. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/libs/cl-protobufs@550053 f8382938-511b-0410-9cdd-bb47b084005c
-
- Jun 13, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/libs/cl-protobufs@548951 f8382938-511b-0410-9cdd-bb47b084005c
-
- Jun 11, 2012
-
-
François-René Rideau authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@548441 f8382938-511b-0410-9cdd-bb47b084005c
-
- Jun 01, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@547034 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 25, 2012
-
-
Scott McKay authored
- 'reinitialize-slot' didn't quite work. - Add a geodata example that uses vectors for repeated fields, which uncovered a bug in the optimized deserializers. - Importing the geodata CLOS classes revealed a bug in default handling when the default is provided only in 'defclass'. - Fix the knock-on bug in deserialization and the optimized (de)serialization caused the above. - Add tighter types in 'decode-uint32' and 'decode-uint64'. Passes 'precheckin'. Even with the new unit tests in place. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@545865 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 23, 2012
-
-
Scott McKay authored
some additions to the macrology and to the (de)serialization code. No runtime performance cost to being able to have things both ways. Fix a bug that caused unprocessed options to get dropped. Improve some of the unit tests. Passes 'precheckin'. Even with the new unit tests in place. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@545367 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 22, 2012
-
-
Scott McKay authored
- Behavior of ':default xxx'/[default=xxx] was not stable, so add an "empty default" marker and respect it during parsing and printing. - 'find-option' now returns a third "found-p" value, useful for the better handling of defaults. - Don't print slot readers/writers if they have the same name as what would be (silently) generated by the macrology. - Don't print 'import descriptor.proto' lines if there are no 'lisp_xxx' options in the generated code. - Add 'clear-field' to the API; add the functions it needs. - Be more careful about how :conc-name interacts with the generation of readers/writers. - When parsing from a .proto file, force the conc-name to be "" unless requested explicitly not to. This has the effect of generating readers/writers for all the fields of imported Protobufs messages, which I think is probably the desired behavior. - Add 'make-byte-vector' for convenience. Passes 'precheckin'. Even with the new unit tests in place. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@545177 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 16, 2012
-
-
Scott McKay authored
- 'define-proto' -> 'define-schema' - 'protobuf' (class name) -> 'protobuf-schema' - 'find-protobuf' -> 'find-schema' - 'parse-protobuf-from-file' -> 'parse-schema-from-file' - 'parse-protobuf-from-stream' -> 'parse-schema-from-file' - 'write-protobuf' -> 'write-schema' - 'write-protobuf-as' -> 'write-schema-as' - 'ensure-all-protobufs' -> 'ensure-all-protobufs' - 'ensure-protobuf' -> 'ensure-protobuf' - 'protobuf-upgradable' -> 'schema-upgradable' - 'protobufs-equal' -> 'schemas-equal' - 'generate-protobuf-schema-for-classes' -> 'generate-schema-for-classes' - 'write-protobuf-schema-for-classes' -> 'write-schema-for-classes' Update the Quake Protobufs schema generator to use the new names. The Protobufs documentation doesn't say so, but enums can be packed. - Update the wire-level protocol to (de)serialize packed enums. - Update the serialization code to use the new wire functions. Passes 'precheckin'. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@544299 f8382938-511b-0410-9cdd-bb47b084005c
-
Scott McKay authored
edge case problems, but it's good enough to continue the Stubby work. The critical .proto files (descriptor.proto, etc) all appear to work. More precise mapping of (mainly integer) types from .lisp to .proto files so that we can a truly exact model once we compile the .lisp file. It may not make any difference, but better safe than sorry. - Introduce Lisp type 'int32', 'int64', 'uint32', etc - Make Lisp->Protobufs recognize the new Lisp types - Make Protobufs schema printers recognize the new types Fix up the handling of imports and namespaces. - Always use truenames to record schemas - Fix typo in 'find-enum' that caused it never to search other schemas - Record the schema in *all-protobufs* at exactly the right time, and simplify 'make-load-form' methods A few tweaks to (de)serialization. - Make the bodies for empty messages not generate compiler warnings - Don't make ':packed t' be the default, the user has to say so - The user documentation doesn't say so, but booleans can be packed. Passes 'precheckin'. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@544222 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 11, 2012
-
-
Scott McKay authored
a few more bugs are showing up: - Add basic handling for namespaces - A typo in my own tests caused me to miss the fact that negative signed integers did not deserialize correctly (thanks, Shaun!) - Just dike out the rest of the Quux dependencies, since it's pretty clear non-QRes folks will be using it Passes 'precheckin'. Passes my by-hand tests. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@543610 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 10, 2012
-
-
Scott McKay authored
- Looks like Stubby will need 'merge-from-array', make room for that. - Text format deserializer didn't correctly parse negative integers. - Simply 'deserialize-object' a bit - Fix a bug in the 'deserialize-object' that caused it not to work correctly on extended fields. - Fix a sloppy bug in 'make-tag' that only showed up in SBCL. - Add a few more examples, soon to be part of a test suite. Passes 'precheckin'. Passes my by-hand tests. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@543418 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 08, 2012
-
-
Scott McKay authored
In particular, uninitialized optional boolean fields whose Lisp type is (or (member t nil) null) now work. Implement 'object-initialized-p' and 'slot-initialized-p' and their Python lookalikes, 'is-initialized' and 'has-field'. Update the documentation. Passes 'precheckin --full+', which makes sense since none of this is called in normal use yet. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@542953 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 07, 2012
-
-
Scott McKay authored
Now we can deserialize responses to BNS lookup requests! Further improve the optimized deserializer generator, gaining up to about 30% for messages with repeated fields. Further improve the wire-level encoders and decoders, gaining about 10-20% in (de)serialization performance across the board. Passes 'precheckin --full+', which makes sense since none of this is called in normal use yet. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@542729 f8382938-511b-0410-9cdd-bb47b084005c
-
- May 04, 2012
-
-
Scott McKay authored
which has been deprecated for years, is still in wide use, e.g., in Chubby's bnsresolver.proto So, implement support for groups: - Add a model class for it - Add .proto and .lisp printers - Add a 'define-group' macro - Make the .proto parser know how to parse them Passes 'precheckin --full+', which makes sense since none of this is used in normal use yet. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@542500 f8382938-511b-0410-9cdd-bb47b084005c
-
Scott McKay authored
to fully serialize a LegacyPnr aggregate. Fix 'skip-element' to ignore (deprecated) groups. Passes 'precheckin --full+', which makes sense since none of this is used in normal use yet. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/quux/protobufs@542375 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 24, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@540715 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 23, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@540598 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 19, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@540133 f8382938-511b-0410-9cdd-bb47b084005c
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@540092 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 11, 2012
-
-
Scott McKay authored
Now that we're using a lighter version of 'list-of', we can avoid using 'map:map' and make this all more portable git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@538774 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 10, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@538580 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 05, 2012
-
-
Scott McKay authored
- When deserializing the wire-format, seeing a null byte in the tag position indicates the end of the message. - Allow the text-format serializer to generate more compact output. - Add a more useful "list" example that he could use for sending stuff to/from his sentence understanding system. git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@537902 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 04, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@537621 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 03, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@537485 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 02, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@537125 f8382938-511b-0410-9cdd-bb47b084005c
-
Scott McKay authored
'serialize-object' and 'object-size' should take a type argument so that aliasing can work properly, always git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@537089 f8382938-511b-0410-9cdd-bb47b084005c
-
- Apr 01, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@537059 f8382938-511b-0410-9cdd-bb47b084005c
-
- Mar 31, 2012
-
-
Scott McKay authored
git-svn-id: http://svn.internal.itasoftware.com/svn/ita/branches/qres/swm/borgify-1/qres/lisp/quux/protobufs@537036 f8382938-511b-0410-9cdd-bb47b084005c
-