the bug when use self.save_hyperparameters()

I followed the tutorial to train my own video classification model, but this bug appeared when I wanted to use the saved model for inference。
model = cls(**_cls_kwargs) TypeError: __init__() missing 1 required positional argument: 'args'
Then they checked the information on the Internet and they said they could add this code.
https://github.com/PyTorchLightning/pytorch-lightning/issues/2909
However, I added this line of code to retrain and there was a bug. Can someone tell me why?
raceback (most recent call last):                                                                                File "train_frame.py", line 630, in <module>     main()   File "train_frame.py", line 610, in main     train(args)   File "train_frame.py", line 617, in train     trainer.fit(classification_module, data_module)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/trainer.py", line 458, in fit     self._run(model)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/trainer.py", line 756, in _run     self.dispatch()   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/trainer.py", line 797, in dispatch     self.accelerator.start_training(self)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/accelerators/accelerator.py", line 96, in start_training     self.training_type_plugin.start_training(trainer)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/plugins/training_type/training_type_plugin.py", line 144, in start_training     self._results = trainer.run_stage()   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/trainer.py", line 807, in run_stage     return self.run_train()   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/trainer.py", line 869, in run_train     self.train_loop.run_training_epoch()   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/training_loop.py", line 584, in run_training_epoch     self.trainer.run_evaluation(on_epoch=True)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/trainer.py", line 1006, in run_evaluation     self.evaluation_loop.on_evaluation_end()   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/evaluation_loop.py", line 102, in on_evaluation_end     self.trainer.call_hook('on_validation_end', *args, **kwargs)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/trainer.py", line 1223, in call_hook     trainer_hook(*args, **kwargs)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/callback_hook.py", line 227, in on_validation_end     callback.on_validation_end(self, self.lightning_module)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/callbacks/model_checkpoint.py", line 249, in on_validation_end     self.save_checkpoint(trainer)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/callbacks/model_checkpoint.py", line 298, in save_checkpoint     self._save_top_k_checkpoint(trainer, monitor_candidates)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/callbacks/model_checkpoint.py", line 669, in _save_top_k_checkpoint     self._update_best_and_save(current, trainer, monitor_candidates)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/callbacks/model_checkpoint.py", line 730, in _update_best_and_save     self._save_model(trainer, filepath)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/callbacks/model_checkpoint.py", line 449, in _save_model     self._do_save(trainer, filepath)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/callbacks/model_checkpoint.py", line 460, in _do_save     trainer.save_checkpoint(filepath, self.save_weights_only)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/properties.py", line 330, in save_checkpoint     self.checkpoint_connector.save_checkpoint(filepath, weights_only)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/trainer/connectors/checkpoint_connector.py", line 392, in save_checkpoint     self.trainer.accelerator.save_checkpoint(_checkpoint, filepath)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/accelerators/accelerator.py", line 516, in save_checkpoint     self.training_type_plugin.save_checkpoint(checkpoint, filepath)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/plugins/training_type/training_type_plugin.py", line 256, in save_checkpoint     atomic_save(checkpoint, filepath)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/pytorch_lightning/utilities/cloud_io.py", line 64, in atomic_save     torch.save(checkpoint, bytesbuffer)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/torch/serialization.py", line 379, in save     _save(obj, opened_zipfile, pickle_module, pickle_protocol)   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/torch/serialization.py", line 484, in _save     pickler.dump(obj) _pickle.PicklingError: Can't pickle <function <lambda> at 0x7ff195ab3b80>: attribute lookup <lambda> on pytorchvideo.models.resnet failed Exception ignored in: <function tqdm.__del__ at 0x7ff1b151cdc0> Traceback (most recent call last):   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/tqdm/std.py", line 1145, in __del__   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/tqdm/std.py", line 1299, in close   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/tqdm/std.py", line 1492, in display   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/tqdm/std.py", line 1148, in __str__   File "/data1/thorqian/anaconda3/lib/python3.8/site-packages/tqdm/std.py", line 1450, in format_dict TypeError: cannot unpack non-iterable NoneType object

Can you give an example to test the use case with the trained ckpt?

Please add this line self.save_hyperparameters(args) to your PytorchLightning model here - https://github.com/facebookresearch/pytorchvideo/blob/master/tutorials/video_classification_example/train.py#L69
This should save and load args automatically when working with checkpoints.
Please re-open the issue if the problem persists.


Incorrect errors in Form Api

Hi! I have following code:
const haveError = (errors: Object, field: string) => (
    errors && errors.hasOwnProperty(field)
);

const readError = (errors: Object, field: string) => (
    haveError(errors, field) ? errors[field] : null
);

const RegisterForm = () => (
    <Form validate={validateMethod} render={({ errors }) => (
            <form>

                // this showing not empty object while really validateMethod return empty object
                { console.log(errors) }

                { haveError(errors, 'email') && {readError(errors, 'email')} }
                <Text field='email' type='email'/>

                { haveError(errors, 'password') && {readError(errors, 'password')} }
                <Text field='password' type='password'/>

                { haveError(errors, 'repeatPassword') && {readError(errors, 'repeatPassword')} }
                <Text field='repeatPassword' type='password'/>
            </form>
    )}/>
);

On change values in form, validateMethod on line 43 showing empty object. I mean -  errors in form api should be empty, but not empty

Im sorry im not following? Can you put your validator and also describe the speps you take to get those logs?

@joepuzzo Im already migrated to redux-form and this code with small changes work there. I do not know why you need more information, I've described enough

You said there was an issue with incorrect errors but did not even put your validator?

<Form validate={validateMethod} render={({ errors }) => ( it would be helpful to see your validateMethod

@joepuzzo See console.log in screenshot. At index.js:43 is Object, returned by validateMethod. Why you need the source of validator, if i told you, what value validator return?

You are suggesting that react form is not setting the correct errors... the console.log shows the result of a function, the validateMethod. Having the log is does not help because that show what react form set on the errors object.. how did react for set the errors? Well it used your validateMethod. Therefore the issue probably exists in that function.

Rly? It normally work with redux-form. Anyway redux-form better, i don't see why you're trying maintenance this bike

Try using redux form in IE with more than 30 inputs ;) but if redux form works better for you then it works better for you :) this works better for me


sudo should ask for password at beginning of 'vagrant up', not in the middle.

Hi,
We've started using this plugin with Vagrant under OS X at our office, and it works well.  But one issue that keeps coming up is that some time after running "vagrant up", 'sudo' requests the user's password (in order to edit /etc/hosts) in the middle of our fairly long provisioning process. The length of that process wouldn't be an issue if a user could start it and walk away, but instead they have to wait around an indeterminate period of time before they're asked to enter their password.
I solve this by running "sudo echo foo; vagrant up" so that sudo caches my password.  It would be much better if the plugin did that internally: ask for the user's password as early in the process as possible, and let sudo cache it until it's needed.

This would most likely have to happen at the Vagrant level. Not sure a plugin can make a sudo password request at the beginning of "vagrant up". This is a good idea though. Happens to me all the time and its frustrating. Maybe open an issue with the Vagrant project? https://github.com/mitchellh/vagrant

Hi there
well we had the same problem and circumvented this the same way it's done when you use NFS mounting on vagrant itself (https://github.com/mitchellh/vagrant/blob/681ba1c3d754b5ec9793a8811ab40eba95c11668/website/docs/source/v2/synced-folders/nfs.html.md)
adding this to the sudoers file should work fine
# Allow passwordless startup of Vagrant with vagrant-hostsupdater.
Cmnd_Alias VAGRANT_HOSTS_ADD = /bin/sh -c echo "*" >> /etc/hosts
Cmnd_Alias VAGRANT_HOSTS_REMOVE = /usr/bin/sed -i -e /*/ d /etc/hosts
%admin ALL=(root) NOPASSWD: VAGRANT_HOSTS_ADD, VAGRANT_HOSTS_REMOVE

Probably we should document this into the readme file and update it when the hostsupdater commands change.
What do you think?

Probably we should document this into the readme file and update it when the hostsupdater commands change.
What do you think?

I just ran into this same issue and independently used the same pattern in my sudoers file to make this fix.  Seems to me like it would make sense to encourage users who aren't already running as part of an admin group for their day-to-day development environment to continue that security best practice.
#73 is a pull request that prints a generalized version of the above advice into STDERR when this issue is encountered.

Going to close this for now.  The main issue was addressed in version 1.0.0.  Host entries are added before any provisioner runs so the user is prompted fairly quickly to enter the sudo password.

Could you please specify that it must be workstation's sudo password?
I was stuck in thinking that it was asking for sudo permission inside vagrant to modify its hosts file and not the one of my host:
==> machine: [vagrant-hostsupdater] This operation requires administrative access. You may skip it by manually adding equivalent entries to the hosts file.
Password:

Maybe we could change the message to something more clarifying like: This operation requires administrative access on your vagrant workstation.
Thanks


Developer documentation and Dockerfile contradict one another

The developer documentation says that spinning up the Docker Compose stack will result in a Mkdocs dev-server listening for incoming requests; but that is no longer the case as of commit https://github.com/microbiomedata/nmdc-schema/commit/3a1381bd050c8a538fc29edc759b90acb4050929, in which the command that starts the Mkdocs dev-server was commented out.
https://github.com/microbiomedata/nmdc-schema/blob/3db6cff34450bfca7d48e305c1495af36606730f/Dockerfile#L67-L71

Here's the path forward I want to take:

Debug the issues with the original command
Reinstate the original command into the Dockerfile

The command poetry install is commented out also. That means the Python dependencies will not be installed.

Hi @ssarrafan, there's a tag I have liked on other projects, called awaiting-response (whether in pursuit of making a decision, gathering more information, etc.).
I think I'd prefer not having a column on the sprint board for "decisions needed". That's because it can occur at various stages of todo -> in progress -> in review -> done and I like the left-to-right flow that the current set of columns "encourages."

I don't expect us to get to this this sprint anymore, so I'll move it to the next one.

Sorry for leaving things in the bad stated @eecavanna . I can help get the documentation to agree with the current implementation, or work together with you to go back to your previous implementation, as long as it works on MacOS and Linux.

Moving to next sprint as I will be out of the office tomorrow (sprint ends tomorrow).

@turbomam and I discussed this today. I will remove him as an assignee and open a PR that updates the documentation.

I opened a PR that resolves this issue: https://github.com/microbiomedata/nmdc-schema/pull/1854


move exp utilities and forward model to database generation

📋 Info
move exp utilities and forward model to database generation

Was this done in #169? If so, can this be closed? @lindamegner

yes it seems I duplicated the issue


FanzyZone new zone editor is unintuitive to merge zones

📝 Provide a description of the new feature
_What is the expected behavior of the proposed feature?  What is the scenario this would be used?
I'm not sure wheather better instructions would help or a redesign but the current zone editor is really hard to understand.
I was dragging the lines trying to merge and couldn't figure out how to merge. Random mouse mashing finally figured it out.
It's also way harder to do exactly a 4 x 4 square which used to be about 1 click (change from 3 to 4).
If you'd like to see this feature implemented, add a 👍 reaction to this post.

behavior hasn't changed, i think we need better helper text.  We also fixed a bug that should enable the ability to do a precision via the custom editor.

For what you're outlining, just click grid and click the + button.

I figured it out but I feel it doesn't make sense for new users and could
be quite confusing.
I didn't notice the grid part, I was clicking the 3 grid which it for some
reason auto changed too, which made weird 2 full screen+2 half screen.
On Tue, 16 Mar 2021, 8:56 am Clint Rutkas, @.***> wrote:

behavior hasn't changed, i think we need better helper text. We also fixed
a bug that should enable the ability to do a precision via the custom
editor.
[image: image]
https://user-images.githubusercontent.com/1462282/111226397-4b532800-859e-11eb-886e-4714e5241f59.png
For what you're outlining, just click grid and click the + button.
[image: image]
https://user-images.githubusercontent.com/1462282/111226547-86edf200-859e-11eb-8954-9abb7e44de07.png
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/microsoft/PowerToys/issues/10230#issuecomment-799781029,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AEFHORUHVXCG63OYQZCVMKTTDZ7APANCNFSM4ZFJNVSQ
.

valid feedback for the +/- for new users.  Solved one problem only to accidently create a different one for a different group of users

Note to clint: change dialog into a few runs, think bullet points,

Splitter: Hold shift for vertical split
Merge/Delete: Click and drag across multiple zones

@niels9001 you think that would be helpful verbiage?

Click zone maybe
On Wed, 17 Mar 2021, 11:07 am Clint Rutkas, @.***>
wrote:

@niels9001 https://github.com/niels9001 you think that would be helpful
verbiage?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/microsoft/PowerToys/issues/10230#issuecomment-800694603,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AEFHORRXN5SXAW5UYNFH5ALTD7XCZANCNFSM4ZFJNVSQ
.

@niels9001 you think that would be helpful verbiage?

@crutkas @enricogior I think the usability issues in the editor keeps coming back across various issues (especially since it has some non-Windows-standard ways of doing things (e.g. press and hold to select).
Would it make sense to explore a different way of enabling these functions? Here's a toolbar idea what would allow you to switch between different "tools" (e.g. horizontal split tool, vertical split tool, merge tool):

@niels9001
for sure it will help discoverability, we can still keep options like using shift to switch splitter orientation to avoid having to use the toolbar each time (that would be frustrating).

@niels9001
for sure it will help discoverability, we can still keep options like using shift to switch splitter orientation to avoid having to use the toolbar each time (that would be frustrating).

Oh yes agree, they would act almost as 'shortcuts'. Might also help for any future tools/settings to that might get added.

This bug handles easy fix, #10292 will handle more complex fix

very niceeeeeeee

long text verified

PR now open

This has been resolved in the 0.35 release.  https://github.com/microsoft/PowerToys/releases/latest


Change mde to use accelerator and device

[ ] Closes #xxxx (Replace xxxx with the GitHub issue number)
[ ] Tests added and passed if fixing a bug or adding a new feature
[ ] All code checks passed.
[ ] Added type annotations to new arguments/methods/functions.
[ ] Added an entry in the latest docs/release_notes/index.md file if fixing a bug or adding a new feature.
[ ] If the changes are patches for a version, I have added the on-merge: backport to x.x.x label.

Do you have any idea whether pyMDE is compatible with TPU and other specialized hardware?

I believe it should work as long as a hardware-compatible version of PyTorch is installed. I'm not sure how well PyTorch supports TPU though.


Stand Alone Widget Deployment

What?
Widget index.js has been improved. In addition to its current properties, developers can use this generator to create widgets in any folder location. This allows developers the flexibility to use the centralized widget templates without the extra requirement of having additional environmental setup such as a preconfigured task runner.
How?
When a user runs
yo esri-appbuilder-js:widget
The code assess the current root project for a  .yo-rc.json file. If it finds one it will continue to use the predefined properties currently utilized in the generator. If it doesn't, it will ask the user for a place to store the widgets. It will then offer the same options to the user when presented with initial project creation.
Why?
This use case has been generated to allow the creation of widgets inside a project that utilities docker and gulp. The project wanted to use the benefits of the generator without the restrictions of the initial project outlay. I felt it would be a useful low impact addition.

thanks for the contribution @mlewis22!

It looks like you've included a commit that includes the "Theme generator" in this PR. Could you please modify this branch (or maybe create a new branch/PR) that contains only the code changes related to this PR (Stand Alone Widget Deployment)
Looks like there are some unit test failures. Please run npm run test on the code and either fix the failures or update the unit tests whee applicable.

Sorry - I thought i was clever and moved it into a different branch. I forgot about the test! (Bad person). Ill take a look and put a new pull.

@gavinr -- updates to the code and readme so tests are now passing


hidden mansion ghosts don't enter dying state

on the hidden mansion the ghosts are now going down to zero but not getting sucked up.

I'm puzzled by this, I didn't tough ghost harming in the commits to the hotfixes.
Are you perhaps in a developmental build (commit pushed here, but no release)?

I downloaded the update you did last. but I had to restart the last time cause I don't know how to overwrite the old save

So version 1.3; and it worked fine in 1.2 per #41.

yeah

I always seem to find new issues when I get to the hidden mansion

Could you send me a copy of your world? I can't seem to trigger it in any of the releases when loading in the hidden mansion.

How do I send you my world?

Upload it somewhere (eg mediafire, dropbox or google drive), and send me the link

I downloaded the update you did last. but I had to restart the last time cause I don't know how to overwrite the old save

BTW, how to do this is explained in the installing and notes.txt

yeah sorry it's taking a long time I'm uploading it to google drive

It’s fixed it’s self I just reloaded the hidden mansion

Hmmm, odd...


How to upload image to server?

I Liked the lib but there is no clear documentation about how we can upload images (UIImage ) to the server. It only shows how we can download it
Thanks,
Nitin

Hey - this could be implemented in a third party API since there's so much stuff to an image upload function (API params, authentication, HTTP headers, buffering, etc etc)

No I am saying How can we send UIImage object to https since your point was not to convert image into base64

Yes, we are talking about the same thing. In this case you will have to upload a binary stream, or base64. But there currently is no API for this, this needs to be implemented.

I think it would be out of scope of this library to handle upload. We need to give Turbo modules and Fabric some time to mature. Ideally, I'd see a flavour of Expo uploadAsync made to handle JSI image, but Expo still haven't implemented Fabric or Turbo modules.


test: Cypress - Fix flaky tests

Description
Fixed below flaky tests

BindButton_Text_WithRecaptcha_spec.js
pagesize_spec.js

Type of change

Flaky test fix

How Has This Been Tested?

Cypress test runs

Checklist:
QA activity:

[ ] Test plan has been approved by relevant developers
[ ] Test plan has been peer reviewed by QA
[ ] Cypress test cases have been added and approved by either SDET or manual QA
[ ] Organized project review call with relevant stakeholders after Round 1/2 of QA
[ ] Added Test Plan Approved label after reveiwing all Cypress test

/ok-to-test sha=cc60a32

/ok-to-test sha=cc60a32


[boost-multiprecision] missing dependency

Describe the bug
Tried to compile simple program with boost-multiprecision and compiler complains about missing boost/math/tools/complex.hpp file
Environment

OS: Windows 10
Compiler: MSVC 19

To Reproduce
Steps to reproduce the behavior:

vcpkg install boost-multiprecision:x64-windows
Add boost to CMakeLists: find_package(Boost REQUIRED); target_link_libraries(Test PRIVATE Boost::boost)
include boost multiprecision header in a simple hello world program
Compile: fatal error C1083: Cannot open include file: 'boost/math/tools/complex.hpp'

Expected behavior
compile successfully
Additional context
Everything works after manually installing boost-math
vcpkg install boost-math:x64-windows

@remz1337, thanks for reporting this issue! I have submitted a PR to fix it.


Duplicate Country names in Data

From looking at the 'COVID-19 Growth Rate Prediction' dashboard I see there are multiple entries in the dataset for the same countries. For example there is: 'United Kingdom' and 'United Kingdom (total)'. The first one appears to be the correct one, while the second one has different much smaller numbers. Is this a bug or does it have a different meaning in the dataset (e.g. deaths)?
In the plot for growth rates in 'COVID-19 Growth Rate Prediction' the wrong 'United Kingdom' entry is used.
Thank you, and excellent job on this project!

this has been fixed


add return value check when calling sensor_i2c_close, fixed #1553

To prevent potential failure, we need to add return value check.
Signed-off-by: yilu.myl<EMAIL_ADDRESS>

感谢提交 Pull Requests！
Thanks for submitting a pull request.

Security Check : ab78a4353510fe605569a659d5137b2babdc2303

auto build fail,number:64

auto build fail,number:64

start build

手动触发！
感谢 Pull Requests！
Thanks for submitting a pull request.

Security Check : 888e7169220163057dcc9eda762296c11a53e1d9

auto build success,number:66

autotest success,number:1130


Rerename and Publish v0.1.0

@JuliaRegistrator register

Registration pull request created: JuliaRegistries/General/115565
Tip: Release Notes
Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.
@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.
Tagging
After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.
This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:
git tag -a v0.1.0 -m "<description of version>" 4f5af0e12c4497c4bcf57eb2b0c05c196cf21bd6
git push origin v0.1.0


cargo-apk: Reimplement "default" subcommand trailing args for cargo with -- separator

clap does not currently support parsing unknown arguments into a side Vec, which is exactly what cargo apk -- needs to parse a few known cargo arguments (such as --target and -p) but forward the rest verbatim to the underlying cargo subcommand.
allow_hyphen_values = true could partially help us out with this, but it parses all remaining arguments into that Vec upon encountering the first unknown flag/arg, resulting in all known flags after that to also be treated as "unknown" instead of filling up our args: Args struct.
Since a workaround for this isn't currently functioning, introduce pure trailing args with an additional -- separator to make it clear which arguments go to cargo-apk (and are almost all, except --device, forwarded to cargo) and which are only passed to cargo <subcommand>.

CC @epage for seeing if we can do something about this :)
CC @kchibisov as I'd like to release cargo-apk with this soon-ish, and will make sure to add the -- separator to winit beforehand for testing.

Fwiw the main reason I dislike this approach is because users may (accidentally) pass cargo-apk-supported arguments after the -- so that they are still passed to the underlying cargo invocation but not to cargo-apk itself, leading to either unexpected or outright broken behaviour :(
(For example cargo apk -- doc --device "xyz" -- --no-deps -p my-crate would confuse cargo-apk, as the -p has to sit before the second --; and at the same time --device isn't actually passed to cargo doc :sweat_smile:)

Realizing the original issue in winit 1 2 won't easily be solvable with this as it currently uses a generic env var to invoke cargo $CMD doc for every target, which we'd have to extend with a custom if: target == android where the arguments supported by cargo-apk are separated out from rustdoc specific args with a --.

Another thought is that we "just migrate winit CI to xbuild", @dvc94ch is that something you can help with time-wise?
Then I'll release cargo-apk with this workaround for now while we look for a more proper solution (or not at all, pending #260 deprecation).

@dvc94ch they do, by (ab)using cargo apk -- to run generic doc/test commands, but nothing else (no build, and clippy is ran globally).
Specifically, since our migration to clap we limit what arguments can be passed to cargo through apk -- and their passing of --no-deps and --document-private-items breaks it currently, hence this PR.
But then I think we may want to skip that doc step entirely?

It seems that cargo doc doesn't need to go through cargo apk -- doc at all, so that's one case solved: https://github.com/MarijnS95/winit/compare/ci-android
Now only cargo test with more unrecognized args remains....

Looks like it's not something xbuild intended to do. To check if the tests compile wouldn't cargo ndk do the job? I could add a cargo command x cargo that would work similar to the cargo ndk tool.

@dvc94ch it might be good for xbuild to support this so that we - again - have one shared codebase that takes care of NDK detection and env-var setup. (Un...)fortunately xbuild uses clap too so it'll suffer from the same parsing "tangle". I think the current PR is "the best we can do" as any alternative is tricky.
I don't want to defer to cargo-ndk as it is known to significantly lag behind NDK compatibility, and has released broken updates after merging in dubious external contributions (at risk of sounding like a broken record: that wouldn't have been a problem if it _Just Used ndk-build™).

Sorry didn't have time this weekend. Had some family stuff on Friday and Saturday and then had to some work today to compensate for Friday. I can look into it towards the end of next week

@dvc94ch No worries, we all have exactly that (plus lots of opensource / hobby projects to care about).
In any case I applied this change to winit to have more visibility into how the API is going to end up breaking.

@msiglreith perfect, thanks! I'll start the release train tomorrow morning :steam_locomotive:!

Haven't researched how you actually use clap, just wanted to quickly note how (I think) cargo-dinghy is doing it, for inspiration:
cargo dinghy --device=... --any-other-dinghy-commands-here run --release --other-normal-cargo-commands-here

(Note that dinghy flags must come before the invoked subcommand (run, build, ...), while any cargo flag always must come after).

@madsmtm looks like dinghy uses quite a complex setup to filter out known args from unknown args?
https://github.com/sonos/dinghy/blob/87463fec2df24bc01c98817b26f8b04c4ec007fa/cargo-dinghy/src/cli.rs#L108-L154
This is what I wanted to avoid and/or have implemented in some way in clap, though maybe @epage is interested in how the ecosystem is tackling this.

(Note that dinghy flags must come before the invoked subcommand (run, build, ...), while any cargo flag always must come after).

Fortunately we do not currently support any arguments before the subcommand, though at some point #[clap(global = true)] arguments may be nice (for e.g. --device).

In other words, @madsmtm would you like to see us implementing something along these lines instead of committing to -- separator "ugliness" (see also additional user-unfriendly complexity https://github.com/rust-windowing/winit/pull/2561)? cargo-apk may be on a deprecation path but xbuild uses clap too and I think it'll all transfer over neatly.

In other words, @madsmtm would you like to see us implementing something along these lines instead of committing to -- separator "ugliness"

I don't have much of an opinion on this, honestly didn't know dinghy's approach was that complicated.
Would be nice though to my eyes if every cargo extension did it in roughly the same way, whichever way that may end up being.

@madsmtm definitely!

(Note that dinghy flags must come before the invoked subcommand (run, build, ...), while any cargo flag always must come after).

Getting back to this, with a slight modification this logic actually/easily starts working with mixed arguments, which is what I originally wanted to have :tada:
(otherwise, why not use trailing_var_arg = true, allow_hyphen_values = true in cargo-dinghy which kicks in as soon as clap sees the first unknown argument...).
I'll push this after lunch and see if it works without the proposed invasive change in winit, thanks so much for pointing this out to me @madsmtm! If you need I can port it back to dingy, made some improvements along the way too :)

And it actually works out for winit without separating out any of the original arguments https://github.com/rust-windowing/winit/actions/runs/3523743875 (disregard MSRV failures)!
Here's a short run-down of what I did and found:
First up the code from dinghy inspired me on this possible implementation, but dingy seems to have some unnecessary complexity that I do not yet understand. As mentioned above by @madsmtm and from this bit of code I gather it's collecting args for cargo as soon as encountering the first thing it doesn't recognize, that isn't a positional argument. Furthermore, initially it considers any arg that starts with - to be a valid, known option even it isn't, leading this to feel like an incomplete trailing_var_arg = true, allow_hyphen_values = true implementation...
Then, for what the implementation does here:

Assuming (and validated by assert!) that our Args doesn't have positionals, it's pretty trivial to introspect clap for what short/long flags are accepted by Args, and filter them out with some basic logic;

only complication I can think of is when a value-taking argument in the cargo subcommand has a value that it also recognized as a cargo-apk arg and consumed out of the list, e.g. rustc --link-arg --quiet ..., but those should be rare and I don't know if = is required instead of a space, nor how clap deals with that;

Added a bunch of tests that mix and match value-taking args and flags, including unknown ones;
By keeping args: Args in the subcommand, all these fields are documented in cargo apk -- -h. Clap keeps moving all mixed args starting from the first unrecognized arg into cargo_args thanks to trailing_var_arg = true, allow_hyphen_values = true, which my logic later separates out and appends to existing args inside args: Args via update_from_arg_matches();

I did not get to add a test-case for this as it'd end up quite verbose with having to parse a full Cmd and match on the nested subcommands.

@MarijnS95 sorry the current winit ci won't work with xbuild. that's not what xbuild is for. If you want to build a gui application or game then you can build/deploy it with xbuild. To test that something compiles for a specific target while respecting all the cargo flags is a different story. I doubt this is acceptable to you, but you could just set RUSTFLAGS="-C linker=echo" and test that it compiles. If you want to detect an ndk and set all the flags and support c compilation etc etc there are two options.

you need a complex tool with lots of edge cases that often behaves unexpectedly
you build your own cli interface with well defined semantics that are not dependent on cargo an then you need to give up some features that are supported by cargo

after picking 1. when building cargo-apk I decided to go with 2. for xbuild. the advantage of 2. is that I'm confident that whatever the combination of cli arguments you provide to xbuild it actually does what it's supposed to.

the other alternative is to just hack it for the winit build, probably also unacceptable:
-C linker=clang -C link-arg=-fuse-ld=lld -L/opt/android-ndk/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/lib/aarch64-linux-android/33 -C link-arg=-B/opt/android-ndk/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/lib/aarch64-linux-android/33 -C link-arg=--target=aarch64-linux-android

@dvc94ch That is fine then, we can look for alternatives by e.g. setting up winit's CI build in such a way that it either builds an APK target or not rely on the NDK compiler/linker.
However, this also means I'm not yet ready to deprecate cargo-apk straight away. I also don't think cargo-apk "often behaves unexpectedly" (I leave that to cargo-ndk thank you), nor is there currently any viable alternative.
Regardless, the fixes have been merged and released, so we can build on this for some time. I'll just have to backport some features to xbuild now to make it work for my case again (workspace inheritance :cold_sweat:).

just fyi "often behaves unexpectedly" this looks like a quote and I never said those words :)

You are right that cargo-apk and anything else is still in catch-up phase to support everything cargo does; not only on the cmdline but also while parsing Cargo.toml manifests, .cargo/config.toml configuration, environment variables and the likes. There's no way to fix this proper other than explicitly not supporting things, or making such tools first-class cargo extensions with a (very tricky to design) carefully crafted API where cargo and the extension work together to achieve whatever is needed. Effectively we and many other projects need a way to run "post build steps" in a super fancy way while also influencing the build system directly.

just fyi "often behaves unexpectedly" this looks like a quote and I never said those words :)

https://github.com/rust-windowing/android-ndk-rs/pull/363#issuecomment-1328075684

you need a complex tool with lots of edge cases that often behaves unexpectedly

...
after picking 1. when building cargo-apk

Take it back, I did say those words hahha

But I think the main point I was trying to make is valid. xbuild is not a cargo replacement and the fact that it uses cargo is an internal implementation detail as far as the user is concerned. Similar like cargo doesn't allow passing arbitrary rustc flags. Yes I know there's RUSTFLAGS and cargo rustc so you can usually somehow manage to do what you were trying to do.


Only Add Public Posts to Feed

if private post made in the homepage, post will be added into feed, but reloading the page, private post is not there. (same with unlisted) maybe not add post to feed depending on the type of post it is, depending on if we want to have those private/unlisted post on the homepage if it corresponds to the current loggedinuser

Done, fixed by #180.


[tool_crash] ArgumentError: Invalid argument(s): Cannot find executable for /Users/cvdtc/Library/Android/sdk/build-tools/30.0.2/aapt.

Command
flutter --no-color run --machine --track-widget-creation --device-id=9585865a --start-paused --dart-define=flutter.inspector.structuredErrors=true lib/main.dart

Steps to Reproduce

...
...
...

Logs
ArgumentError: Invalid argument(s): Cannot find executable for /Users/cvdtc/Library/Android/sdk/build-tools/30.0.2/aapt.
#0      _getExecutable (package:process/src/interface/local_process_manager.dart:127:5)
#1      LocalProcessManager.runSync (package:process/src/interface/local_process_manager.dart:94:30)
#2      _DefaultProcessUtils.runSync (package:flutter_tools/src/base/process.dart:419:51)
#3      new AndroidApk.fromApk (package:flutter_tools/src/application_package.dart:120:33)
#4      AndroidApk.fromAndroidProject (package:flutter_tools/src/application_package.dart:173:27)
<asynchronous suspension>
#5      ApplicationPackageFactory.getPackageForPlatform (package:flutter_tools/src/application_package.dart:47:32)
#6      FlutterDevice.runHot (package:flutter_tools/src/resident_runner.dart:520:56)
<asynchronous suspension>
#7      HotRunner.run (package:flutter_tools/src/run_hot.dart:368:31)
#8      _rootRunUnary (dart:async/zone.dart:1198:47)
#9      _CustomZone.runUnary (dart:async/zone.dart:1100:19)
#10     _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
#11     Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
#12     Future._propagateToListeners (dart:async/future_impl.dart:725:32)
#13     Future._completeWithValue (dart:async/future_impl.dart:529:5)
#14     _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:40:15)
#15     _completeOnAsyncReturn (dart:async-patch/async_patch.dart:311:13)
#16     ResidentRunner.runSourceGenerators (package:flutter_tools/src/resident_runner.dart)
#17     _rootRunUnary (dart:async/zone.dart:1198:47)
#18     _CustomZone.runUnary (dart:async/zone.dart:1100:19)
#19     _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
#20     Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
#21     Future._propagateToListeners (dart:async/future_impl.dart:725:32)
#22     Future._completeWithValue (dart:async/future_impl.dart:529:5)

[✓] Flutter (Channel stable, 1.20.3, on Mac OS X 10.15.6 19G2021, locale en-ID)
    • Flutter version 1.20.3 at /Users/cvdtc/Developer/flutter
    • Framework revision 216dee60c0 (4 weeks ago), 2020-09-01 12:24:47 -0700
    • Engine revision d1bc06f032
    • Dart version 2.9.2

[!] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at /Users/cvdtc/Library/Android/sdk
    • Platform android-30, build-tools 30.0.2
    ✗ Android SDK file not found: /Users/cvdtc/Library/Android/sdk/build-tools/30.0.2/aapt.
    • Try re-installing or updating your Android SDK,
      visit https://flutter.dev/docs/get-started/install/macos#android-setup for detailed instructions.

[✓] Xcode - develop for iOS and macOS (Xcode 11.5)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 11.5, Build version 11E608c
    • CocoaPods version 1.9.3

[✓] Android Studio (version 4.0)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 49.0.2
    • Dart plugin version 193.7547
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[✓] Connected device (1 available)
    • Redmi Note 9 Pro (mobile) • 9585865a • android-arm64 • Android 10 (API 29)

! Doctor found issues in 1 category.

Flutter Application Metadata
Type: app
Version: 1.0.0+1
Material: true
Android X: false
Module: false
Plugin: false
Android package: null
iOS bundle identifier: null
Creation channel: stable
Creation framework version: 216dee60c0cc9449f0b29bcf922974d612263e24
Plugins
firebase_core-0.5.0
firebase_core_web-0.2.0
firebase_messaging-7.0.0
flutter_plugin_android_lifecycle-1.0.8
local_auth-0.6.3+1
path_provider-1.6.14
path_provider_linux-0.0.1+2
path_provider_macos-0.0.4+3
shared_preferences-0.5.10
shared_preferences_linux-0.0.2+2
shared_preferences_macos-0.0.1+10
shared_preferences_web-0.1.2+7

@msaprojects
There's similar open issue describing your case, 54418.
Please follow-up there for updates.
Closing this as duplicate.


doc: update Rust version compatibility

Which issue does this PR close?

Closes #.
Rationale for this change
Updates the Rust version compatibility section to point to minimum supported Rust version exact value

What changes are included in this PR?

Are these changes tested?

Are there any user-facing changes?

Related to https://github.com/apache/arrow-datafusion/pull/8997

oops!


Ability to restore Eth Identity from without Signer

import path from "path";
import ODBKeystore from "orbit-db-keystore";
import Identities from "orbit-db-identity-provider";

const account = accounts[0];
const odbIdentitykeysPath = path.join("./orbitdb", "identity", "identitykeys");
const keystore = new ODBKeystore(odbIdentitykeysPath);
// if account exist in IDB: restore else sign
const identity = await keystore.hasKey(account)
    ? await Identities.createIdentity({
        type: "orbitdb",
        id: account,
    })
   : await Identities.createIdentity({
        type: "ethereum",
        wallet: provider.getSigner(),
    });

https://github.com/orbitdb/orbit-db-identity-provider/blob/main/src/identities.js#L58-L64 to be clear the create works fine, the problem is when i want to restore my identity, actually in the code in my case i want "identityProvider.getId" as Ethereum but i want "identityProvider.signIdentity" as Orbitdb.
Because if a wallet is not specified when he getId as ethereum, he create a new one and return the new one https://github.com/orbitdb/orbit-db-identity-provider/blob/main/src/ethereum-identity-provider.js#L18
And giving the id like that as createIdentity param, I dont need this transformation as orbitdb https://github.com/orbitdb/orbit-db-identity-provider/blob/main/src/orbit-db-identity-provider.js#L26

I'm certainly wrong, I can't restore the identity without asking for the signature after refreshing the page


Display error when devicePixelRatio is 3.5

Is there an existing issue for this?

[X] I have searched the existing issues
[X] I have read the guide to filing a bug

Steps to reproduce
As shown in the code and video，the rendering error resulted in unexpected blank lines. A reasonable conclusion at present is that the product of devicePixelRatio and size is not an integer, causing this error.
Hope this problem can be solved soon.
Expected results
Displayed correctly
Actual results
Display Error
Code sample
Code sample
class ListTest extends StatelessWidget {
  const ListTest({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: _buildBody(),
    );
  }

  Widget _buildBody() {
    return Row(
      children: [
        Expanded(
          child: ListView(
              scrollDirection: Axis.horizontal,
              children: List.filled(
                  10,
                  Container(
                    width: 41,
                    height: 99,
                    color: randomColor(),
                    alignment: Alignment.center,
                    child: Text("${window.devicePixelRatio}"),
                  ))),
        )
      ],
    );
  }
}

Screenshots or Video

Screenshots / Video demonstration
https://github.com/flutter/flutter/assets/22394343/54d532db-7e01-4c33-a73c-2bfc66ccaa3a

Logs
Logs
[Paste your logs here]

Flutter Doctor output
Doctor output
[Paste your output here]

A reasonable conclusion at present is that the product of devicePixelRatio and size is not an integer, causing this error.

@Bigniuql
The documentation says the same. This number might not be a power of two. Indeed, it might not even be an integer. For example, the Nexus 6 has a device pixel ratio of 3.5. Check the same and see if it helps in your case or not.

window.devicePixelRatio

Can you provide what Flutter version are you on ? I verified the code sample on latest stable (3.13.6) in which, the window property is deprecated.

You may try with the newer version and check if using it, you get same behavior or not.

Check the same and see if it helps in your case or not.

Thanks. My Flutter version is 3.3.2, i will have a try with the latest version

A reasonable conclusion at present is that the product of devicePixelRatio and size is not an integer, causing this error.

@Bigniuql The documentation says the same. This number might not be a power of two. Indeed, it might not even be an integer. For example, the Nexus 6 has a device pixel ratio of 3.5. Check the same and see if it helps in your case or not.

window.devicePixelRatio

Can you provide what Flutter version are you on ? I verified the code sample on latest stable (3.13.6) in which, the window property is deprecated.

You may try with the newer version and check if using it, you get same behavior or not.

I verified with the version 3.13.6, but the problem still exists.
Code is as below:
class MyHomePage extends StatelessWidget {
  const MyHomePage({super.key, required this.title});

  final String title;

  @override
  Widget build(BuildContext context) {
    return Scaffold(
        appBar: AppBar(
          backgroundColor: Theme.of(context).colorScheme.inversePrimary,
          title: Text(title),
        ),
        body: Center(
          child: Column(mainAxisAlignment: MainAxisAlignment.center, children: [
            Expanded(
              child: ListView.builder(
                itemBuilder: (context, index) {
                  return Container(
                    width: double.infinity,
                    color: Colors.blueAccent,
                    alignment: Alignment.center,
                    child: Text("${View.of(context).devicePixelRatio}"),
                  );
                },
                itemCount: 10,
                itemExtent: 100,
              ),
            )
          ]),
        ));
  }
}

When i use realme X7 Pro:
https://github.com/flutter/flutter/assets/22394343/ddb59b36-194e-43c3-a6f8-a32dae05844c
When i use Honor magic 5 Pro:
https://github.com/flutter/flutter/assets/22394343/b2470dc3-d8d0-461b-9a67-1d975b8ca184
Now i think the point of this issue is not the device pixel ratio or size, the phenomenon may be common.And not only ListView, Flex also has this issue.

Thanks for the update. I believe you are hitting below similar issues in which you can follow-up for further updates:
Antialiasing behaviour when same-colour  #14288
https://github.com/flutter/flutter/issues/22056
Closing this issue as a duplicate.


v0.2.0

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 79.856%

Totals

Change from base Build<PHONE_NUMBER>:
0.0%

Covered Lines:
95

Relevant Lines:
111

💛  - Coveralls


Create agile-experiments-in-machine-learning.md

Talk proposal

Thanks @mathias-brandewinder :+1:


Does Shuttle support crontab?

Not officially, but it should be possible to add a custom cron service. Docs for creating a custom service should be coming out soon

Closed in favor of #909


Add bit about upgrade project.md

Please add/change if inaccurate.

If the project depends on Mathlib and the old version of lake is able to parse the new lakefiles of all dependencies, then this happens automatically, IIUC. Maybe this should be mentioned, because in most cases nothing has to be done by the user.

@fpvandoorn You mean it's not necessary to lake update, just change lean-toolchain?

I only was talking about manually updating lean-toolchain.

I don't think these instructions are very good, users don't have to directly interact with elan themselves. I added my own version here: #487 487

No problem. I don't have much experience with lean. I'm glad that you are taking over, and that there will be good instructions on that page. Closing.

Thanks for taking the initiative in writing these instructions. They were indeed needed!


chore: expose open and onOpenChange props to DatePicker component

After this discussion here https://github.com/huntabyte/bits-ui/discussions/388, it turns out that the open prop was not being exposed, ergo, couldn't bind to it for programmatic control.
This P.R exposes it and the onOpenChange function.
If there's something else you wish added/removed, please let me know.

Would you mind adding a test for the functionality to ensure it doesn't get regressed in the future? There are similar tests for programmatic openings (I believe) that you could likely copy over!

I actually considered doing this, but somehow decided not to - sorry.
I'll definitely add these in a few hours.
This can be kept open if you want, or I can P.R another.
Thanks.


Feature/timeseries chart

Local testing looks good. Just one points from local testing:

[ ] The mouse to data point association isn't as good as it was before (in the old graph). In the old graph the nearest dot was always on the line that was next to the mouse pointer. In the new graph it is the nearest point to the marker line, which makes it very difficult to get to some data points in the graph. Well, this is not related to this ticket. So maybe we should consider to open a bug issue for this.


Drop support for 3ds Max 2017

That might unlock some code simplifications, this should be checked.

See commit ffce9652808662b0c8b13f9ae8cf0def71271074

Done.


Streaming responses in diff editor (w/ linter) needlessly inefficient

Which API Provider are you using?
Anthropic
Which Model are you using?
Claude 3.5 Sonnet
What happened?
It would be much more efficient if the content was streamed without VS.Code constantly trying to diff and lint it.
Steps to reproduce

have cline read and write an existing file
see the model changes being streamed (and VS.Code struggling to lint/diff it)

Relevant API REQUEST output
No response
Additional context
No response

No thanks. Get a faster linter. This is obviously not a Cline problem.

@pietz thanks for your thoughtful comment and suggestion. I beg to disagree; linting, syntax highlighting, and diffing code that's being streamed is not adding any value to cline or its users. It's 100% a cline issue. If you enjoy seeing your CPU being used for no reason at all you've got many other options.

I use ruff in python, which is written in Rust and I just have zero of the issues you mention. Cline only works with files with less than 300 lines of code well, so it can't take up that much compute.
I like linting while generating. I can see immediately if it uses a function that doesn't exist, which is the number one problem I encounter.
I believe I'm entitled to my opinion here and I would like this feature to stay.

Of course. We're all entitled to our opinion, that's my point—as a response to your 'get a faster linter' suggestion.
First of all: What you're stating you care about is not linting, it's diffing.
More generally: You may have misunderstood the point: I wasn't suggesting disabling linting, syntax highlighting or diffing when viewing the generated output and comparing it with the existing version of the code. That's absolutely necessary. I'm only suggesting disabling it during the streaming phase, i.e. when the content is constantly changing while being streamed. Once it's done, you should be able to get everything enabled.

I personally dislike the streaming "feature".  I totally agree with @cosmix on the issue of the editor struggling and bouncing around through the streaming phase.  I much prefer the original approach that just displayed the diff when it was complete.
Despite the streaming being far too erratic to provide any value what-so-ever, regrettably, it's probably a "feature" that's here to stay.  Best we could hope for is a configuration option to disable it.  However, at this stage of Cline's development there seems to be a reluctance towards adding option settings.

Yea, a third or fourth here.
I can't even figure out what "streaming" does. I'm not sure if it's broken, or it's just not making sense to me. I'm coming from WS, trying to switch to Cline as WS clearly is having some major issues that seem token throttling related.
In Cline, throwing it at a file with 2000 lines, a fairly complex chunk of code, but one that WS managed to refactor prefectly on the first try on day three after launch, Cline with Sonnet 3.5 also manages to get the correct answer on the first try, but absolutely can't implmement it, despite burning $10 on tokens trying to suss out what's actually going wrong. It can tell me the precise line numbers where it's going to put the modified code (in a single try). It can show me that code, but when it comes to implementation in the editor, it completely cacks out, scrolling slowly through the entire file, 1 line at a time, removing every single line that is not related to our updated code, then it adds the first bit of the code it was going to add, then just stops. No option to accept or reject, and it's LOOKING (10 minutes later) like it's trying to remove 1800 lines of the 2000 lines of code.
Reading through other peoples experiences as of a week or two ago, this didn't seem to be the case, but since the streaming feature was added, there are quite a few people complaining it just doesn't work at all, or is enormously inefficient. I definitely agree with the latter. I don't need to see it scanning each line one by one, highjacking my entire IDE for 10 minutes, to fail for $0.50 in tokens each time.


Audio Extraction from video (python)

Title and Issue number
Using Python, we extract audio from a video file by importing the MoviePy library
Input Video:
https://github.com/pranjay-poddar/Dev-Geeks/assets/74114936/413188a7-3ea9-43f7-a81a-668a9a62be16
Output:

Output Audio(saved in the folder):

Close #4709

Checklist:

[x] I have mentioned the issue number in my Pull Request.
[x] I have commented my code, particularly in hard-to-understand areas
[x] I have created a helpful and easy to understand README.md

@MohitGupta121 @TusharKesarwani can you please review and merge this pr, thanking you in advance


pip install -e . fails

During setup
Exception:
Traceback (most recent call last):
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_internal/req/req_install.py", line 483, in check_if_exists
    self.satisfied_by = pkg_resources.get_distribution(str(no_marker))
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py", line 468, in get_distribution
    dist = get_provider(dist)
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py", line 344, in get_provider
    return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py", line 888, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py", line 779, in resolve
    raise VersionConflict(dist, req).with_context(dependent_req)
pip._vendor.pkg_resources.ContextualVersionConflict: (numpy 1.15.1 (/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages), Requirement.parse('numpy<=1.14.5,>=1.13.3'), {'tensorflow'})

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_internal/basecommand.py", line 141, in main
    status = self.run(options, args)
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_internal/commands/install.py", line 299, in run
    resolver.resolve(requirement_set)
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_internal/resolve.py", line 102, in resolve
    self._resolve_one(requirement_set, req)
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_internal/resolve.py", line 256, in _resolve_one
    abstract_dist = self._get_abstract_dist_for(req_to_install)
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_internal/resolve.py", line 193, in _get_abstract_dist_for
    req, self.require_hashes, self.use_user_site, self.finder,
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_internal/operations/prepare.py", line 329, in prepare_editable_requirement
    req.check_if_exists(use_user_site)
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_internal/req/req_install.py", line 494, in check_if_exists
    self.req.name
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py", line 468, in get_distribution
    dist = get_provider(dist)
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py", line 344, in get_provider
    return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py", line 888, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages/pip/_vendor/pkg_resources/__init__.py", line 779, in resolve
    raise VersionConflict(dist, req).with_context(dependent_req)
pip._vendor.pkg_resources.ContextualVersionConflict: (numpy 1.15.1 (/Users/bendecoste/anaconda3/envs/tf-encrypted/lib/python3.6/site-packages), Requirement.parse('numpy<=1.14.5,>=1.13.3'), {'tensorflow'})

I think this is a problem with your environment. You have numpy 1.15.1 installed but tf-encrypted requires less than 1.14.5. Should probably do stuff in a new environment. Or maybe we should accept any version of numpy?!

Hey @vishwajit123. We've recently implemented a custom operation for tensorflow so that we can securely generate random numbers. This custom operation is written in C++ so it must first be built when you're installing tf-encrypted for development. This is hinted at by the error here:
Exception: Could not find the secure random shared object for the installed tensorflow version 1.11.0

So a secure random shared object needs to be built first for your installed version of tensorflow. Before digging deeper into this issue it'd be great to know if you were able to get this shared object built. You can usually find it in the tf-encrypted/tf_encrypted/operations/secure_random/ folder and will look something like secure_random_module_tf_1.11.0.so.

Glad you got it figured out! Cheers!


"SA1649: File name must match first type name." fix "Rename file to match first type name" will delete and add new file instead of just renaming the file which breaks TFS version control server file history

"SA1649: File name must match first type name." fix "Rename file to match first type name" will delete and add new file instead of just renaming the file which breaks TFS version control server file history.
Test.cs
namespace TestApp
{
    public class MyTest // SA1649: File name must match first type name.
    {
    }
}

Produces warning "SA1649: File name must match first type name." as expected.
However, if I let DotNetAnalyzers fix this by selecting "Rename file to match first type name" from the list of potential fixes, Test.cs shows up as deleted and MyTest.cs shows up as added in Visual Studio's "Pending Changes" window.
In contrast, if I just manually rename the file in the "Solution Explorer" window, the file shows up as rename in Visual Studio's "Pending Changes" window.
If I go ahead and check in the changes performed by DotNetAnalyzers, then I cannot view the history on the new file in TFS; whereas the history is maintained if I check in the changes performed when manually renaming the file.
Visual Studio 2015 Update 3
DotNetAnalyzers 1.0.0
TFS 2015 Update 3
Thank you.

Marking this blocked because there is no proper document rename API in Roslyn to achieve this behavior.
dotnet/roslyn#6261was filed for this.

Any news on this?

Looks like something like this might work (although I have not actually tried it):
Microsoft.CodeAnalysis.Rename.Renamer.RenameDocumentActionSet actionSet =
    await Microsoft.CodeAnalysis.Rename.Renamer.RenameDocumentAsync(
        document,
        newDocumentName,
        newDocumentFolders: null,
        optionSet: null,
        cancellationToken).ConfigureAwait(false);
solution = await actionSet.UpdateSolutionAsync(solution, cancellationToken).ConfigureAwait(false);

But this is only available in later Roslyn versions. I feel unsure about how to add "light up" support for this in a good way. Compiling expression trees does not sound fun, due to the return type Task<Microsoft.CodeAnalysis.Rename.Renamer.RenameDocumentActionSet>. Generate source code and compile it at runtime?

This same problem also causes the file to be closed when applying the fix.


Falco does not properly start after upgrade

Using apt, when upgrading Falco, the last few versions does not start up again after a completed upgrade. The service remains stopped.
The following packages will be upgraded:
  falco
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/2 876 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n]
Reading changelogs... Done
(Reading database ... 120936 files and directories currently installed.)
Preparing to unpack .../falco_0.11.1_amd64.deb ...

-------- Uninstall Beginning --------
Module:  falco
Version: 0.11.0
Kernel:  4.9.0-5-amd64 (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

falco-probe.ko:
 - Uninstallation
   - Deleting from: /lib/modules/4.9.0-5-amd64/updates/dkms/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod...

DKMS: uninstall completed.

-------- Uninstall Beginning --------
Module:  falco
Version: 0.11.0
Kernel:  4.9.0-7-amd64 (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

falco-probe.ko:
 - Uninstallation
   - Deleting from: /lib/modules/4.9.0-7-amd64/updates/dkms/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod...

DKMS: uninstall completed.

------------------------------
Deleting module version: 0.11.0
completely from the DKMS tree.
------------------------------
Done.
Unpacking falco (0.11.1) over (0.11.0) ...
Setting up falco (0.11.1) ...
Loading new falco-0.11.1 DKMS files...
Building for 4.9.0-5-amd64 4.9.0-7-amd64
Building initial module for 4.9.0-5-amd64
Done.

falco-probe:
Running module version sanity check.
 - Original module
   - No original module exists within this kernel
 - Installation
   - Installing to /lib/modules/4.9.0-5-amd64/updates/dkms/

depmod...

DKMS: install completed.
Building initial module for 4.9.0-7-amd64
Done.

falco-probe:
Running module version sanity check.
 - Original module
   - No original module exists within this kernel
 - Installation
   - Installing to /lib/modules/4.9.0-7-amd64/updates/dkms/

depmod...

DKMS: install completed.
Processing triggers for systemd (232-25+deb9u4) ...
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

I get a Slack notification when the service is stopped and started (sudo service falco start/stop), but when upgrading, I am only notified of it being stopped. When logging on the server later to check, it is indeed still stopped.
12:49 [root@server ~]# service falco status
● falco.service - LSB: Falco syscall activity monitoring agent
   Loaded: loaded (/etc/init.d/falco; generated; vendor preset: enabled)
   Active: inactive (dead) since Wed 2018-08-01 12:45:55 CEST; 4min 43s ago
     Docs: man:systemd-sysv-generator(8)

aug. 01 12:45:55 server systemd[1]: Stopping LSB: Falco syscall activity monitoring agent...
aug. 01 12:45:55 server systemd[1]: Stopped LSB: Falco syscall activity monitoring agent.
Warning: Journal has been rotated since unit was started. Log output is incomplete or unavailable.

Manually running sudo service falco start starts the service back up without issues.
To be fair I thought maybe this was handled automatically by systemd, but I only have this problem with Falco at the moment.
Servers are running Debian 9.5.

Had the same thing happen now with the 0.12.1 version of Falco

I wonder if this is the same cause as https://github.com/falcosecurity/falco/issues/418. The transition from 0.11.1 to 0.12 included an incompatible kernel module change, so it's possible that falco crashed after the new install because it was trying to use the already-loaded old kernel module.
I know this was a while back, but are you still experiencing this problem and if so could you check /var/log/messages to see if falco had a segfault?

A bit too far for the log archives I'm afraid as the messages.log have been rotated and I can't find anything older than early October.
I guess I will see with version 0.12.2 or 0.13.0 (whichever is first) :slightly_smiling_face:

/usr/lib/dkms/dkms_autoinstaller start

Still happening now with the upgrade to 0.13.0. Tried running the dkms_autoinstaller command first on one server as well, but this had no effect. Falco remains stopped after kernel modules have been installed.

did you confirm the old kernel module is indeed removed and the new version loaded?

@mfdii The un-upgraded servers do appear to be running the 0.12.1 version, if I am not entirely mistaken. The contents of /var/lib/dkms/falco is:
drwxr-xr-x 4 root root 4096 sep.  17 12:59 0.12.1
lrwxrwxrwx 1 root root   27 sep.  17 12:59 kernel-4.9.0-7-amd64-x86_64 -> 0.12.1/4.9.0-7-amd64/x86_64
lrwxrwxrwx 1 root root   27 sep.  17 13:00 kernel-4.9.0-8-amd64-x86_64 -> 0.12.1/4.9.0-8-amd64/x86_64

While on one of the upgraded servers it is:
drwxr-xr-x 3 root root 4096 nov.  12 10:34 0.13.0
lrwxrwxrwx 1 root root   27 nov.  12 10:34 kernel-4.9.0-8-amd64-x86_64 -> 0.13.0/4.9.0-8-amd64/x86_64

I might also add that no sefaults were spotted in /var/log/messages during the upgrade.

Output from terminal when upgrading one of the servers to 0.13.0 tonight:
21:33 [root@server /tmp]# apt install falco
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
  falco
1 upgraded, 0 newly installed, 0 to remove and 43 not upgraded.
Need to get 0 B/3 125 kB of archives.
After this operation, 503 kB of additional disk space will be used.
Reading changelogs... Done
(Reading database ... 115797 files and directories currently installed.)
Preparing to unpack .../falco_0.13.0_amd64.deb ...

-------- Uninstall Beginning --------
Module:  falco
Version: 0.12.1
Kernel:  4.9.0-5-amd64 (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

falco-probe.ko:
 - Uninstallation
   - Deleting from: /lib/modules/4.9.0-5-amd64/updates/dkms/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod....

DKMS: uninstall completed.

-------- Uninstall Beginning --------
Module:  falco
Version: 0.12.1
Kernel:  4.9.0-8-amd64 (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

falco-probe.ko:
 - Uninstallation
   - Deleting from: /lib/modules/4.9.0-8-amd64/updates/dkms/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod....

DKMS: uninstall completed.

------------------------------
Deleting module version: 0.12.1
completely from the DKMS tree.
------------------------------
Done.
Unpacking falco (0.13.0) over (0.12.1) ...
Setting up falco (0.13.0) ...
Installing new version of config file /etc/falco/falco_rules.yaml ...
Installing new version of config file /etc/falco/rules.available/application_rules.yaml ...
Installing new version of config file /etc/falco/falco_rules.local.yaml ...
Loading new falco-0.13.0 DKMS files...
Building for 4.9.0-8-amd64
Building initial module for 4.9.0-8-amd64
Done.

falco-probe:
Running module version sanity check.
 - Original module
   - No original module exists within this kernel
 - Installation
   - Installing to /lib/modules/4.9.0-8-amd64/updates/dkms/

depmod...

DKMS: install completed.
Processing triggers for systemd (232-25+deb9u4) ...

As you also can see from the beginning there, the module version was 0.12.1 before upgrading.
/var/log/messages after/during the upgrade:
Nov 13 21:33:46 server kernel: [2672998.045889] falco_probe: deallocating consumer ffff96777ff93000
Nov 13 21:33:46 server kernel: [2672998.071596] falco_probe: no more consumers, stopping capture

Then a minut pause until I manually start it with service falco start:
Nov 13 21:34:53 server falco: Falco initialized with configuration file /etc/falco/falco.yaml
Nov 13 21:34:53 server falco: Loading rules from file /etc/falco/falco_rules.yaml:
Nov 13 21:34:53 server falco: Loading rules from file /etc/falco/falco_rules.local.yaml:
Nov 13 21:34:53 server falco: Loading rules from file /etc/falco/rules.d/local.yaml:
Nov 13 21:34:54 server kernel: [2673065.527547] falco_probe: adding new consumer ffff9677889af100
Nov 13 21:34:54 server kernel: [2673065.527598] falco_probe: initializing ring buffer for CPU 0
Nov 13 21:34:54 server kernel: [2673065.535927] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.535928] falco_probe: initializing ring buffer for CPU 1
Nov 13 21:34:54 server kernel: [2673065.544242] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.544243] falco_probe: initializing ring buffer for CPU 2
Nov 13 21:34:54 server kernel: [2673065.552423] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.552425] falco_probe: initializing ring buffer for CPU 3
Nov 13 21:34:54 server kernel: [2673065.560346] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.560348] falco_probe: initializing ring buffer for CPU 4
Nov 13 21:34:54 server kernel: [2673065.568472] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.568473] falco_probe: initializing ring buffer for CPU 5
Nov 13 21:34:54 server kernel: [2673065.575993] falco_probe: CPU buffer initialized, size=8388608

If you do a dmesg | grep falco do you see the 0.13.0 kernel module being loaded? If not do a rmmod falco-probe && modprobe falco-probe

On Nov 13, 2018, at 12:39 PM, Alexander Karlstad<EMAIL_ADDRESS>wrote:
Output from terminal when upgrading one of the servers to 0.13.0 tonight:
21:33 [root@server /tmp]# apt install falco
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
falco
1 upgraded, 0 newly installed, 0 to remove and 43 not upgraded.
Need to get 0 B/3 125 kB of archives.
After this operation, 503 kB of additional disk space will be used.
Reading changelogs... Done
(Reading database ... 115797 files and directories currently installed.)
Preparing to unpack .../falco_0.13.0_amd64.deb ...
-------- Uninstall Beginning --------
Module:  falco
Version: 0.12.1
Kernel:  4.9.0-5-amd64 (x86_64)
Status: Before uninstall, this module version was ACTIVE on this kernel.
falco-probe.ko:

Uninstallation

Deleting from: /lib/modules/4.9.0-5-amd64/updates/dkms/

Original module

No original module was found for this module on this kernel.
Use the dkms install command to reinstall any previous module version.

depmod....
DKMS: uninstall completed.
-------- Uninstall Beginning --------
Module:  falco
Version: 0.12.1
Kernel:  4.9.0-8-amd64 (x86_64)
Status: Before uninstall, this module version was ACTIVE on this kernel.
falco-probe.ko:

Uninstallation

Deleting from: /lib/modules/4.9.0-8-amd64/updates/dkms/

Original module

No original module was found for this module on this kernel.
Use the dkms install command to reinstall any previous module version.

depmod....
DKMS: uninstall completed.

Deleting module version: 0.12.1
completely from the DKMS tree.
Done.
Unpacking falco (0.13.0) over (0.12.1) ...
Setting up falco (0.13.0) ...
Installing new version of config file /etc/falco/falco_rules.yaml ...
Installing new version of config file /etc/falco/rules.available/application_rules.yaml ...
Installing new version of config file /etc/falco/falco_rules.local.yaml ...
Loading new falco-0.13.0 DKMS files...
Building for 4.9.0-8-amd64
Building initial module for 4.9.0-8-amd64
Done.
falco-probe:
Running module version sanity check.

Original module

No original module exists within this kernel

Installation

Installing to /lib/modules/4.9.0-8-amd64/updates/dkms/

depmod...
DKMS: install completed.
Processing triggers for systemd (232-25+deb9u4) ...
As you also can see from the beginning there, the module version was 0.12.1 before upgrading.
/var/log/messages after/during the upgrade:
Nov 13 21:33:46 server kernel: [2672998.045889] falco_probe: deallocating consumer ffff96777ff93000
Nov 13 21:33:46 server kernel: [2672998.071596] falco_probe: no more consumers, stopping capture
Then a minut pause until I manually start it with service falco start:
Nov 13 21:34:53 server falco: Falco initialized with configuration file /etc/falco/falco.yaml
Nov 13 21:34:53 server falco: Loading rules from file /etc/falco/falco_rules.yaml:
Nov 13 21:34:53 server falco: Loading rules from file /etc/falco/falco_rules.local.yaml:
Nov 13 21:34:53 server falco: Loading rules from file /etc/falco/rules.d/local.yaml:
Nov 13 21:34:54 server kernel: [2673065.527547] falco_probe: adding new consumer ffff9677889af100
Nov 13 21:34:54 server kernel: [2673065.527598] falco_probe: initializing ring buffer for CPU 0
Nov 13 21:34:54 server kernel: [2673065.535927] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.535928] falco_probe: initializing ring buffer for CPU 1
Nov 13 21:34:54 server kernel: [2673065.544242] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.544243] falco_probe: initializing ring buffer for CPU 2
Nov 13 21:34:54 server kernel: [2673065.552423] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.552425] falco_probe: initializing ring buffer for CPU 3
Nov 13 21:34:54 server kernel: [2673065.560346] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.560348] falco_probe: initializing ring buffer for CPU 4
Nov 13 21:34:54 server kernel: [2673065.568472] falco_probe: CPU buffer initialized, size=8388608
Nov 13 21:34:54 server kernel: [2673065.568473] falco_probe: initializing ring buffer for CPU 5
Nov 13 21:34:54 server kernel: [2673065.575993] falco_probe: CPU buffer initialized, size=8388608
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

I can't say there are any specific messages regarding loading/unloading the kernel module in dmesg no:
[ti. nov. 13 21:34:50 2018] falco_probe: deallocating consumer ffff96777ff93000
[ti. nov. 13 21:34:50 2018] falco_probe: no more consumers, stopping capture
[ti. nov. 13 21:35:57 2018] falco_probe: adding new consumer ffff9677889af100
[ti. nov. 13 21:35:57 2018] falco_probe: initializing ring buffer for CPU 0
[ti. nov. 13 21:35:57 2018] falco_probe: CPU buffer initialized, size=8388608
[ti. nov. 13 21:35:57 2018] falco_probe: initializing ring buffer for CPU 1
[ti. nov. 13 21:35:57 2018] falco_probe: CPU buffer initialized, size=8388608
[ti. nov. 13 21:35:57 2018] falco_probe: initializing ring buffer for CPU 2
[ti. nov. 13 21:35:57 2018] falco_probe: CPU buffer initialized, size=8388608
[ti. nov. 13 21:35:57 2018] falco_probe: initializing ring buffer for CPU 3
[ti. nov. 13 21:35:57 2018] falco_probe: CPU buffer initialized, size=8388608
[ti. nov. 13 21:35:57 2018] falco_probe: initializing ring buffer for CPU 4
[ti. nov. 13 21:35:57 2018] falco_probe: CPU buffer initialized, size=8388608
[ti. nov. 13 21:35:57 2018] falco_probe: initializing ring buffer for CPU 5
[ti. nov. 13 21:35:57 2018] falco_probe: CPU buffer initialized, size=8388608
[ti. nov. 13 21:35:57 2018] falco_probe: initializing ring buffer for CPU 6
[ti. nov. 13 21:35:57 2018] falco_probe: CPU buffer initialized, size=8388608
[ti. nov. 13 21:35:57 2018] falco_probe: initializing ring buffer for CPU 7
[ti. nov. 13 21:35:57 2018] falco_probe: CPU buffer initialized, size=8388608
[ti. nov. 13 21:35:57 2018] falco_probe: starting capture

Looking back in dmesg to October 14 I do see a driver loading message:
[sø. okt. 14 00:05:05 2018] falco_probe: loading out-of-tree module taints kernel.
[sø. okt. 14 00:05:05 2018] falco_probe: driver loading, falco-probe 0.12.1

rmmod falco_probe && modprobe falco_probe did not work, but stopping falco, then modprobing did. So now i see:
[ti. nov. 13 21:59:29 2018] falco_probe: driver unloading
[ti. nov. 13 21:59:58 2018] falco_probe: driver loading, falco-probe 0.13.0

This is still happening though, in Debian. When apt-get upgradeing to 0.17.0 now it stopped Falco but never started it up again.


sync_events: Parse the to-device events.

This obviously depends on https://github.com/ruma/ruma-events/commit/12d725113baa40d9004c36235f82ee4050547bee. Not sure how we handle these cross-repo features, but here is a PR.

We could temporarily set ruma-events to a git dependency, changing it back to a crates-io dependency once a new release is made. But often it's fine to just release before merging related PRs. I'm about to release ruma-events 0.17.0.

The new ruma-events is released and ruma-client-api has been updated to it. I renamed StrippedState to AnyStrippedStateEvent before the release, so this PR has to be updated for that too. But then it's good to be merged. :)


Feature: Release History

🔖 Feature description
Rollouts of software distribution hubs needs a single place to track all the execution history.
🎤 Pitch / Usecases
With Software distribution Hub we can rollout our software releases to multiple tenant environments. However, there isn't any option see the deployment / execution history at one place for that rollout.
🔄 Alternative
User can check deployment histories of all applications part of that release and figure out relevant informations
👀 Have you spent some time to check if this issue has been raised before?

[X] I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

[X] I have read the Code of Conduct

AB#9933

Fixed with attached PR


Implement fallback for getting UAttributes from payload if MQTT5 is not supported

This fix enables using MQTT3.1 messages and still building a full UMessage from the MQTT message. This is particularly important for enabling UProtocol on systems that run threadX beacuse there is currently no MQTT5 capable client that runs on it.

@ValMobBIllich I created https://github.com/eclipse-uprotocol/up-spec/issues/251, can you comment on it so I can assign the ticket to you?
Thanks.

If I understand correctly, if we have MQTT3.1, the entire uMessage is in the payload including the attributes correct? This looks fine to me but you need to push an update to the spec as well to match this change.

Yes! The sender would be required to serialize the UMessage according to the proto definition, then put the serialized byte array into the payload of their mqtt message and send it.
Enforcing MQTT5 compliance would be more elegant but at least on the threadX chips it would require an mqtt client that supports the full MQTT5 spec which currently doesnt seem to exist.

Hey @ValMobBIllich -- would you like to consider using CloudEvents as suggested here?


ConversationalRetrievalChain Vectorstore cannot apply filter to a key with given multiple values

System Info
on Ubuntu with Python 3.11.5, Langchain 0.0.307
Who can help?
@hwchase17
Information

[ ] The official example notebooks/scripts
[X] My own modified scripts

Related Components

[ ] LLMs/Chat Models
[ ] Embedding Models
[ ] Prompts / Prompt Templates / Prompt Selectors
[ ] Output Parsers
[ ] Document Loaders
[X] Vector Stores / Retrievers
[ ] Memory
[ ] Agents / Agent Executors
[ ] Tools / Toolkits
[ ] Chains
[ ] Callbacks/Tracing
[ ] Async

Reproduction
What my code basically does is returns an answer to a given question using conversational retrieval chain with a qdrant vectorstore that stores publications. I want the chain to use only the documents published in specified years.

Create vectorstore
qdrant_client = QdrantClient(QDRANT_HOST, port=int(QDRANT_PORT))
retriever = Qdrant(client=qdrant_client, collection_name=QDRANT_COLLECTION, embeddings=get_encoder(ENCODER))

Create chain:
rag_chain = ConversationalRetrievalChain.from_llm(llm=llm,
retriever = retriever.as_retriever(search_kwargs={"filter": {"year": ["2009","2010"]}),
return_source_documents=return_source_documents,
verbose=verbose)

When I run the chain it retrieves no documents even though it should.

Expected behavior
The chain should return documents related to a given question. When I checked the implementation of qdrant.py under langchain vectorstores I saw that _qdrant_filter_from_dict function makes a "must" match; however in my case I need a "should" match since no document can have more than one publication date.

@muge-birlik  You should be able to pass a qdrant filter directly. Something like this
from qdrant_client.conversions.common_types import Filter as Filter
from qdrant_client.models import Filter, FieldCondition, Range
f = Filter(
should=[
FieldCondition(....)
]
)
....
retriever = retriever.as_retriever(search_kwargs={"filter": f, return_source_documents=return_source_documents,
verbose=verbose)
Let me know if this works.

@sudranga I tried to come up with proof of concept according to your suggestion as such:
If I understood how Langchain vectorstore library works behind the scenes correctly
rag_chain.retriever.search_kwargs={"filter": {"year": ["2009"]}}
above line should produce the same result as the following code snippet
    from qdrant_client.conversions.common_types import Filter as Filter
    from qdrant_client.http import models
    from qdrant_client.models import Filter, FieldCondition, Range

    f = Filter(
        must=[
            models.FieldCondition(
                key="year",
                match=models.MatchValue(value="2009")
            )
        ]
    )

    rag_chain.retriever.search_kwargs={"filter": f}

But it does not. While the regular way of adding filters produces correct results using Filter object doesn't work. Do you think I am doing something wrong?
Thank you for your response.

@sudranga you were right! It works.
The problem with my previous message was totally because of the structure of my payload.


Transparent ball+stick disappears behind transparent cartoon

Here is a CodePen example.
I set two representation: a white cartoon for the protein and a ball+stick for ligand. Both have alpha transparency, with opacity: 0.5.
Observed behaviour:

the ligand completely disappears behind the transparent cartoon
the cartoon is visible behind the cartoon (OK, *)
if you rotate you will see that the transparent cartoon is visible behind the ligand (OK)

Expected behaviour:

the ligand should still be visible behind the transparent cartoon
and 3 are as expected

Additional comments:

Setting the ligand's opacity to 1.0 will make it "re-appear" behind the cartoon, however as soon as it is below (I tested with 0.99) it is hidden.
'line' representations show the same problem as ball+stick.

* Actually, if you set the rotation to o.setRotation([0, 1.3, 1]);, you may notice that the cartoon that is right in front of the scene seems to be hiding a bit of the cartoon too, however it isn't quite as obvious.

Sadly, NGL does not support multi layer transparency. You can try to get a desired effect by setting depthWrite: false on representations. However that will result in other artifacts, but it is often ok when the transperency is not too low.


Add file dialog sample

You can read more about the File Dialog APIs here.
Fixes: #3225

Copied the manifest code from one of the other samples.


Is there a better way to represent optional file properties?

Currently, I'm stuck doing this:
private fun <T : FileSystemLocation> Provider<T>.optional() =
        flatMap { project.objects.fileProperty().apply { set(it.asFile.orNull()) } }

However, I lose the task dependency information with that.

Note to self: this lets me get rid of dependsOn(resourceDir)

I can't quite tell how you're intending to use this.  Can't you just put @Optional on a RegularFileProperty and not set it?
Our community Slack or the forums might be a better place to ask this question.

Sorry, yeah, my issue was super unclear. It's basically the same as #2016 but for Providers.
Say I need to configure something based on what's in a folder. If the folder isn't there, I don't do anything. But if it is, I need to do stuff. Since the folder doesn't change and isn't configurable by the user, I want the property to always be set. However, that doesn't work with Gradle's model since it'll freak out if the file isn't there.
So the question is: can you easily get the property and null it out based on some condition?


Refresh homepage

Yesterday we discussed kicking off a couple Esprima website improvements. I think the homepage could be revisited.
One aspect I'd like the homepage to do a bette job with would be education. A lot of people in the JS community are learning about ASTs for the first time and it would be nice if they could have a better idea of how a program maps to an AST and maybe even CST.
To that effect, I put together a wireframe of an interactive component that could be on the landing page. The boxes below are placeholders for additional content. I intentionally left everything else vague so as to not get lost in the details.

FWIW, I built http://astexplorer.net/. Happy to talk about integration opportunities if you are interested. Either way I'm curious what you come up with on the educational side!

@fkling nice tool. I coud definitely see that being useful.

And there's a cst PR in astexplorer in progress https://github.com/fkling/esprima_ast_explorer/pull/38

Thanks @hzoo following the discussion

Oh and I guess I'l see you at that open source workshop later? Maybe can get some contributors to help out here

@hzoo great! Let's definitely pair on this Sunday. I'll be ramping up on the AST explorer to prep

Also let me know how I could help! E.g. we could have a minimal version of the astexplorer, without toolbar and fixed parser, which could then be embedded (iframe) into the the page.
Or we could create a JS API for the astexplorer, which would give you more control over where / how to render / embed it, and let you interact with it programmatically.

we could have a minimal version of the astexplorer, without toolbar and fixed parser, which could then be embedded (iframe) into the the page.

@fkling That sounds like the simplest thing to do and of course you're second idea is more powerful if we want to extend it - Maybe we just need to brainstorm more about how it could work and how it can teach people about ASTs?

Maybe we just need to brainstorm more about how it could work and how it can teach people about ASTs?

Definitely. In theory, astexplorer would support different visualizations of the code / ast in the right hand panel. The challenge is to come up with a visualization / representation that "teaches" somehow.
And of course this is only one part of the teaching. Documentation (which is probably outside of astexplorer's scope) is another big part.

https://github.com/estree/estree should help with that. There's https://github.com/estree/estree/issues/66 (examples) and I started a PR for it

we could have a minimal version of the astexplorer, without toolbar and fixed parser, which could then be embedded (iframe) into the the page.

@fkling ideally, we would be able to require it as an NPM module and customize how it is shown. In our case it would be an editor / visualizer.

Maybe we just need to brainstorm more about how it could work and how it can teach people about ASTs?

Embedded documentation is a great idea. Esprima has lots of demos as well. Ideally the homepage would surface the demos as different use cases for an AST powered tool.

ideally, we would be able to require it as an NPM module and customize how it is shown.

Sounds good to me. If you have any concrete ideas about the API, let me know.

Embedded documentation is a great idea.

You mean into the visualization? Do you have any concrete ideas? At some point I though about showing little (i) icons next to a node, but wasn't sure what kind of information to put there.

For visualizations, I'd like to take a crack at the the flamechart / tree view inside of the AST Explorer at some point. I think it could give a good birds eye view.

That would be awesome!

It seems that AST Explorer already establishes itself as an AST exploration tool for power users. I doubt that we need to radically change Esprima homepage, nor its simplistic parser demo. So @jasonLaster, unless you have a concrete plan to work on this, I'd rather not keep this issue open for an indefinite time. What do you think?

@ariya I'm fine closing it. I'd like to get to it at some point but this ticket isn't necessary.


Implement unit tests for utility functions Labels

The utils.py file contains several utility functions that currently lack unit tests. We need to create comprehensive unit tests to ensure these functions work correctly and to prevent future regressions.
Approach to fix:

Create a new file test_utils.py in the tests directory.
Import the necessary functions from utils.py.
For each function, create multiple test cases covering different scenarios.
Use the pytest framework for writing and running tests.
Ensure all tests pass and achieve good code coverage.

Can you Assign this issue to me.

@NikhilJ2005 go ahead

Can you assign this issue to me?


Pyroscope configuration options

The PR is aimed to improve documentation:

We had some issues re persistence setup (e.g https://github.com/pyroscope-io/pyroscope/issues/350). Although the documentation is correct, in some corner cases it may lead astray. Therefore I clarified use of podSecurityContext.fsGroup parameter.
I believe, at this point it's better to omit default pyroscope configuration, as it's extended quite often and may confuse users.

Besides, pyroscope version has changed from 0.0.34 to 0.0.37.

I think after we release the next version it should allow us to use 0.0.40 instead of 0.0.37 here (@petethepig fixed bug with loading config file)

LGTM!

@kolesnikovae can we update to most recent version of Pyroscope now?

@Rperry2174 I've asked @kolesnikovae to not update it, since I want to try running renovate against this repo.


bug: can skip account execute and validate

The current implementation does not enforce that a transaction has to be send to a contract account du to the skip of the validation if the transaction entrypoint != __execute__. This means a transaction can just be send without any validation to any contract as long as the entrypoint != __execute__. This means contracts could be DDOS'ed by spamming transactions to them and make them pay transactions fees.
Below is a simple example of calling the inc entry for a counter contract, directly from the counter contract. Can share the whole code if needed but basically just sends a transaction straight to the counter contract, making him pay for the fees and increasing its count.
// Given
let mut state = State::default();
let context = block_context();
let mut sequencer = Sequencer::new(context, state);

// When
let transaction = Transaction::InvokeFunction(
    InvokeFunction::new(
        TEST_CONTRACT,
        field_element_to_felt(&selector!("inc")),
        1_000_000,
        Felt252::from(1),
        vec![],
        vec![],
        CHAIN_ID,
        Some(Felt252::zero()),
    )
    .expect("Failed to create transaction"),
)
.create_for_simulation(false, false, true, false, false); // skip fee transfer because sequencer is not deployed.
sequencer.execute(&transaction).unwrap();

// Then
let expected = Felt252::from(1u8);
let actual = sequencer
    .state
    .get_storage_at(&(
        TEST_CONTRACT.clone(),
        get_storage_var_address("counter", &[])
            .unwrap()
            .to_be_bytes(),
    ))
    .unwrap();
assert_eq!(expected, actual);

Hi @greged93 !!
thanks for the issue, we are checking it and try it to replicate it

If you need me to send the whole test set up let me know, I can push it on our repo if needed.


Work for nvdla master branch?

Hi, Thanks for your great work first!
I would like to ask if your code is also worked for nvdla master branch( nv_small or nv_large specifically)?
Thanks

Hi,
Any update on this, as I need input.txn files for nv_small. Is it possible to get it following the same procedure given for nvdla1?


des.DesKey() cannot operate with variables.

This has to do with the Bytes Literal Prefix, in which case it probably should be something on Stack Overflow. Do you know how to make the 'b' prefix work with user-inputted variables? Take this for example:
from des import DesKey x=input("Key?") abc123=DesKey(x)
That would return with an error saying:
Traceback (most recent call last):
File "<pyshell#2>", line 1, in
abc123=DesKey(x)
File "C:\Users\miraj\AppData\Local\Programs\Python\Python37-32\lib\site-packages\des\base.py", line 21, in init
self.__encryption_key = guard_key(key)
File "C:\Users\miraj\AppData\Local\Programs\Python\Python37-32\lib\site-packages\des\base.py", line 75, in guard_key
assert isinstance(key, bytes), "The key should be bytes or bytearray"
AssertionError: The key should be bytes or bytearray
Please tell us a way to combine variables with the byte prefix.

In your example, x is a string. And as the error message suggests, the DesKey() requires an object of type byte or bytearray. So what you need to do is convert x to an object of the required type.
The following code would work for you:
from des import DesKey

x = input()  # x is a string
x = x.encode()  # x is a byte object
key = DesKey(x)


OneDrive SDK does not support notifications (toast+tile) for background transfers

I would suggest to trigger an event just after the creation of a Background task (download and/or upload). This could allow developers to set advanced options for the just-created background task (e.g., FailureTileNotification, SuccessTileNotification).
For example in the file CreateBackgroundDownloadOperation.cs, the method OnExecute() could be:
protected async override void OnExecute()
{
[...]
var downloader = new BackgroundDownloader();
if (this.LiveClient.OnCreateBackgroundDownloader!=null) {
this.LiveClient.OnCreateBackgroundDownloader(this.LiveClient, this.Url, downloader);
}
[...]
}

Thanks for the suggestion we are not looking to add enhancements to the Windows LiveSDK at this time.  However; I will gladly review pull requests.


Background feed refresher makes current article scroll to top

Newsbeuter version 2.9 on a Mac:
Steps to reproduce the issue:

To make this quicker to reproduce, set reload-time 1 in ~/.config/newsbeuter/config.

Open newsbeuter and start reading an article, moving down a few pages into it.

Wait, and when the reload happens the article you're reading will reload out from under you and jump back to the beginning, losing your place.

Oops, I see this repo is abandoned and the new one resides at https://github.com/newsboat/newsboat


What URL path will this run at?

[ ] Do we need to add a /tigerdata (or something else?) path
[ ] Do we need to take over the domain name tigerdata.princeton.edu on our load balancer and point it at another location for the top domain and to our application for the directory name?

After conversing with Operations, it looks like the best course of action would be not to host this application under a subdirectory of the tigerdata.princeton.edu domain.  I'll work with Matt to come up with a URL path we should use.

Thank you!


Dummy PR to test Coveralls coverage threshold

Coverage decreased (-36.5%) to 59.312% when pulling 1e8fc7d30919d62bd120fec7bc7193a29fdb0667 on coverage-test into d370a2ae792c3877a3b98745ec815646ad476538 on master.