Firmware Script shows that firmware is unavailable to download even though it is manually downloadable.

Hi,
I'm trying to restore my firmware to it's stock version and I don't have the firmware file. I tried using the shellball option and it says it isn't available for my model (CELES). This is quite confusing because this link to directly download the CELES firmware works. Is there any reason the script might not be working?
Thanks.

returning to stock / shellball ROMs are not available for EOL devices, per the script documentation. If the file is on the server, it's only because I hadn't gotten around to removing it.

not going to reopen but since you hadn't removed it at the time, I forced the script to download it and flash it and it worked fine, just here to say that

obviously there's no technical limitation with going back to stock ChromeOS on an EOL device, it's just a terrible idea to be running an out of date OS/browser that isn't being updated anymore and won't get any more security fixes.


Fail to run 'db.version();' with an error (Windows)

OS: Win10
Node.js: V 10.14.2
Build Version: 20190103.3
Repro Steps:

Install the mongo shell and set the 'mongo.shell.path' in VS Code.
New a scrapbook and run 'db.version();'.
Check the result.

Expect:
Return a version.
Actual:
Pop up an error.

Would you mind quickly trying an experimental version that may report better errors? It's easy to uninstall afterwards via the extensions view in vs code.  See instructions here: https://github.com/Microsoft/vscode-cosmosdb/issues/852#issuecomment-479734886.
Thanks!
Stephen

Could you please try once more using https://dev.azure.com/ms-azuretools/AzCode/_build/results?buildId=5664?
Also, what kind of database are you connected to?  Thx.

Hi Stephen, verified on the build 20190502.18 , this issue doesn't rproduce when connecting to a MongoDB.

Fixed by #1162


Loading error

Hi! I have some error with field initialization. I tried using schema and logic name. Unfortunately I can't loading a multiple-choice field from your extension.

ErrorDetails (24).txt

ErrorDetails.24.txt

Hi @bakmichal  as @JasonClair  said it is because the columns, because you need to put the DisplayName, SchemaName so it can be shown in the Header Columns


Rewrite majority of impl reusing libstd

This PR aims at rewriting the majority of current implementation by reusing as much as Rust's libstd as possible. As a direct consequence, it is expected that more host-specific functionality can be pulled together into one platform-independent function which is just great (thanks @alexcrichton for all your suggestions and fruitful discussions!). Also, this PR fixes the issue reported in #32 in a way that avoids duplicating "stdio" handles/fds.
While this PR, in its current form, compiles and passes all enabled tests, please bear in mind, it is still a WIP! ;-)
EDIT: I've now gone ahead and used vectored IO which will feature in the next stable release of Rust just as @alexcrichton suggested. So, as a result, fd_read and fd_write now share implementation between platforms! Happy days (and hopefully more like those to come!) :-D As a caveat, albeit just for the moment, compiling this branch will only work on beta and nightly channels until Rust 1.36.0 is released. Rust 1.36.0 is now officially out!
EDIT2: Fixes #36.

I guess the most interesting part here will be how many places we can change from just pulling out the raw fd/handle and use libstd instead of nix/winx. I look forward to seeing where this goes!

For sure, I'm really excited as well! If we do this right, we should be in a much better shape with Windows implementation, and soon-ish! :-) Anyhow, as I've posted in the update to the PRs description, the implementation of fd_read and fd_write is now common to all platforms!

cc @alexcrichton @sunfishcode

I think this is a good point to make a checkpoint in the rewrite. This PR has grown quite big by now and I'd rather not pile any more on, and instead do more work in new PRs to follow. @sunfishcode @alexcrichton if you guys are happy with its state as is, I guess we can go ahead and merge the changes into upstream.

@sunfishcode While weeding out panics and expects, I've had to change wasi-commons public interface, so misc-testsuite is expected to fail in this crate until we update wasmtime to the new interface. If you don't have any more suggestions/fixes for this PR, feel free to go ahead and force a merge into upstream, and afterwards, I'll go ahead and update wasmtime to the new interface and re-run the builds (which will then make them pass).

Seems reasonable to me!

There's a CI error, but it looks like something resolved by https://github.com/CraneStation/wasmtime/pull/191, which is currently a Draft. Do you think there's more work needed here, or is this ready to merge?

There's a CI error, but it looks like something resolved by CraneStation/wasmtime#191, which is currently a Draft. Do you think there's more work needed here, or is this ready to merge?

Yeah, the error is a result of the crate depending on wasmtime-wasi for tests, and since wasmtime-wasi depends on this crate for functionality, whenever we decide to change to public interface, that's what we get ;-) I don't see a better setup for this ATM though.
I think it's ready to merge as is: it unifies several hostcalls between platforms, plus it advances Windows impl (and resolves the issue on how to handle stdio across platforms). I think that in the upcoming PRs, I'll try and discipline myself and keep the PRs much shorter. This one really grew out of  proportion making it quite tough to review in-depth for what I apologise!


fix(table-of-contents): fixed active section

Related Ticket(s)
#5498
Description
The current Table of Contents changes the active section on the left the moment a new anchor tag appears in the viewport, even if it hasn't reached the top yet.

React
Web components

This PR changes this behavior so the current section is only set to "active" upon it reaches the top, and if a user scrolls down a bit further, the previous section will be the one becoming active, as shown in React.
The Web Component version of ToC uses Intersection Observer API for this functionality. However, after various attempts to modify the existing observer to apply this effect properly, it seems that there are times when the Intersection Observer API fails to detect the element coming into the viewport.
For example, one can be scrolling through Section 1, pass through Section 2 without 2 becoming active, and upon reaching Section 3 this is the one that becomes active, i.e. it ignores Section 2 completely. This happens randomly, and due to the spontaneous nature of this bug, it might be better to stick with using a Scroll Listener, like React is already doing.
Changelog
Changed

replaced Intersection Observer with Scroll Listener to align with React behavior

@IgnacioBecerra @oliviaflory In both versions, depending on the length of the final section there is a chance that the last item of the left nav will not be highlighted since the scrolling conditions don't occur. Should the last item be highlighted if the end of the page is reached?

In both versions, depending on the length of the final section there is a chance that the last item of the left nav will not be highlighted since the scrolling conditions don't occur. Should the last item be highlighted if the end of the page is reached?

@kennylam good question...
I would suggest yes, so far we haven't seen too many very short sections, but I'd expect to still show the last item highlighted/active at the end of the page.
There is also no guarantee that a page will always use the default footer which would add more height to the page.

Looks great!
@IgnacioBecerra I just want to double check, it looks like the colors are different in Locale modal story are different, is this a fluke in the snapshot?

@oliviaflory Yeah I believe so, this PR doesn't modify any styles


fix mitmproxy 10.3.1 installer type

Checklist for Pull Requests

[x] Have you signed the Contributor License Agreement?
[x] Is there a linked Issue?

Manifests

[x] Have you checked that there aren't other open pull requests for the same manifest update/change?
[x] This PR only modifies one (1) manifest
[x] Have you validated your manifest locally with winget validate --manifest <path>?

[x] Does your manifest conform to the 1.6 schema?

Note: <path> is the directory's name containing the manifest you're submitting.

Microsoft Reviewers: Open in CodeFlow

/azp run

/azp run

/azp run

https://github.com/microsoft/winget-pkgs/issues/142854


Bumped Dependencies & Minor QOL Improvements

🚀 Description
This PR contains the following changes:

[x] Bumped dependencies - namely Kotlin language version 1.9.23 -> 2.0.21.
[x] Fixed a broken relative link in the root README.md and applied some (very) minor formatting improvements.
[x] Cleared a few build.gradle.kts deprecation warnings in accordance with the current recommended approach.
[x] Added a bunch of further ignores to the .gitignore.
[x] Bumped root project Gradle version 8.1-rc-1 -> 8.9 and plugin-build Gradle version 8.0.2 -> 8.9.

📄 Motivation and Context
This PR isn't specifically targeting any open issues, however I've personally been encountering some difficulties with getting module-graph working in one of my own projects. The project is a Kotlin Multiplatform one, with a multi-modular architecture.
It had once worked a treat, but ceased functioning at some stage relatively recently - perhaps around the same time as I migrated from Gradle 8.7 -> 8.9. I'm hoping that by bringing module-graph forward to the latest stable Kotlin and Gradle versions, that it might fix (or at least reveal) the root cause, while benefiting this fantastic project in the process!
🧪 How Has This Been Tested?
I've conducted nominal testing with these changes, since the dependencies that were bumped were all exclusively minor or patch updates, and the update of Gradle only affects the build process - which was tested thoroughly, and worked a treat! The Kotlin language version update doesn't seem to collide with any breaking changes either.
I'm hoping to get a chance to do some further testing locally, but have run out of time to do so, right at this moment.
📦 Types of changes

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

✅ Checklist

[x] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[x] I have updated the documentation accordingly.

Hey, thanks for the PR. I'm glad it's useful for you!
Did this solve the issues you were having with your project?

No problem at all!
If I find a pocket of time in the near future, I'd love to contribute with something more substantial! 😅

Did this solve the issues you were having with your project?

Funnily enough, while the content of this PR didn't solve the issue directly, it did clue me onto a build configuration oversight that had been causing things to fall over. (It came down to a Compose Multiplatform compiler plugin not getting applied correctly)
Once that was sorted, the whole thing was singing again - module graphs and all! 😂


fix: using the correct load function

related to #230

Coverage decreased (-1.7%) to 90.566% when pulling 6df247b876eb4a5be106381c1a9878291d875d6a on bug-fix into a9e0fedb6c9b402ef269df18cbf9b5fe7e9f7c0f on main.

The errors are related to coveralls % only


Timeslicing is broken

Describe the bug
I created a simple debug app to test timeslicing. Two threads are created both preemptible with priority of 0. Both in the loop are printing a log and execute k_busy_loop(100000) (full code below). I expect that these two threads will be executed in round-robin fashion and I will see logs from both threads.
Now what I see is that at the beginning everything is fine for random time (usually from 10s to 60s) and then everything stops. When I execute from debugger I get following trace:
(gdb) bt
#0  k_cpu_idle () at /home/pdunaj/work/ncs/zephyr/arch/arm/core/cpu_idle.S:139
#1  0x00001f5a in _SysFatalErrorHandler (reason=<optimized out>, pEsf=<optimized out>) at /home/pdunaj/work/ncs/zephyr/arch/arm/core/sys_fatal_error_handler.c:70
#2  0x00001a42 in _oops () at /home/pdunaj/work/ncs/zephyr/arch/arm/core/swap_helper.S:380
#3  <signal handler called>
#4  0x20003958 in timeout_list ()
#5  0x00030100 in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

It seems that issue is easier to replicate if I set the timeslice to 1 ms. Usually there are no logs at all. When run from debugger I see following trace:
#150 log_output_flush (log_output=log_output@entry=0x59fc <log_output>) at /home/pdunaj/work/ncs/zephyr/subsys/logging/log_output.c:142
#151 0x00001118 in panic (backend=<optimized out>) at /home/pdunaj/work/ncs/zephyr/subsys/logging/log_backend_rtt.c:241
#152 0x00000c5e in log_backend_panic (backend=<optimized out>) at ../../../include/logging/log_backend.h:176
#153 log_panic () at /home/pdunaj/work/ncs/zephyr/subsys/logging/log_core.c:397
#154 0x00001c40 in _Fault (esf=0x1ffffe68, exc_return=<optimized out>) at /home/pdunaj/work/ncs/zephyr/arch/arm/core/fault.c:676
#155 0x00001eae in __usage_fault () at /home/pdunaj/work/ncs/zephyr/arch/arm/core/fault_s.S:147
#156 <signal handler called>
#157 0x20003958 in timeout_list ()
#158 0x00030100 in ?? ()

To Reproduce
Steps to reproduce the behavior:
Build and run app as below. I run it on nrf52840_PCA10056.
Expected behavior
Scheduling must be stable.
Impact
Showstopper for anybody willing to use slicing and preemption.
Screenshots or console output
N/A
Environment (please complete the following information):
ncs zephyr 1d6219ffec845a43f66469354d997fbea2f283a4 from cf85618
Additional context
main.c:
#include <zephyr.h>
#include <misc/util.h>
#include <logging/log.h>

LOG_MODULE_REGISTER(sched_demo, 4);

#define THREAD_COUNT 2
#define STACK_SIZE 1024

static K_THREAD_STACK_ARRAY_DEFINE(stack, THREAD_COUNT, STACK_SIZE);
static struct k_thread thread[THREAD_COUNT];

static void thread_fn(void *p1, void *p2, void *p3)
{
        size_t id = (size_t)p1;

        while (true) {
                LOG_INF("%zu: %p", id, k_current_get());
                k_busy_wait(100000);
        }
}

void main(void)
{
        for (size_t i = 0; i < ARRAY_SIZE(thread); i++) {
                k_thread_create(&thread[i],
                                stack[i], STACK_SIZE,
                                (k_thread_entry_t)thread_fn,
                                (void *)i, NULL, NULL,
                                K_PRIO_PREEMPT(0), 0, K_NO_WAIT);
                LOG_INF("Thread %zu created", i);
        }
        LOG_INF("Start");
}

prj.conf
CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=4096
CONFIG_HEAP_MEM_POOL_SIZE=4096
CONFIG_SYS_CLOCK_TICKS_PER_SEC=1000
CONFIG_NUM_COOP_PRIORITIES=20
CONFIG_NUM_PREEMPT_PRIORITIES=20
CONFIG_TIMESLICE_SIZE=100
CONFIG_SPEED_OPTIMIZATIONS=y
CONFIG_ASSERT=y
CONFIG_ASSERT_LEVEL=2
CONFIG_SYS_POWER_MANAGEMENT=n
CONFIG_LOG=y
CONFIG_LOG_DEFAULT_LEVEL=2
CONFIG_LOG_PRINTK=y
CONFIG_LOG_IMMEDIATE=y
CONFIG_LOG_BACKEND_RTT=y
CONFIG_LOG_BACKEND_RTT_MODE_DROP=y
CONFIG_LOG_BACKEND_RTT_MESSAGE_SIZE=128
CONFIG_LOG_BACKEND_RTT_BUFFER=0
CONFIG_LOG_BACKEND_SHOW_COLOR=y
CONFIG_LOG_BACKEND_FORMAT_TIMESTAMP=y
CONFIG_CONSOLE=y
CONFIG_USE_SEGGER_RTT=y
CONFIG_SEGGER_RTT_BUFFER_SIZE_UP=4096
CONFIG_RTT_CONSOLE=y
CONFIG_UART_CONSOLE=n

I tried to look what may cause it and added some debug traces in timeout. I do not see however crash coming from there. I thought that the problem can be caused by logger and so I removed it. Without logger I have not seen the issues. Then I tried following and issue hit again:
static void thread_fn(void *p1, void *p2, void *p3)
{
        size_t id = (size_t)p1;

        while (true) {
                k_mutex_lock(&lock, K_FOREVER);
                k_busy_wait(10000);
                k_mutex_unlock(&lock);
                k_busy_wait(100000);
        }
}

Logger is using locks that in some cases may not be available. It seems the problem is with how timeslicing and locking interact with each other.

Btw - issue does not seem to replicate itself if I disable timeslice and yield instead.

Hi @andyross , is this anything you know of?

@pizi-nordic , @cvinayak fyi

There are known stability issues on ARM with userspace enabled, does your app have it enabled?  There is some discussion in #12553.  #12559 is one that we can reproduce in simulation using mps2_an385 which sounds similar -- 1ms tick rate + tickless + userspace.

I'm not able to reproduce this.  So... to begin with I have no idea have the Segger RTT stuff works.  I'm just copying the binary to the device via MBED and reading the output on the UART console.
And when I do that (i.e. take your prj.conf and comment out anything with RTT or SEGGER in it and enabled UART_CONSOLE), I get the following, which... I gotta be honest that looks pretty clearly like a bug in the logging subsystem.  Maybe the assertion is not being reported cleanly out of RTT?    It seems to work for me, but note that the time in that test between the calls to k_mutex_lock() (which is a blocking operations and will change priorities and cause context switches) is (if I'm counting right) exactly one slice time, so almost no timeslicing is going to be happening there.
Can you try to pare this down to a smaller test that shows the error, and post the whole project (with instructions I can duplicate with the uart console and MBED flashing, heh)?

@pdunaj can you give an update on this one?

Hi @carlescufi , I will try to replicate it again. I am positive I have similar issue when I used locks only (no RTT logging) but let me try again, I should have the code around.

@pdunaj  Were you able to reproduce this?

Hi @rljordan , have no time yet but will get back to it this week.

I checked it today using ncs zephyr 1937b41459ca722848abe88cf84067945e8cf0c2 (upstream  d3bb3cf) and pca10040.
Issue is still present but it was more difficult to replicate. Logs seems to be reworked so characters are printed synchronously. When I added log issue was not replicable for the time I run test. When I set timeslice to some larger value I was also unable to replicate the problem.
Since logs are fixed crash can be seen:
***** Booting Zephyr OS v1.13.99-ncs1-5783-ge9f04d5cfe99 *****
[00:00:03.273,223] <inf> sched_demo: Thread 0 created
[00:00:03.901,977] <inf> sched_demo: Thread 1 created
[00:00:04.530,670] <inf> sched_demo: Start
***** MPU FAULT *****
  Data Access Violation
  MMFAR Address: 0x0
***** Hardware exception *****
Current thread ID = 0x20000088
Faulting instruction address = 0x492a
Fatal fault in thread 0x20000088! Aborting.
***** HARD FAULT *****
  Fault escalation (see below)
***** MPU FAULT *****
  Data Access Violation
  MMFAR Address: 0x0
***** Hardware exception *****
Current thread ID = 0x20000088
Faulting instruction address = 0x428c
Fatal fault in ISR! Spinning...

The code is as above apart from the thread_fn which is:
static void thread_fn(void *p1, void *p2, void *p3)
{
        size_t id = (size_t)p1;
        static struct k_mutex lock;

        while (true) {
                k_mutex_lock(&lock, K_FOREVER);
                k_busy_wait(1000);
                k_mutex_unlock(&lock);
                k_busy_wait(100000);
        }
}

Following time slice is used: CONFIG_TIMESLICE_SIZE=1

My guess is that this issue is caused by the access to mutex around timeslice (recheduling event in general maybe).
I changed code a bit to replicate bug with higher value of timeslice.
#define THREAD_COUNT 10
#define STACK_SIZE 1024

static K_THREAD_STACK_ARRAY_DEFINE(stack, THREAD_COUNT, STACK_SIZE);
static struct k_thread thread[THREAD_COUNT];

static void thread_fn(void *p1, void *p2, void *p3)
{
        size_t id = (size_t)p1;
        static struct k_mutex lock;

        while (true) {
                k_mutex_lock(&lock, K_FOREVER);
                k_mutex_unlock(&lock);
        }
}

void main(void)
{
        for (size_t i = 0; i < ARRAY_SIZE(thread); i++) {
                k_thread_create(&thread[i],
                                stack[i], STACK_SIZE,
                                (k_thread_entry_t)thread_fn,
                                (void *)i, NULL, NULL,
                                K_PRIO_PREEMPT(0), 0, i);
                LOG_INF("Thread %zu created", i);
        }
        LOG_INF("Start");
}

For clarity: this still requires the log subsystem with the segger backend to reproduce?  Or can you make it happen with printk?

Hi @andyross , you don't need any logging, only mutex lock/unlock in started threads. I placed the snippet that seems to replicate the issue right away (https://github.com/zephyrproject-rtos/zephyr/issues/14096#issuecomment-479434661). The only logged messages are from main thread that is cooperative. All started started threads will run after all code from main is done.

OK, I can make something happen.
FWIW: the problem you were seeing with that specific code is actually a test bug.  You're missing a call to k_mutex_init() on the lock object.  So eventually a thread will be sliced away while the mutex is held, causing future threads to pend themselves inside the k_mutex_lock() call, at which point they will crash because the wait_q is uninitialized.
But even fixing that, I eventually see failures in the scheduler, where it seems like threads are being scheduled again (or maybe twice) after having been pended.   I actually did find some minor races in the mutex code, but they aren't the root cause.

Heh, actually it was just user error.  I stuff the k_mutex_init() into the thread function instead of main, so each thread would clobber the mutex state and thus multiply lock it.  Doing it right works for me on all platforms I tried.
The race I found in k_mutex has a patch up, but on further reflection the code as written wouldn't have been actually racy on a uniprocessor platform, so it's unrelated.
I think we're fine here.  I'm going to close this bug given the impending release.  Please reopen if needed with details and test case.

Hi @andyross , thanks for pointing this one out. It was probably just that as I am unable to replicate other issues.


gemini_install.py permission denied

Permission denied when executing gemini_install.py on Ubuntu:
$ /usr/local/anaconda/bin/python gemini_install.py  /usr/local /usr/local/share/gemini
Checking required dependencies...
 wget found
Installing isolated base python installation
Traceback (most recent call last):
  File "gemini_install.py", line 184, in <module>
    main(parser.parse_args())
  File "gemini_install.py", line 77, in main
    make_dirs(args)
  File "gemini_install.py", line 147, in make_dirs
    os.makedirs(dname)
  File "/usr/local/anaconda/lib/python2.7/os.py", line 157, in makedirs
    mkdir(name, mode)
OSError: [Errno 13] Permission denied: '/usr/local/share/gemini'

$ ls -l /usr/local | grep share
drwxr-xr-x 14 root   root   4096 Nov 13 13:09 share

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=14.04
DISTRIB_CODENAME=trusty
DISTRIB_DESCRIPTION="Ubuntu 14.04.3 LTS"

The installer respects filesystem permissions on your machine, so will only install in locations where your user has permission. If you have sudo access, you can chown /usr/local and /usr/local/share/gemini to your local user and then run the installation. Alternatively, set the data and tool directories to locations on your system where you have write permissions.
Also, while looking at this I realized the new installation method accidentally swapped the order of the tool directory and data directory arguments. This doesn't have anything to do with your error but when you re-run you should get the latest version of the script:
wget https://raw.githubusercontent.com/arq5x/gemini/master/gemini/scripts/gemini_install.py
Hope this gets you going and apologies for the issues. We're working through a new easier installation process for the new release coming next week. Thanks much.


Consider adding RGB Lib to SeaORM showcase!

Hey @zoedberg @nicbus, feel free to submit a PR to showcase your project!

https://github.com/SeaQL/sea-orm/issues/403

done: https://github.com/SeaQL/sea-orm/pull/1027

Thanks!! @zoedberg


Remove IBDesignable/IBInspectable support

It causes interface builder crashes so how to remove it from interface builder and leave support programmatically only?

@gerchicov-bp have you got solution?


Model Class To Array Does Not Use Get Magic Method Or Allowed Fields Property

Because the Model->classToArray() method use reflection, it does not get values use the __get() magic method and could produce incorrect data, also I believe if the Model->allowedFields property is set then it should attempt to get those properties from the class too.
If this is something that's agreed I can implement this and create a pull request.

I am generally good with this, and will help get the Entity classes actually working correctly, as was discussed on the forums.
I'd like to know a tad more about how you plan to implement things:

Since not every class will have a magic getter implemented, how would you detect the difference between a null reponse from get() and a null value? I would think we'd want to fallback to reflection to verify the value?
Using allowedFields is tricky I think, and I'd love to hear your thoughts on it. While I think it's generally desirable, There are also times that I could see a user creating a new Entity, setting values that would not normally be updatable, like created on, id, etc, and wanting to save it. For that matter, the model itself might do that, which should be considered a safe operation that wouldn't need mass assignment protection.

@lonnieezell I'll try to get an example of what I'm currently doing, it's a little messy and could probably use improving, but I think it's a good starting point. Entities can be a very powerful part of CodeIgniter I would imagine.

@lonnieezell How would be best to show you an example of what I'm currently doing? I could upload it and provide you with a link.

@EpicKris You could do that, or provide a GIST, or, if it's short enough, put it here in a code block.

Here is a GIST of my entities and data mappers: https://gist.github.com/EpicKris/619903892899843fe6596561ba2d7b70

Looks a little more involved than I would want to put into core at this moment.
I've written and erased 3 different replies so far. :) The more I think about this, though, the more I think the best solution might be to implement a new BaseEntity class, that can handle the getX() and setX() methods, and could also potentially handle the data-mapping, and additional features. I actually wrote a blog post with a start on something like this a while back, that is close to your Domain class.
Here's my thinking, let me know your thoughts:

Not everyone is going to use Entities/DataMapping, etc. So we should keep additional complexities the core database layer, since it's already complex enough as it is.
By leaving it how it is now, people can choose to create their own custom base classes and provide a different style/syntax that matches their preferences, without being tied to what we implement here. I think that keeps with the traditional flexibility that people like about CodeIgniter.
By implementing a BaseEntity class, we can provide additional tools like automatic timezone-handling, like mentioned in the blog post, in clean way that doesn't dirty up the db layer anymore, especially since it doesn't know anything about field types.
The __get() and __set() methods could check for the object in a class property, datamap, where you could list the database field name and the class property it should map to. This would only require fields that had changed to be inserted, and would be a super-simple to use implementation of datamapper pattern, but would be very effective, I think.

On the surface, entities and data mappers seem like a simple task, but the more you play with them, the more complex they seem to become. While I agree with your thoughts, I did notice that there's an onSave() hook in the database layer for entities, perhaps a similar hook (like extract()) could be used to get the data in a clean way from the entity (if the method exists). A comprehensive base entity could include all the functionality we've discussed, would just need planning out in an appropriate way.


Feat: Adding a Our Contributors page with proper UI

Describe the feature
The page will contain all the contributor name for this repo
Add ScreenShots

I will use this data
Record

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

@Its-Aman-Yadav Please check this issue and assign this to me


add missing docs, priority class, missing extra args

closes #6

Hi @Ashtonian , Let's bump the chart version to 1.1.6, and the PR will be good to go.

Thank you for this !

Thank you for this ! Let's get it merged :)

Waiting for @Ashtonian bump chart version in this PR.

I have created a new commit d9aa2e92ba763d2f2a7e2a2edde19a2fc7d01bd0 to bump the chart version to 1.1.6.
Thanks for your contribution!

@LordNoteworthy ,  extraArgs is supported in the new release.
The tarball has been committed accidentally in 1.1.6, so you better use the 1.1.7.

Thank you so much ! Much appreciated <3

Probably we missed something:
{{ toYaml .Values.nsqadmin.extraArgs | indent 8 }} should be {{*-* toYaml .Values.nsqadmin.extraArgs | indent 8 }}
Otherwise, we end up like this:


Cell height renders incorrectly

Applies To

[X] Notebooks (.ipynb files)
[ ] Interactive Window and/or Cell Scripts (.py files with #%% markers)

What happened?
On many occasions, the cell height of my notebooks changes abruptly, sometimes stretching and at other times shrinking compared to their original height. This problem occurs only during scrolling the document, using either the arrow keys or the mouse. I haven't seen this exact issue arise on the GitHub issues page or other websites like Reddit and StackOverflow.
It is difficult to replicate this issue on demand, but there are a few patterns I've observed:

This issue mostly occurs after running some code that uses RAM to a moderate degree, but I've observed it at other times too when I run generic simple code like defining functions (that doesn't take much memory).
I mostly use Jupyter in Code remotely. Perhaps this problem might be because of that.

VS Code Version
Version: 1.83.0 Commit: e7e037083ff4455cf320e344325dacb480062c3c Date: 2023-10-03T16:13:10.518Z Electron: 25.8.4 ElectronBuildId: 24154031 Chromium: 114.0.5735.289 Node.js: 18.15.0 V8: <IP_ADDRESS>-electron.0 OS: Darwin arm64 23.0.0
Jupyter Extension Version
v2023.9.1102792234
Jupyter logs
Visual Studio Code (1.83.0, ssh-remote, desktop)
Jupyter Extension Version: 2023.9.1102792234.
Python Extension Version: 2023.18.0.
Platform: linux (x64).
Workspace folder /home/umni2/a/umnilab/users/verma99/mk, Home = /home/bridge/c/verma99
17:14:17.963 [info] User belongs to experiment group 'NewJupyterSession'
17:14:18.332 [info] Start refreshing Kernel Picker<PHONE_NUMBER>332)
17:14:18.342 [info] Using Pylance
17:14:19.713 [error] Failed to validate Password info h [FetchError]: request to http://localhost:5000/tree? failed, reason: connect ECONNREFUSED <IP_ADDRESS>:5000
    at ClientRequest.<anonymous> (~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/out/extension.node.js:2:1634096)
    at ClientRequest.emit (node:events:513:28)
    at Socket.socketErrorListener (node:_http_client:502:9)
    at Socket.emit (node:events:513:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at processTicksAndRejections (node:internal/process/task_queues:82:21) {
  type: 'system',
  errno: 'ECONNREFUSED',
  code: 'ECONNREFUSED'
}
17:14:19.733 [error] Error fetching kernels from http://localhost:5000/ (TNET Python mk3.9): FetchError: request to http://localhost:5000/api/kernels?1696713259724 failed, reason: connect ECONNREFUSED <IP_ADDRESS>:5000
    at ClientRequest.<anonymous> (~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/out/extension.node.js:2:1634096)
    at ClientRequest.emit (node:events:513:28)
    at Socket.socketErrorListener (node:_http_client:502:9)
    at Socket.emit (node:events:513:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at processTicksAndRejections (node:internal/process/task_queues:82:21)
17:14:19.735 [error] UniversalRemoteKernelFinder: Failed to get kernels without cache FetchError: request to http://localhost:5000/api/kernels?1696713259724 failed, reason: connect ECONNREFUSED <IP_ADDRESS>:5000
    at ClientRequest.<anonymous> (~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/out/extension.node.js:2:1634096)
    at ClientRequest.emit (node:events:513:28)
    at Socket.socketErrorListener (node:_http_client:502:9)
    at Socket.emit (node:events:513:28)
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at processTicksAndRejections (node:internal/process/task_queues:82:21)
17:14:19.736 [error] Jupyter Lab Helper:getKernelSpecs failure:  Error: Poll (@jupyterlab/services:KernelSpecManager#specs) is disposed.
    at e.dispose (~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/out/extension.node.js:2:211828)
    at u.dispose (~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/out/extension.node.js:2:62940)
    at ks.dispose (~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/out/extension.node.js:2:2305689)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async Promise.all (index 0)
    at Um.listKernelsFromConnection (~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/out/extension.node.js:17:166163)
    at ~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/out/extension.node.js:17:163608
17:14:20.193 [warn] Password for http://localhost:8000/ was invalid.
17:14:20.215 [warn] Password for http://localhost:8000/ was invalid.
17:14:20.220 [warn] Password for http://localhost:8000/ was invalid.
17:14:20.272 [info] Loading webview. View is notset
17:14:20.273 [info] Loading web view...
17:14:20.274 [info] Webview panel created.
17:14:20.555 [info] Web view react rendered
17:14:22.513 [info] Starting Kernel startUsingPythonInterpreter, .jvsc74a57bd0bbbc881a3d2b362a3543a66f24b921db480122daf8c3959affec01aee9a271ec./home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/python./home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/python.-m#ipykernel_launcher  (Python Path: /home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/bin/python, Conda, mk11, 3.11.5) for '/home/umni2/a/umnilab/users/<username>/mk/spr_4711/code/POIs.ipynb' (disableUI=true)
17:14:22.831 [info] End refreshing Kernel Picker<PHONE_NUMBER>332)
17:14:25.503 [info] Process Execution: /home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/bin/python -m pip list
17:14:25.567 [info] Process Execution: /home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/bin/python -c "import ipykernel; print(ipykernel.__version__); print("5dc3a68c-e34e-4080-9c3e-2a532b2ccb4d"); print(ipykernel.__file__)"
17:14:25.600 [info] Process Execution: /home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/bin/python -m ipykernel_launcher --ip=<IP_ADDRESS> --stdin=9003 --control=9001 --hb=9000 --Session.signature_scheme="hmac-sha256" --Session.key=b"d60222d0-6058-42e8-b965-ee9fed1d6eac" --shell=9002 --transport="tcp" --iopub=9004 --f=~/.local/share/jupyter/runtime/kernel-v2-116465Qih337mo2EN1.json
    > cwd: /home/umni2/a/umnilab/users/<username>/mk/spr_4711/code
17:14:25.848 [info] ipykernel version & path 6.25.2, /home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/lib/python3.11/site-packages/ipykernel/__init__.py for /home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/bin/python
17:14:26.201 [warn] StdErr from Kernel Process 0.00s - Debugger warning: It seems that frozen modules are being used, which may
0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off
0.00s - to python to disable frozen modules.
0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation.
17:14:26.328 [warn] StdErr from Kernel Process [IPKernelApp] WARNING | Error in loading extension: sparkmonitor.kernelextension
Check your config files in ~/.ipython/profile_default
Traceback (most recent call last):
  File "/home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/lib/python3.11/site-packages/IPython/core/shellapp.py", line 282, in init_extensions
    self.shell.extension_manager.load_extension(ext)
  File "/home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/lib/python3.11/site-packages/IPython/core/extensions.py", line 76, in load_extension
    return self._load_extension(module_str)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/lib/python3.11/site-packages/IPython/core/extensions.py", line 91, in _load_extension
    mod = import_module(module_str)
          ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1126, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1140, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'sparkmonitor'
17:14:26.656 [info] Process Execution: /home/umni2/a/umnilab/users/<username>/anaconda3/envs/mk11/bin/python ~/.vscode-server/extensions/ms-toolsai.jupyter-2023.9.1102792234-linux-x64/pythonFiles/printJupyterDataDir.py
17:14:41.701 [info] Handle Execution of Cells 1,2,3,4,6 for /home/umni2/a/umnilab/users/<username>/mk/spr_4711/code/POIs.ipynb
17:14:41.734 [info] Kernel acknowledged execution of cell 1 @<PHONE_NUMBER>733
17:14:41.860 [info] End cell 1 execution @<PHONE_NUMBER>859, started @<PHONE_NUMBER>733, elapsed time = 0.126s
17:14:41.869 [info] Kernel acknowledged execution of cell 2 @<PHONE_NUMBER>869
17:14:44.045 [info] End cell 2 execution @<PHONE_NUMBER>045, started @<PHONE_NUMBER>869, elapsed time = 2.176s
17:14:44.051 [info] Kernel acknowledged execution of cell 3 @<PHONE_NUMBER>050
17:14:44.627 [info] End cell 3 execution @<PHONE_NUMBER>627, started @<PHONE_NUMBER>050, elapsed time = 0.577s
17:14:44.633 [info] Kernel acknowledged execution of cell 4 @<PHONE_NUMBER>632
17:14:46.844 [warn] StdErr from Kernel Process Setting default log level to "WARN".
To adjust logging level use sc.setLogLevel(newLevel). For SparkR, use setLogLevel(newLevel).
17:14:47.017 [warn] StdErr from Kernel Process 23/10/07 17:14:47 WARN NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
17:14:47.058 [warn] StdErr from Kernel Process 23/10/07 17:14:47 WARN SparkConf: Note that spark.local.dir will be overridden by the value set by the cluster manager (via SPARK_LOCAL_DIRS in mesos/standalone/kubernetes and LOCAL_DIRS in YARN).
17:14:48.364 [info] End cell 4 execution @<PHONE_NUMBER>364, started @<PHONE_NUMBER>632, elapsed time = 3.732s
17:14:48.375 [info] Kernel acknowledged execution of cell 6 @<PHONE_NUMBER>375
17:14:48.415 [info] End cell 6 execution @<PHONE_NUMBER>414, started @<PHONE_NUMBER>375, elapsed time = 0.039s

Coding Language and Runtime Version
Python 3.11.5
Language Extension Version (if applicable)
No response
Anaconda Version (if applicable)
conda 22.11.1
Running Jupyter locally or remotely?
Remote

This seems to work for me so far...

@rebornix @2-5 FWIW I've noticed that keeping the "notebook.showCellStatusBar" at its default of "visible" is a much more stable experience. I've typically had it on "visibleAfterExecute" and that causes misrenders frequently.


Always convert header values to str()

When serializing input to rest-* protocols, we need
to ensure that any value that's associated with a header value
is converted to a string.
Fixes #791.
cc @kyleknap @JordonPhillips

:ship:


minimal documentation

i've learn materialize and want to implement Sidenav, but the documentation isn't enough.

Please take a look at the templates to find a working implementation


Check for index page existence before generating breadcrumb

[x] Changes have been thoroughly tested to not break existing functionality.
[ ] New functionality has been documented or existing documentation has been updated to reflect changes.
[ ] Visual changes are explained in the PR description using a screenshot/recording of before and after.

Currently the getBreadcrumbs assumes that every resource has an index page. I'm currently creating an app where this is not the case. This PR adds a check to see if the 'index' page actually exists before adding the breadcrumb, in line with the other breadcrumbs.
I think there is no need to change the documentation or update a screenshot since nothing changes for existing apps. Currently an exception occurs when calling the $resource::getUrl() method.

Hey, whats the use case of a resource without the index page?

Currently I link to this resource from a relation manager. The concept of the index page is not relevant for my app, but on the 'view' page I show some history for this record. Other than this I had to make no changes for the functionality to work.

In this situation, I do not suggest using resources. Resources are for full CRUDs. Use a custom page, and the form builder.

Hmm, disagree here since it's a very minor change and the page will need to look like the other resource pages. Duplicating this to it's own page makes it harder to for example use the relationmanager.

How would the breadcrumbs work when there's no index page for a resource though?
It wouldn't be clear that the page is scoped by the resource when you leave out the first breadcrumb, right?

So many features of a resource rely on an index page, it just doesn't make sense for a resource not to be able to "list" IMO
I'm more than happy to make it easier to add a relation manager to a custom page, that is reasonable


[Suggestion] Remove Mod Settings on Main Menu

hi can you add the True/False for Remove Mod Settings in Main Menu.
Tq.

hi can you add the True/False for Remove Mod Settings in Main Menu.
Tq.

It's not planned for that soon
In next major update the modules will maybe have settints and depend of this menu


Consider how this fits in with Policyfiles

With Policyfiles, it's possible that much functionality in this cookbook is unnecessary. For example, the following policyfile can replicate much functionality that this cookbook provides on OS X:
name "pantry"
default_source :community

run_list ["homebrew", "homebrew::cask", "homebrew::install_taps", "homebrew::install_formulas", "homebrew::install_casks"]

default["homebrew"].tap do |homebrew|
  homebrew["casks"] = ["steam", "github", "atom", "google-chrome"]
  homebrew["formulas"] = ["openvpn", "w3m", "emacs"]
end

Similarly, a policyfile that would work on Debian Linux:
name "pantry"
run_list ["packages"]

default["packages"] = ["emacs", "vim", "zsh"]

(It would probably also work on RHEL-family given that those packages are also available)

Note that in these examples, this cookbook is not needed at all.

Closing as we've deprecated this cookbook


Possibility to use a custom replacement string

Is your feature request related to a problem? Please describe.
Currently the replacement string is ***REMOVED*** . In Drupal there are a configuration *.yml files. The secrets are mostly located into them. The asterisk marks (*) are not allowed in a *.yml files as a values. So I need manually surrounded the string by quotation marks like this '***REMOVED***' or find/replace it with another string.
Describe the solution you'd like
It would be great to have an option which could be passed to the command to use a custom string for the replacements. Like this:
gitleaks detect --report-path gitleaks-report.json --replacement-string REMOVED
Additional context
Using in Drupal CMS
cc @zricethezav

Currently the replacement string is REMOVED

What version of Gitleaks are you using? The current version (8.x) doesn't have anything like this AFAIK.
This sounds like bfg-repo-cleaner.


Facebook: Data too long for column 'access_token'

G'Day,
I get the following error when using facebook:
Error: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'access_token' at row 1
255 is the max length for BINARY for me so changing access_token to a BLOB fixes it.
I'm using MYSQL as the DBMS.

Hmm.. In phinx binary is DB agnostic and hence I used that. blob is MySQL only and I would prefer keeping the migrations file DB agnostic.

Same issue on Twitter login.
I'm using MySQL.

@DevSmartSolutions Just change the field type of acces_token column.

I'd like to report that I came across the same problem. It's not a problem with Google but is a problem with Facebook. The data length of the token exceeds 255, so MySQL stores a truncated version of it. This problem may be hard to catch because it does not cause any problem if you are logging in for the first time because you are not DE-serializing the truncated piece of data at that point. But if you log out and try to log back in using the same account, SerializeType::toPHP will try to deserialize this broken piece of data and you will get an error. So, I would suggest that you change the data type of access_token in the migration file to accommodate larger data.

When the access_token column has been changed (e.g. for longtext), the saved content looks like this:
O:32:"SocialConnect\OAuth2\AccessToken":3:{s:8:"�*�token";s:180:"EAADKLd96yFIBADOri3LWM6akzZCLYZB3c7m2wozvabr0RR9UZCjl5INxZADZATejyPaFTfI4c5soLqe6K75FZAgdikJAQyuiGDzmEzEx66ZCyanHTJ8UmYcSDTHUabuZAURFEgEpL7qzs1hWZBoyAtJylSDKSG9FGlv0tBickNKYc3gZDZD";s:10:"�*�expires";i:1532262490;s:6:"�*�uid";N;}

@robertinosantiago viewing textual representation of this serialized data is pointless. You will get proper data back in php var when it's unseralized (as long as it's not truncated).

@robertinosantiago To confirm you are using type longtext for the access_token column and things are working fine for you?
If that's the cause I'll just update the migration schema to not use binary type for access_token.

Blob is already good for store this data. but i think it s little bit complicated to read out from this type of field (we need convert i think). but its ok too. better than binary :)


EventGrid blob trigger support

Current Blob trigger logic relies on pulling azure storage diagnostic logs. This approach gives us high latencies, bad performance and fragile behavior overall. Using EventGrid subscription is much more reliable approach and it will give approximately 2-3 times better performance.
The overall flow for EventGrid Blob trigger:

A blob uploaded to azure storage.
EventGrid subscription detects the blob change and sends a HTTP request to the blob extension HTTP endpoint.
Blob extension receives the HTTP request, parses it and put a new message to the internal storage queue with the blob information and function name. Regular Blob trigger uses the same internal queue.
Internal storage queue listener reads the new queue message, creates CloudBlob and executes the function code.

Steps to test locally:

Create a function app with blob trigger in VS.
Add new nuget source: https://www.myget.org/F/azure-appservice/api/v3/index.json
Replace the storage extension package with Azure.WebJobs.Extensions.Storage.Blobs.5.0.0-alpha.20201120.1
Add "UseEventGrid = true" to trigger definition
public static void Run([BlobTrigger("samples-workitems/{name}", UseEventGrid = true)]Stream myBlob, string name, ILogger log)
Start ngrok http -host-header=localhost 7071
https://docs.microsoft.com/en-us/azure/azure-functions/functions-debug-event-grid-trigger-local
Start the function app VS project.
Open portal and create an EventGrid subscription with WebHook endpoint:
https://83f2d199d6f4.ngrok.io/runtime/webhooks/blobs?functionName=Function1
Note: EventGrid subscription fires on all containers/blobs in the storage account. Maybe you want to add some EventGrid subscription filters.
Note: If you deploy the function app to azure the EventGrid subscription endpoint will be:
https://[functionAppName].azurewebsites.net/runtime/webhooks/blobs?functionName=Function1&code=[blobExtensionKey]
BlobExtensionKey is generated automatically and available on the azure portal.
Add a blob to blob storage and verify the trigger is fired.

The plan is to provide the EventGrid Blob trigger in beta as is, write documentation and collect customers feedback.

Can we add a functional test that simulates an event grid notification?

Can we add a functional test that simulates an event grid notification?

@pakrym,
I added the tests in EventGridBlobTriggerEndToEndTests.

Can we add a functional test that simulates an event grid notification?

@pakrym,
I added the tests in EventGridBlobTriggerEndToEndTests.


can't install zipline-reloaded with python 3.9 on MacOs

I can not install zipline-reloaded in a python 3.9 environment (with 3.7 and 3.8 it's fine)
I'm using MacOs 11.2.3
I'm using Python 3.9 with following versions 3.9.0, 3.9.1, 3.9.2, 3.9.4
I'm trying to install with

conda install -c ml4t -c conda-forge zipline-reloaded
pip install zipline-reloaded

got the following with conda install -c ml4t -c conda-forge zipline-reloaded:
(zip39) carsten@MacBook-Pro ~ % conda install -c ml4t -c conda-forge zipline-reloaded
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: |
Found conflicts! Looking for incompatible packages.
This can take several minutes.  Press CTRL-C to abort.
failed
UnsatisfiableError: The following specifications were found
to be incompatible with the existing python installation in your environment:
Specifications:

zipline-reloaded -> python[version='>=3.7,<3.8.0a0|>=3.8,<3.9.0a0']

Your python: python=3.9.4
If python is on the left-most side of the chain, that's the version you've asked for.
When python appears to the right, that indicates that the thing on the left is somehow
not available for the python version you are constrained to. Note that conda will not
change your python version to a different minor version unless you explicitly specify
that.
(zip39) carsten@MacBook-Pro ~ %

I'm sorry but we are currently working on some challenges around building the conda recipe for Python 3.9 on Mac and Windows. It shouldn't take more than a week to fix but meanwhile there's a macOS wheel for Pyhon 3.9 on PyPI.


refactor!: remove K8S audit logs from Falco

What type of PR is this?
/kind cleanup
/kind design
Any specific area of the project related to this PR?
/area build
/area engine
What this PR does / why we need it:
This is part of the ongoing effort of porting the current K8S Audit Logs support implementation out of Falco and turn it into a Falcosecurity PR. The goals of this PR are to:

Remove the current audit log implementation from Falco
Adapt all integration tests to use new K8S Audit plugin
Adapt the K8S default ruleset to use the new K8S Audit plugin
Drop the civetweb dependency
Re-implement the healthz endpoint with a lightweight HTTP server

Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
This new plugin-based K8S Audit implementation introduces the following breaking changes:

The falco.yaml piece of configuration responsible of K8S Audit is now located under the plugins section
List field types now have explicit list typing: a field can either extract a single value or a list of values. For list values, extracting one value means extracting a list containing only one value, which is not the same thing as extracting regular single values
List field types now only support the in and intersects operators. For example, checks such as ka.req.role.rules.verbs contains create would be rejected and would need to be changed in the equivalent ka.req.role.rules.verbs intersects (create)
Failed field value extraction should be checked with the exists operator, and not by comparing with the <NA> string.
The <NA> string literal is not returned anymore, neither in single-valued fields nor in list fields. For example, in the past field existence was occasionally checked with expressions like ka.target.subresource != <NA>, which would now inherently never be true, because if the field is absent the string comparison fails by default. Instead, prefer using the analoguous ka.target.subresource exists, which explicitly checks for missing values.
The /healtz endpoint cannot bind to the same port of the K8S Audit Log endpoint (e.g. /k8s-audit), due to the fact that they are now managed by two different webservers (one in Falco, one in the plugin)
Syscalls and K8S Audit event sources cannot be active at the same time anymore. This is caused by the current restriction of having 1 event source active per time in the libs, so that this may change in the future

Blocking PRs:

[x] https://github.com/falcosecurity/plugins/pull/79
[x] https://github.com/falcosecurity/falco/pull/1976
[x] https://github.com/falcosecurity/plugins/pull/90

Does this PR introduce a user-facing change?:
refactor!: remove K8S audit logs from Falco

/milestone 0.32.0

This is currently blocked by the changes of https://github.com/falcosecurity/falco/pull/1976.

LGTM label has been added.  Git tree hash: 093cd38cf8219e09e240c466c1ea51cd9a7afd6d

LGTM label has been added.  Git tree hash: 093cd38cf8219e09e240c466c1ea51cd9a7afd6d

(whoops, didn't see that @leogr had also approved). Well I'll check back for the answers and it would be nice to clean up the comment in a later PR. Not the end of the world as that code is pretty retired anyway.


SAMPLEXYT function (incorrectly) samples beyond end of data

Reported by steven c hankin on 22 Jan 2009 22:14 UTC
! err_samplexyt.jnl
! 1/2009

! the SAMPLEXYT function giver erroneous results for T sample points that lie
! beyond the end of the T axis of the grid being sampled

define axis/x=0:360:180/units=longitude/edges/modulo x1
define axis/y=-90:90:45/units=latitude/edges y1
define axis/t0=1-jan-1990/t=1-jan-1991:31-dec-1991:1/units=days/edges t1
define grid/x=x1/y=y1/t=t1 g1

let my_data = 0*x[AXIS/T0=1-JAN-1990/T=1-JAN-1990:31-DEC-1992:40/UNITS=DAYS/EDGES TSAMPLES
LET TPTS = XSEQUENCE(T[GT=TSAMPLES](g=g1]+y[g=g1]+t[g=g1]

DEFINE))
LET YPTS = XSEQUENCE((RANDU(TPTS)-0.5)*90)
LET XPTS = 180 + 0*YPTS
LET errpts =  SAMPLEXYT(my_data,xpts,ypts,tpts)

!    AS MISSING VALUES.    TIME INTERVAL?

!  AND HERE WE SHOW IT GRAPHICALLY
cancel mode calendar
set view upper
shade/hlim=20:1100 my_data[view lower
plot/vs/xlim=20:1100/ylim=0:1000 tpts, 0*MISSING(errpts,0) + 500
plot/vs/color=red/over tpts, errpts

The upper end of the time axis of my_data is at 728
! HERE WE SHOW THE PROBLEM WITH A LISTING
list ypts, tpts, errpts
             X: 0.5 to 28.5
 Column  1: YPTS is XSEQUENCE((RANDU(TPTS)-0.5)*90)
 Column  2: TPTS is XSEQUENCE(T[GT=TSAMPLES](x=180]

set))
 Column  3: ERRPTS is SAMPLEXYT(MY_DATA,XPTS,YPTS,TPTS)
            YPTS   TPTS  ERRPTS
1    /  1:  20.54    20.   ....
2    /  2: -29.07    60.   ....
3    /  3:  26.64   100.   ....
4    /  4: -28.97   140.   ....
5    /  5: -17.10   180.   ....
6    /  6:  -8.79   220.   ....
7    /  7: -26.49   260.   ....
8    /  8:  -9.00   300.   ....
9    /  9: -19.19   340.   ....
10   / 10: -19.84   380.  360.2
11   / 11: -44.11   420.  375.9
12   / 12:  34.07   460.  494.1
13   / 13:  34.63   500.  534.6
14   / 14:  -6.60   540.  533.4
15   / 15: -39.01   580.  541.0
16   / 16: -25.63   620.  594.4
17   / 17: -22.97   660.  637.0
18   / 18: -30.91   700.  669.1
19   / 19: -22.52   740.  711.7
20   / 20: -20.65   780.  733.5
21   / 21: -41.66   820.  732.4
22   / 22:  39.14   860.  833.2
23   / 23:  22.88   900.  836.8
24   / 24: -41.03   940.  792.9
25   / 25:  33.35   980.  887.2
26   / 26:  22.54  1020.  896.3
27   / 27:  13.98  1060.  907.7
28   / 28:  21.99  1100.  935.6

So what are the values that the function appears to be sampling above 728?
Migrated-From: http://dunkel.pmel.noaa.gov/trac/ferret/ticket/1624

Comment by ansley.b.manke on 23 Jan 2009 21:12 UTC
This is fixed in the external function SAMPLEXYT and the shared object file installed on porter and stout.
For future releases, I have included this function in the statically-linked function.
A benchmark test is added to the test suite.


FancyZones

Description of the new feature / enhancement
Intergrate FancyZones into the windows maximize resize layout button.
Scenario when this would be used?
When you click the resize button on an app you get a few layout options. However,  the feature is buggy and never saves the previous locaton.
But with fancy zones layouts work great and maintian the previous location. And look nicer with the space between.
Supporting information
No response

/dup https://github.com/microsoft/PowerToys/issues/11792


Cannot import package, incorrect exports

I tried to use the package in a vite project and I get the following error:
[vite] Internal server error: Failed to resolve entry for package "@streamparser/json". The package may have incorrect main/module/exports specified in its package.json.

It seems like the "module" key in package.json points to a not existing file ./dist/mjs/index.js.

@pgiraud Had the same problem. See https://github.com/juanjoDiaz/streamparser-json/pull/18 for a solution.

Thanks for reporting!
Solved in version 0.10


Error with select (No such option "B" in this select box.  Available options: "A", "B", "C")

Hello.
I am getting a strange error with select.
This is the code:
select("Life Sciences", :from => "division")
This is the resulting error:
No such option 'Life Sciences' in this select box. Available options: 'Please Select...', 'Life Sciences', 'Engineering' (Capybara::OptionNotFound)
It may have to do with the markup, which I have included below (I do see some spacing issues, and also this field is a dependent dropdowns, though the criteria has been met for the selection):
I should note that I tried to pull in the exact text to select with xpath as well.
Thanks for you time,
Chris

    Division*

      <select id="division" disabled="true">
        <option value='Please Select' />

          <option class="sub_2"
            value="4"
            >
            Life Sciences
          </option>

          <option class="sub_2"
            value="7"
            >
            Engineering
          </option>

          <option class="sub_3"
            value="10"
            >

            Liberal Arts
          </option>

          <option class="sub_3"
            value="13"
            >
            Business
          </option>

          <option class="sub_18"
            value="19"
            >
            DIV TEST label
          </option>

          <option class="sub_21"
            value="22"
            >
            CHRIS DIV L
          </option>

          <option class="sub_21"
            value="23"
            >
            CHRIS DIV 2 L
          </option>

    </select>

Updating to the latest capybara and webdriver will fix this. The cucumber wiki suggests using old versions of capybara when working with Rails 2.x; it seems ok to use the latest. See this ticket: https://github.com/cucumber/cucumber/issues/152


Feature: sort-classes Improved custom group system

What rule do you want to change?
sort-classes
Describe the problem
The objective is to extend the custom grouping system of the sort-classes rule in order to respond to the following points

Extend custom group definitions to more than just pattern matching the name of an element. (see issue #165).
Allow users to explicitly define a custom group priority over other custom groups.
Allow users to override official groups priorities if they want.

For the sake of simplicity, I suppose that we are adding a advancedCustomGroups option to the list of existing options for this rule, but nothing prevents from using the existing customGroups option as well.
advancedCustomGroups could be an array of AdvancedCustomGroup, which follows the following interface:
interface SortClassesAdvancedCustomGroup {
  decoratorNamePattern?: string
  elementNamePattern?: string
  valueTypePattern?: string
  typeDeclarationPattern?: string
  modifiers?: string[]
  groupName: string
  selector: string
}

This interface is easily extensible if additional features need to be added later on.

groupName: The group's name. Today in customGroups, this is one key of the object.
selector: Filter on the selector of the element.
modifiers: Filter on the modifiers of the element. (All the modifiers of the element must be present in that list)
elementNamePattern: If entered, will check that the name of the element matches the pattern entered. Today in customGroups, this is the value associated to a key of the object.
decoratorNamePattern: If entered, will check that at least one decorator matches the pattern entered. (solves #165)
valueTypePattern: If entered, will check that the value type of the element matches the pattern entered. (can solve #189 with ArrowFunctionExpression and FunctionExpression, but I don't see other use cases for that otherwise)
typeDeclarationPattern: Similar to valueTypePattern but for type declaration (case 1 in https://github.com/azat-io/eslint-plugin-perfectionist/issues/189#issuecomment-2276741110)

I had in mind to have and conditions between selector, modifiers, decoratorNamePattern, valueTypePattern, etc... in order to match an element successfully.
Because advancedCustomGroups is a list of custom groups and not an object like it is the case with customGroups, this allows the user to properly define an order in which each advanced custom group should be used. Like customGroups, advancedCustomGroups would take priority over official groups if a match is found.
This system also allows users to replicate official groups by only using the selector and modifiers options. This allows them to still make sure that some official groups do not get overridden by other advanced custom groups by placing the official group replica first in the advancedCustomGroups list.
The same groupName can be used multiple times if needed. Official group names can be used as well.
Code example
Here is the simplified configuration that solves #165:
  {
            "groups": [
              "input",
              "output"
            ],
            "advancedCustomGroups": [
              {
                "groupName": "input",
                "decoratorNamePattern": "Input"
              },
              {
                "groupName": "output",
                "decoratorNamePattern": "Output"
              }
            ]
          }

Here is a simplified configuration that can solve #189:
{
            "groups": [
              [
                "public-method",
                "public-function-property"
              ],
              [
                "protected-method",
                "protected-function-property"
              ],
              [
                "private-method",
              ]
            ],
            "advancedCustomGroups": [
              {
                "groupName": "public-function-property",
                "selector": "property",
                "modifiers": ["public"],
                "valueTypePattern": "ArrowFunctionExpression"
              },
              {
                "groupName": "public-function-property",
                "selector": "property",
                "modifiers": ["public"],
                "valueTypePattern": "FunctionExpression"
              },
              {
                "groupName": "protected-function-property",
                "selector": "property",
                "modifiers": ["protected"],
                "valueTypePattern": "ArrowFunctionExpression" // Maybe it is possible to group both `FunctionExpression` and `ArrowFunctionExpression` at the same time with `minimatch`, I haven't looked it up.
              },
              {
                "groupName": "protected-function-property",
                "selector": "property",
                "modifiers": ["protected"],
                "valueTypePattern": "FunctionExpression"
              },
              {
                "groupName": "private-method", // Can even directly write `private-method` if we want
                "selector": "property",
                "modifiers": ["private"],
                "valueTypePattern": "ArrowFunctionExpression"
              },
              {
                "groupName": "private-method",
                "selector": "property",
                "modifiers": ["private"],
                "valueTypePattern": "FunctionExpression"
              }
            ]
          }

Additional comments
A preview of this feature can be found in the forked repo here: https://github.com/hugop95/eslint-plugin-perfectionist/tree/feat/sort-classes/advanced-custom-grouping
Waiting for https://github.com/azat-io/eslint-plugin-perfectionist/pull/196 to create an official PR if the idea is accepted.
Validations

[X] Read the docs.
[X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.

Added in baa701d494baa8d01f977a650080fb52c61dbc46.
Released in v3.2.0.

@azat-io Not yet implemented! 😄 Could you reopen please?

Reopened.


Improved the overview of the main page

✅ Fixes #49
This PR includes many updates to the README.md file to enhance its entire structure and visual appeal by using markdown badges, also the addition of a GitHub Actions workflow to automate updating the contributors list in the README.
Enhancements to README.md:

Improved Layout and Styling:

Center-aligned the header and added a table with badges for stars, forks, issues, open PRs, closed PRs, languages, and contributors. (README.md)
Updated the "Technologies Used" section with badges for each technology. (README.md)

Detailed Instructions for Getting Started:

Added steps for cloning the repository, installing dependencies, creating environment variables, and running the development server. (README.md)

Contribution Guidelines:

Expanded the contribution section with detailed steps for forking the repository, making changes, and submitting a pull request. (README.md)

Acknowledgment of Contributors:

Added a section to acknowledge contributors, with placeholders for automated updates. (README.md)

Automation:

GitHub Actions Workflow:

Added a new workflow file .github/workflows/contributors.yml to automate updating the contributors list in the README. (.github/workflows/contributors.yml)

@notsoocool Review this PR and add labels to it gssoc-ext, hacktoberfest and level etc

codecache-49.webm

@yashksaini-coder have you tested the workflow locally on your repository?

@yashksaini-coder have you tested the workflow locally on your repository?

Yes, all checks were done. Once merged with your main branch it will generate the list and display the profiles automatically.
You can also modify the action workflow to generate the table in a different way using parameters

Thank you for the PR! I will review it as soon as I get some free time.


Binwalk v3 doesn't recognize signature unlike v2

Binwalk v2 used to recognize files embedded into an image file (from a ctf) whereas v3 does not. The file is a jpg file, the embedded files are also jpg's and an invalid tiff.
File in question:
$ file ultimate-meme.jpg
ultimate-meme.jpg: JPEG image data, JFIF standard 1.01, resolution (DPI), density 300x300, segment length 16, Exif Standard: [TIFF image data, little-endian, direntries=8, description=Created with GIMP, orientation=upper-left, xresolution=128, yresolution=136, resolutionunit=2, software=GIMP 2.10.38, datetime=2024:09:16 19:51:13], comment: "Created with GIMP", progressive, precision 8, 881x500, components 3

Extracted files using binwalk v2:
$ file _ultimate-meme.jpg.extracted/*
_ultimate-meme.jpg.extracted/0:     JPEG image data, JFIF standard 1.01, resolution (DPI), density 300x300, segment length 16, Exif Standard: [TIFF image data, little-endian, direntries=8, description=Created with GIMP, orientation=upper-left, xresolution=128, yresolution=136, resolutionunit=2, software=GIMP 2.10.38, datetime=2024:09:16 19:51:13], comment: "Created with GIMP", progressive, precision 8, 881x500, components 3
_ultimate-meme.jpg.extracted/15BBE: JPEG image data, JFIF standard 1.01, resolution (DPI), density 300x300, segment length 16, comment: "Created with GIMP", progressive, precision 8, 500x60, components 3
_ultimate-meme.jpg.extracted/1E:    TIFF image data, little-endian, direntries=8, description=Created with GIMP, orientation=upper-left, xresolution=128, yresolution=136, resolutionunit=2, software=GIMP 2.10.38, datetime=2024:09:16 19:51:13

The jpg inclusive the extracted files are appended
image.tar.gz

This was caused by the fact that end-of-file detection for JPEGs was rudimentary at best. Just merged a patch into the master branch to fix this:


Add ProcessedFiles method

This adds a ProcessedFiles method to the ReadCloser type to allow the
caller to discover which files have been processed during decoding.

any thoughts on this @nwaples ?

Fixes #19


mod mail

old mod mail to ts
i changed from using embeds from user to channel to using webhooks
use button to close the modmail

Let's branch it and test!


Request to document Material

 Issue by sethladd
Thursday Oct 29, 2015 at 21:01 GMT
Originally opened as https://github.com/flutter/engine/issues/1874

Was looking at sample code in the Tutorial, and it used a Material class. I wanted to know what that was for, but didn't see docs for it in my editor (Atom)

 Comment by abarth
Thursday Oct 29, 2015 at 21:32 GMT

Yes, we need to add more dartdoc to the higher levels of the system.

Going to close this issue, as it's too vague. Generally speaking API docs are good :)


Template Addition

Adding Issues and Pr templates

yeah sure @rohan-kulkarni-25 i was going to create a issue for this


Rebound: add literature references for integrators

Rebound has the option of using various integrators (IAS15, WHFast etc.). These have separate literature references, which should be added to the literature output of AMUSE as well.

Is it possible to do a "LiteratureReferencesMixIn" for other things than classes, like functions?

@arjenve @ipelupessy any ideas about this? It may be relevant for other codes that have various integrators (like Huayno(?) and FDPS at some point) as well.

I think you can add the references to the rebound docstring for the moment...the other things are nice, but not possible at the moment I think...

Ok, that's a decent first step. I'll add the required references to the Rebound interface.

close since partially solved, rest is prob wontfix


Moving network (2) resources to v1beta1 version

Moving 2 resources to v1beta1 version:

[x] google_network_connectivity_hub
[x] google_network_connectivity_spoke

Description of your changes

Fixes #160
I have:

[x] Run make reviewable test to ensure this PR is ready for review.

How has this code been tested
Manual and Uptest:
google_network_connectivity_hub - link
google_network_connectivity_spoke - link

/test-examples="examples/networkconnectivity/hub.yaml"

/test-examples="examples/networkconnectivity/spoke.yaml"


[nz-select]: nz-select-item zoomMotion animation issue

Reproduction link
https://stackblitz.com/edit/angular-ksllvu
Steps to reproduce

Open dropdown
Select any user from search
Close search and dropdown
Open dropdown again

What is expected?
Selected items are rendered correctly, no error is thrown after clearing the field.
What is actually happening?
After opening the dropdown again you can see that the selected items are not showing, also clicking the clear search button throws:
ERROR TypeError: Cannot read property 'zoomMotion' of undefined

Environment
Info

ng-zorro-antd
9.1.2

Browser
Google Chrome Version 81.0.4044.138

duplicated #1455
you can disable animation with nzNoAnimation to skip this bug now.
blocked by https://github.com/angular/angular/issues/24041

I found solution. Need use nz-select with *ngIf="visible" and [(nzVisible)]="visible" for nz-dropdown. Example https://stackblitz.com/edit/angular-ksllvu-8udr3r

@LEXXEI I can confirm this workaround works in my case

@LEXXEI Thank you. it works fine.

@vthinkxie While this is a good temporary solution to this exact use case, it doesn't cover the case when you are using ng-content inside a component (when you have a custom component).
Take a look at this example. The steps to reproduce this are the same.
The only solution I found for this problem is to create an observable where I push the changes of the visible property, and then use it in my content, just like this

I believe this also occurs when an nz-select is open inside a modal.


Could numba support big integers for a * b?

Hello. I , I try to use numba to parallelize a function that takes 2 arrays and returns their multiplication (res [i] = a [i] * b [i]). However, the problem is that the values of a and b are greater than int64.
So the problem is that if i try to run the following code:
from numba import guvectorize, int64

@guvectorize([(int64[:], int64[:], int64[:])], '(n), (n)->(n)', target='cuda')
def multiplication(a , b, res):
    for i in range(len(a)):
      res[i] = a[i] * b[i]

N = 10
a = [10**N]
b = [10**N]
res = [0]

size = 10 ** 3
A = [a] * size
B = [b] * size
Res = [res] * size
multiplication(A, B, Res)

I'll get the incorrect results because of overflowing: Res[0][i] ==<PHONE_NUMBER>452241920 of course it's less than 10**20
I read issues in github saying that large int64 numbers are not used because it is part of the relationship with NumPy, however in NumPy I can do this calculation:
import numpy as np
a = np.array([10** 20])
b = np.array([10** 20])
a * b
>>> array([10000000000000000000000000000000000000000], dtype=object)

So NumPy casts it to  type "object". While in numba I did not find analogues of "object".
Is it possible to calculate first example of code with out  overflowing?
If it's not possible please advise me to get out of this situation in another way)

Numba does not have support for big integers, and using Python objects (in this case, Python's integer objects support arbitrary size integers) in nopython mode also is not supported.
Unfortunately, I'm not aware of a workaround for this.  I see you are trying to run on the GPU, which adds additional constraints.

xref https://github.com/numba/numba/issues/5005, duplicate, closing.


Unable to run embedded web server in unit test due to conflicting weld-se / weld-servlet versions

I'm trying to run an embedded web server (tomcat or jetty) in a junit test. The problem is that during weld bootstrapping when starting the embedded web server it picks up jakarta.enterprise.inject.spi.Extension from the weld-se package (org.jboss.weld.environment.se.WeldSEBeanRegistrant) instead of the weld-servlet package (org.jboss.weld.module.web.WeldWebModule) which leads to the following exception:
Caused by: java.lang.RuntimeException: Service class org.jboss.weld.environment.se.WeldSEBeanRegistrant didn't implement the required interface
        at org.jboss.weld.util.ServiceLoader.loadClass(ServiceLoader.java:230)
        at org.jboss.weld.util.ServiceLoader.loadService(ServiceLoader.java:210)
        at org.jboss.weld.util.ServiceLoader.loadServiceFile(ServiceLoader.java:184)
        at org.jboss.weld.util.ServiceLoader.reload(ServiceLoader.java:164)
        at org.jboss.weld.util.ServiceLoader.iterator(ServiceLoader.java:288)
        at org.jboss.weld.util.collections.ImmutableSet$BuilderImpl.addAll(ImmutableSet.java:158)
        at org.jboss.weld.environment.servlet.WeldServletLifecycle.createDeployment(WeldServletLifecycle.java:275)
        at org.jboss.weld.environment.servlet.WeldServletLifecycle.initialize(WeldServletLifecycle.java:153)
        at org.jboss.weld.environment.servlet.EnhancedListener.onStartup(EnhancedListener.java:66)
        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:4412)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:164)
        ... 25 more

Reproducer: https://github.com/jansohn/weld-junit5-embedded-jetty/tree/embedded-tomcat-weld-junit5
Is there any clever trick to make weld-se and weld-servlet-core on the same classloader behave correctly?

What's the use case for mixing weld-junit and jetty together?
Weld-junit is made for SE testing and hence contains Weld SE artifacts (and starts Weld SE container) whereas for servlets, you'd want the Weld Servlet components with a listener starting Weld container instead.

Is there any clever trick to make weld-se and weld-servlet-core on the same classloader behave correctly?

Actually, They don't seem to be on the same classloader here which is the problem. WeldSEBeanRegistrant definitely does implement the interface it complains about - jakarta.enterprise.inject.spi.Extension.
And if you take a look at the service loader code and what class loaders are used, you'll find that the jakarta.enterprise.inject.spi.Extensiontype  (the expected type we cast to; comes from CDI API artifact) is loaded by ParallelWebappClassLoader whereas Weld SE classes (WeldSeBeanRegistrant) are loaded by jdk.internal.loader.ClassLoaders$AppClassLoader. And this IMO causes the problem.

What's the use case for mixing weld-junit and jetty together?
Weld-junit is made for SE testing and hence contains Weld SE artifacts (and starts Weld SE container) whereas for servlets, you'd want the Weld Servlet components with a listener starting Weld container instead.

We use weld-junit (in test Maven scope) to have @Inject support in our unit tests. The project is a web application so it needs weld-servlet as we are using servlet containers to run our application, e.g. Tomcat.
For integration tests, e.g. high load scenarios, we want to spin up an embedded web server hosting our application which we can use to run the tests against.
In our old javax-style environment we have this running properly with embedded Jetty because embedded Tomcat wasn't working correctly when we set this up years ago.
After switching to jakarta-style environment we are now not able to get it running neither with Jetty (which still seems to have a different issue: https://github.com/jetty/jetty.project/issues/12285) nor Tomcat.

Is there any clever trick to make weld-se and weld-servlet-core on the same classloader behave correctly?

Actually, They don't seem to be on the same classloader here which is the problem. WeldSEBeanRegistrant definitely does implement the interface it complains about - jakarta.enterprise.inject.spi.Extension. And if you take a look at the service loader code and what class loaders are used, you'll find that the jakarta.enterprise.inject.spi.Extensiontype (the expected type we cast to; comes from CDI API artifact) is loaded by ParallelWebappClassLoader whereas Weld SE classes (WeldSeBeanRegistrant) are loaded by jdk.internal.loader.ClassLoaders$AppClassLoader. And this IMO causes the problem.

But actually it shouldn't pick up a class from Weld SE in the first place when it is initialized with org.jboss.weld.environment.servlet.EnhancedListener in a weld-servlet environment, right?
I'm not sure anything can be done in this project about the problem besides offering a weld-servlet mode which apparently does not exist.
I've opened an issue on the Weld issue tracker (https://issues.redhat.com/browse/WELD-2797) because in the end I feel this needs to be handled properly in the initialization/bootstrap code.

But actually it shouldn't pick up a class from Weld SE in the first place when it is initialized with org.jboss.weld.environment.servlet.EnhancedListener in a weld-servlet environment, right?

Weld bootstrap performs a service loader discovery and you have Weld SE in classpath which, I assume, finds the extension in question.

I'm not sure anything can be done in this project about the problem besides offering a weld-servlet mode which apparently does not exist.
I've opened an issue on the Weld issue tracker (https://issues.redhat.com/browse/WELD-2797) because in the end I feel this needs to be handled properly in the initialization/bootstrap code.

I don't think this is a supported scenario to be fair.
I know servlet (and EE server) testing was available with Arquillian where you can perform test injection as well; did you give that a go?
Here are some thoughts and ideas if you want to dig deeper into this but note that as there is a CL problem, it will likely be more difficult than this:

I recall we had a weld-se-servlet coop test somewhere with Tomcat that approached it the other way around - by starting Weld SE and then skipping bootstrap for servlet.

Take a look at this test.

In your reproducer you are currently bootstrapping servlet first - maybe try swapping that around?

Weld-junit is by default bootstrapping per-test, but you could try to perform that per-class by using @TestInstance(Lifecycle.PER_CLASS). In such a case, the SE container might be used first and the servlet would just re-use it.

I don't think this is a supported scenario to be fair. I know servlet (and EE server) testing was available with Arquillian where you can perform test injection as well; did you give that a go?

No, so far I have no experience with Arquillian. Back in the days we started with cdi-unit but it did not support Jakarta EE / JUnit 5 for a long time so we switched to weld-junit5.

Here are some thoughts and ideas if you want to dig deeper into this but note that as there is a CL problem, it will likely be more difficult than this:

I recall we had a weld-se-servlet coop test somewhere with Tomcat that approached it the other way around - by starting Weld SE and then skipping bootstrap for servlet.

Take a look at this test.

In your reproducer you are currently bootstrapping servlet first - maybe try swapping that around?

Weld-junit is by default bootstrapping per-test, but you could try to perform that per-class by using @TestInstance(Lifecycle.PER_CLASS). In such a case, the SE container might be used first and the servlet would just re-use it.

I did try to combine your two examples (posted the code here: https://github.com/jansohn/weld-junit5-embedded-jetty/tree/embedded-tomcat-weld-junit5-nobootstrap). Unfortunately as you expected it also fails:
2024-09-24 08:19:05,394 INFO  [main] org.jboss.weld.Version: WELD-000900: 5.1.3 (Final)
2024-09-24 08:19:05,652 INFO  [main] org.jboss.weld.Bootstrap: WELD-000101: Transactional services not available. Injection of @Inject UserTransaction not available. Transactional observers will be invoked synchronously.
2024-09-24 08:19:05,782 INFO  [main] org.jboss.weld.Event: WELD-000411: Observer method [BackedAnnotatedMethod] org.jboss.weld.junit5.auto.TestInstanceInjectionExtension.rewriteTestClassScope(@Observes ProcessAnnotatedType<T>) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds.
2024-09-24 08:19:06,024 INFO  [main] org.jboss.weld.Bootstrap: WELD-ENV-002003: Weld SE container 85663e00-39c4-4cbc-aac7-4f3eea7f9653 initialized
2024-09-24 08:19:06,040 INFO  [main] com.test.EmbeddedJettyIT: Starting embedded server...
Sept 24, 2024 8:19:06 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-nio-auto-1"]
Sept 24, 2024 8:19:06 AM org.apache.catalina.core.StandardService startInternal
INFO: Starting service [Tomcat]
Sept 24, 2024 8:19:06 AM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet engine: [Apache Tomcat/10.1.30]
Sept 24, 2024 8:19:06 AM org.apache.catalina.startup.ContextConfig getDefaultWebXmlFragment
INFO: No global web.xml found
2024-09-24 08:19:09,057 INFO  [main] org.jboss.weld.environment.servletWeldServlet: WELD-ENV-001008: Initialize Weld using ServletContainerInitializer
[...]
Caused by: java.lang.ClassCastException: class org.jboss.weld.bean.builtin.BeanManagerProxy cannot be cast to class org.jboss.weld.manager.api.WeldManager (org.jboss.weld.bean.builtin.BeanManagerProxy is in unnamed module of loader 'app'; org.jboss.weld.manager.api.WeldManager is in unnamed module of loader org.apache.catalina.loader.ParallelWebappClassLoader @1a4d1ab7)
        at org.jboss.weld.environment.servlet.WeldServletLifecycle.initialize(WeldServletLifecycle.java:126)
        at org.jboss.weld.environment.servlet.EnhancedListener.onStartup(EnhancedListener.java:66)
        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:4412)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:164)
        ... 82 more

Take a look at this test.

Out of curiosity: I'd expect that linked test to fail in the same way as my code does. Can you check that?

Out of curiosity: I'd expect that linked test to fail in the same way as my code does. Can you check that?

That one passes; the CI is running it on PRs, see this command for how to run it manually.
Note that it does not use weld-junit and runs on tomcat which means that the order in which contains start is reversed, plus tomcat will have different class loader setup, potentially avoiding this issue.

Out of curiosity: I'd expect that linked test to fail in the same way as my code does. Can you check that?

That one passes; the CI is running it on PRs, see this command for how to run it manually. Note that it does not use weld-junit and runs on tomcat which means that the order in which containers start is reversed (Weld SE first, then servlet which discovers an already running container), plus tomcat will have different class loader setup, potentially avoiding this issue.

Thanks, I was able to successfully run this locally on my machine, too. I'm still trying to figure out though why it is not working with my minimal example. I can see that there are arquillian dependencies and configuration files in place. But when I step through it in debug mode it does not even initialize anything from arquillian, so I don't think that is the difference. I'll play around with it some more to see if I can figure it out...

Arquillian is not present in that test. I suggested that framework because I know there are Arquillian adapters for servlets (such as this one for Tomcat) and those allow you to boot the servlet, use Weld and have tests injected all at the same time. From your description that seems to fit better to what you expect than mixing SE and servlet; give it a look.

I finally seem to have a working solution: https://github.com/jansohn/weld-junit5-embedded-jetty/blob/embedded-tomcat-weld-junit5/src/test/java/com/test/EmbeddedJettyIT.java
The only draw-back is that I cannot use @Inject on the test classes, otherwise the Weld initialization in the Tomcat container blows up.
The main issues were:

JARs in the WEB-INF/lib folder caused conflicts which resulted in the java.lang.ClassCastException
weld-junit and Tomcat used the same Weld instance which caused problems so I decided to pass an explicit WELD_CONTEXT_ID_KEY to the servlet container to make it use its own Weld instance exclusively

weld-junit and Tomcat used the same Weld instance which caused problems so I decided to pass an explicit WELD_CONTEXT_ID_KEY to the servlet container to make it use its own Weld instance exclusively

I think I don't understand the use case still.
You end up with two different Weld containers that know nothing about one another - what's the point/gain?
You won't have access to beans from the other container which seems to defeat the purpose of injecting into the test class, doesn't it?

weld-junit and Tomcat used the same Weld instance which caused problems so I decided to pass an explicit WELD_CONTEXT_ID_KEY to the servlet container to make it use its own Weld instance exclusively

I think I don't understand the use case still. You end up with two different Weld containers that know nothing about one another - what's the point/gain? You won't have access to beans from the other container which seems to defeat the purpose of injecting into the test class, doesn't it?

To be honest in my use case it does not make a difference, I just want to spin up my web application with CDI support to hit some servlets simultaneously for example. For preparation I sometimes need to inject in the test classes, too but it doesn't have to be the same instance as the one running in the web server.
Unfortunately my "solution" does not work once I add some more complexity to it (JSF, OmniFaces, etc.) so I'm pretty much back to square one...

I am sorry but this is out of scope of what Weld-junit is designed for.
I really recommend taking a look at Arquillian which covers this a lot better and I think most of the server/servlet testing is done with it anyway. Or perhaps peek into testsuites of those servlets to see what they leverage and how.

I decided to check out Arquillian today (https://github.com/jansohn/weld-junit5-embedded-jetty/tree/arquillian-embedded-tomcat) and it suffers from the exact same issue as all the other methods I have tried.

You shouldn't need Weld SE in that test case scenario; it's creeping in from somewhere - probably your Weld-junit dep (which is also redundant when running Arq container).
With that I am getting:
[INFO] Results:
[INFO]
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

Here's the PR - https://github.com/jansohn/weld-junit5-embedded-jetty/pull/1

Of course, I know that but I want to be able to use weld-junit in other test classes of my project...


The in-memory executer never cleans the map that it uses

Right now, the executors map is never cleaned off of finished runs. This will result in an ever growing map which eventually consumes all RAM.

It does now.