[RFC] Make expected REST responses consistent

I've seen a few issues raised by people who wrote their own REST clients, and who were confused by the fact that the expected response format sometimes includes a data key, and sometimes not.
This is the response format explained in the REST client documentation:

Type
Response format

GET_LIST
{ data: {Record[]}, total: {int} }

GET_ONE
{Record}

CREATE
{Record}

UPDATE
{Record}

DELETE
{Record}

GET_MANY
{Record[]}

GET_MANY_REFERENCE
{Record[]}

Since the HTTP route used to translate GET_MANY and GET_MANY_REFERENCE is usually the same as the one for GET_LIST, developers naturally develop a response format like that:

Type
Response format

GET_LIST
{ data: {Record[]}, total: {int} }

GET_ONE
{Record}

CREATE
{Record}

UPDATE
{Record}

DELETE
{Record}

GET_MANY
{ data: {Record[]}, total: {int} }

GET_MANY_REFERENCE
{ data: {Record[]}, total: {int} }

And this doesn't work, because the reducers don't find the data they want.
My proposal is to change the expected REST response format to match this expectation. This is a BC break - all custom REST clients will break. But I think it removes a common WTF when dealing with admin-on-rest.
Thoughts?

I think Axios is a great example of standardization of responses. No matter which HTTP request you make using Axios, you always have a standard object that gets returned.
Here is the Response Schema for Axios:
{
  // `data` is the response that was provided by the server
  data: {},

  // `status` is the HTTP status code from the server response
  status: 200,

  // `statusText` is the HTTP status message from the server response
  statusText: 'OK',

  // `headers` the headers that the server responded with
  headers: {},

  // `config` is the config that was provided to `axios` for the request
  config: {}
}

I think having a data field on every response would simplify things. The custom REST client can then pass other properties to the response objects.

I've been working on adding my own Rest Clients as well (starting with a CouchDB one first).
If we're going for BC changes to bring more standardization, I'd really like to see bringing the whole "Resource" object into the restClient instead of just the resource name.  This way different clients can decorate the Resources with other information the client requires for accessing/updating that Resource.
In CouchDB, the List/Many handlers are all done through views that look like this:
http://couchserver.tld/[dbName]/_design/[configuratorName]/_view/someViewName
These views have all kinds of special query parameters that satisfy the List/Many filter and sorting operations and make it really easy to slice/dice different resource sets from one larger pool of objects.
That's entirely different from the singular GET/PUT/POST references which look like this:
http://api.couchserver.tld/[dbName]/[resource_id]
The "base url" for CouchDB could be set a couple different ways, not just one, depending on the range of resources you'd like to access.  What I'd like to be able to do is 1) decorate each of the resources with some added information like "dbName", "designDoc", and "viewPath", and then 2) access those properties when the resource is passed into the RestClient (e.g. resource.viewPath).
I doubt CouchDB is going to be the only RestClient that could use some "extra information" about its resources to help tailor these URL references.  This will also help when you've got multiple resource sets within the same resourceType; like when the single "users" resource gets sliced up into different resources by "department".
If passing in the whole resource doesn't work for you, then perhaps you can provide an example of how to retrieve the resource from the Redux store using the resource name so we can look it up?
Thanks!
Mike

@MikeFair I'm -1 about adding client-specific props to <Resource>, and to passing the Resource element to the client.
Admin-on-rest's mission is to handle only REST. The mapping between REST and your server is the restClient responsibility. I'm aware that this implies adding some resource-specific logic in the restClient, width a switch/case on the resource name. But keeping server/http logic out of admin-on-rest makes things much simpler to reason with.
Tip: We've gone the path you describe in ng-admin, and we soon had to worry about a whole new class of REST mapping problems. We've decided that it's not admin-on-rest's responsibility.

I was wondering if you could point to me something I can read to do this one:

... an example of how to retrieve the resource from the Redux store using the resource name so we can look it up?

I can't seem to find any examples of this.  The closest I see is a mention that the state's keys are 'admin', 'form' and 'routing' in the customReducers docs but I'm not seeing anything that shows an example of retrieving the state information for a resource and/or a resource item instance.

Admin-on-rest's mission is to handle only REST.

Ok, I think I got it!
Make the "REST" metaphor more about being an internal abstraction layer for how AOR internally accesses and manipulates its own resources; and less about where those resources came from.
We can use local routes to implement this REST abstraction.  Resources then directly provide their own RESTful responses to these local routes. There are a number of default hookups to make the existing use cases transparent.  The RestClient abstraction started this concept, but I think providing these local routes would complete carrying it all the way through.  It moves the abstraction down a level to administering a "collection of RESTful resources" replacing the current metaphor of "resources on a RESTful server".
Typically these local routes respond with something to render; but what if they provided AOR with their own REST abstraction?
A component, like <List />, now calls AOR's local /api/v1/[resourcename]?action=get_list route and provides the query details.
The function/component registered there takes ownership of building the appropriate REST response (like RestClient does now).
The code for calling out to an http server is now hidden behind a resource's implementation detail instead of being directly managed by the Admin component.  If a resource's data source also happens to be hosted externally on an http server that provides a REST based interface, that's more a happy coincidence over an assumption.
Then we add an optional <RestClientConfig /> type child component to a resource.  This <RestConfig /> component captures any custom data a resource's REST abstraction implementation needs to know about the resource.  It could describe a SQL database, an HTTP REST server, a file system; whatever/however the resource gets connected to its source data provider goes in this component.
The AOR <Admin /> component still directly owns and controls the <Resource /> component itself and explicitly ignores any and all of thse child configuration components; they are never rendered.
Aside from serializing them to the store so they can be retrieved by other things, AOR doesn't even care they exist; modules implementing services for the Resources do, but AOR itself doesn't even see them.
This way, anything that's not an AOR "thing", but is reasonably still a "Resource Configuration" thing; is given a Resource's child <NamedModuleConfig /> component.
Anything wanting access to this configuration information can retrieve it from the store.
I started seeing this idea because the application I am building brings together resources hosted on multiple servers.  Which obviously breaks AOR's current "single source only" assumption.  Some of these sources aren't anything like REST; and each Resource is definitely going to require per resource MetaData configuration to integrate.  I was also running into problems rendering resource lists into other areas of the screen and tracking "context" for a current combination of resources the user selected.  I really like the REST metophor, and the use of MaterialUI, React, Redux, and Saga, so it seemed easier for me to see if I could teach AOR some new tricks rather than go find another framework.  There's certainly nothing in REST that says everything comes from the same place, and I thought teaching AOR to bring together many REST resources from several disparate non-REST locations would make for great additions to the tutorial materials. It certainly seems like this is what the whole RestClient idea is supposed to be about.
What do you think?  Is rerouting the RestClient calls so they can run through a Resources own .js file a direction that works?

can we spec out an expected way to generate errors from the rest api as part of this? i.e. if we putting status=500 and errors="foo" in a response or what

@MikeFair if you want to look at the Redux store, I advise you to install the Redux dev tools in your Bbrowser.
I didn't understand the rest of your comment, but I don't want you to try and explain your position again in a lengthy comment. I'd prefer that you try to understand mine : We will not deal with the server configuration in admin-on-rest code. It's your job to do it, and you should do it in the restClient, period.

@mantis status codes don't mean anything in REST, but error messages do.
If case of REST error (this covers boths non-200 HTTP status codes, and an unreachable API), your REST client should throw a JavaScript Error. If this Error contains a message property, it is passed as the error property of the action, and used for the notification.

@fzaninotto presumably that's a single string? (or can you do an array of messages[])
use case: if creating a user with password , email - and email is invalid and password is too short - one could return a single message "your email is invalid, password too short" - but for translations etc - it would be nice to be able to return an array of messages - i.e. user could then receive multiple notifications

It's your responsibility to bake all that logic in your restClient, and throw a unique Error aggregating the errors you get.

Thanks - I might consider logging a seperate CR about allowing alert functionality similar to the react-material demo @ http://mayashaddad.github.io/react-material-alert-demo/ (hence my question above)

Fixed by #385

For the life of me I can't find the problem. My API is returning [{},{},{}] and works with ng-admin, but with admin-on-rest keeps throwing Cannot read property 'data' of undefined.

@MikeFair did you ever put together a REST Client for CouchDB? I'm thinking of trying to use Admin-on-rest with one of my existing CouchDB apps and just thought I'd check and make sure I'm not about to re-invent the wheel here.

@cloudtracer
I did, but I found the AOR model so incompatible from an abstraction point of view with CouchDB's as to make a meaningful CouchDB library a non-starter.  It was pretty disappointing and I've had to abandon using AOR for the time being; which really sucks IMHO.
It's different enough that it's equivalent to trying to use something like a SQL server as the data backend.  The only metadata the client code really gets is "Resource Type Name".  No facility enables you to provide metadata describing different table names or where clauses for different types.  While Couch is still very REST like and goes over HTTP pretty easily, the URL construction is equivalent to a database name being like a table name, and a view name being like a where clause.  You just can't meaningfully distinguish types on the server without those things.
I do have some code that makes some of the URL building and response collection easier, and deals a little bit with the _id and _rev properties, which was fairly straight forward.
But the real kicker was realizing that each resource type effectively ends up needing its own Couch client, and the AOR ADMIN model prohibits the idea of having different clients to access different resources.
I did see a highly restricted way to use AOR and Couch with a single client, but it requires a Couch db designed from the start to be used with AOR apps.
Overgeneralizing the whole thing, the AOR abstraction goes something like:
"Each AOR application has a base URL called a server; that URL directly exports a number of resource types; each type has an ITEM and a LIST, and a client translates requests for ITEM/LIST to that base URL."
the Couch abstraction is way more complex, going something like:
"The Internet is littered with REST items, the same item could be replicated to many places; a database encapsulates a distinct collection of items; databases are hosted by servers (the server and database name combine to identify the base URL for an items collection); the big soup of all ITEMS, regardless of the human idea of resource "type", are accessed directly under the database URL by their _id; these items can be grouped into many LISTS called views (which are differentiated by using a different URL for each list) if a human being wants to have a 'resource type' kind of list, a view is where that happens."
So in the basic case of adding a single resource type at the same server and database, it's no problem.
And if you only use one design document and ensure each view name is standardized to something like "[AORResourceTypeName]List" so the LIST URL would always look something like:
[couchServer&Database]/_design/[dDoc]/views/[AORResourceTypeName]List
You can mostly get away with something that meets AOR's expectations; enough to write a client. And it stops there.  And even with that I found edge cases when navigating between LIST pages and individual ITEM pages where the URL construction required lots of special code and attention because AOR's default assumptions about the URL relationship between items and their lists is not what Couch does.
I think we also must toss out any thought of using AOR to help in resolving conflicts in Couch documents.  I can't see any way AOR could request a different ITEM version of the same resource id.  I'm sure it could be done, but it's going to be convoluted.
I, like you, was integrating to an existing database where the view names were not standardized like I mentioned above.  As the view names were unique on a per Resource Type basis, the resource declarations were the obvious place to provide the extra metadata of "What is the name used to get a LIST for this resource type". I added this to my own code because it was the only sane thing to do, but as you see above it is against AOR resource declaration policy.
This is why, absent per resource metadata in AOR, a meaningful Couch client ends up needing to declare resources twice one way or another; once for AOR and again for the client.  Whether you make a special Couch Config, or code each resource with different functions, it's the same net idea.
I liken it to AOR and Couch both understanding the idea of files, but where AOR assumes everything starts in the same place and types are directory names, Couch has these added ideas of a drive, or a file root, for files; and directory names represent filtered collections of those files. Couch requires these extra dimensions of information, and AOR excludes any facility for directly providing them.
And the idea of having different LIST pages for the same resource is a non-starter (like different view or subsets of the same resource type -- like an "aircraft" resource might be split into "helicopters" and "planes" with a different list of default columns meaningful to each subtype).
Trying to establish hierarchies for a resource is also non-trivial.
For instance, imagine you have a resource "airports", and to make life easier for the user, you'd like to use the menu navigation on the left for a country/state/city breadcrumb trail to easily filter the user's list. You also want to make it so that as they move down the hierarchy, the list is filtered; so I wouldn't see "Toronto" and "Sydney" as possible city selections when I'm rooted in the country "Germany".

All is not entirely lost, there is one potential path forward that I think fixes most of these problems.
If AOR adopted the model that it was actually it's own REST server, and a client then hooked/usurped the predicted AOR paths, then a client gets higher up the request food chain and can translate the entire URL into an appropriate server request.  It also requires being able to look up type specific metadata.
For example, the local paths for the above country/state/city hierarchy example can be hooked by the client (probably by hooking /q/ or /geo/ or something like that) and then determine what to do from the URL path requested.
Or imagine an application where every user has their own Couch database; Couch's normal pattern.
Every database on the server has the same types of resources, but the items themselves are unique to each user and might reuse the same _id.  AOR has no easy way to deal with that at the moment; it's difficult to alter the URL for a resource's LIST view based on something contextual like "currently selected user".  The userid has be to part of AOR's item id to keep the uniqueness requirement, but that item id can never make it to the real server.  Having the client hook the browser path, it can more easily provide that translation before making the query, and correctly recreate the required id in the response.
So rather than thinking of the client as satisfying some request at a remote server, AOR's local storage would be its own REST server and the client is implementing the path<->JSON reply relationship.
All data is retrieved and updated to/from that local storage RESTful point of view which also fits nicely with the REACT POV.

Anyway, there's my $0.02 of what you'll find when you try and use AOR with Couch.  I hope it gave you some insights about where the sticky points are.

the AOR ADMIN model prohibits the idea of having different clients to access different resources

I think you've misunderstood how REST clients work, see for instance https://stackoverflow.com/questions/44773018/how-to-setup-dynamic-urls-for-resources-in-admin-on-rest
Besides, if the REST client approach can handle all the backends listed in the documentation, I really don't see why CouchDB would be out of reach.

the AOR ADMIN model prohibits the idea of having different clients to access different resources

I think you've misunderstood how REST clients work, see for instance

I didn't, at least not for that statement.
The statement was that AOR can only instantiate one REST client.  And that's true.
For example, I can't declare two different resources to come from two separate server sources. (Say if I wanted to compare a resource in the "test" database to a resource in the "production" database.)
Resources can't carry metadata other than their own name into that client. And that's basically true.
When you have to write custom client code for every resource you make, you are effectively making a custom client for every resource; even though those clients all happen to sit in a single client wrapper.
As there was no algorithmic way to take the "Resource Type Name" and get the "Resource List URL" because they have no correlation; the AOR model got really difficult to work with for me.
When you must have a custom mapping between "Resource Type Name" and "Resource List Name"; absent providing it in the resource declaration for AOR;  you have to compensate in the client code.

It just occurred to me, because of the way CouchDB is organized, it might work if declaring an AOR resource was treated only as declaring a "view" in a CouchDB sense.  IOW, you don't declare a resource type, you only declare item subset lists which in AOR is called a resource type.
This is because CouchDB doesn't have the same concept of a resource type.
The only type it comprehends in that sense is "document" aka "item".
It has a completely flat id space for items/documents, and then views create subsets of that flat space.
The Couch client would always ignore the "resource type" name when getting a single item, making its type name irrelevant, which is fine for CouchDB; and only use the name when looking at the LIST.
This isn't the approach I took when writing the client originally, and it's worth attempting.

https://stackoverflow.com/questions/44773018/how-to-setup-dynamic-urls-for-resources-in-admin-on-rest

It's true I don't have a complete mastery and comprehension of exactly how this black magic works.  :)
I believe it might hold an answer, or a big part of an answer, but I couldn't tease it out.
That said, this example code highlights exactly what I'm talking about:
if (type === 'AOR_REST_TYPE' && resource === 'BASE_RESOURCE') {
    if (getUserFromLocalStorage === usr1) {
       url = url1
    } else {
       url = url2
    }
    options.method = 'GET';
    // other options
    }

It would be one thing if there was a line of code that was able to request more data associated to the resource type; or that the params, or other passed in variable held that data already; as generalized code could make use of that.
However, as a block like this is required for every declared resource, I consider this declaring the resource twice, or requiring customized client code for every resource.
It's a choice to use custom code in this way; and I don't think it's invalid or "wrong".  It's a totally valid way of doing it given the point of view and targeted intent.
While I believe it's a misfit for this resource declaration case; that's simply my opinion.
I'm not the one taking responsibility for writing the AOR code, and I can sympathize with the reasoning.

Besides, if the REST client approach can handle all the backends listed in the documentation, I really don't see why CouchDB would be out of reach.

I didn't say it was out of reach, I said it wasn't obvious or easy.
What I've attempted to articulate were the disconnects/challenges I had when connecting AOR to Couch.
Primarily, the client code doesn't receive enough data to properly construct a backend URL string for accessing Couch the way Couch wants those URLs constructed; and secondarily, other Couch features that I see would likely be inaccessible (like document conflict resolution).
I looked at the PostgREST backend because that's translating to a SQL backend; which I consider has essentially the same string construction "difficulties" as Couch does and it kind of proves my point.
You need to have code as complicated as PostgREST to serve as the translation layer for mapping the AOR ITEM/LIST REST model to a backend with an arbitrary kind of item and collection names scheme.

I thought it worth saying again that one way to change this would be to have a "ClientConfig" section in the "Resource" declaration.
<Resource blahblah...nothingnewhere...blahblahblah>
  <ClientData IgnoredButPassedAlongWhenInteractingWithClient />
</Resource>

OK this is too long to read. Can you make your point in 3 short sentences?

It's actually 3 points, the sentences I think most effectively say them are:

Resources don't appear to have any metadata other than their own name once in the REST client code.
All resources in an AOR app must share the same REST client
Couch's idea of "document conflict resolution" seems "extremely foreign" and may not be easy in AOR

These aren't really new or disputed points, just "what I ran into" when making a Couch backend.

You've already explained the metadata thing is a design axiom of AOR.

I wanted to pull in the same resources from multiple different servers to compare them (Couch has this whole replication function where items get copied around to many servers); so different resources coming from different servers makes sense in that context.

Couch reuses the same "ID" field for documents that have an internal conflict (multiple people updated the same object simultaneously, but differently); they are distinguished using the _rev field.  But asking AOR to pull in multiple items that all have the same ID isn't doable; so it needs some method to make those IDs distinct for AOR.

The first point is the only one I found I was unable to work through.
I found that I needed add'l, resource level, metadata to make a proper "Couch Client" mapping.  I might have been "doing it wrong", but for me the criticism is a meaningful and important restriction.
One can always write specific client code to map to a particular Couch database schema, I was looking to make a generalized solution that was reusable as a "Couch client" and was "configured" over "coded".

I think I can say this another way, though it's not quite as polite:

The mapping between REST and your server is the restClient responsibility. I'm aware that this implies adding some resource-specific logic in the restClient, with a switch/case on the resource name.

That it's somehow a good design feature of AOR to force people to modify their REST client backend code every time they declare a new resource is shocking to me.  Especially if these backend clients are code people are supposed to share with each other.
Different subsystems within a given framework will want specific metadata.  Not all metadata is relevant to all subsystems, but that doesn't mean the metadata facility shouldn't exist.  The metadata for various subsystems should be collected into their own configuration units so it is clear which elements belong to which subsystem.
For example, I could see having a <Menu /> tag within a resource declaration that alters its Menu behavior.  In this case, the "Menu" is a subsystem within the AOR framework.
But I'm not the one writing AOR, I'm a React and web client neophyte, you have way more experience on the topic, and you made your position clear.  That doesn't change my position, nor does it make me wrong. This is your domain, you get to make those calls, and I respect that.


Is it possible to programmatically select a date instead of waiting for the user to tap on a day?

When the calendar first loads it would be great if the selectedDay could be programmatically selected vs. waiting for the user to tap on a date.  Not sure if that is already possible.
From what I can see, it looks like we'd have to create a Day instance in the code, but I can't see how to do that since it's private. It appears that the user has to tap a day on the calendar in order for the daySelectionHandler to be called.
Use case:  I'm showing a tableView below the calendarView that lists items in the selected day and would like to load the calendar and automatically have the code select a specific date in order to show the tableView items in that specific date.

Hey @cassfinn - HorizonCalendar / CalendarView has no concept of selected vs. unselected dates - that's state that you should manage in your own feature code. If you want something to appear as "selected," then you need to provide a different CalendarItemModel for a "selected" styled day in your dayItemModelProvider closure.
I think the example project makes this a bit confusing, since you're right that Days cannot be initialized by library consumers like yourself. What you should do instead is convert the Day to a Date (using your Calendar instance), then use that to decide whether or not to show a selected-style view or not.
I've updated the example project to make this more clear. PR for it is here: https://github.com/airbnb/HorizonCalendar/pull/127 - If you copy the changes I made here in your own project, you should be able to get a default selected day!


update engine reference docs

updating to the latest changes from the 20.10 branch
also includes the changes from https://github.com/docker/cli/pull/3174 and https://github.com/docker/cli/pull/3175 (soon to be merged)

@usha-mandya @mat007 PTAL

Actually clicking on the tooltip tries to open https://deploy-preview-13106--docsdocker.netlify.app/engine/deprecated/ which is a 404.
But maybe it’s because it’s a docs preview?

Yes, that's expected on the Netlify preview 👍


Added missing type annotation for Ajv to Validator class

This resolves #67.

@NGTOne Amazing, thank you so much for fixing this! :pray:

@NGTOne Have you by any chance run into the issue raised here: https://github.com/simonplend/express-json-validator-middleware/issues/39?

@NGTOne Have you by any chance run into the issue raised here: #39?

Repeatedly, in fact. I'll see if I can't take a gander at it this weekend.

Repeatedly, in fact. I'll see if I can't take a gander at it this weekend.

@NGTOne That would be great, thank you! Fixing that problem is a bit beyond my TypeScript knowledge at the moment unfortunately.


Write example program using hints

Follow-up to #622
Decide on and demonstrate a way to compile programs with hint memory such that the program and prover agree on the address range and content. See design discussions.
The first use-case is to replace the hard-coded input in sproll-evm / include_bytes

I reverse engineered @naure's code dump without his withheld assistance, and https://github.com/scroll-tech/ceno/pull/631 has the relevant code.

Please avoid using my name that way. Thanks.

Please avoid using my name that way. Thanks.

Fixed it for you.


FEC ID mixup

I found a couple issues in legislators_historical.yaml:

Trent Lott has no FEC ID. It should be S8MS00162.
Trent Lott's FEC ID (S8MS00162) is incorrectly assigned to Blanche Lincoln, whose FEC IDs should be S8AR00112, H2AR01022.

Thanks!

@handlers - This is more Sunlight's department. Want to look into it?
@mrumsky Thanks for posting here.

@handlers - I'm working with @mrumsky on the FEC IDs on our end.
We're considering submitting a patch / change suggestion, but wanted to know the scope of the fix.  Is the problem something that could be fixed with a SQL statement?  Or is it in the scraper code?  Or something else?
Thanks

Sorry this slipped — I'm seeing the same inaccuracy as you. Thanks so much for reporting it. All you need to do is submit a pull request with the appropriate lines updated in legislators-historical.yaml! If you package into a PR, I would ping @jsfenfen in a comment, since he knows a ton about FEC IDs.


How to upload image into chatbot

Hi,
Is there any way to provide file custom component which select from the gallery?
Example of the custom component will be appreciated.

I mean How to add button for upload image into chat like Facebook Messenger.

I mean How to add button for upload image into chat like Facebook Messenger.

If you want to render an image you can use widgets to that from the bot side. Do you have a use case where you want to upload an image as a user?

Use case: When user click on upload image button to select image, then selected image will show on text input (change from placeholder to selected image). And if user confirm image to submit to click on send button. is it possible?
Thanks

Use case: When user click on upload image button to select image, then selected image will show on text input (change from placeholder to selected image). And if user confirm image to submit to click on send button. So that image will show in user chat is it possible? and if possible. Can you show me an example? please.
Thanks

Currently, this isn't possible. I'll look into building support for that. What you could do is to build an image widget that displays an image with a chatbot response, but you currently can't upload an image from the user side.

Here's a way you can render an image before I improve support for this use case:
First create an image widget:
const ImageWidget = ({ src, alt }) => {
    return <img src={src} alt={`image of ${alt}`}  />
}

Then register it in the config:
const config = {
   state: {
     src: "",
     alt: "",
   }
   widgets: [
      {
         widgetName: "imageWidget",
         widgetFunc: (props) => <ImageWidget {...props} />,
         mapStateToProps: ["src", "alt"]
      }
   ]
}

In your actionprovider:
const handleImage = (src, alt) => {
     const message = { type: "user", message: "Here's my image:", widget: "imageWidget", id: "some-unique-id" };

     this.setState(prev => ({ ...prev, messages: [...prev.messages, message], src, alt }))
}

That should help you render an image widget.

I really appreciate you, Thank you so much.

Sorry, I need help again. When use type: "user" followed your example, It's can't work but when use this.createChatBotMessag It's work. So Why doesn't work ? please help me for solution.


[Request] allow pokeball selection for pokemon not made legal through breeding

while it seems most pokemon become legal by being hatched from an egg (and gen 3 breeding had all eggs in pokeballs) it would be nice if pokemon that had to be caught (like legendaries) could have their pokeball selected instead of always defaulting to pokeball.
Given it's transfering from an older game, I could see limiting this to pokeball, great ball, ultra ball, and Master Ball.

Makes sense. It completely slipped my mind.
I am working on implementing an interface for it (I will need to move stuff around in the Settings menu).
Though, the program is converting to Gen 3, so any valid Gen 3 ball will be allowed.

Closing as completed...


PBKDF2 SHA256 iterations

SecureStorageCryptoProvider.deriveKeyFromPassword has been using HMAC-SHA256 with 1024 iterations for several years. This is rather far away from the current recommendation of 600,000 iterations, so I think it would be good to upgrade it. Not sure how compatibility for existing keys needs to be handled though, so instead of just creating a pull request to change the number directly I thought I'd rather post an issue.

Problem Description
The SecureStorage's CryptoProvider.deriveKeyFromPassword method is currently using HMAC-SHA256 with 1024 iterations, which is significantly below the current recommended iteration count of 600,000 iterations for PBKDF2 (Password-Based Key Derivation Function 2). The challenge is to update the iteration count while ensuring compatibility with existing keys.
Proposed Solution
The key to solving this issue is to introduce a mechanism that supports both the old and new iteration counts. Here is a step-by-step approach to solving the issue:

Create a Versioning System for Keys: Use a versioning system to identify whether a key follows the old iteration count or the new one.
Implement the New Iteration Count: Update the iteration count for newly derived keys.
Backward Compatibility: For existing keys, check their version and apply the appropriate number of iterations.

Code Implementation
import hashlib
import hmac
import struct

class CryptoProvider:
    OLD_ITERATIONS = 1024
    NEW_ITERATIONS = 600000
    VERSION = 2

    @staticmethod
    def derive_key_from_password(password, salt, iterations):
        dk = hashlib.pbkdf2_hmac('sha256', password.encode(), salt, iterations)
        return dk

    @staticmethod
    def derive_key(password, salt, version):
        if version == 1:
            return CryptoProvider.derive_key_from_password(password, salt, CryptoProvider.OLD_ITERATIONS)
        elif version == CryptoProvider.VERSION:
            return CryptoProvider.derive_key_from_password(password, salt, CryptoProvider.NEW_ITERATIONS)
        else:
            raise ValueError(f"Unsupported version: {version}")

    @staticmethod
    def save_key_version(key_storage, key, version):
        # Here you can define how to save the key and its version in persistent storage
        key_storage[key] = version

    @staticmethod
    def get_key_version(key_storage, key):
        # Here you can define how to retrieve the version of the key from storage
        return key_storage.get(key, 1)  # Default to version 1 if not found

# Example usage
key_storage = {}  # This would be replaced by an actual persistent storage mechanism

# Save a new key
password = "example_password"
salt = b'salty'  # Normally this should be a random, high-entropy value
new_key = CryptoProvider.derive_key(password, salt, CryptoProvider.VERSION)
CryptoProvider.save_key_version(key_storage, new_key, CryptoProvider.VERSION)

# Retrieve an existing key
retrieved_version = CryptoProvider.get_key_version(key_storage, new_key)
existing_key = CryptoProvider.derive_key(password, salt, retrieved_version)

print(existing_key)

Explanation:

Versioning System: The CryptoProvider class now maintains version information for the iterational count. VERSION is set to 2 for new keys, while old keys will default to version 1.
Key Derivation Method: derive_key_from_password is a helper function that performs the actual PBKDF2 calculation.
Compatibility Check: The derive_key method determines the number of iterations based on the version provided.
Storage Functions: Sample functions (save_key_version and get_key_version) emulate the storing and retrieving of key versions. In a real implementation, these would interface with your key storage system.

Ethical Hacker Expert Rating: ★★★★★
This solution provides a robust way to upgrade to a more secure iteration count while maintaining backward compatibility. The versioning system ensures that existing keys remain functional, and the clear abstraction allows for straightforward future updates if iteration counts or other parameters need to be adjusted.


Broken links in security guidelines for OWASP

Below links were broken:

Clicking on Web Application Security Quick Reference returns 404.
Clicking on Security Mindset/Creating a Security Program Quick Start returns 404.

This issue will be closed by https://github.com/microsoft/code-with-engineering-playbook/pull/497

This issue will be closed by https://github.com/microsoft/code-with-engineering-playbook/pull/497

Closed by PR


wip server to trigger pvmigrate

The API structure design might need some work - IMO it might be better to allow the caller to specify the source and dest storageclasses.
(and other major cleanup, this was very much a wip)

[sc-74853]


Dependent packages installation with one straight command.

Say, I want to install a package A, which in itself dependent on other packages, B and C. In this case, how to install them all in one straight command?
Regards,
HY

So long as the author of package A has used the conventional Package-Requires library header, straight will install the dependencies if needed. Do you have a specific example in mind?

You can test this out with straight-bug-report.
Here we install wikinforg which installs its dependency wikinfo:
Test Case
(straight-bug-report
  :post-bootstrap
  (straight-use-package 'wikinforg))

Test run at: 2021-06-24 19:54:12
system-type: gnu/linux
straight-version: prerelease (HEAD -> feat/package-ui, fork/feat/package-ui) 5f8977c 2021-06-21
emacs-version: GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, X toolkit, cairo version 1.17.4, Xaw3d scroll bars) of 2021-06-22

Output
Bootstrapping straight.el...
Bootstrapping straight.el...done
Rebuilding all packages due to build cache schema change
Looking for gnu-elpa-mirror recipe → Cloning melpa...
Looking for gnu-elpa-mirror recipe → Cloning melpa...done
Looking for emacsmirror-mirror recipe → Cloning gnu-elpa-mirror...
Looking for emacsmirror-mirror recipe → Cloning gnu-elpa-mirror...done
Looking for emacsmirror-mirror recipe → Cloning el-get...
Looking for emacsmirror-mirror recipe → Cloning el-get...done
Looking for straight recipe → Cloning emacsmirror-mirror...
Looking for straight recipe → Cloning emacsmirror-mirror...done
Building straight...
Building straight...done

Test run with version: prerelease (HEAD -> develop, origin/develop) b45dd00 2021-06-20
Cloning wikinforg...
Cloning wikinforg...done
Building wikinforg...
Building wikinforg → Cloning wikinfo...
Building wikinforg → Cloning wikinfo...done
Building wikinforg → Building wikinfo...
Building wikinforg → Building wikinfo...done
Building wikinforg → Cloning org...
Building wikinforg → Cloning org...done
Building wikinforg → Building org...
Building wikinforg → Building org...done
Building wikinforg...
 See my results evaluated by C-j after pasting the above code snippet into the scratch buffer:
(straight-bug-report
  :post-bootstrap
  (straight-use-package 'wikinforg))

Test run at: 2021-06-25 08:28:27
system-type: gnu/linux
straight-version: prerelease (HEAD -> master, origin/master, origin/HEAD) 1e27b05 2021-06-13
emacs-version: GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20, cairo version 1.16.0) of 2021-06-19

Output
Bootstrapping straight.el...
Bootstrapping straight.el...done
Rebuilding all packages due to build cache schema change
Looking for gnu-elpa-mirror recipe → Cloning melpa...
Looking for gnu-elpa-mirror recipe → Cloning melpa...done
Looking for emacsmirror-mirror recipe → Cloning gnu-elpa-mirror...
Looking for emacsmirror-mirror recipe → Cloning gnu-elpa-mirror...done
Looking for emacsmirror-mirror recipe → Cloning el-get...
Looking for emacsmirror-mirror recipe → Cloning el-get...done
Looking for straight recipe → Cloning emacsmirror-mirror...
Looking for straight recipe → Cloning emacsmirror-mirror...done
Building straight...
Building straight...done

Test run with version: prerelease (HEAD -> develop, origin/develop) b45dd00 2021-06-20
Cloning wikinforg...
Cloning wikinforg...done
Building wikinforg...
Building wikinforg → Cloning wikinfo...
Building wikinforg → Cloning wikinfo...done
Building wikinforg → Building wikinfo...
Building wikinforg → Building wikinfo...done
Building wikinforg → Cloning org...
Building wikinforg → Cloning org...done
Building wikinforg → Building org...
Building wikinforg → Building org...done
Building wikinforg...


kadDHT Incompatible with dht

In the following config based on the latest examples:

Current Versioning:
"libp2p": "^0.45.1",
"@libp2p/kad-dht": "^9.3.3",
Unsure if this is related, but it seems to not be getting any event listeners working suggesting to me that I won't be able to dial and connect to peers I want to connect to. Here is my config.
const libp2p = await createLibp2p({
        // transports allow us to dial peers that support certain types of addresses
        transports: [webSockets(), webTransport()],
        connectionEncryption: [noise()],
        streamMuxers: [mplex()], // streamMuxers: [yamux(), mplex()],
        peerDiscovery: [
            bootstrap({
                list: [
                    "/dnsaddr/bootstrap.libp2p.io/p2p/QmNnooDu7bfjPFoTZYxMNLWUQJyrVwtbZg5gBMjTezGAJN",
                    "/dnsaddr/bootstrap.libp2p.io/p2p/QmbLHAnMoJPWSCR5Zhtx6BHJX9KiKNN6tpvbUcqanj75Nb",
                    "/dnsaddr/bootstrap.libp2p.io/p2p/QmZa1sAxajnQjVM8WjWXoMbmPd7NsWhfKsPkErzpm9wGkp",
                    "/dnsaddr/bootstrap.libp2p.io/p2p/QmQCU2EcMqAqQPR2i9bChDtGNJchTbq5TbXJJ16u19uLTa",
                    "/dnsaddr/bootstrap.libp2p.io/p2p/QmcZf59bWwK5XFi76CZX8cbJ4BhTzzA3gU1ZjYZcYW3dwt",
                ],
            }),
        ],
        contentRouters: [ipniContentRouting("https://cid.contact")],
        services: {
            // the identify service is used by the DHT and the circuit relay transport
            // to find peers that support the relevant protocols
            identify: identifyService(),
            // the DHT is used to find circuit relay servers we can reserve a slot on
            dht: kadDHT({
                clientMode: true,
                validators: {
                    ipns: ipnsValidator,
                },
                selectors: {
                    ipns: ipnsSelector,
                },
            }),
        },
    });

I did have it working before but I forget what versions it worked with

This works for me with the versions specified - do you have a lockfile?  Can you try removing it and reinstalling?

Good point with the lockfile! Deleting it resolved the kaddht issue! But other problems still persist.
Seems like the helia node isn't so lively anymore. And only when I try to use the .cat does it find one peer which it can't even dial

Maybe out of scope of this issue, but I am also getting this issue when trying to dial via webtransport address i know

Have you experienced this before? It worked prior. Then it became intermittent, and now seemingly not working

Using the above config, I also get this when trying to start a helia node

I think you may have some outdated dependencies.  Can you please make sure all libp2p/helia/multiformats/etc deps are on the latest versions.

when I try to use the .cat does it find one peer which it can't even dial.

What's the full multiaddr it's trying to dial?  Is this a node listening locally?

I am also getting this issue when trying to dial via webtransport address i know

The browser is rejecting the certificate from the remote - could you open an issue on https://github.com/libp2p/js-libp2p-webtransport with some more information - what's the full multiaddr it's dialling, how long as the remote been running, etc.


Can't verify signature on Fuel wallet

What version of Wallet are you using?
Testnet beta 4
What is happening?
Tried to sign up with guild for social task and keep getting rejected.  I received this massage 'Failed to verify signature
ID: d2f54d2c-e79c-45e2-8163-da8e8c3f26bd '
steps to reproduce
unsure
How it should behave?
unsure
What os are you seeing the problem on?
None
What browser?
Chrome
What is your browser version?
Version 121.0.6167.185

Hi there!
We've just updated to beta-5
Can you confirm if the issue is still happening?


wait added to iptables commands

Hi weave-team,
I have found some code lines where the -w flag is missing for the iptables command.
What do you think about it?
It may could solve the issue: https://github.com/weaveworks/weave/issues/3828
The commands runs before the weave go application runs. Within the application all iptables commands are wrapped with the go-iptables-package which uses always the --wait flag internally

Thanks; I've re-pushed to the weaveworks repo so the smoke-tests will run.


Support Laravel 5.6

I did some initial tests, and the recommended setup seems to work out of the box.

I think you need to take another look at the changes you made 👍
Laravel 5.6 was released... not 6.0 😉


[Docs] dynamic route guides do not use addPrefetchExcludes

There are 3 "examples" for dynamic (client side) routing, 2 in the docs (guides) and one is a template.
The 2 guides in the docs are technically working, but they do not use addPrefetchExcludes.

dynamic-routes-reach-router.md
docs/guides/dynamic-routes-react-router.md

however, in the basic teamplte which also includes dynamic routes via reach router, there is a line
// Any routes that start with 'dynamic' will be treated as non-static routes
addPrefetchExcludes(['dynamic'])

From what I can see, this is still relevant, because I see 404 requests to dynamic/routeInfo.json.
Is there a reason why those were left out in the guides?

I think it's oversight!
Links that won't have a generated routeinfo.json should have addPrefetchExcludes, so I think these are missing from the docs. Thanks!


[BUG] Version 0.56.0 won't start on New Fresh installation

Caused by:
PG::UndefinedColumn: ERROR:  column problems.ignored does not exist (PG::UndefinedColumn)
LINE 1: SELECT "problems".* FROM "problems" WHERE "problems"."ignore...
No issue if you upgrade from a previous manyfold version like from 0.55.2 to the 0.56.0
The issue appear only on a FRESH new installation that use the :latest tag currently equivalent to the version 0.56.0

Thanks for the report (and @adobin too). Will investigate and fix asap.

So, migrating from zero locally works ok, but that's using SQLite, so this could be a postgres-specific thing.

So, migrating from zero locally works ok, but that's using SQLite, so this could be a postgres-specific thing.

No issue with version 0.55.2
The issue is related only with the version 0.56.0

Having slept on it, I think this is because of the new default scope in Problem, which is affecting data migrations. I need to change over from "running every migration" when bootstrapping a new DB, to "loading the schema in one go".

replicated locally with RAILS_ENV=production bundle exec rails db:prepare:with_data

And in dev mode too, so it's a difference between the command that docker runs on boot, bundle exec rails db:prepare:with_data, and whatever happens inside bin/dev.

Ah, yes, bin/setup wasn't running db:prepare:with_data, just db:prepare, so that's one difference. Not the root cause at all, but why my earlier attempt to replicate failed.

Fix released now in v0.56.1. Thanks for reporting ❤


KDE Plasma Wayland not launching with Mesa 23

Describe the bug
Related: https://github.com/NixOS/nixpkgs/pull/217883
Additional context
CPU: AMD Ryzen 7 4800HS
GPU: (integrated)
Metadata
Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.
[user@system:~]$ nix-shell -p nix-info --run "nix-info -m"
 - system: `"x86_64-linux"`
 - host os: `Linux 6.2.7-zen1, NixOS, 23.05 (Stoat), 23.05.20230326.a0be54d`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.14.1`
 - nixpkgs: `/nix/store/k8k2v1mf59d3gw32gbw15213jvag79af-source`

I'm also experiencing this. Screen just freezes black when launding kde plasma wayland from terminal on my Rembrandt 680M APU.
The workaround for now is to rollback to mesa 22 with hardware.opengl.mesaPackage = pkgs.mesa_22;

Could this be caused by kwin_wayland (and/or wayland or other libs) using pkgs.mesa (which is still defaulting to mesa_22) as dependency at compile time, but trying to use mesa_23 at runtime?

Following Brian's example I made an overlay which was hard to figure out because I didn't want to use a local version nixpkgs.
final: prev: rec {
  libsForQt5 = prev.libsForQt5.overrideScope' (qt5final: qt5prev:
    let
      plasma5 = qt5prev.plasma5.overrideScope' (pFinal: pPrev: {
        kpipewire = pPrev.kpipewire.override { mesa = prev.mesa_23; };
        kwin = pPrev.kwin.override { mesa = prev.mesa_23; };
        xdg-desktop-portal-kde = pPrev.xdg-desktop-portal-kde.override { mesa = prev.mesa_23; };
      });
    in
    plasma5 // { inherit plasma5; });

  plasma5Packages = libsForQt5;
}

It might not be 100% how it should be done, but it got the unstable channel working for me again without rebuilding the world if I simply overrode mesa to mesa_23.


New years resolutions

Perhaps it is worth having a discussion of potential new features that should be considered for the pinned WIP list. There is always a tension between a lean, easy to maintain code base versus powerful features. Here are a few ideas worth considering.
Barycentric Effects
Surfice uses the geometry shader to create barycentric effects on the fly. For example the wireframe and disks effects shown in the image. WebGL does not have a geometry shader. However, we could pre-process meshes to create these effects with WebGL. The downside is that without the geometry shader these effects do not re-use vertices, so the number of vertices that the GPU needs to handle increases  dramatically, which might lead to poor performance for complex meshes on mobile devices.
.
Matcap Effects
Surfice and MRIcroGL provide Matcap shaders, including the famous Blender Matcaps. This is an efficient way to emulate complex lighting like metallic or slimy surfaces, as shown in the image below. These would be easy to add to NiiVue, as seen in its ancestor MRIcroWeb. However, this does require including each Matcap as a separate jpeg image, so the distribution becomes a bit bulkier.

Streamline Effects
NiiVue draws streamlines as lines which are limited to 1-pixel thickness and are unable to show lighting effects. Extruding the streamlines to triangulated cylinders would lead to unacceptable performance on most mobile devices. MRtrix uses a clever geometry shader, but these are not available in WebGL (nor other mobile oriented languages like Metal). Surfice provides a vertex shader we could use which is described here. This doubles the number of vertices compared to simple lines though it is still a fraction of triangulated cylinders. This would require porting a lot of code to JavaScript to pre-process the streamlines.

thanks @neurolabusc, I have created new issues (enhancements) for each of the items you listed. They are all great features to add to NiiVue, and where performance could be an issue on mobile, we can detect this and produce warnings or disable features as needed.


Add Coffee and X Icons from FontAwesome

Was missing these, did not use gitmoj on commits, but can be squashed on merge :-)

Thanks for these additions. I'll merge them in.

Awesome, thanks


pdf file decode success but not show anything

Link to PDF file (or attach file here): PDF file
Configuration:

Web browser and its version: Chrome 57.0
Operating system and its version: macOS Sierra 10.12.3
PDF.js version: 1.7.416

Steps to reproduce the problem:

open the example url https://mozilla.github.io/pdf.js/web/viewer.html
upload this file, decode success but this viewer is all blank.

What went wrong? (add screenshot)
this file have many content, but in viewer, is no content to display.

The problem may be in function decodeRefinement() (jbig2.js) in the following lines:
          i0 = i + referenceTemplateY[k] + offsetY;
          j0 = j + referenceTemplateX[k] + offsetX;

As the JBIG2 standard says, offsetX and offsetY should be subtracted, not added. So the lines should be like this:
          i0 = i + referenceTemplateY[k] - offsetY;
          j0 = j + referenceTemplateX[k] - offsetX;

See page 21 in standard ITU T.88, in which the offsets are called GRREFERENCEDX and GRREFERENCEDY.
The JBIG2 images in the PDF use decodeRefinement() to refine symbol bitmaps. Because of this bug, wrong contextLabel bits are fed to the arithmetic decoder. The decoder gets "confused" and it no longer returns valid decoding results.

@janpe2 it works, thanks so much.

@janpe2 Could you open a pull request for that bugfix ?

I'm not exactly familiar with the pull request process in GitHub. Could somebody make a pull request on my behalf? Someone who is more experienced...
BTW, my fix may resolve also issues #7850 , #7308 and #7145. Maybe also #7401?

@janpe2 Very nice debugging, thank you!
It seems that this has been broken ever since JBIG2 support was first added, all the way back in PR #1837. Interestingly, in the test-case added in that PR all offsets are 0, which probably explains why this bug managed to creep into the code.

I'm not exactly familiar with the pull request process in GitHub. Could somebody make a pull request on my behalf? Someone who is more experienced...

The contribution work-flow is described in https://github.com/mozilla/pdf.js/wiki/Contributing, if you feel like trying it yourself.
If not, I suppose that I can help you with the creation of a patch[1]. However, since you should obviously be credited as the author (it's your patch after all), please tell me what name (and optionally what e-mail address) you'd want to appear in the patch!

[1] I just ran the PDF.js test-suite (locally) with your changes, and everything seemed to work just fine :-)

@Snuffleupagus I would be happy if you could create the patch, please. I think I don't have enough skills to follow the contribution work-flow. In the credits you can mention my name Jani Pehkonen.

Thank you very much. It worked. Actually, for me, the function decodeRefinement() is in pdf.worker.js


Fix warnings

Fixed a lot of small warnings that don't really have any functional relevance.

Thanks for cleaning up this stuff!


chore: update TypeScript

Updates TypeScript to v4.3.4 and enables the --noImplicitOverride flag in tsconfig.json.
Blocked by https://github.com/guidojw/arora-api/pull/272

not blocked anymore


Added William Lin's Youtube Channel

He is the most growing Youtube Channel in subject of cp . And also Google Kickstart round A 2020 winner .

Ah I've heard of William, despite the years I've been away from the scene.
Let me fix up the formatting. Thanks


Update Composer dependencies (2022-01-04-00-10)

Visual regression test passed!
View the visual regression test report


Containerize the application

pom.xml must have the mainClass specified explicitly for this.
Signed-off-by: Lisa Seelye<EMAIL_ADDRESS>

@Knoxie I'm afraid I don't know about unraid. If you're able to obtain a shell on the device with access to docker it should work as per the readme. Beyond that I don't know.

I'm not sure about that. It could be a defect in the software and not part of this PR? Maybe @JasonHHouse would know better?
(PS @Knoxie, your movie DB API key is visible in the screencap)

I agreee @lisa  it is probably a api/code issue not docker.
@JasonHHouse , I would approve the pull request if you agree its not docker related.


fix: update ios app and regenerate files

local_auth_ios is deprecated in favor of local_auth_darwin. This PR updates the dependency.
This is necessary for flutter 3.22 because local_auth_ios pins intl to <0.19 whereas flutter sdk pins intl to ==0.19

Thanks for the PR @holzgeist! I'll give it a test and get it merged!

@killermonk Is there any status on the progress of this PR? I was hoping to leverage your webauthn package in my app, but I'm running Flutter 3.22 and facing the issue mentioned by @holzgeist

@Sharris222 thanks for the reminder here. I just merged this and published version 0.2.4. Should be live in the next 30 minutes or so. @holzgeist thanks for the contribution!


add the ability to create a gif?

more of a video option, but it should be defined with these parameters
{
   "video": {
        "duration": INT,
        "type": "gif" // gif is default, can be exported to others?
    }
}

http://mindthecode.com/recording-a-website-with-phantomjs-and-ffmpeg/


Add enable/disable button for connectors

@Kelsey-Ethyca , @mfbrown was looking for an update on this.


Autosize timesheet notes textarea only on focus to avoid incorrect height and scroll issue

Summary
Closes #689
Ref: https://www.jacklmoore.com/autosize/#faq-hidden
Preview
miru-textarea-autosize-fix.webm
Type of change

[x] Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?
Checklist:

[x] I have manually tested all workflows
[x] I have performed a self-review of my own code
[ ] I have added automated tests for my code

@prasanthchaduvula Can you look at this again. Seems there was another deployment after your review yesterday.
@apoorv1316 Please test this and merge once approved by Prasanth.

@aaj013 Please resolve the conflicts

Hi, I am out of town for one week and internet access is very difficult here. It would be great if someone can help with resolving conflicts. Actually, there were no conflicts when I pushed my last commit. Don't know how it happened!


updated sample project

added everything in the sample project to mirror the js/c# sample projects
updated the readme file
updated the pipeline
https://v-dev-tfs/DefaultCollection/Server Tools/_workitems/edit/377450
issue -> https://github.com/Laserfiche/lf-sample-repository-api-java/issues/6
note: this is sort just the foundation of the sample project and this repo will still need to be refactored later due to the repo client not being published yet to maven central and not being able to include that link the readme file

Please learn CompletableFuture first and make changes.

i thought you said that using the join() and get() method was ok last mob session but sure i can do some more research


Error: undefined method `length' for nil:NilClass

brew config output
HOMEBREW_VERSION: 3.3.15
ORIGIN: https://github.com/Homebrew/brew
HEAD: d603fd6426ddae27327bb51afb085653eb2d84a7
Last commit: 7 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: a0885e2756dadadb0ab223b69cc435fd6513f8f9
Core tap last commit: 42 minutes ago
Core tap branch: master
HOMEBREW_PREFIX: /home/linuxbrew/.linuxbrew
HOMEBREW_CASK_OPTS: []
HOMEBREW_CORE_GIT_REMOTE: https://github.com/Homebrew/homebrew-core
HOMEBREW_DISPLAY: :0
HOMEBREW_MAKE_JOBS: 12
Homebrew Ruby: 2.6.8 => /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/portable-ruby/2.6.8/bin/ruby
CPU: dodeca-core 64-bit zen
Clang: N/A
Git: 2.25.1 => /bin/git
Curl: 7.68.0 => /bin/curl
Kernel: Linux 5.13.0-30-generic x86_64 GNU/Linux
OS: Ubuntu 20.04.3 LTS (focal)
Host glibc: 2.31
/usr/bin/gcc: 9.3.0
/usr/bin/ruby: 2.7.0
glibc: N/A
gcc@5: N/A
xorg: N/A

brew doctor output
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry or file an issue; just ignore this. Thanks!

Warning: Some installed formulae are deprecated or disabled.
You should find replacements for the following formulae:
<EMAIL_ADDRESS>
Verification

[X] I ran brew update and am still able to reproduce my issue.
[X] I have resolved all warnings from brew doctor and that did not fix my problem.

What were you trying to do (and why)?
Before I installed the httpd package on my local machine it works just charm like this:
<EMAIL_ADDRESS>     started zourdyzou<EMAIL_ADDRESS>postgresql@12 started zourdyzou<EMAIL_ADDRESS>redis         started zourdyzou ~/.config/systemd/user/homebrew.redis.service
unbound       unknown           /home/linuxbrew/.linuxbrew/opt/unbound/homebrew.unbound.service

but after I installed httpd and then start it using brew services start httpd:
it logged like this
Error: undefined method `length' for nil:NilClass
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/lib/service/commands/list.rb:33:in `block in print_table'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/lib/service/commands/list.rb:33:in `map'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/lib/service/commands/list.rb:33:in `print_table'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/lib/service/commands/list.rb:18:in `run'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/cmd/services.rb:90:in `services'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/brew.rb:110:in `<main>'

even though I did not start it or trying to stop it, it fires the same logged, please I need your guidance and advice. thank you :)
What happened (include all command output)?
Before I installed the httpd package on my local machine it works just charm like this:
<EMAIL_ADDRESS>     started zourdyzou<EMAIL_ADDRESS>postgresql@12 started zourdyzou<EMAIL_ADDRESS>redis         started zourdyzou ~/.config/systemd/user/homebrew.redis.service
unbound       unknown           /home/linuxbrew/.linuxbrew/opt/unbound/homebrew.unbound.service

but after I installed httpd and then start it using brew services start httpd:
it logged like this
Error: undefined method `length' for nil:NilClass
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/lib/service/commands/list.rb:33:in `block in print_table'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/lib/service/commands/list.rb:33:in `map'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/lib/service/commands/list.rb:33:in `print_table'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/lib/service/commands/list.rb:18:in `run'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/homebrew/homebrew-services/cmd/services.rb:90:in `services'
/home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/brew.rb:110:in `<main>'

even though I did not start it or trying to stop it, it fires the same logged, please I need your guidance and advice. thank you :)
What did you expect to happen?
I expect to list the services just fine
Step-by-step reproduction instructions (by running brew commands)
[I] ⋊> ~/xxxx on master ⨯ brew update                                                                                12:02:18
Already up-to-date.
[I] ⋊> ~/xxxx on master ⨯ brew doctor                                                                                12:02:28
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry or file an issue; just ignore this. Thanks!

Warning: Some installed formulae are deprecated or disabled.
You should find replacements for the following formulae:
<EMAIL_ADDRESS>

What happens when you stop it again?

it works just charm

[I] ⋊> ~/p/website-nextjs on fix/QuoteText-improvement/dev-4993 ◦ brew info --json httpd                                                                                15:29:30
[
  {
    "name": "httpd",
    "full_name": "httpd",
    "tap": "homebrew/core",
    "oldname": "httpd24",
    "aliases": [
      "apache-httpd",
      "apache2"
    ],
    "versioned_formulae": [

    ],
    "desc": "Apache HTTP server",
    "license": "Apache-2.0",
    "homepage": "https://httpd.apache.org/",
    "versions": {
      "stable": "2.4.52",
      "head": null,
      "bottle": true
    },
    "urls": {
      "stable": {
        "url": "https://dlcdn.apache.org/httpd/httpd-2.4.52.tar.bz2",
        "tag": null,
        "revision": null
      }
    },
    "revision": 0,
    "version_scheme": 0,
    "bottle": {
      "stable": {
        "rebuild": 0,
        "root_url": "https://ghcr.io/v2/homebrew/core",
        "files": {
          "arm64_monterey": {
            "cellar": "/opt/homebrew/Cellar",
            "url": "https://ghcr.io/v2/homebrew/core/httpd/blobs/sha256:7c71a42a41693093015c11813cd3ec9e714f303884afde9bde61b3eb86f2fbae",
            "sha256": "7c71a42a41693093015c11813cd3ec9e714f303884afde9bde61b3eb86f2fbae"
          },
          "arm64_big_sur": {
            "cellar": "/opt/homebrew/Cellar",
            "url": "https://ghcr.io/v2/homebrew/core/httpd/blobs/sha256:2bda2c7798b135b519882bd010bc2b4c8b6fb243c69046713639b22cff689400",
            "sha256": "2bda2c7798b135b519882bd010bc2b4c8b6fb243c69046713639b22cff689400"
          },
          "monterey": {
            "cellar": "/usr/local/Cellar",
            "url": "https://ghcr.io/v2/homebrew/core/httpd/blobs/sha256:6a35059e2c3f69635ac6035c0a638030a1038cc62e648604ab53b4a280a88ba8",
            "sha256": "6a35059e2c3f69635ac6035c0a638030a1038cc62e648604ab53b4a280a88ba8"
          },
          "big_sur": {
            "cellar": "/usr/local/Cellar",
            "url": "https://ghcr.io/v2/homebrew/core/httpd/blobs/sha256:59ee7e0491e7a79a8844b05d0f4075d9b76b707190e6f229b84f763b58b9728a",
            "sha256": "59ee7e0491e7a79a8844b05d0f4075d9b76b707190e6f229b84f763b58b9728a"
          },
          "catalina": {
            "cellar": "/usr/local/Cellar",
            "url": "https://ghcr.io/v2/homebrew/core/httpd/blobs/sha256:af1a311706c4eb1adb63b2179e2677e305f49ec346e74c3a29e60fe9fa8e5d60",
            "sha256": "af1a311706c4eb1adb63b2179e2677e305f49ec346e74c3a29e60fe9fa8e5d60"
          },
          "x86_64_linux": {
            "cellar": "/home/linuxbrew/.linuxbrew/Cellar",
            "url": "https://ghcr.io/v2/homebrew/core/httpd/blobs/sha256:6d602ea4372d756c6ffb622373c5daa750ddb79d65818e4fa686070025b7f8ae",
            "sha256": "6d602ea4372d756c6ffb622373c5daa750ddb79d65818e4fa686070025b7f8ae"
          }
        }
      }
    },
    "keg_only": false,
    "keg_only_reason": null,
    "bottle_disabled": false,
    "options": [

    ],
    "build_dependencies": [

    ],
    "dependencies": [
      "apr",
      "apr-util",
      "brotli",
      "libnghttp2",
<EMAIL_ADDRESS>      "pcre",
      "libxml2",
      "zlib"
    ],
    "recommended_dependencies": [

    ],
    "optional_dependencies": [

    ],
    "uses_from_macos": [
      "libxml2",
      "zlib"
    ],
    "requirements": [

    ],
    "conflicts_with": [

    ],
    "caveats": "DocumentRoot is $(brew --prefix)/var/www.\n\nThe default ports have been set in $(brew --prefix)/etc/httpd/httpd.conf to 8080 and in\n$(brew --prefix)/etc/httpd/extra/httpd-ssl.conf to 8443 so that httpd can run without sudo.\n",
    "installed": [
      {
        "version": "2.4.52",
        "used_options": [

        ],
        "built_as_bottle": true,
        "poured_from_bottle": true,
        "runtime_dependencies": [
          {
            "full_name": "ncurses",
            "version": "6.3",
            "declared_directly": false
          },
          {
            "full_name": "readline",
            "version": "8.1.2",
            "declared_directly": false
          },
          {
            "full_name": "zlib",
            "version": "1.2.11",
            "declared_directly": true
          },
          {
            "full_name": "libxml2",
            "version": "2.9.12",
            "declared_directly": true
          },
          {
            "full_name": "gettext",
            "version": "0.21",
            "declared_directly": false
          },
          {
            "full_name": "util-linux",
            "version": "2.37.4",
            "declared_directly": false
          },
          {
            "full_name": "apr",
            "version": "1.7.0",
            "declared_directly": true
          },
          {
            "full_name": "ca-certificates",
            "version": "2022-02-01",
            "declared_directly": false
          },
          {
            "full_name"<EMAIL_ADDRESS>            "version": "1.1.1m",
            "declared_directly": true
          },
          {
            "full_name": "expat",
            "version": "2.4.5",
            "declared_directly": false
          },
          {
            "full_name": "sqlite",
            "version": "3.37.2",
            "declared_directly": false
          },
          {
            "full_name": "mawk",
            "version": "1.3.4-20200120",
            "declared_directly": false
          },
          {
            "full_name": "m4",
            "version": "1.4.19",
            "declared_directly": false
          },
          {
            "full_name": "libtool",
            "version": "2.4.6",
            "declared_directly": false
          },
          {
            "full_name": "unixodbc",
            "version": "2.3.9",
            "declared_directly": false
          },
          {
            "full_name": "apr-util",
            "version": "1.6.1",
            "declared_directly": true
          },
          {
            "full_name": "brotli",
            "version": "1.0.9",
            "declared_directly": true
          },
          {
            "full_name": "libnghttp2",
            "version": "1.46.0",
            "declared_directly": true
          },
          {
            "full_name": "bzip2",
            "version": "1.0.8",
            "declared_directly": false
          },
          {
            "full_name": "pcre",
            "version": "8.45",
            "declared_directly": true
          }
        ],
        "installed_as_dependency": false,
        "installed_on_request": true
      }
    ],
    "linked_keg": "2.4.52",
    "pinned": false,
    "outdated": false,
    "deprecated": false,
    "deprecation_date": null,
    "deprecation_reason": null,
    "disabled": false,
    "disable_date": null,
    "disable_reason": null
  }
]

Oops, I meant brew services info httpd --json. Sorry about that.

Hey @SMillerDev I just changed the environment to use dpkg and it is working fine right now, I will close this issue immediately


Router state like development example wanted :).

I would love to see a example of this in a project, to see some code how to use it in a project. right now I see a awesome idea in a repository but not really a clue on how to use it in a project.
My goal is to make the whole application in Redux style so at each given moment the state can be read , and with the current navigator its not possible, at least in version 0.23.0 (as far as I can see).
What I want to know is the following:

Can it preserve my state in the application like in Redux?
Is this both available for IOS as for Android?
Is there a working example? so I can see how to use it in a project.

Greetings,
Jasper.

Hi there!
Sorry for the late reply. We now have an example project at https://github.com/bringnow/react-native-autopilot-example.
Please check that out and tell me if it is missing something! Thanks :-)

And regarding your questions:

Yes, please take a look at the referenced example.
Yes. Android and iOS should both work with this (like with plain ExNavigator).
See above.


psql 8.3 and before doesn't accept -w

This makes check_pga currently not compatible with such versions of psql.

As discussed in private:

at least worth a doc patch, to tell the users to use another client
we cannot know if ''trust'' is used, or if the service file contains the password, so it is complicated to add the ''-w'' dynamically
this limit should not be a problem for many people nowadays
testing psql at each query is overkill
a ''--very_old_psql_client'' option to remove the ''-w'' shoud be enough + doc

Thanks for the patch

In fact, this bug has been introduced in de404d9ca13e282 after short discussion in #229.
I wonder if we should revert the patch for this release and postpone in a better shape for next release?

Oops.  I guess we could cache the psql version in the storable file, but I'm not sure of how we should clear that cache.
Is it that common to have that old psql clients?  I'm not opposed to revert the patch to avoid postponing the next release.

I would keep the patch. Some people may already use it. There is a workaround (a less prehistoric client). If somebody really complains, add a ''--psql-is-prehistoric'' option. Or drop 8.3 and sooner support.

I'm fine with an extra option too.  I'm assuming you meant 8.3 and older?  Note that it's only the client side, server side shouldn't be a problem.

Is it that common to have that old psql clients?

No, I don't think so. We have nothing that old on our side. But I have absolutely no clue outside there in the wild.
There might be another solution. Refactor the way we query the instance. This is a long overdue project in my opinion, to eg avoid one connection per query, detect psql version, parse correctly the return value (think #155), etc. Maybe next release might be a good time to fork a psql process and play with its stdin/stdout. We could then deal with psql version and interactive password for older ones to fail the connection quickly?

@rjuju : <8.3 , of course.
@ioguix : We want to release asap, so let's keep it this way now.  8.3 is too old to really support, we have a good work around, and a 2-characters emergency patch.  You can do whatever you want in 2.6.

You can do whatever you want in 2.6.

That's what I wrote.
The release process is on-going: #274


Versioned installs

Enable the possibility of doing versioned installs, where we can specify Helm versions for all the components of the network in the Nephos configuration YAML.
Also remove 2 code smells from SonarQube by refactoring the helm_install and help_upgrade commands, resulting in the new helper helm_extra_vars.
This has breaking changes compared to version 0.2.x, so is updated to 0.3.0, but functionality remains similar.

Builds correctly on my own Travis CI branch, but without SonarQube or CodeCov (but coverage can be seen on logs):
https://travis-ci.com/alexvicegrab/nephos/builds/104771125

Would still like to run Travis CI on the hyperledger-labs PR prior to merging if at all possible.


various big number fixes

New big number was developed in rush with many ideas that make it too complex, this PR aims to clean it a bit and also fix several issues.
It also solves this jira ticket as well.
The tooltip part for big number in this PR depends on this PR.

Are there any core changes we should be aware of?
Can you give some testing insctructions?

Are there any core changes we should be aware of? Can you give some testing instructions?

Are there any core changes we should be aware of? Can you give some testing instructions?

Hi @sareg0 the easiest way to test this is by switching to this branch and using this syntax:
<t-big-number :number-value="29" :number-previous="40" label="Big Num" />
This component can easily be used without any layer.
But if you want to use with a layer you can use this simple query for test.
SELECT 28 as value, 40 as previous

We need a linting tool for public repo,  the code is always badly linted after pushed.


SnipRun is not working on markdown .md files on MacOS

Describe the bug
SnipRun is not working on .md files on MacOS
To Reproduce

Create test.md
Populate with the following code

# Test Python
This is a code snippet

```python
abc = "abc"
print(abc)
```

Run :SnipRun
Output is Filetype not officially supported, nor configured for the Generic interpreter

Expected behavior
If i create the same snippet of code in a .py file it works fine.
I have tried with this in my set.lua:
interpreter_options = {
    GFM_original = {
        use_on_filetypes = {"markdown", "md", "markdown.pandoc", "rstudio" }
    }
}

as well as:
interpreter_options = {
    GFM_original = {  }
}

Screenshots

I also tried the healthcheck with no success.
SnipRun: health#SnipRun#check
========================================================================
  - ERROR: Failed to run healthcheck for "SnipRun" plugin. Exception:
    function health#check, line 20
    Vim(eval):E117: Unknown function: health#SnipRun#check

Environment:

Neovim version NVIM v0.8.2

Just upgraded to NVIM v0.9.4

M1 Mac, 13.5 (22G74)
Packer config:   use { 'michaelb/sniprun', run = 'sh ./install.sh'} and PackerSync successful

run = 'sh ./install.sh'

On macOS ???? (Not "sh ./install.sh 1" ??) I'm flabbergasted it even works
As for your actual issue, neovim usually associate a 'filetype' to files. filetype is not necessary taken from the file extension.
Can you run :set ft? to determine which is the filetype of your buffer ?
Alternatively, :set ft=markdown should make it one of the default filetype for the wanted sniprun interpreter.
It might be necessary to add the filetype (if it's a strange one and you don't want to change it) to the interpreter's options like you have already done (but is your 'set.lua' actually used ?)
If you're still lost, there should be a log file in. $XDG_CACHE_DIR ( ~/Library/Caches on macos?) /sniprun/sniprun.log

I'll be damned,filetype=vimwiki. Once I disabled the plugin (I was going to anyway), it worked just fine.
btw, my original post was incorrect, my config is sh ./install.sh 1 since it requires compiling. I hope you can un-flabber that gast. ;-)
Thank you so much. If someone else comes along and has this issue, here are the parts of the vimwiki config that were set. Perhaps if this is reproducible that vimiwiki format can be added. It is really odd that it tookover the filetype of markdown.

-- vim.g.vimwiki_list = {
--   {
--     path = '~/techdocs/',
--     syntax = 'markdown',
--     ext  = '.md',
--   }
-- }
-- vim.g.vimwiki_ext2syntax = {
--   ['.md'] = 'markdown',
--   ['.markdown'] = 'markdown',
--   ['.mdown'] = 'markdown',
-- }

-- use {
--     'vimwiki/vimwiki',
--     config = function()
--       -- vim.g.vimwiki_list = {
--       --   {
--       --     path = '~/techdocs/',
--       --     syntax = 'markdown',
--       --     ext  = '.md',
--       --   }
--       -- }
--       -- vim.g.vimwiki_ext2syntax = {
--       --   ['.md'] = 'markdown',
--       --   ['.markdown'] = 'markdown',
--       --   ['.mdown'] = 'markdown',
--       -- }
--     end
--   }


Internal consistency violation with added 'if' statement

here's a spec:
TokenGroupIfBug:
    type Float = Native "float"

    state scores : Set<(Int, Float)>
    assume unique [s.0 | s <- scores];

    op addTokenScore(score : Float)
        assume not ((len scores, score) in scores);
        assume not ((len scores) in [s.0 | s <- scores]);
        if (len scores) < 50:
            scores.add((len scores, score))

    query getScore(i : Int)
        assume i >= 0 and i < len scores;
        the [s.1 | s <- scores, s.0 == i]

and the output:
D-173-250-185-41:cozy dgrant$ cozy --simple  --java out.java specs/TokenGroupIfBug.ds
Checking assumptions...
Done!

_var150 : Bag<(Int, float)> = scores

TokenGroupIfBug:
  type Float = float
  state _var150 : Bag<(Int, float)>
  query getScore(i : Int):
    (the Map {(\s -> (s).1)} (Filter {(\s -> ((s).0 == i))} (_var150)))
  query _query151(score : float):
    ((((sum Map {(\_var14 -> 1)} (_var150)) < 50) ? (_var150 + [((sum Map {(\_var15 -> 1)} (_var150)), score)]) : _var150) - _var150)
  query _query152(score : float):
    (_var150 - (((sum Map {(\_var14 -> 1)} (_var150)) < 50) ? (_var150 + [((sum Map {(\_var15 -> 1)} (_var150)), score)]) : _var150))
  op addTokenScore(score : float):
    for _var153 in _query152(score):
      _var150.remove(_var153)
    for _var153 in _query151(score):
      _var150.add(_var153)

Generating final concrete implementation...
At _var150: expression has type NativeSet<(Int, float)> instead of Bag<(Int, float)>
At _var150: expression has type NativeSet<(Int, float)> instead of Bag<(Int, float)>
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.5/bin/cozy", line 11, in <module>
    load_entry_point('Cozy', 'console_scripts', 'cozy')()
  File "/Users/dgrant/Dev/cozy/cozy/cozy/main.py", line 124, in run
    impls = list(autotuning.enumerate_impls(code, state_map, lib, assumptions=ast.spec.assumptions))
  File "/Users/dgrant/Dev/cozy/cozy/cozy/autotuning.py", line 55, in enumerate_impls
    wq.append(apply_rewrite(statevar, new_type, ast))
  File "/Users/dgrant/Dev/cozy/cozy/cozy/autotuning.py", line 37, in apply_rewrite
    raise Exception("internal consistency violation: refined spec does not typecheck")
Exception: internal consistency violation: refined spec does not typecheck

(Commenting out the 'if' statement fixes it.)

There's been a longstanding problem where the ternary operator e ? x : y does not typecheck if the types of x and y are not exactly equal. The correct behavior is for the whole ternary expression to have the "least upper bound" of the two types. So for instance, if x is a bag and y is a set, then the whole thing should be a bag.
The commit I made fixes this exact case, but at some point we'll need to document Cozy's type hierarchy and fully implement the least-upper-bound function.


Product Categories

Hi, How do I get the product category for a product, I was looking for something like $product->getCategory() but haven't found a way to retrieve it.  I would like to use it in the view.php of the community product block.  thanks

You would do with with $locations = $product->getLocations();
$locations is then an ArrayCollection that you can loop through, with each item being a ProductLocation object, which you can call getCollectionID() on to get the id of the page (the 'category').

Thanks. that did the trick


Add badges for the listeners

Draft for now, I still want to add badges for the listeners, but this code was done very complicated  in the past.
Originally posted by @philipsens in https://github.com/ibissource/frank-flow/issues/652#issuecomment-1081676918
As mentioned, the code is a bit of a mess. I think it can be done easier if there is a generic badge attribute on a node.

8u

:tada: This issue has been resolved in version 2.23.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Avoid race conditions when creating cache directories

Thanks for this. Is it worth having this logic in a dedicated "ensureDir" function in lib/libvips.js that can be called where needed?

Coverage increased (+0.007%) to 98.776% when pulling 99f8845546f56eeca12d9e620a413e0422eb70d4 on ajhool:master into 5bed3a7d52434451316e9479c5b5e54fa66ffccb on lovell:master.

Looks like there are five mkdir calls throughout the whole project.
install/dll-copy.js (2)
lib/libvips.js (2)
install/libvips.js (1)
install/libvips.js currently depends on lib/libvips.js
Maybe one function in lib/libvip.js that is also used in install/libvips.js, and a duplicate function in install/dll-copy.js?


Kindly help to update the JavaScript code example

Kindly help to update the JavaScript code example;
var formatted_Card_Payload = {
        "type": "message",
        "attachments": [
            {
                "contentType": "application/vnd.microsoft.card.adaptive",
                "contentUrl": null,
                "content": {
                    "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
                    "type": "AdaptiveCard",
                    "version": "1.2",
                    "body": [
                        {
                            "type": "TextBlock",
                            "text": "Submitted response:"+ response
                        }
                    ]
                }
            }
        ]
    }

var webhookUrl = "https://xxxxx.webhook.office.com/xxxxxxxxx";

axios.post(webhookUrl , formatted_Card_Payload )
    .then(res => {
        console.log(`statusCode: ${res.status}`)
        console.log(res)
    })
    .catch(error => {
        console.error(error)
    })

Also, help to update the sample code reference like with: https://github.com/OfficeDev/Microsoft-Teams-Samples/blob/main/samples/incoming-webhook/nodejs/api/server/index.js#L28
Section to update;

Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.

ID: 90ff2a84-a8bc-9259-d37d-622b102df75b
Version Independent ID: e3b53e27-2946-189c-623b-9df704ea8f12
Content: Create an Incoming Webhook - Teams
Content Source: msteams-platform/webhooks-and-connectors/how-to/add-incoming-webhook.md
Service: msteams
GitHub Login: @surbhigupta
Microsoft Alias: surbhigupta

Hi @surbhigupta12 - Could you please help here to update the doc as suggested?


Question about PIXI v5 on Windows

I apologize if this was asked previously or if I missed something in the documentation. I just had a quick question. I noticed that when I visit the pixi.js examples page in Firefox or Edge using Windows 10, pixi will fallback to using the canvas renderer. However I know WebGL is supported because when I visit https://get.webgl.org/, it tells me WebGL is supported. If I visit the examples page in Chrome using Windows 10, it renders using WebGL.
If I try visiting the examples page in Firefox or Chrome using Mac, it will also render using WebGL.
I just wanted to confirm, is it a known issue that WebGL rendering in pixi will not work in Firefox or Edge using Windows 10? If so, is it because of a lack of stencil support? Am I just completely misunderstanding something? It may or may not also be important to mention that I'm doing this testing with BrowserStack.
Thanks!

Probably stencil. We'll make it optional like in pixijs v4 in next versions.

Here's the function that does the webgl detection (stencil required):
https://github.com/pixijs/pixi.js/blob/dev/packages/utils/src/browser/isWebGLSupported.js

Console shows WebGL for Firefox on Windows 10 for me:

@immanuelx2 Got it. Perhaps it has something to do with the fact that all of the testing I've done has been on VMs (BrowserStack browsers and my own locally installed VM). But even still, why would it work on Chrome but not on Firefox or Edge?

Browsers have their own blacklists for devices or driver versions; sometimes a complete blacklist, sometimes webgl features blacklisted.

Ah, that makes sense, that probably explains why I was running into those issues. I think my question is answered so I'm closing this, if I have any further questions I'll post a new issue. Thanks guys.


ox-ctrl-volt segmentation fault

When running ox-ctrl-volt with the binary I've compiled, segmentation fault occurs while performing memcpy in volt_nand_dma().
The below is the execution of ox-ctrl-volt.
root@ls2085aissd:/media# gdb ./ox-ctrl-volt
GNU gdb (GDB) 7.8.2
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "aarch64-fsl-linux".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./ox-ctrl-volt-LUN4...done.
(gdb) r start
Starting program: /media/ox-ctrl-volt-LUN4 start
warning: Could not load shared library symbols for linux-vdso.so.1.
Do you need "set solib-search-path" or "set sysroot"?
warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.
OX Controller 1.4.0 - The Lonely Dragon
 Starting...
 [volt: Volatile memory usage: 2063 Mb]
[New LWP 1854]

Program received signal SIGSEGV, Segmentation fault.
[Switching to LWP 1854]
0x0000ffffb7e726a8 in memcpy () from /lib/libc.so.6
(gdb) bt
#0  0x0000ffffb7e726a8 in memcpy () from /lib/libc.so.6
#1  0x00000000004124a8 in volt_nand_dma (paddr=0x411, buf=0x8104eff0,
    sz=16448, dir=1 '\001') at mmgr/volt/volt.c:389
#2  0x00000000004125b0 in volt_process_io (cmd=0x815b7690)
    at mmgr/volt/volt.c:414
#3  0x00000000004126a0 in volt_execute_io (req=0x815512c0)
    at mmgr/volt/volt.c:448
#4  0x0000000000406430 in ox_mq_sq_thread (arg=0x8154fff0) at ox-mq.c:327
#5  0x0000ffffb7f97e10 in ?? () from /lib/libpthread.so.0
#6  0x0000ffffb7fb7000 in ?? () from /lib/libpthread.so.0
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
(gdb)

I haven't changed any code, just compiled it myself.
The code I used is the OX Controller v.1.4.0 release.
I believe the segmentation fault occurred due to the paddr address.

Hi,
Before more debugging, please check your firmware version. In special:

This 1.4.0 release only supports the LS2085 board. For newer boards, there is a 2.0 version, but not open source yet.
The FPGA firmware should be version A3_03.01.00, provided by VVDN.
https://github.com/DFC-OpenSource/DFC-sdk/tree/LS2088_iSSD/images

If you have this firmware, the next step is looking at line volt.c:414.
You will find 'blk->pages[cmd->ppa.g.pg].data'.
We should check ppa.g.pg, as well the rest of the PPA address. Then, check the device boundaries in volc.c:760.
It looks like the page address is beyond the boundaries.
Ivan

I am currently working with an LS2085 board.
The problem turned out the be the discrepancy between the ppa bit configurations of ox-ctrl and ox-ctrl-volt in the Makefile.
# (1) Macro to tell OX core which MMGRs and FTLs are compiled
# (2) Macro to define global Open-Channel geometry (in bits)
# (3) Macro for versioning
# ox-ctrl and ox-ctrl-test
CONFIG_DFC  = -DCONFIG_MMGR_DFCNAND	    # (1)
CONFIG_DFC += $(CONFIG_FTL)		    # (1)
CONFIG_DFC += $(CONFIG_VER)		    # (3)
CONFIG_DFC += -DCONFIG_NVM_SECSZ=0x1000     # (2)
CONFIG_DFC += -DCONFIG_NVM_SEC_OOBSZ=0x10   # (2)
CONFIG_DFC += -DCONFIG_NVM_SEC_PG=2	    # (2)
CONFIG_DFC += -DCONFIG_NVM_PG_BLK=9	    # (2)
CONFIG_DFC += -DCONFIG_NVM_CH=3             # (2)
CONFIG_DFC += -DCONFIG_NVM_LUN_CH=2	    # (2)
CONFIG_DFC += -DCONFIG_NVM_BLK_LUN=10	    # (2)
CONFIG_DFC += -DCONFIG_NVM_PLANES=1	    # (2)
CONFIG_DFC += -DCONFIG_NVM_RESERVED=37	    # (2)
# ox-ctrl-volt
CONFIG_VOLT  = -DCONFIG_MMGR_VOLT		# (1)
CONFIG_VOLT += $(CONFIG_FTL)			# (1)
CONFIG_VOLT += $(CONFIG_VER)			# (3)
CONFIG_VOLT += -DCONFIG_NVM_SECSZ=0x1000	# (2)
CONFIG_VOLT += -DCONFIG_NVM_SEC_OOBSZ=0x10	# (2)
CONFIG_VOLT += -DCONFIG_NVM_SEC_PG=2		# (2)
CONFIG_VOLT += -DCONFIG_NVM_PG_BLK=6		# (2)
CONFIG_VOLT += -DCONFIG_NVM_CH=3		# (2)
CONFIG_VOLT += -DCONFIG_NVM_LUN_CH=2		# (2)
CONFIG_VOLT += -DCONFIG_NVM_BLK_LUN=5		# (2)
CONFIG_VOLT += -DCONFIG_NVM_PLANES=1		# (2)
CONFIG_VOLT += -DCONFIG_NVM_RESERVED=45         # (2)

When I changed the ox-ctrl-volt configurations to follow the ox-ctrl configurations, segmentation fault no longer occurs. However, when I try to create a pblk target in the host, it fails to do so because it couldn't get the bad block table from the device.
Are there any more configurations that I should change to get the ox-ctrl-volt working?
Also, was I right to change the ox-ctrl-volt configurations to follow the ox-ctrl ones, or is it the other way around?

Hi,
Be aware that ox-ctrl v1.4 supports open-channel SSD specification v1.2. The newest kernel have migrated to v2.0 of the spec. I am not sure until when they will support v1.2.

The bits you changed define the geometry boundaries in a 64-bit address:
include/ssd.h:99-114
In older versions of lightnvm, the bits exposed to the host (lighnvm.c:452-464) should match exactly the device geometry (lightnvm.c:88-88). All these values are exposed via Identify (0xE2) command in the Open-channel SSD specification v1.2
In newer kernels, lightnvm no longer requires this match. So, exposing a generic bit set will work fine. The issue is that ox-ctrl v1.4 exposes to the host a geometry based on those bits. Your 'way around' won't break anything, as soon as (1) you use let's say kernel v4.15 or higher and (2) the bits match 'volt' geometry (mmgr/volt/volt.h:12-17).
Remember that using ox-ctrl bits will require a 512GB device, which is not viable for an in-memory implementation such as 'volt.c' in ox-ctrl-volt.

If you were able to identify the open-channel SSD in the host side, it is great!
Can you see the device with 'sudo nvme list' and 'sudo nvme lnvm list' ?
Can you see the kernel log identification? Something like this:
[   55.455872] nvm: registered nvme1n1 [4/2/512/1020/128/16]
For the bad block table, you may use debug. Type in the OX command line:
debug on
Then, try to create a pblk target and see the output in OX. Another source for debugging is  looking at /var/log/nvme.log or /var/log/syslog. OX writes there important runtime logs.
Best,
Ivan

Hi, did you solve your issue?
If yes, I will close this issue in a few days.

May I ask on which project you are working on? How are you using DFC card ?
I would appreciate if you could describe your project?
Thanks,
Dragan
On Mon, Dec 3, 2018 at 8:53 AM sooyun802<EMAIL_ADDRESS>wrote:

Closed #15 https://github.com/DFC-OpenSource/ox-ctrl/issues/15.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/DFC-OpenSource/ox-ctrl/issues/15#event-2001462875,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AWj9dEvpN9rvfG4V0uKjD0D5vU-j4mAvks5u1SzmgaJpZM4YsYHV
.


Added missing include and link dir to make CI green again

This PR adds missing:

#include statement
link library dir for python 3.10

to make CI green again.

@hendrikmuhs I'll just go ahead and merge this, to unblock #251, but let me know if you have some comments ... and I'll create a follow-up PR.

Thanks @narekgharibyan!
I don't have a better idea at the moment. Do we need this directory for python or for the other libs?

Do we need this directory for python or for the other libs?

For boost, apparently on python 3.10 it wasn't part of LD_LIBRARY_PATH


Update Contribution Guide -add chapter about release process

For preparation to do more and more specification in github itself (up to now published pdf of the specification was the master) we need to have a clearly defined release process including versioning schema. This issue is strongly related to the approval process of issue #9
Proposal similar to (In this case the working group is the joint working group "Asset Administration Shell" of IDTA and Plattform Industrie 4.0):
https://github.com/OpenManufacturingPlatform/sds-bamm-aspect-meta-model/blob/main/CONTRIBUTING.md#release-process

The process is well-defined in section https://github.com/admin-shell-io/aas-specs/blob/master/CONTRIBUTING.md#before-the-pull-requests . We use feature branches.

This is about releases and not about branch strategy but of course they are related. This is not yet well-defined.


Add book/frontmatter templates to plugin config

Is your feature request related to a problem? Please describe.
I like to be able to edit the metadata of the book in the plugin settings.
Describe the solution you'd like
Add another input for the meta data templates.
Additional context
Maybe the frontmatter part of the book could also be made as a template.

I've implemented your request in version 1.6.0. When you go to the plugin settings, you will be able to customise the default template used for note highlights. You should be able to add a YAML front matter section, or add double colons as you wanted to play well with Dataview.
If you can confirm this release works well for you that would be great.

this works perfect! thanks!

Trying this out now -- I can add/customize the template in the settings

But I can't seem to edit/change the actual front matter itself.

Hi. I am interested to change the frontmatter, will be very usefull.


Whole pop-os freezes while using glfwSetWindowTitle

I created an fps counter where I used glfwSetWindowTitle(window, "test" );
Expectation:
The window should update it's title bar with the string "test".
What actually happened:
The whole system freezes and I can't do anything except forcing the computer to reboot physically through the button on my chassi.
Background:
I use a clean installation of PopOs where I installed glfw with this command:
sudo apt install libglfw3-dev
provided from https://vulkan-tutorial.com/Development_environment which is the tutorial I read.
The application is super simple, I just draw a basic window with nothing else from glfw examples. except that I call  glfwSetWindowTitle(window, "test" ); before glfwPollEvents()
Update:
I called it every frame with an fps on 1156k. Which is probably not suitable for the window manager. Going to test it each second instead

the problem was in the window manager, when to many calls are sent by glfw the os crashes. A time check is in order before doing that


v1.10: Update Go to 1.16.12

/test-backport-1.10

/test-1.19-5.4

ci-aks-1.10

ci-aks-1.10 (wasn't triggered by #18228 (comment) thinking)

This workflow is currently disabled on v1.10 due to https://github.com/cilium/cilium/issues/18107 as confirmed out of band by @nbusseneau. Marking as ready to merge.


Split Guardian & Emergency Contact name fields on Student

Summary
Currently there is a guardian_name and emergency_contact_name field on the student Model/table. These need to be split into guardian_first_name, guardian_last_name, emergency_contact_first_name, & emergency_contact_last_name`.
 So don't worry about backwards compatibility data. There is no prod db yet.
Criteria for Completion

[ ] Specified name fields are removed and replaced with first/last name fields
[ ] Update the seed files to still create valid students
[ ] Update the Students index so it doesn't break. Guardian last name is fine, feel free to add both.
[ ] Update the Student form to accept inputs for these fields as shown in mock below.

HOW IT LOOKS NOW:

How it should generally look after this change:

I'll work on this issue.