New "xs:date" XSD types are including time info from .NET DateTime values

Description
If an XSD schema document has an element or attribute that is defined as "xs:date" type, the FSharp.Data.Xsd library puts DateTime values ("xs:dateTime") instead of date-only values.
Please note that I am explicitly referring to the MySchemaType.MyElement(prop1 = someValue;) method of creating objects. In this case, if prop1 is defined in the XSD as "xs:date", passing a .NET DateTime value in will result in the XElement being created with date and time information...when, acccording to the XSD document, it should be only a date value.
When creating new objects using MySchemaType.MyElement(XElement) works correctly...but only if the XElement already has the correct syntax (i.e., uses a Date-only value rather than DateTime value).  I do not necessarily expect that the library will fix invalid XElement values in this situation, although it might be nice to raise some sort of warning. Overall, I expect the library to adhere to the type definitions in the XSD document and inserting date+time when the XSD explicitly defines date-only values is incorrect behavior.
Repro steps
#r "System.Xml.Linq.dll"
#r "FSharp.Data.Xsd.dll"

open System
open FSharp.Data

type Sample = XmlProvider<Schema = """
  <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
    elementFormDefault="qualified" attributeFormDefault="unqualified">
    <xs:element name="foo">
      <xs:complexType>
        <xs:attribute name="baz" type="xs:date" />
      </xs:complexType>
    </xs:element>
  </xs:schema>""">

let createUsingProps : Sample.Foo = Sample.Foo( DateTime.Now.Date |> Some )
let createUsingXelement : Sample.Foo = Sample.Parse """<foo baz="2018-05-02" />"""

createUsingProps.XElement |> sprintf "Using props method:\n%A"
createUsingXelement.XElement |> sprintf "Using XElement method:\n%A"

(*
>
val it : string =
  "Using props method:
<foo baz="2018-05-02T00:00:00.0000000-04:00" />"
>
val it : string = "Using XElement method:
<foo baz="2018-05-02" />"
>
*)

Expected behavior
That the library would use the"xs:date" type defined in the XSD document when creating new objects.
Actual behavior
The library actually uses a "xs:datetime" type when creating new objects using properties.
Known workarounds
Creating new objects using MySchemaType.MyElement(XElement) works correctly...but only if the XElement already has the correct syntax (i.e., uses a Date-only value rather than DateTime value).
Related information

.NET Framework: 4.5.2
FSharp.Data.Xsd: <IP_ADDRESS>
Windows 10 operating system

I think this may be a bug coming from one of the FSharp.Data XML References.

Wow, okay,...I knew that .NET lacks a Date-only type (I think NodaTime adds one) but I didn't know that Microsoft didn't even have a standard way of dealing with date-only types defined in XSDs. Interesting.
Will using a string type introduce date format issues with regards to localization, etc.?

Date seems pretty standard and easy to output as if it were a string https://www.w3schools.com/xml/schema_dtypes_date.asp

I'm closing this because XSD is now available in F# Data (where some improvements have been made on date handling).


mvn test fails

While rebasing on latest master, our release jobs failed
java.io.FileNotFoundException: file://some/path/pinot/pinot-integration-tests/target/pinot-integration-tests-0.3.0-SNAPSHOT-tests.jar!/On_Time_On_Time_Performance_2014_100k_subset_nonulls.schema (No such file or directory) 51460         at java.io.FileInputStream.open0(Native Method) 51461         at java.io.FileInputStream.open(FileInputStream.java:195) 51462         at java.io.FileInputStream.<init>(FileInputStream.java:138) 51463         at com.fasterxml.jackson.core.JsonFactory.createParser(JsonFactory.java:766) 51464         at com.fasterxml.jackson.databind.ObjectReader.readValue(ObjectReader.java:1262) 51465         at org.apache.pinot.spi.utils.JsonUtils.fileToObject(JsonUtils.java:68) 51466         at org.apache.pinot.spi.data.Schema.fromFile(Schema.java:75) 51467         at org.apache.pinot.integration.tests.HadoopSegmentBuildPushOfflineClusterIntegrationTest.setUp(HadoopSegmentBuildPushOfflineClusterIntegrationTest.java:94)
This can also be reproduced locally by doing mvn test.
It looks like getClassLoader().getResource(getSchemaFileName()) works as long as the resource is a physical file. In this case, the resource is a schema file in the test-jar produced when pinot-integration-tests module was built -- this is why there is an exclamation mark in the path at the end of jar file name.
This link seems to suggest that we should be doing getResourceAsStream() in such cases when the resource file is inside a bundled jar.
https://stackoverflow.com/questions/26675048/classloader-getresource-doesnt-work-in-jar-file/26675158
One another way is to probably copy this schema file in src/test/resources folder for pinot-hadoop module.

@fx19880617  any suggestions?

I feel it's better to use getResourceAsStream if it could read the schema file from pinot-integration-tests jar


read version from package.json

I want to get version from package.json
I use

const version = require(path).version;
Who know this path?

https://github.com/electron/electron/issues/7085

@develar thank you for you replay.
I find way like this
`
import {version} from '../../../package.json';
export default class loadingService extends ILoading {
constructor() {
    super();
}

async getVersion() {
    return version;
}

}
`

I recommend you to use app.getVersion() if you only need to get app version.


Retired item text not displaying on retired items in the Orchestrator

Further to our conversation earlier, Griffiths Eye and Hand Co-ordination Scale Score is showing as retired in Mauro:

The Orchestrator shows the item as retired but the retired text isn't showing:

The retired text now displays in the Orchestrator. However, the short description is still the old one:

Other items have: "This item has been retired from the NHS Data Model and Dictionary.", for example:

10/06/24 - tested this again today and it isn't working. Will test again when the preview in the Orchestrator is working

Just to note this is still an issue we have on our backlog to investigate:

MauroDataMapper-NHSD/mdm-plugin-nhs-data-dictionary#36

19/08/24 - System C are working on this.

Tested today and still isn't working.

System C are still working on this.

This issue has been fixed and deployed to TEST, TRAINING and LIVE. Please move this to the "Ready for NHS E Testing" state.

To test, change an item's status between retired and not-retired, then check the preview of the item. I usually open two tabs for the same item - one in Mauro, one in Orchestrator preview - then make changes in one and refresh the preview in the other.

The retired text is showing but the short description is now not showing at all. Previously, as above, it showed the old one.

Items are showing as having failed the Short Description integrity check when they are retired items. Has this been caused by the issue above?

I will investigate, but I see no problems when I test in my local environment.
Track via:

MauroDataMapper-NHSD/mdm-plugin-nhs-data-dictionary#124

I've fixed this directly on your TEST environment, the PATIENT DIAGNOSIS INDICATOR (DEMENTIA) element now looks like this when retired:

The problem was the retired template you were using:

I looked at it and the template was missing an end angle bracket ">", meaning it was invalid HTML. I fixed it for you and the short description works as expected now.


Wont display nubmered lists

Hey your theme does not seem to want to display numbered lists.  Other themes work fine.

My B. Should be fixed in latest commit.


fish: Unknown command 'npm' when using .fnmrc

#42 Hi! I've been using fish for about a year, and your package is a life saver! Thanks so much 🙏 I'm seeing an issue where a .fnmrc (or .nvmrc, .node-version) breaks my npm. Interestingly, the node executable works.
$ npm i
fish: Unknown command 'npm'
~/.config/fish/functions/__fnm_run_bin_as.fish (line 52):
        command npm $argv
                ^
in function '__fnm_run_bin_as'
        called on line 2 of file ~/.config/fish/functions/./npm.fish
        with parameter list 'npm i'

in function 'npm'
        called on standard input
        with parameter list 'i'
$ node -v
v8.10.0
$ which node
 #/Users/dean/.config/fnm/bin/node
$ which npm
$
$ tree ~/.config/fnm
/Users/qxr9638/.config/fnm
├── bin
│   ├── node
│   ├── npm -> ../lib/node_modules/npm/bin/npm-cli.js
│   └── npx -> ../lib/node_modules/npm/bin/npx-cli.js
├── etc
└── versions
    └── 8.9.4

3 directories, 4 files

If I install using the fnm command, it works fine. It looks like my install is having some confusing between the config and cache dir.
What could I provide to make this easier to debug?

Nope, I stopped using fnm for these projects.

I'm having exactly the same issue.
I don't remember when the issue occurs...
I managed to escape the state by uninstalling the fnm, remove fnm's directory & reinstall fnm.
$ npm -v
fish: Unknown command 'npm'
~/.config/fish/functions/__fnm_run_bin_as.fish (line 52):
        command npm $argv
                ^
in function '__fnm_run_bin_as'
        called on line 2 of file ~/.config/fish/functions/npm.fish
        with parameter list 'npm'

in function 'npm'
        called on standard input
$ fisher uninstall fnm
$ cd /Users/(myUserName)/.config/
$ rm -rf fnm
$ fisher fnm
$ fnm latest
$ npm -v
6.4.1

Environmental Info
Mac OS High Sierra 10.13.6
fisherman version 2.13.2 ~/.config/fish/functions/fisher.fish
fnm v1.8.3

I have the same issue since I set up everything from scratch because I got a new MBP.

macOS Mojave 10.14 (18A391)
fish, version 2.7.1

installed via brew install fish

fisher version 3.1.1 ~/.config/fish/functions/fisher.fish

installed via curl https://git.io/fisher --create-dirs -sLo ~/.config/fish/functions/fisher.fish

fnm v1.8.3

installed fisher add fisherman/fnm

$ fnm ls
  ...
  8.10.0
  ...
  • 11.0.0

On my Mac Pro with the same versions in place, I don't have this issue.

I've switched to using https://github.com/asdf-vm/asdf for a global version manager.


README instructions failed

I went through the README following the directions on how to set up the repo for development, however when I ran npm run build I would keep getting the error that a build script was not found. Is the README outdated?

Yes, I was actually working on that when this issue was posted: https://github.com/Microsoft/PowerBI-visuals-TimeBrush/pull/27
Until that gets merged, you'll need to install yarn and lerna (npm install -g<EMAIL_ADDRESS>When you have those installed, you just need to run
lerna --scope @essex/timebrush run test && lerna run test --ignore @essex/timebrush.
This will produce a pbiviz in the packages/timebrush-powerbi/dist directory.
With the pull request, I'm also going to be adding some convenience scripts, so in the future, all you'll need to do is run, yarn test from the root.

I'm having trouble with the current develop branch (phantomjs isn't playing nicely with karma) - is there a way (even hacky) for me to build the pbiviz file without testing first?

@kodonnell I've made an update to fix the tests, let me know if that fixes it.

Nice - fixed.


Add a "change" function for callbacks

While I was working on a project I was trying to get a navigation bar to stay in a fixed place after the slideout was closed, but this functionality was broken after opening the slideout. It was convenient to create a change function that would run through its callbacks only after the transition finished.
I figured that others might find this useful so I figured I'd submit it. I wasn't sure how what the standards here for minified code are here so I haven't submitted a minified version (I could add a commit later with the min version if I know what I should use for this project).

Hi @burz thanks for the pull request, really apreciated. I'm gonna close it, we think an event driven approach make sense for this. Please see https://github.com/Mango/slideout/tree/feature-add-slideout-events.

btw, you'll have the same (and even more) control over the slideout with the proposed events.


fix: [#4582] UserAssignedIdentity(WorkloadIdentity) auth fails with 'scope https://api.botframework.com is not valid'

Fixes # 4582
#minor
Description
This PR adds the /.default suffix to the scope for MSI communication.
Specific Changes

Updated ManagedIdentityAuthenticator to add the suffix to the scope.

Testing
These images show the fix working with a bot deployed in AKS and another one deployed in an Azure App Service.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.4%) to 84.124%

Totals

Change from base Build<PHONE_NUMBER>:
-0.4%

Covered Lines:
20332

Relevant Lines:
22880

💛  - Coveralls

/promoted 4607


proposal: reflect: allow creation of recursive types

Introduction
In #20013, @ben-clayton asked for runtime creation of recursive structs. The analogous issue arises with several other constructions which are legal at compile time, e. g.:
type A [42]*A
type C chan C
type F func(F) F
type M map[string]M
type P *P
type S []S

While these specific definitions are not as useful at the top-level as a struct, combinations can be, e. g.
type L struct {
  Value interface{}
  Next *L
  Snitch chan L
}

or
type T []struct{ Edge interface{}; Out T }

The issue is related to #16522, where @crawshaw proposes an API to create a named type with a method set. In that issue, @cosmos72 observed that the proposed API would not allow for the creation of recursive types, and also referenced https://golang.org/pkg/go/types/#Named, where recursive named types can be represented in a two-step process. In #16522, it was also observed that the implementation of a runtime method set is met with certain challenges, so this proposal will concentrate on recursive types while leaving the door open for the core concern of #16522.
Proposal
This issue proposes an API for a two-step process of runtime recursive type creation similar to, but not quite analogous to https://golang.org/pkg/go/types/#Named. The first step is to create an incomplete named type which can only be used in certain restricted contexts until it is completed in the second step by binding the name to an underlying type specification, in analogy to a compile-time type declaration.
// Named creates a new incomplete type with the specified valid name.
// An invalid name causes Named to panic.
//
// The resulting type can be used as an argument to ArrayOf, ChanOf, FuncOf, MapOf,
// PtrTo, SliceOf, and StructOf whenever the analogous compile-time type specification
// in a type declaration would result in a valid recursive type. Invalid combinations
// cause Named to panic. E. g., passing an incomplete type to ArrayOf is invalid,
// but passing an incomplete type to PtrTo and then that type to ArrayOf is valid.
//
// Any such type, including the incomplete named type itself, may not be used in any
// other context until it has been completed with Bind. A future version may relax
// this requirement (e. g., allow use in MakeFunc before calling Bind).
func Named(name string) Type

// Bind binds the specified incomplete named type to underlying akin to a valid type
// declaration and returns a completed version of named. The underlying type may
// indirectly reference the named type, but no
// other incomplete type created with Named. A Bind which represents an illegal
// type declaration panics.
//
// Currently, adding a method set to named is not supported and methods must be nil.
// This limitation may be lifted in a future version.
func Bind(named Type, underlying Type, methods []Method) Type

(edit: changed return value of Bind)
Here, the methods would only be added at the Bind stage (in a future version), so that they can refer to named.
Open questions

What is a valid name for Named? The spec suggests letter { letter | unicode_digit }, but that may be expensive to check. Also, should the name be the name of an exported type?
What should the PkgPath() method of the created type return? Probably an empty string, but could also be a pseudo package name where all the types created at runtime end up in.
What should the Kind() method of the named type return before Bind? Of the existing kinds, only Invalid makes sense. Could introduce a new kind, or use the tflags to mark the type incomplete.
(edit: added) goroutine safety: probably the new type won't be intrinsically goroutine-safe until Bind has been called on it.

Good to hear that I am not the only one interested in adding this feature! :)
Some days ago I had almost exactly the same idea, with some minor differences:
// create a new, incomplete, named Type with Kind = Invalid.
// the parameter 'pkgpath string' is stored in the type, but does not grant any special permission:
// for example, creating a type in package "runtime" does not give it access to the package's
// unexported symbols.
// TBD: decide: accept or reject pkgpath+name equal to a pre-existing type?
func NewNamed(pkgpath string, name string) Type

// must be called exactly once before Complete()
func SetUnderlying(named Type, underlying Type)

// cannot be implemented yet because of API/ABI limitations... I would keep this for later
// func AddMethod(named Type, method Method)

// must be called exactly once to "freeze" the type and make it immutable,
// internally it will mark the type as complete and make it fully usable as any other reflect.Type
func Complete(named Type)

@cosmos72 The creation process is already quite involved, what with the invening calls to the PtrTo and SomethingOf functions, so I don't see a problem splitting my Bind up into the functions in your proposal.
The important thing, I think, is that there is a point when the new type is final (my Bind or your Complete); I've added an open question regarding goroutine-safety to my original proposal.
Maybe the next logical step is to see whether our proposals can be implemented without too much hassle.

I had a cursory glance at reflect/type.go and learned that while the dynamic type of a valid Type is *rtype, the object behind the pointer can be different in size for different types, so I think from an implementation standpoint, it's easier if Bind returns a completely new type instead of trying to alter the named argument. I've edited the proposal accordingly.

Yes, reflect.Type internals are quite complicated because they are heavily optimized to reduce memory usage.
There is also a property of reflect.Type that would cause a lot of problems with your last suggestion that Bind() should return a completely new type instead of trying to alter the named argument:
https://golang.org/pkg/reflect/#Type states:
Type values are comparable, such as with the == operator, so they can be used as map keys. Two Type values are equal if they represent identical types.
I hope I'm wrong, but trying to imagine how Named() and Bind() interact with such guarantee, I think you will see that having around two objects representing the same type (one returned by Named() and possibly used to construct other types, for example with PtrTo or one of the *Of functions, the other returned by Bind()) is a source of troubles.

True. One possible solution is that this guarantee simply does not hold until Bind returns. So the Type returned by Named would be just a placeholder, to be used in the *Of functions only, not to be used as map key or in any other context. After Bind, the placeholder cannot be used any more, the new returned Type has to be used instead.
This also means that Bind has to walk recursively through the underlying type and replace all references to the placeholder with the real thing, possibly updating the type cache on the way.
I guess a similar situation arises with goroutine-safety. Probably the involved types do not become goroutine-safe until Bind returns.

What about Go 1.x compatibility promise ?
I am quite sure it also covers the statement cited above:
https://golang.org/pkg/reflect/#Type
"Type values are comparable, such as with the == operator, so they can be used as map keys. Two Type values are equal if they represent identical types."

which you suggest to break.
That's why I preferred your original proposal:
it required internal changes to reflect.Type to allow creating a *reflect.rtype without knowing in advance whether it will describe a struct, map, func or one of the other possible kinds - and instead deciding it later, with Bind or SetUnderlying.
As a consequence, the current technique allocating in a single step reflect.rtype plus its auxiliary (kind-dependent) information could probably not be reused in this case, and an additional layout would probably be needed - a kind of "rtypeUnion" with the ability to contain all the information needed by the different kinds.
But whatever the required changes are - and they could be complicated - they would be internal to the package reflect, and not visible from outside.
I am worried your idea that "Bind has to walk recursively through the underlying type and replace all references to the placeholder with the real thing, possibly updating the type cache on the way"

is quite expensive CPU-wise
falls short on preserving Go compatibility promise, because the placeholder type could be already in the hands of user code, thus breaking the guarantee that Type is comparable with ==

What about Go 1.x compatibility promise ?

Is there any way to gain access to a reflect.Type returned by Named which is outside the control of the caller of Named? If not, I'm not worried about compatibility issues. Named and Bind are a new API with a special, restrictive contract: users of this API have to keep the reflect.Type returned by Named and all derived types close, but once Bind has returned, the returned type as well as the derived types enjoy all the usual guarantees and can be given to other user code. The named argument must never get into the hands of user code and should be thrown away and forgotten after Bind, though.
This way, older source will continue to compile and run as laid out in the compatibility guidelines.

I am worried that your idea "Bind has to walk recursively through the underlying type and replace all references to the placeholder with the real thing, possibly updating the type cache on the way"

is quite expensive CPU-wise

I've had another look at the code and apparently these caches are for the benefit of the *Of functions only. So I don't think the cache has to be touched. That should make the process no more CPU intensive than the work a compiler has to do when it parses a recursive type definition.

If my assumption above about being able to keep the return value of Named close is not correct, then things become difficult. I don't think a "rtypeUnion"-approach would work well (at least not without revamping the internal type system) as some types may require a lot of space (for example, the tail of a function type is an array of *rtype pointers representing the all argument and return types) and you would have to allocate space for the largest possible type. In this case, it would be better if there was some way of asking the gc to explicitly resize a specific block and update all pointers to it, or may do allocate a lot of space and shrink later, without updating any pointers. This is just guesswork, though. I have no clue how the internal go memory system works.

I'm not sure what you mean by keeping a value close.  Certainly once a program has a reflect.Type created by reflect.Named it can call reflect.Zero(t).Interface() to get a value of type interface{}, and the program can do anything with the value, including passing it some other package.  That other package can then call reflect.TypeOf on the value to retrieve the reflect.Type created by reflect.Name.  For example, this would likely happen if the value were passed to encoding/json.

I'm not sure what you mean by keeping a value close. Certainly once a program has a reflect.Type created by reflect.Named it can call reflect.Zero(t).Interface() to get a value of type interface{}, and the program can do anything with the value, including passing it some other package. That other package can then call reflect.TypeOf on the value to retrieve the reflect.Type created by reflect.Name. For example, this would likely happen if the value were passed to encoding/json.

The idea is that there is a special contract for callers of reflect.Named. Callers promise they won't, directly or indirectly, pass the returned reflect.Type, or any type derived from that reflect.Type via reflect.PtrTo or one of the reflect.KindOf functions, to any functions or methods defined in the reflect package, except as prescribed in the description of reflect.Named. Only the return value of reflect.Bind is no longer bound by this special contract and may be passed around freely.
Now, this contract is not enforceable at the language level. If someone wants to shoot themselves in the foot, they certainly can pass a reflect.Type returned by reflect.Named to reflect.Zero — and suffer the consequences (for a deterministic outcome, the implementation could raise a panic in such a case). It's more of a C-style contract, "if you don't do as prescribed here, the behaviour is undefined".
Is such a contract acceptable for the Go community? From your and @cosmos72's comments I get the notion the answer is "no". Is that correct? If so, we need an API which avoids these "special" reflect.Type instances altogether. I'll write another proposal later.

The idea is that there is a special contract for callers of reflect.Named. Callers promise they won't, directly or indirectly, pass the returned reflect.Type, or any type derived from that reflect.Type via reflect.PtrTo or one of the reflect._Kind_Of functions, to any functions or methods defined in the reflect package, except as prescribed in the description of reflect.Named. Only the return value of reflect.Bind is no longer bound by this special contract and may be passed around freely.

And operator== would not have the usual meaning on the Type returned by Named: it's an "incomplete type" different from anything else, including from the completed version of itself.
And the Type returned by Named should not be passed to Go code that is not aware of such special contract - which means all existing Go code that (potentially) deals with reflect.Type
All in all, it seems an API easy to use incorrectly, and such misuses are difficult to detect.
That's why I prefer the initial proposal, where Bind or SetUnderlying simply modify the first argument - i.e. the Type returned by Named - instead of creating a new Type.

Also, operator== would not have the usual meaning on the Type returned by Named: it's an "incomplete type" different from anything else, including from the completed version of itself.
Also, the Type returned by Named should not be passed to Go code that is not aware of such special contract - which means all existing Go code that (potentially) deals with reflect.Type
All in all, it seems an API easy to use incorrectly, and such misuses are difficult to detect.
That's why I prefer the initial proposal, where Bind or SetUnderlying simply modify the first argument - i.e. the Type returned by Named - instead of creating a new Type.

OK, but even with an in-place modification, the reflect.Type returned by reflect.Named would not be allowed to be passed to most functions before reflect.Bind has returned. That's why I wanted to write another proposal to avoid this problem altogether.
FWIW, I implemented the proposal in this issue here: https://github.com/TheCount/go/tree/issue-39528. If you think it's worthwhile pursuing, maybe you can try to change my implementation to an in-place modification (I don't know how to do that, I guess you'd have to somehow interact with the memory management system).

OK, but even with an in-place modification, the reflect.Type returned by reflect.Named would not be allowed to be passed to most functions before reflect.Bind has returned.

True, an incomplete type can only be used in few cases. Mostly to build other types.

That's why I wanted to write another proposal to avoid this problem altogether.

I understand the reason, but it had the side effect of creating a reflect.Type which is and always remains incomplete.

FWIW, I implemented the proposal in this issue here: https://github.com/TheCount/go/tree/issue-39528. If you think it's worthwhile pursuing, maybe you can try to change my implementation to an in-place modification (I don't know how to do that, I guess you'd have to somehow interact with the memory management system).

I have a draft implementation using in-place modification.
The in-place modification itself is relatively simple... the hard part is tracking all types derived from the newly created one to complete them as soon as possible: after
var t = reflect.Named("foo")
var arrayOfT = reflect.ArrayOf(42, t)
reflect.Bind(t, reflect.TypeOf(int(0)))

both t and arrayOfT must be updated by computing their size, GC information and mark them as complete

That's why I wanted to write another proposal to avoid this problem altogether.

I understand the reason, but it had the side effect of creating a reflect.Type which is and always remains incomplete - not just for a limited time.

Small misunderstanding here. I meant I wanted to write (yet) another proposal which avoids even the problem of the limited incompleteness between reflect.Named and reflect.Bind.

I have a draft implementation using in-place modification (UPDATE: published at cosmos72@b010cd5)
The in-place modification itself is relatively simple... the hard part is tracking all types derived from the newly created one abd completing them as soon as possible (not implemented yet):
after
var t = reflect.Named("foo")
var arrayOfT = reflect.ArrayOf(42, t)
reflect.Bind(t, reflect.TypeOf(int(0)))

both t and arrayOfT must be updated by computing their size, GC information and mark them as complete.
And with mutually recursive types it gets more complicated.

In your draft, you define your wrapper type as
type wrapperType struct {
	rtype
	uncommon uncommonType
	under    *rtype
}

How do you go from this to the memory layout of the finished type as the runtime expects it? For example, a function type in memory would look like (pseudocode):
struct {
  rtype
  numIn, numOut uint16
  uncommonType
  [numIn+numOut]*rtype
}

Since you can't know numIn+numOut at the time you allocate the memory for wrapperType, it's difficult to allocate the correct amount for it. (Asking the caller of NewNamed for a hint and panicking in Complete if the hint was wrong might be a practical if slightly awkward solution).

In your draft, you define your wrapper type as
type wrapperType struct {
	rtype
	uncommon uncommonType
	under    *rtype
}

How do you go from this to the memory layout of the finished type as the runtime expects it? For example, a function type in memory would look like (pseudocode):
struct {
  rtype
  numIn, numOut uint16
  uncommonType
  [numIn+numOut]*rtype
}

Since you can't know numIn+numOut at the time you allocate the memory for wrapperType, it's difficult to allocate the correct amount for it. (Asking the caller of NewNamed for a hint and panicking in Complete if the hint was wrong might be a practical if slightly awkward solution.)

That's not necessary. A patched implementation of reflect.Type.Field would be:
func (t *rtype) Field(i int) StructField {
	if t.Kind() != Struct {
		panic("reflect: Field of non-struct type " + t.String())
	}
	if t.tflag&tflagWrapper != 0 {
		t = (*wrapperType)(unsafe.Pointer(t)).underlying("Field")
	}
	tt := (*structType)(unsafe.Pointer(t))
	return tt.Field(i)
}

The idea is to forward (almost) any call to the underlying type, which has the correct layout.

The idea is to forward (almost) any call to the underlying type, which has the correct layout.

OK, I think I understand now. You introduce a completely new "proxy" layout. That means of course checking and updating all parts of the Go source code where a pattern like
var t reflect.Type
…
explicit := *(**expectedLayout)(unsafe.Pointer(&t))

is used. Possibly also third-party tools. But nothing covered by the Go compatibility promise.

Partially constructed types are definitely a major disadvantage. Then everything that accepts a reflect.Type has to guard against them. Given that you've opened the other issue, let's close this one as a duplicate of #39717.


[Zeroconf] WebThings are discoverable using mDNS|SD

Is your feature request related to a problem? Please describe.
A side-benefit of the Zeroconf Protocol Implementation is that Zeroconf enables discovery of any device (services) published using mDNS|DNS-SD.
Revisiting the new (!) WebThings (formerly Mozilla's WebThings), I was heartened to discover that WebThings' devices are published using mDNS|DNS-SD described in the Draft spec here
Unfortunately, there's an issue with the Rust SDK but devices written using other SDKs work as expected. Here using avahi-browse to observe a device published using the WebThings Python sample:
avahi-browse --all
+ enp5s0 IPv6 LightAndTempDevice                            _webthing._tcp       local
- enp5s0 IPv6 LightAndTempDevice                            _webthing._tcp       local

Is your feature request related to a way you would like Akri extended? Please describe.
Zeroconf Protocol implementation provides the foundation for discovery of WebThings devices.
Describe the solution you'd like
Zeroconf Protocol implementation provides the foundation for discovery of WebThings devices.
Describe alternatives you've considered
N/A

This should now be working for devices developed using any of WebThings SDKs; there was an issue with the Rust SDK that is now resolved.
For example, using the non-TLS example described in the Rust SDK:
cargo run
setting new humidity level: 12.535304069519043
setting new humidity level: 2.093383550643921
setting new humidity level: 14.57203483581543
setting new humidity level: 2.1968395709991455
setting new humidity level: 2.9822685718536377

Then:
avahi-browse --all | grep _webthing._tcp
IPv4 LightAndTempDevice         _webthing._tcp       local

NOTE The WebThings examples creates ThingsType::Multiple(things, "LightAndTempDevice".to_owned())

Add it to your Gateway per the instructions.
The Gateway uses mDNS|SD browsing and should find 2 devices on LightAndTempDevice: My Lamp, My Humidity Sensor
Here's the Lamp:

Then, apply the following Akri Zeroconf Configuration to a cluster:
apiVersion: akri.sh/v0
kind: Configuration
metadata:
  name: webthings
spec:
  protocol:
    zeroconf:
      kind: "_webthing._tcp"
      port: 8888
  capacity: 1
  brokerPodSpec:
    containers:
      - name: broker
        image: ghcr.io/deislabs/akri/zeroconf-broker:v1 # This repository does not yet exist
        resources:
          limits:
            "{{PLACEHOLDER}}": "1"

And:
kubectl get configuration
NAME        CAPACITY   AGE
webthings   1          2s

kubectl get instances
NAME               CONFIG      SHARED   NODES    AGE
webthings-d6097c   webthings   true     [akri]   4s

Wait for Akri to create the Broker Pod:
kubectl get instances \
--output=jsonpath="{.items[*].spec.metadata.AKRI_ZEROCONF_DEVICE_NAME}"
LightAndTempDevice

And, lastly:
for INSTANCE in $(kubectl get instances --output=jsonpath="{.items[*].metadata.name}")
do
  POD="pod/akri-${INSTANCE}-pod"
  kubectl logs ${POD}
done
[zeroconf:main] Entered
[zeroconf:new] Entered
[zeroconf:main] Service: kind: _webthing._tcp
name: LightAndTempDevice
host: akri.local
addr: <IP_ADDRESS>
port: 8888
TXTs:
  AKRI_ZEROCONF_DEVICE_PATH: /

[zeroconf:main:loop] Sleep
[zeroconf:main:loop] check_device(Service { kind: "_webthing._tcp", name: "LightAndTempDevice", host: "akri.local", addr: "<IP_ADDRESS>", port: 8888, txts: Some({"AKRI_ZEROCONF_DEVICE_PATH": "/"}) })
[zeroconf:read_device] Entered: Service { kind: "_webthing._tcp", name: "LightAndTempDevice", host: "akri.local", addr: "<IP_ADDRESS>", port: 8888, txts: Some({"AKRI_ZEROCONF_DEVICE_PATH": "/"}) }
[zeroconf:main:loop] Sleep
[zeroconf:main:loop] check_device(Service { kind: "_webthing._tcp", name: "LightAndTempDevice", host: "akri.local", addr: "<IP_ADDRESS>", port: 8888, txts: Some({"AKRI_ZEROCONF_DEVICE_PATH": "/"}) })
[zeroconf:read_device] Entered: Service { kind: "_webthing._tcp", name: "LightAndTempDevice", host: "akri.local", addr: "<IP_ADDRESS>", port: 8888, txts: Some({"AKRI_ZEROCONF_DEVICE_PATH": "/"}) }
[zeroconf:main:loop] Sleep

And:
kubectl exec --stdin --tty ${POD} -- env | grep ^AKRI
AKRI_ZEROCONF_DEVICE_NAME=LightAndTempDevice
AKRI_ZEROCONF_DEVICE_KIND=_webthing._tcp
AKRI_ZEROCONF_DEVICE_ADDR=<IP_ADDRESS>
AKRI_ZEROCONF_DEVICE_PATH=/
AKRI_ZEROCONF=zeroconf
AKRI_ZEROCONF_DEVICE_HOST=akri.local
AKRI_ZEROCONF_DEVICE_PORT=8888

NOTE WebThings adds a TXT record path="/" to the service name referencing the device's path. The Akri Zeroconf protocol handler transfers this to an environment variable AKRI_ZEROCONF_DEVICE_PATH which we'll use below to construct the correct URL to access the device.

And, you can:
kubectl exec --stdin --tty ${POD} -- sh
apt update && apt install -y curl
curl ${AKRI_ZEROCONF_DEVICE_ADDR}:${AKRI_ZEROCONF_DEVICE_PORT}${AKRI_ZEROCONF_DEVICE_PATH} \
| jq -r .[].title
My Lamp
My Humidity Sensor

NOTE DNS-SD aren't exposed directly as host names so we use AKRI_ZEROCONF_DEVICE_ADDR rather than AKRI_ZEROCONF_DEVICE_NAME with curl. If you use a DNS-SD client, you can use the name.

Do I read this correctly that the zeroconf implementation also serves as a WebThings implementation?  That is awesome!!  I can't wait to get the extensibility model fixed up to merge zeroconf!!

Yes :-)
I'm contemplating (!) implementing the Akri "Distribution of Vaccines" scenario by writing WebThings for e.g. vaccine refrigerators and trucks. It may be overkill but it'd be a double whammy of an industrial application using WebThings and a neat scenario for Akri.

We fixed the WebThings Rust SDK so devices built with it, publish mDNS|SD correctly.

We fixed the WebThings Rust SDK so devices built with it, publish mDNS|SD correctly.

Awesome!!

Awesome!!

Per thread above, this has been fixed.


new Form generator error

HI
In the new version in generating new admin_model
when adding more than one item you get this error
Undefined offset: 0
in :…/app/Application/Controllers/Admin/CommandsController.php   line 128
if ($request->colsName) {
$count = 0;
foreach ($request->colsName as $key => $cols) {
$count++;
$lang = $request->lang[$key] == 0 ? 'false' : 'true';
$validation = $this->handelValidation($request->validation[$key], $request->validationVal[$key]);
            $colsOption .= $cols . ':' . $request->migration[$key] . ':' . $validation . ':' . $lang;
            if ($count != count($request->colsName)) {
                $colsOption .= ',';
            }
        }
    }

can you give me the fields you add
to test this case

Ok
I added one field Table Called Owner with multiple fields, That went OK,
I trued to add another Table named Product
fileds owner_id, and name,
and that gave error I mentioned

you must check the max check box
if you put value in the text box
and we will push the fix soon

Hi
I did that but still same prb,
Maybe if I re install the laraflat system will fix, but I thought you ought to know the prb.

you can see where the error comes from,
if you take your  line
" $validation = $this->handelValidation($request->validation[$key], $request->validationVal[$key]); "
in the loop when $key from ( $request->colsName ) = 0.
in $request->validation[$key]  does not have 0 as key as you can see from the array in the image,
it has only 1 and 5, as I have only selected validation on the second column and the last one.
Now if I checkbox any validation in all columns it will work, but if I drop validation for any column it will throw an error.
God Bless.

its must work now
just pull new project
thanks for help


[FLINK-18002][json] Correct the behavior for ContainerNode as varchar…

… type

What is the purpose of the change
Correct the behavior when specifying ContainerNode as varchar type in json.
Brief change log

Change JsonRowDataDeserializationSchema to cover this case.
Change JsonRowDeserializationSchema to cover this case.

Verifying this change
This change added tests and can be verified as follows:

JsonRowDeserializationSchemaTest.testJsonParse()
JsonRowDataSerDeSchemaTest.testJsonParse()

Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency): (yes / no)
The public API, i.e., is any changed class annotated with @Public(Evolving): (yes / no)
The serializers: (yes / no / don't know)
The runtime per-record code paths (performance sensitive): (yes / no / don't know)
Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn/Mesos, ZooKeeper: (yes / no / don't know)
The S3 file system connector: (yes / no / don't know)

Documentation

Does this pull request introduce a new feature? (yes / no)
If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)

@wuchong I've rebased to current master and resolved all conflicts, do you have time to have a look again?


ci: use Kubernetes 1.18.9 for CI jobs

The latest Kubernetes patch release (v1.18.10) can not be deployed with
minikube. Selecting version 1.18.9 until the problems with minikube are
addressed.
Updates: #1588
Note: v1.19.3 has the same problem, kubernetes/minikube#9470 lists 1.18.10 too

@nixpanic can you send PR for Mergify update also


Benchmarks

This script gives you a build for each flag and a benchmark sorted for each flag and with the -B option for an average over 30s. It excludes the first 10s of results.  The mkp224o builds are copied into /usr/local/bin. Requires the bc command.
If you set the NO_CREATE env variable before you run the command it won't recreate the benchmark results
e.g.
NO_CREATE=1 ./benchmark.sh
If you set the NO_BUILD env variable it wont attempt to build mkp224o.
NO_BUILD=1 ./benchmark.sh
Output looks like:
root@localhost:~/mkp224o# ./benchmark.sh
Building mkp224o
already built /usr/local/bin/mkp224o-ref10
already built /usr/local/bin/mkp224o-amd64-51-30k
already built /usr/local/bin/mkp224o-amd64-64-24k
already built /usr/local/bin/mkp224o-donna
already built /usr/local/bin/mkp224o-donna-sse2
 done!

Creating benchmarks
--ref10 -s -T
--amd64-51-30k -s -T
--amd64-64-24k -s -T
--donna -s -T
--donna-sse2 -s -T
--ref10 -B -s -T
--amd64-51-30k -B -s -T
--amd64-64-24k -B -s -T
--donna -B -s -T
--donna-sse2 -B -s -T
done!

Calculating benchmark results............ done!

Results:
benchmark-mkp224o-ref10               2384301
benchmark-mkp224o-ref10-B             2587238
benchmark-mkp224o-donna-sse2          3622626
benchmark-mkp224o-donna-sse2-B        3656571
benchmark-mkp224o-amd64-51-30k        5726968
benchmark-mkp224o-amd64-51-30k-B      5789477
benchmark-mkp224o-donna               6015617
benchmark-mkp224o-donna-B             6201576
benchmark-mkp224o-amd64-64-24k        6444984
benchmark-mkp224o-amd64-64-24k-B      6508391

Script
#!/usr/bin/env bash

echo "Building mkp224o"

if [[ -z $NO_BUILD ]]; then
  if [[ ! -f /usr/local/bin/mkp224o-ref10 ]];then
    make clean; ./autogen.sh; ./configure --enable-ref10; make; cp mkp224o /usr/local/bin/mkp224o-ref10
  else
    echo "already built /usr/local/bin/mkp224o-ref10"
  fi

  if [[ ! -f /usr/local/bin/mkp224o-amd64-51-30k ]];then
    make clean; ./autogen.sh; ./configure --enable-amd64-51-30k; make; cp mkp224o /usr/local/bin/mkp224o-amd64-51-30k
  else
    echo "already built /usr/local/bin/mkp224o-amd64-51-30k"
  fi

  if [[ ! -f /usr/local/bin/mkp224o-amd64-64-24k ]];then
    make clean; ./autogen.sh; ./configure --enable-amd64-64-24k; make; cp mkp224o /usr/local/bin/mkp224o-amd64-64-24k
  else
    echo "already built /usr/local/bin/mkp224o-amd64-64-24k"
  fi

  if [[ ! -f /usr/local/bin/mkp224o-donna ]];then
    make clean; ./autogen.sh; ./configure --enable-donna; make; cp mkp224o /usr/local/bin/mkp224o-donna
  else
    echo "already built /usr/local/bin/mkp224o-donna"
  fi

  if [[ ! -f /usr/local/bin/mkp224o-donna-sse2 ]];then
    make clean; ./autogen.sh; ./configure --enable-donna-sse2; make; cp mkp224o /usr/local/bin/mkp224o-donna-sse2
  else
    echo "already built /usr/local/bin/mkp224o-donna-sse2"
  fi
fi

echo " done!"

if [[ -z $NO_CREATE ]];then
   echo "Creating benchmarks"
   echo "--ref10 -s -T"
  /usr/local/bin/mkp224o-ref10 -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-ref10
  echo "--amd64-51-30k -s -T"
  /usr/local/bin/mkp224o-amd64-51-30k -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-amd64-51-30k
  echo "--amd64-64-24k -s -T"
  /usr/local/bin/mkp224o-amd64-64-24k -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-amd64-64-24k
  echo "--donna -s -T"
  /usr/local/bin/mkp224o-donna -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-donna
  echo "--donna-sse2 -s -T"
  /usr/local/bin/mkp224o-donna-sse2 -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-donna-sse2
  echo "--ref10 -B -s -T"
  /usr/local/bin/mkp224o-ref10 -B -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-ref10-B
  echo "--amd64-51-30k -B -s -T"
  /usr/local/bin/mkp224o-amd64-51-30k -B -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-amd64-51-30k-B
  echo "--amd64-64-24k -B -s -T"
  /usr/local/bin/mkp224o-amd64-64-24k -B -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-amd64-64-24k-B
  echo "--donna -B -s -T"
  /usr/local/bin/mkp224o-donna -B -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-donna-B
  echo "--donna-sse2 -B -s -T"
  /usr/local/bin/mkp224o-donna-sse2 -B -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > benchmark-mkp224o-donna-sse2-B
  echo "done!"
fi

echo -e
echo -n "Calculating benchmark results"

files=( benchmark-mkp224o-ref10 benchmark-mkp224o-amd64-51-30k benchmark-mkp224o-amd64-64-24k benchmark-mkp224o-donna benchmark-mkp224o-donna-sse2 benchmark-mkp224o-ref10-B benchmark-mkp224o-amd64-51-30k-B benchmark-mkp224o-amd64-64-24k-B benchmark-mkp224o-donna-B benchmark-mkp224o-donna-sse2-B)

IFS='
'
regex='^>calc/sec:([0-9]+\.[0-9]+).*'
values=()
for file in "${!files[@]}"; do
  for i in $(<${files[$file]}); do
    if [[ $i =~ $regex ]]; then
      values+=(${BASH_REMATCH[1]})
    fi
  done
  n="(${values[@]})/3"
  line="                                    "
  PROC_NAME=${files[$file]}
  calc=$(bc <<< "${n// /+}")
  line="${line:${#PROC_NAME}}"
  result=$(printf "%s %s %s" $PROC_NAME $line $calc)
  results+=("$result")
  values=()
  echo -n "."
done
echo " done!"

echo -e
echo "Results:"
mapfile -t sorted < <(printf "%s\n" "${results[@]}" | sort -r -k2,2n -k1,1)
for result in "${sorted[@]}"; do
  echo ${result}
done

after replacing all the /usr/local/bin with ., this script works well and confirms what I already guessed would be the fastest on my hardware:
Results:
benchmark-mkp224o-ref10               35373783
benchmark-mkp224o-ref10-B             36767215
benchmark-mkp224o-donna-sse2          55913307
benchmark-mkp224o-donna-sse2-B        57579152
benchmark-mkp224o-donna               76592045
benchmark-mkp224o-donna-B             77199319
benchmark-mkp224o-amd64-51-30k        77893082
benchmark-mkp224o-amd64-51-30k-B      82166666
benchmark-mkp224o-amd64-64-24k        84535220
benchmark-mkp224o-amd64-64-24k-B      85214051

after replacing all the /usr/local/bin with ., this script works well and confirms what I already guessed would be the fastest on my hardware:
Results:
benchmark-mkp224o-ref10               35373783
benchmark-mkp224o-ref10-B             36767215
benchmark-mkp224o-donna-sse2          55913307
benchmark-mkp224o-donna-sse2-B        57579152
benchmark-mkp224o-donna               76592045
benchmark-mkp224o-donna-B             77199319
benchmark-mkp224o-amd64-51-30k        77893082
benchmark-mkp224o-amd64-51-30k-B      82166666
benchmark-mkp224o-amd64-64-24k        84535220
benchmark-mkp224o-amd64-64-24k-B      85214051

The script could probably do with a little more error checking and also the ability to benchmark against some real search terms as these do impact the benchmarks quite significantly when you have a number of terms to search for.  All this said the -B option is typically faster with my current searches (10 search terms, between 8-12 characters)

The script could probably do with a little more error checking and also the ability to benchmark against some real search terms as these do impact the benchmarks quite significantly when you have a number of terms to search for.  All this said the -B option is typically faster with my current searches (10 search terms, between 8-12 characters)

The script could probably do with a little more error checking

correct.

and also the ability to benchmark against some real search terms as these do impact the benchmarks quite significantly when you have a number of terms to search for

keygen rate isn't significantly affected by search terms, unless the list is like really huge and linear search method is used which would start being slowdown at that point, or keys are being found at like really high rate in which case resets of keygen state would also start affecting performance. so idk if adding different search term stuff would affect much.

Ubuntu20.04
i9-10980XE+128G DDR4
Results:
benchmark-mkp224o-ref10-B             37612746
benchmark-mkp224o-ref10               37744107
benchmark-mkp224o-donna-sse2          59914373
benchmark-mkp224o-donna-sse2-B        68708351
benchmark-mkp224o-amd64-51-30k-B      92619635
benchmark-mkp224o-amd64-51-30k        92920878
benchmark-mkp224o-donna-B             96342484
benchmark-mkp224o-donna               104819271
benchmark-mkp224o-amd64-64-24k-B      106678425
benchmark-mkp224o-amd64-64-24k        116345680

I cleaned the script up a little bit to use loops and be easier to modify, and to not leave lots of files in the top-level dir.
I also adapted it to work on a macOS Big Sur system.  I  am pasting it here in case anybody else wants it. It also still works on Linux (but you have to comment-out the macOS stuff and uncomment the Linux stuff at top of file).
Results:
mkp224o-donna-sse2-B 2145568
mkp224o-donna-sse2 2568176
mkp224o-ref10-B 3765567
mkp224o-ref10 6651734
mkp224o-donna-B 9193741
mkp224o-donna 11359662

#!/usr/bin/env bash

set -e

BINDIR=`pwd`/bin
BENCHDIR=`pwd`/benchmarks
#Uncomment for Linux:
#FLAGS="ref10 amd64-51-30k amd64-64-24k donna donna-sse2"
#libdir="/usr/local/lib"
#includedir="/usr/local/include"

#Below is for macOS Big Sur with MacPorts, comment it out if on Linux
FLAGS="ref10 donna donna-sse2"
libdir="/opt/local/lib"
includedir="/opt/local/include"

if [[ -z $NO_BUILD ]]; then
    echo "Building mkp224o"
    mkdir -p "$BINDIR"
    for flag in $FLAGS; do
        OUTFILE="${BINDIR}"/mkp224o-"$flag"
        if [[ ! -f "$OUTFILE" ]]; then
            make clean
            ./autogen.sh
            CFLAGS="-I${includedir}" LDFLAGS="-L${libdir}" \
                ./configure --enable-"${flag}"
            make
            cp -fpv mkp224o "$OUTFILE"
        else
            echo "already built $OUTFILE"
        fi
    done
    echo " done!"
fi

files=""

if [[ -z $NO_CREATE ]]; then
    echo "Creating benchmarks"
    mkdir -p "$BENCHDIR"
    rm -fv "$BENCHDIR"/mkp224o*
fi
for flag in $FLAGS; do
    [[ -z $NO_CREATE ]] && echo "--${flag} -s -T"
    [[ -z $NO_CREATE ]] && "$BINDIR"/mkp224o-"$flag" -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > "$BENCHDIR"/mkp224o-"$flag"
    files="${files} $BENCHDIR/mkp224o-${flag}"
done
for flag in $FLAGS; do
    [[ -z $NO_CREATE ]] && echo "--${flag} -B -s -T"
    [[ -z $NO_CREATE ]] && "$BINDIR"/mkp224o-"$flag" -B -s -T benchmarkkeyhardtofind 2>&1 | head -n 8 | tail -n 3 > "$BENCHDIR"/mkp224o-"$flag"-B
    files="${files} $BENCHDIR/mkp224o-${flag}-B"
done
[[ -z $NO_CREATE ]] && echo "done!"

echo -n "Calculating benchmark results"

regex='^>calc/sec:([0-9]+\.[0-9]+).*'
values=()
for file in $files; do
    for i in $(cat "$file"); do
        if [[ $i =~ $regex ]]; then
            values+=(${BASH_REMATCH[1]})
        fi
    done
    n="(${values[@]})/3"
    line="                                    "
    BASE_NAME=$(basename $file)
    calc=$(bc <<< "${n// /+}")
    line="${line:${#file}}"
    result=$(printf "%s %s %s" $BASE_NAME $line $calc)
    results+=("$result")
    values=()
    echo -n "."
done
echo " done!"

echo -e
echo "Results:"
mapfile -t sorted < <(printf "%s\n" "${results[@]}" | sort -r -k2,2n -k1,1)
for result in "${sorted[@]}"; do
    echo ${result}
done

Would love to see a windows version of this :)

I can try and hack it to work on windows but with mingw & bash probably.. since.. well .. powershell is beyond my capabilities.

I can try and hack it to work on windows but with mingw & bash probably.. since.. well .. powershell is beyond my capabilities.

That's perfectly fine, I'd appreciate that!

#! /usr/bin/env bash

# mkp224o-benchmark.sh - a benchmarking wrapper for mkp224o

# print live stats in a pretty format

# loop different binaries and extra_options
# to find the fastest combination

# MIT license

# select range of samples
samples_from=1; samples_to=5 # slow
samples_from=1; samples_to=1 # too fast. shows speed 0 for some commands
samples_from=2; samples_to=2 # show only the second sample

extra_options_list=()
extra_options_list+=("")
extra_options_list+=("-B")

set -e

bindir=$(dirname $(which mkp224o-donna)) # also works on nixos linux

printf "# args:"; for arg in "$@"; do printf " %q" "$arg"; done; echo
echo -e "# speed\tround\tsample\tcommand"

round_num=0
while true
do
  round_num=$((round_num + 1))
  for bin in $bindir/mkp224o-*
  do
    binname=$(basename $bin)
    if [[ $# == 0 ]]
    then
      $bin -h # show help
      echo
      echo "$(basename "$0"): hint: run this script with extra_options: -qxs"
      echo "$(basename "$0"): hint: pipe the output through: | tee -a stats.txt"
      exit 1
    fi
    for extra_options in "${extra_options_list[@]}"
    do
      command="$binname"
      [[ "$extra_options" != "" ]] && command+=" $extra_options"
      sample_num=0
      while read line
      do
        speed=$(echo "$line" | sed -E "s/^>calc\/sec:([0-9]+)\..*$/\1/")
        if [[ "$speed" == "" ]]; then echo "# $line"; continue; fi
        sample_num=$((sample_num + 1))
        (( sample_num < samples_from )) && continue
        echo -e "${speed}\t${round_num}\t${sample_num}\t${command}"
        (( sample_num >= samples_to )) && break # stop the binary
      done < <(
        # run the binary
        $bin "$@" $extra_options 2>&1
      )
    done
  done
done

example output
# speed round   sample  command
74801   1       2       mkp224o-amd64-51-30k
487311  1       2       mkp224o-amd64-51-30k -B
43524   1       2       mkp224o-amd64-64-20k
677915  1       2       mkp224o-amd64-64-20k -B
46220   1       2       mkp224o-donna
510093  1       2       mkp224o-donna -B
30071   1       2       mkp224o-donna-sse2
345797  1       2       mkp224o-donna-sse2 -B
22929   1       2       mkp224o-ref10
271194  1       2       mkp224o-ref10 -B
42006   2       2       mkp224o-amd64-51-30k
543153  2       2       mkp224o-amd64-51-30k -B
44021   2       2       mkp224o-amd64-64-20k
624928  2       2       mkp224o-amd64-64-20k -B
41333   2       2       mkp224o-donna
543393  2       2       mkp224o-donna -B
30464   2       2       mkp224o-donna-sse2
380156  2       2       mkp224o-donna-sse2 -B
23788   2       2       mkp224o-ref10
282694  2       2       mkp224o-ref10 -B

Arch Linux, Ryzen 9 9900X, numbers averaged over 10 seconds, compiled with -flto=auto -O3 -march=native
--enable-donna
117.197.262 c/s

--enable-donna-sse2
90.019.020 c/s

--enable-ref10
41.197.252 c/s

--enable-amd64-51-30k
116.137.700 c/s

--enable-amd64-64-24k
143.657.351 c/s


[WIP] Prototype Simulator API for creating/assigning simple Phong materials

Motivation and Context
Quick prototype implementation of color material creation/assignment designed to enable primitive visualization shapes to be generated with custom user color materials.
Note: this is not intended to be the final API, will not be merged. Merge this with your branch to utilize.
How Has This Been Tested
Locally in viewer with RIGHT-CLICK to place objects and 't' to swap colors (gif color optimization is poor 😉 ):

Types of changes

[ ] Docs change / refactoring / dependency upgrade
[ ] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist

[ ] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[ ] I have read the CONTRIBUTING document.
[ ] I have completed my CLA (see CONTRIBUTING)
[ ] I have added tests to cover my changes.
[ ] All new and existing tests passed.

Stale prototype feature.


CI pipelines: terraform workflow is broken (plan / apply)

Fixed by https://git.speag.com/oSparc/osparc-ops-deployment-configuration/-/merge_requests/943


Alfoa/reject if failed

Pull Request Description
What issue does this change request address? (Use "#" before the issue to link it, i.e., #42.)
Closes #379
What are the significant changes in functionality due to this change request?
Added the possibility to handle failed runs in Optimizer...

For Change Control Board: Change Request Review
The following review must be completed by an authorized member of the Change Control Board.

[x] 1. Review all computer code.
[x] 2. If any changes occur to the input syntax, there must be an accompanying change to the user manual and xsd schema. If the input syntax change deprecates existing input files, a conversion script needs to be added (see Conversion Scripts).
[x] 3. Make sure the Python code and commenting standards are respected (camelBack, etc.) - See on the wiki for details.
[ ] 4. Automated Tests should pass, including run_tests, pylint, manual building and xsd tests. If there are changes to Simulation.py or JobHandler.py the qsub tests must pass.
[x] 5. If significant functionality is added, there must  be tests added to check this. Tests should cover all possible options.  Multiple short tests are preferred over one large test. If new development on the internal JobHandler parallel system is performed, a cluster test must be added setting, in  XML block, the node <internalParallel> to True.
[x] 6. If the change modifies or adds a requirement or a requirement based test case, the Change Control Board's Chair or designee also needs to approve the change.  The requirements and the requirements test shall be in sync.
[x] 7. The merge request must reference an issue.  If the issue is closed, the issue close checklist shall be done.
[x] 8. If an analytic test is changed/added is the the analytic documentation updated/added?

@crisrab @AaronEpiney @PaulTalbot-INL

This provides baseline mechanics for objective-based constraints, too, right?


CollectionUtils.ArrayEmpty<T>() should be update for netcoreapp3.0

Related to #2137, #2034
Found this while try to debug #2148, it make all unit-test stops with Process terminated. Assertion failed. when hit the assert for Debug builds in netcoreapp3.0.
According to the assert and comments in CollectionUtils.ArrayEmpty<T>(), it should also be update to use Array.Empty<T>() for new platforms(maybe for netstandard1.3 and netstandard2.0), since netcoreapp3.0 switch to return EmptyPartition<T> now.
https://github.com/JamesNK/Newtonsoft.Json/blob/cdf10151d507d497a3f9a71d36d544b199f73435/Src/Newtonsoft.Json/Utilities/CollectionUtils.cs#L369-L390

Thanks for reporting this. It is already fixed and will be in the next release - https://github.com/JamesNK/Newtonsoft.Json/commit/d75074f30c1c65d9101c11aec2ac4273d07b2fa4


Feat: Adding a Link to Info Analytics App

What do you think about adding an "Analytics" or "Stats" link to the header nav pointing to: https://info.whitewhale.money/pools
Unfortunately also linking to the correct pool page from the WhiteWhale App, e.g. in the Pool#Index Action Colum is not possible atm, as the identifer on the info App, doesn't contain the chain, e.g. this link could be migaloo, or terra: https://info.whitewhale.money/pools/bWHALE-WHALE

Yeah, let’s do this!


soc: stm32: add Kconfig-selectable cache enables

The instruction cache in the STM32H7 was enabled regardless of the value assigned via Kconfig to the CONFIG_ICACHE parameter. Add the missing conditional check.
Remove a redundant low-level check on DCache being already enabled, since it is also performed inside the SCB_EnableDCache function.
I also applied the same patch to the F7, according to @FRASTM suggestion.
~In the same spirit, I applied Kconfig-selectable cache enables to other STM32 targets using LL_ICACHE and LL_FLASH HAL APIs. If this is not desired/useful I will drop the relevant patches.~

thanks @pillo79 to change this for the stm32H7 serie.
I guess same PR has to be applied to stm32F7

I probably overdid this now, so let me know if it is not appropriate for any of the targets and I will drop relevant changesets.

a2f8a7653193426021535171177cbe6b844b096e adds conditional instruction cache enable on STM32F7 and STM32H7, and removes a redundant low-level check on data cache enable (its enabling was already controlled via Kconfig).
8afc60de48b8acb0ce28c50703fba127fa00e3d1 adds conditional instruction/data cache enables to STM32F2, STM32F4 and STM32WL targets using the LL_FLASH HAL.
9bf0faa461f9275dfb8b3729cef7f7e72895f3aa adds conditional instruction cache enables to STM32H5, STM32L5, STM32U5 and STM32WBA targets using the LL_ICACHE HAL.

Dropped the extensive patches in favor of H7 (my original goal) and F7.

@pillo79 not sure why, as it fixed not working config options.
The situation with https://github.com/zephyrproject-rtos/zephyr/pull/66140#discussion_r1416223111 has to be clarified and fixed sooner or later (doesn't have to be in this PR).

Though, this change will have impact on all targets with unforeseeable consequences.

@erwango it should be safe as long as config options "default the symbols to y on affected series". Users who set option(s) to n clearly want to disable related cache(s). Without applied fixes, they are not getting that.

@pillo79 not sure why, as it fixed not working config options.
The situation with #66140 (comment) has to be clarified and fixed sooner or later (doesn't have to be in this PR).

@GeorgeCGV you are right, but my patch was totally untested on devices other than the H7 and I did no research other than replace similar code with no obvious side effect. If the consensus is that it's a step in the right direction anyway, I can happily restore them. Maybe forcing a Y on the devices listed above with known driver issues, until a proper fix can be implemented and tested?

@GeorgeCGV you are right, but my patch was totally untested on devices other than the H7 and I did no research other than replace similar code with no obvious side effect. If the consensus is that it's a step in the right direction anyway, I can happily restore them. Maybe forcing a Y on the devices listed above with known driver issues, until a proper fix can be implemented and tested?

Note also that in some cases (H5 for instance) Icache enabling is mandatory (let's say "disable at your own risk") and maybe spread at in some drivers (flash, hwinfo, drivers/sensor/stm32_vref).
So this change remains interesting, but need to be handled carefully.

Note also that in some cases (H5 for instance) Icache enabling is mandatory (let's say "disable at your own risk") and maybe spread at in some drivers (flash, hwinfo, drivers/sensor/stm32_vref). So this change remains interesting, but need to be handled carefully.

Sounds like something that could be handled with some strategically placed select ICACHE.


get the execution result of webassembly module with C API

Hi, I use wasmtime C API to load a .wat module (which uses WASI)  and execute it. It can successfully execute the module and print out "Hello World!" on the stdout. However, I want to retrieve the output as a host runtime variable, is it possible?
I defined the following code trying to get the result:
wasmtime_val_t results[1];
error = wasmtime_func_call(context, &run.of.func, NULL, 0, results, 1, &trap);
if (error != NULL || trap != NULL)
                exit_with_error("failed to call run", error, trap);
printf("output result is %s\n", (char*)wasmtime_externref_data(results[0].of.externref));

This code doesn't work and it print out:
error: failed to call run
expected 0 results, got 1

I made something wrong here or is it possible to get the output? I think it should malloc memory for results on the host runtime and then wasmtime_func_call will write the output to it, however, now the error seems not the memory allocation issue. Any suggestions for this. Thanks very much.

The .wat module I used doesn't return a char* string result, it just print out "Hello World!" and I want to retrieve this "Hello World!".

It sounds like you want to capture stdout.
The Wasmtime C API currently offers two options for what to do with the guest's stdout: you can direct it to a file using wasi_config_set_stdout_file, or have it forwarded to the host's stdout with wasi_config_inherit_stdout.
In your case the best I think you can do today is have the output written to a file and then read the contents of that file after the guest exits.
I believe there are more options if you use Wasmtime's Rust API instead, so the C API could provide other options for what to do with stdout, but nobody has implemented those.
Or, if you can change the code that's running in the guest, then you could pick another way of passing the string out instead of using stdout.

Thanks @jameysharp . Yes, I want to capture the guest stdout. Thanks for letting me know these two interfaces and I tried both of them, and they all works. For now, I will use wasi_config_set_stdout_file for my need, though it could let developers to change their code,  wasi_config_set_stdout_file  is still necessary for those who don't want to change their code. Thanks for your help!

Great, I'm glad that worked! I'll go ahead and close this issue but please do let us know if you have more questions. You can also discuss how to use Wasmtime in our chat at https://bytecodealliance.zulipchat.com/#narrow/stream/217126-wasmtime if that's more convenient.


Please help with a problem when Exporting to Excel

This is such a wonderful extension thank you for all your hard work and for sharing it.
We do, however, have one problem that I hope you can help us resolve.
I downloaded Version 2 of the app.  "Tabbed Container_V2"
The Excel version we're on is Microsoft Excel 2010.
We have the problem when exporting data in a pivot table to excel.
The export creates a column for every comma (thousands separator) in the data.
Below is an example of the problem (if the attachments aren't showing I typed an example below).
These are the measures in our pivot table:

After we select the export button the excel file looks like this:

If I remove the editing in the qlik sheet and just take out the commas as seen here:

The excel looks great:

The problem is we cannot exclude the commas in the editing because our numbers can be large and they become very hard to read.
If you could help us out with this problem the extension will be used a great deal in our Qlik Sense apps.
If the pictures aren't visible above, I typed an example of the problem:
This is an example of a measure in our pivot table:
$132,866
After we select the export button the excel file looks like this:
Column A     ColumnB
$132              866
If I remove the editing in the qlik sheet and just take out the commas as seen here:
$132866
The excel looks great:
Column A
$132,866

Hello @annie8099
This issue reminds me of #59. There is a pull request that kind of solves your issue: #60
The only problem is that this "fix" will break your number formatting by removing the commas and the dolar sign, so I am hesitant about merging it to master. I am still thinking of better solutions.
For now, you could export your data as a tab-separated csv and then save the file as an excel,

Thank you very much for your response.
We ended up using "Sheet Navigation and Actions Button" extension.
You're tabbed extension will be used in the near future and I will let you know how our users make out using the csv and then saving the file as excel.  Thanks again!!

ok. I will close this issue in the meantime, as it is the same as #59
Do let me know when you use the extension again


QSO-field for confirmed long path contact?

Hi,
I just wonder if there could be a check box (create qso, edit qso) for usage of long path -- which would result in a different distance calculation and make a long path drawn on the globe map...

It's totally legit to ask for that as ANT_PATH is an official ADIF field. We currently have no possibility to edit that. I plan to do some frontend stuff for the QSO edit field. I will address this aswell then, okay?
I currently have a lot of private stuff to do (Moving Home from A to B). After that I will take care of that. Please be patient.

i will be

@Beiri22
First step is done. You now can edit ANT_PATH in the QSO edit. The path drawings and distance calculation will be addressed in another PR.

Distance calculation is also included. The path drawings will be adressed some other day as they are really complex. The main request is solved so I guess we can close this issue.


Revisit CALM Node Types

Feature Request
Description of Problem:
With the introduction of interfaces and controls, we have started to challenge the node-type-definition that exists in CALM. The current list is:
"node-type-definition": {
      "enum": [
        "actor",
        "system",
        "service",
        "database",
        "network",
        "ldap",
        "webclient"
      ]
    },

We should revisit this to set what the types would be

@ojeb2 please share some of the definitions/types from your work with OMG

My view is we can remove database;replace with service in the logical representation, more detailed data knowledge to be proposed by @ojeb2, ldap; isn't this just another service or system (depending on level you're looking at); webclient would be replaced by the interface definitions on nodes which could represent both systematic (e.g. API) type interfaces as well as describe user interfaces, unless we think we would want to capture details around implementation choices (which I don' think we do).

Some references for node types:
LeanIX
LeanIX, an enterprise architecture tool, supports 12 different types:
https://docs-eam.leanix.net/docs/meta-model#fact-sheet-types
We are most interested in:

LeanIX Application (CALM System)
LeanIX Interface (CALM Interface)
LeanIX Data Object (new to CALM)
LeanIX IT Component (new to CLAM but probably just another CALM System or Service depending on the hosting situation)

OMG DPROD (Data Product)
The Data Product (DPROD) specification is a profile of the Data Catalog (DCAT) Vocabulary, designed to describe Data Products.  DPROD extends DCAT to enable publishers to describe Data Products and data services in a decentralized way.
https://ekgf.github.io/dprod/#data-product-dprod-model
DPROD has 4 main entity definitions but 2 are most useful to CALM:

DataProduct (new to CALM)
DataService (CALM Interface)

CDMC Cloud Data Management Capabilities
CDMC is a standard created by the EDMCouncil for describing what good data management looks like for cloud hosted data.  It was developed by 150 organisations in 2020-2021 and automated controls were written and implemented for the 3 major CSPs.
CDMC defines Data Assets as part of the CDMC Information Model:
https://github.com/edmcouncil/cdmc/blob/main/ontology/Core.ttl
An example of the Data Asset properties for the implementation of CDMC controls for Google BigQuery is here: https://github.com/GoogleCloudPlatform/cdmc/blob/main/tagging/tag_templates/cdmc_controls.yaml
CDMC terms:

CDMC DataAsset (new to CALM)

FinOS CCC Common Cloud Controls
A FinOS project defining common service definitions for cloud services, common threats against those services, and common controls to mitigate the risks of those threats.
https://github.com/finos/common-cloud-controls
CCC Services are organised into families (https://github.com/finos/common-cloud-controls/blob/main/services/service-families.yaml):

CCC Service (CALM Service)
By providing a mapping of CLAM Service or CLAM System to a CCC Service we would be able to bring in CCC Controls to provide a vocabulary for CALM Controls.


[SPARK-14512][DOC] Add python example for QuantileDiscretizer

What changes were proposed in this pull request?
Add the missing python example for QuantileDiscretizer
How was this patch tested?
manual tests

Test build #55463 has started for PR 12281 at commit acac4ae.

Test build #55463 has finished for PR 12281 at commit acac4ae.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/55463/
Test PASSed.

Looks good to me, confirmed the example runs as expected.

cc @davies ?

@zhengruifeng sorry for the delay. The core of the example looks good, it just now needs to be updated to use SparkSession as per my comment. Thanks!

Test build #57882 has started for PR 12281 at commit 9a29db5.

@MLnick  Updated. Thanks for review this.

Test build #57882 has finished for PR 12281 at commit 9a29db5.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/57882/
Test PASSed.

Merged build finished. Test PASSed.

LGTM. Thanks!

Merging this into master and 2.0, thanks!


feat: Made the changes for the google transulate

Title and Issue number

Title :Made the changes for the google transulate
Issue No. : #1007
Code Stack : HTML CSS JS
Close #1007

Description

Added Google Transulate And styled it Properly
Video/Screenshots (mandatory)

Type of PR

[ ] Bug fix
[ ] Feature enhancement
[ ] Documentation update
[ ] Other (specify): _______________

Checklist:

[x] I have performed a self-review of my code.
[x] I have commented my code, particularly in hard-to-understand areas.
[x] I have tested the changes thoroughly before submitting this pull request.
[x] I have provided relevant issue numbers, screenshots, and videos after making the changes.
[x] I have gone through the  contributing.md file before contributing

Additional context:

##Are you contributing under any Open-source programme?

[x] I am contributing under GSSOC'24
[ ] I am contributing under VSOC'24

@apu52 @itsekta You can please Review it now i have made it as you told @apu52

@apu52 Can you Once please Review for any chages

here is the new transulate

@Saipradyumnagoud all things are working perfect just add "GOOGLE" logo after powered by

@apu52 I have added google logo after powerd by

@Saipradyumnagoud good work & as u already have dedicated a lot of time in this PR , I am assigning u "LAVEL 2"

@Saipradyumnagoud good work & as u already have dedicated a lot of time in this PR , I am assigning u "LAVEL 2"

@apu52 Really very thank you


Rules for sudo CVE-2021-3156

Motivation
Yesterday CVE-2021-3156 was disclosed against  sudo . I believe that the Falco community should provide a rule against this threat.
Feature
Create a specific rule to catch usage of sudo edit and sudoedit from a non-root user.
I know that you usually use those from a non-root user but I also notice that their usage is usually very limited in a system and specifically since this vulnerability exists we should probably always alert when that is done.
This requires a specific rule because we usually exclude the sudo binary from all the other rules.
The rule here could look something like this:
- rule: Sudo Edit as non Root User
  desc: detect usage of the sudo edit command from a non root user
  condition: spawned_process and user.uid!=0 and (proc.name=sudo and proc.args contains "edit") or (proc.name=sudoedit)
  output: Process launched from non-root user is trying to use the sudo edit command (uid=%user.uid user=%user.name user_loginuid=%user.loginuid)
  priority: ERROR

Alternatives
Don't do anything.
Additional context
RedHat did something similar with stap by proposing that as a mitigation.

https://access.redhat.com/security/cve/cve-2021-3156

Wdyt @Kaizhe ?

Wdyt @Kaizhe ?

Great and timely idea, Lore!
Just one thought: would it make sense to restrict this rule by also checking the arguments? IMHO, it could.
I mean, to my understanding, the CVE exists in case a command-line argument to sudoedit (in MODE_SHELL or MODE_CHECK, but not MODE_RUN) ends with a single backslash.

Great and timely idea, Lore!
Just one thought: would it make sense to restrict this rule by also checking the arguments? IMHO, it could.
I mean, to my understanding, the CVE exists in case a command-line argument to sudoedit (in MODE_SHELL or MODE_CHECK, but not MODE_RUN) ends with a single backslash.

@fntlnz thanks starting it. And sorry to replying late in the thread. I will make suggestions.

@fntlnz thanks starting it. And sorry to replying late in the thread. I will make suggestions.


make serve failing on demobook.

Hi, I've no idea how I've managed this, but I'm in a situation where I can't serve any new jupyter book that I create.
E.g. If I run
jupyter-book create book --demo
jupyter-book build book
make serve
The first two commands run fine, but then I get the following error:
bundle exec guard
Configuration file: _config.yml
/Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/jobs/pry_wrapper.rb:131:in `_setup': undefined method `file=' for #<Pry::History:0x00007f9670f01898>
Did you mean?  filter (NoMethodError)
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/jobs/pry_wrapper.rb:68:in `initialize'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/interactor.rb:17:in `new'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/interactor.rb:17:in `initialize'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard.rb:67:in `new'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard.rb:67:in `setup'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/commander.rb:32:in `start'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/cli/environments/valid.rb:16:in `start_guard'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/cli.rb:122:in `start'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/command.rb:27:in `run'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/invocation.rb:127:in `invoke_command'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor.rb:392:in `dispatch'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/base.rb:485:in `start'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/aruba_adapter.rb:32:in `execute'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/lib/guard/aruba_adapter.rb:19:in `execute!'
	from /Users/nataliethurlby/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/guard-2.14.2/bin/_guard-core:11:in `<main>'
make: *** [serve] Error 1

(In case this is helpful: another Jupyter Book which I am working still works when I run make serve :/).
Any clues? Thank you.
EDIT: Fixed now!

In case anyone in the future has this problem, I managed to fix this updating jupyter book (pip install jupyter-book --upgrade).
When I ran make serve on the demo book this time, I got a message saying that I needed to run bundle install, which I did and then it was all working fine once more.

great! Thanks @NatalieThurlby for following up


add 1803 dockerfile

Closing this PR as the referenced commit has already been merged.
@manudeep936 Please open an issue first if there was something else you were trying to achieve.


[Removal]: please remove my real installed hotspot from denylist

Hotspot Name
cheery-fossilized-manatee
Hotspot b58 Address
1123RxX2j1rFipiGjWHpywdtkQWoCrv1jtPEcYqBpec9sWKeo5Wa
Discord Handle
No response
Hotspot Manufacturer
Pisces Miner
Removal Reason
they are real installed, what's going on? how to attach photos here?
Modifications
No
Extra forwarders
Yes
Extra antennas
No
Additional Information
No response

We have taken into account this removal request in the next iteration of the denylist. It may take some time before it's processed. This is an automated comment due to the volume of addition and removal requests. A future tool is in the works to provide more insight into the analysis approach made by the Helium team and community members that maintain this list.


Inconsistent errors and invalid return codes when unable to connect to target hostport

When passing a host:port to ringpop-admin that it cannot connect to, commands return strange errors.
Some examples:

ringpop-admin status returns a JS error:
  $ ringpop-admin status <IP_ADDRESS>:1234

  /usr/lib/node_modules/ringpop-admin/status.js:47
          cluster.membership.forEach(function each(member) {
                 ^
  TypeError: Cannot read property 'membership' of undefined

ringpop-admin count also returns a JS error:
  $ ringpop-admin count -m <IP_ADDRESS>:1234

  /usr/lib/node_modules/ringpop-admin/count.js:73
              console.log(cluster.getNodeCount());
                                  ^
  TypeError: Cannot call method 'getNodeCount' of undefined

ringpop-admin partitions returns a success and shows no partitions:
  $ ringpop-admin partitions <IP_ADDRESS>:1234
   Checksum   # Nodes   Sample Host
  $ echo $?
  0
  $

What we should see is some kind of "connection refused" or "no nodes contactable" message to stderr, along with an error code returned.

Fixed by #18 and #19.


update breaks Uglify2 of RequireJS

Recently updated
qunit#1.23.1 source/bower_components/qunit
now
Running "requirejs:prod" (requirejs) task
>> Error: Cannot uglify2 file:
>> /Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/.t
>> mp/task/requirejs/bower_components/qunit/reporter/html.js. Skipping it. Error
>> is:
>> 'return' outside of function (line: 3, col: 7, pos: 126)
>>
>> Error
>>     at new JS_Parse_Error
>> (/Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/n
>> ode_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:18368:18)
>>     at js_error
>> (/Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/n
>> ode_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:18376:11)
>>     at croak
>> (/Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/n
>> ode_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:18852:9)
>>     at
>> /Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/no
>> de_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:18994:21
>>     at
>> /Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/no
>> de_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:18899:24
>>     at block_
>> (/Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/n
>> ode_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:19179:20)
>>     at
>> /Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/no
>> de_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:18946:29
>>     at
>> /Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/no
>> de_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:18899:24
>>     at if_
>> (/Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/n
>> ode_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:19162:44)
>>     at
>> /Users/jamwilk/dev/hybris/bin/custom/egrocery/egrocerystorefront/front-end/no
>> de_modules/grunt-contrib-requirejs/node_modules/requirejs/bin/r.js:18990:24
Warning: RequireJS failed. Use --force to continue.

why is this using qunit/reporter/html.js? It is supposed to use distro version of qunit.js, it's a single file.

Sorry, I am not sure, this may be an issue with Uglify2 but I started here
first as it was the package that was updated then caused a break.
On Wed, Apr 13, 2016 at 1:23 PM, Leo Balter<EMAIL_ADDRESS>wrote:

why is this using qunit/reporter/html.js? It is supposed to use distro
version of qunit.js, it's a single file.
—
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
https://github.com/jquery/qunit/issues/982#issuecomment-209554009

@jwilkinson how are you including QUnit in your project/build? The error seems accurate on the Uglify end, but as @leobalter pointed out above, the actual distros of QUnit don't have individual files such as reporter/html.js.


Crash when consuming product [ANDROID]

Version of react-native-iap
0.3.23
Platforms you faced the error (IOS or Android or both?)
Android (seems to work on iOS)
Expected behavior
Consume product without crashing
Actual behavior
It crashes the app
Tested environment (Emulator? Real Device?)
Real Device (nexus 5X)
Steps to reproduce the behavior
Prepare iap, buy inapp and consume it:
const receipt = await RNIap.buyProduct(productID)
const result = await RNIap.consumePurchase(receipt)

The app doesn't crash when doing it this way:
  var purchases = await RNIap.getAvailablePurchases();
  for (let purchase of purchases) {
    if (purchase.productId == productID) {
      var result = await RNIap.consumePurchase(purchase.transactionReceipt)
    }
  }

But it's a little overkill, why can't I do it using the receipt from buyProduct?
Also I think the doc is not up to date. You'll find consumeProduct in the method list while the new method is not consumeProduct anymore but consumePurchase.

@alanlanglois Thanks I will update the doc soon.

How to consume product once it's purchased? I don't have the product details I bought.


How to implement one to one chat feature?

@timmydoza Can we use Twilio conversation API for this?

Hi @SanjayBikhchandani - thanks for the question! I think it would be possible to do this with the conversations API. It would be much more complicated than the current implementation though.
Right now, every time a room is created, this app's backend will created a new conversation resource associated with the room. This 'conversation resource' is where all of the group chats in the room happen.
So in order to have a one to one video chat, this app's backend would have to create a new conversation resource for every 1:1 conversation that happened in the room. This could be quite a lot of conversations, but I think it would still be possible to implement with some work. Unfortunately, this feature is a bit out-of-scope for this video app, so we won't be implementing it.
Thanks again for the question! Please let me know if there's anything else we can help with.


[FEAT]: Google Generative AI (Gemini) Embedding Support

What would you like to see?
Support for the Gemini embedding models
https://ai.google.dev/gemini-api/docs/embeddings
Especially these models:
text-embedding-004
embedding-001

This would be amazing. How soon can we expect to see this pull request added to the latest build for docker?


Inscriptions API call returns wrong "total" in some cases

For example:
https://api.hiro.so/ordinals/v1/inscriptions?address=bc1pdq5qmncg4gdztwuxu050d3f208928yey6r9z2h64m42zmhku2fwst60ekg
This api call returns 18 inscriptions, but the "total" value says only 2.

This has been fixed


RDNA 3 support?

Will RDNA 3 GPUs get ROCm support at launch?

The gfx11 related codes is on going.
Because RDNA2 had got official support, RDNA3 may be more quickly.

The new series are launching tomorrow. In what state is ROCM support for these new 7900 cards? Will it already work? If not, when can we expect them to work?
I am currently using a 6900XT, but depending on whether I can run my ROCM workloads on a 7900 I want to try to purchase a new card tomorrow. I am using tensorflow-rocm in my workloads in case that matters.
@xuhuisheng

@Mushoz
There is no offcial roadmap for gfx11 which might be classified. But we can get some clue from CMakeLists.txt. Here is the search results:
work@d96e2f6e1fb2:~/ROCm$ find . -type f -name CMakeLists.txt -print|xargs grep gfx11
./rocThrust/CMakeLists.txt:       TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx1030;gfx1100;gfx1102"
./rocThrust/CMakeLists.txt:        set(DEFAULT_AMDGPU_TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx1030;gfx1100;gfx1102")
./rocFFT/CMakeLists.txt:  TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx1030;gfx1100;gfx1102")
./rocSOLVER/CMakeLists.txt:set(AMDGPU_TARGETS "gfx803;gfx900;gfx906:xnack-;gfx908:xnack-;gfx1010;gfx1030;gfx1102;gfx1100;${OPTIONAL_AMDGPU_TARGETS}"
./llvm-project/openmp/libomptarget/libm/CMakeLists.txt:set(amdgpu_mcpus gfx700 gfx701 gfx801 gfx803 gfx900 gfx902 gfx906 gfx908 gfx90a gfx90c gfx940 gfx1030 gfx1031 gfx1032 gfx1033 gfx1034 gfx1035 gfx1036 gfx1100 gfx1101 gfx1102 gfx1103)
./llvm-project/openmp/libomptarget/hostrpc/CMakeLists.txt:set(amdgpu_mcpus gfx700 gfx701 gfx801 gfx803 gfx900 gfx902 gfx906 gfx908 gfx90a gfx90c gfx940 gfx1030 gfx1031 gfx1032 gfx1033 gfx1034 gfx1035 gfx1036 gfx1100 gfx1101 gfx1102 gfx1103)
./llvm-project/openmp/libomptarget/DeviceRTL/CMakeLists.txt:    set(amdgpu_wfsz_is32 gfx1030 gfx1031 gfx1032 gfx1033 gfx1034 gfx1035 gfx1036 gfx1100 gfx1101 gfx1102 gfx1103)
./llvm-project/openmp/libomptarget/deviceRTLs/amdgcn/CMakeLists.txt:set(amdgpu_mcpus gfx700 gfx701 gfx801 gfx803 gfx900 gfx902 gfx906 gfx908 gfx90a gfx90c gfx940 gfx1030 gfx1031 gfx1032 gfx1033 gfx1034 gfx1035 gfx1036 gfx1100 gfx1101 gfx1102 gfx1103)
./llvm-project/openmp/libomptarget/deviceRTLs/amdgcn/CMakeLists.txt:set(amdgpu_32bitwf gfx1030 gfx1031 gfx1032 gfx1033 gfx1034 gfx1035 gfx1036 gfx1100 gfx1101 gfx1102 gfx1103)
./rocSPARSE/CMakeLists.txt:        TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx1030;gfx1100;gfx1102"
./rocSPARSE/CMakeLists.txt:        set(DEFAULT_AMDGPU_TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx1030;gfx1100;gfx1102")
./hipCUB/CMakeLists.txt:      TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx1030;gfx1100;gfx1102"
./rccl/CMakeLists.txt:       TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx1030;gfx1100;gfx1101;gfx1102"
./rccl/CMakeLists.txt:        set(DEFAULT_AMDGPU_TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx1030;gfx1100;gfx1101;gfx1102")
./rocBLAS/CMakeLists.txt:set_property( CACHE AMDGPU_TARGETS PROPERTY STRINGS all gfx803 gfx900 gfx906:xnack- gfx908:xnack- gfx90a:xnack+ gfx90a:xnack- gfx1010 gfx1012 gfx1030 gfx1100 gfx1102 )
./rocBLAS/CMakeLists.txt:      TARGETS "gfx803;gfx900;gfx906:xnack-;gfx908:xnack-;gfx90a:xnack+;gfx90a:xnack-;gfx1010;gfx1012;gfx1030;gfx1100;gfx1102"
./rocRAND/CMakeLists.txt:    TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx1030;gfx1100;gfx1102"
./Tensile/Tensile/Source/CMakeLists.txt:  set(TENSILE_GPU_ARCHS gfx803 gfx900 gfx906:xnack- gfx908:xnack- gfx90a:xnack- gfx1010 gfx1011 gfx1012 gfx1030 gfx1100 gfx1101 gfx1102 CACHE STRING "GPU architectures")
./Tensile/Tensile/Source/CMakeLists.txt:  set(TENSILE_GPU_ARCHS gfx803 gfx900 gfx906 gfx908 gfx90a gfx1010 gfx1011 gfx1012 gfx1030 gfx1100 gfx1101 gfx1102 CACHE STRING "GPU architectures")
./rocPRIM/CMakeLists.txt:      TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+;gfx1030;gfx1100;gfx1102"
./ROCR-Runtime/src/CMakeLists.txt:                   image/addrlib/src/gfx11/gfx11addrlib.cpp
./ROCR-Runtime/src/CMakeLists.txt:                   image/image_manager_gfx11.cpp
./ROCR-Runtime/src/CMakeLists.txt:                   image/image_lut_gfx11.cpp
./ROCR-Runtime/src/CMakeLists.txt:    ${CMAKE_CURRENT_SOURCE_DIR}/image/addrlib/src/gfx11
./ROCR-Runtime/src/CMakeLists.txt:    ${CMAKE_CURRENT_SOURCE_DIR}/image/addrlib/src/chip/gfx11 )
./ROCR-Runtime/src/core/runtime/trap_handler/CMakeLists.txt:set (TARGET_DEVS "gfx900;gfx1010;gfx1030;gfx1100")
./ROCR-Runtime/src/image/blit_src/CMakeLists.txt:  set (TARGET_DEVICES "gfx700;gfx701;gfx702;gfx801;gfx802;gfx803;gfx805;gfx810;gfx900;gfx902;gfx904;gfx906;gfx908;gfx909;gfx90a;gfx90c;gfx1010;gfx1011;gfx1012;gfx1013;gfx1030;gfx1031;gfx1032;gfx1033;gfx1034;gfx1035;gfx1036;gfx1100;gfx1102;gfx1103")
./rocALUTION/CMakeLists.txt:  set(DEFAULT_AMDGPU_TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx1030;gfx90a:xnack-;gfx90a:xnack+;gfx1100;gfx1102")
./rocALUTION/CMakeLists.txt:  set(DEFAULT_AMDGPU_TARGETS "gfx803;gfx900:xnack-;gfx906:xnack-;gfx908:xnack-;gfx1030;gfx1100;gfx1102")

Sometimes I wonder about what amd does during the 2-3 years they are planning a new arch ... I mean the llvm branch released with rocm 5.4 does understand the gfx1100 target and compiles all fine, yet the output of it is incompatible with the released amdgpu-pro drivers (this is not the case with gfx1030...). And well lack of rocm support at release day for new architectures is an other thing.
I can not understand with the planning time going into a new architecture, why there is so poor software support the moment they get released.

@Lolliedieb What about using Mesa instead of the amdgpu-pro? I have always used tensorflow-rocm on my 6900xt while running the opensource drivers. I just received my new 7900 XTX today and was hoping I could use it to run tensorflow-rocm again.

Hello. Will gfx11 support be in ROCm 5.5 (including MIOpen)? Thank you.

Are there still people who are waiting for 7900XTX support? Though the performance is still a bit poor, TensorFlow-upstream now runs when built on the latest ROCm release. I was looking into the status of ROCm support for 7900XTX and found a few issues opened by different people and wanted to link all to the issue I opened in MIOpen repo. Though there has not been any confirmation from the developer, I think the performance issues are due to insufficient optimization of MIOpen. ROCmSoftwarePlatform/MIOpen#2342

Next month will be released rocm 5.7(7900XTX official support) and miopen for windows

Are there still people who are waiting for 7900XTX support? Though the performance is still a bit poor, TensorFlow-upstream now runs when built on the latest ROCm release. I was looking into the status of ROCm support for 7900XTX and found a few issues opened by different people and wanted to link all to the issue I opened in MIOpen repo. Though there has not been any confirmation from the developer, I think the performance issues are due to insufficient optimization of MIOpen. ROCm/MIOpen#2342

Yeah, I've been waiting since I bought it.  I tried returning it based on the fact it never fully worked despite countless emails following every direction given.  I am about ready to publish the entire email chain so people can see what horrible support they provide and what happens when it doesn't work.  Basically they're response to linux support was to load the latest edition of windows and see if it works.  Seriously??  I will never buy another AMD.  My nvidia in my laptop works without a hitch, never had a problem.  This whole gfx11 saga has got to be one of the worst cases of misrepresentation I've come across.  As far as I'm concerned, they don't support linux as long as there's no RDNA3 support.

@AnonymousRonin
Have you tried ROCm5.7? What issues are you having? Though it takes some fiddling, you should be able to get TensorFlow and PyTorch working using ROCm 5.7 & 7900XTX. Hopefully, with the release of 6.0, things will work more smoothly.

Is there any plan for GFX1103 (M780) support? Currently I see 1100 and 1102, and copying the 1102 libraries to 1103 produces issues.

@AnonymousRonin Have you tried ROCm5.7? What issues are you having? Though it takes some fiddling, you should be able to get TensorFlow and PyTorch working using ROCm 5.7 & 7900XTX. Hopefully, with the release of 6.0, things will work more smoothly.

I'm using rocm6. With tensorflow still have freezes when put models and data in memory

@zhiyuanzhai Closing bug since RDNA3 is supported in latest ROCm 6.1.2
@johnnynunez Please create a separate ticket for your issue if you are still seeing your issue with the latest ROCm 6.1.2


Contig-taxid file does not seem to have two cols with the seqid in the first col and taxid in the second col

Hello everyone,
I am getting the follow error:
"Contig-taxid file random10k.example_scaffolds.fa.nt.1e-5.megablast does not seem to have two cols with the seqid in the first col and taxid in the second col at /home/pkfs/blobology/gc_cov_annotate.pl line 58, <$filehandle> line 1.
Error in file(file, "rt") : não é possível abrir a conexão
Calls: read.delim -> read.table -> file
Além disso: Warning message:
In file(file, "rt") :
não foi possível abrir o arquivo 'blobplot.txt': Arquivo ou diretório não encontrado
Execução interrompida
"
When I open the created file ( "random10k.example_scaffolds.fa.nt.1e-5.megablast"), I have:
"372284	N/A
410910	N/A
281600	N/A
3303361	N/A
1790197	N/A
3226893	N/A
(...)
"
Do you have any ideia how can I solve this problem?
Best regards,
Priscila

Hello Priscila,
blastn for some reason does not like the configuration of  '6 qseqid staxids' from the line
blastn -task megablast -query $RND_ASSEMBLY -db $BLASTDB/nt -evalue 1e-5 -num_threads $NUMPROC -max_target_seqs 1 -outfmt '6 qseqid staxids' -out $RND_ASSEMBLY.nt.1e-5.megablast
I removed the s from staxids so the new configuration is '6 qseqid staxid' and it worked.
Rebecca

Hi both,
the blobology pipeline  is no longer maintained and its use is not encouraged...
You might want to check out BlobTools:

https://github.com/DRL/blobtools
https://blobtools.readme.io/docs

cheers,
dom


Normalize Keys

Currently, you can send keys with spaces or other unwanted special characters. We should normalize these to follow logfmt best practices.

All keys are normalized before being written to the output log.