Meta-Issue: SEO

This largely depends on having a 'default metadata profile' (the stuff of legends!), but we should be shipping with the metatag module and an assortment of its profile specific modules for things like AMP support, twitter/facebook embedding, etc...
https://www.drupal.org/project/metatag
We should also provide xml sitemap capabilities, as they have proven invaluable in 7.x development.
https://www.drupal.org/project/simple_sitemap
That sweet sweet SEO juice should be an out-of-the-box feature for CLAW.

@dannylamb I've been playing around with these modules and feel like I've got a pretty good handle on them and how they could be used for Islandora 8. Both modules should work out of the box with custom content types.
How do we proceed with this? I could write up documentation for how to configure them. I could also try to export some example configurations for islandora_demo but that would require making these modules a dependency. How do we feel about that?

Google Scholar also prefers for IRs to have access to lists of all content published in a certain year, which we accomplished in 7.x by having a basic page with links to canned Solr searches. Not sure if this would be a good thing to do programmatically in 8.x or just mention it in documentation.
Another option would be to create some sort of islandora_seo module that requires simple_sitemap and metatag, and it could even included a setup checklist (using the Checklist API and Tour). We've talked about doing something similar with Scholar (not wanting to lose the name recognition of Scholar but also not wanting to build a mega-package) to make it more of an "IR Starter Kit" that points to other generic modules instead of a rabbit hole of related functionality.

I like @bryjbrown's suggestion of making this a separate islandora_seo module that can be pulled in or forked as necessary.

:+1: to decoupling from the metadata profile if possible.  If you can throw up some default or demo config, I'd love to see it.
Also,

Google Scholar also prefers for IRs to have access to lists of all content published in a certain year, which we accomplished in 7.x by having a basic page with links to canned Solr searches. Not sure if this would be a good thing to do programmatically in 8.x or just mention it in documentation.

The answer you seek is views @bryjbrown

As it currently stands, Islandora 8 Demo uses the RDF mapping to embed RDFa into Repository Item and the Controlled Access Term pages which can be used by search engines (at least Google and Bing) without the need to metatag. However, the typed relations and @type override only apply to the JSON-LD serialization, which means our more granular relationships and types don't appear in the RDFa. (Because the RDF module didn't have any hooks to support this while the JSON-LD module did.)
I can see two possible ways of addressing this:

adding the JSON-LD serialization into our pages so search engines can use it (Bing can use JSON-LD and Google prefers for JSON-LD), OR
duplicating our JSON-LD-based property rewrites as custom metatag module extensions.

P.S. If we pursued pushing the JSON-LD into the HTML page, then we would need to remove the _format=jsonld from the identifier, as per #887, to avoid confusing the search engine as to what the JSON-LD is describing.
P.P.S. Most of the references to Bing suggest JSON-LD is only supported for Schema.org, not Dublin Core (although I can't find anything conclusive) and, as per #1074, we can't really mix Schema.org with Dublin Core without making Google grumpy. So perhaps we need metatag to get our Dublin Core into Bing while using JSON-LD for Google? That feels excessive...

I cannot give enough :+1:'s for option 1.  Scrub _format=jsonld from all the URLs AND make Google happy?  YES PLEASE.

Just checking on this one, has option 1 from @seth-shaw-unlv 's solution been added to the codebase ? This issue remains open but it seems like it may have been resolved here: https://github.com/Islandora/documentation/issues/887

@hachacha. the URLs portion was addressed as you point out. However, I don't believe we add the JSON-LD to the page headers yet.
Further, while I initially thought we could use a src link <script type="application/ld+json" src="https://future.islandora.ca/node/9?_format=jsonld" /> all the examples I've found include the json ld embedded in the script tag like so:
<script type="application/ld+json">
{"@graph":[{"@id":"https://future.islandora.ca/node/9","@type":["http://pcdm.org/models#Object","http://purl.org/coar/resource_type/c_c513"],"http://schema.org/author":[{"@id":"https://future.islandora.ca/user/1"}],"http://purl.org/dc/terms/title":[{"@value":"Grey and White Tabby Kitten","@language":"en"}],"http://schema.org/dateCreated":[{"@value":"2019-06-04T14:46:17+00:00","@type":"http://www.w3.org/2001/XMLSchema#dateTime"}],"http://schema.org/dateModified":[{"@value":"2019-06-05T04:05:52+00:00","@type":"http://www.w3.org/2001/XMLSchema#dateTime"}],"http://purl.org/dc/terms/description":[{"@value":"A worried-looking kitten. ","@language":"en"}],"http://purl.org/dc/terms/created":[{"@value":"2019-04-19","@type":"http://www.w3.org/2001/XMLSchema#string"},{"@value":"2019-04-19","@type":"http://www.w3.org/2001/XMLSchema#date"}],"http://purl.org/dc/terms/extent":[{"@value":"1 item","@type":"http://www.w3.org/2001/XMLSchema#string"}],"http://pcdm.org/models#memberOf":[{"@id":"https://future.islandora.ca/node/7"}],"http://purl.org/dc/terms/type":[{"@id":"https://future.islandora.ca/taxonomy/term/5"}],"http://purl.org/dc/terms/subject":[{"@id":"https://future.islandora.ca/taxonomy/term/27"}],"http://schema.org/sameAs":[{"@id":"https://future.islandora.ca/node/9"}]},{"@id":"https://future.islandora.ca/user/1","@type":["http://schema.org/Person"]},{"@id":"https://future.islandora.ca/node/7","@type":["http://pcdm.org/models#Object"]},{"@id":"https://future.islandora.ca/taxonomy/term/5","@type":["http://schema.org/Thing"]},{"@id":"https://future.islandora.ca/taxonomy/term/27","@type":["http://schema.org/Thing"]}]}
</script>

I don't know how kindly Google will take to simply adding the link as initially suggested.

For the RDM project, we used schema.org Metatag module which converts metatags into JSON-LD i the header.


Updates the ruby generator RubyTypeOf to correctly account for underscores in packages

Prior to this change, when the ruby generator tried to reference an entity that was not part of the same package (or a direct parent package) and the package contains underscores, the result would simply uppercase the first character. It should however uppercase each letter that proceeds an underscore and remove underscores.
i.e.
package my_package.service;

import "my_package/data.proto";

service MyService {
  rpc Test (data.Request) returns data.Response {}
}

Was
   # ...
   rpc :Test, My_package::Data::Request, My_package::Data::Response
   # ...

Should be:
   # ...
   rpc :Test, MyPackage::Data::Request, My_package::Data::Response
   # ...

Thank you for your pull request. Before we can look at your contribution, we need to ensure all contributors are covered by a Contributor License Agreement.
After the following items are addressed, please respond with a new comment here, and the automated system will re-verify.

User @hassox isn't covered by a CLA. They will need to complete the form at https://identity.linuxfoundation.org/projects/cncf

Regards,
The Linux Foundation CLA GitHub bot

Signed

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

@apolcyn Any tips to help get these last few checks passing?

please run tools/buildgen/generate_projects.sh , tools/distrib/clang_format_code.sh , and please fix copyrights until tools/distrib/check_copyright.py passes.
Also, because these testing .proto files are specific to ruby only, can we please move the new testing .proto files to be somewhere under src/ruby/, perhaps under src/ruby/spec/pb/package_with_underscore/checker_spec.rb?
thanks

@apolcyn I am trying to run tools/buildgen/generate_projects.sh and getting the following error:
$ tools/buildgen/generate_projects.sh
Traceback (most recent call last):
  File "src/proto/gen_build_yaml.py", line 75, in <module>
    main()
  File "src/proto/gen_build_yaml.py", line 63, in main
    update_deps(deps_for, look_at, deps_trans, deps_external_trans, True, [])
  File "src/proto/gen_build_yaml.py", line 43, in update_deps
    update_deps(key, imp_proto, deps, deps_external, is_trans, visited)
  File "src/proto/gen_build_yaml.py", line 28, in update_deps
    with open(proto_filename) as inp:
IOError: [Errno 2] No such file or directory: 'grpc/testing/package_with_underscore/data.proto'

It appears that grpc/testing/package_with_underscore/data.proto does exist. I also tried updating the src/proto/gen_build_yaml.py script to help with some debugging, but it doesn't appear my that my changes were actually doing anything. Is there some kind of checkin/build step that I am missing on either of these fronts? Any guidance would be greatly appreciated.

@connorjacobsen the problem is coming from this logic in the src/proto/gen_build.yaml.py, where the script examines proto files that are imported by each proto file.
Change import "grpc/testing/package_with_underscore/data.proto"; to import "src/proto/grpc/testing/package_with_underscore/data.proto"; and this should work (this makes the import path consistent with the rest of the proto files under src/proto.

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

@apolcyn One more for you, I'm now getting this error:
Traceback (most recent call last):
  File "tools/buildgen/mako_renderer.py", line 31, in <module>
    from mako.lookup import TemplateLookup
ImportError: No module named mako.lookup

I pip installed Mako locally, but that didn't seem to do it. Nothing obvious in project docs/issues that would fix it either.

Also, excited that this is almost passing :)

@connorjacobsen for your earlier comment:

I pip installed Mako locally, but that didn't seem to do it. Nothing obvious in project docs/issues that would fix it either.

I'm not sure what the cause is there, but FWIW the test infra that's running that script on kokoro installs it in [https://github.com/grpc/grpc/blob/master/tools/dockerfile/test/sanity/Dockerfile#L86](this way).
But it seems like an issue with mako not being installed. Personally, when running locally outside of docker, I use a python virtualenv and pip install mako for this, which works.
BTW the remaining test failure here is just a C++ formatter error and can be fixed with tools/distrib/clang_format_code.sh

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

@apolcyn I have addressed your comments.
A couple things worth noting:

This spec also has the conditional test that requires both grpc_ruby_plugin and protoc to be available. Is it weird that this new spec (which behaves similarly) is unconditional?
This new test will break if grpc_ruby_plugin or protoc is unavailable.
I am a newb at both bash and make, so I may have done it incorrectly, but it doesn't seem like adding the make grpc_ruby_plugin -j8 actually did anything that changed the test environment. The plugin gets installed by the sudo make install that builds grpc from source, and I had to build protoc from source from the third_party directory. Any guidance you have on that would be useful. I suppose it will also be useful to see how CI responds.
I moved the proto files to the test directory since that's the only place they're being used and it's for a ruby-specific bug fix. Happy to rename or move those protos.

Please let me know what you think about these changes. It also looks like CI is not happy with some of the bazel builds already :/
Of course I am happy to rebase and squash this PR into a single, descriptive commit message once you are happy with it and ready to merge.

[trickle] No significant performance differences

@connor4312  for your questions:

This spec also has the conditional test that requires both grpc_ruby_plugin and protoc to be available. Is it weird that this new spec (which behaves similarly) is unconditional?

This new test will break if grpc_ruby_plugin or protoc is unavailable.

I am a newb at both bash and make, so I may have done it incorrectly, but it doesn't seem like adding the make grpc_ruby_plugin -j8 actually did anything that changed the test environment. The plugin gets installed by the sudo make install that builds grpc from source, and I had to build protoc from source from the third_party directory. Any guidance you have on that would be useful. I suppose it will also be useful to see how CI responds.

I agree that it's odd that the current test is conditional on the plugin and protoc being available, but actually that test is something I would like to change (I would actually like to get both of these tests running under the automated unit test suite). Note that make grpc_ruby_plugin will make both the protoc and the grpc_ruby_plugin executables available under <grpc repo root>/bins/{opt,dbg}/grpc_ruby_plugin and <grpc repo root>/bins/{opt,dbg}/protobuf/protoc, and you should then be able to access those executables from within a subsequent test run (you shouldn't need protoc or the grpc_ruby_plugin to be installed or to be on the PATH). Without running this test the grpc_ruby_plugin built from HEAD, there is just not a good way to make sure that this new change is passing it's test....
Let me know if PR against your branch would be helpful; if so I could get to that by end of week.

@apolcyn Great. I'll take a stab at it today/tomorrow, I think I understand what you're saying and I think I know how to tackle it. Thank you!

[microbenchmarks] No significant performance differences

@apolcyn I think I've successfully done the above. Hopefully it builds.

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

@apolcyn Ready to try running the build again

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

I have a hunch the build step is messed up for dbg mode 🤔
Given that I'm a make newb, any guidance?

I think the failure is coming from the ENV['config'] check. I'm seeing:

Package with underscore protobuf code generation
  should have the same content as created by code generation (FAILED - 1)

Pending: (Failures listed here are expected and do not affect your suite's status)

  1) Ping protobuf code generation protoc || grpc_ruby_plugin missing, cannot verify ping code-gen
     # No reason given
     # ./src/ruby/spec/pb/duplicate/codegen_spec.rb:24

  2) Health protobuf code generation the health service file used by grpc/health/checker protoc || grpc_ruby_plugin missing, cannot verify health code-gen
     # No reason given
     # ./src/ruby/spec/pb/health/checker_spec.rb:28

Failures:

  1) Package with underscore protobuf code generation should have the same content as created by code generation
     Failure/Error: ENV['CONFIG'].present? && ENV['CONFIG'] == 'dbg'

     NoMethodError:
       undefined method `present?' for "dbg":String
     # ./src/ruby/spec/pb/package_with_underscore/checker_spec.rb:19:in `debug_mode?'
     # ./src/ruby/spec/pb/package_with_underscore/checker_spec.rb:27:in `block (2 levels) in <top (required)>'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example.rb:254:in `instance_exec'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example.rb:254:in `block in run'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example.rb:500:in `block in with_around_and_singleton_context_hooks'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example.rb:457:in `block in with_around_example_hooks'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/hooks.rb:466:in `block in run'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/hooks.rb:604:in `run_around_example_hooks_for'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/hooks.rb:466:in `run'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example.rb:457:in `with_around_example_hooks'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example.rb:500:in `with_around_and_singleton_context_hooks'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example.rb:251:in `run'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example_group.rb:628:in `block in run_examples'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example_group.rb:624:in `map'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example_group.rb:624:in `run_examples'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/example_group.rb:590:in `run'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/runner.rb:118:in `block (3 levels) in run_specs'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/runner.rb:118:in `map'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/runner.rb:118:in `block (2 levels) in run_specs'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/configuration.rb:1926:in `with_suite_hooks'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/runner.rb:113:in `block in run_specs'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/reporter.rb:79:in `report'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/runner.rb:112:in `run_specs'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/runner.rb:87:in `run'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/runner.rb:71:in `run'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/lib/rspec/core/runner.rb:45:in `invoke'
     # /usr/local/rvm/gems/ruby-2.1.10/gems/rspec-core-3.7.1/exe/rspec:4:in `<main>'

Finished in 0.03187 seconds (files took 0.23876 seconds to load)

That was a silly boo boo. Sorry about that.

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

sorry for the intermittent review delays. we should be able to get this in to the next release (1.11). The test looks good,m and now passing on mac and linux!
Can you please squash down these commits into just one commit though, before merging? (a git rebase should work).

@apolcyn Squashed!

LGTM. I am just waiting for tests to now run again after the squash (thought they ran earlier)

****************************************************************

libgrpc.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

****************************************************************

libgrpc++.so

     VM SIZE        FILE SIZE
 ++++++++++++++  ++++++++++++++

  [ = ]       0        0  [ = ]

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

Awesome. Let me know if you need anything else on my end!

FYI this was recently pushed in the 1.11.0.pre2 grpc package


(GH-399) Multi-monitor support in Set-TaskbarOptions

Adds support for setting the options for multiple displays in Windows 10.

@HolisticDeveloper Thanks for this PR. Hopefully we can get it merged soon.

@pauby Let me know if I need to take further action. At this point I'm just waiting for you to have bandwidth to review the changes I made.

@holisticdeveloper I'm going to try and take a look at the PR's this weekend.

@HolisticDeveloper Other than the blank lines between the parameter declarations I think we're good to go.

@pauby No problem, I can update that. I was trying to follow the existing style in the script. Are you asking to change (for example):
        [Parameter(ParameterSetName='MultiMonitorOn')]
        [switch]$MultiMonitorOn,
        [Parameter(ParameterSetName='MultiMonitorOn')]
        [ValidateSet('All', 'MainAndOpen', 'Open')]
        $MultiMonitorMode,
        [Parameter(ParameterSetName='MultiMonitorOn')]
        [ValidateSet('Always','Full','Never')]
        $MultiMonitorCombine

to
        [Parameter(ParameterSetName='MultiMonitorOn')]
        [switch]$MultiMonitorOn,

        [Parameter(ParameterSetName='MultiMonitorOn')]
        [ValidateSet('All', 'MainAndOpen', 'Open')]
        $MultiMonitorMode,

        [Parameter(ParameterSetName='MultiMonitorOn')]
        [ValidateSet('Always','Full','Never')]
        $MultiMonitorCombine

Is there a style guide I can reference that would have these and other guidelines, so I can make sure to avoid running into this for future contributions? I didn't see anything in CONTRIBUTING.md that would address it...

@pauby Can you confirm the above example is what you're asking for?

@HolisticDeveloper Apologies for the VERY late reply. That's exactly what I'm looking for. In general the code would follow the existing code. However, we're trying to establish some style guidelines so I'm going to add these to the CONTRIBUTING.md.

@HolisticDeveloper See https://github.com/chocolatey/boxstarter/pull/408 for PR to update some of the guidelines. This is a work in progress so any suggestions welcome.

@pauby As I was going through to update the formatting, I had a couple of extra style questions.

The switch parameters all have the [switch] attribute on the same line as the parameter name. Typically I would expect one attribute per line with the parameter itself on its own line. Which is preferred?
[Parameter(ParameterSetName='lockhide')]
[Parameter(ParameterSetName='locknohide')]
[switch]$Lock,

or
[Parameter(ParameterSetName='lockhide')]
[Parameter(ParameterSetName='locknohide')]
[switch]
$Lock,

There are some inconsistencies in spacing and brace placement with if and switch statements. It seems the most common is to have the opening brace at the end of the line with the if statement. Also, I would typically put spaces around the condition. Please confirm.
Existing code:
if($Lock)
{
    Set-ItemProperty -Path $key -Name TaskbarSizeMove -Value 0
}

Preferred? (note spaces around ($Lock)
if ($Lock) {
    Set-ItemProperty -Path $key -Name TaskbarSizeMove -Value 0
}

Thanks for your questions. To answer:

Switch parameters - I prefer option 2. It takes up more space but is more readable. It should be something else to add to the coding guidelines.

Bracing style - this is actually something we haven't decided on yet. However, option 2 is preferred as spaces are good 😄

Ok, should be good to go with my latest changes then.

@mwallner Can you review this PR when you are free?

@pauby what is the next step?

Awesome work! Thanks for your contribution @HolisticDeveloper !


Some questions about Using Klee for Rust for Linux

I have read your post Using klee on Rust for Linux(part 1). I also keep notice on the project and your post inspires me a lot. But I still have some questions. Since I can found no discussion areas for the post. I put my questions here.

Based on my understanding, the Rust for Linux project is aimed to mitigate the gap between the current situation of Rust and the requirements of kernel development. As I learned from your post, the main problem is aroused by dynamic checks(usually, automatically added by Rust compiler) that will panic the program if the check is not passed. The safety of Rust programs partly relies on these dynamic checks. Verification tools try to eliminate the effects of dynamic checks by two ways: fix check that may fail and remove check that cannot fail. This can be done by an independent verification step before release. Have I got your ideas correctly?
In the subsection Safety checks of section What properties would we like to verify?. You said "if we try to catch the panic, we will risk leaving data in an inconsistent way". I do not know a lot about panic safety. But I guess that leaving data in an inconsistent way indicates a bug that we can avoid if we write codes carefully. Do you mean that this kind of bugs can be easily introduced if we try to handle panics? Therefore trying to handle panics is not a good practice.

Thanks a lot!

Hi Jianfeng Jiang,
Yes, (1) is absolutely right.
The problem referred to in (2) is what to do in a piece of code like this
if the code panics on line 5
unlock(L);
f = open("foo");
p = malloc(100);
q = malloc(100);
if (size >= 65536) panic();
// do something with p and q
free(p);
free(q);
close(f);
lock(L);

At the point where the panic occurs, the lock "L" is unlocked, the file "f"
is open, p and q are allocated.
Our options for what to do when the panic occurs are

Do a proper cleanup by not panicking and, instead, jumping to the first
"free" on line 7.
In other words, do not call panic() or use code that calls panic().

Somewhere higher up the call stack, catch the panic, perhaps print an
error message and continue.
The problem with this is that code higher up the call stack does not
have enough information to clean up the problem before continuing.
It does not have the values of the local variables f, p and q and it
does not know where the panic occurred.
It will leak the objects p and q, leave L unlocked (leading to a
possible deadlock later) and will leave "f" open and therefore inaccessible.
Worse, if the code was part of the way through inserting something into
a linked list (say), the linked list might be corrupted.
The result is that, sometime later, the system will either corrupt data
or deadlock or crash or something like that.

When a panic occurs, reset the entire machine
This avoids the data corruption of option (2) but at the cost of data
loss and loss of service.
Any data not yet saved to disk will be lost.
If another machine relies on the one that you reset, the other
machine may be affected.
(eg if my desktop machine fails, I can't play music in my house)
If the computer is a medical device or controls the car brake system
there is a potential threat to life.
etc.

If the panic is inserted by the compiler (eg array bounds checks) and we
want to avoid (2) and (3),
we could disable those checks in the compiler.
This is not a great option: omitting array bounds checks opens up
security vulnerabilities.

If the panic is inserted by the compiler (eg array bounds checks) and we
want to avoid (2) and (3),
we could do something to convince ourselves that the panic can never
occur.
It would then be ok to leave the checks enabled or to disable the
checks because the checks can
never fail.
We can use testing, fuzzing or some kind of formal verification to
convince ourselves that the panic cannot occur.
What is most likely to happen though is that, out of 1000 checks
inserted by the compiler,

It is clear to the compiler that 900 of them cannot fail - the
compiler deletes the checks
Testing, fuzzing or formal verification finds that 10 of them can
fail - we fix those bugs
A formal verification tool proves that 80 of them cannot fail
We are left with 10 checks that we are unsure about.
For these, we either

rewrite the code to be simpler
or we insert explicit checks with proper cleanup code around it
(this is often enough to persuade the compiler
or verification tool that the compiler-inserted check cannot
fail).
or we increase the amount of code review and testing used on that
part of the code.
In this case, it is useful to document these checks very
carefully to explain why we think the check cannot fail.

In short, the only safe options are (1) and (5): don't use panic in code we
write and work very hard to show that any compiler-inserted checks cannot
fail.
I hope that makes sense?
--
Alastair
On Thu, Sep 2, 2021 at 6:23 AM Jianfeng Jiang @.***>
wrote:

I have read your post Using klee on Rust for Linux(part 1). I also keep
notice on the project and your post inspires me a lot. But I still have
some questions. Since I can found no discussion areas for the post. I put
my questions here.

Based on my understanding, the Rust for Linux project is aimed to
mitigate the gap between the current situation of Rust and the requirements
of kernel development. As I learned from your post, the main problem is
aroused by dynamic checks(usually, automatically added by Rust compiler)
that will panic the program if the check is not passed. The safety of Rust
programs partly relies on these dynamic checks. Verification tools try to
eliminate the effects of dynamic checks by two ways: fix check that may
fail and remove check that cannot fail. This can be done by an independent
verification step before release. Have I got your ideas correctly?
In the subsection Safety checks of section What properties would we
like to verify?. You said "if we try to catch the panic, we will risk
leaving data in an inconsistent way". I do not know a lot about panic
safety. But I guess that leaving data in an inconsistent way indicates a
bug that we can avoid if we write codes carefully. Do you mean that this
kind of bugs can be easily introduced if we try to handle panics? Therefore
trying to handle panics is not a good practice.

Thanks a lot!
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/project-oak/rust-verification-tools/issues/152, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ACXRJSM7ZZX4BFMQLS6AGSTT74C4TANCNFSM5DIGPZFQ
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

Thanks a lot for your detailed response. Now I can understand why panic will not be a wise choice in reliability-focused situations(where reset is not an option at most times, like linux kernel). It seems implicit panics introduced by Rust compiler is not a good practice in these situations. These panics are always overlooked by developers and will cause panic safety problems.
For efficiency-focused situations, eliminating useless dynamic checks will also help improve efficiency. This sounds like an interesting research area.
Thanks again！


[Question] Does td_json_client_destroy remove the directory? If so, how not to auth twice?

Hi!
I've tested tdlib locally and it seems that tdlib removes its files after td_json_client_destroy. I've used wrapper to test, however, it should not influence the behavior. So, my main question is: does td_json_client_destroy remove the directory with files and db?
If so, how to auth only once? Or how to copy the database safely and start tdlib using it?
Excuse me, if this issue is dumb.

td_json_client_destroy only destroys client instance, freeing all allocated by the instance memory. It does nothing beside that. You can create a new instance using td_json_client_create and specify the same database_directory in setTdlibParameters to continue using the same session.

thanks


[Bugfix] Show proper error messages in exam management

Checklist

[ ] I tested all changes and all related features with different users (student, tutor, editor, instructor, admin) on the test server https://artemistest.ase.in.tum.de.
[x] Client: I followed the coding and design guidelines.
[x] Client: I added multiple integration tests (Jest) related to the features (with a high test coverage)
[x] Client: I documented the TypeScript code using JSDoc style.
[x] Client: I added multiple screenshots/screencasts of my UI changes

Motivation and Context

When actions in the student exam management (like generating student exams, missing student exams, assessing unsubmitted student exams, ...) fail the client does not show a proper error message, but instead only shows "Bad Request" or something similar. Especially in the case of student exam generation the user should get detailed information about the failure.
Description

The previous error handling only defaulted to generic error handling, which simply shows a translated error message depending on the response status of the query. I added a method, which is always called when one of related queries fails. This new method shows a translated string specific to the failed action and gives some reasoning (if provided in the request response). Otherwise it falls back to the original generic error handling.
Steps for Testing

Create a new exam and give it a wrong configuration (e.g. set number of exercise groups to 2, but only add 1 exercise group)
Add some students to the exam (Exam Management -> Students -> Import students or Register course students)
Navigate to Exam Management -> Student Exams
Click on generate individual exams
Assert that the alert shows the specific reasoning why the action failed
Also try to cause errors in the other actions on this site (generate missing individual exams, prepare exercise start, unlock all repositories, lock all repositories, evaluate quizzes, assess unsubmitted student exams) and verify the alert messages

Note:
Other actions (except for generating individual exams or generating missing individual exams) do not provide that specific reasoning, so in this case only a translated message specific to that action is shown with the error.message appended if available. Otherwise the old error handling logic applies (this happens for example if the user has no internet connection and the request fails).
Test Coverage

student-exams.component.ts 96%
Screenshots

Before

After

Lgtm. I just noticed there is a space in front of the second row in that error message:

Not sure if that is intentional. (It doesn't look that bad imo.)

Yeah I was also wondering about that. I used the already existing translation strings so the space was already there. I also thought it wasn't that bad, so I left it like that. If anyone has some hard feelings on the matter I will change it.


Feature Request: Screenshot incl. GPS Coordinates

Hello,
I understand that the focus of StreetMeasure is be simple and stable to use, I am not sure wether feature requests are wanted. However, I want to give it a try.
I am using StreetMeasure in particular to measure widths of cycleway infrastructure. As cycleway infrastructure appended to highways (lane) is not a StreetComplete quest ( #5025), my workflow so far is:

measure the width with StreetMeasure
take screenshots (please see picture)
edit afterwards at home with ID Editor

Two features might be helpful for me (and others?):

Geotagged screenshots
built-in picture/screenshot mode thats would allow easier documentation of measurements

I think what you are looking for might be "A simple app to create georeferenced notes"? Check out GeoNotes, it was made for that purpose and actually created by another OSM mapper I know.
After measuring the width, you can just add a new note with the width you just recorded. That should solve your use case.
Regarding attaching the GPS position to a screenshot or something, I would say that is out of scope of this app.

Nice profile pic by the way, lol


marvin: 22.13.0 -> 22.22.0

Automatic update generated by nixpkgs-update tools. This update was made based on information from https://repology.org/metapackage/marvin/versions.
meta.description for marvin is: "A chemical modelling, analysis and structure drawing program"
meta.homepage for marvin is: "https://chemaxon.com/products/marvin"
meta.changelog for marvin is: ""
Updates performed

Version update

To inspect upstream changes
Impact

Checks done (click to expand)

built on NixOS
The tests defined in passthru.tests, if any, passed
found 22.16.0 with grep in /nix/store/5rxgmqkvyzihjphk1jp7wbny5ldky4a0-marvin-22.16.0
found 22.16.0 in filename of file in /nix/store/5rxgmqkvyzihjphk1jp7wbny5ldky4a0-marvin-22.16.0

Rebuild report (if merged into master) (click to expand)

1 total rebuild path(s)

1 package rebuild(s)

First fifty rebuilds by attrpath
marvin

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/5rxgmqkvyzihjphk1jp7wbny5ldky4a0-marvin-22.16.0 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A marvin https://github.com/r-ryantm/nixpkgs/archive/24c068fd8d0ea9575fb7ca8e3eeeb82201af2897.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/5rxgmqkvyzihjphk1jp7wbny5ldky4a0-marvin-22.16.0
ls -la /nix/store/5rxgmqkvyzihjphk1jp7wbny5ldky4a0-marvin-22.16.0/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review run on x86_64-linux 1

1 package built:

marvin

Maintainer pings
cc @fusion809 for testing.

Automatic update generated by nixpkgs-update tools. This update was made based on information from https://repology.org/metapackage/marvin/versions.
meta.description for marvin is: A chemical modelling, analysis and structure drawing program
meta.homepage for marvin is: https://chemaxon.com/products/marvin
Updates performed

Version update

To inspect upstream changes
Impact

Checks done (click to expand)

built on NixOS
The tests defined in passthru.tests, if any, passed
found 22.22.0 with grep in /nix/store/iphvi36ccvsxjrn9sm9mg0fbask2x47l-marvin-22.22.0
found 22.22.0 in filename of file in /nix/store/iphvi36ccvsxjrn9sm9mg0fbask2x47l-marvin-22.22.0

Rebuild report (if merged into master) (click to expand)

1 total rebuild path(s)

1 package rebuild(s)

First fifty rebuilds by attrpath
marvin

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/iphvi36ccvsxjrn9sm9mg0fbask2x47l-marvin-22.22.0 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A marvin https://github.com/r-ryantm/nixpkgs/archive/0fb5ca33ac62c68a00bd68900d79320c9bfc99e5.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/iphvi36ccvsxjrn9sm9mg0fbask2x47l-marvin-22.22.0
ls -la /nix/store/iphvi36ccvsxjrn9sm9mg0fbask2x47l-marvin-22.22.0/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review run on x86_64-linux 1

1 package built:

marvin

Maintainer pings
cc @fusion809 for testing.

No suitable Java Virtual Machine could be found on your system.
The version of the JVM must be at least 11 and at most 17.
Please define INSTALL4J_JAVA_HOME to point to a suitable JVM.

Not a regression, but shouldn't we pin jre to a correct version?

Automatic update generated by nixpkgs-update tools. This update was made based on information from https://repology.org/metapackage/marvin/versions.
meta.description for marvin is: A chemical modelling, analysis and structure drawing program
meta.homepage for marvin is: https://chemaxon.com/products/marvin
Updates performed

Version update

To inspect upstream changes
Impact

Checks done (click to expand)

built on NixOS
The tests defined in passthru.tests, if any, passed
found 23.3.0 with grep in /nix/store/p59md64cwkkb8m7sm0964fblxm4g2i4n-marvin-23.3.0
found 23.3.0 in filename of file in /nix/store/p59md64cwkkb8m7sm0964fblxm4g2i4n-marvin-23.3.0

Rebuild report (if merged into master) (click to expand)

1 total rebuild path(s)

1 package rebuild(s)

First fifty rebuilds by attrpath
marvin

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/p59md64cwkkb8m7sm0964fblxm4g2i4n-marvin-23.3.0 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A marvin https://github.com/r-ryantm/nixpkgs/archive/f30f0efcd63105377036740b2b9664edb04b2d05.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/p59md64cwkkb8m7sm0964fblxm4g2i4n-marvin-23.3.0
ls -la /nix/store/p59md64cwkkb8m7sm0964fblxm4g2i4n-marvin-23.3.0/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review run on x86_64-linux 1

1 package built:

marvin

Maintainer pings
cc @fusion809 for testing.

Approved. As for @bobby285271's query, I guess. I hardly use NixOS anymore though, so I will admit I wouldn't even know how to do what you suggest.

Automatic update generated by nixpkgs-update tools. This update was made based on information from https://repology.org/metapackage/marvin/versions.
meta.description for marvin is: A chemical modelling, analysis and structure drawing program
meta.homepage for marvin is: https://chemaxon.com/products/marvin
Updates performed

Version update

To inspect upstream changes
Impact

Checks done (click to expand)

built on NixOS
The tests defined in passthru.tests, if any, passed
found 23.4.0 with grep in /nix/store/vqv68s74q0naa09yalbsc00sckvzwja9-marvin-23.4.0
found 23.4.0 in filename of file in /nix/store/vqv68s74q0naa09yalbsc00sckvzwja9-marvin-23.4.0

Rebuild report (if merged into master) (click to expand)

1 total rebuild path(s)

1 package rebuild(s)

First fifty rebuilds by attrpath
marvin

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/vqv68s74q0naa09yalbsc00sckvzwja9-marvin-23.4.0 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A marvin https://github.com/r-ryantm/nixpkgs/archive/4da1bc0bfae785def0f379ae88b293744519f821.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/vqv68s74q0naa09yalbsc00sckvzwja9-marvin-23.4.0
ls -la /nix/store/vqv68s74q0naa09yalbsc00sckvzwja9-marvin-23.4.0/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review run on x86_64-linux 1

1 package built:

marvin

Maintainer pings
cc @fusion809 for testing.


Assigning a native pointer to an object - individually.

As part of my project, I need to expose some C++ APIs to JerryScript. Now, the best way to actually do that is by being able to tag the native instance onto the object created. Imagine this class for example:
class Foo {
public:
  Foo();
  ~Foo();
  int someMethod();
};

Now, what I guess I have to do, is to create a jerry_native_object_info_t.
void foo_free(void* ptr) {
  Foo* foo_ptr = (Foo*)ptr;
  delete foo_ptr; // trigger deallocation and deconstruction
}
jerry_object_native_info_t foo_info = {
  .free_cb = foo_free
};

So far, so good. But from what I figured, I would do something like this:
jerry_value_t obj = jerry_create_object();
Foo* foo_ptr = new Foo();
jerry_set_object_native_pointer(obj, (void*)foo_ptr, &foo_info);

And get this pointer in a method like this:
void* ptr;
if(jerry_get_object_native_pointer(obj, &ptr, &foo_info)) {
  Foo* foo_ptr = (void*)ptr;
}

So far, this bit I did understand. But what if I want to have the instance of Foo tagged on an instance object? Do I define that in an Object.constructor? Is it save that - even when I have multiple Foos around, that only the instance tagged to the specific object will be sent to the free_cb once the GC decides to delete it? (And on a side note: how do I actually define a constructor in C?)
Also, can I tag any kind of pointer in? Take for instance: I am working on a C++ wrapper, and I would like to reduce this:
static jerry_value_t
function(
  const jerry_value_t func_value,
  const jerry_value_t this_value,
  const jerry_value_t *args_p,
  const jerry_value_t args_cnt
);

Into this:
Value function(Context ctx);

The idea I had, was to use a generic wrapper object which would construct a function off something like the following, and just take the returned value and return it like usual:
typedef Value (*jerry_cxx_handler_t)(Context);
jerry_object_native_info_t dummy_info = {
  .free_cb = NULL
};
static jerry_value_t
cxx_wrapper(
  const jerry_value_t func_value,
  const jerry_value_t this_value,
  const jerry_value_t *args_p,
  const jerry_value_t args_cnt
) {
  void* ptr;
  if(! jerry_get_object_native_pointer(func_value, &ptr, &dummy_info)) { /* handle error */ }
  jerry_cxx_handler_t handler = (jerry_cxx_handler_t)ptr;
  Context ctx(func_value, this_value, args_p, args_cnt);
  Value cxx_rt = handler(ctx);
  jerry_value_t rt = cxx_rt.raw();
  return rt;
  // ctx and cxx_rt should auto-destruct and release their copy of the value properly.
}

Now, what I am curios about is: When constructing the jerry_value_t with the native pointer set to a jerry_cxx_handler_t, is it ensured that only this func_value has exactly this function pointer assigned at any time?
Thank you very much. :)

FYI: @fbmrk did a similar code generator for IoT.js: https://github.com/pando-project/iotjs/pull/1756
IoT.js is a Node.js like JavaScript framework built on top of JerryScript. I don't know if it can be used in your use case or can it be modified to use JerryScript only.

@LaszloLango I looked into it, and that might just be a little bit more than I actually want. All that I really want is to find out if assigning a pointer to a jerry_value_t of type Function will always stay the same for this exact object.
Imagine this:
function foo() {}

// This is made-up, but you get the idea.
var ptr = <...some native pointer...>
Object.setNativePointer(foo, ptr)

Now, whenever I retrive foo, and extract it's native pointer, am I guaranteed to always get exactly that pointer back - or may the assigned pointer appear on any jerry_value_t of type Function once assigned?

Yes, it will get always the same pointer for a certain value. The pointer is assigned to the value and not to the type of the value.

Perfect :) I just wanted to make sure before I invest myself into something, only to end up running into quite a wall.
Thank you very much - this is very, very helpful!


Transient AGPL Dependency EbookLib

Describe the bug
I currently work on a project that is using textract to help parse pdfs and word documents. It looks great and works well!
However, when I ran an analysis of its license dependencies, I discovered that textract depends on EbookLib which is AGPL licensed. Legally, that means that textract should also carry an AGPL license, as should all programs which use textract, unless textract switches to a different dependency that doesn't use a strict copyleft license.
One alternative epub parsing package that shows promise is epub2txt which carries an MIT license.
To Reproduce
Steps to reproduce the behavior:

Create a new project with a requirements.txt containing textract as the only dependency.
Install the license checker liccheck and follow its documentation for creating a liccheck.ini file, but with no approved licenses. (This will force the tool to list out all dependencies with their licenses.
Review the report on the license dependencies (Shown in the Screenshots section)

Expected behavior
An MIT licensed library like textract should not (in fact, legally cannot) depend on an AGPL licensed library.
Screenshots
gathering licenses...
14 packages and dependencies.
check unknown packages...
14 packages.
    argcomplete (1.8.2): ['Apache Software']
      dependency:
          argcomplete << textract
    beautifulsoup4 (4.5.3): ['MIT']
      dependency:
          beautifulsoup4 << textract
    chardet (2.3.0): ['GNU Library or Lesser General Public License (LGPL)']
      dependency:
          chardet << textract
    docx2txt (0.6): UNKNOWN
      dependency:
          docx2txt << textract
    EbookLib (0.15): ['GNU Affero General Public']     // *** NOTE THE AGPL LICENSE HERE ***//
      dependency:
          EbookLib << textract
    lxml (4.7.1): ['BSD']
      dependencies:
          lxml << EbookLib << textract
          lxml << python-pptx << textract
    Pillow (9.0.0): ['Historical Permission Notice and Disclaimer (HPND)']
      dependency:
          Pillow << python-pptx << textract
    pocketsphinx (0.1.3): ['BSD']
      dependency:
          pocketsphinx << textract
    python-pptx (0.6.5): ['MIT']
      dependency:
          python-pptx << textract
    six (1.10.0): ['MIT']
      dependencies:
          six << EbookLib << textract
          six << textract
    SpeechRecognition (3.6.3): ['BSD']
      dependency:
          SpeechRecognition << textract
    textract (1.6.1): ['MIT']
      dependency:
          textract
    xlrd (1.0.0): ['BSD']
      dependency:
          xlrd << textract
    XlsxWriter (3.0.2): ['BSD']
      dependency:
          XlsxWriter << python-pptx << textract

Desktop (please complete the following information):

OS: Ubuntu 20.04
Textract version: 1.6.4
Python version: 3.9
Virtual environment: yes

Additional context
N/A

This is an excellent catch @jhale1805 . Thank you. Any chance you (or anyone else in this community) might be able to put together a PR for this?
Looking at epub2txt, it's probably pretty straightforward to update the code here.

As long as I can figure out how to run the test suite to make sure I don't break anything, that doesn't look too bad.
I'll see if I can get that done within the next week or so.

Amazing; TYTYTYTY! If the test suite causes you any problems, just let me know. You may need to update the test data in this directory

Okay! I just opened PR #411 which fixes the AGPL dependency issue.
SIDE NOTE: I did have a lot of trouble with the tests. For anyone else contributing to the project, I recommend ignoring the setup instructions in the Contributing.rst (they're outdated) and instead following the commands used in .travis.yml to configure your environment and run the unit test suite.

Thanks so much for your work on this, @jhale1805 and for your patience in me merging in your PR. This is now released in 1.6.5


Debugger for Chrome in VSC 1.47 (Bug)

The Problem is relevant for "June 2020 (version 1.47)". At the Moment i installed the previouse Version and the Bug is not there anymore.
In 1.47 an 1.47.1 debugging was not possible anymore with the extensions "Debugger for Chrome" and "Debugger for Firefox". After the update it didnt work, but after reinstalling 1.46 it perfectly works again.

Install VSC 1.47 or 1.47.1
Install "Debugger for Chrome"
launch.json -> See *1)

*1)
{
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Launch index.html",
            "type": "chrome",
            "request": "launch",
            "file": "${workspaceFolder}/Kapitel 6/index.html"
        }
    ]
}

Start Debugg Mode in VSC (F5)
Then Error appears

As i said before: If i install version 1.46 and perform the Steps above, everything works fine.

Thanks for the issue, you can set debug.javascript.usePreview: false in the meantime to use the old debugger

This will be fixed in the next nightly build released at 5 PM PST.

Thanks a lot, debug.javascript.usePreview = false works perfectly fine. Debuggin is possible even in VSC 1.47.X


[Merged by Bors] - feat: function is differentiable outside of its tsupport

From sphere-eversion; I'm just submitting it.
Also golf the proof of the preceding lemma slightly and add a docstring.

Thanks!
bors merge

These should be to_additivized from the mulTSupposrt versions. And you missed the opportunity to golf ContMDiff.extend_one below.

My bad, I should have seen that in the review indeed. @grunweg could you open another PR implementing Junyan's suggestions please?

@ADedecker @alreadydone Thanks for the fast merge. I just implemented the to_additive suggestion, but failed to golf extend_one. Code is at https://github.com/leanprover-community/mathlib4/commit/14f53396f450fe9d47443338ab6a33add7160a56. What do you think.

I can't open that link

Oops, fixed the link.

Can you open a PR with that code? I'll write a suggestion there

Okay I found the issue: you should state contMDiffWithinAt_of_not_mem_mulTSupport for any manifold with one, not only a normed space. I guess there are a lot of things in the file that could be generalized then, do you want to do so?

Okay I found the issue: you should state contMDiffWithinAt_of_not_mem_mulTSupport for any manifold with one, not only a normed space. I guess there are a lot of things in the file that could be generalized then, do you want to do so?

Thanks! I can add this to my list of things - though, to be honest, I don't see why it should be high up there? Do you want to open an issue about this, and I'll just PR this one lemma? If I decide to work on the issue, I can comment there :-)


Shared directory on Windows guest with Office 365

After installing Office (Microsoft 365) on Windows 11 guest with SPICE guest agent installed, shared directory do not work anymore.
A comment in #3583 (https://github.com/utmapp/UTM/discussions/3583#discussioncomment-2213832) refers to this bug, but I've found no additional information nor workaround.
Is there any way to keep folder sharing working, with Office 365 installed on the Windows guest OS?
Thanks.
Configuration

UTM Version: 4.1.5
macOS Version: Ventura 13.2.1
Mac Chip (Intel, M1, ...): M1 Pro (MacBook Pro)

Thanks so much, @dinosauria123 - that restored access to WebDAV file sharing on a Windows 11 ARM VM where it had been broken after installing Microsoft 365 desktop apps.

Arm binary of Spice WebDAV daemon (https://www.spice-space.org/download/windows/spice-webdavd/) is broken.
Try x64 binary instead of Arm one.

Sir, could you please share as to how I can do this? In the same position and incredibly frustrated!

Arm binary of Spice WebDAV daemon (https://www.spice-space.org/download/windows/spice-webdavd/) is broken.
Try x64 binary instead of Arm one.

Sir, could you please share as to how I can do this? In the same position and incredibly frustrated!

Just download the correct *.msi file, launch it and restart

Oh yes, I've tried installing the spice-webdavd-x64-latest.msi file, but it says "product already installed".
Still cant see the shared location. :(

You need to uninstall spice WebDAV first and then reinstall

You need to uninstall spice WebDAV first and then reinstall

It worked! Thank you SO much!

Hello. So where do we find and remove the old webdav? I can't find the word webdav on the Win11 side.
I am not sure which file to download. spice-webdavd-x64-2.4 I downloaded this.
But first I need to find where and how to uninstall the old webdav.
I would appreciate if someone can help me a little more detailed.

It's in system>apps. I uninstalled it from there and reinstalled the 'latest' .msi for x64

I found it.
Now I will write the detailed answer.
You can find webdav in add\remove programs.
Which webdav file? I installed this one:
spice-webdavd-x64-2.4.
the problem is completely gone.
thank you.

I ran into the same issue and using @realperest solution worked for me.
To make the workaround easier to find this is the error I got when trying to run the spice-webdavd.exe manually:
The application was unable to start correctly (0xc000007b).


Suggestion: Re-export foreign types from extern crates in public APIs

Problem
Consider re-exporting foreign types in public APIs. For example, in https://github.com/rp-rs/rp-hal/blob/715c3c9dd85f4b30d949c310b60e7621ea62c3f6/rp2040-hal/src/timer.rs#L198 there is MicrosDurationU32 from fugit.
The "problem" is: To use this API, I also have to add a compatible version fugit to my crate manually – which is obviously possible, but feels redundant because it splits my dependency tree.
Clean dependency tree: my_crate ─ rp2040_hal ─ fugit

Current dependency tree: my_crate ─ rp2040_hal ─ fugit
                                  ╲
                                    fugit

This might become especially cumbersome if my crate – for some reason – have to use another, possibly API-incompatible version of fugit:
Mixed dependency tree: my_crate ─ rp2040_hal ─ fugit-x
                                 ╲
                                   fugit-x
                                 ╲
                                   fugit-y

Suggestion
A possible alternative would be to publicly re-export the used type, so that I could simply use rp2040_hal::timer::{Alarm, Alarm0, MicrosDurationU32} without having to synchronize my crate's imports.

Sounds like a reasonable request. As it's not specific to this crate: Are there any general best practices covering this question?

Here is an old discussion about this question:
https://github.com/rust-lang/api-guidelines/discussions/176
No clear conclusion, but at least they don't say it's a bad idea to do the re-export in general.

Another open question is where to put the re-export.
For your example it would be in rp2040-hal::timer, so one can do use rp2040_hal::timer::{Alarm, Alarm0, MicrosDurationU32}.
But fugit is also used in several other modules. So it might be better to put it at the top level?
Like this?
use rp2040_hal::MicrosDurationU32;
use rp2040_hal::timer::{Alarm, Alarm0};

Or perhaps like this?
use rp2040_hal::fugit::MicrosDurationU32;
use rp2040_hal::timer::{Alarm, Alarm0};

I implemented the last suggestion in #573, but that's open for discussion. No need for extended bike-shedding, but if somebody knows some good reason why the re-export should be somewhere else (or why it's a bad idea in the first place), please speak up.

I also think that if fugit is used in multiple places, it's best to simply re-export the entire crate as sub-dependency (as done in the PR) instead of re-exporting individual types somewhere within rp2040_hal.


Use require('ipc-renderer') instead

Use require('ipc-renderer') instead of require('electron').ipcRenderer in docs
https://github.com/atom/electron/issues/3577

Thanks for this but require('electron').ipcRenderer is the correct one, the original issue was using docs with the wrong version of Electron.

I'm using "electron-prebuilt" version 0.35.1 and I have same issue.
Does it also use the different version of Electron?

require('electron').ipcRenderer doesn't work for me too

I'm using electron prebuilt 0.36.3 and I'm having the same problem... this make me crazy... because if I remove electron-prebuilt i cant start the app... I need help with this.
Thanks


"error": "'inlinePlayerData'"

:exclamation:  DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE :exclamation:
lack of information will lead to closure of the issue

Describe the bug
idk why when i try to search using keyword "no vitality" it shows that    "error": "'inlinePlayerData'"

code that was used that resulted in the bug
from pytubefix import YouTube

# put your code here
@app.route('/api/yts', methods=['GET'])
def search_videos():
    query = request.args.get('q')

    if not query:
        return jsonify({"error": "No search query provided | Gaada judul yang dikasih"}), 400

    try:
        results = Search(query)

        if not results.videos:
            return jsonify({"error": "No videos found | Tidak ada video yang ditemukan"}), 404

        videos = []
        for video in results.videos:
            yt = YouTube(video.watch_url, use_oauth=True, allow_oauth_cache=True, on_progress_callback=on_progress)

            videos.append({
                "1_title": yt.title,
                "2_thumbnail": yt.thumbnail_url,
                "3_url": yt.watch_url,
                "4_author": yt.author,
                "5_duration": yt.length
            })

        return jsonify({"videos": videos})

    except Exception as e:
        return jsonify({"error": str(e)}), 500

Expected behavior
A clear and concise description of what you expected to happen.
I expected it shows the result but it doesnt

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

OS: [Windows 11 | Linux Ubuntu VPS digital ocean (idk the version)]
Python Version [Windows : 3.12.4 | Vps : 3.8.10 ]
Pytubefix Version [6.16.1]

Additional context
I tested both in windows and vps and its the same idk why
it just the youtube search the download still no problem
i might be dumb so yeah help me pls

I tested your code and it works for me, maybe YouTube is implementing A/B tests.
Would you mind taking a test?
On line 312 of the search.py file change this:
video_id = items['shortsLockupViewModel']['inlinePlayerData']['onVisible'][
                                'innertubeCommand']['watchEndpoint']['videoId']

for this
 video_id = items['shortsLockupViewModel']['onTap']['innertubeCommand']['reelWatchEndpoint']['videoId']

I tested your code and it works for me, maybe YouTube is implementing A/B tests.
Would you mind taking a test?
On line 312 of the search.py file change this:
video_id = items['shortsLockupViewModel']['inlinePlayerData']['onVisible'][
                                'innertubeCommand']['watchEndpoint']['videoId']

for this
 video_id = items['shortsLockupViewModel']['onTap']['innertubeCommand']['reelWatchEndpoint']['videoId']

i tried this and it's working thank you so much


Publishing video with same name cameras only initialize the first one.

So kinda clunky title, but I'll explain.
I'm trying the new "multiple videotracks per peerconnection" feature, and I have two webcameras that are of the same model, Logitech BRIO.
When running PeerConnection.GetVideoCaptureDevicesAsync() both cameras appear and are recognized as seperate cameras.
However, when setting PeerConnection.LocalVideoTrackSettings.VideoDevice to either one of them, only one of them is used.
If I try to enable the first, then the second, in the same peerconnection, the app crashes, which I think is because it tries to access the first camera two times.
I have a third webcamera which has a different name, Microsoft® LifeCam Studio(TM), and this is recognized and utilized correctly in conjunction with either of the two Brios.
I'm assuming then that the WebRTC code checks the name of the camera instead of the ID? That would at least explain my findings.

Is this Desktop or UWP?

In Unity, so desktop?

Yes, Desktop x64 then. I ask because the codepaths are quite different internally.
On Desktop, the video capture is handled by the Google implementation directly. And indeed there a bug in it, already identified by their devs it seems:
https://github.com/webrtc-uwp/webrtc/blob/baa89682df1ab891ae274a1cb2d9be3b1ee7e20b/media/engine/webrtcvideocapturer.cc#L138-L150
This is annoying because there's no easy way currently for us to fix that. We will have to either backport a fix or upgrade to a later Google release.

Note this seems fixed on Google's HEAD, if I am not mistaken in thinking that VcmCapturer is the replacement for the current WebRtcVideoCapturer on M71.
https://webrtc.googlesource.com/src/+/refs/heads/master/test/vcm_capturer.cc#42


⚠ Bofrost.at has degraded performance

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

HTTP code: 200
Response time: 2409 ms

Resolved: Bofrost.at performance has improved in 88ebd9f.


Add support for the --tree argument to the path command

I was trying to cobble together a solution for project-local dependency installations using --tree and wanted to add these to all of the appropriate paths, but found that luarocks path does not respect the --tree argument.
This adds support for the --tree argument in a way that is hopefully not too stupid. Any feedback is very much appreciated.

Hi! Thank you for contributing!
Could you revert all those whitespace-only changes in your patch? It makes it hard to read the diff, and adds many unrelated entries to the history of files.

@hishamhm Yes, I can revert them, but are you sure you want them reverted? It's probably a good idea to get them cleaned up since many editors remove trailing whitespace automatically. As far as commit history, all of the whitespace changes are in files that include actual changes so the git log will still make sense. Finally, you can ignore whitespace-only changes by appending ?w=1 to the pull request URL to make it easier to review.

Well, you used to be able to add ?w=1 to ignore whitespace changes, but apparently that no longer works. Thanks GitHub.

All whitespace changes removed except one where the tabbing was incorrect and inconsistent within a modified function.

Merged! Thank you!


Adding options like grocery, mobiles, fashion etc

Describe the feature
There is no kind options where a customer can easily find his/her desire things.
Add ScreenShots

Here is the screenshot of how do I add the options like the flipkart app
Record

[X] I agree to follow this project's Code of Conduct
[X] I'm a GSSOC'24 contributor
[X] I want to work on this issue

yea sure. you have been assigned . Go ahead @Ishitamukherjee2004


feature: add folder structure

This PR currently contains the folder structure of the entire application
Note: please note that most of the files created are empty and some modules aren't exported as well, once we refactor everything to actual components then we can modularise and export them as required. Thanks
🙋♂ "Feel free to raise any issue or concerns"

might I request for a documentation of the folder structure?

@makunomark  yeah sure, will sort out https://github.com/droidconKE/droidconKE2022ReactNative/pull/3#issuecomment-1238576527 currently in progress

@makunomark yeah sure, will sort out #3 (comment) currently in progress.
At first I thought it wasn't a necessity since things are already laid out, just building on top of what has already been setup

I agree. There's a chance as we proceed it will take shape.


One of the schedule triggered twice in difference of milliseconds.

Added on job in Quartz trigger and its get execute twice withing few milliseconds. It happens intermittent.
Create one schedule with name "TestSchedule" which should be trigger everyday at 13:00 hours.
First instance of schedule will be triggered at 13:00:00,084
Second instance of same schedule will be trigger at 13:00:00,186
Can some one help me over here? Why Quartz.net allow to trigger same schedule twice at same time?

Please give example code to reproduce.

Closing outdated, unresolved issues. Please, reopen if still relevant.


Added active timeseries graph on homepage

Added time series graph for active cases. This is an important metric to track and know the progress of this epidemic.

@JunaidBabu @sudevschiz Thoughts on adding active? I feel like just because active has a similar trend it needs to be ignored, could lead to visualizations like how fast people moved from active to either recovered or deceased state, confirmed does not convey that. But thoughts?

This is helpful to assess the current situation. Look at the China graph below which showcases the active patients. Even though total cases are above 80k, the active cases are less than 5k and that number going to zero signifies that the country is free of any infection. In my opinion this is very useful graph, let me know your thoughts.

We won't be moving forward with adding "active" graphs at the moment.


Add method to create a cookie from a header string

Basically introduces a public API to the internal HTTP::Cookie::Parser.

What do you think about Http::Cookie.build(str : String) instead of Http::Cookie.from_header(header : String)?

@hugopl I went with from_header as the HTTP::Cookies type has like https://crystal-lang.org/api/master/HTTP/Cookies.html#from_client_headers(headers):self-class-method.  I also think it's more clear on what it's doing.

More clear would be Cookies.from_client_headers.

@straight-shoota You think so?  Is there actually a difference between client and server cookie headers in this context?  I went with a singular version as this method doesn't currently handle multiple cookies in the same header string.  Probably should validate that and raise accordingly if needed.

What exactly is "this context"? Could you please show a use case for this?

@straight-shoota Parsing a header string into a Cookie.  To me it just seemed like you should be able to do that.  Mainly since the related HTTP::Cookies type has methods for creating a new instance from the cookie headers, but there was no way to create a single cookie from the header as well.

Got it, it parses the value of a cookie header, client or server (i.e. the contents of Set-Cookie or Cookie in HTTP headers) and creates the Cookie object, I think the docs could somehow say this... but OTOH the examples in the docs speaks by themselves.
P.S.: You missed a opportunity of a fair use of an emoji in a merge request title :cookie: .


next - minor: add isUndefined rule to custom enfource validation functions

Q
A

Bug fix?
✖

New feature?
✔

Breaking change?
✖

Deprecations?
✖

Documentation?
✖

Tests added?
✔

Fixed issues

Add isUndefined validation function to n4s rules.
Regarding to the following issue: https://github.com/ealush/vest/issues/397

I just added isUndefined to the docs.


fix(knative): Fix the knative pods created unitl exhaustion

Setting the sinkbing label when the knative service is
created seems the right place, instead to update the label
seems to trigger a new knative configuration
https://github.com/apache/camel-k/issues/3522
-->
Release Note
Fix knative service triggering new pods until node exhaustion

@christophd for review.
I didn't add e2e tests, as it seems too risky to let the test to create pods and put the worker node unavailable.


Update cleanup() script

This PR aims at cleaning-up type A record entries first,
and thus the associated hosted zone.
Signed-off-by: Krishna Harsha Voora<EMAIL_ADDRESS>

Can one of the admins verify this patch?

Here's the script O/P:-
http://pastebin.test.redhat.com/1072447

Hi :wave: @mukrishn @dry923 @smalleni
ptal


ValueError: Cannot combine AUTHORIZATION header with AUTH argument or credentials encoded in URL

Expected Behavior
kopf to run normall
Actual Behavior
kopf throws error ValueError: Cannot combine AUTHORIZATION header with AUTH argument or credentials encoded in URL.
Please note that this error occurs when using kopf with k3s. However, I don't think k3s is the problem here but rather that it's using username/password authentication instead token.
Steps to Reproduce the Problem

Run kopf with or without --dev flag

Specifications

Platform: Linux
Kubernetes version: v1.16.0
Python version: 3.7.4
Python packages installed: (use pip freeze --all)

Package           Version
----------------- ---------
aiohttp           3.6.2
aiojobs           0.2.2
async-timeout     3.0.1
attrs             19.3.0
cachetools        3.1.1
certifi           2019.9.11
chardet           3.0.4
Click             7.0
google-auth       1.7.1
idna              2.8
iso8601           0.1.12
kopf              0.23rc4
kubernetes        10.0.1
multidict         4.5.2
oauthlib          3.1.0
pip               19.3.1
pyasn1            0.4.7
pyasn1-modules    0.2.7
pykube-ng         19.10.0
python-dateutil   2.8.1
PyYAML            5.1.2
requests          2.22.0
requests-oauthlib 1.3.0
rsa               4.0
setuptools        41.6.0
six               1.13.0
typing-extensions <IP_ADDRESS>
urllib3           1.25.7
websocket-client  0.56.0
wheel             0.33.6
yarl              1.3.0

Stack Trace
$ kopf run release.py
[2019-11-18 11:35:20,726] kopf.reactor.activit [INFO    ] Initial authentication has been initiated.
[2019-11-18 11:35:20,779] kopf.activities.auth [INFO    ] Handler 'login_via_pykube' succeeded.
[2019-11-18 11:35:20,806] kopf.activities.auth [INFO    ] Handler 'login_via_client' succeeded.
[2019-11-18 11:35:20,807] kopf.reactor.activit [INFO    ] Initial authentication has finished.
Traceback (most recent call last):
  File "/home/ctran/.venv/release/bin/kopf", line 8, in <module>
    sys.exit(main())
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/click/core.py", line 764, in __call__
    return self.main(*args, **kwargs)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/click/core.py", line 717, in main
    rv = self.invoke(ctx)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/click/core.py", line 1137, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/click/core.py", line 956, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/cli.py", line 31, in wrapper
    return fn(*args, **kwargs)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/click/decorators.py", line 64, in new_func
    return ctx.invoke(f, obj, *args, **kwargs)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/cli.py", line 78, in run
    vault=__controls.vault,
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/reactor/running.py", line 113, in run
    vault=vault,
  File "/usr/lib64/python3.7/asyncio/base_events.py", line 579, in run_until_complete
    return future.result()
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/reactor/running.py", line 153, in operator
    vault=vault,
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/reactor/running.py", line 239, in spawn_tasks
    standalone=standalone, namespace=namespace, name=peering_name,
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/engines/peering.py", line 116, in detect
    if await Peer._is_peering_exist(name=PEERING_DEFAULT_NAME, namespace=namespace):
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/engines/peering.py", line 158, in _is_peering_exist
    obj = await fetching.read_obj(resource=resource, namespace=namespace, name=name, default=None)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/clients/auth.py", line 34, in wrapper
    return await fn(*args, **kwargs, session=session)
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/kopf/clients/fetching.py", line 57, in read_obj
    url=resource.get_url(server=session.server, namespace=namespace, name=name),
  File "/home/ctran/.venv/release/lib/python3.7/site-packages/aiohttp/client.py", line 442, in _request
    raise ValueError("Cannot combine AUTHORIZATION header "
ValueError: Cannot combine AUTHORIZATION header with AUTH argument or credentials encoded in URL
Task was destroyed but it is pending!
task: <Task pending coro=<_root_task_checker() running at /home/ctran/.venv/release/lib/python3.7/site-packages/kopf/reactor/running.py:418> wait_for=<Future pending cb=[<TaskWakeupMethWrapper object at 0x7f66186b3250>()]>>
Task was destroyed but it is pending!
task: <Task pending coro=<_startup_cleanup_activities() running at /home/ctran/.venv/release/lib/python3.7/site-packages/kopf/reactor/running.py:496> wait_for=<Future pending cb=[<TaskWakeupMethWrapper object at 0x7f661869c9d0>()]>>
Task was destroyed but it is pending!
task: <Task pending coro=<_stop_flag_checker() running at /home/ctran/.venv/release/lib/python3.7/site-packages/kopf/reactor/running.py:447> wait_for=<Future pending cb=[<TaskWakeupMethWrapper object at 0x7f661869c050>()]>>

kobeconfig
apiVersion: v1
clusters:
- cluster:
    certificate-authority-data: MASKED
    server: https://<IP_ADDRESS>:6443
  name: default
contexts:
- context:
    cluster: default
    user: default
  name: default
current-context: default
kind: Config
preferences: {}
users:
- name: default
  user:
    password: MASKED
    username: admin

@chungktran Can you please try it with the new master, or kopf==0.23rc5?

@nolar Looks good. Error is gone. Thanks for fixing this.


Why is frame size equal to 100?

Hi authors,👋
Thank you for sharing such wonderful project!
I saw the code in processor.py, and I notice that the frame size is equal to 100.
        # sample['wav'] is torch.Tensor, we have 100 frames every second

As far as I know, the hop_size && sample_rate of cozyvoice are 256, 22050 respectively, and
$$
frames_in_sec = sample_rate / hop_size
$$
So, the frames in sec of cozyvoice would be 86? I'm wondering how 100 is calucated? Is there any detailed I've igonred?
Bests,
Jongjyh

well this is just for filter logic, it is easier to calculate 1s as 100frame because for example 30000frames equals 300 second


Custom resolver "create" method types

Hello! I'm trying to write a custom resolver for a reason. But when I try to use create method, I get this type error.

But when I ignore the error with // @ts-ignore I get no error and it works.
How can I make this without ignore the errors?
Thanks!

You are running into an issue we have been running into as well. This is because of how the crud service is typing the create method. Here's the solve I've been doing.

import { CreateUserInput, User } from "your-generated-types.ts";

// TypeScript will protect you here. careful not to use `as CreateUserInput`
const createPayload: CreateUserInput = {
    fullname: 'John Doe',
    email<EMAIL_ADDRESS>    password: '12345',
    phone: '555-1234',
};

// you're casting "User" and basically telling TypeScript it's OK.
// this typically would be unsafe, but because you're typing it above, this should be acceptable :)
const user = await context.graphback.User.create(<User>createPayload);

Thank you so much @CoreyKovalik! I've just tried it and It works great.

@CoreyKovalik  I don't know why but VS code started to give me this error...


Create Dockerfile

build docker image for DeepLX

Is it possible to use Action to package the docker directly and publish it to ghcr.io? @sbilly


RDKVREFPLT-3158: Split iarmmgrs hal into individual components

Updated Deepsleep mgr

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

closing this PR, will raise separate PR from dev branch


Feat/point cloud check

:tada: This PR is included in version 1.0.0 :tada:
The release is available on npm package (@latest dist-tag)
Your semantic-release bot :package::rocket:


Upgrade to pytest-asyncio 0.23

closes #1552
Checklist before merging

[ ] I added an appropriate entry to CHANGELOG.md
[ ] I merged main into the current branch.

It's interesting to see this log in the GitHub CI after the first commit
RuntimeError: Event loop is closed
The garbage collector is trying to clean up non-checked-in connection <AdaptedConnection <asyncpg.connection.Connection object at 0x7f7c72ed2d40>>, which will be terminated.  Please ensure that SQLAlchemy pooled connections are returned to the pool explicitly, either by calling ``close()`` or by using appropriate context managers to manage their lifecycle.
sys:1: SAWarning: The garbage collector is trying to clean up non-checked-in connection <AdaptedConnection <asyncpg.connection.Connection object at 0x7f7c72ed2d40>>, which will be terminated.  Please ensure that SQLAlchemy pooled connections are returned to the pool explicitly, either by calling ``close()`` or by using appropriate context managers to manage their lifecycle.

Reason of https://github.com/fractal-analytics-platform/fractal-server/pull/1558/commits/cc0e5b7514e603c5cbf7453cc704161b18c4c8b9
  /Users/yuri/Library/Caches/pypoetry/virtualenvs/fractal-server-zZ2T8p1a-py3.10/lib/python3.10/site-packages/pytest_asyncio/plugin.py:757: DeprecationWarning: The event_loop fixture provided by pytest-asyncio has been redefined in
  /Users/yuri/Desktop/eXact/fractal/fractal-server/tests/conftest.py:24
  Replacing the event_loop fixture with a custom implementation is deprecated
  and will lead to errors in the future.
  If you want to request an asyncio event loop with a scope other than function
  scope, use the "scope" argument to the asyncio mark when marking the tests.
  If you want to return different types of event loops, use the event_loop_policy
  fixture.

I commented out from line 126 to 133 in test_unit_lifespan.py, and then ran the test in both the main branch and the branch of this pr.
These are the outputs:

main

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=============================================================================================== 1 passed, 2 warnings in 7.66s ================================================================================================
ERROR:asyncio:Task was destroyed but it is pending!
task: <Task pending name='Task-5' coro=<<async_generator_athrow without __name__>()> wait_for=<Future pending cb=[shield.<locals>._outer_done_callback() at /Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/asyncio/tasks.py:857, Task.task_wakeup()]>>
$

1552-try-pytest-asyncio-023

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
================================================================================================ 1 passed, 1 warning in 6.90s ================================================================================================
$


Update function and more python notebook

Add mor formative assessment and improve text

This is a long lesson. Would there be room in our schedule to break it in two?

@mdpiper Do you think?
We only see what it is, setup, make a repo and connect it with Github.
The part about collaborative work is not included

@mdpiper
Last season, we could teach the lesson on time.
Any way, we have space to do it.
I will practice this lesson and see how much time it takes me.

Last season, we could teach the lesson on time.

Oh, OK--I defer to your experience, @aguspesce. I withdraw my comment!

it's ok! Your concern is correct.
let me see how much time it is


typos README

Small readme typo fixes

Thanks for your PR. You need to make the change in index.ipynb since the README is auto-generated from it.
Will also try to add a comment to markdown source but not source how to do that.


Few optimisations

Just few optimisations :)

Remove unnecessary null checks before instanceof (instanceof always return false when it's null)
Replace list.stream().collect(Collectors.joining(" ")) with String.join(" ", list)
Replace optional.isPresent() with optional.ifPresent()

Thanks for your interest in contributing!
I'm aware of most of these - they're IntelliJ inspections! However, I prefer a different style in some cases to what it recommends.

Remove unnecessary null checks before instanceof (instanceof always return false when it's null)

I prefer the explicit check - it makes it clear to anyone reading the node that a null value is expected / accounted for.

Replace list.stream().collect(Collectors.joining(" ")) with String.join(" ", list)

I agree with this change.

Replace optional.isPresent() with optional.ifPresent()

I prefer to use an if statement as opposed to using a function in most cases. I know it's more verbose, but it saves on the creation of a Consumer, and is more similar to the if (x != null) {} check.
Other things:

Replacing .forEach(...) with a for loop is fine, I generally prefer to do that.
Removing the explicit <UUID, LPSubject> type params is ok as well - they were left in by mistake.

If you could make those changes, I'll happily merge. :)

Thanks, I made the changes, should be good now :)

Thank you :)


Removed Cocoa Pods version explenation

Removed Cocoa Pods version explenation for dynamic framework support.
Since Coco Pods version is now 1.4.0 it doesn't nedded.

Thanks!


net5.0 OrderBy problem

Hi,
I'm using aspboilerplate that use this nuget.
After update entityframework to version 5 and net5.0 this not longer work
When i run sqlprofiler on my query i saw that is translated into: order by (SELECT 3) and this is not ok;
Because this two query are not equals on result:
Select top 10 * from [pay].[table] order by 3 DESC
Select top 10 * from [pay].[table] order by (SELECT 3) DESC

Hello @totpero, I'll take a look.
(Note that I'm also building a EF5 specific NuGet which could maybe solve your issue)
I keep you informed.

Should a normal OrderBy not be like:
Select top 10 * from [pay].[table] order by id DESC instead of 3 desc ?

Hi,
We're having the same issue with dynamic sql order by in .NET Core 5.  What's strange is that everything works fine until I added 2 new columns to a sql server view, BillingIndLastName and BillingIndFirstName.  I'm able to filter using these two columns with ef core linq to sql, but the dynamic OrderBy throws an error ("No property or field 'BillingIndLastName' exists in type 'MyView'")  when I try to sort on these columns.  There is an object in the EF5 class for this view named BillingInd and a property named BillingIndId - so I'm not sure if that's related to the problem.  I will try to research more but will look for the EF5 nuget lib.  Thank you for this awesome library!

I've uploaded a preview for EF5 (Microsoft.EntityFrameworkCore.DynamicLinq 5.2.7-preview-03)
See https://www.myget.org/feed/Packages/system-linq-dynamic-core

Should a normal OrderBy not be like:
Select top 10 * from [pay].[table] order by id DESC instead of 3 desc ?

The boilerplate use datatables.net and the order is made by the number of the column. If the translated into  order by 3 DESC instade of that will solve the problem order by (SELECT 3) DESC

As far I can see, this code
var orderBy3 = context.Cars.OrderBy("3 DESC").ToList();

Does compile, however no order by is executed because the generated SQL does not have an order by generated:
SELECT [c].[Key], [c].[Brand], [c].[Color], [c].[DateDeleted], [c].[DateLastModified], [c].[Extra], [c].[NullableInt], [c].[Vin], [c].[Year]
      FROM [Cars] AS [c]

Yes, you have right,  the .OrderBy("3 DESC")  do nothing , but after that I have PageBy()  and there is set the ORDER BY (SELECT 1) clause.
But in the previous verison of ef core this works fine OrderBy("3 DESC")

OK. Closing this issue.
@njsent If you still have questions, raise a new issue regarding this.

I've uploaded a preview for EF5 (Microsoft.EntityFrameworkCore.DynamicLinq 5.2.7-preview-03)
See https://www.myget.org/feed/Packages/system-linq-dynamic-core

Unfortunately the new version did not fix the problem but I was able to solve the problem by SELECTing the last & first columns.  These two columns were only used for dynamic OrderBy previously so I'm not sure if it's even related to .net core 5.0 or if I just have to always SELECT the columns that are used for dynamic OrderBy.  I really appreciate you putting the 5.0 lib up so quickly anyway.

https://github.com/zzzprojects/System.Linq.Dynamic.Core/pull/470


Upgrade minimum version of solc to ^0.8.18.

Slither is becoming an increasingly useful tool for analyzing smart contracts and recognizing vulnerabilities within them.
When running this tool against the smart contracts in this codebase, it returns several vulnerabilities pertaining to the solidity compiler version used.

Namely, v0.8.8 contains this bug (documented here):
{
   "uid": "SOL-2021-4",
    "name": "UserDefinedValueTypesBug",
    "summary": "User defined value types with underlying type shorter than 32 bytes used incorrect storage layout and wasted storage",
    "description": "The compiler did not correctly compute the storage layout of user defined value types based on types that are shorter than 32 bytes. It would always use a full storage slot for these types, even if the underlying type was shorter. This was wasteful and might have problems with tooling or contract upgrades.",
    "link": "https://blog.soliditylang.org/2021/09/29/user-defined-value-types-bug/",
    "introduced": "0.8.8",
    "fixed": "0.8.9",
    "severity": "very low"
},

Hence, we can get rid of the warnings from slither and enhance the security of projects that implement this codebase by upgrading the smart contracts to require a more secure version of the solidity compiler (I.E. the proposed 0.8.18 found within these commits).

Old versions are allowed by design.  Imagine a situation where a developer wants to use SS alongside a third-party library which is tied to a single version.  It's preferable to allow the developer to choose a version that works with both libraries, with the understanding that they take responsibility for verifying that the chosen version is safe.  If SS is strictly incompatible with some third-party libraries, the developer is probably going to copy/paste code and update the pragma rather than import, which is generally worse.
With that said, I don't think we need to support versions as old as 0.8.0.  Version 0.8.8 is set for files which use features introduced in that version, but this is also an arbitrary choice.  Is there a particular reason you chose 0.8.18?

Nobody has indicated that this breaking change would inconvenience them, so I'm willing to merge it.  But first I'd like to add a test to ensure that the pragma statement remains consistent across all files, especially when outstanding pull requests are merged.  It would look sort of like the tests in internal.ts and sources.ts.

Nobody has indicated that this breaking change would inconvenience them, so I'm willing to merge it. But first I'd like to add a test to ensure that the pragma statement remains consistent across all files, especially when outstanding pull requests are merged. It would look sort of like the tests in internal.ts and sources.ts.

Apologies, I had meant to reply to your original message.
The choice for 0.8.18 was for the sake of satisfying the slither check. It sees that version as the most stable/secure. I imagine as time goes on that this will change and we will need to update this repository accordingly. This shouldn't usually shouldn't require breaking changes, but will be a pain to keep up to date all the time.
However, I do see your explanation for allowing older versions to be useful. When I worked in Unity, I made sure to support as many versions as possible (Just like solidity, the game engine itself had like 30+ version). I believe with Solidity it is a bit different though as the security obtained from restricting to newer versions would be a large enough benefit. Still new to OSS, so I don't know the best plan of action. Maybe there is a way to appease both sides of aisle?

I added the test mentioned above.  Need to find a place to define the 0.8.18 value other than in the test itself.  It still feels very arbitrary.

Modified the test to avoid the issue mentioned above.  I'll merge this, but no guarantee that we'll stay up-to-date with the Slither-recommended Solidity version in the future.  Thanks for the contribution.


Error: 'python3.10' runtime is not supported

$ sam build && sam deploy --guided
Building codeuri: /home/ec2-user/workspace/serverless-summarize-foundational-model/handlers/transformer runtime: python3.10 metadata: {} architecture: arm64 functions: TextTransformerFunction
Build Failed
Error: 'python3.10' runtime is not supported

@twocoins-ca Do you have the latest version of SAM CLI?

updated and it is better but still got the following issue:
Endpoint jumpstart-dft-hf-text2text-flan-t5-xxl of account<PHONE_NUMBER>16 not found. (Service: SageMakerRuntime, Status Code: 400, Request ID: b08078b1-f39a-4c76-b518-35e0940637c2)
Any quick tip?

@twocoins-ca You will need your own version of FM running in Sagemaker. Mentioned here https://github.com/aws-samples/serverless-summarize-foundational-model#prerequisites


updating JSON file

Hi
if i add a new object using put_one.php file , In which file its getting update ,
Please Can you tell me the file location

Sorry  for this question,
I read the documentation and i got all the details
Thanks.


Amount of embeddings

Hello! We are continuing to study your project. I would like to know when we combine tokens of two modalities, such as text (1 x 768) and pictures (1 x 768), then we get a token using torch.concat (2x768).
features = torch.concat([text_tokenizer(text), image_tokenizer(image)],dim=1)
Then, after the encoder, we get a 2x768 embedding. But since both the text and the picture belong to the same data line, we would like to get a 1x768 embedding. How to do it?

Following common practice, we propose to concat these two embeddings, if your target is to merge or fuse these two embeddings, you can try plus, dot product, convolution operations.


MlModelResourceTest fails

3 tests fail due to naming:
MLModel instance for 216bda15-8db9-4539-84de-ce554d182f63 not found

versus
MlModel instance for 216bda15-8db9-4539-84de-ce554d182f63 not found

Note L versus l

missed that, thanks @tomtor

Morning @tomtor, could you please provide a bit more info on the issue? I just ran mvn clean test in a fresh branch and it is working properly for me.
In this PR https://github.com/open-metadata/OpenMetadata/pull/1288 we changed all the naming and the CI tests ran properly for MlModels
2021-11-20T16:03:24.0794439Z [INFO] Tests run: 28, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 18.423 s - in org.openmetadata.catalog.resources.mlmodels.MlModelResourceTest

Thanks

Morning @pmbrull
I did a checkout of latest main and a clean rebuild and the error is gone now.
So, it's fine. Probably some artifact was not rebuild.
Sorry for the false alarm.

Hi, @tomtor,
Happy to hear! Please, do not hesitate to report any issues or questions you might have.
Thanks!