Websocket diff payload size is dramatically large

Hi,
Thanks for your great work on this library!
I have this fairly simple component that represents a page in my app:
defmodule TalkyWeb.Components.PodcastDetailsPage do
  use Surface.Component

  alias Surface.Components.Form.{Field, Label, Checkbox}
  alias Surface.Components.Form

  prop podcast, :map, required: true
  prop change, :event, required: true

  @impl true
  def render(assigns) do
    ~H"""

{{ @podcast.title }}

{{ @podcast.description }}

Episodes

      <li :for={{ episode <- @podcast.episodes }}>
        {{ episode.title }}

Feeds

      <li :for={{ feed <- @podcast.feeds }}>
        {{ feed.title || feed.url }}

    <Form for={{:podcast}} change={{@change}}>
      <Field name="is_feed_public">

        <Checkbox opts={{[checked: @podcast.is_feed_public]}} />
      </Field>
    </Form>
    """
  end
end

This is used by the parent Surface.LiveView, like this:
defmodule TalkyWeb.PodcastLive do
  use Surface.LiveView

  alias TalkyWeb.Components.PodcastDetailsPage
  alias Talky.Feeds

  data podcast, :map, default: nil

  @impl true
  def mount(%{"podcast_id" => podcast_id}, %{"user_token" => user_token}, socket) do
    if connected?(socket), do: Feeds.subscribe_podcast(podcast_id)

    user = user_token && Talky.Accounts.get_user_by_session_token(user_token)

    socket =
      socket
      |> assign(:current_user, user)
      |> assign_podcast(podcast_id)

    {:ok, socket}
  end

  def assign_podcast(socket, podcast_id) do
    podcast = Talky.Feeds.get_own_podcast_details(socket.assigns.current_user, podcast_id)
    assign(socket, :podcast, podcast)
  end

  @impl true
  def render(assigns) do
    ~H"""
    <PodcastDetailsPage
    :if={{@podcast}}
    podcast={{@podcast}}
    change="podcast_change"
    />
    """
  end

  @impl true
  def handle_event("podcast_change", %{"podcast" => params}, socket) do
    Feeds.update_podcast(socket.assigns.podcast, %{
      is_feed_public: params["is_feed_public"]
    })

    {:noreply, socket}
  end

  @impl true
  def handle_info({Feeds, [:podcast, :updated], podcast}, socket) do
    socket = assign(socket, :podcast, podcast)
    {:noreply, socket}
  end
end

In handle_event/3 a single boolean prop gets toggled on the Podcast struct stored in socket.assigns. The update is then broadcasted and handle_info/3 replace socket.assigns.podcast with the updated struct.
While this technically works, the payload sent over the wire is very much larger than I'd expect. The full struct is sent each time I toggle the checkbox, as well as the full static template.
I looked at the Surface docs/demos for clues, but found the same issue there (I guess). Take a look at Built-in Components/Form to get a feel for the issue.
Typing name "John Doe" and email<EMAIL_ADDRESS>the following payload is sent over the socket:
[
  "113",
  "159",
  "lv:FormInfo",
  "phx_reply",
  {
    "response": {
      "diff": {
        "0": {
          "0": " id=\"ComponentInfo_Form\"",
          "3": "Form",
          "4": "

\nDefines a form that lets the user submit information
\n
",
          "5": "",
          "6": "

\nProvides a wrapper for Phoenix.HTML.Form.form_for/3. Additionally,\nadds the form instance that is returned by form_for/3 into the context,\nmaking it available to any child input.
\n
\nAll options passed via opts will be sent to form_for/3, for\nand action can be set directly and will override anything in opts.
\n
",
          "7": {
            "1": {
              "0": {
                "0": "<form action=\"#\" autocomplete=\"off\" method=\"post\" phx-change=\"change\"><input name=\"_csrf_token\" type=\"hidden\" value=\"DXsyJSszDmdmDRErHARYTgstIDx1ARE0lHJIQZk3SaemSu0vfTVyXXTv\">",
                "1": {
                  "0": {
                    "0": {
                      "0": {
                        "0": " class=\"field\"",
                        "1": {
                          "0": {
                            "0": {
                              "0": {
                                "0": {
                                  "0": {
                                    "0": {
                                      "0": {
                                        "0": "Name"
                                      }
                                    }
                                  }
                                }
                              },
                              "1": " class=\"control\"",
                              "2": {
                                "0": {
                                  "0": {
                                    "0": {
                                      "0": {
                                        "0": "<input class=\"input\" id=\"user_name\" name=\"user[name]\" type=\"text\" value=\"John Doe\">"
                                      }
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      },
                      "1": {
                        "0": " class=\"field\"",
                        "1": {
                          "0": {
                            "0": {
                              "0": {
                                "0": {
                                  "0": {
                                    "0": {
                                      "0": {
                                        "0": "E-mail"
                                      }
                                    }
                                  }
                                }
                              },
                              "1": " class=\"control\"",
                              "2": {
                                "0": {
                                  "0": {
                                    "0": {
                                      "0": {
                                        "0": "<input class=\"input\" id=\"user_email\" name=\"user[email]\" type=\"text\"<EMAIL_ADDRESS>                                      }
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              },
              "1": "{\n  "email": "john@doe.com",\n  "name": "John Doe"\n}"
            }
          },
          "9": 1,
          "10": {
            "2": {
              "0": 2
            }
          }
        }
      }
    },
    "status": "ok"
  }
]

Perhaps this works as expected, but I thought the LiveView diffing used under the hood was smarter than this?
I'm new to both Phoenix and LiveView.

Hmm, does it make any difference if you use a stateful component (i.e., use Surface.LiveComponent and add an id)

Hmm, does it make any difference if you use a stateful component (i.e., use Surface.LiveComponent and add an id)

I converted the code you posted to just plain live view (it's not exact, but it's pretty close: https://github.com/lnr0626/large_diff_payload_web). When I click the checkbox, the diff sent across the wire is:
[
    "4",
    "5",
    "lv:phx-FluoWewwsTVidQUD",
    "phx_reply",
    {
        "response": {
            "diff": {
                "2": {
                    "0": {
                        "0": {
                            "0": "The one true podcast pfnY",
                            "1": "Some text about the pod cast....but wait, there's some randomness!! KgeqxMgNLANssHcvDgdnVPOxTVnrefyUsatCam",
                            "2": {
                                "d": [
                                    [
                                        "Episode Name UoeTCyExsv"
                                    ],
                                    [
                                        "Episode Name kRMDdbRODl"
                                    ],
                                    [
                                        "Episode Name rnVwWU US"
                                    ],
                                    [
                                        "Episode Name UWoKIIbIJg"
                                    ],
                                    [
                                        "Episode Name zTukPxqXP"
                                    ],
                                    [
                                        "Episode Name XBRTReshF"
                                    ],
                                    [
                                        "Episode Name IZbRUrpmk"
                                    ],
                                    [
                                        "Episode Name fmTCrjNltI"
                                    ]
                                ]
                            },
                            "3": {
                                "d": [
                                    [
                                        "Feed Name KWQkSQPpoy"
                                    ],
                                    [
                                        "Feed Name aPYIXwaa"
                                    ]
                                ]
                            },
                            "4": "<form action=\"#\" method=\"post\" phx-change=\"podcast_change\"><input name=\"_csrf_token\" type=\"hidden\" value=\"PCF9RwJ0CxokOQQ9HwNoOXhsAURiKBs2wND-HCGBi_uSmJ-UN3H-PQPi\">",
                            "5": "Is feed public",
                            "6": "<input name=\"podcast[is_feed_public]\" type=\"hidden\" value=\"false\"><input checked=\"true\" id=\"podcast_is_feed_public\" name=\"podcast[is_feed_public]\" type=\"checkbox\" value=\"true\">"
                        }
                    }
                }
            }
        },
        "status": "ok"
    }
]

There are some slight differences because I didn't do any styling (so no class="..." diffs), but the size/content is fairly comparable.
I also added an example using a live component, which resulted in the following diff when the checkbox was checked:
[
    "4",
    "5",
    "lv:phx-Fluq4XRTiDhPQgJk",
    "phx_reply",
    {
        "response": {
            "diff": {
                "2": {
                    "1": {
                        "0": 1
                    }
                },
                "c": {
                    "1": {
                        "4": "<form action=\"#\" method=\"post\" phx-change=\"podcast_2_change\"><input name=\"_csrf_token\" type=\"hidden\" value=\"fSRVWx1eHQt7KEc-QSNzKnMsDTBZGiku6Kl1WiQS6N6P3j6FEsDYkcbq\">",
                        "5": "Is feed public",
                        "6": "<input name=\"podcast[is_feed_public]\" type=\"hidden\" value=\"false\"><input checked=\"true\" id=\"podcast_is_feed_public\" name=\"podcast[is_feed_public]\" type=\"checkbox\" value=\"true\">"
                    }
                }
            }
        },
        "status": "ok"
    }
]

the demo site uses some stuff to avoid duplicating code between the examples and demos of the example, so the diffs on those may not be as optimized as the could be
@msaraiva may have some addition insight as he's more familiar with how the change tracking works

I converted the code you posted to just plain live view (it's not exact, but it's pretty close: https://github.com/lnr0626/large_diff_payload_web). When I click the checkbox, the diff sent across the wire is:
[
    "4",
    "5",
    "lv:phx-FluoWewwsTVidQUD",
    "phx_reply",
    {
        "response": {
            "diff": {
                "2": {
                    "0": {
                        "0": {
                            "0": "The one true podcast pfnY",
                            "1": "Some text about the pod cast....but wait, there's some randomness!! KgeqxMgNLANssHcvDgdnVPOxTVnrefyUsatCam",
                            "2": {
                                "d": [
                                    [
                                        "Episode Name UoeTCyExsv"
                                    ],
                                    [
                                        "Episode Name kRMDdbRODl"
                                    ],
                                    [
                                        "Episode Name rnVwWU US"
                                    ],
                                    [
                                        "Episode Name UWoKIIbIJg"
                                    ],
                                    [
                                        "Episode Name zTukPxqXP"
                                    ],
                                    [
                                        "Episode Name XBRTReshF"
                                    ],
                                    [
                                        "Episode Name IZbRUrpmk"
                                    ],
                                    [
                                        "Episode Name fmTCrjNltI"
                                    ]
                                ]
                            },
                            "3": {
                                "d": [
                                    [
                                        "Feed Name KWQkSQPpoy"
                                    ],
                                    [
                                        "Feed Name aPYIXwaa"
                                    ]
                                ]
                            },
                            "4": "<form action=\"#\" method=\"post\" phx-change=\"podcast_change\"><input name=\"_csrf_token\" type=\"hidden\" value=\"PCF9RwJ0CxokOQQ9HwNoOXhsAURiKBs2wND-HCGBi_uSmJ-UN3H-PQPi\">",
                            "5": "Is feed public",
                            "6": "<input name=\"podcast[is_feed_public]\" type=\"hidden\" value=\"false\"><input checked=\"true\" id=\"podcast_is_feed_public\" name=\"podcast[is_feed_public]\" type=\"checkbox\" value=\"true\">"
                        }
                    }
                }
            }
        },
        "status": "ok"
    }
]

There are some slight differences because I didn't do any styling (so no class="..." diffs), but the size/content is fairly comparable.
I also added an example using a live component, which resulted in the following diff when the checkbox was checked:
[
    "4",
    "5",
    "lv:phx-Fluq4XRTiDhPQgJk",
    "phx_reply",
    {
        "response": {
            "diff": {
                "2": {
                    "1": {
                        "0": 1
                    }
                },
                "c": {
                    "1": {
                        "4": "<form action=\"#\" method=\"post\" phx-change=\"podcast_2_change\"><input name=\"_csrf_token\" type=\"hidden\" value=\"fSRVWx1eHQt7KEc-QSNzKnMsDTBZGiku6Kl1WiQS6N6P3j6FEsDYkcbq\">",
                        "5": "Is feed public",
                        "6": "<input name=\"podcast[is_feed_public]\" type=\"hidden\" value=\"false\"><input checked=\"true\" id=\"podcast_is_feed_public\" name=\"podcast[is_feed_public]\" type=\"checkbox\" value=\"true\">"
                    }
                }
            }
        },
        "status": "ok"
    }
]

the demo site uses some stuff to avoid duplicating code between the examples and demos of the example, so the diffs on those may not be as optimized as the could be
@msaraiva may have some addition insight as he's more familiar with how the change tracking works

Using a stateful component the payload size changes from ~900 to ~600 bytes. The whole form markup is still sent with each toggle of the checkbox.
@Inr0626 interesting, that seems to have improved it by quite a bit. I still don't understand why the markup is sent with each change, though.

Using a stateful component the payload size changes from ~900 to ~600 bytes. The whole form markup is still sent with each toggle of the checkbox.
@Inr0626 interesting, that seems to have improved it by quite a bit. I still don't understand why the markup is sent with each change, though.

Hey @miickel!
As already mentioned, change tracking has its limitations. As far as I can remember, change tracking is disabled inside functions like form_for and any other helper function depending on content_tag. That's actually the only reason we don't care much about passing assigns to helper functions inside form controls. We'd probably need to run some additional tests to confirm that but based on the results of @lnr0626's experiments, I'd say that that assumption is correct.
I believe this could be addressed (or at least improved) when LV introduces the new functional component which might replace those helper functions allowing change tracking.
In case you want to run some extra benchmarks to make sure, I'd advise following @lnr0626 steps and try to create a minimal example in plain LV. If the issue is not present then we may have a way to optimize it on the Surface side.
I'm closing this issue for now but feel free to reopen it in case you have any update.
Thanks for the provided example and the detailed explanation.

Hey @miickel!
As already mentioned, change tracking has its limitations. As far as I can remember, change tracking is disabled inside functions like form_for and any other helper function depending on content_tag. That's actually the only reason we don't care much about passing assigns to helper functions inside form controls. We'd probably need to run some additional tests to confirm that but based on the results of @lnr0626's experiments, I'd say that that assumption is correct.
I believe this could be addressed (or at least improved) when LV introduces the new functional component which might replace those helper functions allowing change tracking.
In case you want to run some extra benchmarks to make sure, I'd advise following @lnr0626 steps and try to create a minimal example in plain LV. If the issue is not present then we may have a way to optimize it on the Surface side.
I'm closing this issue for now but feel free to reopen it in case you have any update.
Thanks for the provided example and the detailed explanation.


⚠ Bofrost.at has degraded performance

In b67f880, Bofrost.at (https://www.bofrost.at) experienced degraded performance:

HTTP code: 200
Response time: 1205 ms

Resolved: Bofrost.at performance has improved in a298728 after 304 days, 21 hours, 22 minutes.


feat: add support for including/excluding headers and footers when partitioning pdfs

we should just bubble up exclude_element_types as an option in partition* for now


[docs] Links not working in just book

The links are not working correct in the book on https://just.systems/man/en/.
The links do work correctly in the readme.md
It's due to the fact that html anchors are used and the book is splitted over several html files.
I think there are two ways to fix it:

Don't split the readme in separate files (so the links keep working).
Rewrite all links so they link properly to the right places in the manual.

Thanks for reporting this! I changed the script that builds the book sources to rewrite all the links so that they point to the right place. (It was surprisingly hard 😭.) But it should work now!


fix(application-federated-credential): fix nil pointer and display name

:tada: This issue has been resolved in version 1.0.2 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


feat(Dispatcher): allow dispatch operations to accept a GameObject

The Dispatch operations of Enter/Exit/Select now have methods where they can accept a GameObject as the target to dispatch to.

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

npm package (@latest dist-tag)
v2.3.0
GitHub release

Your semantic-release bot :package::rocket:


Jesse: Watch shortiecuts.com

Jesse requests the watch of the watch_keyword shortiecuts\.com. See the MS search here and the Stack Exchange search in text, in URLs, and in code.

shortiecuts\.com has been seen in 1 true positive, 0 false positives, and 0 NAAs.

Approved by Jeff Schaller in Charcoal HQ


Change new tab url check for firefox

On firefox the new tab url is not chrome://newtab/, this change it with the correct one on firefox.
(Maybe you will want to do some lodash for that)

Thank you!


Update logging configuration

Configure API to log everything at info level and above to STDOUT.
This fixes the issue with almost nothing being logged to Cloudwatch.

@TomJKing Would you mind taking a look at this one? Nigel and I paired on it.


Inline CSS

Critical CSS should be inline to increase rendering speed.
https://developers.google.com/speed/docs/insights/InlineCSS

This is not a Jekyll-Assets bug.

@envygeeks No. It's more like a feature request. Since this is more and more becoming important if one wants a good page ranking.

Fair enough, thanks for the elaboration.  I'm going to re-open and consider but tbh, I think this might be out of our scope or at least something we won't be looking at doing for a while.

you do this with
<style>{% asset inline.scss %}</style>

That seems an option. However, it's not possible to have a matching (subresource) integrity-hash that way. This possibility for a hash value is why I switched to this assets pipeline, so it's a bit silly to leave it out then...

Yes it's a bummer and I think it's great that you want to use SRI.
SRI is useful when the resource is on a CDN or on a seperate host and you want to make sure that the resources is the one you intended. Now if you have have your html and resources on the same host (e.g they are both processed through jekyll or other pipline and I assume they are hosted together) than a SRI is useless; because if an attacker managed to change the resource, what stops them from modifying the hash also?
 I just wanted to make the limitations of SRI clear.
From the link you posted:

Subresource Integrity (SRI) is a security feature that enables browsers to verify that files they fetch (for example, from a CDN) are delivered without unexpected manipulation. It works by allowing you to provide a cryptographic hash that a fetched file must match.

Yeah SRI isn't really meant for (and I don't even think browsers care about) inline CSS an stuff.

Ok. You can close the issue then.
However, newer browsers do care about a correct hash value if the headers have certain options.

headers have certain options

Are you talking about the Content Security Policy ?

I mean that the Content Security Policy header is added by the server. This header contains the SRI settings.

It looks like you can whitelist the SHA hash we provide, so I'll add support for this.

Just in-case this is of use:
An example of a hash in the CSP (not to be confused with the SRI)
Content-Security-Policy: script-src 'sha256-076c8f1ca6979ef156b510a121b69b6265011597557ca2971db5ad5a2743545f'

<script>var inline = 1;</script>

Reference: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src

<hash-source>
A sha256, sha384 or sha512 of inline scripts or styles. When generating the hash, don't include the

We won't directly support outputting the HTML but in Sprockets 3.x you can do {% css bundle.css @source %} and it will return the source, you can do it with any asset, regardless of type.  And if it's an image you should also be able to do {% img name.png @data %} and get back a data uri.

you can do this with <style>{% asset inline.scss %}</style>

@publicarray  I can't. I get the following message:

Liquid Exception: Liquid syntax error (/Library/WebServer/Documents/blog/_includes/head.html line 35): Unknown tag 'asset' included in /_layouts/default.html

@alvarotrigo In the new version it's <style>{% asset inline.scss @inline %}</style>


Magic link strategy with disabled registration doesn't work

Here's how the magic link strategy was implemented:
magic_link do
  identity_field :email
  registration_enabled? false

  sender X.Accounts.User.Senders.SendMagicLinkEmail
end

...

read :sign_in_with_magic_link do
  description "Sign in or register a user with magic link."

  argument :token, :string do
    description "The token from the magic link that was sent to the user"
    allow_nil? false
  end

  prepare AshAuthentication.Strategy.MagicLink.SignInPreparation

  metadata :token, :string do
    allow_nil? false
  end
end

With the code above I'm getting this error:
[error] ** (FunctionClauseError) no function clause matching in URI.decode_query/3
(elixir 1.17.2) lib/uri.ex:204: URI.decode_query(nil, %{}, :www_form)
(ash_authentication 4.2.7) lib/ash_authentication/strategies/magic_link/sign_in_preparation.ex:28: AshAuthentication.Strategy.MagicLink.SignInPreparation.prepare/3

When registration is enabled it works as expected

@jimsynz sorry I won't be able to address this before I leave, but I imagine this is something that I broke in my recent work making registration possible.


Split-off dependencies.md from dev.md

add links for all required packages

[skip ci]
Signed-off-by: Klaus Kämpf<EMAIL_ADDRESS>

Force merge due to [skip ci] (somehow not handled by github correctly ?!)


Steamline trace selection from trace explorer and other locations

When a trace/experiment is opened, a new tab is opened for it and the trace appears in the Trace Explorer under the Opened Experiment.

[ ] When a user selects a trace under the Opened Experiement, its tab should be opened.

[ ] When a user selects a tab, the corresponding trace should be selected under the Opened Experiments and also the root path of the experiment should be selected in the File explorer, like it would for a source code file

[ ] Sometimes, an experiment may be available under the Opened Experiments, but no corresponding tab is opened, for instance, if the trace was opened in another browser, or from another workspace. Here one of 2 things should be done:

detect that no tab is opened for this trace and do not display the trace (in which case, it will not be possible to delete this trace from the trace server), or maybe just for traces that are not on this workspace?

Open a tab for it.

Fixed by PRs #180, #318 (and others?)
Except for "the root path of the experiment should be selected in the File explorer, like it would for a source code file" because opened traces aren't necessarily in the workspace.


Using bevy_gizmos feature with default-features=false renders nothing (requires extra bevy_pbr feature)

Bevy version
0.12
What you did
Tried to use bevy_gizmos with the following bevy dependency configuration:
[dependencies.bevy]
version = "0.12"
default-features = false
features = ["bevy_gizmos"]

What went wrong
Gizmos were not drawn.
Additional information
The fix was to add the bevy_pbr feature:
[dependencies.bevy]
version = "0.12"
default-features = false
features = ["bevy_gizmos", "bevy_pbr"]

I think we just need to add an explicit dependency on bevy_pbr here:
https://github.com/bevyengine/bevy/blob/ca1874e6c612d73306173065242aaaa8733c9b20/Cargo.toml#L132

Always adding bevy_pbr as a feature would prevent users that only need bevy_sprite from disabling it, and vice versa.

Since gizmos requires either bevy_pbr or bevy_sprite, perhaps a compile error could be thrown is neither is enabled.
#[cfg(all(not(feature = "bevy_pbr"), not(feature = "bevy_sprite")))]
compile_error!("bevy_gizmos requires either bevy_pbr or bevy_sprite. Please enable one as an optional dependency.");


Errors on scenario view after upgrading to v1.17.1

Getting the following errors on scenario views after upgrading to v1.17.1, and the roadmap diagrams are not rendered correctly (columns and rows squashed together):

Potentially related to #4039 ?

Seems to be related to the number of cols, will look into it.

Patched in master, can you give it a spin.  Fix was v. small, I had forgotten to take into account the case when the number of columns was larger than 8 and we were flooring the value down to zero, hence the squished rendering

Thanks @davidwatkins73 , that has fixed the issue.


Komf

I don't understand what's the issue since no description was provided. Assuming it was opened by mistake.
I'm closing this issue


TypeError: max() received an invalid combination of arguments

I am following the basic tutorial and when decoding probabilities with no language model I run into an error during the decode step.
Env info
pyctcdecode 0.1.0
numpy 1.21.0

Code
# Change from (1 x classes x length) to (length x classes)
probabilities = probabilities.transpose(1, 2).squeeze(0)
print(probabilities.shape) # torch.Size([276, 36]) - shape appears to be correct
decoder = build_ctcdecoder(labels)
text = decoder.decode(probabilities)

Stack Trace
Traceback (most recent call last):
  File "train/train_nemo.py", line 79, in <module>
    text = decoder.decode(probabilities)
  File "/home/rob/code/thunder_speech_latest/.venv/lib/python3.8/site-packages/pyctcdecode/decoder.py", line 611, in decode
    decoded_beams = self.decode_beams(
  File "/home/rob/code/thunder_speech_latest/.venv/lib/python3.8/site-packages/pyctcdecode/decoder.py", line 513, in decode_beams
    logits = np.clip(_log_softmax(logits, axis=1), np.log(MIN_TOKEN_CLIP_P), 0)
  File "/home/rob/code/thunder_speech_latest/.venv/lib/python3.8/site-packages/pyctcdecode/decoder.py", line 85, in _log_softmax
    x_max = np.amax(x, axis=axis, keepdims=True)
  File "<__array_function__ internals>", line 5, in amax
  File "/home/rob/code/thunder_speech_latest/.venv/lib/python3.8/site-packages/numpy/core/fromnumeric.py", line 2754, in amax
    return _wrapreduction(a, np.maximum, 'max', axis, None, out,
  File "/home/rob/code/thunder_speech_latest/.venv/lib/python3.8/site-packages/numpy/core/fromnumeric.py", line 84, in _wrapreduction
    return reduction(axis=axis, out=out, **passkwargs)
TypeError: max() received an invalid combination of arguments - got (keepdims=bool, out=NoneType, axis=int, ), but expected one of:
 * ()
 * (Tensor other)
 * (int dim, bool keepdim)
 * (name dim, bool keepdim)

Thanks for the snippet, does the problem persist if you convert your torch tensor to a numpy array before decoding? eg probabilities.numpy()

Wow, thank you for the lightning fast reply.
Changing decoder.decode(probabilities) to decoder.decode(probabilities.detach().numpy()) fixed the issue! Cheers.

great! :)


Add basic spatial metadata support

Reading/writing BioImaging compatible axes
Reading/writing transformations

De-listed from the current sprint


no visible @interface

I keep getting No visible @interface for 'RCTRootView' declares the selector 'initWithBundleURL:moduleName:launchOptions:'
I have reinstalled the library and started a new project to test it. The error message comes up when I go to click on an action like "tweet".
"dependencies": {     "react": "^0.14.8",     "react-native": "^0.25.1",     "react-native-social-share": "^0.7.0"   }

Hi @sdnorm
As it is very long time since I made this repo, I don't really know too much about any changes that have been made to react native.
I tried to do a clean install of react native on my computer and installed react-native-social-share. I followed the instructions in the readme and did some tweaking to the example js code to follow the new syntax (ES6 or ES7 i guess).
I works on my computer, both Facebook and Twitter sharing.
Can you walk my trough how you started your new project, maybe I can see something that could be done differently 👍

To test it again I did the following:
react-native init social -> then followed the instructions you have.
I am still getting the same error. Not sure what is happening. I am just going to use the react-native-share package to finish my app. On my next app I will try this package again, I liked it when I had it working.


Table not refreshed on data updates

Expected Behavior
On data change table should be refreshed
Current Behavior
Table and rowData values are not reflecting new values
Your Environment

Tech
Version

Material-UI
4.5.1

MUI-datatables
2.12.4

React
16.10.2

browser
Firefox 70.0.1

I have a modal window that opens on row click. There are 3 buttons to edit row data (OK, NOT OK, PAUSE). The data is changing with setState but table is not refreshing with the new value.
const columns = [
  {
    name: "id"
  },
  {
    name: "name",
    options: {
      filter: true,
      sort: true
    }
  },
  {
    name: "ownerName",
    options: {
      filter: true,
      sort: true
    }
  },
  {
    name: "quantity",
  },
  {
    name: "unit",
  },
  {
    name: "department",
    options: {
      filter: true,
      sort: true
    }
  },
  {
    name: "verified",
    options: {
      filter: true,
      sort: true
    }
  }
];

export default class extends React.Component {
  constructor(props) {
    super(props);
    this.state = {
      loading: false,
      page: 1,
      pageSize: 5,
      data: [],
      totalRows: 0,
      showModal: false,
      clicked: []
    };
    this.handleCloseModal = this.handleCloseModal.bind(this);
    this.handleOpenModal = this.handleOpenModal.bind(this);
  }

  handleOpenModal() {
    this.setState({ showModal: true });
  }

  handleCloseModal() {
    this.setState({ showModal: false });
  }

  preVerification(rowItem) {
    this.setState({ clicked: rowItem, showModal: true });
  }

  verification(msg, item) {
    this.setState({ showModal: false });
    var tempData = this.state.data
    for (var i = 0; i < tempData.length; i++) {
      if (tempData[i]["id"] == item[0]) {
        tempData[i]["verified"] = msg;
        this.setState((state) => ({
          data: tempData
        }));
        break;
      }
    }
    console.log(this.state.data);
  }

  async componentDidMount() {
    this.setState({ loading: true });
    const getCodes = await axios.get(`api/listrequests`);
    this.setState({
      data: getCodes.data,
      loading: false
    });
  }

  render() {
    const { loading, totalRows } = this.state;
    const options = {
      filterType: "dropdown",
      page: 0,
      pagination: true,
      rowsPerPage: 5,
      rowsPerPageOptions: [5, 10, 20, 30, 50, 100, 1000, 10000],
      fixedHeaderOptions: { xAxis: true, yAxis: true },
      rowHover: true,
      search: true,
      download: true,
      print: true,
      selectableRows: "none",
      onRowClick: rowData => this.preVerification(rowData),
    };
    return (

        <Modal
          isOpen={this.state.showModal}
          ariaHideApp={false}
          onRequestClose={this.handleCloseModal}
          style={customStyles}
          overlayClassName="Overlay"
        >

{this.state.clicked}

          <button onClick={() => this.verification("NOT OK", this.state.clicked)}>NOT OK</button>
          <button onClick={() => this.verification("PAUSE", this.state.clicked)}>
            PAUSE
          </button>
          <button onClick={() => this.verification("OK", this.state.clicked)}>OK</button>
        </Modal>
        <MUIDataTable
          data={this.state.data}
          columns={columns}
          options={options}
        />

    );
  }
}

Hey @fuzunspm, can you create a minimal example that I can run, like in a codesandbox? The problem with trying to run your sample code here is that it uses a lot of things I would need to spend time setting up locally (I don't know what Modal you're using, I don't know what endpoint you're using, checking for missing variables, etc.). Verification and finding the issue is much simpler when the code is exactly as complex as it needs to be, so not including external libraries or http requests, and using minimal options necessary to produce the error.
In the mean time, have a look at the custom-action-columns example, as it demonstrates table actions changing data via setState, so it may prove instructive somehow.

codesandbox demo
I output the data every time it changes to the console. It changes but the table remains the same

Thanks for the example. In your example, you're setting the new data equal to the old data. So in that case, I would not expect the data or the table to change. Am I missing something?

I'm overwriting new data on to the old data via setState. Isn't it how I'm suppose to do?

In theory, yes, but in this section:
var tempData = this.state.data;
for (var i = 0; i < tempData.length; i++) {
  if (tempData[i]["id"] == item[0]) {
    tempData[i]["verified"] = msg;
    this.setState(state => ({
      data: tempData
    }));
    break;
  }
}

we set the new data to the old data with var tempData = this.state.data; and then set it back again with
this.setState(state => ({
  data: tempData
}));

So I'm not sure if that's what's happening in your main application, but this would result in no change to the table. If you instead insert some new fake data like
this.setState(state => ({
  data: [{id: 123, name: 'foo', ...}, {id: 456, name: 'bar'}]
}));

then the table will update to reflect the new data, which is what I saw when I modified your example to do the above.

Sorry, I realized I may not have been clear. In javascript, when you assign an object (array in this case, but js treats arrays like objects under the hood) to variable, the reference of the object is passed, rather than the value. This means that, even though you modify it later, under the hood, it looks to js like it's the same object, and so it doesn't update the way you would expect in react.
To fix this, you need to actually copy the object (array of objects in your case). One way to do so is
var tempData = [...this.state.data];

If you do that, you will notice it now updates. This is not an issue with the table library, it's a consequence of how js and react work.

Thank you very much, copying object did the trick but even thought this is unrelated to mui-datatables, could you please explain why it won't do the same thing. In the end when i output state.data, it outputs modified values so it actually overwrites

@fuzunspm React re-renders if it detects a change via setState, but the change in your case occurs before setState is called due to the object reference issue.


Text annotation objects might need to behave more like legend annotation objects

Describe the bug

Create 3 different databases from arbitrary but distinctly different subsets of the waveXXXX.silo files.
Put up PC plot of pressure from waveA.silo and Mesh plot from waveB.silo
Draw plots
Add text annotation for $time and confirm it displays time of first database of first plot in plot list
Change order of plots in plot list and watch value for $time annotation change

Somehow, the text annotation object is getting what it knows about the database only from the first entry in the plot list. I think the solution is for it to track which plot its associated with in the plot list. Looking here...
https://github.com/visit-dav/visit/blob/9d76188e4f5f9169709e9c0cf274209dbeca13e2/src/avt/VisWindow/Colleagues/avtAnnotationWithTextColleague.C#L76
Its obviously only using plot list entry 0. But, what plot...the plot's index at the time the annotation object was created? The plot's type...the plot`s database/variable name. The latter might be best so it could find which entry to query in the plot list to update its value.

I think what we need is a printable form way of identifying plots. Currently, plots are identified by and large within a VisIt session as an index into a list of plots. But, because plots are added and deleted and can even be re-ordered in the plot list, an index into the list is an unreliable way to identify a plot.
We could compute a hash of all relevant stuff that goes into a plot...the database, variable name, plot attributes, attributes of any operators applied, etc. Whenever anything about the plot changes, that hash would change...does that mean the plot itself is a different thing than it was before the change?
From the point of view of identifying the C++ object within a VisIt session, such an approach is overkill and leads to far too many instances where the identifer changes for the same C++ object instance. OTOH, in such an approach the same plot created in two different instances of VisIt would have the same id and maybe that is a good thing?
Could we just use the C++ plot object's pointer as its id? That certainly would not work across session saves and restores?


Instana Addon Documentation PR

Instana Addon for Amazon EKS Blueprint Documentation PR
Issue #, if available:
Description of changes:
This PR updates the IBM® Instana® Addon documentation in the AddOns section. The Addon consists of separate public NPM packages, and their source code can be found here.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@arpitn2020 thank you for the contribution, we are excited to have Instana integrated with the Blueprints.
I assume you are familiar with the process for partner extensions, it is outlined here.
Before we publish any documentation on our channels, we will need to validate it. I don't see a PR against the patterns repo to make it happen. When are you planning to submit?

@arpitn2020 Thankyou for submitting a pattern. I have some comments on the Patterns PR.

@arpitn2020 We would Instana license to validate the Pattern before this PR can be merged.

@arpitn2020 In the instana-addon.md please remove AWS CLI, node, npm pre req and just share the quickstart link for Prereq as you did. Also please check one of our Partner addons for an example on how usage, installation and options are formatted and you can follow the same approach if thats possible. rest of the stuff like Intro, testing, screenshots all look good.

Hi @elamaran11, I have updated the Instana Addon Documentation by incorporating the necessary changes. Additionally, I have included Instana in the index.md file. Please review the changes and provide your feedback. Thank you.

@shapirov103 LGTM. Please check and merge this.

@elamaran11 Yes. I am looking on it.

@arpitn2020 Thankyou for working on this. Please check the merge conflicts. Also please make sure to update the Instana pattern in patterns repo too

@elamaran11 Pattern repo https://github.com/aws-samples/cdk-eks-blueprints-patterns/pull/103.
Please review the changes

@elamaran11 Pattern repo aws-samples/cdk-eks-blueprints-patterns#103. Please review the changes

@arpitn2020 Thanks for the amazing work on the patterns repo. Please reflect the changes you had for patterns repo here especially on how you are handling secrets along with fixing other comments from Mikhail. We can then march past to merge.

@elamaran11 Pattern repo aws-samples/cdk-eks-blueprints-patterns#103. Please review the changes

@arpitn2020 Thanks for the amazing work on the patterns repo. Please reflect the changes you had for patterns repo here especially on how you are handling secrets along with fixing other comments from Mikhail. We can then march past to merge.

@elamaran11 Thanks for the feedback. I have added docs for secrets implementation

@elamaran11 I didn't get. I changed to bin/<your-project-name>.ts. will this be ok ?

@arpitn2020 Merged. Nice work on the PR and overall integration.


SD and cPP use mixture of US and UK English

Both the NDcPP and NDSD use a mixture of US and UK English. Suggest that this should be cleaned up and that US English is adopted across both documents.

Noting that ISO (and the CC organization versions of the standards) adopt the Oxford spelling rules.  This can appear to look like a mix of British and American spelling has been deployed. However, this is intentional.
I would recommend that Oxford spelling is also adopted in PPs for the sake of consistency.
https://en.wikipedia.org/wiki/Oxford_spelling

I am adding the MiNT and CC2022 labels, so this issue can be considered in context with that work.


installing uncrustify - HOW TO ¿¿

on the docker link, there is no instructions on how to get and install uncrustify ( in order to make beautify to work in Atom)  , in fact there is no single mention to it on the linked page .
i would suggest to add this information and delete the non-relevant links as the information provided there is not useful for the install purpose .
thank you

The instructions are at the bottom. If you're on a Mac or Linux, I'd suggest using Whalebrew. Otherwise you can run docker pull unibeautify/uncrustify.
Also, if you have Docker installed it should install the Docker image automatically when you run the beautify command for an uncrustify supported language.

Thank you for your answer , I have installed  docker today , I will test it tomorrow but I think that docker is “ empty” after installation, so I’m not sure if it will be able to find the source , will test it tomorrow .

@gnkarn : Thank you for providing your feedback. We are always trying to improve the user experience.
If I am not mistaken, the "non-relevant links" you are referring to can be found at https://github.com/Glavin001/atom-beautify/blob/master/src/beautifiers/uncrustify/index.coffee#L18-L19 . Pull Requests are very welcome! Thanks again!

it worked fine , i would suggest to remark, those two steps : install Docker , and the fact that it will automatically detect and install the uncrustify container . thank you

@gnkarn : Great to here everything is working now! If you have no more questions, please close this issue 😃 .

This does not work on Win 10 x64 pro, docker is installed, it also automatically pulls the docker on intending to beautify a .java file but then you get the following error:
load_option_file: fopen(C:\Users\myusername\AppData\Local\Temp\118319-16936-rvqr0u.5da7c.cfg) failed: Invalid argument (22) Unable to load the config file Try running with -h for usage information
--
Error: load_option_file: fopen(C:\Users\myusername\AppData\Local\Temp\118319-16936-rvqr0u.5da7c.cfg) failed: Invalid argument (22)
Unable to load the config file
Try running with -h for usage information
at file:///C:/Users/myusername/.atom/packages/atom-beautify/src/beautifiers/executable.coffee:182:23
at tryCatcher (C:\Users\myusername.atom\packages\atom-beautify\node_modules\bluebird\js\release\util.js:16:23)
at Promise._settlePromiseFromHandler (C:\Users\myusername.atom\packages\atom-beautify\node_modules\bluebird\js\release\promise.js:512:31)
at Promise._settlePromise (C:\Users\myusername.atom\packages\atom-beautify\node_modules\bluebird\js\release\promise.js:569:18)
at Promise._settlePromise0 (C:\Users\myusername.atom\packages\atom-beautify\node_modules\bluebird\js\release\promise.js:614:10)
at Promise._settlePromises (C:\Users\myusername.atom\packages\atom-beautify\node_modules\bluebird\js\release\promise.js:693:18)
at Async._drainQueue (C:\Users\myusername.atom\packages\atom-beautify\node_modules\bluebird\js\release\async.js:133:16)
at Async._drainQueues (C:\Users\myusername.atom\packages\atom-beautify\node_modules\bluebird\js\release\async.js:143:10)
at Async.drainQueues (C:\Users\myusername.atom\packages\atom-beautify\node_modules\bluebird\js\release\async.js:17:14)
at
at process._tickCallback (internal/process/next_tick.js:109:7)

@g-uru  it doesn't work for me either and I have win 10 x64  pro

I think I am having the same issue.
user@windows{~}>> UNCRUSTIFY_CONFIG=/cygdrive/c/Users/edp/.babun/cygwin/home/edp/.uncrustify.conf uncrustify -l C main.c
unc_getenv: name=UNCRUSTIFY_CONFIG len=61 value=/cygdrive/c/Users/edp/.babun/cygwin/home/edp/.uncrustify.conf
load_option_file: fopen(/cygdrive/c/Users/edp/.babun/cygwin/home/edp/.uncrustify.conf) failed: No such file or directory (2)
Unable to load the config file
Try running with -h for usage information


Improve commit title

Resending Issue #166 as a PR for convenience

Thank you.

thanks for merging and cleaning up my mess. i'd like to add more stuff to cask-repair, but bash isn't my area of expertise ;/


Add 11.5-11.7 cuda toolkit options and install 11.5 (495) driver by default

Add more CUDA toolkit options for install_gpu_driver. This adds 11.5, 11.6, and 11.7, while leaving the default as 11.2.
In order to pick one of these newer versions, please continue to use --metadata cuda-version=[major.minor]. For 11.5, we would request it this way: --metadata cuda-version=11.5.
This patch also changes the default driver to 495 (11.5).

@medb @mengdong FYI

@medb @bradmiro could you please help run the test? thanks!

@mengdong  let's use https://github.com/GoogleCloudDataproc/initialization-actions/pull/1013 since it has the changes for this PR as well.
I would suggest we close this PR .

Please feel free to close it yourself
On Wed, Aug 31, 2022 at 15:56 Hao Zhu @.***> wrote:

@mengdong https://github.com/mengdong let's use #1013
https://github.com/GoogleCloudDataproc/initialization-actions/pull/1013
since it has the changes for this PR as well.
I would suggest we close this PR .
—
Reply to this email directly, view it on GitHub
https://github.com/GoogleCloudDataproc/initialization-actions/pull/1011#issuecomment-1233518331,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABLQN44C5DMB2ZZATYICPHLV37PKTANCNFSM565Y4EQQ
.
You are receiving this because you were mentioned.Message ID:
@.***
com>


Update appengine/build.xml

Delete old blockly-.js files before creating new one.
I noticed that everytime I do "ant" or "ant noplay", I end up with an additional blockly-.js file in the appengine/build/war directory. These files are 3.9M each.

@halatmit @jisqyv

@lizlooney There was another place to get (which I took care of) so "ant Blockly" also gets rid of the old blocklies.

LGTM

@lizlooney MERGED.


Can the FORCE option in build_visit modules be removed?

Is your feature request related to a problem?
A number of build_visit modules have a "FORCE" option.
Not sure why its there, or when it is useful.
Can it be removed?
Modules with FORCE:
bv_adios.sh
bv_cmake.sh
bv_python.sh
bv_qt.sh
bv_qwt.sh
bv_uintah.sh
bv_vtk.sh
What I think is the relevant bv_main section that should be using bv_<module>_force but instead calls bv_<module>_enable
https://github.com/visit-dav/visit/blob/5caaa0297b9b5925ce9c34a8b76c2a0642526405/src/tools/dev/scripts/bv_support/bv_main.sh#L1146-L1150
None of the bv_<module>_enable functions read an argument, they all just set FORCE_<MODULE> to "yes".
Having the 'FORCE' option seems redundant.

I propose a slight change to issue title, Remove FORCE and intra-package build_xxx calls in build_visit and then adding this to issue...
We appear to have some places in build_visit where we explicitly call build_cmake from within another package’s bv_xxx.sh file. But, this design is not universal either. For example Adios and Conduit do it but not VTK, VTKm, icet or xdmf.
This should not be happening. We should handle CMake dependence by adding cmake to the depends_on variable for the package.

resolved in 3.4RC in https://github.com/visit-dav/visit/pull/19770 and on develop in https://github.com/visit-dav/visit/pull/19934


add pagable to the AppService spec

The AppService spec doesn't use x-ms-pagable to describe it's pagable operations. This creates extra models in most languages and provides a less than optimal developer experience.
@tbombach please give this a look.
@veronicagg and @vishrutshah please verify this resolves the Ruby SDK issue with get_next_page_lazy.

Python is broken because of:
FATAL: Error saving generated code: Couldn't find the nextLink property specified by extension on operation Certificates_GetCertificate and property Certificate

@devigned you sure some of your nextLink should have not been null ?

oh no... looks like I was a little over zealous. Fixing it.

@lmazuel I think we are green.

@amarzavery what do you think about pulling this in?

LGTM.

 https://github.com/Azure/azure-sdk-ruby/pull/39

 https://github.com/Azure/azure-sdk-for-python/pull/725

 https://github.com/Azure/azure-sdk-for-node/pull/1844


On-demand minting

Currently Freshmint pre-mints all NFTs. This is a placeholder issue to brainstorm methods for on-demand minting.

Freshmint can add a create-edition command to allow users to create an edition without minting into it. This allows minting to happen separately.

It's not possible to create edition templates by running fresh mint --templates. Implemented in #164


fix: fail accessing navigator on Node

navigator doesn't exist on the Node environment, so it is required to check if navigator is not undefined.

Thank you!


Use JDK11 as the build JDK with target set to 1.8

This PR sets JDK 11 as the JDK version used for publish, however it also sets target to 1.8.
cc @sideeffffect

Hm, interesting, that is not possible with JDK17. Closing it for now, we'll just keep things as is.


[Bug]: [webpack-dev-middleware] RangeError: Invalid string length

Version
N/A

Details
Entrypoint main 116 MiB = main-8d27d6eb9b39386ef1df.js
Entrypoint unsupportedBrowser 887 KiB = unsupportedBrowser-b4d2fea7fce3de54a441.js
Entrypoint reactdevtools 645 KiB = reactdevtools-b671b3ece8b25cd3fd9b.js
Rspack 0.5.2 compiled successfully in 27.12 s (2faf356ab27d33a22682)
 [webpack-dev-middleware] RangeError: Invalid string length
     at PassThrough. (/Users/pushkargupta/source/teams-modular-packages/node_modules/@rsdoctor/utils/dist/cjs/build/json.js:33:16)
     at PassThrough.emit (node:events:513:28)
     at addChunk (node:internal/streams/readable:315:12)
Running into the above error with rsdoctor and serving an application.
Reproduce link
N/A
Reproduce Steps
yarn rspack serve
with
rsdoctor

This is maybe  json data too large eventually exceed buffer.constants.MAX_STRING_LENGTH, I'll try to optimize this.
You can try on lite mode, https://rsdoctor.dev/config/options/index#features-values.

@pushkargupta9807 Does it work if the options are set to features: [lite, loader, plugins]?

Perhaps an idea would be to have a similar implementation as Statoscope which is able to handle our stats

Yeah okay. And this is postman right? So you have a large codebase.
From the error it sounds like it’s due to stats size exceeding json stringify capability.
Do you know the size of your stats file for reference? It was a few 100mb if I remember?
I’ll look at statosope and how they implement stat serilize

@ScriptedAlchemy Thx! Yes. The stats file is approx 1.6 GB. This is split across: children -> 145 MB, chunks -> 843 MB, modules -> 592 MB.
We have ~27 child compilers, ~511 chunks (we are busy optimizing this) and ~22k modules

I'm running into this too and with just a portion of a a codebase. The build without rsdoctor completes in about 20s, with rsdoctor I get the error below. I took a peek at the .rsdoctor folder and its 3.3MB.
[rspack-cli] RangeError: Invalid string length
    at PassThrough.<anonymous> (/Volumes/CaseSensitive/myrepo/node_modules/@rsdoctor/utils/dist/cjs/build/json.js:33:16)
    at PassThrough.emit (node:events:518:28)
    at addChunk (node:internal/streams/readable:559:12)
    at readableAddChunkPushByteMode (node:internal/streams/readable:510:3)
    at Readable.push (node:internal/streams/readable:390:5)
    at node:internal/streams/transform:178:12
    at PassThrough._transform (node:internal/streams/passthrough:46:3)
    at Transform._write (node:internal/streams/transform:171:8)
    at writeOrBuffer (node:internal/streams/writable:564:12)
    at _write (node:internal/streams/writable:493:10)

Perhaps an idea would be to have a similar implementation as Statoscope which is able to handle our stats

Good idea, it is true that rsdoctor's analysis logic is relatively heavy, and it is not optimized for large projects. We are also ready to provide an extremely lightweight version for large projects.

I'm running into this too and with just a portion of a a codebase. The build without rsdoctor completes in about 20s, with rsdoctor I get the error below. I took a peek at the .rsdoctor folder and its 3.3MB.
[rspack-cli] RangeError: Invalid string length
    at PassThrough.<anonymous> (/Volumes/CaseSensitive/myrepo/node_modules/@rsdoctor/utils/dist/cjs/build/json.js:33:16)
    at PassThrough.emit (node:events:518:28)
    at addChunk (node:internal/streams/readable:559:12)
    at readableAddChunkPushByteMode (node:internal/streams/readable:510:3)
    at Readable.push (node:internal/streams/readable:390:5)
    at node:internal/streams/transform:178:12
    at PassThrough._transform (node:internal/streams/passthrough:46:3)
    at Transform._write (node:internal/streams/transform:171:8)
    at writeOrBuffer (node:internal/streams/writable:564:12)
    at _write (node:internal/streams/writable:493:10)

I'm running into this too and with just a portion of a a codebase. The build without rsdoctor completes in about 20s, with rsdoctor I get the error below. I took a peek at the .rsdoctor folder and its 3.3MB.
[rspack-cli] RangeError: Invalid string length
    at PassThrough.<anonymous> (/Volumes/CaseSensitive/myrepo/node_modules/@rsdoctor/utils/dist/cjs/build/json.js:33:16)
    at PassThrough.emit (node:events:518:28)
    at addChunk (node:internal/streams/readable:559:12)
    at readableAddChunkPushByteMode (node:internal/streams/readable:510:3)
    at Readable.push (node:internal/streams/readable:390:5)
    at node:internal/streams/transform:178:12
    at PassThrough._transform (node:internal/streams/passthrough:46:3)
    at Transform._write (node:internal/streams/transform:171:8)
    at writeOrBuffer (node:internal/streams/writable:564:12)
    at _write (node:internal/streams/writable:493:10)

I'll find a repo has this similar problem and fix this problem.

@easy1090 still running into this issue. It is hard to repro with a smaller repo .

@pushkargupta9807  Generated stats without turning on Rsdoctor. What is the size of json? Is it possible to send stats.json to my email<EMAIL_ADDRESS>？
This is likely a problem with our data storage structure, as it does not consider data exceeding the limit in large projects. Rsdoctor will break down the chunk graph data structure to address this issue.
Please set stats options to the below setting without turn on the rsdoctor plugin, to generate the stats.json file:
{
 all: false,
 assets: true,
 chunks: true,
 modules: true,
 builtAt: true,
 hash: true,
 ids: true,
 version: true,
 entrypoints: true,
}

@pushkargupta9807 @zackarychapple
After detailed investigation, it was found that there is a problem with the noAssetsAndModuleSource configuration in the rspack mode (I made the problem more complicated, which led to a delay in solving this problem for a relatively long time). Please try the rsdoctor @0.3.2 version, and at the same time, add the following reportCodeType configuration:
new RsdoctorWebpackPlugin({
      features: ['bundle', '....'],// some features
      reportCodeType: { noAssetsAndModuleSource: true }
    }

I have tried the above scheme for a project that also has this problem, and it is effective. If you have any questions, please continue to contact me.
In addition, if it is an MF project, there may be a problem of the overly large size of stats.json, because the identifier of the container entry module of the issuerPath may be very long, and the container entry module may appear very many times. The overly large stats.json will lead to too slow analysis of rsdoctor. It can be considered to turn off the ability to parse the bundle to some modules, and the configuration is as follows:
new RsdoctorWebpackPlugin({
      features: ['bundle', '....'],// some features
      reportCodeType: { noAssetsAndModuleSource: true },
      supports: {
        parseBundle: false,
      }
    }

@easy1090 Thank you for looking into this! I can confirm that with the latest version RsDoctor now works as expected for our application 👍 . I did not need do set noAssetsAndModuleSource, the plain new RsdoctorWebpackPlugin() works as well.

@easy1090 Unfortunately I am still running into that same issue in my repo.
      new RsdoctorRspackPlugin({         disableClientServer: false,         features: ["loader", "plugins", "lite"],         reportCodeType: { noAssetsAndModuleSource: true },       })
 However if I exclude the "loader" option , it works but ideally I want to be able to analyze the loaders . FYI, I am running my build in serve mode.

And I am using the latest 0.3.5 version.

@pushkargupta9807
If you turn on the loader option, an invalid string length error will occur, right?

@easy1090 that is correct . With the loader option the invalid string length error occurs.
Without it, it works, but I would really want the loader functionality in the rsDoctor analysis and visualization :)

@pushkargupta9807  I'll try to fixed this problem this week.

@easy1090 that is correct . With the loader option the invalid string length error occurs.
If I remove the loader and use ["plugins", "lite"] , it works. However I would really want the loader functionality in the rsDoctor analysis and visualization :)

Please try version 0.3.8-beta.0 to see if it's okay?

@easy1090 Thank you. I did try , the serve command completed and the Rsdoctor analyze server was launched successfully. However the loader analysis tab never loads and is shown as below:

I also tried to use just the [loader] option, but it never loads the loader analysis.

Also when I try to open the manifest.json file using the rspack cli option I run into the below error:
[@rsdoctor/cli] ✖ EISDIR: illegal operation on a directory, read
Error: EISDIR: illegal operation on a directory, read
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
the command I am running is : sudo yarn rsdoctor analyze --profile dist/undefined/rsdoctor/manifest.json

@easy1090 Thank you. I did try , the serve command completed and the Rsdoctor analyze server was launched successfully. However the loader analysis tab never loads and is shown as below:

I also tried to use just the [loader] option, but it never loads the loader analysis.

@pushkargupta9807
It seems that the invalid string length problem has been solved, but the loader data is too large and the page pull is too slow. That needs to wait for the loader data disassembly and transformation.

@pushkargupta9807
This issue has fixed by #419
I will open another one issue  for the optimize of the large loader data .

Thank you !


[Feat]: Add support for systemd notification protocol

Is your feature request related to a problem? Please describe.
When running the zot service under systemd, the current example uses a Type=simple service. With that service type, systemd assumes the service is ready to accept traffic immediately after it starts zot. But in reality, zot needs to initialize itself and we cannot immediately use, for example, see this sequence of commands, that end up with zli failing:
# systemctl daemon-reload

# systemctl enable zot
Created symlink /etc/systemd/system/multi-user.target.wants/zot.service → /etc/systemd/system/zot.service.

# systemctl restart zot

# zli completion bash

# zli config add main http://registry.example.test

# zli config --list
main	http://registry.example.test

# zli image list --config main
Error: Get "http://registry.example.test/v2/_catalog": dial tcp <IP_ADDRESS>:80: connect: connection refused

Describe the solution you'd like
Would like to see zot.service systemd unit using Type=notify and the above sequence of commands to work without errors.
This requires zot to have some kind of a ready mechanism and use the daemon package from https://github.com/coreos/go-systemd to notify systemd.
Does this ready mechanism already exist in Zot? Maybe to implement the readyz endpoint on kubernetes? If it does, please point me in the right direction, and I can try to implement the rest.
Describe alternatives you've considered
The correct solution is to be able to use:
systemctl is-active --quiet --wait zot

But for my particular use-case, this can be worked around with this bash snippet:
while ! wget -qO- "$zot_url/v2/" >/dev/null; do sleep 1; done;

When using it, you can see it took, in this particular case, 4 tries:
# systemctl daemon-reload

# systemctl enable zot
Created symlink /etc/systemd/system/multi-user.target.wants/zot.service → /etc/systemd/system/zot.service.

# systemctl restart zot

# systemctl is-active --quiet --wait zot

# wget -q http://registry.example.test/v2/
# sleep 1

# wget -q http://registry.example.test/v2/
# sleep 1

# wget -q http://registry.example.test/v2/
# sleep 1

# wget -q http://registry.example.test/v2/

# zli completion bash

# zli config add main http://registry.example.test

# zli config --list
main	http://registry.example.test

Additional context
No response

Hi @rgl, we already use "/v2" endpoint for the readiness probe in our helm-chart configuration https://github.com/project-zot/helm-charts/blob/main/charts/zot/templates/deployment.yaml#L83-L93.
What would be the benefits of a separate readyz endpoint implementation? What would make it different from the "/v2" endpoint that we already have?
Also, let us know if the support for systemd notification protocol is still needed.

this is not about replacing the readyz endpoint that is used by kubernetes. it's about implementing an equivalent mechanism when running under systemd supervision. for the exact reasons its used in k8s.
what I am looking for is a common function that can be called by both implementations, to implement the k8s readyz endpoint and the systemd one.


File doesn't exist at specified Info.plist path

I am new on Bitwise and just tried to build.
But I can see this issue.
INFO[17:54:41]  * [OK] Step dependency (xcode) installed, available.
[!] File doesn't exist at specified Info.plist path: /Users/vagrant/git/DuckDuckGo/Info.plist
|                                                                              |
+---+---------------------------------------------------------------+----------+
| x | Set 18-Plus App Build Number (exit code: 1)                   | 2.27 sec |
I also saw many related solutions for this issue.
https://github.com/bitrise-steplib/steps-set-xcode-build-number/issues/3
$BITRISE_SOURCE_DIR/MyProjectName/Info.plist
how can I set this path?
Please help me.
Thanks

Hi @Maxymdev90, do you certainly have your info.plist in that path? Can you send us a build URL?

Hi @bitce
Thanks for your reply.
I am not sure this is correct build url.
Please check this.
https://app.bitrise.io/build/8dfeb099ec279399

This is build logs.
8dfeb099ec279399.log

Okay @Maxymdev90, thanks! So can you verify that the file is there, maybe with a screenshot?

Hi, I am struggling with same issue https://github.com/bitrise-steplib/steps-set-xcode-build-number/issues/3#issuecomment-721942883

Hi @suathh, be sure to provide the path relative to your online git repository, not the project's local settings. When in doubt, you can easily remote access or use a script to search for a file on the virtual machine.

@bitce
Hello there,I also faced the same problem above.
You can see that i list the path before  and i use steps-set-xcode-build-number.
The Info.plist file is at the root path, but it still tell me  「File doesn't exist at specified Info.plist path」:
https://drive.google.com/file/d/1pnBnxgrqU6VIkDGZ6xgSXZPkJuAjrAen/view?usp=sharing

Hey there @591700757  👋
Can you submit a ticket with this issue at https://support.bitrise.io/hc? Please make sure to send us the log file or the URL of the related build and also enable Support Access on the Settings tab of the app ( https://devcenter.bitrise.io/troubleshooting/enabling-bitrise-support-user/ ) so that we can take a more in-depth look 🙂


[WIP] Set JTREG concurrency based on cores and memory size

Upstream OpenJDK test framework, roughly, sets it to
min(NPROCS/2, MEM_IN_GB/2). Set it to a similar value
so as to avoid test reliability issues due to memory
limits.

Grinder on the big Aarch64 box with this:
https://ci.adoptopenjdk.net/job/Grinder_Sandbox/884/console
It's rather conservative but certainly better than a concurrency value of NPROCS. I'll do some more testing on other boxes and may amend it. Hence, the WIP suffix.

@smlambert Thoughts?

Thanks @jerboaa - have been meaning to look at what we were currently doing, based on the troubles seen running on the 'big box' / test-packet-armv8-ubuntu-16-04 reported in https://github.com/AdoptOpenJDK/openjdk-tests/issues/1203 and seen in a bunch of the recent release runs (seen more frequently now that there are less aarch64 machines in the pool.
Agree its an improvement, will be good to see it run through the other platforms to make sure it doesn't hose anything, thanks for looking at this !

Windows sandbox grinder with this:
https://ci.adoptopenjdk.net/job/Grinder_Sandbox/886/

Another run on the 96 core aarch64 box (on upstream aarch64 JDK 11.0.6+1 EA build):
https://ci.adoptopenjdk.net/job/Grinder_Sandbox/889/
Contrast this to flaky runs earlier on the same JDK: 11.0.6+1 EA. For example:
https://ci.adoptopenjdk.net/view/Test_upstream/job/Test_openjdk11_hs_sanity.openjdk_aarch64_linux_upstream/23/consoleFull

This seems to build OK on Windows/Linux/Mac. I'm removing the WIP prefix.

@smlambert More testing of this completed. Make file seems OK. I don't think any of the failures are related to this patch. Mac/Win (no JRE 8 got downloaded, hence failure). Aarch64 linux on the big box now passes (or is significantly better than before in terms of reliability). ppcle 64 bit linux failures for JDK 13 also seem unrelated.
I'd appreciate somebody reviewing this! Thanks!

Thanks, @smlambert!


Genesis parallelism

Currently chunk loading, generation, updating and saving are all done in sequence. This PR aims to using Bevy AsyncComputeTaskPool and IoComputeTaskPool to reduce genesis time by increasing parallelism.

It seems to have a regression
Before: 35s
After: 44s

2022-08-24T11:22:43.810508Z TRACE projekto_shaping::light_propagator: Propagating natural light on new 169 chunks
2022-08-24T11:22:59.332578Z TRACE projekto_shaping::light_propagator: Preparing to propagate natural light to neighbors of 169 chunks
2022-08-24T11:22:59.658166Z TRACE projekto_shaping::light_propagator: Propagating light on 169 chunk neighbors
2022-08-24T11:23:05.073777Z TRACE main::world::terraformation::genesis::task: Generation completed! 169 chunks dirty.
2022-08-24T11:23:05.633527Z TRACE projekto_shaping::light_propagator: Preparing to propagate natural light to neighbors of 169 chunks
2022-08-24T11:23:05.958320Z TRACE projekto_shaping::light_propagator: Propagating light on 169 chunk neighbors
2022-08-24T11:23:10.448411Z TRACE projekto_shaping::light_propagator: Preparing to propagate natural light to neighbors of 169 chunks
2022-08-24T11:23:10.778483Z TRACE projekto_shaping::light_propagator: Propagating light on 169 chunk neighbors

The propagation function is doing more work than it should.

Loading reduced from 5s, to 2.5s;
Full generation had no reduction since I was unable to parallel compute light, since it would need more rework, which I'll do in another PR.

I figured out a way to propagate natural light on new chunks in parallel. Full genesis went from 35s to 26s.
I'm happy with how it is now. I'll cleanup and merge


Fix PromptChoice's recognize* parameters documentation

The docs of the parameters were mixed up.

@msft-shahins FYI


wip: update: add function to retrieve fields used in output strings

What type of PR is this?

Uncomment one (or more) /kind <> lines:

/kind bug

/kind cleanup

/kind design

/kind documentation

/kind failing-test

/kind feature

Any specific area of the project related to this PR?

Uncomment one (or more) /area <> lines:

/area API-version

/area build

/area CI

/area driver-kmod

/area driver-bpf

/area driver-modern-bpf

/area libscap-engine-bpf

/area libscap-engine-gvisor

/area libscap-engine-kmod

/area libscap-engine-modern-bpf

/area libscap-engine-nodriver

/area libscap-engine-noop

/area libscap-engine-source-plugin

/area libscap-engine-savefile

/area libscap-engine-udig

/area libscap

/area libpman

/area libsinsp

/area tests

/area proposals

Does this PR require a change in the driver versions?

/version driver-API-version-major

/version driver-API-version-minor

/version driver-API-version-patch

/version driver-SCHEMA-version-major

/version driver-SCHEMA-version-minor

/version driver-SCHEMA-version-patch

What this PR does / why we need it:
This PR adds a method to sinsp_evt_formatter to list down all the fields used in output strings.
Still in WIP cause the method relies on m_tokens which contains spaces for the moment, other than fields. I'm investigating the issue as well!
Which issue(s) this PR fixes:

Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?:

NONE

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: loresuso
Once this PR has been reviewed and has the lgtm label, please assign molter73 for approval. For more information see the Kubernetes Code Review Process.
The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

OWNERS

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

cc @jasondellaluce

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

Needs approval from an approver in each of these files:

OWNERS [Andreagit97,jasondellaluce]

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


[stable/efs-provisioner] storageclass template regression

Is this a request for help?: no

Is this a BUG REPORT or FEATURE REQUEST? (choose one):
BUG REPORT

Version of Helm and Kubernetes:
$ helm version
Client: &version.Version{SemVer:"v2.12.3", GitCommit:"eecf22f77df5f65c823aacd2dbd30ae6c65f186e", GitTreeState:"clean"}
Server: &version.Version{SemVer:"v2.12.3", GitCommit:"eecf22f77df5f65c823aacd2dbd30ae6c65f186e", GitTreeState:"clean"}
K8s 1.11
Which chart: stable/efs-provisioner
What happened: template error when storageclass is set to default
What you expected to happen:
no error
How to reproduce it (as minimally and precisely as possible):
set storageClass.isDefault to true and do not provide annotations
Anything else we need to know:
Explained here https://github.com/helm/charts/pull/10829/files#r251376176

I added the following to my ovverride values.yaml to get it working:
# HACK: workaround for https://github.com/helm/charts/issues/10936
annotations:
  storageclass.beta.kubernetes.io/is-default-class: "true"

Otherwise I would get errors deploying it. It is worth noting that the gp2 original default storageclass has both annotations - storageclass.kubernetes.io amd storage.beta.kubernetes.io in my kops deployed cluster. I, however, did try a "made up" annotation too which didn't work out so well but this one works perfectly.


Android Basics: tip-calculator

URL of codelab
https://developer.android.com/codelabs/basic-android-kotlin-training-tip-calculator?continue=https%3A%2F%2Fdeveloper.android.com%2Fcourses%2Fpathways%2Fandroid-basics-kotlin-unit-2-pathway-1%23codelab-https%3A%2F%2Fdeveloper.android.com%2Fcodelabs%2Fbasic-android-kotlin-training-tip-calculator#2
In which task and step of the codelab can this issue be found?
Enable view binding
Describe the problem
Enabling viewBinding seems to default to Groovy syntax as per
https://stackoverflow.com/questions/68569379/access-to-viewbinding-exceeds-its-access-rights
I had to remove the "=" to get the codelab to work
eg:
buildFeatures {
viewBinding true
}
Steps to reproduce?
Follow steps in codelab and ActivityMainBinding will remain undefined in MainActivity.kt until the gradle syntax is corrected as per above
Versions
Android Studio version:
Android Studio Bumblebee | 2021.1.1 Patch 3
Build #AI-211.7628.21.2111.8309675, built on March 17, 2022
Runtime version: 11.0.11+0-b60-7590822 x86_64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
macOS 12.3.1
GC: G1 Young Generation, G1 Old Generation
Memory: 2048M
Cores: 8
Registry: external.system.auto.import.disabled=true
API version of the emulator:
API 31
Additional information
Include screenshots if they would be useful in clarifying the problem.

@sufood
Thank you for reaching out to us and sharing your experience.


General optimizations

Hereby the PR you asked for by mail.
It contains basically 2 things:

Optimizations by pre-calculating vertices & corners (gave a huge performance boost in my project)
Fixing some (100+ :blush:) raw-generic type warnings

Did you run the checkstyle plugin? It says there are some checkstyle violations. I'll check out your code and look into it. Checkstlye can be a nuisance sometimes. Thanks for your PR though I'll review it ASAP.

Oops I completely forgot tests... :blush:

I think it did not run the tests because Checkstyle failed the build before it got there. :D

So I checked your PR and fixed the checkstyle problems. There is something which I'd like to clarify:
which parts are the optimization? I mean I'd like to know exactly what resulted in a huge speedup for you because there are some redundancies (pointList vs pointArray for example). I'd like to remove them but keep the stuff which is faster. The code looks good btw, thanks!

which parts are the optimization?
Well what I mainly did was pre-calculating some things on every hexagon-instantiation instead of when a method was invoked, wich creates a general speed boost (altough not that big). Also it just makes more sense.

I mean I'd like to know exactly what resulted in a huge speedup for you
Well I didn't really test the pre-calculations individually but I guess the pre-calculations of the points (HexagonImpl.calcPoints()) had a big part in it and not having to call List.toArray every frame could also have helped (It pre-calculates these now).

because there are some redundancies (pointList vs pointArray for example)
Well I made changes over the cours of weeks and pushed them waaay later so I don't remember clearly why they're both in here. What I can see now is that getPointList() is just a "workaround" for the "general" type List of getPoints() because my mind derped and didn't really figure out I could just edit the Hexagon interface to change it. That could be easily changed.

why vertices is useful? From what I understand it is simply a denormalized list of points so it contains all the points flattened like this: (x, y, x, y, etc...).
Would you kindly clarify these?
It's exactly what you understood it is, it's useful for rendering (at least in my GDX-implementation). You could remove it, I guess I didn't fully qualify it as GDX-exclusive in my head.

The code looks good btw, thanks!
Well that's the first time in forever that I've heard that :joy:

Cool, then I'll leave everything in place but I'll factor the getPointArray out since an ArrayList is backed by a real array and it does not have any overhead whatsoever. Is this OK for you? I tend not to use plain arrays because they don't add anything compared to a List and using a List isn't noticeably slower.

Is this OK for you?

Sure it's your project :man_shrugging:

Cool, I've released a new version. Related reddit post here


add option to copy .htaccess or other files verbatim

Use case:
User is transferring to a web server supporting htaccess and needs to keep the htaccess there for 301 redirects or such (this may pave the way for including our own .htaccess/entries for the wp-content to contents, etc rewriting
Other uses may include favicons (should be a default kind of thing, though).

Other use cases include:

Users change a headline of a WP post, and update the URL correspondingly, but want to keep the original URL. (Note: this is probably the most common use case.)

User removes a page, but doesn't want it the former page going to an error page but instead to redirect it to another page such as the front page of the site

Certain pages are password protected via the .htaccess (note: the .htpasswd file also needs to be moved in those cases)

.htaccess removes the "www." from URLs to have all URLs redirect to the non-www form. Or vice-versa.

.htaccess redirects all users from the 'http://' URL to the 'https://' URL.

.htaccess to ban any access to a directory, like a directory of just the the backup plugin-created .zip backup files

.htaccess to ban users from downloading certain file-types, like to prevent any access to .zip or .tar.gz or .docx files

Other Notes / Suggestions:

The fantastic plugin "Redirection" ( https://wordpress.org/plugins/redirection/ ) has over 1+ million installs, and it includes lots of great functionality, and it modifies the .htaccess with the rules that the plugin either automatically creates [when a post name changes etc] or you create manually via the plugin. So this is basically ensuring compatibility with this plugin.

The .htaccess and .htpasswd files aren't only in the root directory, it's common to put them in sub-directories also, so ensure that this copies the files in all/any directories

The main complexity seems to be that the .htaccess file will contain a bunch of code that's no longer needed -- most notably, code from a caching plugin, for example. One possible solution is to search for and remove the code from all the major caching plugins. (Don't forget my beloved WP-Rocket, hehe.)

Special feature request: to me, it makes the most sense to use the .htaccess file to make my privateinvisibleWP.domain.com site [the subdomain for the WP install that creates the text files to be moved over] to make the entire site private via the htaccess file. It would be amazing to have the ability to modify the htaccess to do that but not carry over that one line to the live version.

I so use the .htaccess file soooo much that.... I once created a plugin to help manage it by doing some particular functionality easily via the WP interface: https://en-au.wordpress.org/plugins/htaccess-site-access-control/ [I also made a paid version once that like 6 people bought, but that I never marketed it but it never caught on organically] so I'm happy to give you free access to the paid version if you want to use/test it btw! My gift to you ;)

I personally use all the above use cases extensively so I'm happy to test it as needed, or to provide to you sample .htaccess files from one of my sites to test or to let you know which plugins I use that modify the .htaccess files, etc.

I realized in the shower this morning that: while I suggested removing the .htaccess code for the caching plugins -- on reflection, it may be more complex than that. Lots of caching plugins add .htaccess lines that do something valuable, like the gzipping, and more broadly, with the flat files, some parts of the caching are made irrelevant but some parts aren't. This requires more thought. Possible solutions include: [a] options to turn it on/off that the user has, [b] maybe support a very limited number of caching plugins [including wp-rocket of course haha] and have a deeper integration with them, [c] give users an interface to adjust the .htaccess rules via your plugin on the static site.
Yeah I know I'm obsessed with your plugin ;)

Thanks @themorgan for further fleshing this out.
Perhaps the easiest way for the first cut of this, is to present the user with a copy of the original WP site's .htaccess, with some rules added for 301's of the wp-content to contents, etc as the plugin has set or they have overridden.
Any more advanced usage beyond that and the user is probably proficient enough to setup some more scripts. I should have SSH/SCP deploys working soon, where the user will have the ability to add some pre/post commands to the deploy, such as to unzip an archive on the remote or such.

Love it! Agreed that anyone who is editing it at the level I articulate above will know what they're doing, or at least think they know what they're doing. And this is much simpler than the complex solution I was imagining above. Some further thoughts on that:
1 - the .htpasswd should always go hand-in-hand with that
2 - not just for the root directory (I often edit the .ht-files in /wp-admin for example)
Thank you!

@themorgan - I'll migrate this over to an Idea topic on forum.wp2static.com soon and close the issue.
Hopefully, you've had a chance to play around with the new WP-CLI integration, else will with the release. This should give the behaviour of what I was mentioning re the SCP/SSH deploys, which I don't think I will do via the UI anymore, or at least not for sometime, as the WP-CLI runner now affords the flexibility DIY those workflows.


linux-hardkernel: 4.14.78-150 -> 4.14.81-151

Motivation for this change
Simple version bump.
Things done
This is up and running on my Odroid HC1.

[x] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
Built on platform(s)

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Assured whether relevant documentation is up to date
[x] Fits CONTRIBUTING.md.

Would you mind amending the commit message to use a correct attribute name? linux_hardkernel_4_14 or linux_hardkernel_latest?


Self-Practice Recommendations

Hello all! I am looking to improve my programming skills/computational thinking specifically relevant to this module's topics. Given that my only computing experience is CS1010 from a year ago, and suppose that I am willing to dedicate 1-2 hours of extra time per week to self-practice in addition to the module exercises/labs, how best should I go about this?
I was thinking of following a practice problems book (as compact as possible 🤣), though I do not know where to find such a book, but I am open to any other recommended resources as well. Looking forward to any suggestions for resources and/or tips! Thank you!

Hi, it is great that you want to put in extra practice! For CS2030, I would think that the exercises and labs are enough, as long as you complete them. You should also code the programs snippets from lecture and recitations to see the behavior for yourself. Hit those compile errors yourself so you learn to debug your own programs. Also learn to read to Java API docs to figure out how you should use classes from Java.
There is no practice book suitable for this class, but if you still need more practice, try to come up with interesting problems with friends.

Student here; disclaimer that I am not a TA and speaking from experience
One thing that helped me ease into CS2030 is coding a decently big OOP project over the summer break. I made a lot of mistakes, and I struggled to prevent code from growing too unwieldy. When CS2030 started and the lecturer went over the OOP principles, a lot of things clicked for me since I had made mistakes (circular dependency especially) where it would have helped to organize my code a bit better.
I'd say find something you're passionate about and do a medium scale coding project. You'll make a lot of mistakes along the way (and it may be possible you won't even finish) but experience helps, a lot.
For some ideas, maybe a Discord/telegram bot with functions that build on top of each other? Or a small text-based game, since games have many different moving parts that build on one another. The former would require some research on external libraries (which is out of scope for CS2030) but is easier to see how things apply to something you use frequently.

Thank you very much for the suggestions and tips everyone! 🙏

This is not an official textbook for CS2030, but I would recommend the book "Effective Java". A lot of the concepts taught in CS2030 seems to be explained inside.

Looks really good, thank you!


Adjust default height on volume study and add green / red colour

The Chore
The volume chart is now displayed as default on console, request two tweaks to the way its presented.
Tasks

[ ] Adjust the default height to be approx half to 2/3rd what it is now
[ ] Colour all candles the same colour as the price candle for the same time period

Additional details / background info
Example from Binance

Blocked by https://github.com/vegaprotocol/pennant/issues/705

This is all done


How to make the alarm work?

Version: pinpoint 1.5.2
According to the guide
https://github.com/naver/pinpoint/blob/master/doc/alarm.md#2-implementation--configuration
I have setup the database for user and batch, and used the maven overlay to add the AlarmMessageSenderImpl to implement the email function.
The pinpoint web is working well, and i have setup the userGroup and user with correct email address. And setup the alarm rules as below

But it seems not working, i can't get the email and even the debug(info level and sysout) log.
What's wrong with my configuration? how to make it work.
Pls help, thanks in advanced!

Something wrong with my spring configuration, now it works.


In-place upgrade from previous release fails on Ubuntu 14

These steps might be able to be simplified but to make sure I wasn't doing anything wrong, this is what I did:

Set up three Ubuntu 14 systems.  One to build OpenGEE 5.2.3, one to build 5.2.4, and one to install on (the deployment system).
Build OpenGEE 5.2.3 and the installer on one machine.
Build OpenGEE 5.2.4 and the installer on another machine.
Copy the install files to the deployment system. I created a dir named ~/installers with subdirs of opengee523 and opengee524.
On the deployment system:
a. Clone the google/earthenterprise repository.
b. Checkout the release_5.2.3 branch.
c. Install OpenGEE 5.2.3 on the deployment system. Use the -dir parameter to specify the location of the install files.
d. Checkout the release_5.2.4 branch.
e. Attempt to install fusion and notice the incorrect values for the asset root, fusion user, and group.
f. Exit as there's no need to attempt the install.

The problem is visible in the initial output from install_fusion.sh:
ubuntu@geeserver:~/src/earthenterprise/earth_enterprise/src/installer$ sudo ./install_fusion.sh -dir /home/ubuntu/installers/opengee524
cat: ../version.txt: No such file or directory

Welcome to the Google Earth Enterprise Fusion  installer.

You have chosen to install Google Earth Enterprise Fusion with the following settings:

# CPU's:                2
Operating System:       Ubuntu 14.04
64 bit OS:              YES
Backup Fusion:          YES
Install Location:       /opt/google
Asset Root:              -------
/usr/local/google/gevol_test/assets
Source Volume:          /gevol/src
Fusion User:             -------
gefusionuser
Fusion User Group:       -------
gegroup
Disk Space:

Filesystem      Size  Used Avail Use% Mounted on
udev            2.0G   12K  2.0G   1% /dev
tmpfs           396M  356K  395M   1% /run
/dev/xvda1       59G   12G   46G  20% /

X (Exit) the installer and cancel the installation - C (Continue) to install/upgrade.

The failure is in reading the existing /etc/opt/google/systemrc configuration file.
Here is a test script I wrote to isolate the problem:
ubuntu@geeserver:~/src/earthenterprise/earth_enterprise/src/installer$ cat test.sh
#!/bin/bash

set +x
umask 002

SCRIPTDIR=`dirname $0`

. $SCRIPTDIR/common.sh

GEFUSIONUSER_NAME=$(xml_file_get_xpath "/etc/opt/google/systemrc" "//Systemrc/fusionUsername/text()")

echo "GEFUSIONUSER_NAME=\"${GEFUSIONUSER_NAME}\""

and the output:
ubuntu@geeserver:~/src/earthenterprise/earth_enterprise/src/installer$ ./test.sh
cat: ../version.txt: No such file or directory
GEFUSIONUSER_NAME=" -------
gefusionuser"

It appears this has been broken since 5.2.2. I used this test script against the branches release_5.2.2 and release_5.2.3 and got the same result.
WORKAROUND:  In your local clone, edit earth_enterprise/src/installer/common.sh.  In the xml_file_get_xpath() function, change the tail command to from "+2" to "+3".

Did you stage an install before running this?

Yes, on a separate Ubuntu 14 system.  I then copied the /tmp/fusion_os_install dir to the system running 5.2.3.

Updated the description with reproduction steps and more detail.

The install scripts need to be updated to support running in that scenario.
Otherwise, you want to compare the versions of xmllint running on the various platforms.


Ensure popular Swift Frameworks on GitHub build fine

This requires #29 to be solved. Then it can be merged.


Post process script missing some variables or not sure how to use them

Hi,
Running ubuntu 16.04, SABNZBD, and using sickbeard_mp4_automator script, SABPostProcess.py.  I would like to enable using a post processing script to do file renames before sending it back to the appropriate tools (ie sonarr/radarr).  I would like to use filebot, but to have the script process the file I need some some information which is normally passed to the SABPostProcess.py script, but doesn't look like a way to pass it to the post processing script.
Filebot is looking for the following info to process the files:
Input Parameters
ARG_PATH="$1"  #The final directory of the job (full path)
ARG_NAME="$3" #Clean version of the job name
ARG_LABEL="$5" #user-defined category
From -> https://github.com/filebot/plugins/blob/master/bash/sabnzbd-postprocess.sh
descriptions are taken from here -> https://sabnzbd.org/wiki/scripts/post-processing-scripts
The variables which are documented to be available do not seem to be helpful to me in this case.
So my question is, how can I get the variables passed to the SABPostProcess.py script to the postprocess script?  Are there any work arounds which might allow me to incorporate filebot renames into updating my video files?

I now realize I can just schedule filebot to run the amc script at a regular intervals.


Fixes 4526: added subscription check in templates

Summary
This PR introduces a subscription check for disabling template add/edit actions (and routes) for users that don't have a valid RHEL subscription.
Testing steps
Verify that when signed in with a user that has a valid subscription everything works fine.
And when signed in with a user that doesn't (the future API implementation determines that) these things are true:

Add Content Template is disabled on the template page.
The kebab menu is disabled for each item in the template table.
The actions select in the Template Detail view is disabled.
You can't access the add/edit template modal by visiting the URL for it.

https://issues.redhat.com/browse/HMS-4526

/retest

Okay functional review looks good, just a question here.
(More for @jlsherrill)
Should we be using this functionality for more than just the templating-write permissions.
Would it make sense to stop a user from associating a template to a system as well?

Yes, associating or unassociating a system should require template write (for now)

/retest

Adding another requirement here! 😅
All template edit related actions  should be disabled if the user does not have a subscription.
But the delete action should still be permitted if the user has template-edit permissions.
This would mean that we should enable both of these drop downs:

But disable the corresponding actions within them if the user does not have a subscription.

/retest

/retest

Hi
Thanks for the fix @dominikvagner
No longer breaks ephemeral, merging and  will test again in stage.


esphome + tuya causes unresponsive device

Just flashed a BK7321T (WB3S) module with libretuya and it seems to be working, until I add the tuya: module to my esphome yaml, after which the API becomes unresponsive. I can still upload new firmware with esphome, so it's not like it's completely bricked. I guess it's probably boot looping? Can't connect to view logs and can't connect to it in home assistant
Is the TuyaMCU module not supported yet? Serial seems to be working so I figured this would too, but I guess not?

We haven't tested TuyaMCU yet. What is the exact config you're using? Maybe something's wrong with the UART settings.

Ah ok, that's unfortunate. Hopefully I messed something up. I'm using the same config I used for the version of this that has an esp8266.
substitutions:
  device_name: mtl-light-dining-room-fixture
  friendly_name: Dining Room Light Fixture
  ip_addr: <IP_ADDRESS>
  icon: "mdi:chandelier"

esphome:
  name: ${device_name}

libretuya:
  board: wb3s
  framework:
    version: latest

# Make sure logging is not using the serial port
logger:
  baud_rate: 0
  # level: VERY_VERBOSE

api:
  encryption:
    key: !secret encryption_key

ota:
  password: !secret ota_password

wifi:
  ssid: !secret wifi_ssid_mtl
  password: !secret wifi_password_mtl
  use_address: ${ip_addr}
  domain: !secret domain_mtl
  fast_connect: on

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: ${device_name}
    password: !secret fallback_ap_password_mtl

uart:
  rx_pin: GPIO3
  tx_pin: GPIO1
  baud_rate: 115200
  debug:
  # rx_buffer_size: 512

# tuya:

# light:
#   - platform: tuya
#     name: ${friendly_name}
#     dimmer_datapoint: 2
#     min_value_datapoint: 3
#     switch_datapoint: 1
#     min_value: 100
#     max_value: 1000

# [17:20:33][C][tuya:048]:   Datapoint 1: switch (value: ON)     -- Switch State
# [17:20:33][C][tuya:050]:   Datapoint 3: int value (value: 100) -- Minimum value
# [17:20:33][C][tuya:050]:   Datapoint 102: int value (value: 0)
# [17:20:33][C][tuya:054]:   Datapoint 4: enum (value: 0)        -- Dimming mode
# [17:20:33][C][tuya:050]:   Datapoint 104: int value (value: 1)
# [17:20:33][C][tuya:050]:   Datapoint 2: int value (value: 722) -- Dimmer value
# [17:20:33][C][tuya:046]:   Datapoint 101: raw (value: 00.00.00)
# [17:20:33][C][tuya:046]:   Datapoint 105: raw (value: 06.00.00)

As per WB3S docs on LibreTuya, UART pins are D10+D11 (UART1) and D6+D7 (UART2).
Your GPIO1 and GPIO3 don't really point to anything. How do you know where the TuyaMCU is connected?

Ahhhh thank you for pointing that out, I think I just hit the same problem on the SS01S. Will test and report back.

Yup that fixed it, thanks for the quick help as usual! Out of curiosity, do you know if that's the failure mode that regular esphome has? It just doesn't start up? Seems strange to me, because as soon as I comment out the tuya: line, it boots fine, even with the wrong uart pins. Anyway, not an issue. Thanks again!

I don't know. Maybe it waits for something on the UART line, or maybe the pins are used by something else and that creates problems.