[ScrollResponder][Feature] Scroll to native handle only if handle is under the keyboard

As of now, ScrollResponder implements method to scroll native handle to the keyboard. Handle, usually, is a text input but it could be whatever component...
Current solution:
/**
   * This method should be used as the callback to onFocus in a TextInputs'
   * parent view. Note that any module using this mixin needs to return
   * the parent view's ref in getScrollViewRef() in order to use this method.
   * @param {any} nodeHandle The TextInput node handle
   * @param {number} additionalOffset The scroll view's top "contentInset".
   *        Default is 0.
   * @param {bool} preventNegativeScrolling Whether to allow pulling the content
   *        down to make it meet the keyboard's top. Default is false.
   */
  scrollResponderScrollNativeHandleToKeyboard: function(nodeHandle: any, additionalOffset?: number, preventNegativeScrollOffset?: bool) {
    this.additionalScrollOffset = additionalOffset || 0;
    this.preventNegativeScrollOffset = !!preventNegativeScrollOffset;
    UIManager.measureLayout(
      nodeHandle,
      ReactNative.findNodeHandle(this.getInnerViewNode()),
      this.scrollResponderTextInputFocusError,
      this.scrollResponderInputMeasureAndScrollToKeyboard
    );
  },

Issue with current solution:
Handle scrolls to bottom of the keyboard even if it's not covered by the keyboard itself. This looks very bad and causes unnecessary distraction.
Proposed solution:
What I propose is to implement very similar method which would measure handle's dimensions and it's Y position relative to viewport/screen (not "document", which might and ofter is higher than viewport/screen height) and scroll only if handle is under the keyboard. In order to to so, ScrollResponder has to retain scroll offset (content offset) in one of it's method.
// ScrollResponder.js
scrollResponderHandleScroll: function(e: Event) {
  this.state.observedScrollSinceBecomingResponder = true;
  this.props.onScroll && this.props.onScroll(e);
  // retain contentOffset
  this.contentOffset = e.nativeEvent.contentOffset;
},

// Expose method which solves the issue
scrollResponderScrollNativeHandleToKeyboardIfCovered: function(nodeHandle: any, additionalOffset?: number, preventNegativeScrollOffset?: bool) {
  this.additionalScrollOffset = additionalOffset || 0;
  this.preventNegativeScrollOffset = !!preventNegativeScrollOffset;
  UIManager.measureLayout(
    nodeHandle,
    ReactNative.findNodeHandle(this.getInnerViewNode()),
    this.scrollResponderTextInputFocusError,
    this.scrollResponderInputMeasureAndScrollToKeyboardIfCovered
  );
},

// Measure handle's position and decide whether to scroll or not to.
// Under the hood, original `scrollResponderInputMeasureAndScrollToKeyboard` method is used.
scrollscrollResponderInputMeasureAndScrollToKeyboardIfCovered(left: number, top: number, width: number, height: number) {
  var bottommostCoord = top + height - this.contentOffset.y;
  var keyboardScreenY = Dimensions.get('window').height;
  if (this.keyboardWillOpenTo) {
    keyboardScreenY = this.keyboardWillOpenTo.endCoordinates.screenY;
  }

  if (bottommostCoord - keyboardScreenY > 0) {
    // Use existing method to do measurements and scroll to handle to keyboard.
    this.scrollResponderInputMeasureAndScrollToKeyboard(left, top, width, height);
  }
},

Questions:
What I am not sure about is scrollResponderScrollNativeHandleToKeyboardIfCovered which is mostly copy-paste of scrollResponderScrollNativeHandleToKeyboard. The only difference is it's "on success" callback for UIManager.measureLayout call.

Should standalone scrollscrollResponderInputMeasureAndScrollToKeyboardIfCovered be implemented or in order to avoid almost 1:1 copy should scrollscrollResponderInputMeasureAndScrollToKeyboard accept one more argument?
If scrollscrollResponderInputMeasureAndScrollToKeyboard accepts one more argument wouldn't it be too many arguments (it's already too many to my taste)?
Is it possible for scrollscrollResponderInputMeasureAndScrollToKeyboard to break current API and have something like
scrollscrollResponderInputMeasureAndScrollToKeyboard(layout: Object, dontScrollIfNotCovered: boolean);
Or is it something you'd like to avoid?
do you have any better method naming in mind?

If we clear those questions and you are interested, I'd be happy to send PR.

Can you confirm if this is still an issue for you? I'm not able to replicate this on current master.

@chirag04 could you point me to recent updates of what changed, related to this issue? I've seen there is KeyboardAvoidingView available now, which could be used to shrink inner ScrollView. I am about to try that out...

Is there a way to get KeyboardAvoidingView to work with a TextInput that's inside a ScrollView?

@npomfret  Your best option there is https://github.com/APSL/react-native-keyboard-aware-scroll-view

@npomfret I use this: https://gist.github.com/chirag04/d7a7d58f4afc9520a51f511ce7f67788

@chirag04   It didn't work for me.

Closing this issue because it has been inactive for a while. If you think it should still be opened let us know why.


Fixes compiled file permissions

Fixes issue #4212 .

I did sign the CLA, but I don't know how can I ask GitHub to test again. Do I need to remove this PR and create another one?

I reran the CLA job.

Instead of using Files.setPosixFilePermissions after the fact, can't we create the files with the right permissions in the first place? It seems that createTempFile could accept that through the FileAttributes, through the asFileAttribute adapter.

Yes, it can be passed in createTempFile, but the docs on createTempFile state that it'll throw an exception if the attributes can't be set atomically when the file is created.
I thought calling setPosixFilePermissions separately would potentially cover systems that use POSIX permissions but can't set them atomically when creating a temp file.
If this is unnecessary, I'll just do the other way.

As for the guidelines, I'm sorry. I'll correct my pull request/code style according to them and create a new PR from the correct branch.


Prestashop

add same generation for pretashop as you did for wordpress and magento pelase)

I'm taking this.


Vue clickaway except spefic element

Hello there.My problem is that I have an input (search bar) ; onfocus another element where search results would appear is displayed and I attached the v-on-clickaway directive to this element.
Every time I click on the input(to type my search keywords), the search results element dissapears.So basically I want that element to not dissapear whenever I click the input or the search results element.
It is possible to achieve this functionality ?
Thank you.

Call event.stopPropagation() on the element that you want to exclude.

As @diakonovm said - you can use on your element:
e.g.
@click.stop

Thanks for the replies.Solved.

I have tried this solution but I'm using vue-flatpickr component and that one uses it's own internals.
For more context I am using clickaway for my filters container which contains a few filters
 <div v-on-clickaway="onClickAway"
      class="absolute block inset-auto right-0 top-full bg-white min-w-300px mt-2 z-20 shadow-context rounded-xl"
      v-if="open"
    >

onClickAway() {
      this.open = false
    },

One of the filters sets a date via flatpickr
<flat-pickr
      :name="filter.id"
      :id="filter.id"
      @on-change="changeFilter"
      ref="field-input"
      class="w-full"
      v-model="value"
      :config="flatpickrConfig"
      :placeholder="filter.filter_configuration.placeholder"
    />

For some reason I can click on days of this flatpickr, but when I click on prev/next month or month/year selector it closes the filters container
I can send a video for more context


Allow fastlane core to handle linux errors better

This replaces https://github.com/fastlane/fastlane/pull/3805 and should resolve https://github.com/fastlane/fastlane/issues/3821.  This adds the functionality back in, but not the test.  The test was flakey when run back-to-back which indicates a bug somewhere, but as it is very difficult to track down and not necessarily happening in the wild, this allows us to fix problems for Linux folks without diving too much further down that rabbit hole.

LGTM besides the style violation, and some questions about comments


Switch Cloud8 to use legacy ISO server (SOC-11466)

Recent changes to the mirroring policies for ibs-mirror.prv.suse.net
mean that it no longer mirrors the SLE 12 SP3 ISO that is needed by
the SOC 8 CLM cobbler (PXE Boot) re-imaging process.
I have manually setup a mirror of the necessary ISO on the legacy
CI artifacts server for Ardana, ardana.ci.prv.suse.net, with the
same directory hierarchy, so we can just switch the hostname in
the URL to fix this.
Also updated an occurrence of the old suse.provo.cloud version of
the name for the legacy CI artifacts server.

https://ci.suse.de/job/openstack-ardana/849/ kicked off to validate that this patch fixes the issues downloading the ISO... If it gets past the Prepare Environment stage, e.g. gets to Deploy Cloud or later, then this patch is working as intended ;-)

Why introduce another server? Can't we mirror it on clouddata?

Why introduce another server? Can't we mirror it on clouddata?

Jan, it was there but since SLES-12-SP3 is old they deleted it and this is an alternative from them deleting it once again in the future.

Why introduce another server? Can't we mirror it on clouddata?

Jan, it was there but since SLES-12-SP3 is old they deleted it and this is an alternative from them deleting it once again in the future.

https://chat.suse.de/channel/cloud-cicd?msg=8iFBYMDHBgtANB4dM

clouddata != ibs-mirror (here variable name sles_media_server). clouddata is maintained by us, ibs-mirror isn't. an ibs-mirror location is removed in this version of the patch. That chat conversation might be wrong, clouddata might not have had the isos before. But we could put it there, if we have an existing url in NUE where we can mirror the iso from we can add it in https://github.com/SUSE-Cloud/automation/blob/master/hostscripts/clouddata/syncSLErepos . Otherwise we can manually copy it there.

clouddata != ibs-mirror (here variable name sles_media_server). clouddata is maintained by us, ibs-mirror isn't. an ibs-mirror location is removed in this version of the patch. That chat conversation might be wrong, clouddata might not have had the isos before. But we could put it there, if we have an existing url in NUE where we can mirror the iso from we can add it in https://github.com/SUSE-Cloud/automation/blob/master/hostscripts/clouddata/syncSLErepos . Otherwise we can manually copy it there.

So per the discussion about this last week, the clouddata mirroring process, as implemented in syncSLErepos, is mirroring ISO content rather than the ISOs themselves, and I think only Ardana requires the SLE ISOs to be available like this, so we only really need this to support Ardana. Changing syncSLErepos to mirror the repos is more than just a one liner change that had previously been suggested because we actually need the SLE ISO images, not the Cloud ISO images, and not just their content. And given what just happened there is no guarantee that the same situation won't arise at a future date if we rely on the mirroring process.
The ardana.ci.prv.suse.net virtual host is served by static.ci.prv.suse.net, which is a key part of the legacy CI that is required to exist to support HOS CI build process, which has to remain functional until August/September 2022, and is backed by a support contracted 3Par, and thus should be a pretty safe bet to keep running until we no longer need it... Additionally the legacy artifact server is setup such that all published files are immutable so no risk of accidental deletions. And, finally, it was already serving the required SLE 12 SP3 ISO anyway, as part of the initial Ardana rebranding/Cloud8 CLM development process, so serving the files to the ECP CI is not a significant extra burden.
And thus this approach represents a minimal change to SUSE-Cloud/automation to get the cobbler/PXEboot working again... Additionally I've already setup the SLE 12 SP4 ISOs to be served by ardana.ci.prv.suse.net as well, so that we can potentially switch Cloud9 settings to use this source as well if we decide too, or the need arises.
So in summary, yes we could change syncSLErepos to do what is needed, but it would entail more than just the one line change that this patch implements to fix the problem, which is fundamentally breaking this aspect of the ECP CI workflow for Ardana testing right now.
And whichever approach we take will require about the same amount of effort to address the impact of this breakage in ardana/ardana-dev-tools, which I will be doing as well, so from, my perspective, opting for the minimal overall change to the systems and code bases involved makes the most sense.
If you feel that it should be handled by syncSLErepos, or by manually setting up provo-clouddata.cloud.suse.de to serve the ISOs, feel free to implement the necessary changes to either the script or the system itself, and propose the necessary changes.

While it might be planned to switch HOS8 CI off after 2022, that is not true for SOC8 CI. But it can be changed again then.
I'm not against merging this.

@JanZerebecki IIUC, around the same time the HOS 8 CI contract ends, the Provo systems "move/decommission" will happen so any on-going SOC 8 CI will likely need TLC to get it working on the moved/replacement environment, wherever that may end up being.


Fixed exporters to support features

Unified how resources are loaded into the configuration system (Config.load_resources) and applied to bith build_api and exporters

@mbed-bot: TEST
HOST_OSES=windows
BUILD_TOOLCHAINS=GCC_ARM,ARM,IAR
TARGETS=K64F,KL25Z

@mbed-bot: TEST
HOST_OSES=windows
BUILD_TOOLCHAINS=GCC_ARM,ARM,IAR
TARGETS=K64F,KL25Z

LGTM

Tests results are good .
+1

@mbed-bot: TEST
HOST_OSES=windows
BUILD_TOOLCHAINS=GCC_ARM,ARM,IAR
TARGETS=K64F,KL25Z


istioctl controlz dashboard UI shows errors in subpage

Bug description
istioctl controlz dashboard UI shows error in subpage  'Process Info' and 'Version Info'
Expected behavior
display the correct debug info in 'Process Info' and 'Version Info' sub page
Steps to reproduce the bug

install the istio 1.5 release version
install the bookinfo demo
exec cmd: istioctl dashboard controlz istiod-.istio-system
open web browser and navigate to 'http://localhost:9876/', click the 'Process Info' or  'Version Info' sub menu
you will get error messge as below:
template: base:28:18: executing "content" at <.User>: can't evaluate field User in type *version.BuildInfo

Version (include the output of istioctl version --remote and kubectl version and helm version if you used Helm)
client version: 1.5.0
egressgateway version: 1.5.0
ingressgateway version: 1.5.0
pilot version: 36d71286472022e5d49cd8f404a86f163086b310-dirty
data plane version: 1.5.0 (9 proxies)
How was Istio installed?
follow the release 1.5 release doc with demo profile
Environment where bug was observed (cloud vendor, OS, etc)
Ubuntu 18.04

The fix PR is created here

This is a duplicate of https://github.com/istio/istio/issues/21342

The PR is merged and this issue can be closed.


Import on execute

Description
airflow: only import ML libs on execute
Resolve (we hope) a persistent issue and cause of incidents:
import time for DAGs takes an unreliably bounded amount of time,
resulting in Airflow's web UI raising an AirflowTaskTimeout
(which isn't really for a task at all...but oh well). Key changes:

Add a library for safely importing modules from within Airflow
task execute() methods.
Move heavy imports for all ML tasks into their execute() methods.

Also fix a typo in airflow.tasks.es_index_publications.
https://github.com/wellcometrust/policytool/issues/194
https://github.com/wellcometrust/datalabs-infra/issues/203
https://github.com/wellcometrust/datalabs-infra/issues/209
Type of change

[x] :bug: Bug fix (Add Fix #(issue) to your PR)

How Has This Been Tested?

make docker-test.
Ran test DAG locally.
Manually verified exceptions raise by running thread w/time.sleep() and then trying to enter the safe_import() context a second time.

Checklist:

[x] My code follows the style guidelines of this project (pep8 AND pyflakes)
[x] I have commented my code, particularly in hard-to-understand areas
[ ] New and existing unit tests pass locally with my changes
[x] If my PR aims to fix an issue, I referenced it using #(issue)

OK! tests are passing locally after long download b/c of one additional commit, upgrading jinja..!


Insufficient budget for bandwidth when downloading a small file

Describe the bug
Downloading of large files (10+MB) runs without issues. The issue occurs when I try to download a small file (12KB).
Expected behaviour
Able to download files of any size.
Additional context
The file was uploaded with upload packing disabled.
General Information
Are you running a fork of renterd? A fork synced to origin/master on September 21.
Are you on the mainnet or on the testnet? Mainnet.
Renterd Config
Please provide us the following information:
Autopilot Config
	"contracts": {
		"set": "autopilot",
		"amount": 20,
		"allowance": "1000000000000000000000000000",
		"period": 1008,
		"renewWindow": 302,
		"download":<PHONE_NUMBER>00,
		"upload":<PHONE_NUMBER>0,
		"storage":<PHONE_NUMBER>0
	},
	"hosts": {
		"allowRedundantIPs": false,
		"maxDowntimeHours": 1440,
		"scoreOverrides": null
	},
	"wallet": {
		"defragThreshold": 1000
	}
}

Bus Config
	"minShards": 3,
	"totalShards": 9
}

{
	"hostBlockHeightLeeway": 6,
	"maxContractPrice": "1000000000000000000000000",
	"maxDownloadPrice": "1200000000000000000000000000",
	"maxRPCPrice": "1000000000000000000000",
	"maxStoragePrice": "69444444444",
	"maxUploadPrice": "100000000000000000000000000",
	"minAccountExpiry":<PHONE_NUMBER>0000,
	"minMaxCollateral": "10000000000000000000000000",
	"minMaxEphemeralAccountBalance": "1000000000000000000000000",
	"minPriceTableValidity":<PHONE_NUMBER>00
}

Contract Set Contracts
20
Renterd Logs
2023-09-25T15:30:06+02:00	ERROR	downloadmanager	worker/download.go:332	download slab 0 failed: failed to download slab: completed=2, inflight=0, launched=9 downloaders=37 unused=0 errors=
aaf5aa89: ReadSector: ReadResponse: couldn't read subscription response: insufficient budget for bandwidth
74e99212: ReadSector: ReadResponse: couldn't read subscription response: insufficient budget for bandwidth
ab49fe30: ReadSector: ReadResponse: couldn't read subscription response: insufficient budget for bandwidth
6b4b7117: ReadSector: ReadResponse: couldn't read subscription response: insufficient budget for bandwidth
e534d338: ReadSector: ReadResponse: couldn't read subscription response: insufficient budget for bandwidth
23b0ee17: ReadSector: ReadResponse: couldn't read subscription response: insufficient budget for bandwidth
54a37a9c: ReadSector: ReadResponse: couldn't read subscription response: insufficient budget for bandwidth

This was actually on my radar, we will get this fixed asap, thanks for reporting @mike76-dev


Download exclusion flag

There are some modules which don't exist anymore or not at all for the client which can be selected on the download page, resulting in a failed download.
It would probably make sense to add a flag to exclude them from the download page, similar to the recommended flag.
https://github.com/prebid/prebid.github.io/blob/master/dev-docs/modules/consentManagement.md?plain=1#L9
Missing client modules I know of:

triplelift_nativeBidAdapter
pairIdSystem
openxoutstreamBidAdapter

Oh, looks like there already is one: https://github.com/prebid/prebid.github.io/blob/master/dev-docs/modules/consentManagement.md?plain=1#LL8C1-L8C16


Code reloading

Resolves: #37
Needs an fs watcher compatible backend to work.
See: https://github.com/synrc/fs#backends

Coverage increased (+1.001%) to 86.076% when pulling 34e0e02dc49b618fea2ffc97f6bb340df16f81e7 on code-reloading into f129784d09c8f912c8705f3ba942ba415c086325 on master.

Coverage increased (+0.7%) to 85.774% when pulling 34a37e30563755e4e4dea021b76d58a247438977 on code-reloading into f129784d09c8f912c8705f3ba942ba415c086325 on master.

Coverage increased (+1.1%) to 86.192% when pulling 4baa3b9c7912f525e97a4caf40c440d693d19a32 on code-reloading into f129784d09c8f912c8705f3ba942ba415c086325 on master.

Coverage increased (+1.1%) to 86.192% when pulling 0a2611e5521b3b32afa6a99c617e08a99f3613b3 on code-reloading into f129784d09c8f912c8705f3ba942ba415c086325 on master.

Coverage increased (+1.1%) to 86.192% when pulling 58ec9ade083f59b5075019813d5ce310bf189819 on code-reloading into f129784d09c8f912c8705f3ba942ba415c086325 on master.


Update spdlog

Attaching some logs displaying backtraces:
mainlog.log
ptylog.log
sharedlog.log
wbenchlog.log
This is with process reuse enabled on a Mac.

very likely duplicate of https://github.com/microsoft/vscode/issues/103124, at that time spdlog seemed like a culprit and we wanted to update it to a newer version but didn't get to it. Also we don't have spdlog in the renderer anymore, but to rule its effect out

Compare the thread states
Update spdlog dep to latest https://github.com/microsoft/node-spdlog

Updating this to a debt task, because even after commenting out spdlog while testing #121513, I still see freezing at times. I wouldn't be surprised if the freezing came from the interaction between the render process and extension host.


My First edit

Contains info about the name Powerslave.

\m\

High hopes

hbjegbtfgjlen'

?

?


Adding a reusable typography component

Following the discussion in #315 and with some inspiration from #11. The idea is to not only have the typography in the introduction of the docs as inspiration, but having a reusable typography component that implements these styles, can be used across the project and be installed with npx shadcn-ui typography
After having run in this issue multiple times myself, i created the code for typography component that exactly mimics the styles from https://ui.shadcn.com/docs/components/typography plus added 'text-foreground' or 'text-muted-foreground' to also enable dark mode.
Ps: this is my first ever contribution to an open source project, so be gentle :)

@armandsalle thanks for the feedback, appreciate it a lot! Were you thinking something like this? Just added the changes you proposed. Will start working on the documentation.
Not sure though if this is the most elegant way to do it Typography element='h1' as='h1>Example</Typography> feels a lot more clunky than
Example. Any thoughts on this?

Hey! I was reading the CVA documentation and I saw this example of  polymorphic components
-- // A familiar `styled` button as a link
-- <Button as="a" href="#" variant="primary">Button as a link</Button>

++ // A `cva` button as a link
++ Button as a link

in https://cva.style/docs/faqs
So why not just export classnames? No more need for the createElement() function

Any updates on this?

So far, it works like a charm. Thank you @nilaq !

Agree with @armandsalle
Exporting typographyVariants({...}) is more than enough

import * as React from "react";
import { VariantProps, cva } from "class-variance-authority";
import cn from "utils/cn";

const typographyVariants = cva("text-foreground", {
  variants: {
    variant: {
      h1: "scroll-m-20 text-4xl font-extrabold tracking-tight lg:text-5xl",
      h2: "scroll-m-20 border-b pb-2 text-3xl font-semibold tracking-tight first:mt-0",
      h3: "scroll-m-20 text-2xl font-semibold tracking-tight",
      h4: "scroll-m-20 text-xl font-semibold tracking-tight",
      h5: "scroll-m-20 text-lg font-semibold tracking-tight",
      h6: "scroll-m-20 text-base font-semibold tracking-tight",
      p: "leading-7 [&:not(:first-child)]:mt-6",
      blockquote: "mt-6 border-l-2 pl-6 italic",
      ul: "my-6 ml-6 list-disc [&>li]:mt-2",
      inlineCode:
        "relative rounded bg-muted px-[0.3rem] py-[0.2rem] font-mono text-sm font-semibold",
      lead: "text-xl text-muted-foreground",
      largeText: "text-lg font-semibold",
      smallText: "text-sm font-medium leading-none",
      mutedText: "text-sm text-muted-foreground",
    },
  },
});

type VariantPropType = VariantProps<typeof typographyVariants>;

const variantElementMap: Record<
  NonNullable<VariantPropType["variant"]>,
  string
> = {
  h1: "h1",
  h2: "h2",
  h3: "h3",
  h4: "h4",
  h5: "h5",
  h6: "h6",
  p: "p",
  blockquote: "blockquote",
  inlineCode: "code",
  largeText: "div",
  smallText: "small",
  lead: "p",
  mutedText: "p",
  ul: "ul",
};

type Element = keyof JSX.IntrinsicElements;

type TypographyProps<T extends Element> = {
  as?: T;
} & VariantPropType &
  React.HTMLAttributes<HTMLElement>;

const Typography = <T extends Element>({
  className,
  as,
  variant,
  ...props
}: TypographyProps<T>) => {
  const Component =
    as ?? (variant ? variantElementMap[variant] : undefined) ?? "div";

  const componentProps = {
    className: cn(typographyVariants({ variant, className })),
    ...props,
  };

  return React.createElement(Component, componentProps);
};

export default React.forwardRef(Typography);

This one an update with ref
import * as React from "react";
import {VariantProps, cva} from "class-variance-authority";
import {cn} from "@/lib/utils"
import {Slot} from "@radix-ui/react-slot";

const typographyVariants = cva("text-foreground", {
    variants: {
        variant: {
            h1: "text-6xl scroll-m-20 font-bold",
            h2: "text-5xl scroll-m-20 font-bold",
            h3: "text-4xl scroll-m-20 font-bold",
            h4: "text-3xl scroll-m-20 font-bold",
            h5: "text-2xl scroll-m-20 font-bold",
            h6: "text-xl scroll-m-20 font-bold",
            p: "leading-7 [&:not(:first-child)]:mt-6",
            blockquote: "mt-6 border-l-2 pl-6 italic",
            ul: "my-6 ml-6 list-disc [&>li]:mt-2",
            inlineCode:
                "relative rounded bg-muted px-[0.3rem] py-[0.2rem] font-mono text-sm font-semibold",
            lead: "text-xl text-muted-foreground",
            regularText: "text-base",
            largeText: "text-lg font-semibold",
            smallText: "text-sm leading-none",
            mutedText: "text-sm text-muted-foreground",
        },
        weight: {
            bold: '!font-bold',
            semibold: '!font-semibold',
            normal: '!font-normal',
            medium: '!font-medium',
            light: '!font-light'
        }
    },
    defaultVariants: {
        variant: "regularText",
        weight: "normal",
    },
});

type VariantPropType = VariantProps<typeof typographyVariants>;

const variantElementMap: Record<
    NonNullable<VariantPropType["variant"]>,
    string
> = {
    h1: "h1",
    h2: "h2",
    h3: "h3",
    h4: "h4",
    h5: "h5",
    h6: "h6",
    p: "p",
    blockquote: "blockquote",
    inlineCode: "code",
    largeText: "div",
    regularText: "div",
    smallText: "small",
    lead: "p",
    mutedText: "p",
    ul: "ul",
};

export interface TypographyProps
    extends React.HTMLAttributes<HTMLElement>,
        VariantProps<typeof typographyVariants> {
    asChild?: boolean
    as?: string
}

const Typography = React.forwardRef<HTMLElement, TypographyProps>(
    ({className, variant, weight, as, asChild, ...props}, ref) => {
        const Comp = asChild ? Slot : as ?? (variant ? variantElementMap[variant] : undefined) ?? "div"
        return (
            <Comp
                className={cn(typographyVariants({variant, weight, className}))}
                ref={ref}
                {...props}
            />
        )
    }
)

Typography.displayName = "Typography"

export {Typography, typographyVariants}

Been this using the latest version and has a great developer experience would be awesome to see this part of the repo 🥇

any progress here? I'm available to finish this if @shadcn is interested in merge this.

I really like where this is going!  I just spend the last couple evenings eventually getting to something very similar!

I additionally decided to create some semantic/wrapper components (Heading, Text, etc.) on top of the Typography component.  I decided this after looking at what it looks like using the same "base" Typography component for everything (I didn't love it), as well as looking into other UI component libraries were doing  and seeing them be more semantic (e.g. Radix UI, etc.).

Semantic vs Non-Semantic

      {/* Semantic */}

        <Heading variant="h1">Heading 1</Heading>
        <Heading variant="h2">Heading 2</Heading>
        <Heading variant="h3">Heading 3</Heading>
        <Heading variant="h4">Heading 4</Heading>
        <Heading variant="h5">Heading 5</Heading>
        <Heading variant="h6">Heading 6</Heading>
        <Text variant="lead">This is a lead paragraph.</Text>
        <Text variant="large">This is large text.</Text>
        <Text variant="muted">This is muted text.</Text>
        <Text variant="p">This is a paragraph.</Text>
        <Text>This is a paragraph (without a variant prop).</Text>
        <Text>
          This is a paragraph with em.
        </Text>
        <Text>
          This is a paragraph with strong.
        </Text>
        <Text>
          This is a paragraph with small.
        </Text>

This is a blockquote.

        This is inline code.

      {/* Non-semantic */}

        <Typography variant="h1" gutterBottom>
          Heading 1
        </Typography>
        <Typography variant="h2">Heading 2</Typography>
        <Typography variant="h3">Heading 3</Typography>
        <Typography variant="h4">Heading 4</Typography>
        <Typography variant="h5">Heading 5</Typography>
        <Typography variant="h6">Heading 6</Typography>
        <Typography variant="p">This is a paragraph.</Typography>
        <Typography>This is a paragraph (without a variant prop).</Typography>
        <Typography variant="lead">This is a lead paragraph.</Typography>
        <Typography variant="large">This is large text.</Typography>
        <Typography variant="muted">This is muted text.</Typography>
        <Typography variant="blockquote">This is a blockquote.</Typography>
        <Typography variant="code">This is inline code.</Typography>

I adapted my semantic components to now use the "base" typography component that you guys have come up with, instead of my own.
To more easily create semantic components, I added a couple additions to the "base" typography component (could use some renaming):
// typography.tsx

...

type TypographyVariantType = NonNullable<
  VariantProps<typeof typographyVariants>["variant"]
>

interface VariantPropsTypographyWithoutVariant
  extends Omit<VariantProps<typeof typographyVariants>, "variant"> {
  asChild?: boolean;
}

...

export type { VariantPropsTypographyWithoutVariant, TypographyVariantType };

I also created FilterUnionType to filter down the TypographyVariantType in individual semantic components based on what I wanted each to have available to them (while also keeping them connected to the "base" Typography component):
// Helper type to filter union types
export type FilterUnionType<T, U> = T extends U ? T : never;

Some of my semantic components:

Heading (heading.tsx)
import React from "react";
import type { FilterUnionType } from "@/lib/types";
import {
  Typography,
  type VariantPropsTypographyWithoutVariant,
  type TypographyVariantType,
} from "./typography";

// Specify the variants you want to allow (linting error will be thrown when using exported component with a variant (1) not specified here or (2) not within TypographyVariant)
type AllowedVariants = FilterUnionType<
  TypographyVariantType,
  "h1" | "h2" | "h3" | "h4" | "h5" | "h6"
>;
type HTMLTypographyElement = HTMLHeadingElement;

interface HeadingProps
  extends React.HTMLAttributes<HTMLTypographyElement>,
    VariantPropsTypographyWithoutVariant {
  variant: AllowedVariants;
}

const Heading = React.forwardRef<HTMLTypographyElement, HeadingProps>(
  ({ variant, ...props }, ref) => {
    return <Typography ref={ref} variant={variant} {...props} />;
  },
);

export default Heading;

Text (text.tsx)
import React from "react";
import type { FilterUnionType } from "@/lib/types";
import {
  Typography,
  type VariantPropsTypographyWithoutVariant,
  type TypographyVariantType,
} from "./typography";

// Specify the variants you want to allow (linting error will be thrown when using exported component with a variant (1) not specified here or (2) not within TypographyVariant)
type AllowedVariants = FilterUnionType<
  TypographyVariantType,
  "p" | "lead" | "largeText" | "mutedText" // ...smallText, etc.
>;
type HTMLTypographyElement = HTMLParagraphElement;

interface TextProps
  extends React.HTMLAttributes<HTMLTypographyElement>,
    VariantPropsTypographyWithoutVariant {
  variant?: AllowedVariants;
}

const Text = React.forwardRef<HTMLTypographyElement, TextProps>(
  ({ variant, ...props }, ref) => {
    return (
      <Typography
        ref={ref}
        variant={variant}
        {...props}
      />
    );
  },
);

export default Text;

Blockquote (blockquote.tsx)
import React from "react";
import {
  Typography,
  type VariantPropsTypographyWithoutVariant,
  type TypographyVariantType,
} from "./typography";
import type { FilterUnionType } from "@/lib/types";

// Specify the variants you want to allow (linting error will be thrown when using exported component with a variant (1) not specified here or (2) not within TypographyVariant)
type AllowedVariants = FilterUnionType<TypographyVariantType, "blockquote">;
type HTMLTypographyElement = HTMLQuoteElement;

export interface BlockquoteProps
  extends React.HTMLAttributes<HTMLTypographyElement>,
    VariantPropsTypographyWithoutVariant {
  variant?: AllowedVariants;
}

const Blockquote = React.forwardRef<HTMLTypographyElement, BlockquoteProps>(
  ({ variant = "blockquote", ...props }, ref) => {
    return <Typography ref={ref} variant={variant} {...props} />;
  },
);

export default Blockquote;

Code (code.tsx)
import React from "react";
import {
  Typography,
  type VariantPropsTypographyWithoutVariant,
  type TypographyVariantType,
} from "./typography";
import type { FilterUnionType } from "@/lib/types";

// Specify the variants you want to allow (linting error will be thrown when using exported component with a variant (1) not specified here or (2) not within TypographyVariant)
type AllowedVariants = FilterUnionType<TypographyVariantType, "inlineCode">;
type HTMLTypographyElement = React.ElementRef<"code">; // using React.ElementRef<"code"> instead of HTMLXElement because HTMLCodeElement is not a valid HTML element

interface CodeProps
  extends React.HTMLAttributes<HTMLTypographyElement>,
    VariantPropsTypographyWithoutVariant {
  variant?: AllowedVariants;
}

const Code = React.forwardRef<HTMLTypographyElement, CodeProps>(
  ({ variant = "inlineCode", ...props }, ref) => {
    return <Typography ref={ref} variant={variant} {...props} />;
  },
);

export default Code;

...I also started creating some "other" typography-related elements (elements that are supposed to exist within other typography elements, etc.) (again, similarly to Radix UI).  Structurally, they are a bit of a mix of shadcn and Radix UI:

Em (em.tsx)
import { cn } from "@/lib/utils";
import { type VariantProps, cva } from "class-variance-authority";
import * as React from "react";

const emVariants = cva("italic", {
  variants: {
    variant: {
      default: "",
    },
  },
  defaultVariants: {
    variant: "default",
  },
});

type EmElement = React.ElementRef<"em">;
export interface EmProps

  extends React.ComponentPropsWithoutRef<"em">,
    VariantProps<typeof emVariants> {
  asChild?: boolean;
}

const Em = React.forwardRef<EmElement, EmProps>(
  ({ children, className, variant, ...props }, ref) => (

      {children}

  ),
);
Em.displayName = "Em";

export default Em;

Strong (strong.tsx)
import { cn } from "@/lib/utils";
import { type VariantProps, cva } from "class-variance-authority";
import * as React from "react";

const strongVariants = cva("strong", {
  variants: {
    variant: {
      default: "",
    },
  },
  defaultVariants: {
    variant: "default",
  },
});

type StrongElement = React.ElementRef<"strong">;
export interface StrongProps
  // extends React.HTMLAttributes<HTMLTypographyElement>,
  extends React.ComponentPropsWithoutRef<"strong">,
    VariantProps<typeof strongVariants> {
  asChild?: boolean;
  as?: string;
}

const Strong = React.forwardRef<StrongElement, StrongProps>(
  ({ children, className, variant, ...props }, ref) => (

      {children}

  ),
);
Strong.displayName = "Strong";

export default Strong;

Small (small.tsx)
import { cn } from "@/lib/utils";
import { type VariantProps, cva } from "class-variance-authority";
import * as React from "react";

const strongVariants = cva("small", {
  variants: {
    variant: {
      default: "",
    },
  },
  defaultVariants: {
    variant: "default",
  },
});

type SmallElement = React.ElementRef<"small">;
export interface SmallProps
  // extends React.HTMLAttributes<HTMLTypographyElement>,
  extends React.ComponentPropsWithoutRef<"small">,
    VariantProps<typeof strongVariants> {
  asChild?: boolean;
}

const Small = React.forwardRef<SmallElement, SmallProps>(
  ({ children, className, variant, ...props }, ref) => (

      {children}

  ),
);
Small.displayName = "Small";

export default Small;

I would love to hear your input!
Overall, I'm new to shadcn and I was just starting to go over the documentation and truly use it for the first time, but I got to the Typography section and went down this rabbit hole lol.  I'm coming from using MUI for the last couple years, so... I may have gotten a bit excited about the semantic components (MUI = non-semantic Typography component for everything)

`import * as React from "react";
import Link, { LinkProps } from "next/link";
import { Slot } from "@radix-ui/react-slot";
import { VariantProps, cva } from "class-variance-authority";
import { cn } from "@/lib/utils/cn";
const typographyVariants = cva("text-foreground", {
variants: {
variant: {
a: "",
abbr: "",
b: "",
strong: "",
cite: "",
code: "",
em: "",
i: "",
sub: "",
sup: "",
u: "",
var: "",
p: "",
h1: "",
h2: "",
h3: "",
h4: "",
h5: "",
h6: "",
div: "",
span: "",
blockquote: "",
ul: "",
ol: "",
li: "",
large: "",
small: "",
lead: "",
muted: "",
},
},
});
type VariantPropType = VariantProps;
const excludedVariants = ["a", "large", "lead", "muted"] as const;
type TypographyProps =
| (React.HTMLAttributes &
VariantPropType &
LinkProps & {
as: "a";
asChild?: boolean;
})
| (React.HTMLAttributes &
VariantPropType & {
as?: Exclude<
VariantPropType["variant"],
(typeof excludedVariants)[number]
>;
href?: never;
asChild?: boolean;
});
const Typography = React.forwardRef<HTMLElement, TypographyProps>(
({ className, variant, as, href, asChild, ...props }, ref) => {
const Component = asChild
? Slot
: as === "a"
? Link
: (as as React.ElementType) ||
(excludedVariants.includes(
variant as (typeof excludedVariants)[number],
)
? "p"
: variant) ||
"p";
return (
  <Component
    className={cn(typographyVariants({ variant, className }))}
    ref={ref}
    {...props}
    href={as === "a" ? href : undefined}
  />
);

},
);
Typography.displayName = "Typography";
export { Typography, typographyVariants };
`
Add your styles.

import * as React from "react";
import Link, { LinkProps } from "next/link";
import { Slot } from "@radix-ui/react-slot";
import { VariantProps, cva } from "class-variance-authority";
import { cn } from "@/lib/utils/cn";

const typographyVariants = cva("text-foreground", {
  variants: {
    variant: {
      a: "",
      abbr: "",
      b: "",
      strong: "",
      cite: "",
      code: "",
      em: "",
      i: "",
      sub: "",
      sup: "",
      u: "",
      var: "",
      p: "",
      h1: "",
      h2: "",
      h3: "",
      h4: "",
      h5: "",
      h6: "",
      div: "",
      span: "",
      blockquote: "",
      ul: "",
      ol: "",
      li: "",
      large: "",
      small: "",
      lead: "",
      muted: "",
    },
  },
});

type VariantPropType = VariantProps<typeof typographyVariants>;

const excludedVariants = ["a", "large", "lead", "muted"] as const;

type TypographyProps =
  | (React.HTMLAttributes<HTMLElement> &
      VariantPropType &
      LinkProps & {
        as: "a";
        asChild?: boolean;
      })
  | (React.HTMLAttributes<HTMLElement> &
      VariantPropType & {
        as?: Exclude<
          VariantPropType["variant"],
          (typeof excludedVariants)[number]
        >;
        href?: never;
        asChild?: boolean;
      });

const Typography = React.forwardRef<HTMLElement, TypographyProps>(
  ({ className, variant, as, href, asChild, ...props }, ref) => {
    const Component = asChild
      ? Slot
      : as === "a"
        ? Link
        : (as as React.ElementType) ||
          (excludedVariants.includes(
            variant as (typeof excludedVariants)[number],
          )
            ? "p"
            : variant) ||
          "p";

    return (
      <Component
        className={cn(typographyVariants({ variant, className }))}
        ref={ref}
        {...props}
        href={as === "a" ? href : undefined}
      />
    );
  },
);

Typography.displayName = "Typography";

export { Typography, typographyVariants };

Add your styles. 👍

Adding my 2 cents on this which would allow for an api similar to MUI being
<Typography variant="h1">Hello World</Typography>; // renders as H1 by default
<Typography variant="h1" component='h2'>Hello World</Typography>; // renders as H2

While the code might seem like a-lot most if not all has been copied from MUI
import { cva, cx, VariantProps } from<EMAIL_ADDRESS>
type DistributiveOmit<T, K extends keyof any> = T extends any ? Omit<T, K> : never;

type OverrideProps<TProps, TComponent extends React.ElementType> = TProps &
  DistributiveOmit<React.ComponentPropsWithRef<TComponent>, keyof TProps>;

interface OverrideAbleComponentFC<TDefaultComponent extends React.ElementType, TProps> {
  <TComponent extends React.ElementType = TDefaultComponent>(
    props: {
      component?: TComponent;
    } & OverrideProps<TProps, TComponent>
  ): JSX.Element | null;
  displayName?: string;
}

export interface TypographyProps extends React.PropsWithChildren, VariantProps<typeof variants> {
  className?: string;
}

const variants = cva({
  variants: {
    variant: {
      h1: 'scroll-m-20 text-4xl font-bold text-primary-dark lg:text-5xl',
      h2: 'mt-10 scroll-m-20 pb-2 text-3xl font-bold text-primary-dark first:mt-0 lg:text-4xl',
      h3: 'mt-8 scroll-m-20 text-2xl font-bold text-primary-dark',
      h4: 'mt-6 scroll-m-20 text-xl font-bold text-primary-dark',
      p: 'leading-7 [&:not(:first-child)]:mt-4',
      large: 'text-xl',
    },
  },
  defaultVariants: {
    variant: 'p',
  },
});

const variantComponent = cva({
  variants: {
    variant: {
      h1: 'h1',
      h2: 'h2',
      h3: 'h3',
      h4: 'h4',
      p: 'p',
      large: 'div',
    },
  },
  defaultVariants: {
    variant: 'p',
  },
});

export const Typography: OverrideAbleComponentFC<'p', TypographyProps> = ({
  children,
  className,
  component,
  variant = 'p',
}) => {
  const Component = component || variantComponent({ variant });

  return <Component className={cx(variants({ variant, className }))}>{children}</Component>;
};

Up :)

@amocarski updated to include the missing 'use client' thanks for noticing 🙏

Hey guys, any idea when this component will be released?

I implemented it in my app, but we lack support for dynamic responsiveness IMHO.
I'll give an example - if you have you want to show a title that need to have different styles attched to it depeneds on screen size you are ending up using this kind of code:

    Repeated Title

    Repeated Title

Especially when using RSC where you cannot use isMobile hook. I thought it could be nice to expand the typographyVariants API to allow multiple variants, something like:
     const prefixClasses = (classes: string, prefix: string) =>
  classes.split(' ').map(cls => `${prefix}:${cls}`).join(' ');

const variants = {
  h1: 'text-xl scroll-m-20 font-bold tracking-[-0.36px] text-balance',
  h2: 'font-bold scroll-m-20 text-lg leading-[120%] text-balance',
  // ... other variants
} as const;

const typographyVariants = cva('text-foreground', {
  variants: {
    variant: variants,
    mdVariant: Object.entries(variants).reduce(
      (acc, [key, value]) => ({
        ...acc,
        [key]: prefixClasses(value, 'md')
      }),
      {} as Record<keyof typeof variants, string>
    ),
  },
});

and then use it like this:

   Title

This is not working completely as we need a more smart solution to not pass the mobile styles into the desktop.


Bump up version to v0.4.0.

Codecov Report

Merging #17 (40d7e52) into main (98510fd) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main      #17   +/-   ##
=======================================
  Coverage   86.40%   86.40%
=======================================
  Files          28       28
  Lines         765      765
=======================================
  Hits          661      661
  Misses        104      104

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.


Add "Scroll Down Progress Bar" for Enhanced Navigation

What would you like to share?
Hey @punyakrit

The website would benefit from the addition of a scroll-down progress bar that appears on all pages, particularly useful for longer pages such as "Contributors".
This feature will enhance user navigation by providing a visual indicator of their progress through the content.

Like This:

Could you please assign this issue to me under GSSOC 24?
Additional information
N/A
Record

[X] I agree to follow this project's Code of Conduct
[X] I'm a GSSOC'24 contributor
[X] I want to work on this issue

dont require for now as ui is pretty simple


Always declare access modifier public

https://github.com/Dayver3/blog/blob/74d31977693388c9827764144fb0eca3440b9c62/src/application/controllers/LoginController.php#L5

done


chore(promotheus): add how to create Prometheus instance in README

There is  introduction how to deploy prometheus-operator by helm in README.md, but no introduction about how to create a Prometheus instance

The kube-prometheus-stack creates one for us. Do we really need it?🤔


TypeError: Cannot read property 'length' of undefined

Good day,
i believe there is a bug in the convert function:
node: 8.11.2
excel: 0.1.7
excel-as-json: 2.0.2
  convert = function(data, options) {
    // console.log(data);
    var index, item, j, k, keys, len, len1, result, row, rows, value;
    if (options.isColOriented) {
      data = transpose(data);
    }
    keys = data[0];
    rows = data.slice(1);
    result = [];
    for (j = 0, len = rows.length; j < len; j++) {
      row = rows[j];
      item = {};
      for (index = k = 0, len1 = row.length; k < len1; index = ++k) {
        console.log(value); // undefined
        assign(item, keys[index], value, options);
      }
      result.push(item);
    }
    return result;
  };

so when it goes to the assign function i get the error:
...\node_modules\node-promise\promise.js:204
throw error;
^
TypeError: Cannot read property 'length' of undefined
at convertValue (...\node_modules\excel-as-json\lib\excel-as-json.js:49:15)
at assign (...\node_modules\excel-as-json\lib\excel-as-json.js:106:33)
at convert (...\node_modules\excel-as-json\lib\excel-as-json.js:143:9)
at ...\node_modules\excel-as-json\lib\excel-as-json.js:218:20
at ...\node_modules\excel\excelParser.js:163:3
at Immediate._onImmediate (...\node_modules\node-promise\promise.js:164:27)
at runCallback (timers.js:810:20)
at tryOnImmediate (timers.js:768:5)
at processImmediate [as _immediateCallback] (timers.js:745:5)

updated everything
excel and excel-as-json.
now everything seems to work

This is probably the best bug report I have received (only missing the source excel file) - really appreciate that.
It is curious to me how many of these issues are solved by "turning it off and turning it back on again". Glad you were able to solve your problem.

testfile.xlsx
attached the file if you still want to debug.
Thanks for the great work


Add new artifacts to tenant deployment

Can you provide some details or example how can I add a tenant related stack written in CDK python? If a new tenant registers we need another two apps to run at every tenant.
As i assume we should create all of our resources with tenant id prefixes because of tenant isolation.
Also CDK doesn't create standalone CFN templates, so I assume it doesn't fit to the process handled by lambda-deploy-tenant-stack.py lambda handler.

Hi @tomeszmh :
You would use cdk deploy with parameters in this case.
https://docs.aws.amazon.com/cdk/v2/guide/parameters.html
Further, I would recommend that you look at this blog post:
https://aws.amazon.com/blogs/devops/parallel-and-dynamic-saas-deployments-with-cdk-pipelines/
This blog post extends the idea presented in this reference solution and uses CDK based approach. The concept still remains the same, where you uses DynamoDB to keep track of tenant installations.

Hi Anubhav,
Thanks for the reference architecture. Its really great to get an comprehensive insight into serverless saas.
I am running lab 5 on Cloud9 and noticed that the CodeCommit repository for Code pipeline serverless-saas-pipeline is not being created. (Although the documentation indicates that The pipeline has already been created as part of the initialization script you ran at the start of this lab.)
Due to this subsequent steps are failing.
Is there a way to add the serverless-saas-pipeline seperately to codecommit  ?

Hi @attainmax - you can look at this code to see how this is created:
https://github.com/aws-samples/aws-serverless-saas-workshop/blob/main/Lab5/scripts/deployment.sh#L25


Creating and destroying AI Cores

About the PR
AI Cores can now be destroyed and soon(tm) built.
Why / Balance
AI Core currently lacks quite a lot of things to make it feel like it fits. One of those things is the fact it cannot die.
Technical details
Mostly just added missing components
Media

None yet.
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

:cl:

tweak: Additional AI Cores can now be constructed.
fix: AI Core now gets correctly powered and unpowered.

Just posting the draft to show this is something I'm working on.
Just gotta figure out how construction works

posibrains/MMIs/pAIs being turned into AI cores?

posibrains/MMIs/pAIs being turned into AI cores?

That will be another PR
I still gotta figure out how I wonna tackle all this stuff but I do plan to work on it


Prototype generator - error with an unexpected character

Message received when generating a new prototype:

Is that because you were trying to use emojis somewhere odd?

It's webpack failing to parse a file. I'm not even sure what a .node file is.
I'm guessing it's doing something odd on OSX.

The FSEvents API in MacOS allows applications to register for notifications of changes to a given directory tree. It is a very fast and lightweight alternative to kqueue.
I guess so...

Sounds like we could fix this by upgrading webpack: https://github.com/webpack/webpack/issues/10783#issuecomment-619542931
I think my most recent attempt at that failed though...

Webpack v5 PR: https://github.com/daniel-ac-martin/NotGovUK/pull/95

This is fixed and will be in the next release.
We may still have a problem in #118 though.


Standalone: Support refresh_token flow

It seems that when using Firefox with 3rd party storage partitioning enabled and the Keycloak mock server running on a different root domain than the frontend, the iframe will not be able to access the session token received during the authentication redirect, and will thus request a token refresh even if the token itself is not yet expired.

Note: it turns out that it is not possible to fix the issue with refresh_token flow, because that flow is only called after the tokens have been invalidated in keycloak.js. The only way around this (until Keycloak fixes the issue) is to either run your backend and the sso server on the same domain or explicitly configure an exception in Firefox using the property privacy.restrict3rdpartystorage.skip_list (see https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Privacy/State_Partitioning#Exempt_specific_origins_from_partitioning).


Pattern Matching Identically Named Record Fields

main = let r = { x = "Problem?" } in plainText <| (\{x} {x} -> x) r r

produces Problem?, which I didn't expect. I discovered this when writing something like
main = let r = { x = "Problem?" } in plainText <| (\{x} {x'} -> x ++ x') r r

and the compiler forced me use the identifier x. The workaround I am currently using is
main = let r = { x = "Problem?" } in plainText <| (\{x} o -> x ++ o.x) r r

Closing in favor of #809 which, when fixed, will resolve this issues as well.


Bootcamps for Full stack web dev, building production ready web apps.

Project-based learning by building production-ready web apps.

@sheoranharis please resolve this merge conflict
__
  Summary: :hammer_and_wrench: This code needs a fix  |  Tags: Not reusable


Scores from Index at extra positions are not filtered out

If a FAISS index has fewer records than the requested number of top results (k), then it returns -1 in indices for the additional positions. The get_nearest_examples method only filters out the extra results from the dataset samples. It would be better to filter out extra scores too.
Reference: https://github.com/huggingface/datasets/blob/2.0.0/src/datasets/search.py#L693

Hi! Yes, that makes sense! Would you like to submit a PR to fix this?

Created PR https://github.com/huggingface/datasets/pull/3971


Apps should have a canonical route

When adding routes to an app like:

www.tld.com
tld.com

there should be a way to specify the canonical route, so all requests get redirected to that domain.
This is extremely useful when dealing with SEO (Search engines hate dupe content).
A way to do this could be: flynn route add http --canonical www.tld.com.

If somebody points me in the right direction I'd be happy to try and implement this if desired.

I'm not sure about this. The proposed implementation would toggle all of the other routes to a different type (a HTTP redirect).
Also, it's not clear that this is actually a problem that we should be solving right now in the router, as we'd also need to open the door to handle HTTPS redirects, HSTS, path rewriting, etc.

I'm not sure about this. The proposed implementation would toggle all of the other routes to a different type (a HTTP redirect).

The canonical redirect is only required for http, but you are right that other redirects might be required as well. But having both www.tld.com and tld.com is a common issue so it should be tackled imho.
For now however, the redirect can be solved by adding a URL to the DNS records, which circumvents the necessity to solve this problem from within the app.

Having redirects might be something which could be tackled in #1084

Flynn is unmaintained and our infrastructure will shut down on June 1, 2021. See the README for details.


Ancillary Generation for IMPROVER

As an IMPROVER developer I want flexible functionality to generate ancillary files so that I can generate any ancillaries needed for new IMPROVER developments easily.
Related issues:
Initially, several issues were opened for ancillary generation which will be superseded by this epic: #43, #76, #77, #78, #79, #80, #81,  #83, #85.
Functionality will be needed for all ancillaries listed below. For each one, the following acceptance criteria will be applied:

Develop plugin(s) to generate the required ancillary.
Develop flexible script(s) that can be called from the command line, in order to generate the required ancillary files
Develop tests for CLI script(s) and unittests for plugin(s)
Check ancillaries (plot, metadata etc)

NOTE: StaGE does not currenty produce orography ancillaries or land-sea mask/fraction on all the standard grids. Prerequisites listed are estimated

[x] Landmask
Prereqs: landmask/land-fraction field on standard grids.
The StaGE field should not require much adjustment; a CorrectLandMask plugin has been implemented to ensure there are no non-int/boolean values in the field (see #43).

[x] Topography bands
Prereqs: orography on standard grids.
These configurable orography bands will be used in neighbourhood processing routines to filter unsuitable grid points from the neighbourhoods used (ex: to remove grid points in valleys from the neighbourhoods of grid points on hills).
A GenerateOrographyBandAncils plugin has been implemented to generate a mask of land points within a given orography range (see #43).

[x] E-W and N-S orography gradient field
Prereqs: orography on standard grids.
These fields will be used when carrying out recursive filtering of probability fields, to avoid spreading probabilities up/down slopes.
Gradients should be calculated in the x and y directions only (not diagonal). The suggested convention is that the x-direction gradient specified for a grid square relates to the gradient on the eastern edge of that square and the y-direction gradient specified for a grid square relates to the northern edge of that square. Plugin(s) developed should be written to fulfil functionality requirements of this task (orography gradient between adjacent grid squares - originally ticket #76 ) and of ticket #83 (rain rate gradient between adjacent grid squares).

[x] Step 1 in rebadged user story #83 to cover creating a general function/utility that can calculate gradients.

[x] Sea/land grid squares in which there is land/sea
Prereqs: land-fraction field.
This relates to "Sub-grid topography ancillaries" in the roadmap. Ancillary field flagging up any points which are specified as land/sea in the Landmask ancillary, but which contain some area of sea/land (ie: mostly-land-some-sea, mostly-sea-some-land grid squares). (Originaly #85)

[ ] Nearest appropriate point around coasts
Prereqs: field produced by subtask above (land/sea areas in sea/land grid squares), landmask.
Generate ancillary field pointing to the nearest land/sea grid square for a land/sea site located in a sea/land grid square (originally #85 )

[ ] Hill/Valley diagnosis field
Prereqs: orography, orography gradient from the earlier subtask.
Generate an ancillary field categorising land points as hill/valley type. Possibly useful: ValleyIndex ancillary used by the old visibility scheme, topographic index used by the model hydrology scheme. (Originally #77)

[ ] Distance to nearest coast
Prereqs: landmask. (Originally #78)

[ ] Direction of nearest coast
Prereqs: orography gradient ancillary from earlier subtask, landmask, may share functionality with subtask above (to find nearest coast). (Originally #79)

[ ] Exposure to wind from each direction
Prereqs: gradient field from earlier subtask?
Generate fields of exposure to winds from each direction of: N, N, E, SE, S, SW, W, NW.  (Originally #80)

[ ] Masking fields used by GPP fog product
Current GPP fog product uses: sea mask (inverse of landmask), ValleyIndex (may be interchangeable with Hill/Valley diagnosis field). (Originally #81).

No longer using these epic tickets and outstanding requirements are unclear and not needed in the near future so closing


[Tooling] Fix Python tests to put target back to a known-good commissioning state

Reproduction steps / Feature
The current Mobly-based Python tests assume the target is commissioned to a single fabric, with a single controller with admin privileges on it.

This isn't great when dealing with devices that are coming in having partially failed a previous test, and may have more fabrics on them.

Solution:

Using that 'primordial' fabric, read out the fabric table and call `RemoveFabric` on all other fabrics till we are back at having just as single fabric.

Then, re-set the ACL table to containing just a single ACL entry granting privileges to the controller's NodeId/CAT tag.

Platform
python
Platform Version(s)
No response
Type
Hardware validated
(Optional) If manually tested please explain why this is only manually tested
No response
Anything else?
No response

FYI @tcarmelveilleux


Add support for spline and ellipse

This completes the support for splines as discussed in #11; and also adds support for ellipses. The README is also updated listing the newly supported entities.
I'm not sure about adding the types into index.d.ts, is that file auto-generated or edited by hand?

Here are two test DXFs I generated, and what they should look like. They render fine in LibreCAD, but I'm unable to test them using anything else.
test-splines.zip
spline-blob.dxf

so-many-ellipses.dxf

Here are two test DXFs I generated, and what they should look like. They render fine in LibreCAD, but I'm unable to test them using anything else.
test-splines.zip
spline-blob.dxf

so-many-ellipses.dxf

@ericman314
Would you mind updating "example/spline.js" file with your working code, and adding an example for ellipse?

@ericman314
Would you mind updating "example/spline.js" file with your working code, and adding an example for ellipse?

Sure, see #36

Sure, see #36


Synthesis failes

Lua code:
function sum(x1, x2)
     x1 = x1 + x2
     x2 = x2 + 3
     sum(x1, x2)
end
sum(1,2,3)

DFG at the moment of stop:

My guess is that the FRAM can't overwrite x2 variable because it is needed for second add function. So we have dead lock here.
Maybe related: #213

Not reproduce. But highlight the following problem https://github.com/ryukzak/nitta/issues/267


Documentation for TipableVMobject

Add an overview of TipableVMobject's functionality and a few comments, as well as grouping some methods by functionality (roughly).
Just a bit of documentation :) I'm trying to go through manim's source code and see how it all fits together.
As you'd expect, given that I'd only added a few multi-line comments and grouped a few methods together, the scenes in example_scenes.py rendered correctly w/o any dramas.

The docs currently don't display docstrings, but they probably should eventually.


Can't authenticate with GitHub, never provided prompt

Extension version: 0.1.1
VSCode Version: 1.27.1
OS: Windows 10 17134.228

Steps to Reproduce:

Open VS Code
Pop up appears that I need to sign in to use the Pull Requests functionality with a sign in button
Click the Sign In button. Another pop up immediately appears stating that an error occurred signing in to GitHub.com with a "Try Again?" button. Clicking the "Try Again?" button repeats the same flow

Trying to interact with the Pull Requests window creates more pop-ups about not being authenticated. I'm never shown a panel to provide credentials, so I'm not sure how to debug this further.

@dwalleck can you please try opening Command Palette and search for Sign in to GitHub and see if that can work?

Thanks for the tip.

Ah good, I knew there had to be output somewhere! Here's what I have in the GitHub Pull Requests log:
Looking for git repository
> git symbolic-ref --short HEAD
> git rev-parse task/ZAM-400
> git rev-parse --symbolic-full-name task/ZAM-400@{u}
> git rev-list --left-right task/ZAM-400...refs/remotes/origin/task/ZAM-400
> git for-each-ref --format %(refname) %(objectname) --sort -committerdate
> git remote --verbose
Git repository found, initializing review manager and pr tree view.
> git config --local --get remote.origin.github-pr-remote
Error signing in to github.com: undefined
Unable to resolve remote: Error: Not authenticated.
> git config --local --get branch.task/ZAM-400.github-pr-owner-number
Review> no matching pull request metadata found for current branch task/ZAM-400
> git branch
> git config --local --get remote.origin.github-pr-remote
> git config --local --get remote.origin.github-pr-remote
> git config --local --get remote.origin.github-pr-remote
> git config --local --get remote.origin.github-pr-remote
> git config --local --get branch.feature/***.github-pr-owner-number
> git config --local --get branch.master.github-pr-owner-number
> git config --local --get branch.task/ZAM-400.github-pr-owner-number
GitHubRepository> Fetching all pull requests failed: Error: Not authenticated.
GitHubRepository> Fetching all pull requests failed: Error: Not authenticated.
GitHubRepository> Fetching all pull requests failed: Error: Not authenticated.
GitHubRepository> Fetching all pull requests failed: Error: Not authenticated.
> git config --local --get branch.task/ZAM-400.github-pr-owner-number
> git config --local --get branch.task/ZAM-400.github-pr-owner-number
Error signing in to github.com: undefined
Error signing in to github.com: undefined
Error signing in to github.com: undefined
Error signing in to github.com: undefined
Error signing in to github.com: undefined
Error signing in to github.com: undefined
> git config --local --get branch.task/ZAM-400.github-pr-owner-number

I'm not currently on a VPN and I don't think my firewall rules have changed beyond the Windows standard defaults (but I could always be wrong about that!) I'll try manually creating a token as you suggested.

Minor update, but manually adding my credentials did work. Thanks! I did double check my firewall settings and just to be safe, I added VS Code to the allow list but I was still seeing the same error.

Weird. This is either the initial connection for the authentication failing, or vscode being unable to open the web browser. I don't think I have enough detailed logging in place to track this down right now unfortunately :-/
Glad to hear it's working now, let us know if it breaks.

I believe I have the same issue, here's my log output:
Looking for git repository
> git symbolic-ref --short HEAD
> git rev-parse master
> git rev-parse --symbolic-full-name master@{u}
> git rev-list --left-right master...refs/remotes/origin/master
> git for-each-ref --format %(refname) %(objectname) --sort -committerdate
> git remote --verbose
Git repository found, initializing review manager and pr tree view.
> git config --local --get remote.origin.github-pr-remote
Error signing in to github.com: undefined

Will try adding the credentials manually next!

I'm seeing the same problem. I am behind a proxy in my office, which of course makes things more difficult to debug. I have the usual environment variables set to help (http_proxy, https_proxy, etc.), but I also have Proxifier available to make more tweaks if necessary.
Mac OS - 10.13.6
VS Code - 1.27.1
Extension Version - 0.1.1

I did a little more digging for my problem with the github.com connection with Little Snitch. It looks like something in the "Code Helper" app isn't honoring the proxy settings and is connecting to dc.services.visualstudio.com directly. When I added a proxy rule to force this to go through my company proxy, I got a normal prompt to sign in to GitHub in Safari and everything was fine.
Seems like something needs to get fixed with how the helper process is detecting proxy settings.

@shana I believe this might be happening because our GitHub Enterprise instance does not have rate limiting enabled which makes GET /api/v3/rate_limit return a 404 error with this error:
{
    "message": "Rate limiting is not enabled.",
    "documentation_url": "https://developer.github.com/enterprise/2.13/v3/rate_limit/#get-your-current-rate-limit-status"
}

That API is used to validate the provided credentials on start-up and the validation fails because of the 404:
https://github.com/Microsoft/vscode-pull-request-github/blob/cd5f1dd04e90655409765ee973ac4db611392431/src/authentication/githubServer.ts#L210
If the credentials for the request however were actually bad, GHE would respond with a 401 error and
{
    "message": "Bad credentials",
    "documentation_url": "https://developer.github.com/enterprise/2.13/v3"
}

I just opened https://github.com/Microsoft/vscode-pull-request-github/pull/397 with a suggested fix that locally made the extension work for me ✨

Manually adding my credentials doesn't seem to work, on version 0.1.2
As soon as I hit save, I get the original popup to sign in to github and the settings entry updates itself to just have the "host" field.

Same problem here. When I click 'Sign In', I expect Code to open a web browser to authenticate to GitHub, but nothing happens, and the 'Error signing in' flash message appears immediately.
Output:
> git config --local --get branch.master.github-pr-owner-number
Error signing in to github.com: undefined

No proxies, no strange network setup, default browser is Chrome, and Code has no problem opening it when Cmd-clicking on links, for example.

@wesbland Thanks for the spelunking. It does look like your proxy is not being honored, not sure why :-/. dc.services.visualstudio.com is nothing related to the extension, that's the VSCode pinging the application insights service. That likely means that the problem with your proxy is affecting all of VSCode and not just the extension's connection.

You're right. I did end up adding a rule that just says that everything (that isn't to an internal site) from the "Code Helper" app should go through the proxy and I can see now that a bunch of api.github.com traffic is going there as well.

Hi all I am stuck at the following point after following the instructions:
Make sure you have VSCode version 1.27.0 or higher
Download the extension from the marketplace
Reload VS Code after the installation (click the reload button next to the extension)
This point here I cannot see my repos.
Open your desired repo
Go to the SCM Viewlet, and you should see the GitHub Pull Request treeview.
A notification should appear asking you to sign in GitHub, follow the directions to authenticate
You should be good to go!

@masacuna I'm not sure what you mean by "I cannot see my repos" - are you not seeing the GitHub Pull Requests treeview? Note that on the first load, it will show up collapsed at the bottom of the viewlet. Please make sure that you have a folder open with a remote that points to GitHub. If you're still not seeing anything, what's the output of running git remote -v in this folder if you still see the problem?

C:\Program Files\Git\cmd>git remote -v
fatal: not a git repository (or any of the parent directories): .git

@masacuna Let's move this conversation to a new issue since this is not related to the problem reported by this thread: https://github.com/Microsoft/vscode-pull-request-github/issues/456

There’s a fix on master now for this, if you want to try it out.
@wesbland Looks like some extensions are shipping with old versions of the application insights package that kinda breaks http requests, and it might be causing your proxying issues too. #449 has more details, but try disabling all your extensions to see if that makes things work.

@shana - It doesn't seem to have helped. I pretty much only had language extensions anyway since I just started VS Code because of this plugin.

This issue should be fixed in release 0.1.5 as part of the fix for #449. Please reopen if you find that you still never get a prompt to sign in.

Just got this error. This is the output:
[Info] Looking for git repository
[Info] Git repository found, initializing review manager and pr tree view.
[Info] Found GitHub remote
[Info] Error signing in to github.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at n (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354529)
	at new Promise (<anonymous>)
	at n (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354306)
	at t.CredentialStore.login (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356515)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356396)
	at Generator.next (<anonymous>)
	at o (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)
[Info] Error signing in to github.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at o (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)
[Info] Error signing in to github.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at o (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)
[Info] Error signing in to github.com: TypeError: Cannot set property 'text' of undefined
[Info] TypeError: Cannot set property 'text' of undefined
	at t.CredentialStore.willStartLogin (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:358635)
	at t.CredentialStore.<anonymous> (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:356720)
	at Generator.next (<anonymous>)
	at o (/Users/eric/.vscode/extensions/github.vscode-pull-request-github-0.8.0/media/extension.js:36:354362)

Same issue not able to authenticate properly?

Same issue in latest android studio(
Failed to initiate the GitHub login process. Please try again.

hosts add ip for api.github.com
see https://github.com/github-community/community/discussions/16965#discussioncomment-2881851

Is it possible that authentication is not working in vscode due to "Github Desktop" app on same computer?🤪🤪

For some reason, after loading this plugin today it's decided that github's url is https://gh. Has anyone else had this issue? There's no changes to my settings.json, nor any /etc/hosts changes.
This breaks the plugin and requires manual intervention.
023-03-14 10:46:35.038 [warning] GitHubServer> No response from host https://gh/repo/reponame request to https://gh/api/v3/rate_limit failed, reason: getaddrinfo ENOTFOUND gh
2023-03-14 10:46:35.038 [warning] No remotes found. The following remotes are missing: github, origin, upstream


fix bug: random choice instead of mean

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

It's interesting that the author switched to the mean of cluster initialization in the latest version of the paper... I checked the previous explanation in https://github.com/alibaba/cluster-contrast-reid/issues/15 and the author tried to convince us random sampling has a lower risk of having noise... But now ... I don't know how to comment on this sudden change ...


feat(Pipelines): validate parameter types upon PipelineVersion run

Changes
Enforces pipeline type arguments to contain only valid parameter types
How/what to test
Try submitting pipeline version with invalid types

Don't forget to edit the PR description to reflect your changes

Valid points I have updated the pr


Upgrade ASM to 9.2 in the Gradle distribution

Required by #19283

@bot-gradle test this

OK, I've already triggered the following builds for you:

PullRequestFeedback build

@bot-gradle test and merge

Your PR is queued. See the queue page for details.

OK, I've already triggered a build for you.


[BUG]: Error scaning device

In raising this issue I confirm that

[X] I have fully completed the issue template
[X] I have searched open and closed issues for duplicates
[X] I have read the Contribution Guidelines
[X] I have read the Code of Conduct
[X] I have read the Documentation

Describe the bug
The program "steamdeck" (the UI) reports a error when starting the connection to the steamdeck.
It will report:
Unable to set font: /usr/lib/python3.11/site-packages/streamdeck_ui/fonts/roboto/Roboto-BlackItalic.ttf
Unable to set font: /usr/lib/python3.11/site-packages/streamdeck_ui/fonts/roboto/Roboto-BlackItalic.ttf
Unable to set font: /usr/lib/python3.11/site-packages/streamdeck_ui/fonts/roboto/Roboto-BoldItalic.ttf
Unable to set font: /usr/lib/python3.11/site-packages/streamdeck_ui/fonts/roboto/Roboto-BoldItalic.ttf
Unable to set font: /usr/lib/python3.11/site-packages/streamdeck_ui/fonts/roboto/Roboto-BlackItalic.ttf
Exception in thread Thread-1 (_run):
Traceback (most recent call last):
File "/usr/lib/python3.12/threading.py", line 1073, in _bootstrap_inner
self.run()
File "/usr/lib/python3.12/threading.py", line 1010, in run
self._target(*self._args, **self._kwargs)
File "/usr/lib/python3.12/site-packages/streamdeck_ui/stream_deck_monitor.py", line 117, in _run
self.attached(streamdeck_id, streamdeck)
File "/usr/lib/python3.12/site-packages/streamdeck_ui/api.py", line 203, in _on_steam_deck_attached
self._update_streamdeck_filters(serial_number)
File "/usr/lib/python3.12/site-packages/streamdeck_ui/api.py", line 658, in _update_streamdeck_filters
self._update_button_filters(serial_number, page, button)
File "/usr/lib/python3.12/site-packages/streamdeck_ui/api.py", line 701, in _update_button_filters
display_handler.replace(page, button, filters)
File "/usr/lib/python3.12/site-packages/streamdeck_ui/display/display_grid.py", line 97, in replace
pipeline_filter.initialize(self.size)
File "/usr/lib/python3.12/site-packages/streamdeck_ui/display/image_filter.py", line 90, in initialize
frame = frame.resize((int(v * scale_factor) for v in frame.size), Image.LANCZOS)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/site-packages/PIL/Image.py", line 2305, in resize
im = im.resize(size, resample, box)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/site-packages/PIL/Image.py", line 2328, in resize
return self._new(self.im.resize(size, resample, box))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: argument 1 must be 2-item sequence, not generator

after a few seconds of loading.
Also this did work in the past so a recent update of something must have broken this.
Steps to reproduce the behavior

Have version 4.1.2.r4.g0f42d50d-1
Run steamdeck
Wait

Expected behavior
My steamdeck should be listed (since its listed in lsusb)
Screenshots

System Information
OS: Arch based
Destop: KDE
Python Version: Python 3.12.4
Im also using the arch repo git version
Stream Deck Version
Standard

Issue seems related to last weeks update to PIL library on Python: https://github.com/python-pillow/Pillow/commit/6990fc4a0996753c5faa6cc272b753cac23cffdf
Changes to the type hint might have broke support, and need conversion to a tuple: https://github.com/python-pillow/Pillow/issues/8195
Annoying, but a temporary fix is to downgrade PIL (python-pillow) to 10.3.0-2.
@marvin1099: If you haven't yet, since you are Arch-based, you should be able to pull that version from here until it's fixed: https://archive.archlinux.org/packages/p/python-pillow/

Hi, please read: https://github.com/streamdeck-linux-gui/streamdeck-linux-gui/discussions/203

Thanks for the clarity about the project status @coolapso !
Fixed this (for now) by changing line 90 in /usr/lib/python3.12/site-packages/streamdeck_ui/display/image_filter.py:
-            frame = frame.resize((int(v * scale_factor) for v in frame.size), Image.LANCZOS)
+            frame = frame.resize(tuple(int(v * scale_factor) for v in frame.size), Image.LANCZOS)

based on this discussion in Pillow.
Unfortunately there are still too many issues for me with streamcontroller.

If you care to open  PR I could try to make a fix release for that.

@coolapso

For streamcontroller I ran into a lot of missing dependencies not noted in the requirements.txt. Finally ending in pypi package install missing which since seems to have been blocked on pypi package index: https://pypi.org/project/install/ (see: https://github.com/pypi/support/issues/451) - working around that issue was possible - I might open a PR at some point to add the missing dependencies. (After this experience, I refuse using flatpack to install streamcontroller)
I started working on a fix, but after updating pillow to 10.3.0 to address security warnings from the linter, I ran into issues related to typing in multiple other places. Started fixing those but unfortunately I don't have enough time to see this through - encouraging others to continue working on this.

For streamcontroller I ran into a lot of missing dependencies not noted in the requirements.txt. Finally ending in pypi package install missing which since seems to have been blocked on pypi package index: https://pypi.org/project/install/ (see: https://github.com/pypi/support/issues/451) - working around that issue was possible - I might open a PR at some point to add the missing

hmm, yeah if you are trying to install build it like that, probably there are some issues ... Flatpak is your best bet.
as for the rest .. the codebase of this project is hard to get into, hence the migration to streamcontroller.

@thyme-87
Hi, I'm one of the developers of StreamController! First of all thanks for the feedback. Idk what exactly happened to the install module, but we removed the dependency of it. Regardless of this I highly recommend using the Flatpak for day to day use.

@coolapso @Core447 first of all, thanks for your fast reply here.
Please do not take it as a negative comment or attitude towards you or the StreamController project - which overall makes a good impression.
As a result of my take on installing it locally, I'll raise a PR with the missing dependencies that I encountered on my system. However, this experience also led me to believe, that the build and release process for StreamController is yet involving certain manual steps and/or a manually maintained build system. And for that reason I will keep checking in on building and installing it locally for now.

[Edit: can't reproduce the missing dependencies. So apparently I made something wrong during the initial setup. All the best for the StreamController project]

Thank you!

Believe v4.1.3  fixes this issue. Please check and let me know

Jep it works now.
I will keep both progamms around maby.
For me Streamcontroller running from source works great, not the flatpac though.


Outdated/New thirdparty dependencies

Last update: 2022-12-21 fully.
Name / New version / Used version

[x] - amd-fsr - 1.0.2 - 1.0.2 - (https://github.com/GPUOpen-Effects/FidelityFX-FSR)
[x] - BasisUniversal - 1.16.3 - 1.16.3 - (https://github.com/BinomialLLC/basis_universal)
[ ] - brotli - GIT (2022.12) - GIT (2022.01) - (https://github.com/google/brotli)
[x] - bullet - 3.24 - 3.24 - (https://github.com/bulletphysics/bullet3)

3.x only, dropped in master

[x] - certs - GIT (2022.10) - GIT (2022.10) - (https://github.com/bagder/ca-bundle)
[x] - cvtt - GIT (2022.06) - GIT (2022.06) - (https://github.com/elasota/ConvectionKernels)
[x] - doctest - 2.4.9 - 2.4.9 - (https://github.com/onqtam/doctest)
[x] - embree - 3.13.5 - 3.13.5 - (https://github.com/embree/embree)
[x] - enet - 1.3.17 - 1.3.17 - (https://github.com/lsalzman/enet)
[x] - etcpak - 1.0 - 1.0 - (https://github.com/wolfpld/etcpak/)
[x] - freetype - 2.12.1 - 2.12.1 - (https://github.com/freetype/freetype)
[x] - glad - 2.0.2 - 2.0.2 - (https://github.com/Dav1dde/glad)
[x] - glslang - sdk-<IP_ADDRESS> - sdk-<IP_ADDRESS> - (https://github.com/KhronosGroup/glslang)
[x] - graphite - GIT (2022.12) - GIT (2022.12) - (https://github.com/silnrsi/graphite)
[x] - harfbuzz - 6.0.0 - 6.0.0 - (https://github.com/harfbuzz/harfbuzz)
[x] - icu4c - 72.1 - 72.1 - (https://github.com/unicode-org/icu)
[x] - jpeg-compressor - GIT (2020.05) - GIT (2020.05) - (https://github.com/richgel999/jpeg-compressor)
[x] - libogg - 1.3.5 - 1.3.5 - (https://github.com/xiph/ogg)
[x] - libpng - 1.6.39 - 1.6.39 - (https://github.com/glennrp/libpng)
[x] - libtheora - GIT (2020.10) - GIT (2020.10) - (https://github.com/xiph/theora)
[x] - libvorbis - 1.3.7 - 1.3.7 - (https://github.com/xiph/vorbis)
[ ] - libvpx - 1.12.0 - 1.6.0 - (https://chromium.googlesource.com/webm/libvpx/)

3.x only, dropped in master

[ ] - libwebm - 1.0.029 - ? - https://chromium.googlesource.com/webm/libwebm

3.x only, dropped in master

[x] - libwebp - 1.2.4 - 1.2.4 - (https://chromium.googlesource.com/webm/libwebp/)
[x] - mbedtls - 2.28.2 - 2.28.2 - (https://github.com/ARMmbed/mbedtls)

We keep to the 2.28 LTS branch.

[x] - meshoptimizer - GIT (2022.12) - GIT (2022.12) - (https://github.com/zeux/meshoptimizer)
[x] - minimp3 - GIT (2021.11) - GIT (2021.11) - (https://github.com/lieff/minimp3)
[x] - miniupnpc - 2.2.4 - 2.2.4 - (https://github.com/miniupnp/miniupnp)
[x] - minizip - 1.2.13 - 1.2.13 - (https://github.com/madler/zlib)
[x] - msdfgen - 1.9.2 - 1.9.2 - (https://github.com/Chlumsky/msdfgen)
[x] - nanosvg - GIT (2022.12) - GIT (2022.11) - (https://github.com/memononen/nanosvg)

3.x only, replaced by thorvg in master

[ ] - oidn - 1.4.3 - 1.1.0 (2019) - (https://github.com/OpenImageDenoise/oidn)

oidn versions after 1.1.0 require the ISPC compiler, which makes our build instructions more complex. So for now we're sticking to the old version.

[x] - openxr - 1.0.26 - 1.0.26 - (https://github.com/KhronosGroup/OpenXR-SDK)
[x] - pcre2 - 10.42 - 10.42 - (https://github.com/PhilipHazel/pcre2)
[x] - pvrtccompressor - GIT (2015.04) - GIT (2015.04) - (https://github.com/LibreGamesArchive/PVRTCCompressor)

3.x only, dropped in master

[x] - recastnavigation - GIT (2022.11) - GIT (2022.11) - (https://github.com/recastnavigation/recastnavigation)
[ ] - rvo2 - GIT (2022.11) - GIT (2021.05) - (https://github.com/snape/RVO2-3D)
[x] - spirv-reflect - sdk-<IP_ADDRESS> - sdk-<IP_ADDRESS> - (https://github.com/KhronosGroup/SPIRV-Reflect)
[x] - squish - GIT (2019, minor changes) - 1.15 (2017) - (https://sourceforge.net/p/libsquish/code/HEAD/tree/)
[ ] - tinyexr - GIT (2022.12) - 1.0.1 - (https://github.com/syoyo/tinyexr)
[x] - thorvg - 0.8.3 - 0.8.3 - (https://github.com/Samsung/thorvg)
[ ] - vhacd - GIT (2022.08) - GIT (2020.05) - (https://github.com/kmammou/v-hacd)
[x] - volk - sdk-<IP_ADDRESS> - sdk-<IP_ADDRESS> - (https://github.com/zeux/volk)
[x] - vulkan - sdk-<IP_ADDRESS> - sdk-<IP_ADDRESS> - (https://github.com/KhronosGroup/Vulkan-Headers)

volk and vulkan should be kept in sync. volk doesn't tag every single update, but unless we need the latest and greatest, we can just follow their latest tag.

[ ] - wslay - GIT (2022.08) - GIT (2021.01) - (https://github.com/tatsuhiro-t/wslay)
[ ] - xatlas - GIT (2022.07) - GIT (2022.03) - (https://github.com/jpcy/xatlas)
[x] - zlib - 1.2.13 - 1.2.13 - (https://github.com/madler/zlib)
[x] - zstd - 1.5.2 - 1.5.2 - (https://github.com/facebook/zstd)

@qarmin FYI, for libraries which have frequent tagged stable releases, we shouldn't bother tracking their latest Git commits. It's their job as upstream developers to define what is a stable version of downstream to use, so we follow that.
It's only for libraries which do not tag stable releases, or haven't tagged any in a long time, yet have a lot of bugfix commits in their latest Git branch, that we track Git.

I'm interested in updating vhacd.

cvtt was updated with #69061

It has been completely rewritten, so it's not an easy update. Feel free to have a go at it.

xatlas files used by Godot have not changed since the last upstream sync, therefore it can be considered up to date

By checking every library version and/or judging updates on their source repos I might say the following are now outdated:
certs
harfbuzz
icu4c
miniupnpc
minizip
nanosvg
recastnavigation
thorvg
zlib
I decided to not check vulkan related libraries (glslang, spirv-reflect, volk, vulkan) .

nanosvg is deprecated and I'm not sure the status of its code.
thorvg can be updated as soon as possible since it has bugfixes for our bugs.

Vulkan-related libraries should be updated to 1.3.239

Harfbuzz, ICU and Freetype got updated weeks ago in https://github.com/godotengine/godot/pull/77379. We can mark as done in first comment.

glslang, spirv-reflect, volk and vulkan are now at <IP_ADDRESS>

Do not update cvtt until upstream fixes https://github.com/godotengine/godot/commit/f7e72d1f3d523668dce7c8a1c45324f4888d1cf9

There is an attempt to update pcre2 to 10.42 at #70472, not implemented yet due to some issues.

oidn got removed in 4.2 with #81659

Version 4.0 of V-HACD was officially released on April 7, 2022. It's now a header file only library so just one source file is needed apparently. Version 4.1 of V-HACD was officially released on Oct 24, 2022.
Is anyone working on this?

@Anutrix Feel free to work on it :)

The Vulkan dependencies (glslang, spirv-reflect, volk, vulkan) seem to be at 1.3.268.0.

Is this list maintained?

The following have newer versions than the ones shown:

astcenc: 4.7.0
certs: GIT (2023.12)
clipper2: 1.3.0
glad: 2.0.5
glslang/spirv-reflect/volk/vulkan: vulkan-sdk-1.3.275.0
harfbuzz: 8.3.0
icu4c: 74.2
libktx: 4.3.1
libpng: 1.6.43
mbedtls: 2.28.7
meshoptimizer: GIT (2024.02) No difference from GIT (2023.11)

While minimp3 isn't outdated, I suggest replacing it with dr_mp3 as there's minimal differences (one is based off the other) and it's actually maintained.

miniupnpc: 2.2.6
minizip/zlib: 1.3.1
msdfgen: 1.11
nvapi: R550
openxr: 1.0.34
pcre2: 10.43
rvo2-[2d,3d]: GIT (2023.12)
tinyexr: 1.0.8
thorvg: 0.12.6
vhacd: GIT (2024.01)

Feel free to delete this comment once the list gets updated.

We're fully up-to-date as of 2024-04-05, aside from:

ANGLE: Not critical as our version is not old, requires manual work to make custom builds
Vulkan stuff: New SDK release, not critical as our version is not old, but we could update
RVO2 2D/3D: Requires significant work, not trivial
VHACD: Requires significant work, not trivial
meshoptimizer: Very recent commits adding a new experimental feature, we can wait for it to stabilize and assess if we should use it


Istio related docker images/Dockerfile's to test sample examples with kubernetes on s390x

We have build istioctl from source on s390x and tested all the UTC's. Now we are trying to run a sample example with Kuberenetes.
We have started Kubernetes local cluster using kubeadm (Version:1.8.3).
To test Istio with Kuberentes we executed the prerequisite yaml, i.e
kubectl apply -f install/kubernetes/istio.yaml
The YAML file refers to amd64 images as a result the required istio pods are down in our s390x cluster.
Could you'll please let us know if there are plans to push s390x specific docker images for below listed images, also if possible could you'll give us reference to the Dockerfile's from where we could build these images locally.
Images include:

gcr.io/istio-testing/proxy_debug
gcr.io/istio-testing/istio-ca
gcr.io/istio-testing/mixer
gcr.io/istio-testing/pilot

@guirish  Dockerfiles can be found in the following directories:
https://github.com/istio/istio/tree/master/pilot/docker
https://github.com/istio/istio/tree/master/mixer/docker
https://github.com/istio/proxy/tree/master/docker

Thanks @GregHanson for the information.


Fix wrong appearance in "Consuming Secret Values from Environment Variables" part

Fix wrong appearance in "Consuming Secret Values from Environment Variables" part

I signed it

I signed it

/check-cla

Hi @Tony-Hu, thanks for the fix! It looks like the CLA bot is acting up. Can you try closing and reopening this PR to see if that'll trigger it again? If that still doesn't work, please follow the steps at in the troubleshooting section.

Hello @cody-clark , thanks for your suggestion. It works!

/lgtm

Awesome, thanks @Tony-Hu!
Preview: https://deploy-preview-13042--kubernetes-io-master-staging.netlify.com/docs/concepts/configuration/secret/
/approve


(1.15) [FLINK-27118][yarn] TM ignores localhost BIND_HOST

This picks #19395 to 1.15

@flinkbot run azure

Merged


Can't open the application (check that first install works fine)

When I launch the app, I get a blank screen for a few seconds, then an alert pups up with this content (sorry html mess this up):
Error when setting up Kresus: xhr error: Gateway Time-out

Error 504 Gateway Time-out

Error 504 Gateway Time-out
 This cozy is not responding.

 The proxy may be crashed - Please contact us at<EMAIL_ADDRESS>Provide us this url, so we can fix it.

Thanks for reporting. It looks like your entire cozy is down. If not, you can try to uninstall and reinstall Kresus, maybe? Not sure what would cause an infra issue like that.

Yup, tried it, no change. And I don't see how the Cozy is entirely down, since I can use other apps, change the Cozy's settings, etc. Also tried to reboot it, no change.

Hi I have a similar issue when I try to launch kresus. It is the first time I launch kresus since cozy was updated to 2.0.
Cozy instance hosted on Cozy infrastructure (nicolas-6)
Data System: 2.0.0
Proxy: 2.0.0
Home: 2.0.1
Controller: 2.0.24
Kresus:  0.5.1

OK. I restarted Cozy, got notifications for updates of Data Systme and Home.
Data System: 2.0.3
Home: 2.0.2
Kresus is launched and works fine now.

Same, I updated my Cozy, and Kresus works fine now.

Strange. I'll check that kresus is installing fine the first time on a new empty cozy.

Just retried on an hosted CC instance, worked fine... the second time. It seems there is some race condition in the installation process that went in the way of Kresus. Opened https://github.com/cozy/cozy-controller/issues/67
If that ever happens again, I recommend reinstalling / restarting Kresus :/


Global search

Is your feature request related to a problem? Please describe.
No not at all.
Describe the solution you'd like
Maybe something along the lines of: freevine.py search * "test"
Describe alternatives you've considered
For now this can be used, although it's a pain to keep up with all the new services :)
freevine.py search abciview,bbciplayer,cbc,cbs,channel4,channel5,crackle,ctv,cwtv,itv,plex,pluto,roku,rte,stv,svtplay,tubi,tv4play,tvnz,uktvplay "test"
Additional context
N/A

Superb. Thanks very much :)

Awesome! Is there a trick to searching for something consisting of two words please? E.g. I'm looking for anything with the comedian Paul Foot but when I search "Paul Foot" it's failing:

@PlaceboPRS Seems to be a problem specifically with channel4 & svtplay. Both don't seem to cope with multiple words.

Tested and spot on. Following command now works perfectly!
Cheers @stabbedbybrick
freevine.py search all "Paul Foot"

Works a treat now thank you! I hate to ask this sorry to sound demanding, wondered if there's any way to force results that only have both words e.g. "Paul+Foot"? Right now it's returning all results with Paul and all with Foot...

Aha ok I fully understand! I already found some good leads with the search so thank you for that! :)


try jenkinsapi instead of jenkins-python

https://github.com/salimfadhley/jenkinsapi

jenkinsapi do not support python 3.x as for today

jenkinsapi do not support python 3.x as for today

Not True. The project have been tested and working on Python 2.7, 3.3 and 3.4.

I like jenkins-python better


Several additions for various entities.

Support for Mules and Donkeys to EntityTag.jump_strength
Add new tag/mech for Llamas: EntityTag.strength. This value determines their inventory size, and intimidation level.
Add new tag/mech for Bees: EntityTag.hive, also EntityTag.has_hive.

Closing due to lack of update. Can reopen once work on this is resumed.


[Question] How to use sriov function in harvester1.20

I saw that the official community has released the sriov function, and I want to know how to use the various functions of sriov。TKS

harvester 1.2.0-rc1 does have a part of the sriov changes.
To use, please enable the pcidevices addon: https://docs.harvesterhci.io/v1.1/advanced/pcidevices
Once this is deployed, the UI should show a new option for SriovNetworkDevices: this basically leverages pcidevices addon to scan the nodes for nic's which are sriov capable.
Once devices sriov capable devices appear, please edit the device and define the number of VF's.
pcidevices addon will now scan the VF's and will make them available as additional pcidevices, which can not be passed through to VM's.

Do I need to create SriovNetworkDevices manually？Or is it automatically recognized, as long as my physical network card turns on sriov。 @ibrokethecloud

capable devices will show up automatically. there could be a slight lag since it the underlying reconcile is an async process.
A side note: pcidevices controller will also skip nic's already in use for management and additional cluster network configurations. So if you have sriov capable nic's used in cluster network definitions they may not show up.

ok i know it and i am tring to test it. tks @ibrokethecloud

had got the information that i want to know


[release-4.10] OCPBUGS-20802: CVE-2023-44487: bump golang.org/x/net to v0.17.0

cc @openshift/storage

/retest

/label backport-risk-assessed

/test verify-deps

/retest

/lgtm

The 4.10 bugs were closed, apparently this is not being backported past 4.11 after all.


[Snyk] Security upgrade aiohttp from 2.1.0 to 3.10.11

Snyk has created this PR to fix 1 vulnerabilities in the pip dependencies of this project.
Snyk changed the following file(s):

async_downloader/requirements.txt

[!IMPORTANT]

Check the changes in this PR to ensure they won't cause issues with your project.
Max score is 1000. Note that the real score may have changed since the PR was raised.
This PR was automatically created by Snyk using the credentials of a real user.
Some vulnerabilities couldn't be fully fixed and so Snyk will still find them when the project is tested again. This may be because the vulnerability existed within more than one direct dependency, but not all of the affected dependencies could be upgraded.

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.
For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic

Learn how to fix vulnerabilities with free interactive lessons:
🦉 Learn about vulnerability in an interactive lesson of Snyk Learn.

:tada: Snyk checks have passed. No issues have been found so far.
:white_check_mark: security/snyk check is complete. No issues have been found. (View Details)
:white_check_mark: license/snyk check is complete. No issues have been found. (View Details)