[go-nuts] Re: JSON Compare

2023-09-19 Thread Maxime Soulé
Hi,

You can have a look at go-testdeep [1] and its JSON [2] operator.
go-testddep is tailored for tests, but it provides EqDeeplyError [3] 
function that can perhaps be useful in your use case.

json1 := json.RawMessage(`{"foo":{"a":1}}`)
json2 := json.RawMessage(`{"foo":{"b":8}}`)
err := td.EqDeeplyError(json1, td.JSON(json2))

→ https://go.dev/play/p/6dtEB5lZOBG

Regards,

Max.

[1]: https://go-testdeep.zetta.rocks/
[2]: https://go-testdeep.zetta.rocks/operators/json/
[3]: https://pkg.go.dev/github.com/maxatome/go-testdeep/td#EqDeeplyError

Le lundi 18 septembre 2023 à 12:14:43 UTC+2, Corin Lawson a écrit :

> What makes you say the existing packages are not maintained?  They may 
> simply be complete?
>
> On Friday, 15 September 2023 at 5:05:10 am UTC+10 Sapna Jayavel wrote:
>
>> I am implementing a method find difference between two JSON objects and 
>> it has to drill down recursively. My usecase has very large nested JSON 
>> objects. Response should have the data that has changed between two JSON 
>> and position of the object. Do we have any Go package to support this?
>>
>> I looked at couple of packages available out there but seems ones are not 
>> currently maintained.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/30ea284b-254d-4fe7-b514-4762fd00b43an%40googlegroups.com.


[go-nuts] [ANN] GraphBLAS binding for Go

2023-09-19 Thread Pascal Costanza


Hi,


I am happy to announce a library that we have been working on at Intel.

It is a Go binding for the GraphBLAS  C API that 
calls into the widely used SuiteSparse:GraphBLAS C library.


You can find the Go binding at forGraphBLASGo 
 and some example algorithms at 
forLAGraphGo .


GraphBLAS is a specification for an API that defines standard building 
blocks for expressing graph algorithms in the language of linear algebra. 
It consists of data types for opaque representations of sparse matrices, 
vectors and scalars over the usual elementary types (Booloans, integers, 
floating point numbers), as well as user-defined element types. Operations 
on those data types include matrix-vector, vector-matrix, matrix-matrix 
multiplications, element-wise addition and multiplication, and so on. Apart 
from the usual integer and floating point addition and multiplication, 
client programs can use other arbitrary operators with these high-level 
operations, represented as monoids or semirings, to express a wide range of 
powerful algorithms.


SuiteSparse:GraphBLAS is a complete implementation of GraphBLAS in the C 
programming language. It is used heavily in production. For example, it is 
used as the underlying graph engine in FalkorDB (previously RedisGraph), 
and as the built-in sparse matrix multiply in MATLAB. Several bindings 
exist for SuiteSparse:GraphBLAS for Python, Julia, and PostgreSQL.


The forGraphBLASGo library is a binding that defines a Go API for GraphBLAS 
and the SuiteSparse:GraphBLAS extensions. It strives to adhere to Go 
programming style as much as possible. Most prominently, it uses type 
parameters that have been introduced in Go 1.18 to make the various 
GraphBLAS object types generic, for added type safety. Other supported Go 
features include: using multiple return values instead of reference 
parameters, and Go-style error handling.


We consider the forGraphBLASGo library as quite mature. However, we haven’t 
yet assigned the version number 1.0.0 to it yet. If you have any feedback 
or suggestions for improvement, please let us know.


The forLAGraphGo library is less mature and still work in progress.

Looking forward to hearing what you think about this library.


Thanks a lot,

Pascal

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/d2f081d8-d464-4228-bc5a-90c1b6e116e3n%40googlegroups.com.


Re: [go-nuts] Re: 'go run hello.go' taking ~30 seconds on windows

2023-09-19 Thread Hoo Luu
Windows defender slows apps first time ran. I had replaced several hard 
disks(HDDs and SSDs) and reinstalled OS systems(win7,win10,win11), nothing 
changed. After turning off  windows defender, everything returns to normal.

在2023年6月24日星期六 UTC+8 02:00:20 写道:

> Hi Declan,
>
> What's the full code? Also have you tried using 
> https://learn.microsoft.com/en-us/sysinternals/downloads/procmon and see 
> what it does? 
>
>
>
> On Friday, June 23, 2023 at 10:04:24 AM UTC+5:30 Henry wrote:
>
>> I am running Windows 11 with Kaspersky. I don't have such problems. When 
>> it comes to Windows, it isn't as simple as blaming your AV. Windows is a 
>> complex OS and it is doing many different things in the background (e.g. 
>> doing maintenance, installing updates, etc.).  You should open your Task 
>> Manager and see what is hogging your resources. You also need some decent 
>> hardware as Windows is a bit resource hungry. You may also check if there 
>> is an error with Windows itself. See  Using System File Checker in 
>> Windows - Microsoft Support 
>> 
>>
>> On Thursday, June 22, 2023 at 7:47:59 PM UTC+7 Jet Li wrote:
>>
>>> Like to note that if you mean Windows Defender, there is no way to 
>>> disable that after Build 20H2 iirc where I was task to deploy Windows 10 
>>> and could not find the option in Windows Group Policy settings after the 
>>> update, if Go app are affected by Windows Defender. Your only option is to 
>>> use older Windows build and alternative OS, mileage may vary.
>>>
>>> Another option, could be impossible to backup VM image as it's on macOS
>>> https://multipass.run/
>>> On Thursday, 22 June 2023 at 19:52:56 UTC+8 Wojciech S. Czarnecki wrote:
>>>
 Dnia 2023-06-18, o godz. 22:52:58 
 tokintmash  napisał(a): 

 > Hello, 
 > 
 > Was there a solution to this? I am having the same issue. Win 10 
 machine 
 > and compiling and running simple lines of code takes ages. 

 The answer is always the same: turn off your antivirus software for 
 your development tree. 

 Such delays are due to "heuristics" usually implemented by uploading 
 your exe to the vendor. 
 Root cause is that after 12 years AV vendors still can not cope with 
 what they pereceive 
 a "non standard" linker, ie. a Go's one. 

 hope this helps, 

 -- 
 Wojciech S. Czarnecki 
 << ^oo^ >> OHIR-RIPE 

>>>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/2dcbf249-88d0-4bbd-a0fd-2d3b11d3ea8bn%40googlegroups.com.