The m2m_changed signal is not triggered when adding objects

Hi! I encountered an issue with the m2m_changed built in signal. The signal is triggered only when removing objects from the m2m relation, but not when adding. Imagine I have a Book and Label models. A book can have multiple labels and each label can be used in multiple books, your standard m2m scenario. For my API, I use the built in strawberry_django.mutations.update mutation to update a book, nothing extra. The input node has the standard annotation for m2m: labels: Optional[strawberry_django.ListInput[strawberry.relay.GlobalID]]. So far so good. I also have a signal receiver like this:
@receiver(models.signals.m2m_changed, sender=Book.labels.through)
def do_something(sender, instance, **kwargs):
    action = kwargs["action"]
    if action in ["post_add", "post_remove"]:
        print('foo')

In my frontend, for the ListInput, I'm only ever using set. I start with a Book with no labels. I add the first label and the signal is not triggered. I then remove the label and the signal is indeed triggered.
Describe the Bug
The reason why the signal is not triggered when a label is added is because of the way the through models are created in https://github.com/strawberry-graphql/strawberry-graphql-django/blob/8f82b84141c182980b5001b4f0f562c787fe2dda/strawberry_django/mutations/resolvers.py#L479
I do not fully understand the implications of the above logic or why it's done the way it's done. Why not simply use the managers add method? You can pass the through_defaults to add. I also don't understand when the condition hasattr(manager, "through") would be False as all managers have the through model, even if it's auto generated?
Generally speaking I'm not familiar with Django or Strawberry Django internals and I have hard time understanding the intents here since it's not documented. For this reason I'm not suggesting any particular fix.
As a workaround, I can hook up to the post_save signal of the through model.
System Information

Strawberry version (if applicable): 0.20

Hey @Mapiarz ,
TBH, its been awhile since I wrote that code (back on strawberry-django-plus), and it has been adjusted over the past 2 years.
Maybe we could indeed call add and pass through_defaults in this case and, worst case scenario hook up the post_save signal.
Do you want to try to open a PR for this? I can help you through the development as needed :)


Make a combination of text/status filters on the main page a bookmarkable URL

Discussion history from https://github.com/EBIvariation/trait-curation/pull/36#issuecomment-644216291:

Another consequence of instant search is that it's not possible to bookmark a combination of specific filters, as there isn't a dedicated URL to use for that. If this can be fixed easily, then please do so as part of this PR. Otherwise, we can create a separate low-priority issue in the backlog for that.

Yes, that is the drawback of using JavaScript to filter. We cannot include the filters in a URL so I think we should add a new issue for that, although I am not quite sure what that would be. Possibly a page with query history?

I think it should be possible to manipulate URL from JavaScript both ways. I.e., when user changes something (enters text or clicks on one of status buttons), a script could both update the table and modify the URL. And for the reverse flow, if the page is loaded with some parameters specified in the URL, the script could take them and apply the filters to the table immediately after the page loads.
This can probably be done with History API. Since I'm not a web developer, this idea can be horribly wrong :)

This is a very tiny detail which is not really relevant to any of the use cases I know for our app. So this should be considered very low priority, if ever implemented at all.

For example of what I mean, see the EVA website: https://www.ebi.ac.uk/eva. Internally it's implemented as a one huge page controlled by JavaScript. When you click on any of the tabs, you will notice that while the action is performed by JavaScript without actually reloading the page, the URL still updates and can be used to return to that state of the page


UPDATE SQL question

when run:
update items set "embedding"='[0,0,0]' where id = 1;
result:
ERROR:  called Result::unwrap() on an Err value: Closed
Is my SQL statement incorrect?

Can you give more information? Did you follow docs/install.md and modify postgresql.conf?

I have tested this query at my example DB and it works fine.

Could you please provide steps to reproduce this error?

Closed for now. If you still meet this problem, please feel free to reopen it.


[improve][test] Reduce LedgerUnderreplicationManagerTest flakyness

Motivation
In our CI environment we've seen many times that the test LedgerUnderreplicationManagerTest fails in this way:
java.util.concurrent.TimeoutException
	at java.base/java.util.concurrent.CompletableFuture.timedGet(CompletableFuture.java:1886)
	at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2021)
	at org.apache.pulsar.metadata.bookkeeper.LedgerUnderreplicationManagerTest.test2reportSame(LedgerUnderreplicationManagerTest.java:428)

All of the tests then fail. The reason behind the timeout is that the method LedgerUnderreplicationManagerTest#getLedgerToReplicate uses the common thread pool and it causes deadlock in some way. Using a dedicated thread pool solves the issue.
Note that I haven't ever seen this failure in the OSS pulsar CI so I believe is related to the way we run the tests in our CI but the fix is still a good solution
Modifications

Use a dedicated thread pool for the method getLedgerToReplicate. This is a test method so the production code is not affected at all.

[x] no-need-doc

/pulsarbot rerun-failure-checks


Svelte 5 Migration

I tried running Breadcrumb.svelte through the migration script and got this, which is specifically that it couldn't decide how to resolve the run()

You may see that the migration script converts some of your $: statements to a run function which is imported from svelte/legacy. This happens if the migration script couldn’t reliably migrate the statement to a $derived and concluded this is a side effect instead. In some cases this may be wrong and it’s best to change this to use a $derived instead. In other cases it may be right, but since $: statements also ran on the server but $effect does not, it isn’t safe to transform it as such. Instead, run is used as a stopgap solution. run mimics most of the characteristics of $:, in that it runs on the server once, and runs as $effect.pre on the client ($effect.pre runs before changes are applied to the DOM; most likely you want to use $effect instead).

From: https://svelte.dev/docs/svelte/v5-migration-guide#Migration-script
Auto migrated code:
<script lang="ts" generics="Metadata = any">
	import { run } from 'svelte/legacy';

	import type { Crumb, ModuleData } from '.././types';
	import { onMount } from 'svelte';

	export function titleSanitizer(title: string) {
		return title.replace(/([A-Z])/g, ' $1').replace(/^./, (str) => str.toUpperCase());
	}
	interface Props {
		// Relative path to the routes folder for the glob import
		relPathToRoutes?: string;
		// The route from the routers perspective, e.g. $page.route.id
		routeId: string | null;
		url: URL;
		crumbs?: Crumb<Metadata>[] | undefined;
		routeModules?: Record<string, ModuleData> | undefined;
		pageData: any;
		children?: import('svelte').Snippet<[any]>;
	}

	let {
		relPathToRoutes = '/src/routes/',
		routeId,
		url,
		crumbs = undefined,
		routeModules = $bindable(undefined),
		pageData,
		children
	}: Props = $props();

	onMount(async () => {
		// If nothing is passed to routeModules, populate it
		if (routeModules === undefined) {
			routeModules = import.meta.glob('/src/routes/**/*.svelte', {
				eager: true
			});
		}
	});

	// Given a module and a crumb, determine the page title
	function getPageTitleFromModule(module: ModuleData | undefined) {
		if (module?.pageTitle) {
			return module.pageTitle;
		}
		// Fall back to crumb title if the function returns undefined
		if (module?.getPageTitle) {
			return module.getPageTitle(pageData);
		}
		return undefined;
	}

	let _crumbs = $state([] as Crumb<Metadata>[]);
	run(() => {
		_crumbs = [] as Crumb<Metadata>[];
		if (crumbs != undefined) {
			// If crumbs array is passed in always use that with highest priority
			_crumbs = [...crumbs];
		} else if (routeId) {
			// If there is routeing info, use it to find the page modules and
			// subsequently the page titles for each route leading up to the
			// current page.
			let completeUrl = '';
			let completeRoute = relPathToRoutes + (relPathToRoutes.slice(-1) == '/' ? '' : '/');
			// Split the route ID on every forward slash, but if there is a group route include that in the
			// following route. This accounts for the fact that (group) routes do not show up in the path.
			// For Example:
			// routeId: test/(group1)/test2/test3
			// routes: ["test", "(group1)/test2", "test3"]
			const routes = routeId.split(/(?<!\))\//).filter((p) => p != '');
			const paths = url.pathname.split('/').filter((p) => p != '');

			// Loop over each directory in the path and generate a crumb
			// for each one.
			for (let i = 0; i < paths.length; i++) {
				let path = paths[i];
				let route = routes[i];
				completeUrl += `/${path}`;

				// Note: the slash is trailing here because the prefix always exists as the provided
				// relative path to the routes folder, and we are appending another path to
				// the end later
				completeRoute += `${route}/`;

				// routeModules type is technically undefined so we can detect when a value
				// is passed in or not, but will always be generated in the onMount as a
				// fallback.
				const routeModule =
					routeModules === undefined ? undefined : routeModules[`${completeRoute}+page.svelte`];

				_crumbs.push({
					// Last crumb gets no url as it is the current page
					url: i == paths.length - 1 ? undefined : completeUrl,
					title: getPageTitleFromModule(routeModule) || titleSanitizer(path)
				});
			}

			// Force trigger an update
			_crumbs = _crumbs;
		} else {
			// And if there is no route info, simply generate breadcrumbs from the url
			// path
			let completeUrl = '';
			const paths = url.pathname.split('/').filter((p) => p != '');
			for (let i = 0; i < paths.length; i++) {
				let path = paths[i];
				completeUrl += `/${path}`;
				_crumbs.push({
					title: titleSanitizer(path),
					url: i == paths.length - 1 ? undefined : completeUrl
				});
			}

			_crumbs = _crumbs;
		}
	});
</script>

{@render children?.({ crumbs: _crumbs, routeModules, })}

I tried changing the run() to $effect but this causes a whole page reload. Would you know what the right way to update that might be?

Hm I am admittedly not very familiar with the changes in Svelte 5. It looks like the script did most changes I would have done if I were to migrate manually, other than using $effect instead of run like you said. Not sure why it would do a full page reload... When does it trigger this reload?

You're updating _crumbs in a for loop.
Because $effect runs each time _crumbs is updated this will cause an infinite loop that Svelte will then automatically break.
One quick fix is to use a temporary array of crumbs that updates _crumbs only once at the bottom of the function:
<script lang="ts" generics="Metadata = any">
	import { onMount } from 'svelte';
	import type { Crumb, ModuleData } from '.././types';

	export function titleSanitizer(title: string) {
		return title.replace(/([A-Z])/g, ' $1').replace(/^./, (str) => str.toUpperCase());
	}
	interface Props {
		// Relative path to the routes folder for the glob import
		relPathToRoutes?: string;
		// The route from the routers perspective, e.g. $page.route.id
		routeId: string | null;
		url: URL;
		crumbs?: Crumb<Metadata>[] | undefined;
		routeModules?: Record<string, ModuleData> | undefined;
		pageData: any;
		children?: import('svelte').Snippet<[any]>;
	}

	let {
		relPathToRoutes = '/src/routes/',
		routeId,
		url,
		crumbs = undefined,
		routeModules = $bindable(undefined),
		pageData,
		children
	}: Props = $props();

	onMount(async () => {
		// If nothing is passed to routeModules, populate it
		if (routeModules === undefined) {
			routeModules = import.meta.glob('/src/routes/**/*.svelte', {
				eager: true
			});
		}
	});

	// Given a module and a crumb, determine the page title
	function getPageTitleFromModule(module: ModuleData | undefined) {
		if (module?.pageTitle) {
			return module.pageTitle;
		}
		// Fall back to crumb title if the function returns undefined
		if (module?.getPageTitle) {
			return module.getPageTitle(pageData);
		}
		return undefined;
	}

	let _crumbs = $state([] as Crumb<Metadata>[]);
	$effect(() => {
		let tmpCrumbs = [] as Crumb<Metadata>[];
		if (crumbs != undefined) {
			// If crumbs array is passed in always use that with highest priority
			tmpCrumbs = [...crumbs];
		} else if (routeId) {
			// If there is routeing info, use it to find the page modules and
			// subsequently the page titles for each route leading up to the
			// current page.
			let completeUrl = '';
			let completeRoute = relPathToRoutes + (relPathToRoutes.slice(-1) == '/' ? '' : '/');
			// Split the route ID on every forward slash, but if there is a group route include that in the
			// following route. This accounts for the fact that (group) routes do not show up in the path.
			// For Example:
			// routeId: test/(group1)/test2/test3
			// routes: ["test", "(group1)/test2", "test3"]
			const routes = routeId.split(/(?<!\))\//).filter((p) => p != '');
			const paths = url.pathname.split('/').filter((p) => p != '');

			// Loop over each directory in the path and generate a crumb
			// for each one.
			for (let i = 0; i < paths.length; i++) {
				let path = paths[i];
				let route = routes[i];
				completeUrl += `/${path}`;

				// Note: the slash is trailing here because the prefix always exists as the provided
				// relative path to the routes folder, and we are appending another path to
				// the end later
				completeRoute += `${route}/`;

				// routeModules type is technically undefined so we can detect when a value
				// is passed in or not, but will always be generated in the onMount as a
				// fallback.
				const routeModule =
					routeModules === undefined ? undefined : routeModules[`${completeRoute}+page.svelte`];

				tmpCrumbs.push({
					// Last crumb gets no url as it is the current page
					url: i == paths.length - 1 ? undefined : completeUrl,
					title: getPageTitleFromModule(routeModule) || titleSanitizer(path)
				});
			}
		} else {
			// And if there is no route info, simply generate breadcrumbs from the url
			// path
			let completeUrl = '';
			const paths = url.pathname.split('/').filter((p) => p != '');
			for (let i = 0; i < paths.length; i++) {
				let path = paths[i];
				completeUrl += `/${path}`;
				tmpCrumbs.push({
					title: titleSanitizer(path),
					url: i == paths.length - 1 ? undefined : completeUrl
				});
			}
		}
		_crumbs = tmpCrumbs;
	});
</script>

{@render children?.({ crumbs: _crumbs, routeModules })}


panic when checking repo

Hi, fist of all thank you for this great piece of software :+1:
Restic version : e738d35c compiled 2015-10-01 11:59:10 with go version go1.5.1 linux/amd64
Expected behavior: report the integrity and consistency of the backup without panic and unlock the repository when executing $ restic check
Observed behavior:  having this message in the stdout
Create exclusive lock for repository
Load indexes
Check all packs
Check snapshots, trees and blobs

and a panic attached - debug enabled in the stdout without unlocking the repo (need to run $ restic unlock )
My repo is stored in a usb drive formated with NTFS if this can help.

Thanks for reporting this issue, it is indeed a bug.

This is probably the same as #311.

Today I ran into the same issue, but in an interesting context: I copied a restic repository created with the current master version (e738d35) from an internal ext4 drive to a samba share backed by an external ntfs-formatted usb3 device attached to a Windows 10 client.  The copy has been verified to be identical with the source repository:
$ diff -qr /media/backup-intern/restic/limucs-main.repo /mnt/backup-extern/restic/limucs-main.repo
diff -qr /media/backup-intern/restic/limucs-main.repo   31,64s user 373,25s system 9% cpu 1:14:56,53 total

If I run restic check on the source repository, no issues are found. Howerver, if I run restic check on the copied repository, the same nil pointer dereference error as above occurs. These are the last lines of the debug log:
[...]
2015/10/02 16:49:49 [ checker.loadTreeWorker] 166 checker.go:321 load tree 52334555
2015/10/02 16:49:49 [           Index.Lookup] 166 index.go: 98 id 52334555 found in pack ab9a0283 at 3677006, length 2707
2015/10/02 16:49:49 [ checker.loadTreeWorker] 168 checker.go:321 load tree ab9a943f
2015/10/02 16:49:49 [           Index.Lookup] 168 index.go: 98 id ab9a943f found in pack 8aacd119 at 3000126, length 1687
2015/10/02 16:49:49 [ checker.loadTreeWorker] 170 checker.go:321 load tree a08bd1eb
2015/10/02 16:49:49 [           Index.Lookup] 170 index.go: 98 id a08bd1eb found in pack 748d3e6a at 1750222, length 947
2015/10/02 16:49:49 [ checker.loadTreeWorker] 166 checker.go:324 load tree <nil> (52334555) returned err open /mnt/backup-extern/restic/limucs-main.repo/data/ab/ab9a02831a04a19ee9f3fb346aced22fbf04f6cf8c99f0a1b885340fc170feb5: input/output error
2015/10/02 16:49:49 [ checker.loadTreeWorker] 166 checker.go:330 sent tree 52334555
2015/10/02 16:49:49 [    checker.filterTrees] 108 checker.go:440 input job tree 52334555
2015/10/02 16:49:49 [    checker.filterTrees] 108 checker.go:395 closing output channels

dmesg does not report any read/write errors!
Restic has been compiled using go version go version go1.4.2 linux/amd64.

I'm able to reproduce it, working on it now. It's indeed a duplicate of #311

The nil pointer dereference is explained by #311. However the source of the input/output error remains unclear: Multiple runs of diff do not raise any IO-Errors!
Would be interesting to see the debug log of the original reporter. Also an input/output error?

I'm pretty sure that it's not caused by an i/o error, I was able to reproduce it with a fresh repository with just one (non-interrupted) backup.


Resolved issue with cards headers and sub headers

Hard to read due to color mismatch

Just because we won't show them on the demo page isn't reason enough to break them. We should still make sure all existing components and functionality of bootstrap is there.

Agreed. We will still make sure they look good.


build(cert-manager): upgrade cert-manager version

Welcome to Cryostat! 👋
Before contributing, make sure you have:

[x] Read the contributing guidelines
[x] Linked a relevant issue which this PR resolves
[x] Linked any other relevant issues, PR's, or documentation, if any
[x] Resolved all conflicts, if any
[x] Rebased your branch PR on top of the latest upstream main branch
[x] Attached at least one of the following labels to the PR: [chore, ci, docs, feat, fix, test]
[x] Signed all commits: git commit -S -m "YOUR_COMMIT_MESSAGE"

Fixes: #484
Description of the change:
Upgrade cert-manager to 1.11.5. I selected this version to match the Go module version (1.11.1), but went with this patch because it included CVE fixes.
Releases: https://github.com/cert-manager/cert-manager/releases?q=1.11.&expanded=true
Motivation for the change:
Cert Manager >= 1.10 includes fixes that ensures pods are able to run under restricted policy.

@tthvo I see your commits are signed but unverified. This usually means that your GPG setup on your workstation is working correctly and signing commits, but your GitHub profile is missing information to match up with those commit signatures - either the GPG public key needs to be added to your profile, or I think this may also happen if your committer email address is not on your profile.

Updated now! Seems like it also requires version bumps in other k8s modules. Should we wait till #614 to use 1.12.4?

@tthvo I see your commits are signed but unverified.

Opps sorry laptop crashed last night and had to reinstall Fedora :(( So lost the old keys. Signed again now :))

It might be better to wait - assuming that the Operator SDK upgrade is also going to upgrade the k8s modules to those same versions.
Did 1.11.5 not need to update those?

Seems to break the tests too. Yeh, 1.11.5 does not require any other upgrades.

Not sure why the image is not available after successful push: https://github.com/cryostatio/cryostat-operator/actions/runs/6126153972/job/16629579344?pr=622
Checked here but can't see it either: https://github.com/orgs/cryostatio/packages/container/package/cryostat-operator-bundle

That is weird. The CI runner logs do report that it successfully pushed an image with that tag to ghcr.io . Could be a ghcr.io infra thing.

Yehh no idea :)) I can't rerun actions tho. Can u help..?

Trying a rerun of the same one you posted now.

Now, the image is available :)) very odd haha...

@tthvo Could I get you to upgrade the k8s deps to 0.26.8 actually? And run go mod tidy again?

Sure make sense to me! Updated now ^^

Thanks @tthvo for taking the time to do this. Much appreciated!

Thanks I am happy to help anytime :))


Features/add ignore case enhancement

This adds the option
sortedBy('key', {ignoreCase: true})

in order to get a closer result to alphaNumeric sorting like what returns from a sql db in ORDER BY

+1

@NoxPhoenix Good use case example
I'm taking a look right now

Cool, feel free to comment on anything you would like changed. I did my best to follow the style you had in place.

@johntimothybailey How are we looking on this?

That is cool about dropping the node 4 support. I had originally wrote this alot cleaner before I realized it had backwards compatibility that far.

How is this looking now? It would great to get this in before you start your update so that you can update the new code as you refactor the rest!

@johntimothybailey

Hi @johntimothybailey, Any update on when this feature is going to be merged?

@johntimothybailey How is this looking?

@johntimothybailey any chance to get this merged and released?


perl syntax highlight is broken?

Description of the problem or steps to reproduce

s/1.4.1-git/1.4.2-git/

use, FindBin, qw() should highlight in different colors
text between () should be in different color
my $answer = breaking something, but this is how should be written

Specifications
Version: 1.4.2-dev.19
Commit hash: 9cbe2c6
Compiled on August 27, 2018
OS: Arch Linux
Terminal: Tilix

Oh, very sorry. I had old file inside my home, probaby very very old (i forgot about). But syntax highlight can be better. Lightly modified file: perl.yaml.gz


Uncaught Error: The specified module could not be found./?~\AppData\Local\atom\app-1.38.1\res...

[Enter steps to reproduce:]

...
...

Atom: 1.38.1 x64
Electron: 2.0.18
OS: Microsoft Windows 10 Home
Thrown From: Atom Core
Stack Trace
Uncaught Error: The specified module could not be found.
\?\C:\Users\luci\AppData\Local\atom\app-1.38.1\resources\app.asar.unpacked\node_modules\keyboard-layout\build\Release\keyboard-layout-manager.node
At ELECTRON_ASAR.js:166

Error: The specified module could not be found.
\\?\C:\Users\luci\AppData\Local\atom\app-1.38.1\resources\app.asar.unpacked\node_modules\keyboard-layout\build\Release\keyboard-layout-manager.node
    at process.module.(anonymous function) [as dlopen] (ELECTRON_ASAR.js:166:20)
    at Object.Module._extensions..node (module.js:671:18)
    at Object.module.(anonymous function) [as .node] (ELECTRON_ASAR.js:180:18)
    at Module.load (module.js:561:32)
    at tryModuleLoad (module.js:504:12)
    at Function.Module._load (module.js:496:3)
    at Module.require (/app.asar/static/index.js:60:45)
    at require (internal/module.js:11:18)
    at customRequire (~/AppData/Local/atom/app-1.38.1/resources/app/static/<embedded>:1:688769)
    at get_KeyboardLayoutManager (~/AppData/Local/atom/app-1.38.1/resources/app/static/<embedded>:14:2692775)
    at get_manager (~/AppData/Local/atom/app-1.38.1/resources/app/static/<embedded>:14:2692855)
    at Object.getCurrentKeyboardLayout (~/AppData/Local/atom/app-1.38.1/resources/app/static/<embedded>:14:2692981)
    at e.keystrokeForKeyboardEvent (~/AppData/Local/atom/app-1.38.1/resources/app/static/<embedded>:14:1078253)
    at KeymapManager.t.exports.KeymapManager.keystrokeForKeyboardEvent (~/AppData/Local/atom/app-1.38.1/resources/app/static/<embedded>:11:1244475)
    at KeymapManager.t.exports.KeymapManager.handleKeyboardEvent (~/AppData/Local/atom/app-1.38.1/resources/app/static/<embedded>:11:1242460)
    at WindowEventHandler.handleDocumentKeyEvent (~/AppData/Local/atom/app-1.38.1/resources/app/static/<embedded>:11:283624)

Commands
     -1:06.5.0 core:select-all (input.hidden-input)
     -0:38.9.0 tree-view:add-file (ol.tree-view-root.full-menu.list-tree.has-collapsable-children.focusable-panel)

Non-Core Packages
atom-beautify 0.33.4
atom-html-preview 0.2.6
atom-ternjs 0.19.1
autoclose-html 0.23.0
busy-signal 2.0.1
csslint 1.2.0
emmet 2.4.3
intentions 1.1.5
language-ejs 0.4.0
linter 2.3.0
linter-eslint 8.5.5
linter-jshint 3.1.16
linter-ui-default 1.7.1
pigments 0.40.2
Sublime-Style-Column-Selection 1.7.5

keyboard layout manager.node electron_asar.js:166

Thanks for taking the time to contribute!
We noticed that this is a duplicate of https://github.com/atom/atom/issues/14461. You may want to subscribe there for updates.
Because we treat our issues list as the Atom team's backlog, we close duplicates to focus our work and not have to touch the same chunk of code for the same reason multiple times. This is also why we may mark something as duplicate that isn't an exact duplicate but is closely related.
For information on how to use GitHub's search feature to find out if something is a duplicate before filing, see the How Can I Contribute? section of the Atom CONTRIBUTING guide.


Upgrade onyx to 2.0.24

Details

Upgrade onyx to version 2.0.24 to fix infinite loading when login with a magic link.
Fixed Issues

$ https://github.com/Expensify/App/issues/37351
PROPOSAL: https://github.com/Expensify/App/issues/37351#issuecomment-1991804964
Tests

Same as QA Steps

[x] Verify that no errors appear in the JS console

Offline tests

Requires internet connection to log in
QA Steps

Web/mWeb only

Sign out
Enter your login and press next
Copy the magic link from the email and open it on a new tab
Wait until the magic link login completes
Go back to the first tab
Verify the app won't infinitely load and show/populate the LHN with your chat list

[x] Verify that no errors appear in the JS console

PR Author Checklist

[x] I linked the correct issue in the ### Fixed Issues section above
[x] I wrote clear testing steps that cover the changes made in this PR

[x] I added steps for local testing in the Tests section
[x] I added steps for the expected offline behavior in the Offline steps section
[x] I added steps for Staging and/or Production testing in the QA steps section
[x] I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
[x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
[x] I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).

[x] I included screenshots or videos for tests on all platforms
[x] I ran the tests on all platforms & verified they passed on:

[x] Android: Native
[x] Android: mWeb Chrome
[x] iOS: Native
[x] iOS: mWeb Safari
[x] MacOS: Chrome / Safari
[x] MacOS: Desktop

[x] I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
[x] I followed proper code patterns (see Reviewing the code)

[x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
[x] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g. myBool && <MyComponent />.
[x] I verified that comments were added to code that is not self explanatory
[x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
[x] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method

[x] If any non-english text was added/modified, I verified the translation was requested/reviewed in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:

[x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
[x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
[x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
[x] I verified the JSDocs style guidelines (in STYLE.md) were followed

[x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
[x] I followed the guidelines as stated in the Review Guidelines
[x] I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
[x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
[x] I verified any variables that can be defined as constants (ie. in CONST.js or at the top of the file that uses the constant) are defined as such
[x] I verified that if a function's arguments changed that all usages have also been updated correctly
[x] If any new file was added I verified that:

[x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory

[x] If a new CSS style is added I verified that:

[x] A similar style doesn't already exist
[x] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))

[x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
[x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
[x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
[x] If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
[x] If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:

[x] I verified that all the inputs inside a form are aligned with each other.
[x] I added Design label and/or tagged @Expensify/design so the design team can review the changes.

[x] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
[x] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.

Screenshots/Videos

Android: Native

Android: mWeb Chrome

iOS: Native

iOS: mWeb Safari

https://github.com/Expensify/react-native-onyx/assets/50919443/d6a8f6b1-dc48-4658-85ad-bd11f094467b

MacOS: Chrome / Safari

https://github.com/Expensify/react-native-onyx/assets/50919443/d1b11263-e609-4c93-8043-458ffbfba847

MacOS: Desktop

Merged with main again, the reassure test now passes.

Updated. No crash when running the app and sending a message.

Updated

@bernhardoj Thank you!

@bernhardoj Could you merge again please?

We can go ahead here

:hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

🚀 Deployed to staging by https://github.com/mountiny in version: 1.4.63-0 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅

🚀 Deployed to production by https://github.com/mountiny in version: 1.4.63-21 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅


Document watch and upcoming changes

Turns out watch was barely documented, while it very much needs documentation :grin:
Preparation for 5.0 changes proposed in https://github.com/abonas/kubeclient/pull/275#issuecomment-591928097
Also, the whole "Examples" section (which is really the main documentation) is messy, took a small step towards organizing it...
@grosser @qingling128 @mszabo @Stono please review

In several places here, I neglected to say which exception / how exactly to detect 410 errors.  I don't really want people to now write code catching HTTP errors and to check notice.code, I hope to fix them asap (and I intend to have a separate sub-exception for 410 because of its importance).

I didn't mention the new "BOOKMARK" type.
Kubeclient doesn't know how to opt-in yet.  Once we track last seen version, we could opt-in and honor these transparently without yielding them to the block.  Will decide how to cross that bridge when we get there.
I wondered if I should add generic advice to ignore unknown type for future compatibility?  But if people did that now, we'd all be ignoring "type": "ERROR" :laughing:  And it seems k8s will make any new types opt-in.

BTW, the terminology "watch notice" comes from Kubeclient::WatchNotice, which we dropped in #299.  The k8s golang & opeapi type name is WatchEvent, so maybe should start using that?
https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.17/#watchevent-v1-meta


Electron fails to build on OSX because assertion fails in libcap/default.nix

Issue description
The electron-1.2.2 package fails to build on OS X because an assertion fails:
installing ‘electron-1.2.2’
error: assertion failed at /nix/store/2k70j2jyvj7z27l4gwf5mx1l8n8zg3ai-nixpkgs-17.03pre93030.548bcd0/nixpkgs/pkgs/os-specific/linux/libcap/default.nix:2:1

Since libcap is in os-specific/linux, I'm guessing the electron package should check whether it's on Linux before requiring it as a dependency.
The failed assertion:
{ stdenv, fetchurl, attr, perl, pam ? null }:
assert pam != null -> stdenv.isLinux;

Steps to reproduce
On OS X:
nix-env -i electron

Technical details

System: OS X 10.11.6
Nix version: nix-env (Nix) 1.11.2
Nixpkgs version: 17.03pre93030.548bcd0

If I look at the electron expression today, it looks like it has a few things that assume Linux, presumably because it uses a precompiled binary rather than a source release. It might need some work before it works on OSX. The current expression seems to be using patchelf, libXscreensaver, and the url mentions linux. Might be worth coordinating with @travisbhartwell to figure out how to make it more friendly to other platforms?

I've been trying to write a version for OS X myself.
There's already a couple of issues (https://github.com/NixOS/nixpkgs/issues/17073 and https://github.com/NixOS/nixpkgs/issues/6689) for building Electron from source, but apparently it's quite difficult—certainly beyond my Nix knowledge to fix.
Would it be possible to install Electron on OS X using a binary provided by Electron? I can fetch the Darwin binary as easily as the Linux one, but there are a few things I don't know:

what do I need to do with the Electron.app file after I downloaded and extracted it?
do I need some equivalent of patchelf to make external binaries work on OS X with Nix?
what does makeWrapper do and would I need it for OS X as well?

I don't know if installing binaries like this is really practical on OS X or not, but if it is I could definitely work on updating the Electron derivation.

I think we'd all prefer to have everything be source based. That said, pull requests are usually accepted with binary blobs.
The main thing you're going to need to do is download the file, extract the .dmg, then copy it to $out/Applications/. You probably won't need to use something like patchelf because the binaries are probably not dynamically compiled. This means that the closure going to be bigger than it would be if we used Nix-pure stuff.
Anyway, is there a reason you want to use Electron on Nix Mac? I usually just use homebrew for Application level stuff on my Mac computers.
https://github.com/NixOS/nixpkgs/issues/16455#issuecomment-228061221

Anyway, is there a reason you want to use Electron on Nix Mac?

Philosophically, I want to manage everything with Nix: I don't even have homebrew installed. (It's a work computer, so I haven't needed anything Nix couldn't handle.)
More practically, I want to create a friendly Nix wrapper around a Haskell project that uses Electron to make it easy to install on both OS X and Linux. People on my team at work all have Nix and use OS X, so this can save them a lot of time over manually fiddling with Electron.

@matthewbauer The binary distribution of Electron comes as a .app bundle. I put together a .nix expression that downloads and unpacks Electron.app from the .zip file and puts it in $out/Applications—but I'm not sure it does what I want. At the very least, it doesn't seem to put electron into my path. How should I install a .app file?
Thanks for the help!

Can we close this?


Add Instituto de Ciencias

@etochavez First stage of verification passed, official domain is idec.edu.mx as far as I verified. This is just an informational note. Pull request is still in the review. I appreciate your patience while waiting for the final decision.

@etochavez Thank you for your patience while waiting for a review and processing your request. Pull request merged.


patch submission code diff is incorrect right after submission, but correct after a page reload

When I submit a patch in the System tab (haven't check the Components tab yet), here's what I see:
I write some code:

I get ready to submit a patch, and everything looks good in the diff:

After I submit the patch, I click on any other system, and then back to the one I just submitted a patch for (without actually reloading the page).  I see my patch waiting for approval, but when I check the diff I see that random pieces have been duplicated:

I reload the page, and now the diff looks correct

I don't have a screenshot of it, but for the submission that made me notice this, the bad diff showed really garbled code that wasn't even syntactically correct.

Can no longer reproduce. Closing unless it shows up again.


Upde current dashboards & queries for gitbase-spark-connector

Replicate (and adapt when necessary) queries and dashboards from the current CE dashboards for EE.
If the queries are not compatible, we will need to have different json files for CE and EE. They should be loaded automatically on bootstrap, just like we do for CE.
We need to pay attention also to the internal links from the welcome dashboard to the other ones.
note: we already have an undocumented env var, MODE=Community/Enterprise, used in superset_config.py for the database connection string.

With the new CE & EE roadmap, there is no need to keep both versions. The current dashboards need to be updated to work with gitbase-spark-connector.
For now we need to start working on it, to find incompatibilities and possible bugs in gitbase-spark-connector as soon as possible.
To help with development, let's work with PRs against a new branch, gsc. This way we can have smaller PRs before merging everything to master.

Adding the 'blocked' label because we should wait for #251 to be merged first.

Removing the blocked label as #251 has been merged.

As discussed in Apps sync of 2019-10-02 this is a won't do.


Hit testing can be triggered while layout is still pending, causing assertion errors

Steps to reproduce
Run the following app in the target that can produce PointerScrollEvent events (e.g. desktop or web with a trackpad or mouse with a scroll wheel connected).
import 'package:flutter/gestures.dart';
import 'package:flutter/rendering.dart';
import 'package:flutter/widgets.dart';

void main() {
  runApp(BugReport());
}

class BugReport extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Align(
      child: FractionalTranslation(
        translation: Offset.zero,
        child: RelayoutOnMouseScroll(
          child: ConstrainedBox(
            constraints: BoxConstraints(
              minWidth: 200,
              minHeight: 200,
            ),
            child: ColoredBox(
              color: const Color(0xffff0000),
            ),
          ),
        ),
      ),
    );
  }
}

class RelayoutOnMouseScroll extends SingleChildRenderObjectWidget {
  const RelayoutOnMouseScroll({Key key, Widget child}) : super(key: key, child: child);

  @override
  RenderObject createRenderObject(BuildContext context) => RenderRelayoutOnMouseScroll();
}

class RenderRelayoutOnMouseScroll extends RenderBox with RenderObjectWithChildMixin<RenderBox> {
  @override
  void handleEvent(PointerEvent event, BoxHitTestEntry entry) {
    if (event is PointerScrollEvent) _handlePointerScrollEvent(event, entry);
    super.handleEvent(event, entry);
  }

  Offset _scrollDelta = Offset.zero;

  void _handlePointerScrollEvent(PointerScrollEvent event, BoxHitTestEntry entry) {
    _scrollDelta += event.scrollDelta;
    markNeedsLayout();
  }

  @override
  double computeMaxIntrinsicWidth(double height) {
    return child.getMaxIntrinsicWidth(height) + _scrollDelta.dx;
  }

  @override
  double computeMinIntrinsicWidth(double height) {
    return child.getMinIntrinsicWidth(height) + _scrollDelta.dx;
  }

  @override
  double computeMaxIntrinsicHeight(double width) {
    return child.getMaxIntrinsicHeight(width) + _scrollDelta.dy;
  }

  @override
  double computeMinIntrinsicHeight(double width) {
    return child.getMinIntrinsicHeight(width) + _scrollDelta.dy;
  }

  @override
  bool hitTestSelf(Offset position) => true;

  @override
  void performLayout() {
    final EdgeInsets deflation = EdgeInsets.fromLTRB(_scrollDelta.dx, _scrollDelta.dy, 0, 0);
    child.layout(constraints.deflate(deflation), parentUsesSize: true);
    size = constraints.constrain(child.size);
  }

  @override
  void paint(PaintingContext context, Offset offset) {
    context.paintChild(child, offset);
  }
}

... then use the scroll wheel / trackpad to scroll over the red box.
Expected behavior
You expect the red box to grow or shrink as you scroll.
Actual behavior
[ERROR:flutter/lib/ui/ui_dart_state.cc(171)] Unhandled Exception: 'package:flutter/src/rendering/proxy_box.dart': Failed assertion: line 2594 pos 12: '!debugNeedsLayout': is not true.
#0      _AssertionError._doThrowNew (dart:core-patch/errors_patch.dart:46:39)
#1      _AssertionError._throwNew (dart:core-patch/errors_patch.dart:36:5)
#2      RenderFractionalTranslation.hitTestChildren (package:flutter/src/rendering/proxy_box.dart:2594:12)
#3      RenderFractionalTranslation.hitTest (package:flutter/src/rendering/proxy_box.dart:2581:12)
#4      RenderShiftedBox.hitTestChildren.<anonymous closure> (package:flutter/src/rendering/shifted_box.dart:85:24)
#5      BoxHitTestResult.addWithPaintOffset (package:flutter/src/rendering/box.dart:777:31)
#6      RenderShiftedBox.hitTestChildren (package:flutter/src/rendering/shifted_box.dart:80:21)
#7      RenderBox.hitTest (package:flutter/src/rendering/box.dart:2163:11)
#8      RenderView.hitTest (package:flutter/src/rendering/view.dart:189:13)
#9      RendererBinding.hitTest (package:flutter/src/rendering/binding.dart:458:16)
#10     GestureBinding._handlePointerEvent (package:flutter/src/gestures/binding.dart:266:7)
#11     GestureBinding._flushPointerEventQueue (package:flutter/src/gestures/binding.dart:240:7)
#12     GestureBinding._handlePointerDataPacket (package:flutter/src/gestures/binding.dart:213:7)
#13     _rootRunUnary (dart:async/zone.dart:1206:13)
#14     _CustomZone.runUnary (dart:async/zone.dart:1100:19)
#15     _CustomZone.runUnaryGuarded (dart:async/zone.dart:1005:7)
#16     _invoke1 (dart:ui/hooks.dart:265:10)
#17     _dispatchPointerDataPacket (dart:ui/hooks.dart:174:5)

Diagnosis
We're calling markNeedsLayout() on the render object, which is scheduling a layout, but our event dispatcher is flushing the event queue before the layout happens.  This can be seen if you instrument the GestureBinding._flushPointerEventQueue() as well as RenderRelayoutOnMouseScroll._handlePointerScrollEvent() and RenderRelayoutOnMouseScroll.performLayout() -- which produces the following:
flutter: flushing 1 events
flutter: marking needing layout
flutter: laying out
flutter: flushing 1 events
flutter: marking needing layout
flutter: flushing 1 events
[ERROR:flutter/lib/ui/ui_dart_state.cc(171)] Unhandled Exception: 'package:flutter/src/rendering/proxy_box.dart': Failed assertion: line 2594 pos 12: '!debugNeedsLayout': is not true.
#0      _AssertionError._doThrowNew (dart:core-patch/errors_patch.dart:46:39)
...

Other info
$ flutter doctor -v
[✓] Flutter (Channel master, 1.22.0-2.0.pre.51, on Mac OS X 10.15.3 19D76, locale en-US)
    • Flutter version 1.22.0-2.0.pre.51 at /Users/tvolkert/project/flutter/flutter
    • Framework revision 9497c3ec54 (2 days ago), 2020-08-24 14:40:50 -0700
    • Engine revision aa08192a6b
    • Dart version 2.10.0 (build 2.10.0-52.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at /Users/tvolkert/Library/Android/sdk
    • Platform android-29, build-tools 29.0.2
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.2.1)
    • Xcode at /Applications/Xcode_11.2.1.app/Contents/Developer
    • Xcode 11.2.1, Build version 11B500
    • CocoaPods version 1.9.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.0)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 48.1.2
    • Dart plugin version 193.7361
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[✓] Connected device (3 available)
    • macOS (desktop)  • macos      • darwin-x64     • Mac OS X 10.15.3 19D76
    • Web Server (web) • web-server • web-javascript • Flutter Tools
    • Chrome (web)     • chrome     • web-javascript • Google Chrome 84.0.4147.135

• No issues found!

This'll be a problem for platform view hover events too due to: https://github.com/flutter/flutter/commit/fa0c49d77

It's capable of biting any render object that calls markNeedsLayout() in an event handler.  Practically speaking, the only events that come in fast enough to trigger this are going to be scroll events and hover events.
Per @Hixie, this is something we ran into early on in the framework, and the solution is to add something analogous to the widget build phase (which runs before flushLayout() is called in each frame).  Using this mechanism, the render object would mark itself as dirty in some way, then at the beginning of the next frame, the dirty bit would cause it to invalidate its layout... then the corresponding layout pass would happen synchronously in the same frame -- with no opportunity for input events to be dispatched while it was marked as needing layout.
The problem with the solution above is that it currently necessitates a hook to run code before RendererBinding.drawFrame() (such as WidgetsBinding does by overriding drawFrame() to do its build phase).  Attempting to call SchedulerBinding.addPersistentFrameCallback() won't work, because you'll be in line after the frame is drawn.
Adding a notion of "pre-frame" callbacks (SchedulerBinding.addPreFrameCallback()) would solve for this.

We have that, it's called scheduleFrameCallback.

Oh man, didn't see it because it didn't match the "add*Callback()" naming pattern. 🙄

Yeah... a lot of our earliest APIs aren't perfectly aligned because we didn't yet know what we were building.

Is it not possible for events to be dispatched in between window.beginFrame and window.drawFrame?

Seems like it's safe:

The onDrawFrame callback is invoked immediately after onBeginFrame, after draining any microtasks (e.g. completions of any Futures) queued by the onBeginFrame handler.

Ok, with the following mixin added to RenderRelayoutOnMouseScroll  above, and with replacing markNeedsLayout() with markDirty(), the issue is fixed.
mixin DeferMarkNeedsLayoutMixin on RenderObject {
  bool _dirty = false;
  void markDirty() {
    if (!_dirty) {
      _dirty = true;
      SchedulerBinding.instance.scheduleFrameCallback((Duration timeStamp) {
        if (_dirty) {
          _dirty = false;
          markNeedsLayout();
        }
      });
    }
  }
}


Drop support for Java EE 6

Update Maven artifacts to Java EE 7
Use CDI 1.1 beans.xml
remove BeanManagerProvider and BeanProvider (CDI.current().select(C.class).get() )
Use JSF 2.2 versioned config files.

Use MethodHandles instead of reflection (since Java 7 is now the minimal targetted version)


Updated tutorials for HADDOCK version 2.4

Updated education part - tutorials for HADDOCK 2.4.
New option where one can choose between tutorials for HADDOCK2.2 or 2.4

The changes must also affect other links to our tutorials since the URLs will change (with the additions subdirectory for haddock24. Should check all links on our web pages and also the server pages.
Or will the old links to the haddock2.2 tutorial still work?
It probably depends on if you also defined a haddock-22 subdirectory or not.
If this is the case we will also need to update the links on the BioExcel and WeNMR pages.

Or we could add softlinks into education to ensure the old links will still work

Another thing. The community-forum-2017 was a link to biomolecular-simulations-2018
Now you seem to have duplicated the entire directory... Can you check?

PS: Will clone your version and check things.


added loginEndPointWithPath

Signed-off-by: Mattijs Vanhaverbeke<EMAIL_ADDRESS>Description
This adds the basepath to the login button when multiple authentication is enabled with openid/saml with a csutom basePath
Category
Bug fix
Why these changes are required?
Login button redirects to the wrong location.
What is the old behavior before changes and new behavior after changes?
Redirects to /auth/XXX instead of basePath/auth/
Issues Resolved
#1349
Testing
manual tested
Check List

[ ] New functionality includes testing
[ ] New functionality has been documented
[x] Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Thanks for this fix @mattieserver could you please add / update a test case to verify this behavior?

Yes, will try to add some tests this week

Hi @RyanL1997 & @peternied  ,
It seems like there are already tests that should catch this issue.
The basepath is already set in login-page.test.tsx, so i changed the snapshot to reflect this.
Are there any other tests that are needed?

Hi @mattieserver, thanks for the follow-up.

The basepath is already set in login-page.test.tsx, so i changed the snapshot to reflect this.
Are there any other tests that are needed?

Modify the snapshot will be sufficient enough to adapt your change, so at this point this PR is good to be merged imo. Just for your info, we are also working on a OIDC integration test, so that the issues like this can be automatically detected in the future. And I will create a follow up issue on that.

Also, the only thing i am not sure about is what happens when the basepath is not set.

For this question, based on my experiment, the server.basePath will use the default value if it is not get setup. However, if the base_redirect_url doesn't setup, it will cause an Invalid parameter: redirect_uri error.
Again, thanks for this contribution! I will update the branch and approve this PR.


restructure discovery documentation

fix #1 and fix #2
okay, this is my attempt to make the documentation more readable. i restructured it quite heavily, i hope you can see what i did...

Thanks you. It is indeed better this way. I added a few comments, can you check those before merging?

updated. i think the trait idea would make no sense actually, as you have to initialize the properties anyways

Cool, thanks. Ready to merge?

in my opinion: yes


Initializer bug or am i missing something ?

Hello,
i am playing with codes examples in the Fun with Stamps medium.com articles series.
Just found something strange in the Breaking down a stamp into pieces from the first article code examples :
#!/usr/bin/env node
'use strict';

const {compose, init} = require('stampit');

const HasFoo = compose({
    properties: {
        foo: 'default foo!'
    }
});

const PrintFoo = compose({
    methods: {
        printFoo() {
            console.log(this.foo || 'There is no foo');
        }
    }
});

const InitFoo = init(function(foo) {
    console.log('init arg value is ', foo);
    if (foo) this.foo = foo;
});

const Foo = compose(HasFoo, PrintFoo, InitFoo);

const objNoArg = Foo();
console.log('objNoArg :', objNoArg); // objNoArg : { foo: {} }

const objArgNull = Foo(null);
console.log('objArgNull :', objArgNull); // objArgNull : { foo: 'default foo!' }

When the initializer receive no value at all, the stamp lib replace undefined by an empty literal object, so the if statement is true instead of false, and the default value is overwritten with the literal object.
I am using<EMAIL_ADDRESS>and node 6.11.3.

Oh, right. The article was written before this change: https://github.com/stampit-org/stamp-specification/issues/93
Thank you for finding it!
Basically, the first argument is considered an options object. Thus, should never be undefined. You can manually specify null which is an object typeof null === 'object'.
Let me fix the article.

The article should be fixed now.
Thank you for the great issue!

Oooookayyyyy ;)
It's crystal clear now.
It imply that factory function have to takes an object as param.
We cannot do that const myInstance = FactoryFn(prop1, prop2, ...)
We have to do that const myInstance = FactoryFn({prop1: 'val1', prop2, ...})
To be honest the rtype spec to describe stamps add a step in the library adoption. You want to learn stamp but you have to learn rtype + stamp. Javascript executable examples in addition to the rtype def in the stamp-specification repo would be valuable.
Thanks !


Fix incorrect GPU assignment in multi gpu setup

Fix for #369

Check out this PR - works fine on WSL2 Ubuntu 22.04. Thanks for the fix!

This fix works on my end for the small/default gpt2 model (2.1m tok/s on 8 GPU).
The current code still breaks for the gpt2-xl model, albeit in a different way, unrelated to openMPI (with 1 GPU or 8GPU).  The error I'm getting is:
1373: void matmul_backward(floatX*, floatX*, floatX*, floatX*, floatX*, floatX*, float*, int, int, int, int): Assertion `(OC % OC_per_warp) == 0' failed.
Commit 6c179fa works fine for gpt2-xl.  It is possible that a separate independent bug was introduced since that commit that only breaks the larger model.

Confirm this fixes the issue, stepping at ~460K tok/s on 4XA100 GPUs.

I've verified that the fix by ademeure works on my end for GPT2-XL and opened a PR.


mcuboot: Brick when using BOOT_SWAP_USING_MOVE and reset happens during images swap

Describe the bug
Interrupted swap of images when swap_move (CONFIG_BOOT_SWAP_USING_MOVE=y) strategy (default for nRF chips) is selected, can end up in "bricked" state. Possible workaround is to use swap_scratch (CONFIG_BOOT_SWAP_USING_SCRATCH=y) strategy, which doesn't seem to have this specific issue.
To Reproduce
Steps to reproduce the behavior:

west build -d build_boot -b nrf52840dk_nrf52840 ../bootloader/mcuboot/boot/zephyr/
west flash -d build_boot
west build -b nrf52840dk_nrf52840 samples/subsys/mgmt/mcumgr/smp_svr/ -- -DOVERLAY_CONFIG=overlay-bt.conf
west sign -t imgtool --no-bin -H app.hex -- --key ../bootloader/mcuboot/root-rsa-2048.pem --version 1.0.0 --pad --confirm
west flash --hex-file app.hex
west sign -t imgtool --no-hex -B fake.bin -- --key ../bootloader/mcuboot/root-rsa-2048.pem --version 1.2.3
mcumgr --conntype ble --connstring peer_name=Zephyr image upload fake.bin
mcumgr --conntype ble --connstring peer_name=Zephyr image test 597f80daf86f4d5bbe0a23af28167ae1de07cbd441b1c2db862e8dff17cf2037

Images:
 image=0 slot=0
    version: 1.0.0
    bootable: true
    flags: active confirmed
    hash: 096918ac22fbc49f7613ccabbd06853804c7422a7884239c212c7f70dd58976e
 image=0 slot=1
    version: 1.2.3
    bootable: true
    flags: pending
    hash: 597f80daf86f4d5bbe0a23af28167ae1de07cbd441b1c2db862e8dff17cf2037
Split status: N/A (0)

Press RESET button, wait ~2s, press RESET.
Log shows mcuboot messages after first (and second) reset:

$ cat /dev/ttyACM1 | ts '[%H:%M:%.S]'
[20:14:48.323953] *** Booting Zephyr OS build zephyr-v2.4.0-226-gb89548198d99  ***
[20:14:48.329925] [00:00:00.257,659] <inf> mcuboot: Starting bootloader
[20:14:48.339929] [00:00:00.264,129] <inf> mcuboot: Primary image: magic=good, swap_type=0x1, copy_done=0x3, image_ok=0x3
[20:14:48.346898] [00:00:00.274,414] <inf> mcuboot: Boot source: primary slot
[20:14:48.355929] [00:00:00.283,966] <inf> mcuboot: Swap type: test
[20:14:50.282960] *** Booting Zephyr OS build zephyr-v2.4.0-226-gb89548198d99  ***
[20:14:50.288973] [00:00:00.257,598] <inf> mcuboot: Starting bootloader
[20:14:50.298939] [00:00:00.264,068] <inf> mcuboot: Primary image: magic=good, swap_type=0x1, copy_done=0x3, image_ok=0x3
[20:14:50.305945] [00:00:00.274,322] <inf> mcuboot: Boot source: primary slot

Board never recovers.

Expected behavior
Swap of images should continue.
Impact
Remote firmware upgrade is not safe, i.e. can result in bricked devices in the field.
Environment (please complete the following information):

OS: Linux
Toolchain: Zephyr SDK 0.11.4
Commit SHA: dac6937cdacd4473f3e6d16964436cbf8c25b295 (2.4.99) + https://github.com/JuulLabs-OSS/mcuboot/pull/828 bugfix

Additional context
It seems that problems start here (https://github.com/JuulLabs-OSS/mcuboot/blob/aac99a14c9cdc8684fd4fbced130d3065a75ffea/boot/bootutil/src/loader.c#L1084):
        /*
         * If a swap was under way, the swap_size should already be present
         * in the trailer...
         */
        rc = boot_read_swap_size(image_index, &bs->swap_size);
        assert(rc == 0);

mcuboot reads 0xFFFFFFFF after swap was interrupted, because this is what was contained originally in app.hex (signed and confirmed) image trailer and that was never updated by mcuboot. This value is passed as copy_size to swap_run() and results in infinite loop there (https://github.com/JuulLabs-OSS/mcuboot/blob/aac99a14c9cdc8684fd4fbced130d3065a75ffea/boot/bootutil/src/swap_move.c#L448):
    while (1) {
        sz += sector_sz;
        /* Skip to next sector because all sectors will be moved up. */
        g_last_idx++;
        if (sz >= copy_size) {
            break;
        }
    }

I was able to reproduce what I suppose is a similar issue (also bricking) on the frdm_k64f but only seems to happen when using --pad --confirm in step 4; padding+confirming the image in the primary slot is completely unnecessary, would you mind giving a try without passing those flags? In the interim I'll check if I can reproduce the issue in the simulator, so hopefully it will be easy to fix.

padding+confirming the image in the primary slot is completely unnecessary, would you mind giving a try without passing those flags?

I confirm that everythink is fine without using --confirmed --pad flags, when flashing to fully erased slot.
The reason why I am using padded images is that I don't know whether there was some data on the (primary) slot to be flashed. Padded image makes sure it will replace all contents of image slot, because flash operation is prededed by erase of region where image lies.


Convert detected face to base64

Hi guys, i'm trying to write api that recive image, detect face, then return as string in base64. I tried to find functions in face-recognition, but without a luck. Do you have/know any solution for that?

There is no built in function in this package to convert images from or to base64. However you can do all that by using this package in conjunction with opencv4nodejs. If it's only about face detection and not face recognition, you could probably also simply use the CascadeClassifer in opencv4nodejs for detection with haar cascades.

Thank you for your answer. I'm creating app that will store detected faces in database and use it for learning, online. Can you point me a direction where i should look in opencv4nodejs for functions that would convert detected faces to base64?

You could simply compute the coordinates of the bounding boxes for the faces, with the face detector and extract the face images with opencv4nodejs mat.getRegion(x, y, width, height). To encode a cv.Mat to a base64 string simply use cv.imencode(mat)


Optimize some reductions

This uses np.nditer() where possible to optimize some reductions. Also, np.median() is improved to support >1D arrays and sped up on odd-sized arrays.
Based on PR #1787.

Current coverage is 87.96%

Merging #1789 into master will increase coverage by +0.07% as of 6611ea1

@@            master   #1789   diff @@
======================================
  Files          283     283
  Stmts        49305   49924   +619
  Branches      5035    5121    +86
  Methods
======================================
+ Hit          43336   43918   +582
- Partial        864     872     +8
- Missed        5105    5134    +29

Review entire Coverage Diff as of 6611ea1

Powered by Codecov. Updated on successful CI builds.

This appears to do what it suggests. Thanks for the patch.

This has merge conflicts now.

Ok, merged.


fix: allow events helper to specify output schema

#184  👈
main

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @pevisscher and the rest of your teammates on  Graphite


Convert to 0.5

So this works ... but maybe could maybe be better.  Looking forward to feedback.  :)

Going to address the rest of the comments tomorrow when I get in. Thanks a ton for reviewing!

@tboerger I Added some commits to address some of your concerns and left comments regarding the other ones.  Thanks again for reviewing this!

Did outside of this PR


Item module causes malformed input on dedicated servers

Cardinal-Components-Item will not let clients join a dedicated server. Attempting to do so results in a  malformed input error. It seems likely that this stems from MixinPacketByteBuffer, although I can't pinpoint what it's doing that causes this (besides reading a bad packet).
 Connecting to the server will fail, resulting in this:

Until then, mods using Cardinal-Components-Item seemingly won't work in multiplayer.

Trying this on a dedicated server outside of a dev environment is even less specific, all that gets spit out on the server it:
[00:45:57] [Server thread/INFO]: X joined the game
[00:45:57] [Netty Server IO #1/ERROR]: java.lang.NullPointerException
[00:45:57] [Server thread/INFO]: X lost connection: Internal Exception: io.netty.handler.codec.EncoderException: java.lang.NullPointerException
[00:45:57] [Server thread/INFO]: X left the game
[00:46:17] [Server thread/INFO]: Stopping the server```

It turns out that there's no clear way to reproduce this so far, but here's a gist containing a log:
clientside crash log
This is with CCA 2.4.0-nightly.1.16-pre2


Restart tasks in a background job

Codecov Report

Merging #226 (da0c2bf) into main (c71568f) will decrease coverage by 0.03%.
The diff coverage is 50.00%.

:exclamation: Current head da0c2bf differs from pull request most recent head b13c14f. Consider uploading reports for the commit b13c14f to get more accurate results

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
@@            Coverage Diff             @@
##             main     #226      +/-   ##
==========================================
- Coverage   78.46%   78.44%   -0.03%
==========================================
  Files         112      112
  Lines        6911     6912       +1
  Branches     1160     1161       +1
==========================================
- Hits         5423     5422       -1
- Misses       1320     1321       +1
- Partials      168      169       +1

Impacted Files
Coverage Δ

orchestrator/services/tasks.py
8.69% <0.00%> (ø)

orchestrator/services/processes.py
90.27% <58.33%> (-0.67%)
:arrow_down:

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


Nts loa and SIT flaky fix int

Lines of Accounting E2E
Fixes flaky formatting causing the following test to fail
https://app.circleci.com/pipelines/github/transcom/mymove/74644/workflows/333fc39d-183e-447d-b592-802ddb69953b/jobs/1315694/tests#failed-test-0
This is due to DateTimeFormat not sharing the same format as MomentJS which we use in our src code. MomentJS is not used within Playwright at this time due to additional setup required to get it compatible with the TypeScript check enforced through our e2e tests.
Previously, this would pass in August but the formatting fails for September.
SIT E2E
Fixed flaky SIT tests https://app.circleci.com/pipelines/github/transcom/mymove/74655/workflows/3b2861e7-f276-4be6-b40d-6911b9caf8d5/jobs/1315834
Due to month calculation diffs
Dashboard view

The day after today thru authorized end date (Today is already counted in the current SIT)

Aug 4 - Today

July 5 - Aug 4

Failing SSW server tests should be fixed in this PR: https://github.com/transcom/mymove/pull/13574/files

Found flaky SIT tests due to month issues - resolved

looks like the days are still off in the server_test fail

looks like the days are still off in the server_test fail

actually the fail is related to SSW
do we need to consider how we count days for all testing purposes?

Anthony caught this test failure, explained at the bottom of this PR: https://github.com/transcom/mymove/pull/13594
Fix is in this PR, not in int yet: https://github.com/transcom/mymove/pull/13574

do we need to consider how we count days for all testing purposes?

Since the SIT dashboard is populated entirely by the backent, I have some checks to make sure it works properly. For example, this snippet for the authorized end date double checks the backend calculation on the frontend https://github.com/transcom/mymove/pull/13613/files#diff-d804e95767522788e9051063bb6ce933aeea6e2d61dc03162a91ebfa190c8070R74-R79


Add a link from the planned recipe view back to the library view for that same recipe

It would be handy, while looking at the planned recipe, to reference the original recipe "template". Often the planned recipe has undergone edits that the larger recipe has not.

W/in PlannedRecipeController, the lo variable's value has an ingredientId property which is the library recipe the planned recipe was created from. It's not part of the RecipeFromPlanItem type, because its never mattered, but probably should be. The aggregateId might also be interesting, so if you've opened a planned subrecipe, you can navigate back to the top-level planned recipe, especially if you've moved the subrecipe out from under its parent on the plan, so you can bucket it separately or what have you.


Suggestions doesn't work in some letters in version 1.69.0

Does this issue occur when all extensions are disabled?: Yes

VS Code Version: 1.69.0
OS Version: Windows 10 21h2

Steps to Reproduce:
This work

When write 4 suggestions disappear

And "!" as well

It work with ctrl + space only

Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.69.0. Please try upgrading to the latest version and checking whether this issue remains.
Happy Coding!

Thanks for creating this issue! We figured it's missing some basic information or in some other way doesn't follow our issue reporting guidelines. Please take the time to review these and update the issue.
Happy Coding!

try without special settings
try without extensions
needs copy-paste-able source code and the language in use (screen shots are for illustration but usually useless)
needs precise steps - what did you type, what keybindings did you trigger, etc

The problem here all letters trigger quick suggestions menu but when user write any special character or any number for example p.bold*4 suggestions disappear and to show it again user must press Ctrl + Space.

See https://github.com/microsoft/vscode/issues/154375

/duplicate of #154375

Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for similar existing issues. See also our issue reporting guidelines.
Happy Coding!


Python bindings of integrated action model + Euler

In GitLab by @cmastalli on Jul 16, 2019, 16:50
null

In GitLab by @cmastalli on Jul 16, 2019, 16:50
assigned to @cmastalli

In GitLab by @cmastalli on Jul 18, 2019, 17:12
closed


Added hyperparameter tuning for RecurrentPPO

Hyperparameter tuning for RecurrentPPO was non-existent as hyperparams_opt.py did not accept 'ppo_lstm' as a valid argument
Description

Extended sample_ppo_params() to be called by sample_ppo_lstm_params(), trail is then updated with some lstm specific hyperparams, and "policy_kwargs" is updated
Added "tiny" to sample_ppo_params() to support smaller neural nets for the LSTM (solution 2 in issue #409)

Motivation and Context

closes #409
ReccurentPPO's hyperparameters can not be tuned by passing "ppo_lstm" to -optimize
[x] I have raised an issue to propose this change (required for new features and bug fixes)

Types of changes

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

Checklist:

[x] I've read the CONTRIBUTION guide (required)
[x] I have updated the changelog accordingly (required).
[ ] My change requires a change to the documentation.
[x] I have updated the tests accordingly (required for a bug fix or a new feature).
[ ] I have updated the documentation accordingly.
[x] I have reformatted the code using make format (required)
[x] I have checked the codestyle using make check-codestyle and make lint (required)
[x] I have ensured make pytest and make type both pass. (required)

Note: we are using a maximum length of 127 characters per line

updated changelog, let me know if anything else is required, I can add you as a contributor, seems a little late to create a branch (I will keep this in mind next time)


download dataset

I can not download the dataset such as  ADE20K , could you check that problem ?  I am in China .Thank you very much !

Sorry,I didn't finish reading the documentation.Now I can use sh file to download the dataset. the another queston is what does the semantic_score mean,if it is prob predicted by semantic network, the sum of its value must be 1,but I see there is a sample whose semantic_score is [0.0,0.0,0.392],I do not know what this value mean .hope to get your reply !

Those values are indeed semantic probabilities obtained by the semantic network. However, in the proposed method only the Top 3 semantic predictions are used (the actual model retrieves 150 semantic classes). That's why those 3 scores do not sum up to 1.
The paper contains further information about this.


Support RTEMS

It would be interesting to use micro-ROS on RTEMS (The Real-Time Executive for Multiprocessor Systems).
It is an RTOS used in space applications.
It offers POSIX interface.
A simple and cheap SBC like a BeagleBone Black would be sufficient to make tests on hardware (but everything can be done also virtually).
For now, I do not have the time to try alone,
Of course, if I ever find the time I will try on my own and share PRs if it's ok.

I discovered that no matter if in your custom toolchain you add a line such:
set(CMAKE_DL_LIBS "-lrtemscpu") # contains dlopen() family of symbols in RTEMS

the rcutils CMake will always have dl as ${CMAKE_DL_LIBS}. Like if the override would not work correctly.

I opended some PRs to fix the warnings.
Next step is waiting to retrieve my Beaglebone Black (which now I don't have with me, but it will be again sometime in the following weeks) and start some tests.

I believe the basic setup could be a RTEMS application with 1 task and 1 micro-ROS publisher.
Yes, I need to check if with my pre-existing setup I can already run a RTEMS-only demo in qemu, just to be sure that everything works before start breaking stuff.

I have some questions in my mind, but the first one is: do you believe or know wether it will be necessary to write some specific code to adapt to this RTOS, or everything shoud work out of the box because the target RTOS is a POSIX system? Do you have a list of steps for things to check?

I can't tell if this is a micro-ROS or RTEMS question. I can't imagine ROS needs anything from POSIX that RTEMS does not have. We have this guide in our documentation set (https://docs.rtems.org/branches/master/posix-compliance/index.html) which details how RTEMS aligns against various C and POSIX based standards.

EDIT: let me rephrase that: using generate_lib, is there any target-specific source code implementation needed to support micro-ROS, or I just need to use its API as normal when writing a task of my RTOS image?

If a package has a POSIX port which is geared to embedded environments (e.g. doesn't use fork/exec, graphics, etc.), then it often just compiles for RTEMS. The issues that must be addressed are RTEMS initialization and configuration and possibly contents of the initial filesystem.

Hello everyone, finally I got a clean RTEMS 5.1 erc32 BSP (sparc) built on my PC.
All standard tests ran in the simulator, so I was ready to start fiddling with microROS in a RTEMS app.
A year ago, I wrote this simple CMake template fort RTEMS.
I made it compile for erc32 and run with the simulator. Everything OK.
Now I started porting the ping-pong microROS app.
Here is the source pingpongport_1.zip.
I started copy-pasting some code from freeRTOS ping-pong example and up to now, the compiler errors are:
[build] Starting build
[proc] Executing command: /usr/bin/cmake --build /mnt/sdb/rtems_master/workspace/microROS/build --config Debug --target all -j 10 --
[build] [1/1 100% :: 0.132] Linking CXX executable HELLO
[build] FAILED: HELLO
[build] : && /mnt/sdb/rtems_master/rtems/5/bin/sparc-rtems5-g++  -B/mnt/sdb/rtems_master/rtems/5/sparc-rtems5/erc32/lib -B/mnt/sdb/rtems_master/rtems/5/sparc-rtems5/lib -specs bsp_specs -qrtems -mcpu=cypress -g   CMakeFiles/HELLO.dir/example.cpp.obj  -o HELLO -L/mnt/sdb/microros_ws/firmware/build -lmicroros && :
[build] /mnt/sdb/rtems_master/rtems/5/lib/gcc/sparc-rtems5/7.5.0/../../../../sparc-rtems5/bin/ld: /mnt/sdb/microros_ws/firmware/build/libmicroros.a(libmicrocdr-array.c.obj): in function `ucdr_serialize_array_uint16_t':
[build] /mnt/sdb/microros_ws/firmware/mcu_ws/eProsima/Micro-CDR/src/c/types/array.c:176: undefined reference to `_GLOBAL_OFFSET_TABLE_'
[build] /mnt/sdb/rtems_master/rtems/5/lib/gcc/sparc-rtems5/7.5.0/../../../../sparc-rtems5/bin/ld: /mnt/sdb/microros_ws/firmware/mcu_ws/eProsima/Micro-CDR/src/c/types/array.c:176: undefined reference to `_GLOBAL_OFFSET_TABLE_'
[build] /mnt/sdb/rtems_master/rtems/5/lib/gcc/sparc-rtems5/7.5.0/../../../../sparc-rtems5/bin/ld: /mnt/sdb/microros_ws/firmware/build/libmicroros.a(libmicrocdr-array.c.obj): in function `ucdr_serialize_array_uint32_t':
[build] /mnt/sdb/microros_ws/firmware/mcu_ws/eProsima/Micro-CDR/src/c/types/array.c:177: undefined reference to `_GLOBAL_OFFSET_TABLE_'
[build] /mnt/sdb/rtems_master/rtems/5/lib/gcc/sparc-rtems5/7.5.0/../../../../sparc-rtems5/bin/ld: /mnt/sdb/microros_ws/firmware/mcu_ws/eProsima/Micro-CDR/src/c/types/array.c:177: undefined reference to `_GLOBAL_OFFSET_TABLE_'
[build] /mnt/sdb/rtems_master/rtems/5/lib/gcc/sparc-rtems5/7.5.0/../../../../sparc-rtems5/bin/ld: /mnt/sdb/microros_ws/firmware/build/libmicroros.a(libmicrocdr-array.c.obj): in function `ucdr_serialize_array_uint64_t':
[build] /mnt/sdb/microros_ws/firmware/mcu_ws/eProsima/Micro-CDR/src/c/types/array.c:178: undefined reference to `_GLOBAL_OFFSET_TABLE_'
[build] /mnt/sdb/rtems_master/rtems/5/lib/gcc/sparc-rtems5/7.5.0/../../../../sparc-rtems5/bin/ld: /mnt/sdb/microros_ws/firmware/build/libmicroros.a(libmicrocdr-array.c.obj):/mnt/sdb/microros_ws/firmware/mcu_ws/eProsima/Micro-CDR/src/c/types/array.c:178: more undefined references to `_GLOBAL_OFFSET_TABLE_' follow
[build] /mnt/sdb/rtems_master/rtems/5/lib/gcc/sparc-rtems5/7.5.0/../../../../sparc-rtems5/bin/ld: /mnt/sdb/microros_ws/firmware/build/libmicroros.a(libmicroxrcedds_client-serial_transport_posix.c.obj): in function `uxr_read_serial_data_platform':
[build] /mnt/sdb/microros_ws/firmware/mcu_ws/eProsima/Micro-XRCE-DDS-Client/src/c/profile/transport/serial/serial_transport_posix.c:64: undefined reference to `poll'
[build] collect2: error: ld returned 1 exit status
[build] ninja: build stopped: subcommand failed.
[build] Build finished with exit code 1

In practice, two problems up to now:

undefined reference to `GLOBAL_OFFSET_TABLE'
undefined reference to `poll'

I suspect the second one is related to the simulator not having a serial port implemented, so I may fix it changing microROS build configuration to use network instead of serial port. But the first issue is the most critical IMHO, and I don't know how to proceed. Any help?

Seems that adding to rtems-colcon.meta the following:
"microcdr": {
            "cmake-args": [
                "-DUCDR_PIC=OFF"
            ]
        },

solved the GLOBAL_OFFSET_TABLE problem. Now I have the issue with the unimpemented poll for serial ports in erc32 architecture (sounds to me this is the core of the issue) and going on adding other code of the ping-pong demo to my RTEMS app until everything can be tested and demonstrated.

Seems that RTEMS deliberately does not support poll() call.
https://docs.rtems.org/releases/rtems-docs-4.11.1/bsp-howto/console.html
RTEMS relies on termios. I need to investigate how to maybe offer an alternative to the POSIX implementation
Micro-XRCE-DDS-Client/src/c/profile/transport/serial/serial_transport_posix.c

Email me at joel AT rtems dot org and I will email you back a quick start network example for zynq qemu that should help you. If you don't initialize the network stack, then there is no networking.

@joelsherrill I wrote to you by email but sadly no response... Today I set up my beaglebone black and now I'm stuck at the same point of setting up networking. Could you send me the example at<EMAIL_ADDRESS>? It would be very helpful for me.

@roncapat Not sure what happened. I don't see any email from you about this. But I went ahead and sent it. Poke me if you don't get it.

Thank you so much! Hope to share some project updates before Christmas :)

Working again on the subject.
This time I'm here to share a build issue related to glibc 2.46.
On my system (Ubuntu 20.04) I have sb-set-builder failing with the following, uninformative last line:
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 78: ordinal not in range(128)
Adding --log /path/to/logfile to the command line helps to get insights on what happened:
CC       libgio_2_0_la-gdbuserror.lo
../../glib-2.46.2/gio/gdbusauth.c: In function ‘_g_dbus_auth_run_server’:
../../glib-2.46.2/gio/gdbusauth.c:1295:11: error: ‘%s’ directive argument is null [-Werror=format-overflow=]
 1295 |           debug_print ("SERVER: WaitingForBegin, read '%s'", line);
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  CC       libgio_2_0_la-gdbusconnection.lo
  CC       libgio_2_0_la-gdbusmessage.lo
  CC       libgio_2_0_la-gdbusnameowning.lo
cc1: some warnings being treated as errors
make[4]: *** [Makefile:3624: libgio_2_0_la-gdbusauth.lo] Errore 1
make[4]: *** Attesa per i processi non terminati....
../../glib-2.46.2/gio/gdbusmessage.c: In function ‘g_dbus_message_to_blob’:
../../glib-2.46.2/gio/gdbusmessage.c:2698:30: error: ‘%s’ directive argument is null [-Werror=format-overflow=]
 2698 |       tupled_signature_str = g_strdup_printf ("(%s)", signature_str);
      |                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors

On the internet, I found only this reference to a simple patch to use whenever host GCC is version 9. However, I have GCC 8 as host compiler and GCC 7.5 as ARM compiler from RSB tools.
I tried to apply manually the patch to the source files and rebuild but files are probably being overwritten. Anyone has the solution to trigger a sb-set-builder rebuild without overwriting source files?

Another error while trying to build devel/qemu4:
/usr/bin/ld: linux-user/syscall.o: in function `do_syscall1':
/mnt/sdb/rtems-work/rtems-source-builder/bare/build/qemu-4.1.0-x86_64-linux-gnu-1/qemu-4.1.0/linux-user/syscall.c:7660: undefined reference to `stime'

the proper fix should be this one. Trying to follow the same patching logic of the glibc problem.

@joelsherrill I think I got to a good point. The task passes all allocations for the DDS, and now the application fails to establish a qemu-outgoing TCP connection to my local host. In fact, the connect() call fails and I receive no handshake on host side. Do you have hints on how to configure gateway or other parameters for outgoing connections from RTEMS app in qemu?

connect() from RTEMS QEMU guest tries to connect to microROS Agent on the TCP host port 8888. (<IP_ADDRESS>:8888) but returns EADDRNOTAVAIL, when using QEMU SLIRP which by default should allow outgoing packets to <IP_ADDRESS>. RTEMS is configured to use DHCP, as Joel told me to do in his tutorial.
Any suggestions about how to proceed?

Aaaand: IT WORKS!
PingPong example ran successfully on my machine after a very long weekend.
First of all, before forgetting it forever, here is what I found useful to set a tap network between host and qemu:
# For Network Bridging/TAP
# Set permissions of tun device
chown root.users /dev/net/tun
chmod g+rw /dev/net/tun

#Add a bridge, add eth0
brctl addbr br0
ifconfig eth0 <IP_ADDRESS> promisc
brctl addif br0 eth0
dhclient br0

# Create tap0
tunctl -t tap0 -u username #replace username by your username

# Enable tap0
brctl addif br0 tap0
ifconfig tap0 up

I used qemu from rtems-libbsd. My current command line is:
qemu-system-arm \
-no-reboot \
-serial null -serial mon:stdio \
-net tap,ifname=tap0 -net nic,model=cadence_gem,macaddr=0e:b0:ba:5e:ba:11 \
-nographic \
-M xilinx-zynq-a9 -m 256M \
-kernel <<<RTEMS exe file>>>

For now, the application connects to the host and set ups correctly all publishers and subscribers. The timer ticks every 2 secs and published a ping message, but unfortunately I can't see it while ros2 topic echo /microROS/ping.

Solved the bug. It was an issue on host->target communication, where the custom code for the DDS failed to poll presence of incoming data. Seems I was not resetting the FD_SET prior to calling select(). Now that everything works well, I do some cleanups and open a PR for the DDS Client.

If possible, I'd keep this Issue open. Since support was merged, now the next step would be to find a way to add scripting support for RTEMS build in this repo. When I will have more time I'll give it a try.

Rapid note about testing serial transport with QEMU:
command line:
qemu-system-arm \
-no-reboot \
-serial pty \
-serial mon:stdio \
-nographic \
-M xilinx-zynq-a9 \
-m 256M \
-kernel <<<RTEMS exe file>>>

When launched, a message like this is printed:
char device redirected to /dev/pts/3 (label serial0)

this means that on your host /dev/pts/3 is the port for the micro_ros_agent, while on RTEMS guest side the UART is /dev/ttyS0. Thus, in colcon.meta you have to configure rmw_microxrcedds with "-DRMW_UXRCE_DEFAULT_SERIAL_DEVICE=/dev/ttyS0".
Launch the micro_ros_agent with command line:
ros2 run micro_ros_agent micro_ros_agent serial --dev /dev/pts/3

and only then you can launch your RTEMS mros application.


Request friendlier nz-table-sort and nz-table-filter

I'm submitting a...

[ ] Bug report
[x] Feature request
[ ] Documentation issue or request
[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Support request => Please do not submit support request here

Current behavior

Now nz-table-sort output only a string value of sort way, and nz-table-filter is provided as a content container. Maybe these two could be more convenient used.
Expected behavior

nz-table-sort: input fieldname (string), sort data by executing method in NzTableSortComponent when nzValueChange is not defined.
nz-table-filter:: similar to nz-table-sort.

Maybe it's helpful when data is requested from remote server and network is not good.

Thanks for your advice, but sort and filter function in table is indeed complex, it have to support both server and local sort and filter, I think it is better to make it simple, that all users can define their own strategy.

supported in version 0.7.0 closed


grabbed frame doesn't look right with certain MP4 files

I've been using JCodec successfully for some MP4 files, but have encountered an unusual case.
When I grab a frame from the MP4 straight out of my Ricoh Theta it looks wrong, specifically it looks like this:

However, if I recode the MP4 (using Freemake Video Converter in my case) and grab the frame it looks right, specifically it looks like this:

Both MP4s look the same as each other (in other words, fine) when played in my video player.
I have tried a number of different ways to get the frame, and a number of different ways to save the frame, but they all give the same incorrect appearance with the "straight out of camera" MP4 (and the correct appearance with the recoded MP4).
I'd like to be able to grab the frames right from the MP4 that comes out of the camera rather than recoding it.  I'm hoping someone here might have encountered something similar and be able to offer a solution.  I searched around and couldn't find a matching question.
My current example code is:
	File origVideo = new File("filename.mp4");
	SeekableByteChannel bc = org.jcodec.common.io.NIOUtils.readableChannel(origVideo);
	MP4Demuxer dm = new MP4Demuxer(bc);
	FileChannelWrapper ch =  NIOUtils.readableChannel(origVideo);
	AWTFrameGrab8Bit fg = AWTFrameGrab8Bit.createAWTFrameGrab8Bit(ch);
	fg.seekToFramePrecise(1);
	Picture8Bit frameAsPicture = fg.getNativeFrame();
	BufferedImage frameAsImage = AWTUtil.toBufferedImage8Bit(frameAsPicture);
	ImageIO.write(frameAsImage, "png", new File("filename.png"));
	NIOUtils.closeQuietly(ch);
	dm.close();

My first intuition is this might be due to the gama and color settings in the MP4 header. In any case, could you upload the sample video so I can take a look?

Thanks.  Here's a zip file containing the straight-out-of-camera MP4 that I used for the above example of what's happening.
original.zip

Using an MP4Demuxer object for the original and recoded files I went in and compared the
getVideoTrack().getMeta().getCodec() objects and they were the same.
I compared the three individual things within the VideoCodecMeta object that comes back from  getVideoTrack().getMeta().getVideoCodecMeta() for each as well (size, pixelAsepctRatio, color) and all three were the same there too.
Could you point me in the right direction for finding those MP4 header differences and then in the right direction for dealing with those differences if/when I find them?  Thanks.

At first I saw this was related to brightness settings in MP4 header but now I think this may be a decoding artifact. In any case I need to have a closer look.

Apparently this video is using a feature called 'scaling matrix' which is not currently supported in JCodec. I will repurpose this bug into a feature request to support the scaling matrix.

Hello, @svitvitskiy! Are you planning to implement Support scaling matrix in h.264 decode in nearest future? And how "nearest" if yes?

We do, but not in the nearest month. I'd say next month.

@svitvitskiy ok, thank you.

I've got a problem. scaling matrix got broken afret editing metadata on MP4 with H.264
before edit metadata:
Matrix Structure 1 0 0 0 1 0 0 0 1
after edit metadata:
Matrix Structure 2e-05 0 0 0 2e-05 0 0 0 1.52587890625e-05
before edit meta:
SIDE DATA LIST
Side Data Type Display Matrix Displaymatrix 00000000: -65536 0 0 00000001: 0 -65536 0 00000002: 0 0<PHONE_NUMBER> Rotation -180
after edit meta:
SIDE DATA LIST
Side Data Type Display Matrix Displaymatrix 00000000: -1 0 0 00000001: 0 -1 0 00000002: 0 0 16384 Rotation -180
before:
TAGS
Creation Time 2018-08-03T04:32:38.000000Z
Language eng
Handler Name SoundHandle
after
TAGS
Rotate 0
Creation Time 2018-08-03T04:32:38.000000Z
Language eng Handler Name SoundHandle
(used https://www.get-metadata.com to analyze)


feat: Support datetime in Python (box/box-codegen#459)

Pull Request Test Coverage Report for Build<PHONE_NUMBER>
Details

46 of 47 (97.87%)  changed or added relevant lines in 15 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.1%) to 88.955%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

box_sdk_gen/internal/base_object.py
20
21
95.24%

Totals

Change from base Build<PHONE_NUMBER>:
0.1%

Covered Lines:
8416

Relevant Lines:
9461

💛  - Coveralls


Roll Flutter Engine from e61bc853acb2 to bd36636b9a83 (7 revisions)

https://github.com/flutter/engine/compare/e61bc853acb2...bd36636b9a83
2024-09-30<EMAIL_ADDRESS>Roll Dart SDK from 79863e31de87 to d9fb41a4b5ee (1 revision) (flutter/engine#55533)
2024-09-30<EMAIL_ADDRESS>Introduce a GN rule that (explicitly) generates a dart test wrapper (flutter/engine#55475)
2024-09-30<EMAIL_ADDRESS>Remove the need to use runZoned by replacing print statements (flutter/engine#55530)
2024-09-30<EMAIL_ADDRESS>Roll Skia from 6c89706638ee to 534633fb4bd9 (2 revisions) (flutter/engine#55531)
2024-09-30<EMAIL_ADDRESS>[Impeller] Create a libImpeller dylib and expose symbols. (flutter/engine#55526)
2024-09-30<EMAIL_ADDRESS>Added metal validation for `impeller_unittests (flutter/engine#55527)
2024-09-30<EMAIL_ADDRESS>Roll Skia from dfeeb199b226 to 6c89706638ee (2 revisions) (flutter/engine#55528)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Please CC bdero<EMAIL_ADDRESS>on the revert to ensure that a human
is aware of the problem.
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose
To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Commit queue failed; closing this roll.


Add rust supoort;

Please disregard my question in the issues, I figured there was slightly more going on in the code then simply changing the language to one of the supported by Leetcode.

Thank you for your commit!
Everything is good except that we don't know if it is really necessary to add a new README.html since we already have a README.md.
One possible inconvenience of adding a new README.html is that we need to synchronize the content of the two, which we may forget to do. Hence, unless it has some significant advantages, we hope to maintain only one README.
Please don't hesitate to tell us your opinions!


Fix systemd template

When MAX_LOCKED_MEMORY was not set it would leave an empty setting in
the systemd file which caused some errors.
Now we check if its actually set ( not undef ) before printing its
value.
Closes #362

just tested it on centos7, works fine. +1 for merge

Failure due to disk space issues on docker servers :-( Merging anyway since most did pass :-)


Class II alpha/beta chain pairing

Great idea to make this a separate tool, I've found a need for MHC parsing outside of prediction as well.
For class II alleles with alpha/beta chains, NetMHC requires them to be entered as paired alleles, but HLA typing usually reports the chains separately. I have a simple function to contribute for this

Hey @jfeala, sorry I didn't see this before. Do you want to add a helper which generates all pairs of alpha+beta chains? Sounds useful, want to open a PR?


PSFTeppCompletionResult - Unrecognized Command

Describe the bug
Steps to reproduce

GitHub> Create Template from AzOps-Accelerator
GitHub> Settings > Add secrets
GitHub>Actions>AzOps - Pull results in 'New-PSFTeppCompletionResult' unrecognized command

Screenshots

@FriedrichWeinmann notified me today that there's a new release of PSFramework which includes a fix for this issue.
I'm planning to test and update the module dependencies either by the end of this week or early next.

The required version of PSFramework has now been incremented which includes a fix for this issue.


Sphinx last version have a bug. Use stable version

:tada: This PR is included in version 0.4.2 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket: