Interaction between mj-all border attribute and mj-accordian border attribute

Is your feature request related to a problem? Please describe.
Demo at https://mjml.io/try-it-live/Sy2gzO5jQ
Also (because it's short and we might be changing the code as we work):
<mjml>
  <mj-head>
    <mj-attributes>
      <mj-all border="none" />
    </mj-attributes>
  </mj-head>

  <mj-body width="690px" >
    <mj-wrapper padding="20px" >
      <mj-section padding="20px 0 0 0" >
        <mj-column>
          <mj-accordion border="solid blue 1px" >
            <mj-accordion-element>

              <mj-accordion-title>
                accordion title
              </mj-accordion-title>

              <mj-accordion-text>
                accordion text
              </mj-accordion-text>

            </mj-accordion-element>
          </mj-accordion>
        </mj-column>
      </mj-section>
    </mj-wrapper>
  </mj-body>
</mjml>

Note the attribute and property on mj-accordion: border="solid blue 1px".
With the three lines in <mj-head> either
<mj-attributes>
  <mj-all border="none" />
</mj-attributes>

or
<mj-attributes>
  <mj-all border="0" />
</mj-attributes>

the output for the accordion closed is

and the output for the accordion open is

Note the absence of the bottom border(s).
Describe the solution you'd like
Bottom border(s).
Additional info
Without the three lines in mj-head described above (that is, with nothing between the mj-head and /mj-head tags), the output for the accordion closed is

and the output for the accordion open is

There are no other changes to the source. Note the presence of bottom border(s).
Additional behaviors of mj-accordion demonstrated

Notes about icons and defaults:

None of the three variants of code mentioned above included use of mj-accordion attributes icon-unwrapped-alt, icon-unwrapped-url, icon-wrapped-alt, or icon-wrapped-url.
All four of the mentioned attributes have defaults (the plus and minus characters for two of them; imgur URLs for the other two).
Neither result includes either an imgur icon or alternate text.
I would not have been surprised to see either an imgur icon or a character backup.

Notes about text color:

None of the code specified a color for text.
For MJML color attributes (color, background-color, border-color, etc.), all defaults are either white, greys, or black.
The text in both results is blue.
Perhaps there's an undocumented blue default somewhere?

I can't suspect the text color is following the border color. I changed the border color to red and got a red border around blue text.

Describe alternatives you've considered
For the first report, there is the option to not use mj-all.
For the second and third reports, there is the option to always specify the four subject attributes (report 2) and any color attributes (report 3).
In any of those cases, perhaps we'll consider change to MJML documentation.
HTML differences
There are five differences between HTML generated by code mj-all and other code:

Three differences are in style attributes. In each case, code using mj-all includes a property "border:none;" that is absent in the other code.
Two differences are in properties on the <table> tags holding, respectively, the "accordion title" and "accordion text" strings.

For the code using mj-all, both tables include the property "border-bottom:none;".
For the other code, those two tables include instead, "border-bottom:solid blue 1px;".

HTML observations
I find many references mj-accordion-checkbox in several forms. Many have display:none associated. Similarly, I find references to the imgur URLs, both with attribute style="display:none;" among other properties.

It looks like some of the internal border logic shouldn't be affected by mj-all, cc @kmcb777 accordion-element should only listen to mj-accordion border and ignore local border attribute
It should be easy to fix in 4.3

@GarryFlemings Hi, thanks for reporting this but this is actually already fixed in 4.2
Attributes transmitted by the parent element now have priority over those transmitted by mj-all


Add variable for representing torque/force in electromechanic converters

In the models

Modelica.Electrical.Analog.Basic.EMF
Modelica.Electrical.Analog.Basic.TranslationalEMF

there is, unfortunately, no alias variable representing torque and force, respecitively.
In order to unify the electromechanical components including machines, it makes sense to additionally introduce the following variables:

Modelica.Electrical.Analog.Basic.EMF tau = flange.tau;
 tauElectrical = -flange.tau;

Modelica.Electrical.Analog.Basic.TranslationalEMF f = flange.f;
 fElectrical = -flange.f;

tauElectrical / fElectrical may then also be used in the internalSupport modification for f / tau.

I probably wouldn't do that to better maintain the symmetry of the torques of the flange and the internal support, as the electrical torque and force rather represent alias variables.
In case of Modelica.Electrical.Analog.Basic.EMF I would go for the following equations (an keep the rest as it is):
  SI.Torque tau "Torque of shaft";
  SI.Torque tauElectrical "Electrical torque";
equation
  tau = flange.tau;
  tauElectrical = - tau;

Actually, I would additionally change the original implementation to
  Mechanics.Rotational.Interfaces.InternalSupport internalSupport(tau=-tau)
equation
  tau = -k*i;

This is what I meant.
Mechanics.Rotational.Interfaces.InternalSupport internalSupport(tau=tauElectrical);


Progress Update Does Not Save

I try to enter a number into the "progress update" field but it does not save in the field or reflect in the "total approved quantity."

@angaither - @namimody is blocked on testing other override functionality with this issue.


Plugin Generator page is missing

Describe the bug
Plugin Generator page https://verdaccio.org/docs/plugin-middleware/plugin-generator is missing (linked from https://verdaccio.org/docs/plugin-middleware/#generate-an-middleware-plugin)
To Reproduce
Go to https://verdaccio.org/docs/plugin-middleware/#generate-an-middleware-plugin and click on the "plugin generator" link.

Plugin generator is deprecated, too much work for maintain and I couldn't find anyone take care of it. We should update docs.

@hybridherbst I cannot reproduce. Anyway I just changed my mind and I updated the generator.


New attack: set SPN

Good afternoon, I added a few new flags into the tool to support removing a user from groups (gotta clean up sometimes), as well as setting a SPN on an account so you can kerberoast it (--set-spn)

Hello,
Thanks for your contribution.
Can you update the README with the new help menu and an example for the new functions?
:sunflower:

added as requested

Whoa! I'm sorry, it seems I f up your PR.
However your contribution has been merged.
Thanks!


go test fails on a clean windows install

Howdy!
I'm fairly new to go so help me out if I'm completely in left field on this one.
Running a plain go test on a clean windows install of gosigar fails. I believe that this is due to platform differences between windows and *nix systems that are not accounted for in the sigar_interface_test.go and the concrete_sigar_test.go outlined in detail in this pull request: elastic/gosigar/pull/13
One example is that executables in windows need a ".exe" suffix whereas in a *nix system this need not be the case
Apologies for the rough cmd window formatting :)
←[90mC:/Projects/GoWorkspace/src/github.com/elastic/gosigar/sigar_interface_
test.go:100←[0m

  ←[91mExpected
      <[]string | len:2, cap:2>: ["go", "ginkgo"]
  to contain element matching
      <string>: go.exe←[0m

Perhaps an appveyor + travis CI server would help illuminate these types of issues by building and running tests on all environments gosigar is deployed :)

There is already a travis build running: https://travis-ci.org/elastic/gosigar It would be great if we could also add appveyor for the windows build.
Probably we should also link the Travis build in the README: https://github.com/elastic/gosigar/blob/master/README.md
For the appveyor config it is best to have a look at the file from the beats project: https://github.com/elastic/beats/blob/master/.appveyor.yml

go test is passing on Windows.
AppVeyor and TravisCI both build this project (and badges added to README).

Awesome! :smile: :+1:


feat(docs): update references to removed appengine and artifacts feature flags

feat(appengine): remove reference to removed feature flag
We removed the long-unused appengineContainerImageUrlDeployments from Halyard; let's update the corresponding documentation to clarify that this flag is no longer needed.

feat(artifacts): update instructions for enabling artifacts
As of Spinnaker 1.20, the standard ("rewrite") artifacts experience will be enabled by default. Let's re-label the previous "Standard" artifacts experience to "Legacy," move its section under the now-default artifacts documentation section in the nav, and replace all instructions for enabling artifacts with a reference to a new Enabling Artifact Support section. Per the RFC, we can safely remove all legacy artifacts documentation after release 1.23, when no supported release will include the legacy artifacts experience.

@fifthposition , FYI

Thanks @maggieneterval and @dorbin! Sorry I didn’t stick around to finish the artifacts rewrite work... 😢

No prob, Ben! Just wanted you to see it come to fuition.


Fixed .glide error

Fixes error while building vagrant (vagrant up), when no glide repository is available in the host OS.
Summary of changes:

Instead of always syncing the .glide directory from the host and guest OS, it's done now only when this directory exists in the host OS

Testing done:

The vagrant up command runs now fine.

run integration tests

run integration tests

run integration tests


Check for privilleged execution with getauxval.

Check getauxval on systems that have it when checking for setuid execution.

I also cleaned up the preprocessor directive guarding the include line.
That's enough changes to justify a review I think.

Merged thanks.


Add note about Spring Boot Starter dependency to README

Description
The README should mention to use the Spring Boot Starter dependency instead of the core dependency when working with Spring Boot.
Motivation and Context
To combat issues like this one https://github.com/zalando/logbook/issues/218#issuecomment-506634294
Types of changes

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

Checklist:

[x] My change requires a change to the documentation.
[x] I have updated the documentation accordingly.
[ ] I have added tests to cover my changes.

:+1:

Thanks for the contribution!


Script overhaul

Hey,
I have put some time into this script as I am using it on a daily basis. Therefore, added some nice little things to it:

Added more comments around the code, added docstrings
Linted file via prospector (linting rules are available at .prospector.yaml)
Simplified snapshot delete logic
Added possibility to specify amount of snapshots to retain (-r or --retain)
Added possibility to set custom snapshot name from command line (-n or --name)
Added possibility to set custom snapshot description from command line (-d or --description)
Added verbosity flag for a detailed output from a script (-v or --verbose)
Updated .gitignore to ignore python venv
Removed unused requirements from requirements.txt, updated the ones used

Overall, basic usage remained unchanged, but new extra stuff was added.

Hi @dimsanius, as usual thanks a lot.
Of course I'll integrate your improvements 👍 .


Ensure when npm-linking govuk-frontend browsersync picks up changes.

Enables you to make changes in the GOV.UK Frontend project and see it update
in the design system quickly.
As part of https://github.com/alphagov/govuk-frontend/pull/624

You can preview this change here:
Built with commit e867318f3d78a0b2380e01bb47983c62615030d7
https://deploy-preview-227--govuk-design-system-preview.netlify.com


Replace buildin.addressof with withUnsafeMutablePointer

@swift-ci Please test

@swift-ci Please smoke test

@jrose-apple, is this really an improvement? I'm worried that it looks safer than it actually is because it breaks the safe usage of withUnsafeMutablePointer. If we're going to do that then we may as well keep doing the thing that also looks unsafe.

Builtin.addressof is no more or less safe than withUnsafeMutablePointer; they are unsound in exactly the same cases.

(modulo lifetime concerns)

Oh, wait, never mind. I should read the patch first.
Xin, I meant to put the whole body inside the withUnsafeMutablePointer. It's not considered safe to propagate that address out of the body.

It's not considered safe to propagate that address out of the body.

Why?  It is an address of a global.  It is valid for the whole program execution.

I agree with @jrose-apple, Builtin.addressof with a comment that we're relying on its operand being a non-reabstracted global variable is better than pretending we're being safe by misusing withUnsafePointer.

I'm not sure if that's agreeing with me or @gribozavr. I want to use withUnsafeMutablePointer the usual way with a comment saying we're relying on it being the actual address (on the grounds that external developers should be able to do the same thing). @gribozavr wants to use Builtin.addressof with the same comment (which is what @trentxintong originally implemented, though without the comment). The current patch doesn't do either (sorry, Xin).

@gribozavr wants to use Builtin.addressof with the same comment

I don't actually care whether there is a comment or not.  The use of the builtin is enough of a signal that something unusual is happening, and the whole method is small enough for the reader to immediately notice the atomic operations.

@jrose-apple sorry that i misunderstood you.
I am fine to move everything in the function into the closure (i feel it might "look" safer), But i also agree with @gribozavr that the variable is an address of a global which is valid for the whole program execution and the builtin is enough of a signal that something unusual is happening.
I am going to let this stay as a builtin.addressof unless we have compelling reasons that withUnsafeMutablePointer leads to a real improvement.

Sure, that's fine until we decide to either try to kill addressof or to get more aggressive reasoning about global writes for some reason.

All right, guess I'm overruled. Thanks for the discussion, at least (and thanks for humoring me, Xin).


Keyboard event objects for accessibility.

Feature Proposal
Accessibility standards suggest that all elements that are able to be interacted with by mouse must also have keyboard interactivity visit https://www.w3.org/WAI/WCAG21/Understanding/keyboard. Currently to the best of my knowledge this interactivity does not exists and is not codable within the canvas elements that your service generates.
Possible Implementation
As with other event objects keyboard or tab events can be added for an added layer of accessibility for none mouse users.

@bthornburg-av maybe something is already available.
I have created a codepen where:

a plugin implements beforeEvent hook to manage events
the plugin is managing ONLY keyup event (see events: ['keyup'], in the plugin object)
enable keyup event (and click) on the chart, setting events option set to events: ['click', 'keyup']

How it works:

click on "Focus" button to set focus on canvas (note tabindex="1" attribute of canvas element)
pressing ArrowRight key, you can set as active element the points going to the right
pressing ArrowLeft key, you can set as active element the points going to the left
pressing Enter, onClick callback of the chart is invoked and show in the selected index below the button.

Codepen: https://codepen.io/stockinail/pen/BarGxjM

Duplicate of #1976


Failure to hash function when using .map()

Describe the bug
Parameter 'function'=<function process at 0x7f1ec4388af0> of the transform datasets.arrow_dataset.Dataset._map_single couldn't be hashed properly, a random hash was used instead. Make sure your transforms and parameters are serializable with pickle or dill for the dataset fingerprinting and caching to work. If you reuse this transform, the caching mechanism will consider it to be different from the previous calls and recompute everything. This warning is only showed once. Subsequent hashing failures won't be showed.
This issue with .map() happens for me consistently, as also described in closed issue #4506
Dataset indices can be individually serialized using dill and pickle without any errors.  I'm using tiktoken to encode in the function passed to map(). Similarly, indices can be individually encoded without error.
Steps to reproduce the bug
from datasets import load_dataset
import tiktoken

dataset = load_dataset("stas/openwebtext-10k")

enc = tiktoken.get_encoding("gpt2")

tokenized = dataset.map(
    process,
    remove_columns=['text'],
    desc="tokenizing the OWT splits",
)

def process(example):
        ids = enc.encode(example['text'])
        ids.append(enc.eot_token)
        out = {'ids': ids, 'len': len(ids)}
        return out

Expected behavior
Should encode simple text objects.
Environment info
Python versions tried: both 3.8 and 3.10.10
PYTHONUTF8=1 as env variable
Datasets tried:

stas/openwebtext-10k
rotten_tomatoes
local text file

OS: Ubuntu Linux 20.04
Package versions:

torch 1.13.1
dill 0.3.4 (if using 0.3.6 - same issue)
datasets 2.9.0
tiktoken 0.2.0

Hi ! enc is not hashable:
import tiktoken
from datasets.fingerprint import Hasher

enc = tiktoken.get_encoding("gpt2")
Hasher.hash(enc)
# raises TypeError: cannot pickle 'builtins.CoreBPE' object

It happens because it's not picklable, and because of that it's not possible to cache the result of map, hence the warning message.
You can find more details about caching here: https://huggingface.co/docs/datasets/about_cache
You can also provide your own unique hash in map if you want, with the new_fingerprint argument.
Or disable caching using
import datasets
datasets.disable_caching()

@lhoestq Thank you for the explanation and advice. Will relay all of this to the repo where this (non)issue arose.
Great job with huggingface!

We made tiktoken tokenizers hashable in #5552, which is included in today's release datasets==2.10.0

Just a heads up that when I'm trying to use TikToken along with the a given Dataset .map() method, I am still met with the following error :
  File "/opt/conda/lib/python3.8/site-packages/dill/_dill.py", line 388, in save
    StockPickler.save(self, obj, save_persistent_id)
  File "/opt/conda/lib/python3.8/pickle.py", line 578, in save
    rv = reduce(self.proto)
TypeError: cannot pickle 'builtins.CoreBPE' object

My current environment is running datasets v2.10.0.

cc @mariosasko

@lhoestq @edhenry I am also seeing this, do you have any suggested solution?

@lhoestq @edhenry I am on datasets version '2.12.0'. I see the same TypeError: cannot pickle 'builtins.CoreBPE' object` that others are seeing.

I am able to reproduce this on datasets 2.14.2.

I  have met the same problem, here is my env:
datasets                      2.14.4
transformers                  4.31.0
tiktoken                      0.4.0
torch                         1.13.1

It seems that such errors only occur when using batched=True:
TypeError: cannot pickle 'builtins.CoreBPE' object

@mengban I cannot reproduce the issue even with these versions installed. It would help if you could provide info about your system and the pip list output.

@mariosasko Please take a look at this
from typing import Any
from datasets import Dataset
import tiktoken

dataset = Dataset.from_list([{"n": str(i)} for i in range(20)])
enc = tiktoken.get_encoding("gpt2")

class A:
    tokenizer = enc #tiktoken.get_encoding("gpt2")

    def __call__(self, example) -> Any:
        ids = self.tokenizer.encode(example["n"])
        example["len"] = len(ids)
        return example

a = A()

def process(example):
    ids = a.tokenizer.encode(example["n"])
    example["len"] = len(ids)
    return example

# success
tokenized = dataset.map(process, desc="tiktoken", num_proc=2)

# raise TypeError: cannot pickle 'builtins.CoreBPE' object
tokenized = dataset.map(a, desc="tiktoken", num_proc=2)

pip list
datasets                      2.14.4
tiktoken                      0.4.0

Thanks @maxwellzh! Our Hasher works with this snippet, but the problem is running multiprocessing with a non-serializable tiktoken.Encoding object.
Inserting the following code before the map should fix this:
import copyreg

def pickle_Encoding(enc):
  return (functools.partial(tiktoken.core.Encoding, enc.name, pat_str=enc._pat_str, mergeable_ranks=enc._mergeable_ranks, special_tokens=enc._special_tokens), ())

copyreg.pickle(tiktoken.core.Encoding, pickle_Encoding)

But the best fix would be implementing __reduce__ for tiktoken.Encoding or tiktoken.CoreBPE. If I find time, I'll try to fix this in the tiktoken repo.

I think the right way to fix this would be to have new tokenizer instance for each process. This applies to many other tokenizers that don't support multi-process or have bugs. To do this, first define tokenizer factory class like this:
    class TikTokenFactory:
        def __init__(self):
            self._enc = None
            self.eot_token = None

        def encode_ordinary(self, text):
            if self._enc is None:
                self._enc = tiktoken.get_encoding("gpt2")
                self.eot_token = self._enc.eot_token
            return self._enc.encode_ordinary(text)

Now use this in .map() like this:
    # tokenize the dataset
    tokenized = dataset.map(
        partial(process, TikTokenFactory()),
        remove_columns=['text'],
        desc="tokenizing the splits",
        num_proc=max(1, cpu_count()//2),
    )

A full working example is here: https://github.com/sytelus/nanoGPT/blob/refactor/nanogpt_common/hf_data_prepare.py


Drop-placeholder doesn't seem to apply

Hi !
I'm using vue-smooth-dnd to build a kanban board and it's working well so far.
The only thing that isn't working for me is the :drop-placeholder.
Actually I'm trying to mimic the cards page of the demo.
"vue": "^2.6.10",
"vue-smooth-dnd": "^0.8.1",
"vuetify": "^2.2.21",

      <Container
        group-name="tickets"
        @drop="(event) => onTicketDrop(stage, event)"
        :get-child-payload="getTicketPayload(stage)"
        drag-class="ticket-ghost"
        drop-class="ticket-ghost-drop"
        :drop-placeholder="dropPlaceholderOptions">
        <Draggable
          v-for="ticket in stage.ticketIds"
          :key="ticket.id">
          <v-card outlined class="ticket-card">
            <v-card-title class="subtitle-2">{{ ticket.name }}</v-card-title>
          </v-card>
        </Draggable>
      </Container>

  data () {
    return {
      dropPlaceholderOptions: {
        className: 'drop-preview',
        animationDuration: '150',
        showOnTop: true
      }
    }
  }

  .ticket-ghost {
    cursor: grabbing;
    transition: transform 0.18s ease;
    transform: rotateZ(5deg);
  }
  .ticket-ghost-drop {
    transition: transform 0.18s ease-in-out;
    transform: rotateZ(0deg);
  }
  .drop-preview {
    background-color: rgba(150, 150, 200, 0.1);
    border: 1px dashed red;
    margin: 5px;
  }

What am I doing wrong ?
You can see below that there is no zone with red border that appears :

I'm having this same issue. I can't get a drop-placeholder class to apply either. Any pointers would be appreciated.
<Container id="drag-container" style="min-height:150px;"
        group-name="zone"
        :get-ghost-parent="getGhostParent"
        :get-child-payload="getChildPayload"
        @drag-enter="onDragEnter"
        drag-handle-selector=".objectHandle"
        @drop="onZoneDrop(commonSvc.GetId(zone.id), $event)"
        drag-class="card-ghost"
        drop-class="card-ghost-drop"
        :drop-placeholder="dropPlaceholderOptions">
        <Draggable style="min-height:150px;" v-for="item in zone.sceneobjects" :key="item.id">
          <sceneobject :objectdata="item" />
        </Draggable>
      </Container>

 dropPlaceholderOptions: {
        className: 'drop-preview',
        animationDuration: '150',
        showOnTop: true
      },

.drop-preview {
    background-color: rgba(150, 150, 200, 0.1) !important;
    border: 1px dashed red !important;
    margin: 5px !important;
    z-index: 88888;
    min-height: 200px;
  }

@sheibeck
Waiting for an answer here.

@sheibeck
Try with just :drop-placeholder="true" and the basic drop-placeholder (I guess default one) will appear.
Then I found out the CSS class to which default style is applied, which is .smooth-dnd-drop-preview-default-class but I can't apply other style to it except directly through the developer tools in the browser.
Any advice to force the style ?
I tried with CSS like this :
.smooth-dnd-drop-preview-default-class {
  background-color: rgba(150, 150, 200, 0.1);
  border: 1px dashed red;
}

and even with !important keyword but it doesn't apply.
I also tried > operator to go from element to element with known classes that I found while inspecting the drop-preview element in the developer tools but nothing.

Thanks for the advice. I ended up going a different route. Not related to this issue at all, but just a change in plans.

@sheibeck
No problem. The thing is, I don't know how the author managed to make it works in the demo page. While we can't do it..

I "think" the demo used the JavaScript version instead of the Vue wrapper. But, that just a guess.

I don't think so. Here is the demo page.

Bumping an older issue here but for anyone looking for the answer to this, when using
:drop-placeholder="{ className: '<className>' }"
You need to make sure the css class you're trying to apply isn't scoped, for me this meant moving it to an external global css sheet

Bumping an older issue here but for anyone looking for the answer to this, when using
:drop-placeholder="{ className: '<className>' }"
You need to make sure the css class you're trying to apply isn't scoped, for me this meant moving it to an external global css sheet

Oh god that's true I'm using a  <style scoped> tag.. I'm going to try without the scoped attribute.

You can still use styled <style scoped> by using ::v-deep


Fix PartialStringMatch for function components

Proposed Changes
PartialStringMatch was not highlighting matches rendered by functional components.

Changed the *deepReplaceStrings method so that it picks-up children of functional components
Simplified *deepReplaceStrings method my extracting 2 new methods: lookupChildren and hightlightMatches.

Potential Breaking Changes
None.
Acceptance Criteria

[x] The proposed changes are covered by unit tests
[x] The potential breaking changes are clearly identified
[x] README.md is adjusted to reflect the proposed changes (if relevant)

Codecov Report

Merging #1203 into master will increase coverage by <.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #1203      +/-   ##
==========================================
+ Coverage   99.66%   99.66%   +<.01%
==========================================
  Files         353      353
  Lines        8890     8900      +10
  Branches     2112     2113       +1
==========================================
+ Hits         8860     8870      +10
  Misses         30       30

Impacted Files
Coverage Δ

...onents/partial-string-match/PartialStringMatch.tsx
100% <100%> (ø)
:arrow_up:

...s/partial-string-match/PartialStringMatch.spec.tsx
100% <100%> (ø)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 912867b...df2ba8e. Read the comment docs.


DateTime Picker

new Date() object is changed to "PM" if the time in AM.
<DateTimePicker timeConvention={TimeConvention.Hours12} />

@makafsal I am closing this issue as I believe it was fixed some time ago, but please reopen if you are still experiencing it with a recent version.
Many thanks for reporting it


Pasting a single paragraph with , , possibly others, breaks up paragraph of text

It doesn't appear to happen when you paste more than one paragraph.
To reproduce, paste the following paragraph into the demo.

The Division is a very interesting game. It's a game caught between worlds, and could be described as a shooter, or an RPG, or an MMORPG, or a shoot–and–looter, and it's sort of all of those things and yet none of them. It's a mongrel, and being a mongrel is what gives it the soaring highs as well as the flaws

Thanks for filing this I can reproduce.

Thanks for taking a look 👍


Add postStart hook to remove WAL data

Fix #459

I'm wondering if disabling the WAL may be a cleaner approach, if we're always going to drop the data anyways.
https://github.com/prometheus/prometheus/blob/main/tsdb/db.go#L95

Thanks.
The only missing thing is the ask from @lyanco make this configurable from the operator side. This is due to the fact that persistent and proper WAL handling is great for local debuggabilitity. We want customers to enable/disable it on the fly.
For the same reason we don't want to disable WAL from the Prometheus code. There are a few other reasons:

We want to be prepared for resource usage when we will decide to maintain persistence with remote write. This is to manage expectations going forward.
We don't want to diverge too much with the fork, especially given plan to switch to native remote write at some point.

Do we have precedense on customizing DaemonSet yaml based on operator config @pintohutch @TheSpiritXIII ?

@bwplotka Based on our discussions, my opinion is that the best option is to proceed with implementing the postStart lifecycle hook (the current PR), rather than disabling the WAL. This solution will continue to allow customers to access local data in most circumstances (except immediately after a restart), and is expected to resolve the reported issue.
In additional, the actual window of data loss should be expected to be small, as most data is being sent to the GCP backend quickly - on the order of seconds. So, the scenario where this change would impact customers is only when the collector crashes/restarts and either:

Data of interest was collected immediately preceding a restart, between the time that it was written to the WAL and when it is replicated to GCP.
Customer is interested in debugging local data only, preceding a restart. Data stored in GCP is not a suitable alternative.

In the more somewhat more common case where a customer is interested in looking at local data and the collector has not crashed recently, there would effectively be no difference for their use case, based on this change.
We may want to re-evaluate creating a configuration option to disable the WAL in the future if we have additional reasons to do so.
Let me know if you have any additional comments/concerns.

Thanks. What you said makes sense, it is hypothetically rare. However I see also a use case where users are debugging why metric was not exported (e.g misconfigured filtering). I still see your point that crash/restart reset might be fine if you are debugging metric which is constantly scraped, but the problem might be when user ingested something 1h ago and is debugging now where sample steam is blocked (is sample not scraped? Scraped but not exported? Not exported why?).
Another unknown is self-deployed OSS users. Are we sure we know all their cases? Ideally we let them opt-in to "kill your data on start" - in some way we are not managing their setups to decide about it. By adding this hook, we or user will not have much control over any of this.
This is why I would vote for adding opt-out of force data removal setting for managed GMP from the start. For unmanaged it should be opt-in if possible. Thanks to @pintohutch mention it should be relatively simple to do. We could add OperatorConfig Collector setting "ForceEmptyStorageOnStart bool" (with the right commentary that it's only "local" persistence, for export it does not work yet - might in future). By default false for self-deployed, true by default on GMP managed. (Calling this setting "Persistence bool" might be misleading - even with true export is not truly persistent). Essentially, given we are theoretically imagining certain cases, it's likely we are wrong and we miss important use case.
This setting can control postHook (by templating collector DaemonSet), but I am not sure I am a fan of this. It's generally racy and we have full control of Prometheus to do it there. We could add hidden flag --storage.debug.remove-data-on-start (default false) flag to our Prometheus fork that will explicitly remove all files from "data" directory. Alternatively we can try playing with WAL disable flag (perhaps it discards any WAL?), but remove data flag will be safer and faster (less tests to make), as users might have already corrupted or large WALs. Thanks of Compression precedence passing flag, this should be trivial in operator.
However, we could also skip adding custom code to Prometheus fork and we can simply change collector's DaemonSet data dir to memory when "ForceEmptyStorageOnStart" is true. The only minor nit is that it will improve perf characteristics -- might be not a bad thing as well (: Another nice thing about this is that there is no need to explain or debug any logic of synthetic removal. The memory is ephemeral by design, no extra logic to maintain.
To sum up:

I would still expect a setting in OperatorConfig that controls this behaviour. Data consistency is important for users. CC @lyanco opinion would be valuable (:

Ideally we don't remove data dir for self-deploy users

PostStart Hook might be not the ideal solution, why not changing emptyDir medium to memory? Or collector custom flag.

In my testing, if the container hit an OOM with emptyDir.medium = Memory, the data persisted. The data is not persisted through a node restart, but it did seem to survive a container restart. So, that alone would not solve #459.

Regarding ForceEmptyStorageOnStart, it does not seem like configuration to me, per se. As I understand it, the only use case to opt in for that config option would be because you're running into a bug. But removing the data on startup would not actually result in any runtime differences in the program. So, putting that option alongside other configuration options that all correspond to runtime functionality feels strange to me.
As I think about it, I think the most narrowly tailored solution for the problem that was reported simply allows a customer using a GKE Autopilot cluster a mechanism to delete the data and restart the container as a troubleshooting step. It is likely this would only need to be done once, rather than every time the container starts.
For unmanaged instances, we could probably just add an appropriate kubectl exec -- rm command to the troubleshooting runbook.
Alternatively (in managed/autopilot environments), we could watch for OOM events and use that event as a trigger to reset the data in the container. It's theoretically possible to have some OOM events that are not related to this issue, but it would have greater accuracy than unconditionally wiping the data every startup.

https://github.com/GoogleCloudPlatform/prometheus-engine/pull/518#issuecomment-1648331138 - wow nice, good to know, thanks!
Cool, all of those are nice ideas, all have some trade-offs.  I agree runtime/environment impression around this configuration, the alternative is to configure patch Daemon Set based on that config. It is weird, but other options (Autopilot node restart and kubectl exec -- rm) are far less scalable and more painful for support and customers. We know it's safe to kill it so why not doing it always until we have full persistence?

We need more eyes on this too, so short proposal outlining option might be amazing if we want to progress on it, WDYT?
Thanks for elaborating 💪🏽


how do i upgrade project

I don't remember how did I installed, (not git), but now I want to upgrade my wakapi instance. I tried to download the latest .tar.gz file, extracted in the same folder, edited docker-compose.yaml with previous settings and ran docker-compose up -d --force-recreate but this removed all data on my postgresql database. I reverted back from backup and it's now working on previous version of 2.0.2
Thanks in advance

Can you please show us the previous docker-compose.yml?

version: '3.7'
services:
wakapi:
build: .
ports:
- 3000:3000
restart: always
environment:
WAKAPI_DB_TYPE: "postgres"
WAKAPI_DB_NAME: "wakapi"
WAKAPI_DB_USER: "wakapi"
WAKAPI_DB_PASSWORD: "pass"
WAKAPI_DB_HOST: "db"
WAKAPI_DB_PORT: 5432
ENVIRONMENT: "prod"
WAKAPI_DB_MAX_CONNECTIONS: 4
WAKAPI_MAIL_SENDER: "mail"
WAKAPI_MAIL_SMTP_HOST: "smtphost"
WAKAPI_MAIL_SMTP_PORT: 587
WAKAPI_MAIL_SMTP_USERNAME: "username"
WAKAPI_MAIL_SMTP_PASSWORD: "pass"
WAKAPI_ALLOW_SIGNUP: "false"
db:
image: postgres:12.3
environment:
POSTGRES_USER: "wakapi"
POSTGRES_PASSWORD: "pass"
POSTGRES_DB: "wakapi"

Make backup.
Create named volume defined in new docker-compose.yml.
docker volume create --name wakapi_wakapi-db-data
Get existing volume name.
docker inspect wakapi-db-1 | jq '.[0].Mounts'
Shut down existing containers. Note: If you were to bring it back up again, it seems to start with a new volume (i.e. it appears that all the data is gone).
docker-compose down
Copy from old to new volume. e.g.:
docker container run --rm -it -v 701ffdad1fe74f61ae1073554abe5495391ab98d14cfb5807f18cb33563e159c:/from -v wakapi_wakapi-db-data:/to alpine ash -c "cd /from ; cp -av . /to"
https://stackoverflow.com/questions/67567986/copy-docker-volumes

@fuzunspm Was this helpful for you? Can the issue be closed?

Yes thank you!


SortMeRNA exceeds requested resources

Hi, after several tests I noticed that for some samples SortMeRNA fails with error 143, after running for 16 hours. It can't be a lack of resources, given 40 cores and 500GB RAM.
I run the pipeline as follows:
nextflow run nf-core/rnaseq \
    --input 'samplesheet.csv' \
    --outdir 'sample/out/' \
    -profile singularity \
    -c 'nf_rnaseq.conf' \
    -r dev

With this config file:
// Global params
params {

  // References
  genome           = 'GRCh37'
  transcript_fasta = 'rnaseq_pipeline/transcripts.fa'
  salmon_index     = 'rnaseq_pipeline/salmon_index/'
  star_index       = 'rnaseq_pipeline/STARIndex/'
  fasta            = 'rnaseq_pipeline/references/GRCh37/WholeGenomeFasta/genome.fa'
  gtf              = 'rnaseq_pipeline/references/GRCh37/genes.gtf'
  gene_bed         = 'rnaseq_pipeline/references/GRCh37/genes.bed'
  save_reference   = false

  // Ribosomal RNA removal
  remove_ribo_rna        = true
  save_non_ribo_reads    = false
  ribo_database_manifest = 'rnaseq_pipeline/rRNA_db.txt'

  // Alignment
  unStranded           = true
  aligner              = 'star'
  pseudo_aligner       = 'salmon'
  min_mapped_reads     = 5
  save_unaligned       = false
  save_align_intermeds = false
  skip_markduplicates  = false
  skip_alignment       = false

  // Read Counting
  fc_extra_attributes    = 'gene_name'
  fc_group_features      = 'gene_id'
  fc_count_type          = 'exon'
  fc_group_features_type = 'gene_biotype'
  skip_featurecounts     = false
  skip_biotype_qc        = false

  // Don't skip any QC
  skip_qc        = false
  skip_bigwig    = false
  skip_stringtie = false
  skip_fastqc    = false
  skip_preseq    = false
  skip_dupradar  = false
  skip_qualimap  = false
  skip_rseqc     = false
  skip_deseq2_qc = false
  skip_multiqc   = false
  multiqc_title  = false
  deseq2_vst     = false
  rseqc_modules  = 'bam_stat,inner_distance,infer_experiment,junction_annotation,junction_saturation,read_distribution,read_duplication'

  // Other options
  pull_docker_container  = true
  max_memory             = 500.GB
  max_cpus               = 40
  igenomes_ignore        = false
  igenomes_base          = 'dbs/iGenomes_GRCh37/Homo_sapiens/'

}

// Singularity
singularity {

  enabled                = true
  singularity.autoMounts = true
  cacheDir               = 'dbs/singularity_cache/'

}

// Executor system
process {

  beforeScript = "module load tools singularity/3.6.2"
  executor     = 'pbs'

}

And this is the execution trace:

task_id
hash
native_id
name
status
exit
submit
duration
realtime
%cpu
peak_rss
peak_vmem
rchar
wchar

2
42/f184e6
27773061.moab
INPUT_CHECK:SAMPLESHEET_CHECK (samplesheet.csv)
COMPLETED
0
2020-10-26 13:42:53.890
1m 9s
0ms
42.4%
1 MB
11 MB
660.9 KB
499 B

1
3d/b02fd2
27773062.moab
GET_CHROM_SIZES (genome.fa)
COMPLETED
0
2020-10-26 13:42:53.972
1m 9s
12s
93.6%
2.3 MB
26.6 MB
2.9 GB
1.4 KB

3
97/bbd0e6
27773067.moab
CAT_FASTQ (tumor_R1)
COMPLETED
0
2020-10-26 13:44:02.935
59.9s
41ms
0.0%
1.5 MB
3.9 MB
80 KB
218 B

5
fb/2f4108
27773068.moab
FASTQC_UMITOOLS_TRIMGALORE:FASTQC (tumor_R1)
COMPLETED
0
2020-10-26 13:45:04.363
8m 34s
7m 30s
198.1%
1.4 GB
4.3 GB
10.4 GB
4.2 MB

4
3c/ac7981
27773069.moab
FASTQC_UMITOOLS_TRIMGALORE:TRIMGALORE (tumor_R1)
COMPLETED
0
2020-10-26 13:45:04.870
46m 4s
44m 39s
484.1%
4 GB
4.8 GB
275.6 GB
265.1 GB

6
1b/882c67
27774975.moab
SORTMERNA (tumor_R1)
FAILED
143
2020-10-26 14:31:08.674
16h 52s
16h 17s
-
-
-
-
-

This happens only for some samples, while for others it works (although SortMeRNA takes 13 hours!!). Here's the execution trace of a successful run:

task_id
hash
native_id
name
status
exit
submit
duration
realtime
%cpu
peak_rss
peak_vmem
rchar
wchar

2
98/20b915
27780112.moab
INPUT_CHECK:SAMPLESHEET_CHECK (samplesheet.csv)
CACHED
0
2020-10-27 11:40:02.133
15m 4s
0ms
45.6%
1 MB
11 MB
660.9 KB
498 B

1
98/bd1c69
27780111.moab
GET_CHROM_SIZES (genome.fa)
CACHED
0
2020-10-27 11:40:02.071
15m 35s
11s
96.6%
2.3 MB
26.6 MB
2.9 GB
1.4 KB

3
6d/35856c
27780131.moab
CAT_FASTQ (tumor_R1)
CACHED
0
2020-10-27 11:55:06.679
1m 5s
33ms
0.0%
0
0
79.9 KB
217 B

5
ca/abf284
27780136.moab
FASTQC_UMITOOLS_TRIMGALORE:FASTQC (tumor_R1)
CACHED
0
2020-10-27 11:56:11.692
7m 10s
6m 1s
198.2%
1.3 GB
4.4 GB
6.6 GB
4.1 MB

4
0f/3f31b3
27780137.moab
FASTQC_UMITOOLS_TRIMGALORE:TRIMGALORE (tumor_R1)
CACHED
0
2020-10-27 11:56:11.743
46m 11s
33m 40s
482.1%
4 GB
4.9 GB
258.9 GB
252.2 GB

6
24/9fa24a
27780255.moab
SORTMERNA (tumor_R1)
CACHED
0
2020-10-27 12:42:23.316
13h 1m 1s
13h 22s
0.0%
-
-
-
-

7
9d/5ed2e5
27814145.moab
QUANTIFY_SALMON:SALMON_QUANT (tumor_R1)
CACHED
0
2020-10-28 01:43:24.891
17m 10s
15m 11s
576.4%
2.7 GB
4.2 GB
6.8 GB
11.3 MB

8
6f/4b3d46
27814146.moab
ALIGN_STAR:STAR_ALIGN (tumor_R1)
CACHED
0
2020-10-28 01:43:24.946
24m 10s
22m 42s
945.4%
35.7 GB
37.8 GB
94.2 GB
9.3 GB

9
82/3d44d9
27814170.moab
QUANTIFY_SALMON:SALMON_TX2GENE (genes.gtf)
CACHED
0
2020-10-28 02:00:35.468
2m 5s
38s
99.5%
7.1 GB
7.1 GB
874.4 MB
8.1 MB

10
e6/b6f1aa
27814176.moab
QUANTIFY_SALMON:SALMON_TXIMPORT (tumor_R1)
CACHED
0
2020-10-28 02:02:40.300
1m 35s
14s
104.7%
646.1 MB
1.5 GB
84.2 MB
10.1 MB

11
dd/716235
27814180.moab
QUANTIFY_SALMON:SALMON_MERGE_COUNTS
CACHED
0
2020-10-28 02:04:15.402
2m 35s
183ms
63.9%
1.6 MB
3.9 MB
29.1 MB
20.2 MB

12
a0/ee9f13
27814187.moab
QUANTIFY_SALMON:SALMON_SE_GENE (salmon_tx2gene.tsv)
CACHED
0
2020-10-28 02:07:21.312
1m 9s
9s
99.6%
456.8 MB
821.4 MB
59.8 MB
1.2 MB

14
54/61202a
27814186.moab
QUANTIFY_SALMON:SALMON_SE_TRANSCRIPT (salmon_tx2gene.tsv)
CACHED
0
2020-10-28 02:07:21.257
1m 9s
10s
99.4%
442.4 MB
806.4 MB
65.3 MB
4.4 MB

13
f7/b599e6
27814188.moab
DESEQ2_QC_SALMON
CACHED
0
2020-10-28 02:07:24.867
2m 6s
11s
108.4%
520.3 MB
1.3 GB
69.4 MB
5 KB

15
64/800680
27814190.moab
ALIGN_STAR:BAM_SORT_SAMTOOLS:SAMTOOLS_SORT (tumor_R1)
CACHED
0
2020-10-28 02:07:35.649
3m 15s
1m 48s
481.8%
5.1 GB
6.2 GB
9.4 GB
6.5 GB

16
e4/9c4a76
27814196.moab
ALIGN_STAR:BAM_SORT_SAMTOOLS:SAMTOOLS_INDEX (tumor_R1)
CACHED
0
2020-10-28 02:10:50.736
2m 10s
29s
98.0%
49.7 MB
86.3 MB
2.9 GB
3.8 MB

18
47/fd4a28
27814200.moab
MARK_DUPLICATES_PICARD:PICARD_MARKDUPLICATES (tumor_R1)
CACHED
0
2020-10-28 02:11:43.093
15m 18s
13m 27s
123.8%
25.6 GB
40 GB
5.8 GB
3 GB

20
d0/65f8df
27814205.moab
ALIGN_STAR:BAM_SORT_SAMTOOLS:BAM_STATS_SAMTOOLS:SAMTOOLS_STATS (tumor_R1)
CACHED
0
2020-10-28 02:13:00.945
4m 15s
2m 19s
98.8%
4.4 MB
29.1 MB
2.9 GB
259.8 KB

21
83/c5e2e3
27814204.moab
ALIGN_STAR:BAM_SORT_SAMTOOLS:BAM_STATS_SAMTOOLS:SAMTOOLS_FLAGSTAT (tumor_R1)
CACHED
0
2020-10-28 02:13:00.858
2m 10s
29s
97.8%
2.4 MB
26.6 MB
2.9 GB
817 B

19
ee/87f4d3
27814203.moab
ALIGN_STAR:BAM_SORT_SAMTOOLS:BAM_STATS_SAMTOOLS:SAMTOOLS_IDXSTATS (tumor_R1)
CACHED
0
2020-10-28 02:13:00.701
1m 35s
0ms
18.6%
1 MB
11 MB
3.9 MB
929 B

Any suggestion? Thanks!!

It is most likely because the process itself doesn't have enough time to run. SortMeRNA isn't the most efficient in terms of time requirements. The --max_* parameters you have set just cap the total resources you can use so you don't over request on your cluster . In order to increase the resources for that particular process you can include the below in  your custom config too and then re-run with -resume:
process {
  withName:SORTMERNA  {
    cpus = 12
    memory = '72 GB'
    time = '48h'
  }
}

By defaut, that process uses label process_high which is defined here so it makes sense that it is failing after 16 hours because that is the default. You can increase that as I explained above.

Thank you @drpatelh, your solution solved the problem (so I guess you can close this issue).
Apparently SortMeRNA requires a pretty insane amount of time (looks like it's an issue specifically related to version 4.2.0).

Yeah, I know...it's not great 😏 Be interested to know if there are ways to speed it up.

Here is the issue in the SortMeRNA repo referencing the 4.2.0 performance degradation: https://github.com/biocore/sortmerna/issues/231
One way to solve the slow runtime could be reverting an earlier version.


[WIP] Add image comparison testing with pytest

Fixes #8

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@3ce69be). Click here to learn what that means.
The diff coverage is 94.33%.

@@            Coverage Diff            @@
##             master       #9   +/-   ##
=========================================
  Coverage          ?   83.28%
=========================================
  Files             ?       12
  Lines             ?      317
  Branches          ?       39
=========================================
  Hits              ?      264
  Misses            ?       32
  Partials          ?       21

Impacted Files
Coverage Δ

animatplot/testing/__init__.py
100% <100%> (ø)

animatplot/testing/tools.py
94.23% <94.23%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3ce69be...11978d4. Read the comment docs.

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@3ce69be). Click here to learn what that means.
The diff coverage is 94.33%.

@@            Coverage Diff            @@
##             master       #9   +/-   ##
=========================================
  Coverage          ?   83.28%
=========================================
  Files             ?       12
  Lines             ?      317
  Branches          ?       39
=========================================
  Hits              ?      264
  Misses            ?       32
  Partials          ?       21

Impacted Files
Coverage Δ

animatplot/testing/__init__.py
100% <100%> (ø)

animatplot/testing/tools.py
94.23% <94.23%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3ce69be...d97ee1d. Read the comment docs.


combined inside and outside prediction

Hello. Is the script for training using outside and inside videos not available?

Hi hivabhagat,
to combine the features from inside and outside videos is actually straight-forward.
I first saved the features from two video streams beforehand to save some computation time, and then used several layers to process to get the final results.
I can try to find the script for this. It has been a while and I might need some time.
If you need help with the model itself, pls let me know.

If you could find the script that would be great. I am trying out an approach for my thesis and i want to use your proposed model as a baseline

could you provide codes for getting the accuracy and outside video or code to run the model on a demo video?
It would really help me out. I would really appreciate it.

could you provide codes for getting the accuracy and outside video or code to run the model on a demo video? It would really help me out. I would really appreciate it.

Hi there,
could you please check the script main_outside.py to run the code on outside video?
For the demo, I run the script to get the results for test samples at each timestamp, and then just add the predicted action to the corresponding video.
Hope it helps you.

I understand that we get the predicted frame from the convLSTM. Is there a way to calculate accuracy? You mention accuracy and F1 scores for outside video but I cannot seem to generate them using the function in utils. I am interested in reproducing the results of your models and it will really help me out if I can get all the codes. Could you email them to<EMAIL_ADDRESS>

Hello, is it correct that main_inside.py and main_outside.py output the features extracted from inside and outside respectively? Then they are input into a training model to output intention. My confusion is which script is the final training model that can output intentions?

Since I am working on a project taking the predicted driver's intention as input for other training aims, I wonder which model of yours can be used as input directly. Thanks a lot.

Hi, I see that the code for running the model using both inside and outside features is missing, please would it be possible to share the complete to<EMAIL_ADDRESS>. Also how to generate results like the ones you have in the demo folder from the one drive link?

@yaorong0921

@Hirva-Bhagat were u able to get the code for this work, if so please would you share them?

I have yet to receive a response from them.


chore(main): release 0.14.8

:robot: I have created a release beep boop
0.14.8 (2024-02-28)
Bug Fixes

SearchBar: search bar doesn't recognize the hashtag character (#321) (d543942)
TopBar: center the right side items (f654392)
TopBar: search bar cannot be centered in the top bar (becdcc4)
ts error (e3de0b0)
VideoCard: bug fixes (#316) (1790d3a)
VideoCard: bug fixes (#316) (#318) (562c766)
VideoCard: ensure clicking on bangumi name or avatar goes to the right page (7adb17c)
VideoCard: fix double page open on author's name click (#315) (e185098)
搜索框用中文输入法输入单词回车不应该直接触发搜索 #334 (18e6689)

Style Changes

TopBar: adjust style (5af83fa)

CI

changelog: update ci (f8f2776)
release: trigger workflow only on push to main branch (8d6d179)
release: update ci (edd243c)
release: update ci (28bd6a1)
release: update ci (e847901)

Miscellaneous

chore:  (a50e617)
chore:  (0700b27)
chore:  (88d879d)
update ci (cdf5889)
update version number (f9499be)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/hakadao/BewlyBewly/releases/tag/v0.14.8 :sunflower:


Syntax for non-greedy quantifiers

[1+:fewest #any]!

Should compile to:
(.)+?!

See e.g. https://www.oreilly.com/library/view/perl-cookbook/1565922433/ch06s16.html

Python is done, Rust needs implementation


Custom transformer - Can't add to resolver slots

How did you install the Amplify CLI?
No response
If applicable, what version of Node.js are you using?
No response
Amplify CLI Version
12.2.3
What operating system are you using?
Windows
Did you make any manual changes to the cloud resources managed by Amplify? Please describe the changes made.
No manual changes made
Describe the bug
This is the code in my custom transformer, but the contents of the request and response mapping templates don't make it either to disk or S3. (I have removed the contents of the mapping templates.)
    const models = context.output.getTypeDefinitionsOfKind('ObjectTypeDefinition');
    const createMutationResolvers: TransformerResolverProvider[] = [];
    for (const model of models) {
      const createMutationResolver = context.resolvers.getResolver('Mutation', 'create' + model.name.value) as TransformerResolverProvider;
      if (createMutationResolver) {
        createMutationResolvers.push(createMutationResolver);
      }
    }

    const requestMappingTemplate = MappingTemplate.inlineTemplateFromString();

    const responseMappingTemplate = MappingTemplate.inlineTemplateFromString();

    for (const resolver of createMutationResolvers) {
      resolver.addToSlot('init', requestMappingTemplate, responseMappingTemplate);
    }
  };

In addition, there may be an issue below as it always evaluated to false when I tried it so my code ended up as an S3 location. https://github.com/aws-amplify/amplify-category-api/blob/02b9cc0308d591f9caa21729ce5236c4611c31b3/packages/amplify-graphql-transformer-core/src/appsync-function.ts#L62
But even when I fixed that, my custom transformer template code was nowhere to be found.
Expected behavior
The mapping templates in my custom transformer should make it to either S3 or disk.
Reproduction steps
The code in the "Describe the bug" section should suffice.
Project Identifier
No response
Log output

# Put your logs below this line

Additional information
No response
Before submitting, please confirm:

[X] I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
[X] I have removed any sensitive information from my code snippets and submission.

As an aside, the docs on making your own transformer/directive could be way better and more helpful.

This issue is related to adding multitenancy support to our app so I would really appreciate some help.

Another related question is:
Let's say I have a "GuardMutationFunction" that I want to insert (or link or reference) into the resolver pipeline of every model in the postAuth.2 slot. How would I do that outside a transformer/directive and without adding a Mutation.(Delete|Update){MODEL}.postAuth.2.req.vtl resolver function for every model?

I know you have plenty on your plate, but following up.

Hi @redjonzaci, Apologies for the delay. I'll contact the engineering team to explore potential workarounds for you while we investigate reproducing the issue on our end.

@AnilMaktala it's okay and thanks!

Hey @AnilMaktala, any update from the team or any additional information we can provide?

We made it work by fitting https://www.npmjs.com/package/@aws-amplify/graphql-default-value-transformer to our need and updating the CLI to version 12.3.0. However, there are still some unclear things and the docs for adding a custom transformer need to be improved.
If we will have any other question, will post here or in another issue if this is closed by then.
Thank you!

Another question came up:
On mutation resolver pipelines, you do a query of the record in the auth slot (which I don't know why is it used),
but that record isn't saved for subsequent slots to use it.
I need to use it in a postAuth slot to check for attributes of a record.
Is there a way I can modify the auth slot without overriding the auth slots of every mutation
or without adding another slot that does querying (as we would do 2 queries for each mutation then)?

hey @redjonzaci - it looks like i am having similiar issues to you wrt creating custom transformers.
are you able to load your transformer into your project? if so, how do you do it?
i am getting stuck on #2077
also, your multi-tenent transformer looks interesting. is this something you will release publically?
thanks

Hey @craig-at-metashield-io, how are you?

You could put the code of the following package
https://www.npmjs.com/package/@aws-amplify/graphql-default-value-transformer
in a local package of your repo (assuming it's a monorepo)
and once you get it working, you can fit the code to your needs.

Or you could start an NPM package based on the defaultValue transformer
and try to install that in your project.

We still haven't got it working for proper multitenancy,
but if we see that it works for general use cases, we might release it.

thanks @redjonzaci  - i'm doing well and i hope you are too 😄
i'll give that a try, but i must say that i've had a devil of time getting amplify stuff to build correctly. there's a lot of package conflicts.

hey @redjonzaci - thanks again for your helpful advice.
i have managed to get around the loading issue and finally have a working directive that validates string/number fields.
keep well,

@sundersc I would appreciate if someone could answer the only question left: https://github.com/aws-amplify/amplify-category-api/issues/2019#issuecomment-1812505293.

Hi @sundersc,
Hi Amplify team, we've hit a bit of a snag with our current issue.
I'm wondering if anyone has any ideas on how we can better leverage the query that the @auth directive is already executing. We're currently checking some attributes in the postAuth slot, and there's also a need to compare the 'old' record with the 'new' one in the postUpdate slot.
The challenge is, it seems like we're having to unnecessarily use an extra query or a resolver slot to re-query the data. At the moment, there doesn't appear to be a straightforward way to get the @auth directive to either store the data in the stash or forward it down the chain via prev.results.
Any thoughts or suggestions on this would be greatly appreciated! With the slot quota being hardset and immovable we are trying to  be very conservative, also it feel really wasteful to waste the query.
Thanks,
Dhimitri.

Hi @djorgji, we do not store the fetched item in stash and this might be something we need to take up as a feature request. I see the value in it especially for such customizations. Marking this as a feature request. For now, you might have to override the request template in Auth resolver slot that fetches the item to additionally also put it in a stash variable that you own.

Hi @phani-srikar, any suggestion on what the easiest way to do that across all resolvers? We are at 40 tables at the moment, and that is quite a few resolvers to override manually?


ffcast: fix cross-compilation

Description of changes

Fix cross-compilation
Update download url
Fix wrapping
Fix license

Things done

Built on platform(s)

[x] x86_64-linux
[x] aarch64-linux (cross)
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
22.11 Release Notes (or backporting 22.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[x] Fits CONTRIBUTING.md.

Cleanup looks nice too.

@sikmir Feel free to take over the maintenance of xrectsel and ffcast if you’d like, as I am no longer using these.

Oops, I overlooked that .ffcast-wrapped has #!/bin/bash in it's script. You need to add bash to buildInputs to ensure the shebang is properly rewritten.

Oops, I overlooked that .ffcast-wrapped has #!/bin/bash in it's script. You need to add bash to buildInputs to ensure the shebang is properly rewritten.

But it's properly rewritten:
$ cat result/bin/.ffcast-wrapped | grep "bin/bash"
#!/nix/store/3j18grljsyy4nxc078g00sy4cx6cf16g-bash-5.1-p16/bin/bash

What is wrong with it?

That's not the aarch bash, is it?

I see, you're right. I will create another PR to fix it. Thanks.


Remove old SES code

Request
Investigate if the endpoints are still in use and if they aren't we can remove them. If they are we should pause and determine what work is needed to migrate away from using them.
Value Statement
As a VANotify developer
I want to have less redundant code in the codebase
So that the code is simpler to maintain
Checklist
Remove:

[ ] app.celery.process_ses_receipts_tasks.sns_callback_handler
[ ] app.celery.process_ses_receipts_tasks.sns_smtp_callback_handler
[ ] app.celery.process_ses_receipts_tasks.process_ses_smtp_results
[ ] and corresponding tests

Assumptions

Additional Info/Resources

Out of Scope

Open Questions

Unused methods. Update comments in code re: unused methods.

Okay to keep.


AngularFireAuth idToken emits a string instead of User

Hi there, thanks for a great library, I've been using it on a large-ish project for a year or so.
I recently upgraded Angular/AngularFire/Firebase in the project and struck an issue with the account creation flow that took me a little while to fathom. It all came down to the change of behaviour of authState in 4.0.0-rc0, due to the underlying change in Firebase's onAuthStateChanged. After finding your changelog entry stating "The added AngularFireAuth.idToken: Observable<firebase.User> behaves as authState used to." I tried using it, but found the signature did not match what I was expecting.
Also, I read your v4 upgrade guide but didn't see any mention of the backward compatible idToken observable.
I have downgraded to AngularFire 5.0.0-rc.0 as a temporary workaround, to get latest version before idToken was altered.
Version info

Angular: 5.2.2
Firebase: 4.9.1
AngularFire: 5.0.0-rc.6
Other (e.g. Ionic/Cordova, Node, browser, operating system):
Expected behavior
idToken would be a drop-in replacement for users upgrading from pre-4.0.0 angularfire2's authState, as described in the changelog
This makes sense as it follows the interface of the firebase library's onIdTokenChanged which returns a nullable firebase.User
Actual behavior
idToken emits the result of the user.getIdToken promise to subscribers. This behaviour appears to have changed in this commit: https://github.com/angular/angularfire2/commit/8ab38037df901030b378e4e7d881677e65169be5

See #1069

Can you help me understand your use case? Happy to reevaluate the change or put something else in there.

Hi James, thanks for getting back to me.
My use case is this:
On registration to our app we have a form which takes the user's firstname and lastname, as well as their email and password. We then chain some calls to firebase like this:
this.af.auth.createUserWithEmailAndPassword(email, password)
  .then((afUser: firebase.User) => {
    this.log.info('requesting firebase profile update for new user');
    return afUser.updateProfile({
      displayName: [firstName, lastName].join(' ').trim(),
    }).then(() => afUser.sendEmailVerification());
  })
  .then(() => this.af.auth.signInWithEmailAndPassword(email, password))
  .catch((err) => {
    this.handleFirebaseError(err);
  });

Under pre-4.0.0 angularFire2, the authState subscription would fire after the createUserWithEmailAndPassword and after signInWithEmailAndPassword, allowing us to get a fully updated user and token to send to our backend API.
After the update, authState no longer fires after signInWithEmailAndPassword, so we only ever see a user object emitted from the createUserWithEmailAndPassword which has no displayName attribute.
I had hoped to just change af.authState.subscribe to af.idToken.subscribe and everything would work as before. The idToken subscription does fire at the same times as the old authState did, just that it provides a string instead of a User.
It seems odd to me that the idToken interface does not match firebase's onIdTokenChanged when authState matches onAuthStateChanged.

Have to agree with @markstuart  that it should return the User instead a string.

Yea I have done some craziness to get this all to work with Universal. Not sayings its great or anything, but this service helped me work on universal with cookies
https://github.com/patrickmichalina/fusebox-angular-universal-starter/blob/master/src/client/app/shared/services/auth.service.ts

@jamesdaniels It seems to me that one of the aims of the AngularFire2 4.0 upgrade was to simplify the authentication api, and in doing so bring it more in line with the Firebase library.
To me, the meaning of onIdTokenChanged signifies that the users authentication token has changed in some way, not that it should return a token.
Firebase provide it as a backward compatible way of detecting changes in the auth state (including refresh events), and it was originally your intention to do the same. Given that the AngularFire2 auth api is not extensively documented, and Firebase's api docs are rather more extensive (completely understandable of course, on both counts) it makes sense for the auth methods to follow the Firebase ones so that there aren't too many surprises like this one.

FYI We're planning on adding .user which will expose the user from onIdTokenChanged

Thanks for the heads up @jamesdaniels, looking forward to replacing my hack of your original implementation of idToken (that did return the user) from our codebase once the user observable comes into play. Do you know what release that is likely to be in?

Addressing in #1642

Just cut rc.9, which includes the change

Quick question @jamesdaniels :
do I still have to set & watch a meta-data in db and then trigger user.getIdToken(true) from client-side as expressed in example here in docs to get updated token. Or token updates are now automatically propagated behind the scenes now?

Yes I am kind of confused to see that authState and user do the same? Is There any difference?


Implement configuration lifecycle management

Implement configuration lifecycle management.
Create, List, Read, Update, Delete, etc for configurations.
Note

Initial solution can be a github repo based approach

@ananya-jain1 and @htvenkatesh , Please look into this ticket

Approach being finalised for cQube roadmap.

Invalid


Add LDAP as a service

Add LDAP as a service so that it can be used for authentication of other services.
Look at https://hub.docker.com/r/osixia/openldap as a candiate.

duplicate to #377


Ensure support for gpt-4-1106-preview OpenAI model

When setting the OpenAI model to gpt-4-1106-preview, the response doesn't seem to be received as expected.
2024/01/22 16:33:45 Sending the crafted response to [::1]:58577
2024/01/22 16:34:02 Received a request for "/users.csv" from [::1]:58652
2024/01/22 16:34:02 Request cache miss for "/users.csv": Not found in cache
2024/01/22 16:34:08 Generated HTTP response: ```json
{
  "Headers": {
    "Content-Type": "text/csv",
    "Content-Disposition": "attachment; filename=\"users.csv\"",
    "Server": "Apache/2.4.41 (Ubuntu)"
  },
  "Body": "id,username,email\r\n1,johndoe,johndoe<EMAIL_ADDRESS>}```
2024/01/22 16:34:08 Error unmarshalling the json-encoded data: invalid character '`' looking for beginning of value

Using OpenAI's response format and the cleanResponse function in the recent merge request fixed this issue.


Incompatible with "ComfyUI jank HiDiffusion"

ComfyUI jank HiDiffusion allows generating 4096x4096 images without deformation.

Finally someone feed 4K to CN fr


Synthesis failed for nodejs-bigquery-storage

Hello! Autosynth couldn't regenerate nodejs-bigquery-storage. :broken_heart:
Here's the output from running synth.py:
2020-05-14 06:37:10,870 autosynth [INFO] > logs will be written to: /tmpfs/src/github/synthtool/logs/googleapis/nodejs-bigquery-storage
2020-05-14 06:37:10,873 synthtool [ERROR] > Failed executing git clone --single-branch https://github.com/googleapis/nodejs-bigquery-storage.git /home/kbuilder/.cache/synthtool/nodejs-bigquery-storage:

fatal: could not create work tree dir '/home/kbuilder/.cache/synthtool/nodejs-bigquery-storage': No space left on device

Traceback (most recent call last):
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 600, in <module>
    main()
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 472, in main
    return _inner_main(temp_dir)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 519, in _inner_main
    working_repo_path = synthtool_git.clone(f"https://github.com/{args.repository}.git")
  File "/tmpfs/src/github/synthtool/synthtool/sources/git.py", line 83, in clone
    shell.run(cmd, check=True)
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 39, in run
    raise exc
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 33, in run
    encoding="utf-8",
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/subprocess.py", line 438, in run
    output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['git', 'clone', '--single-branch', 'https://github.com/googleapis/nodejs-bigquery-storage.git', PosixPath('/home/kbuilder/.cache/synthtool/nodejs-bigquery-storage')]' returned non-zero exit status 128.

Google internal developers can see the full log here.

Autosynth is still having trouble generating nodejs-bigquery-storage. :sob:
Here's the output from running synth.py:
2020-05-14 16:12:53,216 autosynth [INFO] > logs will be written to: /tmpfs/src/github/synthtool/logs/googleapis/nodejs-bigquery-storage
2020-05-14 16:12:53,219 synthtool [ERROR] > Failed executing git clone --single-branch https://github.com/googleapis/nodejs-bigquery-storage.git /home/kbuilder/.cache/synthtool/nodejs-bigquery-storage:

fatal: could not create work tree dir '/home/kbuilder/.cache/synthtool/nodejs-bigquery-storage': No space left on device

Traceback (most recent call last):
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 600, in <module>
    main()
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 472, in main
    return _inner_main(temp_dir)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 519, in _inner_main
    working_repo_path = synthtool_git.clone(f"https://github.com/{args.repository}.git")
  File "/tmpfs/src/github/synthtool/synthtool/sources/git.py", line 83, in clone
    shell.run(cmd, check=True)
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 39, in run
    raise exc
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 33, in run
    encoding="utf-8",
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/subprocess.py", line 438, in run
    output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['git', 'clone', '--single-branch', 'https://github.com/googleapis/nodejs-bigquery-storage.git', PosixPath('/home/kbuilder/.cache/synthtool/nodejs-bigquery-storage')]' returned non-zero exit status 128.

Google internal developers can see the full log here.

Autosynth is still having trouble generating nodejs-bigquery-storage. :sob:
Here's the output from running synth.py:
2020-05-14 19:39:20,882 autosynth [INFO] > logs will be written to: /tmpfs/src/github/synthtool/logs/googleapis/nodejs-bigquery-storage
2020-05-14 19:39:20,886 synthtool [ERROR] > Failed executing git clone --single-branch https://github.com/googleapis/nodejs-bigquery-storage.git /home/kbuilder/.cache/synthtool/nodejs-bigquery-storage:

fatal: could not create work tree dir '/home/kbuilder/.cache/synthtool/nodejs-bigquery-storage': No space left on device

Traceback (most recent call last):
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 601, in <module>
    main()
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 473, in main
    return _inner_main(temp_dir)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 520, in _inner_main
    working_repo_path = synthtool_git.clone(f"https://github.com/{args.repository}.git")
  File "/tmpfs/src/github/synthtool/synthtool/sources/git.py", line 83, in clone
    shell.run(cmd, check=True)
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 39, in run
    raise exc
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 33, in run
    encoding="utf-8",
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/subprocess.py", line 438, in run
    output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['git', 'clone', '--single-branch', 'https://github.com/googleapis/nodejs-bigquery-storage.git', PosixPath('/home/kbuilder/.cache/synthtool/nodejs-bigquery-storage')]' returned non-zero exit status 128.

Google internal developers can see the full log here.

Autosynth is still having trouble generating nodejs-bigquery-storage. :sob:
Here's the output from running synth.py:
2020-05-15 05:48:45,999 autosynth [INFO] > logs will be written to: /tmpfs/src/github/synthtool/logs/googleapis/nodejs-bigquery-storage
2020-05-15 05:48:46,003 synthtool [ERROR] > Failed executing git clone --single-branch https://github.com/googleapis/nodejs-bigquery-storage.git /home/kbuilder/.cache/synthtool/nodejs-bigquery-storage:

fatal: could not create work tree dir '/home/kbuilder/.cache/synthtool/nodejs-bigquery-storage': No space left on device

Traceback (most recent call last):
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 601, in <module>
    main()
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 473, in main
    return _inner_main(temp_dir)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 520, in _inner_main
    working_repo_path = synthtool_git.clone(f"https://github.com/{args.repository}.git")
  File "/tmpfs/src/github/synthtool/synthtool/sources/git.py", line 83, in clone
    shell.run(cmd, check=True)
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 39, in run
    raise exc
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 33, in run
    encoding="utf-8",
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/subprocess.py", line 438, in run
    output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['git', 'clone', '--single-branch', 'https://github.com/googleapis/nodejs-bigquery-storage.git', PosixPath('/home/kbuilder/.cache/synthtool/nodejs-bigquery-storage')]' returned non-zero exit status 128.

Google internal developers can see the full log here.

Autosynth passed, closing! :green_heart:


Fix - JIT second level defence

Codecov Report
Attention: Patch coverage is 93.33333% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 89.41%. Comparing base (179a0f9) to head (351e7f7).

Files
Patch %
Lines

src/jit.rs
93.33%
1 Missing :warning:

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #554      +/-   ##
==========================================
+ Coverage   88.34%   89.41%   +1.07%
==========================================
  Files          24       23       -1
  Lines       10282     9943     -339
==========================================
- Hits         9084     8891     -193
+ Misses       1198     1052     -146

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


Titles are percentage signs instead of title name

Describe your bug here.
Like the issue name says and it happens when I replace the whole image folder and I don’t know what image it’s changing
Command Prompt/Terminal logs (if existing)
No response
Are you modding a build from source or with Lua?
Lua
What is your build target?
Mac
Did you edit anything in this build? If so, mention or summarize your changes.


[WIP] get addresses for job iteration object

GetIPAddress renders a string with IP addresses for the object template from the list of input addresses based on iteration number and number of addresses requested per object

Looks good to me. Requires signed commit I guess.


When we add a new listener how we can check or know the new user is came?? so please tell me the way because these two type of notifications are not available in react native if these are available then we can identify using these notifications

please read it carefully for react native read it carefully then go for closed and support

This ticket seems to be very similar to https://github.com/DolbyIO/comms-sdk-react-native/issues/87. As mentioned in it the work for this kind of functionality was already scheduled in https://github.com/DolbyIO/comms-sdk-react-native/issues/75 and https://github.com/DolbyIO/comms-sdk-react-native/issues/82. Both are now deployed in version 3.8.0 Beta 1 and hence I am closing this. (Please see: https://docs.dolby.io/communications-apis/docs/rn-client-sdk-references-notificationservice)
Should I have misunderstood your request, or find that the events from the notification service are not working correctly please raise a new ticket.


Should we implement EventEmitter?

Current implementation of event streams using "flutter streams channel" plugin which will create an instance of Event Channel on platform side.
This discussion sheds some light on different approaches that can be followed to implement the same along with caveats of each approach.

Looks like this was already done using Streams channel. Should this be closed @QuintinWillison 🤔

The referenced discussion was had very early on in the development of this plugin. We've been released (out of preview) for nearly six months now, and we've not seen any evidence that EventEmitter is required or makes idiomatic sense for Dart / Flutter.


Cross compilation?

I am trying to cross-compile a haskell project that uses a .hsc file that uses bindings-DSL, but I get error messages like
src/….hsc:22 directive strict_import cannot be handled in cross-compilation mode

or
src/….hsc:26 directive starttype cannot be handled in cross-compilation mode

https://github.com/haskell/hsc2hs#cross-compilation writes

Only a subset of .hsc syntax is supported by --cross-compile. The following are unsupported: … Custom constructs

Does that mean that using binding-DSL will prevent any kind of cross compilation?

In my concrete case the FFI was small enough to just drop down on “raw” hsc, not using bindings-DSL, so this is not urgent. I guess this issue can serve as a place for people to find more information related to cross compilation and bindings-DSL.


NIFI-11748 Upgrade Apache Commons Codec from 1.15 to 1.16.0

Summary
NIFI-11748 Upgrades Apache Commons Codec from 1.15 to 1.16.0.
Tracking
Please complete the following tracking steps prior to pull request creation.
Issue Tracking

[X] Apache NiFi Jira issue created

Pull Request Tracking

[X] Pull Request title starts with Apache NiFi Jira issue number, such as NIFI-00000
[X] Pull Request commit message starts with Apache NiFi Jira issue number, as such NIFI-00000

Pull Request Formatting

[X] Pull Request based on current revision of the main branch
[X] Pull Request refers to a feature branch with one commit containing changes

Verification
Please indicate the verification steps performed prior to pull request creation.
Build

[X] Build completed using mvn clean install -P contrib-check

[X] JDK 17

Licensing

[ ] New dependencies are compatible with the Apache License 2.0 according to the License Policy
[ ] New dependencies are documented in applicable LICENSE and NOTICE files

Documentation

[ ] Documentation formatting appears as expected in rendered files

+1 LGTM, thanks for the upgrade! Merging to support/nifi-1.x and main


Is it possible to combine global parameters with a verb?

It seems like a common use case, but so far I could not find any reference to it in the documentation, open/closed issues or Q&As online: say I want to use the verbs scenario (e.g. 'get' and 'post') but also need to configure 'cross-cutting concerns' like logging (-log='file-path') that is relevant for all verbs:
MyCLI post -content="Hello" -log="trace.log"
Do I need to replicate those global parameters in all verbs, use inheritance or is there a "mode" that supports a combination of e.g. a global Options and verb-specific GetOptions and PostOptions classes?

Hi @ivanko2000, the best way would be to use inheritance. The following works fine, for example:
void Main()
{
	var result = Parser.Default.ParseArguments<Add, Remove>("remove -l file.txt".Split());
	result.MapResult<Add, Remove, object>(
		(Add o) => o.Dump(),
		(Remove o) => o.Dump(),
		errs => errs.Dump());
}

public abstract class CommonOptions
{
	[Option('l', "log")]
	public string LogFile { get; set; }
}

[Verb("add")]
public class Add : CommonOptions
{
}

[Verb("remove")]
public class Remove : CommonOptions
{
}

Thank you! This is exactly what I was looking for.
P.S. Might want to add a one liner on the documentation page to point to this approach


WebRTC appears to grab more and more CPU over time

As described, I'm using WebRTC as the live preview using substream from Reolink cameras, and the CPU usage appears to start low, and slowly consume more and more over time. Attached is a snapshot of my processes, about 6 hours from last reboot.
My lovelace card code is also attached, anythign else you would need?
Hass OS on NUC i3-6100U 16GB Ram

Duplicate #64


Need help with Scipy

I could use help with the following parts of the Scipy notebook:

[x] statistics section (temporarily removed; I am terrible with statistics)
[x] exercises

I will work on them as well, but help would be much appreciated!

Thanks @TarekHC and @ftorradeflot for the help!


Replace links to live transactions with links to our explorer

@aulneau  pointed out: Hey Mary! I'm reading up on the docs and I saw here -> https://docs.blockstack.org/core/naming/creationhowto.html that we're liking to live transactions, it would probs make sense to replace them with links to our explorer
moxiegirl [8:59 AM]
Yes. Let me make an issue so I don't forget

Our explorer doesn't explore namespaces which is the topic of this referenced page. That said, I've updated to page to address the key point which is linking to the actual transactions.

Closed by: https://github.com/blockstack/docs.blockstack/commit/b91d0ed93a4e67de86debaea14fcb3457d866a3d


fix(deps): update dependencies and drop ember-cli-eslint

ember-source can't be updated to v3.10.0 for now because something breaks it without any error message..
Closes #120
Closes #132
Closes #152
Closes #127
Closes #133
Closes #121
Closes #103
Closes #151
Closes #150
Closes #125
Closes #96
Closes #129
Closes #147
Closes #128
Closes #143
Closes #149

Shall we accept the failing test on the release branch for the moment?

Well, the release branch is version 3.10.0 and I'm looking into why this is failing

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

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


Fixed SlideChange State getting empty data at the beginning

Describe the bug
When the component is on mount, the state data is empty, and a change is required to have the carousel status data.
Expected behavior
Get the onSlideChange data at the beginning
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
check https://workspace.acrool.com
workspace > task > image list > onClick open prevew
https://github.com/user-attachments/assets/1878de7b-cc79-4234-bd0a-de8be6310aa0

release to v5.1.1


ModuleNotFoundError: No module named 'sonnet'

/tensor2robot_bcz/tensor2robot/layers/bcz_networks.py", line 24, in
import sonnet as snt
ModuleNotFoundError: No module named 'sonnet'
Hello, how can I solve this problem?
Thanks!

/tensor2robot_bcz/tensor2robot/layers/bcz_networks.py", line 24, in
import sonnet as snt

ModuleNotFoundError: No module named 'sonnet'
Hello, how can I solve this problem?
Thanks!

Try
pip install sonnet

/tensor2robot_bcz/tensor2robot/layers/bcz_networks.py", line 24, in
import sonnet as snt

ModuleNotFoundError: No module named 'sonnet'
Hello, how can I solve this problem?
Thanks!

Try pip install sonnet

Thank you! I have solve it.


Understanding dvajs put

I couldn't post on Stackoverflow as tag is missing.
I have just recently found out that this can be done. However, I don't really understand what happened in the background. I try reading dva-core sourecode but still can not really figure out
This is taken from dva example.
  reducers: {
    save(state, { payload: { data: list, total, page } }) {
      return { ...state, list, total, page };
    },
  },
  effects: {
    *fetch({ payload: { page = 1 } }, { call, put }) {
      const { data, headers } = yield call(usersService.fetch, { page });
      yield put({
        type: 'save',
        payload: {
          data,
          total: parseInt(headers['x-total-count'], 10),
          page: parseInt(page, 10),
        },
      });
    },
    *remove({ payload: id }, { call, put }) {
      yield call(usersService.remove, id);
      yield put({ type: 'reload' });
    },
    *reload(action, { put, select }) {
      const page = yield select(state => state.users.page);
      yield put({ type: 'fetch', payload: { page } });
    },
  },

There are two ways put is being used here

yield put({ type: 'reload' }); is used to run another effect
yield put({ type: 'save',..}); is used to run reducer.

I was reading redux-saga document and can not really find documentation regarding using put to run another effect. Is this something specific for dvajs?

put dispatches the action which you defined as type
It's more like
dispatch({type: 'reload'})

doing in the background. However, execution won't stop when you call yield put(...) unlike yield call(...) so be aware of that.
If you dispatch an action and there are both effect (e.g. *reload) and reducer (e.g. reload) with the same name, both of them will be executed.

@cihadturhan thanks! I am starting to understand redux saga more now. However are you sure about the last statement?
If you dispatch an action and there are both effect (e.g. *reload) and reducer (e.g. reload) with the same name, both of them will be executed.
I tried this and only effect seemed to be executed. I haven't yet figure out why having the same name prevent reducer from running.

@RatchapongT you are right. I forgot that how it works.
Here what it says:

Reducer and effect with the same name will not fallthrough (both executed), but only execute effect

Source: https://github.com/dvajs/dva/releases/tag/dva%402.0.0

@cihadturhan wow thank you so much for finding the actual statement. Do you possibly know where in the source code of dva that is controlling this behavior?

Nope :) Actually it doesn’t matter as far as your job is done :)
Cihad Turhan
R.T <notifications<EMAIL_ADDRESS>şunları yazdı (2 Ara 2017 04:28):
@cihadturhanhttps://github.com/cihadturhan wow thank you so much for finding the actual statement. Do you possibly know where in the source code of dva that is controlling this behavior?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/dvajs/dva/issues/1363#issuecomment-348656699, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ADkPkKQnQKXFgwB3B5FPWM_K3LWKbJOZks5s8KfCgaJpZM4Qs3h3.


Version 0.8.8 Highlighting changes

Added files

Added Shell, _Hide, Hide

Added the missing "E" to PRESERV now it's PRESERVE

Added cwd

Added option base


tasks+omnibus: use a versioned SDS shared library.

What does this PR do?
Use a pinned version of the SDS shared library.

/merge


feat: Manage flavours of nopol

Implement two different strategies for running Nopol.
Fix #638

Pull Request Test Coverage Report for Build 1888

129 of 164 (78.66%)  changed or added relevant lines in 3 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.2%) to 54.531%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

repairnator/repairnator-pipeline/src/main/java/fr/inria/spirals/repairnator/process/step/repair/nopol/NopolSingleRepair.java
10
12
83.33%

repairnator/repairnator-pipeline/src/main/java/fr/inria/spirals/repairnator/process/step/repair/nopol/NopolMultiWithTestExclusionRepair.java
23
25
92.0%

repairnator/repairnator-pipeline/src/main/java/fr/inria/spirals/repairnator/process/step/repair/nopol/AbstractNopolRepair.java
96
127
75.59%

Totals

Change from base Build 1885:
0.2%

Covered Lines:
2834

Relevant Lines:
5197

💛  - Coveralls


Log Request header for Broker

Background
Add request header to broker logs
See #8869 for more details.
Release Note
This PR introduces passing a new parameter ** remoteIps** to broker logs, so we can track the source info of queries being sent to the broker

Can we make this optional (configurable on the broker config)? You can keep the default ON. In our company, requests come via an endpoint that already logs all the previous calltree information, so this additional log only makes our log files bigger.

Please provide an example of what you see as the log entry, and then we can debate on the delimiter, format, etc.
Also, I want to make sure (like I indicated in the issue) that this is a MUST have feature before we start adding more stuff to the logs. I agree it is nice to have, but in large volume query systems, it can harm more than being useful

Codecov Report

Merging #8907 (92d29d6) into master (f3bde9f) will decrease coverage by 54.76%.
The diff coverage is 0.00%.

@@              Coverage Diff              @@
##             master    #8907       +/-   ##
=============================================
- Coverage     69.60%   14.84%   -54.77%
+ Complexity     4997      170     -4827
=============================================
  Files          1806     1766       -40
  Lines         94202    92466     -1736
  Branches      14050    13887      -163
=============================================
- Hits          65571    13725    -51846
- Misses        24072    77753    +53681
+ Partials       4559      988     -3571

Flag
Coverage Δ

integration1
?

integration2
?

unittests1
?

unittests2
14.84% <0.00%> (-0.59%)
:arrow_down:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

...roker/requesthandler/BaseBrokerRequestHandler.java
32.76% <0.00%> (-40.50%)
:arrow_down:

...src/main/java/org/apache/pinot/sql/FilterKind.java
0.00% <0.00%> (-100.00%)
:arrow_down:

...ain/java/org/apache/pinot/core/data/table/Key.java
0.00% <0.00%> (-100.00%)
:arrow_down:

...in/java/org/apache/pinot/spi/utils/StringUtil.java
0.00% <0.00%> (-100.00%)
:arrow_down:

.../java/org/apache/pinot/spi/utils/BooleanUtils.java
0.00% <0.00%> (-100.00%)
:arrow_down:

.../java/org/apache/pinot/core/data/table/Record.java
0.00% <0.00%> (-100.00%)
:arrow_down:

.../java/org/apache/pinot/core/util/GroupByUtils.java
0.00% <0.00%> (-100.00%)
:arrow_down:

...java/org/apache/pinot/spi/trace/BaseRecording.java
0.00% <0.00%> (-100.00%)
:arrow_down:

...java/org/apache/pinot/spi/trace/NoOpRecording.java
0.00% <0.00%> (-100.00%)
:arrow_down:

...ava/org/apache/pinot/spi/config/table/FSTType.java
0.00% <0.00%> (-100.00%)
:arrow_down:

... and 1395 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f3bde9f...92d29d6. Read the comment docs.

Multiple IP Request :
curl --location --request POST 'http://localhost:8000/query/sql' \ --header 'X-Forwarded-For: <IP_ADDRESS>,<IP_ADDRESS>,120.192.338.678' \ --header 'Content-Type: text/plain' \ --data-raw '{"sql":"select yearID, count(*) from baseballStats group by yearID limit 20"}'
Response :

Single IP Request :
curl --location --request POST 'http://localhost:8000/query/sql' \ --header 'X-Forwarded-For: <IP_ADDRESS>' \ --header 'Content-Type: text/plain' \ --data-raw '{"sql":"select yearID, count(*) from baseballStats group by yearID limit 20"}'
Response :

@vvivekiyer : Please review and provide comments. thanks !

LGTM. @siddharthteotia  can you please review, kick-off tests and merge this PR?

@abhs50  No action needed from you. Siddharth with review when he finds time and we can take it from there.


Address asserts raised when conforming pseudogeneric type to protocol.

Implemented Remangler::mangleDependentPseudogenericSignature (with the same one-line implementation as OldRemangler's implementation) to fix the assertion that the coroutine continuation prototype's mangling could be roundtripped.
And loosened an assertion in SILFunctionType::get so that instances for pseudogeneric coroutines without signatures to be created.  Such instances are created by SILTypeSubstituter::substSILFunctionType when SILGen'ing a conformance of a pseudogeneric type to a protocol featuring a coroutine requirement.
rdar://81421394

@swift-ci please test

@swift-ci please test


Upgrade to POMDPTools

Reference directions here: https://sites.google.com/view/pomdps-hackathon/pomdptools-upgrade-instructions

In progress: https://github.com/JuliaPOMDP/POMDPGifs.jl/pull/24


update

@KhalipskiSiarhei how did you make that graph showing the sizes?

@hakonamatata it is in the PR and it is used webpack-bundle-analyzer.
Here is a fragment from webpack.config.js file to generate main-server.js + lazy loaded bundles report:

You need to add the similar changes in webpack.config.vendor.js file to generate vendor.js bundle report (specify another report and stats,json file only). And to not forget to add/uncomment const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin; in the top of the *.config.js file(s).


instanceOf assertion does not work properly with java.util.Iterator

I was testing the concrete class of an java.util.Iterator by
java.util.Iterator<Integer> javaIterator = asJavaUtilIterator(list.iterator());
assertThat(javaIterator).isInstanceOf(ReducibleJavaIterator.class);

But that test fails with:
java.lang.AssertionError:
Expecting:
 <[1, 2, 3, 4, 5, 6]>
to be an instance of:
 <com.github.blahord.betterrcollections.compatibility.ReducibleJavaIterator>
but was instance of:
 <org.assertj.core.api.IterableAssert.LazyIteratorToIterableWrapper>

even javaIterator is an instance of the class ReducibleJavaIterator as the Debugger tells me.
Screenshot:
http://s11.postimg.org/3ms9kz8rn/Screenshot_20160130_125326.png

Can by workarounden with:
assertThat(javaIterator.getClass()).isEqualTo(ReducibleJavaIterator.class);

Example test:
public void testIteratorInstanceOf() throws Exception {

    class MyIterator implements java.util.Iterator<Integer> {
        @Override
        public boolean hasNext() {
            return false;
        }

        @Override
        public Integer next() {
            throw new java.util.NoSuchElementException();
        }
    }

    assertThat(new MyIterator()).isInstanceOf(MyIterator.class);
}

The thing is that we wrap the given iterator in a lazy one (LazyIteratorToIterableWrapper) to avoid consuming it when the assertions does not need to do so, so what you pass to actual(Iterator) is transformed thus the error.
Your workaround is the right way to test the class.
We should mention the sneaky behavior of actual(Iterator) in the javadoc as the beahviour you experienced is "by design".
Sorry for the lack of documentation

The workaround has a problem: I can only check for the exact class, not for any superclass.
For Lists and Sets i can do 'assertThat(list).isInstanceOf(MyList.class)' So i feels unnatural, if i can't do that for Iterators. Is there a technical reason, why on Iterators it behaves different?

As (badly ?) explained before, the technical reason is a design choice to avoid consuming the given iterator when not needed.

you can use this assertion in the meantime:
assertThat(javaIterator instanceof ReducibleJavaIterator.class).isTrue();

Fixed along with all related instanceOf assertions


Preload state trie node

Signed-off-by: Karim TAAM<EMAIL_ADDRESS>Co-authored-by: Ameziane H<EMAIL_ADDRESS>PR description
The idea behind this PR is to preload asynchronously account nodes and storage nodes from the database during the transaction processing to use these nodes during the calculate root hash step.
We've created two caches, one for account nodes and one for storage nodes. The size of these caches is 100k for accounts and 200k for storage. We've tested other values but this configuration is the one that works better.
We also exporter cache metrics as Prometheus metrics to check cache efficiency.
We didn't see any impact on GC activity even on 4 GiB Heaps (-Xmx4g).
The results
We did our tests on different AWS EC instances, here're the results.
M6a.xlarge (4 vCPU, 16 GiB)
Block processing time is 34% better for median values and 41% better for 95th percentile.

M5.xlarge (4 vCPU, 16 GiB)
Block processing time is 28% better for median values and 95th percentile.

I3.2xlarge (8 vCPU, 61 GiB)
Block processing time is 21% better for median values and 95th percentile.

Cache Efficiency
We can see in the screenshots below that these two caches are very efficient (>99%) and increasing storage cache size more than 200k is not necessary.
Account cache size = 100k and Storage cache size = 200k

Account cache size = 100k and Storage cache size = 1 million

Fixed Issue(s)

Documentation

[ ] I thought about documentation and added the doc-change-required label to this PR if
updates are required.

Changelog

[ ] I thought about the changelog and included a changelog update if required.

I merge and I will fix in a next PR. Thank you for your reviews