Ability to pass client object in openai_embeddings.py

Thank you @archit0 !

Hi @zainhoda when will you be creating the next release?

@archit0 if you need this released soon, I can release it today. Otherwise I was planning on combining this with the ollama integration and other changes.

If you can create a release today, it will be helpful. Thanks

Sure. I can do that. Where are you storing the generated embeddings btw?
On Sat, Jan 27, 2024 at 9:09 AM Archit Dwivedi @.***>
wrote:

If you can create a release today, it will be helpful. Thanks
—
Reply to this email directly, view it on GitHub
https://github.com/vanna-ai/vanna/pull/191#issuecomment-1913168778, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ABWQVKSPNTJN6TNNKKGNMFTYQUDAVAVCNFSM6AAAAABCMV5LZ2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMJTGE3DQNZXHA
.
You are receiving this because you were mentioned.Message ID:
@.***>

Im currently storing the embeddings in postgres(pgvector)

That’s great! It’s been on our backlog for a while. Would you be able to
give the code snippet that we could use as a starting point for a pgvector
implementation
On Sat, Jan 27, 2024 at 9:42 AM Archit Dwivedi @.***>
wrote:

Im currently storing the embeddings in postgres(pgvector)
—
Reply to this email directly, view it on GitHub
https://github.com/vanna-ai/vanna/pull/191#issuecomment-1913176151, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ABWQVKTRWGWJ5LVLAMDLUQTYQUG47AVCNFSM6AAAAABCMV5LZ2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMJTGE3TMMJVGE
.
You are receiving this because you were mentioned.Message ID:
@.***>

For other projects I was using pgvector pacakage directly, im still building pgvector class for vanna ai, i will raise a pr once in 2 days once i build and test that feature

Awesome!
On Sun, Jan 28, 2024 at 4:54 AM Archit Dwivedi @.***>
wrote:

For other projects I was using pgvector pacakage directly, im still
building pgvector class for vanna ai, i will raise a pr once in 2 days once
i build and test that feature
—
Reply to this email directly, view it on GitHub
https://github.com/vanna-ai/vanna/pull/191#issuecomment-1913538177, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ABWQVKTISCR4CLC56TFDIJTYQYN5RAVCNFSM6AAAAABCMV5LZ2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMJTGUZTQMJXG4
.
You are receiving this because you were mentioned.Message ID:
@.***>


Occasional jitter

Often ALVR appears jittery when moving the head horizontally. It's probably not the video stream because the oculus universal menu also appears jittery (with ALVR stream in the background). The same thing happens to a lesser degree with VD.
This could be caused by unoptimized code. One of the causes could be the webview that gets rendered constantly even when not shown.
This could also be caused by uneven video encoding/decoding times across frames. A workaround is implementing the latency minimization/regulation system. This system increases (frame queue) latency until the number of missed deadlines per hour (that cause jitter) falls below a certain threshold.

The WebView itself only renders when it needs to due to a change on the page, not each frame. Only its SurfaceTexture's updateTexImage() gets called each frame, which should not cause jitter like that.
What I found out so far is that each time I experience the jitter, I can pair it to an error log from OutputFrameQueue about the FrameQueue being full (OutputFrameQueue.java:71), which points to the uneven decoding times you've described.

Possibly also be closed

This is not fixed completely. The "staircase latency" is on the path to be fixed soon, as well as microjitter caused by tracking poll on the SteamVR side.


Doc about skipping some integration tests with '-check.f ConsulCatalogSuite'

Corrected ;-) 👍

Other than the comment, LGTM :wink:
(and needs a rebase, sorry :sweat:)

Oops, sorry, i forgot to rebase.
It's alright ;-)

LGTM! Thanks @samber :+1:


⚠ Turnos 24x7 has degraded performance

In 642a1aa, Turnos 24x7 (https://reservas-dev.alternativasinteligentes.com/) experienced degraded performance:

HTTP code: 200
Response time: 850 ms

Resolved: Turnos 24x7 performance has improved in af6e9ad.


Enable Documentation Preview

Description:
Enable Documentation Preview that is disabled with https://github.com/ballerina-platform/plugin-vscode/pull/100.
Suggested Labels:

Suggested Assignees:

Affected Product Version:
OS, DB, other environment details and versions:
Steps to reproduce:
Related Issues:

Holds the feature until we can reuse the components in the doc react app.

Removed the Doc preview https://github.com/ballerina-platform/plugin-vscode/issues/124

Removed the Doc preview https://github.com/ballerina-platform/plugin-vscode/issues/124


fix(telemetry): remove configID from mixer self-monitoring metrics

This PR removes the config identifier dimensions from Mixer's self-monitoring metrics and introduces an additional metric for tracking dispatches by template variety.
There have been several requests to remove the configID dimension from the self-monitoring metrics for Mixer, including https://github.com/istio/istio/issues/9077. For the 1.1 release, during the discussion around turning istio-policy off-by-default, we discovered that we had no way of monitoring the different modes of dispatch within Mixer.
Most of the content on this PR is turning the counter metrics into gauges (and then adjusting the code to enable setting the measurement for each gauge in a single place).
A side benefit of this PR is that now we get values for metrics in situations that we would not before (zero errors, for example).
Example snippet of the /metrics with this PR:
# HELP mixer_config_adapter_info_config_errors_total The number of errors encountered during processing of the adapter info configuration.
# TYPE mixer_config_adapter_info_config_errors_total gauge
mixer_config_adapter_info_config_errors_total 0
# HELP mixer_config_adapter_info_configs_total The number of known adapters in the current config.
# TYPE mixer_config_adapter_info_configs_total gauge
mixer_config_adapter_info_configs_total 0
# HELP mixer_config_attributes_total The number of known attributes in the current config.
# TYPE mixer_config_attributes_total gauge
mixer_config_attributes_total 112
# HELP mixer_config_handler_configs_total The number of known handlers in the current config.
# TYPE mixer_config_handler_configs_total gauge
mixer_config_handler_configs_total 6
# HELP mixer_config_handler_validation_error_total The number of errors encountered because handler validation returned error.
# TYPE mixer_config_handler_validation_error_total gauge
mixer_config_handler_validation_error_total 0
# HELP mixer_config_instance_config_errors_total The number of errors encountered during processing of the instance configuration.
# TYPE mixer_config_instance_config_errors_total gauge
mixer_config_instance_config_errors_total 0
# HELP mixer_config_instance_configs_total The number of known instances in the current config.
# TYPE mixer_config_instance_configs_total gauge
mixer_config_instance_configs_total 14
# HELP mixer_config_rule_config_errors_total The number of errors encountered during processing of the rule configuration.
# TYPE mixer_config_rule_config_errors_total gauge
mixer_config_rule_config_errors_total 0
# HELP mixer_config_rule_config_match_error_total The number of rule conditions that was not parseable.
# TYPE mixer_config_rule_config_match_error_total gauge
mixer_config_rule_config_match_error_total 0
# HELP mixer_config_rule_configs_total The number of known rules in the current config.
# TYPE mixer_config_rule_configs_total gauge
mixer_config_rule_configs_total 12
# HELP mixer_config_template_config_errors_total The number of errors encountered during processing of the template configuration.
# TYPE mixer_config_template_config_errors_total gauge
mixer_config_template_config_errors_total 0
# HELP mixer_config_template_configs_total The number of known templates in the current config.
# TYPE mixer_config_template_configs_total gauge
mixer_config_template_configs_total 2
# HELP mixer_config_unsatisfied_action_handler_total The number of actions that failed due to handlers being unavailable.
# TYPE mixer_config_unsatisfied_action_handler_total gauge
mixer_config_unsatisfied_action_handler_total 1
# HELP mixer_dispatcher_destinations_per_variety_total Number of Mixer adapter destinations by template variety type
# TYPE mixer_dispatcher_destinations_per_variety_total gauge
mixer_dispatcher_destinations_per_variety_total{variety="TEMPLATE_VARIETY_CHECK"} 2
mixer_dispatcher_destinations_per_variety_total{variety="TEMPLATE_VARIETY_QUOTA"} 1
mixer_dispatcher_destinations_per_variety_total{variety="TEMPLATE_VARIETY_REPORT"} 2
# HELP mixer_handler_closed_handlers_total The number of handlers that were closed during config transition.
# TYPE mixer_handler_closed_handlers_total gauge
mixer_handler_closed_handlers_total 0
# HELP mixer_handler_daemons_total The current number of active daemon routines in a given adapter environment.
# TYPE mixer_handler_daemons_total gauge
mixer_handler_daemons_total{handler="memquota.istio-system"} 1
mixer_handler_daemons_total{handler="prometheus.istio-system"} 1
# HELP mixer_handler_handler_build_failures_total The number of handlers that failed creation during config transition.
# TYPE mixer_handler_handler_build_failures_total gauge
mixer_handler_handler_build_failures_total 1
# HELP mixer_handler_handler_close_failures_total The number of errors encountered while closing handlers during config transition.
# TYPE mixer_handler_handler_close_failures_total gauge
mixer_handler_handler_close_failures_total 0
# HELP mixer_handler_new_handlers_total The number of handlers that were newly created during config transition.
# TYPE mixer_handler_new_handlers_total gauge
mixer_handler_new_handlers_total 5
# HELP mixer_handler_reused_handlers_total The number of handlers that were re-used during config transition.
# TYPE mixer_handler_reused_handlers_total gauge
mixer_handler_reused_handlers_total 0

This is part of code mauve as it improves system debugability and addresses a known issue in monitoring.
Fixes: https://github.com/istio/istio/issues/9077

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: douglas-reid
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

mixer/OWNERS [douglas-reid]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@douglas-reid: The following test failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-pilot-multicluster-e2e.sh
11d5bc18c21daf2627a3d1d2543e2d079dadc0af
link
/test istio-pilot-multicluster-e2e

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@douglas-reid: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-pilot-multicluster-e2e.sh
11d5bc18c21daf2627a3d1d2543e2d079dadc0af
link
/test istio-pilot-multicluster-e2e

prow/istio-integ-k8s-tests.sh
11d5bc18c21daf2627a3d1d2543e2d079dadc0af
link
/test istio-integ-k8s-tests

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@douglas-reid: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-integ-k8s-tests.sh
11d5bc18c21daf2627a3d1d2543e2d079dadc0af
link
/test istio-integ-k8s-tests

prow/istio-pilot-multicluster-e2e.sh
37d61b0c02dd73e5a7adc88ee1ef52a48f125269
link
/test istio-pilot-multicluster-e2e

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@douglas-reid: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-pilot-multicluster-e2e.sh
37d61b0c02dd73e5a7adc88ee1ef52a48f125269
link
/test istio-pilot-multicluster-e2e

prow/istio-integ-k8s-tests.sh
37d61b0c02dd73e5a7adc88ee1ef52a48f125269
link
/test istio-integ-k8s-tests

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

Friendly ping on review.

@douglas-reid: PR needs rebase.

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@douglas-reid: The following test failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-integ-k8s-tests.sh
b311051e6d3da740a0b97886b6ff0ebc06a5685b
link
/test istio-integ-k8s-tests

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

Friendly ping on review.

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: douglas-reid, kyessenov
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

mixer/OWNERS [douglas-reid,kyessenov]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment


Streetview broken

This only happens since today. The colors are inverted and it shows "For development purposes only" in the middle of the screen.

Hey please read the limitation section on the home page.

Currently I set quotas per day so the cost to run this game can't get too high. If the map doesn't load, it means the quotas has been exceeded on the day. It will reset at midnight Pacific Time. Sorry for inconvenience. This game is open source so you can build your own game server and play this game unlimitedly.


Reusing pool delivers error "The requested Node .... already exists in partition tenant1

Environment

FAST RPM Version: 1.24
BIG-IP Version: <IP_ADDRESS>

Summary
One deploying a simple-http-app using the simple-http template I define a pool in tenant1.
When deploying another application using template HTTP Application Template in the same tenant 1 and selecting the already existing Pool created at the simple-http template deployment, the deployment of the HTTP Application template fails with the following error "01020066:3: The requested Node (/tenant1/a.b.c.d) already exists in partition tenant1."
Steps To Reproduce

Deploy simple-http template in tenant1
Deploy HTTP Application Template in tenant1 and select existing Pool (created from the previous pool)
Deployment of HTTP Application fails.

Expected Behavior
I would expect that if I am allowed to select an existing pool from the drop down menu and the pool is within the same tenant, that the template deployment should succeed.
Actual Behavior
Selecting an existing pool and deploying the template it fails with this error: 01020066:3: The requested Node (/tenant1/a.b.c.d) already exists in partition tenant1.

The simple_http template creates a new pool, using the app name, for every app deployed, which can be seen in the schema:
{
"class": "ADC",
"schemaVersion": "3.0.0",
"{{tenant_name}}": {
"class": "Tenant",
"{{application_name}}": {
"class": "Application",
"template": "http",
"serviceMain": {
"class": "Service_HTTP",
"virtualPort": {{virtual_port::integer}},
"virtualAddresses": ["{{virtual_address}}"],
"pool": "{{application_name}}_web_pool"
},
"{{application_name}}_web_pool": {
"class": "Pool",
"monitors": [
"http"
],
"members": [
{
"servicePort": {{server_port::integer}},
"serverAddresses": {{server_addresses::array}}
}
]
}
}
}
}
Did you customize this template so that you can select an existing pool?

I was able to deploy first the simple-http template, that creates a pool, and then deploy http-application-template to the same tenant and select the existing pool. Both deployed without errors.
Maybe there is something else going on with your templates?


Specify a java_package for identifier.proto [phab:D1974]

Created by zarko at 2017-10-09 18:14:45:

shahms accepted this revision at 2017-10-09 18:20:46

zarko closed via commit b12c11b7c99e479eab4b08373a86708fcb84b155 at 2017-10-09 18:23:45


fix controller QPS issue

Fixing the issue that replica-set controller was set to 8000. It should be caused by shared config which was multiplied by 20 by the tenant controller and namespace controller.

/lgtm

/approve


build: Prepare and generate typetests on next branch

Commands run:
npm run typetests:prepare -- -b next -v
npm i
npm run typetests:gen -- -b next -v

This sets the baseline version to ^previousMajor, which resolves to 2.0.0-internal.2.1.1.

Thanks for the review, @alexvy86!


Understanding trigger address setting and handling faulted instruction address that occur at the beginning of a TB

I'm seeing some issues with situations where the instruction to be faulted occurs at the start of a TB and a negative trigger_address is specified for the fault. If the instruction to be faulted occurs at the start of a TB then very frequently (perhaps always) ARCHIE either fails to find a trigger instruction or it finds a trigger instruction that executes after the instruction to be faulted.
It appears to me that search_for_fault_location() searches the wrong direction. goldenrun_tb_exec and goldenrun_tb_info are sorted such that the first index (index 0) is the last TB executed. Thus, to search earlier in the execution, the index value should be increased if the TB at the current index doesn't have the trigger location. However, on lines 62 and 88 the index is decreased.
Also, in case the trigger location is not found, the while loop should start with a check that the idx value does not equal or exceed the number of rows in the goldenrun TB data frames. (Or a try block should catch a ValueError when the idx is used in the call to find_tb_info_row.)
I can open a PR, but wanted to have a discussion first in case I am misunderstanding something.

Did you find these isues in your data?
If i remember correctly the tables should be reversed before they are given to the calculation function. At least thats how i first implemented it. Could have changed.
You are definitely correct with the while loop. Maybe archie should first check if the fault location is reached during normal execution?

@tibersam , Yes I can see trigger addresses selected which occur at the end of the next TB when the fault address is at the start of a TB. By "next" I mean next in execution. There are two places where the lists are reversed. If I'm reading the code correctly, the lists passed to search_for_fault_location have been unreversed. The lists are first reversed in build_filters. Then calculate_trigger_addresses reverses them before passing them to search_for_fault_location().

OK. This definitly is a bug, could be the double reversion, that is the problem. Or the strategy is flawed. I will try to investigate this further. If you already have a solution, please open a PR. I don't think you are misunderstanding something. As soon as gitlab is back online (currently has an outage) i also will look further into this

@aewag or @lukasauer can you mark this as a bug?

New theory: If you look into the tbexeclist data you find that it is not sorted correctly. Probably that is why it selects the wrong translation block

@e-shreve-ti can you verify if my branch fixes your problem?
@aewag and @lukasauer did you run into similar problems?

@aewag and @lukasauer did you run into similar problems?

I am not quite sure. I may have missed it, if it occured.

@tibersam , yes your branch address the issue of finding the correct trigger address for my application.
However, in case the trigger location is not found, I still think the while loop should start with a check that the idx value is in range. Otherwise an uncaught exception terminates the program and none of the experiments are executed. For me, this is now occurring when my fault address range includes the first instruction executed. Or I can file another ticket for this as I do note that the behavior (even if the idx value is checked to avoid an exception) means that the first instruction executed can't be faulted.

OK, we can merge #37.
I am currently looking into the while loop problem. The exception is probably index out of range?
I will change the calculation behaviour to inject the fault at start point, not when the trigger is executed if idx ever gets negativ. Also i will update the calculation to also change the lifespan so that the faulted instruction is not reverted before it is executed.  Am I overlooking something? This will take some time but i try to open the PR this week.
With this the first instruction executed should be fault-able i think.

@aewag can you reopen the issue?

@tibersam,
The exception in the while loop is a KeyError on this line
idtbinfo = find_tb_info_row(goldenrun_tb_exec.at[idx, "tb"], goldenrun_tb_info)
Yes, supporting faulting the first instruction would be great. Thanks.

@e-shreve-ti can you look into PR #38? I hope this PR fixes your probelm :)
Also could you give me also the line number of the KeyError? the find_tb_info_row is called in two locations inside the function

It should be line 58. I also ran into this error this morning, but did not have the time to look into it yet.

@tibersam , yes, as @lukasauer said, it is line 58, which is the occurrence at the start of the while loop.

I just merged pull request #38, which should fix this issue. Thanks for reporting the issue! Feel free to reopen the issue or open a new one, should it not be fixed with the pull request.


Which CLIP model?

Hi, can you tell me whether it is ViT-B/32 that you use to obtain the results reported in the paper? Did you run experiments also with a ResNet-based CLIP model and do you have any observations which works better? Thanks!

Hi @YovaKem,
We used both, and the results were similar.
But if anyone observed differently I would be interested to hear.

Thanks, @rmokady! If I understand correctly the model available at this address: 14pXWwB4Zm82rsDdvbGguLfx9F8aM7ovT as used here uses ViT-B/32 as the image encoder for Conceptual Captions data. Is there an address to download the ResNet50x4 model for Conceptual Captions? Have you made that available/are you able to share it with me? Thanks!

notebooks/clip_prefix_captioning_inference.ipynb contains the ResNet50x4 model , while also train the GPT-2 and employ MLP mapping network.

Ack, sorry, I'm not able to see where, can you point me to the exact location?
These are the only lines I can see where a model is being downloaded:
if pretrained_model == 'Conceptual captions':
  downloader.download_file("14pXWwB4Zm82rsDdvbGguLfx9F8aM7ovT", model_path)
else:
  downloader.download_file("1IdaBtMSvtyzF0ByVaBHtvM0JYSXRExRX", model_path)

Here, it's not clear whether the models are trained on ViT or ResNet, but then two cells down a ViT encoder is used to encode the images regardless of which model was loaded
clip_model, preprocess = clip.load("ViT-B/32", device=device, jit=False)

So I'm assuming both models linked above use the ViT encoder.
What would that alpha-numerical string be for downloading a ClipCaps model (i.e. the parameters of the MLP and finetuned GPT2) based on ResNet50x4? Thanks a lot for your help!

Hi @YovaKem,
Indeed I was wrong and pointed to wrong files
We didn't publish Conceptual Captions model  based on ResNet and we currently not plan to as there is no improvement
Sorry for the confusion


scan() accepts num=0.1 and does nothing but should give warning or error

The scan() plan accepts num=0.1 and behaves as if num=0. This seems like something a user would not expect.
Expected Behavior
I think an error or warning should be displayed to the user.
Current Behavior
scan(..., num=0.1) seems to do nothing.

Good catch! I'm surprised this has not been reported before.
I propose that in all scans that accept some number of steps num, we do the following check:
if not (float(num).is_integer() and num > 0):
    raise ValueError(f"The parameter `num` is expected to be a number of steps (not step size!) "
                     f"It must therefore be a whole number. The given value was {num}.")

I am suggesting ValueError not TypeError because I think that we ought accept float objects and int objects so long as the float objects (which are actually doubles in Python) represent integer values, as in:
In [1]: 2.0.is_integer()
Out[1]: True


Add access to properties of node's native element

New feature exposes the properties of a native element.  Previously,
only attributes and "checked" or "selected" properties were accessible.

I pulled this into PR #685 and added some other stuff

Closed - Was included into PR #685


Plumb kubernetes.Interface through storage backends.

Rather than synthesizing a k8schain.NewInCluster, use k8schain.New and plumb through a kubernetes.Interface from our context injection logic.
In practice this should be roughly semantically equivalent, although it will have some small side effects like respecting the shared rest.Config for things like client-side rate-limiting.  The effects of this are probably all desirable and unlikely to be consequential to any existing usage.
Related: https://github.com/tektoncd/chains/issues/161

cc @dlorenc @priyawadhwa
This is mostly cleanup.  In a subsequent change I'll change the service account this uses and reflect that in release-notes.

/kind cleanup

/lgtm

/approve


A bug about statusbar‘s height  in the multi window on Xiaomi phone

Is there an existing issue for this?

[X] I have searched the existing issues
[X] I have read the guide to filing a bug

Steps to reproduce
on Xiaomi Phone
1.change from full screen to multi screen
Expected results
statusbar’s height is not 0
on Xiaomi phone，when app in multi window，the captionBar.top is not 0 and statusbar.top is 0，but FlutterView only used statusBar，this may cause bugs！
from full screen to multi screen

Actual results
statusbar’s height is 0，the line in statusbar shade appbar
Code sample
Code sample
import 'package:flutter/material.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
        useMaterial3: true,
        appBarTheme: const AppBarTheme(
          centerTitle: true
        )
      ),
      home: const MyHomePage(title: 'Flutter示例'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({super.key, required this.title});

  final String title;

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  int _counter = 0;

  void _incrementCounter() {
    setState(() {
      _counter++;
    });
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text(widget.title),
      ),
      body: Center(
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: <Widget>[
            const Text(
              'You have pushed the button this many times:',
            ),
            Text(
              '$_counter',
              style: Theme.of(context).textTheme.headlineMedium,
            ),
          ],
        ),
      ),
      floatingActionButton: FloatingActionButton(
        onPressed: _incrementCounter,
        tooltip: 'Increment',
        child: const Icon(Icons.add),
      ),
    );
  }
}

Screenshots or Video

Screenshots / Video demonstration
https://github.com/flutter/flutter/assets/18473359/c31842ed-0242-422e-bd01-8feaadacc75e

Logs
Logs
[Paste your logs here]

Flutter Doctor output
Doctor output
[!] Flutter (Channel stable, 3.10.6, on macOS 12.6.1 21G217 darwin-arm64, locale zh-Hans-CN)
    • Flutter version 3.10.6 on channel stable at /Users/bin_ren/.fvm/versions/3.10.6
    ! Warning: `dart` on your path resolves to /opt/homebrew/Cellar/dart/2.19.1/libexec/bin/dart, which is not inside your current Flutter SDK checkout at /Users/bin_ren/.fvm/versions/3.10.6. Consider adding /Users/bin_ren/.fvm/versions/3.10.6/bin to the front of your path.
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision f468f3366c (5 weeks ago), 2023-07-12 15:19:05 -0700
    • Engine revision cdbeda788a
    • Dart version 3.0.6
    • DevTools version 2.23.1
    • Flutter download mirror https://storage.flutter-io.cn
    • If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades.

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.2)
    • Android SDK at /Users/bin_ren/Library/Android/sdk
    • Platform android-33, build-tools 33.0.2
    • ANDROID_HOME = /Users/bin_ren/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 14.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 14B47b
    • CocoaPods version 1.12.1

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

[✓] Android Studio (version 2021.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)

[✓] IntelliJ IDEA Community Edition (version 2022.3)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart

[✓] VS Code (version 1.80.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.70.0

[✓] Connected device (3 available)
    • M2101K9C (mobile) • a0f0e393 • android-arm64  • Android 13 (API 33)
    • macOS (desktop)   • macos    • darwin-arm64   • macOS 12.6.1 21G217 darwin-arm64
    • Chrome (web)      • chrome   • web-javascript • Google Chrome 115.0.5790.170

Hi @AWarmHug
I don't have a Xiaomi phone but a Realme one (Realme 6, Android 11). It displays as expected in Floating window mode:

Demo

I wonder if the multiple window mode on Xiaomi is similar to Floating window mode in Realme?

Also, can you share the device info (OS, model)? And please confirm this on the latest Flutter master channel as well. Thanks!

Hi @AWarmHug I don't have a Xiaomi phone but a Realme one (Realme 6, Android 11). It displays as expected in Floating window mode:
Demo
I wonder if the multiple window mode on Xiaomi is similar to Floating window mode in Realme?

Also, can you share the device info (OS, model)? And please confirm this on the latest Flutter master channel as well. Thanks!

Yes!,is Floating window,I tested other phones and they all displayed as expected.
device info:

Thanks for the information. Unfortunately, I don't have such a device to check this. Labeling the issue as a device-specific issue.

I Could reproduce the error on my Xiaomi phone
and to show this better I just changed the status bar color to gray
by adding this line inside the AppBar
systemOverlayStyle: const SystemUiOverlayStyle(           statusBarColor: Colors.grey,         ),
it looks like when I go to floating mode the status bar will go above the app bar as if the status bar is not there

but if I don't change the color  of the status bar I believe it is there but becomes transparent
I couldn't figure out where the code responsible for this bug in the Flutter code source
this a very old app that I made using, an older version of Flutter It looks doesn't have the same bug

any update arround this issue ?

@bagus-repository See https://github.com/flutter/flutter/wiki/Issue-hygiene#when-will-my-bug-be-fixed

Taking this off the framework team because I think this bug might be related to multi window support.

From Android triage:
go/android_insiders_25_notes
We believe this would be fixed by changing from using
https://developer.android.com/reference/android/view/WindowInsets.Type#statusBars()
to using
https://developer.android.com/reference/android/view/WindowInsets.Type#systemBars()


Doc create wishlist

Codecov Report

Merging #89 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master      #89   +/-   ##
=======================================
  Coverage   95.35%   95.35%
=======================================
  Files           2        2
  Lines         280      280
=======================================
  Hits          267      267
  Misses         13       13

Impacted Files
Coverage Δ

server.py
93.1% <ø> (ø)
:arrow_up:

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 1e2f47e...3db8af2. Read the comment docs.


Support Iceberg custom catalog

Feature request
Support Iceberg custom catalog so that users can build their own catalog to store metadata of Iceberg
related with https://github.com/StarRocks/starrocks/issues/1030

please assign this to me thanks

I'll take it, pls assign to me.

thanks @mxdzs0612


Add script for running perfdash locally

As we talked about offline, we'll keep the script in a separate directory.
I've added a short readme as it's a temporary solution until we get perfdash instance running all the time.
If you want to test the script before merging, switch GITHUB_CONFIG to:
'https://api.github.com/repos/marseel/perf-tests/contents/perfdash/test?ref=test_throughput'


PEP8, remove unused code, fix multiple calendar generation

Blank lines, padding, etc.
Remove is_future function
Remove duplicate parse_date function
fix "Unresolved reference NUM_ROWS"

Hello, thanks for pointing out the bug in the "end date" option, and the duplicate code! I wasn't a fan of all your whitespace changes, however, so I fixed those things myself and updated the master branch. Closing this.


updating pks

if you have a table with a pk and update a row to have the same pk it says pk violated... make sure pk row isn't same as updated row before throwing that error///

finally figured out what the issue was... if you have a table with a pk, and update all the rows of that table at once the map of pks will all point to a single row....

var sql = `--------------------------------------------------------
-- Exported by jSQL v3.2.6 Tue, 06 Feb 2018 18:41:54 GMT
--------------------------------------------------------
CREATE TABLE certificates (
	sponsorid VARCHAR() NULL,
	sponsorname VARCHAR() NULL,
	address VARCHAR() NULL,
	city VARCHAR() NULL,
	state VARCHAR() NULL,
	zip VARCHAR() NULL,
	primaryphone VARCHAR() NULL,
	frontgraphic VARCHAR() NULL,
	backgraphic VARCHAR() NULL,
	request_id INT() NULL,
	offer_desc VARCHAR() NULL,
	mailmonth VARCHAR() NULL,
	type VARCHAR() NULL,
	redeemed VARCHAR() NULL,
	reviewcount INT() NULL,
	avgstars NUMERIC() NULL,
	expires DATE() NULL,
	lat NUMERIC() NULL,
	lng NUMERIC() NULL,
	digital_certs NUMERIC() NULL,
	proximity_verified NUMERIC() NULL,
	last_update NUMERIC() NULL,
	PRIMARY KEY (sponsorid,mailmonth,type)
);
INSERT INTO certificates (sponsorid,sponsorname,address,city,state,zip,primaryphone,frontgraphic,backgraphic,request_id,offer_desc,mailmonth,type,redeemed,reviewcount,avgstars,expires,lat,lng,digital_certs,proximity_verified,last_update) VALUES ("171248","Digney Family Chiropractic","4190 N Garfield Ave Ste 3 ","Loveland","CO","80538","9705410402","171248","null",42791,"Free cold laser session with $47 exam","0917","C","N",2,5,null,40.434837,-105.076991,1,0,1517769683040);
INSERT INTO certificates (sponsorid,sponsorname,address,city,state,zip,primaryphone,frontgraphic,backgraphic,request_id,offer_desc,mailmonth,type,redeemed,reviewcount,avgstars,expires,lat,lng,digital_certs,proximity_verified,last_update) VALUES ("170742","Dominos Pizza","1119 Eagle Dr ","Loveland","CO","80538","9706198137","170742","null",0,null,"0917","C","Y",3,4,1512014400000,40.381031,-105.098223,0,1,1517769683040);
INSERT INTO certificates (sponsorid,sponsorname,address,city,state,zip,primaryphone,frontgraphic,backgraphic,request_id,offer_desc,mailmonth,type,redeemed,reviewcount,avgstars,expires,lat,lng,digital_certs,proximity_verified,last_update) VALUES ("161714","Lakeside Pediatric Dentistry","2700 Madison Sq ","Loveland","CO","80538","9702313538","161714-1","161714-2",0,null,"0917","C","N",7,5,null,40.421107,-105.058943,1,1,1517769683040);
INSERT INTO certificates (sponsorid,sponsorname,address,city,state,zip,primaryphone,frontgraphic,backgraphic,request_id,offer_desc,mailmonth,type,redeemed,reviewcount,avgstars,expires,lat,lng,digital_certs,proximity_verified,last_update) VALUES ("170555","Morning Fresh Dairy","5821 W Co Rd 54E ","Bellvue","CO","80512","9702134928","170555-1","170555-2",0,null,"0917","C","N",14,5,1512014400000,40.64791,-105.183347,0,0,1517769683040);
INSERT INTO certificates (sponsorid,sponsorname,address,city,state,zip,primaryphone,frontgraphic,backgraphic,request_id,offer_desc,mailmonth,type,redeemed,reviewcount,avgstars,expires,lat,lng,digital_certs,proximity_verified,last_update) VALUES ("170742","Dominos Pizza","1119 Eagle Dr ","Loveland","CO","80538","9706198137","170742R001-1","170742R001-2",0,null,"0917","P","N",3,4,1512014400000,40.381031,-105.098223,0,1,1517769683040)`;

jSQL.import(sql);

function updateCert(cert){

	Object.keys(cert).forEach(k => {
		cert[k.toLowerCase()] = cert[k]
		if (k !== k.toLowerCase()) delete cert[k]
	});

	var exp_date = cert.expires instanceof Date ? cert.expires : cert.expires !== false ? new Date(cert.expires) : null;
	var params = [
		cert.sponsorname,
		cert.address,
		cert.city,
		cert.state,
		cert.zip,
		cert.primaryphone,
		cert.frontgraphic,
		cert.backgraphic,
		cert.request_id,
		cert.offer_desc,
		~["Y","N"].indexOf(cert.redeemed) ? cert.redeemed : cert.redeemed ?


Add luxtronik2 to latest

Just to be clear: this is not an alternative to luxtronik1. These are two different hardwares which require different ways to talk to them.

RE-CHECK!

Automated adapter checker
ioBroker.luxtronik2

:thumbsup: No errors found

[ ] :eyes: [W400] Cannot find "luxtronik2" in latest repository

Add comment "RE-CHECK!" to start check anew

Hey, some small stuff:

Please all admin>=4.0.9 dep as common.globalDependencies to use the passwoerd encryption
formally "close websocket" is async, callback should be called when closed ... callback or event or such? Can give issues in compact mode when restart is too fast
do you really do extendObject in each data response process? Please not ... only if needed. This will cost a lot performance asnd produces I/O because objects are lareays updated (timestamp)

Please check and adjust

@UncleSamSwiss any update? :-)

Please all admin>=4.0.9 dep as common.globalDependencies to use the passwoerd encryption

Fixed.

formally "close websocket" is async, callback should be called when closed ... callback or event or such? Can give issues in compact mode when restart is too fast

What do you mean by this? WebSocket.close() doesn't return a Promise. Also, all handlers (e.g. this.webSocket.on('close', ...) make sure the adapter is not closing, and if it is, the handler does nothing. I assume, in compact mode a new instance of the adapter class is created for every "restart", so there shouldn't be any conflict.

do you really do extendObject in each data response process? Please not ... only if needed. This will cost a lot performance asnd produces I/O because objects are lareays updated (timestamp)

No, every call to extendObjectAsync() is depending on a condition that is only true at start-up:

the method createLuxTreeAsync() is only called from onReady()
the method handleWsMessageAsync() is only called with a NavigationMessage when the REFRESH message was sent to the heat pump which only happens from this.webSocket.on('open', ...), thus only at start-up or when reconnecting.
the handlers' extendObjectAsync() is only called after creating a handler that didn't exist yet

it sseems that the luxtronic class used also created a network connection ... but this is not closed in unload or?!

You are right, there is an undocumented socket being open for a few milliseconds, this is now fixed.
@Apollon77 please check my comments and provide me feedback. If everything is OK, I will create a new release and update this PR afterwards.

For close: aah yes it's a Websocket, then ok - we can not do anything more.
So rest ok for me. New version released? Then we could merge it


Impossible to grant user permission to import new users from LDAP without grant permission to all pages

Version used: 16.1.17-i386
WebGUI URL: /system_usermanager_import_ldap.php
How to replicate:

Make sure you're linked to an LDAP server and can import users using the user manager as root.
Create a new local test user.
Edit the new user, go to the Edit Privileges page and click Select All to tick all permissions, but unselect "WebCfg - All pages" after that.
Log out and log in as the new user.
Go to System -> Access -> Users and click the import button.
A window will pop-up, but instead of getting the user import page, you'll be redirected to the index page.

Thanks for this report. There's no ACL entry for system_usermanager_import_ldap.php, that should be easy enough to fix. :)

Patch will be in 16.1.18 today, so no need for manual apply.
Cheers,
Franci


Accessibility test pass: Workspaces window

Keyboard access
High contrast black/white
Large fonts
Screen reader (should read name, destination machine, port and the selected R interpreter)
Necessary fixes

https://github.com/Microsoft/RTVS/issues/3171
https://github.com/Microsoft/RTVS/issues/3172


Update rapids JNI and private dependency to 24.12.0-SNAPSHOT

commitBody=To fix: https://github.com/NvTimLiu/spark-rapids/issues/132
Wait for the pre-merge CI job to SUCCEED

build


withdrawing 100% liquidity protection will leave some fragments of tokens behind

Describe the bug
When withdrawing 100% of liquidity protection some fragments of tokens will left behind on the contract

To Reproduce

have open liq protection positions that can be withdrawn
click withdraw
withdraw 100%

Expected behavior
It will withdraw 100%

@H34D I just tried this and it seemed to work okay, can you confirm my assertions made in commit hash bdc59709977156cebd3fac75b39f42337ee8407c just in the console logs?

I have withdrawn a bunch of positions yesterday on ropsten. Worked fine.

Bump @H34D

you can reproduce this when staking a crude amount like 0.334343478349374234 and then try to unstake all, there must be rounding / conversion issue somewhere also related to #640


Blog organization inconsistencies

This is a Request for Discussion

What would you like to be changed

Currently there appears to be 2 ways to organize blog posts and their associated files:

The post is added as a single file in /content/en/blog/_posts, formatted as <date>-<blog name>.md. Any supplementary content is added to /static/images/blog (usually, but not always, in a subfolder refering to the <date>-<blog name> blog post).
The post is added as a folder in /content/en/blog/_posts, formatted as <date>-<blog name>, with an index.md file with in it along side any supplementary content (images, etc.).

There may be other ways of organizing that I've not picked up on.
Some questions:

Is it OK to have 2 methods?
Is there a preferred way to organize blog entries?
Do we translate blog posts? If so, is there an organization that works well for localizers?

If one method is preferred, then we might add an image to the blog-post archetype and update the Submitting blog posts and case studies page to illustrate how to organize a blog post.

Is it OK to have 2 methods?

IMO yes

Is there a preferred way to organize blog entries?

For my part: no strong opinion. The existing loose conventions seem OK. I don't mind changing away from them. I do like that there's a basic attempt at rigor / consistency.

I think we can close this now.


HTML input value is not reflected on the view

It seems the value attribute of an input field is not correctly reflected on the view when the model changes.
case class Model(input: String)

input(`type` := "text", attribute("value", model.input))

The input field is updated either on Msg.SymbolChanged or reset (input = "") on Msg.Subscribe.
// view
input(`type` := "text", attribute("value", model.input), onInput(s => Msg.SymbolChanged(s)))

// update
case Msg.SymbolChanged(in) =>
  model.copy(input = in) -> Cmd.Empty

case Msg.Subscribe =>
  val nm  = model.copy(input = "")
  val cmd = model.ws.map(ws => Cmd.Batch(ws.publish(WsIn.Subscribe.asJson.noSpaces), refocusInput))
  nm -> cmd.getOrElse(Cmd.Empty)

Everytime the model is updated in the first message, I can see the HTML input value is updated (seeing this by inspecting the element in the browser). However, when the Subscribe message is handled and the input in the model is reset, the value attribute is properly reset as well, but the view remains with the previous value.
Here's an example from the trading application, right after clicking subscribe, where I first noticed the issue.

The value attribute is reset but the view still shows the previously entered value "CHFEUR". I'd expect the input field to be cleared up as well.

I believe this is something about "attribute" vs "property". Unfortunately, I don't remember the details anymore. However, I solved it by creating a value property and using that:
def valueProp(value: String): tyrian.Attr[Nothing] = tyrian.Property("value", value)

I completely forgot about this, should have contributed back (at least the question...)

Oh that's interesting - thanks for the tip!

Morning @gvolpe and @aumann,
I'm having two problems with this:

I fully accept the properties vs attributes thing - it's a little confusing but I'm prepared to make the code change. However finding a list of attributes that should be properties is proving tricky.
The bigger problems is that I can't replicate it (or I'm miss-understanding the issue and therefore failing to replicate it). Can you give me a hand?

I've been trying to break the "field" example in the tyrian examples folder. To run that example:
sbt build5 in the examples dir of the tyrian repo, then cd examples/field, yarn install (the first time), yarn start.
Here is the change I made:
diff --git a/examples/field/src/main/scala/example/Main.scala b/examples/field/src/main/scala/example/Main.scala
index 76416e8..4c94470 100644
--- a/examples/field/src/main/scala/example/Main.scala
+++ b/examples/field/src/main/scala/example/Main.scala
@@ -13,6 +13,7 @@ object Main extends TyrianApp[Msg, Model]:
   def update(msg: Msg, model: Model): (Model, Cmd[Msg]) =
     msg match
       case Msg.NewContent(content) => (content, Cmd.Empty)
+      case Msg.Clear => ("", Cmd.Empty)

   def view(model: Model): Html[Msg] =
     div()(
@@ -21,6 +22,8 @@ object Main extends TyrianApp[Msg, Model]:
         onInput(s => Msg.NewContent(s)),
         myStyle
       ),
+      input(`type` := "text", attribute("value", "Entered: " + model)),
+      button(onClick(Msg.Clear))("clear"),
       div(myStyle)(text(model.reverse))
     )

@@ -39,4 +42,5 @@ object Main extends TyrianApp[Msg, Model]:
 type Model = String

 enum Msg:
-  case NewContent(content: String) extends Msg
+  case NewContent(content: String)
+  case Clear

That appears to work, and changing attribute to property seems to make no difference... what am I missing?

Unrelated: attribute("value", "Entered: " + model) is needed here due to a bug, but in the unreleased version value := "Entered: " + model is identical.

Excellent - thanks @aumann! I can see it not working now.
So that only leaves problem 1 to solve: I can certainly change it for value everywhere... but does value always need to be a property? And which other attributes/properties does this apply to? 🤔

We could probably look into what Elm does? I must admit, this is way out of the scope of my knowledge 😄

I suspect that secretly, this is really a snabbdom thing.
So plan B is to fix this specific case and wait for more instances of this issue to roll in as people use the library more.
Removing snabbdom is on my wish list of things to do. 🙂

https://github.com/elm/html/blob/master/properties-vs-attributes.md
😭

For future reference, if there should be more issues, an entry level explanation of attributes vs DOM properties: https://stackoverflow.com/a/6004028/14188171


Fall back to navigator.clipboard if navigator.share isn't supported.

Fixes https://github.com/rknoll/draw/issues/24.


interval variable semantic

Hi,
according to grafana doc http://docs.grafana.org/reference/templating/#the-interval-variable the $__interval variable is a great as the bucket size parameter. That how it is used for influxdb and elasctisearch data sources.
but in warp, there is a variable interval injected into the warpscript but its equal to the current time range (if I select "last 3 hours' as a time range, interval=3h). So if I use it as the bucket size parameter, it yeld only 1 data point for the whole time range.

Hi @tgermain, you have now the 2 variables available in your scripts: $interval and $__interval


Fail to start multi masters due to leader election problem

Hi chrislusf, I tried to start three masters on the same machine with the commands:
nohup ~/weed -logdir $MDIR -alsologtostderr=false \
    master -volumePreallocate -maxCpu 0 -mdir $MDIR -ip $IP -port 9333 \
    -peers=$IP:9333,$IP:9334,$IP:9335 -defaultReplication=010 &

nohup ~/weed -logdir $MDIR -alsologtostderr=false \
    master -volumePreallocate -maxCpu 0 -mdir $MDIR -ip $IP -port 9334 \
    -peers=$IP:9333,$IP:9334,$IP:9335 -defaultReplication=010 &

nohup ~/weed -logdir $MDIR -alsologtostderr=false \
    master -volumePreallocate -maxCpu 0 -mdir $MDIR -ip $IP -port 9335 \
    -peers=$IP:9333,$IP:9334,$IP:9335 -defaultReplication=010 &

But I got a panic: assertion failed: leader.elected.at.same.term.0, and the full log is as below:
panic: assertion failed: leader.elected.at.same.term.0

goroutine 102 [running]:
github.com/chrislusf/raft._assert(...)
        /home/travis/gopath/src/github.com/chrislusf/raft/util.go:60
github.com/chrislusf/raft.(*server).processAppendEntriesRequest(0xc000158d80, 0xc0003820a0, 0xc0003820a0, 0x0)
        /home/travis/gopath/src/github.com/chrislusf/raft/server.go:948 +0xea5
github.com/chrislusf/raft.(*server).leaderLoop(0xc000158d80)
        /home/travis/gopath/src/github.com/chrislusf/raft/server.go:849 +0x3b5
github.com/chrislusf/raft.(*server).loop(0xc000158d80)
        /home/travis/gopath/src/github.com/chrislusf/raft/server.go:609 +0x1be
github.com/chrislusf/raft.(*server).Start.func1(0xc000158d80)
        /home/travis/gopath/src/github.com/chrislusf/raft/server.go:470 +0x5a
created by github.com/chrislusf/raft.(*server).Start
        /home/travis/gopath/src/github.com/chrislusf/raft/server.go:468 +0x2ab

After viewing related codes, I find that each master sends a DefaultJoinCommand command to its raft server when it starts up. In the follower loop, when a raft server receives a JoinCommand and if the log.currentIndex() == 0, it becomes leader directly.
I wonder if this could be a problem? Since all the servers has their log.currentIndex() equals to 0 when the system starts up.
I also have rerun this test, and found that the problem occurs randomly, and if I set to sleep 1 second after each master starts up, it can be avoided. I also notice that there is a random timeout before each raft server performs the JoinCommand, but it seems not work for this problem. The weed version is 1.24.

@chrislusf the fixes are reverted and this issue still exists.


Release 1.2.1

Proposed changes
Releasing 1.2.1 Mainly because fixing the husky issue during installation #313
Screenshots (if appropriate) or codepen:
N/A
Types of changes

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

Checklist:

[x] I have read the CONTRIBUTING document.
[x] My commit messages follows the conventional commit format
[ ] My change requires a change to the documentation, and updated it accordingly.
[ ] I have added tests to cover my changes.
[ ] All new and existing tests passed.

I have assigned @materializecss/members-write-access as reviewer since no one was informed due to the missing assignment.

anyway, to reduce the manual work for CHANGELOG, how about if we include only from 1.2.0 to 1.2.1?
for the earlier versions, the user can read on releases page
wdyt?

Oh thats correct I forgot that, thanks!

Regarding assignments, I will check if we can enable some sort of auto-assignments. So no PR will be missed then in the future.

Ok, please review, I have updated the changelog with only the differences since the last version (1.2.0)

Ok, please review, I have updated the changelog with only the differences since the last version (1.2.0)

Seems now all the old changelog entries are gone.

Seems now all the old changelog entries are gone.

Yes, there was an error when generating the whole changelog, some PRs were not found and needed manual fixing.
@Smankusors suggested to only list the changes between two releases. (from 1.2.0 to 1.2.1) I also think this is the better approach. When looking up older changes this can be done via the release-page. Wdyt?

ooh! I just realized that we can use --base CHANGELOG.md to append the changelog, then there is no manual work anymore 😳
hmm but I'm still not sure if we should maintain a full changelog? I'm curious since we have a releases page, what's the purpose of the CHANGELOG.md anymore other than for drafting the changelog? 😅

Changelog via GH interface and releases sounds way easier and better. Afaik GH supports the creation of the release changelog via click.
If this is the best option for us, then we can empty changelog.md and link there to https://github.com/materializecss/materialize/releases/tag/1.2.1 in there.

Changelog via GH interface and releases sounds way easier and better. Afaik GH supports the creation of the release changelog via click.
If this is the best option for us, then we can empty changelog.md and link there to https://github.com/materializecss/materialize/releases/tag/1.2.1 in there.

I will merge this now. We also can further improve the changelog handling, let us discuss ideas and improvements in a speperate issue. Thanks and happy holidays to all of you!


Building RESTful APIs with Express.js

Title Of Blog Post : Building RESTful APIs with Express.js
Short Description of what is expected: Learn to build RESTful APIs using Express.js, a popular Node.js framework, and explore middleware and routing.
Category: Web Development
Tags: Express.js, RESTful APIs, Node.js, Web Development.

assign this to me !

folder in which I have to work ?
and can you please provide some details like what kind of API I have to code ?


Support stream load transaction interface

What type of PR is this：

[ ] bug
[x] feature
[ ] enhancement
[ ] others

Which issues of this PR fixes ：

Fixes #4757
Problem Summary(Required) ：

[FE PR Coverage check]
:disappointed: fail : 9 / 45 (20.00%)
file detail

path
covered line
new line
coverage

:large_blue_circle:
com/starrocks/service/FrontendServiceImpl.java
0
5
00.00%

:large_blue_circle:
com/starrocks/http/rest/TransactionLoadAction.java
8
39
20.51%

:large_blue_circle:
com/starrocks/http/HttpServer.java
1
1
100.00%

[FE PR Coverage check]
:disappointed: fail : 9 / 45 (20.00%)
file detail

path
covered line
new line
coverage

:large_blue_circle:
com/starrocks/service/FrontendServiceImpl.java
0
5
00.00%

:large_blue_circle:
com/starrocks/http/rest/TransactionLoadAction.java
8
39
20.51%

:large_blue_circle:
com/starrocks/http/HttpServer.java
1
1
100.00%

[FE PR Coverage check]
:disappointed: fail : 9 / 45 (20.00%)
file detail

path
covered line
new line
coverage

:large_blue_circle:
com/starrocks/service/FrontendServiceImpl.java
0
5
00.00%

:large_blue_circle:
com/starrocks/http/rest/TransactionLoadAction.java
8
39
20.51%

:large_blue_circle:
com/starrocks/http/HttpServer.java
1
1
100.00%

[FE PR Coverage check]
:disappointed: fail : 9 / 45 (20.00%)
file detail

path
covered line
new line
coverage

:large_blue_circle:
com/starrocks/service/FrontendServiceImpl.java
0
5
00.00%

:large_blue_circle:
com/starrocks/http/rest/TransactionLoadAction.java
8
39
20.51%

:large_blue_circle:
com/starrocks/http/HttpServer.java
1
1
100.00%

[FE PR Coverage check]
:disappointed: fail : 9 / 45 (20.00%)
file detail

path
covered line
new line
coverage

:large_blue_circle:
com/starrocks/service/FrontendServiceImpl.java
0
5
00.00%

:large_blue_circle:
com/starrocks/http/rest/TransactionLoadAction.java
8
39
20.51%

:large_blue_circle:
com/starrocks/http/HttpServer.java
1
1
100.00%


19m param model

Where did the 19m model go to!

Hey! We recently renamed all models to take their embedding and unembedding layers into account, and to better reflect both the naming scheme used by OPT and GPT-2 as well as reflecting the model's size on GPU.

Ah okay, that makes sense! thanks for clarifying


storage::drivers::aws::new support cover endpoint ?

Feature Request
In development, local minio container is usually used to store small files, so should you consider adding an endpoint to overwrite the endpoint?
At present, I see that aws::new in the loco source code does not allow overwriting endpoints.
/// Create new AWS s3 storage with bucket and region.
///
/// # Errors
///
/// When could not initialize the client instance
pub fn new(bucket_name: &str, region: &str) -> Result<Store> {
    let s3 = AmazonS3Builder::new()
        .with_bucket_name(bucket_name)
        .with_region(region)
        .build()
        .map_err(Box::from)?;

    Ok(Store::new((Box::new(s3) as Box<dyn ObjectStore>).into()))
}

currently, no; you can see the AWS builders here.
Why are you not working in-mem driver in development?

ok, I use minio, because api upload file store minio, other service will use file by minio.

Is it possible to add an api or re-export the AmazonS3Builder? I'm working with another cloud provider's object storage which are compatible with S3 api.

currently, no; you can see the AWS builders here.
Why are you not working in-mem driver in development?

ok, I use minio, because api upload file store minio, other service will use file by minio. I would like to use object_store to communicate with my local object store (which is a minio object store) I initialize the client like this
let s3 = AmazonS3Builder::new()
    .with_endpoint("http://localhost:30002")
    .with_region("us-east-1") // Dummy region for local testing
    .with_bucket_name("my-bucket")
    .with_access_key_id("minio")
    .with_secret_access_key("miniostorage")
    .build()
    .expect("error creating s3");

Hey, does it work if use minio now ?  what to do if use minio ?

currently, no; you can see the AWS builders here.
Why are you not working in-mem driver in development?

ok, I use minio, because api upload file store minio, other service will use file by minio. I would like to use object_store to communicate with my local object store (which is a minio object store) I initialize the client like this
let s3 = AmazonS3Builder::new()
    .with_endpoint("http://localhost:30002")
    .with_region("us-east-1") // Dummy region for local testing
    .with_bucket_name("my-bucket")
    .with_access_key_id("minio")
    .with_secret_access_key("miniostorage")
    .build()
    .expect("error creating s3");

Hey, does it work if use minio now ? what to do if use minio ? @fan-tastic-z

I didn’t have the author’s idea at the time, and I still couldn’t use it at the time

currently, no; you can see the AWS builders here.
Why are you not working in-mem driver in development?

ok, I use minio, because api upload file store minio, other service will use file by minio. I would like to use object_store to communicate with my local object store (which is a minio object store) I initialize the client like this
let s3 = AmazonS3Builder::new()
    .with_endpoint("http://localhost:30002")
    .with_region("us-east-1") // Dummy region for local testing
    .with_bucket_name("my-bucket")
    .with_access_key_id("minio")
    .with_secret_access_key("miniostorage")
    .build()
    .expect("error creating s3");

Hey, does it work if use minio now ? what to do if use minio ? @fan-tastic-z

I didn’t have the author’s idea at the time, and I still couldn’t use it at the time

Did you try to use http or local ?


Remap incorrectly using escaped paths

json-schema-ref-parser/lib/bundle.js in routine remap will take external file $ref's and remap them to self-relative $refs. At the time this is done, the paths in the parsed api file have been escaped ('/' -> '~1'), so you end up with a reference that looks like:
$ref: #/paths/~1foo~1bar/content-type...

This will break anyone (such as ajv) who will parse this on '/' boundaries and use it to walk the json file to find the actual referent.
The problem may be located in crawl() which calls Pointer.join to form full paths and also escape the embedded '/'

Completely bad triage. Ignore.

Completely bad triage. Ignore. Sorry


code snippet (ch.10): stray line on pg. 320 + missing >= 0

There's a stray line as highlighted and also FindProcess is missing >= 0 on the condition check.

Checking.

My bad. fixing.

fixed in the latest ed.


Cannot access global variable that created by setupfiles file.

🐛 Bug Report

Cannot access value from global that created in setupFiles file "setup.js".
Tests all passed when not using the setupFiles file.
Able to access value from global that set in jest.config.js.
Like:
setupFiles: ["/Users/zhenyuandu/cloudfunctionlive/functions/src/__tests__/customSetup.js"],
globals: {
      "id": "aaa",
}

To Reproduce
Steps to reproduce the behavior:
// setup.js
module.exports = async () => {
      global.id = "aaa";
}

// test.js
test('something', () => {
    console.log(global.id)
    expect(true).toBe(true);
});

// jest.config.js
module.exports = {
    setupFiles: ["mypath/src/__tests__/setup.js"]
}

Expected behavior

Expected:
PASS src/__tests__/test.js
aaa

Actually get:
PASS src/__tests__/test.js
undefined

Link to repl or repo (highly encouraged)

envinfo

VSCODE: v1.42.0
MacOS: 10.15.2

// package.json
"engines": {
        "node": "8"
}

// jest.config.js
module.exports = {
    testRegex: 'src(/__tests__/.*|(\\.|/)(test|spec))\\.(jsx?|tsx?)$',
    testPathIgnorePatterns: ['lib/', 'node_modules/'],
    moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json', 'node'],
    testEnvironment: 'node',
    rootDir: 'src',
    setupFiles: ["mypath/src/__tests__/setup.js"]
}

setupFiles do not execute the function provided, it just loads the module. So you'll need to do your assignment at the top level

Hi Simen,
What do you mean by "at the top level"? Can you please explain with an
example? All I want is just to mock some same modules before each test
file.
On Sun, Feb 16, 2020 at 2:25 AM Simen Bekkhus<EMAIL_ADDRESS>wrote:

setupFiles do not execute the function provided, it just loads the
module. So you'll need to do your assignment at the top level
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/facebook/jest/issues/9577?email_source=notifications&email_token=ALL3JE3S6HMNCB6KQIF5E73RDDZ6PA5CNFSM4KWATT42YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEL4AUMQ#issuecomment-586680882,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ALL3JE7UNIB45LKHDNEKHMLRDDZ6PANCNFSM4KWATT4Q
.


Range control thumb :active is invalid as the slider thumb does not receive active or focus events

Add :focus range track style of the range input control to aid visibility while tabbing.
Update colors used from theme to make more appropriate for darker page backgrounds as well as light backgrounds.

Fixed.


Cypress freezing after triggering transaction

Cheers!
I am trying to test a transaction.
After the button to trigger the transaction is pressed, no MetaMask window to confirm the transaction appears and the Cypress UI becomes unresponsive. The confirmMetamaskTransaction() function obviously doesn't work when no transaction-confirmation window is showing.
No UI-Element in the Cypress test runner is clickable.
The Chrome UI (switching tabs etc.) still works.
There are not transactions listed when inspecting the MetaMask tab in the Chrome window.
Testing the failing transaction manually works as expected.
A button with exactly the same functionality (calling the same function in the same context) exists on another site of the website I am testing. Triggering the same transaction using that quasi-identical button through Synpresss does work.
Synpress gets invoked using the 'run' option and I have isolated the test to make sure there is no interference with another test.
Any ideas what could be causing this?
Thanks!

Can you provide like a video so I can try to help?

I am sorry but I found a workaround and can't reproduce it anymore. It seemed like it had something to do with the browser cache and local storage being deleted between tests. I can't figure out how that would make Cypress crash though.
I guess this Issue is fine to be closed right?


Refactor deployResource method of ZeebeGrpcClient

This method should take a more generic signature.

The issue with this is that a more generic input signature produces a more generic return signature. At the moment we can narrow the response shape type based on the input signature that is used.
In the interests of type safety and developer ergonomics (intellisense), I'll leave this as it is.


must we swallow an error if session is not configured?

I'm using an extension method on controller to set alerts using TempData which in turn depends on session, code for the method is as follows:
private static void AddAlert(
        this Controller controller,
        string alertStyle,
        string message,
        bool dismissable)
    {
        try
        {
            if(controller.Context.Session != null)
            {
                var alerts = controller.TempData.ContainsKey(Alert.TempDataKey)
                ? (List<Alert>)controller.TempData[Alert.TempDataKey]
                : new List<Alert>();

                alerts.Add(new Alert
                {
                    AlertStyle = alertStyle,
                    Message = message,
                    Dismissable = dismissable
                });

                controller.TempData[Alert.TempDataKey] = alerts;
            }

        }
        catch(InvalidOperationException)
        {
            // happens if session is not configured
            // TempData depends on session
        }

    }

I don't like it that it I'm having to catch System.InvalidOperationException even though I'm checking if session is null. If I remove the check for null the error is not stopped by the try catch so it completely breaks the app if session is not configured. Adding the null check somehow made it possible to catch the exception.
Of course I can fix it by enabling session, but my code is in a library that I expect others to use and I don't want to force them to enable session if they don't want to. If they don't enable session I want the alerts feature to fail silently, it will be documented that to use it session must be enabled. But in that scenario I'm forced to keep swallowing the exception which seems undesirable.
Is there any way to detect if session is available without raising an exception?

Try: if (controller.Context.GetFeature<ISessionFeature>() != null)

That works great! I was able to remove the try catch.
Thanks for the amazingly fast response with the answer!

Welcome.


[Bug]: Using a double wildcard (**) in project patterns leads to test suites being run multiple times

Version
29.5.0
Steps to reproduce

Create a monorepo-like structure, like so:

|- `jest.config.js`
|- `packages`
    |- `core`
        |- `jest.config.js`
    |- `client`
        |- `package-c-a`
            |- `jest.config.js`
        |- ...
    |- `server`
        |- `package-s-a`
            |- `jest.config.js`
        |- ...

Make sure there are some tests in each of the packages.

In the top-level jest.config.js, write the following:

module.exports = {
  projects: [
    '<rootDir>/packages/**/jest.config.js',
  ]
}```

3. Run `jest` from the top level directory.

### Expected behavior

I would expect every test suite in all packages to be run only once.

### Actual behavior

My suites are run 10x. Sometimes 3x, as I was fiddling around with the pattern, but mostly 10x.

### Additional context

When I run `jest` in any of the `packages` subdirs, everything is run only once.

### Environment

```shell
System:
    OS: macOS 13.4.1
    CPU: (10) arm64 Apple M1 Max
  Binaries:
    Node: 20.1.0 - ~/.nvm/versions/node/v20.1.0/bin/node
    Yarn: 1.22.19 - ~/.nvm/versions/node/v16.13.1/bin/yarn
    npm: 9.6.4 - ~/.nvm/versions/node/v20.1.0/bin/npm
    pnpm: 8.4.0 - /opt/homebrew/bin/pnpm
  npmPackages:
    jest: ^29.5.0 => 29.5.0

O FYI, I am able to solve it by modifying my config like so:
module.exports = {
  projects: [
    '<rootDir>/packages/*/jest.config.js',
    '<rootDir>/packages/*/*/jest.config.js',
  ]
}

Would be way easier to take a quick look if you could provide a reproduction repo. That saves a lot of time and makes sure everyone looks at the same thing. Just a suggestion.

I would love to, but I cannot share the production repo because this is for my work – NDA's and stuff. And I have about 10 minutes before I leave for vacation, so maybe I'll make a reproduction repo as I got back. I just felt it would be nice to report it before I left :).

Sure. Also consider running Jest with the --showConfig flag and inspecting the resolved config. This can help a lot while debugging projects configuration.

Ok but I mean, I've resolved it. The workaround is not to use ** in my project paths. I'm just leaving it here to inform you guys this might be something in the future. Do with it what you may!
For me, all is good!


Change structure for form definition

⚠ This is a breaking Change
Previously, we went with a very minimal API for defining your form validations (which are just attributes in the built-in cases):
const formValidations = {
  firstName: {
    required: true,
    maxLength: 50,
  },
  lastName: {
    required: true,
    maxLength: 50,
  },
};

But as we scaled up functionality, this started to become a bit limiting:

Adding custom validations directly alongside built-in attributes makes type restrictions harder, since you can't restrict the object keys to only those built-in HTML validation attributes.
There's no room for custom error messages, so they needed to go in a separate object.  Being able to colocate them with their specific validations would be nice.
Typings got really nasty when looking to implement additional, seemingly simple, functionality

This PR moves to a new more-comprehensive API for defining your form information with 2 major changes:

Built-in validations are separated from custom validations
Error messages can be included at either the field level or the global level

A new form definition would looks look like:
import type { ErrorMessage, InputDefinition } from "remix-validity-state";

// Define your schema so we can properly infer types on things such as `serverFormData.inputs`
interface MyFormSchema {
  inputs: {
    username: InputDefinition;
    emailAddress: InputDefinition;
  };
  errorMessages: {
    tooShort: ErrorMessage;
  };
}

let formDefinition: FormSchema = {
  inputs: {
    username: {
      validationAttrs: {  // 👈 Built-in HTML validations
        required: true,
        minLength: 5,
        pattern: "^[a-zA-Z]+$",
      },
    },
    emailAddress: {
      validationAttrs: {
        type: "email",
        required: true,
      },
      customValidations: {  // 👈 Custom validations
        async uniqueEmail(value) {
          await new Promise((r) => setTimeout(r, 1000));
          return value !==<EMAIL_ADDRESS>&& value !==<EMAIL_ADDRESS>        },
      },
      errorMessages: {  // 👈 Field-level error messages
        uniqueEmail(attrValue, name, value) {
          return `The email address "${value}" is already in use!`;
        },
      },
    },
  },
  errorMessages: {  // 👈 Global error messages
    tooShort: (attrValue) => `Field must be at least ${attrValue} characters long`,
  },
};

My hope is that this makes things like #8 and #21 a good bit easier 🤞

This also includes the change from #17


Add all HTTP methods for CORS. When enabling CORS on AWS API Gateway,…

Description
Add all HTTP methods for CORS

Coverage remained the same at 80.633% when pulling 1b7a79721e6bb0ae7e0c757d6acfcb31fcee9e33 on geeknam:feature/extra_methods_cors into 43ae24e0ec32a0a215f90919ed99226c5cc2d3e7 on Miserlou:master.


Running Zero Result

Hi Author,
Is it compulsory to run in test folder?can I move to other folder? Because when I put into test folder..those library seems cannot recognize?can u clarify this? I  using your library. thanks alot

What are you asking? What is wrong with using src/test/java? Android unit tests should go in src/test/java and instrumentation tests should go in src/androidTest/java.

nothing. is was resolved. Thanks ya

Can we close this issue then?

sure bro


Animation_NodeMisc Model Group

Further progress on #414 that covers edge cases

[ ]  Change model 02 so that it isn't cut off by the side of the screen in the viewer
[ ]  Make sure model 03 not rendering isn't a problem with the model itself
[ ]  Change model 04 so that it looks less trippy

@bghgary and @kcoley The issue with model 03 looks to me like a bug in Babylon.js. The other model have been updated per your feedback.

Confirmed. This is a bug.

This is fixed now.

@kcoley Sorry to ask for another so soon, but could you update the screenshot generator to the latest version of babylon again?

@stevk sure, I'll work on it now.

@stevk looks like Babylon's npm package was not updated recently.  You will have to update the files manually for now.

I've made the requested changes.

05 the base translation is unexpectedly kept in addition to the translation animation
06 the base translation is unexpectedly overridden by the rotation animation

I think these two things are causing issues with positioning on model 04 as well.

@bghgary I've fixed models 05 and 06.
04 still isn't being framed correctly. One of the nodes is centered on 0,0,0 while the other is offset by -0.8, 0, 0. The camera is centered as expected, but the sides of both nodes are cutoff.
Readme : https://github.com/stevk/glTF-Asset-Generator/tree/nodeanimationextras/Output/Animation_NodeMisc
View Link: https://bghgary.github.io/glTF-Assets-Viewer/?manifest=https://raw.githubusercontent.com/stevk/glTF-Asset-Generator/nodeanimationextras/Output/Manifest.json&folder=1&model=4


Updated problem-sets-competitive-programming.md file

Added one Best competitive coding platforms, i.e., Pep Coding, where people can get the best and free resources for competitive programming
What does this PR do?
Add resource(s) | Add info | Improve repo
For resources
Description
This PR will helps the programmers to get exposed to one of more best platforms where they can improve their coding skills while learning with the best community!
Why is this valuable (or not)?
Because this PR includes the latest and updated platforms rather than older ones in which many bugs are not fixed.
How do we know it's really free?
The platforms are open to all!
For book lists, is it a book? For course lists, is it a course? etc.
Checklist:

[x] Read our contributing guidelines.
[x] Search for duplicates.
[x] Include author(s) and platform where appropriate.
[x] Put lists in alphabetical order, correct spacing.
[x] Add needed indications (PDF, access notes, under construction).
[x] Used an informative name for this pull request.

Follow-up

Check the status of GitHub Actions and resolve any reported warnings!

insert specific link

Hello @LuigiImVector, As per your request, I had updated and committed. Please check this PR!!

Good

@eshellman, If possible, please add a hacktoberfest-accepted label; it will be beneficial and motivate me!!

@eshellman, If possible, please add a hacktoberfest-accepted label; it will be beneficial and motivate me!!

merged PRs are automatically counted in your hacktoberfest profile

@LuigiImVector, but if label is added, there may be no chances of exclusion

repository has that label, everything is fine


Example gpu_device_ids for multi-model usage?

System Info
P4D (A100 40 GB x 8)
Who can help?
@juney-nvidia @byshiue
Information

[X] The official example scripts
[ ] My own modified scripts

Tasks

[X] An officially supported task in the examples folder (such as GLUE/SQuAD, ...)
[ ] My own task or dataset (give details below)

Reproduction
I want to use multi-model TP-4 x 2 setup. How do I set gpu_device_ids to [[0,1,2,3],[4,5,6,7]]
Could you please provide an example usage of gpu_device_ids?
Expected behavior
n/a
actual behavior
n/a
additional notes
n/a

How do I use an ensemble which load balances across these 2 model instances?


Can't Use Google Account Sync in Application

System Details

OS: Android 11
Thorium Version: Latest Version

Problem
When I click "turn on sync" on a fresh install, I don't see the any google accounts that I'm logged into on my Android Device... If I click add account and add a new google account it doesn't sign in & sync.
Additional Notes
There is no simpler problem with chrome.
Thank You In Advance 😄
Oct 31, 2023

#6


Suricata shows a warning on boot

What should we do here? Mute the output and potentially remove useful hints as to why Suricata may not work as expected?

I would prefer if It would be changed like described in the warning as it says it is faster and always the fastest option should be used if it does not break anything else ;)

It complains about not having selected IPS mode, which is a valid configuration option...

Maybe suricata wants to use netmap regardless of running IPS or not. Maybe there is something in the configuration where IPS can be disable while using netmap.

PCAP mode is sane and safe. Netmap requires newer hardware. I don't see how we should switch because there is a warning in Suricata. If anything it would help to report this to Suricata as a bug. We set suricata.yaml correctly and still have this warning ;)

I think the warning is not referencing the yaml file but directly the command line. I also noticed I have this warning, and the current command line of my suricata (running in IDS, not IPS) is:
/usr/local/bin/suricata -D -i re0 --pidfile /var/run/suricata.pid -c /usr/local/etc/suricata/suricata.yaml
It seems to be complaining that we didn't explicitely told it to use netmap or pcap, and warns us.
I suppose the /usr/local/etc/rc.d/suricata file should be modified to add the --pcap option when $suricata_netmap = "NO" ?

@speed47 the launcher scrip is from FreeBSD ports so ideally this needs to be fixed in coordination with them

Actually, I think this patch might do the trick coupled with using "$suricata_pcap"
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=212192

Indeed, it should do the trick. I'll test by patching my rc with their diff and report if it works.

I can confirm it works by applying their patch (https://bugs.freebsd.org/bugzilla/attachment.cgi?id=174112&action=diff).
My new command-line, even without defining $suricata_pcap, is:
/usr/local/bin/suricata -D --pcap=re0 --pidfile /var/run/suricata.pid -c /usr/local/etc/suricata/suricata.yaml.

Thanks for testing 👍 I've prodded the bug report, maybe it can be included in FreeBSD soon. 😊

still delayed in FreeBSD...

The suricata rc script is so royally inflexible that it's simply not possible to fix this warning from our end.


Code Injection data is not updated properly if we send empty data

the same thing is happening while updating space data


Primal offset and documentation update

add primal offset as optional keyword for plot_trajectories to handle log scaling of the y-axis for objectives with negative minima
Update documentation of ALM and minor other consistency fixes

@JannisHal there seems to be conflicts, maybe merge master into your branch


Include "required" and "additionalProperties" keys to the object definitions

Feature Request
Include "required" and "additionalProperties" keys to the object definitions. The field list of "required" key should be as per the prisma model definition. The "required" is very much needed as the default behaviour of json schema specs is to allow empty objects to pass the validation.
For example:
{
  "definitions": {
    "address": {
      "type": "object",
      "properties": {
        "street_address": { "type": "string" },
        "city":           { "type": "string" },
        "state":          { "type": "string" }
      },
      "required": ["street_address", "city", "state"]
    }
  },
  "additionalProperties": false
}

@valentinpalkovic I saw your comment on the commit that removed the required functionality that you had implemented earlier. I have a suggested approach to address your concern.
I use id (autoincrement) as the primary key for my tables but do not expose it to the front-end app instead I expose cuid. Therefore, effectively unique key for my biz logic is cuid.
Organization Model
generator jsonSchema {
  provider = "node node_modules/prisma-json-schema-generator"
  primaryKey   = "cuid"     // Optional, if set use this field as the primary key otherwise use the prisma model primary key
  fieldsNotRequired = [ "createdAt", "updatedAt", "updatedBy" ]
}

model Organization {
  id               Int                  @id @default(autoincrement())
  address          String
  name             String               @unique
  organizationType String               @map("org_type")
  status           String
  cuid             String               @unique @default(cuid())
  createdAt        DateTime             @default(now()) @map("created_at")
  updatedAt        DateTime             @updatedAt @map("updated_at")
  updatedBy        String?              @default("system") @map("updated_by")

  @@map("sys_t_organization")
}

Schema should look like this when primaryKey parameter is not set
{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "definitions": {
    "Organization": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "address": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "organizationType": {
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "cuid": {
          "type": "string"
        },
        "createdAt": {
          "type": "string",
          "format": "date-time"
        },
        "updatedAt": {
          "type": "string",
          "format": "date-time"
        },
        "updatedBy": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "if": {
        "properties": {
          "id": {
            "const": null
          }
        }
      },
      "then": {
        "required": [
          "address",
          "name",
          "organizationType",
          "status"
        ]
      },
      "else": {
        "anyOf": [
          {
            "required": [
              "address"
            ]
          },
          {
            "required": [
              "name"
            ]
          },
          {
            "required": [
              "organizationType"
            ]
          },
          {
            "required": [
              "status"
            ]
          }
        ]
      }
    },
  },
  "type": "object",
  "properties": {
    "organization": {
      "$ref": "#/definitions/Organization"
    }
  }
}

Schema should look like this when primaryKey parameter is set
{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "definitions": {
    "Organization": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "address": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "organizationType": {
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "cuid": {
          "type": "string"
        },
        "createdAt": {
          "type": "string",
          "format": "date-time"
        },
        "updatedAt": {
          "type": "string",
          "format": "date-time"
        },
        "updatedBy": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "if": {
        "properties": {
          "cuid": {
            "const": null
          }
        }
      },
      "then": {
        "required": [
          "address",
          "name",
          "organizationType",
          "status"
        ]
      },
      "else": {
        "anyOf": [
          {
            "required": [
              "address"
            ]
          },
          {
            "required": [
              "name"
            ]
          },
          {
            "required": [
              "organizationType"
            ]
          },
          {
            "required": [
              "status"
            ]
          }
        ]
      }
    },
  },
  "type": "object",
  "properties": {
    "organization": {
      "$ref": "#/definitions/Organization"
    }
  }
}

NOTE
Please note that when id' or cuidis null then it will be treated as a new (create) request, therefore it will force all required fields to be present. And whenidorcuidis not null then it will be treated as an update request, hence usesanyOf` to enforce at least one of the fields to be present for updation.
Also note that this mitigates your concern of prisma select or include field selections in the result to be sent to the client. It will always pass as the result wil have either the id or the cuid, therefore else path will be followed.
fieldsNotRequired parameter
If this parameter is set then omit these fields from the required key values in both the if paths.

In principle a good idea. But you only treat the cases of creating or editing a new entity from the frontend. How should the schema validation looks like, if the user wants to fetch an entity with some specific fields (Graphql case). The frontend client can fetch any fields and does not have to fetch all of them at once. Therefore marking fields as required might only be true for (in REST language) PUT/POST requests. Therefore it is impossible at build/compile time to know, which fields are actually fetched by the client. Secondly, you cannot be sure, which fields have to be sent by the client and which can be delivered by other microservices or even be extracted from the user session information (information saved in JWT). The Prisma schema doesn't answer these types of questions and I have the feeling that your provided solution would cover one small use-case out of a bunch of possible use-cases.
Also, in the use-case of a backend-for-frontend solution, where most of the business logic lays in the backend, additional fields, which are not persisted in the database, might be sent to the frontend (persisted ui states, session related information,...). Marking additionalProperties: false would disallow this and would only allow sending database-related fields to the client and back.

I use graphql not rest api. In my opinion, all cases will be covered by setting additionalProperties: true with the suggested approach. There will be rare cases where front-end does not require the primary key along with other fields, in such a case of course the else path will not be followed and validation will throw errors. This case will be effective only when you want to validate the response of a controller/action before passing it to graphql that does not include the primary key.
The current generated schema is of no use as it will pass any object

empty objects
objects that do not have any of the properties in the schema

How do you propose to use the current state of generated schema for input validation in the api?

To be a bit more specific to my previous comment (because you haven't answered my concerns yet):

Your proposed solution only works, if client-side data is validated. Any data, which is sent by the backend to the client cannot be validated, because the client could only request a subset of data. The validation would fail in the below example because all the other as required marked fields are not provided.

query getOrganization() {
  organization {
    id
    address
    name
  }
}

Your proposed solution ignores computed fields, which derives out of database data.

query getOrganization() {
  organization {
    id
    address
    name
    someComputedValueWhichIsNotSavedIntoDatabase
  }
}

someComputedValueWhichIsNotSavedIntoDatabase is not saved in the prisma model and therefore setting additionalProperties: false the validation would fail.

What happens, if the client wants to do a delete mutation? Then only the id or cuid is provided
mutation deleteOrganization($input: DeleteOrganizationInput) {
id
}

Your proposed solution: "And when id or cuid is not null then it will be treated as an update request, hence uses anyOf to enforce at least one of the fields to be present for updation." wouldn't work.
But maybe the JSON schema validation is only used for client-data validation. In this case, my concerns mentioned in 1. and 2. don't matter. I just don't know currently, how the schema is used to validate data. Maybe you could provide some examples and use-cases which could show the usage of the generated JSON schema.

The current generated schema is of no use as it will pass any object

empty objects
objects that do not have any of the properties in the schema

Currently, that's true. Only known fields are validated and checked, whether the right type is passed or not. Unknown fields or empty objects are not validated.

Point 1. The solution can be enhanced to include all the fields in the else path of anyOf and setting the additionalProperties: true as default. Then the client will be able to validate the api response with additional computed fields as well. The only case where it will fail is in case the id or cuid is not inluded in the graphql query. It will become mandatory to include the id or cuid to make it work.
Point 2. Is addressed by setting additionalProperties: true as default.
Point 3. Why anyone would like to do an explicit schema validation for delete mutation. The id or cuid will be inherently validated by graphql automatically, just use the value as-is to delete the record.

Here's my solution to this problem, a simple utility function:
export const requireSchema = <T>(
    schema: { type: string; properties: T },
    required: (keyof T)[]
) => {
    return { ...schema, required }
}

It takes a schema definition with a list of required params. Here's an example using it with fastify:
server.route<{ Body: Lead }>({
    method: "POST",
    url: "/leads",
    schema: {
        body: makeSchema(schema.definitions.Lead, [
            "first_name",
            "last_name",
            "email",
        ]),
    },
    handler: async (req, reply) => {
        // ...
    },
})

This allows to enforce which fields are necessary on a route-by-route basis instead of just based on the database. Since it makes use of typescript generics, the array of required fields is validated against the schema, so its type-safe. With this method you could make the mistake of leaving out a field required by the database, but at that point Prisma will throw an error anyway. For me this is a decent middle-ground.

This library isn't usable without required

This library isn't usable without required

I think we have to talk about the abilities of the Prisma schema and its main purpose.
Per docs, the Prisma schema consists of three parts:

Data sources: Specify the details of the data sources Prisma should connect to (e.g. a PostgreSQL database)

Generators: Specifies what clients should be generated based on the data model (e.g. Prisma Client)

Data model definition: Specifies your application models (the shape of the data per data source) and their relations

The Prisma model definitions "represent the entities of your application domain, map to the tables (relational databases like PostgreSQL) or collections (MongoDB) in your database, form the foundation of the queries available in the generated Prisma Client API and when used with TypeScript, Prisma Client provides generated type definitions for your models and any variations of them to make database access entirely type-safe." - https://www.prisma.io/docs/concepts/components/prisma-schema/data-model
By only parsing the Prisma model, it is not possible to figure out, which endpoints will be created, whether it is a GraphQL endpoint or a plain REST endpoint. The actual code of your backend defines, which data the user has to send to create, read, update or delete data. Already mentioned techniques like computed fields makes things even more unpredictable. It would be necessary to parse your endpoints to create JSON schema definitions for each of them.
As @auderer already mentioned, you need validation on a route-by-route base, instead of purely relying on the type definition of the database models.
Let's take a look, what would happen if all the fields would be marked as required:
Read
Depending on where the schema validation happens, it can cause huge problems, if all the fields are marked as required (except the fields which have the attributes @id, @default or @updatedAt). Talking about GraphQL, the client is able to fetch only a subset of a specific model, which is required for a specific purpose. Talking about REST, you might create REST endpoints, which will only deliver a subset of the defined model to the client.
Update
Updating a model can happen in a lot of different ways. The client might send only a subset of data (patch, a partial update) or it has to update all of the fields at once (put operation). The Prisma model doesn't define this behaviour, but your programming code does. It's impossible to guess, whether all the fields are required or only a subset without analyzing your endpoints.
Create
Creating a new entry in your database requires all the field information for a model. But it doesn't mean, that all the defined model fields have to be sent by the client. Maybe some information is aggregated or fetched from a different source. This means, that the client might only send a subset of the needed information and the rest is calculated/aggregated/pulled from another source.
As you can see, it is not possible to just mark all the fields as required, because a couple of cases are not covered.
@ShivamJoker Nevertheless, if you have some smart ideas to tackle the mentioned issues, I would be happy to continue the discussion and maybe find a way of supporting your needed use case. Maybe you can start by describing your issue in detail with some examples to continue the discussion upon it.

I have to add additionalProperties to  the schema if i have extra properties, otherwise the prisma will give me a 5xx.
Mix prisma json schema with other keys is a not good idea.


Switch references to Interface

Fixes https://github.com/aspnet/Security/issues/181

Merged e2a8efbb64578602828336474d7083e5f7842702


Lowering the user list and chat pane by 1px so it matches the nav.

Before:

After:

which browser is this? in firefox it looks correct.

Oh, god dammit.
Move along here, nothing to see.


Semantic release

Moves to semantic release alongside some general tidy up.

:tada: This PR is included in version 1.1.0 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


Remove artifact implimentations (niecza, mildew, kp6)

Trying to resolve issue #235. One commit for each implementation removal as requested.  Tested against 'make spectest' on recent Rakudo and passed.

If I do not hear back with any issues, will apply soon after today's release.


Trying to launch the bot but nothing happens

I am trying to make the bot run, note that I am not very skilled with npm and node yet :)
I follow the instructions and try to run the bot with the help of the npm start command.
Here's the output I get :
F:\norrisbot>npm start

><EMAIL_ADDRESS>start F:\norrisbot
> node bin/bot.js

F:\norrisbot>

No error, but nothing happens either in the console or the slack general channel...
By the way I set up my BOT_API_KEY variable correctly (with the token.js method)

StackOverflow discussion of the same issue - possible path formatting problem on Windows?
http://stackoverflow.com/questions/36612467/trying-to-launch-my-node-js-program-with-npm-but-nothing-happens/36637596#36637596

@ibiza240 whether you tried to debug, using console.log, that where the program's flow is breaking. Try to print the message using console.log at every point. I followed this tutorial : https://scotch.io/tutorials/building-a-slack-bot-with-node-js-and-chuck-norris-super-powers
and it helped me alot to clear my doubts and concept regarding bot.

Hi Guys, sorry for the very late reply. I just updated Norribot to version 2.0 using the official slack bot app and bots Node.js sdk. This version should be more stable and reliable. I won't be supporting anymore the old version, so I am closing this issue.
Feel free to open a new one if you have some issue with the new version.


Open-state should be exposed as prop

In Flux/Redux apps, the state of components is externalized and injected via properties. What I would like to do is have flux events that mutate the contents of the skylight, then present it by setting the "open" state to true.

I don't think this should be too crazy. I'll submit a PR later