Vite plugin for optimization

Package

[ ] lucide
[ ] lucide-angular
[ ] lucide-flutter
[ ] lucide-preact
[ ] lucide-react
[ ] lucide-react-native
[ ] lucide-solid
[ ] lucide-svelte
[ ] lucide-vue
[ ] lucide-vue-next
[ ] Figma plugin
[X] all JS packages
[ ] site

Description
While the new way of importing components in svelte using the full path works pretty well to avoid annoyingly long vite optimizations, i think its just bad DX. So after a bit of playing around i came up with a vite plugin that solves this issue.
function lucideSvelteImportOptimizer(): Plugin {
	return {
		name: 'lucide-svelte optimizer',
		transform(code, id) {
			const ms = new MagicString(code, { filename: id });

			ms.replace(
				/([ \t]*)import\s+\{(.*?)\}\s+from\s+['"]lucide-svelte['"];?/g,
				(match, whitespace: string, importNames: string) => {
					const hasSemi = match.endsWith(';');

					const imports = importNames
						.split(',')
						.map((v) => v.trim())
						.map((name) => {
							const path = name
								.split('')
								.map((c, i) => {
									const code = c.charCodeAt(0);
									return code >= 65 && code <= 90
										? (i === 0 ? '' : '-') + c.toLowerCase()
										: c;
								})
								.join('');

							return `${whitespace}import ${name} from 'lucide-svelte/icons/${path}'${hasSemi ? ';' : ''}`;
						});

					return imports.join('\n');
				},
			);

			if (ms.hasChanged()) {
				return {
					code: ms.toString(),
					map: ms.generateMap(),
				};
			}
		},
	};
}

I did not yet test if it works with aliases (eg. User as UserIcon) with other than that it works pretty well!
Use cases
<script>
  import { User, FolderCog } from 'lucide-svelte'
  // is transformed to
  import User from 'lucide-svelte/icons/user';
  import FolderCog from 'lucide-svelte/icons/folder-cog'
</script>

<User />
<FolderCog />

Checklist

[X] I have searched the existing issues to make sure this bug has not already been reported.

I have not checked out if other packages than lucide-svelte expose the icons via the .../icons/* path but if so it would work for any lucide package when used with vite

@david-plugge This is awesome thanks for sharing.
Aliases could be a problem, but not in the way you described. We currently have alias imports for certain icons, sometimes we rename icons when needed, we solve this by exporting the "old" name. But I think we can fix this.

@david-plugge  thank you so much, this has solved my problem over at tabler icons:
function tablerSvelteImportOptimizer(): import('vite').Plugin {
	return {
		name: 'tabler-svelte optimizer',
		transform(code, id) {
			const ms = new MagicString(code, { filename: id });
			ms.replace(
				/([ \t]*)import\s+\{([^;]*?)\}\s+from\s+['"]@tabler\/icons-svelte['"];/g,
				(match, whitespace: string, importNames: string) => {
					const hasSemi = match.endsWith(';');
					const imports = importNames
						.split(',')
						.map((v) => v.trim())
						.map((name) => {
							const path = name;
							return `${whitespace}import ${name} from<EMAIL_ADDRESS>? ';' : ''}`;
						});
					return imports.join('\n');
				}
			);

			if (ms.hasChanged()) {
				return {
					code: ms.toString(),
					map: ms.generateMap()
				};
			}
		}
	};
}

cool plugin, I had to modify it a bit to get it to work with icons with numbers in them, as well as new lines within the import.
Whilst i was there I also bodged in support for lucide aliases by checking against the .d.ts for each icon, I'm sure this pretty inefficient but its still faster than transforming all the icons
function lucideSvelteImportOptimizer(): Plugin {
	const aliases = readFileSync('node_modules/lucide-svelte/dist/aliases.d.ts', 'utf8');
	return {
		name: 'lucide-svelte optimizer',
		transform(code, id) {
			const ms = new MagicString(code, { filename: id });

			ms.replace(
				/([ \t]*)import\s+\{([^}]+)\}\s+from\s+["']lucide-svelte["'];/g,
				(match, whitespace: string, importNames: string) => {
					const hasSemi = match.endsWith(';');

					const imports = importNames
						.split(',')
						.map((v) => v.trim())
						.map((name) => {
							let path;
							const alias = aliases.match(
								new RegExp(`as ${name} } from '\\.\\/icons\\/(.+)\\.svelte';`),
							);
							if (alias) {
								path = alias[1]!;
							} else {
								path = name
									.split('')
									.map((c, i) => {
										const code = c.charCodeAt(0);
										return (code >= 65 && code <= 90) || (code >= 48 && code <= 57)
											? (i === 0 ? '' : '-') + c.toLowerCase()
											: c;
									})
									.join('');
							}

							return `${whitespace}import ${name} from 'lucide-svelte/icons/${path}'${hasSemi ? ';' : ''}`;
						});

					return imports.join('\n');
				},
			);

			if (ms.hasChanged()) {
				return {
					code: ms.toString(),
					map: ms.generateMap(),
				};
			}
		},
	};
}

Maybe someone wants to try https://www.npmjs.com/package/vite-plugin-barrel

get it works, for lucide-react, thank you for the script:
import { Plugin } from 'vite';
import MagicString from 'magic-string';

function lucideReactImportOptimizer(): Plugin {
  return {
    name: 'lucide-react-import-optimizer',
    transform(code: string, id: string) {
      const ms = new MagicString(code, { filename: id });

      ms.replace(
        /import\s+\{\s*([^}]+)\s*\}\s+from\s+['"]lucide-react['"]/g,
        (match: string, imports: string) => {
          const importStatements = imports
            .split(',')
            .map((imp: string) => {
              const [name, alias] = imp.split(' as ').map((s: string) => s.trim());
              const importName = alias || name;
              const kebabCaseName = name
                .replace(/([a-z])([A-Z])/g, '$1-$2')
                .toLowerCase();
              return `import ${importName} from 'lucide-react/dist/esm/icons/${kebabCaseName}';`;
            })
            .join('\n');
          return importStatements;
        }
      );

      if (ms.hasChanged()) {
        return {
          code: ms.toString(),
          map: ms.generateMap(),
        };
      }
    },
  };
}

export default lucideReactImportOptimizer;

Hi all, I made a proper Vite preprocessor for that purpose: https://github.com/WarningImHack3r/vite-plugin-lucide-preprocess.
Been using it for 3 months, includes an auto-updater and is thoroughly tested. Check it out!

Hi all, I made a proper Vite preprocessor for that purpose: https://github.com/WarningImHack3r/vite-plugin-lucide-preprocess. Been using it for 3 months, includes an auto-updater and is thoroughly tested. Check it out!

does not load using vite.config.ts
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
import { nxViteTsPaths } from<EMAIL_ADDRESS>import { nxCopyAssetsPlugin } from<EMAIL_ADDRESS>import lucidePreprocess from "vite-plugin-lucide-preprocess";

export default defineConfig({
  root: __dirname,
  cacheDir: '../../node_modules/.vite/apps/mobile-app',
  server: {
    port: 4000,
    host: 'localhost',
  },
  preview: {
    port: 4300,
    host: 'localhost',
  },
  plugins: [
    react(),
    nxViteTsPaths(),
    nxCopyAssetsPlugin(['*.md']),
    lucidePreprocess(),
  ],
  build: {
    outDir: '../../dist/apps/mobile-app',
    emptyOutDir: true,
    reportCompressedSize: true,
    commonjsOptions: {
      transformMixedEsModules: true,
    },
  },
  test: {
    watch: false,
    globals: true,
    environment: 'jsdom',
    include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}'],
    reporters: ['default'],
    coverage: {
      reportsDirectory: '../../coverage/apps/mobile-app',
      provider: 'v8',
    },
  },
});```

```      An error occurred while processing files for the @nx/vite/plugin plugin.
    - apps/backoffice/vite.config.ts: Build failed with 1 error:
  node_modules/esbuild/lib/main.js:1225:27: ERROR: [plugin: externalize-deps] "vite-plugin-lucide-preprocess" resolved to an ESM file. ESM file cannot be loaded by `require`. See https://vite.dev/guide/troubleshooting.html#this-package-is-esm-only for more details.
      Error: Build failed with 1 error:
      node_modules/esbuild/lib/main.js:1225:27: ERROR: [plugin: externalize-deps] "vite-plugin-lucide-preprocess" resolved to an ESM file. ESM file cannot be loaded by `require`. See https://vite.dev/guide/troubleshooting.html#this-package-is-esm-only for more details.```

  Error: Build failed with 1 error:
  node_modules/esbuild/lib/main.js:1225:27: ERROR: [plugin: externalize-deps] "vite-plugin-lucide-preprocess" resolved to an ESM file. ESM file cannot be loaded by `require`. See https://vite.dev/guide/troubleshooting.html#this-package-is-esm-only for more details.

My plugin is ESM only, try using a vite.config.mts to force ESM

for lucid-react the import path is: lucide-react/dist/esm/icons/

Good to know! Can you please open an issue?

@ericfennis I think that the DX could be drastically improved, without the need for such vite plugin optimizations, if the icons would be exported properly. Right now this is the generated file:
export { default } from "./triangle-alert.svelte";

I think that if that would be changed to:
import { default: TriangleAlert } from "./triangle-alert.svelte";
export default TriangleAlert;

then we would get autocomplete for the direct import.

@ericfennis I think that the DX could be drastically improved, without the need for such vite plugin optimizations, if the icons would be exported properly. Right now this is the generated file:
export { default } from "./triangle-alert.svelte";

I think that if that would be changed to:
import { default: TriangleAlert } from "./triangle-alert.svelte";
export default TriangleAlert;

then we would get autocomplete for the direct import.

If by 'Better DX' you mean that it would improve performance, I would be happily surprised to see that actually work.
The problem as I see it is that vite currently doesn't perform barrel optimization in dev mode.
NEXT is the only thing that I know that comes with this kind of barrel optimization out of the box.

this should also work
import TriangleAlert from "./triangle-alert.svelte";
export default TriangleAlert;

If by 'Better DX' you mean that it would improve performance, I would be happily surprised to see that actually work.

No, he is just talking about auto-completion. If you just export { default } from "./triangle-alert.svelte"; the ts-server does not know the name of the default export and therefore does not suggest it when typing TriangleAle.... If you name the default export it does.


console.log overescapes data structures

In a spec:
console.log {a: {b: 'c'}}
Output:
{"a":"{\"b\":\"c\"}"}

Thank you for reporting this issue and appreciate your patience. We've  notified the core team for an update on this issue. We're looking for a response within the next 30 days or the issue may be closed.

Fixed via the console implementation https://github.com/facebook/jest/blob/98fbf3f28fbff2181cb4450366e0163106755756/src/Console.js


git.countBadge tracked should only omit unstaged unknown

Is the plan still to fix this for the May 2017 milestone? I think it was only working on one release - 1.10. On 1.11 and 1.12 it was broken (in different ways), and the next version is about to be released soon...

Reminder for this issue, hopefully it can meet the milestone this time. Thanks.

Thanks. I'd like to test it before the milestone this time. Can I expect the fix at the next nightly build (today?)?

The previous insiders build had the issue, but the latest build seems fixed. Thanks :)


How to convert OpenCVSharp Mat/ Bitmap/IntPtr to Intel.RealSense.VideoFrame

Before opening a new issue, we wanted to provide you with some useful suggestions (Click "Preview" above for a better view):

Consider checking out SDK examples.
Have you looked in our documentations?
Is you question a frequently asked one?
Try searching our GitHub Issues (open and closed) for a similar issue.

All users are welcomed to report bugs, ask questions, suggest or request enhancements and generally feel free to open new issue, even if they haven't followed any of the suggestions above :)

Required Info

Camera Model
{ D435i }

Firmware Version
(Open RealSense Viewer 2.5.3)

Operating System & Version
{Win 10

Kernel Version (Linux Only)
<IP_ADDRESS>

Platform
PC

SDK Version
2.5.3}

Language
C# }

Segment
others

Issue Description
<Describe your issue / question / feature request / etc..>
Can any one tell me how to convert OpenCVSharp Mat/ Bitmap/IntPtr to Intel.RealSense.VideoFrame? Or Bitmap/IntPtr to VideoFrame??

Hi @leoteo1  https://github.com/IntelRealSense/librealsense/issues/2634 may be a helpful reference for converting cv::mat to rs2::frame.

I have tried to convert C++ to equivalent C# code but its still not work :(.
// Assuming you have an Image object called "image"
// and a Byte array called "buffer" managed by a Res object
int width = image.Width;
int height = image.Height;
// Get the number of bytes per row (assuming 16-bit depth)
int bytesPerRow = width * 2;
// Copy the data from the image into the buffer
Buffer.BlockCopy(image.Data, 0, buffer, 0, bytesPerRow * height);

There are no references available for applying the C++ information in the link to C#, unfortunately.

Hello,
My purpose is: I just want to convert the VideoFrame to OpenCVSharp Image for processing, afterward the processed image will be converted back to VideoFrame for displaying in WPF image.
Is there any sample code for realtime display OpenCVSharp Image in C#?
Thanks,

https://github.com/IntelRealSense/librealsense/issues/5582 and https://github.com/IntelRealSense/librealsense/issues/8226 have C# scripts that demonstrate use of OpenCVSharp

Case closed due to no further comments received.


Is this project being maintained?

If not, I would be more than happy to take on that responsibility. I love ReasonML and this project and I want to see it thrive. Application state management is an important aspect of the projects I work on, so having a well maintained library is crucial for me.
At the very least, please comment on my pull requests.

Damn it, just spent the last couple of hours trying to figure that curry error out - the one mentioned in one of your PRs (assuming it was something I had done due to this all being new territory for me).
@nlfiedler It might be worth just forking it at this point as it seems as though the original maintainers may have gone awol.

@wyze Do you have any suggestions for how to move forward with this project? You're in the reasonml-community, and have contributed to this repo in the past, so I'm hoping you know how to respond to questions about the maintenance of this project.

Hey Nathan,
Sorry for the delayed response. According to the readme in https://github.com/reasonml-community/meta it should be maintained by @rickyvetter. Looks like I do have permissions to merge PRs so I can take a look at them.
In the meantime, we can see if we can summon @glennsl and see about getting you added to the maintainers of this project.

I do monitor some of these threads, but I'm very removed from ReasonML so I can't add much. I lack the permissions to add someone else.

@nlfiedler Could you try to get hold of @rickyvetter on Discord? Or alternatively @chenglou, who should be able to reach Ricky IRL.
I don't want to go over their heads, especially since I'm not much involved in the community these days. But if all else fails, I think we can assign a new maintainer if three org members support it.

Hey folks! Apologies for being missing for a while here. I'm working mostly on some FB internal projects and have been somewhat ignoring open source stuff. This is my bad. Looking at the PRs first right now and then I'll look at the open issues.
If someone else is interested in helping/taking over maintenance, please reach out!

Closing this since things seem to be - at least for now - back on track. Thanks for the wakeup call. Please reach out to me any time about this repo if things aren't moving the direction you want. I am terrible at responding on github, but working to get better! And I am actually pretty good on all other mediums :)


global music PCA

Would be interested to know how PCA was run, i.e. labels for tracks (genre etc) included as well as track itself.  Great feature.

The PCA analysis incorporated top lyrics languages, artists, tracks, artist nationalities, and genres for each country. Sources for artist nationalities were Soundcharts, Popnable and Google searches, and the source for genres was Soundcharts.


move build from quay.io to local jenkins instance

we should be building all of our artifacts to grow our experience and ensure we are able to move our artifact generation when we want to.
we will need to create a makefile and a jenkins job for this artifact.  we should continue to publish to quay.io

blocked by samsung-cnct/k2#189

Is this different from #16?

I really liked this issue.


Aqara Cube | what button does what?

I cant get behind which of the 9 buttons in Homekit is what cube gesture.
Thanks

See https://github.com/dresden-elektronik/deconz-rest-plugin/issues/138#issuecomment-325101635 for an overview of the buttonevents deCONZ issues for the cube, and how the sides are layed out.  This is translated to HomeKit as follows:

The first six HomeKit buttons map to the 100x, 200x, ..., 600x events.  Single Press for flip, Long Press for push, and Double Press for double tap.   The side (ending) on top determines the button.  The starting side for flip is lost in the translation to HomeKit.
The seventh button is for the 700x events.  Double Press for drop and Long Press for shake.
The last two buttons are for rotation left and right.  Single Press for an angle < 45°, Double Press for an angle between 45° and 90°, and Long Press for an angle > 90°.

Great overview, thanks

The last two buttons are for rotation left and right.  Single Press for an angle < 45°, Double Press for an angle between 45° and 90°, and Long Press for an angle > 90°.

Hi, I don't really get your 'the last two buttons' remark. Do you mean button 6 and 7? After pairing I have 6 buttons, each with three different 'tap' types. Next to that I have a 7th button with only two 'tap' types. However, I don't find any buttons relating to the rotational movement of the cube. Did I mess up the pairing?

No, buttons 8 and 9.  If they don’t show, most likely deCONZ hasn’t exposed the second ZHASwitch resource for the Analog Input cluster 0x000c on endpoint 0x03.

No, buttons 8 and 9. If they don’t show, most likely deCONZ hasn’t exposed the second ZHASwitch resource for the Analog Input cluster 0x000c on endpoint 0x03.

Sorry to be bothering you, but does this mean I can't use the rotational switches using your homebridge-hue plugin?

No, buttons 8 and 9. If they don’t show, most likely deCONZ hasn’t exposed the second ZHASwitch resource for the Analog Input cluster 0x000c on endpoint 0x03.

Meaning I should re-pair the device?

Probably.  You might also try reading the Basic cluster attributes in the deCONZ GUI while searching for new devices.
If memory serves, there were several issues causing deCONZ not to expose the second ZHASwitch.  You might want to check https://github.com/dresden-elektronik/deconz-rest-plugin/issues.
You might want to double-check that:

The deCONZ GUI shows three endpoints; and
The REST API plugin exposes two ZHASwitch /sensors resources, one for the digital events (with a uniqueid ending in -02-0012) and one for the analog events (ending in -03-000c).

Interesting I found this .. my recommendation would be to check the zigbee adapter for iobroker .. the dev has managed to make the objects quite understandable. In comparisson (and I am a complete newbie to conbee) what I get out of the deconz iobroker adapter (API call) is not understandable at all.
I am not much into clusters and endpoints - I take the user perspective as a non-dev who automates his home.


tweak to make clearer some implicit dependencies

Signed-off-by: Jordan Keister<EMAIL_ADDRESS>solves #67

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 69.88%

Totals

Change from base Build<PHONE_NUMBER>:
0.0%

Covered Lines:
348

Relevant Lines:
498

💛  - Coveralls


Speedup fetch

Changed Selenium to httpx, which made the script up to 15 times faster
The script usage has not changed, the output data.json has the same format as before

Thanks for your PR! I will test your combined changes on a new branch.


Why  is implemented in terms of  ?

Hi,
I am new to Purescript. As I was learning about Monad Transformers Stack, how many different types of Monad Transformers are there and how they are implemented,  I was going through the code and felt you have over-implemented the Observable a by declaring it in terms of ObservableT Identity as it could just be equal to ObservableImpl a. You are using a lot of unwrap*** functions which I felt was unnecessary and a performance burden coz if you look at the implementation of MaybeT. It's just wrapping already defined Maybe a type (which in this case is ObservableImpl a). So propose to rename ObseravbleImpl a to Observable a and take out all the unnecessary code. Also, you should also add the instances for MonadState, MonadTell, MonadEffect and so on as done in the implementation of MaybeT (if they make sense for ObservableT).

Thanks for the question and issue.

over-implemented the Observable a by declaring it in terms of ObservableT Identity as it could just be equal to ObservableImpl a.

It's much more convenient to use the monad transformer like we currently have.

The transformer means we can derive ObservableT a from a. Otherwise we'd have to write new functions every time we define a new newtype.

There's very little impact on performance.

Am I missing something? If so would you be able to elaborate? Otherwise we can close this issue.


refactor: convert to a hybrid ESM/CommonJS package

After migrating zwave-js to a hybrid ESM/CommonJS package, I noticed that Z-Wave JS UI contains both CommonJS and ESM sources of the same files in the bundle. I believe this is because Z-Wave JS Server is still CommonJS.
This PR converts the package into an ESM/CommonJS hybrid, meaning it supports being imported as ESM, as well as required from CommonJS.

Confirmed to be working when compiling the HA addon with this. Z-UI's bundle size is down to old levels aswell.


[Bug]: ReAct agent Action Input parser does not handle multiline input

Bug Description
I am using the ReAct agent with a complex tool that requires many lines of input.  The agent succesfully generates the Agent Input, but it's on multiple lines, and the regex does not handle that.
https://github.com/jerryjliu/llama_index/blob/9fd16c9e809e8146f2663709003fe4c5d235e4f5/llama_index/agent/react/output_parser.py#L20

Version
0.7.13
Steps to Reproduce
from llama_index.agent.react.output_parser import extract_tool_use

test_str = """\
Thought: Now that I have both the pre-migration and post-migration code... I will use the code_writer tool to write the initial code.
Action: code_writer
Action Input: {
  "working_file": "",
  "instructions": "do stuff",
  "context": "some context {"key": "maybe there's a nested json here"}
}
let's add some garbage in here too.
"""

extract_tool_use(test_str)

output:
('Now that I have both the pre-migration and post-migration code... I will use the code_writer tool to write the initial code.',
 'code_writer',
 '{')

A different implementation the simple regexs the outermost {} after Action Input might be better.
from typing import Tuple
import re
def my_extract_tool_use(input_text: str) -> Tuple[str, str, str]:
    pattern = r"\s*Thought:(.*?)Action:(.*?)Action Input:\s*(\{.*\})"

    match = re.search(pattern, input_text, re.DOTALL)
    if not match:
        raise ValueError(
            "Could not extract tool use from input text: {}".format(input_text)
        )

    thought = match.group(1).strip()
    action = match.group(2).strip()
    action_input = match.group(3).strip()
    return thought, action, action_input

print(my_extract_tool_use(test_str))

('Now that I have both the pre-migration and post-migration code... I will use the code_writer tool to write the initial code.', 'code_writer', '{\n  "working_file": "",\n  "instructions": "do stuff",\n  "context": "some context {"key": "maybe there\'s a nested json here"}\n}')

Relevant Logs/Tracbacks
No response

Thanks for raising this bug!
One concern with the proposed change. This would assume the action input is always surrounded by braces right?
This might be too strict for other tools that take arbitrary str input.

pattern = r"\s*Thought:(.*?)Action:(.*?)Action Input:\s*(\{.*\})
Yes, this would greedily match {...} after Action Input: and any amount of whitespace, but given that it's in the ReAct tool subfolder, it makes sense to customize it for that purpose.  The ReAct tools is instructed to to format its output as follows:
Thought: I need to use a tool to help me answer the question.
Action: tool name (one of {tool_names})
Action Input: the input to the tool, in a JSON format representing the kwargs (e.g. {{"text": "hello world", "num_beams": 5}})

Please use a valid JSON format for the action input. Do NOT do this {{'text': 'hello world', 'num_beams': 5}}.


Proposal - Allow JS config file

Hi, awesome extension of the original FoldersLint package!
I am interested in using this internally within my organisation and would like the ability to define some default configs that can be extended and reused
To enable this, I am proposing the package also accept a JS file (.folder-structure-lint.js) with the config exported as a default export.
Would you accept a PR facilitating this?

Yes, that’s definitely something I think should exist. Thank you. I’ll do what I can to help if needed.

Also @dmastrorillo, please let me know if you or any your peers have additional concerns that should be addressed. Thanks!


Youtube-dl cuts connection between syncplay and mpv

Playing any youtube video will cut the connection between mpv and syncplay. The video plays fine, but seeking/pausing/changing video doesn't work anymore, syncplay automatically quits after 60 seconds because it can't detect the player, and messages don't appear in the GUI. (typing a message will send it correctly, though)
arch linux, latest syncplay appimage release, mpv 0.30.0, youtube-dl-git (built on 2019-11-28)

Things work fine for me on Windows when I use mpv and YTDL, so the issue might be the AppImage. Does it work fine if you run Syncplay through other means on Arch?

Same thing happened before I updated, back when I was using the AUR package. (switched to appimage temporarily because of the pyside bug)

I've just tried this on my Debian with mpv 0.30.0, youtube-dl 2019.09.28 and Syncplay git master. It works as you'd expect, though my youtube-dl is 2 months old.
Do you have an easy way to test with older version of youtube-dl?

Bug present as far back as youtube-dl 2019-10-29, can't test with older versions as they do not run with latest python on arch
Can also confirm it happens whenever youtube-dl handles a video, not just youtube
This doesn't happen when I try to load a .webm directly from an url, since that seems to be handled directly by mpv with no need for ytdl.

Fixed by removing "profile=gpu-hq" from my mpv config, which apparently interacted weirdly with syncplay on my machine.


Exceptions in Logs. Home Assistant becomes unresponsive. Closing tab and opening again is a workaround.

Release with the issue:
v1.1.0
Last working release (if known):
Browser and Operating System:
Edge / Windows 10
Logger: frontend.js.latest.202108300
Source: components/system_log/__init__.py:190
First occurred: 4:34:08 PM (11 occurrences)
Last logged: 4:39:01 PM

http://XYZ/hacsfiles/frigate-hass-card/frigate-hass-card.js?hacstag=394082552110:491:34 Uncaught TypeError: this._elementResized is not a function

Additional information:

What version of Home Assistant are you running?

core-2021.9.7
supervisor-2021.09.6
Home Assistant OS 6.4

Thanks. Last one -- what are  you doing when this happens? From that  line of code, looks like maybe you're live viewing a camera -- but perhaps a camera that isn't a Frigate stream camera (e.g. a different camera, or a Frigate MQTT snapshot camera?)

Frigate stream camera - live view only, all was working fine with earlier release. This situations happens randomly but frequently.
Sometimes this creates a repro - If I try editing the lovelace UI, make some changes, switch tabs, come back to the tab in a few minutes.
Let me know if anything else I can tell you that helps.

I've found a change to the HA frontend between your version of HA, and mine, that removes that function in question. I am going to try to reproduce on my end with a cutting edge version of HA. This bug is in a place that could be more than 1 of the issues you have reported.
I have failed to reproduce any of your issues in Edge with my version of Home Assistant and a tall/portrait camera.

I seem to have the latest version of HA as best as I can tell. If you have
any potential fixes or private release, I can try it for you.
On Wed, Sep 29, 2021 at 10:15 PM Dermot Duffy @.***>
wrote:

I've found a change to the HA frontend between your version of HA, and
mine, that removes that function in question. I am going to try to
reproduce on my end with a cutting edge version of HA. This bug is in a
place that could be more than 1 of the issues you have reported.
I have failed to reproduce any of your issues in Edge with my version
of Home Assistant and a tall/portrait camera.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/dermotduffy/frigate-hass-card/issues/94#issuecomment-930790696,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ATOFJSUCTGHXZKM4EZGPN3DUEPW77ANCNFSM5FBA57WQ
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

Good news: I can reproduce it! (Using a bleeding edge Home Assistant).

@utkarshjain00 -- would you mind trying this out (since you offered -- thank you!):
frigate-hass-card.zip

You should be able to unzip  and  drop into your /www/community/frigate-hass-card/ directory (
(Please delete the file(s) in there before hand so you  don't get stuck with the old build).
Make sure you clear your browser cache.

This should fix this issue, but also may fix https://github.com/dermotduffy/frigate-hass-card/issues/90 .

I still see some exceptions in the logs, even after clearing cache, reloading browser etc. Having said that, things seem to be working fine in the limited testing I have done so far. Yes, it seems to have fixed #90 too.
`
Logger: frontend.js.latest.202108300
Source: components/system_log/init.py:190
First occurred: 11:24:54 PM (110 occurrences)
Last logged: 11:25:20 PM
http://XYZ/hacsfiles/frigate-hass-card/frigate-hass-card.js?hacstag=394082552110:491:34 Uncaught TypeError: this._elementResized is not a function
`

Great that it works!
The exception is still complaining  about the same line 491, which used to -- but no longer -- contains a reference to this._elementResized. This makes me think somehow you still have something cached. Maybe try from an Incognito/InPrivate window just to be sure? On my side, I only see that error message before my change, but not after.

No problem! Thanks for all the good work and such a quick turnaround on all the bugs.
Yes, I think you are right. The errors are likely from multiple devices I have where I view the cards. As I refresh/reload the devices, exceptions are going away.


output NaN value when training

Hi, your paper and code are very helpful.
I try to reproduce your results, but in training step, just in Fold 1 and epoch 1, the model outputs all NaN values (shape is [72, 2]).
Why is this happen, how can i fix it?
I will be really appreciate for your response!

Hi Liu - It maybe Thanks for reaching out! Regarding the NaN outputs you're seeing, it’s possible that this is due to some instability at the very beginning of training, which might stabilize as the model continues to train. Since softmax is involved, it could initially produce extreme values that cause this behavior, but as training progresses, it should correct itself.
I’d recommend letting the model run for a few more epochs to see if the NaN issue resolves itself. If the problem persists beyond the initial stages, it might help to adjust a few settings:

Lower the learning rate
Check if the input data contains any NaN or Inf values

Thanks for your reply @zhenyuanlu !
I have tried a lower learning rate (0.001 -> 0.00001) and more training epochs (1 -> 20), and the output result of all rounds are all NaN values.
config.json is
{
    "name": "LOSO_0_vs_4",
    "n_gpu": 1,
    "arch": {
        "type": "PainAttnNet",
        "args": {
        }
    },
    "data_loader": {
        "args":{
            "batch_size": 128,
            "num_folds": 86
        }
    },
    "optimizer": {
        "type": "Adam",
        "args":{
            "lr": 0.00001,
            "weight_decay": 0.001,
            "amsgrad": true
        }
    },
    "metrics": [
        "accuracy"
    ],
    "trainer": {
        "epochs": 20,
        "save_dir": "saved/",
        "save_period": 30,
        "verbosity": 2,
        "monitor": "min val_loss"
    },
    "label_converter": {
        "0": 0,
        "1": -1,
        "2": -1,
        "3": -1,
        "4": 1
    }
}

I tried other BioVid biosignals, and interestingly, only GSR (EDA) had this problem, ECG and EMG did not have NaN outputs. I checked the differences between GSR and other two signals, GSR seems to have smaller variance and flatter waveforms.

I tried more experiments on ECG. Validation loss and validation accuracy seem to be less than ideal, especially since validation loss is known to be maintained at 0.5, that is, 0 or 1 for all validation samples in binary classification. Is this some kind of overfitting, or is there something wrong with the model itself ?
Fold 1

Fold 5

Fold 10

This seems like overfitting to me, but the accuracy plot suggests that there’s no improvement at all.

Please follow the paper guideline, set leave-one-out cross-validation (LOOCV), which means set $k$=87.
Make sure you’ve installed the correct versions of the dependencies as listed in the README.
You might want to try adjusting the learning rate to 1e-03.
Set epoch as 100


syscall: syscall.SIGABRT not defined for Plan 9

The x/tools/cmd/stress package uses it and cannot be built for Plan 9.
See e.g.: http://farmer.golang.org/temporarylogs?name=plan9-386&rev=883bc6ed0ea815293fe6309d66f967ea60630e87&st=0xc829582fc0&subName=tools&subRev=32dcbb4ccca1d39fc73d6d9707d72e31d53fa0e1

I've a fix for this issue. I'll send a CL once the Go 1.6 tree will be open.

Do you want to send a fix?

I've implemented a special "abort" note as _SigThrow, which causes
the sighandler to print a stack trace and exit.
Does it sound good to you?


⚠ Samsung has degraded performance

In 8128ee5, Samsung (https://samsung.com) experienced degraded performance:

HTTP code: 200
Response time: 2620 ms

Resolved: Samsung performance has improved in 7b00d58.


feat(gcs): allow unauthenticated requests

Which issue does this PR close?

Closes https://github.com/apache/opendal/issues/4963
What changes are included in this PR?
Introduction of:

allow_anonymous
disable_vm_metadata
disable_config_load

to GcsConfig and their corresponding plumbing within GcsCore.

Are there any user-facing changes?
Changes are internal only.

I see there's the use of an AtomicBool for tracking previously loaded credentials within the S3 core, is that relevant to also do with this GCS change or better for another PR?

That's fine to include in another PR.

Perhaps you might be interested in assisting with https://github.com/apache/opendal/issues/4876 :laughing:


PDF rendering issue with missing text layer

Attach (recommended) or Link to PDF file here: file.pdf
Configuration:

Web browser and its version: Firefox 102.0.1
Operating system and its version: Windows 7 x64
PDF.js version: the one included in Firefox 102.0.1
Is a browser extension: no

Steps to reproduce the problem:

Open the pdf in firefox
The text layer quickly disappears

What is the expected behavior? (add screenshot): Text layer present.

What went wrong? (add screenshot)

WFM, using PDF.js version 2.15.259 in Firefox Nightly 104.
Note that the invisible textLayer, which is what allows you to select/copy text and search in the document, should actually still be present. What more likely happens, in your case, is that the images that make up the document are not rendered as intended.
So, are there any error messages in the console?

WFM, using PDF.js version 2.15.259 in Firefox Nightly 104.
Note that the invisible textLayer, which is what allows you to select/copy text and search in the document, should actually still be present. What more likely happens, in your case, is that the images that make up the document are not rendered as intended. So, are there any error messages in the console?

You are right, the text is still searchable. The browser console displays 'TYPE1STANDARD' is an invalid string label when the text image disappears after being displayed briefly.
How do I figure out which version of PDF.js is used by firefox? The issue is also present in Zotero 6.0.9 which uses PDF.js, but it's unclear to me which version.

The browser console displays 'TYPE1STANDARD' is an invalid string label when the text image disappears after being displayed briefly.

That message should be completely unrelated to this issue. Can you please check the web console instead, opened with Ctrl + Shift + K, since I'm not sure if the browser console will contain all possibly relevant messages?
Also, note that the image is likely never actually becoming visible in your case. What actually happens is that this PDF document first (visibly) renders its text-content using standard PDF text-rendering operators, and that's then being hidden before the image is (supposed to) being rendered. The issue, without being able to reproduce it myself, seems to happen only at that last step.

How do I figure out which version of PDF.js is used by firefox?

It's being printed in the web-console when a PDF document is opened. Also, you may want to test using Nightly: https://nightly.mozilla.org/

web console:

The last warning appears when the text disappears.
I will try to test nightly later.


Install, Readme etc.

Hi all,
if I try with ruby-2.3.3 it says at bundle install:
The git source git://github.com/gogovan/delayed_job.gituses thegitprotocol, which transmits data without encryption. Disable this warning withbundle config git.allow_insecure true, or switch to the httpsprotocol to keep your data secure. The git sourcegit://github.com/gogovan/delayed_job_active_record.gituses thegitprotocol, which transmits data without encryption. Disable this warning withbundle config git.allow_insecure true, or switch to the https protocol to keep your data secure. Your Ruby version is 2.3.3, but your Gemfile specified 2.4.1
If I tell him to use ruby-2.4.1:
/usr/lib/ruby/2.3.0/rubygems/dependency.rb:319:in to_specs': Could not find 'bundler' (>= 0.a) among 17 total gem(s) (Gem::LoadError)
Checked in 'GEM_PATH=/home/myuser/.rvm/gems/ruby-2.4.1:/home/myuser.rvm/gems/ruby-2.4.1@global', execute gem env for more information
from /usr/lib/ruby/2.3.0/rubygems/dependency.rb:328:in to_spec' 	from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_gem.rb:65:in gem'
from /usr/local/bin/bundle:22:in <main>'
gem env says:
`RubyGems Environment:

RUBYGEMS VERSION: 2.6.11
RUBY VERSION: 2.4.1 (2017-03-22 patchlevel 111) [x86_64-linux]
INSTALLATION DIRECTORY: /home/myuser/.rvm/gems/ruby-2.4.1
USER INSTALLATION DIRECTORY: /home/myuser/.gem/ruby/2.4.0
RUBY EXECUTABLE: /home/myuser/.rvm/rubies/ruby-2.4.1/bin/ruby
EXECUTABLE DIRECTORY: /home/myuser/.rvm/gems/ruby-2.4.1/bin
SPEC CACHE DIRECTORY: /home/myuser/.gem/specs
SYSTEM CONFIGURATION DIRECTORY: /etc
RUBYGEMS PLATFORMS:

ruby
x86_64-linux

GEM PATHS:

/home/myuser/.rvm/gems/ruby-2.4.1
/home/myuser/.rvm/gems/ruby-2.4.1@global

GEM CONFIGURATION:

:update_sources => true
:verbose => true
:backtrace => false
:bulk_threshold => 1000

REMOTE SOURCES:

https://rubygems.org/

SHELL PATH:

/home/myuser/.rvm/gems/ruby-2.4.1/bin
/home/myuser/.rvm/gems/ruby-2.4.1@global/bin
/home/myuser/.rvm/rubies/ruby-2.4.1/bin
/home/myuser/.rvm/bin
/home/myuser/.rbenv/plugins/ruby-build/bin
/home/myuser/.rbenv/shims
/home/myuser/.rbenv/bin
/home/myuser/bin
/home/myuser/.local/bin
/usr/local/sbin
/usr/local/bin
/usr/sbin
/usr/bin
/sbin
/bin
/usr/games
/usr/local/games
/snap/bin
`
Any ideas?

The first set of warnings can be ignored. I've silenced them in the latest version on master (pushed a few moments ago).
As for the second error, run gem install bundler and try again.


Use one method for querying on Chargeback subclass

Purpose or Intent

Use is_db_chargeback? instead of chargeback_model method
Refuse empty string in is_db_chargeback?
Other places were found for using method  is_db_chargeback?

Links

issue https://github.com/ManageIQ/manageiq/issues/9456
https://github.com/ManageIQ/manageiq/pull/8406

cc @martinpovolny @zeari
@miq-bot add_label ui
@miq-bot add_label chargeback
@miq-bot add_label refactoring

@martinpovolny @lpichler Is this darga/yes or darga/no?


Tado operation_mode --> off not working on >0.89.2 other modes unaffected

Home Assistant release with the issue:
0.91.1
Last working Home Assistant release (if known):
0.89.2
Operating environment (Hass.io/Docker/Windows/etc.):
Hass.io on a RBPi3
Component/platform:
Tado
Description of problem:
cannot switch Tado operation_mode to OFF. all other states are working
Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):
- id: '1526671873416'
  initial_state: true
  alias: Badezimmer Tado Fenster OFF
  trigger:
  - entity_id: binary_sensor.fenster_badezimmer
    platform: state
    to: 'on'
  condition: []
  action:
  - data:
      entity_id: climate.badezimmer
      operation_mode: 'Off'

Traceback (if applicable):
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/automation/__init__.py", line 380, in action
    await script_obj.async_run(variables, context)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/script.py", line 131, in async_run
    await self._handle_action(action, variables, context)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/script.py", line 210, in _handle_action
    action, variables, context)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/script.py", line 299, in _async_call_service
    context=context
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/service.py", line 88, in async_call_from_config
    domain, service_name, service_data, blocking=blocking, context=context)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/core.py", line 1138, in async_call
    self._execute_service(handler, service_call))
  File "/usr/local/lib/python3.7/site-packages/homeassistant/core.py", line 1160, in _execute_service
    await handler.func(service_call)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/entity_component.py", line 188, in handle_service
    self._platforms.values(), func, call, service_name
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/service.py", line 314, in entity_service_call
    future.result()  # pop exception if have
  File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/service.py", line 328, in _handle_service_platform_call
    await getattr(entity, func)(**data)
  File "/usr/local/lib/python3.7/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/tado/climate.py", line 248, in set_operation_mode
    self._control_heating()
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/tado/climate.py", line 366, in _control_heating
    self._store.set_zone_overlay(self.zone_id, CONST_OVERLAY_MANUAL)
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/tado/__init__.py", line 122, in set_zone_overlay
    self.tado.setZoneOverlay(zone_id, mode, temperature, duration)
  File "/usr/local/lib/python3.7/site-packages/PyTado/interface.py", line 287, in setZoneOverlay
    data = self._apiCall(cmd, "PUT", post_data)
  File "/usr/local/lib/python3.7/site-packages/PyTado/interface.py", line 81, in _apiCall
    response = self.opener.open(req)
  File "/usr/local/lib/python3.7/urllib/request.py", line 531, in open
    response = meth(req, response)
  File "/usr/local/lib/python3.7/urllib/request.py", line 641, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/local/lib/python3.7/urllib/request.py", line 569, in error
    return self._call_chain(*args)
  File "/usr/local/lib/python3.7/urllib/request.py", line 503, in _call_chain
    result = func(*args)
  File "/usr/local/lib/python3.7/urllib/request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 422:

Additional information:
I've been using this automation for a long time but ever since updating to anything newer than 0.89.2 switching my Tado to off does not work. I have a similar automation to switch the Tado back on when a window is closed. this still works as intended. There has been a bug reports by @wmalgadey  in the last few days and a PR was merged but the problem still persists for me.

Same for me. It looks like it started when Tado switched the API endpoint. Home Assistant had troubles querying it until the endpoint name was not changed in the code. It was querying the current status successfully, however changing values never worked since.

Duplicate of #22290

PR merged doesn't released. It will be 0.91.2


Default DHCP broadcast set to ''.

It will be derived from IP and subnet mask, unless set explicitly in CLI
or config file. Fixes #132.

@lqu has this been tested? @psychomario if you approve (and it's been tested) I'll do a squash merge.

@mmattioli I tested it manually in my environment (virtrualbox internal network). Is there a standard or automated test to run?

Nope, we don't have any testing framework unfortunately.
@mmattioli Looks good to me, go ahead and merge, Thanks!
@lqu Thanks for your contribution!


This is just a test and will NEVER be checked in

/azp run java - core - ci

@JimSuplizio If the testing is done, could you please close this PR?


[Existing API Name] : Universities Worldwide API

Brief Description 🤓
The Universities Worldwide API provided by Hipolabs is a public API that allows users to search for universities globally. This API is particularly useful for educational applications, research purposes, or any platform that needs to display information about universities.
Provide reference!
For more information on the Universities Worldwide API, you can visit the official documentation provided by Hipolabs:
Hipolabs Universities API
Select the open source program you are contributing to
Other
Code of Conduct

[X] I follow CONTRIBUTING GUIDELINES of this project.

Greetings @pankaj-bind🎀 ! , We are excited to have you dive into another issue with us!🚀
Your involvement in our project has been invaluable, and we're confident that your skills and insights will help us conquer this challenge😇.  Use command /gssoc24 to self assign the issue.  This issue represents an exciting opportunity for us to improve and enhance our project, and we are thrilled to have you on board.
We request you to follow CONTRIBUTING GUIDELINES.
Looking for your PR soon!
In case of any issues, you can contact us on Discord.❣

/gssoc24

please merge this PR

Hey @pankaj-bind ! I wanted to inform you that we have closed issue.Thank you for your understanding, and we look forward to your continued engagement with our repository🤗.
In case of any issues, you can contact us on Discord.
Thank you! ❣
Happy Coding! ✨
Will See you soon❣


setup github pipelines and rules

Hey Josh, I was wondering if you could provide some clarification on what this issue means. Thanks.

sure, I basically wanted you to learn this and then schedule some time with
me to implement it
we use the following in github for rules and pipelines

codeclimate
snyk
circleci - which runs the tests

if any of the above fails, then the pull request is not allowed to be merged
On Tue, Aug 23, 2022 at 7:55 AM Michael Neal @.***>
wrote:

Hey Josh, I was wondering if you could provide some clarification on what
this issue means. Thanks.
—
Reply to this email directly, view it on GitHub
https://github.com/WebJamApps/SellStuff/issues/3#issuecomment-1223962784,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ADFY3WGUMS42E4OVU2473ALV2S34DANCNFSM55HLJ5DA
.
You are receiving this because you were assigned.Message ID:
@.***>

--
Josh Sherman
https://web-jam.com
https://www.linkedin.com/in/joshuavsherman/
540-494-8035


Document validity parameter when getting a jwt

Docs have been updated as part of eb93cf2beff458c5f9d66d787e4cca3ba9f71ad9, however these changes are not reflected on gitbook


Bang that closes rainmeter when you click and opens it when you close the program?

I know I have to follow this guide but I don't get how to install them in the skin nor how to exactly do this
I'm guessing I'd have to use !Quit, but how do you open it again once you close the program? It's from Rainmeter, so if it's closed there's no way you can open it from rainmeter... right?
Thanks
Edit: Maybe it could be done with !Hide, but would the skin still consume RAM&CPU Usage?

If you want to reduce RAM and CPU usage, then your best bet is to toggle/disable skins. If you want to do that to multiple skins, then it might be more convenient to switch layouts.


Fix base formatter when there are no params on the filename

In my project the body and instrumnet query params were not being added to the file name I believe because we use the already compiled assets to run the tests. Because of this the base formatter were failing because it expects the query parameters to exists.

Thanks Rafael!


Indexes inside createTableIfNotExists

Hi. I've already mentioned this problem in https://github.com/tgriesser/knex/issues/322#issuecomment-74895279 but haven't got response so I've decided to create separate issue to track it down.
My use case is simple: I want to create table with an index and I'm using createTableIfNotExists for that. The problem is: knex run createTableIfNotExists callback even if table already exists so it tries to create index second time and fails.
Example to reproduce this:
var knex = require("knex")({
  client: "sqlite3",
  debug: true,
  connection: {
    filename: "test.db",
  },
});

knex.schema.createTableIfNotExists("test", function(table) {
  console.log("Inside createTableIfNotExists cb");
  table.string("name").unique();
}).then(function(res) {
  console.log("OK:", res);
}).catch(function(err) {
  console.log("ERR:", err.message);
}).finally(function() {
  process.exit(1);
});

Output:
$ node test.js
Inside createTableIfNotExists cb
{ __cid: '__cid1',
  sql: 'create table if not exists "test" ("name" varchar(255))',
  bindings: [] }
{ __cid: '__cid1',
  sql: 'create unique index test_name_unique on "test" ("name")',
  bindings: [] }
OK: [ [], [] ]

$ node test.js
Inside createTableIfNotExists cb
{ __cid: '__cid1',
  sql: 'create table if not exists "test" ("name" varchar(255))',
  bindings: [] }
{ __cid: '__cid1',
  sql: 'create unique index test_name_unique on "test" ("name")',
  bindings: [] }
ERR: SQLITE_ERROR: index test_name_unique already exists

So, is there any better way to create a table only on first run other than manually check its existense with hasTable & createTable? Should createTableIfNotExists run the callback even if table already exists or is it a bug?

I just ran into this issue today. I also think that the table definition callback shouldn't be called if the table already exists.

+1

I too experienced this. I as a user (without looking at the library code) wouldn't expect the inners of the createTableIfNotExists call to execute if the table exists.

I agree with @chrisbroome, I don't think that the callback should be called. It is an unexpected behaviour. I would like to confirm if there is a consensus within the community.

Just to confirm, the callback IS CALLED even if the table exists right?
I'm experiencing the same confusion and I think it's counter-intuitive to call the callback in this case.

I agree, the example code shows a case where the current behavior causes an error, and intuitively shouldn't be a problem.

+1
any solutions?

+1

There are more discussion about the topic in #1303. Closing this as duplicate.


Add scrutinizer coverage upload

Let's not do this. Scrutinizer's code coverage has several implementation issues with github actions.


Multiple user testing bugs

Thanks wgm! Actions items based on an email conversation:

[done] Inconsistent email database encryption. User email addresses should either be encrypted or not (preferably encrypted). Causes bugs in the user settings page and likely elsewhere (invites).
[done] Email change confirmation was never fully implemented. The callback that sends the email with a selector and token is commented out. It also needs to use the library function directly, or a custom function to handle encrypted email addresses needs to use the same signature.
[mitigated] I need to double check the usability and flow of the user settings page. Requiring the current passphrase to change anything may be hostile to the UX and introduce bugs.
[done] Figure out why logging out works different across browsers (no in Chrome, yes in Firefox).
[done] Ensure that all variables in the User class are defined as $foo ??= null before trying to use them (500 error on user stats).
[!!] Go through the user-related database queries and ensure that they're using the most recent schema definition, e.g., select where users.id = ? but join users_main on users_main.userId.
[done] Ensure that account recovery works (it didn't).

[!!] Actually, there's a better way to do this for now. The codebase references users_main 355 times in 140 files. Many of these are legacy "glitch art" queries, either massive or programmatically determined. I need to remove the auto_increment and primary key properties of users_main.id and manually set it to users.id. Then the existing queries for users_main.id should work long enough for them to be rewritten.

 ' AND c.`ID` > IF(lr.`PostID` IS NULL, 0, lr.`PostID`)' : '') .  " AND p.`ID` > IF(t.`IsLocked` = '1' AND t.`IsSticky` = '0'" . ", p.`ID`, IF(lr.`PostID` IS NULL, 0, lr.`PostID`))" : '') .
    ' AND ' . Forums::user_forums_sql() . "
  GROUP BY t.`ID`)
  ORDER BY `LastPostTime` DESC
  LIMIT $Limit");

All that remains is to do the necessary database surgery (quicker without a migration) and do a quick end-to-end test of the features on a new account.


nixos/atuin: add services.atuin.package option

Description of changes
Add services.atuin.package option
Closes  https://github.com/NixOS/nixpkgs/issues/289741

Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[ ] Tested basic functionality of all binary files (usually in ./result/bin/)
24.05 Release Notes (or backporting 23.05 and 23.11 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

what is the policy for backporting changes like this?

It is unlikely that this will cause breakages, so we could do it.


Move to common source blocks for SDRs between scanner and birdseye.

Do not merge yet - still testing with each SDR.

Now OK to merge (if passes!).


Upgrade to the latest Kubernetes API client

It doesn't have a transitive dependency on Log4J 1.x.

Updated PR includes a fix for a 9-argument method that became a 12-argument method!


Add splash text on configure() when in live interpreter

Users feel reassured that stuff is working correctly when they manually configure() ARMI and get a nice splash screen in the terminal. This will do just that when running within an live Python interpreter. Otherwise, we still use the logic in EntryPoint to determine whether we should emit splash text.

🔥


Reinstallation Failed

Hi,
Everything was running perfectly since the last couple of days, but I needed to restart Domoticz today. Unfortunately the plugin stopped working after the restart. I have tried to reinstall it, so to start fresh, but I am not able to initialize the plugin. When executing the Example.py, I get the following error:
Traceback (most recent call last):
  File "example.py", line 423, in <module>
    main()
  File "example.py", line 419, in main
    ret = example(args.country, args.language, args.verbose, cmd=args.cmd, args=args.args)
  File "example.py", line 335, in example
    resp = example_command(client, cmd, args)
  File "example.py", line 283, in example_command
    return func(client, *args)
  File "example.py", line 59, in ls
    thinq1_devices = [dev for dev in client.devices if dev.platform_type == "thinq1"]
  File "/home/<username>/domoticz/plugins/domoticz_lg_thinq_plugin/wideq/client.py", line 135, in devices
    self._devices = self.session.get_devices()
  File "/home/<username>/domoticz/plugins/domoticz_lg_thinq_plugin/wideq/core.py", line 525, in get_devices
    return get_list(self.get("service/application/dashboard"), "item")
  File "/home/<username>/domoticz/plugins/domoticz_lg_thinq_plugin/wideq/core.py", line 510, in get
    return thinq_request(
  File "/home/<username>/domoticz/plugins/domoticz_lg_thinq_plugin/wideq/core.py", line 281, in thinq_request
    raise API_ERRORS[code](code)
wideq.core.AgreementError: 0110

Any idea hat could cause this?

wideq.core.AgreementError: 0110
means that you need to open LG app in your smartphone and accept new agreement. After that everything should work as before. It happens from time to time as LG introduces some changes in their agreements.

@majki09 Awesome you're right. When performing the steps for example.py, I indeed got the new agreement questions, but it still didn't work afterwards when I did the reinstallation. I haven't opened the App though in that time..Accept the agreements in the App and everything was working afterwards; Thanks again!! So needed to do it there..


Adds attribute accessors for competed_at and completed_by_id and an interface to query the logged in user

As the API provides these already, I merely added the corresponding calls.

Thanks!!
LGTM!!


Missing description for CNO reference data

In partyfunctioncodes.csv

CNO is no longer a valid party code AFAICT, so the issue is now obsolete.


Added two Color methods to be more web-related explicitly

Added two new methods to Color provider:

Color::htmlColorName()
Color::x11ColorName()
Those are just colorName() and safeColorName() renamed but with those new names it is more clear the relation with web colors.

bumping this up


shadow bugfix

Codecov Report

Merging #185 (d9520bb) into master (42664e6) will not change coverage.
The diff coverage is 0.00%.

@@           Coverage Diff           @@
##           master     #185   +/-   ##
=======================================
  Coverage   68.37%   68.37%
=======================================
  Files          71       71
  Lines        4914     4914
=======================================
  Hits         3360     3360
  Misses       1123     1123
  Partials      431      431

Impacted Files
Coverage Δ

service/sync.go
47.94% <0.00%> (ø)

Continue to review full report at Codecov.

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


Module same contents (basic working version)

This is the first working basic version of module-same-contents.

@tiagostutz Could you please comment on it? I made this PR before adding the more complex configurations because I felt I will have to change the code a bit and wanted to make sure this working code gets merged to main as soon as possible to avoid conflicts with other branches.


Reference other keys in my translations

Is it possible to reference other keys in the project and automatically replace them in the generated files?
Example in Phrase:
key: example_key_source
value: TEST
key: example_key
value: This is a {{example_key_source}} key.
Generated files after phrase pull:
example_key_source => TEST
example_key => This is a TEST key.

We have decided to close all GitHub issues and, instead, handle them through our Customer Support. We think this shift will allow us to offer proper prioritization of issues as well as a more appropriate response time that would be expected from Phrase products.
We apologize for any inconveniences this may cause. If you believe your issue is still relevant or has a high priority, please contact<EMAIL_ADDRESS>and we can take more direct action toward finding a solution.


File upload issue with Grafana data manipulation plugin

I am having an issue uploading files using the Grafana data manipulation plugin. The plugin is uploading the files in a base64 encoded format, but I am having trouble decoding the base64 in my backend.
I have tried decoding the base64 string using different libraries, but I am getting the same error.
I am also wondering how I can get the path of the uploaded file in my backend. I need the path of the file in order to save it to my database.
If anyone has any suggestions on how to fix this issue, please let me know.

Following as i too have similar requirement.

@asimonok Could you please check.

@utkarshsalunkhe @vanimesh file is sent within array. To get base64 value you have to take request.file[0] // base64 value.

I am using isset($_FILES['fileToUpload']) in my php @asimonok

and this is how i am testing in postman which works fine

I am using isset($_FILES['fileToUpload']) in my php @asimonok

Please debug the request payload to see what is the correct field. Please keep it mind that sending files is an array.
In the postman example, it's not array

@utkarshsalunkhe @vanimesh file is sent within array. To get base64 value you have to take body.file[0] // base64 value.
In additional, to get file name you should use Content-type = multipart/form-data for the updated request

Hi @asimonok , i am using multipart/form-data but it dosent work propely. The files are not getting copied to backend. Is there any example which you tried in your tests ? It would be really helpful for us to learn and replicate. Thank you very much.


Misleading 404 errors when static files not found

If the static files cannot be found, then either

The web app should exit early with an error message
The web app should continue running, but only running the webservice.

Currently, no message is given on startup, the webservice cannot be reached, and every requested address returns 404.

There is a fix in 16e0f9e but there are likely to be further changes before this is merged into main.

Won't fix.  User' responsibility to host files (see #8)


can't retrieve IMEI with getIMEI

Unable to get the IMEI from the device, using the function getIMEI(uint8_t *buf, size_t size) any help for a working example that gets IMEI from sim900?
Thanks,

Oh, it works now!


Authentication failed

Can you please help, I always got authentication failed.

Please provide more information so that we can investigate.

I just wanted to try your samples, and I put information of account name, and account key. I couldn’t do nothing, because I just got this.
Failed to create container, Error: 403, AuthenticationFailed
Failed to upload blob, Error: 403, AuthenticationFailed
Failed to download blob, Error: 403, AuthenticationFailed
Sent from Mailhttps://go.microsoft.com/fwlink/?LinkId=550986 for Windows
From: @.>
Sent: Wednesday, February 23, 2022 2:40 AM
To: @.>
Cc: Gicic, @.>; State @.>
Subject: Re: [Azure/azure-storage-cpplite] Authentication failed (Issue #130)
External Message - Use caution before opening links or attachments
Please provide more information so that we can investigate.
—
Reply to this email directly, view it on GitHubhttps://urldefense.com/v3/__https:/github.com/Azure/azure-storage-cpplite/issues/130*issuecomment-1048377247__;Iw!!In4Qlw!-LdDGLKxZMtU7eNFPZc9Lnlmd0zjwcZR1DE0SBv28SbN5_uv4fCK5OgXzG3GicFrmQ$, or unsubscribehttps://urldefense.com/v3/__https:/github.com/notifications/unsubscribe-auth/AW7XMIP7MJQKK45QKCZUEHDU4Q3KHANCNFSM5PC4LJSQ__;!!In4Qlw!-LdDGLKxZMtU7eNFPZc9Lnlmd0zjwcZR1DE0SBv28SbN5_uv4fCK5OgXzG2knpk9SQ$.
Triage notifications on the go with GitHub Mobile for iOShttps://urldefense.com/v3/__https:/apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675__;!!In4Qlw!-LdDGLKxZMtU7eNFPZc9Lnlmd0zjwcZR1DE0SBv28SbN5_uv4fCK5OgXzG2ooU5ZRg$ or Androidhttps://urldefense.com/v3/__https:/play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign*3Dnotification-email*26utm_medium*3Demail*26utm_source*3Dgithub__;JSUlJSU!!In4Qlw!-LdDGLKxZMtU7eNFPZc9Lnlmd0zjwcZR1DE0SBv28SbN5_uv4fCK5OgXzG0JSNTClg$.
You are receiving this because you modified the open/close state.Message ID: @.***>


C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/plugins/kernel_v2/config/vm.rb:319:in `network': wrong number of arguments (given 2, expected 1) (ArgumentError)

When I try to provision the guest I am getting this error:
psalm@Grieg MSYS /d/VirtualMachines/ubuntu-22-04
# vagrant up --provision
C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/plugins/kernel_v2/config/vm.rb:319:in `network': wrong number of arguments (given 2, expected 1) (ArgumentError)
        from D:/VirtualMachines/ubuntu-22-04/Vagrantfile:20:in `block (2 levels) in <top (required)>'
        from D:/VirtualMachines/ubuntu-22-04/Vagrantfile:19:in `each'
        from D:/VirtualMachines/ubuntu-22-04/Vagrantfile:19:in `block in <top (required)>'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/config/v2/loader.rb:37:in `load'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/config/loader.rb:126:in `block (2 levels) in load'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/config/loader.rb:119:in `each'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/config/loader.rb:119:in `block in load'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/config/loader.rb:116:in `each'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/config/loader.rb:116:in `load'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/vagrantfile.rb:31:in `initialize'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/environment.rb:817:in `new'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/environment.rb:817:in `vagrantfile'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/environment.rb:998:in `process_configured_plugins'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/lib/vagrant/environment.rb:189:in `initialize'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/bin/vagrant:211:in `new'
        from C:/HashiCorp/Vagrant/embedded/gems/gems/vagrant-2.3.6/bin/vagrant:211:in `<main>'

Here is my settings.yml:

:machine:
https://app.vagrantup.com/bento/boxes/ubuntu-22-04
:box: bento/ubuntu-22.04 # 64GB HDD
:memory: 3072 # 3GB RAM
:cpus: 1
:hostname: ubuntu-22-04
:timezone: Canada/Pacific
:forwarded_ports:
SSH

:id: ssh
:host: 2200
:guest: 22

HTTP

:host: 8000
:guest: 80

MySQL

:host: 33060
:guest: 3306

:synced_folder:
:host: D:/VirtualMachines/ubuntu-22-04/code
:guest: /home/vagrant/code
:copy_files:

:source: ~/.ssh
:destination: ~/.ssh
:source: ~/.gitconfig
:destination: ~/.gitconfig

:php_error_reporting: E_ALL & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT
...
Do you have any suggestions?

Hey sorry I just saw this.
I fixed this error today.
I think it has something to do with a ruby update that no longer allows hashes to feed a method argument with a splat **.


docs: readme updates

Summary

Updated readme with the correct Python version that is in use to 3.12.1+

@2byrds I have updated the python version to 3.12.1+


Add query params, fragment and reuse route result

This PR adds support for query parameters, fragment and a reuse route result boolean.
Usage: {{ path('article_show', {'id': '3'}, {'foo': 'bar'}, 'fragment') }}
Generates: http://example.com/article/3?foo=bar#fragment

Usage: {{ url('article_show', {'id': '3'}, {'foo': 'bar'}, 'fragment') }}
Generates: http://example.com/article/3?foo=bar#fragment

[x] Requires zendframework/zend-expressive-helpers#27
[x] Needs tests (after zendframework/zend-expressive-helpers#27 is merged and final)
[x] Add documentation
[ ] Remove temp dependency to zendframework/zend-expressive-router:^2.0.0-dev once it is stable.
[ ] Change dependency to zendframework/zend-expressive-helpers:^3.0 once it is stable.

Ok, question is how to add the reuse_route_result parameter?
// As a boolean
Usage: {{ path('article_show', {'id': '3'}, {'foo': 'bar'}, 'fragment', true) }}
Generates: http://example.com/article/3?foo=bar#fragment

Usage: {{ url('article_show', {'id': '3'}, {'foo': 'bar'}, 'fragment', false) }}
Generates: http://example.com/article/3?foo=bar#fragment

vs
// As an array
Usage: {{ path('article_show', {'id': '3'}, {'foo': 'bar'}, 'fragment', {'reuseResultParams': true}) }}
Generates: http://example.com/article/3?foo=bar#fragment

Usage: {{ url('article_show', {'id': '3'}, {'foo': 'bar'}, 'fragment', {'reuseResultParams': false}) }}
Generates: http://example.com/article/3?foo=bar#fragment

I think I like the second one, as an array since it is more inline with the updated UrlHelper signature. It also gives plenty of room to add more options if needed.
/cc @pine3ree, @glen-84, @edigu

Yes, option 2.
I'm not sure if Twig array keys are usually camelCased or snake_cased (?).

@xtreamwayz @glen-84
I also prefer option 2. In the core functions Twig uses snake_case for parameter keys:
in the source:
https://github.com/twigphp/Twig/blob/1.x/lib/Twig/Extension/Core.php line 195 (the same is true for twig filters about 60 lines above)
in the official docs
http://twig.sensiolabs.org/doc/functions/include.html
http://twig.sensiolabs.org/doc/functions/source.html
, so maybe using reuse_route_result would be more consistent.
kind regards

Thanks, @xtreamwayz! I have updated the dependencies, and discovered that tests pass against both original versions and the latest; as such, I have added a lowest/locked/latest CI strategy during merge. Will release with 1.2.0 shortly!


Improve modularity

This PR removes the include and exclude query param when importing VSCode module that allowed us to import only partially a module. It has some downside:

It's dangerous: it you import with include=anyFunction and you import it without any filter elsewhere, the code matching anyFunction will be duplicated
The filter is really basic (only on called function name)
If the function name change during a VSCode update (it will happen in the next VSCode release), this mechanism break silently

Replaced by simply splitting the file by hands using the patch file
This PR aims at removing unwanted visible commands (in the command picker) when the view service override is not used
There are still some remainings but I don't think will be able to perfectly split them without introducing a huge complexity

This PR makes sense. There's also a downside to using the patch file, though. We need to keep the new files in sync, and make sure that when we update we check that those files are still in sync with VSCode equivalent.
That said, I think those separate files is the lesser of the two evils, it's better than having ?include. I was bitten before by that as well.

I am looking for a better approach than having a big PATCH file... relying on a fork with several additional commit and rebasing it at every VSCode release seems like a better idea but I don't know how to implement it exactly


Issue-3359

Modified grade_entry_forms_helper so that grade_entry_items with empty name and out_of will be ignored and thus no validation will be triggered on empty grade entry items.
Demo

@czack810150 the deletion inside iteration isn't a good approach. Please use delete_if: https://apidock.com/ruby/Hash/delete_if


[BISERVER-13909] - Uploaded PDI Job/Transformation has file size of 0 on the Properties screen

@pentaho/tatooine_dev

 Note:

Frogbot also supports Contextual Analysis, Secret Detection, IaC and SAST Vulnerabilities Scanning. This features are included as part of the JFrog Advanced Security package, which isn't enabled on your system.

🐸 JFrog Frogbot

:x: Build failed in 2m 18s
Build command:
mvn clean verify -B -e -Daudit -Djs.no.sandbox -pl plugins/pur/core

:exclamation: No tests found!
Errors:
Filtered log (click to expand)

script returned exit code 1

:information_source:  This is an automatic message

 Note:

Frogbot also supports Contextual Analysis, Secret Detection, IaC and SAST Vulnerabilities Scanning. This features are included as part of the JFrog Advanced Security package, which isn't enabled on your system.

🐸 JFrog Frogbot

:white_check_mark: Build finished in 27m 26s
Build command:
mvn clean verify -B -e -Daudit -Djs.no.sandbox -pl plugins/pur/core

:ok_hand: All tests passed!
Tests run: 277, Failures: 0, Skipped: 0    Test Results

:information_source:  This is an automatic message


Fix for broken tests in sls^3.0 - converting deprecated CLI arguments to env vars

Hey,
I wanted to work on a different feature, but to my surprise most of the tests were failing on an unmodified fork. That's because I was using latest version of Serverless and the tests are full of CLI arguments which are now deprecated. Here's a small trick that makes the tests valid again without having to modify all the functions.
I also think getting rid of the python2.7 tests is a good idea.

Hey @martinezpl - it looks like the CI builds are failing - could you please look into that?

Whoops, sorry, fixed.


Remove/Copy Relay card

Is your feature request related to a problem? Please describe.
Until recently tapping on a relay in the relay menu brought up a card with 'remove' and 'copy'. It got replaced with "push data" etc.
I like to request this back please :)

We need to review those cards and bring that back, yes! thanks!

Saved issue, updating it in design tomorrow. Thank you!

This was already implemented in one of the latest versions 👍


fix: Escape backslashes and single quotes using String.replaceAll

There is a bug in the way escaping is done on the JSON serialized state: the code is seemingly trying to not add extra escape characters but turns out to produce invalid JSON anytime there's a nested JSON string containing an escape character. This was causing an error when the page loaded, and the INITIAL_STATE was discarded. (More precisely, there's a missing backslash in every nested JSON string containing an escaped character.)
This PR fixes that bug. The thing to understand is that escaping should be simple and, in a sense, "dumb" — the proposed code in this PR simply takes the JSON-stringified state object and doubles up each backslash character. It really is as simple as that, and any attempt to use regex to check where an escape character may not be needed will necessarily be buggy because it wouldn't be able to account for arbitrarily deeply nested JSON.
Similarly, I'm simplifying the escaping of single quotes in the same way: When we've JSON-stringified the state object, the JSON will not contain any escaped single quotes because JSON.stringify doesn't escape single quotes. Note that runtime strings don't have any escaping... escaping is used only when representing a string in code. So escaping the single quotes in our JSON string is simply a matter of replacing each ' with a \'.
Besides adding tests, I've manually tested these changes in my project and it works.

@dchenk Thanks for checking this! I agree it's better to simplify it as long as it doesn't break any test. Just one thing, since you are already using regexp as the first parameter of replaceAll, can you switch to replace instead? I think the behavior is the same when using regexps and replaceAll is not implemented in Node 14.

@frandiox The replace method wouldn't work here. Using regexp as the first parameter does not change the behavior; the thing is that, if regexp is used, then it needs to have the global 'g' flag set (MDN docs). (I suppose I could've passed in the string '\\' instead which would be simpler.)
Which versions of Node do you intend this framework to support? It looks like Node v14 is already in maintenance mode—i.e., no longer the active LTS. I doubt that many users of Vite are using anything older than v15, where the replaceAll method is added.

@dchenk Right now we support v14 in development and v12 in production (even lastest v12 should work in dev). I don't mind about v12 but it might be a bit early to deprecate v14 if we can avoid it.
Sorry to insist but can you help me understand what would be something that works with replaceAll and fails with replace when using a regexp with g flag? The tests provided in this PR pass with replace and, in fact, we are still using replace to remove all the unsafe chars.
Also, it looks like some replaceAll polyfills simply fallback to replace when the first parameter is a regexp with g flag (if I understood the code correctly).
Just to be clear, I'm not against using replaceAll if it's a requirement, I'm just trying to understand why it is a requirement 🤔

@frandiox you're right—I apologize. I've updated the PR now. 😃

No problem, thank you!


The install.sh file seems to be missing.

Dear Authors,
Thanks for sharing the awesome code of LIAM. But I find the install.sh file seems to be missing, which makes installing the environment be hard.

I have the same problem. How did you solve it? Thanks.


Update the document to format the JSON object properly.

@ankitC : Thanks for your contribution! The author(s) have been notified to review your proposed change.

#sign-off


Unable to compile

Hi, I am building the package with Ubuntu 20.04 and ros foxy and I encountered this issue.
colcon build --packages-up-to explored_space_costmap_plugin
Starting >>> explored_space_costmap_plugin
--- stderr: explored_space_costmap_plugin
/home/yxydw98/CPP/src/epsilon-star-coverage-path-planner/explored_space_costmap_plugin/src/explored_space_layer.cpp: In member function ‘virtual void explored_space_costmap_plugin::ExploredSpaceLayer::onInitialize()’:
/home/yxydw98/CPP/src/epsilon-star-coverage-path-planner/explored_space_costmap_plugin/src/explored_space_layer.cpp:34:21: error: ‘using SharedPtr = class std::shared_ptr<rclcpp_lifecycle::LifecycleNode>’ {aka ‘class std::shared_ptr<rclcpp_lifecycle::LifecycleNode>’} has no member named ‘lock’
34 |   auto node = node_.lock();
May I know what is the reason? Is it because a wrong type was assigned to the node variable that does not have the .lock() method? Thank you for you time.

I tried building under ros-galactic and it works. I think the reason may due to some of the changes in the navigation2 packages.

thanks for trying out the repo @yxydw123456 . I am sure you noticed this by now, but this repo is kind of abandoned / not being actively worked on. I had high hopes -- but just not enough time.
You are right -- I probably had developed this against galactic nav2 and not humble.
if you end up getting this algorithm to work, let me know!
Closing issue for now.


give me access so I commit directly

Seems like I have to propose pull requests if I edit from the site, I want direct commit access.

ERROR: Permission to protocultural/protocultural.org.git denied to rejon.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.

Added you as collaborator


Update app-attach-powershell.md

since MSIX appattach is now GA removed  “This host pool must be in the validation environment”

@jobende : Thanks for your contribution! The author(s) have been notified to review your proposed change.

#sign-off


Create a mixin for textual_osinfo to address Identical code

Address Identical code on Code Climate

@miq-bot add_label ui
@miq-bot add_label refactoring
@miq-bot add_label technical debt

@h-kataria Please review

looks good


How do I add a new method to Encore\Admin\Grid\Column ?

Laravel Version: 8.12
PHP Version: 8.0.28
Laravel-admin: 1.8.16

Description:
I am trying to add a new column filter. To achieve this, I need to place a new method similar to "filter" that exists in "Encore\Admin\Grid\Column". Since this is part of a vendor package, I cannot edit it directly. Therefore, my plan is to rewrite this vendor class. I tried using the following code in "AdminServiceProvider". This is a new ServiceProvider I added under config/app.php to make this change.
public function boot()     {         Admin::booting(function () {                  $this->app->singleton(\Encore\Admin\Grid\Column::class, \App\Admin\Extensions\Override\Grid\Column::class);         });     }
Here my try is to rewrite vendor class method "filter"
`<?php
namespace App\Admin\Extensions\Override\Grid;
use Encore\Admin\Grid\Column as OriginalColumn;
class Column extends OriginalColumn
{
/**
* Set column filter.
*
* @param mixed|null $builder
*
* @return $this
*/
public function filter($builder = null)
{
dd('sss');
return $this->addFilter(...func_get_args());
}
}`
I do not see this change reflected. Could someone help me with rewriting this vendor class?

I need to keep the column filter open, like below

I did this by editing the vendor files.

Edited "Encore\Admin\Grid\Column" class by adding new method called "open_filter"

/**      * Set column open filter.      *      * @param mixed|null $builder      *      * @return $this      */     public function open_filter($builder = null)     {         return $this->addOpenFilter(...func_get_args());     }
2. Inside the trait "HasHeader", added "addOpenFilter" method

`protected function addOpenFilter($type = null, $formal = null)
{
    if (is_array($type)) {
        return $this->addHeader(new CheckOpenFilter($type));
    }

    if (is_null($type)) {
        $type = 'equal';
    }

    if (in_array($type, ['equal', 'like', 'date', 'time', 'datetime'])) {
        return $this->addHeader(new InputOpenFilter($type));
    }

    if ($type === 'range') {
        if (is_null($formal)) {
            $formal = 'equal';
        }

        return $this->addHeader(new RangeOpenFilter($formal));
    }

    return $this;
}`

3. included CheckOpenFilter, InputOpenFilter and RangeOpenFilter classes to the folder. those actually a copy of InputFilter, CheckFilter and RangeFilter. The only change is below

Updated the inline styling of ul dropdown-menu class element with below

`style="padding: 10px;box-shadow: 0 2px 3px 0 rgba(0,0,0,.2);left: -5px;border-radius: 0; display: block; position: relative;"` display and position updated.

Now, I achieved this by editing vendor files. However, this approach is not allowed and is generally considered a bad practice to meet this requirement. As I mentioned in my question, I was unable to achieve the same result using the rewrite method.
If anyone knows of a better approach to accomplish this without editing the vendor files, please advise.

Maybe you can inherit the Column class, add new method which you need in the new class, and then adopt it in your view?
I had use the way to create new Authenticate way to integrate the authentication with other way. It works.


Update dependencies of yarn tests

Fixes #3507
Describe the changes you have made in this PR -
I have updated the required dependencies of yarn as suggested in #3507
Screenshots of the changes (If any) -

Note: Please check Allow edits from maintainers. if you would like us to assist in the PR.

Thanks @Prerna-0202,
can you also fix these warnings by running npx browserslist@latest --update-db.

few more changes:

to speed up tests we can limit maxWorkers in jest.config.js file to 50%.
in Gitpod, when we run tests by cmd yarn run test, then it run all tests available in root folder(backend tests + simulator tests), this can be fixed by updating testMatch path in jest.config.js file to **/simulator/spec/**/*.spec.js.

Done @pulkit-30

It seems that we are not running those tests in CI, could you please add them?

It seems that we are not running those tests in CI, could you please add them?

@tachyons  Do you mean github actions/workflows?

Yes

It seems that we are not running those tests in CI, could you please add them?

@tachyons They are running for any change in the simulator/ directory only. I have checked it here 'https://github.com/Prerna-0202/CircuitVerse/pull/200'
Let me know If I am doing anything wrong.

It seems that we are not running those tests in CI, could you please add them?

@tachyons They are running for any change in the simulator/ directory only. I have checked it here 'Prerna-0202#200' Let me know If I am doing anything wrong.

Does yarn run test run on CI?


ee to_xarray() method

I know it's outside the scope of this project and It wasn't obvious how to make a feature requeset to https://github.com/google/earthengine-api
I think a good long term goal would be to add a .to_xarray() method to ee objects e.g. ee.Image('LANDSAT/LC08/C02/T1_TOA/LC08_044034_20140318').select('B4').to_xarray() which I would image use xee under the hood

I think on the other hand it's clearly in the scope of geetools. In the current refactoring of the lib (https://github.com/gee-community/gee_tools/tree/1.x) I'm integrating all the existing functionalities of gee_tools + some very nice extentions inside an extention "namespace".
It would be ee.image.constant(1).geetools.to_xarray() do You think it would do the trick ?

I think it would be more appropriate to call to_xarray() on an image collection and not an image.

Sure you are very right (but considering the last example of the readme this option is also on the table 😀)

It should be released in geetools v1.1.0


Fixing HCMT part in the post installation area

Problem
HCMT ( Hana Cloud Measurement Tool) not working any more
Solution
added new BOM version and fixed post installation pipeline
Tests
done
Notes
n.a.

will be replaced by an update


fabric8:debug keeps giving Connection Refused Error

After deploying my application in minikube, when I run mvn fabric8:debug from another tab in the Terminal and tries to attach a remote debugger from STS [Eclipse] on a Spring Boot app, the debugger keeps failing with Connection Refused error.
Info
[WARNING] F8:port-forward E1129 22:31:02.006587   53164 portforward.go:331] an error occurred forwarding 5005 -> 5005: error forwarding port 5005 to pod 70be95b7a71f7430b22782dbb8a5577b4c856862e12480305541e1b268e7a002, uid : exit status 1: 2017/11/30 03:31:01 socat[14252.140167599941376] E connect(5, AF=2 <IP_ADDRESS>:5005, 16): Connection refused

f-m-p version : 3.5.33
Maven version (mvn -v) : 3.5.0

Kubernetes / OpenShift setup and version : minikube version: v0.22.2
Sample project : https://github.com/deepank-sharma/ms_travel_project_v2

I think there has been a race introduced recently. If you run mvn fabric8:debug a second time right after this call, does it work then ? (This happened to work for me when I did a demo lately)

I tried it, still does not work. I am working on a Mac though. Steps:

Started my application through mvn fabric8:deploy fabric8: log

Opened a new terminal mvn fabric8:debug. I saw it restarted my POD with JAVA_DEBUG_ENABLED as true.

Opened my project in STS, created a new Remote Java Debug Config at localhost:5005.

As soon as I hit Debug I get following error in STS
Failed to connect to remote VM
com.sun.jdi.connect.spi.ClosedConnectionException

The logs under fabric8:debug terminal shows
[WARNING] F8:port-forward E1130 13:22:29.041177   26253 portforward.go:331] an error occurred forwarding 5005 -> 5005: error forwarding port 5005 to pod fc10c5e39a65935953b3e099aca08266e0c8f863b9bd1314398a13bc3167ca49, uid : exit status 1: 2017/11/30 18:22:28 socat[5065.140221186778880] E connect(5, AF=2 <IP_ADDRESS>:5005, 16): Connection refused

I tried closing the current session and restarting , still get the same error.

Attached complete set of logs from fabric8:debug window, if it helps
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building ms-travel-website 1.0.0
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- fabric8-maven-plugin:3.5.33:debug (default-cli) @ ms-travel-website ---
[INFO] F8: Using Kubernetes at https://<IP_ADDRESS>:8443/ in namespace default with manifest /Users/sharde6/Downloads/ms_travel_project_v2/target/classes/META-INF/fabric8/kubernetes.yml
[INFO] Using namespace: default
[INFO] Updating a Service from kubernetes.yml
[INFO] Updated Service: target/fabric8/applyJson/default/service-ms-travel-website-1.json
[INFO] Using namespace: default
[INFO] Updating ConfigMap from kubernetes.yml
[INFO] Updated ConfigMap: target/fabric8/applyJson/default/configmap-ms-travel-website-1.json
[INFO] F8: Enabling debug on Deployment ms-travel-website
[INFO] F8: Waiting for debug pod with selector LabelSelector(matchExpressions=[], matchLabels={app=ms-travel-website, provider=fabric8, group=com.mytravel}, additionalProperties={}) and $JAVA_ENABLE_DEBUG = true
[INFO] F8:[W] ms-travel-website-1141802263-w60xc status: Running Ready
[INFO] F8:[W] ms-travel-website-2545493797-5ssxb status: Pending
[INFO] F8:[W] ms-travel-website-1141802263-w60xc status: Running Ready
[INFO] F8:[W] ms-travel-website-2545493797-5ssxb status: Pending
[INFO] F8:[W] ms-travel-website-1141802263-w60xc status: Running
[INFO] F8:[W] ms-travel-website-1141802263-w60xc status: Running
[INFO] F8:[W] ms-travel-website-2545493797-5ssxb status: Running
[INFO] F8:[W] ms-travel-website-1141802263-w60xc status: Running
[INFO] F8:[W] ms-travel-website-1141802263-w60xc status: Running : Pod Deleted
[INFO] F8:[W] ms-travel-website-2545493797-5ssxb status: Running Ready
[INFO] F8: Port forwarding to port 5005 on pod ms-travel-website-2545493797-5ssxb using command /usr/local/bin/kubectl
[WARNING] F8:port-forward E1130 13:22:12.106251   26253 portforward.go:331] an error occurred forwarding 5005 -> 5005: error forwarding port 5005 to pod fc10c5e39a65935953b3e099aca08266e0c8f863b9bd1314398a13bc3167ca49, uid : exit status 1: 2017/11/30 18:22:12 socat[4987.139655014201088] E connect(5, AF=2 <IP_ADDRESS>:5005, 16): Connection refused
[WARNING] F8:port-forward E1130 13:22:29.041177   26253 portforward.go:331] an error occurred forwarding 5005 -> 5005: error forwarding port 5005 to pod fc10c5e39a65935953b3e099aca08266e0c8f863b9bd1314398a13bc3167ca49, uid : exit status 1: 2017/11/30 18:22:28 socat[5065.140221186778880] E connect(5, AF=2 <IP_ADDRESS>:5005, 16): Connection refused

Found the solution, seems the connection was being terminated at the Pod but not reaching the container.
I added the following args to the image configuration in POM and was able to debug then.
-Xdebug
-Xrunjdwp:server=y,transport=dt_socket,address=5005,suspend=n


Run virtual machine and install

Hi, when i run this:
sudo qemu-system-x86_64 -enable-kvm
-machine q35 -smp sockets=1,cores=1,threads=2 -m 2048
-usb -device usb-kbd -device usb-tablet -rtc base=localtime
-net nic,model=virtio -net user,hostfwd=tcp::4444-:4444
-drive file=hdd.img,media=disk,if=virtio
-drive file=Win10_1809Oct_English_x32.iso,media=cdrom
-drive file=virtio-win-0.1.141.iso,media=cdrom
i get this response:
qemu-system-x86_64: -net user,hostfwd=tcp::4444-:4444: Could not set up host forwarding rule 'tcp::4444-:4444'
Why ? What's the problem?

@szakika10 couldn't you have a Selenium server already listening on port 4444? If you have Selenium server, Selenoid or Selenium Grid just stop it.

Thx, something was listening on this port.

@szakika10 closing then?

Of course


Flipping the camera results in error in console and no camera flip

Describe the bug
Tapping the button to flip the camera does nothing.
To Reproduce
Steps to reproduce the behavior:

Using code after commit 15627c2, deploy and access app with mobile device.
Tap the flip button.
Nothing visible happens.

Expected behavior
The camera should flip.
Environment (please complete the following information):

OS: Android 9.0.0
Browser: Chrome 83.0

Additional context
The flipping of the camera works if I revert commit 15627c2.
Looking at the console, I see the following error message:
react-dom.production.min.js:17 Uncaught TypeError: o.restart is not a function
    at FlipCameraButton.tsx:29
    at Object.v (react-dom.production.min.js:15)
    at _ (react-dom.production.min.js:15)
    at react-dom.production.min.js:16
    at S (react-dom.production.min.js:16)
    at P (react-dom.production.min.js:17)
    at C (react-dom.production.min.js:17)
    at j (react-dom.production.min.js:17)
    at On (react-dom.production.min.js:81)
    at ue (react-dom.production.min.js:285)

Let me know if you need more information.

Hi @matstc - thanks for the issue!
The commit that you referenced changed package.json to upgrade the twilio-video SDK to version 2.7.0.  npm install would have to be run in order to actually install the newer version of the library (which includes the o.restart function). Did you run npm install to update the dependencies? You can verify the version of twilio-video inside the app itself by looking at the TwilioVideo.version variable in the browser console.

Thanks @timmydoza. I ran npm install and things are indeed working fine.
I'll be closing this. Thank you.


add real service

authorization & listing. /apply was not added yet.

it's not building because automation package changes are not in master yet. please review real-service-automation-part first


fix(console): use toString implementation if object has provided one

The changes in this PR provide a partial fix to https://github.com/NativeScript/android-runtime/issues/955
Should a JavaScript class/Object instance have a custom toString implementation, it will be used in favor of JSON.Stringify()

run ci

run ci