proposal: a shorthand to use in blade

Hi,
your package works great and (short of DB-supported translations) it makes it possible for me to migrate from L4 finally, but...
is there a way of using in BLADE conditions such as:
@if (Auth::user()->is('Admin'))

without a need to create any $user variable?
I'd be happy to see an elegant solution for the issue.
What I do now is to define a $user variable in each method with this command:
$user = User::find(Auth::id());

I tried to add the varaible controller-wide
public function __construct()
{
$user = User::find(Auth::id());
View::share('user', $user); // Share $user with all views
}

but it doesn't work to me. :(
Thanks again.

Hi,
you always need to have User object. If we're talking only about Blade, you can take advantage of view composers in Laravel 5.
Then you can have something like this:
@if ($currentUser->is('admin'))
    //
@endif

Instead of this:
@if (Auth::user()->is('admin'))
    // something
@endif

But if I understand correctly, you want something like this?
@role ('admin')
    // something
@endrole

@permission ('edit_articles')
    // something
@endpermission

Please, specify me your vision :-).

There is also a very nice video about view composers in Laravel 5. Have a look!

This solution would be amazing:
@role ('admin')
    // something
@endrole

The below made me perfectly happy:
@if (Auth::user()->is('admin'))
   // something
@endif

What I was unable to do in my L4 solution was using multiple conditions. I just user &&
Can you give me an example of a syntax for sth like this:
 @if (Auth::user()->is('admin') && Auth::user()->is('Developer'))

desired solution would be sth like this:
@if (Auth::user()->is('Admin','Developer')

After you answer I will prepare a pull request with all working examples you have provided. My pleasure.

There is a way to check for multiple roles or permissions in one condition in my package.
if ($user->is('admin|moderator')) // or $user->is('admin, moderator') or $user->is(['admin', 'moderator'])
{
    // if user has at least one role
}

if ($user->is('admin|moderator', 'all')) // or $user->is('admin, moderator', 'all') or $user->is(['admin', 'moderator'], 'all')
{
    // if user has all roles that we check for
}

The same syntax applies to permissions.
Later today, I'll be working on this syntax:
@role ('admin')
    // something
@endrole

New release is out. Check it out. There are some changes.


fix(Exception): handle exceptions in async context

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


Deploy issue

Describe the bug
I'm trying to deploy the backend of my app to a DigitalOcean droplet running Ubuntu 20.04. I build a docker image and then deploy that with Dokku 0.21.4 after pulling it to my VPS from DockerHub. I'm using AdminJS, and it works fine locally, but when I deploy I get the error below. Locally, I'm running an older version of node (12.18.4) with npm version 8.4.1.
Error message:
App container failed to start!!
=====> api web container output:
       query: SELECT * FROM current_schema()
       query: SHOW server_version;
       Warning: connect.session() MemoryStore is not
       designed for a production environment, as it will leak
       memory, and will not scale past a single process.
       AdminJS: bundling user components...
       server started successfully
       node:internal/process/promises:246
                 triggerUncaughtException(err, true /* fromPromise */);
                 ^
       [Error: EACCES: permission denied, mkdir '.adminjs'] {
         errno: -13,
         code: 'EACCES',
         syscall: 'mkdir',
         path: '.adminjs'
       }
       query: SELECT * FROM current_schema()
       query: SHOW server_version;
       Warning: connect.session() MemoryStore is not
       designed for a production environment, as it will leak
       memory, and will not scale past a single process.
       AdminJS: bundling user components...
       server started successfully
       node:internal/process/promises:246
                 triggerUncaughtException(err, true /* fromPromise */);
                 ^
       [Error: EACCES: permission denied, mkdir '.adminjs'] {
         errno: -13,
         code: 'EACCES',
         syscall: 'mkdir',
         path: '.adminjs'
       }
=====> end api web container output

Installed libraries and their versions

<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>
AdminJSOptions
AdminJS.registerAdapter({ Database, Resource });
    const adminJs = new AdminJS({
        databases: [conn],
        rootPath: "/admin"
    });

    const adminJsRouter = AdminJSExpress.buildAuthenticatedRouter(
        adminJs,
        {
            authenticate: async (email, password) => {
                const user = await User.findOne({ email });
                if (user) {
                    const matched = await argon2.verify(
                        user.password,
                        password
                    );
                    if (matched) {
                        return user;
                    }
                }
                return false;
            },
            cookiePassword: process.env.ADMIN_PASSWORD
        },
        null,
        {
            resave: false,
            saveUninitialized: false,
            secret: process.env.ADMIN_PASSWORD
        }
    );

app.use(adminJs.options.rootPath, adminJsRouter);

       [Error: EACCES: permission denied, mkdir '.adminjs'] {

This says that AdminJS cannot create a folder called .adminjs on your machine.  After it's bundled, it's served as components.bundle.js. I suggest pre-bundling assets for your production environment.
We have a package which helps with this: https://github.com/SoftwareBrothers/adminjs-bundler
Here's the script which I'm using in CI to upload my AdminJS assets to S3 storage:
/* eslint-disable max-len */
/* eslint-disable import/first */
// eslint-disable-next-line @typescript-eslint/no-var-requires
require('dotenv').config({ path: `${__dirname}/../../.env` });

import 'reflect-metadata';
import { promises as fs } from 'fs';
import { join, parse } from 'path';
import { bundle } from '@adminjs/bundler';
import AWS from 'aws-sdk';

import config from '../config';
// eslint-disable-next-line @typescript-eslint/no-unused-vars
import * as components from '../admin/components.bundler';
import getAdminOptions from '../admin/admin.options';

type UploadOptions = {
  keyPrefix: string;
  bucket: string;
  cacheControl?: string;
};

const aws = new AWS.S3({
  region: config.aws.region,
  accessKeyId: config.aws.s3accessKeyId,
  secretAccessKey: config.aws.s3secretAccessKey,
  signatureVersion: 'v4',
});

const uploadFile = async (
  { destinationPath: filePath }: { destinationPath: string },
  { keyPrefix, bucket, cacheControl }: UploadOptions,
): Promise<void> => {
  const file = await fs.readFile(filePath);
  const destinationName = parse(filePath).base;
  const s3Path = join(keyPrefix, destinationName);

  // eslint-disable-next-line no-console
  console.log(`Uploading ${filePath} to ${s3Path}`);

  return new Promise((resolve, reject) => {
    aws.upload(
      {
        Bucket: bucket,
        Key: s3Path,
        Body: file,
        CacheControl: cacheControl,
      },
      (err) => {
        if (err) reject(err);
        // eslint-disable-next-line no-console
        console.log(`Succesfully uploaded ${filePath} to ${config.app.assetsUrl}${destinationName}`);
        resolve();
      },
    );
  });
};

(async () => {
  // eslint-disable-next-line global-require
  require('@adminjs/passwords');
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
  const { resources: _resources, databases: _databases, ...otherOptions } = getAdminOptions();
  const manifestPath = 'src/admin/assets-manifest.json';
  const files = await bundle({
    customComponentsInitializationFilePath: 'src/admin/components.bundler.ts',
    destinationDir: 'public',
    adminJsOptions: otherOptions,
    versioning: {
      manifestPath,
    },
  });

  // eslint-disable-next-line no-console
  console.log(files);

  const keyPrefix = `admin-${config.app.environment}`;
  await Promise.all(files.map((file) => uploadFile(
    file,
    { keyPrefix, bucket: config.aws.s3bucket },
  )));

  await uploadFile(
    { destinationPath: join(process.cwd(), manifestPath) },
    { keyPrefix, bucket: config.aws.s3bucket, cacheControl: 'no-store, no-cache' },
  );

  await Promise.all(files.map((file) => fs.unlink(file.destinationPath)));
})();

Note that you must import all files with calls to AdminJS.bundle so that these components are properly registered, that's why I e. g. require @adminjs/passwords or import admin options or my components.bundler (this is where I keep all AdminJS.bundle calls).
Your other option would be to:
a) have write permissions on your server to create .adminjs folder there
b) if there is a path under which you can write new files/folders, you can try setting ADMIN_JS_TMP_DIR environment variable as long as you're using the latest version of adminjs (example: ADMIN_JS_TMP_DIR=path/for/adminjs/tmp, it defaults to .adminjs)
c) try to create .adminjs folder in your Docker image and see if AdminJS can generate entry.js inside

@dziraf Thanks for the detailed response. I got it working in the end. For some reason, there was a command in my Dockerfile to run as a different user. When I removed that, it changed the permissions in my Dokku app back to the root user. I'll definitely look into pre-bundling my assets though—thanks for the suggestion.


Can't compile a c file.

Hi!
I installed the packages and gave the for the compiler in my computer "C:\MinGW\bin". But i can't compile a file becasue a get this error:
c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find C:\MinGW: Permission denied
collect2.exe: error: ld returned 1 exit status
Somebody could help to me?

Thanks for reaching out!
We require the template to be filled out on all new issues and pull requests. We do this so that we can be certain we have all the information we need to address your submission efficiently. This allows the maintainers to spend more time fixing bugs, implementing enhancements, and reviewing and merging pull requests.
Thanks for understanding and meeting us half way :grinning:


Vscode debugging

Details on how I setup a firmware debug environment in Visual Studio code that works on both Mac and Linux (Ubuntu 18.04).
The master branch also has the material for MkDocs theme, so I don't think this can be easily applied to the currently live docs.

Thanks man!  This is cool.


WIP, VIZ: plot_compare_evokeds can plot epochs

As discussed in #5812: plot_compare_evokeds can take dicts of epochs. This allows:

for a dict of epochs: plotting the confidence interval within a subject/across trials
for a dict of lists of epochs: automatically selecting conditions from the epochs without having to construct the evoked objects

The API is unchanged. Only now code like this is legal:
plot_compare_evokeds({"aud": epochs, "vis": epochs})
@palday @mmagnuski

... the next step would be adding this as a method to Epochs. I.e.,
epochs.plot_compare_evokeds()
would plot one line per event_id.
epochs.plot_compare_evokeds(("aud", "viz"))
would be equivalent to plot_compare_evokeds({"viz": epochs, "aud": epochs}).
Would be nice for fast evaluation of simple contrasts, and, again, the API comes for free as it'd just be adding the existing function as a method to Epochs.

Done, thanks @agramfort .
Still WIP, needs an example etc.

I think this is elegant:
from mne.datasets import testing
data_path = testing.data_path()
fname = data_path + "/EEGLAB/test_raw.set"
montage = data_path + "/EEGLAB/test_chans.locs"

event_id = {"rt":1, "square":2}
eog = {"FPz", "EOG1", "EOG2"}
raw = mne.io.eeglab.read_raw_eeglab(fname, preload=True, eog=eog, montage=montage)
events, event_id = mne.events_from_annotations(raw)
picks = mne.pick_types(raw.info, eeg=True)
epochs = mne.Epochs(raw, events,  event_id, tmax=.7, picks=picks)

epochs.plot_compare_evokeds(picks=4);

You can also provide a conditions arg, with a list of the events you want to plot.
(Alternatively, this could be skipped, as it approximates epochs[conds].plot_compare_evokeds())

Or this:
import os.path as op
import mne

data_path = op.join(mne.datasets.sample.data_path(), 'MEG', 'sample')
raw = mne.io.read_raw_fif(
    op.join(data_path, 'sample_audvis_raw.fif'), preload=True)
raw.filter(None, 30, fir_design='firwin')
event_id = {'auditory/left': 1, 'auditory/right': 2, 'visual/left': 3, 'visual/right': 4}
events = mne.read_events(op.join(data_path, 'sample_audvis_raw-eve.fif'))
epochs = mne.Epochs(raw, events, event_id=event_id, tmin=-0.2, tmax=.5)

epochs.plot_compare_evokeds(picks=4, ci=.68, split_legend=True,
                            colors={"left": "C0", "right": "C1"},
                            linestyles={"auditory": "-", "visual": ":"});

@agramfort What do you think?
@mmagnuski useful?

(The CI errors are due to the lack of docstring for the method.)

@jona-sassenhagen Sure, looks very useful. In general I perfer separation of computation (here - erp) and plotting but in this case the convenience wins for me (and the computation is trivial and super-fast anyway so dropping intermediate results does not hurt anyone).

@agramfort are you in principle ok with this?

Would it make sense to have the Epochs method be a bit smarter for hierarchical event_ids? Right now, they are treated as flat and assigned a different color, but for 1-deep nesting it would be straightforward to do color for the outer level and linetype for the inner level.

I thought about that, but my hunch is this would be too much magic for @agramfort :)
Note we enforce zero structure on event ids. Although maybe this should change - we could more openly suggest, e.g., an ordering scheme, and implicitly make use of it.

Yeah, I'm also somewhat torn about the necessity of having the Epochs method, even though / because it's just a wrapper for the viz method.

@agramfort ..?
It seems @nbara and @mmagnuski like it ...
Maybe @sappelhoff has an opinion too.

no strong feeling here but I would suggest to discuss during the sprint next month.

+1 looks very useful for me during initial exploration in a notebook :-)

This probably became irrecoverably conflicted with Dan's big refactor. I am considering closing and writing new from scratch.


Fail when prerequisites not met

As @kipz pointed out, when you run an editor whose prerequisites are not met, a console.log is output, but this is lost in the bot. We think the editor should fail in this case. Current thinking is that the best way to fail in this case is to throw an exception.

This is a bit complicated. Changing the behavior to throwing an exception results in the scenario being aborted. There is currently no way to capture this behavior and test for it in the BDD framework.

See atomist/rug#569

Should be possible once atomist/rug#571 is merged and released.


up_squared: most of the test case timeout

Describe the bug
The test case failed after commit id: d5e7732e0d0f66bc9a3684f9597d9fd6a2d351b2 .
Many tests failed , we take hello_world as an example.
To Reproduce
Steps to reproduce the behavior:

source zephyr-env.sh
west build -p always -b up_squared samples/hello_world
Open another terminal and execute: picocom -b 115200 /dev/ttyUP2
west flash
See error
or
2.twister -p up_squared --device-testing --device-serial /dev/ttyUP2 -T samples/hello_world/ --west-flash=/home/chenp1/up_squared_efi.sh --no-skipped-report -vv
3.See error

Expected behavior
Test case should pass as expected.
Impact
Most the test case failed(timeout).
Logs and console output
DEBUG   - Flash command: ['west', 'flash', '--skip-rebuild', '-d', '/home/chenp1/work/zephyrproject/zephyr/twister-out/up_squared/samples/hello_world/sample.basic.helloworld', '--', '/home/chenp1/up_squared_efi.sh']
DEBUG   - -- west flash: using runner misc-flasher

<META HTTP-EQUIV="refresh" content="0; URL=/script.htm">

/home/chenp1/work/zephyrproject/zephyr/twister-out/up_squared/samples/hello_world/sample.basic.helloworld/zephyr/zephyr.efi

<META HTTP-EQUIV="refresh" content="0; URL=/script.htm">

DEBUG   - Timed out while monitoring serial output on up_squared
DEBUG   - run status: up_squared/samples/hello_world/sample.basic.helloworld timeout
INFO    - 1/1 up_squared                samples/hello_world/sample.basic.helloworld        FAILED Timeout (device 62.632s)
ERROR   - see: /home/chenp1/work/zephyrproject/zephyr/twister-out/up_squared/samples/hello_world/sample.basic.helloworld/device.log

Environment (please complete the following information):
OS: Linux,
Toolchain Zephyr SDK 0.13.2
Commit SHA or Version: d5e7732e0d0f66bc9a3684f9597d9fd6a2d351b2

Hi @andyross, @spoorthik  we found the up2 daily testing blocked by this change https://github.com/zephyrproject-rtos/zephyr/commit/d5e7732e0d0f66bc9a3684f9597d9fd6a2d351b2 . Do we need to set any extra BIOS configuration for supporting it? Thanks!

@shaoanxli: Do you see any BIOS output ? If not, could you check BIOS settings if EFI is to display-only ?

@shaoanxli: Do you see any BIOS output ? If not, could you check BIOS settings if EFI is to display-only ?

Currently ，the daily up_squared  board cannot enter the bios , is trying to find another board or wait for chenpeng to enter the lab to see if it can be solved .

this is mainly caused by the bios console redirection setting, not related to zephyr code.
because now we could still get test results from monitor screen via HDMI, the only problem was that we couldn't get results from device serial COM0, because that after d5e7732, we got results from bios efi console directly, if we want to access efi via serial, we need to enable this console redirection for COM0, like below:

tested to enable this on QA daily up_squared, now it worked well, so closed this.


Design: Use in notebook interface?

Let's say I have a Python notebook open and have some data in a dataframe. I would like to be able to understand that data better and visualize it with Voyager. Right now, I would have to export that as a CSV in the current directory, then open the file with the Voyager viewer. This is problematic, because it interrupts my flow in the notebook, creates a file I may not want to use again, and might be slow.
Also, I might want to explore the visualizations in Voyager, then settle on one I like, and embed that in the notebook.  Currently, I would have to copy the Vega Lite from Voyager graph I liked, then maybe use Altair to create a visualization for that dataframe with that data. Again, this isn't ideal because it disrupts my flow in the notebook.

For the first problem, I have the same feeling: it interrupts the work flow. What do you think if we have something like the graph building tool in Excel?  One concern is that with the data we have in python notebook (usually don't have a strict format like csv),  directly using Vega or Vega-lite would be easier for the users?

One concern is that with the data we have in python notebook (usually don't have a strict format like csv), directly using Vega or Vega-lite would be easier for the users?

Personally, I always use Altair if I am in a notebook and trying to visualize some data with Vega Lite. I think it will be important to switch between some GUI editor for the visualization and declarative format. So yeah, you should be able to move between these two.


Send a photo

Not tested or reviewed yet.

In README.md, the Usage Send a notification example doesn't use the new Notifier class.

There's no usage example for sending a photo

The test doesn't use the Notifier class and there's no test for send_photo

Tested it. We're good. Going to merge.


Migrate OG API to app router

Context
We have one last route to migrate to the /app router.
It generated the OG images (pages/api/og/index.tsx).
We should move this to the /app router.
Expected Behavior
The OG image generation should still work as it does now but be served from an API route in the /app router.
Steps to reproduce
Please provide detailed steps for reproducing the issue:
GET request to http://localhost:3000/api/og?title=Hello%20world!

Hi @NiallJoeMaher . Hope you are doing well.
I have migrated the OG image generation endpoint to /app/api. Can i go ahead and send a PR?

Heck yes! Thanks 🙏


Emojis in the terminal offset the selection 1 per character

Environment

VSCode Version: 1.14.2 (had the same issue in the previous version as well)
OS Version: OS X 10.11.2

Problem
See how a character (which is =)gets copied from the left and one character (which is 3) from the right is skipped.

Steps to Reproduce:
Select a text from Integrated Terminal, copy it using right click or cmd+c, and then paste it somewhere

I suspect the :beer: emoji in the terminal prompt is probably responsible for this, and that this would be reproducible by having any emoji (or any other character from one of the supplimentary Unicode planes) in your prompt. If what I suspect is correct, changing your prompt to contain two beer emojis (i.e., :beer::beer:) would cause the selection to be off by two characters rather than one, because some part of the selection code is counting code units when it should be counting codepoints, or vice versa.
For anyone not aware of the difference between code units and code points: a code point is a single Unicode character, like U+1F37A. In UTF-8, that character is represented as the sequence 0xF0 0x9F 0x8D 0xBA. In UTF-16, it's represented by the surrogate pair 0xD83C 0xDF7A. A "code unit" is the individual units of those representations; so 0xF0 is a code unit in UTF-8, and 0xD83C is a code unit in UTF-16. A single code unit will always be the same size in any given Unicode encoding (8 bits in UTF-8, 16 bits in UTF-16). But a single code point will vary in size. People working in UTF-8 are constantly aware of this, but people who work in UTF-16 often forget this point since so many UTF-16 codepoints are a single code unit long.

This might be related to https://github.com/Microsoft/vscode/issues/26038. It probably stems from a different cause ultimately, but looking at how https://github.com/Microsoft/vscode/issues/26038 was resolved is likely to help with fixing this bug.

@rmunn you're exactly right, 🍺 is causing the problem. Created https://github.com/sourcelair/xterm.js/issues/826
#26038 is related but the case is different, the problem there was just that there was an extra span. For this issue it appears that the selection logic is simply counting an emoji as the wrong number of characters.

This should be fixed in v1.18, closing for verification.


Adding opp name setting validation, fixed formula name to correctly key off of open ended status.

Warning
Info

Opportunity Naming is now out of beta! If you already created opportunity name settings, you'll have to edit each setting, select the correct "Attribution" setting, and save the setting.

Issues

@davidhabib Ready for review, added validation and a test.


Dockerize the app

Simple docker config would be great. It should be able to start server, start client and run tests.

Hey,
so you want a docker-compose file to startup your Project, is that correct?

Hi, @Rayleigh3105! Yes, nothing special, just basic implementation of docker, so it would be easier to unfold the project on different machines. I've done something similar here in the first version of the [app], but I'm not sure if it's correct, I'm just learning docker.
(https://github.com/DavidGolodetsky/GeekScore-1)

I think I Van help you out.

Hey, can you assign the Ticket to me?

The compose file I´m creating, will not work for windows. The reason for this are mount binds for the database data which are getting stored on the host.
Is it necessary to store data permanent on the host? Or is this docker-compose file only for development purpose?

yeah, it's fine, development purpose is first. If anything, it'll be improved later if it's needed.

I´m getting an error when pushing a new branch to this repo.
remote: Permission to DavidGolodetsky/GeekScore-2.git denied to Rayleigh3105.
fatal: unable to access 'https://github.com/DavidGolodetsky/GeekScore-2.git/': The requested URL returned error: 403
00:53:17.565: [GeekScore-2] git -c credential.helper= -c core.quotepath=false -c log.showSignature=false push --progress --porcelain origin refs/heads/docker:docker --set-upstream
remote: No anonymous write access.
fatal: Authentication failed for 'https://github.com/DavidGolodetsky/GeekScore-2.git/'
Can you give me write access?

You don't need to have any specific access in order to create PR. You need to fork the repo, create a branch in your repo, push everything there and create a PR from this branch to my master. More info here: https://github.com/acmbvp/Hacktoberfest#2-star-and-fork-this-repository

Also, I've updated Readme contributions guid.

PR is made -> https://github.com/DavidGolodetsky/GeekScore-2/pull/56


should I use pretrained for fine-tuning v1.3 weight?

Hi,
My purpose is to fine tune v1.3 model weight trained at stage 3 in the image below for text2video.

However, the weights uploaded on HF are of 640x640 (link below) while the resolution used at stage3 is 352x640.
https://huggingface.co/LanguageBind/Open-Sora-Plan-v1.3.0/tree/main/any93x640x640
Q1. Where did 640x640 come from?
Q2. Assuming any93x640x640 is the latest weight of v1.3, should I use this weight for --pretrained?
Below is the script I'm using for fine-tuning.
You can try to generate that the best results should be at 352x640, but at the same time it can generate other resolutions as long as they are within 640x640.


Fix locales/parameters settings in config (fixes #23)

@sweoggy This should fix the issue you reported in #23.

@sweoggy Do you have a moment to have a look at this fix?

It works as expected!


Swashbuckle.AspNetCore.SwaggerGen and Swashbuckle.AspNetCore.SwaggerUi RC1 to RC3 update

After updating this 2 packages from version 1.0.0-rc1 to version 1.0.0-rc3 I noticed that the UseSwaggerUi extension method has been renamed to UseSwaggerUI. After changing the code the swagger endpoint stopped working and the following exception is now being shown: "Object reference not set to an instance of an object.". The HTTP error code is 500. The actual configuration line is "app.UseSwaggerUi(options => { options.SwaggerEndpoint("/swagger/v1/swagger.json", "V1 Docs"); });".
Is there some other changes that I should be implementing to accomplish the update?
Thanks in advance!

Try deleting project.lock.json

Thank you, I will be looking forward for an updated package then.


md-input-container invalid state

Bug, feature request, or proposal:
question, bug, or feature request. not sure
What is the expected behavior?
When a user enters text into a required input field and removes the text, there should be an immediate warning as the form control is now touched.
What is the current behavior?
The invalid color and md-error text are only updated after blur.

What are the steps to reproduce?
<md-input-container>
      <input mdInput formControlName="answer" [required]="true">
     <md-error *ngIf="answerControl.errors?.required">Dies ist ein Pflichtfeld.</md-error>
</md-input-container>

What is the use-case or motivation for changing an existing behavior?
better user experience
Which versions of Angular, Material, OS, TypeScript, browsers are affected?
ng4.1.x, md beta 5
Is there anything else we should know?

Error state is calculated as
isInvalid && (isTouched || isSubmitted)

and touched is true when the control has been focused and then blurred.
There's an open issue at https://github.com/angular/material2/issues/4232 that could be of interest.

ok, but where does isSubmitted come from? My control does not change to submitted when i submit the form

See the source here

@willshowell yes, but there is no submitted property on my form, also in my usecase i cannot use a submit button to submit my form.

Hmm I see. I think for your original question, your best bet is to push the team on #4232 since that would allow you to configure how the errors are shown.
As a workaround for now, you could bind to the focus event and use myFormControl.markAsTouched(). I think that would get the error to show up immediately.

ok found a workarround. I created a hidden submit button and an event listener for my custom form submitted event:
´´´
formSubmittedSubscription = this.surveyService.formSubmittedChange.subscribe(value => {
this.formSubmitted = value;
this.submitBtn.nativeElement.click();
});
@ViewChild('submitBtn') submitBtn: ElementRef;
´´´

Tracked via #4232


Database connection dropped on long running jobs from Windows Container

Is there any way we can increase the TCP idle timeout value for Windows Container? The pod running on Windows Node is connecting to a database external to the cluster but in the same network where sometimes the Database takes 20+ minutes to respond with results and the client closes the TCP connection i.e. Windows container.
I found the following documentation link:
--> https://learn.microsoft.com/en-us/azure/aks/windows-faq?tabs=azure-cli#what-is-the-default-tcp-timeout-in-windows-os
However, if the request is initiated directly from the Windows node then connection doesn't drop after 20+ minutes but from the pod it's dropping.

Unfortunately, there isn't a way to increase the idle timeout for Windows Containers, we do have an issue (#81 ) that we monitor the interest of if this is a priority for you. At the time we of the original issue though, we deemed this enhancement not a priority.
A possible workaround to this is to implement a keep-alive mechanism where you send periodic keep-alive messages to the external database to ensure that the TCP connection remains active.
CC @mikezappa87 for visibility.

Hey @fady-azmy-msft thanks for replying, I checked for adding tcp_keepalive in deployment for the pods but as per my understanding it will work fine for Linux container and not sure about Windows Container. Will you be able to confirm or share an example for Windows Container if possible for you?

@fady-azmy-msft any help on this please?

The container networking stack has different settings outside of the ip stack for the host. A few questions.
What database are you using? Does it have any way to send keep alives?
Have you tried to optimize the database so that a query does not take 20+ minutes?
Keep in mind, increasing the timeout can impact performance in other ways since the socket is left open.

Closing this because it's going stale.


add sql managed instance

Hi,
Recently we had to setup managed ident auth into SQL MI from Cog search, would love to see this page updated to reflect that product being a viable offering. We found out through trial and error that it does work. So would like to see the docs reflect that.
Thanks,
Paul

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 6e98ae28-72c2-72c8-ddc4-4015b4c90968
Version Independent ID: 2d86eef9-0259-ec0c-3b4a-390f53296cc9
Content: Connect to Azure SQL - Azure Cognitive Search
Content Source: articles/search/search-howto-managed-identities-sql.md
Service: cognitive-search
GitHub Login: @gmndrg
Microsoft Alias: gimondra

@pmpopovichjr, Thanks for the feedback! We are taking a look into this and will get back to you soon.

pmpopovichjr, Your feedback has been shared with the content owner for further review. Thanks again for your feedback.

@pmpopovichjr we are currently working to update this content. Thank you so much for your feedback and time.

@pmpopovichjr We have created the article for SQL Managed Instance with managed identity. This will be available publicly as soon as merged with all content. Thank you so much for your feedback.

#please-close


No DefaultAuthenticateScheme found when using AddIdentityCore

Issue / Steps to reproduce the problem
Create an application with Identity Server 4 and Asp.Net Core Identity simply using:
dotnet new is4aspid

Then on Startup replace the code line:
services.AddIdentity<ApplicationUser, IdentityRole>()

By:
services.AddIdentityCore<ApplicationUser>()

Which is the Asp.Net Core option to use only User / Claims without Role.
Exception
When I run the application I get the Exception:
InvalidOperationException: No DefaultAuthenticateScheme found.
IdentityServer4.Services.DefaultUserSession.GetCookieSchemeAsync() in C:\local\identity\server4\IdentityServer4\src\IdentityServer4\src\Services\Default\DefaultUserSession.cs, line 114

I suppose this is a bug?
Is there a way to solve this?

Set the IdentityServer options' CookieAuthenticationScheme: http://docs.identityserver.io/en/latest/reference/options.html#authentication

@brockallen Do you have any example / template using AddIdentityCore instead of AddIdentity?
I am asking this because your answer helped me solving the problem but now a new one shows up:
InvalidOperationException: Unable to resolve service for type 'Microsoft.AspNetCore.Identity.SignInManager`1[Entities.User]'
while attempting to activate 'IdentityServer4.AspNetIdentity.ResourceOwnerPasswordValidator`

And I think more issues will come up as IdentityCore leaves some configuration out which is needed by IdentityServer.

I found a better way by using:
  .AddDefaultIdentity<User>()

Which allows to use User without Role and does not seem to miss any configuration needed by Identity Server.


Make pumps mutually exclusive

Forces only one pump to be active at a time, to avoid the sudden inrush current browning out the Pi or causing weirdness when multiple pumps fire and drop the voltage.

Note, this is all included in #5 which has an additional fix so that it doesn't free-run the pump and cause water chaos. This probably doesn't need merging separately.


Wrong links in rendered content website

When rendering a website with NEBULA, the links sometimes lead to a url with /NEBULA in there.

This was solved as per #20


enhacement: avoid enumerate subgraph twice

Signed-off-by: xiejiann<EMAIL_ADDRESS>Proposed changes
If the upper bound number of HyperGraph's subgraph is greater than the limit, we just simplify it rather than after enumerate failed
Problem summary
Describe your changes.
Checklist(Required)

Does it affect the original behavior:

[ ] Yes
[ ] No
[ ] I don't know

Has unit tests been added:

[ ] Yes
[ ] No
[ ] No Need

Has document been added or modified:

[ ] Yes
[ ] No
[ ] No Need

Does it need to update dependencies:

[ ] Yes
[ ] No

Are there any changes that cannot be rolled back:

[ ] Yes (If Yes, please explain WHY)
[ ] No

Further comments
If this is a relatively large or complex change, kick off the discussion at<EMAIL_ADDRESS>by explaining why you chose the solution you did and what alternatives you considered, etc...

TeamCity pipeline, clickbench performance test result:
the sum of best hot time: 34.45 seconds
load time: 476 seconds
storage size:<PHONE_NUMBER>0 Bytes
https://doris-community-test-1308700295.cos.ap-hongkong.myqcloud.com/tmp/20230206041038_clickbench_pr_90629.html


Object literal fat arrow with argument parens causes syntax highlighting error in jsx

Using the fat arrow syntax with argument parens in an object is causing weird syntax highlighting for the remainder of a jsx file.

However, omitting the parens, or using the function shorthand syntax works fine.

I can see what is happening. Neither of the first two are working, but the second is less offensive. In the first two, because the grammar doesn't expect a literal named fat arrow in an expression the
 getAttribute: (name) => {

is being interpreted a flow type of a function named getAttribute returning some form of callback.
I'll look into this.

I've just committed a change to the master branch that should fix this but may have other issues. It is not published to atom. Any chance you can check this out by downloading the new grammar files  and replacing the current ones and reloading atom?

is being interpreted a flow type of a function named getAttribute returning some form of call back

I should have said - is being interpreted as an argument named getAttribute being passed to a function that returns some form function. Or in the second case returning a value of type name.

I'll give it a shot.

It works! Thanks.

Thanks for your help. I'll publish this once I've done some more checks.


setWindowSoftInput Problem

setWindowSoft Input(binding.price EditText,binding.root) I use the above code for a button and it works fine, but when I click on another edittexe in the same fragment, the screen scrolls completely.
How can we solve this?

soft-input-event: 1.0.9
Android: API 28

https://i.hizliresim.com/ssn2fzz.gif

I'm sorry, I don't know what happened, I missed this question. I'm not very clear about the issue you mentioned. Could you fork the repository to reproduce the problem? I will fix the problem as soon as possible


Chapter 10: WASM samples not working (book and code differences)

I'm trying to execute the samples for JS interoperability.
I'm having a lot of problems.
a) I miss the @rendermode InteractiveWebAssemblyin the book (is in the github code only)
b) The file Chapter10/MyBlog/SharedComponents/Demo/JSInteropSamplesWasm/JSToStaticNET.razor has the code pointing to sample in await JSHost.ImportAsync("nettojs", "../JSInteropSamples/NetToJS.razor.js");but, on the other hand the file NetToJS.razor.js exist in the correct folder JSInteropSamplesWasm/NetToJS.razor.js
Still fighting to get this working in my installation. It's possible new issues arise.

Those are samples for reference not "follow along"-instructions. Since we don't use it in our project, so there might be missing steps.
Not sure what you mean with b?

The b) is a problem of cut&paste. You duplicated the folder, and forgot to modify the javascript called. It worked because the second one call the first one javascript, and is the same code.


Should not export py2ju

We should release a breaking version where we do not export this helper function. It is fine to just type CDSAPI.py2ju.

I would like to take this one.

Thank you @klu17 for the help. Assigning you to the issue :)


Claude v2.1

Adding Claude v2.1.
Tested locally with IMDB and Raft, where it performed significantly better than v2.0

@farzaank you should merge main, we have disabled the test that is failing

@farzaank you should merge main, we have disabled the test that is failing

Since @yifanmai requested changes I need to wait for re-review to merge.

@farzaank you should merge main, we have disabled the test that is failing

Since @yifanmai requested changes I need to wait for re-review to merge.

What I meant is merge main into your branch and the test fail will go away.
git checkout main
git pull
git checkout farzaan/claude2.1
git merge main


How to pass supress_tokens config in WhisperConfig?

Basically I want to run whisper and be able to generate quotation marks (") in the transcript. I can't find a way to pass config to whisper in stable-ts.
Its apparently easy to do in normal whisper:
https://github.com/openai/whisper/discussions/844
But I guess I'll have to do it using this config? Problem is I can't find this file in Google Colab where I'm runing stable-ts.
https://huggingface.co/docs/transformers/en/model_doc/whisper#transformers.WhisperConfig

suppress_tokens='' works unless you're using the Hugging Face models.
For Hugging Face models, you can remove quotation mark tokens from this list of suppress_tokens in generation_config of the model.
model = stable_whisper.load_hf_whisper('base')
tokenizer = model._pipe.tokenizer
suppress_tokens = model._pipe.model.generation_config.suppress_tokens
for i, token in reversed(list(enumerate(suppress_tokens))):
    text = tokenizer.decode([token])
    if '"' in text or "'" in text:
        suppress_tokens.pop(i)
        print(f'Removed:{text}')

Note: there are tokens in suppress_tokens will cause hallucinations if removed.

Thank you. Your code for hugging face models worked. Feel Although I still do not get where to pass the supress_tokens='' in stable-ts. Do you mean like this?
result = model.transcribe('audio.mp3', supress_tokens='')
I tried that but it didn't work.

Although if its not too much bother can you please explain where to pass the supress_tokens='' in stable-ts. I tried it like this but it didn't work.

There's a typo parameters you used, supress_tokens. It should be suppress_tokens.


[Playground] - Remove authentication step for Example pipeline

Need to remove Authentication step from "playground_deploy_examples" pipeline

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

[ ] Choose reviewer(s) and mention them in a comment (R: @username).
[ ] Mention the appropriate issue in your description (for example: addresses #123), if applicable. This will automatically add a link to the pull request in the issue. If you would like the issue to automatically close on merging the pull request, comment fixes #<ISSUE NUMBER> instead.
[ ] Update CHANGES.md with noteworthy changes.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

See the Contributor Guide for more tips on how to make review process smoother.
To check the build health, please visit https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md
GitHub Actions Tests Status (on master branch)

See CI.md for more information about GitHub Actions CI.

LGTM thanks!


First review of the Apptentive-mParticle kit

Looks good. Do you want to merge or should I?

If it looks good to you I can merge it to master and create the repo in mParticle-Integrations that will be the kit's final home.


export-client: Fix getting no registrations from memorydb

It was returning null instead of empty array when a registration was never added.

I'm not sure, but I should tell that it is not the case. In data y metadata I used a different approach when getting all the items in one table.

@feclare, I checked this issue it's present in core-data. Should be fine to fix it in another PR

@jduranf Thanks for the test.
I think I will add the fix to this PR as it is the same error.

@feclare @jduranf Do we have an issue for what's being addressed here? If so, can you link it in the PR comment above?


STANDALONE mode does not load current Team/Roster XML from FUMBBL correctly

Trying to set up the server in STANDALONE mode and importing a team from FUMBBL I ran into some issues, that looks like bugs.
To reproduce:

Fetch the XML for a Team on FUMBBL, e.g. https://fumbbl.com/xml:team?id=1158751
Copy it as file to /ffb-server/teams/human_team.xml
Note it has the rosterId: 4964
Trying to fetch that roster using this endpoint fails: https://fumbbl.com/xml:roster?id=4964 (I guess this is working as intended)
Fetch the roster data using https://fumbbl.com/xml:roster?team=1158751 and copy it to /ffb-server/teams/test_human_roster.xml (note that it has an .
Start the server in standalone mode.
Start a test game with the team that was copied. (using coach cmelchior)
The server will now log this crash:

2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.RosterCache.getRosterById(RosterCache.java:34)
2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.GameCache.updateRoster(GameCache.java:246)
2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.GameCache.lambda$getTeamsForCoach$1(GameCache.java:305)
2024-10-07T07:48:18.146 -------- ---- 	at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197)
2024-10-07T07:48:18.146 -------- ---- 	at java.base/java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:1024)
2024-10-07T07:48:18.146 -------- ---- 	at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509)
2024-10-07T07:48:18.146 -------- ---- 	at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
2024-10-07T07:48:18.146 -------- ---- 	at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:575)
2024-10-07T07:48:18.146 -------- ---- 	at java.base/java.util.stream.AbstractPipeline.evaluateToArrayNode(AbstractPipeline.java:260)
2024-10-07T07:48:18.146 -------- ---- 	at java.base/java.util.stream.ReferencePipeline.toArray(ReferencePipeline.java:616)
2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.GameCache.getTeamsForCoach(GameCache.java:305)
2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.handler.ServerCommandHandlerJoinApproved.sendTeamList(ServerCommandHandlerJoinApproved.java:256)
2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.handler.ServerCommandHandlerJoinApproved.handleCommand(ServerCommandHandlerJoinApproved.java:110)
2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.handler.ServerCommandHandlerFactory.handleCommand(ServerCommandHandlerFactory.java:46)
2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.net.ServerCommunication.handleCommandInternal(ServerCommunication.java:131)
2024-10-07T07:48:18.146 -------- ---- 	at com.fumbbl.ffb.server.net.ServerCommunication.run(ServerCommunication.java:106)
2024-10-07T07:48:18.146 -------- ---- 	at java.base/java.lang.Thread.run(Thread.java:1583)

Looking at the code, the behaviour makes sense since the new roster API doesn't have an ID that matches <rosterId> but matches team id instead. It is avery easy to fix, but it raises a few questions:

Is it intended that the standalone mode should not be able to load current rosters from FUMBBL?

Should the standalone roster loading mechanism be backwards compatible? I.e. if I provide a fix, should it still be able to load the old XML format?

All the team/roster/setup information looks outdated, are they actively being used for anything? I guess the question is if I provide a patch for the roster loading, should I delete/update these? E.g. all the setup files need to adjust their values (it looks like they are off-by-one).

Just had a look at the RosterCache and yes, that is currently not working with the fumbbl xmls out of the box. So far I did not bother with it as you can easily add the roster id to the xml when needed and the live mode looks up the roster per team anyways.
If you feel like adding a fix for that go ahead. As long as the existing teams still work afterwards it should not matter how they are looked up. Just make sure your change only affects standalone mode.
I use the existing teams for local testing all the time. I am aware the stats are not in syn with the official ones but that does not matter much. But what do you mean by the setup files being off-by-one? Setups are linked to team ids, so changes in roster ids or the actual values in the teams should not affect that.
From my side I do not see any need or much benefit from updating the teams but feel free if you want to.


Tic-Tac-Toe Game: Extension Fails to Load Due to Missing Icons in manifest.json

Describe the bug
The Tic-Tac-Toe Game extension fails to load due to missing icons specified in the manifest.json file. The error message indicates that the file images/icon-48.png could not be loaded, which results in the entire manifest failing to load.
To Reproduce
Steps to reproduce the behavior:
Go to the directory ~\Open source\GGExtensions\Tic-Tac-Toe Game
Attempt to load the Tic-Tac-Toe Game extension in the browser
Observe the extension failing to load
See error message indicating the missing icon and manifest load failure
Expected behavior
The Tic-Tac-Toe Game extension should load successfully without any errors. All icons specified in the manifest.json file should be present and accessible.
Screenshots

Additional context
The error indicates that the icon file images/icon-48.png specified in the manifest.json is missing. Ensure all files referenced in the manifest are correctly placed in the specified paths.

working fine @Sulagna-Dutta-Roy  close these kind of issues


recursive disclosure with sd-jwt

specification are here: https://www.ietf.org/archive/id/draft-ietf-oauth-selective-disclosure-jwt-12.html#name-example-sd-jwt-with-recursi

test with backup with sicpa VCs


Update Dockerfile

Deleting apt cache in each RUN step is history and file-size friendly.

Hi @mancvso, thanks for the patch.
Could you explain why moving / appending apt-get clean all to initial dependencies install makes the final container image any smaller?

It doesn't, but subsequent modifications to the Dockerfile will have
smaller layers.
2015-01-15 20:08 GMT-03:00 Anastas Dancha<EMAIL_ADDRESS>
Hi @mancvso https://github.com/mancvso, thanks for the patch.
Could you explain why moving / appending apt-get clean all to initial
dependencies install makes the final container image any smaller?
—
Reply to this email directly or view it on GitHub
https://github.com/anapsix/gitlabci-docker/pull/7#issuecomment-70180370.

--
Brian Vidal

I suppose, if apt-get clean all is "squashed" onto install step, the whole install step will result in a smaller install layer, which is good.
Alrighty then..


Enable LG debuggability

fixes #2385
Enable LG debuggability with event handler.

Add event in LG sdk
Add event handler in Adaptive Generator

moving this out of R9

This should not be merged until we open master for R10 commits

@cleemullins  @tomlm  may you take a look and to see if there is any problem.

blocked by the ID discussion https://github.com/microsoft/botbuilder-dotnet/pull/4155#discussion_r446528210

LG debugger is ready to review. All kinds of discussions and suggestions are welcome 😊
@boydc2014  @tomlm @chrimc62 @cleemullins

@tomlm , @cleemullins , @boydc2014 , please review if all your concerns have been addressed. Thank you.


chore: fix doc

RT

fix typo
add doc

Thanks. But I want to move this section the official docs site later. See docs repo at https://github.com/farm-fe/farm-fe.github.io, maybe you can add it to the docs. Appreciate for your contribution.

Thanks. But I want to move this section to the official docs site later. See docs repo at https://github.com/farm-fe/farm-fe.github.io, maybe you can add it to the docs. Appreciate for your contribution.

👌🏻


the result of training TS-Net on the new subject is  poor

the result of training TS-Net on the new subject is  poor ,
LEARNING_RATE = 2e-4
training image num is 296 .

and when the training image is same as testing image .
the result  is good,
so it need a large number of images includes different pose to train?

Hi, @chenbolin-master, for the new subject, you may need some images including different poses to ensure the good generalization ability of the model.


Provide output as text files.

Is your feature request related to a problem? Please describe.
It's quite costly to obtain the output of this model at the moment. One has to prepare their system to run it, then do so for a few hours.
Describe the solution you'd like
If you guys are running it most days anyway, couldn't you just provide the output? I see the graphs on your website, but no raw data output from anything I can see. It would be very helpful!
Describe alternatives you've considered
Putting the graph into one of those graph digitisers. Or just running it myself.
Additional context
Just a thank-you for your work on this!

How long does it take to run?  I'm running it now.  Only took about 15 minutes to setup.  What kind of machine are you using.  I will benchmark mine when it finishes...

Approximate benchmark is it takes about 40 minutes on an old mac-mini.  I would bet it would run about 4x faster on a newer machine.  I give this just so that other users running for the first time can have an idea on how much time it would take.

G-Rutter -- I think the run takes about an 40 minutes on a macmini, although I am not sure I get the same results as they are presenting.  To get the data in tabular form, find make-table.r and uncomment the commented lines that do a write.csv.  You can change the target directory from "figures" to something else you prefer.  I suggest setting up the batch job to run once around 1300Z so as to capture the current day's Euro CDC data.  After that -- no need to resort to reading pixel's from a chart.  If you are lucky you can get the Imperial College Team to do it for you, but it is not that hard.  I wrote a small r function to translate their csv's back into the format that my R model expects transposing the rows and columns.

Hi @g-rutter  sure we are working on it to provide csv or just a model that runs in like an hr or so. @becare-rocket  that 40 min is the debug run not the full run.

@g-rutter I have a script here that generates a CSV from the output data: https://github.com/jarib/covid19model/blob/6e4a0e36e220333d43b8f6d75480b2e16cbb9240/make-country-csvs.r
@s-mishra Let me know if you'd like a pull request that drops this under web/ somewhere.

@s-mishra Thanks for your response. I am glad to hear that. I think the issue should remain open if your advice is "we are working on it" - that would be the usual approach.
@jarib Thanks for this. It should be helpful to the Imperial team.

Hello @jarib,
Lovely feature! It was on my todo list, I'm gonna pull it into my fork on branch https://github.com/payoto/covid19model/tree/community-contribs , if you don't mind.
I'm maintaining a branch of community features on my fork feel free to have a look for something of interest.
@s-mishra It would be nice to reopen this and tag it with the community label as we discussed the other day, similarly with PR #66 which seems related.


Implement undo/redo command

Store the current game state every time a move is made or deck index is changed.

This seems like it could be really in effecient if the user is going to the next card in the deck.

Store an array of moves so a user can undo and redo moves when they want.
When a user makes a move after undoing, all the saved moves after the current move are lost.
Store the original board so all the moves can be replayed? - I think this should be for if we want to implement saving games.

Undo has been implemented.


Deserialization error for Acknowledgement in Spring Kafka Listener

I am getting message deserialization exception when I attempt to acknowledge the message using acknowledge(). If I remove this part of acknowledgement everything is working i.e. messages are getting consumed without any error.
Given below is the last exception in the stack trace.
Caused by: org.springframework.messaging.converter.MessageConversionException: Cannot convert from [org.purbarun.kafka.model.OrderMessage] to [org.springframework.kafka.support.Acknowledgment] for GenericMessage [payload=OrderMessage[orderRequest=OrderRequest[item=iphone, quantity=4, price=90000], messageId=238394fd-6c85-4463-a2ee-b777806d4188], headers={kafka_offset=19, kafka_consumer=org.springframework.kafka.core.DefaultKafkaConsumerFactory$ExtendedKafkaConsumer@71e72ebe, kafka_timestampType=CREATE_TIME, kafka_receivedPartitionId=0, kafka_receivedTopic=NEW_ORDER, kafka_receivedTimestamp=1722484594330, kafka_groupId=NEW_ORDER_group}]
	at org.springframework.messaging.handler.annotation.support.PayloadMethodArgumentResolver.resolveArgument(PayloadMethodArgumentResolver.java:151) ~[spring-messaging-6.1.11.jar:6.1.11]
	at org.springframework.kafka.listener.adapter.KafkaNullAwarePayloadArgumentResolver.resolveArgument(KafkaNullAwarePayloadArgumentResolver.java:48) ~[spring-kafka-3.2.2.jar:3.2.2]
	at org.springframework.messaging.handler.invocation.HandlerMethodArgumentResolverComposite.resolveArgument(HandlerMethodArgumentResolverComposite.java:118) ~[spring-messaging-6.1.11.jar:6.1.11]
	at org.springframework.messaging.handler.invocation.InvocableHandlerMethod.getMethodArgumentValues(InvocableHandlerMethod.java:147) ~[spring-messaging-6.1.11.jar:6.1.11]
	at org.springframework.messaging.handler.invocation.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:115) ~[spring-messaging-6.1.11.jar:6.1.11]
	at org.springframework.kafka.listener.adapter.HandlerAdapter.invoke(HandlerAdapter.java:70) ~[spring-kafka-3.2.2.jar:3.2.2]
	at org.springframework.kafka.listener.adapter.MessagingMessageListenerAdapter.invokeHandler(MessagingMessageListenerAdapter.java:420) ~[spring-kafka-3.2.2.jar:3.2.2]
	... 16 common frames omitted

Below is my Java based configuration where I have configured the listener and all that stuff:
@Bean
ConsumerFactory<String, OrderMessage> consumerFactory() {

// Creating a map of string-object type
Map<String, Object> config = new HashMap<>();

// Adding the Configuration
config.put(ConsumerConfig.BOOTSTRAP_SERVERS_CONFIG, "<IP_ADDRESS>:9092");
config.put(ConsumerConfig.GROUP_ID_CONFIG, "NEW_ORDER_group");
config.put(ConsumerConfig.KEY_DESERIALIZER_CLASS_CONFIG, StringDeserializer.class);
config.put(ConsumerConfig.VALUE_DESERIALIZER_CLASS_CONFIG, JsonDeserializer.class);

// Returning message in JSON format
return new DefaultKafkaConsumerFactory<>(config, new StringDeserializer(),
		new JsonDeserializer<>(OrderMessage.class));
}

// Creating a Listener
@Bean
ConcurrentKafkaListenerContainerFactory<String, OrderMessage> orderListener() {
ConcurrentKafkaListenerContainerFactory<String, OrderMessage> factory = new ConcurrentKafkaListenerContainerFactory<>();
factory.setConsumerFactory(consumerFactory());
return factory;
}

I have tried JsonDeserializer of type GenericMessage<OrderMessage> but configuration seems to be not correct as per the requirement.
Can anyone help to fix the same.
I have referred the code from https://github.com/spring-tips/kafka/blob/4d1d09caed751f94419b3229a3a65bef9a57ec0b/producer/src/main/java/com/example/analytics/ProducerApplication.java#L71
My code for producer and consumer is present in the given link:
https://github.com/purbarunc/Spring-Boot-Kafka
There is no reproduction steps as such. Just need to create the containers using docker compose and once producer and consumer app is up use the below curl to publish message to the Kafka Topic.
curl --request POST \
  --url http://localhost:8080/order \
  --header 'Content-Type: application/json' \
  --header 'User-Agent: insomnia/8.6.1' \
  --cookie JSESSIONID=14321649AD00C61688D54D493B5F2E10 \
  --data '{
	"item": "iphone",
	"quantity": 4,
	"price": 90000
}'

@purbarunc Thanks for the report. We will triage the issue soon and get back to you.

The Acknowledgment argument makes sense (and resolved respectively) only if ContainerProperties.AckMode is MANUAL or MANUAL_IMMEDIATE.
I don't see anywhere in your configuration such an option applied.
See more info in docs:
https://docs.spring.io/spring-kafka/reference/kafka/receiving-messages/listener-annotation.html#manual-acknowledgment
https://docs.spring.io/spring-kafka/reference/kafka/receiving-messages/message-listener-container.html#committing-offsets
The issue has nothing to do with deserialziation. Just because the MessageListener is not an AcknowledgingMessageListener, there is no way to resolve this Acknowledgment argument from some other place, so it falls back to the mentioned PayloadMethodArgumentResolver.
You see, the mentioned project does configure respective property before using this feature: https://github.com/spring-tips/kafka/blob/main/producer/src/main/resources/application.properties#L3
Perhaps we can improve the logic somehow to indicate such an illegal state and reject such a configuration when no manual ack mode is configured.

@artembilan Is this the only change that is needed https://github.com/purbarunc/Spring-Boot-Kafka/commit/e0ef2743de22a4b8e1dee2c92e49ede704aa9181 or there should also be some change in Java Configuration since I am still getting MessageConversionException even after adding the property. Please let me know if any more changes are needed as from the docs it seems this is the only missing piece.

That change would make sense if you rely on the Spring Boot auto-configuration, but apparently you create ConcurrentKafkaListenerContainerFactory manually, so those properties won't have any effect on your application.
Therefore you need to do like this:
factory.getContainerProperties().setAckMode(AckMode.MANUAL);

Not sure, though, why would one use Spring Boot, but still creates all the beans manually.
Your ConsumerFactory also does not look like require any manual creation.
Please, also take a look closer to that stack trace. It has a message like this:
No Acknowledgment available as an argument, the listener container must have a MANUAL AckMode to populate the Acknowledgment.

@artembilan the issue solved by adding this factory.getContainerProperties().setAckMode(AckMode.MANUAL);
But I agree with you that I am not using the power of Spring Boot to any extent and hence I tried eliminating all the Java Config code https://github.com/purbarunc/Spring-Boot-Kafka/commit/f2b5222be23d9ced8e51feafe38dd01e2a2c723a I see the below same error over again:
Caused by: org.springframework.messaging.converter.MessageConversionException: Cannot convert from [java.lang.String] to [org.purbarun.kafka.model.OrderMessage] for GenericMessage [payload={"orderRequest":{"item":"iphone","quantity":4,"price":90000},"messageId":"5fd21348-d6a4-4788-8c2e-b635162fed7a"}, headers={kafka_offset=24, kafka_consumer=org.springframework.kafka.core.DefaultKafkaConsumerFactory$ExtendedKafkaConsumer@57b346f2, kafka_timestampType=CREATE_TIME, kafka_receivedPartitionId=0, kafka_receivedTopic=NEW_ORDER, kafka_receivedTimestamp=1722527413774, kafka_acknowledgment=Acknowledgment for NEW_ORDER-0@24, kafka_groupId=NEW_ORDER_group}]
even after adding the below property:
spring.kafka.consumer.value-deserializer=org.springframework.kafka.support.serializer.JsonDeserializer
Do you have any solution for the same.

I'm not sure what for the same phrase means, but I hear it a lot from the community.
Would you mind to re-phrase it some how else, so I would get a gist of its meaning 😄
Even if exception is the same but the reason is slightly different:
Cannot convert from [org.purbarun.kafka.model.OrderMessage] to [org.springframework.kafka.support.Acknowledgment]

from original one in opposed to your new one:
Cannot convert from [java.lang.String] to [org.purbarun.kafka.model.OrderMessage]

Looks like that spring.kafka.consumer.value-deserializer does not have an effect somehow and default StringDeserializer one is in action.
Or... it ignores all the type info and just returns String for you.
Try to add this property then spring.kafka.consumer.properties[spring.json.use.type.headers]=false.
This way the target type to convert JSON into is going to be inferred from your @KafkaListener method parameters.

@artembilan for the same here was the above mentioned error instead of repeating the same thing over again just like a address/tag  😄
But do you mean this spring.kafka.producer.properties.spring.json.add.type.headers=false ?? Even this doesnt seem to be working neither spring.kafka.consumer.properties[spring.json.use.type.headers]=false
https://github.com/purbarunc/Spring-Boot-Kafka/commit/32051d6a56251f9576229f8544ac00981454475d

Right, but for the same is not a correct English phrase in this context. It feels like not finished sentence. Something else has to go after same.
That's why I'm always confused what does that mean.
We can ask @sobychacko to judge us, but in my opinionon the matter is the right choice for this kind of situation.
I cannot play with your application right now, but I thin this is what you need over there:
spring.kafka.consumer.value-deserializer=org.springframework.kafka.support.serializer.JsonDeserializer
spring.kafka.consumer.properties[spring.json.use.type.headers]=false

See more info in docs: https://docs.spring.io/spring-boot/reference/messaging/kafka.html#messaging.kafka.additional-properties
Not sure why you have commented out a JsonDeserializer in your last commit.
Either way, this does not look like we use GitHub issues feature properly.
This is more like a support ticket discussion which is out of scope of issue purpose.
I prefer to do support on StackOverflow. GH issues are for bugs and project improvement requests.
We have already realized for this issue that we need to improve the stack trace for this MANUAL ack mode and respective docs.
Everything else sounds like issue hijacking.
Thanks for understanding!

Okay..We can probably close this thread right here.

We will still use this issue to improve the exception.

FWIW, this the correct configuration you need to run your app:
spring.kafka.listener.ack-mode=manual
spring.kafka.consumer.value-deserializer=org.springframework.kafka.support.serializer.JsonDeserializer
spring.kafka.consumer.properties[spring.json.value.default.type]=org.purbarun.kafka.model.OrderMessage
spring.kafka.consumer.properties[spring.json.trusted.packages]=org.purbarun.kafka.model


Substitute Ed25519 message signing and verification for Keccak256 checksums

Fixes #172

Codecov Report

Merging #174 into master will increase coverage by 0.02%.
The diff coverage is 49.27%.

@@            Coverage Diff             @@
##           master     #174      +/-   ##
==========================================
+ Coverage   59.56%   59.59%   +0.02%
==========================================
  Files         108      108
  Lines        5728     5712      -16
==========================================
- Hits         3412     3404       -8
+ Misses       1804     1798       -6
+ Partials      512      510       -2

Impacted Files
Coverage Δ

pkg/core/consensus/component.go
68.18% <ø> (ø)
:arrow_up:

pkg/core/consensus/eventprocessor.go
77.77% <ø> (+17.77%)
:arrow_up:

pkg/util/nativeutils/eventbus/mock.go
62.85% <0%> (ø)
:arrow_up:

pkg/core/consensus/round.go
70.16% <0%> (+2.28%)
:arrow_up:

pkg/core/consensus/reduction/testutil.go
48% <0%> (ø)
:arrow_up:

pkg/core/consensus/agreement/agreement.go
84.72% <100%> (ø)
:arrow_up:

pkg/core/chain/chain.go
55.47% <100%> (ø)
:arrow_up:

pkg/core/consensus/selection/testutil.go
70.73% <100%> (ø)
:arrow_up:

pkg/p2p/peer/processing/gossip.go
62.5% <100%> (+7.95%)
:arrow_up:

pkg/p2p/peer/handshake.go
38.46% <38.88%> (-3.01%)
:arrow_down:

... and 7 more

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 3cb3269...dd35a8a. Read the comment docs.

Both very good points, I will address them in the next few commits.


make M4 test cross platform

Update M4 test to not pass if the the M4 binary is not found. Also use os.linesep for parsing output so that it works with windows and linux line endings.
Contributor Checklist:

[x] I have created a new test or updated the unit tests to cover the new/changed functionality.
[ ] I have updated master/src/CHANGES.txt directory (and read the README.txt in that directory)
[ ] I have updated the appropriate documentation

Found this while testing https://github.com/SCons/scons/pull/3270

This one is good to go.
Regarding the appveyor fail, since I only changed the M4.py test code, the other failures must be unrelated.
As such, the expected mingw failure is there, and the docbook ones look like the vm lost connection, because it passes in the other platforms.


[SUBMISSION] Completion of Instruction Tuning

December 2024 Student Submission
Module Completed

[x] Module 1: Instruction Tuning
[ ] Module 2: Preference Alignment
[ ] Module 3: Parameter-efficient Fine-tuning
[ ] Module 4: Evaluation
[ ] Module 5: Vision-language Models
[ ] Module 6: Synthetic Datasets
[ ] Module 7: Inference
[ ] Module 8: Deployment

Changes Made
Describe what you've done in this PR:

Explored chat formats and templates in fine-tuning.
Converted datasets into ChatML format.
Conducted supervised fine-tuning for smollm2 using an astronomy dataset.
Resolved W&B API key issue during Trainer API training by disabling reporting with report_to=None.

Notebooks Added/Modified
List any notebooks you've added or modified:

[ ] Added new example in module_name/students/my_example.ipynb
[x] Modified existing notebook with additional examples
[ ] Added documentation or comments

Checklist

[x] I have read the module materials
[x] My code runs without errors
[x] I have pushed models and datasets to the huggingface hub
[x] My PR is based on the december_2024 branch

Questions or Discussion Points
Add any questions you have or points you'd like to discuss:
1.
2.
Additional Notes
Any other information that might be helpful for reviewers:

Nice work! I'll merge because I haven't heard back from you. Join the discord to Discuss:
https://discord.com/channels/879548962464493619/1313889336907010110


how does the RGB image an arrray of bytes ?

I want to add here:
https://github.com/VulcanTechnologies/HoloLensCameraStream/blob/master/HoloLensVideoCaptureExample/Assets/CamStream/Examples/Video Panel Example/Scripts/VideoPanelApp.cs#L93
a condition that says if half of the pixels is red, do something ( show a hologram):
but _latestImageBytes  is an array of bytes.. so how can I code that ?
it shouldn't be a 2-d array  (RGB)X(number of pixels) ?

If it is an array of BGRA bytes, this means it is similar to Format32bppArgb?

Yeah that's right, but the order of the bytes is BGRA rather than ARGB.

Depending on your endianess ;)


Turn on micrometer instrumentation in API

GraphQL-java has built-in support for Spring Boot micrometer metrics. We should investigate what benefit they could provide, and switch them on if it seems worthwhile.
https://github.com/graphql-java-kickstart/graphql-spring-boot#tracing-and-metrics

wont do


[bug usability] Multiple cursors bug on phone

On phone I experience the following issue, I tap to a position in the editor and sometimes the old position remains in its position

@cata0309 please report the issue to https://github.com/microsoft/monaco-editor


Slicing shall be blocked

Hi Thomas,
based on one of our latest discussions, my understanding now is that slicing shall not be supported (even in case of it's already working partially).
Therefore possibly ongoing development should be stopped.
And slicing notation inside square brackets has to cause a corresponding error message.
Reference:
https://github.com/test-fullautomation/python-jsonpreprocessor/issues/184#issuecomment-1918354577

Hi Son,
as Holger writes I decided yesterday that we don't support slicing. Maybe later we will no, but not now.
Reaons:

first we should be free of existing issues.
rare use case
much effort to stabilize (e.g. can have nested parameters, ...

So, please create an error message in case you find a slicing operator.
Thank you,
Thomas

Self test: added JPP_1350 - JPP_1364 (topic: slicing; tests commented out)

Hello Holger, Hello Thomas,
I created the commit 48eae0f0df on stabi branch.
I aslo enabled the 2 test cases JPP_1350 - JPP_1364
Thank you,
Son

Hi Son,
in one of my commits I wrote: "JPP_1350 - JPP_1364". And the meaning of this is: "from JPP_1350 to JPP_1364", and not: "JPP_1350 and JPP_1364".
All further test cases between 1650 and 1364 are still commented out - and cause errors when I activate them.
But to fix the remaining aspects is for 0.12.x.

Example:
'Expression '${listParam}[:]' cannot be evaluated. Reason: Empty or special character is detected in pair of square brackets.'
Expected: Slicing is not supported
"testParam" : {"key" : ${listParam}[:]}
still causes
Expecting ',' delimiter: line 5 column 1 (char 75)'

Hello Holger,
All blocked slicing's test cases are uncovered and tested successful.
Thank you,
Son

Hello Holger,
Could you please check error message again, I updated error message as Thomas' suggestion: https://github.com/test-fullautomation/python-jsonpreprocessor/issues/186#issuecomment-1887111574
Thank you,
Son

Hi Son,
I still get this error message with slicing proposed:
Error: 'Could not set variable '${listP}['${indexP}']' with value 'newvalue'! Reason: list indices must be integers or slices, not str'!
But "or slices" is not expected.

Hello Holger,
I updated error message in this case.
Thank you,
Son

Retest successful. Issue can be closed.

Released with RobotFramework AIO 0.12.0


Training suspends in last batch of the epoch - HDF5 selections.py issue?

Thanks for this repo. I ran the steps to download and preprocess data. It also starts training, but fails in the last batch of the first epoch. I'm using TF1.14 (not 1.15 as prescribed on the README), however I doubt that has anything to do with this error. Could this be a h5py version issue?
[UPDATE]: Before training, I set USE_KERAS_API to False, hence forcing it to pick tf.keras. Could this be the same issue referred in settings.py?
Error:
------------------------------
Fitting model with training data ...
------------------------------
Step 3, training the model started at 2020-06-16 12:51:03.365806
Train on 62930 samples, validate on 4960 samples
Epoch 1/40
62848/62930 [============================>.] - ETA: 1s - loss: 0.7630 - acc: 0.9642 - dice_coef: 0.6290 - soft_dice_coef: 0.2496
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/h5py/_hl/selections.py in select(shape, args, dsid)
     84             try:
---> 85                 int(a)
     86                 if isinstance(a, np.ndarray) and a.shape == (1,):

TypeError: int() argument must be a string, a bytes-like object or a number, not 'list'

Here's the complete error stack:
------------------------------
Fitting model with training data ...
------------------------------
Step 3, training the model started at 2020-06-16 12:51:03.365806
Train on 62930 samples, validate on 4960 samples
Epoch 1/40
62848/62930 [============================>.] - ETA: 1s - loss: 0.7630 - acc: 0.9642 - dice_coef: 0.6290 - soft_dice_coef: 0.2496
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/h5py/_hl/selections.py in select(shape, args, dsid)
     84             try:
---> 85                 int(a)
     86                 if isinstance(a, np.ndarray) and a.shape == (1,):

TypeError: int() argument must be a string, a bytes-like object or a number, not 'list'

During handling of the above exception, another exception occurred:

TypeError                                 Traceback (most recent call last)
/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/tensorflow/python/keras/engine/training_arrays.py in model_iteration(model, inputs, targets, sample_weights, batch_size, epochs, verbose, callbacks, val_inputs, val_targets, val_sample_weights, shuffle, initial_epoch, steps_per_epoch, validation_steps, validation_freq, mode, validation_in_fit, prepared_feed_values_from_dataset, steps_name, **kwargs)
    345           else:
--> 346             ins_batch = slice_arrays(ins, batch_ids)
    347         except TypeError:

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/tensorflow/python/keras/utils/generic_utils.py in slice_arrays(arrays, start, stop)
    530         start = start.tolist()
--> 531       return [None if x is None else x[start] for x in arrays]
    532     else:

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/tensorflow/python/keras/utils/generic_utils.py in <listcomp>(.0)
    530         start = start.tolist()
--> 531       return [None if x is None else x[start] for x in arrays]
    532     else:

/data/unet-intelai/2D/data.py in __getitem__(self, key)
    158         """
--> 159         data = super().__getitem__(key)
    160         self.idx += 1

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/tensorflow/python/keras/utils/io_utils.py in __getitem__(self, key)
    113     else:
--> 114       return self.data[idx]
    115

h5py/_objects.pyx in h5py._objects.with_phil.wrapper()

h5py/_objects.pyx in h5py._objects.with_phil.wrapper()

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/h5py/_hl/dataset.py in __getitem__(self, args)
    552         # Perform the dataspace selection.
--> 553         selection = sel.select(self.shape, args, dsid=self.id)
    554

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/h5py/_hl/selections.py in select(shape, args, dsid)
     89                 sel = FancySelection(shape)
---> 90                 sel[args]
     91                 return sel

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/h5py/_hl/selections.py in __getitem__(self, args)
    366                     if any(fst >= snd for fst, snd in adjacent):
--> 367                         raise TypeError("Indexing elements must be in increasing order")
    368

TypeError: Indexing elements must be in increasing order

During handling of the above exception, another exception occurred:

TypeError                                 Traceback (most recent call last)
<ipython-input-24-41921214fca5> in <module>
     23               validation_data=(imgs_validation, msks_validation),
     24               verbose=1, shuffle="batch",
---> 25               callbacks=model_callbacks)
     26
     27 print("Total time elapsed for training = {} seconds".format(time.time() - start_time))

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/tensorflow/python/keras/engine/training.py in fit(self, x, y, batch_size, epochs, verbose, callbacks, validation_split, validation_data, shuffle, class_weight, sample_weight, initial_epoch, steps_per_epoch, validation_steps, validation_freq, max_queue_size, workers, use_multiprocessing, **kwargs)
    778           validation_steps=validation_steps,
    779           validation_freq=validation_freq,
--> 780           steps_name='steps_per_epoch')
    781
    782   def evaluate(self,

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/tensorflow/python/keras/engine/training_arrays.py in model_iteration(model, inputs, targets, sample_weights, batch_size, epochs, verbose, callbacks, val_inputs, val_targets, val_sample_weights, shuffle, initial_epoch, steps_per_epoch, validation_steps, validation_freq, mode, validation_in_fit, prepared_feed_values_from_dataset, steps_name, **kwargs)
    407           validation_in_fit=True,
    408           prepared_feed_values_from_dataset=(val_iterator is not None),
--> 409           steps_name='validation_steps')
    410       if not isinstance(val_results, list):
    411         val_results = [val_results]

/scratch/sambhavj/anaconda3/envs/tf1.14/lib/python3.6/site-packages/tensorflow/python/keras/engine/training_arrays.py in model_iteration(model, inputs, targets, sample_weights, batch_size, epochs, verbose, callbacks, val_inputs, val_targets, val_sample_weights, shuffle, initial_epoch, steps_per_epoch, validation_steps, validation_freq, mode, validation_in_fit, prepared_feed_values_from_dataset, steps_name, **kwargs)
    346             ins_batch = slice_arrays(ins, batch_ids)
    347         except TypeError:
--> 348           raise TypeError('TypeError while preparing batch. '
    349                           'If using HDF5 input data, '
    350                           'pass shuffle="batch".')

TypeError: TypeError while preparing batch. If using HDF5 input data, pass shuffle="batch".

UPDATE: Switching to standalone keras (using the default setting USE_KERAS_API=True) overcomes this HDF5 issue encountered when using tf.keras.

Glad you found a solution @sjain-stanford . Closing this issue as it is resolved.


Try to migrate from version 4 to 5 - Cannot read property 'name' of undefined

Describe the bug
Cannot read property 'name' of undefined
Stack trace
TypeError: Cannot read property 'name' of undefined
at Configuration.cached (/var/www/html/test/server/node_modules/@mikro-orm/core/dist/utils/Configuration.js:182:29)
at Configuration.getMetadataProvider (/var/www/html/test/server/node_modules/@mikro-orm/core/dist/utils/Configuration.js:102:21)
at Configuration.init (/var/www/html/test/server/node_modules/@mikro-orm/core/dist/utils/Configuration.js:129:19)
at new Configuration (/var/www/html/test/server/node_modules/@mikro-orm/core/dist/utils/Configuration.js:36:14)
at new MikroORM (/var/www/html/test/server/node_modules/@mikro-orm/core/dist/MikroORM.js:17:27)
at Function.init (/var/www/html/test/server/node_modules/@mikro-orm/core/dist/MikroORM.js:38:21)
at InstanceWrapper.useFactory [as metatype] (/var/www/html/test/server/node_modules/@mikro-orm/nestjs/mikro-orm.providers.js:21:32)
at Injector.instantiateClass (/var/www/html/test/server/node_modules/@nestjs/core/injector/injector.js:304:55)
at callback (/var/www/html/test/server/node_modules/@nestjs/core/injector/injector.js:48:41)
at processTicksAndRejections (internal/process/task_queues.js:95:5)
To Reproduce
install version 5
Expected behavior
work well
Versions
"@mikro-orm/core": "^5.0.0-dev.562",
"@mikro-orm/migrations": "^5.0.0-dev.562",
"@mikro-orm/mysql": "^5.0.0-dev.562",
"@mikro-orm/nestjs": "^4.3.1",
"@mikro-orm/reflection": "^5.0.0-dev.562",
"@mikro-orm/sql-highlighter": "^1.0.1",
node - v14.17.6

    cached(cls, ...args) {

        console.log('>>    ', cls)
        if (!this.cache[cls.name]) {
            const Class = cls;
            this.cache[cls.name] = new Class(...args);
        }
        return this.cache[cls.name];
    }

output

[class UnderscoreNamingStrategy extends AbstractNamingStrategy]
undefined

Please join the slack channel or start using discussions here on GH, you keep creating low effort issues, full of pseudocode, that are more like questions, without proper context.
Like sorry, but to reproduce I should install v5? Are you kidding me?

@B4nan  Found the problem :) :) :). It's not you It's my bad :)!
Was that in config file i commented line:
metadataProvider: TsMorphMetadataProvider,
but in app.module file remains:
 metadataProvider: configService.get('app.db.metadataProvider'),
But such error Cannot read property 'name' of undefined is not very usefully.

So you get this error when configService.get('app.db.metadataProvider') gives you undefined, right?
So basically when doing:
MikroORM.init({
  metadataProvider: undefined,
});

@B4nan yes

@B4nan the weak part of mikro-orm is its error messages. other are nice

This is not sequelize, it was never the goal to mimic their API 🤷 If something, the goal was to mimic doctrine/hibernate.

Transaction in sequelize is also passed with findOptions.

You can pass the transaction handle via FindOptions here too, its the ctx?: Transaction property. But you should almost never need to use this, as the transaction context is bared in the EM instance.

But here need to fork, call always flush.

In general you should not need to fork manually, that should happen in some middleware. See https://mikro-orm.io/docs/identity-map#-requestcontext-helper-for-di-containers
And I do care about error messages, a lot is actually deeply validated, including relationship definitions and populate hints (and in v5 many things are even validated on compile time). You are just breaking things in a way that literally noone tried before, like here - providing explicit undefined value for optional things.

@B4nan oooo that I can, I will be very helpfully in that aspect :1st_place_medal :).
I am recently moved to node and I am in process of learning and moving some of my apps from php to node.

In general you should not need to fork manually, that should happen in some middleware. See https://mikro-orm.io/docs/identity-map#-requestcontext-helper-for-di-containers

@B4nan That was first error that I encountered with mikro-orm, when I save errors to BD but It say me that I can't flush in hooks. Resolve by fork.

That error is also triggered if you try to work with global EM instead of having forks for each request. More about this is in the docs page I already gave you. Note that this particular issue is also part of the FAQ page: https://mikro-orm.io/docs/faq#you-cannot-call-emflush-from-inside-lifecycle-hook-handlers
You should not fork inside your handlers to get around this, you should already have a fresh for created in the middleware.
And lastly, in v5 it is now allowed to flush single EM in parallel via Promise.all (it won't really happen in parallel, but it won't fail with this error anymore unless you actually do flush from hooks - that is still disallowed as it would cause infinite loops).


[IDE] Don't widen source range for AccessorDecl

Syntactically, Attributes for AccessorDecl are not part of AccessorDecl,
but part of PatternBindingDecl. When the selected range is the brace for
implicit getter, it should be considered as selecting getter decl
regardless of the attributes.
Conversely, we should widen source range for PatternBindingDecl by
looking into declared VarDecls because, in AST, attributes on
PatternBindingDecl are attached to VarDecls.
rdar://problem/41073182

@swift-ci Please smoke test

Added a test case.
@swift-ci Please smoke test

@swift-ci Please smoke test

Ah, what about attributes that are on the accessors?
var foo: Int {
  @inlinable get { return 0 }
}

Ah, I will look into it. Thanks!


Know More modals for on-ramps

Issue replicated on the following account details

Swan Bitcoin
Wyre Account
Ramp Account

https://xd.adobe.com/view/e74a06be-c6d2-4ee1-a8aa-dc3c61d017f9-b219/grid
The UX is done with the content.
Specs Link: https://xd.adobe.com/view/3ebba4c6-dfc4-4062-baa4-9f1fde256bc5-6be8/

-Verified this issue on Dev app v1.7.0 (292)


add unit tests for ResolverUtil.

add unit tests for ResolverUtil.

@peterchenhdu Thanks! I've merged your PR at now.


customVerificationCallback not fired.

It seems like the customVerificationCallback does not fire what so ever in the constructor: NIOSSLServerHandler(context: , customVerificationCallback: ).
I have tried setting the TLSConfiguration to a bunch of different states/configs. But no combination seem to trigger the custom verification callback.
Is this a bug, or a misconfiguration on my part?
Best regards.
Sample code:

      func customVerf(certs: [NIOSSLCertificate], result: EventLoopPromise<NIOSSLVerificationResult>) {
        print("Hello from customVerf!") // this should be printed but it does not for some reason...
        return result.succeed(.certificateVerified)
      }

       ......

      let (cert, key) = try generateSelfSignedTLSIdentity()
      var tlsConf = TLSConfiguration.makeServerConfiguration(certificateChain: [.certificate(cert)], privateKey: .privateKey(key))
      tlsConf.trustRoots = NIOSSLTrustRoots.certificates([cert])
      tlsConf.certificateVerification = .fullVerification
      let sslContext = try NIOSSLContext(configuration: tlsConf)

      let bootstrap = NIOTSListenerBootstrap(group: group)
        .serverChannelOption(ChannelOptions.socketOption(.so_reuseaddr), value: 1)
        .childChannelInitializer { channel in
          channel.pipeline.addHandler(NIOSSLServerHandler(context: sslContext, customVerificationCallback: self.customVerf), position: .first)
            .flatMap {
              channel.pipeline.addHandler(MyCustomHandler())
            }
        }
      let channel = try bootstrap
        .bind(host: host, port: port)
        .wait()

      try channel.closeFuture.wait()

Thanks for filing this! Is the client sending certs? If the client sends no certificates at all, the server will reject the handshake entirely and never get to the custom verification callback.

For me locally, if I use openssl s_client to connect without passing -cert and -key, I see an error and the callback isn't called. If I do pass those two arguments, I see the callback invoked appropriately.


iOS implementation requires Android embedding v2

Trying to run on an iOS 14 device, I receive the following message:
The plugin native_admob_flutter requires your app to be migrated to the Android embedding v2. Follow the steps on https://flutter.dev/go/android-project-migration and re-run this command. Exited (1)
If this package supports both Android and iOS, why do I need to include Android embedding support?
Is this something that will change as the package matures?

iOS is NOT supported: https://github.com/bdlukaa/native_admob_flutter/wiki/Platform-setup#ios

iOS is currently not supported (I don't have an Apple environment :/).

But it's weird that you're trying to run on iOS and it says something about android. But either way, it's necessary to migrate to embeeding v2 to use this plugin on Android.

Ah okay, thanks for the clarification.
I assumed iOS was supported as it states so on the pub.dev page, I'd recommend changing that :)

Removed the iOS label from pub and added the supported platforms on readme :) (v0.9.1+1)

iOS is now supported! It supports Banner, Interstitial, Banner and App Open Ads. v1.0.0

That's awesome to hear!  I'll let you know if I have any issues. :)


Clean inst/java directory before building subprojects

Closes #4
This should prevent problems with old jars left in this directory after
the version of the dependency in a subproject is changed.

LGTM.


badarg for brod_topic_subscriber:start_link

While testing the Quick Demo, I'm stuck at the 12th command. Please help me sort out this issue.

Zookeeper, Kafka running; with the latter running at localhost:9092.

brod-test topic exists.

Producer part of brod is working fine (I'm able to consume the messages through the native Kafka consumer).

This consumer part of brod isn't working fine for me.

brod_topic_subscriber:start_link(client1, Topic, Partitions=[Partition],
_ConsumerConfig=[{begin_offset, earliest}],
_CommittdOffsets=[], SubscriberCallbackFun,
_CallbackState=self()).

** exception exit: badarg
in function  apply/3
called as apply(#Fun<erl_eval.18.99386804>,init,[])
in call from brod_topic_subscriber:init/1 (src/brod_topic_subscriber.erl, line 178)
in call from gen_server:init_it/2 (gen_server.erl, line 365)
in call from gen_server:init_it/6 (gen_server.erl, line 333)
in call from proc_lib:init_p_do_apply/3 (proc_lib.erl, line 247)
I am sure that I haven't done any modifications to the original code. Can this be some syntax error? Please help me sort this issue out.

Sorry, the demo code is a bit outdated, please add a ‘message‘ or ‘ message_set’ atom before the SubscriberCallbackFun in the arg list.
Will fix it.

Thanks, I'm now able to consume messages through brod.
Thanks again for the prompt support.


Stats monitoring

I'm going to close this pull-request. It contains conflicts, but I believe this functionality already exists? See
# Metrics configuration.
[metrics]

  # Metrics stored in Prometheus.
  #
  # These metrics expose information about the state of the LoRa Gateway Bridge
  # instance like number of messages processed, number of function calls, etc.
  [metrics.prometheus]
  # Expose Prometheus metrics endpoint.
  endpoint_enabled=false

  # The ip:port to bind the Prometheus metrics server to for serving the
  # metrics endpoint.
  bind=""


chore: cast message to string if not instanceof Jsonable, Arrayable

Goal

Design

Changeset

Testing

HI @dammy001 ,
Thanks for the PR, would you mind giving us a little bit of an explanation as to why you feel it is necessary to make this change?

Closing as we haven't had any response to the question above.


Upgrade minify

minify is currently on version 9. When I upgraded it, it changes the syntax of some of the arrays and objects.
This should be fixable, as I'm sure minify has simply added a new configuration option.

Fixed in https://github.com/markwylde/workerbox/commit/a3795aefdfc060f0f6ee2779ec362ee55713e063


Design - ui release/upgrade  flow

https://www.notion.so/digma1/UI-release-upgrade-flow-149e2a56b6418021b2b2ec3eb3924cc5


vscode.dev source code / self hosted version

Will you be releasing the source code for vscode.dev?
A self hosted version would be awesome.

See also #135856 and #135733


Add default link CSS

Fix #56 by adding default color for all links. I decided to go with the same color, that links have at elixirschool.com.

Thank you @gavlak!


Added ability to remove volume to host mapping

Added deletion host mapping

Related PRs:
https://github.com/ManageIQ/manageiq-api/pull/1075
https://github.com/ManageIQ/manageiq-ui-classic/pull/7862
https://github.com/ManageIQ/manageiq-providers-autosde/pull/85

@miq-bot add_label morphy/yes?


Failure on Mac M1 ARM

Unfortunately I get a panic like this:
| Cloningfatal error: concurrent map writes

goroutine 86 [running]:
runtime.throw(0x1043f78e4, 0x15)
	/opt/hostedtoolcache/go/1.16.10/x64/src/runtime/panic.go:1117 +0x54 fp=0x140002b3d40 sp=0x140002b3d10 pc=0x104239734
runtime.mapassign_faststr(0x10447d160, 0x140000b2000, 0x140000146d8, 0x18, 0x0)
	/opt/hostedtoolcache/go/1.16.10/x64/src/runtime/map_faststr.go:211 +0x3c0 fp=0x140002b3db0 sp=0x140002b3d40 pc=0x104219c70
github.com/alajmo/mani/core/dao.CloneRepo(0x1400001a060, 0x21, 0x140000146d8, 0x18, 0x140001c6800, 0x38, 0x0, 0x0, 0x14000198940, 0x40, ...)
	/home/runner/work/mani/mani/core/dao/project.go:194 +0x4b0 fp=0x140002b3f20 sp=0x140002b3db0 pc=0x1043d9fd0
runtime.goexit()
	/opt/hostedtoolcache/go/1.16.10/x64/src/runtime/asm_arm64.s:1130 +0x4 fp=0x140002b3f20 sp=0x140002b3f20 pc=0x10426bd14
created by github.com/alajmo/mani/core/dao.Config.CloneRepos
	/home/runner/work/mani/mani/core/dao/project.go:111 +0x808

goroutine 1 [semacquire]:
sync.runtime_Semacquire(0x1400008e258)
	/opt/hostedtoolcache/go/1.16.10/x64/src/runtime/sema.go:56 +0x38
sync.(*WaitGroup).Wait(0x1400008e250)
	/opt/hostedtoolcache/go/1.16.10/x64/src/sync/waitgroup.go:130 +0x74
github.com/alajmo/mani/core/dao.Config.CloneRepos(0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x140001c3590, 0x1, 0x1, 0x140001da000, ...)
	/home/runner/work/mani/mani/core/dao/project.go:122 +0x190
github.com/alajmo/mani/core/dao.Config.SyncProjects(0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x140001c3590, 0x1, 0x1, 0x140001da000, ...)
	/home/runner/work/mani/mani/core/dao/config.go:566 +0x214
github.com/alajmo/mani/cmd.runSync(0x1046194a0, 0x1)
	/home/runner/work/mani/mani/cmd/sync.go:36 +0xdc

while running mani sync on a Mac M1 ARM based machine
Installed via brew.
Additional context
Mani version:
$ mani version
Version:    0.10.0
Commit:     af8f8a0e98f0a3eed64ed616357a482dd6eb7fd2
Date:       2021-11-10T10:12:45Z

$ file /opt/homebrew/bin/mani
/opt/homebrew/bin/mani: Mach-O 64-bit executable arm64

If you need more details please ping me... I appreciate to. help...

Thanks for bug report, I think I found the issue and was able to replicate the bug, but in the meantime, you could try mani sync --parallel=false.

I released a new version that should hopefully resolve the concurrent map write issue, please let me know if the issue persists.
One note though, if you're running mani sync, by default it will clone the repositories in parallel and lock the terminal screen so if you need to enter credentials manually, it's better to run with mani sync --parallel=false since it won't lock the screen.

I can confirm that the above panic does not occurs anymore.


Re-enable CUDA tests

Codecov Report

Merging #482 (af7d22e) into main (640d71c) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #482   +/-   ##
=======================================
  Coverage   94.45%   94.45%
=======================================
  Files          65       65
  Lines        8653     8653
=======================================
  Hits         8173     8173
  Misses        480      480

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


Create REST Agent

Method signature:

Method to parse output spec, which will format the outdata
create a component called Paths and map the services to path

Reference: http://petstore.swagger.io/

done


include neuro expression datasets

Allen brain institute (publicly available and downloadable), who we would need to convince to submit to arrayxpress/geo

brainiac (John hardy) who we would have to convince to pre-release RNA seq data

Closing as already being addressed by @MichaelaEBI and @AsierGonzalez as part of data backlog list.


Increase the amount of mods in a mod channel.

I notice that 6 is a rather small number of mods. Because of this, people require many mod channels for the same thing. To shorten on this, maybe add at least 2 or 3 more mod slots per mod channel? This will need a lot of trickery to work.

Idea further moved onto #116


Kafka and mqtt examples?

Look through the repo, but couldn't find any reference for how to use kafka and mqtt with the service. When trying to run with the following configurations (please excuse the Python scaffolding, but one should get the idea):
{
    "source": {"uri": self.source, "type": "uri"},
    "destination": {
        "type": "kafka",
        "host": f"{protocol}://{KAFKA_HOSTNAME}",
        "topic": f"/VAS/{self.uid}",
    },
}

Where protocol is either http or kafka, I get the following error as a log in the video-analytics-serving:
video-analytics-service    | %4|1593223459.081|BROKER|rdkafka#producer-1| [thrd:app]: Broker name "kafka://kafka:9092" parse error: unsupported protocol "KAFKA"

or
video-analytics-service %4|1593222222.849|BROKER|rdkafka#producer-1| [thrd:app]: Broker name "http://kafka:9092" parse error: unsupported protocol "HTTP"

Figured out my own issue... I need some sleep. In my Kafka settings inside my docker-compose.yml I have the following environment variable:
KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://kafka:9092

Therefore, simple setting the protocol to PLAINTEXT fixed my issue.