Full page server rendering? (with   tags)

I want to render <html> in main class, making full react app. This way i can have title/meta tags.
Is it a right way with this gem?
all i want from rails is rendering the page and respond to api queries.
I try to avoid bloating my stack with nodejs, trying to prerender on rails side.
It looks like i cant put <html> at the very beginning of document using react and server rendering. It trashes html with <div> tag before it.
Am i doing it wrong?

Sounds like a case we've never looked into. @Fedcomp we'd probably consider a PR for that one.

@Fedcomp If you want to pre-render components in Rails, we support via an option for the view helper from ReactOnRails.

Prerendering component leaves component body on the result page, and rendered component body in the place where it rendered inside of additional div, makes full page rendering not working (html starts with <html>). But it doesn't matter, i googled awhile and now i'm certainly sure it's not react way either, and what i tryed to do is wrong way.
Sorry.

@Fedcomp Please never render body tag with React, b/c there is a high probability that in some point of time in your app something from outside will need to do something with/inside body tag. And then you have problems. It's a bad practice.

I was needed it for metatags.

@Fedcomp You can render <head> and <div id="app" /> separatly, but not <body /> or <html />.


[Bug] Unable to create task group from folder when using DBT_MANIFEST

Astronomer Cosmos Version
Other Astronomer Cosmos version (please specify below)
If "Other Astronomer Cosmos version" selected, which one?
1.5.1
dbt-core version
1.8.4
Versions of dbt adapters
dbt_redshift==1.8.1
LoadMode
DBT_LS_MANIFEST
ExecutionMode
LOCAL
InvocationMode
None
airflow version
2.9.1
Operating System
Amazon Linux 2023
If a you think it's an UI issue, what browsers are you seeing the problem on?
No response
Deployment
Amazon (AWS) MWAA
Deployment details
I've also tested this in the docker-compose MWAA local runner
What happened?
When using DBT_MANIFEST as the load_method, cosmos does not generate tasks for models in a path but DBT_LS will.
dbt will allow you to run this as: dbt ls -s marts.some_folder_with_models or dbt ls -s ./models/marts/some_folder_with_models
This doesn't work:
    project_config=ProjectConfig(
        dbt_project_path=AIRFLOW_HOME / "dags/dbt/dbt-analytics",
        manifest_path=AIRFLOW_HOME / "dags/dbt/dbt-analytics/target/manifest.json",
    ),
    render_config=RenderConfig(
        select=["+marts.some_folder_with_models"],
        load_method=LoadMode.DBT_MANIFEST,
        dbt_executable_path=AIRFLOW_HOME / "dbt_venv/bin/dbt",
    ),

This works:
    project_config=ProjectConfig(
        dbt_project_path=AIRFLOW_HOME / "dags/dbt/dbt-analytics",
    ),
    render_config=RenderConfig(
        select=["+marts.some_folder_with_models"],
        load_method=LoadMode.DBT_LS,
        dbt_executable_path=AIRFLOW_HOME / "dbt_venv/bin/dbt",
    ),

Relevant log output
No response
How to reproduce

in your render config select a folder with models
change load_method from DBT_LS to DBT_MANIFEST
In the GUI, reload and watch the tasks in the task group disappear

Anything else :)?
IMO the two methods should return the same DAG, so DBT_MANIFEST should be able to recognize all models and upstream/downstream dependencies in a folder.
Are you willing to submit PR?

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

Contact Details
<EMAIL_ADDRESS>

@pankajastro - sorry for the profile switch, I've tested with 1.6.0a4 and it still appears to be an issue, here is the example dag using jaffle shop in the ./dev folder
"""
An example DAG that uses Cosmos to render a dbt project into Airflow using a dbt manifest file.
"""

import os
from datetime import datetime
from pathlib import Path

from airflow.decorators import dag
from airflow.operators.empty import EmptyOperator

from cosmos import DbtTaskGroup, ExecutionConfig, LoadMode, ProfileConfig, ProjectConfig, RenderConfig
from cosmos.profiles import DbtProfileConfigVars, PostgresUserPasswordProfileMapping

DEFAULT_DBT_ROOT_PATH = Path(__file__).parent / "dbt"
DBT_ROOT_PATH = Path(os.getenv("DBT_ROOT_PATH", DEFAULT_DBT_ROOT_PATH))

execution_config = ExecutionConfig(dbt_project_path=DBT_ROOT_PATH / "jaffle_shop")

profile_config = ProfileConfig(
    profile_name="default",
    target_name="dev",
    profile_mapping=PostgresUserPasswordProfileMapping(
        conn_id="example_conn",
        profile_args={"schema": "public"},
        dbt_config_vars=DbtProfileConfigVars(send_anonymous_usage_stats=True),
    ),
)

@dag(
    schedule_interval="@daily",
    start_date=datetime(2023, 1, 1),
    catchup=False,
    default_args={"retries": 2},
)
def cosmos_manifest_example() -> None:

    pre_dbt = EmptyOperator(task_id="pre_dbt")

    # [START local_example]
    manifest_example = DbtTaskGroup(
        group_id="manifest_example",
        project_config=ProjectConfig(
            manifest_path=DBT_ROOT_PATH / "jaffle_shop" / "target" / "manifest.json",
            project_name="jaffle_shop",
        ),
        profile_config=profile_config,
        render_config=RenderConfig(load_method=LoadMode.DBT_MANIFEST, select=["+path:models/staging"]),
        execution_config=execution_config,
        operator_args={"install_deps": True},
    )
    # [END local_example]

    ls_example = DbtTaskGroup(
        group_id="ls_example",
        project_config=ProjectConfig(
            manifest_path=DBT_ROOT_PATH / "jaffle_shop" / "target" / "manifest.json",
            project_name="jaffle_shop",
        ),
        profile_config=profile_config,
        render_config=RenderConfig(load_method=LoadMode.DBT_LS, select=["+path:models/staging"]),
        execution_config=execution_config,
        operator_args={"install_deps": True},
    )

    post_dbt = EmptyOperator(task_id="post_dbt")

    (pre_dbt >> ls_example >> manifest_example >> post_dbt)

cosmos_manifest_example()

you can see I'm still getting an empty task group with DBT_MANIFEST method

It seems there might be an issue when using a relative path. Could you please update the select argument to be select=["path:models/staging"]?

@pankajastro - select=["path:models/staging"] does render correctly with both DBT_LS and DBT_MANIFEST, but selecting upstream or downstream with select=["+path:models/staging"] or select=["path:models/staging+"] does not work

would you like to submit a PR? I’d be happy to review and merge it.

@pankajastro - I'm getting familiar with the code base, I'll take a stab at it.

Thanks, @micahVictoria , for identifying and proposing a fix for this.
To some extent, this is a duplicate / generalisation of: a previously logged issue #823


Fix error when item.filename is nil

I'm using telescope-file-browser, and whenever I pressed the change_cwd action (https://github.com/nvim-telescope/telescope-file-browser.nvim#mappings) I got the following error from trouble.nvim:
E5108: Error executing lua: ...im/lazy/trouble.nvim/lua/trouble/providers/telescope.lua:15: attempt to concatenate field 'filename' (a nil value)

This PR fixes this.

Seems that did didn't really work, trouble still expects item.bufnr to be set, so will just fail elsewhere.


Session Management

A possibility to load save and edit different "Projects".
Sometimes it would be nice if one could prepare slides for multiple events.
it would be fine, if those projects could also share templates and participants.

You can export the  tables agenda, motions and particpants as csv - and import these lists in a new OpenSlides instance. OpenSlides does not support multiple instances in one database. Therefore you can use the OpenSlides multi-instance Manager which based on a generic image for new instances.


Fix node e2e test.

Our first cron build fails, because the test command returns exit code 1, which travis thought the test was failing.
@kubernetes-incubator/maintainers-cri-containerd

Merged. @mikebrow Thanks for reviewing!


[BUG] [3.0/main branch] Failing remote integ test (create detector flow)

What is the bug?
Our main branch has a consistently failing remote integration test. This can't be reproduced either locally or on GH runners against our 2.x branch.
The test that has failed consistently 6 times in a row on GH runner is the create detector flow.
error: AssertionError: Timed out retrying after 60000ms: Expected to find element: [data-test-subj="defineOrEditDetectorTitle"], but never found it.
This is likely due to an issue during the bulk indexing of sample data which is the only thing that happens before the line it fails on, meaning we aren't able to move to the create detector page
Additionally AD Dashboard page tests have been flaky during these re-runs on Github, 6 re-runs here: https://github.com/opensearch-project/anomaly-detection-dashboards-plugin/actions/runs/3715398767/jobs/6377116197
When trying to reproduce the create detector flow failure locally, I was able to actually pass the line where it fails on GH runner but consistently fail on AssertionError: Timed out retrying after 60000ms: Expected <h1.euiTitle.euiTitle--large> not to exist in the DOM, but it was continuously found. This error happens when we try to move on from the first step in the create detector page to the next step of setting up the configuration so later on then the failures seen on the GH runner.
What is your host/environment?

OS: Linux
Version: OpenSearch 3.0

The error appears in 2.5 and 2.x as well.

I see that this failure also occurred in windows in some of our runs, however 2.5.0 has passed all tests through jenkins. Are the failures you are seeing on windows only? Or also just other additional flaky tests you see in linux?

Mostly on windows. But in my recent PR run, it fails on Linux as well due to times out waiting for server to start: https://github.com/opensearch-project/anomaly-detection-dashboards-plugin/pull/399

Current status:
       Spec                                              Tests  Passing  Failing  Pending  Skipped
  ┌────────────────────────────────────────────────────────────────────────────────────────────────┐
  │ ✔  plugins/anomaly-detection-dashboard      01:00        1        1        -        -        - │
  │    s-plugin/create_detector_spec.js                                                            │
  ├────────────────────────────────────────────────────────────────────────────────────────────────┤
  │ ✔  plugins/anomaly-detection-dashboard      01:08        8        8        -        -        - │
  │    s-plugin/dashboard_spec.js                                                                  │
  ├────────────────────────────────────────────────────────────────────────────────────────────────┤
  │ ✖  plugins/anomaly-detection-dashboard      01:34        5        -        1        -        4 │
  │    s-plugin/detector_configuration_spe                                                         │
  │    c.js                                                                                │
  ├────────────────────────────────────────────────────────────────────────────────────────────────┤
  │ ✔  plugins/anomaly-detection-dashboard      01:31       11       11        -        -        - │
  │    s-plugin/detector_list_spec.js                                                              │
  ├────────────────────────────────────────────────────────────────────────────────────────────────┤
  │ ✔  plugins/anomaly-detection-dashboard      02:14        6        6        -        -        - │
  │    s-plugin/historical_analysis_spec.j                                                         │
  │    s                                                                                │
  ├────────────────────────────────────────────────────────────────────────────────────────────────┤
  │ ✔  plugins/anomaly-detection-dashboard      00:48        4        4        -        -        - │
  │    s-plugin/overview_spec.js                                                                   │
  ├────────────────────────────────────────────────────────────────────────────────────────────────┤
  │ ✔  plugins/anomaly-detection-dashboard      00:44        2        2        -        -        - │
  │    s-plugin/real_time_results_spec.js                                                          │
  ├────────────────────────────────────────────────────────────────────────────────────────────────┤
  │ ✔  plugins/anomaly-detection-dashboard      01:12        3        3        -        -        - │
  │    s-plugin/sample_detector_spec.js                                                            │
  └────────────────────────────────────────────────────────────────────────────────────────────────┘
    ✖  1 of 8 failed (13%)                      10:15       40       35        1        -        4

The failures seem to be happening in windows envs every time, where the test cluster looks to be extremely unstable based on the time elapsed for running even very basic tests. Opened an issue in FTRepo for more tracking. The only failures I've seen lately are just due to this. All of the tests run by infra during release time for the last 2 releases haven't seen any AD failures, since those clusters are stable.
Opened issue here: https://github.com/opensearch-project/opensearch-dashboards-functional-test/issues/615
Will just continue to track there since there's no urgent failing / flaky tests on our end since it is strictly test env issues.


It works really nice , but i have a strange issue does the playable link gets expires after a day . Cause the app fetches the playable link plays great! I minimise the app after a day if i open and try to play through that stored url , It doesnt work , This Url no more works

It works really nice , but i have a strange issue does the playable link gets expires after a day . Cause the app fetches the playable link plays great! I minimise the app after a day if i open and try to play through that stored url , It doesnt work , This Url no more works

@SachinB17 yes that is correct the URL will expire after sometime.


azure-ai-formrecognizer: Include vcr cassettes in pypi package

Package Name: azure-ai-formrecognizer
Package Version: 3.1.2
Operating System: Fedora 36
Python Version: 3.10.5

Describe the bug
Although the tests are included with azure-ai-formrecognizer in pypi packages, the vcr cassettes are not provided. This causes almost all of the tests to fail.
To Reproduce
Steps to reproduce the behavior:

Download azure-ai-formrecognizer from pypi and extract
Run pytest
Almost all tests fail

Expected behavior
I would expect the tests to run properly with the vcr cassettes.
Screenshots
N/A
Additional context
N/A

Thanks for the feedback, we’ll investigate asap.

Hi @major, thanks for reaching out. We are going to be including test recordings as of package version 3.2.0b6.

Hi @major, thanks for reaching out. We are going to be including test recordings as of package version 3.2.0b6.

Thank you!


Add bash script to create a pull request (fixes #29)

I have requested @c0sm0void for review.

I have requested @c0sm0void for review.

@c0sm0void :p


Remove the frozen indicator.

The frozen indicator has been targeted for termination.  Let's get that done.
Besides falling into disuse for the most part, it doesn't work correctly with multiple repos either.  The link is built from the repo  of the first frozen pull it comes across.  On the comior instance it appears to point to a dead repo?
Closes #136

CR 👍

CR :coffee:

I tried to QA this but I couldn't get a local instance to work.  I followed the setup instructions in the README.md but I couldn't get the app container to connect to the mysql container.  If I use --network=host, I can get them to connect but I couldn't connect to the app using my browser.  In this case, I also had to import the schema by hand to clear errors in the app log.  Anyway, if someone has any tips on how to get this QA'd I'm all ears.

I'd vote for just QAing it live. Rolling back to the previous container image won't be hard if this breaks catastrophically.
That said, we should probably have a docker-compose file that'll get a dev instance up and running quickly. Though it'd be of limited usage without github webhooks and a bootstrapped dataset. So, hard to say.

Going to go ahead a QA this live as Danny suggested.  I'll go ahead and hit this with a QA tag and get it merged.
QA 💀

pulldasher.cominor.com is running my branch now and and it looks good.
We're going to deploy block it for the day while we make sure there are no unintended consequences surfacing as people use the app.
deploy_block 💀
After the merge, we will need to re-deploy master and we will be all set.

I've not seen/heard about any issues.  Going to merge and re-deploy master in a few minutes.

un_deploy_block :sunny:


fix a performance issue with opening files

Fix #105. Atom sends a lot of change events when a file is opened. The number of events is proportional to the size of the file. For average file, this is 3-10 events. We introduce a very short frappe debounce to address this. We'll have to be aware that this might interact poorly with code completion - we might be completing on a file w/o the last typed char.
For very large files, atom sends hundreds of events. For dart:html it was over 800 events. We put in a check to make sure we're not sending change overlays for files that are not in dart projects (like the sdk files).

fix #106

fixes https://github.com/dart-atom/dartlang/issues/77


Remove unnecessary defer in Span.End, shaving significant time

Updates #590
Defer is quite expensive and in this context, we are using it for
code that's very short. Microbenchmarks of defer show a significant
time improvement such as
https://gist.github.com/odeke-em/f8fb3a8695b33dd06a700fc3473f3e62
With this change, after running the benchmarks 10 times, we
get an ~10% time shave from AlwaysSample and a 4% time shave for
NeverSample i.e. on average 65 nanoseconds for always sampling.
$ benchstat old.txt new.txt
name                         old time/op    new time/op    delta
StartEndSpan/AlwaysSample-4     679ns ±17%     614ns ± 9%  -9.65%
(p=0.001 n=9+9)
StartEndSpan/NeverSample-4      192ns ± 5%     184ns ± 1%  -4.11%
(p=0.000 n=10+8)

name                         old alloc/op   new alloc/op   delta
StartEndSpan/AlwaysSample-4      576B ± 0%      576B ± 0%    ~     (all
samples are equal)
StartEndSpan/NeverSample-4       128B ± 0%      128B ± 0%    ~     (all
samples are equal)

name                         old allocs/op  new allocs/op  delta
StartEndSpan/AlwaysSample-4      4.00 ± 0%      4.00 ± 0%    ~     (all
samples are equal)
StartEndSpan/NeverSample-4       2.00 ± 0%      2.00 ± 0%    ~     (all
samples are equal)

If our sampling probability is 1 in 10000, and used on a system
processing 1BN (1e9 requests) an hour, that's 0.0065 seconds shaved an
hour.

Nice, I almost about to believe defer got so much better in the last release but we may actually go through a few things to avoid defer.

Offline @ramonza raised a great point that if ExportSpan happens to panic, this lock will be held forever since we don't have the defer. My response was that, yes I acknowledge that, but for the meantime, before we've encountered that problem let's tradeoff waiting for that day of reckoning with speed here.

@ramonza in the meantime I'll merge this PR, it is all internal stuff so we can revert if we feel strongly about it.

If ExportSpan panics, the process crashes. I don't understand the last comment.

@rakyll, in the common case sure it will panic but defer exportsMu.Unlock() won't be invoked, in the case that Span.End() was invoked by a function that has recover() in it.

In Go, we don't encourage recover at all. Don't optimize behavior for recover.

for example
func pageContent(w http.ResponseWriter, r *http.Request) {
   defer func() {
       if r := recover(); r != nil {
             log.Printf("Handler crashed: %v\n", r)
       }
   }()

   ctx, span := trace.StartSpan(r.Context(), "/template")
   defer span.End()
   ...
}

I've seen a bunch of handlers with recovers in them. In this case exportersMu.Lock() will be held forever yet the program will proceed normally.

This brings the other question of whether it is a good practice to call ExportSpan in the critical path at all.


Getting LWF.Bounds of a LWF.Movie immediately

Right now it seems like the only way to get the bounds of a LWF.Movie is to do this:
private LWF.Bounds theBounds;
private void BoundsFetcher(LWF.Movie m) {
    theBounds = m.GetBounds();
}
public LWF.Bounds GetBounds (string mcInstanceName = null) {
    lwf.SearchMovieInstance ("instancename").RequestCalculateBounds(BoundsFetcher);
    lwf.Exec (0);
    return theBounds;
}

However this means you have to update the flash once. Is there a better way to do it, without using RequestCalculateBounds()?
Or using RequestCalculateBounds() but not having to call Exec(0)?

A workaround would be to avoid calling Exec(0) and simply have LWF RequestCalculateBounds() after every single update that it does, on all its LWF.Movies. However then I ask how can I loop through all LWF.Movies in a LWFObject? I know about lwf.buttonHead to loop through all buttons however there isn't anything similar for movies or is there?


Julia parse does not accept input at once in VSCiode

Type: Bug
The julia command
print("Enter a umber N = ")
N=parse(Int64,readline())
is supposed to accept a keyboard input once. For example if you run the above code on the VSCode editor, it returns "Enter a number N =" and type 50 from the keyboard and press enter, the code will not execute until you retype 50 and press enter again.
VS Code version: Code 1.74.2 (e8a3071ea4344d9d48ef8a4df2c097372b0c5161, 2022-12-20T10:29:14.590Z)
OS version: Windows_NT x64 10.0.22621
Modes:
Sandboxed: No
Extensions (1)

Extension
Author (truncated)
Version

language-julia
jul
1.38.2

Is this the Julia command's behavior? Not sure this has to do with VS Code.

Thanks for your response. If you run the commands I used as example on
Julia REPL and press enter, it accepts input once. But if you run it from
VScode editor, you will have to enter the input twice and press enter twice
before it executes.
Let me add that if you run a Julia file that contains PyCall on Julia REPL
with include(filepath.jl) on VScode, it runs perfectly but if you run such
file on Vscode editor PyCall does not work.
Follow these steps to see what I am saying.
A. In VScode, open a new Julia file and  type on the editor

print("Enter N")
N = parse(Int64, deadline())
3 g = N^2
Then save it as test.jl and run.
B. Julia returns Enter N thenType 10 for N on Julia terminal and press enter

Regards.
On Tue, 27 Dec 2022, 2:30 pm Christof Marti, @.***>
wrote:

Is this the Julia command's behavior? Not sure this has to do with VS Code.
—
Reply to this email directly, view it on GitHub
https://github.com/microsoft/vscode/issues/170046#issuecomment-1365903337,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AK4NBY2WKCGZ4UYLZXU7PRLWPLVPBANCNFSM6AAAAAATJXAEVI
.
You are receiving this because you authored the thread.Message ID:
@.***>

Hey @chrmarti, this issue might need further attention.
@ay111, you can help us out by closing this issue if the problem no longer exists, or adding more information.

This seems to be an issue with the Julia extension, could you open an issue for it at https://github.com/julia-vscode/julia-vscode/issues? Thanks!

Ok. Thanks.
On Tue, 21 Mar 2023, 3:51 pm Christof Marti, @.***>
wrote:

This seems to be an issue with the Julia extension, could you open an
issue for it at https://github.com/julia-vscode/julia-vscode/issues?
Thanks!
—
Reply to this email directly, view it on GitHub
https://github.com/microsoft/vscode/issues/170046#issuecomment-1477875690,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AK4NBY2KSIFVHIQVNUE7CCLW5GW7PANCNFSM6AAAAAATJXAEVI
.
You are receiving this because you were mentioned.Message ID:
@.***>


Add API to request historical data

Would be nice to have some API endpoints so you can easily inspect, filter etc historical data

Yes it is also possible. But unfortunately I am super busy at my work.
Hopefully I can look into it in early 2024.
If you have other suggestions feel free to create new issues.
On 17 December AD 2023 at 05:25:37, JannemanDev @.***)
wrote:
Would be nice to have some API endpoints so you can easily inspect, filter
etc historical data
—
Reply to this email directly, view it on GitHub
https://github.com/0xFar5eer/AzeroTradeFeed/issues/2, or unsubscribe
https://github.com/notifications/unsubscribe-auth/AZRKNY5ZHKRFSOREAGVSPGDYJYGVDAVCNFSM6AAAAABAX262JOVHI2DSMVQWIX3LMV43ASLTON2WKOZSGA2DIOJWGU2TSNY
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>


[service] Client version guards

Create client version guards to check client vs server version. These have not been wired up yet.

Related to issue https://github.com/michaelgambold/pi-garage/issues/104


consistent libvirt error handling in virt-handler

This PR adds a new module to virtwrap package that is reponsible for handling libvirt errors. We do that to unify the way errors are handled within virt-handler. Without these patches, the errors must be explicitly casted to libvirt.Error and compared to libvirt.ErrorNumber, unless the return is already typed (that's the case for libvirt.GetLastError).
The abstraction brought by the new module adds currently two checked ErrorNumber: ERR_OK and ERR_NO_DOMAIN. Any new error should be added to the module with descriptive name so the rest of the code can use it.
The idea is based on error abstractions in k8s apimachinery.

ok to test

Everything except the usual flaky test passes.


Recognise only blockquotes followed by space

This PR changes quote regex to enforce following space after >.
> not followed by space won't be parsed as quote. In the multiple level quote context spaces between > signs are irrelevent
Fixed Issues
$ https://github.com/Expensify/App/issues/41696
Tests

What unit/integration tests cover your change? What autoQA tests cover your change?
I've Adjusted already present unit tests
What tests did you perform that validates your changed worked?
I've run unit tests and checked the changes in both example app of react-native-live-markdown and E/App itself, by bumping the expensify-common version to my branch head

QA

What does QA need to do to validate your changes?
bump expensify-common version in E/App and use chat normally - sent messages should be parsed with the new rule
What areas to they need to test for regressions?
All quotes usage are vulnerable to regressions

Sure, I'm on it 👀


Create bfs.cpp

this is with reference to issue #58
problem link:  https://practice.geeksforgeeks.org/problems/bfs-traversal-of-graph/1
problem type : BASIC GRAPH TRAVERSAL(breadth first search)

@vaishnavijha please before making PR use the file format:-
BFS/CPP/BFS.C++
or you can check issues box

ok sure will take care next time .Do i make another pull request changing the name of this bfs file?Sent from my Samsung Galaxy smartphone.
-------- Original message --------From: zahin ekbal<EMAIL_ADDRESS>Date: 05/10/2020  10:57  (GMT+05:30) To: zahinekbal/codeWith-hacktoberfest<EMAIL_ADDRESS>Cc: vaishnavi jha<EMAIL_ADDRESS>Mention<EMAIL_ADDRESS>Subject: Re: [zahinekbal/codeWith-hacktoberfest] Create bfs.cpp (#68)
@vaishnavijha please before making PR use the file format:-
BFS/CPP/BFS.C++
or you can check issues box
—You are receiving this because you were mentioned.Reply to this email directly, view it on GitHub, or unsubscribe.

yeah change your file then make your pull request again..


Optimize row validation to avoid SELECT * in each level

Currently a row validation generates a query like so:
SELECT *, TO_HEX(SHA256(`concat__all`)) AS `hash__all`
FROM (
  SELECT *,
         ARRAY_TO_STRING([`upper__rstrip__ifnull__cast__id`, `upper__rstrip__ifnull__cast__ts`, `upper__rstrip__ifnull__cast__order_date`], '') AS `concat__all`
  FROM (
    SELECT *,
           upper(`rstrip__ifnull__cast__id`) AS `upper__rstrip__ifnull__cast__id`,
           upper(`rstrip__ifnull__cast__ts`) AS `upper__rstrip__ifnull__cast__ts`,
           upper(`rstrip__ifnull__cast__order_date`) AS `upper__rstrip__ifnull__cast__order_date`
    FROM (
      SELECT *, rtrim(`ifnull__cast__id`) AS `rstrip__ifnull__cast__id`,
             rtrim(`ifnull__cast__ts`) AS `rstrip__ifnull__cast__ts`,
             rtrim(`ifnull__cast__order_date`) AS `rstrip__ifnull__cast__order_date`
      FROM (
        SELECT *,
               IFNULL(`cast__id`, 'DEFAULT_REPLACEMENT_STRING') AS `ifnull__cast__id`,
               IFNULL(`cast__ts`, 'DEFAULT_REPLACEMENT_STRING') AS `ifnull__cast__ts`,
               IFNULL(`cast__order_date`, 'DEFAULT_REPLACEMENT_STRING') AS `ifnull__cast__order_date`
        FROM (
          SELECT *, CAST(`id` AS STRING) AS `cast__id`,
                 CAST(`ts` AS STRING) AS `cast__ts`,
                 CAST(`order_date` AS STRING) AS `cast__order_date`
          FROM `pso-kokoro-resources.hivetest.test_timestamp`
        ) t4
      ) t3
    ) t2
  ) t1
) t0

We can optimize the results returned by the query if we get rid of the SELECT * at each level.

Closing this as the SELECT * FROM ( NESTED QUERY) is Ibis's way to compile subqueries.


Install sass in the Travis build

The grunt-contrib-sass plugin execs sass from the Rubygem. Fortunately, all Travis environments include some kind of Ruby runtime. Let's see if it's good enough.
I might need to do some tinkering to get gem install to work properly.

Hah. Gem install succeeded. This should help, then.


Fixed Incorrect Cross references

Problem: Even I fixed Cross-references there were few xrefs that they didnt render correctly on the website. And they wont be caught in yarn link checker because their links redirect to the same webpage.(href:"#")
Example:- they show up on a website like "something-component.adoc"
Solution: Since this is not user-friendly. I used some bash script to iterate through all the. adoc files in docs/components directory and grab a one file name and search where it has mentioned in docs/user-manual without correct cross-referencing fixed them using a regex expression. likewise same did for docs/user-manual .adoc files.Since some .adoc files are autogenerated files I did same to those resources paths.
#!/bin/bash function fixContent() {     for filename1 in /home/nayananga/Desktop/camel/docs/components/modules/ROOT/pages/*.adoc; do         extractName1=${filename1##*/}         echo ${extractName1}         find '/home/nayananga/Desktop/camel/docs/user-manual/modules/ROOT/pages/' -iname "*.adoc" -exec perl -pi -e  "s/xref:${extractName1}?/xref:components::${extractName1}/g" {} \;     done } fixContent exit 0
#!/bin/bash function copyContent() {     for filename1 in /home/nayananga/Desktop/camel/docs/components/modules/ROOT/pages/*.adoc; do         extractName1=${filename1##*/}         find '/home/nayananga/Desktop/camel/components/' -iname "*.adoc" -printf "%h\n" | sort -u | while read i; do                                                           cd "$i"              for filename2 in $PWD/*.adoc; do                 extractName2=${filename2##*/}                 if [ "$extractName1" == "$extractName2" ];then                                      echo "match found coping $filename1 to $filename2"                     cp $filename1 $filename2                     fi             done             # && pwd && $COMMAND         done    	     done } copyContent exit 0
Output: This fixed almost all incorrect cross-references but not all of them.

Thank you!


add dockerfile

add dockerfile

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Add a note to install cluster local gateway for knative 0.9.0+

What this PR does / why we need it:
Add a note to install cluster local gateway for knative 0.9.0+, or there will be issue when using transformer or explainer.
Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #

This change is

/lgtm
/approve

/retest

/assign @yuzisun

/lgtm
/approve


Break expression into distinct sub-expressions Fix #2

/src/.build/checkouts/iCalSwift/Sources/Parser/ICalParser.swift:198:16: error: the compiler is unable to type-check this expression in reasonable time; try breaking up the expression into distinct sub-expressions

I have no type checking issues with any iOS build in Xcode 15.0
can you tell me what your build environment is like?

I've been developing on MacOS using VS Code – i.e. swiftc command line and SPM swift package build. I'm targeting AWS Lambda but the error was happening during the local build (the deployment build happens inside a Linux Docker container).


Error block indication is not clear

Link to reproduction
https://github.com/shefing/PayloadSplitBug
Environment Info
New instance of payload website template

Describe the Bug
When I have a content page that contains many blocks one after the next ,
and I have an issue with one of the blocks (For example : a required field is empty ),
I get a pop-up error message box that I have an error in the block before the block with the issue.
(For example : block number 3 has a non-filed required field , the message wile be - block.2.XXX  .....)
Attached a screenshot with the issue (Issue is in the second block but the pop-up points on block 1) .

Reproduction Steps
Step for reproduction:

Clone the reproduction repo or create  a new payload website template

Create a new Page instance

In the Hero tab:
- Fill in the title
- Add a Link block and fill it up
- Add a second Link block and fill it up except the Label field

Try to publish the page

Expected :
An error message "hero.links.2.link.label"
Actual:
An error message "hero.links.1.link.label"
Adapters and Plugins
No response

The user has reported in Discord that this issue still exists.
I haven't reproduced it, but it seems different than #7914


IGNITE-15721 Implemented the ability to use configuration instances as direct proxies to underlying storages.

https://issues.apache.org/jira/browse/IGNITE-15721

Merged


[DO NOT MERGE] Auto PR to update dependencies of istio

This PR will be merged automatically once checks are successful.
none

@istio-testing: The following test failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-pilot-e2e.sh
d8c0e7a3a3fe2e048a51a2ac042e6f30431aa86d
link
/test istio-pilot-e2e

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


[#5] Add function to execute transaction via the mock

Fixes #5
Changes in PR:

[ ] Tests
[x] Allow execution of tx via mock

I have read the CLA Document and I hereby sign the CLA


NameError: global name 'get_nearest_terms_in_idxphrase_with_collection' is not defined

Affected versions
Everything since 4b95199889cbf814a2ef134cb149946f44a58d1e, so maint-2.1 and master.
Error
XXX.YYY.ZZZ.WWW - - [15/Jun/2015 13:28:13] "GET /search?ln=en&p=&action_browse= HTTP/1.1" 500 -
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/site-packages/flask/app.py", line 1836, in __call__
    return self.wsgi_app(environ, start_response)
  File "/code/invenio/ext/legacy/__init__.py", line 114, in __call__
    response = self.app.handle_exception(e)
  File "/usr/local/lib/python2.7/site-packages/flask_restful/__init__.py", line 270, in error_router
    return original_handler(e)
  File "/usr/local/lib/python2.7/site-packages/flask/app.py", line 1403, in handle_exception
    reraise(exc_type, exc_value, tb)
  File "/code/invenio/ext/legacy/__init__.py", line 110, in __call__
    response = self.app.full_dispatch_request()
  File "/usr/local/lib/python2.7/site-packages/flask/app.py", line 1477, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python2.7/site-packages/flask_restful/__init__.py", line 270, in error_router
    return original_handler(e)
  File "/code/invenio/base/wrappers.py", line 133, in handle_user_exception
    return super(Flask, self).handle_user_exception(e)
  File "/usr/local/lib/python2.7/site-packages/flask/app.py", line 1381, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python2.7/site-packages/flask/app.py", line 1475, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python2.7/site-packages/flask_debugtoolbar/__init__.py", line 125, in dispatch_request
    return view_func(**req.view_args)
  File "/code/invenio/base/decorators.py", line 203, in decorator
    return f(*args, **argd)
  File "/code/invenio/modules/collections/decorators.py", line 56, in decorated
    return method(collection, *args, **kwargs)
  File "/code/invenio/modules/search/views/search.py", line 344, in search
    return browse()
  File "/code/invenio/base/decorators.py", line 82, in decorated_function
    ctx = f(*args, **kwargs)
  File "/code/invenio/base/decorators.py", line 203, in decorator
    return f(*args, **argd)
  File "/code/invenio/modules/collections/decorators.py", line 56, in decorated
    return method(collection, *args, **kwargs)
  File "/code/invenio/modules/search/views/search.py", line 279, in browse
    colls=colls, p=p, f=f, rg=rg, ln=g.ln))
  File "/code/invenio/legacy/search_engine/__init__.py", line 254, in browse_pattern_phrases
    browsed_phrases_in_colls = get_nearest_terms_in_idxphrase_with_collection(p, index_id, rg/2, rg/2, coll_hitset)
NameError: global name 'get_nearest_terms_in_idxphrase_with_collection' is not defined

Steps to reproduce
Method a:

Go to the landing page /
Click on the +-Party near the search field,
Click on Browse at the bottom right in the option field that appears

Method b:

Go to /search?action_browse=

Cause
4b95199889cbf814a2ef134cb149946f44a58d1e

I did some digging on this. In commit aebbd45, the one before 4b95199, get_nearest_terms_in_idxphrase_with_collection was in the same file as its use: https://github.com/inveniosoftware/invenio/blob/aebbd45f5aae03fd70804192744a4b80d258f9b4/invenio/legacy/search_engine/init.py#L3487. So we need to add back the import from its new location in 4b95199.
Then, a parameter name changed from f to index_id everywhere except than in the function declaration.
Finally, when no model is given (which is the case when clicking "browse" as described in the issue), the method should return an empty list and not None, since we will eventually try to map over it: https://github.com/inveniosoftware/invenio/blob/f6bee4828bf93f66bef1885f09c421d1eb083c6f/invenio/modules/search/views/search.py#L276.
I tentatively created https://github.com/jacquerie/invenio/commit/901a04db18d3eee34eea4b8fd842a1fb59f55554 that fixes the present issue. Should I submit a PR?

I tentatively created jacquerie@901a04d that fixes the present issue. Should I submit a PR?

Yes. Please add FIX label to commit messages. Thanks


Merge the 2.13 release branch

Hmm, I would just merge the prometheus:release-2.13 branch into prometheus:master. But here you are merging one of your own branches.

I see, there are merge conflicts...

I tried in https://github.com/prometheus/prometheus/pull/6167 , but there is was a merge conflict so need to create another branch to resolve the conflict

But why are there so many more commits in here?
Let me try something...

fixed it

I see. Now your attempt and mine (#6171) look the same. :+1: here and I'll remove my own PR.


Transform http to https in links in uploaded ReadMe files

https://devdiv.visualstudio.com/DevDiv/_workitems/edit/730865

@chenriksson , how hard do you think it is?


Allow Apartment v2, fix Sidekiq Pro Batch Lookup

I know this is already done in two separate MR but I also needed the fix for Sidekiq Pro. @mperham fix this but didn't correctly reference ::Sidekiq::Batch::Server in the insert_before method. This prevented us from starting sidekiq server

Looks good.


Betterdiscord... Icon?

So what does this flashing Better Discord icon in the bottom right mean?

Notes:
I can't click on it.
Betterdiscord shows no other signs of working. (I've made use of themes and plugins in the past)
I'm using Debian 10 and have followed all instructions given on installing it.
I have gotten it to work previously, but it seems to randomly work and then not work between reboots.

Run betterdiscordctl reinstall and betterdiscordctl update.
If it still fails to load, it's probably a network issue.

I did just do it, but man the number of times I've reinstalled both Discord and Betterdiscord. It still doesn't work, but the Icon is still there. I did make another post yesterday (I think it was deleted or something because I couldn't find it) and there are two things that I think could be the problem. One is that I was trying to install an emulator, had issues, and went to my BIOS to enable it. The other is a line I get when told it cannot find Discord and it recommends using "--discord". Then I used it and it said something about a config file. My other post was much more detailed, like I said, but I couldn't find it. I can try looking for it again to see if I can get that line.

So…where's that detailed post?

I couldn't find it unfortunately. It should have been posted here. But as a summary I used this link to install Discord. It says it should be Canary but I tried to install Betterdiscord for Canary and it didn't work (It says "Discord installation not found."). So I tried the normal version and it worked kind of. I had it working properly a couple times and it would randomly work or break between reboots. Although it doesn't do that anymore, it doesn't work at all now. Though I had uninstalled, reinstalled, updated, and upgraded repeatedly when it was working even that little bit. It also happened to stop working at all when I enabled use of virtual machines in the BIOS. And like I said previously, there's also some error it gives about the config file. Though it's been too long, I can't remember what exactly it said. What I have noticed is the following regarding Betterdiscord showing signs of working: The flashing icon from above and when I hit "public" under the friend icon up at the top left I get the Betterdiscord server option, but I can't join it. Though I can join other ones.

there's also some error it gives about the config file
Would it happen to be the same error as #77?

I just took a look and no, Discord functions perfectly fine. I don't have a problem opening that. I have also only used sudo when the instructions said to, and I've been paying attention to whether the lines start with a # or a $. (I never really use super user I just use sudo.) I might have used it the first time I installed Betterdiscord, but I've been typing betterdiscordctl commands without sudo as far as I remember. I tried as you instructed anyway. I deleted .local/share/betterdiscordctl and tried again.
user@hostname:~$ betterdiscordctl install
Cloning https://github.com/rauenzi/BetterDiscordApp...
Cloning into '/home/d34ddud3/.local/share/betterdiscordctl/bd/0'...
remote: Enumerating objects: 13, done.
remote: Counting objects: 100% (13/13), done.
remote: Compressing objects: 100% (10/10), done.
remote: Total 13 (delta 0), reused 6 (delta 0), pack-reused 0
Unpacking objects: 100% (13/13), done.
Installed. (Restart Discord if necessary.)
user@hostname:~$ betterdiscordctl upgrade
betterdiscordctl is already the latest version (1.7.0).
user@hostname:~$ betterdiscordctl update
Updating Git repository...
From https://github.com/rauenzi/BetterDiscordApp
 * branch            injector   -> FETCH_HEAD
HEAD is now at 79ff7d8 change backup url
user@hostname:~$
It seems like it works from here, but when I restart Discord the flashing icon and "public" button under the friends icon to access dm's have both disappeared. Now there are absolutely no signs of it working other than what the console says above. I tried once to install Canary as well after this because the website I linked in my last comment said it would be Canary. Though Betterdiscord doesn't seem to install if I try the Canary installation. (I tried after deleting .local/share/betterdiscordctl again before trying just to make sure.)

Run betterdiscordctl status -v -v and post the output.
For Canary you should add the --flavor=canary flag.

user@hostname:~$ betterdiscordctl -v -v
VV: Scanning /opt
VV: Trying flavor ''
VV: Trying flavor 'canary'
VV: Trying flavor 'ptb'
VV: Scanning /usr/share
VV: Trying flavor ''
V: Using Discord at /usr/share/discord
V: Found modules in /home/d34ddud3/.config/discord/0.0.11/modules
Discord: /usr/share/discord
Modules: /home/d34ddud3/.config/discord/0.0.11/modules
Index modified: yes
Linked injector directory: /home/d34ddud3/.local/share/betterdiscordctl/bd/0
Linked injector repository: https://github.com/rauenzi/BetterDiscordApp
I tried to use the --flavor=canary but I don't know how. I tried adding it to betterdiscordctl and betterdiscordctl -v -v but it just spat out the line WARN: Unknown option (ignored): --flavor=canary and ran the rest of the command. I tried looking through betterdiscordctl -h and a Google search (that ended up as fruitless as a desert) but I couldn't figure out how to use it.

My bad, it's --flavors=canary.

Alright... I am confused beyond measure now. So when I saw your comment I decided to look into whether that website lied to me or not, turns out it did. I have normal, apparently Canary has an orange icon which I didn't know because I only ever used the stable and standard. So while I was looking at Discord I noticed, "oh hey, I have an update. Maybe that will fix it?" and right I was! Almost... After the update I decided to reboot to see if the previous problem would still occur... and it did... So now I once again have the flashing icon at the bottom right and the "public" button under the friend dm's icon at the top left...  Sidenote: That update was apparently from August 10th... is there an option to turn on update notifications or auto-updates? If not is there a plugin I can get? And if still no that would be an awesome feature to add to Betterdiscord because that update icon is very easy to miss and forget about.

So I just installed the Discord update file discord-0.0.12.deb and completely reinstalled BetterDiscord (without sudo as always) in the order of install, upgrade (1.7.0), then update. Now I see absolutely no signs of it working at all. I assume the most likely reason is that I just need to wait for the next BetterDiscord version but I figure this post wouldn't hurt.

So...there's no issue?

No, I'm just back to where I started when I made the initial post. I have no BetterDiscord settings. The only difference from when I started is that the public button is in the right place and I updated Discord from discord-0.0.11.deb to discord-0.0.12.deb.

Open the Discord console with Ctrl + Shift + i and screenshot any errors you see.

These are the only two warnings and errors I have.

Can you upload ~/.config/BetterDiscord/injector.log and ~/.config/BetterDiscord/bdstorage.json?

I can confirm the existence of one of those things. Here's bdstorage.json. (It wouldn't let me upload file directly, so I copy and pasted through Kate)
{
    "settings": {
        "stable": {
            "settings": {
                "bda-gs-1": true,
                "bda-gs-2": false,
                "bda-gs-3": false,
                "bda-gs-4": false,
                "bda-gs-5": true,
                "bda-gs-6": true,
                "bda-gs-7": true,
                "bda-gs-8": false,
                "bda-es-0": true,
                "bda-es-1": true,
                "bda-es-2": true,
                "bda-es-4": false,
                "bda-es-6": true,
                "bda-es-7": true,
                "bda-gs-b": false,
                "bda-es-8": true,
                "bda-dc-0": false,
                "bda-css-0": false,
                "bda-css-1": false,
                "bda-es-9": true,
                "fork-dm-1": false,
                "fork-ps-1": true,
                "fork-ps-2": true,
                "fork-ps-3": true,
                "fork-ps-4": true,
                "fork-ps-5": true,
                "fork-es-2": false,
                "fork-es-3": true,
                "fork-wp-1": false,
                "fork-wp-2": false,
                "fork-beta": true,
                "reactDevTools": false
            },
            "plugins": {},
            "themes": {
                "theme1": true,
                "theme2": false,
                "theme3": false,
                "theme4": false,
                "theme5": false,
                "theme6": false,
                "theme7": false
            }
        },
        "canary": {},
        "ptb": {}
    },
    "version": "0.3.5",
    "emoteCacheDays": 7,
    "emoteCacheDate": "2020-09-11T21:10:47.833Z"
}
As for injector.log... Yeah that doesn't exist.

So I decided to run betterdiscordctl update after I saw that.
user@hostname:~$ betterdiscordctl update
Updating Git repository...
From https://github.com/rauenzi/BetterDiscordApp
 * branch            injector   -> FETCH_HEAD
HEAD is now at 79ff7d8 change backup url
user@hostname:~$
The last line caught my eye. "...change backup url" Might that be the problem with injector.log not appearing?

No. Run betterdiscordctl install -v -v now and post the output if it fails

user@hostname:~$ betterdiscordctl install -v -v
VV: Scanning /opt
VV: Trying flavor ''
VV: Trying flavor 'canary'
VV: Trying flavor 'ptb'
VV: Scanning /usr/share
VV: Trying flavor ''
V: Using Discord at /usr/share/discord
V: Found modules in /home/user/.config/discord/0.0.12/modules
ERROR: Already installed.
user@hostname:~$
I went and checked for injector.log after this and nothing changed there.

Again with reinstall instead.

user@hostname:~$ betterdiscordctl reinstall -v -v
VV: Scanning /opt
VV: Trying flavor ''
VV: Trying flavor 'canary'
VV: Trying flavor 'ptb'
VV: Scanning /usr/share
VV: Trying flavor ''
V: Using Discord at /usr/share/discord
V: Found modules in /home/d34ddud3/.config/discord/0.0.12/modules
Killing Discord processes...

V: Injecting into index.js...
V: Linking BetterDiscord injector...
Reinstalled.
user@hostname:~$
So by doing this BetterDiscord seems to work now. The public button is misplaced again but that's a simple fix in the .css files I suppose. I went ahead and did a reboot to see if it broke again and it didn't. I then went into Discord and used ctrl+shift+i and checked the console tab. The two errors went away, but those same two warnings remain. Don't know if that's important or not. And the file injector.log still doesn't exist under ~/.config/BetterDiscord. That directory hasn't changed at all. I suppose it's probably not too important in terms of function.


Fix add/remove import tests noticed on test machine

'Remove import' tests failures were easy to repro on my machine, and adding the wait for analyzer makes them succeed consistently.
'Add import' tests were not failing on my machine. On test machine they fail waiting for the lightbulb session, so adding a wait on the analyzer makes some sense.

👍


Support more player parameters and youtube-nocookie

At the moment the default template adds rel=0 to the YT URL and the video ID.
The module should support more player parameters: https://developers.google.com/youtube/player_parameters - possibly exposing some options within the element, with sensible defaults, without it becoming cumbersome to content editors.
It should also support youtube-nocookie.com as the domain of the video. To avoid breaking backwards compatibility the domain selection could initially be behind a configuration setting or in the element itself, with nocookie being set as the default from v1.

(the workaround at the moment is to override Includes/LinkedVideo.ss in the project theme: https://github.com/nswdpc/silverstripe-elemental-feature-video/blob/master/templates/Includes/LinkedVideo.ss)

WIP: https://github.com/nswdpc/silverstripe-elemental-feature-video/commit/7e8118375237f014e597ea7b1a452b42d40c5d7d

closed by #6 and #7


keep the messages between two users in a single thread

i have seen this on closed question
{Yes, you can definitely do that.
In your MessagesController@index method, you'll have to use $threads = Thread::forUser($currentUserId); as shown in the example file.
This will make sure that your users only see the threads that they are participating in.
In your MessagesController@show method you'll have to do a check in order to see if the current user is a participant in the thread that they are requesting.
You can do this fairly easily - after line 55 add: $thread->getParticipantFromUser(Auth::id());
You'll have to create a different route for your create method that will include a user id to add as a participant. So maybe something like Route::get('create/{toUser}', ['as' => 'messages.create', 'uses' => 'MessagesController@create']);
Then in your store method you'll just use the current user id and the toUser as the participants.}
i dont get this part
"Then in your store method you'll just use the current user id and the toUser as the participants."
how to do that?

I am sorry but looking at the last few "issues" you have created none of them are issues
and they draw a quite clear picture of your ability's, you really should start by learning how to use Laravel and maybe php in general there are plenty of tutorials and guides on the web, for laravel specific I would suggest laracasts.com

Please see #15


[5.3] Fixes for RedisQueue

Reopening of #12655
Changes

Implement migrateExpiredJobs() using eval instead of watch-multi-exec (check and set) transactions to prevent issue #12653.
Increment attempts counter when reserving job, instead of when releasing it, so that fatal errors be considered as tries.
Migrate expired delayed jobs but not expired release ones when expire is null. Issue #12595
A few transaction guards for the times we moving jobs between main/reserved and delayed queues, so that the jobs are not lost in Redis server in the case of network/client failures.

Upgrade guides required
The changes require Redis >= 2.6.0. I don't think it will be an issue, since 2.6.0 itself is too old! Also, Redis eval command should not be disabled in the Redis configuration file, which I don't think is a big deal - why should somebody do that.

Please squash to one commit.


Where can I get the datasets?

The link is in the notebook.
https://quantquote.com/historical-stock-data

@vaektor Great ..thanks for help.


Colored self-attention map visualization seems to be wrong in the Colab

Hi, thanks for the great work :)
I have a question about colored self-attention map visualization.
The colored self-attention map visualization example in the Colab visualize only 6 heads for ViT-B model, which has 12 heads.
I guess the current code is only working for the ViT-S model.
I fixed it by revising the company_colors definition and head parameter in show_attn_color() as shown below.

Open for the full code
from analysis.attention_map.visualize_attention import apply_mask2

transform = pth_transforms.Compose([
    pth_transforms.Resize([480, 480]),
    pth_transforms.ToTensor(),
    pth_transforms.Normalize((0.485, 0.456, 0.406), (0.229, 0.224, 0.225)),
])

company_colors = [
    (0,160,215), # blue
    (220,55,60), # red
    (245,180,0), # yellow
    (10,120,190), # navy
    (40,150,100), # green
    (135,75,145), # purple
    (255,165,0), # orange
    (124,252,0), # lawn green
    (0,255,255), # cyan
    (135,206,235), # sky blue
    (255,105,180), # hot pink
    (139,69,19), # saddle brown
]
company_colors = [(float(c[0]) / 255.0, float(c[1]) / 255.0, float(c[2]) / 255.0) for c in company_colors]

def show_attn(img, index=None):
    w_featmap = img.shape[-2] // 16
    h_featmap = img.shape[-1] // 16

    attentions = vit.get_last_selfattention(img.cuda())

    nh = attentions.shape[1] # number of head

    # we keep only the output patch attention
    attentions = attentions[0, :, 0, 1:].reshape(nh, -1)

    # we keep only a certain percentage of the mass
    val, idx = torch.sort(attentions)
    val /= torch.sum(val, dim=1, keepdim=True)
    cumval = torch.cumsum(val, dim=1)
    th_attn = cumval > (1 - 0.6)
    idx2 = torch.argsort(idx)
    for head in range(nh):
        th_attn[head] = th_attn[head][idx2[head]]
    th_attn = th_attn.reshape(nh, w_featmap, h_featmap).float()
    # interpolate
    th_attn = nn.functional.interpolate(th_attn.unsqueeze(0), scale_factor=16, mode="nearest")[0].cpu().numpy()

    attentions = attentions.reshape(nh, w_featmap, h_featmap)
    attentions = nn.functional.interpolate(attentions.unsqueeze(0), scale_factor=16, mode="nearest")[0].cpu().numpy()

    # save attentions heatmaps
    prefix = f'id{index}_' if index is not None else ''
    os.makedirs('pics/', exist_ok=True)
    torchvision.utils.save_image(torchvision.utils.make_grid(img, normalize=True, scale_each=True), os.path.join('pics/', "img" + ".png"))
    img = Image.open(os.path.join('pics/', "img" + ".png"))

    attns = Image.new('RGB', (attentions.shape[2] * nh, attentions.shape[1]))
    for j in range(nh):
        fname = os.path.join('pics/', "attn-head" + str(j) + ".png")
        plt.imsave(fname=fname, arr=attentions[j], format='png')
        attns.paste(Image.open(fname), (j * attentions.shape[2], 0))

    return attentions, th_attn, img, attns

def show_attn_color(image, attentions, th_attn, index=None, head=[0,1,2,3,4,5]):
    M = image.max()
    m = image.min()
    span = 64
    image = ((image - m) / (M-m)) * span + (256 - span)
    image = image.mean(axis=2)
    image = np.repeat(image[:, :, np.newaxis], 3, axis=2)

    for j in head:
        m = attentions[j]
        m *= th_attn[j]
        attentions[j] = m
    mask = np.stack([attentions[j] for j in head])

    blur = False
    contour = False
    alpha = 1
    figsize = tuple([i / 100 for i in [480, 480]])
    fig = plt.figure(figsize=figsize, frameon=False, dpi=100)
    ax = plt.Axes(fig, [0., 0., 1., 1.])
    ax.set_axis_off()
    fig.add_axes(ax)
    ax = plt.gca()

    if len(mask.shape) == 3:
        N = mask.shape[0]
    else:
        N = 1
        mask = mask[None, :, :]

    # AJ
    for i in range(N):
        mask[i] = mask[i] * ( mask[i] == np.amax(mask, axis=0))
    a = np.cumsum(mask, axis=0)
    for i in range(N):
        mask[i] = mask[i] * (mask[i] == a[i])

    colors = company_colors[:N]

    # Show area outside image boundaries.
    height, width = image.shape[:2]
    margin = 0
    ax.set_ylim(height + margin, -margin)
    ax.set_xlim(-margin, width + margin)
    ax.axis('off')
    masked_image = 0.1*image.astype(np.uint32).copy()
    for i in range(N):
        color = colors[i]
        _mask = mask[i]
        if blur:
            _mask = cv2.blur(_mask,(10,10))
        # Mask
        masked_image = apply_mask2(masked_image, _mask, color, alpha)
        # Mask Polygon
        # Pad to ensure proper polygons for masks that touch image edges.
        if contour:
            padded_mask = np.zeros(
                (_mask.shape[0] + 2, _mask.shape[1] + 2))#, dtype=np.uint8)
            padded_mask[1:-1, 1:-1] = _mask
            contours = find_contours(padded_mask, 0.5)
            for verts in contours:
                # Subtract the padding and flip (y, x) to (x, y)
                verts = np.fliplr(verts) - 1
                p = Polygon(verts, facecolor="none", edgecolor=color)
                ax.add_patch(p)
    ax.imshow(masked_image.astype(np.uint8), aspect='auto')
    ax.axis('image')
    #fname = os.path.join(output_dir, 'bnw-{:04d}'.format(imid))
    prefix = f'id{index}_' if index is not None else ''
    fname = os.path.join('pics/', "attn_color.png")
    fig.savefig(fname)
    attn_color = Image.open(fname)
    return attn_color

img = transform(img)
# make the image divisible by the patch size
w, h = img.shape[1] - img.shape[1] % 16, img.shape[2] - img.shape[2] % 16
img = img[:, :w, :h].unsqueeze(0)
attentions, th_attn, pic_i, pic_attn = show_attn(img)
pic_attn_color = show_attn_color(img[0].permute(1, 2, 0).cpu().numpy(), attentions, th_attn, head=[i for i in range(th_attn.shape[0])])
final_pic = Image.new('RGB', (pic_i.size[1] * 2 + pic_attn.size[0], pic_i.size[1]))
final_pic.paste(pic_i, (0, 0))
final_pic.paste(pic_attn_color, (pic_i.size[1], 0))
final_pic.paste(pic_attn, (pic_i.size[1] * 2, 0))
display(final_pic)

And the results are as below.
Colored self-attention map with 6 heads (current Colab)

Color self-attention map with 12 heads (Revised)

Can you check if this is correct?

Hi @kobiso,
You're right and thanks for pointing it out! Feel free to make a pull request. That will be greatly appreciated.


fix(curriculum): display console.log as inline code instead of code block

Checklist:

[x] I have read and followed the contribution guidelines.
[x] I have read and followed the how to open a pull request guide.
[x] My pull request targets the main branch of freeCodeCamp.
[x] I have tested these changes either locally on my machine, or GitPod.

Closes #56643

Update formatting on quiz.

Hi @schofield-paul . Congrats on your first pull request (PR)! 🎉
Thank you for your contribution to the page! 👍
We are happy to accept these changes and look forward to future contributions. 📝


Host receive dependecy from Child MFE

Hi
I have two microfrontends applications (Host and Product) in angular v.13 and using the concept of module federation with webpack 5. My Product application uses the Angular Material library and when I'm running the Product application and accessing it through local url, the button (with angular material styles) renders correctly. However, when I access through my Host application, the button lose the styles coming from angular material. I wouldn't want to have to add Angular Material as a dependency of my Host application. Is there any way for the Product application to export angular material styles and settings?
Tks

Hi @Eduk29
The way we did this was to:

create a shared library containing all of our styling (including setup of material)
create another library that exposes Angular Material modules (something in the lines of https://fireflysemantics.medium.com/creating-a-shared-angular-material-module-73dfb32f0838) - simply create an angular library and re-export the material modules that your application needs.

Shared styling
Update the project.json both apps:
"targets": {
  "build": {
      ...
       "assets": [
          "apps/<app-name>/app/src/favicon.ico",
          "apps/<app-name>/main-window/app/src/assets",
          { // this snippet is not directly related to your question but a nice way to share assets
            "glob": "**/*.{png,json,jpg}",
            "input": "libs/shared/resources/src/lib",
            "output": "./assets"
          }
        ],
        "styles": ["apps/<app-name>/app/src/styles.scss"],
        "stylePreprocessorOptions": {
          "includePaths": ["libs/shared/theme/src/lib/scss"]
        },
  }
}

Finally, in apps/<app-name>/app/src/styles.scss import your theme (we are using scss)
@import 'theme';

This assumes that the styles are exposed as a barrel scss exported via index.ts. In out theme library we have libs/shared/theme/src/lib/scss/theme.scss containing:
@import './normalize.scss';
@import './init-basics.scss';
@import './colors.scss';
@import './material.scss';
@import './fonts.scss';
@import './tailwind.scss';

As we added the whole folder as stylePreprocessorOptions in project.json, simply adding @import 'theme' will pick up the theme.scss file at libs/shared/theme/src/lib/scss/theme.scss.
This pattern can be repeated for all MFE apps to share stylings (including material stylings).
Shared Angular Material Module
The shared Angular Material module from step 2 should simply be imported at the parts of your application that needs material components.

Hope I managed to explain how this could be accomplished


Question about limitation

As I see, this package stores data in SharedPreferences. Is there any limitation on the size of stored data?

Limitation is scoped by SharedPreferences and I'm not sure what is the exact limit or what variables affect that limit. If you want to have a different implementation, you may want to create your custom Storage implementation.


first_image shape is inverted in load_image function

ERROR
Traceback (most recent call last):
File "fid.py", line 280, in <module>
    images1 = load_images(options.path1)
  File "fid.py", line 251, in load_images
    final_images[idx] = im
ValueError: could not broadcast input array from shape (128,96,3) into shape (96,128,3)
This occurs because at line 242 W, H = first_image.shape[:2]  height and width dimensions are switched.

Thank you for the solution


CF enable-service-access fails when already exists

Command
cf enable-service-access myservice myorg
What occurred, incl. error and/or stack trace
Exits with error code 1 when already exists
What you expected to occur
Because it already exists, the command has in fact succeeded, not failed
CLI Version
6.21.1
CC API Endpoint Version
2.57.0
Platform & Shell Details
All
Any other relevant information
cf commands need to be idempotent and work as expected, current work around is we disable all prior to enabling otherwise we cannot reasonably check bash errors

Hi @sharms
What flags and arguments are you passing in to the command?
Can you attach the output of running the command with the -v option?
I can't reproduce the issue:
D:\Users\koperd\Downloads\bin>cf enable-service-access dummy-dev -o dies-test
Enabling access to all plans of service dummy-dev for the org dies-test as admin...
OK

D:\Users\koperd\Downloads\bin>cf enable-service-access dummy-dev -o dies-test
Enabling access to all plans of service dummy-dev for the org dies-test as admin...
OK

D:\Users\koperd\Downloads\bin>echo %ERRORLEVEL%
0

Closing. Feel free to reopen or submit a new issue if you can help us reproduce it.

jmcarp@Joshuas-MBP-3|~/code
) cf --version
cf version 6.21.1+6fd3c9f-2016-08-10
jmcarp@Joshuas-MBP-3|~/code
) cf enable-service-access mysql56-multinode -p persistent -o cloud-gov
Enabling access to plan persistent of service mysql56-multinode for org cloud-gov as services...
OK
jmcarp@Joshuas-MBP-3|~/code
) cf enable-service-access mysql56-multinode -p persistent -o cloud-gov
Enabling access to plan persistent of service mysql56-multinode for org cloud-gov as services...
FAILED
Server error, status code: 400, error code: 260002, message: This combination of ServicePlan and Organization is already taken: organization_id and service_plan_id unique
-> [1]

@dkoper: the snippet above should reproduce the error on the latest cli version. Can you reopen this?

Ping @dkoper

@SocalNick Is this expected API output? I believe other CC APIs are idempotent and may at most return a warning?

I cannot reproduce. Can you tell us how the mysql56-multinode service offering was created?
$ cf --version
cf version 6.22.1+6b7af9c-2016-09-24
$ cf enable-service-access fake-service-a64c0e1b-0595-4e5c-bcd0-4abe8310b132 -o nick
Enabling access to all plans of service fake-service-a64c0e1b-0595-4e5c-bcd0-4abe8310b132 for the org nick as admin...
OK
$ cf enable-service-access fake-service-a64c0e1b-0595-4e5c-bcd0-4abe8310b132 -o nick
Enabling access to all plans of service fake-service-a64c0e1b-0595-4e5c-bcd0-4abe8310b132 for the org nick as admin...
OK
$ cf enable-service-access fake-service-a64c0e1b-0595-4e5c-bcd0-4abe8310b132 -o nick -p fake-plan
Enabling access to plan fake-plan of service fake-service-a64c0e1b-0595-4e5c-bcd0-4abe8310b132 for org nick as admin...
OK
$ cf enable-service-access fake-service-a64c0e1b-0595-4e5c-bcd0-4abe8310b132 -o nick -p fake-plan
Enabling access to plan fake-plan of service fake-service-a64c0e1b-0595-4e5c-bcd0-4abe8310b132 for org nick as admin...
OK

I have the issue as well.  Why not just return 200 OK ?
`
REQUEST: [2016-11-30T11:20:59+08:00]
POST /v2/service_plan_visibilities HTTP/1.1
Host: ....
Accept: application/json
Authorization: [PRIVATE DATA HIDDEN]
Connection: close
Content-Type: application/json
User-Agent: go-cli 6.22.1+6b7af9c / darwin
{"service_plan_guid":"f0613dcf-4d5b-4867-9d54-52f6a5919884", "organization_guid":"8a8610e1-ada4-4607-8f0a-d81f4b71cc94"}
RESPONSE: [2016-11-30T11:21:02+08:00]
HTTP/1.1 400 Bad Request
Connection: close
Transfer-Encoding: chunked
Content-Type: application/json
Date: Wed, 30 Nov 2016 03:21:00 GMT
Server: nginx
X-Backside-Transport: FAIL FAIL
X-Content-Type-Options: nosniff
X-Global-Transaction-Id: 16543521
d0
{
"code": 260002,
"description": "This combination of ServicePlan and Organization is already taken: organization_id and service_plan_id unique",
"error_code": "CF-ServicePlanVisibilityAlreadyExists"
}
0
FAILED
Server error, status code: 400, error code: 260002, message: This combination of ServicePlan and Organization is already taken: organization_id and service_plan_id unique
`

Hi all,
I apologize, my reproduction attempt before wasn't valid. I was able to reproduce and I believe the API is responding appropriately. HTTP POST is not considered to be an idempotent operation. The relationship between service plan and organization already exists, so 400 is appropriate.

Yes, that is why this issue is filed under cli - while POST is not idemponent, I don't see why it wouldn't use POST, furthermore I don't think the cf command should ever return an error to configure a service correctly which is configured correctly.

CLI could potentially look for existing visibility using GET /v2/service_plan_visibilities?q= organization_guid:<org_guid>&q= service_plan_guid:<service_plan_guid> before doing the POST.

Yes, agree.   The cli should check the existing visibility with GET first, then return OK if the relationship is here.  Another sample in cli is :
$cf create-service   test
Creating service instance test in org xxxx/xxxx as admin:
OK
Service test already exists
$echo $?
0
In this implementation, cli do "get" services first, and return 0 when it  exists

+1 ran into this issue recently as well and would love to idempotently enable-service-access.

Is this still in progress? I'd love to have an easy way to make sure in a script that a service is available for an org....

Hi @holgero thanks for reaching out. We still plan on reviewing this issue once we've had a chance to rewrite this command. We hope the rewrite will fix the issue but it does not, we will look into it separately. Thanks.

Hi，everyone：
Execute command times following error. How do I fix it？

cf enable-service-access bookstore -o CrazyJvm-Org
Enabling access to all plans of service bookstore for the org CrazyJvm-Org as<EMAIL_ADDRESS>Service Plan Visibility is invalid: service_plan is from a private broker
FAILED

cf version 6.41.0+dd4c76cdd.2018-11-28

Hi @icodelabs - looks like you're trying to enable service access to a plan that's offered by a space-scoped broker, which isn't allowed. Space-scoped brokers can only expose their service offerings to the space to which they are scoped.

FYI: We've merged the fix, it should be available in the next CLI release :)


updated Docker file

:star: PR built and available in a preview environment anners-python-http-pr-2 here


Zachmu/index or bug fix

Fixed a bug in indexing code that would cause queries to return incorrect results. Along the way, implemented index capabilities for the in-memory tables (only for correctness verification), and expanded engine_test to test every combination of indexes, partitions, and parallelism.

@Hydrocharged , please give this a quick sanity check. I know it's big, so don't worry about verifying every line. But let me know if there are any glaring errors I should fix before sending this to src-d.


[Web Drop-in] Allow hiding amount

Is your feature request related to a problem? Please describe.
In my team we are working a lot with recurring payments. The button that is rendered by the drop-in contains the preauthorization amount that we are charging. We'd like the to be able to hide that amount and be fully in control of the copy inside of the button. Currently it seems to work if the amount equals zero (thanks to this PR), but since we are usually charging (only to immediately refund that amount) 0,01€ that always shows up in the button. We have tried to override it manually by passing amount: { value: 0, currency: '...' } to the config object, but that doesn't work. We have also tried to implement our own button component, but we ran into issues since PayPal doesn't support calling submit programatically. We exist on many different markets with varying payment methods, so we need a solution that works in all cases.
Currently we are exploring hacks to be able to handle the copy ourselves. We feel we shouldn't have to resort to this in order to get the UI right.
We saw a similar request has been closed before. The recommended solution doesn't work in our case due to the limited compatibility of a custom button implementation.
Describe the solution you'd like
Enable passing a boolean for hiding the amount from the button. hideAmount: boolean would work just fine. For our purposes it would be fine just allowing it for preauthorization payments since we do wanna show the amount for actual purchases.
Describe alternatives you've considered

Passing { amount: 0 } to the the config manually.
Using a hacky MutationObserver API solution to alter the drop-in after it is ready.
Custom button implementation.

Hi @hbystrom91 - can you please elaborate on why using your own, custom, pay button doesn't work for you?
This would still be our recommended solution. It shouldn't conflict with PayPal since that renders it's own pay button

Hi @hbystrom91 - can you please elaborate on why using your own, custom, pay button doesn't work for you? This would still be our recommended solution. It shouldn't conflict with PayPal since that renders it's own pay button

Absolutely! To use our own button we need to say showPayButton: false to avoid displaying two buttons. This removes the button for all payment methods, including PayPal and Apple Pay. I guess a potential solution would be to keep track of the selected payment method and add display: 'hidden' to the default button depending on that. However, that's outside of your API and it also feels like a hack in a sense. Hope that's enough.

@hbystrom91 - I see your problem!
However you can overcome this by setting the general, showPayButton: false, when instantiating Checkout but specifying in the paymentMethodsConfiguration object that the button should be shown for PayPal/ApplePay:
const checkout = await AdyenCheckout(
{
  showPayButton: false,
  paymentMethodsConfiguration: {
    paypal: {
      showPayButton: true
    },
    applepay: {
      showPayButton: true
    }
  }
})

@hbystrom91 - I see your problem! However you can overcome this by setting the general, showPayButton: false, when instantiating Checkout but specifying in the paymentMethodsConfiguration object that the button should be shown for PayPal/ApplePay:
const checkout = await AdyenCheckout(
{
  showPayButton: false,
  paymentMethodsConfiguration: {
    paypal: {
      showPayButton: true
    },
    applepay: {
      showPayButton: true
    }
  }
})

Interesting. I don't know how I missed that. With that information in mind we should have all we need. Thanks for helping us out.


Inline flex fix

Anything with the right hand value that contained flex would be replaced with flex ONLY.  So, inline-flex was being replaced to flex.
With this little regex solution, you can now have both inline-flex and flex work, it will just use what it finds there.
Tested this locally, and it seemed to fix the issue.

@cgood92 thank you!


License question

Hey guys!
First of all, this is a really cool project. It's lovely to see well integrated Swift libraries, great job.
Secondly, I have a small question regarding the licensing. GEOSwift is MIT licensed, which is really nice. However, it is based on GEOS, which is LGPL. Does this mean that if I want to use GEOSwift in my iOS application, I effectively have to make it open source? Or is the actual situation different?
Thanks in advance.

@egorf good question, but probably not one that is best answered here. You'll find many discussions of this topic if you search "iOS LGPL". You may also want to reach out to the GEOS team and seek your own legal counsel.


Shift key still considered pressed after open link in browser

Godot version: v3.1.2.stable.offical
OS/device including version: macOS Catalina 10.15.1 / MacBook Pro (Retina, 13-inch, Early 2015)
Issue description:
In the "Download Templates" dialog, you can Shift + Click to open the link in browser.

If I shift click the link and then get back to Godot, clicking the link again without the shift key pressed will still open the link in the browser.
Godot thinks that the shift key is still pressed even if I close the Export Template Manager dialogs and open them again.
I think it's because that the shift key is pressed in Godot and unpressed in the browser. So that godot never get the unpressed event. When I go back to Godot from the browser, press the shift key once indeed reset the shift key state, and then the click works as normal.
Steps to reproduce:

Open any project
Click menu: Editor -> Manage Export Templates
Click the Download button to open the "Download Templates" dialog
Shift click the link, to open it in the browser. DON'T release the shift key untill you are in the browser.
Switch back to Godot, click the link again without the shift key pressed
The browser still opens
Switch back to Godot, close the "Download Templates" and "Export Template Manager" dialogs, and open the dialogs again
Clicking the link without shift key still opens the browser
Switch back to Godot, press the shift key once, and click the link without shift key pressed
The download starts as normal

Related to #33928.


New MapTiler 6.4 fails periodically on production server

Maptiler 6.4 has replaced Maptiler 5.5 on production server. Maptiler 6.4 requires the license as an environmental variable, because the production server runs in a virtual machine. This gives problems because the application is executed as a linux service and normail environmental variables are not present for services. First fix attempted was to create maptiler-pro.sh file which exports the variable and the executes maptiler. File content:
export MAPTILER_LICENSE=XXXX-XXXX-XXXX-XXXX-XXXX
maptiler ....

But it seems random when maptiler actually picks up the license from the environmental variable and when it does not.

environmental variables behaved differently on Redhat (production), than on Ubuntu. (dev). Solved by correct installation in production.


JWT claims conditions for advanced throttling is not working

Description:
JWT claims condition for advanced throttling policies is not working
Steps to reproduce:

Add enable_jwt_claim_based_throttling = true under apim.throttling in deployment.toml.
Start the server.
Define JWT Condition Policy in a new Advanced Policy.
Add the defined policy for an API.
Invoke and check whether requests get throttled.

Refer to docs for more info.

This cannot reproduce in latest pack


raise optparse-applicative upper bound

Can we raise the upper bound on optparse-applicative?
The test suite produces the same error with optparse-applicative 0.15 and 0.17:
Error: cabal: Tests failed for test:hypsrc-test from haddock-2.27.0.

The other tests pass with both 0.15 and 0.17.
If optparse-applicative-0.17 is allowed, I think it will be easier to use haddock-library with Nix.
optparse-applicative is on 0.17 in nixpkgs-unstable: https://search.nixos.org/packages?channel=unstable&show=haskellPackages.optparse-applicative&from=0&size=50&sort=relevance&type=packages&query=optparse-applicative Using the alternative optparse-applicative_0_15_1_0 may have other issues.

@Kleidukos can this be merged? Thanks

Sorry for the delay :)


miden-client init defaults

What should be done?
Update the init command to enable initialization of the config file with good defaults
How should it be done?
We need two flags:

miden-client init --default should make the interactive command into a non-interactive command that just initializes everything with the suggested defaults
miden-client init --testnet should initialize the toml file with defaults, but point to the testnet DNS name.

When is this task done?
When the two flags are implemented.
Additional context
Tagging @Dominik1999 in case he wants to provide more context

Is the primary job of the init command adding node endpoint to the client config? If so, it's probably pass the endpoint as a parameter. For example:
miden-clinet init --rpc devnet.miden.io
miden-clinet init --rpc testnet.miden.io

The --rpc parameter could take anything that is a URL - e.g., it could be an IP address (with or without port number).
I think the overall effect is the same, but what is happening is a bit more explicit.

The init command creates the miden-client.toml in the current dir, so it initializes the RPC and the Store config. I think your suggestion would work fine anyway.

In the future, we could also add an option to specify that a default account should be created at init time. This way, after init completes, the client should be immediately usable.


When the modifier_data_deposit runs exception retrieve data runs anyway

When the modifier_data_deposit runs exception, retrieve data runs anyway. backend_data_retrieval container should stop, but it doesn't in this case.

This is a part of #269


Include Option for Desktop Shortcut to QMC Utils in Installation

URL configuration is in documentation but can be complex. Easier to supply a desktop shortcut, especially with the trailing forward slash requirement.

Won't fix.  Adding an icon with proper server name is a function of installer and with pending changes to installation methodology for QMC Utilities this is not possible.


New version: Meitu.ColorByte version 5.7.0

Created by 🥟 Dumplings in workflow run #6464.

Log
Updated: 5.6.5 → 5.7.0
No ReleaseNotesUrl for version 5.7.0
Submitting WinGet manifests
Creating manifests
Uploading manifests and making commits
Creating a pull request

Microsoft Reviewers: Open in CodeFlow

/azp run

/azp run

[Policy] Needs-Manual-Merge

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


Add support for phinx.

Phinx is a database migration utility for PHP and can be installed through composer.
I believe this is installed much like composer was, but I did this to enable it and add it to the system path.
composer global require "robmorgan/phinx:*"
export PATH=$PATH:/home/vagrant/.composer/vendor/bin

New version #155 will allow any ansible galaxy playbooks so I will be relying on most of them or 3rd parties to maintain the playbooks.


Better handle missing data in histograms and cumulative incidence plots

resolved in afad61b.
Previously in Mortality section Association table and Mortality risk table were filled with "no data" text and 0's were shown for case counts in cases where no data was available for that section.

Now the look is simplified and clarified to show only "no data" text when there's no data at all for a given part (association or mortality risk) of the mortality section. Examples below
no data at all:

no data from other sex:

no mortality risk estimates in selected ages:


Making geometry and bbox optional.

Making geometry and bbox optional to support optional geometry.
I tried adding a validator to check that bbox is present when geometry is present but it seemed to fail all the tests using the factory.
closes #51

@rsmith013 geometry and bbox are required fields (which can be set to null), but I believe exporting this as JSON would cause you to either have to include all null fields (in which case many optional fields would be serialized as null values), or produce JSON that didn't have a "geometry" or "bbox" property. Is that the case with this change? Do you have any ideas on how to work around that, so geometry and bbox are always included even if the are None values?

For context, the initial use case for this ticket was using the STAC filter extension in stac-fastapi to exclude geometry fields which is a common way to reduce the size of payloads returned by the API, especially if the caller is just interested in metadata.  Now that stac-fastapi is moving away from pydantic for API response serialization I think it makes the most sense to keep geometry as a required field.

@lossyrob  OK. As this stands, it would lead to allowing JSON without the geometry or bbox property which breaks the convention. The motivation was that this causes conflict in stac-fastapi where geometry or bbox not available but as @geospatial-jeff has mentioned, stac-fastapi is moving away from pydantic for response serialisation.
This does still raise the question of, if it remains a required field, how do you validate a model with a null geometry bbox which is valid STAC? Setting to None will raise a validation error and using "null" will also produce a validation error and not serialise correctly even if it was allowed.
stac-fastapi uses exclude_none=True on the dict and json methods of Pydantic BaseModel. Maybe stac-pydantic would need to modify those to allow None through for bbox and geometry fields even where exclude_none=True

Maybe stac-pydantic would need to modify those to allow None through for bbox and geometry fields even where exclude_none=True

I think that's the fix...I'm not versed enough in Pydantic to know how to pull that off. Anyone else know how to accomplish this?

I think it would be possible to override the .dict() method on the class, and do special handling of the exclude_none parameter?

Both the geometry and the bbox are now optional, so I think this PR can be closed, see
https://github.com/developmentseed/geojson-pydantic/pull/47
https://github.com/stac-utils/stac-pydantic/pull/108

Closing as this appears to have been superseded


TransferCoding is not a case class

Its equality semantics are not consistent with the equality of its components.  Better to just make this a wrapper class, like Scheme.

Pinged @cquiroz since he did the work, but I think several people were around when we discussed case class expectations.  Anyone's review is good here.


Drawer security : see text update from hugo on slack / marketing

Verify issuer website identity
Default: Off
Enable to verify website identity before access.
Confirm verifier access
Default: On
Disable to skip confirmation when you share your verifiable credentials.
Secure Authentication with PIN Code
Default: On
Turn off to skip PIN code for website authentication (not recommended).


⚠ Processors has degraded performance

In 9ac0e71, Processors ($STATUS_URL) experienced degraded performance:

HTTP code: 200
Response time: 79 ms

Resolved: Processors performance has improved in 22f938a.


feat: promote Pendulum dapp

Should we also add it to the dapps_full ?

already added occasionally here:
https://github.com/novasamatech/nova-utils/pull/1782


[useQuery] Skip the first fetch

Hi,
I'm currently trying react-navi library as a routing solution (cc @jamesknelson).
It has an interesting approach in which you can provide a route's data before the route's component is rendered. (see getData here).
So the idea is to fetch the route's data first using directly apollo-client, and then to subscribe to eventual refetchs inside the component using useQuery.
My main issue is that when declaring useQuery inside the component, the query gets fired on mount. I'd like to skip this first query and only "subscribe for updates". Do you think it's possible with the current API? If not, would you consider adding an option to avoid the first fetch when declaring useQuery? Maybe adding a skipFirst option or allowing to pass initialData to useQuery so it doesn't fire a fetch but return the initialData instead?
My current code is like this :
export default route({
  title: "List of actions",
  getData: (_, { graphqlClient }) => graphqlClient.query(GET_ACTIONS),
  view: <ActionListPage />
})

function ActionListPage(props) {
  // the page receive props.data

  // here I only want "updates" to avoid the initial fetching that I already got from above
  let {
    data: { actions = [] },
    loading,
    error
  } = useQuery(GET_ACTIONS)
  // possible APIS :
  // useQuery(GET_ACTIONS, {}, { initialData: props.data })
  // useQuery(GET_ACTIONS, {}, { skipFirst: true })

 // boring JSX...
}

It should be achieved with fetchPolicy option.

@umidbekk could you please give us a working example?
It would need a fetchPolicy that skips the first fetch and then you can use refetch to get the data, but I don't see any ...

Incorrect. This is done with the skip option. In your case:
let {
    data: { actions = [] },
    loading,
    error
  } = useQuery(GET_ACTIONS, {
    skip: true
})


DeprecationWarning for inspect.getargspec in Python 3.5

When running newest version of sh under Python 3.5.
Reproduction: use sh with _out or _err with custom callbacks.
/.../lib/python3.5/site-packages/sh.py:1073: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() instead
  num_args = len(inspect.getargspec(handler_to_inspect).args)

thanks for reporting @jgoclawski


Unhandled SecurityException: Resolved path jumped beyond configured root

Seems like some users with super user privilege are causing a crash on the library. Here is the stack trace:
Fatal Exception: java.lang.SecurityException: Resolved path jumped beyond configured root
       at androidx.core.content.FileProvider$SimplePathStrategy.getFileForUri(FileProvider.java:864)
       at androidx.core.content.FileProvider.openFile(FileProvider.java:630)
       at android.content.ContentProvider.openAssetFile(ContentProvider.java:2070)
       at android.content.ContentProvider.openAssetFile(ContentProvider.java:2131)
       at android.content.ContentProvider$Transport.openAssetFile(ContentProvider.java:496)
       at android.content.ContentResolver.openAssetFileDescriptor(ContentResolver.java:1860)
       at android.content.ContentResolver.openOutputStream(ContentResolver.java:1562)
       at com.canhub.cropper.BitmapUtils.writeBitmapToUri(BitmapUtils.kt:460)
       at com.canhub.cropper.BitmapCroppingWorkerJob$start$1$1.invokeSuspend(BitmapCroppingWorkerJob.kt:96)
       at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
       at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
       at kotlinx.coroutines.internal.LimitedDispatcher.run(LimitedDispatcher.kt:42)
       at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:95)
       at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.java:570)
       at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)
       at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:677)
       at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:664)

Can we add some try/catch to the writeBitmapToUri (BitmapUtils.kt) in order to handle the SecurityException, safely return error and prevent the app from crashing.

Can't you do this yourself?

Created the pull request https://github.com/CanHub/Android-Image-Cropper/pull/590, but i was not able to compile the library via JitPack, it gives error:
Could not resolve com.vanniktech:gradle-code-quality-tools-plugin:0.23.0.

Having similar crash reportsd, although devices are not rooted (based on Crashlytics data).
@EzequielAdrianM I saw that you created PR but declined it in the end. Was there any follow-up?

The PR didn't make any sense. You will need to FileProvider.getUriForFile together with a filepaths.xml file


How to use it with cuda in v0.0.5

Apologies - there was an issue with the build of the cuda docker image at v0.0.5. You can now use v0.1.0 with cuda:
v0.1.0-cuda11


refactor the redirector modules into the service and service-impl modules

I would like to see the redirector module moved from support into the services module and then the two implementations of the redirectors should be split out into their own modules under the services-impl along with the rest-redirector

merged into develop


assignment cannot find deep path

Version
Kestrel v1.5.7

Data
tests/test_bundle_nt_1.json

Huntflow
conns = GET network-traffic
        FROM file:///tmp/kestrel-test-data/nt_1.json
        WHERE src_ref.value LIKE '192.%'
        START 2022-01-01T00:00:00.000Z STOP 2023-01-01T00:00:00.000Z

c2 = conns WHERE dst_ref.value = '<IP_ADDRESS>'

Error
[ERROR] MissingEntityAttribute: variable "conns.dst_ref" does not have required attribute "value"
remove transform or specify different variable in the Kestrel command.

Found that the problem is not caused by variable recognition or deref. It is caused by the deep attribute/property/column that is actually a reference in firepit but we haven't supported the specific SQL query for it in Predicate() call.
More specifically, when an ECGP like conns WHERE dst_ref.value = '<IP_ADDRESS>' is converted to firepit query for assignment, the conversion creates a Predicate() object here.
The error from firepit is:
12:25:27 ERROR firepit.sqlitestorage PRAGMA table_info("c2"): no such column: conns.dst_ref.value

The error is caught by the assignment command in command.py here, thus throwing the MissingEntityAttribute error. The misinformation in the MissingEntityAttribute error is caused by the error parsing part in the command.py, which is easy to address.
The more difficult part and the key to solve the issue is to implement an additional part of Predicate() to handle reference like dst_ref.


add ProgressBar::abandon(), abandon_with_message()

I use abandon() so a user can still see the incomplete progress bar after a task fails.
Was there already a way to accomplish this? I couldn't find one.
Thanks,
Cory

Good idea.


internal data of String validator breaks AWG5014

In PR #859 new variables ._valid_values are added to the String validator. The default validator object qcodes.utils.validators.String() now has a size of 1 GB.
The AWG5014 driver uses the String validator four times, so the driver now is 4GB. If one reloads the driver 8 GB is occupied, which crashes a system with limited amount of RAM.
https://github.com/QCoDeS/Qcodes/blob/master/qcodes/instrument_drivers/tektronix/AWG5014.py#L326
I am not sure how the ._valid_values field is used, but I think it does not make a lot of sens for a String. Can we set the _valid_values field to None as a solution?
@WilliamHPNielsen @AdriaanRol @jenshnielsen @lucblom

Woops... Luckily the fix is straightforward.
I can even disclose that the _valid_values are not currently used for anything, but the great plan is to eventually use them to auto-generate simulated instruments from an instruments parameters.


Getting "Signature verification failed" when sending signed file too often

I did a manual test of this and found that gorjun starts to authorize normally approximately after one minute of idle.

Figured out that this is a cache problem

@crioto should work now

Thank you, Timur. I will test and report

On Oct 2, 2017, at 5:14 PM, Timur Zununbekov<EMAIL_ADDRESS>wrote:
@crioto https://github.com/crioto should work now
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/subutai-io/gorjun/issues/118#issuecomment-333505654, or mute the thread https://github.com/notifications/unsubscribe-auth/AAo9q2lHMaxEPbOgRmelPh83TsYtDlNBks5soMWugaJpZM4PqdxC.

Thanks, guys! Works perfectly!

On Oct 2, 2017, at 5:15 PM, Mikhail Savochkin<EMAIL_ADDRESS>wrote:
Thank you, Timur. I will test and report

On Oct 2, 2017, at 5:14 PM, Timur Zununbekov<EMAIL_ADDRESS><EMAIL_ADDRESS>wrote:
@crioto https://github.com/crioto should work now
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/subutai-io/gorjun/issues/118#issuecomment-333505654, or mute the thread https://github.com/notifications/unsubscribe-auth/AAo9q2lHMaxEPbOgRmelPh83TsYtDlNBks5soMWugaJpZM4PqdxC.

@crioto welcome