jackson-avro set bytes is failing - jackson-databind

I am using jackson-dataformat-avro and its failing when trying to set bytes in AvroParserImpl.java (setBytes method and failing in bb.remaining() as byteBuffer is null)
I am using JsonParser from 2.1.1 version of jackson-dataformat-avro
Do I need to set anything specific for avro bytes datatype in jackson ?
Any help will be much appreciated.

Related

Lua protobuf. pb package sends wrong encoded message if this message is empty

I've got a problem with using lua pb package.
pb.encode function encodes protobuf message in a wrong way if this message is described so:
message MyMessage
{
}
When I got the encoding message on server it differs from one that has at least one field.
What's wrong with pb ? Thanks

Error when converting form Python 2. to Python 3

can you help me to convert this to python 3.5 ? I tried but it don't work. I did the following steps:
I change the package md5 to hashlib
I change all the id = md5.new("%s"%str(clf.get_params())).hexdigest() to id = hashlib.md5(("%s"%str(clf.get_params())).encode('utf-8') ).hexdigest()
but I still have somme problems when I put a directory to these parameters
save_preds="",
save_params=""
save_test_only=""
clf_name="XX"
I have the folowing error when I put something in thise parameters:
TypeError: a bytes-like object is required, not 'str'
Please see the code here:
blend_proba.py
Thanks,
cdk
Replacing
clf_name="XX"
by
clf_name=b"XX"
would convert the strings into objects of type bytes. Whether those changes will be enough, I honestly have no idea.

QBO - Error while quering TaxRate with QB V3 API

I get an error while querying TaxeRate from QBO using QB API V3.
Here is my request:
String query = "Select * FROM TaxRate ";
List<? extends IEntity> result = service.executeQuery(query).getEntities();
below is what i get in return
Some other Exception in SDK or network happened: org.codehaus.jackson.map.JsonMappingException: Can not construct instance of com.intuit.ipp.data.SpecialTaxTypeEnum from String value 'NO_TAX': value not one of declared Enum instance names
at [Source: N/A; line: -1, column: -1] (through reference chain: com.intuit.ipp.data.TaxRate["SpecialTaxType"])
Can someone help me?
Thank you.
There is a server side change (Addition of a new Enum value) which is causing this devkit break. A newer version of devkit with latest changes (XSD) will be released soon. That will resolve the issue.
As a temporary workaround, you can try to call this without using devkit. Sample V3 call (using dev-defined) - https://gist.github.com/IntuitDeveloperRelations/0913b4c224de758fde0a
Update
This change might get rollbacked from the server side soon. In that case, current devkit will work as it is.

invalid request BLR at offset 163

I have the following error in the Firebird Database. version 2.5.2
invalid request BLR at offset 163
function F_ENCODEDATE is not defined
module name or entrypoint could not be found
Error while parsing procedure GETMONTHSBYYEAR's BLR
Until last week everything was functioning correctly. This UDF exists on the disk. How can I debug this problem? Anyone can help me to sort out this problem.
PS: What I did so far to fix:
Backup / restore - no result. (any structure problem is fixed in my opinion after a BK/Restore).
Comment all dependencies, drop UDF function, recreate again - no result.
Potential problems could be that he UDF dll is inaccessible for the server (eg due to permissions, or the UDF restriction config in firebird.conf), or you have installed a 64 bit version of Firebird and your UDF is 32 bit (or vice versa), so Firebird cannot load the DLL.

Delphi and XPath functions

Can I use Xpath node set function position() in Delphi's function selectNodes() to select only a certain number of element from a node list? If I do like this:
selectNodes('Item[1]')
its all fine and I get the element with index 1, but when I try
selectNodes('Item[position()<10]')
I get exception 'unknown method', when I try
selectNodes('Item[<10]')
I get 'unexpected token <'.
Im using delphi7 and I also imported new type library into my project with newer versions of msxml.
This is not really a Delphi question I think, but an MSXML one. Check the MSXML docs or rather the MS XPath docs.
Hmm, according to the XPath examples posted on MSDN "Item[position() < 10]" should have worked, at least if "Item" is the name of the element you're after...
selectNodes requires a string, so you should try:
selectNodes('Item[position()<10]')
Or whatever xpath query.
Could it be a version-issue? I have imported typelibrary from MS XML 6, and gets no error.

Resources