D3303: cborutil: implement support for streaming encoding, bytestring decoding

2018-04-16 Thread indygreg (Gregory Szorc)
This revision was automatically updated to reflect the committed changes. Closed by commit rHG65a23cc8e75b: cborutil: implement support for streaming encoding, bytestring decoding (authored by indygreg, committed by ). CHANGED PRIOR TO COMMIT

D3303: cborutil: implement support for streaming encoding, bytestring decoding

2018-04-16 Thread yuja (Yuya Nishihara)
yuja added a comment. Queued, thanks. INLINE COMMENTS > cborutil.py:206 > +""" > +fn = STREAM_ENCODERS.get(v.__class__) > + Nit: We might have to support subtypes such as util.sortdict. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D3303 To:

D3303: cborutil: implement support for streaming encoding, bytestring decoding

2018-04-14 Thread indygreg (Gregory Szorc)
indygreg updated this revision to Diff 8301. REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D3303?vs=8152=8301 REVISION DETAIL https://phab.mercurial-scm.org/D3303 AFFECTED FILES contrib/import-checker.py mercurial/utils/cborutil.py

D3303: cborutil: implement support for streaming encoding, bytestring decoding

2018-04-14 Thread indygreg (Gregory Szorc)
indygreg added a comment. In https://phab.mercurial-scm.org/D3303#53422, @yuja wrote: > If it's just for date tuple, I have a patch to get rid of floating-point timestamps > as our timestamps should be effectively ints. I believe that's the only place we use floats. Or at

D3303: cborutil: implement support for streaming encoding, bytestring decoding

2018-04-13 Thread yuja (Yuya Nishihara)
yuja added a comment. > FWIW, the more I'm looking at the CBOR code, the more I'm thinking > we will end up having to reinvent the full wheel. Sounds reasonable to me. > We need to at least implement support encoding floats in order to > support -Tcbor. If it's just for

D3303: cborutil: implement support for streaming encoding, bytestring decoding

2018-04-13 Thread indygreg (Gregory Szorc)
indygreg added a comment. I ended up implementing my own CBOR encoder for a starting subset of types. Profiling the wire protocol server inspired me to do this. I have a future wire protocol command that emits the fulltext data of every file in a revision. It was taking ~45s CPU to run.

D3303: cborutil: implement support for streaming encoding, bytestring decoding

2018-04-13 Thread indygreg (Gregory Szorc)
indygreg updated this revision to Diff 8152. indygreg edited the summary of this revision. indygreg retitled this revision from "cborutil: implement support for indefinite length CBOR types" to "cborutil: implement support for streaming encoding, bytestring decoding". REPOSITORY rHG Mercurial