Dashboards need to be created for manager, employee, and customer profiles

The routes for these dashboards already exists, and the login redirect is already written (but commented out)
The customer dashboard needs to show all previous orders made by that customer (along with text when no previous orders are found). A customer should also be able to reorder a previous order from the dashboard, sending the page directly to /order with that order prefilled.
The employee dashboard should function as a order-queue screen, allowing employees to see all orders, along with a filter to see only the active ones. They should also be allowed to mark orders as complete.
The manager dashboard should also have the same qualities as the employee dashboard, but with an additional functionality to see the customers in the database.

Completed for now. Might revisit if professor increases scope (since employee and manager dashboards are the same).


URL encoding for autotune filters

The change in #578 to use ns-get instead of directly using curl broke the time based filters that autotune uses to limit its data download, because ns-get uses curl's -g flag.  This caused autotune in 0.5.3 dev to run extremely slowly (due to all the extra treatments) and to erroneously autotune with multiple days' worth of data each day.

Turns out removing -g does break things, so I URL-encoded the [ and ]'s as %5B and %5D in the autotune URLs instead.

This has been tested from cron and is ready to merge to dev if no objections.


Mojo::JSON doesn't produce the same output on repeated runs

There's no sort when it traverses the keys of a JSON document.
This means that if I want to tell if my output has changed, I have to serialize to a -different- format first that is canonical, then do the JSON encoding.
This also means I can't e.g. use a sha1 to generate an etag for caching, and upsets HTTP cache servers in general.
All 'fixing' this would require is changing 'keys' to 'sort keys' in _encode_object and I'd be happy to do that w/tests, but I'm wondering if there's a reason it hasn't already been done? (if there is a reason, I'm also happy to write a doc patch to make it explicit ... and if it's already in the docs, then my apologies for my reading comprehension sucking)

This has come up before (a few times actually), but so far it has not managed to get the required votes. https://github.com/kraih/mojo/pull/665

I'm still :-1: and I stand by my comments in #665.

For the record, i've tried replicating @daoswald's results from 2014, and have not been able to. https://github.com/kraih/mojo/pull/665#issuecomment-51255616

I've just tried as well, and can't find any significant impact from adding a sort, so I'm going to vote :+1:.

With this version i do see a small performance loss. https://gist.github.com/anonymous/fca9dd4d0f766b6d653d

So, (1) being able to use 'eq' in tests rather than is_deeply is really nice sometimes, (2) it's much easier for me to diff changes this way, and (3) "caching should depend on the input", well, yes, but while I can do that, there's a bunch of really easy caching tricks at middleware/http proxy/etc. layers that don't have the input and I'd like the option to use those as well. Also, if, for example, I'm building up a data structure from somewhere, being able to generate the etag by sha1-ing the content is often quicker overall than having to serialize it twice, once for etag generation and once for json.

I think really what I'm saying is "not sorting feels like a micro-optimisation that costs me more in usability than it's worth in performance". I'm fairly sure that the time I'd save from not having to deal with this would be sufficient to do an extra NYTProf run and therefore end up with a simpler and faster codebase in the end overall. The question then becomes whether that's true of everybody else, nobody else, or somewhere in between.

Guess i'm still neutral on this issue, while i can see sorting making everything more dwim, i also want that extra 1% performance.

Predictable and repeatable output is favourable if the overhead is negligible, and i have no doubt that this issue will just come up again and again. So :+1:

One more thing, this has the potential to be a breaking change for people using tied hashes (like Mango::BSON::Document) for a custom order. Not that i think it's common practice, but worth considering.

FWIW if you remove the unnecessary ops from sub _encode_object, to bring it more inline with sub _encode_array, and do the same with sub _encode_value then you get back most of performance lost by sorting the object keys:
diff --git a/lib/Mojo/JSON.pm b/lib/Mojo/JSON.pm
index df032ad..6eee6f0 100644
--- a/lib/Mojo/JSON.pm
+++ b/lib/Mojo/JSON.pm
@@ -211,10 +211,9 @@ sub _encode_array {
 }

 sub _encode_object {
-  my $object = shift;
-  my @pairs = map { _encode_string($_) . ':' . _encode_value($object->{$_}) }
-    keys %$object;
-  return '{' . join(',', @pairs) . '}';
+  '{' . join(
+    ',', map { _encode_string($_) . ':' . _encode_value($_[0]->{$_}) } keys %{$_[0]}
+   ) . '}';
 }

@@ -224,39 +223,37 @@ sub _encode_string {
 }

 sub _encode_value {
-  my $value = shift;
-
   # Reference
-  if (my $ref = ref $value) {
+  if (my $ref = ref $_[0]) {

     # Object
-    return _encode_object($value) if $ref eq 'HASH';
+    return _encode_object($_[0]) if $ref eq 'HASH';

     # Array
-    return _encode_array($value) if $ref eq 'ARRAY';
+    return _encode_array($_[0]) if $ref eq 'ARRAY';

     # True or false
-    return $$value ? 'true' : 'false' if $ref eq 'SCALAR';
-    return $value  ? 'true' : 'false' if $ref eq 'JSON::PP::Boolean';
+    return ${$_[0]} ? 'true' : 'false' if $ref eq 'SCALAR';
+    return $_[0]  ? 'true' : 'false' if $ref eq 'JSON::PP::Boolean';

     # Everything else
-    return _encode_string($value)
-      unless blessed $value && (my $sub = $value->can('TO_JSON'));
-    return _encode_value($value->$sub);
+    return _encode_string($_[0])
+      unless blessed $_[0] && (my $sub = $_[0]->can('TO_JSON'));
+    return _encode_value($_[0]->$sub);
   }

   # Null
-  return 'null' unless defined $value;
+  return 'null' unless defined $_[0];

   # Number
   no warnings 'numeric';
-  return $value
-    if length((my $dummy = '') & $value)
-    && 0 + $value eq $value
-    && $value * 0 == 0;
+  return $_[0]
+    if length((my $dummy = '') & $_[0])
+    && 0 + $_[0] eq $_[0]
+    && $_[0] * 0 == 0;

   # String
-  return _encode_string($value);
+  return _encode_string($_[0]);
 }

 sub _throw {

Currently:
[leejohnson@lees-macbook-air J0 C10044 13:46:00 * master]
/Users/leejohnson/working/mojo > perl -Ilib sortdumbbench.pl
encode_json: Ran 1050 iterations (41 outliers).
encode_json: Rounded run time per iteration: 2.9237e-02 +/- 9.3e-05 (0.3%)

With above diff applied + sorting the keys:
[leejohnson@lees-macbook-air J0 C10043 13:44:52 * master]
/Users/leejohnson/working/mojo > perl -Ilib sortdumbbench.pl
encode_json: Ran 1050 iterations (42 outliers).
encode_json: Rounded run time per iteration: 2.936e-02 +/- 1.1e-04 (0.4%)

That's a difference of 0.4% on 0.03s, or 0.0001s. That's on a rather large JSON struct, on more typical JSON data it's going to be in the order of µs.
Benchmarking code:
#!perl

use strict;
use warnings;

use Mojo::JSON qw/decode_json encode_json/;
use Dumbbench;

my $json = join '', <DATA>;

our $structure = decode_json($json);
our $rv;

my $bench = Dumbbench->new(
  target_rel_precision => 0.5 / 100,
  initial_runs         => 1000,
);

$bench->add_instances(
  Dumbbench::Instance::PerlSub->new(
    name => 'encode_json',
    code => sub {
      $main::rv = encode_json($main::structure);
    }
  )
);

$bench->run;
$bench->report;

__DATA__
# same as in https://gist.github.com/anonymous/fca9dd4d0f766b6d653d

so, seems it's less than 1% at this point - @kraih looks like we have +2, -1, and a patch that (a) works (b) would let you add multi-key object tests to json.t (which I presume this issue is why there currently aren't any). Thoughts? (I'm not sure how the mojo process works here)

@shadowcat-mst So far all votes from members of the core team have been -1 or neutral, so i'm afraid it doesn't look like this will pass.

I thought @jberger had some input...

I think this is a solid idea, and I don't see significant downsides, so
I'm +1.
M
On Fri, Apr 1, 2016 at 9:46 PM Jan Henning Thorsen<EMAIL_ADDRESS>wrote:

I thought @jberger https://github.com/jberger had some input...
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
https://github.com/kraih/mojo/issues/941#issuecomment-204540726

I'm generally +1 as well, but I don't know what performance cost is worth the feature and don't know how to judge that. I have a use case at work where we get recurring messages from an external service. We would like to determine if they are the same data as the last stored message and only store it if it changes. This is rather similar to caching. Currently we also use one of the other JSON emitters which allows canonical representations. If Mojo::JSON could do this we would likely use it for this purpose as we do for the others, without it we would continue on as we are now.
I do wonder about the fact that (assuming it is correct) we don't have tests for emitting a JSON object with multiple keys. Accepting this feature or not it would probably be good to cover that. For me that might be enough to tip the scale.

Thanks, this proposal passed the vote. https://github.com/kraih/mojo/commit/5f47058d37534ab77398f9df620625a59283f809


Remove src/core/include/utils/defines.h

The macro defined in this header is not used anymore.

Removed a variable from BM_BigInt_ModInverse()  (benchmark/src/IntegerMath.cpp). The assembly code generated with or without using that variable was identical:
difference in IntegerMath.ii (source):
<         I(3017).ModInverse(I(108));
<
<

    I c = I(3017).ModInverse(I(108));
    (void)(c);

difference in IntegerMath.s (assembly code):
<       movq    %r12, %rdi
<       callq   __ZN9bigintdyn5ubintIjED1Ev
170a169,170

  movq    %r12, %rdi
  callq   __ZN9bigintdyn5ubintIjED1Ev

difference in IntegerMath.ii (source):
<         I(3017).ModInverse(I(108));
<
<

    I c = I(3017).ModInverse(I(108));
    (void)(c);

difference in IntegerMath.s (assembly code):
<       movq    %r12, %rdi
<       callq   __ZN9bigintdyn5ubintIjED1Ev

  movq    %r12, %rdi
  callq   __ZN9bigintdyn5ubintIjED1Ev

<         I(3017).ModInverse(I(108));
<
<

    I c = I(3017).ModInverse(I(108));
    (void)(c);


[MINOR][DOC] Update index type desc

Change Logs
Add Index type desc
Impact
Index type doc
Risk level (write none, low medium or high below)
NONE
Documentation Update
Describe any necessary documentation update if there is any new feature, config, or user-facing change

The config description must be updated if new configs are added or the default value of the configs are changed
Any new feature or user-facing change requires updating the Hudi website. Please create a Jira ticket, attach the
ticket number here and follow the instruction to make
changes to the website.

Contributor's checklist

[ ] Read through contributor's guide
[ ] Change Logs and Impact were stated clearly
[ ] Adequate tests were added if applicable
[ ] CI passed

Hi, I originally wanted to update the introduction related to indexing. After I finished writing it, I merged the remote git and found that someone had already updated it, and only some changes were merged. Regarding the advantages and disadvantages, could you please help me check if there are any errors?

@nfarah86 has been working on improving Indexing docs.  @nfarah86 do you want to review this PR?  cc @bhasudha

@bhasudha Hello, could you help me review this pr? Thx

Nice ping @nsivabalan ~


Introduce easy volume mounts for UDF/UDSource/UDSink

Problem Statement
Currently when a user wants to define a UDSource, couple of volumes are required to hold data like config map and secrets. An example is as below.
apiVersion: numaflow.numaproj.io/v1alpha1
kind: Pipeline
metadata:
  name: nats-source-e2e
spec:
  vertices:
    - name: in
      scale:
        min: 2
      volumes:
        - name: my-config-mount
          configMap:
            name: nats-config-map
        - name: my-secret-mount
          secret:
            secretName: nats-auth-fake-token
      source:
        udsource:
          container:
            image: quay.io/numaio/numaflow-source/nats-source-go:v0.5.0
            volumeMounts:
              - name: my-config-mount
                mountPath: /etc/config
              - name: my-secret-mount
                mountPath: /etc/secrets/nats-auth-fake-token
    - name: out
      sink:
        log: {}
  edges:
    - from: in
      to: out

The problem is that user needs to ensure the name of the volume and the corresponding name of volumeMount are exactly same. e.g. my-config-mount appears twice in the template above.
A better user experience would be to only specify volume mount name once. Something like below:
apiVersion: numaflow.numaproj.io/v1alpha1
kind: Pipeline
metadata:
  name: nats-source-e2e
spec:
  vertices:
    - name: in
      scale:
        min: 2
      udSourceVolumes:
        - name: my-config-mount
          mountPath: /etc/config
          configMap:
            name: nats-config-map
        - name: my-secret-mount
          mountPath: /etc/secrets/nats-auth-fake-token
          secret:
            secretName: nats-auth-fake-token
      source:
        udsource:
          container:
            image: quay.io/numaio/numaflow-source/nats-source-go:v0.5.0
    - name: out
      sink:
        log: {}
  edges:
    - from: in
      to: out

This applies to all UD artifacts.

Message from the maintainers:
If you wish to see this enhancement implemented please add a 👍 reaction to this issue! We often sort issues this way to know what to prioritize.

let's not call it udSourceVolumes, rather udVolumes and we can generalize and attach it anywhere.

Can we go with Kubernetes native Volume definition, and we default the mount path?

Can we go with Kubernetes native Volume definition, and we default the mount path?

yes, but we do not want to conflict with the top-level name (volumes vs. udvolumes), right?

Can we go with Kubernetes native Volume definition, and we default the mount path?

yes, but we do not want to conflict with the top-level name (volumes vs. udvolumes), right?

Correct. What I meant was, Use the native Volume struct for the slice, instead of building our own. The example yaml obviously is doing something with our own struct.

Correct. What I meant was, use the native Volume struct for the slice, instead of building our own. The example yaml obviously is doing something with our own struct.

absolutely

Can we go with Kubernetes native Volume definition, and we default the mount path?

Sry correct me is I am wrong. Why can we default the mount path? This is not for built-in source hence the platform is not supposed to know where the secrets are mounted.

For example, mount them to /var/numaflow/vols/{volume-name}?

For example, mount them to /var/numaflow/vols/{volume-name}?

This requires a mutual agreement between UDF/UDSource/UDSink and the platform.

For example, mount them to /var/numaflow/vols/{volume-name}?

This requires a mutual agreement between UDF/UDSource/UDSink and the platform.

What does it mean?


Flickr JSON doesn't load

Load the following URL in your browser...
http://api.flickr.com/services/feeds/photos_public.gne?id=49297289@N08&lang=en-us&format=json - this wraps the json response with a function called jsonFlickrFeed.
If I try to do...
window.jsonFlickrFeed = function(data) {
    console.log(data);
}

require(['async!http://api.flickr.com/services/feeds/photos_public.gne?id=49297289@N08&lang=en-us&format=json']);

...I get the data but I then get a timeout error Uncaught Error: Load timeout for modules: async!http://api.flickr.com/services/feeds/photos_public.gne?id=49297289@N08&lang=en-us&format=json
If I try a different URL format (e.g. just return plain JSON data)...
http://api.flickr.com/services/feeds/photos_public.gne?id=49297289@N08&lang=en-us&format=json&nojsoncallback=1
...then I get the error Uncaught SyntaxError: Unexpected token : (followed by the same timeout error above) as the browser considers the returned JSON data to be invalid. But yet if I run the returned data through a validator it passes?
Any ideas?
I noticed this on my own JSONP plugin (https://github.com/Integralist/RequireJs-Example/blob/master/Assets/Scripts/Plugins/jsonp.js) and then thought I would check yours to see if it had the same issues and it did.

ah! ok I understand now the whole section of your async plugin where you're formatting the URL before loading the resource. Yes what you suggested fixed the problem.


README: update examples

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.


[stdlib] Tag a handful of additional issues with FIXME(ABI)

Most were already in as FIXMEs associated with radars but weren't tagged as ABI-impacting.

@swift-ci Please smoke test

Have you tested to see if any of these radars are fixed already? We fixed a bunch of generics. Ugh recently (but far from all of course)

Autocomplete fail -- bugs not ugh -- but I guess that works too :-)

The ones that look like they're fixed I'm fixing in separate PRs (though looks like I screwed up my branching so one of those has made it onto this PR, oops...)

@swift-ci Please smoke test


Add list_deployed_models to inference client

Add list_deployed_models to HuggingFace🤗 Hub
References https://github.com/huggingface/huggingface_hub/issues/1557
Key Features

Modifies _client.py to add list_deployed_models functionality. Provides a list of model_id with the framework for a list of tasks provided.

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint.


Windows wamr build error

The following error occurs when building Wamr for Windows:
CMake Error at CMakeLists.txt:573 (message):
perf support is available on Linux only.
When I change line 71 of file ...build-scripts\build_llvm.py into
-DLLVM_USE_PERF:BOOL=OFF",
it will circumvent the error

@louisvangeldrop I tried to fix it in PR #2868.

THX for the fix. It works now


Does or should "join" clause in Query class support "select" statement?

Hi,
I am trying to implement such query using Query class.
select * from some_table
join (select id as fid, max(seq) as fseq from some_table group by some_value) as f
on id = fid and seq = fseq

I have code like:
let filterQuery = myTable.select(
  "id as fid",
  "max(seq) as fseq"
).group(someField).alias("f")
let onExp = Expression<Bool>(literal: "id = fid and seq = fseq")
let mainQuery = myTable.join(filterQuery, on: onExp)

But seems the joinClause function only takes the tableName and alias. The query becomes
select * from some_table
join some_table as f
on id = fid and seq = fseq

Should it expand the whole select statement here? Or is there other api I can use for this?
Thanks.

Do you need the sub-select? For the GROUP BY clause I suppose? This is on the TODO list, but isn't quite supported yet. You can, however, avoid the literal Expression<Bool>(literal: "id = fid and seq = fseq"):
let filterQuery = myTable.alias("f")
let mainQuery = myTable
    .select(myTable[id], max(filterQuery[seq])
    .join(filterQuery, on: myTable[id] == filterQuery[id] && myTable[seq] == filterQuery[seq])

I'll try to sneak sub-SELECT support into a commit soon.

Yes, I need sub-select, but for "join" clause, not "group by" clause.
Glad to know this feature will be here. For now I think I can change query to avoid this problem.
Thanks a lot.

This should now be possible:
let fid = id.alias("fid")
let fseq = max(seq).alias("fseq")
let filterQuery = myTable.select(fid, fseq).group(someField)
let mainQuery = myTable.join(filterQuery, on: id == fid && seq == fseq)

Awesome!!! Thank you so much for making this.

I think this might be broken.
I have the following code:
let innerQuery = messageTable.group(messageConstants.roomId)
let outerQuery = roomTable.join(.leftOuter, innerQuery, on: roomConstants.id == messageConstants.roomId)
            .order(messageConstants.date.desc)

Inner's query .asSQL() returns the following:
"SELECT * FROM \"Message\" GROUP BY \"roomId\""
But outerQuery returns this:
"SELECT * FROM \"Room\" LEFT OUTER JOIN \"Message\" ON (\"Room.id\" = \"roomId\")"
Ignoring the GROUP BY clause of the inner query.
This is the current code in SQLite.swift that generates the join clause (it seems to be ignoring everything in query except for the table name)
    fileprivate var joinClause: Expressible? {
        guard !clauses.join.isEmpty else {
            return nil
        }

        return " ".join(clauses.join.map { type, query, condition in
            " ".join([
                Expression<Void>(literal: "\(type.rawValue) JOIN"),
                query.tableName(alias: true),
                Expression<Void>(literal: "ON"),
                condition
            ])
        })
    }

I think this might be broken.
I have the following code:
let innerQuery = messageTable.group(messageConstants.roomId)
let outerQuery = roomTable.join(.leftOuter, innerQuery, on: roomConstants.id == messageConstants.roomId)
            .order(messageConstants.date.desc)

Inner's query .asSQL() returns the following:
"SELECT * FROM \"Message\" GROUP BY \"roomId\""
But outerQuery returns this:
"SELECT * FROM \"Room\" LEFT OUTER JOIN \"Message\" ON (\"Room.id\" = \"roomId\")"
Ignoring the GROUP BY clause of the inner query.
This is the current code in SQLite.swift that generates the join clause (it seems to be ignoring everything in query except for the table name)
    fileprivate var joinClause: Expressible? {
        guard !clauses.join.isEmpty else {
            return nil
        }

        return " ".join(clauses.join.map { type, query, condition in
            " ".join([
                Expression<Void>(literal: "\(type.rawValue) JOIN"),
                query.tableName(alias: true),
                Expression<Void>(literal: "ON"),
                condition
            ])
        })
    }

What if I want data from both of the tables?


Move GoPublisher into its own file

Refactor GoPublisher to its own .go file and update govec.go accordingly.

done.


Change History showing change for a Localised text field without making any change.

WE have a field Desc in our DB entity for a Rule. It is having the Localised annotation to support multiple languages. When logged in with English language, the field DESC on the UI shows the default value(in current example, English text). When logged in with a language for which we have a translated text available, the UI shows the corresponding text in DESC. When logged in with a. language for which no translation is available, the default text is displayed.
Now, if we go to the EDIT mode of a RULE, and do not make any change, still the DESC field is captured as changed.
PFA the recording for the behaviour.
https://github.com/user-attachments/assets/1709571f-3ec9-4c6c-b5af-5259f06ead28

Hello @navdmad
the change-tracking plugin works as intended.
In the video, we can see that the texts in the UI actually change, when you go in Edit-Mode, so we capture these changes, too. This is probably an issue with your UI, either draft handling, or Fiori-Annotations etc.
Please check whether these texts also change, when you do not enable the Change-Tracking plugin, to confirm.
Best,
Nick


No parser was explicitly specified

/usr/local/lib/python3.4/dist-packages/bs4/init.py:166: UserWarning: No parser was explicitly specified, so I'm using the best available HTML parser for this system ("lxml"). This usually isn't a problem, but if you run this code on another system, or in a different virtual environment, it may use a different parser and behave differently.
To get rid of this warning, change this:
BeautifulSoup([your markup])
to this:
BeautifulSoup([your markup], "lxml")
markup_type=markup_type))
Need to use add_soup method or what?

Need to use:
browser = mechanicalsoup.Browser(parser='html.parser')
or
browser = mechanicalsoup.Browser(parser='lxml')

Ah presumably the warning was added by a recent version of BeautifulSoup. It's not obvious what parser MechanicalSoup should default to. Your workaround looks good to me.

when i try to use
        browser = mechanicalsoup.Browser(parser = "lxml")

i get the following error message:
TypeError: __init__() got an unexpected keyword argument 'parser'

I also cant find the keyword parser in the constructor for the mechanicalsoup browser, so why would this work?

@lawli3t maybe you're using an old version. Try simply mechanicalsoup.Browser()

Error is still present, from both ArchLinux's packaged version and pip3 version.

You're right. Let me take a look.

The easy fix for this is to use the parameter soup_config:
mechanicalsoup.Browser(soup_config={"features":"lxml"})

wernersa's solution works for me (while stdex'es fails with a TypeError). I'd expect html.parser to be used by default and/or a more obvious parameter to specify the expected parser.

It's just because the __init__() in
browser.py
doesn't have the parser argument. Instead, there is a argument soup_config should be settled up.
By the way, seems the 'lxml' are not supported in recently change check this issue
I think this issue can be closed.

Got the same issue even after setting:
soup_config={'features': 'html.parser'}

It'd also be good to default to a sensible value.

Voila! https://pypi.python.org/pypi/MechanicalSoup/0.5.0
Sorry for the lack of attention to this project—I'm getting married next year =)


Theoretically possible to test without packaging?

Thanks for sharing your hard work! Is there any chance in the future that tests will be able to be run without first packaging the application?

I'm looking for this as well

@achtan theoretically yes, but if you need transpilation then no: https://github.com/microsoft/playwright/issues/19854#issuecomment-1375407099

It should be possible now to do Playwright testing without packaging the Electron application. This repository is just an example… and to be honest, most of the work has moved to the electron-playwright-helpers repository. But you would just launch the Electron app by following the normal Playwright Electron instructions. Then you could use the electron-playwright-helpers functions for IPC, menu interactions, and (new feature!) Dialog stubbing.

@jjeff thanks for the great work. Can you please elaborate more on this? I'm not really familiar with electron nor playwright. Thanks

In Electron, you can run your application with a script (usually npm start) that will run the original source without packaging it into an application of its own. It runs using the Electron executable which lives in your node_modules folder. However, if you are using electron-forge or electron-builder, you can build (aka "package") a freestanding application (and installers, .zip, .dmg, .etc).
Playwright's Electron functionality defaults to testing the unpackaged application. This repository and the electron-playwright-helpers library have functionality to help you to test a packaged, free-standing Electron application, more closely resembling the version that you will distribute to your end-users. The challenge of testing a packaged Electron app is discerning its component parts (executable, main javascript file, package.json, etc) in order to tell Playwright how to launch your app.
But if you're testing your unpackaged application, you can simply follow Playwright's example in their documentation. That's a good way to start.

Hi @jjeff  - I have similar requirement with Playwright, where need to launch .exe file on windows machine running on OpenFin server and need to access menus which will take to chrome ( chromium shell ).
Will the implementation be similar as above ?
Kindly suggest.

The helper functions in this package should work the same in either a packaged app or an unpackaged one. So you should be able to test menus, ipc functionality, etc, using these functions.
I don't know much about OpenFin and the configuration of Chromium that you're talking about. But if you're not loading Electron, you won't be able to test Electron's menus. Playwright should handle loading/running Electron though -- all of that is outside of the scope of this repository though.

Thanks @jjeff . I haven't received the Openfin config yet. I will test it out with electron-playwright-helpers and reach out for help.
This repo has given me idea on how the approach could be taken ahead. Thanks much for this contribution.

I have tried with the example.  App gets launched but electron.launch doesn't come out of the process and throws timeout error. Can you please help on this?


Fix link to rasterizer-ordered views

The link that was supposed to lead to rasterizer-ordered views page was pointing to volume tiled resources page instead. Now it points to the correct page

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


New package: Misc v1.0.0

Registering package: Misc
Repository: https://github.com/xuestrange/Misc.jl
Created by: @xuestrange
Version: v1.0.0
Commit: 94efccb285404969ff790210aa18e518ebc308f7
Reviewed by: @xuestrange
Reference: https://github.com/xuestrange/Misc.jl/issues/1#issuecomment-2142751381

the package content doesn't look like it would be useful for general Julia user, and the package name is too generic

Yeah, Misc is not a possible package name, apart from the fact that “personal utility packages” should not be registered in the General registry.


Fix GetTensorShape() TF_GraphGetTensorShape should not use ref for []

Hey Miguel, please check if this fix is looks right. If this is correct I expect there are other places where the ref [] pattern needs to be fixed (I just did the one causing SampleTest to fail). btw I also wondered if these pointers should be handled as unsafe but the post below says no...
UPDATE  I just noticed that the unsafe declaration is in the DllImport (static extern unsafe void TF_GraphGetTensorShape...) so yeah, I think this is the correct fix. Certainly the old code which passed a ref to the array won't work as the C code would have to allocate and return a C# managed object. Also this works :)
This fixes a memory violation running SampleTest, for extern C arrays are passed directly, not via ref which requires C to create a managed object.
http://stackoverflow.com/questions/741206/using-arrays-and-pointers-in-c-sharp-with-c-dll

I did not see that crash, but the change looks fine, I made this change and another similar signature.


How to deal with unused-expressions

Node.js is full of unused expressions.
For example, If I call setHeader on a ClientRequest I have a non-useful return.
There are things like Eff or Io to model side-effects; Is the best approach to disable eslint checking for unused expressions inside these monads?

Hi @jgrund!
You are right that Node.js has plenty of APIs that "kind of" makes use of unused expressions, and that's because Node, or JavaScript for that matter, was not made to be a full-fledged FP language / ecosystem.
You can't for instance use FP techniques with tools like express out of the box, but you're right that you can remove the side-effects by using Monads.
I haven't used them as much as I would have liked to (and never used Io or Eff), so take the rest of my comment with a grain of salt.
I think the approach you described is a very good one, if I understood you correctly: Create a new Monad type that wraps your HTTP requests tool and make its API stateless just like you'd expect from other monads.
In its implementation, you can then disable the ESLint rules that create errors. As long as you avoid things that would make your API not stateless and side-effectful, you are good to go. You are simply relocating your side-effectful code to a part where it is controlled and outside of your pure logic, and that's :+1:.
Let me know if my answer was not clear, or if I misunderstood you :)

Yup, that was it; thanks :)

One other thing of note, I wonder if using something like Unit from PureScript might be a good idea in tandem with this.

I have never tried PureScript, but if you go ahead and try it and it works nicely, let me know :)

I'm not a fp expert, really far from it, I only grasp the very basics, but how should we handle basic cases like console.log ?
To wrap values in a monad/container/wtv seems to be a bit overkill, but then again, I might be missing something really basic due to my inexperience.


[Feature request] Publish an MSI installer or a version that isn't an .msixbundle

Is your feature request related to a problem? Please describe.
I'm always frustrated when i'm forced to have the Windows Store installed to install a basic windows application
Describe the solution you'd like
Could you please create an MSI Installer, or some sort of executable that doesn't depend on the Windows store
Describe alternatives you've considered
N/A
Additional context
A lot of people don't have the Windows Store installed or can't install it due to their operating system

I totally understand your pain here. Notepads right now is a full-blown UWP app which requires Store to function. The "Store" is not only the app store that you are seeing, it also comes with a bundle of binaries and DLLs which used by all UWP apps. We have to wait for WinUI 3 to be ready before migrating to the new Windows App model where we can have full access to do whatever we want.

From my experience it doesn't strictly require MS Store, just having the App Installer (winget) is enough since it'll install the dependencies.
However having at least a portable zip option would be great.
Windows Terminal has it
https://github.com/microsoft/terminal/releases


Remove unused hast-util-raw dependency

Initial checklist

[x] I read the support docs
[x] I read the contributing guide
[x] I agree to follow the code of conduct
[x] I searched issues and couldn’t find anything (or linked relevant results below)
[x] If applicable, I’ve added docs and tests

Description of changes
Remove hast-util-raw as it's not used in the published files. It's only used in test/raw.js for ambient types, but I found from https://github.com/syntax-tree/hast-util-raw?tab=readme-ov-file#types and https://github.com/syntax-tree/mdast-util-to-hast?tab=readme-ov-file#types that the types should be sourced from mdast-util-to-hast, so I switched to that instead and hast-util-raw is no longer used anywhere else.

There wasn’t really a place where “raw” was coming from, so it used to be defined in both places.
That’s now cleaned, as you noticed from the docs, they’re in mdast-util-to-hast.

9.0.2, thanks!


Replace precomputed providers used to determine injection point

resolves #1078

@AbdellaToronto Can you review this one? It's pretty straight forward. Something was removed that shouldn't have been and silently broke something else.

@AbdellaToronto or @riavalon Please review.

@JinSY Please review.

@igor-ka Please review.

@igor-ka Rebased

Can we have a release with this? That would be appreciated.

@charpeni Release will happen today. Thanks.


Mask more than 1 character not working.

Hi.
Every mask more than one character is not working. But If I copy/paste I can edit the value.
Any clue what could be the cause ?

Going to need more information to help you out or even a plunk that shows the issue.


SUSE OS installation was failing when the node has too many Ethernet …

…ports.
We added a wait statement to give a chance for the ports to initialize

@RackHD/corecommitters @uppalk1 @geoff-reid @keedya @amymullins

BUILD on-http #2715 : FAILURE

** BUILD build-config-setup  #135388: SUCCESS
** BUILD unit-tests  #9783: SUCCESS
** BUILD smoke-test  #3626: FAILURE

test this please


Google2Client (OAuth): Not getting email addresses

I am using pac4j-oauth to allow Facebook and Google Authentication. Facebook is working just fine and Google as well, but there's one thing that bothers me: I don't get the user email, even though it is requested.
Here's my code:
  final Google2Client gClient = new Google2Client("KEY", "SECRET");
  gClient.setScope(Google2Client.Google2Scope.EMAIL); // also tried EMAIL_AND_PROFILE

then I see this in the logs:
root 2015-12-02 16:55:23,223 (DEBUG) [XNIO-1 I/O-2] : response code : 200 / response body : {
root  "kind": "plus#person",
root  "etag": "\"REDACTED\"",
root  "gender": "male",
root  "emails": [
root   {
root    "value": "REDACTED",
root    "type": "account"
root   }
root  ],
root  "objectType": "person",
root  "id": "REDACTED",
root  "displayName": "REDACTED",
root  "name": {
root   "familyName": "REDACTED",
root   "givenName": "REDACTED"
root  },
root  "url": "REDACTED",
root  "image": {
root   "url": "REDACTED",
root   "isDefault": false
root  },
root  "isPlusUser": true,
root  "language": "de",
root  "circledByCount": 6,
root  "verified": false,
root  "domain": "REDACTED"
root }

so the email is present as part of the emails array, but a few lines below:
root 2015-12-02 16:55:23,501 (DEBUG) [XNIO-1 I/O-2] : converted to => key : gender / value : MALE / class org.pac4j.core.profile.Gender
root 2015-12-02 16:55:23,501 (DEBUG) [XNIO-1 I/O-2] : converted to => key : displayName / value : REDACTED / class java.lang.String
root 2015-12-02 16:55:23,502 (DEBUG) [XNIO-1 I/O-2] : converted to => key : name.givenName / value : REDACTED / class java.lang.String
root 2015-12-02 16:55:23,503 (DEBUG) [XNIO-1 I/O-2] : converted to => key : name.familyName / value : REDACTED / class java.lang.String
root 2015-12-02 16:55:23,503 (DEBUG) [XNIO-1 I/O-2] : converted to => key : url / value : REDACTED / class java.lang.String
root 2015-12-02 16:55:23,504 (DEBUG) [XNIO-1 I/O-2] : converted to => key : image.url / value : REDACTED / class java.lang.String
root 2015-12-02 16:55:23,504 (DEBUG) [XNIO-1 I/O-2] : converted to => key : language / value : de / class java.util.Locale
root 2015-12-02 16:55:23,508 (DEBUG) [XNIO-1 I/O-2] : converted to => key : emails / value :  / class org.pac4j.oauth.profile.JsonList

Note the empty "value: " part when it converts the emails field.
This seems like a problem with pac4j-oauth somehow, but I'm not sure.
Any help is much appreciated - and if it should turn out to be a problem within pac4j-oauth, I'm grateful for any pointers on how to contribute a fix!

The output (empty value) might be tricky as the configuration is done by default not to save the JSON raw value. Can you retest using ProfileHelper.setKeepRawData(true) and check the output? Thanks

Thank you @leleuj for your super quick response!
So with your suggestion I am seeing this:
root 2015-12-02 17:19:45,519 (DEBUG) [XNIO-1 I/O-1] : converted to => key : emails / value : [{"value":"naumann@archilogic.com","type":"account"}] / class org.pac4j.oauth.profile.JsonList

but still the call for:
StorageHelper.getProfile(exchange).getProfile();

returns
<CommonProfile> | id: REDACTED | attributes: {access_token=REDACTED, name.familyName=REDACTED, displayName=REDACTED, name.givenName=REDACTED, image.url=REDACTED, url=REDACTED} | roles: [] | permissions: [] | isRemembered: false |

I wonder right now if it's rather a problem in pac4j-undertow as the log suggests that pac4j-oauth gets the value right or am I misreading something?

And you don't have anything returned by profile.getEmail()?

Ah wait, no. That's a different problem and that's specific to our application.
I put it into the undertow-pac4j-demo and it works. It just didn't show up when the profile was stringified...
So this was a false alarm but you've been a huge help to me identifying the issue - thank you so much and again my apologies for taking your time!

No problem. You're welcome.


need iot service in path

Without this change, wrp Source property is incomplete (current: [baseSource]/ vs. desired: [baseSource]/iot)

Codecov Report

Merging #65 into master will not change coverage.
The diff coverage is 100%.

@@           Coverage Diff           @@
##           master      #65   +/-   ##
=======================================
  Coverage   76.08%   76.08%
=======================================
  Files           6        6
  Lines         552      552
=======================================
  Hits          420      420
  Misses        124      124
  Partials        8        8

Impacted Files
Coverage Δ

src/tr1d1um/tr1d1um.go
34.39% <100%> (ø)
: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 7095b97...2eeb9f3. Read the comment docs.


Missing user warning

Add a warning during puppet run if user specified in cron::d is missing. Configurable with a toggle, can be switched off in hiera, defaults to true.

Sorry, you can't do this for 2 reasons:

A user may not be defined in the first place (root? nobody?) they just come from the system
A user may be defined (parsed) after the cron  is included

cron:d { 'bla':
  user => 'bar',
}

user { 'bar': }

will fail because it wasn't defined at the time.
Imo defined() should probably never be used to (try to) reference things outside a modules' own scope.

Argh. Closing


MYSQL_OPT_RECONNECT is deprecated in MySQL 8.0.34.

The MySQL client library currently supports performing an automatic reconnection to the server if it finds that the connection is down and an application attempts to send a statement to the server to be executed. Now, this feature is deprecated and subject to removal in a future release of MySQL.
The related MYSQL_OPT_RECONNECT option is still available but it is also deprecated. C API functions mysql_get_option() and mysql_options() now write a deprecation warning to the standard error output when an application specifies MYSQL_OPT_RECONNECT. (WL #15766)
https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-34.html#mysqld-8-0-34-deprecation-removal
https://dev.mysql.com/doc/relnotes/mysql/8.1/en/news-8-1-0.html#mysqld-8-1-0-deprecation-removal
Similar to issue in DBD-mysql: https://github.com/perl5-dbi/DBD-mysql/issues/354

It looks like it's been since MYSQL_VERSION_ID >= 50013 that the automatic reconnection behaviour has been in place. I could imagine since then that there's new code in APR that isn't prepared to handle error returns from the client library that say "disconnected, retry manually" or however the library is going to work in the future. (At least, I assume it'll work like it did in the past. That might be a very poor assumption.)
Is the responsibility for these forthcoming new errors going to be on APR or on APR's users? Do those changes need to happen ASAP with this flag being removed?
Thanks

Reconnect is MySQL specific option not affecting functionality of any other code in APR whether enabled or disabled. Apache dbd and authn_dbd modules that use APR correctly identified lost connection with this patch and showed/logged error. The connection was restored on next request when MySQL was available again.
As other database drivers in APR (e.g. oracle/postgresql) do not support reconnect, there should not be programs using APR relying on option available only on one database driver.

Awesome, thanks!


refactor(cfg): use IndexVec for storing basic blocks

Use an IndexVec when storing basic blocks. This makes the link between nodes in .graph and elements of .basic_blocks more clear. I had to rename BasicBlockId to BlockNodeId to avoid a name collision. I wasn't sure what else to name the Idx type for the basic blocks vec.

[!WARNING]
This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

#6323  👈
#6322
#6321
#6320
#6319
main

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

Join @DonIsaac and the rest of your teammates on  Graphite

3 things:
Why is BlockNodeId a better name than BasicBlockId? I don't know much about CFGs, but isn't "basic block" a term that's usual with CFGs?
If you are making that change, it'd be much easier to review a PR like this if the unimportant change - renaming the type - was a separate PR, so that the substantive change stands out. It's quite hard to wade through the diff in a PR like this, and figure out what's going on.
It's really helpful if you can put some description on PRs. It's doesn't need to be an essay, but just something short indicating the purpose of/motivation for the change, and any salient points about the implementation. The code usually is self-explanatory concerning the "what", but it often doesn't give you the "why".

@overlookmotel thanks for the feedback. I've added a description, and it should answer your question.


WinForms: improve the designer experience for .NET Framework apps

SkiaSharp can't load in the designer view of .NET Framework WinForms apps. The control appears in the toolbox, but drag-dropping it onto the window causes a spectacularly confusing error (screenshot below).
The presently recommended workaround is to add a FormsPlot programmatically (https://scottplot.net/faq/add-winforms-programmatically/) but some users may find this confusing (e.g., #4312)
This issue will track using preprocessor directives to create a version of FormsPlot specifically for .NET Framework projects that does not use SkiaSharp and will not crash in this way, but that will replace itself at runtime with a regular FormsPlot containing the SkiaSharp surface.

Oof, I'm having a rough time. Lots of time the control doesn't even show up in the Toolbox.
I'm concluding that the Visual Studio experience with SkiaSharp controls in a .NET Framework apps is just lacking, and there's not a lot I can do to make it better on my end.
I think the best strategy to overcome this remains for the user to place a Panel then programmatically create a FormsPlot and place it inside, as described by https://scottplot.net/faq/add-winforms-programmatically/


MIREOT 'sample size' from STATO

Add 'sampleSize' as its UAL, once MIREOT'd.

I imagine this means we'll also want to delete the class with rdfs:label 'σ'.

Not sure.  Depends on what was meant by sigma.
On Thu, Aug 18, 2016 at 1:21 PM, dillerm<EMAIL_ADDRESS>wrote:

I imagine this means we'll also want to delete the class with rdfs:label
'σ'.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/ApolloDev/apollo-sv/issues/44#issuecomment-240794075,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ABMe9tvuaOI8FtCjZtqhfAuaoU1-Nh0Cks5qhJS0gaJpZM4JihEy
.


Email 198 performance in image html email

There are several fixes and improvements to the regex's here:

The regex could run with exponential time in the \\s*[^>]*?\\s+ part, this is because the \s, [^>], and \\s+ parts can all match whitespace and so when excessive whitespace is encountered it will attempt all combinations to find a match. This is a fairly well documented phenomenon https://blog.codinghorror.com/regex-performance/
The <script> tag matching did not match multiple scripts.
Fix the edge case where tags could match which started with img or script e.g. <imgx ...>
Use a greedy matcher for the src url [^\"']+ which gives a slight performance boost - we will always want to grab the whole url.

One question is should I also update the similar class in the javax package?
Benchmark results
VM version: JDK 17.0.10, OpenJDK 64-Bit Server VM, 17.0.10+8-b1207.12
Result for old regex (<[Ii][Mm][Gg]\s*[^>]*?\s+[Ss][Rr][Cc]\s*=\s*["'])([^"']+?)(["'])
32.339 ±(99.9%) 4.394 ops/s [Average]
(min, avg, max) = (20.590, 32.339, 40.601), stdev = 5.866
CI (99.9%): [27.945, 36.733] (assumes normal distribution)
Result for new regex - candidate non greedy url (<[Ii][Mm][Gg](?=\s)[^>]*?\s[Ss][Rr][Cc]\s*=\s*["'])([^"']+?)(["'])
1244.602 ±(99.9%) 225.819 ops/s [Average]
(min, avg, max) = (518.410, 1244.602, 1512.089), stdev = 301.462
CI (99.9%): [1018.783, 1470.420] (assumes normal distribution)
Result for new regex (<[Ii][Mm][Gg](?=\s)[^>]*?\s[Ss][Rr][Cc]\s*=\s*["'])([^"']+)(["'])
1480.002 ±(99.9%) 160.408 ops/s [Average]
(min, avg, max) = (986.366, 1480.002, 1651.095), stdev = 214.140
CI (99.9%): [1319.594, 1640.409] (assumes normal distribution)

Hello @seanfabs
I can't reproduce these results unless a benchmark run executes tests with old and new code. You can usually do this by copying old code into a benchmark test method so that you have two methods: One tests the new patched main code and the old runs the old code now living in the benchmark; in this case, it's not much code since these are REs. Please rebase on git master to pick up the new Maven I added to facilitate running benchmarks from the command line like mvn -P benchmark -Dbenchmark=ImageHtmlEmailBenchmark -pl commons-email2-jakarta.
TY!

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 76.71%. Comparing base (0bd7e34) to head (59a9c16).
Report is 140 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #239      +/-   ##
============================================
+ Coverage     74.34%   76.71%   +2.36%
- Complexity      353      635     +282
============================================
  Files            22       39      +17
  Lines          1072     1915     +843
  Branches        126      233     +107
============================================
+ Hits            797     1469     +672
- Misses          216      345     +129
- Partials         59      101      +42

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


pagespeed should have an option to add no-transform header

PageSpeed honors no-transform headers on origin resources, but it should be possible for sites to add no-transform headers to PageSpeed's generated resources, to avoid re-optimization of images.

#1005 would let us do that.  Closing as a special case.

@jeffkaufman I'm not sure I follow, how would https://github.com/pagespeed/mod_pagespeed/issues/1005 let sites add no-transform headers to PageSpeed's generated resources?

@jeffkaufman Wait, I think you meant ngx_pagespeed's issue 1005, https://github.com/pagespeed/ngx_pagespeed/issues/1005 - sorry!

Yes, sorry, https://github.com/pagespeed/ngx_pagespeed/issues/1005


an error for "steps_per_epoch = display_interval"

in main() function, there is a bug for display_interval parameter. It seems set wrongly in the main() funciton for train().
because in keras, steps_per_epoch doesn't mean it.
for i_e in range(num_iters):
for tag, generator in train_gen.items():
genfun = generator.get_batch_generator()
print('[%s]\t[Train:%s] ' % (time.strftime('%m-%d-%Y %H:%M:%S', time.localtime(time.time())), tag), end='')
history = model.fit_generator(
genfun,
steps_per_epoch = display_interval,
epochs = 1,
shuffle=False,
verbose = 0
) #callbacks=[eval_map])

@nanzhao is correct, it's a bug.


Config file reset to default (AUR version)

I will try to add app to blacklistedApps and change imageCachePath parameters, but... if i start daemon via systemd, config file parameters resets to default! If config file chmod-ed to 0440 permission, daemon failed at start.
greenclip v3.4 maked via AUR PKGBUILD tested on latest Manjaro.

Hello,
Greenclip rewrite the config file at startup everytime (it was to auto-update config between version) and fails if it cannot do it.
So sadly you can't chmod it to 0440 :x

Hello,
Greenclip rewrite the config file at startup everytime (it was to auto-update config between version) and fails if it cannot do it.
So sadly you can't chmod it to 0440 :x

Hmm... How do you configure the daemon then?

What's the point of having a config file if it's reset everytime the daemon is started? please fix this

Thanks for asking, it was to migrate the config file painlessly for users across greenclip versions.
Feel free to submit a PR to fix this

fixed in version 4.0