Set/Get primitives = Shared properties + reduced verbosity

The Problems
In https://github.com/facebook/lexical/issues/1262#issuecomment-1186170960 I explained a series of problems when it comes to extending nodes.
At that time I thought that the best way to solve it was to group different nodes in the same class (as is done now with the different levels of Heading). In fact later in the same thread, I offered a proof of concept. I still think this could potentially reduce code repetition in very similar nodes like headings and paragraphs, but after thinking about it a lot I came to the conclusion that it is not a viable solution, at least for all the problems that I described.
After that the node replacement API came out. Although it solves some problems, I think the first 3 items of my initial post are still valid:

When converting one elementNode to another, the shared properties are lost (for example, convert an indented paragraph to a heading and the indentation will be lost). The reason for this is that since they are different classes, a new instance is required. Of course, by changing the type of a node one could also copy the desired properties to the new node. EDIT: It seems this has been fixed only for the indent case, and not for arbitrary user-defined properties.
Even if some properties are used only by some nodes, it would be ideal if the other nodes keep that information. The reason for this is that users often undo operations using the reverse operation instead of ctrl + z. For example, ListItem currently ignores the __indent property because it handles it with nesting. But if I have indented paragraphs, I would like the indents to be preserved when I convert them to a list and return them to paragraphs. Or if I have a checklist checked, convert it to something else, and return to the checklist, the "completed" property should be preserved. I recommend seeing this notion blog article where they talk about this.
If the different types of elementNodes are subclassed and we have a shared property, then the same display logic must be defined in the updateDOM and createDOM of each node, which makes it very difficult to maintain the code. In Lexical right now there is a workaround with the __indent case that is handled in Reconcilier.ts. Besides being a bit confusing, the rest of us can't do the same for other shared properties we might want to add.

Things I've Tried
So once I had the node replacements API available, I decided to ignore issues 1 and 2 for the moment and focus on issue 3. That is, I tried to reduce the excessive code repetition required to add a shared property to multiple nodes at once; and I did it using a combination of the node replacement API and the mixin pattern.
In the process I ran into many difficulties, but I came up with an idea that I think would solve all 3 problems at once.
New idea: how I think extending a node should look like.
As I mentioned in the other thread, note for example how applications like Notion, Dynalist, Remnote, Roam Research and Workflowy have properties such as color shared by what in Lexical we would call nodes of type element.
If a user wanted to do something like this with Lexical, for each of the nodes they would do something like this:
export type SerializedColoredTextNode = Spread<
{
  color: string;
  type: 'heading';
  version: 1;
},
SerializedTextNode
>;

export class ColoredNode extends TextNode {
__color: string;

constructor(text: string, color?: string, key?: NodeKey): void {
  super(text, key);
  this.__color = color || "defaultColor";
}

static getType(): string {
  return 'colored';
}

setColor(color: string) {
  const self = this.getWritable();
  self.__color = color;
}

getColor(): string {
  const self = this.getLatest();
  return self.__color;
}

static clone(node: ColoredNode): ColoredNode {
  return new ColoredNode(node.__text, node.__color, node.__key);
}

createDOM(config: EditorConfig): HTMLElement {
  const element = super.createDOM(config);
  element.style.color = this.__color || "defaultColor";
  return element;
}

updateDOM(prevNode: ColoredNode, dom: HTMLElement, config: EditorConfig): boolean {
  const isUpdated = super.updateDOM(prevNode, dom, config);
  if (prevNode.__color !== this.__color) {
    dom.style.color = this.__color;
  }
  return isUpdated;
}

static importJSON(serializedNode: SerializedMentionNode): MentionNode {
  const node = new ColoredNode(serializedNode.text, node.serializedNode.color);
  node.setFormat(serializedNode.format);
  node.setDetail(serializedNode.detail);
  node.setMode(serializedNode.mode);
  node.setStyle(serializedNode.style);
  return node;
}

exportJSON(): SerializedHeadingNode {
  return {
    ...super.exportJSON(),
    color: this.getColor()
    tag: this.getTag(),
    type: 'colored',
    version: 1,
  };
}
}

Instead, the solution I have in mind would reduce it to just this:
export class ColoredNode extends TextNode {
  static getType(): string {
  return 'colored';
}

createDOM(config: EditorConfig): HTMLElement {
  const element = super.createDOM(config);
  element.style.color = this.getProperty(color) || 'defaultColor';
  return element;
}

updateDOM(prevNode: ColoredNode, dom: HTMLElement, config: EditorConfig): boolean {
  const isUpdated = super.updateDOM(prevNode, dom, config);
  if (prevNode.getProperty(color) !== this.getProperty(color) {
    dom.style.color = this.getProperty(color);
  }
  return isUpdated;
}
}

Note: I think there are ways to simplify this even further, but I'll leave it as a starting point for now.
Implementation
The way to avoid defining properties, getters and setters in each class would be with the following primitives:
class LexicalNode {
  //...
  __properties: object;

  getProperties(): object {
    const self = this.getLatest();
    return self.__properties;
  }

  setProperties(properties: object): object {
    const self = this.getWritable();
    self.__properties = properties;
  }

  getProperty(key: string): any {
    const self = this.getLatest();
    return self.__properties[key];
  }

  setProperty(key: string, value: any): void {
    const self = this.getWritable();
    self.__properties[key] = value;
  }
}

Cloning or serializing a class instance is tricky. But by making the properties a simple object we could do without explicitly defining the clone(), importJSON or exportJSON() methods for every subclass.
Each class would inherit those methods something like:
exportJSON() {
   return {
     //...
     properties: this.getProperties(),
     type: getType(),
   };
}

importJSON(serializedNode) {
   const node = $createXnode();
   //...
   node.setProperties(serializedNode.properties);
   return node;
}

clone(node: XNode): XNode {
   return new XNode(node.__properties, node.__key);
}

Of course, an interface could be defined to the __properties object, to get the typesafety.
The point is that the properties would be decoupled from the nodes. In other words: although li, or paragraph are not going to use the "checked" property, it would still be nice if they did, which is what I explained in points 1 and 2 at the beginning of the post.
Then, keeping any arbitrary properties when converting one node to another would be trivial. You would only have to clone the properties in the $setBlocksType function
This could fix:

https://github.com/facebook/lexical/issues/1262
https://github.com/facebook/lexical/issues/2557
https://github.com/facebook/lexical/discussions/3353

Thx for starting this discussion @EgonBolton. I am supportive for the 2 first goal (and probably also the 3rd one which I understand less).
Quick questions:

How related is this proposal to the node replacement system https://github.com/facebook/lexical/pull/3367?
If you have a POC at hand, a sandbox that demonstrates how you can convert a indented paragraph to heading (and back) while keeping the indent would be help demonstrate the value of this proposal.

Thanks @Echarles.
Point 3 is basically about verbosity and repetition. I mean that extending a node for something as simple as adding a property requires a lot of boilerplate, unnecessary in my opinion (example above).
If you also want to add that same property to different nodes, you must repeat that code, making it difficult to maintain.

How related is this proposal to the node replacement system #3367?

Both are intended to simplify the way nodes are extended. Before that solution, extending nodes was even more complicated. You would have to overwrite all the commands, plugins, or functions that created the node you wanted to replace.

If you have a POC at hand, a sandbox that demonstrates how you can convert an indented paragraph to heading (and back) while keeping the indent would be help demonstrate the value of this proposal.

In fact, it seems that they have solved just the use case of indents (I put it in the edit of problem 1). You can try it in the playground. However, this cannot be done by us with custom properties of our nodes (as requested by @aquarius-wing at https://github.com/facebook/lexical/issues/2557).

I think this would be a very large change to the current architecture. Not saying it's a bad thing, but introducing such changes now would be very churning on the existing set of nodes and plugins.

Update: This proposal can be divided into parts. The first PR that is to eliminate the Clone method is already pending review:

[ ] Clone: https://github.com/facebook/lexical/pull/3920
[ ] ExportJSON / ImportJSON
[ ] Setters / Getters

The reason I started with Clone() is because I found a way to generalize it without even requiring _properties as I proposed above.

I have this basic custom node implementation but I am getting an error after the node transformation saying:
Node Incorrect Node does not match the serialized type. Check if .exportJSON() is implemented and it is returning the correct type
import { EditorConfig, LexicalNode, NodeKey, TextNode } from "lexical";

export class IncorrectNode extends TextNode {
    constructor(text: string, key?: NodeKey) {
        super(text, key)
    }

    static getType(): string {
        return 'incorrect'
    }

    static clone(node: TextNode): IncorrectNode {
        return new IncorrectNode(node.__text, node.__key)
    }

    createDOM(config: EditorConfig): HTMLElement {
        const element = super.createDOM(config);
        element.className = config.theme.incorrect;
        return element;
    }
}

export function $isIncorrectNode(node: LexicalNode): node is IncorrectNode {
    return node instanceof IncorrectNode;
}

export function $createIncorrectNode(incorrectText: string) {
    return new IncorrectNode(incorrectText).setMode('normal')
}

is it something related to the current discussion or is there something specific I am not implementing in my code?


[Feature] Call-to-vote for ARNEIS

Extends https://github.com/B-AROL-O/ARNEIS/pull/315
📑 Description

✅ Checks

[x] My pull request adheres to the code style of this project
[ ] My code requires changes to the documentation
[x] I have updated the documentation as required
[ ] All the tests have passed

ℹ Additional Information

@alv67 I need your help to figure out why the image does not show up!

Please Merge if you like


Support Simple protocol plans using scratch buffer

Separate the options whether to use packet and whether to use double buffer.
Reduce primitive implementation fixes in executor.
Add validation for number of operations, channels and channels per operation.

@Binyang2014 Any updates in this PR?

@Binyang2014 Any updates in this PR?

I think there not blocker for this PR. Just need to resolve the conflict. Let me check with Ziyue


[Addition]: Suspicous gamer

Hotspot b58 Addresses
112WjQnbwn1Pk43hEYGXKaenjsXR65drsXSWJy19rwxXfFYpwJNZ
Discord Handle
No response
Reason(s)
According to the coordinate, the hotspot is located in a center of a natural park, there is completely no infrastructure in that park, besides, there is also no tall building nearby. It is not possible to put antenna in 27 meters high inside the park.
Also the hotspot is relayed with so high earning compared to all the hotspots nearby, the number of witnessed is bizarre. Moreover, a 2.9 dBi antenna reaches 150 kilometers away!
This COTX hotspot also looks very similar and same pattern as several hotspots which have been already on the denylist in the area, as an example: https://explorer.helium.com/hotspots/11qxA35LEyibTA16szsvhoft4oJF2Hug7pwrrakp1QafjgX7dDs

Just an fyi...people are making off-grid solar powered units with cellular connections that can be in rote locations. Can you prove it's not?

I am not the only one who reported this hotspot, it is also on the list of this issue: https://github.com/helium/denylist/issues/502


Update path.Path

According to the history: http://pythonhosted.org/path.py/history.html

We need to update the usage in addition to the import. :wink:

Already done: https://github.com/Flexget/Flexget/pull/576


Add support for looking up a previous stable version's tag

Hi @MaxwellBo! Could you explain what the motivation for this feature is?

Hi @dwijnand - sincerest apologies for the delay! We're currently using previousStableVersion with mimaReportBinaryIssues, so that any every version is compatibility checked against the previous (assumed) release. We guessed that this might be a common use-case for sbt-dynver.

I'm working one this with Max. There are some more improvements we want to make. Will update the PR (or raise another) when we're done

Superseded by #50


Fix Binder links

Addresses https://github.com/ProjectPythiaCookbooks/projectpythiacookbooks.github.io/issues/85 for this repo.

Thanks!


(WIP) add scopes

Still work in progress, but this is adding import maps scopes of #38  to the repo. It's not finished yet, though big part is here. Theres some refinement needed in the web-server. Additionally i think its wise to create some tests around this to expect the same behaviour

What still is left out is the scoping URL validation, which I think requires some setup of jest testing to cover all situations. Any objections to set that up in this pr @joeldenning?

Updated the pr with more separation of the services and scopes. I'll continue to work on the validation.

@joeldenning i see travis is doing some eslint stuff over here, can i extend the eslint in this project to also check in the precommit hook?


How to ctrl+right arrow and/or ctrl+left arrow, jump words in Visual Studio Code's Terminal

Issue Type: Feature Request
My fingers are years-programmed to use ctrl+right arrow to jump a word forward, ctrl+left arrow to jump a word back, in Terminal/iTerm.
I can not figure out how to get this functionality in Visual Studio Code's Integrated Terminal (macOS obviously). vscode/Code Version 1.30
I have disabled Mission Control, https://apple.stackexchange.com/questions/18043/how-can-i-make-ctrlright-left-arrow-stop-changing-desktops-in-lion
How do I accomplish this?
VS Code version: Code 1.30.0 (c6e592b2b5770e40a98cb9c2715a8ef89aec3d74, 2018-12-11T22:22:15.793Z)
OS version: Darwin x64 18.2.0

This is the behavior out of the box for bash. If you are using zsh option+left/right will jump words and you can configure the terminal to use ctrl with these keybindings:
    {
        "key": "ctrl+left",
        "command": "workbench.action.terminal.sendSequence",
        "args": { "text": "\u001bb" }
    },
    {
        "key": "ctrl+right",
        "command": "workbench.action.terminal.sendSequence",
        "args": { "text": "\u001bf" }
    }

Added to the FAQ on the website https://github.com/Microsoft/vscode-docs/commit/4ae3b801c291365a44b7ce2d07123be941ac321c

Awesome!!!!!!!
I'm actually using GNU bash, version 4.4.23 (via homebrew: brew install bash) and those keybindings work!
Thank you, thank you, thank you

Good to hear 😃


removing react-scripts library

Fixes #176

@DhananjayThomble, please check the PR and provide feedback on it.


Fixed incorrect APIVersion in APIResourceList

What this PR does / why we need it:
Currently the APIResourceList reports an invalid v1alpha3 apiVersion. This is not standard compliant and causes issues with kube-rs operators.
Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged): fixes #10899
Fixes #
Special notes for your reviewer:
Checklist
This checklist is not enforcing, but it's a reminder of items that could be relevant to every PR.
Approvers are expected to review this list.

[ ] Design: A design document was considered and is present (link) or not required
[ ] PR: The PR description is expressive enough and will help future contributors
[ ] Code: Write code that humans can understand and Keep it simple
[ ] Refactor: You have left the code cleaner than you found it (Boy Scout Rule)
[ ] Upgrade: Impact of this change on upgrade flows was considered and addressed if required
[ ] Testing: New code requires new unit tests. New features and bug fixes require at least on e2e test
[ ] Documentation: A user-guide update was considered and is present (link) or not required. You want a user-guide update if it's a user facing feature / API change.
[ ] Community: Announcement to kubevirt-dev was considered

Release note:

No, I think that is already done correct. When I look at:
❯ kubectl get --raw /apis/subresources.kubevirt.io | yq -P
kind: APIGroup
apiVersion: v1
name: subresources.kubevirt.io
versions:
  - groupVersion: subresources.kubevirt.io/v1
    version: v1
  - groupVersion: subresources.kubevirt.io/v1alpha3
    version: v1alpha3
preferredVersion:
  groupVersion: subresources.kubevirt.io/v1
  version: v1

The v1 is already the correct one. The ordering is AFAIK unrelated to the line you mentioned.

Any Chance to get this in? I would really love to go back to using the official images instead of my own.

Any Chance to get this in? I would really love to go back to using the official images instead of my own.

I'll have a look tomorrow. In the meantime, do you have any link to the doc or code to where this is consumed?

This example here should be sufficient to trigger it: https://github.com/kube-rs/kube/blob/main/examples/dynamic_api.rs
But I will double check tomorrow. Thanks for taking a look.

Can we please go ahead with this PR? It would make my life so much easier now. Thanks.

Can we please go ahead with this PR? It would make my life so much easier now. Thanks.

Yeah, apologies, this makes total sense.
/lgtm

/release-note Fixed incorrect APIVersion in APIResourceList

/release-note-edit release-note  BugFix: Fixed incorrect APIVersion of APIResourceList

/release-note-edit BugFix: Fixed incorrect APIVersion of APIResourceList

@KarstenB Could you please edit the description with this release note? bot seems to be broken
BugFix: Fixed incorrect APIVersion of APIResourceList

/test pull-kubevirt-unit-test

/test pull-kubevirt-e2e-k8s-1.28-sig-compute

/uncc


[question] How does one use rrrr

How does one query rrrr? I have it running with some GTFS data, but can't seem to figure out how to query it (sorry!)
Is it possible to query it via HTTP / does it need a webserver in front of it...?
Is there a doc for the API?
Thank you.

I solved json.c issue by changing line 104
if (remaining(21)) b += sprintf(b, "%" PRId64 , value);

to
if (remaining(21)) b += sprintf(b, "%jd" , value);


Use haskell.nix to build

Additionally, the project should be usable with at least GHC 8.10.

Done with #2


remove running single function argument

resolve #95
Remove running single function argument since function-cli no longer support start a single function.

Codecov Report

Merging #120 into master will decrease coverage by 0.26%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master     #120      +/-   ##
==========================================
- Coverage   63.92%   63.66%   -0.27%
==========================================
  Files          45       45
  Lines        1422     1409      -13
  Branches      158      154       -4
==========================================
- Hits          909      897      -12
  Misses        457      457
+ Partials       56       55       -1

Impacted Files
Coverage Δ

...va/com/microsoft/azure/maven/function/RunMojo.java
95.65% <100%> (+0.73%)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3b4dc15...d4ac08a. Read the comment docs.


Update node-build Dockerfile node version to 10-alpine

Moving from node:8-alpine to node:10-alpine

Hi, and thanks for contributing!
Note: If you are part of Qlik R&D, you can ignore this process (but let us know in a comment below!)
Before we can handle your pull request we need you to sign our contributor license agreement.
This is a one-time thing and enables you to contribute without hassle to any of the qlik-oss repositories in the future.
And it only takes a few minutes! Here are some useful links to get you started:

Sign the CLA
Rationale behind the CLA
Qlik R&D Open Source repository
Official Slack team

Having troubles? Feel free to reach out to us either here or on Slack!

I am part of Qlik R&D

Thanks @mustafanawabi!


[2.13.0] Script not called when refresh or page from direct link

Version
v2.12.2
Reproduction link
https://github.com/mathieunicolas/site-perso/blob/master/components/mastotest.vue
Steps to reproduce
I use nuxt-edge, with target: static. This bug appears mostly when dist directory is uploaded into netlify. There's no problem when I use npm run serve after npm run generate (which is build && generate).
When you go to https://musing-ardinghelli-337c44.netlify.app/ then click on "Mastodon c'est cool", the comments appear. If you reload, they don't.
When you go to https://musing-ardinghelli-337c44.netlify.app/foss/mastodon, the comments don't appear. The mount script is not called.
I spend HOURS on this problem, I don't know why this behaviour.
I've tried so many things... Fetching from a page component, using middlewares, methods, inline calls, mounted, created, method called from the page...
The code of the component :
<template>

Commentaires à cet article :

      <a :href="`https://diaspodon.fr/web/statuses/${statid}`"
          >(Commenter sur mastodon)

    <mastocom
      v-for="com in data.descendants"
      :com="com"
      :key="com.id.toString()"
      class="comms"
    ></mastocom>

</template>

It's in the mastotest component, called in /pages/_dir/_slug.vue
Do you why ? And how I can fetch mastodon comments each time the page is reloaded/called/displayed from direct link, no matter from where it's called ?
Thanks !
What is expected ?
Comments in pages reloaded each time the page is displayed/reloaded/accessed from direct link
What is actually happening?
Comments don't appear when reloading the page, accessing it from a direct link.
Additional comments?
Please help meeeee I'm clueless and I think I've tried everything !
Thanks !

This bug report is available on Nuxt community (#c10769)

Small and shy up, because I definitely don't understand what's going on with this one and I don't know where to look...
thanks guys !

The console says DOMException: Node.appendChild: Cannot add children to a Text. Might be an issue related to hydration, e.g. to https://github.com/nuxt/nuxt.js/issues/1552

The console says DOMException: Node.appendChild: Cannot add children to a Text. Might be a userland issue related to hydration, e.g. to #1552

damn your reply rang a bell. This error comes from netlify forms, and I noticed the form still works so I didn't pay attention to it anymore.
But the fact is, this error was apparently linked to my issue : I deleted the netlify form, and it worked like a charm.
Thanks for you intervention, I feel perfectly good now !

Nuxt generated some js files named starting with .(dot), but the browser request will be 404


Extract reporters as separate artifacts

@tarlog Thanks for the help! If you can go over the final result It would be great


Inline Keyboard for Telegram Alert

⚠⚠⚠ Since we do not accept all types of pull requests and do not want to waste your time. Please be sure that you have read pull request rules:
https://github.com/louislam/uptime-kuma/blob/master/CONTRIBUTING.md#can-i-create-a-pull-request-for-uptime-kuma
Tick the checkbox if you understand [x]:

[x] I have read and understand the pull request rules.

Description
Hi there.
I add inline keyboard use (like in discord webhooks, check screenshots)
Hope this improves view of telegram alert messages.
Type of change

Other
Alert changes

Checklist

[ ] My code follows the style guidelines of this project
[x] I ran ESLint and other linters for modified files
[x] I have performed a self-review of my own code and tested it
[x] I have commented my code, particularly in hard-to-understand areas
(including JSDoc for methods) (I try to do this)
[x] My changes generate no new warnings
[ ] My code needed automated testing. I have added them (this is optional task)

My Own Checklist

[x] Test telegram alert (when service UP or DOWN)
[x] Test telegram alert (when test alert)

Screenshots

I try get the same result as in discord webhooks

But, I found a bug (? probably) so maybe I should also duplicate title (name and status) to the body of telegram message? 🤔
Empty message, so you can't see about what service you get alert:

But, that could be fixed by a few methods.

I checked the inline keywords is likely used for multiple choices or buttons. I feel that the info/message displaying on buttons is a bit strange to me.
https://core.telegram.org/bots/2-0-intro#new-inline-keyboards


HomePage of Website is not responsive

Images of testimonials are overlapping each other and also no space from the ends in the smaller screens

Thanks for reporting this!

@abi I am doing this, i will release PR soon for this issue as it is very important

@abi i know it's odd but i am not able to find the file of homepage, can you please help me to locate it

@Aman-Manwani it's in the hosted branch

@abi can you review above PR and suggest changes


using @RefreshScope on grails application

I'm developing an application using Grails 3.0.9 with spring-cloud-config well configured, nevertheless I can't successfully get the config changes after a refresh
curl -X POST "http://localhost:8080/refresh"
["assets","assets.baseUrl"]

I tried using the @RefreshScope on lot of ways and can't find why my configs aren't refreshed.
package configurable

import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.beans.factory.annotation.Value;

@RefreshScope
class TestInterceptor {

    @Value('${assets.baseUrl}')
    assetsUrl

    boolean before() { true }

    boolean after() { true }

    void afterView() {
        println "this is the interceptor"
        println assetsUrl
    }
}

package configurable

import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.beans.factory.annotation.Value;

@RefreshScope
class TestController {

    @Value('${assets.baseUrl}')
    assetsUrl

    def index() {
        assetsUrl
    }
}

I seen lots of examples using @RefreshScope on the Application class, this of course won't work on grails.
package configurable

import grails.boot.GrailsApp
import grails.boot.config.GrailsAutoConfiguration
import org.springframework.cloud.context.config.annotation.RefreshScope;

@RefreshScope
class Application extends GrailsAutoConfiguration {
    static void main(String[] args) {
        GrailsApp.run(Application, args)
    }
}

2016-07-27 07:52:12 [main] ERROR grails.boot.GrailsApp - Application startup failed
java.lang.IllegalStateException: No Scope registered for scope name 'refresh'

Based on this response I tried to create a new bean
package configurable

import org.springframework.boot.context.properties.ConfigurationProperties
import org.springframework.stereotype.Component

@Component
@ConfigurationProperties(prefix="assets")
class Assets {
    String baseUrl
}

and it works, and don't even need to add the @RefreshScope annotation to the Bean


[FEATURE] CIDR management capabilities, enabling at-scale spoke VPCs w/central routing

Today ASEA supports:

deploying VPC's either: a) centrally in a shared account or accounts, or b) locally in each spoke account
these VPC's CAN be attached to a central TGW enabling central routing, if individually defined on a per account basis
if defined per ou, they cannot be TGW attached, as IP's would be identical per spoke account, preventing routing

Add the capability to:

define VPC's per ou, deployed locally in each spoke account AND attached to the TGW
this requires the addition of a CIDR management component
vpc and subnet definition should continue to have existing flexibility/definition in the config file
allow replacing VPC and subnet CIDRs in existing config file with dynamic environment variables (i.e. %block1_24%. %block2_16%)
customer stores a large IP CIDR block or blocks in a DDB table, marked available
on vpc provisioning:

break the specified block size out of the defined range, update available and assigned CIDRs back into DDB table (recording account/vpc assignment)
on vpc provisioning, replace environment variable with assigned range for the vpc/subnets

IMPROVE VPC DEPLOYMENT FUNCTIONALITY
Enable inter-connected spoke VPCs, VPC templates, and user selectable VPCs

Add new internal search/replace variables called ${VPC_NAME}, ${OU_NAME} for config.json

Only valid in vpc json object and resolves to vpc\name=value i.e. Dev
Only valid in ou json object and resolves to organizational-units\value i.e. Dev

Create 3 new DDB tables: (bold fields are mandatory, blue required for lookup)

table name: AccelPrefix-cidr-pools

fields: cidr, region, pool
cidr in format: <IP_ADDRESS>/8
region in format: ca-cenral-1
pool: any string

table name: AccelPrefix-cidr-vpc-assign

fields: status, region, cidr, pool, index, account-ou-key, vpc-name, account-id, vpc-id, date, requester
status: available || assigned || blocked
index: unique row identifier
date: date record last programmatically updated
account-ou-key: organizational-unit\value, workload-account-configs\value, mandatory-account-configs\value i.e. organizational-unit\Dev
account-ou-key and vpc-name are used for assignment and lookup
account-id and vpc-id are programmatically populated during vpc creation

reference only-not used for lookup

requester: “AcceleratorPrefix” || Manual || {userid}

table name: AccelPrefix-cidr-subnet-assign

fields: status, region, cidr, vpc-index, account-ou-key, vpc-name, subnet-name, az, subnet-id, date, requester, sub-pool
sub-pool: any string
az: a single letter i.e. a, b, c

NOTE: Ensure all codified updates to these tables prevent concurrent updates to the same record

Add new config file variables inside all vpc objects (vpc\cidr-src  and vpc\opt-in)

opt-in: true || false, default value is “false” (current behaviour)

if opt-in is true, ignore current vpc creation steps
only valid in OU’s section of config file
will be used as part of part 6)

cidr-src: “provided” || “lookup” || “dynamic”, default value is “provided”

valid in OU, mandatory and workload account sections of config file
both cidr and cidr2 must use the same src type
*“provided” - *config file as-is today
“lookup” – see 4) below
“dynamic” – see 5) below

cidr-src: “lookup”

gets vpc\cidr from cidr-vpc-assign DDB table

using status=assigned, region, account-ou-key, vpc-name

gets vpc\subnets\definitions\cidr from cidr-subnet-assign DDB table

using status=assigned, region, account-ou-key, vpc-name, subnet-name, az

the cidr values in the config file become optional (no longer used)
DDB tables are pre-populated manually by customer with values
SM validates all values exist in DDB table at early stage in SM, fails if error
when vpc created, vpc-id and subnet-id will be appended by Accelerator

account-id and vpc-id can be multi-value items (i.e. sandbox OU)

this will enable us to use the same sub-file to define each vpc in the ou/account sections in a multi-part config file, if vpc structures are identical
If a deployed cidr range changes in DDB, fail the SM

*5) *cidr-src: “dynamic”

add new optional config file parameters in vpc objects

cidr-size parameter (and cidr2-size for vpc only, not subnets - see bullet 3/4)

beside: vpc\cidr and vpc\subnets\definitions\cidr
value: between 16 and 28

cidr-pool parameter  (and cidr2-pool for vpc only, not subnets - see bullet 3/4)

beside: vpc\cidr and vpc\subnets\definitions\cidr
value: any string || the variable: ${OU_NAME}
${OU_NAME} resolves to the value of the ou the vpc is being created in

plan for vpc\cidr2 to be an array, see GitHub PR670 (https://github.com/aws-samples/aws-secure-environment-accelerator/pull/670)
convert the subnet cidr2 value back to a cidr, at the subnet level we do not need to distinguish cidr1 from cidr2

PROCESS:

For vpc\cidr, using cidr-vpc-assign

1st: Check status=assigned, region, account-ou-key, vpc-name, pool (and use)

Ensure value has not changed since last SM execution, if deployed

2nd: Check: status=available, region, pool, size

Change status=assigned, Set account-ou-key, vpc-name, date, requestor
(add account-id and vpc-id after vpc creation as a separate update to prevent deadlocks)

3rd: Create a new block using NetAddr from cidr-pools table in cidr-vpc-assign

https://pypi.org/project/netaddr/
Sample code leveraging net-addr: https://github.com/aws-samples/aws-vpc-cidr-mgmt (use the ipmgmt.zip code as is, if desired)
Cannot overlap with any existing: status: available || assigned || blocked from cidr-vpc-assign for that region/pool
Divide the pool usig the first/smallest available space
Add the new cidr assignment to cidr-vpc-assign DDB table populating:

Status=assigned, region, cidr, pool, index=unique, account-ou-key, vpc-name, date, requester=”AccelPrefix”

For vpc\subnets\definitions\cidr, using cidr-subnet-assign

1st: Check status=assigned, region, account-ou-key, vpc-name, subnet-name, az, vpc-index (and use)

Ensure value has not changed since last SM execution, if deployed

2nd: Check: status=available, vpc-index, size, sub-pool

Change status=assigned, Set subnet-name, az, date, requestor
(add subnet-id after subnet creation as a separate update to prevent deadlocks)

3rd: Create a new block using NetAddr from cidr-vpc-assign table in cidr-subnet-assign table

Add the new cidr assignment to cidr-subnet-assign DDB table populating:

Status=assigned, region, cidr, vpc-index, account-ou-key, vpc-name, subnet-name, az, date, requester

All cidrs with same vpc-index must be unique/no overlap

Add new config file variables inside all account objects (accountname\opt-in-vpcs)

opt-in-vpcs: [“opt-in-vpc-name1”, “opt-in-vpc-name2”, “opt-in-vpc-nameN”]

a vpc definition with the specified name, must exist in the ou config for the specified account
the vpc definition in the ou must have the opt-in: true set
When this parameter exists, create the vpc for the account
Allow adding new vpc’s to array, block removing vpc’s from the array unless:
{ "overrideComparison": true } or  {"configOverrides": {'ov-acct-vpc-optin': true } }

Near end of state machine, backup all DDB tables to individual files in s3 bucket

Enable accounts to request an opt-in VPC - TODO - refine requirements

Deploy Service Catalog (SC) item to each account
SC to offer opt-in VPC options

How do we list the options/what is available?

Sends message to central config file to add new entry in opt-in-vpcs parameter in the specific account
attains approval, auto-runs
runs state machine

SAMPLE DDB RECORDS:
DDB table: PBMMAccel-cidr-pools
{
"cidr": "<IP_ADDRESS>/13",
"region": "ca-central-1",
"pool": "main"
}
{
"cidr": " <IP_ADDRESS>/23",
"pool": "RFC6598",
"region": "ca-central-1"
}
DDB table: PBMMAccel-cidr-vpc-assign
{
"status": "assigned",
"region": "ca-central-1",
"cidr": "<IP_ADDRESS>/16",
"pool": "main",
"index": "548726314785236765",
"account-ou-key": "organizational-unit\Dev",
"vpc-name": "Dev",
"account-id":<PHONE_NUMBER>11,
"vpc-id": "vpc-096b07371301eeb7f",
"date": "thedatewithtime",
"requester": "Accelerator-Prefix"
}
DDB table: PBMMAccel-cidr-subnet-assign
{
"status": "assigned",
"region": "ca-central-1",
"cidr": "<IP_ADDRESS>/24",
"sub-pool": "a",
"vpc-index": "548726314785236765",
"account-ou-key": "organizational-unit\Dev",
"vpc-name": "Dev",
"subnet-name": "Dev",
"az": "a",
"subnet-id": "subnet-00f76121991ce23fa",
"date": "thedatewithtime",
"requester": "Accelerator-Prefix"
}

Will be in next MAJOR (not minor release) i.e. v1.5


Split viewer-prototype in packages

In prevision of the development of a vscode extension, the code in the
viewer-prototype has been mostly moved to 2 new packages:

@trace-viewer/base: Queries the trace server for traces, experiments
and possible outputs
@trace-viewer/react-components: Contains the various types of
visualization for trace data, queries the trace server for output data
to display

Those 2 packages can eventually be published to npm.
In the viewer-prototype directory only remains the theia specific module
contributions. So the application still works as before using theia,
it's just that most of the classes used by the trace-viewer have been
moved to new npm packages.
Signed-off-by: Geneviève Bastien<EMAIL_ADDRESS>

This PR is replacing PR #124. This one does not change our way of working right now. The theia browser and electron apps still work, but a good part of the code is moved to 2 packages that will be published on npm and consumed by the vscode and theia extension.
Thus this is a smaller bite to swallow on our way to a vscode extension.

I have not opened this repo in Gitpod for a while, so I do not know if this is new, but I notice the readability of the text is poor, in the example Electron application, accessed through vnc:

I found a VNC setting that fixes it: scaling mode: remote resizing instead of local scaling

When I briefly tested, I could get almost no graphs to display - maybe a single line for CPU usage view. Could be related to this backend trace, or not. Starting fresh in another container, that time I seem to crash it playing with the trace views. Not sure what happened exactly but the backend became unreachable. Maybe just bad luck. But I see kind of crazy amount of CPU being used, with one trace open and only the non-working CPU view. Like half to three quarters of the CPU power of the 16 cores of that host. Likely our container was killed because of too much resource usage.
Like before, I do not know if this is new or the same would happen on master.
root WARN Provided WebGL context does not have a stencil buffer, masks may not render correctly
root INFO
    PixiJS 5.3.3 - ✰ WebGL 2 ✰      http://www.pixijs.com/    ♥♥♥

root WARN Provided WebGL context

React is apparently not happy about something. Not sure if important:
root WARN Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details.

* Move data fetching code or side effects to componentDidUpdate.
* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state
* Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress this warning in non-strict mode. In React 17.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run `npx react-codemod rename-unsafe-lifecycles` in your project source folder.

Please update the following components: ReactGridLayout, ResponsiveReactGridLayout

@marcdumais-work Thanks for trying it. You're talking about gitpod only? Or did you try it somewhere else more local to you? I'll investigate, try to see if this is new from this PR or if it was there now in master.

It will be very nice when we can use the browser version of your app, in Gitpod. All these GPU problems go away then.

You're talking about gitpod only?

Correct. Most likely it will be better locally, but I'll let others confirm for now

@bhufmann I'm waiting for your feedback on this patch.
Would you rather
1- I do something custom to keep the tooltip for now, or
2- wait for a later patch where we can make the react-components dispatch , including tooltip, to ?

@bhufmann I'm waiting for your feedback on this patch.
Would you rather
1- I do something custom to keep the tooltip for now, or
2- wait for a later patch where we can make the react-components dispatch , including tooltip, to ?

@tahini, #170 implements a tooltip pop-up window and it doesn't need the signal (I think). So, I don't think we need a 1). Later I will see that we need for other purposes a way to communicate between the VSCode extension and the react-components.

Let me know when I can merge this, I just rebased on latest master, including the experiment sync.

Let me know when I can merge this, I just rebased on latest master, including the experiment sync.

@tahini #170 won't be ready for the MVP. So, this split patch would remove the tooltip window that shows the state tooltip. I think we should have the original tooltip behaviour for the MVP. So, we have 2 options:

don't merge this patch before the MVP
update this patch to bring back the original tooltip functionality.

Option 1) is the safe way for the MVP. However, option 2) would ok too, if the change doesn't take too long to implement. For option 2) we would have a minor update on our internal integration build.
What do you think?

I'll update this patch and bring back tooltip. I'd rather have this in sooner, it's a pain to rebase, especially with features that involve interactions between trace explorer and trace viewer.
It shouldn't impact your internal MVP too much, especially that the packages are still in the same repo, no?

I'll update this patch and bring back tooltip. I'd rather have this in sooner, it's a pain to rebase, especially with features that involve interactions between trace explorer and trace viewer.
It shouldn't impact your internal MVP too much, especially that the packages are still in the same repo, no?

The only impact I think is to have both the base and react-component packages published in our registry and reference them in our package.json. Should be straight forward.
Thanks for bringing the tooltip back in this PR.

The tooltips are back

@tahini, patch is good to be merged

Thanks!


examples: panic on errors in Wasm.

This commit makes sure that in-Wasm errors are detected as panics in examples.

exactly!


use eslint JSON output over errorformat

eslint provides a JSON output format. Using it gives us accurate highlight lengths.

Tests have been fixed.

Thank you!


added steganography

📥 Pull Request
Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
Fixes #728
Type of change

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] Documentation update

Checklist:

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my code
[x] I have commented my code, particularly in hard-to-understand areas
[x] I have added tests that prove my fix is effective or that my feature works
[x] New and existing unit tests pass locally with my changes
[x] Any dependent changes have been merged and published in downstream modules

@ajay-dhangar  please review this


Load pretrained models on different device

Problem statement
The current code results in the following error when running python test.py --gpu_idx 0 --peak_thresh 0.2:
using ResNet architecture with feature pyramid

-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=-*=

Traceback (most recent call last):
  File "test.py", line 113, in <module>
    model.load_state_dict(torch.load(configs.pretrained_path))
  File "/usr/local/lib/python3.6/dist-packages/torch/serialization.py", line 593, in load
    return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args)
  File "/usr/local/lib/python3.6/dist-packages/torch/serialization.py", line 773, in _legacy_load
    result = unpickler.load()
  File "/usr/local/lib/python3.6/dist-packages/torch/serialization.py", line 729, in persistent_load
    deserialized_objects[root_key] = restore_location(obj, location)
  File "/usr/local/lib/python3.6/dist-packages/torch/serialization.py", line 178, in default_restore_location
    result = fn(storage, location)
  File "/usr/local/lib/python3.6/dist-packages/torch/serialization.py", line 154, in _cuda_deserialize
    device = validate_cuda_device(location)
  File "/usr/local/lib/python3.6/dist-packages/torch/serialization.py", line 148, in validate_cuda_device
    device=device, device_count=torch.cuda.device_count()))
RuntimeError: Attempting to deserialize object on CUDA device 1 but torch.cuda.device_count() is 1. Please use torch.load with map_location to map your storages to an existing device.

Proposed solution
Remap the Tensor location at load time using the map_location.

hi @f-fl0
Thank you. Currently, I have no machine to test your commit, so I can't merge the pull request at this time. I'll do it ASAP. Thank you once again!

Thanks for your work. I fixed the minor error here. Please check it out. Thanks!

Thanks for your work. I fixed the minor error here. Please check it out. Thanks!

I tried your fix and everything works. Thank you!


[Feature Request]: Ability to add/remove/upgrade packages from the cli

Is your feature request related to a problem? Please describe.
I did a bit research on this and did not find a way to easily add package without having to open pubspec.yml and manually adding the package and version.
Describe the solution you'd like
Implement command to add package using fvm. fvm package add http
Describe alternatives you've considered
Not sure if this should be built into FVM, but would love if there is an existing 'official' solution.

Found exactly what I was looking for.
https://pub.dev/packages/pubx


Add behavior test for plcoud

pcloud has been added but no test cover, it's better to add behaivor test for it.

I can do this, but need a test account.

I can do this, but need a test account.

Perhaps you could register using your Apache email once you obtain one?

I can do this, but need a test account.

Perhaps you could register using your Apache email once you obtain one?

I registered one, how do I use it in behavior tests?

I registered one, how do I use it in behavior tests?

Please send a mail to private AT opendal.apache.org with title Request for adding secrets pcloud and all secrets that needed to configure. I will add them in 1password instead.


SS14-33795 Refactor Door Code

About the PR
Go through Door and Airlock code and migrate to consistently use Entity and better-define all the states doors can be in.
Otherwise, move Firelock and Airlock systems to be in the SharedDoorSystem and its client and server children, matching how bolting works.
This code whacks quite a lot of random code but in general the meaningful work is in Shared/Doors, Client/Doors and Server/Doors.
Why / Balance
Door code in general needed a pass. This stops endless bools being added to hack extra nuance onto door state and makes things more understandable.
Technical details
The main work here has been to make doors work off of one enum to cover door states, rather than an enum and a slowly-increasing set of bools (two as of today) that cover state implicitly.
Doors now have specific states for how they're being opened or closed (by self - the door is opening under its own steam, or by prying, because the door is being forced open); the "partial" bool is now "opening/closing" states that are moved to from states where a door is starting to open/close.
Otherwise, a sweep of firelock and airlock code has allowed DoorSystem to become the sovereign and solitary system for doors. Just like bolts, airlocks and firelocks are both components that sit alongside a mandatory door component.
Media

Requirements

[x] I have read and am following the Pull Request and Changelog Guidelines.
[x] I have added media to this PR or it does not require an ingame showcase.

Breaking changes

Changelog
No functional changes, ma'am

Have checked airlocks so far, clicking, bumping and hacking/prying. The lights system on doors seems to be fine too. Not checked firelocks.

OK, I've rebased and force-pushed up so this is now pointing at master without any shenanigans.

Alright gamers the tests pass.

TODOs:

Load into a big map like Meta and make sure doors act normally
Get this merged onto the test server that will be totally real soon (tm) and do tests


Setting EntityReference using key not working if key is numerical

Let's say I want to create and invoice referencing a salesorder using key instead of salesorderid.
 var invoice = new Entity("invoice");
invoice["salesorderid"] = new EntityReference("salesorder", "new_key", 123);
service.Create(invoice);
This will fail with Bad Request - Error in query syntax
By inspecting the request I see that the content is generated with ' around the int value making it a string:
{ "salesorderid@odata.bind":"/salesorders(new_key=\u0027123\u0027)"}

It works if you chose service.UseWebApi = false, but I just wanted to let you know.

Thanks for Reporting this @petersk80,  We have been chasing a number of these inconsistencies in the way the WebAPI handles alternate keys.  Will take a look.

This has been identified and fixed in the next drop.

Excellent, thank you. Keep up the great work


Plugin manager

Adds a message when trying to invoke a previously bundled action from a Fastfile or using the one-off command.
The user is presented with a message informing that we no longer bundle it and to install it using the new plugin commands.

@KrauseFx  As part of this should we shortlist actions to consider unbundling in the future ?

This is a great change, thanks @jcampbell05. I added some comments before it's ready to be merged.
We don't plan on suddenly removing a high number of actions, but slowly deprecate more and more actions. It would be great to have xcake as one of the first publicly available plugins 👍
We'll let you know in the #plugins channel when the fastlane new_plugin action is ready 🚀

I'd also like some tests to cover this change 👍

@KrauseFx do you have an example on a good way to test this output ?

Looks great, thanks. I'll add some tests for you, I'll link you to the commit once it's ready 👍

Here are the tests https://github.com/fastlane/fastlane/pull/4722/commits/a076f1503ba8c321cf0d4bf8c5ffbb940280bac4 🚀


[Bug]: Unable to import external module with webpackIgnore

Version
29.7
Steps to reproduce
In my code I have:
import(/* webpackIgnore: true */ js_module)
Expected behavior
Import the module how a browser would import the module, based on the presence of the webpackIgnore comment. i.e. Making a network request to the provided URL.
Actual behavior
It attempts to import a local module:
Cannot find module 'http://localhost:8080/admin/js' from 'src/App.js'

Maybe this relates to #9430, but I'm not clear exactly how much it overlaps.

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 30 days.

...

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 30 days.

.

.

.

.

.

.

.

.


Some input in date are panicking the binary

using gnu date command
date --version
    gnu 8.30
date "+%Y-%m-%d %H-%M-%S%:::z"
    2022-08-5 09-53-28+00

while executing coreutils' date command
date --version
    0.0.14
date "+%Y-%m-%d %H-%M-%S%:::z"
$ RUST_BACKTRACE=1 ./target/debug/coreutils date "+%Y-%m-%d %H-%M-%S%:::z"
thread 'main' panicked at 'a Display implementation returned an error unexpectedly: Error', /usr/src/rustc-1.59.0/library/alloc/src/string.rs:2399:14
stack backtrace:
   0: rust_begin_unwind
             at /usr/src/rustc-1.59.0/library/std/src/panicking.rs:498:5
   1: core::panicking::panic_fmt
             at /usr/src/rustc-1.59.0/library/core/src/panicking.rs:116:14
   2: core::result::unwrap_failed
             at /usr/src/rustc-1.59.0/library/core/src/result.rs:1690:5
   3: core::result::Result<T,E>::expect
             at /usr/src/rustc-1.59.0/library/core/src/result.rs:975:23
   4: <T as alloc::string::ToString>::to_string
             at /usr/src/rustc-1.59.0/library/alloc/src/string.rs:2398:9
   5: uu_date::uumain::uumain
             at ./src/uu/date/src/date.rs:246:37
   6: uu_date::uumain
             at ./src/uu/date/src/date.rs:145:1
   7: coreutils::main
             at ./src/bin/coreutils.rs:95:31
   8: core::ops::function::FnOnce::call_once
             at /usr/src/rustc-1.59.0/library/core/src/ops/function.rs:227:5
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

Screenshot are terrible for search and for accessibility.
Please replace them by actual text. thanks

using gnu date command
date --veriosn
    gnu 8.30
date "+%Y-%m-%d %H-%M-%S%:::z"
    2022-08-5 09-53-28+00

while executing coreutils' date command
date --version
    0.0.14
date "+%Y-%m-%d %H-%M-%S%:::z"
    >>> main thread panic

Thanks, it should be easy to fix

Other occurrence found by the fuzzer published in issue #3785
 ./target/debug/coreutils date '+~\x0a~%\x0a'
thread 'main' panicked at 'a Display implementation returned an error unexpectedly: Error', /rustc/34a6cae28e7013ff0e640026a8e46f315426829d/library/alloc/src/string.rs:2490:14

It looks like chrono does not support %::z or %:::z format specifiers. I think the right solution is to upstream it there?

Looks like this was just added to chrono, actually: https://github.com/chronotope/chrono/commit/5f5410163b6655cd0098530f2c6c44bbcc87d102

I have still same problem when running app with this arguments in latest git version of chrono cargo run -- "+␅+%+␄^%)"

Apparently this behaviour is fixed in main, commit https://github.com/uutils/coreutils/commit/af2833761c7d2b8ba9717503683d2b06f848812a

Excellent! I think we can close this after we made a regression test for it.

working on it :)

What about other panics from issue like cargo run '+~\x0a~%\x0a' or cargo run "+␅+%+␄^%)" ?
New issue should be created?

yes please


Please invite me to the GitHub Community Organisation

#include
int main() {
std::cout << "Knocking to join @eddiejaoude 's community! 👋 ";
return 0;
}

Invitation sent for the GitHub Organisation. Welcome to the community 🎉
Don't forget after accepting to make it public so it appears on your GitHub profile for everyone else to see, you can do this by finding your name in the GitHub organisation list and change the dropdown to public https://github.com/orgs/EddieJaoudeCommunity/people
Tips for practising:
Customise your GitHub profile, here is a live stream on it https://www.youtube.com/watch?v=cT6GXCuS0Zo
Practice repo, instructions on how to add your name to the README in the README https://github.com/EddieJaoudeCommunity/hacktoberfest-practice
Remember contributing to open source is not just about code, its about collaboration, communication and adding value
I hope that helps


Text generation

Text Generation with Tensorflow Eager Execution

@alextp @MarkDaoust @lamberta @random-forests @asimshankar

Hi Yash, can you coordinate these notebooks with Josh for the 1.10 release?

@lamberta I did ask Josh and he told me to put these here for now and then for 1.10, we can move it to wherever the folder is

Now let's wait for the hold on merges to be lifted to merge this.


Make Transcriber class that can support different asr backends.

Done, currently we have only one faster_whisper backend but in the future I will add more.

Done, currently we have only faster_whisper backend, but in the future I will add more.


feat: startknet indexer

Detailed Information

Related Issues
Closes #236

Type of Change

[x] 🐛 Bug fix or ⚙ enhancement
[ ] ✨ New feature or Chore (change with no new features or fixes)
[ ] 📚 Documentation update

Checklist (select as many as applicable)

[x] The code follows the style guidelines of this project.
[ ] All new and existing tests pass.
[ ] This pull request is ready to be merged and reviewed.

Nice. Please separate db operations.

Will push my changes now!


I can't see my profile on skylea

When i try to search my name on skylea, my profile doesn't show up.
https://sky.shiiyu.moe/stats/LeonheartOP/Raspberry

OS:  Windows 11

Browser: chrome

Device: Vivobook_asusLaptop

@metalcupcake5


Hackpad Pull Request (WIP) and request for extension

Ready to submit your project? Nice job! Hopefully you've read the submission guidelines. If not, make sure to read them first.
If you're unsure about the format, make sure to check out the Orpheuspad example and follow the format there.
If this PR isn't a submission, that's okay too! If there's anything about this PR template that seems confusing, let me know in #hackpad on the slack!

Hey there, could you update your PR to follow the submitting guidelines? You're missing a lot of files

Alright. I've added all of my files, so now can you merge this branch?


DNN-6833: fixing unclosed db connection bug.

Please remember to mark the issue with the Merged label when you process a PR.  We use this label for reporting purposes.


[RFE] Steve should only send schema updates when schemas change

We are seeing on various systems at scale that the backend if almost flooding the web socket every few seconds with schema updates, even though schemas have not changed.
The UI has to process these and since these drive a lot of the UI, this causes a lot of elements in the UI to re-compute.
It would be nice if the backend could check that a schema did actually change before sending updates.
You can see this for yourself by opening the UI with developer tools in Chrome, going to the Network tab and looking at web sockets. Find the Steve web socket - do this on a downstream cluster.
Create a new CRD (e.g. create the one from here - https://kubernetes.io/docs/tasks/extend-kubernetes/custom-resources/custom-resource-definitions/)
You will observe that in addition to the new schema, you get web sockets for a tonne of other schemas that were not changed).

Internal reference: SURE-5398

Rancher PR for Steve changes https://github.com/rancher/rancher/pull/39782

Validation
Root Cause
The Steve Websocket used to stream schema updates contained false positives when detecting changes in schemas causing the unnecessary change event to be sent on the websocket. These false positives were caused by the access attribute being stripped before checking for equivalency to the previously saved list of schemas.
What was fixed, or what change has occurred
Steve's change detection logic was updated to ignore the access attribute since it is not sent to the frontend.
Areas or cases that should be tested
Test that only correct schema changes are sent on the socket

Start Rancher server v2.7-HEAD
Login to the Rancher server
Open Developer UI in Chrome
Select network tab
Select WS filter for Websockets
Navigate to the local cluster dashboard
Refresh the page.
Select subscribe?socketId=1
Select the Messages tab
In the filter bar under the message tab, input "resourceType":"schema" so we only see relevant messages.
Apply the given CRDapiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: crontabs.stable.example.com
spec:
  group: stable.example.com
  versions:
    - name: v1
      served: true
      storage: true
      schema:
        openAPIV3Schema:
          type: object
          properties:
            spec:
              type: object
              properties:
                cronSpec:
                  type: string
                image:
                  type: string
                replicas:
                  type: integer
  scope: Namespaced
  names:
    plural: crontabs
    singular: crontab
    kind: CronTab
    shortNames:
    - ct

Verify that there are only two new messages for the added schema.
{"name":"resource.create","resourceType":"schema","data":{"id":"stable.example.com.v1.crontab.spec",...
"{"name":"resource.create","resourceType":"schema","data":{"id":"stable.example.com.crontab",...

Are the repro steps accurate/minimal?

Start Rancher server v2.7.0
Login to the Rancher server
Open Developer UI in Chrome
Select network tab
Select WS filter for Websockets
Navigate to the local cluster dashboard
Refresh the page.
Select subscribe?socketId=1
Select the Messages tab
In the filter bar under the message tab, input "resourceType":"schema" so we only see relevant messages.
Apply the given CRDapiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: crontabs.stable.example.com
spec:
  group: stable.example.com
  versions:
    - name: v1
      served: true
      storage: true
      schema:
        openAPIV3Schema:
          type: object
          properties:
            spec:
              type: object
              properties:
                cronSpec:
                  type: string
                image:
                  type: string
                replicas:
                  type: integer
  scope: Namespaced
  names:
    plural: crontabs
    singular: crontab
    kind: CronTab
    shortNames:
    - ct

Verify that there are multiple 100+ resource.change events for schemas.

Followed validation steps and observed the correct behavior.
@bmdepesa Should we run a larger performance test for this issue, or just wait for release testing?


npm install doesn't work

Hi Team,
npm install doesn't work.
yarn install does work on the other hand.
I'm trying to understand why.

Just remove the     "bootstrap_calendar": "https://github.com/xero/bootstrap_calendar.git#1.0.1", in package.json Still looking for an alternative.

We removed "bootstrap_calendar": "https://github.com/xero/bootstrap_calendar.git#1.0.1", from package.json


requests with timespan based on minutes fail

Hi @alex9smith,
I text you again about another issue I've recently found while working with your library. According to the gdelt documentation, one can choose the time range by using this option to specify the number of months, weeks, days, hours or minutes (minimum of 15 minutes).
It works for all specifications except for the "minutes" one. I tried this way:
f = Filters(
timespan = "15min",
theme  =  'CORRUPTION'
repeat = repeat(3, 'italy')
)
gd = GdeltDoc()
news = gd.article_search(f)
It gives as output:
TypeError: argument of type 'int' is not iterable
Am I doing something wrong?

Thanks @priolap, I get the same error.
I think this is similar to the last couple of problems that you've reported, and the query string that's getting built for those filters isn't correct. I will investigate and sort out a fix.
What this also tells me is:

I need to check through all the other filter options and write some more tests based on the documentation, as the test coverage is pretty poor at the moment.
I need a better error message if the query string is invalid.

I'll get your problem fixed first, then look at some longer term fixes to reduce the number of times people get similar problems.

This is a really unfortunate error 😞
Even though the documentation says you can query the last 15 minutes, my testing shows the smallest value allowed in the timespan parameter is actually 60 minutes.
The error message you're getting here was really unhelpful though (sorry!). I've just released version 1.4.0 which has validation of the timespan parameter and better error handling so if there's another case that produces an invalid API query you'll at least see a proper error message.
On 1.4.0 running your example results in:
In [1]: from gdeltdoc import GdeltDoc, Filters, repeat
   ...:
   ...: f = Filters(
   ...: timespan = "15min",
   ...: theme = 'CORRUPTION',
   ...: repeat = repeat(3, 'italy')
   ...: )
   ...: gd = GdeltDoc()
   ...:
   ...: news = gd.article_search(f)
---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
Input In [1], in <cell line: 3>()
      1 from gdeltdoc import GdeltDoc, Filters, repeat
----> 3 f = Filters(
      4 timespan = "15min",
      5 theme = 'CORRUPTION',
      6 repeat = repeat(3, 'italy')
      7 )
      8 gd = GdeltDoc()
     10 news = gd.article_search(f)

File ~/code/gdelt-doc-api/gdeltdoc/filters.py:169, in Filters.__init__(self, start_date, end_date, timespan, num_records, keyword, domain, domain_exact, near, repeat, country, theme)
    166     self.query_params.append(f'&enddatetime={end_date.replace("-", "")}000000')
    167 else:
    168     # Use timespan
--> 169     self._validate_timespan(timespan)
    170     self.query_params.append(f"&timespan={timespan}")
    172 if num_records > 250:

File ~/code/gdelt-doc-api/gdeltdoc/filters.py:268, in Filters._validate_timespan(timespan)
    265     raise ValueError(f"Timespan {timespan} is invalid. {value} could not be converted into an integer")
    267 if unit == "min" and int(value) < 60:
--> 268     raise ValueError(f"Timespan {timespan} is invalid. Period must be at least 60 minutes")

ValueError: Timespan 15min is invalid. Period must be at least 60 minutes

This doesn't fix what you were trying to do, but at least we know why now.

Hi @alex9smith,
thanks for your testing but currently I can query up to the last 31 minutes!

Oh, interesting. Can you share the query you did that worked for 31 minutes?


Fix compile errors

Hi @mbana, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
The agreement was validated by Microsoft and real humans are currently evaluating your PR.
TTYL, MSBOT;

Hi @mbana, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
The agreement was validated by Microsoft and real humans are currently evaluating your PR.
TTYL, MSBOT;

@mbana there is not need to add ./node_modules/ to scripts. npm doesn this automatically.
And I don't see any compile errors on master which would require your code changes. Can you please explain why you are suggesting those.
I like your script. However to merge this in I need Windows scripts as well :-)

ok thanks. i was just being careful; i think i may have run into an issue in the past with a global installation overriding the package-specific one. soz, please close then.
compile errors:
i'm sure i was getting compile errors are those lines.
in the future, i will capture the error when raising PRs.
build:
can i kindly suggest compiling in Docker - since they are no native dependencies required? - and running the tests on the various platforms. you probably already do this.
any chance of adding pre-commit hooks, that way compile errors (in theory) in master won't happen.
thanks,

errors i got before the fix are below.
any idea what's up?
file: 'file:///Users/mbana/dev/vscode/mbana/vscode-languageserver-node/client/src/main.ts'
severity: 'Error'
message: 'Type 'Promise<{}>' is not assignable to type 'Thenable<void>'.
  Types of property 'then' are incompatible.
    Type '{ (onfulfilled?: (value: {}) => {} | PromiseLike<{}>, onrejected?: (reason: any) => {} | PromiseL...' is not assignable to type '{ <TResult>(onfulfilled?: (value: void) => TResult | Thenable<TResult>, onrejected?: (reason: any...'.
      Types of parameters 'onfulfilled' and 'onfulfilled' are incompatible.
        Type '(value: void) => any' is not assignable to type '(value: {}) => {} | PromiseLike<{}>'.
          Types of parameters 'value' and 'value' are incompatible.
            Type '{}' is not assignable to type 'void'.'
at: '1580,10'
source: 'ts'

file: 'file:///Users/mbana/dev/vscode/mbana/vscode-languageserver-node/client/src/main.ts'
severity: 'Error'
message: 'Type 'Promise<{}>' is not assignable to type 'Thenable<void>'.'
at: '1593,10'
source: 'ts'

LN 1579-160:
	private handleRegistrationRequest(params: RegistrationParams): Thenable<void> {
		return new Promise((resolve, reject) => {
			params.registrations.forEach((element) => {
				const handler = this._registeredHandlers.get(element.method);
				element.registerOptions.documentSelector = element.registerOptions.documentSelector || this._clientOptions.documentSelector;
				if (handler) {
					handler.register(element);
				}
			});
			resolve();
		})
	}

	private handleUnregistrationRequest(params: UnregistrationParams): Thenable<void> {
		return new Promise((resolve, reject) => {
			params.unregisterations.forEach((element) => {
				const handler = this._registeredHandlers.get(element.method);
				if (handler) {
					handler.unregister(element.id);
				}
			});
			resolve();
		})
	}

There are automatic builds happen on every checkin. They are here: https://travis-ci.org/Microsoft/vscode-languageserver-node
I am not sure why the build fails for you. I assume an older version of a TS compiler.


serverside pagination issues

I'm trying to implement server-side pagination but dataTotalSize is not working. It is showing infinite page numbers. Can someone help me with this?
The following is the initialization code
<BootstrapTable
                                data={props.participantDetails}
                                striped={true}
                                hover={true}
                                remote={true}
                                pagination={true}
                                search={true}
                                fetchInfo={ { dataTotalSize: props.totalParticipantsCount } }
                                options={ {
                                    onPageChange: props.participantsListPageChangeHandler,
                                    page: props.currentPage,
                                    sizePerPage: 10
                                } }>

                                <TableHeaderColumn dataField="name">Participant Name</TableHeaderColumn>
                                <TableHeaderColumn dataField="emailId" isKey={true}>Email ID</TableHeaderColumn>
                                <TableHeaderColumn dataField="mobileNumber">Mobile</TableHeaderColumn>
                            </BootstrapTable>

Fixed it? why close? and I have no idea about "showing infinite page numbers", what's the means?

it is fixed my issue mismatch of variable name


[Non-Node Envs] Make openai classes use fetch, remove use of node-fetch

Adds installation instructions for node 16

Looks like https://github.com/vespaiach/axios-fetch-adapter doesn't support CJS.
It's small enough and doesn't really have any deps besides axios that we could just pull the one adapter function into our codebase.
Also looks like axios has an open PR to add fetch support natively: https://github.com/axios/axios/pull/5146 so we could eventually remove whatever we go with here.

@sullivan-sean yea or we wait until going for a full ESM build to merge this one, which was my plan, hopefully I can fix the remaining issues in #124

@sullivan-sean I did what you suggested, in #124 , that package has a misconfigured package.json


TIFF Compression without bit depth loss

What are you trying to achieve?
I would like to compress (deflate) a 16bit tiff image with no loss of bitdepth.
Have you searched for similar questions?
Yes
Are you able to provide a minimal, standalone code sample that demonstrates this question?
Using imagemagick I can compress the image and not reduce the bit depth.
mogrify -compress zip *.tiff
It would be great to do the same with sharp but all my compressed Tiffs now have 8 bits
options.bitdepth number  reduce bitdepth to 1, 2 or 4 bit (optional, default 8)
Are you able to provide a sample image that helps explain the question?
Not really...

https://github.com/lovell/sharp/issues/534#issuecomment-236826614 seems to downsample if 16bit, I wondered what the reason was? Probably some ignorance on my part.

Hi, did you see toColourspace?
await sharp('16-bit.tiff')
  .toColourspace('rgb16')
  .toFile('16-bit-too.tiff');

Amazing. Thank you.


Firebase plugins (FlutterFire) support

The FlutterFire Dart SDK is under active development and we may be able to use it in Tizen apps in the near future.
GitHub repo: https://github.com/invertase/flutterfire_desktop
Please check the current status of the packages or even contribute to the project if anyone is interested.

[x] firebase_core
[x] firebase_auth
[x] firebase_functions

The following libraries are not supported by flutterfire_desktop. They might be implemented using the Firebase C++ SDK instead.

[ ] firebase_analytics
[ ] cloud_firestore
[ ] cloud_functions
[ ] firebase_messaging
[ ] firebase_storage (work in progress by flutterfire_desktop)
[ ] firebase_database
[ ] firebase_remote_config (work in progress by flutterfire_desktop)

@HakkyuKim
Im currently assigned to this task.
For now following variations have been tested:
native webview does not cooperate with google oauth - https://github.com/flutter-tizen/plugins/issues/390
I'm during testing whether google oauth cooperate with an ewk version of webview - https://github.com/flutter-tizen/plugins/pull/400

google_sign_in_tizen introduces an interface to obtain an OAuth token from Google API.
As the docs state, it is required to use a private key for the sake of authentication.
This forces app developer to share their apps with private keys or obfuscate their code.
Also google_sign_in on tizen platform uses a simplified flow, which requires more interaction from user.
I am currently working on implementing a tizen version of desktop_webview_auth for the firebase auth with implicit flow which does not require sharing a private key and simplifies user interaction.
Should I rather use google_sign_in or stick to the current approach?
What do you think @bwikbs @HakkyuKim @swift-kim

@JRazek
I understand your concerns (Plz, forget my previous suggestion).
IMO, There is no need to try to use google_sign_in_tizen unless you have major problems with your current task.
I think we can discuss it again later if necessary.

@JRazek I personally prefer google_sign_in_tizen's way in terms of the user interface. If you use a webview for authentication, the user has to enter their account name and password using buttons on a remote control and that's fairly painful.
The only concern for me if we decide to use "OAuth 2.0 for TV and Limited-Input Devices" is its limited API scopes. So I think we can support both ways so that developers can choose the best option for their apps.

At this moment I have a draft of a webview_auth_tizen plugin.
It is an equivalent of a flutter_desktop_webview_auth plugin.
I've decided to write a separate plugin instead of porting it because it is much simpler approach. It required no native implementation, just usage of an existing webview plugin.
Please let me know if you agree on that approach.

@JRazek That looks like only a partial solution for your final goal (which is to implement firebase_auth for Tizen). You need to also consider how the user (an app developer) can use your package to implement "Firebase Auth" in their app.
As you can see in the firebase_auth_desktop example, an app should depend on firebase_auth_desktop and desktop_webview_auth to implement Firebase Auth for desktop platforms. If a developer wants to add Tizen support on top of it, they will have to add tizen_webview_auth (I think this naming is better than webview_auth_tizen) as an extra dependency. The API should also look similar to desktop_webview_auth's so that the developer can write cross-platform code easily. For example,
// desktop_webview_auth
final result = await DesktopWebviewAuth.signIn(GoogleSignInArgs(...));

// tizen_webview_auth
final result = await TizenWebviewAuth.signInGoogle(...);

You can even add Tizen support to the desktop_webview_auth package by implementing its implicit method channel. What you have to do is to simply implement the channel in a Dart class, and you don't need to write any native code or add additional complexity to your code.

The final app side code will look like this:
// If using google_sign_in:
GoogleSignIn googleSignIn = GoogleSignIn(scopes: <String>['email', 'profile']);
GoogleSignInTizen.setCredentials(
  clientId: ..,
  clientSecret: ..,
);
GoogleSignInAccount googleUser = await googleSignIn.signIn();
GoogleSignInAuthentication result = await googleUser.authentication;

// Alternatively, if using tizen_webview_auth:
AuthResult result = await TizenWebviewAuth.signInGoogle(
  clientId: ..,
  redirectUri: ..,
  scope: 'https://www.googleapis.com/auth/userinfo.email',
));

// Common to all:
OAuthCredential credential = GoogleAuthProvider.credential(
  accessToken: result.accessToken,
  idToken: result.idToken,
);
UserCredential userCredential = await FirebaseAuth.instance.signInWithCredential(credential);

A developer can choose which method to use to sign in. google_sign_in would be the best option if signing in to Google. Otherwise, tizen_webview_auth would be the only available option (as long as it supports Apple, Facebook, ...).

I would call it the part of the solution rather than the partial solution.
The reason for making the webview_auth_tizen API as a widget is because in original implementation they do not pass the context.
They directly call the static function for logging
https://github.com/invertase/flutter_desktop_webview_auth/blob/7082cd06564515d7e8add0aa95e51cf90204bc53/example/lib/main.dart#L37 which calls native side and does not care about flutter at all.
There are a few solutions, that I see:

Do it as a free function as in the upper example, but pass a BuildContext as well,
Initialize a plugin with proper data,
Just use the plugin as it is now.

Please tell me which one will suit you best or suggest how would you do it in other way.

@JRazek The first option makes most sense to me but it's up to your choice. Obviously the third one will require more user code than the others so you will need to provide a "complete" guide on how to use the widget. You also need to clarify how the sign-in screen should be displayed to the end user (e.g. by using showDialog or Navigator.push) and how the app should receive the result when the dialog or page is closed.

Most firebase plugins are not yet supported in pure Dart: https://github.com/invertase/flutterfire_desktop.
In the meantime, we could use the Firebase C++ SDK if we can build this for Tizen architecture: https://github.com/firebase/firebase-cpp-sdk.
I'm first attempting to build for emulator, I'll share any progress worth mentioning here.

Hi @HakkyuKim,
Glad you are trying it for the Tizen arch, do you have any update on that.?

Hi, @prasanna-jeyam.
I've been moved to a different project starting this year so I'm not working on this issue now. But the last time I checked, The C++ SDK didn't build for X86 (was trying to run on emulators first). I posted an issue here, I think the developer who fixed it afterwards was able to build it, but I remember it didn't work on my machine.
For wasn't able to further investigate for arm builds.

@HakkyuKim When I checked last time (a month ago) the build itself succeeded without error. I haven't checked if the built libraries actually work on Tizen devices though.
I think we're going to work on this feature this year but still don't have detailed plans or schedules. /cc @bbrto21 @JSUYA

@HakkyuKim When I checked last time (a month ago) the build itself succeeded without error. I haven't checked if the built libraries actually work on Tizen devices though.
I think we're going to work on this feature this year but still don't have detailed plans or schedules. /cc @bbrto21 @JSUYA

CC. @daeyeon @hs0225

This issue is a showstopper for us unfortunately as our app heavily uses Firebase. Firestore and Storage in particular.
Unfortunately flutterfire_desktop is not actively developped due to a lack of funding. Maybe Samsung can help here?
The author of the firebase_dart plugin would be willing to work on this as he mentioned here for example:
https://github.com/appsup-dart/firebase_dart/issues/21#issuecomment-1296769240
A merge with flutterfire_desktop was proposed here: https://github.com/appsup-dart/firebase_dart/issues/33
A dart implementation of the most used firebase plugins would be prefered but wrapping the C++ SDK is also an option. Unfortunately it is still not recommended to be used outside of development and some features might still be stubs. If Samsung could contact the Google Firebase team on this matter and discuss a collaboration that might help a lot.
/cc @marb2000

@cbenhagen I am currently trying to support flutter firebase packages based on the firebase C++ SDK.
There is a limit to extending the flutterfire_desktop because the flutter rest api used by it provides less firebase functionality than firebase C++ SDK.
Although firebase C++ SDK also doesn't cover all the firebase features, I think it's the best way to provide more features at the moment.
But as you know, firebase C++ SDK is a beta feature. So I'm also working on validating it.

@hs0225 thank you so much for working on this! Other platforms could also greatly benefit from this. Especially Linux and Windows.
Linking some relevant issues:
https://github.com/firebase/firebase-cpp-sdk/issues/442
https://github.com/firebase/firebase-cpp-sdk/issues/42
Also this discussion:
https://github.com/firebase/flutterfire/discussions/5557

@hs0225 / @HakkyuKim did you see https://github.com/firebase/flutterfire/pull/10496?

@everyone please show your support for Flutter / Firebase on Linux based devices by upvoting this idea. Thanks!

@cbenhagen Sorry for the late reply. And thanks for your info. I will refer to it for future development.
For your information, we will start committing from firebase_core for Tizen next month.

The flutterfire_desktop repo has been moved to the FirebaseExtended organization, and according to the recent announcement at Google I/O, there will be more Google support for this project than before. It's still not clear which way (C++ SDK or pure Dart based on REST API) they will eventually go and how much effort they will put into it.


Add index to FindMergeCommits

Could we add an index to the output of FindMergeComits, this will allow me to preserve that ordering throughout the pipeline.

Thanks


Error with b2c.scaled_he_image()

I am having the same problem as comment #29.
File ~/.local/lib/python3.9/site-packages/bin2cell/bin2cell.py:705, in actual_vs_inferred_image_shape(adata, img, ratio_threshold)
    702 #do the two match, within some tolerance of rounding etc?
    703 #divide both ways just in case
    704 if np.min(np.hstack((actual_dim/inferred_dim, inferred_dim/actual_dim))) < ratio_threshold:
--> 705     raise ValueError("Morphology image dimension mismatch. Dimensions inferred from Spaceranger output: "+str(inferred_dim)+", actual image dimensions: "+str(actual_dim)+". Are you running with ``source_image_path`` set to the full resolution morphology image, as used for ``--image`` in Spaceranger?")

ValueError: Morphology image dimension mismatch. Dimensions inferred from Spaceranger output: [33606.99885915 26487.91626749], actual image dimensions: [31606 33607]. Are you running with ``source_image_path`` set to the full resolution morphology image, as used for ``--image`` in `Spaceranger?`

print(np.shape(adata.uns["spatial"]['BG_Y12369_High_Res']["images"]["hires"]))
print(np.min(adata.obsm["spatial"],axis=0))
print(np.max(adata.obsm["spatial"],axis=0))

(6000, 4729, 3)
[3612.86561995 4792.48615448]
[28445.11050502 29472.01037198]
img = b2c.load_image(source_image_path)
img.shape

(31606, 33607, 3)
Y12369.tif[0] TIFF 33607x31606 33607x31606+0+0 8-bit sRGB 280.818MiB 0.000u 0:00.007
Y12369.tif[1] TIFF 16803x15803 16803x15803+0+0 8-bit sRGB 0.000u 0:00.001
Y12369.tif[2] TIFF 8401x7901 8401x7901+0+0 8-bit sRGB 0.000u 0:00.001
Y12369.tif[3] TIFF 4200x3950 4200x3950+0+0 8-bit sRGB 0.000u 0:00.001
Y12369.tif[4] TIFF 2100x1975 2100x1975+0+0 8-bit sRGB 0.000u 0:00.001
Y12369.tif[5] TIFF 1050x987 1050x987+0+0 8-bit sRGB 0.000u 0:00.001
Y12369.tif[6] TIFF 525x493 525x493+0+0 8-bit sRGB 0.000u 0:00.001
Y12369.tif[7] TIFF 262x246 262x246+0+0 8-bit sRGB 0.000u 0:00.001
It does not look like the solution to my problem is the same as #29. I would appreciate any help you can provide!

Thanks for doing the same diagnostics as that issue, it makes my life a lot easier. Hopefully the error is informative enough to get the point across - the shrunken image loaded as part of the Spaceranger output looks like it came from a different source image than the one you've got here. The actual dimensions are off, the ratios of the dimensions are off (you can check the reverse-engineered ones versus the hires ones to see the calculation is not messed up, feel free to dig up the size factor and double check). At this point pretty much all you can do is actually take a look at the images.

Sorry it took so long to follow up, I never got a notification of that you replied. The thing that doesn't make sense to me is that this is the exact same image I input for SpaceRanger. It is also weird that one of the dimensions matches but not the other. Perhaps it is because I annotated the barcodes so that only those overlapping with tissue were included in the SpaceRanger run? Otherwise I can try to rerun SpaceRanger and see if that solves it.

I remain quite confident that this is not the image Spaceranger was ran on - you technically have a shared dimension of 33607 on reinspection, but from shape alone it seems like the image was rotated and had things cropped from it in the other dimension prior to going into Spaceranger. If that's something you did, don't do that, or ingest the modified version. If you genuinely fed that exact file to Spaceranger, contact 10X customer support.

You would be absolutely correct... I accidentally uploaded the binned_outputs and spatial folder for the practice data to the folder containing my data. Oops! Works fine now. Sorry for wasting your time!


Merging of local objects based on (trying to add an existing) external data source

Follow-on from #809, specifically https://github.com/acdh-oeaw/apis-core-rdf/issues/809#issuecomment-2203245269, https://github.com/acdh-oeaw/apis-core-rdf/issues/809#issuecomment-2203855550:
Current behaviour when trying to merge external data into a local object when the external data source is already linked on another object is to merge the two local objects.
I'm not sure if this is the best course of action / if automagic merging of local objects based on external (meta) data is what users would expect to happen.
It's very easy to merge two local objects if that's the intention since those appear first in the merge field's search results. Or even when it's not the intention, i.e. when the user wasn't aware that a local duplicate already exited -> same thing, it would turn up at the top of the list, from where users could inspect it and decide to merge the two local objects if that's what should happen.
But in cases where local objects / external data sources "look" the same but are actually separate entities and should remain separate, I can see users accidentally selecting the wrong external data source to add meta information and thus inadvertently merging the two local objects. Example: identically named places which are easy to confuse, e.g. cities and federal states which share a name (Vienna, Salzburg).
TL;DR I think (destructive) actions like merging need to be really transparent to users. I'd therefore limit merging of local objects to users having to actively, specifically select local objects to merge together.
A temp. message, similar to the one we now show for object duplication, to let users know the data source they are trying to add to object X already exists (on other local object Y) would add transparency. We could then add the current mechanism to that if that were useful, e.g. by extending the message with a link or button that users could (would have to) click to merge the two local objects.

Implemented in ba7ad4c2b450e83069b960d012ff4e3f544306e8


Implementation of HD Map (DRG)

HD Map

Generalize pedestrian regulatory element code to be for any obstacle

Mostly changing variable names
On the visualization side we have to display the obstacles as a 2d bounding box (convert polygon to marker array representation of a 2d bounding box)
Add attribute that stores the detected class (object hypothesis in the detection3d message)

Color code the bounding box based on the class

Visualization of traffic sign and traffic light

Store traffic light state (or sign type) as attribute in reg elem
These can be simple lines (color coded for the traffic light state)

Write code for traffic sign reg elems following similar pattern as pedestrian reg elem


pub serve isn't obvious that it's not ready to serve resources

Starting pub serve, I see this:
Serving angular_dart_demo on http://localhost:8080
However, it's many seconds until the server is actually ready. On my machine, maybe 17 seconds?
Took 0:00:17.372084 to compile angular_dart_demo|web/main.dart.
Can we immediately emit a message that says something like
"Starting server, stand by..."
and then some other signal when we're 100% ready?
Thanks!

This issue has been moved to dart-lang/pub#831.


Disable web-preview for TextStyleProps example

Why
react-native-web does not support the deprecated Slider component causing the TextStyleProps example to fail with a React minified error upon loading the page.
As discussed here:
https://github.com/facebook/react-native-website/pull/2476#issuecomment-864892954
@Simek
before

after

How

Make example only available on ios and android

Why

See screenshot
Ran yarn prettier to verify the file doesn't contain any styling issues

Hi @IjzerenHein, thank you for catching this issue out and pushing the fix! 🙂

Your welcome :D


[question] KADhosts

Steven @StevenBlack  looking at the domain entries in the KADhosts lists probably 85% are Polish. Isn't better if it has own extension,this way anyone in Poland can use it and be more secure and for the rest of us(non Polish residents) have lighter lists.You yourself mentioned that are getting concerned about the size of the hosts file and the number of domains in it.It's more like suggestion then a question and hopefully you'll consider.Other,more useful hosts lists can be substitute (see #636 ) instead,in my opinion.Thanks.
P.S. That lists was last updated on Feb 20......doesn't look like it's been maintained very good....just saying...

Hi @dnmTX
KADHosts has been updated sixteen times in the past year.
I have no problem with KADhosts.
Closing.

@dnmTX, it's all about reliability and consistency over time. And personally even if it was 100% Polish, it's still making everyone safer. It would be great if we could have a specialist in every country.

@ScriptTiger  sure,at this point of view but me not browsing any Polish websites is just extra "weight" in my hosts file.I also realized how wrong i am to ask such a things(very selfish of me) when i can just modify it on my end cause this is something that i don't like,not the whole community here.Already found a solution,just waiting for @StevenBlack  to pull a PR and it will be perfect.Thanks for pitching in though 😋

Polish or not..


chore: improve Workflow overview deserialization to use the dataclass package

Introduced deserialization using the dataclass package
This package provides a standard clean solution for deserializing to immutable data objects

@jkilzi please review


Runs bug

What's this PR do?
Added missing setOffset to ReportbackTransformer.php and SignupTransformer.php to fix pagination issues.
Updates build function in Signup.php to only return drupal_id - the rest of the user information gets filled in by Northstar proxy.
How should this be manually tested?
Make sure that prev_uri and next_uri links return different data on each page for /signups and /reportbacks.
What are the relevant tickets?
Fixes #6373
Refs #6372 - fixes pagination error for this issue.

@weerd @DFurnes Working through this more, I think we'll need to still keep the $this->user business on the phoenix side because otherwise, in ns, we don't have access to the user if it's not returned in the results here.
In ns, I'm taking the results from hitting the phoenix endpoint, iterating through each one to get the user, find the user avatar image and append it to the user object.
Just want to run by you both quickly to make sure I'm not going down a rabbit hole! Please let me know if this makes sense to you both or if I'm overlooking something obvious!

@chloealee Ahhhh, yeah that makes sense. It may be best to remove all the fields aside from drupal_id then so that it's more clear that the user content gets re-written elsewhere?

@DFurnes smart - that makes sense!

Yep yep! Defs don't remove the user object on the Phoenix side. There's other things that need it, etc. Just getting rid of the user->photo or whatever should be fine, and then like you mention, having NS add that data and property :)

@weerd Do we have any services that aren't using the Northstar proxy for those endpoints? If not, I'd make a vote for not including those fields in the original Phoenix response and then replacing them on Northstar just so it's clear that they're coming from elsewhere.

@DFurnes I don't think there's any service using /signups without going via the proxy.
Which fields do you mean? I thought it's just the photo related one?

@weerd the user object also returns  'first_name', 'last_initial', and country in addition to photo and id. I think @DFurnes is suggesting to leave id (which I believe is the northstar id) and then just append all the rest into the user object coming from NS.

Oh gotcha! Yep yep. Thanks for clarifying @chloealee 💃

I think @DFurnes is suggesting to leave id (which I believe is the northstar id) and then just append all the rest into the user object coming from NS.

Yep! The reason I say that is so that there aren't two separate scenarios where first_name (or other fields) could be filled in with potentially different data (depending on where you hit the endpoint from).
If we only return user: { drupal_id: 123456 } on the response, I feel like it makes it a bit more clear that it's a "placeholder" for someone else down the line to fill-in the real user data in the response.

Cool. We'll likely need to update other endpoints that pull in the user info too. It'll probs just be an update to the user transformer :)

@weerd  - @DFurnes helped to refactor this to make sure nothing breaks! We just added drupal_id in the transformUser function in the Transformer. This way, nothing should change elsewhere and data just gets overridden by the northstar proxy.
This is all set for review whenever you get a chance @weerd !

Right-on! Checking now 💃

@DFurnes @weerd quick q! Trying to test and debug this and I'm not sure it's actually getting sent through to NS when I thought it already was hooked up - where does the NS proxy connect/come into play here?

@chloealee Northstar is the "proxy" for the request –– so clients would request https://northstar.dosomething.org/v1/signups and then Northstar would make the corresponding Phoenix API request on their behalf (and then make any modifications before/after the request)! So Phoenix never talks to Northstar here. :)

@DFurnes oooohhh that makes so much more sense, thank you for clarifying that! That's why when /signups testing on dev.dosomething.org, all user info isn't fully returned - mystery solved! Thank you!

@weerd going to merge the NS code  and then after would love to merge this! I tested with /reportbacks?load_user=true along with testing pagination and nothing broke on my local! Would you mind taking a final look for merge?

¡OLÉ!
:sheep: it!


torchaudio.pipelines.WAVLM encounted error: Mask shape should match input

🐛 Describe the bug
Bug: I tried to use "torchaudio.pipelines.WAVLM_BASE_PLUS", however, it suffered from an error: "RuntimeError: Mask shape should match input. mask: [384, 199, 199] input: [32, 12, 199, 199]".   Which only happens when using "with torch.no_grad():", it seems it enables the fast path and then crashes.
Sample Code:
import torchaudio
import torch
bundle = torchaudio.pipelines.WAVLM_BASE_PLUS
ssl_model = bundle.get_model()
ssl_model = ssl_model.cuda()
with torch.no_grad(): #without this, it works fine
    waveform = torch.rand(32, 4*16000)
    print(waveform.size())
    features, _ = ssl_model.extract_features(waveform.cuda())
    print(len(features))
    print(features[0].size())

Error:
return torch._native_multi_head_attention(
Traceback (most recent call last):
File "/data1/test_wavlm.py", line 9, in
features, _ = ssl_model.extract_features(waveform.cuda())
File "/data1//myve_torch2/lib/python3.9/site-packages/torchaudio/models/wav2vec2/model.py", line 84, in extract_features
x = self.encoder.extract_features(x, lengths, num_layers)
File "/data1//myve_torch2/lib/python3.9/site-packages/torchaudio/models/wav2vec2/components.py", line 525, in extract_features
return self.transformer.get_intermediate_outputs(x, attention_mask=masks, num_layers=num_layers)
File "/data1//myve_torch2/lib/python3.9/site-packages/torchaudio/models/wav2vec2/components.py", line 474, in get_intermediate_outputs
x, _ = layer(x, attention_mask)  # Ignore position_bias
File "/data1//myve_torch2/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/data1//myve_torch2/lib/python3.9/site-packages/torchaudio/models/wav2vec2/components.py", line 405, in forward
x, position_bias = self.attention(
File "/data1//myve_torch2/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/data1//myve_torch2/lib/python3.9/site-packages/torchaudio/models/wav2vec2/wavlm_attention.py", line 185, in forward
attn_output, _ = self.attention(
File "/data1//myve_torch2/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/data1//myve_torch2/lib/python3.9/site-packages/torch/nn/modules/activation.py", line 1144, in forward
return torch._native_multi_head_attention(
RuntimeError: Mask shape should match input. mask: [384, 199, 199] input: [32, 12, 199, 199]
Versions
Versions of relevant libraries:
[pip3] numpy==1.24.1
[pip3] pytorch-triton==2.1.0+e650d3708b
[pip3] torch==2.0.0
[pip3] torchaudio==2.0.1
[pip3] torchvision==0.15.1+cu118
[pip3] triton==2.0.0

The issue could be related with torch.nn.MultiheadAttention in PyTorch core, according to https://github.com/pytorch/pytorch/issues/97409