mock function does not work with nodejs optional chaining (?.) (new syntax from nodejs 14)

Before opening, please confirm:
I have installed the latest version of the Amplify CLI (see above), and confirmed that the issue still persists.
I have searched for duplicate or closed issues.
I have read the guide for submitting bug reports.
I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
How did you install the Amplify CLI?
curl -sL https://aws-amplify.github.io/amplify-cli/install | bash && $SHELL
If applicable, what version of Node.js are you using?
v14.15.5
Amplify CLI Version
4.47.1
What operating system are you using?
Mac (intel)
Amplify Categories
function
Amplify Commands
Not applicable
Describe the bug
in mock function(testing locally), if my code contains "optional chaining (?.)" which is a new syntax from nodejs version14, it raises a following error.
{
  stack: "Error: Could not load lambda handler function due to SyntaxError: Unexpected token '.'\n" +
    '    at loadHandler (/snapshot/node_modules/amplify-nodejs-function-runtime-provider/lib/utils/execute.js:106:15)\n' +
    '    at processTicksAndRejections (internal/process/task_queues.js:97:5)',
  message: "Could not load lambda handler function due to SyntaxError: Unexpected token '.'"
}

Expected behavior
It should simply work without any errors.
Reproduction steps

amplify function add   # nodejs
add "optional chaining (?.)" in index.js like :

exports.handler = async (event) => {
    console.log(event?.data?.text);   // this should log "undefined"

amplify mock function $functionName

GraphQL schema(s)

# Put schemas below this line

Log output

# Put your logs below this line

Additional information
The same code can work after "amplify push", and execute it from Lambda's web console.
PS. I confirmed that "$FUNCTIONNAME-cloudformation-template.json" file contains "Resources.LambdaFunction.Runtime = nodejs14.x"

I cannot reproduce this locally on Node 14, but can on earlier versions. I believe mock is just using whatever version of Node you're running locally. You can verify by logging process.version in your function.

@cjihrig
Thanks a lot for your advice.
As you mentioned, my process.version returns v12.18.1 .
This should be the reason...
My simply node -v returns v14.15.5.    May I know how to switch Node version for my amplify mock function ?

I did

"amplify uninstall"
curl -sL https://aws-amplify.github.io/amplify-cli/install | bash && $SHELL

But my process.version still returns the old one v12.18.1 .  (node -v returns v14.15.5 though.)

It sounds like a possible$PATH issue on your machine. I would try looking at process.execPath and process.env.PATH and see how they compare between your system Node and the Node executable being used in mock.

The strange thing is that I don't have v12.18.1 on my local machine.
I am using nodebrew locally.  my machine should have only v12.20.1 and v14.15.5 ...
> nodebrew ls
v12.20.1
v14.15.5
current: v14.15.5

process.execPath returns /Users/myname/.amplify/bin/amplify
process.env.PATH returns undefined
I checked Users/myname/.amplify/bin/amplify. It is Mach-O 64-bit executable x86_64 and the size is 395MB. I guess this binary file contains not only amplify-cli but also node v.12.18.1 ???

Oh, you installed the packaged version of the CLI. That is bundled with a version of Node - in this case v12.18.1. AFAIK, there isn't a way to change the bundled Node version. As a workaround, if you install the CLI from npm (npm install -g @aws-amplify/cli), you should be able to use your local version of Node.

I did this following workaround.

amplify uninstall  # remove amplify-cli installed by curl... .
npm install -g @aws-amplify/cli

Now, my amplify mock function can work as I expected.
I'm happy with this solution for now.

Glad you're unblocked. I'll close this issue out.

@cjihrig
Thanks a lot for your comment.
Somehow I reached the same solution you suggested.
I hope the packaged version will have v14 instead of v12 someday.
Anyway, Thank you very much.


Complete documentation

Please complete the documentation for this cmdlet

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 0662c036-4a3c-7e89-caaa-b2265d7a7199
Version Independent ID: 1f117040-2424-bfc6-14ef-0ac033330107
Content: Remove-SPOGeoAdministrator (sharepoint-online)
Content Source: sharepoint/sharepoint-ps/sharepoint-online/Remove-SPOGeoAdministrator.md
Service: sharepoint-powershell
GitHub Login: @techwriter40
Microsoft Alias: kirks

@DeanGross Thank you for this feedback
I am getting this over to the PowerShell team for completion.
I was able to get this into the backlog for the PowerShell team. The team will get this prioritized into a sprint plan. Thank you for reporting and making the docs better. Much appreciated.
I made a note to request the team to update this when the work is complete.

Hi @DeanGross  Sorry for the delayed answer.
I'm hitting base with your basically to know what part do you think it requires more work?
I mean specifics parts like examples, description, etc. We'll be glad to help with those.

@j0rt3g4  Thank you very much for the contribution and updating the documentation with PR. @DeanGross Hope this update is helpful for you. Thanks for taking out some time to open the issue. Appreciate and encourage you to do the same in future also.


refactor CLI to be top level package

What does this PR do?
Moving the CLI to be top level package, as it is the mostly changed API point, so we can converge on App stability...
discussed with @lantiga

Before submitting

Was this discussed/agreed via a GitHub issue? (not for typos and docs)
[x] Did you read the contributor guideline, Pull Request section?
[x] Did you make sure your PR does only one thing, instead of bundling different changes together?
Did you make sure to update the documentation with your changes? (if necessary)
Did you write any new necessary tests? (not for typos and docs)
[x] Did you verify new and existing tests pass locally with your changes?
Did you list all the breaking changes introduced by this pull request?
Did you update the CHANGELOG? (not for typos, docs, test updates, or minor internal changes/refactors)

PR review
Anyone in the community is welcome to review the PR.
Before you start reviewing, make sure you have read the review guidelines. In short, see the following bullet-list:

Reviewer checklist

[x] Is this pull request ready for review? (if not, please submit in draft mode)
[x] Check that all items from Before submitting are resolved
[x] Make sure the title is self-explanatory and the description concisely explains the PR
[x] Add labels and milestones (and optionally projects) to the PR so it can be classified

Probably we are hitting App instability as some tests are failing and shall not... similar to we run all tests just in random order...

Closing since app is being evicted from the monorepo


Working code samples

Hi,
First of all good job on the work you've done so far with jsreport. I spent the weekend evaluating it in a fair bit of detail. This tool shows some real promise. The ability to dispense with large cumbersome and bloated frameworks and other tooling for creating static visualisations and reports could finally be over.
I logged a couple of issues/questions which I think are mainly due to the lack of some complete end to end code samples and documentation. This maybe specifically due to my use case where I really need to use jsreport-core as oppose to the full server.
Although I've pretty much got things working now, I could do with more complete code samples and descriptions as to whats happening. Especially with regards to capturing and handling errors. Also I needed to wrap my process.exit() within a timeout otherwise nothing gets written to files. Not sure if this is correct or just lack of my understanding.
Anything you have that provides more information as to whats happening would be very much appreciated.

Moving this to the jsreport repo issues.


Reorganize graphs in tabs in unique HTML file

Currently two html files are output, however it would be preferable to only output one and use tabs to separate different groups of graphs (eg: Memory, CPU, GC, IO, Traces) so that it will be easier to share files and easier to understand.
Nice to have:

build pipeline that embed dependencies js (currently we rely on external cdns. If they break, files are unusable)
modular app (eg: single app webpage)

The build process and usage needs to be kept very simple for babar to remain "plug-and-play".

Done with babar-report module


v4.2.3 completely breaks our app!

Changes like this usually interpreted as breaking change. Are you sure about 4.2.3 ? It is rather v5 with these changes to api.
By the way, seems like there is no (easy) way to bring our app to work with these changes, because we use [(dateTimePicker)]= and [(ngModel)]= together. Could you please show how to do it now ?

@Sky4CE
we don't use [(dateTimePicker)]= and [(ngModel)]= together
we use dateTimePicker and [(ngModel)]
You could read more from README.md or from the Demo page

@DanielYKPan , yes I see, but prior 4.2.3 I could use it together, so our logic depend on this.

New version break out project too,

I think I would revert back to old version, hope that you can have a look at these new version issues.
Thank you.

In your case, you may try this
<div>
    <input class="picker-input"
           [value]="data | amDataFormat: dateTimeFormat"
           dateTimePicker
           [ngModel]="data"
           [mode]="'dropdown'"
           [returnObject]="'moment'"
           [pickerType]="pickerType"
           [hourTime]="hourTime"
           [(disabled)]="disabled"
           (onChange)="onChange($event)"
           readonly>
</div>

@DanielYKPan , it works this way, thank you very much.


Upsampling provides no benefit

In enable-hifiberry.sh you upsample the audio to 192000. Not only is this a waste of CPU cycles it actually degrades fidelity for audio that's sample rate is not an integer divisor of 192000 namely 44100 audio that accounts for the vast majority of audio that is played because by default ALSA resamples with a trivial algorithm (basically straight multiplication division with a lot of rounding errors because of the remainders). Changing the bit depth to S32_LE is a good idea because it gives more headroom for digital volume control though but resampling is no good. If you don't resample ALSA will just play whatever at it's native sampling rate. There's really no need to specify a global sampling rate. You can just use softvol in ALSA by itself for software volume without dmix.

I've read somewhere that the upsampling algorithm of ALSA is quite okay, and may even be (much) better than anything that is done in the hardware: I'm not sure what the "native" sampling rate of e.g. HiFiBerry's DAC+ series is, but I think they can play at any multiple of 44100 or 48000...

Modern delta sigma DACs are going to oversample even 192000. That's just the max input sampling rate due to the Linux drivers for some HiFiBerry DACs. Delta sigma DACs work by upsampling the crap out of the PCM audio by as much as 64 times or more and then they convert it to Pulse Width Modulation and then they use filters to get rid of the ultrasonic noise. To defeat the upsampler in the PCM5122 chip used in the DAC+ Pro for example you'd have to oversample to 384000. It's impossible to defeat the resampling in the PCM1796 chip used in the DAC 2 HD. Even at 192000 it upsamples 32 times. The data sheets for both DAC chips are easy to find.
As far as the quality of upsampling algorithm(s) of ALSA. There are several you can choose from. The default if libasound2-plugins is not installed is linear, which creates all kinds of rounding errors when not resampling to values that are not divisible by each other. So going from 44.1 to any thing not 88.2, 176.4 and so on is going to degrade the sound quality. Even with a "good" algorithm upsampling in and of itself NEVER improves sound quality. You can't make something from nothing.
The only possible benefit of upsampling would to make up for the fact that the clock on the Pi's is not capable of producing a clean 44.1 signal. And that only affects DACs that don't provide their own master clock and even then the benefit is suspect at best.
 You can't get to the "native" sampling rates of any HiFiBerry Dacs. Upsampling NEVER makes anything sound better by itself.

As an experiment I invite you to install libasound2-plugins and add this to /etc/asound.conf to change the upsampling algorithm to something decent and then play some 44.1 audio upsampled to 192000 and see what happens:
defaults.pcm.rate_converter "speexrate_best"
Spoiler:
It will murder your CPU and you'll more than likely experience dropouts and have unusable audio.

If it were me /etc/asound.conf would look like this, (in fact mine look very similar):
# defaults.pcm.card 0 # Redundant, 0 is already the default.
# defaults.ctl.card 0 # Redundant, 0 is already the default.

pcm.hifiberry {
    type hw
    card 0
    device 0
}

pcm.dmixer {
    type dmix
    ipc_key 1024
    ipc_perm 0666
    slowptr true # read the docs
    hw_ptr_alignment roundup # read the docs
    slave.pcm hifiberry # Don't need quotes for strings that don't contain special chars.
    slave {
        period_time 250000 # 0.25 secs.
        buffer_time 1000000 # 1.0 secs. Low latency is really only a concern when recording. Big buffer equals less chance of dropouts and/or clicks and pops.
        rate 44100
        format S16_LE
    }
    bindings {
        0 0
        1 1
    }
}

ctl.dmixer {
    type hw
    card 0
}

pcm.softvol {
    type softvol
    slave.pcm dmixer
    control {
      name Softvol
      card 0
    }
    min_dB -90.2 # not sure why this isn't -96.3? If you're going to go to -90.2 why not go for 16 bit full scale?
    max_dB 0.0
}

pcm.!default {
    type plug
    slave.pcm softvol
}

Here if you want to be able to configure pretty much everything this Gist will let you do it by changing just a couple lines.
The part that a user would touch looks like this:
defaults.pcm.card 1 # Change to the card you want to be default.
defaults.ctl.card 1 # Change to the card you want to be default.

ctl.!default {
    type plug
    # slave.pcm "HQstereoHardWareVol20:CARD=0,DEV=0,SUBDEV=-1,RATE=44100,FORMAT=S16_LE,RATE_CONVERTER=samplerate_linear,PERIODS=4,PERIOD_TIME=125000"
    # slave.pcm "HQstereoSoftWareVol20:CARD=0,DEV=0,SUBDEV=-1,RATE=44100,FORMAT=S16_LE,RATE_CONVERTER=samplerate_linear,PERIODS=4,PERIOD_TIME=125000"
    slave.pcm "HQstereoHardWareVol20:CARD=1"
}

ctl.!default {
    type hw
    card 1 # Change to the card you want to be default.
    device 0 # Change to the device you want to be default.
    subdevice -1 # Change to the subdevice you want to be default.
}

CARD, DEV, SUBDEV, RATE, FORMAT, RATE_CONVERTER, PERIODS, and PERIOD_TIME are all configurable in one line and you can choose between hardware and software volume control. If any arg is omitted the default value will be used. The Gist is set up for my personal setup with a USB DAC with hardware volume control.

Maybe you are right, I just copied the settings that HiFiBerry use for their HiFiBerry OS: https://github.com/hifiberry/hifiberry-os/tree/master/buildroot/package/hifiberry-tools/conf
I guess people who use an external sound card (I2S or USB) will most probably touch their asound.conf according to their preferences anyway, so I'd like to leave sane simple defaults here.
As I do not have the resources to maintain a knowledge base for ALSA configuration in this repository, I'll close this for now, maybe I can link to your asound.conf in the docs?

The main reason "audiophiles" love to upsample is the same reason they love crazy hi res audio. Because of ignorance. More must equal better (in their minds at least). Upsampled DSD remasters of digital recordings that were originally stored as PCM or DSD64 is a great example. You can't make something from nothing, you can't retrieve detail that's not there. Digital audio is science and math. Objective quality is absolutely quantifiable. Does the output match the input and is the difference (distortion) audible?
Here is a link to the alsa plugin docs. They read like stereo instructions (in a bad way) and they're out of date. You can't really use them to write an asound.conf because if you follow them to the letter it won't work.
https://www.alsa-project.org/alsa-doc/alsa-lib/pcm_plugins.html
The asound.conf docs are even worse.
https://alsa.opensrc.org/Asoundrc
It took me a few days of trial and error and Googling to figure out what little I know.


Suggesting content improvements

As of today, there are common aliases used by those that work with Kubernetes clusters often. These could include the following commonly used ones -
alias kgp='kubectl get pod -owide'
alias kgs='kubectl get service -owide'
alias kgd='kubectl get deploy -owide'
alias kd='kubectl describe'
alias kg='kubectl get -owide'
alias ka='kubectl apply -f'
alias kx='kubectl exec -it'
alias ke='kubectl edit'
alias ns='kubectl config set-context --current --namespace '
export dry='--dry-run=client -oyaml'
export y='-oyaml'
export w='-owide'
export j='-ojson'
export force='--force --grace-period=0'

It would be of value add if there was a common space on the kubernetes docs, where these aliases could be placed and copied over.

Hi @shyamg28, thanks for the suggestion for alias the available Kubernetes commands but, as I can relate, it is most of personal choice that if you want to alias your command or not.

I was more or less expecting this 😄  The cheatsheet also has certain more personal suggestions around autocomplete and using k as an alias. We could expand it to have these as suggestions isn't it?

Instead of adding to the documentation, you can post a blog on it.

I believe there are various blogs with such aliases in place, more or less similar 😄

I love this idea. The reason why I am in for this idea is because this is the only documentation we can access for CKA and CKAD exam.  We can present this documentation as one flavour of aliases. Also lets put a disclaimer that the users can modify this as per convenience.

Hi @shyamg28 , great idea.
you can add them at https://kubernetes.io/docs/reference/kubectl/cheatsheet/#kubectl-context-and-configuration under title: commonly used alias

/sig docs

Hi @shyamg28 , great idea. you can add them at https://kubernetes.io/docs/reference/kubectl/cheatsheet/#kubectl-context-and-configuration under title: commonly used alias

Created a PR here - https://github.com/kubernetes/website/pull/40261

/retitle Suggest convenient kubectl shell aliases

Is there anyone still willing to work on it?

/sig docs
/kind feature
/language en


Changing parameters for docker-entrypoint-initdb.d sql inits.

It seems that there are no way to change parameters, that require postgres instance to restart, for your init scripts.
I ran into trouble when i needed to increase max_locks_per_transaction before creating tables.
Mounting conf file onto default path stops container from starting as it's data directory is not empty.
Using ALTER TABLE SET does not work as postgers instance is started once for all init scripts.
And there is no way of sending parameters to instance that executes inits using "-c".

https://github.com/docker-library/docs/tree/master/postgres#database-configuration
You want to mount that to /etc/postgresql/postgresql.conf

While it is technically a bug that we do not pass any of the container arguments like -c name=value (roughly "$@" in the entrypoint), it would be fairly complex to do so since it would require parsing all of the flags via bash to possibly filter out conflicting flags and then bundling them up into a -o option for the temporary server started by pg_ctl.
You can work around it by restarting the temporary server in an initdb.d script:
$ ls -ln docker-entrypoint-initdb.d/
-rw-rw-r-- 1 1000 1000 143 Aug 13 15:56 new-options.sh
$ cat docker-entrypoint-initdb.d/new-options.sh
#!/bin/bash

echo 'SHOW max_locks_per_transaction;' | "${psql[@]}"

# or even sed or otherwise update `/var/lib/postgresql/data/postgresql.conf` instead of adding options here
pg_ctl -D "$PGDATA" \
	-o "-c max_locks_per_transaction=256" \
	-o "-c listen_addresses=''" \
	-w restart

echo 'SHOW max_locks_per_transaction;' | "${psql[@]}"

$ docker run -it --rm \
 -v /path/to/test/postgres/docker-entrypoint-initdb.d/:/docker-entrypoint-initdb.d/ \
 --name posty \
 postgres:10
.... (cut for brevity)

/usr/local/bin/docker-entrypoint.sh: sourcing /docker-entrypoint-initdb.d/new-options.sh
 max_locks_per_transaction
---------------------------
 64
(1 row)

2018-08-13 23:08:00.867 UTC [44] LOG:  received fast shutdown request
waiting for server to shut down....2018-08-13 23:08:00.868 UTC [44] LOG:  aborting any active transactions
2018-08-13 23:08:00.869 UTC [44] LOG:  worker process: logical replication launcher (PID 51) exited with exit code 1
2018-08-13 23:08:00.869 UTC [46] LOG:  shutting down
2018-08-13 23:08:00.879 UTC [44] LOG:  database system is shut down
 done
server stopped
waiting for server to start....2018-08-13 23:08:01.017 UTC [74] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2018-08-13 23:08:01.037 UTC [75] LOG:  database system was shut down at 2018-08-13 23:08:00 UTC
2018-08-13 23:08:01.042 UTC [74] LOG:  database system is ready to accept connections
 done
server started
 max_locks_per_transaction
---------------------------
 256
(1 row)

...

Or you can provide your config file on top of the sample file (any changes would require a new empty datadir, since it is only used as a template during initdb):
$ cat pg.conf
max_locks_per_transaction=256
$ ls -ln docker-entrypoint-initdb.d/
-rw-rw-r-- 1 1000 1000  32 Aug 13 16:25 test.sql
$ cat docker-entrypoint-initdb.d/test.sql
SHOW max_locks_per_transaction;
$ docker run -it --rm \
 -v /path/to/test/postgres/pg.conf:/usr/share/postgresql/postgresql.conf.sample \
 -v /path/to/test/postgres/docker-entrypoint-initdb.d/:/docker-entrypoint-initdb.d/ \
 --name posty \
 postgres:10

/usr/local/bin/docker-entrypoint.sh: running /docker-entrypoint-initdb.d/test.sql
 max_locks_per_transaction
---------------------------
 256
(1 row)


Update README.markdown

One more example with multiple rocommunity.

Thanks for your submission.  Could you please resubmit against the develop branch?  The file DEVELOP.md has all of the details.

@razorsedge Updated PR

Merged in commit 32dcb674bef9cc2be529088cee08ce5bcb00bb81.


Run Now not running when job is already scheduled

Describe the bug
"Run Now" has no effect for jobs that are already scheduled (or cron'ed with the new cron)
One option would be to replace in admin.py, line 113: enqueue_at( ...
with enqueue(... (remove the first parameter)
Thanks!!

@cunla question: how would you like this issue to be addressed. As of now, the "run now" action has no effect on enabled cronjobs/repeated jobs.
One way to go about is to remove that scheduled entry and schedule now.
Let me know if I can be of help here. The PR might be small, but I don't want to go in a direction you don't like to begin with.
Thanks!

I haven't thought about it.
If it is urgent for you, you can extend the given admin interface - I want to address other issues before.

@cunla I will work on this because end-users are used to do "Run Now" and expect it to run now. So the fix will just go and find the job in the scheduled registry and if there's a scheduled job with same callable, will remove it and then enqueue_at(now()...) (to account for any change). it might not be perfect for every case, but keeping it like it's now it's misleading (the more so because the previous behavior was different).
Let me know, looking forward to it!

Do you know how to trigger a dialog box form in django-admin?
I would want to have a list of the selected jobs to "Run now" and tell the user the jobs will be unscheduled for their next run
This is true for ScheduledJob and RepeatableJob but not for CronJob.


🐛 [firebase_dynamic_links] dynamic links works fine on simulator but not on real iOS device.

Bug report
Hi. I have an app where the user can look for restaurants and their details. Now, I have integrated shareable links and deep linking to open a specific restaurant's details in the app from that dynamic link. This works perfectly fine on Android devices and iOS simulator, but not on real iOS device. I followed all the steps to configure the dynamic links properly. Can anyone help me with what I am missing?
Run flutter doctor and paste the output below:
Click To Expand
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 1.22.0, on Microsoft Windows [Version 10.0.19043.1165], locale en-IN)

[√] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
[!] Android Studio (not installed)
[√] Connected device (1 available)

Below is my code for reference:
Click To Expand
void initDynamicLinks() async {
    FirebaseDynamicLinks.instance.onLink(
        onSuccess: (PendingDynamicLinkData dynamicLink) async {
      final Uri deepLink = dynamicLink?.link;

      if (deepLink != null) {

        print("THIS IS THE DATA" + deepLink.toString());
      } else {

      }
    }, onError: (OnLinkErrorException e) async {
      print('onLinkError');
      print(e.message);
    });

    final PendingDynamicLinkData data =
        await FirebaseDynamicLinks.instance.getInitialLink();
    final Uri deepLink = data?.link;

    if (deepLink != null) {
      print(deepLink);
      print(deepLink.toString().substring(53));
      Future.delayed(const Duration(milliseconds: 4000), () {
        getRestaurantDetails(deepLink.toString().substring(53));
        setState(() {});
      });
    } else {
      getLoginStatus();
    }
  }

Hi @ayaanpathan
Can you please provide your flutter pub deps -- --style=compact? What exact device and iOS version does this occur on and how are you opening the link on the device?
Thank you


request: convert and keep only specific language

Hi
would be possibile to convert to ac3 only specific language tracks ?
ideally should be possibile to discard all other audio tracks
thanks
BHH

Discarding or compressing them to MP3/AAC or something with a small filesize


Update dockerfiles for node 16 and a12

adjust the productive dockerfiles to work with angular12 and use node16

@gsiv this should fix #6160
browserslist was replaced with .browserslistrc.
I suppose node16 will not be a problem for us, the productive client builds in 143127ms (roughly two minutes). This takes so long due to still existing CommonJS deps


Adding new reference to SCA on PHP

Please review this PR. Added new SCA on PHP reference

commit was not signed Closing this PR. Will raise a new PR


Field(nullable=True) is ignored due to recent changes released in version 0.0.7

First Check

[X] I added a very descriptive title to this issue.
[X] I used the GitHub search to find a similar issue and didn't find it.
[X] I searched the SQLModel documentation, with the integrated search.
[X] I already searched in Google "How to X in SQLModel" and didn't find any information.
[X] I already read and followed all the tutorial in the docs and didn't find an answer.
[X] I already checked if it is not related to SQLModel but to Pydantic.
[X] I already checked if it is not related to SQLModel but to SQLAlchemy.

Commit to Help

[X] I commit to help with one of those options 👆

Example Code
from typing import Optional

from sqlmodel import Field, Session, SQLModel, create_engine

class Hero(SQLModel, table=True):
  id: Optional[int] = Field(default=None, primary_key=True)
  # This should not be nullable
  name: Optional[str] = Field(default=None, nullable=False)

hero = Hero()
engine = create_engine("sqlite:///database.db")

SQLModel.metadata.create_all(engine)
with Session(engine) as session:
  session.add(hero)
  session.commit()
  session.refresh(hero)
  print(hero)

Description

Create a hero model with a non-nullable column by assigning it to Field(nullable=True)
Create a hero instance without setting the column
Save the instance to the DB. Should get an error but the hero instance saves successfully.

I believe this issue was introduced here: https://github.com/tiangolo/sqlmodel/commit/9830ee0d8991ffc068ffb72ccead2427c84e58ee#r82434170
Operating System
macOS
Operating System Details
No response
SQLModel Version
0.0.7
Python Version
Python 3.10.5
Additional Context
No response

Yeah, there's something iffy here, but I can't reproduce your example.
In the test, it is asserted that name VARCHAR NOT NULL.
This test still pass when changing into this:
from typing import Optional

from sqlmodel import Field, SQLModel, create_engine

class Hero(SQLModel, table=True):
    id: Optional[int] = Field(default=None, primary_key=True)
-   name: str
+   name: Optional[str] = Field(default=None, nullable=False)
    secret_name: str
    age: Optional[int] = None

sqlite_file_name = "database.db"
sqlite_url = f"sqlite:///{sqlite_file_name}"

engine = create_engine(sqlite_url, echo=True)

SQLModel.metadata.create_all(engine)

Which is good.
However, it also passes when changing name in to nullable=True. So nullable properties have some weird behavior.
from typing import Optional

from sqlmodel import Field, SQLModel, create_engine

class Hero(SQLModel, table=True):
    id: Optional[int] = Field(default=None, primary_key=True)
-   name: str
+   name: Optional[str] = Field(default=None, nullable=True)
    secret_name: str
    age: Optional[int] = None

sqlite_file_name = "database.db"
sqlite_url = f"sqlite:///{sqlite_file_name}"

engine = create_engine(sqlite_url, echo=True)

SQLModel.metadata.create_all(engine)

I've submitted a new test that tests nullable fields, and it seems correct to me. See PR #423.

I believe I have confirmed and addressed the issue in https://github.com/tiangolo/sqlmodel/pull/424.

Aha, I understand now. Seems like a weird pattern to set a default value, but not allow it..
As a side note, please either branch out from the PR / ask for branch permissions to add more commits / add the original author as a co-author when you copy/paste code from another PR 😊

You might type is as optional so that you can create the object without setting all the fields.
Happy to do either. If you give me branch permissions, I can make my change to your existing branch.

Aha, I understand now. Seems like a weird pattern to set a default value, but not allow it.. To me it seems like you just shouldn't type it as optional.
As a side note, please either branch out from the PR / ask for branch permissions to add more commits / add the original author as a co-author when you copy/paste code from another PR 😊

Added you as a co-author:
https://github.com/tiangolo/sqlmodel/pull/424/commits/00cebd28c39a818f884194680531f78fac9158a3

Gave you access to mine, but up to you. I assume you have to rebase those commits into one commit to get it merged anyway 😄

Since you added me as a co-author on the wrong commit, I honestly think you should just finish your PR, copy over the changes you'd like into my PR, and then close yours. Then git history will be correct, and git commit history could be two commits with the correct authors.

I assumed he would squash the commits. But I will commit to your PR.

Thanks for the report @JonasKs! And thanks for the help to you both.
https://github.com/tiangolo/sqlmodel/pull/423 is now merged. I tweaked it a bit with extra cases and fixes. It will be available in the next version released in the next hours. SQLModel 0.0.8 :rocket:


max open connection in database updated from 1000 to 100

TL;DR

Decrease the number of max open connection to 100, 1000 is very high number for default

Type

[x] Bug Fix
[ ] Feature
[ ] Plugin

Are all requirements met?

[ ] Code completed
[ ] Smoke tested
[ ] Unit tests added
[ ] Code documentation added
[ ] Any pending items have an associated Issue

Complete description
How did you fix the bug, make the feature etc. Link to any design docs etc
Tracking Issue
Remove the 'fixes' keyword if there will be multiple PRs to fix the linked issue
fixes https://github.com/flyteorg/flyte/issues/2171
Follow-up issue
NA
OR
https://github.com/flyteorg/flyte/issues/

Shall we fix https://docs.flyte.org/en/latest/deployment/cluster_config/flyteadmin_config.html#maxidleconnections-int as well? Thanks.

So the sql execution is slow.

We could try to give cloudsql-proxy more CPU. Maybe double the current allocation.

Sorry I accidentally commented on wrong PR. I have removed my other comments.

@honnix are you seeing any side-effects with the current idle connections set to 10? hopefully 10 is low enough to not consume excessive resources

No I meant the doc still says 1000 as default max open connections.

ah @honnix I think we need to upgrade flytestdlib in flyteadmin with this fix (https://github.com/flyteorg/flytestdlib/releases/tag/v1.0.3)

Right I see. It's not a problem for us since we have custom configuration anyway. Thanks for fixing it.


image link fixes

There was an error while validating job 3fbc2d57-5d2d-4b1a-954d-c339f5af15bb Message:Error clonning repositoryDetails:System.ArgumentException: Error clonning repository ---> System.Exception: Error when trying to initialize shared repository ---> LibGit2Sharp.NotFoundException: Branch 518 not found. Available branches:
at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.GetBranch(Repository repo, String name)
at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.<>c__DisplayClass3e.b__3d()
at Microsoft.Practices.EnterpriseLibrary.TransientFaultHandling.RetryPolicy.<>c__DisplayClass1.b__0()
at Microsoft.Practices.EnterpriseLibrary.TransientFaultHandling.RetryPolicy.ExecuteAction[TResult](Func1 func)    at Microsoft.Practices.EnterpriseLibrary.TransientFaultHandling.RetryPolicy.ExecuteAction(Action action)    at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.InitializeSharedRepository(String url, IDictionary2 branches, String sharedRepoPath)
at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.VerifySharedRepository(String url, IDictionary2 branches, String tempPath)    --- End of inner exception stack trace ---    at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.VerifySharedRepository(String url, IDictionary2 branches, String tempPath)
at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.CloneRepository(String url, IDictionary2 branches)    --- End of inner exception stack trace ---    at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.CloneRepository(String url, IDictionary2 branches)
at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.CloneRepository()
at Microsoft.DPS.Services.LibGit2SharpSourceControlProvider.GetTreeAsync(String path, Boolean includeSubDirectories, String excludePath, IList1 extensionWhiteList)    at Microsoft.DPS.Commands.IdentifyDocumentsToPublish.ListSourceControlFilesCommand.Do(IDictionary2 context)
at Microsoft.LightweightJobEngine.Core.Language.JobWorkflow1.RunCommands(Guid jobId, IDictionary2 context, CancellationTokenSource cancelSignal)


Notification related feature request

Please also add a tray icon whenever the app is closed so that one doesn't have to start it again.

[ ] An option in the settings to choose what to do when the user closes the app(minimize to tray or quit)
[ ] Bring the app's window into focus whenever a download is added(can be toggled from the settings)
[ ] Notifications via the tray icon whenever the download is complete

@gmastergreatee Thanks for your advice.

Since this app is developed using Electron, some system specific features can not be accomplished. I can not keep app alive when you close the app on Windows.
I will see if I can detect and bring the app's window into focus when a download is added from outside
Completion notification is on my to-do list

Well, I think, for creating the tray icon, the details in the below link should suffice.
http://electron.rocks/proper-tray-icon/
As for the case while closing the app window, one could detect the event(as shown in one of the comment-replies of above link), prevent it, add a menu-item in the tray icon(to show the window when clicked) & then just hide the window.

@gmastergreatee You are right. I will implement this when I get my windows computer.


Demographics - Remove Contributor Payment Measurement

All credit for this PR goes to @emmairwin, a perceptive individual!
Original Post from #381:

Hi,
I agree that paid v unpaid contributor is an error here. I think orginally this was meant to nudge those projects being run by companies to expand their goals and reach to those who do not work for the company. But paid/v paid is not the right way to say that.
Do you mind instead of adding the NOTE: to just remove the paid v unpaid? And then open an issue to discuss what it could be replaced with?
Fully support addition of equity.

We are also discussing the possibility of making this into a new metric in #383
Signed-off-by: Matt Cantu Snell<EMAIL_ADDRESS>

Ahh looks like a merge conflict came up after #381 was merged. @Nebrethar, are you able to fix the merge conflicts? Then we can merge this one in, no problem. 👍🏻

Actually I was able to rebase this one in the command line. It's all ready to merge. Bringing it in! 🌊


Missing some text functions

First of all: Thanks for this great piece of software. After getting frustrated with the mcf2pdf Java software (due to changes in the latest Cewe .mcf files, using version 7+) and getting the cewe2pdf Python script not running (on a Win10 machine) I got your software to work. The production of pdf files is very fast!
Unfortunately, I am missing some functions which would be great to incorporate into next versions. Here some examples:

some text decorations like rotating a textbox are not handled
background of textbox is not handled
the alignment of text seems to be always "left". I would need "justify".
corner decorations of images are seemingly not supported:
example:
<corners enabled="yes">                   <corner length="15" shape="convex" where="top-right"/>                   <corner length="15" shape="convex" where="bottom-left"/>                   <corner length="15" shape="convex" where="top-left"/>                   <corner length="15" shape="convex" where="bottom-right"/>               </corners>
I guess it is resulting in the following log entry: "[Warning] No style for span: ' '."
an option for "one-page" or "double-page" pdf would be great.

Regards and happy coding.

Hi, thanks for the detailed feedback!
I just implemented the easy ones for the upcoming version 0.3.0:

textbox (and image) rotation now works
textbox background colors work
justify alignment works, but may produce slightly different results from the Cewe software. This will probably never match perfectly.

These changes are available in Cewe2pdf-v0.3.0-alpha3 here.
Just had a quick look at decorations, getting them to work in all corner combinations including borders and shadow will take some time. Will probably work on that after 0.3.0.
I agree that an option for single page pdfs would be really nice to have. But that requires some deeper changes, not likely to happen soon.
Let me know if you find more problems :)

Hi, thanks for the detailed feedback!
I just implemented the easy ones for the upcoming version 0.3.0:

textbox (and image) rotation now works
textbox background colors work
justify alignment works, but may produce slightly different results from the Cewe software. This will probably never match perfectly.

These changes are available in Cewe2pdf-v0.3.0-alpha3 here.
Just had a quick look at decorations, getting them to work in all corner combinations including borders and shadow will take some time. Will probably work on that after 0.3.0.
I agree that an option for single page pdfs would be really nice to have. But that requires some deeper changes, not likely to happen soon.
Let me know if you find more problems :)

Dear Stefan,
Thanks for the quick response and the great improvements.
I confirm you that the following functions work successful for my recent fotobook:

textbox rotation
textbox color background
justify alignment of text (was actually nearly perfect in my case)
Regards
Bernard

Dear Stefan,
Thanks for the quick response and the great improvements.
I confirm you that the following functions work successful for my recent fotobook:

textbox rotation
textbox color background
justify alignment of text (was actually nearly perfect in my case)
Regards
Bernard

Vertical text on cover-spine seems not to be handled,
Converting 4 pages.
Starting conversion. This may take several minutes.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled area type in <page/area> 'spinelogoarea'.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[0,0%]  processing Page 1/4...
[Info]    Added 429 Design IDs to resource cache.
[Info]    Loading DesignID from path: C:\Program Files\d*\d*-Fotowelt//Resources//photofun/backgrounds/einfarbige/229.webp
[Info]    Rendering Image: xxxxxxxxxxxxxxxxxxx
[Info]    Rendering Image: xxxxxxxxxxxxxxxxxxx
[Info]    Rendering Text: font=Calibri; size=20; align=ALIGNVCENTER; valign=ALIGNLEADING
[Warning] Unhandled text align: 'ALIGNVCENTER'.
[Warning] Unhandled text vertical align: 'ALIGNLEADING'.
        remaining: ~1 minutes.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.

For the spine-size there were some problems with big books (many pages) in the other converters, just for info:
https://github.com/albrechtf/mcf2pdf/issues/15#
https://github.com/albrechtf/mcf2pdf/pull/37

Which version are you using? The current alpha release should already handle spine text and vertical alignment fine.
I think spine size should always be handled correctly.
The roadmap is actually somewhat outdated... the readme still needs some reworking for the final 0.3.0 release :)

yes I used 0.3.0 alpha 6
I just tested it again using the standard spinetext field and on top adding a usual textarea also moved to spine area side-by-side.
The usual textarea is rendered correctly ON the spine-area (so that is a workaround for PDF generation), but the dedicated spinetext does not apear and throws the errors:
[Warning] Unhandled text align: 'ALIGNVCENTER'.
[Warning] Unhandled text vertical align: 'ALIGNJUSTIFY'.
No matter what font, size, color, alignment
Cewe2pdf v0.3.0-alpha6 [Release]
[Info]    Set 'ToPage' to '2'.
[Info]    Loading config from 'config.txt'...
[Info]    Set 'ProgramPath' to 'C:\Program Files\d*\d*-Fotowelt'.
[Info]    Loading config defaults...
[Info]    Set 'ImgScale' to '1'.
[Info]    Using Config:
                ToPage=2
                ProgramPath=C:\Program Files\d*\d*-Fotowelt
                ImgScale=1
Loaded 'FOTOBUCH.mcf'.
[Info]    mcf content:
<fotobook>
        art_id=9733
        productname=ALB41
        <project>
                createdWithHPSVersion=7.1.2
        <articleConfig>
                normalpages=114
                totalpages=119
[Warning] Unhandled Node in <fotobook> 'project'.
[Warning] Unhandled Node in <fotobook> 'savingVersion'.
[Warning] Unhandled Node in <fotobook> 'creationHistory'.
[Warning] Unhandled Node in <fotobook> 'articleConfig'.
[Warning] Unhandled Node in <fotobook> 'addOns'.
[Warning] Unhandled Node in <fotobook> 'extra'.
[Warning] Unhandled Node in <fotobook> 'userfeedback'.
[Warning] Unhandled Node in <fotobook> 'fotoRelationships'.
[Info]    Loading fonts from C:\Windows\Fonts
[Info]    Loading fonts from C:\Program Files\d*\d*-Fotowelt\Resources\photofun\fonts
[Info]    Searching for fonts directory at C:\ProgramData\hps
[Info]    Loading fonts from: 'C:\ProgramData\hps\1320\photofun\fonts'.
[Info]    Loading fonts from: 'C:\ProgramData\hps\1320\addons\fontspackage\fonts'.
[Info]    Found 2750 fonts.
Converting 2 pages.
Starting conversion. This may take several minutes.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[0,0%]  processing Page 1/2...
[Info]    Added 429 Design IDs to resource cache.
[Info]    Loading DesignID from path: C:\Program Files\d*\d*-Fotowelt//Resources//photofun/backgrounds/einfarbige/229.webp
[Info]    Rendering Image: original size=4928x3264; scaled size=1036x686
[Info]    Rendering Image: original size=3888x2592; scaled size=1089x726
[Info]    Rendering Text: font=Calibri; size=36; align=ALIGNVCENTER; valign=ALIGNJUSTIFY
[Warning] Unhandled text align: 'ALIGNVCENTER'.
[Warning] Unhandled text vertical align: 'ALIGNJUSTIFY'.
[Info]    Rendering Text: font=Calibri; size=36; align=ALIGNJUSTIFY; valign=ALIGNVTOP
        remaining: ~1 minutes.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.
[Warning] Unhandled Node in <page> 'background'.

So perhaps some positioning trouble with my special landscape book article (bundlesize?) and huge pagenumber (and therefore spinesize?).


Fix/flake8 consistent checks

What kind of change does this PR introduce?

Bug fix
What is the current behavior?

Right now the prec-commit check confirms that functions pass the flake8 and flake8-docstring linter checks, while the github action CI checks confirm that flake8, flake8-black, and flake8-isort run. This means there is an inconsistentcy between the linter checks run locally and the ones run remotely.
What is the new behavior?
Now the flake8 extensions are consistent between the pre-commit and remote CI runners.
Does this PR introduce a breaking change?

No breaking change :tada:
Other information
Sorry for making this mistake :cry:

@DaleSeo I originally figured it out just by comparing the pre commit config file to the setup.py file to see if there were a mismatch.
To test, in my forked version of the repo I branched off of my fix branch and confirmed a few of the different checks both locally with pre-commit and remotely with github actions. I made sure pre-commit would complain when expected, then I would commit with the --no-verify option to force the commit to the remote server. There I would confirm that the remote check failed. If you want to check, in my forked repo you'll see a failed version of the check at https://github.com/steve148/python-graphql-client/runs/498862259?check_suite_focus=true.
isort is a utility library for ordering python imports in a file. According to PEP-8 the import order should be standard library, third party libraries, and then local files / modules. If you're using VSCode it provides a command called something like Organize your imports which uses isort to automatically sort the imports using isort.


docs: Update apify_platform.mdx

I had problem where to set my own env variables so I added useful link into the documentation.

i am not completely opposed by adding the link there, but it feels like you missed the fact that you don't need any tooling to set env var. also you updated only one version snapshot, your change would be forgotten on next feature release.

I know that I can set env vars on the apify platform, what branch should i put it into to be included in next release?


VRM 1.0 models not colliding at feet

When I export models using VRM0 spec, the models correctly land on their feet in game spaces (such as onhyper.io) when I import them online. When I use VRM1 spec, the models fall through the floor to approximately their midpoints (can only see torso and above). Not sure how to correct.

OS: Windows 11
Blender 3.6.1
Addon Version latest avaiable 8/8/2023

I think there is currently a fault in hyperfy.io's VRM 1.0 support, the official VRM 1.0 model from the VRM Consortium is not showing up correctly either.
Please contact hyperfy.io.

Expected screenshot:

hyperfy.io screenshot:


Version bumped to v3.0.5 but tag was not created

Package version was bumped to v3.0.5 but the corresponding tag was not created. Latest one available is still v3.0.4.

Pushed the tag. Guess I forgot. Note: the package is on the npm registry!


Define NANODBC_ODBC_VERSION after all the headers are included.

Otherwise, the SQL_OV_ODBC3_80 may not get defined yet and so the previous order would always fallback to ODBC v3.x.
Add another defined check to ensure both 'SQL_ATTR_ASYNC_STMT_EVENT' and 'SQLCompleteAsync' symbols exist before enabling async mode. The header included by the unixODBC could have half-baked support for ODBC 3.8 in some of the Linux distros. In my Fedora 22, the symbol 'SQL_ATTR_ASYNC_STMT_EVENT' exists but the 'SQLCompleteAsync' is not yet defined yet. Without the enhanced conditional check, release v2.7.0 did not build successfully on my Fedora 22.

Good catch!


add --delete/-d flag to the CLI

would be nice to be able to remove all the generated files. Like for example when I am tweaking my config, maybe I rename a few things and now I have to go in and manually delete hundreds of  generated files.
Thankfully I have git, so I can remove them easily in there, but there are situations where having a delete flag on the CLI would be useful. Possible use cases:

you don't have git,
you have other changes you want to keep without stashing them
you need to switch from a normal mode to near-operation-file and you want to prepare a commit that cleans the current generated files before making the config change in codegen.yml

Hi @capaj ,
This could be nice, but it means that we need to keep track on files that codegen has been generated in the previous execution. And this might be fragile because we don't want to store a persisted state to the project's directory.
Do you have another idea for managing that kind of state?

No that's not what I had in mind. I was thinking of just removing the files that would get generated in this current pass. This will suffice for the usecases I have mentioned.


The react/require-extension rule is deprecated.

The react/require-extension rule is deprecated. Please use the import/extensions rule from eslint-plugin-import instead.

I'm not sure what you're posting about - we're quite aware that it's deprecated :-)

@ljharb Sorry! I thought that it was warnning by this package!

But the rule is still showing on the README

@Darmody I removed it from the README since we do not	usually list the deprecated rules in it.


Branch 198743117

Any idea why all the presubmit tests arent being triggered?

The xla build link shows that the build passed.
For pip3, not sure why it is complaining "TypeError: a bytes-like object is required, not 'str'". The file_content was read in under binary mode already?

@case540 do you or @yifeif mind making a new push as this has failed Python3 Pip? Thanks!

Is there a fix internally that creating a new push would solve? Otherwise, I'm keeping on trying things to fix this. Also, not sure if there is an easy way to run the pip3 tests locally. Do you know a way @av8ramit

I dont think we run this build internally. Quick way to reproduce this locally is probably use virtualenv.

Ok, closing PR, creating new one to get latest internal CLs. Will add fix.


Improve design with Shell

Improve design with Shell.

More feedback

I've been struggling to remove safeAreaInsets on MainPage on iOS until I find out this bug:Xamarin.Forms/issues/6499, which not fixed until latest version.
I use Shell.Current.GoToAsync("//picture"); to navigate page, but when I use Shell.Current.Navigation.PopModalAsync(); to pop back, it crashed! Maybe GoToAsync method not effect navigation stack.bug:Xamarin.Forms/issues/4769
So I use Shell.Current.GoToAsync("//main"); to pop back, but I navigate to picture page next time, this page is not recreated which means the page instance and viewmodel not disposed.

Thanks for completing the challenge! Fill out this form so we can send you the swag! https://aka.ms/cog-svcs-swag

Thanks for completing the challenge! Fill out this form so we can send you the swag! https://aka.ms/cog-svcs-swag

Thank you!


 Please let me know what the typo is?

The after doesn't have --
This was fixed here https://github.com/docker/docker.github.io/pull/7953
So I am going to close this.


Update pyproject.toml

You are using these features which can only be used from version 3.11
PEP 673: Self type
Enum auto argument

Thank you so much for the pull request! Sorry - i forgot about this.


What is private const int MaxRequestLength = 8192; means?

Dears
I have a question about private const int MaxRequestLength = 8192;.
if I changed from an 8192 to more bigger value what things affected?
Regards,
John Ahn

@jeong760 MaxRequestLength is to prevent someone from bombarding the server with megabytes of junk data with the intent to crash the server. Feel free to increase it to your liking.

Dears,
Does it related to ew RecyclableMemoryStreamManager(0x200, 16 * 0x200, 0x20000);?
if I change a 16*0x200 to 32 * 0x200, what affect?
Regards,
John Ahn

Why would you want to do that?

I want to see the result what affect


Add a parameter to configure the number of seconds to wait before killing the container

I would like to expose the t parameter of the stop call (see https://docs.docker.com/reference/api/docker_remote_api_v1.20/#stop-a-container) to the docker-maven-plugin configuration.
This defaults to 0 in docker. Therefore, for the process running inside there is no change of a proper shutdown, when receiving SIGTERM.
In my use case the process writes some log data, when SIGTERM is received before exiting gracefully.
With the current docker-maven-plugin this file is empty.
I extended docker-maven-plugin in a fork and it is working fine there.

Fixed with merge of #294


Update tdd-tests.yml

Add upload action for codecov

Codecov Report

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

@@           Coverage Diff           @@
##             main      #62   +/-   ##
=======================================
  Coverage        ?   96.86%
=======================================
  Files           ?        5
  Lines           ?      351
  Branches        ?        0
=======================================
  Hits            ?      340
  Misses          ?       11
  Partials        ?        0

Continue to review full report at Codecov.

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


Verify TestDouble call counts

I added code to verify the number of times a test double was called, and brought the existing code up to date with current practices.  I added tests and updated the documentation as well.
If there's something about it you don't like or would prefer done another way, let me know.  I'm not dogmatic, and I'd be happy to change it.

Hey @cwilbur thank you for this awesome PR! I haven't looked at this project in quite some time (hence my slow reply), so it'll take me a minute to get things set back up to review this properly, but I will set aside time for that this week.


Secure alarm activity

If no activtiy is provided for an alarm activtiy, destroy attribute has to be set to true though this will cancel the alarm.

https://github.com/dhbw-timetable/dhbw-timetable-android/commit/f9cd6e1dec82864cf77e5d74dbc0082983cfcccc will fix this.


Warbar claims buffer is opaque when it's being hidden by depressing $mod

Waybar seems to swap out the buffer when it's trying to hide/show itself when using sway IPC mode with the $mod key being depressed. When it swaps the buffer out to something that's completely transparent (functionally hiding it) it still claims the buffer being opaque and so the wayland compositor might try to do optimizations that aren't safe (like in sway master). Waybar needs to have a solid background color configured for the bug to occur.
It's strange that we are committing a new buffer instead of just mapping/unmapping the layer shell?
Ref: https://github.com/swaywm/sway/issues/8075

This issue appears partially fixed with https://github.com/Alexays/Waybar/pull/3528 . Only tested for ~5min but the usual "$mod+focus elsewhere" doesn't leave a black silhouette anymore. That's is such a relief!
On a side note, I have a (short) CSS animation to slowly transition the opacity of the bar when displayed. I see that it first displays a black background when the bar appears.
Example when increasing the animation time + low opacity + pink background: a black background appears first. This does not happen on waybar v0.11.0
https://github.com/user-attachments/assets/cfaa78af-3594-4790-9118-337d7cb5f8f3

In Sway, a black silhouette is still left on the wallpaper in workspaces with only floating windows.
Reproduction steps: create a floating window and focus on it -> press and hold $mod to display Waybar -> change focus -> release $mod :   black silhouette is displayed on the background.
It disappears the next time the bar is displayed

I don't believe it's possible to completely fix that one :(
The root of the problem is in the GtkWindow::update_opaque_region. GTK window has 3 sources of alpha: CSS background-color, CSS opacity and user alpha set via gtk_window_set_opacity. Whenever the style context is changed, update_opaque_region will check the background-color and the user alpha to see if the window is opaque and set the region accordingly.
If you feel like something is missing in the list - indeed, CSS opacity value is ignored and will not affect the opaque region. It seems easy to fix, just need to check GtkWidgetPrivate.alpha instead of GtkWidgetPrivate.user_alpha, but while the latter is exposed via gtk_widget_get_opacity, the former is a private implementation detail with no way to access[^1].
The documented workaround is to use gdk_window_set_opaque_region, which could look like this:
waybar::Bar::Bar(...) {
  // ...
  window.signal_style_updated().connect(sigc::mem_fun(*this, &Bar::onStyleUpdated));
  // ...
}

void waybar::Bar::onStyleUpdated() {
  if (auto gdk_window = window.get_window(); gdk_window) {
    /* Always assume that the window is transparent */
    static Cairo::RefPtr<Cairo::Region> region;
    gdk_window->set_opaque_region(region);
  }
}

The problem is, GTK explicitly commits its own update, and our change gets deferred until the next frame callback. In the best case it results in flickering, and in the worst case - you'll be seeing a black rectangle until the compositor starts sending frame callbacks again.
The full patch is here: https://github.com/alebastr/Waybar/commit/set-opaque-region. I'm fine with submitting it if it makes things better for someone, but it didn't do a lot in my testing.
tl;dr:
Don't use the opacity property. Specify alpha in the background-color instead.
window#waybar {
  background-color: alpha(pink, 0.5);
}

[^1]: now, that's not completely accurate, but I don't intend to work on the necessary GTK3 changes


summarize fails to parse objdump output

The output of my objdump for a certain instruction the sifter found looks like:
o:     file format binary

Disassembly of section .data:

00000000 <.data>:
   0:	prefetch BYTE PTR [rax]

However the things that try to parse it "swallow" the instruction, in particular the sed ones which I am not at all sure what they are supposed to do

Same here, for example 0f0d00 (an instruction SS said that objdump thought was unknown is decoded by objdump itself as prefetch (%rax), so not sure what's going on there.


Performance of multi-machine is worse than one-machine

I used example/image-classification/train_cifar10.py on two computers, which were directedly connected by wire. The speed of net is about 100MB/s.
Could anyone tell me how much net bandwidth do I need? Should I use infiniband?
Sincere Thanks

the model in train_cifar10.py is two small.
it's better for multi-machine when you are training large model, like vgg/resnet model on imagenet.

Besides, please try the latest PR https://github.com/dmlc/mxnet/pull/3241


Interested to work with you

@sonufrienko sonufrienko when will the next commit, waiting from long back. I loved this application and I would like to contribute the development part. Please connect me<EMAIL_ADDRESS>

since the original creator is not here anymore, we made a new repository here. Everyone is welcome to join https://join.slack.com/t/caesarcommerce/shared_invite/enQtNTA0ODExMjIyNjU3LWRhNTM2YzQ4MzMwMjMzN2Y1ZTNmYTkzMWJiOTg5NmE3OGZmOWRlNzViMmQyOTM1NjZjOGNlMWUyNmU5MzJmNjE

@ravitalari you can close the issue if you find our new repo. and can contribute there.

<EMAIL_ADDRESS>Love to join

feel free to give PR to our new repos.. if your PR are good we will join in members list.
github.com/cezerin2

Anil,
Start your work and let us know by raising the PR will always welcome the
young champs like you.
On Tue, Jun 18, 2019 at 10:41 AM Anil yadav<EMAIL_ADDRESS>wrote:

<EMAIL_ADDRESS>Love to join
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/cezerin/cezerin/issues/600?email_source=notifications&email_token=ADHQPKO54J6SP2STBXAQ4ATP3BU7NA5CNFSM4F7VHBA2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODX5GNMI#issuecomment-502949553,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ADHQPKPBF42C4W34Z3RBNP3P3BU7NANCNFSM4F7VHBAQ
.


Make exit explicit

allow rerunning with new routes for as long as you need with explicit instructions on how to end the program
Estimated ~300points

done


Verify that committed GeneratedPluginRegistrant are up-to-date

Follow-up to https://github.com/flutter/flutter/pull/13500.
/cc @mit-mit @mravn-google @Hixie @tvolkert


Building tensorflow 1.14 (bazel 0.24.1) on Jetson Xavier with the trouble

Please make sure that this is a build/installation issue. As per our GitHub Policy, we only address code/doc bugs, performance issues, feature requests and build/installation issues on GitHub. tag:build_template
System information

OS Platform and Distribution
Linux Ubuntu 18.04

TensorFlow installed from (source or binary):
source

TensorFlow version:
1.14

Python version:
3.6.8

Installed using virtualenv? pip? conda?:
pip3

Bazel version (if compiling from source):
Build label: 0.24.1- (@non-git)
Build target: bazel-out/aarch64-opt/bin/src/main/java/com/google/devtools/build/lib/bazel/BazelServer_deploy.jar
Build time: Thu Jul 25 13:20:03 2019<PHONE_NUMBER>)
Build timestamp:<PHONE_NUMBER>
Build timestamp as int:<PHONE_NUMBER>

GCC/Compiler version (if compiling from source):
gcc 5.5.0

CUDA/cuDNN version:
CUDA 10.0
cuDNN 7.5

GPU model and memory:
Nvidia Jetson AGX Xavier

Describe the problem
I try to install tensorflow 1.14 with next config:
bazel build --config=monolithic --jobs 8 -c opt --linkopt='-lrt' //tensorflow:libtensorflow_cc.so
But i get an error
Starting local Bazel server and connecting to it...
ERROR: /root/tensorflow-1.14/WORKSPACE:94:1: Traceback (most recent call last):
	File "/root/tensorflow-1.14/WORKSPACE", line 94
		tf_workspace()
	File "/root/tensorflow-1.14/tensorflow/workspace.bzl", line 708, in tf_workspace
		native.new_http_archive(name = "double_conversion", urls =..."], <3 more arguments>)
type 'struct' has no method new_http_archive()
ERROR: Error evaluating WORKSPACE file
ERROR: Skipping '//tensorflow:libtensorflow_cc.so': error loading package 'external': Package 'external' contains errors
WARNING: Target pattern parsing failed.
ERROR: error loading package 'external': Package 'external' contains errors
INFO: Elapsed time: 5.360s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded)

Provide the exact sequence of commands / steps that you executed before running into the problem

Just to verify did you get chance to follow instructions from TensorFlow website .Please, let us know. Thanks!

@suffererofautomation NVIDIA provides validated and optimized binaries. Although currently, it is for TF 1.13.1. Take a look at: https://elinux.org/Jetson_Zoo#TensorFlow
If you want to build from source (assume you have a specific requirement for 1.14 and you cannot wait), check out this thread. Please consult the thread for a working procedure to build TF from source for Jetson Xavier.

Redirecting to tf mobile team.

What version of bazel do you have installed?

What version of bazel do you have installed?

Now i use:
bazel 19.2
tf 1.13
The configuration works perfectly.
The topic may be closed.

I was able to get the c++ api compiled by following the link left by @tlkh. However the pip package will not build for tensorflow 1.14.0 and i get the same error as in issues/28277

@suffererofautomation
Can we close this issue since the query is been resolved. Thanks!


WIP: Have event checking test helpers wait 50ms before reading events from channel

Changes
fixes #5160
I believe we're seeing flakiness in the cloud events tests (and possibly other event-related tests) due to load resulting in initial deliveries failing and being retried after a 10ms delay. Then the reconciliation ends up finishing before the event is actually delivered, and the event checking helpers don't pick up the eventual delivery. If that's correct, then adding a 50ms delay before CheckEventsOrdered and CheckEventsUnordered read from the events channel should make a big difference in terms of test reliability.
I'm currently running go test -race -count 1 -v ./pkg/... in a loop in a constrained container on my desktop - I've reproduced the cloud events failure fairly often in this way, and after 10 or so runs so far, I haven't seen it with this change...so I'm cautiously optimistic.
Submitter Checklist
As the author of this PR, please check off the items in this checklist:

[ ] Has Docs included if any changes are user facing
[x] Has Tests included if any functionality added or changed
[x] Follows the commit message standard
[x] Meets the Tekton contributor standards (including
functionality, content, code)
[x] Has a kind label. You can add one by adding a comment on this PR that contains /kind <type>. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tep
[x] Release notes block below has been updated with any user facing changes (API changes, bug fixes, changes requiring upgrade notices or deprecation warnings)
[ ] Release notes contains the string "action required" if the change requires additional action from users switching to the new release

Release Notes
NONE

/kind flake
/assign @lbernick

/retest

Ok, the flake count went down considerably, but I also saw a case of an event being set twice even though it was theoretically cached. Digging into that now...

/retest
There's definitely something else wrong with the event cache - I'm seeing two attempts to send an identical event, which it shouldn't be doing. Digging further!

What's the actual race condition here? This seems like it might be a bandaid over most of the test flakes, but is it possible to fix the underlying problem?

What's the actual race condition here? This seems like it might be a bandaid over most of the test flakes, but is it possible to fix the underlying problem?

That's part of what I'm still trying to figure out. If I am right about the retries (which I'm less sure of now!), then the race would be that sometimes, under load, sending the cloud event fails the first time and gets resent 10ms later, which is fine. That's why we have the retries there - the end result is correct, it's just the test scenario that has problems due to expecting all the events to be delivered by the time the PipelineRun reconciliation is over...which may not be the case if it had to retry.
But I have now seen at least one case (with a bunch of extra debug logging tossed in to give me better visibility into what's actually happening) of an event getting sent successfully, then when the second reconcile happens, it shouldn't be sending the event again because it's already in the cloud event controller cache, but it is, in fact, being sent again. So that's where I'm poking around in right now.

Also, to make it more fun, in my test setup, TestReconcile_InvalidPipelineRuns in pkg/reconciler/pipelinerun/pipelinerun_test.go is flaking out fairly often, which I've never seen in CI and am assuming is just a weird artifact of the resource-limited setup I'm running in...which, of course, could throw off all my theories around the cloud events tests. Fun!

So I've added https://github.com/tektoncd/pipeline/pull/5313/commits/1cdc4fa81100a8c3525069aa5d0caf9bd27f8a36 to this PR - as I detailed in #5160, I've narrowed down the cause of the run_test cloud events failures to multiple events for the same Run being sent before the first call finishes, so adding a mutex to cloud event dispatch in the Run reconciler should solve that. This particular issue is very specific to Runs - we only do caching to prevent duplicate event dispatch for Runs. This mutex should also deal with the race condition that shows up sometimes in the various cloud event tests in pkg/reconciler/run/run_test.go, I believe.
That said, I think the sleep in the original commit here is still valuable for other event test flakiness, such as TestSendKubernetesEvents, TestSendCloudEventWithRetries/test-send-cloud-event-taskrun, and TestReconcile_CloudEvents in taskrun_test.go - these event-related flakes are all cases where events, either k8s events or cloud events, have not yet been received when we go to check them, rather than the Run/cloud events flakes, which are caused by a duplicate event being received. So I do still think that a delay should cut down on the "missing event" flakes.

Thanks for this. I wonder if we should add the mutex further down in the code structure though, because this will hold the entire reconcile cycle, so it will basically force reconciles to not happen in parallel as long as long as cloudevents for run is enabled. It feels like this would slow down things a lot because the event will be taken from the queue and sit there waiting.
Perhaps it would be enough to add locks to the methods in https://github.com/tektoncd/pipeline/blob/main/pkg/reconciler/events/cache/cache.go, similar to what the original cache class does?

Thanks for this. I wonder if we should add the mutex further down in the code structure though, because this will hold the entire reconcile cycle, so it will basically force reconciles to not happen in parallel as long as long as cloudevents for run is enabled. It feels like this would slow down things a lot because the event will be taken from the queue and sit there waiting.

Yeah, I don't love this location, but the thing is that we do actually need to lock the whole of events.EmitCloudEvents, or at least all of cloudevent.SendCloudEventWithRetries. That said, I'm 100% sure there's a better way to do it than what I've done here, I just haven't landed on it yet.

Perhaps it would be enough to add locks to the methods in https://github.com/tektoncd/pipeline/blob/main/pkg/reconciler/events/cache/cache.go, similar to what the original cache class does?

No, that wouldn't work, because it's not that we're having problems because of the cache calls directly. The problem is that https://github.com/tektoncd/pipeline/blob/45b7c378985f0baaab751980511228fdce1e0801/pkg/reconciler/events/cloudevent/cloud_event_controller.go#L148-L174 isn't locked, so two different calls can be somewhere in that block at the same time. What's happening is that call 1 gets past cache.IsCloudEventSent(...) and into ceClient.Send(...), and before call 1 gets past that to get to cache.AddEventSentToCache(...), call 2 gets to cache.IsCloudEventSent(...). So really, we want a lock on that go func()....

Thanks for this. I wonder if we should add the mutex further down in the code structure though, because this will hold the entire reconcile cycle, so it will basically force reconciles to not happen in parallel as long as long as cloudevents for run is enabled. It feels like this would slow down things a lot because the event will be taken from the queue and sit there waiting.

Yeah, I don't love this location, but the thing is that we do actually need to lock the whole of events.EmitCloudEvents, or at least all of cloudevent.SendCloudEventWithRetries. That said, I'm 100% sure there's a better way to do it than what I've done here, I just haven't landed on it yet.

Perhaps it would be enough to add locks to the methods in https://github.com/tektoncd/pipeline/blob/main/pkg/reconciler/events/cache/cache.go, similar to what the original cache class does?

No, that wouldn't work, because it's not that we're having problems because of the cache calls directly. The problem is that
https://github.com/tektoncd/pipeline/blob/45b7c378985f0baaab751980511228fdce1e0801/pkg/reconciler/events/cloudevent/cloud_event_controller.go#L148-L174
isn't locked, so two different calls can be somewhere in that block at the same time. What's happening is that call 1 gets past cache.IsCloudEventSent(...) and into ceClient.Send(...), and before call 1 gets past that to get to cache.AddEventSentToCache(...), call 2 gets to cache.IsCloudEventSent(...). So really, we want a lock on that go func()....

So, I'm thinking that we should change this function to add the event to the cache before we invoke the actual send function, since that might do retries and take an arbitrary amount of time to complete.
I would propose to:

Change the AddEventSentToCache function to, lock, read, write, unlock, and return whether the event was already there
Call the AddEventSentToCache where the IsCloudEventSent is now, and use the result to decide whether to send the event or not

Yeah, that all sounds good to me. Lemme do that.

/retest

/retest

/assign @afrittoli @jerop

/assign @vdemeester

ping @afrittoli @jerop @lbernick =)


Update wording payment_infos.tpl

Should have been changed in September. Maybe the changes got lost.

Hello @Nobodaddy,
Thanks for your contribution.
We agree with the changes of this line https://github.com/PrestaShop/ps_checkpayment/pull/5/files#diff-b5a3dead95ffe83bf1c36d9fa746634fR27 but "information" never takes a S.
Also the second line changed has already been modified by another PR. So, I close this one, but if you want, you can open another one for the first modification.
Thank you


work-for-faction.js: Ignores clearly more effective jobs for reputation gain

The script refuses to switch to Security Supervisor job and even switches back to the previous, less effective one after manually switching to Security Supervisor.

Hey @guy-732 , thanks for the report.
Indeed, this is known behaviour and a bit by design. The idea is that if your focus is on the hack stat, only hacking jobs are worthwhile, and that if your focus is on the physical stats, most likely you are either committing crime or doing faction work, not doing job / corporate work.
There are probably niche moments towards the ned of a bitnode where physical stats have scaled significantly more than hack (which they tend to do late in BNs with most augmentations installed), but at that point there's often little need to work for companies unless you're trying to get the last few company-faction-exclusive augmentations, and then your stats are probably so high that the difference between hacking your way to CEO and a different job is a matter of minutes.
If that's not true, I might consider expanding support for different career paths, but I'd need to know the logic for when to switch to that career path, because the game itself doesn't provide an API for telling you how much EXP/second you're gaining from a given job - only the UI gets that information - so there's no easy way to know when to switch.


Events (active item changed)

How to trigger function if active element changed?
This library has events?
I have a long menu list with scroll (div with overflow) and want to make autoscroll following Active item..

Sorry for stupid question, find solution:
v-scroll-spy="{data: 'section'}"
than
watch:
        {
            'ActiveSection': function ()
            {
                document.querySelector(' /* my list div */ ').scrollTop = document.querySelector(' /* list item with active class */ ').offsetTop-128;
            }
        }


Where is CoveredOption contract?

https://github.com/dydxprotocol/protocol/pull/96

Hey @k06a, we haven't been focusing on options yet. The PR you're referencing is a pretty outdated, untested, and generally early version of the covered option smart contract
We'll open source the options protocol when it's ready


Both: change start button

We should change the start button to show it's an online application.
The text should change from "Start now" to "Apply online now".

@kateiw I didnt see you were assigned to this and I just did it too :(

lol no worries, thanks for doing it!
On 3 February 2017 at 10:02, kaydale<EMAIL_ADDRESS>wrote:

@kateiw https://github.com/kateiw I didnt see you were assigned to this
and I just did it too :(
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/alphagov/verify-local-patterns/issues/114#issuecomment-277209273,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ATw9IiBkkaNe8Cd33ebugzu2oGhkzxjzks5rYvtAgaJpZM4Ly3SK
.

--
Kate Ivey-Williams | Service Designer for GOV.UK


Combine tests

Nice - we were actually wondering about this as Aurelien opened https://github.com/batijs/bati/pull/12.

Yes, very nice!


AddressSanitizer: use-after-poison in _vflow_find_attribute ../src/vanflow.c:194

https://github.com/skupperproject/skupper-router/actions/runs/4532214932/jobs/7983452930#step:10:4489

This is possibly duplicate of https://github.com/skupperproject/skupper-router/issues/966

58: ==5949==ERROR: AddressSanitizer: use-after-poison on address 0x613000118d70 at pc 0x55ddee0803c8 bp 0x7f061b3051e0 sp 0x7f061b3051d0
58: READ of size 8 at 0x613000118d70 thread T1
58:     #0 0x55ddee0803c7 in _vflow_find_attribute ../src/vanflow.c:194
58:     #1 0x55ddee0897ed in _vflow_set_int_TH ../src/vanflow.c:470
58:     #2 0x55ddee097d0a in _vflow_thread ../src/vanflow.c:1216
58:     #3 0x55ddee077eb9 in _thread_init ../src/posix/threading.c:155
58:     #4 0x7f0621395608 in start_thread /build/glibc-SzIz7B/glibc-2.31/nptl/pthread_create.c:477
58:     #5 0x7f0620481132 in __clone (/lib/x86_64-linux-gnu/libc.so.6+0x11f132)
58:
58: 0x613000118d70 is located 240 bytes inside of 320-byte region [0x613000118c80,0x613000118dc0)
58: allocated by thread T6 here:
58:     #0 0x7f0621ad86e5 in __interceptor_posix_memalign ../../../../src/libsanitizer/asan/asan_malloc_linux.cc:217
58:     #1 0x55ddedfbea07 in qd_alloc ../src/alloc_pool.c:404
58:     #2 0x55ddee07fea7 in new_vflow_record_t ../src/vanflow.c:98
58:     #3 0x55ddee098300 in vflow_start_record ../src/vanflow.c:1306
58:     #4 0x55ddedf0989c in _client_rx_request_cb ../src/adaptors/http1/http1_client.c:929
58:     #5 0x55ddededd474 in parse_request_line ../src/adaptors/http1/http1_codec.c:629
58:     #6 0x55ddededf095 in parse_start_line ../src/adaptors/http1/http1_codec.c:728
58:     #7 0x55ddedee7f1e in decode_incoming ../src/adaptors/http1/http1_codec.c:1256
58:     #8 0x55ddedee8f2e in h1_codec_connection_rx_data ../src/adaptors/http1/http1_codec.c:1308
58:     #9 0x55ddedf0385c in _do_raw_io ../src/adaptors/http1/http1_client.c:509
58:     #10 0x55ddedf059ed in _do_io ../src/adaptors/http1/http1_client.c:660
58:     #11 0x55ddedf06dba in _handle_connection_events ../src/adaptors/http1/http1_client.c:780
58:     #12 0x55ddee1e077e in handle_event_with_context ../src/server.c:801
58:     #13 0x55ddee1e07c3 in do_handle_raw_connection_event ../src/server.c:807
58:     #14 0x55ddee1e4cb3 in handle ../src/server.c:1085
58:     #15 0x55ddee1e4f89 in thread_run ../src/server.c:1117
58:     #16 0x55ddee077eb9 in _thread_init ../src/posix/threading.c:155
58:     #17 0x7f0621395608 in start_thread /build/glibc-SzIz7B/glibc-2.31/nptl/pthread_create.c:477
58:
58: Thread T1 created by T0 here:
58:     #0 0x7f0621a04815 in __interceptor_pthread_create ../../../../src/libsanitizer/asan/asan_interceptors.cc:208
58:     #1 0x55ddee078075 in sys_thread ../src/posix/threading.c:166
58:     #2 0x55ddee09ba3f in _vflow_init ../src/vanflow.c:1586
58:     #3 0x55ddee15a0de in qdr_adaptors_init ../src/router_core/router_core_thread.c:168
58:     #4 0x55ddee137c08 in qdr_core_setup_init ../src/router_core/router_core.c:72
58:     #5 0x55ddee138872 in qdr_core ../src/router_core/router_core.c:122
58:     #6 0x55ddee1d09c4 in qd_router_setup_late ../src/router_node.c:2106
58:     #7 0x7f061c307ff4  (/lib/x86_64-linux-gnu/libffi.so.7+0x6ff4)
58:     #8 0x7ffd8ef30bff  ([stack]+0x1dbff)
58:
58: Thread T6 created by T0 here:
58:     #0 0x7f0621a04815 in __interceptor_pthread_create ../../../../src/libsanitizer/asan/asan_interceptors.cc:208
58:     #1 0x55ddee078075 in sys_thread ../src/posix/threading.c:166
58:     #2 0x55ddee1ec509 in qd_server_run ../src/server.c:1513
58:     #3 0x55ddee1f8d73 in main_process ../router/src/main.c:109
58:     #4 0x55ddee1fadc2 in main ../router/src/main.c:363
58:     #5 0x7f0620386082 in __libc_start_main ../csu/libc-start.c:308
58:
58: SUMMARY: AddressSanitizer: use-after-poison ../src/vanflow.c:194 in _vflow_find_attribute

Duplicates #1021


source dist name

see https://github.com/apache/incubator-pekko/pull/468

All tests are failing but I think its unrelated, re-running CI just to be sure


How can I insert a function component inside a existing component?

You can write your topic however you want, but you need to answer these questions:

What do you want to achieve? Keep it simple and clear!
I am wondering how I can insert a existing  function component inside an existing component as it's child?

Here is my script so far:
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Roact = require(ReplicatedStorage.Module.roact)
-- tip that indicate what to do
-- if you still dont get it:
--[[
    |-------|
    |  btn |
    | what |
    -------
]]
local function  what(info)
    Roact.createElement("TextLabel",{
        AnchorPoint = Vector2.new(0.2,0);
        Position = UDim2.fromScale(0.2,0);
        Text = info;
        Font = Enum.Font.GothamSemiBold;
        BackgroundColor3 = Color3.fromRGB(107, 107, 158);
        BorderColor3 = Color3.fromRGB(95, 95, 121);
        BorderSizePixel = 2;
        BorderMode = Enum.BorderMode.Inset;
    })
end
local menuBg  = Roact.createElement("Frame",{-- what i want to insert the what function  in as a child
    BackgroundColor3 = Color3.fromRGB(217, 216, 247);
    BorderSizePixel = 0;
    Size = UDim2.fromScale(0.3,0.4);
    Position = UDim2.fromScale(0.5,0.5);
    AnchorPoint = Vector2.new(0.5,0.5);
},{
    title = Roact.createElement("TextLabel",{
        AnchorPoint = Vector2.new(0.5,0);
        Position = UDim2.fromScale(0.5,0.2);
        BackgroundTransparency = 1;
        -- text part
        Text = "Jinx";
        Font = Enum.Font.GothamBold;
        TextSize = 36;
    });
})

local menu = Roact.createElement("ScreenGui",{},{})
local PlayerGui = Players.LocalPlayer:WaitForChild("PlayerGui")
Roact.mount(Roact.createElement("ScreenGui",{},menuBg), PlayerGui)

I thinked that I could create the menu bg as a function compent however I am not sure if it will be great when it come to roact standard.
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Roact = require(ReplicatedStorage.Module.roact)
-- tip that indicate what to do
-- if you still dont get it:
--[[
    |-------|
    |  btn |
    | what |
    -------
]]
local function  what(info)
    Roact.createElement("TextLabel",{
        AnchorPoint = Vector2.new(0.2,0);
        Position = UDim2.fromScale(0.2,0);
        Text = info;
        Font = Enum.Font.GothamSemiBold;
        BackgroundColor3 = Color3.fromRGB(107, 107, 158);
        BorderColor3 = Color3.fromRGB(95, 95, 121);
        BorderSizePixel = 2;
        BorderMode = Enum.BorderMode.Inset;
    })
end

local function createMenuBg(...)
    local extraComponent = {...}
    local menuBg  = Roact.createElement("Frame",{-- what i want to insert the what function  in as a child
        BackgroundColor3 = Color3.fromRGB(217, 216, 247);
        BorderSizePixel = 0;
        Size = UDim2.fromScale(0.3,0.4);
        Position = UDim2.fromScale(0.5,0.5);
        AnchorPoint = Vector2.new(0.5,0.5);
    },{
        title = Roact.createElement("TextLabel",{
            AnchorPoint = Vector2.new(0.5,0);
            Position = UDim2.fromScale(0.5,0.2);
            BackgroundTransparency = 1;
            -- text part
            Text = "Jinx";
            Font = Enum.Font.GothamBold;
            TextSize = 36;
        });
        extraComponent
    })
end

local menu = Roact.createElement("ScreenGui",{},{})
local PlayerGui = Players.LocalPlayer:WaitForChild("PlayerGui")
Roact.mount(Roact.createElement("ScreenGui",{},createMenuBg(what("Lorem ipsum dolor sit amet."))), PlayerGui)

Function components are a fairly standardized feature. The "Components" section of the guide goes over how they're intended to be used.
In general, you should not call them like functions, but instead always use createElement on them. If you need to pass children through them, write your function component to pass on props[Roact.Children] to one of its children, like:
return Roact.createElement("Frame", {}, props[Roact.Children])

Thnaks. You solved the problem


Bugfix: Cronjob ctx cancel

Removed the stop channel and just use ctx.
Fixes https://github.com/kubernetes-sigs/descheduler/issues/728

/ok-to-test
/approve

There's a valid building error in the e2e:
vet: test/e2e/e2e_test.go:989:105: too many arguments in call to descheduler.RunDeschedulerStrategies

@jklaw90 would you mind squashing the commits? Looks good.

/retest

/lgtm

/retest


Better breaking change notice

Hey folks,
I appreciate the Golang support but please documentation breaking API changes.
...GetConfig().GetArtDetails undefined (type config.Config has no field or method GetArtDetails)

This was broken upgrading from v0.8.1 -> v0.9.0
This commit broke the API and there were no documentation/announcement for it https://github.com/jfrog/jfrog-client-go/commit/a265a825ffe8f94cd985d179133306b57dade16a
This method is a public API so please dont just change it without announcement :(

@sluongng,
Thanks for sharing this with us.
Till now, we've been treating the APIs documented in the README as public APIs. I believe that the ..GetConfig().GetArtDetails API is not there.
Do you think we should add additional APId to the README, so that they are treated as public? Do you have a suggestion for an alternative way to mark APIs as public? We're open to suggestions.

https://tour.golang.org/basics/3
Its simple, GetArtDetails() is exported so its open to be used outside of the package. i.e. public usage.
If you dont want to make it public, then just ensure that you dont export the function.
For my use case, I made 2 helper functions in my code
// GetArtUrl is helper method to get base artifactory url from config
func (ctx *ArtServices) GetArtUrl() string {
	return ctx.GetConfig().
		GetArtDetails().
		GetUrl()
}

// GetClientDetails is helper method to get base client config
func (ctx *ArtServices) GetClientDetails() *httputils.HttpClientDetails {
	d := ctx.GetConfig().
		GetArtDetails().
		CreateHttpClientDetails()
	return &d
}

So that I have an easier time building custom request that your client has yet to support.
i.e.
url := ctx.GetArtUrl() + "api/trash/restore/" + blah + "?to=" + blah2

or
myart.Client().SendGet(url, true, ctx.GetClientDetails())

I find that this is a useful flexibility to have while you guys still building more client support for more http api.


#15  added README file  for local running of the application

added the necessary changes from the resource given by the mentor

hey @yashksaini-coder yeah there was an small issue when merging (it is showing build error) not sure how to fix that

@nagajaideep I created a build-deploy workflow script. as there was no github actions generally present at that time. So this script naturally build the site & deploy them.
However after merging the PR, deploy job fails as there is already settings configured on the project to build & publish. That's why deploymeny job doesn't work.

i can fix the configuration settings if I have access to main repo as collaborator.

@nagajaideep can you tell me what issue does this PR #16 fixes ?

#16 pull req: this have changes in the readme file on how to run the application locally on your system and I've also added the template for pull request
there are no merge conflicts when when added to my forked repo only deployment issues
i have no idea what went wrong if you don't mind can you explain what is the issue exactly about given in the screenshot above

#16 pull req: this have changes in the readme file on how to run the application locally on your system and I've also added the template for pull request
there are no merge conflicts when when added to my forked repo only deployment issues
i have no idea what went wrong if you don't mind can you explain what is the issue exactly about given in the screenshot above

issue is to enhance live location of ambulance on google map

@mansiruhil13 can you add gssoc & hacktoberfest labels in this PR,


Print Trend Details in the logs

The default log does not contain this info.
The user should be able to compute the forecast by hand based on the logs.
JSON outputs also should be complete.

Closing


[fusell] Allow userdata to be passed to constructor

Arbitrary data can be passed as an optional parameter to the FUSELL
constructor. This is then passed to the init and destroy methods.
I've chosen to save the userdata as an instance variable instead of
passing it to fuse_lowlevel_new because that seemed simpler than dealing
with ctypes. We then need to intercept the init and destroy calls to
pass them the correct userdata.
Resolves #111

To be honest, I don't see how that can be useful.
Passing an userdata pointer makes sense in C, where the function callback isn't associated with a context.
But in Python each callback is associated with the FUSELL instance. Since you need to subclass it anyway, you can add as many attributes as you want -- As you pointed out, storing a new attribute as is quite easy.

So the recommended solution is to override __init__? That felt like not what I was supposed to do, but maybe the existence of init and the userdata param just tricked me. If userdata is always going to be None, maybe it would be more clear to just remove it from the init args? I suppose that would cause backwards compatibility issues though.

I'm just a random person who happens to watch this repo, so I don't think I get to say what is the recommended way -- But that is how I've been doing.
On the other hand, I didn't realize that init/destroy already had an always-null userdata parameter 🤦. I'd delete them, but given that it is API-breaking, I now think your change makes sense. Sorry :P

Looking at this change I didn't realize there were hooks that you could use. Based on your commit I would suggest as @paulo-raca is suggesting to subclass and override __init__ (calling super as needed). I was under the impression you wanted/needed to pass userdata to fuse_lowlevel_new which is in __init__ and would be much harder to override (you'd have to basically copy the code verbatim)

Yeah I agree now that this is unnecessary.
It seems like the real issue is that the userdata param is passed to init and destroy even though it is always None. The existence of the param suggested to me that the intended usage was to set this somehow and use init as the constructor. I image we would not want to remove the param as it would break backwards compatibility, but maybe it would be worth just adding a note here that it will always be None?


Feature Request: Allow error message text to be copy pasted.

While helping report bugs and errors, it would be convenient to be able to select and copy the text in the error message.
Even cooler to just have a button that says 'copy error text'.
Coolest to have a button that says 'report error' that redirects to the issues page to either add to an existing conversation or report a new error.

Great point @talon256. The copy / paste at a minimum seems helpful.
Note: the tool does save logs to your user's home directory (os dependent), e.g. for macOS: /Users/$USER/MintAmazonTagger/Tagger Logs/DATE_OF_RUN.log). This file would be the most helpful when filing a bug report; thanks!

Thanks for the FR @talon256. The text is now copyable in 1.43. I'll leave this open as a future FR to make reporting even easier.

have a button that says 'report error' that redirects to the issues page to either add to an existing conversation or report a new error.

I realized today that something as simple as a 'Go to GitHub' option on the menu bar drop down (on Mac) or file menu (on PC) would be very nice for 'bookmarking' this forum. That's probably much easier to implement than the 'report error' button, but basically just as helpful.

I've added a report button to the UI as well! Unfortunately github's url API isn't rich enough to be extremely useful, but good enough.


generated files (eg nimpb/compiler/nimpb_build) should go in a subfolder

eg:
nimpb/compiler/nimpb_build
=>
this could go under ./build/bin/nimpb_build
protobuf-all-3.5.1.zip and protobuf-3.5.1 could go under ./build/ ...
.gitignore could add ./build/ so that git status can stay clean (eg after running nimble build_protobuf git status is not clean)

When I first started to create this package, I had some problems with nimble, srcDir and binaries. Maybe I'll need to take a fresh look.


call onStreamCompleted without holding stream locks

An example fix for #1364 ... in this case I tried to preserve the property that the onStreamCompleted callback has been called / completed before returning from the triggering call by calling it deferred once the stream lock has been released.  (and some related monkeying to communicate with the lock holding scope)

I signed it!

Codecov Report

Merging #1365 into master will increase coverage by 0.02%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #1365      +/-   ##
==========================================
+ Coverage   89.98%   90.01%   +0.02%
==========================================
  Files         119      119
  Lines        8346     8366      +20
==========================================
+ Hits         7510     7530      +20
  Misses        550      550
  Partials      286      286

Impacted Files
Coverage Δ

send_stream.go
97.22% <100%> (+0.2%)
:arrow_up:

receive_stream.go
97.33% <100%> (+0.15%)
: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 407a563...59102d3. Read the comment docs.

@marten-seemann great thanks!


update branch workflow -> feature branch workflow

Sorry @fabian-s and @berndbischl  it took so long for me to update :)
Please check!

@fabian-s @berndbischl could you review and merge if possible?
@ludwig-max might need to know about the workflow ;)


Gibberish translation coming for some languages

Hi @nreimers
I am using m2m_100_1.2B for translation. I noticed that for some languages like Azerbaijani (az) it is giving weird results. Couple of examples are below. Can you suggest what is happening here and how to fix this?

I have experienced this issue as well. The gibberish is always of a repeat string of text. Like this.


kmcos view Dependencies

Dependencies for kmcos view functionality. Testing with fresh Ubuntu machine and was able to run kmcos view in MyFirstSnapshot_local_smart.

@meelod  Great work!


Luma wont update- 3ds won't stream to PC.

What model of system are you using?

[ ] New 3DS XL

What is your current Luma3DS version?
If you are running an hourly version of Luma3DS, please manually update to a stable version as I will no longer deal with people who are using hourlies.

[ ] Luma3DS v7.1 + boot9strap v1.0/v1.1
[ ] Luma3DS v8.0 + boot9strap v1.2+
[ ] Luma3DS v8.1 + boot9strap v1.2+
[ ] Luma3DS v8.1.1 + boot9strap v1.2+
[ ] Luma3DS v9.0 + boot9strap v1.2+
[ ] Luma3DS v9.1 + boot9strap v1.2+
[ ] Luma3DS v10.0+ + boot9strap v1.2+
I am not sure how do i check?

What version of Luma Updater are you using?

[ ] v2.4

How are you running Luma Updater?

[ ] .cia

What problems are you experiencing?
Please tell us what problems you are facing.
Will not update
What is the exact error code you are receiving?
Please give the exact error code the app gives you.
Reason for failure: DOWNLOAD FAILED
Steps to reproduce

Opened luma updater
selected update
download failed

#53


Number of delegators under a node does not seem correct

Issue description
The number of delegators does not seem correct, only taking into consideration the delegation done under the V8.

This is I believe intentional, the number of delegators will increase as people migrate their stake / delegate using new mechs. Can you confirm @u-hubar ?