Move DNS debugging page back to cluster administration

DNS resolution is a task in the control plane rather than application layer.
closes: #21930

Page preview:
https://deploy-preview-21933--kubernetes-io-master-staging.netlify.app/docs/tasks/administer-cluster/dns-debugging-resolution/

Hi @tengqm .
This page is reverting this change?
https://github.com/kubernetes/website/pull/21166/

@kbhawkey Partially revert. It is not reverting the tweaking to the text. It is moving the page back to the directory to which it belongs.

I just read through the comments in issue #21930.
Here are the current pages:
https://kubernetes.io/docs/tasks/access-application-cluster/
https://kubernetes.io/docs/tasks/administer-cluster/
I suggest to look at the current pages under each folder and decide if the folders help categorize the task pages (for the reader). Do most pages under administer-cluster focus on administration?
What kind of tasks are represented by access-application-cluster? I find this name less obvious.

@kbhawkey Indeed. For example, the page https://kubernetes.io/docs/tasks/administer-cluster/access-cluster-api/ doesn't look like an administration task, and it should go to the other directory.

I'd probably group cluster networking tasks and DNS tasks into one section. How does that sound?

Going forward, I suggest to:

move this page to administer_cluster so that DNS pages are located under the same folder and the failing links are corrected.
log an issue to investigate whether there should be a new folder created specifically for DNS and cluster networking tasks
log an issue to possibly move the other DNS task page from tasks/access-application-cluster

/lgtm

If there is still more to discuss, feel free to hold this PR.

@kbhawkey @sftim Consolidating networking and DNS into a subgroup is a good idea. Let's ensure we add redirect entries in such PRs. We are seeing some broken links from some "downstream" projects.

Is this good to move forward and log an issue to create a new folder/sub-folder?

/approve

If I get time I will also check for redirects that now need to be undone.


Error on acceptance tests

Describe the bug
Verify multiple apps dir can be added to the cluster using single repo for wego config [It]
  /home/runner/work/weave-gitops/weave-gitops/test/acceptance/test/add_tests.go:807

  Expected success, but got an error:
      <*errors.errorString | 0xc000028be0>: {
          s: "Error: Failed to find the resource nginx-r2li0n of type deploy, timeout reached",
      }
      Error: Failed to find the resource nginx-r2li0n of type deploy, timeout reached

  /home/runner/go/pkg/mod/github.com/onsi/gomega@v1.14.0/internal/assertion/assertion.go:38

Environment

wego: [e.g. v0.1.0]
kubernetes:  [e.g. 1.20.4]

[ ] KinD - version]
[ ] k3s - version
[ ] cloud [e.g., EKS, AKS]  version
[ ] other - name version

Browser + version: [e.g. chrome 74, safari 12, firefox 87]

Affects versions
To Reproduce
Steps to reproduce the behavior:

Go to '...'
Click on '....'
Scroll down to '....'
See error

Expected behavior
A clear and concise description of what you expected to happen.
Config and Logs
If applicable, add logs to help explain your problem. please compress the output before attaching

[ ] wego config
[ ] wego cli call output (and parameters)
[ ] wego-controller logs
[ ] Events from wego-* namespaces
[ ] kubectl cluster-info dump
[ ] Prometheus alerts

Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.

The actual problem seems to be flaky results due to corrupt binary by other builds


Profile card scrollable on small devices

Issue

close #703

Overview (Required)

Made the profile card scrollable on small devices (when the height is low).

Links

Screenshot (Optional if screenshot test is present or unrelated to UI)

Before
After

Movie (Optional)

Before
After

Sorry, could you please resolve the conflict?

Resolved!

Thanks!


add missing input.json to transformer example

What this PR does / why we need it:
Add missing input.json for transformer example
Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #
Special notes for your reviewer:

Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.

Release note:

thanks @jzhoucliqr !
/lgtm
/approve


[msgvote]

Add per server emojis for up/down votes.

A good suggestion. It will get added at some point, likely when I finish porting the cog for Red v3.

Hello, this was just merged into the v3 branch. Please update the cog and give it a try.


Changes

🛠 Fixes issue #
📇 Changes proposed
✅ Check List (Mark all the applicable boxes)

[ ] My code follows the code style of this project.
[ ] This PR does not contain plagiarized content.
[ ] This PR contains changes in the documentation
[ ] This PR contains changes in the Code of the project
[ ] The title of my pull request is a short description of the requested changes.

📄 Note to reviewers

📷 Screenshots

yeah ok, I was not aware of adding new commits in the same PR, I will send new one with new commits, if no problem


Title not set in template parameters when editing person

Display all persons.
Pick a person.
Edit (e.g., go to http://<IP_ADDRESS>:8000/workshops/person/100/edit).
View source.

If you have #140, you will see XXX-unset-variable-XXX as the page title, because title isn't included in the context used when the page is expanded.  How should title be set when editing?  The editing form is auto-generated from PersonUpdate(UpdateView).

Hey, @gvwilson, I don't have much experience with class-based views, but it seems like ContextMixin is a solution:
https://docs.djangoproject.com/en/1.7/topics/class-based-views/mixins/#context-and-template-responses
Here's sample usage:
https://docs.djangoproject.com/en/1.7/ref/class-based-views/mixins-simple/#django.views.generic.base.ContextMixin.get_context_data
We can basically inherit ContextMixin as, for example, UpdateViewContextMixin that provides proper title:
class UpdateViewContext(UpdateView, ContextMixin):
    def get_context_data(self, **kwargs):
        context = super(ContextMixin, self).get_context_data(**kwargs)
        context['title'] = str(self.object)  # from UpdateView
        return context

Then we can use UpdateViewContext instead of UpdateView, I think.

Hi Piotr,
Doesn't work for me.  Grab #143 (which isolates this change), and look at:
class PersonUpdate(UpdateView, ContextMixin):
     model = Person
     fields = '__all__'
     pk_url_kwarg = 'person_id'

     def get_context_data(self, **kwargs):
         context = super(UpdateView, self).get_context_data(**kwargs)
         context['title'] = str(self.object)
         return context

The title is still 'XXX-unset-variable-XXX.  If I change the super
call to super(ContextMixin, self), Python complains that there's no
such method.

Greg, it's definitely working for me:

What are your Python and Django versions? I'm using:
Python 2.7.9 :: Continuum Analytics, Inc.
Django 1.7.1

I believe you should invoke super() in this way:
    def get_context_data(self, **kwargs):
        context = super(PersonUpdate, self).get_context_data(**kwargs)
        context['title'] = str(self.object)  # from UpdateView
        return context

The change is that in your code you had super(UpdateView, self), here it's super(PersonUpdate, self).
I'm still advocating for using a new class-based view that I wrote in previous post (there's an error linked to using super() that I fixed in code below):
class UpdateViewContext(UpdateView, ContextMixin):
    def get_context_data(self, **kwargs):
        context = super(UpdateViewContext, self).get_context_data(**kwargs)
        context['title'] = str(self.object)
        return context

I tried this and it worked. Cheers!

Hi Piotr,
Can you submit a PR with your version and I'll try it here?
Thanks,
Greg

Python 2.7.8 |Anaconda 2.1.0 and django.VERSION = (1, 7, 1, 'final', 0)
And I tried both the super(PersonUpdate, self) and the
UpdateViewContext that you advocated - failed the same way.

Greg, I sent you https://github.com/gvwilson/amy/pull/11.

Yup, I replied - fixes the title, but breadcrumbs are still not set.
Separate bug?

Greg,
yeah there are some minor bugs with breadcrumbs. I'd go ahead and merge this PR and let me squash these bugs.
Cheers

Thanks - I fixed some things in the adding-tests branch (in particular,
escaping characters in breadcrumb text), so you might want to start from
there.  I'll go ahead and merge in your title-fixing PR.
Thanks,
Greg

p.s. should UpdateViewContext be used as a parent for all other editing
views?  And is something equivalent needed for the creation views?

Yes, unless we have to use some specific template variables other than title. In that case, we should directly inherit ContextMixin
Yes, I can see some XXX-unset-variable-XXX in title when creating a new person.

Thanks - can you please update the ones that need updating? I think
title will be enough, and I'm building tests to catch other cases that
might slip through.
Thanks,
Greg


Admin event editing

Functionality for admins to swipe left on event to delete and swipe right to edit

Outdated issue.


Support both lab and notebook

Rewritten using mimerender-cookiecutter. Tested and working in both notebook 4.3 and lab 0.12.1.

Quick note in case you hadn't seen it, the PR is failing a test... Would love to see this working across classic/lab, thx!!

@jasongrout The build is failing with:
rake aborted!
No Rakefile found (looking for: rakefile, Rakefile, rakefile.rb, Rakefile.rb)
/home/travis/.rvm/gems/ruby-1.9.3-p551/bin/ruby_executable_hooks:15:in `eval'
/home/travis/.rvm/gems/ruby-1.9.3-p551/bin/ruby_executable_hooks:15:in `<main>'
(See full trace by running task with --trace)
The command "rake" exited with 1.

Is this because Travis is not set up?

It looks like it. I think the relevant error is Could not find .travis.yml, using standard configuration..
Are there tests that Travis is supposed to run?

@jasongrout Nope, I don't think any tests are set up for this repo.

@jasongrout I'd like to get this merged but I don't know how to configure or disable Travis for this repo. Can you help?

@gnestor, I disabled it on Travis and added you to the committers team on the repo.

Thanks @blink1073!


Adding extra packages since they are needed by RDMA-CORE for issue #10

I have updated the docker file and the documentation regarding the missing packages; this fixes issue #10

This has been addressed in other commits.


Event registration system

How to register participants for a hackathon is a very common question with a rather stubborn answer.
Currently there is a simple way to use Dribdat to keep track of who has registered for an event: simply log in for a user account JOIN any challenge that has been posted to the event site. There is a Participants link at the bottom of the Events page which takes you to a page like this for an overview of who's coming. This has not been widely tested, could use some design improvements, and the main problem with this is the still quite lousy auth in place and until #150 is resolved I wouldn't suggest this to everybody.
A simple TypeForm or Google Form works well for many events, though it is nice for people to have something like Doodle.ch, Tipo.ch or Eventbrite to be able to cancel their tickets. There are open source ticketing platforms that we could look into connecting to the project.
Any recommendations?

Any recommendations?

Eventbrite integration would be awesome

Eventbrite has an API which supports OAuth 2, and I can see this should be reasonably straight forward to use it to enable log-in to Dribdat. Do you mean anything else by "integration", @gonzalocasas ?

The typical use case here seems to be to compare the lists of registrants. I'm not sure there is enough friction here to warrant much more effort than a more prominent "Register now!" button, which I've just added.


Ensure that s3 bucket is created

Without the creation of report bucket:
Generation of presigned URL will not fail. But client will fail during creation of s3 object:
<?xml version="1.0" encoding="UTF-8"?><Error>NoSuchBucket<Message>The specified bucket does not exist</Message><BucketName>slipstream-reports</BucketName><RequestId>c8b30139-8fbe-4ac8-bbe7-3ef4f5b9c0a8</RequestId><HostId>c8b30139-8fbe-4ac8-bbe7-3ef4f5b9c0a8</HostId></Error>%```

We have to manage report external object case and also others for new external object template

Implemented here https://github.com/slipstream/SlipStreamServer/pull/1454/commits/872d15f6e21d43b40f998833d869dc16f79ebf3f


Add in ICEES for rule mining?

Right now, none of our rules make use of clinical data e.g. ICEES or COHD.   That's partly because we don't have those data in the graph when we rule mine.   Since ICEES is served in automat we can presumably use ORION to easily create a combined robokop + icees for rule mining.
It may turn out that the rules still don't work - the correlative nature of ICEES may just not be helpful wrt these queries.   But at least we should try it.

Assigned Evan just for the creation of the graph.


Inconsistent execution bug

Steps to reproduce
output := ComObjCreate("WScript.Shell").Exec("powercfg /requests").StdOut.ReadAll()
MsgBox % output

Run from Sublime Text it will show an incorrect output, different from the output of running powercfg /requests from a command prompt. Run by clicking on the .ahk file it will show the correct output.
Also described in ComObjCreate("WScript.Shell").Exec("powercfg /requests") returns different output than actual command run in command prompt : AutoHotkey
Fix
Using AutoHotkeyU32.exe / AutoHotkeyA32.exe on x64 systems runs into this bug.
Changing to a 64-bit executable fixes it.
AutoHotkey.sublime-settings
{
  "AutoHotKeyExePath":
  {
    "default": "C:\\Program Files\\AutoHotkey\\AutoHotkey.exe"
  }
}

Fixed with Commit 8cc1631 - "ahkrun and ahkcompile allow targeting multiple ahk versions"

In my opinion fixing the bug would be to automatically pick the correct executable based on system architecture.


Problem with the example idtoken.php

When running the example "idtoken,php" I received the following error
"Undefined index: id_token in ...\Google\Auth\OAuth2.php on line 446"
I changed "id_token" to "access_token" (the only element containing data) only to receive the following error:
Fatal error: Uncaught exception 'Google_Auth_Exception' with message 'Wrong number of segments in token: ' in ...\Google\Auth\OAuth2.php on line 480
Any assistance much appreciated.

Hmm, I am wondering if we have insufficient scopes in that example. Can you change "email" in the scopes string to "profile" and see if that helps (and revert your id token -> access token change).

@ianbarber, Setting profile scope throws a 403 error for me. Any idea? P.S.: Every other thing works as usual.


Copy tables as CSV

Users may want to be able to copy tables in the CSV format. A new setting in the options page could be created for which table format to use.

If the user chooses to copy tables as CSV, they may also want more options, such as:

delimiter, e.g. ,
encapsulator, e.g. "
line terminator, e.g. \r\n
whether to quote all fields, quote fields minimally, or use some other quoting rule
whether to trim fields

These pages explain the CSV format:

RFC 4180 - Common Format and MIME Type for Comma-Separated Values (CSV) Files
Comma-separated values - Wikipedia
csv — CSV File Reading and Writing — Python 3.12.4 documentation


opt Add object ID in expression and use it as hash code

Proposed changes
This pull request introduces a change to the expression evaluation mechanism to improve the stability of hash values. By incorporating the object ID into the expression and using it as the hash code, we can avoid scenarios where the hash value becomes unstable due to changes in the object's internal state or memory address.

run buildall

run buildall

run buildall

run buildall

run buildall

run buildall

run buildall


Add bohb support

Add BOHB-support. --file_format now accepts BOHB which will run CAVE for every budget explored in the optimization-process of BOHB.
Bugfixes:

catch fANOVA error on too few datapoints
add sanity checks for exceptional cases (e.g. with very few configs)
bind memory error in parallel coordinates by limiting configs available for epm-training
small bugfixes

@AndreBiedenkapp do you want to look at this before I merge?

Codecov Report

Merging #158 into development will decrease coverage by 1.22%.
The diff coverage is 15.82%.

@@               Coverage Diff               @@
##           development     #158      +/-   ##
===============================================
- Coverage        48.27%   47.05%   -1.23%
===============================================
  Files               26       27       +1
  Lines             2703     2818     +115
===============================================
+ Hits              1305     1326      +21
- Misses            1398     1492      +94

Impacted Files
Coverage Δ

cave/plot/algorithm_footprint.py
60.37% <ø> (ø)
:arrow_up:

cave/analyzer.py
33.08% <0%> (-2.33%)
:arrow_down:

cave/plot/cost_over_time.py
15.74% <0%> (ø)
:arrow_up:

cave/cavefacade.py
32.43% <0%> (-0.64%)
:arrow_down:

cave/plot/parallel_coordinates.py
13.71% <0%> (-0.24%)
:arrow_down:

cave/utils/converter/hpbandster2smac.py
24.61% <24.61%> (ø)

cave/cave_cli.py
78.81% <42.85%> (-5.3%)
:arrow_down:

cave/plot/configurator_footprint.py
86.98% <50%> (-0.71%)
:arrow_down:

Continue to review full report at Codecov.

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


I want to be able to get the trimmed part of the body when editing - …

…using compose.dom('trimmed').val()
If there is a better way, please let me know.

I don't see the use for this myself, but I don't see any reason not to add it either.
That said, if you are adding new methods, please also add them to the documentation in README.md.

Forgot one final part: It also needs to be added to the typescript type-annotations in gmail.d.ts:
https://github.com/KartikTalwar/gmail.js/blob/4f0b48309fa0d8f3c1fee3d3fffa7bd89df877f0/src/gmail.d.ts#L486-L488
And a final question (because I'm obviously going to test this before I merge), what is the expected behaviour of this selector? What part of the compose dialogue is it supposed to extract?
Currently, with this email:

I'm getting these results:

Is that the expected value?

Hopefully this screenshot helps clarifying. There might be a better way to accomplish the same thing with existing functionality.

Yeah that seems to work. Thanks for clearing it up.
Before putting any more work into this, I was wondering if perhaps we could come up with a better name. In my opinion trimmed  is not very descriptive, and I certainly didn't understand what to look for.
What about quoted_reply instead?
If that's OK, feel free to update the code, the readme and the typescript definitions, and I think we can call it a day :smile:

Thanks. Merged!

Is there anyway to modify the quoted_reply in a way that is respected when the compose is sent?
Ie it looks like calling:
compose.dom('quoted_reply').val('FOOOO')

Does not in fact change the contents of the sent email message.


Updated AES CBC encryption/decrpytion and padding

Description

In the original code, the PKCS7Padding function always adds an extra block of padding for messages that are multiple of the AES blockSize. An "if statement" has been added to take care of that.
Also, in the PKCS7UnPadding function, an "if statement" has been added to take care of the condition when a message is empty, e.g message := "". In the current code, an empty message will cause a panic.
Finally, in AESEncryptCBC and AESDecryptCBC functions, changes are made to variable declaration.
Motivation and Context

Added code in PKCS7Padding function helps save to padding for plaintext messages with length of multiple of the AES blocksize.
Added code in PKCS7UnPadding function to prevent users from encrypting an empty message which will trigger a panic.
To satisfy compliance requirements.

How Has This Been Tested?
This only changes implementation of existing functions and existing unit test cases (primitives_test.go) cover these changes.
Checklist:

[X] I have added a Signed-off-by.
[X] I have either added documentation to cover my changes or this change requires no new documentation.
[X] I have either added unit tests to cover my changes or this change requires no new tests.
[X] I have run golint and have fixed valid warnings in code I have added or modified. This tool generates false positives so you may choose to ignore some warnings. The goal is clean, consistent, and readable code.

Signed-off-by:

Hi @itp4IBM, we have been talking/working exactly on this with @starsheriff as part of #1780 and following PR #2051.
We might have a few bunch of tests that can we useful to test and support this change/PR...

Moved my comment to #2093.

@itp4IBM Do you want to discuss this and #2093 over Slack, or shall I review these here? These need some work... but along with some other work that's in the making, we can do these together.

Hello @JonathanLevi . Let us discuss #2092 and #2093 over slack.
Thank you.

Hi,
if I may add some comments. The changes will break the tests we have prepared for #1780, so we would need to adjust them. If we include these changes before we accept this PR we could easily document the behavior before and after the changes.
The issue with the padding adding an extra block if the message is a multiple of aes.BlockSize came up there as well and I think changing that is a great idea. I would be ready to start a PR for #1780 right away.

hello @JonathanLevi:
Thank you for your comments.  I will update the code with your suggestions.

@itp4IBM  - I am not exactly sure what you were trying to fix here?  Maybe another way to say this is what led you to think this is a problem?

Hello Mr. Singh, @mastersingh24:
The changes made to CBC Encryption/Decryption was an attempt to remediate the compliance issue.
The changes made to PKCS7Padding/UnPadding aims to improve the efficiency of the decryption/encryption step.
Thank you.

@itp4IBM what compliance issue? there's nothing but a vague assertion mentioned. compliance with what?

@itp4IBM I think that a test/test-case (or a few) will make it easier for you to present the change/proposal, and clearer us for us to evaluate/review...

@itp4IBM Can you please also elaborate on the second point too? That is, how do The changes made to PKCS7Padding/UnPadding aims to improve the efficiency of the decryption/encryption step?
Improving efficiency is what way? Is this a proposal for a better/faster/more-compact padding /encryption scheme?

@christo4ferris It is a legal issue because the method that was changed had a non-apache license.  This was just discovered.

@JonathanLevi . The purpose of the padding is to make the plaintext a multiple of 16 bytes. But the original code would add 16-byte padding to plaintexts of all lengths. The padding and unpadding does consume some computation time. For a large number of transactions where encryption/decryption that needs to be done, this could add extra time.
Thank you.

(Good morning) Yes, I wasn't sure at first whether this was the intended behavior or an oversight. Thank you for confirming @itp4IBM.
OK, so a few things:

The computation load/time it takes to add an extra (AES blocksize=) 16 bytes to the 'payload' is negligible compared to the computation required for the encryption/decryption.

I think these are your first PRs to fabric. I do not want to come across as too 'harsh', quite the opposite. I wish we had an open issue against which these 2 PRs were submitted, as then I would have been able to discuss this earlier.

While I have been told that this code/PR has been reviewed by others, please appreciate that I will be doing many people (/several Hyperledger projects?) a dis-service if I give my thumbs-up to this: These two naive looking changes make us not comply with the standard AES/PCKS#7 standard.

Even if people believe/told you that it is fine having this 'faster' version of AES/Padding (as fabric shares this crypto code both in the client and server...) we won't be able to interoperate with the rest of the world.
For example, think about Membership Services issuing x.509 certificates that only 'fabric' can produce/read or parse.

(Good morning) Yes, I wasn't sure at first whether this was the intended behavior or an oversight. Thank you for confirming @itp4IBM.
OK, so a few things:

The computation load/time it takes to add an extra (AES blocksize=) 16 bytes to the 'payload' is negligible compared to the computation required for the encryption/decryption.

I think these are your first PRs to fabric. I do not want to come across as too 'harsh', quite the opposite. I wish we had an open issue against which these 2 PRs were submitted, as then I would have been able to discuss this earlier.

While I have been told that this code/PR has been reviewed by others, please appreciate that I will be doing many people (/several Hyperledger projects?) a dis-service if I give my thumbs-up to this: These two naive looking changes make us not comply with the standard AES/PKCS#7 standard [I'll add a reference below]

Even if people believe/told you that it is fine having this 'faster' version of AES/Padding (as fabric shares this crypto code both in the client and server...) we won't be able to interoperate with the rest of the world.
For example, think about Membership Services issuing x.509 certificates that only 'fabric' can produce/read or parse.

@JonathanLevi reference missing? what behavior does the standard require? Is this your concern:
" If some of your messages require padding, then you will have to add some sort of padding systematically, otherwise decryption will be ambiguous." http://security.stackexchange.com/questions/29993/aes-cbc-padding-when-the-message-length-is-a-multiple-of-the-block-size

[@christo4ferris, sorry I was just typing this at the same time, yes!]
See RFC2315, PKCS #7: Cryptographic Message Syntax, v1.5, 1998.
Page 21:
Some content-encryption algorithms assume the input length is a multiple of k octets, where k > 1, and let the application define a method for handling inputs whose lengths are not a multiple of k octets. For such algorithms, the method shall be to pad the input at the trailing end with k - (l mod k) octets all having value k - (l mod k), where l is the length of the input.
In other words, the input is padded at the trailing end with one of the following strings:
                     01 -- if l mod k = k-1

                  02 02 -- if l mod k = k-2
                      .
                      .
                      .
            k k ... k k -- if l mod k = 0

The padding can be removed unambiguously since all input is padded and no padding string is a suffix of another. This padding method is well-defined if and only if k < 256; methods for larger k are an open issue for further study.

So specifically, this line
k k ... k k -- if l mod k = 0

is how this padding works (rule of thumb/when in doubt in AES-CBC: 'we are always padding' => when it's a multiple (k=0) we append a full block.
The original code is/was doing the right thing, adding an extra block when k=0.

[@christo4ferris, sorry I was just typing this at the same time, yes!]
See RFC2315, PKCS #7: Cryptographic Message Syntax, v1.5, 1998.
Page 21:

Some content-encryption algorithms assume the input length is a multiple of k octets, where k > 1, and let the application define a method for handling inputs whose lengths are not a multiple of k octets. For such algorithms, the method shall be to pad the input at the trailing end with k - (l mod k) octets all having value k - (l mod k), where l is the length of the input.
In other words, the input is padded at the trailing end with one of the following strings:

                     01 -- if l mod k = k-1

                  02 02 -- if l mod k = k-2
                      .
                      .
                      .
            k k ... k k -- if l mod k = 0

The padding can be removed unambiguously since all input is padded and no padding string is a suffix of another. This padding method is well-defined if and only if k < 256; methods for larger k are an open issue for further study.

So specifically, this line
k k ... k k -- if l mod k = 0

is how this padding works (rule of thumb/when in doubt in AES-CBC: 'we are always padding' => when it's a multiple (k=0) we append a full block.
The original code is/was doing the right thing, adding an extra block when k=0.

so, the only think that might need addressing is the empty message panic? Or, should this PR simply be closed.

@christo4ferris I'm looking...

@christo4ferris Assuming you/we are referring to the below as the panic... than the original code core/crypto/primitives/aes.go#L54-L55, returning nil with an error:
if unpadding > aes.BlockSize || unpadding == 0 {
		return nil, fmt.Errorf("invalid padding")

is/was also correct.
Since the standard states/dictates that we always pad, we cannot 'not unpad'. Therefore, we should not return the plaintext, raising/flagging an error is the standard. It's not really a panic, it's more of a correct reporting.
p.s. There is another check in the CBCEncrypt/CBCDecrypt implementation as for the length, so the two tie up well together actually.

@smithbk, @itp4IBM how about we discuss/approach the (re)naming separately (in different issues/PRs)?
I agree that we could/should do some housekeeping in the core/crypto section. I think we can safely import other libraries with the appropriate licensing. Will happily spend some time on this with you two.

@JonathanLevi . Thank you for the reference to PKCS #7 padding.
I will close this PR and PR 2093. I will reach out to you regarding the renaming of the AES CBC functions.


JavaScript

JavaScript
User Story
As a boot camp student
I want the prework notes to be structured on a webpage
So that I can easily find and read the information
Acceptance Criteria
GIVEN a Prework Study Guide website
WHEN I view the study guide
THEN I can see the four topics I learned listed along with a suggestion on what I should study first

Added the JavaScript file to perform functions in the application.
Edited the final text of the site to include JavaScript notes.


fix: removed some stashed changed git output

accidentally commited stashed chnage merge issue, I just removed the git merge error output bit, not sure how this affects anything but thought I'd just get it open and visible for that

@aaronreed708 further to your Slack message I would appreciate it if you just did it and closed this. I thought it would be an easy one because it's simply removing accidental commit noise. At this point I have a few things going on, so taking that off my hands would be appreciated.

Per @toni-sharpe I addressed this in https://github.com/finos/a11y-theme-builder/pull/998 which has been merged.  So closing this PR.

Thanks for resolving this :-)


Better animation on data updates #3399 -

Hi @etimberg & @simonbrunel ,
related to live charts immediately had a new gulp build and some test after #3399 and found out a little problem: datasets.datas nicely render sliding right to left, but not graph ticks generated over a callback (data was already rendering nicely without latest PR too, just adding a linear easing on animation), getting rendered delayed to relative data value (no smooth sliding too).
on data update from Django we get cpu stats & timistamp, labels array populated only with :15, :30: :45 min:00
callback: function(value) {
    return value.toString().length > 0 ? value : null;

Any suggestion?
Mirko

Hi @MFlyer,
If your question is "how to animate labels horizontally", I don't think that Chart.js currently supports animation of scale elements. It would be a very great feature, but I suppose, not quite easy to implement :\

Hi @simonbrunel you're right, that was the one line question eheh :smile:
Here is a plunker example showing scale ticks rendering before animation ending: http://plnkr.co/edit/M92CwRGoJw5YJM6M9VpA?p=preview
Please check same example both on Chrome-Chromium and Firefox (no smoothing over Firefox)
Mirko

I don't have any good suggestion for the labels issue, @etimberg can confirm what is currently feasible. For smooth data animations, you need a duration a bit longer than the refresh rate (e.g. 1250ms for the chart animation.duration and 1000ms for setInterval()).

Thanks for suggestion about animation.duration
One question: why not having callback return null (so we have no ticks) and instead draw ticks inside animation onProgress?

At the moment scales are not affected by the easing (which is a number on the range [0, 1]) indicating how far along the animation is and so always draw on the first frame of the animation in their final position. I suppose it is possible to make it work, but it could get complicated.

Hi @etimberg ,
this seems to be an interesting issue, maybe I'll give it a shot :)
M.

@MFlyer sounds good

Hi @etimberg and @simonbrunel  , reading code from core.scale.js finally found why ticks & labels have wrong positions on a dynamic data chart:
On draw function every tick and label defines its x/y positions by getPixelForTick func, but x/y pos don't have any relationship with points[index_of_tick/label] x/y (data points array, don't know real var name), so it's all fine over a static chart (every chart point has a well defined pos equal to ticks/labels position) not on dynamic chart - points moving right to left from tick_xpos(n) to tick_pos(n-1) over z number frames each rendering a different position between n and n-1, while ticks/labels having only 2 states/pos/array indexes
Where to check for chart points array data / functions? Just to avoid reading again all chart.js modules :laughing: thx
Mods required over var pixel
		getPixelForTick: function(index, includeOffset) {
			var me = this;
			if (me.isHorizontal()) {
				var innerWidth = me.width - (me.paddingLeft + me.paddingRight); // <- OK
				var tickWidth = innerWidth / Math.max((me.ticks.length - ((me.options.gridLines.offsetGridLines) ? 0 : 1)), 1); // <- OK
				var pixel = (tickWidth * index) + me.paddingLeft; // <- Every tick position grounds on tick index and tickWidth, not current related chart point

				if (includeOffset) {
					pixel += tickWidth / 2;
				}

				var finalVal = me.left + Math.round(pixel);
				finalVal += me.isFullWidth() ? me.margins.left : 0;
				return finalVal;
			}
			var innerHeight = me.height - (me.paddingTop + me.paddingBottom);
			return me.top + (index * (innerHeight / (me.ticks.length - 1)));
		},

Hi @etimberg & @simonbrunel got it, enjoy this demo :wink:
http://plnkr.co/edit/KToiNLlBrQzBsO1cPDNU?p=preview
Going to PR asap
Mirko

@MFlyer that looks really nice. I'm excited to look at the PR

Hi @etimberg just one suggestion because had it working on the fly without reading all chart.js code:
How to correctly get _view / chart metadata from core.scale draw function?
Currently having
var meta = me.data.datasets[0]._meta[0]; //grab metadata
....
var xLineValue = meta.data[index]._view.x; //replaced getPixelForTick
labelX = meta.data[index]._view.x + optionTicks.labelOffset; //replaced getPixelForTick

Last 2 rows use _viex.x instead of getPixelForTick(), so we have real position during animations too, but probably there's a better way to query chart metadata and _view.
Pls note: Plunker example working with this code, while same built and used on a backbone context not working :/

Yup, getDatasetMeta is the correct method to use.
One thing I should note is that you can't guarantee that meta.data[index]._view.x; is a grid line. In a scatter chart, it definitely will not be.
What might be better would be to have the axes create an _model property like the elements and then transition it to _view and then draw from the views. That way the positions would only be determined once on update and then each frame of the animation would simply transition a little further towards the final value.

Update
Hi @etimberg ,
finally found why having issues over Rockstor projects graphs and i can confirm your doubts about _view.x : it works fine over a line graph and have an animated bar chart too, while we have a Uncaught TypeError: Cannot read property '_view' of undefined on a stacked bar chart with getDatasetMeta not collecting data (probably on other charts to)
My suggestion (to have smooth line charts / to be improved with future another PR):

We check if getDatasetmeta is ok and apply the _view.x way, otherwise have old getPixelForTick

Do you agree on this?

Update:
Over Rockstor backbone widgets solved (missing initial dataset data) plus if statement over Chart.js, checking for meta.data[index] (if ok use it, otherwise use old getPixelForTick - example horizontalbar chart)

Closing this as chartjs-plugin-streaming provides a solution for the real-time use cases like this.


Possible native WebP encoder?

https://www.reddit.com/r/golang/comments/1678nh0/native_webp_encoder_for_go
Is this what we've been waiting for?

ooh!  yeah, maybe!  Assigning this to myself to come back and take a look when I've got some time
https://git.sr.ht/~jackmordaunt/go-libwebp

ooh! yeah, maybe! Assigning this to myself to come back and take a look when I've got some time
https://git.sr.ht/~jackmordaunt/go-libwebp

Any chance it will be added?

@willnorris - Do you have any idea when this might be implemented?

I've added an experimental branch in #393, though my initial test results aren't great.   I'd love for others that are interested to give it a try and see how it works for them.

Wow thanks for that @willnorris!
Hmmmmm, just noticed that Hugo seems to be using this go library for webp encoding: https://github.com/webmproject/libwebp
Might be a better option?


New 310es shader - Muller's method

Related issue: #545
muller

Given a uniform vec3 polynomial representing the constants of a quadratic function, and a uniform vec3 initial_xvalues that represents the xvalues to begin the algorithm with (with initial_xvalues.y being the midpoint of [initial_xvalues.x, initialxvalues.z]), approximates a root of polynomial nearest to initial_xvalues by approximating using quadratic functions.
Uses a while loop
Math-heavy
Renders red if the test passes (the method finds the correct root, given a small margin of error), otherwise green

From some fuzz testing, this shouldn't be vulnerable to floating point issues and should give consistent results.

@jarikomppa could you please take a look at this one for stability (using the same CPU technique you used for other shaders)?  As mentioned in my above comment, it appears to be pretty stable.

Results from float and double implementations are equal.


Update README.md

Update link to paper

hey @bkmgit thanks a lot for noticing the broken link! The SOE tech report is a bit outdated with respect to the pre-print version of the paper that appeared in IPDPS'17. The working link is https://github.com/systemslab/popper-paper/raw/master/paper/paper.pdf, would it be possible to update the PR with this instead of the SOE tech report? thanks!

@ivotron Thanks. Updated link.

thanks a lot @bkmgit


Added keyboardType to cvv

Details

Added keyboardType to cvv

Fixed Issues

$ https://github.com/Expensify/App/issues/6748
Tests

Tested the keyboard type on all mobile platforms.

QA Steps

Go to settings -> Payments
Click on "Add Debit Card"
Focus on CVV field, ensure that it shows number pad.

Tested On

[x] Web
[x] Mobile Web
[x] Desktop
[x] iOS
[x] Android

Screenshots

Web

Mobile Web

Desktop

iOS

Android

:hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

🚀 Deployed to staging by @Julesssss in version: 1.1.21-2 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅

🚀 Deployed to production by @sketchydroide in version: 1.1.22-0 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅


Cursor type definition is wrong

Describe the bug
Cursor type definition is wrong
To Reproduce
const total = await this.db.countAsync(query) // type definition is Document<number> ?
const records = await this.db.findAsync(query).skip(skip).limit(limit) // type definition is Document<T[]> ?

Expected behavior
const total = await this.db.countAsync(query) // type definition is number
const records = await this.db.findAsync(query).skip(skip).limit(limit) // type definition is Document<T>[]

Actual behavior
const total = await this.db.countAsync(query) // type definition is Document<number> ?
const records = await this.db.findAsync(query).skip(skip).limit(limit) // type definition is Document<T[]> ?

The synchronized methods is normal

@ion1ze I understand that this is not perfect. However, this is due to a limitation of the way the async version of functions still allow you to call subsequent methods. I think it would be very hard to fix without a full rewrite of NeDB in TypeScript (which is on the roadmap !).
My suggestion : just explicitly type your variables, and typescript should accept it without problem.
const implicitTotal = await this.db.countAsync(query) // type is Document<number>, not great.

const explicitTotal: number = await this.db.countAsync(query) // type is number, TypeScript is happy with this.


Harmonize license blurbs

We should try to do a quick sweep through all of these and change them to the same text, which better reflects the actual copyright (which is held jointly by all libuv project contributors, per https://github.com/libuv/libuv/blob/v1.x/LICENSE#L1). For example, some say minor variations, such as:
/* Copyright libuv project and contributors. All rights reserved.
/* Copyright libuv contributors. All rights reserved.
# Copyright (c) 2013, Ben Noordhuis<EMAIL_ADDRESS>
Originally posted by @vtjnash in https://github.com/libuv/libuv/issues/4080#issuecomment-1632756828

The Copyright (c) 2013, Ben Noordhuis in the autotools files is because I lifted those from one of my other projects, although for the life of me I can't remember which one... anyway, it's fine to relicense them.

You will still hold the copyright to that part of the code, since you are a contributor


LangChain v0.3 not supported. For example, TestsetGenerator raise ExceptionInRunner with LangChain v0.3.

[x] I have checked the documentation and related resources and couldn't resolve my bug.

Describe the bug
LangChain recently released v0.3.When using LangChain v0.3, TestsetGenerator raises an ExceptionInRunner.
From v0.3, LangChain internally use pydantic v2. On the other hand, ragas internally uses langchain_core.pydantic_v1. This might be the cause of the error.
LangChain v0.3 migration guide is here.
https://python.langchain.com/docs/versions/v0_3/
Using LangChain v0.3 also introduces numerous potential errors, and it's necessary to update ragas to be compatible with LangChain v0.3.
Versions
I encountered this error on Google Colab.
!python --version
Python 3.10.12

!pip install langchain-core==0.3.0 langchain-openai==0.2.0 \
    langchain-community==0.3.0 ragas==0.1.14 nest-asyncio==1.6.0

ragas 0.1.18 (latest) also raise the same Error.
Code to Reproduce
Share code to reproduce the issue
import os
from google.colab import userdata

os.environ["OPENAI_API_KEY"] = userdata.get("OPENAI_API_KEY")

import nest_asyncio
from langchain_core.documents import Document
from langchain_openai import ChatOpenAI, OpenAIEmbeddings
from ragas.testset.evolutions import multi_context, reasoning, simple
from ragas.testset.generator import TestsetGenerator

documents = [Document(page_content="sample", metadata={"source": "sample"})]

for document in documents:
    document.metadata["filename"] = document.metadata["source"]

nest_asyncio.apply()

generator = TestsetGenerator.from_langchain(
    generator_llm=ChatOpenAI(model="gpt-4o-mini"),
    critic_llm=ChatOpenAI(model="gpt-4o-mini"),
    embeddings=OpenAIEmbeddings(),
)

testset = generator.generate_with_langchain_docs(
    documents,
    test_size=4,
    distributions={simple: 0.5, reasoning: 0.25, multi_context: 0.25},
)

Error trace
/usr/local/lib/python3.10/dist-packages/pydantic/_internal/_fields.py:132: UserWarning: Field "model_name" in _VertexAIBase has conflict with protected namespace "model_".

You may be able to resolve this warning by setting `model_config['protected_namespaces'] = ()`.
  warnings.warn(
/usr/local/lib/python3.10/dist-packages/pydantic/_internal/_fields.py:132: UserWarning: Field "model_name" in _VertexAICommon has conflict with protected namespace "model_".

You may be able to resolve this warning by setting `model_config['protected_namespaces'] = ()`.
  warnings.warn(
/usr/local/lib/python3.10/dist-packages/ragas/metrics/__init__.py:1: LangChainDeprecationWarning: As of langchain-core 0.3.0, LangChain uses pydantic v2 internally. The langchain_core.pydantic_v1 module was a compatibility shim for pydantic v1, and should no longer be used. Please update the code to import from Pydantic directly.

For example, replace imports like: `from langchain_core.pydantic_v1 import BaseModel`
with: `from pydantic import BaseModel`
or the v1 compatibility namespace if you are working in a code base that has not been fully upgraded to pydantic 2 yet. 	from pydantic.v1 import BaseModel

  from ragas.metrics._answer_correctness import AnswerCorrectness, answer_correctness
/usr/local/lib/python3.10/dist-packages/ragas/metrics/__init__.py:4: LangChainDeprecationWarning: As of langchain-core 0.3.0, LangChain uses pydantic v2 internally. The langchain.pydantic_v1 module was a compatibility shim for pydantic v1, and should no longer be used. Please update the code to import from Pydantic directly.

For example, replace imports like: `from langchain.pydantic_v1 import BaseModel`
with: `from pydantic import BaseModel`
or the v1 compatibility namespace if you are working in a code base that has not been fully upgraded to pydantic 2 yet. 	from pydantic.v1 import BaseModel

  from ragas.metrics._context_entities_recall import (
---------------------------------------------------------------------------
ExceptionInRunner                         Traceback (most recent call last)
<ipython-input-3-e09f8b7c4199> in <cell line: 14>()
     12 )
     13
---> 14 testset = generator.generate_with_langchain_docs(
     15     documents,
     16     test_size=4,

2 frames
/usr/local/lib/python3.10/dist-packages/ragas/testset/docstore.py in add_nodes(self, nodes, show_progress)
    251         results = executor.results()
    252         if not results:
--> 253             raise ExceptionInRunner()
    254
    255         for i, n in enumerate(nodes):

ExceptionInRunner: The runner thread which was running the jobs raised an exeception. Read the traceback above to debug it. You can also pass `raise_exceptions=False` incase you want to show only a warning message instead.

Expected behavior
Generating testset success without any Error.
Additional context
Based on my investigation, I found that at least the implementation of default values for the Document class and Node class in ragas/testset/docstore.py is causing incorrect behavior.
https://github.com/explodinggradients/ragas/blob/c40891bf168de3124c845b75af31ed557eb79709/src/ragas/testset/docstore.py#L31-L33
https://github.com/explodinggradients/ragas/blob/c40891bf168de3124c845b75af31ed557eb79709/src/ragas/testset/docstore.py#L82-L86
For example, the embedding of Document is supposed to have None as its default value. However, for some reason, an instance of a Field object is being set instead. As a result, in the following section, the condition "n.embedding is None" is evaluated as False, leading to incorrect behavior.
https://github.com/explodinggradients/ragas/blob/c40891bf168de3124c845b75af31ed557eb79709/src/ragas/testset/docstore.py#L233
It seems that using langchain_core.pydantic_v1 is also causing issues with the values of Fields in classes that inherit from BaseModel.
Same error issue
The same error is described in the following issue.
https://github.com/explodinggradients/ragas/issues/1319

I'm having the same issue as well!

@frieda-huang Which filetype are you trying for test data generation. Is it pdf ?

Hey, We will take a look at this soon. We are also preparing to release a new and improved version of test data generation with v0.2 release (in 2 weeks) https://github.com/explodinggradients/ragas/pull/1321

thanks a lot for bringing this up 🙌🏽. the current strategy for the fix is as follows

The new langchain v0.3 will break the current usage of metrics. the plan for actions is as follows

for ragas<0.2 we will pin langchain_core to <0.3
for ragas>0.2 we will directly depend on pydantic>=2

cut a new release with the dependency as well

Yes.
On Wed, Sep 18, 2024 at 12:33 AM Akshay Wanje @.***>
wrote:

@frieda-huang https://github.com/frieda-huang Which filetype are you
trying for test data generation. Is it pdf ?
—
Reply to this email directly, view it on GitHub
https://github.com/explodinggradients/ragas/issues/1328#issuecomment-2357474632,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/A5VHN6E6IT7HPIJ3NEF2C7DZXD7B5AVCNFSM6AAAAABOMQOOB2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGNJXGQ3TINRTGI
.
You are receiving this because you were mentioned.Message ID:
@.***>

@frieda-huang I am also stuck at the same thing since 2 days. I don't know if ragas support pdf file ingestion for test data generation. convert that pdf to txt file and try it is working.

@frieda-huang I am also stuck at the same thing since 2 days. I don't know if ragas support pdf file ingestion for test data generation. convert that pdf to txt file and try it is working.

Test data generation on PDFs works for me, but it's super slow. I'm generating test data from 3 papers based off CVPR 2019 Papers. I'm using open-sourced models, so the output is not ideal but somewhat useful.
My code looks something like this:
from langchain_community.document_loaders import DirectoryLoader
from langchain_ollama import OllamaLLM
from ragas.testset.evolutions import multi_context, reasoning, simple
from ragas.testset.generator import TestsetGenerator
from langchain_community.embeddings import HuggingFaceInferenceAPIEmbeddings

loader = DirectoryLoader(DATA_DIR)
docs = loader.load()

llm_model = "llama3.1:8b-instruct-fp16"
llm = OllamaLLM(model=llm_model)

embed_model = "sentence-transformers/all-MiniLM-l6-v2"
embeddings = HuggingFaceInferenceAPIEmbeddings(
    api_key=HF_API_KEY,
    model_name=embed_model,
)

generator = TestsetGenerator.from_langchain(
    generator_llm=llm, critic_llm=llm, embeddings=embeddings
)

testset = generator.generate_with_langchain_docs(
    docs,
    test_size=20,
    distributions={simple: 0.5, reasoning: 0.25, multi_context: 0.25},
)

df = testset.to_pandas()
df.to_csv("testset_output.csv", index=False)

Output looks like follows:
learning rule deﬁned as a function of the perceptual prediction error deﬁned in Section 3.2 and is deﬁned as\n\nλlearn = \uf8f1 \uf8f4\uf8f2\n\n− t λinit, EP (t) > µe t λinit, EP (t) < µe otherwise\n\n∆ ∆+ λinit,\n\n\uf8f4\uf8f3\n\n− t , ∆+\n\nt and λinit refer to the scaling of the learning where ∆ rate in the negative direction, positive direction and the ini- t2 tial learning rate respectively and µe = 1 t1 EP dEP . The learning rate is adjusted based on the quality of the predictions characterized by the perceptual prediction er- ror between a temporal sequence between times t1 and t2, typically deﬁned by the gating signal.. The impact of the adaptive changes to the learning rate is shown in the quan- titative evaluation Section 4.4, where the adaptive learn- ing scheme shows improvement of up to 20% compared to training without the learning scheme.\n\nt2−t1\n\nR\n\n3.5.

@frieda-huang  Did you face connection timeout issue while running the models
ConnectError: All connection attempts failed
The above exception was the direct cause of the following exception:
ConnectError                              Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/httpx/_transports/default.py in map_httpcore_exceptions()
87
88         message = str(exc)
---> 89         raise mapped_exc(message) from exc
90
91
ConnectError: All connection attempts failed

@frieda-huang Did you face connection timeout issue while running the models ConnectError: All connection attempts failed
The above exception was the direct cause of the following exception:
ConnectError Traceback (most recent call last) /usr/local/lib/python3.10/dist-packages/httpx/_transports/default.py in map_httpcore_exceptions() 87 88 message = str(exc) ---> 89 raise mapped_exc(message) from exc 90 91
ConnectError: All connection attempts failed

I didn't now, but it's behaving very weirdly. I'm now generating 50 tests based on 10 papers. I let my laptop (Apple M2) run throughout the night, it's still on 32% in generation. It would sometimes tell me generation fails and return None and then progress more in generation.

@frieda-huang Did you face connection timeout issue while running the models ConnectError: All connection attempts failed
The above exception was the direct cause of the following exception:
ConnectError Traceback (most recent call last) /usr/local/lib/python3.10/dist-packages/httpx/_transports/default.py in map_httpcore_exceptions() 87 88 message = str(exc) ---> 89 raise mapped_exc(message) from exc 90 91
ConnectError: All connection attempts failed

New Update:
I got the following error after 10 hours of generating :(
    result = await callable(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/friedahuang/Documents/csye7230/.venv/lib/python3.12/site-packages/ragas/testset/evolutions.py", line 143, in evolve
    ) = await self._aevolve(current_tries, current_nodes)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/friedahuang/Documents/csye7230/.venv/lib/python3.12/site-packages/ragas/testset/evolutions.py", line 554, in _aevolve
    result = await self._acomplex_evolution(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/friedahuang/Documents/csye7230/.venv/lib/python3.12/site-packages/ragas/testset/evolutions.py", line 411, in _acomplex_evolution
    return await self.aretry_evolve(current_tries, current_nodes)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/friedahuang/Documents/csye7230/.venv/lib/python3.12/site-packages/ragas/testset/evolutions.py", line 121, in aretry_evolve
    return await self._aevolve(current_tries, current_nodes)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/friedahuang/Documents/csye7230/.venv/lib/python3.12/site-packages/ragas/testset/evolutions.py", line 554, in _aevolve
    result = await self._acomplex_evolution(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/friedahuang/Documents/csye7230/.venv/lib/python3.12/site-packages/ragas/testset/evolutions.py", line 382, in _acomplex_evolution
    simple_question, current_nodes, _ = await self.se._aevolve(
                                        ^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/friedahuang/Documents/csye7230/.venv/lib/python3.12/site-packages/ragas/testset/evolutions.py", line 298, in _aevolve
    passed = await self.node_filter.filter(merged_node)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/friedahuang/Documents/csye7230/.venv/lib/python3.12/site-packages/ragas/testset/filters.py", line 60, in filter
    output["score"] = sum(output.values()) / len(output.values())
                      ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
ZeroDivisionError: division by zero
sys:1: RuntimeWarning: coroutine 'Executor.wrap_callable_with_index.<locals>.wrapped_callable_async' was never awaited

hey @frieda-huang @wanjeakshay we are really sorry about this but looks like something broke in the testset generation part.
we have a new version of this coming soon #1321 and I would suggest you wait for that sadly 🙁

hey @frieda-huang @wanjeakshay we are really sorry about this but looks like something broke in the testset generation part.
we have a new version of this coming soon #1321 and I would suggest you wait for that sadly 🙁

Thank you, @jjmachan! That would be very much appreciated! Do we know when the new version will be released?

we are aiming for this month end 🤞🏽


Make CowData self-inserts safe

When inserting an element taking the original from the current data block so that it will be resized, potentially invalidating the reference to the original, a backup is made to base the copy on it instead.
Fixes #31736.
Other related items (fixed, superseded or plainly related): #16961, #29408, #31159, #31609, #31694.
P. S.: Haven't had time to test this thoroughly.

Ah I hadn't noticed that your PR'ed it on the vulkan branch, but it should track master. The vulkan branch is strictly for Vulkan-related changes, I rebase it every once in a while on master.

OK. I'll fix this.
What about changes for 4.0, like C++11 atomics? Is master for 4.0 now?

What about changes for 4.0, like C++11 atomics? Is master for 4.0 now?

Not yet, but soon. For now it's probably best to PR such changes against master for review, and redo them once the vulkan branch is merged.

For 3.2 we merged #34618 as a simpler stopgap solution, so we'd probably consider that one too for cherry-picking in 3.1.x.
This PR should be reviewed for 4.0. There was a lot of discussion on IRC with @reduz and @hpvb regarding what should be done exactly to solve those issues, which might be worth rediscussing with you.

IMO I would just close this, the solution is bigger than the problem. As I mentioned in the existing fix, the drawbacks of just copying the value are next to none in real life scenarios.


fix the typo in the new ansible setting name

The new setting name is callbacks_enabled (in the plural).
Also keep the deprecated name around since currently we are using an ansible version that doesn't know about the new one.
fixes https://github.com/kiali/kiali/issues/4338

i confirmed molecule tests can still pass with this (I'm not even sure if we use the junit plugin in our tests but whatev).


mobile: add Swift C++ interop implementation

This acts as a drop-in replacement for the existing Objective-C implementation that we've always used for the Swift APIs.
It leverages Swift's experimental C++ interoperability support to allow us to write Swift code that interacts directly with Envoy's C++ APIs.
Also add a new Swift C++ interop test suite.
This is still unreachable from the main library's API, so it's very low risk as-is, but that will be hooked up in an upcoming change.
~Depends on https://github.com/envoyproxy/envoy/pull/25971~
Commit Message:
Additional Description:
Risk Level: Low, unreachable code
Testing: Added new test suite with tests for much of the new code.
Docs Changes: None, unreachable code
Release Notes: None, unreachable code
Platform Specific Features:
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Fixes commit #PR or SHA]
[Optional Deprecated:]
[Optional API Considerations:]

/assign @Augustyniak

I reviewed a portion (maybe ~50%) of files in this PR. Submitting my partial PR since it's better than nothing and I need to move to other efforts for the next few hours.

I appreciate you taking a look!

Curious of your comments to some of my memory (autorelease pool)/flow (calling callback with continue as opposed to resume) related comments.

I'll be working through your comments with a focus on the memory management.
At a high-level I will say that I measured memory usage in all our example apps using Instruments & Xcode's memory graph debugger comparing both the objc (useSwiftCxxInterop(false)) and the swift (useSwiftCxxInterop(true)) implementations and they were in the same ballpark, and when terminating & deallocating the engine, nothing relevant leaked in either implementation.

For the record, I do think that this is a high-risk change.

Maybe I'm being pedantic, but this change is low risk as-is, since all this is new code that should be 100% unreachable in its current form. That said, the code is also useless in its current form for the exact same reason. 🤷
I'd characterize https://github.com/envoyproxy/envoy/pull/26011 as medium-high risk since it actually makes this code reachable to the Swift APIs, unless disabled by setting useSwiftCxxInterop(false) or building with --define=envoy_mobile_swift_cxx_interop=disabled. This comment attempts to characterize the risk factors involved, and I do think that memory management is one of the more likely risks, despite my best attempts to hunt for and catch leaks.

Maybe I'm being pedantic, but this change is low risk as-is, since all this is new code that should be 100% unreachable in its current form. That said, the code is also useless in its current form for the exact same reason. 🤷

Yes, of course 🤓 . My high-risk comment applied for when this feature (Swift implementation) was enabled/active. This is when I think it becomes high-risk. Otherwise it's a low-risk.

Went with https://github.com/envoyproxy/envoy/pull/26111 instead of this as a short-term & low-risk way to dip our toes into Swift / C++ interop waters.
I'll close this PR for now and might revive it after I'm back from my leave in mid-April.


Add sample datasets that work out-of-the-box with the pipeline

If possible, it might be nice to ship, or automatically download some small sample datasets so that users can test out the pipeline even if they don't have any data.
This will also be useful for development (in particular testing).
There are numerous datasets already on Bioconductor (e.g. http://www.bioconductor.org/packages/release/data/experiment/) so perhaps we can find a few ones there that would fit our purposes.
Incorporating external datasets would also be a good way  to ensure that the pipeline is actually generalizable to other datasets and doesn't depend too much on specific features of any one dataset.

I'll prepare the sample datasets

Great!
If you are going to include your own data, we could put it in either samples/ or doc/samples?

If the files are large, it might be better to NOT include them in the git
repository.  Perhaps a subset would be better?
Sean
On Fri, Aug 7, 2015 at 7:51 AM, Keith Hughitt<EMAIL_ADDRESS>wrote:

Great!
If you are going to include your own data, we could put it in either
samples/ or doc/samples?
—
Reply to this email directly or view it on GitHub
https://github.com/DCGenomics/Pharmacogenomics_Prediction_Pipeline_P3/issues/5#issuecomment-128682107
.

Agreed. I would try to only include files less than ~1Mb. This is why it may be good (if possible) to use datasets already on Bioconductor -- then the library can just be loaded and the sample dataset will be available. It requires, however, that there are appropriate datasets we can use already out there.

If you have data, we can easily make a bioconductor data package.
On Aug 9, 2015 8:24 AM, "Keith Hughitt"<EMAIL_ADDRESS>wrote:

Agreed. I would try to only include files less than ~1Mb. This is why it
may be good (if possible) to use datasets already on Bioconductor -- then
the library can just be loaded and the sample dataset will be available. It
requires, however, that there are appropriate datasets we can use already
out there.
—
Reply to this email directly or view it on GitHub
https://github.com/DCGenomics/Pharmacogenomics_Prediction_Pipeline_P3/issues/5#issuecomment-129174331
.

Since our study has not been published yet, it seems for now we could use a small subset of permuted data with mock cell line/compound names.
I've prepared an example data and  copied them to sample_in_progress (raw.zip, ~40kb). I've also added a readme file there.

Thanks, this is great.
The unzipped size is still pretty small (212K). I also subsetted the GO, MSIG, and CPDB annotation files to only have data for the 100 genes in the example data. Everything together weighs in at 760K uncompressed.
To make things easier for version control and testing, are there any objections to unzipping these 760K into an "example_data" dir in the top-level dir of the repo?

You could also use S3 versioning:
http://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTVersioningStatus.html
Sean
On Mon, Aug 10, 2015 at 11:56 AM, Ryan Dale<EMAIL_ADDRESS>wrote:

Thanks, this is great.
The unzipped size is still pretty small (212K). I also subsetted the GO,
MSIG, and CPDB annotation files to only have data for the 100 genes in the
example data. Everything together weighs in at 760K uncompressed.
To make things easier for version control and testing, are there any
objections to unzipping these 760K into an "example_data" dir in the
top-level dir of the repo?
—
Reply to this email directly or view it on GitHub
https://github.com/DCGenomics/Pharmacogenomics_Prediction_Pipeline_P3/issues/5#issuecomment-129505279
.

Done. Thanks, @ammhub!


Improve Licence Manager description

We need to further detail the LM module.
Diego (TID) proposed the following:

[...] I think that a discussion on the gatekeeper as the focal point for license management (among other things), how they will be enforced, and the procedures for the different kinds would be more than enough, just to provide a more comprehensive solution that the usual license server approaches that seem to be favored by some of the NFV participants.
I am wondering that we could use the text of the draft we submitted to NFVRG (see attached) as a base, augmenting it with the considerations on licensing. What is more, we could try to battle at the two fronts: NFVRG (extending the draft to include license management considerations), and ETSI NFV (adapting the draft text into a shorter contribution on applying the gatekeeper) and move them in parallel. What do you think?

Duplicate of #438


Deploy docs to RTD for easy viewing online

Now that we have a docs folder. Let's deploy to Read the docs so that it's all consolidated and can easily be viewed.

I just set up RTD: https://readthedocs.org/projects/echoshader/
and added both of you @lsetiawan @emiliom as maintainers also.

Thanks @leewujung! That looks great! Did you activate the PR previews also?

Just did on your prompt!

Seems that this is ready to be closed. 😀


Clear kubens selection

Hi 👋🏻 ,
Is it possible to have a subcommand like clear for kubens where it clears current namespace?
This seems to be possible with kubectl config set-context --current --namespace=""
Maybe we can even do kubens "" but it prints an error that it couldn't find that namespace.

kubens -f "" might work.
I see we have unset operation for ctx but not namespace. We could add, I'm surprised this never came up before.

Unfortunetely that doesn't work:
kubens -f ""
error: too many flags
USAGE:
  kubens                    : list the namespaces in the current context
  kubens <NAME>             : change the active namespace of current context
  kubens -                  : switch to the previous namespace in this context
  kubens -c, --current      : show the current namespace
  kubens -h,--help          : show this message

How about kubens -u just like kubectx?


Added support for dynamic authentication

@Na-ru-to4170 Good one.
BTW, you don't need to commit files in dist folder. Also in your PR , I don't see an option to specify tokenAuth details in config editor.  I assume this is a work in progress from your side.

Thanks for quick reply..
I will remove it from the dist folder.
My question is that if we can add it in plugin.json itself then anybody can inject their values according to there need then is there any need to have a config editor for it ?

Yes you need to have config editor. you can't edit the plugin.json directly.

ok got it.
Will give a try to add in editor mode.
One last question.. will this suffice for now or you think I need to add something extra?

Thats all i think. Sensitive information you need to read rom SecureJsonData and not from JsonData

Done.. Can you approve it? :)

This won't work without config editor to pass the fields.

Hi
Can you tell me how to test this in my local ?

Hi @Na-ru-to4170  - Can you take latest from https://github.com/yesoreyeram/grafana-infinity-datasource/tree/feature/token-authentication and work if you are interested. I have setup a base for token authentication. ( working version )

Sure @yesoreyeram  let me give a try.. Thanks :)

hi @yesoreyeram  I am having difficulty with these type-scripts.
Can you point to right doc where I can learn type-script.. then I might be able to contribute here

As the plugin is being migrated into the backend to support more features, I am closing this PR for now. Thank you very much for the efforts and feedback.


translations not work in several places

Translations not work in several places:

hello page:

Android and IPhone tabs in apps page:

all in resource "translationsjson"

@umairwaheed can you take a look at part 3 at least?
@Jianchun1 I think for parts 1 and 2, the issue is that the relevant templates (e.g. templates/zerver/api.html) haven't had translation tags added yet.  http://zulip.readthedocs.io/en/latest/translating.html has documentation on how to add translation tags to the templates for strings that are missing them...

@timabbott I've checked "hello.html" and "apps.html". It looks that those strings had been tagged properly, using Jinja2 style:
templates/zerver/hello.html

{% trans %}Every conversation in Zulip has a topic, so it’s
      easy to keep conversations straight. Are other users discussing
      a software bug and the content of your website at the same time?
      No problem.{% endtrans %}

{{ _("You wouldn’t tolerate email without subject lines or threading, so why do you for chat?") }}

templates/zerver/apps.html

{% trans %}Zulip has a free, 100% native app for Android,
          and you can easily grab it from
          the Google
          Play Store{% endtrans %}.

Do you have any other suggestions?

Ahh, I see, this is because I hadn't run tx push recently, which I just did; so I think those strings should now be available for translation.

(And the JSON errors will be available once #832 is merged)

Now the part 1 is ok, part 2 is still English. It confuses me, because I'm sure the two parts had been translated before.
And JSON errors translation done in Transifex.

Checking this.

In case of problem number 2, the translation file seems to be fine, the problem is %% pattern. makemessages escapes % sign but then it can't match with the correct string. I just removed one % sign in .po file and the translation worked. Let me see what I can do.

OK, frontend translations are fixed in #960. I am still working on % issue.

Fixed in #960

@Jianchun1 I merged https://github.com/zulip/zulip/pull/960 which should fix the other problems; let us know if that's not working.
And thanks for the bug report!  I'd love to get all the issues worked out with our internationalization support, so please keep the reports coming!

yes, I will


Schema version checked instead of rule engine version when determining open rules

Describe the bug
The SchemaVersion attribute of a rule is checked against the ver attribute of the DCC to determine if the rule is open or not (instead of pass or fail)
https://github.com/eu-digital-green-certificates/dgc-certlogic-ios/blob/a478f350183b467929450966d5a2cf7599bdff4d/Sources/CertLogic/CertLogic.swift#L55-L57
Expected behaviour
As per the specification, a rule can only be open if EngineVersion is not compatible:

5.4.1 Incompatible Rule Engine Versions
In the case of an incompatible engine version (rule engine version> current version), the technical validation has to be performed a human readable fallback.

Steps to reproduce the issue
look at the code
Technical details
n/a
Possible Fix
check for engine version instead of schema version
Additional context
n/a

@mlenkeit  open status will be added to Android with latest commits and it's status only for rule with scheme version miss match with specific error for the user. All this added in latest commits.
Please see, if it's good we can close this issue.


MPVolume Hud doesn't disappear with AVPlayerViewController

I have a UIViewController with an AVPlayerViewController in it. I disable MPVolume Hud in the ViewController, and it doesn't appear until I play the AVPlayer in the AVPlayerViewController. I know that with
avplayercontroller.showsPlaybackControls = false
the hud disappears, but the problem is that every control disappears, and I need controls, and I prefer to use system controls instead of custom ones.
SubtleVolume works, but when I play the Player controller both the hud and SubtleVolume are visible.
I tried to create a MPVolume and add it to the app window, to the player controller view, but the hud is still visible.
let volumeView = MPVolumeView(frame: CGRect.zero)
if let appDelegate = UIApplication.shared.delegate as? AppDelegate, let window = appDelegate.window {
    window.insertSubview(volumeView, at: 0)
}

I've tried almost everything, but I can't figure out what is the problem.

Hey @gianpispi
I'm not sure I understand the issue, what is your desired result?
Consider that SubtleVolume creates internally a MPVolumeView as you can see here.
The volume view can't be completely hidden, or the default volume UI will kick in, so I just hide it with a fraction of alpha, as you can see here

Hey @andreamazz
Thanks for heading back!
Sorry fro the bad explanation. I add the SubtleVolume to my view controller. It hides the Volume HUD perfectly until I start the AVPlayer into the AVPlayerViewController added as child to my first view controller. When I play the video, and try to change the volume, the hud becomes visible as SubtleVolume does. So I have two volume indicators.
I tried to add a MPVolumeView to the AVPlayerViewController, but it doesn't change anything.

Can you post a screenshot?
If I understand correctly you want the media controls visible, but not the volume bar, right?

So the problem is this basically: I have both, and the status bar doesn't disappear.

Thank you!


GROUP BY not consistent with IS DISTINCT FROM for NaN

In 0.73:
presto> select nan() is distinct from nan();
 _col0
-------
 true

presto:datascience> select distinct a/a FROM (VALUES (0.0), (0.0)) x (a);
 _col0
-------
   NaN
   NaN

But in master (0.74):
presto> select nan() is distinct from nan();
 _col0
-------
 true

presto> select distinct a/a FROM (VALUES (0.0), (0.0)) x (a);
 _col0
-------
   NaN

The behavior in 0.74 is inconsistent. NaNs should not group together if they are distinct from each other.
We should actually change the behavior to make NaN work like nulls:
NaN = NaN => false
NaN IS NOT DISTINCT FROM NaN => true

Just discussed with @dain and @electrum. The problem is that select nan() is distinct from nan(); should return false

We should be able to fix this once https://github.com/prestodb/presto/pull/6091 is merged

This test case should produce a single row:
presto:di> select * from (values nan(), nan(), nan()) group by 1;
 _col0
-------
   NaN
   NaN
   NaN
(3 rows)


V2 Fixes Into V3

Description
In the process of fixing up testnet, many fixes were added to #853. This PR moves those fixes into the master branch that is based on v3.

scribe and explorer tests are flaking. not entirely sure why @nautsimon @trajan0x


Standardize quickwit env variable

Currently, some environment variables have the prefix QUICKWIT_, some don't.
We should keep the same standard everywhere.

let me try

@fatelei you can :)
don't hesitate to come to our discord server to discuss about it.

Keep in mind a lot of those are planned to move into configuration files though.

ok，refactor it using config file

I assigned you the ticket but please give us a couple of days to flesh out a good ticket description!

After further investigation we decided to move all of the env variable to the configuration. Closing the issue!

so，i submit a configuration design doc?

Hi @fatelei,
This is already work in progress. I'll open two PRs in the next coming days. I can tag you in them if you're interested.


java.lang.ArithmeticException: / by zero in WeightedRoundRobinBalancer

I was trying to use the WeightedRoundRobinBalancer to give preference to a Redis server over another for reads and encountered java.lang.ArithmeticException: / by zero. Following is the unit test and the stacktace. Interestingly, this error happens only when the slave is given an higher weight; if the master is given a weight of 2 and slave a weight of 1, then the error does not occur.
The setup used for the unit test below is:

Master listening on localhost:6379
Slave listening on localhost:6380
Sentinels running on localhost:5000, localhost:5001 and localhost:5002
No network issues from the unit test to the master, slave or sentinels.

import static org.junit.Assert.assertEquals;

import java.util.HashMap;
import java.util.Map;

import org.apache.log4j.BasicConfigurator;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
import org.redisson.Config;
import org.redisson.ReadMode;
import org.redisson.Redisson;
import org.redisson.RedissonClient;
import org.redisson.SentinelServersConfig;
import org.redisson.connection.balancer.WeightedRoundRobinBalancer;

public class WeightedRoundRobinBalancerTest {

    static {
        // For logging to console
        BasicConfigurator.configure();
    }

    private static RedissonClient redissonClient;

    @BeforeClass
    public static void beforeClass() throws InterruptedException {
        Config config = new Config();
        SentinelServersConfig sentinelServersConfig = config.useSentinelServers();
        sentinelServersConfig.setMasterName("mymaster");
        sentinelServersConfig.addSentinelAddress(new String[] { "localhost:5000", "localhost:5001", "localhost:5002" });
        sentinelServersConfig.setReadMode(ReadMode.MASTER_SLAVE);

        Map<String, Integer> serverWeightsMap = new HashMap<>();
        serverWeightsMap.put("localhost:6379", 1);
        serverWeightsMap.put("localhost:6380", 2);
        sentinelServersConfig.setLoadBalancer(new WeightedRoundRobinBalancer(serverWeightsMap, 1));

        redissonClient = Redisson.create(config);
    }

    @AfterClass
    public static void afterClass() {
        if (redissonClient != null) {
            redissonClient.shutdown();
        }
    }

    @Test
    public void testReads() {
        redissonClient.getBucket("testReads").set("value");

        assertEquals("value", redissonClient.getBucket("testReads").get());
        assertEquals("value", redissonClient.getBucket("testReads").get());
        assertEquals("value", redissonClient.getBucket("testReads").get());
        assertEquals("value", redissonClient.getBucket("testReads").get());
    }

}

The stacktrace is:
java.lang.ArithmeticException: / by zero
	at org.redisson.connection.balancer.WeightedRoundRobinBalancer.getEntry(WeightedRoundRobinBalancer.java:150)
	at org.redisson.connection.pool.ConnectionPool.getEntry(ConnectionPool.java:135)
	at org.redisson.connection.pool.ConnectionPool.get(ConnectionPool.java:140)
	at org.redisson.connection.pool.SlaveConnectionPool.get(SlaveConnectionPool.java:24)
	at org.redisson.connection.balancer.LoadBalancerManagerImpl.nextConnection(LoadBalancerManagerImpl.java:139)
	at org.redisson.connection.MasterSlaveEntry.connectionReadOp(MasterSlaveEntry.java:363)
	at org.redisson.connection.MasterSlaveConnectionManager.connectionReadOp(MasterSlaveConnectionManager.java:589)
	at org.redisson.command.CommandAsyncService.async(CommandAsyncService.java:393)
	at org.redisson.command.CommandAsyncService.readAsync(CommandAsyncService.java:267)
	at org.redisson.RedissonBucket.getAsync(RedissonBucket.java:97)
	at org.redisson.RedissonBucket.get(RedissonBucket.java:92)

This issue caused by empty clientsCopy collection at WeightedRoundRobinBalancer.java:150 line.  It seems like provided hosts localhost:6379 localhost:6380 are not known by sentinel or freezed by them or due to network issues.

It seems like provided hosts localhost:6379 localhost:6380 are not known by sentinel or freezed by them or due to network issues

The same test passes if the master is given a higher weight of 2 and slave a lower weight of 1.

I'll check that

It seems like provided hosts localhost:6379 localhost:6380 are not known by sentinel or freezed by them or due to network issues

You were right, this issue is due to connections to the only slave being frozen.

Added a unit test to reproduce the issue and test the fix to PR #583.


pulley: Get block.wast test suite passing

Filling out float compares and some miscellaneous bit-related integer
instructions.
cc https://github.com/bytecodealliance/wasmtime/issues/9783

Note that this is based on https://github.com/bytecodealliance/wasmtime/pull/9789


streamcontroller: 1.5.0-beta.6-unstable-2024-08-13 -> 1.5.0-beta.7

Release note: https://github.com/StreamController/StreamController/releases
Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[ ] Tested, as applicable:

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

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

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

@ciferkey FYI the new version now supports Streamdeck Neo buttons

Thanks! It just landed in unstable and I gave it a try. Enabled it with programs.streamcontroller.enable = true.
journalctl shows the Neo being detected. If I open Streamcontroller it says no deck is connected. If I unplug and plug the deck back in Streamcontroller logs:
src.backend.DeckManagement.DeckManager:load_hardware_decks:92 - Failed to open deck. Maybe it's already connected to another instance?
If I use the quit option in the hamburger menu to completely stop Streamcontroller and then run it with sudo it detects the Neo and works correctly!
Since its rather not great to run it through elevated permissions is there anything that needs to change with the package so it has the correct access to the device?

I guess it's due to udev rule for Stream Deck Neo missing in upstream, I created a PR to try fix it https://github.com/StreamController/StreamController/pull/269


lint: Remove exclusions for Python 2 style type comments

The EC2 script we should probably just switch.  It's run only when creating a new load balancer instance, and I'm find with just doing a quick migration and testing it the next time we make one.


Cursor and history command(zsh) display abnormally

Contributing guidelines

[X] I have read CONTRIBUTING.md
[X] I have read CODE_OF_CONDUCT.md
[X] I have updated 'mini.nvim' to latest version

Module(s)
mini.hues
Description
This plugin is nice.
When I use habamax colorscheme, all display well in toggleterm(Fig. 1).

 Fig. 1 habamax
But when I use mini.hues, the cursor and the history command(powered by zsh) both can not be displayed in toggleterm(Fig. 3).

 Fig. 2 minu.hues(when nothing typed)

 Fig. 3 minu.hues(when just typing ls)
Hope to fix this problem as soon as possible. Sincerely thanks!
Neovim version
0.9.1
Steps to reproduce

My mini.hues config:

{
   "echasnovski/mini.hues",
   version = false,
   config = function()
     require("mini.hues").setup({
       background = "#0E1F25",
       foreground = "#c0c8cc",
       n_hues = 8,
       satuation = "medium",
       accent = "fg",
       plugin = { default = true },
     })
   end,
 },

My toggleterm config:

{
   "akinsho/toggleterm.nvim",
   version = "*",
   keys = {
     { "<C-\\>", "<Cmd>execute v:count . 'ToggleTerm '<CR>", mode = { "i", "n" } },
   },
   config = true,
   opts = {
     size = 20,
     open_mapping = [[<c-\>]],
     hide_numbers = true,
     shade_filetypes = {},
     shade_terminals = true,
     shading_factor = 2,
     start_in_insert = true,
     insert_mappings = true,
     persist_size = true,
     direction = "float",
     close_on_exit = true,
     shell = vim.o.shell,
     float_opts = {
       border = "curved",
       winblend = 0,
       highlights = {
         border = "Normal",
         background = "Normal",
       },
     },
   },
 },

I'm using LazyVim.

Expected behavior
Just like Fig. 1 above.
Actual behavior

Thanks for the issue!
I can not reproduce this, as I don't have the zsh extension showing the history like that.
However, my guess would be that that history uses vim.g.terminal_color_8 which in 'mini.hues' is the same as background (hence virtually invisible when actually shown). Would you mind try adding the following line after the require('mini.hues').setup() call:
vim.g.terminal_color_8 = '#767676'

Does this fix the issue?

Yes! It works well !!!
{
   "echasnovski/mini.hues",
   version = false,
   config = function()
     require("mini.hues").setup({
       background = "#0E1F25",
       foreground = "#c0c8cc",
       n_hues = 8,
       satuation = "medium",
       accent = "fg",
       plugin = { default = true },
     })
     vim.g.terminal_color_8 = '#767676'
   end,
 },

Thanks for your quick reply very much! Taking this small problem into consideration for your plugin will be good!

Yes! It works well !!!

Great! Thanks for the feedback.
I'll think about it, as it really seems to be an issue.

Let's keep it open for a while, so that I don't forget about it.

Yeah, I think having 0-7 and 8-15 terminal colors the same is the best approach here. Otherwise, there is no good way to choose which shade of background/foreground to use to have a universally good user experience. I'll leave it to the user to tweak it to their liking.
Thanks again for raising the issue, though!


Potentially remove all those pesky .pyi files

See original issue on GitLab
In GitLab by [Gitlab user @tristanvb] on Dec 2, 2020, 10:07
Apparently, it is possible to encode pep484 type information directly into cython modules
It could be nice to remove all the redundant forward declarations...
Needs investigation, possibly we need to use a mypyc extension for validation in CI.

In GitLab by [Gitlab user @tristanvb] on Dec 2, 2020, 10:11
changed the description

@gtristan I tried to look into this: https://github.com/apache/buildstream/pull/1547 ports buildstream._types and buildstream._utils to use the pure-python cython syntax (The former is already in python, the latter needed some porting).
Regarding mypyc, it seems to be an alternative to cython based on mypy rather than an extension for mypy to support checking cython code. We could probably try to use it instead of cython at some point but the drawback is that it can't do things you can't do in pure python (In particular, it seems buildstream._utils is trying to call into cpython internals to raise an exception in a thread).

@gtristan I tried to look into this: #1547 ports buildstream._types and buildstream._utils to use the pure-python cython syntax (The former is already in python, the latter needed some porting).
Regarding mypyc, it seems to be an alternative to cython based on mypy rather than an extension for mypy to support checking cython code. We could probably try to use it instead of cython at some point but the drawback is that it can't do things you can't do in pure python (In particular, it seems buildstream._utils is trying to call into cpython internals to raise an exception in a thread).

Thanks for taking a look and clarifying. This issue was mostly a hopeful thought as I came across the referenced URLs and wanted to note these down.

I've dug a little bit deeper on this trying to port a bigger module (_node.pyx). Newer Cython looks promising, but there are still some blockers like https://github.com/cython/cython/issues/3957 and https://github.com/cython/cython/issues/4252

Sorry for lack of feedback here I haven't had time to keep up.
Now that I look closely it looks like there is something called pure python mode in cython. Reading that page, I doubt we want to get rid of the .pyx files in some of the hotter code paths (e.g. _node.pyx and _variables.pyx), as these should get better performance by leveraging cython constructs.

There are actually three "pure python" modes in cython:

good old "pure python" code
good old "pure python" + hot code paths rewritten in cython syntax in a separate .pxd file
pure python with special cython decorators

All three can be executed as pure python (3. needs to have cython installed), and can be compiled for performance gain (1. offers modest gains, while 2. and 3. can leverage the full potential of cython). 2. has the obvious downside of having to keep two implementations in sync for the hot paths.
What I was investigating is 3. which should allow us to get rid of the cython syntax without losing the other advantages of cython. Currentyl the only missing feature I noticed is cdef enum (https://github.com/cython/cython/issues/4252). Then there is the huge bug that shows that nobody is currently using this in production (https://github.com/cython/cython/issues/3957).
What I'm currently investigating is 4. mypyc. mypyc is an alternative to cython. It is used by two tools we depend on (mypy and black) so it's used in production (even though it is still considered alpha software). mypyc compiles (a growing subset of) real pure python with type annotations. It is supposed to get a modest speedup when compiling code without type annotations, and a good speedup when adding type annotations.
The upside is that we'd end up with real pure python that can be executed without a compilation step during e.g. debug-edit cycle, and potentially compile the whole tool (with heavy type annotations on the hot paths) on release.
Currently, trying to port _node.pyx, I'm struggling mainly with the fact that mypy takes None-ability very seriously. So if something can be None, it should be checked before being used.
I think there is a buildstream benchmark somewhere. It would be nice to use it to test this.


Status based on current month

Is it possible to have a badge that stays green in October and red in other months?

A badge that displays the current month?
Always displays month x, but color is based on whether x is current?
what's your use case?

I want to add a badge here in Hacktoberfest: https://github.com/swapagarwal/swag-for-dev
The badge should show status=active in October and status=inactive in other months. 😅

Unfortunately we do not have a badge which does that,
Although you could setup a tiny script to return the image you were wanting:
Example in php:

<?php
header('Content-type: image/svg+xml');

$isOctober = Date('F') === 'October';

$label = 'status';
$message = $isOctober ? 'active' : 'inactive';
$color = $isOctober ? 'brightgreen' : 'red';
echo file_get_contents("https://img.shields.io/:{$label}-{$message}-{$color}.svg");
?>

ya.. at first I'd say.. just dynamically generate ...
ie https://img.shields.io/badge/Hacktoberfest-inactive-red.svg
but if you're wanting other's to easily use the badge...

Edited above comment to add example without sending a request to shields server.

I'd propose something like this:
https://img.shields.io/month/000000000100/hacktoberfest/active-green/inactive-red.svg
where:
month is the template name
000000000100 is the data to the template, denoting the months where the condition should evaluate to true or false
hacktoberfest is the label name
active-green should be rendered on the true condition
inactive-red should be rendered when condition evaluates to false

I'd propose something like this:

I really don't see that happening...  This is an extremely niche/specific request...
the service already provides a generic/"static" method of generating a badge (@RedSparr0w 's solution(s))
I kinda like the "badges-json" format idea (aka feature request)..  anyone could create a service by providing the json that shields.io can grab..   it's super generic .   shields.io, need not add specific support for said service.
I assume a "hacktoberfest" organizer/admin could create a page that serves
{
  "label": "Hactoberfest",
  "status": "inactive",
  "colorB": "red"
}


Tool reports that a new version is available when it's not

Really minor bug. I have floyd-cli version 0.9.9 installed. When running floyd init project the tool tells me
$ floyd init project

New version of CLI (0.9.7) is now available. To upgrade run:
    pip install -U floyd-cli

Project "project" initialized in current directory

This is not the case, and running that pip command (obviously) does nothing. Steps to reproduce:
virtualenv venv
source venv/bin/activate
pip install -U floyd-cli
floyd login
floyd init project

Pip freeze:
args==0.1.0
certifi==2017.4.17
chardet==3.0.4
click==6.7
clint==0.5.1
floyd-cli==0.9.9
idna==2.5
marshmallow==2.13.5
pathlib2==2.3.0
pytz==2017.2
requests==2.18.1
requests-toolbelt==0.8.0
shortuuid==0.5.0
six==1.10.0
tabulate==0.7.7
urllib3==1.21.1

Python 3.5.3, virtualenv 15.1.0 on Fedora 4.11.8-200.fc25.x86_64

Hi! Thanks for the report, I forgot to push out the server config to update the latest client, it's pointed at 0.9.7 right now, but we have 0.9.9 published on pypi. I will get that fixed as soon as possible.

This issue should have been resolved.

This is still unresolved in version 0.9.10:
$ pip freeze
args==0.1.0
certifi==2017.4.17
chardet==3.0.4
click==6.7
clint==0.5.1
floyd-cli==0.9.10
idna==2.5
marshmallow==2.13.5
pathlib2==2.3.0
pytz==2017.2
requests==2.18.1
requests-toolbelt==0.8.0
shortuuid==0.5.0
six==1.10.0
tabulate==0.7.7
urllib3==1.21.1
$ floyd run --env tensorflow --mode jupyter

New version of CLI (0.9.10) is now available. To upgrade run:
    pip install -U floyd-cli

Ok, I've worked this out. In my system python environment I had floyd-cli 0.8.9 installed, and the latest one in a virtual env. Despite which floyd-cli reporting that the executable used is the one in virtual env, the one in the system python must have been executed.


Moving response caching into a lower level lib

The response caching doesn't need to be implemented within react-request.

Closing in favor of https://github.com/jmeas/fetch-dedupe/issues/22


add dockerfile and envd build file

Signed-off-by: Keming<EMAIL_ADDRESS>

Is this ready to review?

Is this ready to review?

yes


Show more debonding information

There is very little information about the debonding period when you want to reclaim your stake. I suggest we provide the user with basic debonding information:

[ ] model: fetch current epoch, find a way to compute expected epoch duration (genesis file?)
[ ] in the reclaimEscrow preview dialog, there should be a note saying Current debonding period is x epochs (~y days z hours). You will not be able to access the reclaimed balance until the debonding period is over. Reclaimed balance is not awarded during the debonding period.
[ ] in Debonding delegations table add a localized (~dd-mm-yy) to values in Debonding epoch columns
[ ] in Debonding delegations table add Remaining epochs column showing x epochs (~y days z hours)

model: fetch current epoch, find a way to compute expected epoch duration (genesis file?)

For the expected epoch duration, I think one would need to query Oasis Monitor for the average block length and compute that by multiplying with the expected number of blocks in an epoch.

Current debonding period is x epochs (~y days z hours). You will not be able to access the reclaimed balance until the debonding period is over. Reclaimed balance is not awarded during the debonding period.

Is there a gRPC query to get the current value of the staking.params.debonding_interval parameter?

yeah, use StakingConsensusParameters https://github.com/oasisprotocol/oasis-sdk/blob/7d7d592b533cc4c43cde39d9c8cc5440958491d8/client-sdk/ts-web/core/src/client.ts#L990


NEW FORK announcement(+Message from Original Owner 'MirroMutth')

⚠ Deprecation Notice ⚠

Recently, there have been concerns about the maintenance of the R2DBC-MySQL project as the original repository appears to be abandoned.

However, we have been fortunate to receive a response from the original owner, Mirro Mutth, who has kindly granted permission for us to take over the project, as long as it remains open source.

In his response, Mirro Mutth explained that he is unable to maintain the project due to his busy schedule in the real world, and he would be happy if we took over the project. We are grateful for his contribution to the project and his willingness to keep it open source.

We Have Created a New Fork
You can find the new forked repository here:  https://github.com/asyncer-io/r2dbc-mysql 👈
We've already resolved various bugs and updated dependencies to their latest versions.
As a result, we have released version 0.9.0.
We've also implemented new features to improve the usability of the project. Our team is committed to maintaining and updating the project going forward.
We welcome anyone who is interested in contributing to this project, whether by fixing bugs, adding new features, or improving documentation. You can visit the repository today to try out the updated version of the project.
If you encounter any issues or have suggestions for improvements, please create an issue on the GitHub repository or submit a pull request.
We look forward to collaborating with you on this project!
TL;DR

A new fork of this project has been created at https://github.com/asyncer-io/r2dbc-mysql
Version 0.9.0 has been released
See below for instructions on how to use the new version.

Maven

<dependency>
  <groupId>io.asyncer</groupId>
  <artifactId>r2dbc-mysql</artifactId>
  <version>0.9.0</version>
</dependency>

Gradle
Groovy DSL
dependencies {
    // Maybe should to use `compile` instead of `implementation` on the lower version of Gradle.
    implementation 'io.asyncer:r2dbc-mysql:0.9.0'
}

Kotlin DSL
dependencies {
    // Maybe should to use `compile` instead of `implementation` on the lower version of Gradle.
    implementation("io.asyncer:r2dbc-mysql:0.9.0")
}

Thanks @mirromutth for pinning this issue. 😄

🎉We've just  released the v1.0.0 of r2dbc-mysql.
This version fully supports the latest r2dbc-spi, providing improved performance and stability.
Please check out our repository: https://github.com/asyncer-io/r2dbc-mysql