[EDI] Huge memory leak when parsing ~20MB EDI file

Hi, we found a huge memory leak on parsing the EDI file with a size of over 20Mb

EDI is a sample INVOIC type with millions of LIN items.
attaching SVG of export --memprofile of benchmark,
it allocates over 5GB memory for the single ~23MB EDI file

is there any alternative to rather than calling ingester.Parse() for the large files?

Thx for reporting the issue! A few things:

Unfortunately with other things at hand and holiday/vacation, will only get to sit down looking at it in depth in a couple days. Heads up.

It would be great we can have your schema and a sample EDI file that repros the problem. If you can zip them and send to  jf.tech.llc at gmail. Sanitize if any sensitive info is present.

Based on your description, a wild guess is there are millions of LIN segments underneath a segment you designate as is_target, thus omniparser has no choice but load/keep everything underneath that target segment in memory in case any xpath based queries might hit any of them. "Millions" of segments, and each might take a couple kB can easily lead to GBs of memory. Don't know what solution would be exactly: our current model of parsing EDI is assuming everything under is_target is potentially needed thus all in memory.

Meanwhile before we can dig deeper, any chance you don't need the full omniparser capability and just a simple EDI segment reader would suffice: https://github.com/jf-tech/omniparser/blob/master/doc/programmability.md#non-validating-edi-segment-reader ?

@jurabek we haven't received any repro info from you. Still want us to follow up on this?

Hi @jf-tech, it seems non-validating-edi-segment could work for us in case of parsing big EDI files, however, I was struggled to parse our line items with split segments into our current transformed Messages
just wondered, do you have some examples of parsing the whole LIN item using seg, err := r.Read() which contains multiple lines?

Again if you can attach/link/email an small sample that containing the LIN segments (with line breakers) so we can take a look.

Closed due to lack of activities. FYI @jurabek

Hi @jf-tech I emailed for the following email test invoice file

Opened given new activity.

A bunch of observations/experiments I did given your sample EDI and schema:

Below is the count of all the segments in the sample EDI:
$ cat ~/Downloads/omniparser-157/INVOIC_test.EDI | cut -c 1-3 | sort | uniq -c
1000 BGM
1000 CUX
3000 DTM
36832 FTX
173522 IMD
83639 LIN
48012 MOA
3041 NAD
44472 PIA
44472 PRI
83639 QTY
85344 RFF
47006 TAX
1 UNA
1 UNB
1000 UNH
1000 UNS
1000 UNT
1 UNZ

If my tally is correct, in the 16MB sample EDI, we have totally 650K+ segments, all of which are required (based on the
the instructions of your schema) to be loaded in memory at the same time. Note most of these segments do have
elements, on avg 3, let's say. In EDI IDR each
segment is constructed as an IDR node, each of its elements is also constructed as an IDR node, then the element
value another node. So all in all, we are (very roughly) constructing
650K * (1 /*seg itself*/ + 3 /*elements*/ + 3 /*element values*/) = 4,550K IDR nodes.

A quick run of of the code in cli mode to do the transform and tallied its consumption:
/usr/bin/time -l ./op transform -i ~/Downloads/omniparser-157/INVOIC_test.EDI -s ~Downloads/omniparser-157/invoice.json
        6.11 real        10.92 user         0.33 sys
<PHONE_NUMBER>  maximum resident set size
                   0  average shared memory size
                   0  average unshared data size
                   0  average unshared stack size
              127697  page reclaims
                   0  page faults
                   0  swaps
                   0  block input operations
                   0  block output operations
                   0  messages sent
                   0  messages received
                 675  signals received
                 136  voluntary context switches
                5797  involuntary context switches
<PHONE_NUMBER>38  instructions retired
<PHONE_NUMBER>9  cycles elapsed
<PHONE_NUMBER>  peak memory footprint          <<<<<<<<

So about 2GB consumed. So that's roughly (again, very roughly) 2G / 4,550K = 468 bytes for each node. Considering
the overhead of pointers, other stuff, plus the transformed in-memory map[interface{}]interface{} and resulting json
take memory as well, the each node consumption isn't too outrageous.

I inspected the invoice.json, some of its elements can be removed since they're not used:
$ diff ~/Downloads/omniparser-157/invoice.json ~/Downloads/invoice.json
62a63,67
>                                         "name": "freetext_function",
>                                         "index": 2,
>                                         "default": ""
>                                     },
>                                     {
67a73,84
>                                         "name": "freetext_reference_code",
>                                         "index": 3,
>                                         "component_index": 2,
>                                         "default": ""
>                                     },
>                                     {
>                                         "name": "freetext_reference_code_two",
>                                         "index": 3,
>                                         "component_index": 2,
>                                         "default": ""
>                                     },
>                                     {
134a152,186
>                                             },
>                                             {
>                                                 "name": "party_name",
>                                                 "index": 3,
>                                                 "default": ""
>                                             },
>                                             {
>                                                 "name": "party_name",
>                                                 "index": 3,
>                                                 "component_index": 1,
>                                                 "default": ""
>                                             },
>                                             {
>                                                 "name": "party_name",
>                                                 "index": 3,
>                                                 "component_index": 2,
>                                                 "default": ""
>                                             },
>                                             {
>                                                 "name": "party_name",
>                                                 "index": 3,
>                                                 "component_index": 3,
>                                                 "default": ""
>                                             },
>                                             {
>                                                 "name": "party_name",
>                                                 "index": 3,
>                                                 "component_index": 4,
>                                                 "default": ""
>                                             },
>                                             {
>                                                 "name": "party_name",
>                                                 "index": 3,
>                                                 "component_index": 5,
>                                                 "default": ""
229c281,296
<                                         "max": -1
---
>                                         "max": -1,
>                                         "elements": [
>                                             {
>                                                 "name": "line_item_identifier",
>                                                 "index": 1
>                                             },
>                                             {
>                                                 "name": "line_item_number",
>                                                 "index": 3
>                                             },
>                                             {
>                                                 "name": "line_item_type",
>                                                 "index": 3,
>                                                 "component_index": 2
>                                             }
>                                         ]
235a303,307
>                                                 "name": "product_identifier",
>                                                 "index": 1,
>                                                 "default": ""
>                                             },
>                                             {

That reduced a little memory consumption but not much.

LIN is indeed not used during transformation. However omniparser EDI parser does require full segment specification in order to validate all the min/max integrity thus it (LIN) currently must be included in the schema. I did a quick hack in omniparser EDI reader.go  to exclude LIN from being included into the full IDR tree (since it is not used). The resulting time -l gives a sizable reduction to<PHONE_NUMBER> total memory used, about 168MB reduction or 8%. Not good enough but it's something. I'll file a separate ticket to add a new attribute not_in_idr (or not_used, ignored, or similar names) for the EDI sgement decl. Default to false, but if it's true, the segment, while must be declared in order for validation to take place, will not be included into the IDR tree (neither will any of its child segments) to reduce memory footprint.

That brings me to the final point: while it is possible to redesign the IDR format to compact/compress things up a little bit (the current design of having one new IDR node for each element and one for each of the element values is to make xpath query feasible), but all in all, your situation is: you attempted to load a huge and highly complex hierarchical document in its entirety into memory. omniparser is designed to do parsing/transforming in a "streaming" fashion. While I don't understand fully your business requirements, I couldn't help but noticed: Instead of putting is_target=true on the root segment UNA, why not putting it on UNA/GRP0, which instantaneously reduces the max memory consumption by more than 1000 folds (since we have about 1000 instances of UNA/GRP0) to about 136MB. You can easily re-combined all those 1000 json blobs back to an array on your side of the code if you'd like to.

Thoughts?

@jurabek any more investigation/help you need at this point? Or I can close the ticket?

Closed due to lack of response.


Typo in T1060 Reference

There's a minor typo (an }) in the Cardinal RAT reference for T0160.

It looks like this was resolved. Closing the issue.


Rename connector API interface class and functions

Remove factory and adaptor keyword from connector API interface class
Renve unused files
Signed-off-by: Manoj Gopalakrishnan<EMAIL_ADDRESS>

Fix typo error in PR comments.


request: show custom data of selected element

similarly https://github.com/excalidraw/excalidraw/pull/6382

Not sure what's requested here, but since https://github.com/excalidraw/excalidraw/pull/6382 is being linked, I'm closing.
If the request was for something else, please comment and we'll reopen.


Task automation for the repo

The  instructions in the README are certainly very easy to follow at present, but I wanted to add some leverage there with a top level Make file --  and want to gauge interest/see if that's something people would be open to.
GNU make is great and all, but to avoid the pitfalls and complexity that can sometimes come with it, I'd like to do one of the following:

Create a top level Rust workspace so we can leverage cargo xtask (no extra dependencies, but would require the Rust toolchain more strongly -- e.g. we could update the documentation to run xtasks that run cmake underneath)

Use a more general task runner like just

My goals with this change are to add a little leverage to enable easier setup and ongoing usage for devs -- whether it's explicitly checking whether dependencies are downloaded, checking/printing versions of all involved tooling, orchestrating multi-language build targets, etc.

I agree that more automation for some of the core bootstrapping and development loop tasks would be great, yes!
At the same time, I'd be a bit wary of adding additional requirements that have to be met before anything else happens. Right now, that's just CMake and rustup, and arguably we could eliminate the latter if we wanted to.
One option to perhaps explore is whether CMake workflows get us sufficiently far: combined with presets, they would allow us to reduce the "clone the repo --> have tests passing" process to something like

install CMake and rustup
clone the repo
run cmake --workflow --preset test-debug

After these steps, we'd have a cmake-build-debug folder with a build that has passed tests.

At the same time, I'd be a bit wary of adding additional requirements that have to be met before anything else happens.

Yeah I definitely understand/agree with this -- one thing I want to note is that cargo xtask is actually not a separate tool -- it's a convention (and Cargo.toml config) rather than something you need to install!
So running an xtask looks like this:
cargo xtask deploy
``

> Right now, that's just CMake and rustup, and arguably we could eliminate the latter if we wanted to.

Ah did I miss this? When you say `rustup` do you mean *literally* `rustup` and not a-version-of-the-rust-toolchain?

Given the Rust bits, I was assuming we could depend on `cargo` being present/installed. If we can't then `cargo xtask` is certainly a new dep.

> One option to perhaps explore is whether [CMake workflows](https://cmake.org/cmake/help/latest/manual/cmake.1.html#workflow-mode) get us sufficiently far: combined with presets, they would allow us to reduce the "clone the repo --> have tests passing" process to something like

TIL about CMake workflows! I'm not so familiar with CMake but I guess the two no-dep choices are:

- CMake workflows
- `cargo xtask`

I like the `xtask` mostly because I'm more familiar with Rust than CMake, and since it's a fully general language we can make use of the Rust ecosystem (for better or worse, complexity wise!).

What do you think -- if CMake workflows looks more exciting I can take a stab at building it out to see how it would work, but IMO we could orchestrate CMake itself (and optionally even install it, if it's missing) from `xtask`.

At the same time, I'd be a bit wary of adding additional requirements that have to be met before anything else happens.

Yeah I definitely understand/agree with this -- one thing I want to note is that cargo xtask is actually not a separate tool -- it's a convention (and Cargo.toml config) rather than something you need to install!
So running an xtask looks like this:
cargo xtask deploy

Right now, that's just CMake and rustup, and arguably we could eliminate the latter if we wanted to.

Ah did I miss this? When you say rustup do you mean literally rustup and not a-version-of-the-rust-toolchain-is-installed?
Given the Rust bits, I was assuming we could depend on cargo being present/installed. If we can't then cargo xtask is certainly a new dep.

One option to perhaps explore is whether CMake workflows get us sufficiently far: combined with presets, they would allow us to reduce the "clone the repo --> have tests passing" process to something like

TIL about CMake workflows! I'm not so familiar with CMake but I guess the two no-dep choices are:

CMake workflows
cargo xtask

I like the xtask mostly because I'm more familiar with Rust than CMake, and since it's a fully general language we can make use of the Rust ecosystem (for better or worse, complexity wise!).
What do you think -- if CMake workflows looks more exciting I can take a stab at building it out to see how it would work, but IMO we could orchestrate CMake itself (and optionally even install it, if it's missing) from xtask.

Oh, I only now saw this. I've been maintaining a justfile for myself but maybe someone can find it useful too. I pushed it here:
https://github.com/bytecodealliance/StarlingMonkey/pull/180
just has pretty much become the standard nowadays. +1 from me :)

I think the combination of CMake and an optional Just file would work well.
With regards to introducing a new dependency - I would recommend we make Just entirely optional for convenience, and just note it at the end of the getting started what the sugars are.
I don't know enough about CMake workflows to make a judgement call, but overall I like the command recipe model combined with a caching task runner model and would favour Just over xtask and CMake workflows.

OK great it seems like we're all at least partially aligned on just moving forward, in an optional manner (with some mention in the README).
@tschneidereit how does that sound to you?
If so, we can review @andreiltd 's existing PR and then I've got some additions I'd like to make which I'll open a separate PR for (but we can close this issue at the very least!)


Feat : Add Top Rated Filters

Add some filters for the top rated screen with topics like genre , season .

Hey @Abhigyan103  assign this issue to me under JWOC


Bad result with provided model, "deeplab-resnet.pth"

Using the provided model deeplab-resnet.pth from google drive, I got the following result.

Test loss: 3.045851: 100%|██████████████████████████████████████████████████████████████████████| 363/363 [03:42<00:00,  2.06it/s]
Validation:
[numImages:  1449]
Acc:0.017332007782534742, Acc_class:0.0529151632597871, mIoU:0.002817205803557816, fwIoU: 0.0011586984138953578
Loss: 1105.644
I think this shouldn't be the expected result, can anybody tell me what's wrong?

Try new code please.


[DONE] Added 'ignore userhighlights' to userpopup

TODO: better way of determening when a button is changed, currently stateChanged gives a pulse when the userinfopopup opens (added stuff so it doesn't fuck up anything, but it could be done better) #617

It would be better if the checkbox was in indeterminate state when the username is matched by a regex but not by a non-regex.
Also showing a tooltip when hovering it which says that it gets matched by a regex would be good.


Use fake kubeconfig in addtomesh test

Fixes https://github.com/istio/istio/issues/16639

@howardjohn: The following test failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

e2e-bookInfoTests-envoyv2-v1alpha3-master
c922a08ba1b1ec4c58fc255a5c34dfb6e36b8b95
link
/test e2e-bookInfoTests-envoyv2-v1alpha3-master

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.

/retest

@esnible
https://github.com/istio/istio/blob/53691c3cea725e4a9ce76ab21efded032f1035fe/istioctl/cmd/root.go#L170-L182
is the problem. It happens after that code. Its about setting up the namespace it seems
I don't follow the code well since there's a bunch of globals and stuff so I didn't have time to find a better solution

I can reproduce this locally.  I am working on a non-hacky fix I will complete this weekend.

thanks!
On Sat, Aug 31, 2019, 7:56 AM Ed Snible<EMAIL_ADDRESS>wrote:

I can reproduce this locally. I am working on a non-hacky fix I will
complete this weekend.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/istio/istio/pull/16708?email_source=notifications&email_token=AAEYGXI6FETQOLSOZFH7Z6LQHKBBLA5CNFSM4ISPHMDKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD5TOJGA#issuecomment-526836888,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAEYGXPGJE6TSEXHEAR2PFDQHKBBLANCNFSM4ISPHMDA
.

@howardjohn @esnible I have the fix ready at https://github.com/istio/istio/pull/16745. Please help review. Thanks!

#16752


Clean up the README

Codecov Report

:exclamation: No coverage uploaded for pull request base (main@6858eed). Click here to learn what that means.
The diff coverage is n/a.

@@          Coverage Diff           @@
##             main      #3   +/-   ##
======================================
  Coverage        ?   50.0%
======================================
  Files           ?       1
  Lines           ?       6
  Branches        ?       0
======================================
  Hits            ?       3
  Misses          ?       3
  Partials        ?       0

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 6858eed...b97abb8. Read the comment docs.


Configure GraphQL scalar mapping

While GraphQL SDL doesn't yet support an expressive enough syntax for scalar value definitions, there is some mapping needed for custom scalars (e.g. DateTime in GraphQL SDL should map to string in TypeScript). This mapping is depending on the application's implementation and therefore needs to be configured in the graphqlgen.yml.
Here is a proposal for the configuration format:
scalars:
  DateTime: string

Additionally, we should extend the validation logic of graphqlgen (similar to how types <> models are validated) to always require a mapping for custom scalars.

Looks like this might land soon: https://github.com/facebook/graphql/pull/521

Is there any advice for what to do in the meantime? I'm not sure where to go next.
Does this mean my app has to serialize to / deserialize from string manually in the resolvers for now or is there some other workaround?

Given that this doesn't seem to have moved forward yet, as an interim measure I'm wondering how useful it would be to have options similar to apollo client:codegen's passthroughCustomScalars and customScalarsPrefix? In the case of TypeScript at least, it's then easy enough to declare a global type definition for the scalar type name (with the option of attaching the prefix to avoid clashes with other ambient names). This approach has worked successfully for me with the output of apollo client:codegen.


The grand totals are not correctly

The grand totals are not correctly considered when using different aggregate functions in different columns (sum, avg).
We use the Saiku-3.14 for Pentaho 7.1

Please, can you explain the steps how we can reproduce this? Did you use plain MDX query or only Saiku interface to build report? May be also can you create simple data set with demonstration of incorrect results?

We set the method for calculating the totals for the various measures http://joxi.net/KAgWnpeH4y58gA and http://joxi.net/LmGjRxJheOBawr, when constructing the report we see that these settings are ignored http://joxi.net/a2XO0pbf1jQP8m. Both measures are summarized.


Logging Encrypted Attributes Or Prevent Logging Under Conditions

Hello.
First of all, congrats on your work, I use this package (and others by you) in almost all my projects.
In a current project I am working on, I have 2 requirements.  One is that the data must be encrypted in the database and the other that it should log every change in the models.
So, I created a trait that encrypts/decrypts properties in the model
trait Encryptable
{
    public function getAttribute($key)
    {
        $value = parent::getAttribute($key);

        if (in_array($key, $this->encryptable)) {
            $value = decrypt($value);
        }

        return $value;
    }

    public function setAttribute($key, $value)
    {
        if (in_array($key, $this->encryptable)) {
            $value = encrypt($value);
        }

        return parent::setAttribute($key, $value);
    }
}

Next, I added the LogsActivity trait in my model and I realised I have 2 major issues.
The first is that the activity is saved with the encrypted values (this could be solved in the views I think) and the other is that, since the encryption is changed each time, even if no change is made to that data I still get an activity logged (because it compares encrypted values).
I tried to tackle this with the tapActivity function and I am stuck at the last step (preventing the activity from being saved if the properties are empty).
public function tapActivity(Activity $activity, string $eventName)
    {
        if (property_exists($this, 'encryptable'))
        {
            $properties = $activity->properties->toArray();
            $changes = $activity->changes()->toArray();

            foreach (Arr::get($changes, 'attributes') as $attribute_name => $attribute_value)
            {
                if (in_array($attribute_name, $this->encryptable)) {
                    $attribute_value = decrypt($attribute_value);

                    if (decrypt($changes['old'][$attribute_name]) == $attribute_value)
                    {
                        Arr::forget($properties, ['attributes.' . $attribute_name, 'old.' . $attribute_name]);
                    }
                }
            }

            $activity->properties = $activity->properties->merge(collect($properties));
        }
    }

What I want is to prevent the save if the activity has no properties.  Is this possible;

Hey,
thanks for the flowers.
I've added an unittest for your scenario and it passes #534 until I change the specific accessor/mutator into, your case, general ones.
I think that this is related to \Spatie\Activitylog\Traits\DetectsChanges::logChanges(). I will try to debug it deeper and find a way to also respect the general accessor/mutator.

So, I've fixed the logChanges() method to use the getter in general, The toArray() method doesn't call getters - this was the problem.

Wow! I only expected a pointer or a suggestion, not a complete solution.
It works and it solves both my issues.  Thank you very much for your efforts!
Kudos!

Ok, I would like to wait for review by @freekmurze of the last open PRs. I hope that he will have time tomorrow. Otherwise I will release it my own at monday.

I do not mind waiting for the release, I still have time until deployment.
Thank you again.

https://github.com/spatie/laravel-activitylog/releases/tag/3.6.0

Thanks for the pipeline idea. I read your comments and tried to solve it like you proposed.
About the test, I didin't know what to assert. I would have wanted to assert that it was encrypted, but don't know how. Will it work like I did? $this->assertNotEquals($article->name, $this->getLastActivity()->properties["attributes"]["name"]);.


Sort extracted strings by an address of the first cross-reference

Similarly to https://github.com/dfint/dfrus/issues/12

Done wia a3d6d3404533805cba358d0a3dbfbc8c21ad79c7


Feature suggestion - Add responsive display property to TabNav Link

Say I have a TabNav with 8 items:

Home
Tasks
(... some other things)
Account

but on low breakpoints I want to reduce the tabs to:

[Hamburger Icon]
Account

...making the hamburger icon tab trigger a dropdown containing Tasks and "some other things".
I could do this with the TabNav if TabNav items had the display property.
Does this make sense? If so are you able to add the display property to TabNav Link?
🙏

Actually I could probably do this by wrapping the items:
<RadixThemes.Flex
    display={{ initial: "none", md: "flex" }}
    asChild
  >
    <RadixThemes.TabNav.Link
      asChild
      active={pathname.startsWith("/home")}
    >

I was going to suggest your workaround, considering:

that this is not a hugely common scenario
that we want to keep the APIs lean
that we want to keep layout concerns to layout components

I think this is the right approach.

Looks cool!
The only thing I'd say that I would do differently would be to completely hide when TabNavRoot using (an asChild layout component like you do) and replace with a nav with the dropdown instead.
I understand you're probably trying to take advantage of "some" of the styling there already, but I don't think you end up with what you expect anyway, like making the trigger a tabnavlink doesn't make it navigable with the keyboard, etc

I understand you're probably trying to take advantage of "some" of the styling there already

yes in this example the mobile nav is really just using TabNav for the consistent bottom border, but perhaps better to swap the whole thing out.
I’m not sure tab items or tab nav items were designed to allow for a single icon as their children. I guess not. I have 3 different approaches here.
I could imagine still keeping one or two items on mobile, and putting the rest under the hamburger.
Definitely feels I’m doing a lot here that isn’t intentional usage though, so thanks for the tip re: keyboard access.


Expand cleanse function

if managing Zettelkasten using the backup and sync functions, the repo can get large.

[ ] Identify a better way to keep repo-size down
[ ] ensure that it works on low-end devices

xargs -P 0 where possible to use parallelisation?


UofT-DSI | SQL - Assignment 1

What changes are you trying to make? (e.g. Adding or removing code, refactoring existing code, adding reports)
Complete Assignment 1 by filling out design_a_logical_model.md file
What did you learn from the changes you have made?
Was there another approach you were thinking about making? If so, what approach(es) were you thinking of?
Were there any challenges? If so, what issue(s) did you face? How did you overcome it?
How were these changes tested?
A reference to a related issue in your repository (if applicable)
Checklist

[x] I can confirm that my changes are working as intended

Assignment marked.


catalog访问hive，use database或show tables太慢[Bug]

Search before asking

[X] I had searched in the issues and found no similar issues.

Version
2.0.5
What's Wrong?
通过catalog访问hive，执行use database或show tables时，doris都要重新去ranger拉取策略，并没有使用缓存，由于生产上面表和策略特别多，导致需要几分钟才能执行成功，甚至长时间无法执行成功
What You Expected?
是否有修改配置方法能够不用每次都拉取策略，还是代码就是设计的有问题
How to Reproduce?
No response
Anything Else?
No response
Are you willing to submit PR?

[X] Yes I am willing to submit a PR!

Code of Conduct

[X] I agree to follow this project's Code of Conduct

可以试一下 mysql -A
创建catlog 的时候将 metadata_refresh_interval_sec 调大试一试


Video or screenshots of Buttercup

As someone coming to the buttercup.pw website for the first time and thinking about trying it out, the website is a bit thin when it comes to conveying what the product does and doesn't do.
Would it be possible to add either some screenshots (beyond the one) or a video of it in use?
I think this would help potential users have confidence that buttercup did what they wanted to get them to install.

That's a great idea! Thanks @gene1wood


SubMenu onClick Event

Hello,
It's onClick event working with <MenuItem /> but not in <SubMenu />
In SubMenu it has onChange props. But in my case, I need to add an onClick event when Submenu is clicked. Something like this -
<SubMenu label="Category 1" onClick={() => console.log('clicked')}> {/* There is no onClick props actually */}
    <MenuItem />
</SubMenu>

I've tried also by adding a parent div, but not working. Then menu is not coming.

 console.log('clicked')}>
     <SubMenu label="Category 1">
            <MenuItem />
    </SubMenu>

Is there any possibility to achieve this ?

Hi @ManiruzzamanAkash ,
onClick of <SubMenu/> fires when the submenu itself is clicked;
If you want to listen onClick event on submenu item, currently the solution is to add a wrapping
 on label prop and attach onClick on the
.
e.g.: https://codesandbox.io/s/react-menu-issue-228-x5buj
Please make sure click the text 'Open' in submenu item when testing, unless you override styles and remove the padding around the item.
In the next coming release, there will be an additional prop which allows to add event handlers on the label directly.

Great. onClick event works perfectly on <SubMenu /> using this approach. Thanks.


Only 18 items returned

Hi there,
I got an issue retrieving results of a search by bounding-box. The issue is that I only get 18 items returned:
INFO    Searching rectangle: zoom factor = 0, node = []
INFO    Page 01 returned 18 listings
INFO    Page 02 returned 00 listings
INFO    Final page of listings for this search
INFO    Results: 2 pages, 0 new rooms
So it looks like that the pagination is not working properly.
Was there again a change in the airbnb-page, or am I missing something. I tried several bound boxes over cities, statest, etc. in germany.
Thank's for any help.

Found out why it doesn't work:
I didn't use any proxy, so the script will terminate without warnings after the first page.


Assignment to enum field does not converts type

Bug

OS: Linux lptp 4.20.6-arch1-1-ARCH #1 SMP PREEMPT Thu Jan 31 08:22:01 UTC 2019 x86_64 GNU/Linux
Python version: 3.7.2
Pydantic version: StrictVersion ('0.18.2')

from pydantic import BaseModel
from enum import Enum

class TestEnum(Enum):
    a = "a"
    b = "b"

class Model(BaseModel):
    q: TestEnum = TestEnum.a

m = Model()
m.q = "b"
print(m.q)
print(type(m.q))

gives
b
<class 'str'>

IMO, pydantic should either disallow such assignment or automatically convert str to enum member. For now m.q has actual type str while it's mypy revealed type would be TestEnum.

as per the documentation you need:
class Model(BaseModel):
    q: TestEnum = TestEnum.a

    class Config:
        validate_assignment = True

Let me know if it still doesn't work.


Styles are not working when using fullScreenAction

The styles applied to title and body are not working. And anyone know how to apply style for the action buttons ?
If I remove fullScreenAction the styles are working. I want this to be worked as an incoming call. So it should stay in the screen for 2 minutes as well.
 await notifee.displayNotification({
    title:
      '
Test Title
',
    body: '
Test Body
',
    android: {
      sound: 'ring',
      importance: AndroidImportance.HIGH,
      ongoing: true,
      channelId,
      timeoutAfter: 120000,
      color: '#4caf50',
      fullScreenAction: {
        id: 'default',
      },
      visibility: AndroidVisibility.PUBLIC,
      actions: [
        {
          title: 'Action 1',
          pressAction: { id: 'test1' },
        },
        {
          title: 'Action 2',
          pressAction: { id: 'test2' },
        },
      ],
    },
    });

+1


Minor bug in timer during shutdown code

When the timer is shutdown, it fires all the pending timers. It does so by calling the function
run_some_expired_timers(grpc_millis now, grpc_millis* next, grpc_error* error)  which executes all timers before now.
The shutdown code is currently calling run_some_expired_timers(GPR_ATM_MAX, ...)  (i.e GPR_ATM_MAX as now). The idea here being that GPR_ATM_MAX represents "infinity future" and all timers before infinity are fired right away.
However, on  32-bit systems, GPR_ATM_MAX resolves to INT_MAX which is much smaller and roughly evaluates to ~24 days worth of milliseconds.. i.e NOT really representing "infinity". So if there are any pending timers with a deadline after 24 days, they will not be shutdown.
The correct parameter to pass here is GRPC_MILLIS_INF_FUTURE (which resolves to INT64_MAX)

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,975,262      Total (>)      1,975,261

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,769,646      Total (=)     10,769,646

 No significant differences in binary sizes

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,976,226      Total (>)      1,976,225

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,770,420      Total (>)     10,770,419

 No significant differences in binary sizes

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE              FILE SIZE
 ++++++++++++++ GROWIN ++++++++++++++
  [ = ]       0 [None]      +8  +0.0%

  [ = ]       0 TOTAL       +8  +0.0%

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,976,357      Total (>)      1,976,356

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,770,411      Total (<)     10,770,412

 No significant differences in binary sizes

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,976,655      Total (>)      1,976,654

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,775,734      Total (<)     10,775,735

 No significant differences in binary sizes

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,975,936      Total (>)      1,975,935

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,774,675      Total (=)     10,774,675

 No significant differences in binary sizes

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE              FILE SIZE
 ++++++++++++++ GROWIN ++++++++++++++
  [ = ]       0 [None]      +8  +0.0%

  [ = ]       0 TOTAL       +8  +0.0%

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,976,403      Total (>)      1,976,402

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,775,377      Total (<)     10,775,382

 No significant differences in binary sizes

[microbenchmarks] No significant performance differences

[microbenchmarks] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,950,830      Total (>)      1,950,829

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,668,835      Total (>)     10,668,833

 No significant differences in binary sizes

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,950,695      Total (>)      1,950,694

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,668,837      Total (<)     10,668,839

 No significant differences in binary sizes

[microbenchmarks] No significant performance differences

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,951,565      Total (>)      1,951,564

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,662,105      Total (<)     10,662,109

 No significant differences in binary sizes

[microbenchmarks] No significant performance differences

This should fix #16417 👍

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

This should probably be merged as soon as all the non-flaky tests pass.

[trickle] No significant performance differences

Objective-C binary sizes
*****************STATIC******************
  New size                      Old size
 1,955,026      Total (>)      1,955,025

 No significant differences in binary sizes

***************FRAMEWORKS****************
  New size                      Old size
10,843,754      Total (<)     10,843,755

 No significant differences in binary sizes

[microbenchmarks] No significant performance differences

Test failures are known issues:
https://github.com/grpc/grpc/issues/13611
https://github.com/grpc/grpc/issues/16482


Added an example to iso_diamond example for handling tile clicks in respect to the 2d camera

I added an example to iso_diamond's example for working with the cursor position with the tile map. This permits the user to click on any tile to change the color while the example is running. Left clicking increments the tile's color index, and right clicking decrements the tile's color index.
This is to offer an example for this issue: https://github.com/StarArawn/bevy_ecs_tilemap/issues/305Issue 305
--
Part of the reason for this example is that it took me the better part of a week to figure out how to do this. I wanted an example of this to be accessible.

This seems to be implementing Bevy's viewport_to_world_2d manually. I think #305 probably predates that addition to Bevy, and can be closed now.
We also have a mouse_to_tile example that works with iso diamond.

@rparrett: Thanks for reviewing. I see now my misunderstanding of the mouse_to_tile example. I didn't realize that "CursorPos" was self-contained in the example. I attempted using TilePos::from_world_pos using the cursor position from the window, which obviously didn't work, hence how I guess ended up rebuilding "viewport_to_world_2d" that I didn't know existed.
That simplifies my usage quite a bit. Thank you!


One question in regards of the Github workflow related commits

A more workflow related question. I am running Gittower 2.x on MacOS so far. I've added my Github account with an oAuth token. Now with the latest changes with workflow related commits i was unable to push those afterwards from my local repo to my origin. It was stating that oAuth accounts aren't allowed to push commits in the scope of workflow.
Did a "workaround" with Sublimemerge which has only a password authentification so it was possible to push the changes. But what would be the proper way to enable that for oAuth as well? in the settings on the github page i am unable to alter the scope of permissions for a token. just to revoke it? do i need another client or better another authentification method?

ahhhhh remember now. sorry :((( it was achieved with personal access token.


refactor: ecr login retry

Refactors the retry logic out of ecr_login and dockerhub_login in favour of using our retry wrapper script.
Makes our bootstrap_docker.sh script check if there are any aws credentials first, before attempting to use ecr to skip build.

Also tiny thing but chore captures a bit too much right now, I'm in favour of calling this refactor: and leaving chore for metadata

Benchmark results
Metrics with a significant change:

note_successful_decrypting_time_in_ms (8): 313 (-28%)

Detailed results
All benchmarks are run on txs on the Benchmarking contract on the repository. Each tx consists of a batch call  to create_note and increment_balance, which guarantees that each tx has a private call, a nested private call, a public call, and a nested public call, as well as an emitted private note, an unencrypted log, and public storage read and write.
This benchmark source data is available in JSON format on S3 here.
Values are compared against data from master at commit e63f0226 and shown if the difference exceeds 1%.
L2 block published to L1
Each column represents the number of txs on an L2 block published to L1.

Metric
8 txs
32 txs
128 txs

l1_rollup_calldata_size_in_bytes
45,956
181,604
724,196

l1_rollup_calldata_gas
227,204
888,344
3,536,096

l1_rollup_execution_gas
320,395
1,006,792
3,756,474

l2_block_processing_time_in_ms
1,190 (-1%)
4,457
17,635 (-1%)

note_successful_decrypting_time_in_ms
:warning: 313 (-28%)
970
3,590 (-1%)

note_trial_decrypting_time_in_ms
25.5 (-39%)
102 (-3%)
166 (-6%)

l2_block_building_time_in_ms
18,234
72,066
288,444

l2_block_rollup_simulation_time_in_ms
13,517
53,389
214,395

l2_block_public_tx_process_time_in_ms
4,687
18,603
73,797

L2 chain processing
Each column represents the number of blocks on the L2 chain where each block has 16 txs.

Metric
5 blocks
10 blocks

node_history_sync_time_in_ms
14,950 (-6%)
31,433 (+3%)

note_history_successful_decrypting_time_in_ms
2,461 (+7%)
5,127 (+11%)

note_history_trial_decrypting_time_in_ms
108 (+23%)
228 (-8%)

node_database_size_in_bytes
17,285,200
33,198,160

pxe_database_size_in_bytes
29,923
59,478

Circuits stats
Stats on running time and I/O sizes collected for every circuit run across all benchmarks.

Circuit
circuit_simulation_time_in_ms
circuit_input_size_in_bytes
circuit_output_size_in_bytes

private-kernel-init
327
44,528
25,313

private-kernel-ordering
196
43,633
16,193

base-rollup
1,457
129,774
933

root-rollup
86.3 (+5%)
4,192
729

private-kernel-inner
436
70,819
25,313

public-kernel-private-input
242
33,663
26,945

public-kernel-non-first-iteration
239
33,705
26,945

merge-rollup
7.99 (+2%)
2,712
933

Tree insertion stats
The duration to insert a fixed batch of leaves into each tree type.

Metric
0 deployed contracts
1 deployed contracts

tx_size_in_bytes
16,859
35,484

Transaction processing duration by data writes.

Metric
0 new commitments
1 new commitments

tx_pxe_processing_time_ms
549 (-1%)
1,440

Metric
0 public data writes
1 public data writes

tx_sequencer_processing_time_ms
0.550 (+8%)
577

Lasse should have pinned slitherin so I reverted that change before adding to merge queue


Running mean-variance during first batches

The implementation of the running mean and variance has the following update method which was inspired by this:
https://github.com/openai/baselines/blob/b5be53dc928bc19c39bce2a3f8a4e7dd0374f1dd/baselines/common/vec_env/vec_normalize.py#L69
While this works once the self.count is not zero as for the very first batch and then large enough compared to batch_count for the first number of batches the resulting reward in the VecNormalize peaks unnaturally high compared to later updates. Is this behaviour neglectable for the training of an agent or would it make sense to modify the update method and apply a different algorithm while self.count is not way larger then batch_count.

There are always some problems with scaling reward, or scaling observations. So the answer to your question is yes, that part can be problematic. But also never was a showstopper. Your best bet is to scale rew/obs to the scale known beforehand. (and if you compare it to this automatic scaling, you may assess the severity of the problem.)


#120

unikube ps command

@Schille Do you know how I can get the infos about switched apps? Do we have this functionallity?

You can get this information using the telepresence status command.


Video from previous screen disturbs video on current screen

Need urgent help
There are two screens both having videos, when i open the app , suppose first screen opens which have some videos , now when i navigate to second screen which also have some video, then video areas of both the screens affect each other , and in the video area of second screen , i can see the video of first screen.
please help fast.

+1

Any Luck figuring it out?

@keshamtravels What kind of Navigator you're using? Could you provide some code of that particular implementation? Basically I've implemented several screens each with a video component but doesn't encounter such issues like you described.

i m using  create stack navigator from  react-native navigation , videos are in a flat list and when i navigate to another screen with video they interat with each other , further i am using content from nativebase

@keshamtravels You have to make sure that your video is stopped and/or the component is unmounted then you're leaving the screen. So said, when you're adding a new screen to the stack in react-native-navigation, you should make sure that the (running) video component on the previous screen is unmounted and the video is stopped from playing. Are you using some state handler like Redux? If so, make sure that your state is up-to-date when navigating to a new screen.

A code like this should solve your issue
  componentWillMount() {
    // This will fix the thumbnail when changing screens. It's necessary to avoid the overlap on video player
    this.blurSubscription =
      this.props.navigation.addListener(
        'willBlur',
        () => {
          if (this.player) {
            if (!this.player.state.paused) {
              this.player.pause()
            }
          }
          this.setState({showThumbnail: true})
        }
      );
  }

  componentWillUnmount() {
    this.blurSubscription.remove()
  }


a system for caching user loads

we're not caching users, but rather UserPlusAllKeys objects, which we can do some interesting things with
some tests

r? @mlsteele

Ok, this is all ready, and has #4900 merged in


Add keyboard avoiding view examples

Summary
Added examples to keyboard avoiding view in RNTester for:

contentContainerStyle
enabled

Changelog

[General] [Added] - Add keyboard avoiding view examples
Test Plan

@rickhanlonii The only failing test is test_ios_unit_frameworks_hermes which was failing on master!


chore: jsonfmt healthcareapis

Automation for azure-sdk-for-go

Automation for azure-sdk-for-ruby

Automation for azure-sdk-for-python

Can one of the admins verify this patch?

Automation for azure-sdk-for-java


Improve parallel stage duration

The duration computed for intermediate, parallel stages is inaccurate

Largely mitigated in c6eb5f9bec65dd26fe211cd9766f63d888d0f246.


Invert configuration struct direction

Currently most of our components depend on package config as that's where their configuration structs are defined.
That's noisy for package reuse. In some places we work around it by specifying structs in the packages and mirroring them.
Package config should be similar to main in that it bundles together all packages and parses the YAML configuration into the package's own confiuguration structs.
We should also get rid of the YAML-unmarshal-embedded validation and instead provide decicate ValidateX methods.

Related to this, we should not parse YAML directly: http://ghodss.com/2014/the-right-way-to-handle-yaml-in-golang/
Instead use: https://github.com/ghodss/yaml – also how Kubernetes handles it.
What we have to watch out for is keeping the validation of "overflow" fields, which detects mostly typod keys by the user.

Interesting read. One thing to watch out for is whether error messages for invalid YAML (during the YAML->JSON conversion) will be better than the current ones. Some first tests seem promising, although the user might be confused about the mention of JSON conversion:
err: error converting YAML to JSON: yaml: [] mapping values are not allowed in this context at line 4, column 10

We've been bitten by the nil issue a few times, this does seem a rather roundabout way to solve it though.

I'm not sold on the idea of using https://github.com/ghodss/yaml yet. The premise of the blog post is "if you support both json and yaml, here is a way to skip yaml parsing". We only support yaml though, in contrast to Kubernetes.
While it's true that JSON is a subset of YAML (something I've told people a few times when they complained about yaml syntax), the reverse is not true. How are YAML references and anchors be handled for example?

why not use something like viper? It's a global registry for your configuration. You can define your own configuration structs in each package and then simply rely on viper to populate it for you accordingly.

Since this is the only open issue referencing the inability to use YAML anchors and map merging, I'll add my +1 for prometheus support of those features here. I've seen recommendations by devs to use external configuration management tools such as Viper in other issues, but IMO that approach is overkill for many use cases and some areas of config (e.g. alert rules) would benefit greatly from the ability to reuse previously defined maps.

Any news\plans here?

4 years passed

Since this is the only open issue referencing the inability to use YAML anchors and map merging, I'll add my +1 for prometheus support of those features here. I've seen recommendations by devs to use external configuration management tools such as Viper here and in other issues, but IMO that approach is overkill for many use cases and some areas of config (e.g. alert rules) would benefit greatly from the ability to reuse previously defined maps.

I don't get it. We support YAML anchors.

Partially.
This works:
s1: &definition
  - x
  - y
s2: *definition

This does not:
s1: &definition
  - x
  - y
s2:
  <<: *definition

What is the difference?

What is the difference?

I guess the difference is in the first form, you can't add more elements to s2, whereas in the the second one you can add other fields to s2 or override those contained in the *definition

Update: I confirm that in december 2023, prometheus 2.48.1 you still cannot use anchors to merge or override chunks of the YAML config file with the <<: syntax.
You will likely get some error like:
yaml: unmarshal errors:
  line 37: key "severity" already set in map

This is very unfortunate for writing alert unit tests, which may contain a lot repeated data, as mentioned above.

Hello from the bug scrub: this issue now seems to be about supporting yaml <<: syntax, unrelated to the config structure. We're changing the title to better reflect this. Still valid issue, looking for contributor.


Sort thread posts by created date

For some reason, our database is not sending posts out in the order they were created.  Adding an orderBy('created_at') on the Thread->posts relation ensures they always come out in the expected order.

Looks good. Thanks for the PR 👍


setting additional class (via variable)

using
.foo class="bar" baz

results in

baz

and should be

baz

Thanks @smeevil :+1:


EventTypes from listers.

🧽 Update or clean up current behavior

I'd removed this in my previous PR, but I realized looking through couchdb that the reason the eventTypeInformer was unused (other than events) is because the github source was breaking our pattern of listing/fetching through the lister instead of the client (which it gets through reconciler.Base).
This reverts the informer event bits, and makes the object fetches go through the lister for consistency with out best practices.

/lgtm
/approve


Add support for hydrated aggregation results

This PR builds on aggregation builder added in doctrine/mongodb#213 and adds hydrated aggregation results to ODM. It supersedes #1263 which will be closed for repository changes
Similar to createQueryBuilder, one now has createAggregationBuilder in DocumentManager and DocumentRepository classes. This will create an ODM aggregation builder that adds support for references and includesReferenceTo in match stages as well as type handling in those stages as well (type handling for other stages to be added later). The aggregation builder itself is extended to provide optional hydration for aggregation result documents via a new AggregationResultDocument type.
This new mapping type was necessary to handle the special cases for aggregation results:

aggregation result documents may have complex IDs (think $group stages where the id might actually be an embedded document)
aggregation result documents should not be managed by UnitOfWork
aggregation result documents should not be persisted to the database

Note: hydrated aggregation will only be available for MongoDB 2.6 and later. MongoDB 2.2 and 2.4 do not support the cursor option for aggregation commands so no hydration results for those versions.
TODO list:

[x] Add builder with hydration support
[x] Ensure type handling and field name translation in match stage
[x] Ensure type handling in other stages
[x] Ensure field name translation in $sort and $unwind stages
[x] Make $lookup stage work with referenced documents (TBD)
[x] Ensure filters are applied to aggregation queries
[x] Write tests for above cases
[x] Write documentation

Love following the progress on this! Very off topic, but I am very curious to know what tool you use to do the Todo checklist in a PR on github like you have . All of my searches for "github todo list" etc have turned up empty. Is the checklist integrated with something or is there a special syntax? I hate to take your time and impede on this PR but hoping you can point me in the right direction. Thanks!

This is part of GitHub Flavoured Markdown, scroll down to "Task Lists" in the GFM documentation.

That's exactly what I've been looking for. Thank you very much!

Any news about this PR? When the merge will be made?

I'm currently working on finalizing tests and writing documentation. No timeline though since I tend to not keep any deadlines I set myself. We're getting closer though :)

Any news about this PR? When the tag will be made?

The initial idea was to release 1.2 along a bunch of deprecations required for 2.0. Since work on 2.0 is currently on hold due to time issues on my end, we'll revisit the timeline and try to release 1.2 soon. I'll revisit the issue tracker to triage issues that need to go into 1.2 and report back.


Adds e2e test to verify experience when user attempts to save a document but server returns error.

Fixes CAB-3885
I am open to feedback on this approach. I tried several things, before deciding on this approach:

Tried writing an angular HttpInterceptor that could return 500 error when dev conditions are met.
Tried triggering the error from nginx using some of the other request headers.
Getting the uploaded file name from nginx was too complicated and more time that I am willing to spend.

Using the file size as a way to make the test fail is probably a better solution for this scenario.


[FX-533] Expose updateSessionToken and updateMerchantID

What

Why

Test Plan

✅ | ❌ Not a front-end change
✅ | ❌ iOS QA Tests passed locally
✅ | ❌ Unit Tests passed locally

How

Current dependencies on/for this PR:

main

PR #96   👈

This comment was auto-generated by Graphite.


[MHRise]Unicode

Plz add unicode suport.
RU and CN players - sufering.
Thx.

Known issue, work in progress. See #213


[PkgEval] Your package doesn't have a test/runtests.jl file

PackageEvaluator.jl is a script that runs nightly.
It attempts to load all Julia packages and run their tests (if available) on both the stable
version of Julia (0.3) and the nightly build of the unstable version (0.4).
The results of this script are used to generate a package listing
enhanced with testing results. This service also benefits package developers by notifying them if
their package breaks for some reason (caused by e.g. changes in Julia, changes in dependencies,
or broken binary dependencies.)
Currently PackageEvaluator attempts to find your test scripts using a heuristic, preferring the
standarized test/runtests.jl whenever present. Using test/runtests.jl allows people to test
your package using simply Pkg.test("DICOM"), with any testing-only dependencies being
installed by looking at test/REQUIRE.
Your package doesn't appear to have a test/runtests.jl file. PackageEvaluator is going to move
away from auto-detecting tests and will instead only test packages with a test/runtests.jl
file. This change will take place in about a month.
You can:

Add the file and tag a new version. You may in fact have already added this file but not
tagged a new version. PackageEvaluator only tests your latest tagged verison, so you must tag
for the file to be detected.
Chose to do nothing. PackageEvaluator will stop attempting to test your package, and the testing
status will be reported as "not possible".

If you'd like help or more information, please just reply to this issue.

Fixed by #10.


[gws][schedule] undo delete notification for plans

Coverage increased (+3.008%) to 74.975% when pulling a82365c1762fe4dd4b272607f426565da9d21567 on sunny4381:features/gws-schedule-undo-delete-notification into ad87452fb1fbaf5feeec9f0d485546f71dffd75c on shirasagi:master.


The reaction teaser

🎮 Game Request
This game is about the reaction it will count the time how much time to talk to click on different shapes shown in the screen. it will show your reaction. That was interesting to check how fast you are .
you can play with your friends
Point down the features
Reaction teaser
end less game
Select program in which you are contributing
GSSoC23
Code of Conduct

[X] I follow CONTRIBUTING GUIDELINE of this project.

Hey @Sushilverma002! 🙂
It seems like you are not following proper guidelines !! 👀
Read documentation properly !!🙏
If you have any queries reach out to us on Discord🕹 .

Hey @Sushilverma002 !
Thank you for raising an issue 💗
You can self assign the issue by commenting /assign in comment 😀
Make sure you follow CODE OF CONDUCT and CONTRIBUTING GUIDELINES 🚀
Don’t Forget to ⭐ our GameZone🎮
Make sure you join our Discord🕹

Hey @Sushilverma002 ! Thank you so much for your raising the issue💗
It’s all yours, you can come anytime again and make some contributions! 🚀
Alone, we can do little, but together we can do so much! 😇

self assign


[Feature] sc-30606 Select project when signup or login

Auto upload will default disable
Ask user to select defatul project if there are multiple projects

PR checklist

[x] Ensure you have added or ran the appropriate tests for your PR.
[x] DCO signed

What type of PR is this?
Feature
What this PR does / why we need it:

Ask user to select default project when login or signup if there are more than one project in the cloud.
Default disable auto-upload flag when user first time sign up or login

Which issue(s) this PR fixes:
sc-30606
Special notes for your reviewer:
Does this PR introduce a user-facing change?:

Behavior changes:

PipeRider CLI signup command

Auto-set the default project when users signup

PipeRider CLI login command

Auto-set the default project if the users only have a single project
Ask users to select a default project if the users have multiple projects
Support option --project to config default project from command-line

PipeRider CLI logout command

Remove the default_project config


Update pr_checker.js

Clarify that the wait time is a minimum not a maximum. Also see  #131

failed because of tests…


"XMLHttpRequest is not defined" on sveltekit endpoints when deployed on Vercel

Bug report
Describe the bug
Using the client for auth or for querying the database in a sveltekit endpoint throw an error :
{
  data: null,
  error: ReferenceError: XMLHttpRequest is not defined
      at file:///var/task/server/app.mjs:2522:21
      at new Promise (<anonymous>)
      at fetch2 (file:///var/task/server/app.mjs:2517:16)
      at file:///var/task/server/app.mjs:2646:7
      at new Promise (<anonymous>)
      at file:///var/task/server/app.mjs:2645:12
      at Generator.next (<anonymous>)
      at file:///var/task/server/app.mjs:2619:67
      at new Promise (<anonymous>)
      at __awaiter$8 (file:///var/task/server/app.mjs:2601:10)
}

To Reproduce
I made a repository exposing the issue : https://github.com/Pixselve/supabase-sveltekit-endpoints
Click on a button to fetch the endpoint and observe the cloud functions logs on Vercel.
Expected behavior
Requests should not fail and should give the appropriate data.
System information

OS: Vercel Node.js Runtime
Version of supabase-js: 1.10.0
Version of Node.js: 14

Related? vitejs/vite/pull/2996

Could be - we already had to do a bunch of work to make Vite work:
https://github.com/supabase/supabase-js/issues/89
https://github.com/supabase/supabase-js/issues/155
Is this still causing problems on the latest supabase-js?

I've been trying to get this working over the weekend, my package.json is:
{
	"devDependencies": {
		"@commitlint/cli": "^12.1.1",
		"@commitlint/config-conventional": "^12.1.1",
		"@sveltejs/adapter-node": "next",
		"@sveltejs/adapter-vercel": "^1.0.0-next.10",
		"@sveltejs/kit": "next",
		"autoprefixer": "^10.2.5",
		"cssnano": "^5.0.0",
		"husky": "^6.0.0",
		"openapi-typescript": "^3.2.3",
		"postcss": "^8.2.10",
		"postcss-load-config": "^3.0.1",
		"prettier": "~2.2.1",
		"prettier-plugin-svelte": "^2.2.0",
		"pretty-quick": "^3.1.0",
		"svelte": "^3.29.0",
		"svelte-preprocess": "^4.7.0",
		"tailwindcss": "^2.1.1",
		"tslib": "^2.0.0",
		"typescript": "^4.0.0",
		"vite": "^2.1.0"
	},
	"type": "module",
	"dependencies": {
		"@supabase/supabase-js": "^1.11.6"
	},
}

With the following svelte.config.cjs
module.exports = {
	preprocess: [
		sveltePreprocess({
			defaults: {
				style: "postcss",
			},
			postcss: true,
		}),
	],
	kit: {
		adapter: vercel(),
		target: "#svelte",
		vite: {
			ssr: {
				// noExternal: Object.keys(pkg.dependencies || {})
			},
		},
	},
};

Deploying this configuration to vercel serverless produces the "XMLHTTPRequest is not defined" error in production. In local dev everything works fine. It might be the way vercel handles node resolves because I've excluded these deps from vite's bundler. If I add supabase-js to the noExternal array this causes multiple "module/require is not defined" errors in both dev and production.

I note that the PR mentioned above has already been merged. I tried building Vite locally and it doesn't appear to make a difference.

Strongly suspect this is https://github.com/lquixada/cross-fetch/issues/78 in disguise.

In that case, you could try this: https://github.com/supabase/supabase/tree/master/examples/with-cloudflare-workers

async function supabaseInsert (table, arg) {
 return fetch(`${supabaseUrl}/rest/v1/${table}`, {
  headers: {
    Apikey: supabaseKey,
    Authorization: `Bearer ${supabaseKey}`,
    "Content-Type": "application/json",
    Prefer: "return=representation"
  },
  method: "POST",
 body: JSON.stringify(arg)
})
}

async function supabaseFrom (table, filter) {
return fetch(`${supabaseUrl}/rest/v1/${table}?${filter}`, {
  headers: {
    Apikey: supabaseKey,
    Authorization: `Bearer ${supabaseKey}`,
  }
})
}

got it done after an hour or two of npm misadventures.
In any case, appreciate the prompt response @kiwicopple ! Supabase is working marvelously and took exactly one evening to actually get working. The exploration also introduced me to postgrest, which seems a phenomenal building block for supabase's product! Cheers!

I think I've gotten to the bottom of this.

Serverless deployments require bundling of node_modules. That's why you need noExternal to include all node dependencies otherwise you get errors during deployment. This causes dev mode to break, so only add node deps to noExternal when process.env.NODE_ENV = "production.

Vite creates two bundles, a server bundle "functions/node/render/server/app.mjs" and a client bundle "static/_app/*". The problem is that it only reads dependencies once:

https://github.com/vitejs/vite/blob/344d77e9735bc907b9383ad729afb0a8daa2af5f/packages/vite/src/node/plugins/resolve.ts#L466
First off, cross-fetch always resolves to the browser entry point. The way the entry point is resolved does not take into account whether the bundler is in SSR mode or not.

But even if it did resolve correctly, Vite only does one pass over each dependency and then caches it. You can't have the same package resolve to a different entry point for SSR unless you remove resolvedImports['.'] or flush it between each phase.

So my hacky workaround at the moment is to force disable the browser entry point during SSR module generation, and to disable module caching.

This will need to be fixed by Vite.

Hi all, I think this issue can be fixed all the way at the core dependency, even deeper than cross-fetch, but might require more input and attention to actually push it through. It could fix not just this problem, but a lot of other tangential issues as well.
https://github.com/github/fetch/pull/956

@Pixselve interesting it worked for you.. cross-fetch hasn't yet updated the dependency needed with the underlying changes. :thinking: Maybe Vite made some adjustment that made it work?
@kiwicopple I think the change is going to have to propagate through cross-fetch before it will do us any good. Maybe I'll bump this again on the cross-fetch side.

It looks like FaunaDB solved this. Essentially, they added an extra config argument that allows users to opt-out of cross-fetch by passing in a custom fetch function.
Issue: https://github.com/fauna/faunadb-js/issues/207
PR: https://github.com/fauna/faunadb-js/pull/214
So a potential solution for this is:
import { createClient } from '@supabase/supabase-js'

export const supabase = createClient(
    import.meta.env.VITE_SUPABASE_URL,
    import.meta.env.VITE_SUPABASE_KEY,
    {
        fetch: import.meta.env.USE_NATIVE_FETCH ? fetch : undefined,
    }
)

If no fetch is provided, cross-fetch is used. @kiwicopple, would this be straightforward to implement?

Hi there, I believe this is why I'm getting this error with svelte kit and supabase:

__layout.svelte
<script lang="ts">
	import { user } from '../store/sessionStore';
	import { supabase } from '$lib/supabaseClient';
	import { browser } from '$app/env';

	user.set(supabase.auth.user());

	if (browser) {
		supabase.auth.onAuthStateChange((event, session) => {
			console.log('updating with', session);
			user.set(session!.user);
		});
	}
</script>

<slot />

Hope to get a fix soon. Thank you all for your hard work.

I've opened several PRs that allow specifying a custom fetch implementation as an option - ideally I think cross-fetch should support environments like Cloudflare Workers given its use in the ecosystem, but a custom fetch option both enables a workaround today, gives flexibility for future environments (e.g. ones that don't yet exist or are more esoteric), and allows you to provide a mocked fetch for testing.
import { createClient } from '@supabase/supabase-js'

const supabase = createClient('url', 'key', { fetch: fetch })

The main @supabase/supabase-js library wraps other client libraries, so each needs a PR to enable the option.
Wrapped Clients

https://github.com/supabase/postgrest-js/pull/222
https://github.com/supabase/gotrue-js/pull/168
https://github.com/supabase/storage-js/pull/24

supabase-js (depends on the other three PRs)

https://github.com/supabase/supabase-js/pull/297

FYI this also happens when supabase-js is used within NextJS 12 middleware. Since the PRs above aren't merged yet, I am not sure there's a solution other than using the REST API directly over the SDK.

Thanks to a very impressive series of PRs from @jacobwgillespie , this now has a workaround
https://github.com/supabase/supabase-js/releases/tag/v1.27.0
after upgrading to v1.27.0 you can use a custom fetch implementation
import { createClient } from '@supabase/supabase-js'

// Provide a custom `fetch` implementation as an option
const supabase = createClient('https://xyzcompany.supabase.co', 'public-anon-key', { fetch: fetch })

Hello @kiwicopple it's not working for me, i do it createClient('..','..',{fetch:fetch})
but it still doesn't work, Cloudflare workers shows Invalid invocation

@PH4NTOMiki that's probably unclear documentation on my part, I believe if you directly pass the native fetch function as the custom fetch, JavaScript will treat this as an "illegal invocation" as it tries to execute a native method in the context of the Supabase options argument rather than in the global context it was attached to.
You can pass a custom function or bind the fetch function to work around that issue. For Cloudflare Workers specifically, there is no global or window object like you'd have in other runtimes, but you do have self, so:
const supabase = createClient('...', '...', {fetch: fetch.bind(self)})

Really the example I added to the README should have probably been { fetch: customFetch } to avoid confusion, I can look at opening a few more PRs. 🙂

Hello @kiwicopple it's not working for me, i do it createClient('..','..',{fetch:fetch}) but it still doesn't work, Cloudflare workers shows Invalid invocation

I'm getting a similar issue — adding const supabase = createClient('...', '...', {fetch: fetch.bind(self)}) still results in the XMLHTTPrequest error when deployed on Cloudflare pages.
@jacobwgillespie @kiwicopple can you provide a code example of what that customFetch function should be and how it should be included in an endpoint?
In my case, here is the original call I'm making
    async function submitForm(e) {
        var formData = new FormData(e.target);

        formData.append('loaded_address', loaded_address);
        formData.append('address', address);

        const response = await fetch(`./submitform`, {
      method: 'post',
      body: formData
    })
        response.ok ? ( form_submit = "success" ) : (form_submit = "error" )

    }

And here is the SvelteKit endpoint it hits, which makes the Supabase request and produces the FetchError: XMLHttpRequest is not defined error:
    // import supabase from "$lib/db"
import { variables } from '$lib/variables';

import { createClient } from '@supabase/supabase-js'

const supabase = createClient( import.meta.env.VITE_SUPABASE_URL,
    import.meta.env.VITE_SUPABASE_ANON_KEY, { fetch: fetch })

export async function post(request) {

const {data, error} = await supabase
.from('support_responses')
.insert({support_info: request.body.get('support_info'), introduction: request.body.get('introduction'), contact: request.body.get('contact'), loaded_location: request.body.get('loaded_address'), searched_location: request.body.get('address')})

if (error) {
return {
    status: 500,
    body: error
  }
}
else {

return {
    status: 200,
    body: {
      data
    }
  }
}

}

@sbutler-gh I believe you want this when creating the client in Cloudflare Workers:
const supabase = createClient( import.meta.env.VITE_SUPABASE_URL,
    import.meta.env.VITE_SUPABASE_ANON_KEY, { fetch: fetch.bind(self) })

Note the fetch: fetch.bind(self). It would probably also work with fetch: (...args) => fetch(...args).

@sbutler-gh I believe you want this when creating the client in Cloudflare Workers:
const supabase = createClient( import.meta.env.VITE_SUPABASE_URL,
    import.meta.env.VITE_SUPABASE_ANON_KEY, { fetch: fetch.bind(self) })

Note the fetch: fetch.bind(self). It would probably also work with fetch: (...args) => fetch(...args).

Huge thanks for the help on this @jacobwgillespie .  When I try fetch: fetch.bind(self), I get the following error locally and when building for production:

Error when evaluating SSR module /Users/sam/just-start/src/routes/submitform.js:
ReferenceError: self is not defined
at /Users/sam/just-start/src/routes/submitform.js:7:65
at async instantiateModule (/Users/sam/just-start/node_modules/vite/dist/node/chunks/dep-f5e099f1.js:66443:9)
self is not defined
ReferenceError: self is not defined
at /Users/sam/just-start/src/routes/submitform.js:7:65
at async instantiateModule (/Users/sam/just-start/node_modules/vite/dist/node/chunks/dep-f5e099f1.js:66443:9)

When I try fetch: (...args) => fetch(...args), it works in development and when building locally, but results in the same XMLHTTPrequest error when deployed on CF.  Any other thoughts?

@sbutler-gh I think your repo isn't actually using the up-to-date version of @supabase/supabase-js, see here:
https://github.com/sbutler-gh/just-start/blob/c32ecef9d35bfbcb67f187f6725b66986a288b0a/package-lock.json#L325-L326
It appears it's using version 1.24.0, and the ability to pass in a custom fetch implementation was added in 1.27.0 (and 1.28.1 is the latest version).

@sbutler-gh I think your repo isn't actually using the up-to-date version of @supabase/supabase-js, see here:
<EMAIL_ADDRESS>It appears it's using version 1.24.0, and the ability to pass in a custom fetch implementation was added in 1.27.0 (and 1.28.1 is the latest version).

After running npm update to update packages and re-deploying, it now works as expected in production on Cloudflare Pages!  (using fetch: (...args) => fetch(...args), didn't try the other syntaxes yet.). Thank you SO MUCH @jacobwgillespie !  I can't thank you enough!

For Next users wondering if this allows Supabase client use in the middleware API - yes:
import { createClient } from '@supabase/supabase-js';
import { NextRequest, NextResponse } from 'next/server';

export async function middleware(request: NextRequest) {
  const supabase = createClient(process.env.NEXT_PUBLIC_SUPABASE_URL!, process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!, { fetch });
  …

This works great and there is not even need to rebind fetch using fetch.bind(self) or (...args) => fetch(...args)!

Is there probably a regression in the 2.0 branch? I have trouble getting the server side code to work. Tried the new {global: {fetch: ...}} config option. But that doesn't seem to work. Even using Node 18 didn't help.
require is not defined
ReferenceError: require is not defined
    at [...]/node_modules/.pnpm/cross-fetch@3.1.5/node_modules/cross-fetch/dist/node-ponyfill.js:1:32
    at instantiateModule (file:///[...]/node_modules/.pnpm/vite@3.1.8/node_modules/vite/dist/node/chunks/dep-4da11a5e.js:53445:15)


Not clear how to use orderBy in find() method

It is not clear how to use orderBy in the find method:
`Event.find(session,
        where: (event) => event.sectionId.equals(sectionId), orderBy: ???? );

The where parameter provides an Expression in the closure that can reference the column names.
I'd expect orderBy to have a similar closure, or to provide some other means of getting the Column expression.
I think this works:
    var sc = EventTable().startTime; // get column for orderBy=

But it feels kludgy

  return await UserServer.find(session,orderBy: ColumnDateTime("dateTime"),orderDescending: false);
I have not used it yet but I understand that it is used like this

This should be added to the documentation if it isn't already.
Event.find(
  session,
  where: (event) => event.sectionId.equals(sectionId),
  orderBy: Event.t.id,
);

The Event.t object will be a representation of your table, and have a field for each column.

Added docs here: https://github.com/serverpod/serverpod_docs/commit/c4334ead9ed266d88c428f51f33370f1a83b7c54
Will be updated with the 1.1 release.

Please tell me
How do I write the orderBy to refer to the year Field and then, if it is the same year, to refer to the month and day Field in the same table ?

@dongri727 if you use a DateTime, it will be sorted by date (including year, month, and day) or am I missing something?
There is also a orderByList property if you need to order by multiple columns.

@vlidholt Thanks for the answer. Since I am dealing with historical events, like 13.8 billion years ago, or 772 BC... I didn't think I could use DateTime. Anyway how do I describe the orderByList in my endpoint ?


Conflict with Advanced XRay (Fabric Edition)

For whatever reason having the mod Advanced XRay (Fabric Edition) makes it to where none of the link buttons in the menu work at all. Everything else from Useful Widgets seems to load and work fine (reloading the menu, the icons textures, and buttons), but pressing any of the link buttons will do nothing at all.
I don't really know much about coding at all, but I'm trying my best to look into what the conflict is.
Here are the links for the other mod's curseforge and gethub:
https://www.curseforge.com/minecraft/mc-mods/advanced-xray-fabric-edition
https://github.com/MichaelHillcox/XRay-Fabric
Please let me know if I can do anything to help resolve this issue, and thank you in advance.

I'm afraid I haven't been able to recreate this issue, can you send me your config file or a screenshot of it?

I had to convert the files to .txt since the Widgets file was .properties and the Advanced-Xray files were .json
Here is the Useful Widgets file:
config.txt
Here are the Xray files:
blocks.txt
settings.txt

Okay idk why I didn't think of deleting the Advanced xray files and letting the game recreate them before... I'm looking into that now and it seems to be somehting in the blocks.json file.
The new blocks file that it created worked fine, but copying the old text into that file broke the mod again.
I'm looking now to see if creating any file will break it or if it happens on restart or what. Should just take me a few minutes.

Okay so once any block is added to the Advanced Xray blocks.json config file and the game is restarted then the Useful Widgets mod links no longer work.

blocks.txt
Here is that same file but with a lot less clutter if it helps to look at this instead of the one I sent before.

This bug seems rather odd. Tomorrow I will have a closer look and try and see where they conflict, although on first glance (of the source code) I couldn't see any clear problems. I'll look again more thoroughly.

Interesting. Thanks so much for looking into it!

I had to convert the files to .txt since the Widgets file was .properties and the Advanced-Xray files were .json
Here is the Useful Widgets file: config.txt
Here are the Xray files: blocks.txt settings.txt

Okay I have just tried out the files you have sent me (these ones), and everything seems to be working just fine for me. I don't know what was causing your issue but as I can't recreate it I'm going to have to mark it as closed. Thanks for reporting this bug though, its appreciated that you'd take time to try and find the error with my mod.

Thanks anyways 😔
If I find the actual cause you may hear more from me


Fix: make results logger errors manageable.

Description
When the number of errors is high the results logger spews pages of them. This cuts down the list.
Before:
FAILED  RESPONSE PAYLOAD SCHEMA (data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/ignore_above property is not defined in the spec, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/type must be equal to one of the allowed values, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/ignore_above property is not defined in the spec, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/type must be equal to one of the allowed values, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/ignore_above property is not defined in the spec, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/type must be equal to one of the allowed values, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/ignore_above property is not defined in the spec, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/type must be equal to one of the allowed values, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/ignore_above property is not defined in the spec, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/ignore_above property is not defined in the spec, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/type must be equal to one of the allowed values, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/ignore_above property is not defined in the spec, data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/t

... many many lines

After:
FAILED  RESPONSE PAYLOAD SCHEMA data/security-auditlog-2024.07.03/mappings/properties/audit_category/fields/keyword/ignore_above property is not defined in the spec, ...

Not sure how it interacts with @nhtruong's #378, can wait for that to be merged or not.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Lint errors fixed in #240


Update "Demo Source" links to point to correct location

The "Demo Source" links in the components are pointing to the wrong place. Would probably be good to clear out the preview-app directory in ionic-site then move a fresh copy over to get the right paths.
For example:

inputs -> labels
inputs/segment -> segments

Pushed, just need to build and promote to live.


feat(react|redux): add getProductDenormalized selector

Description

Added getProductDenormalized selector.
Replaced getProduct selector by the new getProductDenormalized selector inside bag, wishlist, and details selectors.

Dependencies

Checklist

[X] The commit message follows our guidelines
[ ] Tests for the respective changes have been added
[X] The code is commented, particularly in hard-to-understand areas
[X] The labels and/or milestones were added

Disclaimer
By sending us your contributions, you are agreeing that your contribution is made subject to the terms of our Contributor Ownership Statement

useProductDetails should make use of the getProductDenormalized selector as well as it exposes the product instance to the caller. Can you change it, please?


Table 'DataConnectionUserAccessTable' not found

Prerequisites

[ ] Put an X between the brackets on this line if you have done all of the following:

Checked that your issue isn't already filed: https://github.com/issues?utf8=✓&q=is%3Aissue+repo%3Aeapowertools/governedmetricsservice

Description
[Description of the issue]
Steps to Reproduce

[First Step]
[Second Step]
[and so on...]

Expected behavior: [What you expect to happen]
Actual behavior: [What actually happens]
Reproduces how often: [What percentage of the time does it reproduce?]
Versions
You can get this information by looking on the GMS test page or the config.js file located in the config directory of the distribution. Also, please include the OS and what version of the OS you're running.
Additional Information
Any additional information, configuration or data that might be necessary to reproduce the issue.

Error in generating the  Data connection metadata:
{"errno":-4058,"code":"ENOENT","syscall":"open","path":"c:\metadata\userAccess\c1e76ee6-2e59-454d-b646-48ab0323699f_DataConnection.xml"} 534b92c2-13ed-4d10-bbeb-9d0d9e94f05c
CallgetUserAccessControl errored.  Result=={"errno":-4058,"code":"ENOENT","syscall":"open","path":"c:\metadata\userAccess\c1e76ee6-2e59-454d-b646-48ab0323699f_DataConnection.xml"}
CallgetUserAccessControl errored.  Result=={"errno":-4058,"code":"ENOENT","syscall":"open","path":"c:\metadata\userAccess\c1e76ee6-2e59-454d-b646-48ab0323699f_DataConnection.xml"}
queue 7b06ac52-dd1a-432c-a9e7-89142adcb9dc finished.


Openid Federation IdPs with invalid OPs break the login page due to NullPointerException

In a realm when there is an openid federation identity provider, if there is an offline of invalid OP in the federation, the whole login page will crash (even if other providers could be available in the federation).
When the login controller obtains the login provider
https://github.com/scc-digitalhub/AAC/blob/e5bbba84a116d783e613fd29b4d0bd6bf230c1ee/src/main/java/it/smartcommunitylab/aac/controller/LoginController.java#L227-L233
in case of the openid federation we loop through each possible OP to add it to the login
https://github.com/scc-digitalhub/AAC/blob/e5bbba84a116d783e613fd29b4d0bd6bf230c1ee/src/main/java/it/smartcommunitylab/aac/openidfed/provider/OpenIdFedIdentityProvider.java#L198-L233
but some those steps might produce a null pointer exception if the OP is offline, has invalid metadata or has other issues.
For example op defined in line 208 is null, then line 211 will produce a null pointer exception.
This issue was discovered due to the fact that today (2024-03-04) the CIE federation pre-production environment has an invalid OP metadata and as a consequence the whole realm login page was not usable.

closed with #557


Plugin breaks HTML internal links, just by loading it

Currently the plugin applies the ListGroup 'selecting' behavior to all elements with class 'list-group' by default.
Effectively, it intercepts the clicks. This 'breaks' the following code-snipet that we used as a kind of "Table Of Contents":

  Go to Section 1.1
  Go to Section 1.2
  Go to Section 1.3
  Go to Section 1.4
  Go to Section 1.5

Is there a way the internal link as used in the href attribute of the involved anchor is still respected => the browser scrolls to that section as it would do without the plugin loaded?

walking into this issue again, now for external hyperlinks. Maybe the class that listgroup.js uses to apply its functionality can be made configurable (defaulting to "list-group")? This would be the easiest and quite powerful approach I would say. My JavaScript is not great, otherwise I would come up with a PR...

@rickardn bump?


Disable a symbol name cache if ASLR is enabled

resolve_usym() caches a bcc_symbol object using an executable name
as a key, but on the ASLR-enabled platform, symbol addresses change with
each execution. Disable (discard) a cache, in this case, to resolve
symbol names properly.
Note and known issues:

A cache is discarded whenever resolve_usym is called even if a pid is
the same as the old one. This is because pid may be reused.
This does not check whether a binary is PIE ASLAR or not. Note that
even if a binary is not PIE ASLR, addresses of shared libraries are
randomized if ASLR is enabled.  (If a binary is not PIE ASLR and
resolve_usym() resolves symbol in a binary, we can utilize a cache.)
If ASLR is disabled on the first execution but enabled on the second
execution, resolve_usym() for the second run will use the previous
cache.
I'm not sure how much performance impact this has. If the impact is
huge, maybe this should be an option.
As discussed in #246, symbolizing will fail after process termination
(this is a separate issue). For example:

% bpftrace -e 'u:/lib/x86_64-linux-gnu/libc.so.6:*nanosleep* /comm == "sleep"/ { @[ustack] = count(); }'
Attaching 7 probes...
^C

@[
    0x7ff1917cb990
]: 3
@No such file or directory: /proc/3557/personality
[
    0x7fea4211c990
]: 3
@No such file or directory: /proc/3554/personality
[
    0x7f32bc51a990
]: 3

Closes #1031 and solves the second part of #75.

@No such file or directory: /proc/3557/personality

I do not like the mid output errors, makes it visually very messy. The errors aren't really informative either, it is just a confusing way of telling people that the process has exited before the stackframe was symbolized. I think it is better to aggregate them and print them last, skipping ENOENT. Or just skip them at all.

A cache is discarded whenever resolve_usym is called even if a pid is
the same as the old one
I'm not sure how much performance impact this has. If the impact is
huge, maybe this should be an option.

We should measure this, I can't imagine it being "cheap" for the larger binaries. Although I do not know what tricks bcc has, they might have some tricks to speed it up.
I think we should make this thing optional with a flag that accepts:

on, flush the cache to avoid breaking with ASLR
off, do not flush the cache
auto, auto detect based on kernel/program

I do not like the mid output errors, makes it visually very messy.

I feel the same. I'm thinking about making output only when bt_verbose.
I'll look into the overhead. By the way, we can use BPFTRACE_NO_USER_SYMBOLS=1 to disable user symbol resolutions.

This is the result of the simple benchmark.
for i in `seq 1 1 10`
do
    sudo ./src/bpftrace -c "/bin/bash" -e \
    'u:/bin/bash:readline { @start = elapsed; unroll(20) { unroll('$i') { printf("%d %s %s\n", cpu, usym(reg("ip")), ustack);}} exit();}
     END { printf("%d\n", elapsed-@start); delete(@start);}' \
    | sed '/^$/d' | tail -n1
done

cache       nocache
147954778   95647408
125798568   137093331
123463690   190338079
124233236   189265622
136969078   249505589
154593444   265685467
123442989   312219876
141076933   387775882
124469933   404608889
130294544   459923131

Time increases proportionally if the cache is disabled.

I made the following changes.

Disable caching when ASLR is enabled on system and -c option is not given (if trace one program execution, caching is fine)
Introduce BPFTRACE_CACHE_USER_SYMBOLS env variable to force caching.

clang-format test failed. But I think it is much easier to read codes without newlines in this case...

LGTM