Add pkgs.nixosTest

Motivation for this change
This makes writing NixOS tests easier and faster for project that use Nixpkgs, because it reuses the applied pkgs.
(The fast aspect was available since config.nixpkgs.pkgs but its use is unlikely to have spread much)
This now also includes a test for pkgs.nixos.
Things done

[x] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
Built on platform(s)

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[x] Fits CONTRIBUTING.md.

I also have a test for this and pkgs.nixos but that depends on #47430

@GrahamcOfBorg build tests.nixos-functions.nixosTest-test tests.nixos-functions.nixos-test

Success on x86_64-linux (full log)
Attempted: tests.nixos-functions.nixosTest-test, tests.nixos-functions.nixos-test
Partial log (click to expand)
machine# [   15.629935] systemd[1]: Listening on Load/Save RF Kill Switch Status /dev/rfkill Watch.
machine# [   15.652585] systemd[1]: Started Name Service Cache Daemon.
machine: exit status 0
test script finished in 17.99s
cleaning up
killing machine (pid 597)
vde_switch: EOF on stdin, cleaning up and exiting
vde_switch: Could not remove ctl dir '/build/vde1.ctl': Directory not empty
/nix/store/fqml68ffajk250dqj3rq4gfpd0nzsn35-vm-test-run-nixosTest-test
/nix/store/clq7f02ijzsdallwvf0999qgh4ccb93h-nixos-system-nixos-19.03.git.bba4655

Success on aarch64-linux (full log)
Attempted: tests.nixos-functions.nixosTest-test, tests.nixos-functions.nixos-test
Partial log (click to expand)
building '/nix/store/2qq81mmf4kc75d2vz1vjza0w2cln5jsg-unit-polkit.service.drv'...
building '/nix/store/7vrv7477qqwpbgnw2ka19y47hf5nz6w4-unit-systemd-fsck-.service.drv'...
building '/nix/store/5ny207c93rri58nds5a85g1hydiqz2w8-unit-dbus.service.drv'...
building '/nix/store/r3ywvinmx5x2vfh3s38mjg87hq4b68n9-unit-dbus.service.drv'...
building '/nix/store/daiily46ya44kk4q5h5dgs2y1vry9p97-system-units.drv'...
building '/nix/store/zaflv7ffp4sj4p7jznb77rnr0cp663vy-user-units.drv'...
building '/nix/store/zmnn9a8gpwq1yi73f32fxy3nwnylpvdj-etc.drv'...
building '/nix/store/vmbf1zkrqza5ikpvwb12l207q4mifcz6-nixos-system-nixos-19.03.git.bba4655.drv'...
/nix/store/1l8lgk0ix55yqczawszyaaiiwpwkg6f0-vm-test-run-nixosTest-test
/nix/store/qgfi5vyy2dncq5cvyk98xgxmj7x5zqk4-nixos-system-nixos-19.03.git.bba4655

Documenting this limitation (which is still the case, not only for config but because just appending overlays won't suddenly make things more deterministic as the existing overlays are still in effect) will not suddenly prevent people from using this and once that lands in nixpkgs, people probably will build things around this, so I think we have to be really careful whether we really want something like this.
What would be the actual use cases where importing <nixpkgs/nixos/tests/make-test.nix> or <nixpkgs/nixos/lib/testing.nix> wouldn't work?

just appending overlays won't suddenly make things more deterministic as the existing overlays are still in effect

The logic in this PR is entirely deterministic. If someone wants to have a fresh Nixpkgs, they should just import it. Having pkgs.nixosTest ignore pkgs defeats the purpose of putting it in pkgs.

so I think we have to be really careful whether we really want something like this.

It makes sense for a project to use Nixpkgs as a central part of their Nix expressions. Having functions like nixos and nixosTest there makes it easy to create images and tests based on the project-specific pkgs. Setting this up used to require a deep dive into the Nixpkgs/NixOS directory tree, which is a waste and likely results in ad-hoc solutions that are worse than this.

What would be the actual use cases where importing <nixpkgs/nixos/tests/make-test.nix> or <nixpkgs/nixos/lib/testing.nix> wouldn't work?

These don't work if you only have a pkgs attrset with custom stuff inside. With master, you have to go out of your way to insert it into the NixOS configs.
Another use case is where you have many machines that need to be evaluated. With master, if you use those imports, you will re-apply Nixpkgs for each machine, which will waste a lot of time producing the same pkgs over and over.

Another very important reason to have this function is to make it easy for beginners to get started with writing NixOS tests for their own projects. It's really a 'killer feature' of the Nix ecosystem so it should be easy to get started with.
Would you really want to point people at these weird, undocumented deep imports?
This function is easy to get started with and it scales well into 'serious projects' and setups with a company overlay, for example.

These kinds of attributes should not be included in all-packages.nix! They confuse tools like nix-env and Hydra (see e.g. https://github.com/NixOS/nixpkgs/pull/50405) and are IMHO confusing to users (e.g. why is something that is not a package in something called pkgs?).

Would you really want to point people at these weird, undocumented deep imports?

It may be undocumented but so is an attribute in all-packages.nix. And importing a file is less weird than getting a function for testing from something called pkgs. (It's also no weirder than, say, #include <stdlib.h>.)
BTW, the flake mechanism should provide a better way to handle this by giving tools like nix-env a dedicated entry point into Nixpkgs.

Same applies to runCommand, I'd say.
I hope flakes aren't too heavy a solution. How are those coming along?

Yes, runCommand was also a mistake. But let's not use that as a reason for making things worse.

Shouldn't there be a way to tell nix-env to exclude something to be installable? We have a way to do that for Hydra.

This also breaks nixops:
error: anonymous function at /home/joerg/git/nixpkgs/nixos/lib/testing.nix:1:1 called without required argument 'pkgs', at /home/joerg/git/nixops/nix/eval-machine-info.nix:9:6
error: evaluation of the deployment specification failed

nixops breakage documented here: https://github.com/NixOS/nixpkgs/issues/50419

No, this doesn't break NixOps. #50233 broke NixOps.
Everything in Nixpkgs is a 'public interface'.

BTW, the flake mechanism should provide a better way to handle this by giving tools like nix-env a dedicated entry point into Nixpkgs.

It's ~4 years later and this can be discussed now.
packages' lack of nesting makes it unsuitable as a replacement for "pkgs", yet we don't have a place for functions that have pkgs in their closure.


Create 3.0 release

Let`s create 3.0 release. There are a lot of changes, refactorings, some of them are incompatible.
I have tested from develop branch in my projects and it works good.
I am ready to assist if new bugs appear
@camilonova

pypi build is not happy about it https://github.com/jazzband/django-constance/actions/runs/5394515587/jobs/9795898856
@sergei-iurchenko can you help?

Seems to be this issue @camilonova : https://github.com/django/asgiref/issues/393

Sorry for delay.
What do you think about removing pypy support? https://github.com/jazzband/django-constance/pull/524
It is actually used only for dj 3.2

What's next?

Let's do it)

Let's do it)

Are you working on it?

@camilonova do we still have any blockers?
I could make a release but I don't know how and I suppose I don't have enough permissions.

https://github.com/jazzband/django-constance/commit/bc9707d618d733f209483f665320cc4484eb7d52


Tunneling to https with an auth http proxy

I tried using okhttp to connect to an https page using a http proxy
If I run a test, it seems to pass by RealConnection::createTunnel
The initial call responds with a 407 asking for auth and passes trough
        case HTTP_PROXY_AUTH:
          tunnelRequest = route.address().proxyAuthenticator().authenticate(route, response);
          if (tunnelRequest == null) throw new IOException("Failed to authenticate with proxy");

          if ("close".equalsIgnoreCase(response.header("Connection"))) {
            return tunnelRequest;
          }
          break;

but when I look at the headers I am getting :
Proxy-Authenticate: Basic realm="proxy"
Proxy-Connection: close
Content-type: text/html; charset=utf-8

The header equal to close is Proxy-Connection and not Connection. And thus it does not goes trough a proxy.
If I do the same process using curl in verbose mode, I see that it makes a tunnel, like it should do when using http to call https.
The question is :
Is the proxy returning a bad response, or should OkHttp be reading the right header (or both) ?

Looks like RFC 7230 has advice on the Proxy-Connection header. We might be better to handle Connection: close when talking to a proxy. We can experiment to see what Firefox & Chrome do.

We are having the same issue with squid/2.6.STABLE21, it sends Proxy-Connection: close header with 407 response code, so we end up with
java.io.IOException: unexpected end of stream on null
	at okhttp3.internal.http1.Http1Codec.readResponseHeaders(Http1Codec.java:208)
	at okhttp3.internal.connection.RealConnection.createTunnel(RealConnection.java:375)
	at okhttp3.internal.connection.RealConnection.connectTunnel(RealConnection.java:218)
	at okhttp3.internal.connection.RealConnection.connect(RealConnection.java:159)
	at okhttp3.internal.connection.StreamAllocation.findConnection(StreamAllocation.java:257)
	at okhttp3.internal.connection.StreamAllocation.findHealthyConnection(StreamAllocation.java:135)
	at okhttp3.internal.connection.StreamAllocation.newStream(StreamAllocation.java:114)
	at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.java:42)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
	at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.java:93)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
	at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.java:93)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
	at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.java:126)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
	at delightex.platform.android.AndroidHttp.lambda$static$1(AndroidHttp.java:35)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
	at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
	at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:200)
	at okhttp3.RealCall.execute(RealCall.java:77)
	at delightex.platform.android.AndroidHttp.openConnection(AndroidHttp.java:231)
	at delightex.platform.android.AndroidHttp.access$100(AndroidHttp.java:23)
	at delightex.platform.android.AndroidHttp$1.run(AndroidHttp.java:142)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)
Caused by: java.io.EOFException: \n not found: limit=0 content=…
	at okio.RealBufferedSource.readUtf8LineStrict(RealBufferedSource.java:237)
	at okhttp3.internal.http1.Http1Codec.readHeaderLine(Http1Codec.java:215)
	at okhttp3.internal.http1.Http1Codec.readResponseHeaders(Http1Codec.java:189)
	... 28 more

apparently after repeating CONNECT... request with Proxy-Authorization header and then trying to read from the connection that was already closed by the server a while ago (right after it sent 407).
Changing "Connection" to "Proxy-Connection" here fixes the issue for us.


Week 3-Arya Learning Nihongo- Asakatsu Project

About to complete three weeks, I am so excited!

Great progress @AryaCodesAI

I think @avie-dev forgot the PRs. Let me take care of it.

Thank you so much, Philips! I appreciate it.

Great progress @AryaCodesAI

Yes! Thanks for the support!


Upgrade pysaml2 from version 4.4.0 to version 4.5.0

Upgrade pysaml2 package to current latest stable version.
(Fixes issues with #165)

Once this is merged, #126 can also move forward.


Allow to edit the left hand side of a diff editor if possible

You can hit it by using Compare with action and --diff. This is really sad. The editor on the left should only be read-only if the input behind it is really read-only (coming from the git index, for example).
cc @alexandrudima @bpasero

Yes I always wanted that actually :)

On my side it would be pretty easy to just comment out the forcing of readOnly=true on the left-hand-side. But I need to add an option to allow the workbench to make the git diff case left-hand-side readOnly.

There's also the inline diff case, where I cannot make the "original" editable.

@alexandrudima yeah I think we know in all places if the left hand side should be editable or not, I think it would only be the file-2-file compare where this applies.

Ok, there is a new option originalEditable to the diff editor. It is false by default.

@alexandrudima cool, let me pick this up then...

@alexandrudima so by default this option is true or false?

:) Wrote in comment and in jsdoc: it is false by default.

Don't editor inputs have a readonly property?

:+1:

Hm, I forgot that this adds a bit more complexity to how actions operate on the active editor and how dirty state is indicated. I think I was a bit too optimistic for March but will check. Otherwise April it will be.

Surprisingly lots of things actually do work in terms of dirty indication but the one for the actual editor does not because it only checks for the right hand side.

If this something that can be done as a first PR? Would be great if you could indicate issues that would be easy wins for an outsider to contribute. I really really really really want git diffing to work on the right side. I will buy you a coffee/beer if you fix this :stuck_out_tongue_winking_eye:

@nojvek you can always edit on the right hand side when comparing outgoing changes in git!

(this feature request is about being able to edit either the left hand or the right hand side when comparing 2 files)

Oh I just saw that after doing an upgrade. This seems fairly recent. This really bought me a lot of joy when it worked.

It was always possible to edit the right hand side of the diff editor for git changes view.

From @alexandrudima

in the explorer,
right click on a file A, choose "Select for compare"
right click on another file, choose "Compare with A"
observe: left hand side of the diff is not editable

Fix: use originalEditable when the diff editor models are both editable files.

It would be cool to have two buttons in the middle "copy changes from left to right" and vice versa.
Like this (Eclipse):

Yeah the copy changes is super useful.

So the option works
"diffEditor.originalEditable": true

but VSCode 1.20.0 (1.20.0) complains about "Unknown configuration setting":

What's also strange (mac here): Cmd+S does not save the original! The UX handling is really weird with the original file and I had lost my editing once. I have to close the diff window after editing and save the unsaved original which is not how I assumed the saving should work with this option turned on.

It would be nice if there was read-only on/off control of both sides of the diff editor. In GitLens, when diffing history both sides should be read-only.

Can someone explain to me where I can set originalEditable ?
Really confused. That option is not listed on my settings v1.27.1

This setting is just working for the split view. If switched to inline view, i can't even just select (nor copy) the original text.

would be nice to have that available also in the "ui" version of "settings"
Having both editable is very convenient for refactoring:

identify common code and
possibly move that to a parent-class

Nice.

It would be cool to have two buttons in the middle "copy changes from left to right" and vice versa.
Like this (Eclipse):

The ability to move code from the original to the new is pretty fundamental in vcs compare tools. I don't think I've ever found a diff tool before that doesn't have it.

"diffEditor.originalEditable": true, works perfectly! Is there any way to make this the new default? I can't imagine ever not wanting this on.

Now "diffEditor.originalEditable": true has a bug. It allow edit on left side but then it make right side cannot be edited
Please stop hacking around and just let the diff editor can edit both side. Maybe just having lock icon that can be toggled and that's all

I pushed a change to enable this by default if the left-hand editor is not readonly. Pressing CtrlCmd+S or File > Save will now save both sides of the diff editor.
Feedback welcome, it will be in tomorrows insider build: https://code.visualstudio.com/insiders/

@bpasero Thanks for implementing! Now that this is closed, is it possible to finally implement https://github.com/microsoft/vscode/issues/25887 and https://github.com/microsoft/vscode/issues/37350? This would address a critically missing piece of editor functionality that has been heavily requested for over two years.
Also mentioning @alexandrudima who has been consolidating a number of issues to #25887
Thanks much!


serverZoneId option not working

I have created my connection like this:
MySqlConnectionConfiguration configuration = MySqlConnectionConfiguration.builder()
                    .host("localhost")
                    .user("test")
                    .port(3306)
                    .password("mydbpassword")
                    .database("mytestdb")
                    .serverZoneId(ZoneId.of("Australia/Darwin"))
                    .build();
            ConnectionFactory connectionFactory = MySqlConnectionFactory.from(configuration);

            return (Mono<Connection>) Mono.from(connectionFactory.create())
                    .onErrorResume(exception -> {
                        log.debug("Error when creating datasource.", exception);
                        return Mono.error(Exceptions.propagate(exception));
                    })
                    .subscribeOn(scheduler);

When fetching timestamp type from mysql server, the value fetched by the driver had not changed the timestamp values as per the zone.
My test table:
mysql> select * from test_date_time_types;
+------------+---------------------+---------------------+----------+--------+
| c_date     | c_datetime          | c_timestamp         | c_time   | c_year |
+------------+---------------------+---------------------+----------+--------+
| 2020-12-01 | 2020-12-01 20:20:20 | 2020-12-01 20:20:20 | 20:20:20 |   2020 |
+------------+---------------------+---------------------+----------+--------+

Hi there,
Sorry for the late reply.
The LocalDateTime will favor to use the original value you stored, and ZonedDateTime/OffsetDateTime will use server timezone and original value.
It should be noticed that these three datetimes (LocalDateTime/ZonedDateTime/OffsetDateTime) are not strictly timestamp. They consist of year, month, day, hour, minute, second, nanosecond, timezone id (ZonedDateTime only), timezone offset (OffsetDateTime only).
So, if you want to get the timestamp, should call Row.get(index, Instant.class) instead. If you want to get the datetime after the timezone conversion, should call Row.get(index, ZonedDateTime.class).withZoneSameInstant(ZoneId.systemDefault()).
In my limited experience with date and time system, the timestamp does not defined by timezone. As far as I know, the datetime (year-month-day hour:minute:second.nanosecond) is formatted by timestamp with timezone offset. This means that the timestamp does not change due to changes in timezone. In other words, if we do not consider clock skew and clock back, all timestamps should be consistent on all systems (hmmm, the real world is always unsatisfactory).
If the problem or more questions persists, please continue reply.
Best Regards,

Hi there,
Sorry for the late reply.
The LocalDateTime will favor to use the original value you stored, and ZonedDateTime/OffsetDateTime will use server timezone and original value.
It should be noticed that these three datetimes (LocalDateTime/ZonedDateTime/OffsetDateTime) are not strictly timestamp. They consist of year, month, day, hour, minute, second, nanosecond, timezone id (ZonedDateTime only), timezone offset (OffsetDateTime only).
So, if you want to get the timestamp, should call Row.get(index, Instant.class) instead. If you want to get the datetime after the timezone conversion, should call Row.get(index, ZonedDateTime.class).withZoneSameInstant(ZoneId.systemDefault()).
In my limited experience with date and time system, the timestamp does not defined by timezone. As far as I know, the datetime (year-month-day hour:minute:second.nanosecond) is formatted by timestamp with timezone offset. This means that the timestamp does not change due to changes in timezone. In other words, if we do not consider clock skew and clock back, all timestamps should be consistent on all systems (hmmm, the real world is always unsatisfactory).
If the problem or more questions persists, please continue reply.
Best Regards,

Hi,
If reading timestamp field as Instant, it gets wrong value. Tried setting serverZoneId to UTC. This doesn't help.
E.g. DB stores 2021-06-30 13:46:50 but when reading as Instant, the obtained value is 2021-06-30T10:46:50Z.
But write to DB works OK even without this config. LocalDateTime works normally for both write and read.


POST /v3/platform/private/besthitsearch is not working

The POST request for the endpoint https://platform-api.opentargets.io/v3/platform/private/besthitsearch is not working properly
curl -d '{"q":["dmd"]}' -H "Content-Type: application/json" -X POST "https://platform-api.opentargets.io/v3/platform/private/besthitsearch"

Fixed.
commit b3a2e92ff3daa38fb322ab29babe51a1e4e1ba2c


Autofocus should not add tabindex="-1" to element.

currently the element that is autofucus, also has tabindex="-1" which should not be like this.

@TheHadiAhmadi is this issue valid?

Yes, If we use blazor's FocusOnNavigate (or ExterdedFocusOnNavigate Which we had before), It will add tabindex=-1 to the focused element.
We should consider this issue when we want to add autofocus feature to project.

@pournasserian it can be a comment in the issue related to Adding Autofocus and tabindex order of elements.


tsc-make-cursor and tsc-goto-xxxx does not appear to work when created against a non-root node

I'm encountering a weird issue and I'm fairly certain it's a bug.
If you create a cursor against a non-root node the cursor movement code does not work.
Version: 0.15.1
Test case:
(ert-deftest cursor::walk-from-root-node ()
  (let ((parser (tsc-make-parser))
        (language (tree-sitter-require 'rust)))
    (tsc-set-language parser language)
    (let* ((tree (tsc-parse-string parser "fn foo() {}"))
           (root-node (tsc-root-node tree))
           (tree-sitter-tree tree)
           (cursor (tsc-make-cursor root-node)))
      (ert-info ("Moving a cursor that was made against a non-root should work")
        ;; test that the root node can navigate independently
        ;; this works
        (should (eq (tsc-node-type (tsc-current-node cursor)) 'source_file))
        (should (tsc-goto-first-child cursor))
        (should (eq (tsc-node-type (tsc-current-node cursor)) 'function_item))
        ;; this too
        (let* ((sub-node (tsc-current-node cursor))
               (sub-cursor (tsc-make-cursor sub-node)))
          (should (tsc-node-p sub-node))
          (should (tsc-cursor-p sub-cursor))
          (should (eq (tsc-node-type (tsc-current-node cursor)) 'function_item))
          ;; this should move us back from whence we came but this fails with a nil response.
          (should (tsc-goto-parent sub-cursor)))))))

EDIT: I amended the test slightly to make it more specific.

The current behavior is that tree cursor is scoped to the node it's created against.
There are more details in https://github.com/tree-sitter/tree-sitter/issues/567.

Hm. Yeah, I did actually see the documentation in tree-sitter that said that, but I clearly misunderstood what they meant by that.
It's a shame as text editing with tree-sitter most often revolves around the idea of acting on/around where point is. I'll stick to the other helper methods then in the interim.
Thanks for clarifying!


Allow client migration tests to write arbitrary bytes to database snapshots

It's currently difficult to test client state machine migrations because we want to write the old state into the database, which requires keeping extra structs and enums around to be able to do this.
If the tests could write raw bytes directly into the database, we could serialize the old bytes into a string and write that into the db, which would allow us to delete the old structs and the old enums.

PRs that need cleanup once this lands:

[ ] #4024
[ ] #3820

Keeping these old enum variants around is very bad for maintainability.


⚠ Bofrost.at has degraded performance

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

HTTP code: 200
Response time: 2149 ms

Resolved: Bofrost.at performance has improved in c0b2b47 after 14 minutes.


Don't error on admin panel if user is anonymous

Right now going to /admin with an AnonymousUser just errors instead of redirecting to /login.

Whoops, based off the wrong branch. Will fix this PR after breakfast.

Beat me to it!


[pwrmgr] V2S review action items

[x] [Tim] Double check design about escalation reset path is supposed to be unstoppable with any external behavior of the module. For example - pwrmgr cannot be stoped by clkmgr clk gating .
[x] [Cindy] Check if formal can help with the previous notes.
[x] [Tim] Add firing a fatal alert when pd_rst_local_esc occurs #12072
[x] [Tim] rename fsm_local_esc, so that all local_esc behave consistently #12072
[x] [Jaedon] add rst_req check to all sec_cm except fsm_local_esc and global esc.

Update testplan
Create a common check for local_esc to check that it transitions to FastPwrStateResetPrep state and pwr_rst_req is triggered, then invoke this check for all local_esc
Override check_tl_intg_error_response to invoke this check for bus integrity

[x] [Jaedon/Cindy] Fix FPV failures on pwr_mgr tests
[x] [Jaedon] Fix simulation failures on those countermeasure related tests and ensure coverage passes V2S criteria

cc: @matutem

cross reference with #12072

I can confirm the behavior of the first bullet. Upon escalation, clkmgr should not be able to gate reset entry.

Pwrmgr is at V2S now - can this be closed?

Pwrmgr is at V2S now - can this be closed?

@msfschaffner we can close this issue but pwrmgr v2s still tied to
new ndm reset update. See #15125

Ah yes, I see. That should be ok - we have an issue that tracks the reset domain changes: https://github.com/lowRISC/opentitan/issues/15317


Uncaught Error: Unknown DraftEntity key.

I initially posted this issue here: https://github.com/facebook/draft-js/issues/1363
But since I mostly copied the code from the SeparatorSideButton from this repo I thought maybe you stumbled upon this issue.
I have several instances of medium-draft, and all work smoothly except one, where, when I try to add a separator or an embed from the side buttons I get this error.
This is how my code looks like:
onClick() {
    const entityKey = Entity.create('separator', 'IMMUTABLE', {});
    this.props.setEditorState(
      AtomicBlockUtils.insertAtomicBlock(
        this.props.getEditorState(),
        entityKey,
        '-'
      )
    );
    this.props.close();
  }

I then saw you had updated this code here: https://github.com/brijeshb42/medium-draft/blob/master/src/example.js#L121
But the issue persists.
Again, what I find more awkward is that for all the other instances it works. The only difference is that the other instances of medium-draft are loaded with initial content, while the one that doesn't work is initially empty. I tried to explicitly initialize the EditorState with "this.refs.myeditor.initializeEditorState();" but the problem persists.
Sorry I know this might not be 100% related to medium-draft but any help is very welcome!

Entity has been deprecated from 0.10 of draft-ja

Yeah, I tried doing it like you do in the examples
onClick() {
    let editorState = this.props.getEditorState();
    const content = editorState.getCurrentContent();
    const contentWithEntity = content.createEntity('separator', 'IMMUTABLE', {});
    const entityKey = contentWithEntity.getLastCreatedEntityKey();
    editorState = EditorState.push(editorState, contentWithEntity, 'create-entity');
    this.props.setEditorState(
      AtomicBlockUtils.insertAtomicBlock(
        editorState,
        entityKey,
        '-'
      )
    );
    this.props.close();
}

but the problem is still there... :/

Do you have a demo somewhere?

I'll set one up. Is there any email or way to privately message you a test password?

@mezod You can pm me on draft-js channel.

Whats is solution? got same problem unknown DraftEntity key.

@IzaGz What version of draft are you using? The entity api has been deprecated. Try to update draft and then check.

@brijeshb42 I use "draft-js": "^0.9.1"

Update to 0.10.* if that is not a problem. Otherwise you can downgrade the version of medium-draft01.11.2017, 16:30, "IzaGz" notifications@github.com:@brijeshb42 I use "draft-js": "^0.9.1"
—You are receiving this because you were mentioned.Reply to this email directly, view it on GitHub, or mute the thread.


Create imnisarg.txt

This Pull Request resolves Issue #
Description:
In this Pull Request we have done the following additions/edits for the code:
Note: Delete all the text including this!

Make sure you replace #<IssueNumber> with the particular Issue that you are referencing with!
Make sure you describe the Issue properly and ask as many people as possible to review your Pull Request so that it can be merged as soon as possible!

adding file

Are there any updates here or should we close the PR and label it as spam?

spam!


Looping not working

Hi, I´m using the react-simple-typewriter with next.js, but the loop isn´t working. It´s types the first word, delete it, but not type the other words.

Can you send at least a piece of code, what versions are you using for next.js, react ?

this is happening to me as well, even if the loop is set to false or 0

+1 same issue, it takes very long to go to the next word

I have this same issue the words is only displaying the first word
React 18

Same issue, i'm using Next 12.1.4 and react 18.0.0

Use the hook option and if you want to use the cursor effect you will need o to import it
import React from 'react'
import { useTypewriter, Cursor} from 'react-simple-typewriter'

const MyComponent = () => {

  const {text} = useTypewriter({
    words: ['Hello', 'From', 'Typewriter', 'Hook!'],
    loop: {3},
    onLoopDone: () => console.log(`loop completed after 3 runs.`),
  })

  return (

      {text}
      <Cursor />

  )
}

nexpected token (9:15)
7 |     const text = useTypewriter({
8 |         words: ['Hello', 'From', 'Typewriter', 'Hook!'],

9 |         loop:{3},
|                ^
10 |       })

You can do that with number like.
<Typewriter
  words={["1", "2", "3", "4"]}
  loop={1}
  cursor
  cursorStyle="_"
  typeSpeed={50}
  deleteSpeed={20}
  delaySpeed={1000}
/>;

Solved using useTypewriter hook, here let the code
import type { NextPage } from "next";
import { useTypewriter, Cursor } from "react-simple-typewriter";

const Home: NextPage = () => {
    const words = ["Software developer", "Full-Stack developer", "Creative", "Web designer"];
    const { text } = useTypewriter({
        words,
        loop: 0, // Infinit
    });
    return (

Hector Lobato

                    {text}
                    <Cursor />

            <button>Download Resume</button>

    );
};

export default Home;

This code re-renders the component every letter change.


An error occured, no output was received after executing the phpmd command

[Info  - 21:57:46] Document saved, starting validation.
[Info  - 21:57:46] PHP Mess Detector validation started for file:///c%3A/Progetti/example.com/src/Admin/CategoryHasFeatureAdmin.php
[Info  - 21:57:46] PHP Mess Detector command not using global PHP, skipping PHP test
[Info  - 21:57:46] Building phpmd version command: vendor/bin/phpmd.bat --version
[Error - 21:57:46] An error occured during document validation after save with the following message: An error occured, no output was received after

Any help? My configuration is basically this (locally phpmd, workspace settings):
  "phpmd.command": "vendor/bin/phpmd.bat",
  "phpmd.rules": "cleancode,codesize",
  "phpmd.verbose": true

The command is working just fine from the terminal:

PS C:\Progetti\example.com> vendor/bin/phpmd.bat --version
PHPMD 2.8.1

VSCode version:

PS C:\example.com> code --version
1.45.0
d69a79b73808559a91206d73d7717ff5f798f23c
x64

Hi,
The paths in your log indicate you are on a windows system but your config value uses forward slashes. Could you try using backslashes in your phpmd.command setting. I'm guessing that will do the trick.

Hai, thanks, I will try. Anyways, do you think that this could be fixed in the next release? The workspace settings could be shared and versioned, you know 😉

I'll add it to the list, I'll probably be working on a new release by the last quarter of this year... A PR is always welcome though :stuck_out_tongue_winking_eye:


[Bug] Can not run vLLM Mixtral 8x7b

先决条件

[X] 我已经搜索过 问题 和 讨论 但未得到预期的帮助。
[X] 错误在 最新版本 中尚未被修复。

问题类型
我正在使用官方支持的任务/模型/数据集进行评估。
环境
{'CUDA available': True,
 'CUDA_HOME': '/usr/local/cuda',
 'GCC': 'gcc (Ubuntu 12.3.0-1ubuntu1~22.04) 12.3.0',
 'GPU 0,1,2,3,4,5,6,7': 'NVIDIA GeForce RTX 4090',
 'MMEngine': '0.10.4',
 'MUSA available': False,
 'NVCC': 'Cuda compilation tools, release 12.4, V12.4.131',
 'OpenCV': '4.10.0',
 'PyTorch': '2.3.1+cu121',
 'PyTorch compiling details': 'PyTorch built with:\n'
                              '  - GCC 9.3\n'
                              '  - C++ Version: 201703\n'
                              '  - Intel(R) oneAPI Math Kernel Library Version '
                              '2022.2-Product Build 20220804 for Intel(R) 64 '
                              'architecture applications\n'
                              '  - Intel(R) MKL-DNN v3.3.6 (Git Hash '
                              '86e6af5974177e513fd3fee58425e1063e7f1361)\n'
                              '  - OpenMP 201511 (a.k.a. OpenMP 4.5)\n'
                              '  - LAPACK is enabled (usually provided by '
                              'MKL)\n'
                              '  - NNPACK is enabled\n'
                              '  - CPU capability usage: AVX512\n'
                              '  - CUDA Runtime 12.1\n'
                              '  - NVCC architecture flags: '
                              '-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_75,code=sm_75;-gencode;arch=compute_80,code=sm_80;-gencode;arch=compute_86,code=sm_86;-gencode;arch=compute_90,code=sm_90\n'
                              '  - CuDNN 8.9.2\n'
                              '  - Magma 2.6.1\n'
                              '  - Build settings: BLAS_INFO=mkl, '
                              'BUILD_TYPE=Release, CUDA_VERSION=12.1, '
                              'CUDNN_VERSION=8.9.2, '
                              'CXX_COMPILER=/opt/rh/devtoolset-9/root/usr/bin/c++, '
                              'CXX_FLAGS= -D_GLIBCXX_USE_CXX11_ABI=0 '
                              '-fabi-version=11 -fvisibility-inlines-hidden '
                              '-DUSE_PTHREADPOOL -DNDEBUG -DUSE_KINETO '
                              '-DLIBKINETO_NOROCTRACER -DUSE_FBGEMM '
                              '-DUSE_QNNPACK -DUSE_PYTORCH_QNNPACK '
                              '-DUSE_XNNPACK -DSYMBOLICATE_MOBILE_DEBUG_HANDLE '
                              '-O2 -fPIC -Wall -Wextra -Werror=return-type '
                              '-Werror=non-virtual-dtor -Werror=bool-operation '
                              '-Wnarrowing -Wno-missing-field-initializers '
                              '-Wno-type-limits -Wno-array-bounds '
                              '-Wno-unknown-pragmas -Wno-unused-parameter '
                              '-Wno-unused-function -Wno-unused-result '
                              '-Wno-strict-overflow -Wno-strict-aliasing '
                              '-Wno-stringop-overflow -Wsuggest-override '
                              '-Wno-psabi -Wno-error=pedantic '
                              '-Wno-error=old-style-cast -Wno-missing-braces '
                              '-fdiagnostics-color=always -faligned-new '
                              '-Wno-unused-but-set-variable '
                              '-Wno-maybe-uninitialized -fno-math-errno '
                              '-fno-trapping-math -Werror=format '
                              '-Wno-stringop-overflow, LAPACK_INFO=mkl, '
                              'PERF_WITH_AVX=1, PERF_WITH_AVX2=1, '
                              'PERF_WITH_AVX512=1, TORCH_VERSION=2.3.1, '
                              'USE_CUDA=ON, USE_CUDNN=ON, USE_CUSPARSELT=1, '
                              'USE_EXCEPTION_PTR=1, USE_GFLAGS=OFF, '
                              'USE_GLOG=OFF, USE_GLOO=ON, USE_MKL=ON, '
                              'USE_MKLDNN=ON, USE_MPI=OFF, USE_NCCL=1, '
                              'USE_NNPACK=ON, USE_OPENMP=ON, USE_ROCM=OFF, '
                              'USE_ROCM_KERNEL_ASSERT=OFF, \n',
 'Python': '3.10.14 (main, May  6 2024, 19:42:50) [GCC 11.2.0]',
 'TorchVision': '0.18.1+cu121',
 'numpy_random_seed':<PHONE_NUMBER>,
 'opencompass': '0.2.6+c5074c0',
 'sys.platform': 'linux'}

重现问题 - 代码/配置示例
Just the built in run.py file.
重现问题 - 命令或脚本
CUDA_VISIBLE_DEVICES=4,5 python run.py --models vllm_mixtral_8x7b_v0_1 --datasets mmlu_gen -m infer --max-num-workers 1 --debug
重现问题 - 错误信息
/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/transformers/utils/hub.py:127: FutureWarning: Using `TRANSFORMERS_CACHE` is deprecated and will be removed in v5 of Transformers. Use `HF_HOME` instead.
  warnings.warn(
07/23 14:32:38 - OpenCompass - INFO - Loading mmlu_gen: configs/datasets/mmlu/mmlu_gen.py
07/23 14:32:38 - OpenCompass - INFO - Loading vllm_mixtral_8x7b_v0_1: configs/models/mistral/vllm_mixtral_8x7b_v0_1.py
07/23 14:32:38 - OpenCompass - INFO - Loading example: configs/summarizers/example.py
07/23 14:32:38 - OpenCompass - INFO - Current exp folder: outputs/default/20240723_143238
07/23 14:32:38 - OpenCompass - WARNING - SlurmRunner is not used, so the partition argument is ignored.
07/23 14:32:38 - OpenCompass - DEBUG - Modules of opencompass's partitioner registry have been automatically imported from opencompass.partitioners
07/23 14:32:38 - OpenCompass - DEBUG - Get class `NumWorkerPartitioner` from "partitioner" registry in "opencompass"
07/23 14:32:38 - OpenCompass - DEBUG - An `NumWorkerPartitioner` instance is built from registry, and its implementation can be found in opencompass.partitioners.num_worker
07/23 14:32:38 - OpenCompass - DEBUG - Key eval.runner.task.judge_cfg not found in config, ignored.
07/23 14:32:38 - OpenCompass - DEBUG - Key eval.runner.task.dump_details not found in config, ignored.
07/23 14:32:38 - OpenCompass - DEBUG - Key eval.given_pred not found in config, ignored.
07/23 14:32:38 - OpenCompass - DEBUG - Additional config: {}
07/23 14:32:38 - OpenCompass - INFO - Partitioned into 1 tasks.
07/23 14:32:38 - OpenCompass - DEBUG - Task 0: [mixtral-8x7b-v0.1-vllm/lukaemon_mmlu_college_biology,mixtral-8x7b-v0.1-vllm/lukaemon_mmlu_college_chemistry]
07/23 14:32:38 - OpenCompass - DEBUG - Modules of opencompass's runner registry have been automatically imported from opencompass.runners
07/23 14:32:38 - OpenCompass - DEBUG - Get class `LocalRunner` from "runner" registry in "opencompass"
07/23 14:32:38 - OpenCompass - DEBUG - An `LocalRunner` instance is built from registry, and its implementation can be found in opencompass.runners.local
07/23 14:32:38 - OpenCompass - DEBUG - Modules of opencompass's task registry have been automatically imported from opencompass.tasks
07/23 14:32:38 - OpenCompass - DEBUG - Get class `OpenICLInferTask` from "task" registry in "opencompass"
07/23 14:32:38 - OpenCompass - DEBUG - An `OpenICLInferTask` instance is built from registry, and its implementation can be found in opencompass.tasks.openicl_infer
07/23 14:32:39 - OpenCompass - INFO - Task [mixtral-8x7b-v0.1-vllm/lukaemon_mmlu_college_biology,mixtral-8x7b-v0.1-vllm/lukaemon_mmlu_college_chemistry]
07/23 14:32:39 - OpenCompass - DEBUG - Modules of opencompass's model registry have been automatically imported from opencompass.models
07/23 14:32:39 - OpenCompass - DEBUG - Get class `VLLM` from "model" registry in "opencompass"
INFO 07-23 14:32:39 config.py:695] Defaulting to use mp for distributed inference
INFO 07-23 14:32:39 llm_engine.py:174] Initializing an LLM engine (v0.5.2) with config: model='mistralai/Mixtral-8x7B-v0.1', speculative_config=None, tokenizer='mistralai/Mixtral-8x7B-v0.1', skip_tokenizer_init=False, tokenizer_mode=auto, revision=None, rope_scaling=None, rope_theta=None, tokenizer_revision=None, trust_remote_code=True, dtype=torch.bfloat16, max_seq_len=32768, download_dir=None, load_format=LoadFormat.AUTO, tensor_parallel_size=2, pipeline_parallel_size=1, disable_custom_all_reduce=False, quantization=None, enforce_eager=False, kv_cache_dtype=auto, quantization_param_path=None, device_config=cuda, decoding_config=DecodingConfig(guided_decoding_backend='outlines'), observability_config=ObservabilityConfig(otlp_traces_endpoint=None), seed=0, served_model_name=mistralai/Mixtral-8x7B-v0.1, use_v2_block_manager=False, enable_prefix_caching=False)
INFO 07-23 14:32:40 custom_cache_manager.py:17] Setting Triton cache manager to: vllm.triton_utils.custom_cache_manager:CustomCacheManager
(VllmWorkerProcess pid=2577027) Process VllmWorkerProcess:
(VllmWorkerProcess pid=2577027) Traceback (most recent call last):
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/multiprocessing/process.py", line 314, in _bootstrap
(VllmWorkerProcess pid=2577027)     self.run()
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/multiprocessing/process.py", line 108, in run
(VllmWorkerProcess pid=2577027)     self._target(*self._args, **self._kwargs)
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/vllm/executor/multiproc_worker_utils.py", line 210, in _run_worker_process
(VllmWorkerProcess pid=2577027)     worker = worker_factory()
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/vllm/executor/gpu_executor.py", line 70, in _create_worker
(VllmWorkerProcess pid=2577027)     wrapper.init_worker(**self._get_worker_kwargs(local_rank, rank,
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/vllm/worker/worker_base.py", line 326, in init_worker
(VllmWorkerProcess pid=2577027)     self.worker = worker_class(*args, **kwargs)
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/vllm/worker/worker.py", line 90, in __init__
(VllmWorkerProcess pid=2577027)     self.model_runner: GPUModelRunnerBase = ModelRunnerClass(
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/vllm/worker/model_runner.py", line 229, in __init__
(VllmWorkerProcess pid=2577027)     self.attn_backend = get_attn_backend(
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/vllm/attention/selector.py", line 45, in get_attn_backend
(VllmWorkerProcess pid=2577027)     backend = which_attn_to_use(num_heads, head_size, num_kv_heads,
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/vllm/attention/selector.py", line 148, in which_attn_to_use
(VllmWorkerProcess pid=2577027)     if torch.cuda.get_device_capability()[0] < 8:
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/torch/cuda/__init__.py", line 430, in get_device_capability
(VllmWorkerProcess pid=2577027)     prop = get_device_properties(device)
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/torch/cuda/__init__.py", line 444, in get_device_properties
(VllmWorkerProcess pid=2577027)     _lazy_init()  # will define _get_device_properties
(VllmWorkerProcess pid=2577027)   File "/home/cpwu/miniconda3/envs/opencompass/lib/python3.10/site-packages/torch/cuda/__init__.py", line 279, in _lazy_init
(VllmWorkerProcess pid=2577027)     raise RuntimeError(
(VllmWorkerProcess pid=2577027) RuntimeError: Cannot re-initialize CUDA in forked subprocess. To use CUDA with multiprocessing, you must use the 'spawn' start method
ERROR 07-23 14:32:41 multiproc_worker_utils.py:120] Worker VllmWorkerProcess pid 2577027 died, exit code: 1
INFO 07-23 14:32:41 multiproc_worker_utils.py:123] Killing local vLLM worker processes

其他信息
No response

Hi, the issue appears to be due to vLLM's inability to run the Mixtral model internally, rather than an issue with OpenCompass. I suggest trying to create a minimal reproducible script that excludes OpenCompass components. Instead, write a simple Python file to run this model using vLLM and see if it can be loaded successfully.

Thank you for your reply, I created a minimal reproducible script vllm_mixtral.py
from vllm import LLM, SamplingParams

# Sample prompts.
prompts = [
    "Hello, my name is",
    "The president of the United States is",
    "The capital of France is",
    "The future of AI is",
]
# Create a sampling params object.
sampling_params = SamplingParams(temperature=0.8, top_p=0.95)

# Create an LLM.
llm = LLM(model="mistralai/Mixtral-8x7B-v0.1", tensor_parallel_size=8, download_dir="/home/data/huggingface", gpu_memory_utilization=0.9)

# Generate texts from the prompts. The output is a list of RequestOutput objects
# that contain the prompt, generated text, and other information.
outputs = llm.generate(prompts, sampling_params)
# Print the outputs.
for output in outputs:
    prompt = output.prompt
    generated_text = output.outputs[0].text
    print(f"Prompt: {prompt!r}, Generated text: {generated_text!r}")

and run it with command HF_HUB_OFFLINE=1 python vllm_mixtral.py
and it successfully execute the model.

After trying more models, it appears that this issue seems to be related to tensor parallelism. When adjusting the configuration file config/models/qwen/vllm_qwen1_5_moe_a2_7b.py and set tensor_parallel_size=2 and num_gpus=2, the same issue occurred.

Thank you for reporting the issue. To resolve this, try modify the tensor parallel parameter in the configuration file configs/models/mistral/vllm_mixtral_8x7b_v0_1.py to tensor_parallel_size=8. This change may enable the model to run correctly.

After modified the configs/models/mistral/vllm_mixtral_8x7b_v0_1.py file with tensor_parallel_size=8 and num_gpus=8
And run with command python run.py --models vllm_mixtral_8x7b_v0_1 --datasets mmlu_gen -m infer --max-num-workers 1
The log still shows the same problem.
Is there a specific environment version that than successfully run at tensor_parallel=8? Are there any vllm, torch or opencompass version requirements?

After some searching, this should be caused by a behavior change of vLLM since vllm-0.5.1. As metioned here: https://github.com/vllm-project/vllm/pull/5669#issuecomment-2181625739.
So an easy workaround is using VLLM_WORKER_MULTIPROC_METHOD=spawn prior to the python run.py command.


Array indexing  for v1beta1

Feature request

Hi Team ,I come up with a problem where we are using v1beta1 and we are trying to use array indexing for default values to pass those in steps.As i am aware this feature in alpha,But my team was not a in place to upgrade it to newer version just because of one task that it requires.So as this feature is not available in v1beta1 ,is there any chance that could added in next resales ?
To get more insights into this i am leaving a slack thread that i discussed  https://tektoncd.slack.com/archives/CJ62C1555/p1668629030223269
Use case
The above slack thread will provide the use case details and it will benefit the users who are still depending the v1beta1.

Also, https://github.com/tektoncd/pipeline/issues/5632 tracks allowing alpha features to be enabled individually instead of all or nothing


[Feature] Create own tests

Difficult to know what to review without PR description (but I think I got the idea)

Oops, I thought that the title was enough, sorry! To explain a bit more, the goal is to give users the possibility to create their own tests (name, initial input, expected output), and to submit their code on these tests only.


Improving search function in admin area

The admin > plans view only allows search by title. We should expand the search so it also allows the author name to be search, and displays the dept and searches this if in use by uni.

In addition, the author names should be links so you can navigate through to see all the plans created by one user.

I think this ticket should stick to improving the search options, and maybe offering some filtering options to enhance this functionality beyond text-matching.
(along with adding the links to the owner's edit profile page)
I've added #2240 to cover the list of user's plans, and other changes to the admin view of the user's profile.

Search is so much better now! Really great to be able to search by stems and across fields.
Closing out


Add new blog post for GSoC - User Interface

I am preparing the animated GIF for adding it in the post, so I will update the MD file soon.

title: "Google Summer of Code 2019: User Interface"
id: gsoc-2019-user-interface

Thanks, @Siedlerchr! I have done those changes.

Sure! It is done :D


[DBT Doc Update] Updating the latest options visible in the BigQuery Create credentials Wizard

This is a minor change to remove an extra line in the instructions to make it more learner-friendly.
What are you changing in this pull request and why?
Change reasons documented in the Issue: https://github.com/dbt-labs/docs.getdbt.com/issues/4299
We are making this change to reflect the latest BigQuery UI for Creating the Credentials.

[ ] Review the Content style guide and About versioning so my content adheres to these guidelines.
[ ] Add a checklist item for anything that needs to happen before this PR is merged, such as "needs technical review" or "change base branch."

Validated the step is no longer in the Google workflows.
Thank you @anksu2024 for the update!


Get a list of scenarios

I will find very usefull to have an option for formatting behat output only to list the scenarios that i have in the application.
The progress option is fine, but if i want only the list of scenarios i have it is useless.
The pretty option has the scenarios, but also have the steps, so it have too much information.
I understand that i have to have control of which scenarios i have and which not, but nowadays i have more than 200 scenarios (and growing), and sometimes it is difficult to know which ones are missing, and which ones are obsolete.

Hi,
Is this solution developped on the actual version ?


Backend: Implement Preview Image APIs

NOTE: We should wait to do this after we've defined the APIs and data storage (https://github.com/LPGameDevs/EditarrrPublic/issues/53)
We're building a backend service/DB to store the data about levels.
The proposed APIs we'll need for this backend service are listed in https://github.com/LPGameDevs/EditarrrPublic/blob/develop/backend/README.md#apis
We're splitting the API implementation work into several Issues - this Issue is to implement the APIs that store the preview images for the level in the S3 bucket:

UploadPreviewImage
GetPreviewImage

See https://github.com/LPGameDevs/EditarrrPublic/blob/develop/backend/README.md for the proposed backend setup

Notes on implementation:

https://aws.amazon.com/blogs/compute/patterns-for-building-an-api-to-upload-files-to-amazon-s3/ has some great info about recommended patterns for uploading to an S3 bucket. I'm thinking the Using Amazon API Gateway as a direct proxy approach should suit us fine, because we can be flexible with the bucket URL, the images should < 10MB, and its the simplest.

https://docs.aws.amazon.com/apigateway/latest/developerguide/integrating-api-with-aws-services-s3.html#api-as-s3-proxy-iam-permissions is a tutorial on how to implement this
https://serverlessfirst.com/serverless-photo-upload-api/ is a tutorial on how to do the alternate option, Using API Gateway with presigned URLs

https://aws.plainenglish.io/use-s3-to-store-images-from-your-application-e3f8c912b422 is another tutorial where the Lambda would do all the handling, but I think it doesn't seem like a recommended design, and might as well leave the lambad out of it

Closing this - done in https://github.com/LPGameDevs/EditarrrPublic/commit/7c88380e93bcb83e289bb889ad4b779acc56aa88#diff-bafac369c447357e72d5abf660a99375f32d2bbc24309ebf5037160e6ea0ee78


Examples in Azure PowerShell and CLI differ

The examples given in the Azure PowerShell and Azure CLI  blocks differ, for no good reason.
Azure CLI has an extra --parameters storageAccountType=Standard_GRS. Also the name of the resource group differs from the one shown in the PowerShell block. And the order of arguments also isn't identical.
I'd suggest to make them be the same.
Going to submit a PR in a few moments.

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

ID: 97d412f9-6a69-d104-e3da-a5aa4a8b267a
Version Independent ID: 504e27e0-6013-7605-d440-7d7f3384d4fe
Content: Deployment modes - Azure Resource Manager
Content Source: articles/azure-resource-manager/templates/deployment-modes.md
Service: azure-resource-manager
Sub-service: templates
GitHub Login: @mumian
Microsoft Alias: jgao

See https://github.com/MicrosoftDocs/azure-docs/pull/77095

@alexs77  Thanks for your valuable feedback and for contributing to Azure documents.
@mumian Kindly review the PR submitted by @alexs77 .

@alexs77 Thank you for your comment.  I have approved your PR.
#please-close


Search SDK: Adding new preview features to indexers

This is the first pass of updating Indexers and DataSources with the new features introduced in 2015-02-28-Preview. This commit includes the smallest changes that are easiest to test; more to follow.
FYI @chaosrealm @seansaleh

💵 LGTM


Documentation for running on node

Can you add documentation for running on node?
I am currently using a hack found in a closed issue:
import 'undom/register';

global['document'].createDocumentFragment = () => global['document'].createElement('#fragment');

Hopefully there's a way to do this without messing with global objects!

@peterjwest the recently released 1.1.0 version should allow you to do:
import undom from 'undom';
import {config as renderSpyConfig} from 'preact-render-spy';
renderSpyConfig.createFragment = () => undom().body;

This is documented here:
https://github.com/mzgoddard/preact-render-spy#configuration
I would be open to a PR making a change to the README with an example

import undom from 'undom';
import {config as renderSpyConfig} from 'preact-render-spy';
let doc = undom();
renderSpyConfig.createFragment = () => doc.createElement('body');

@developit would createElement('#fragment') be better/worse?

Ace, thanks! I will be trying this out in the next few days.

@peterjwest got any feedback, how do you think we should document this?

Not yet, sorry! I will try to have a look tonight.


[9.x] Re-implement original SesTransport

Replaces https://github.com/laravel/framework/pull/40685
This PR re-implements the old SesTransport again. All features should work again except the swift mailer specific ones.
Here's the original SesTransport: https://github.com/laravel/framework/blob/8.x/src/Illuminate/Mail/Transport/SesTransport.php
I've also removed the addition of Message ID's to the headers of the sent message afterwards since Symfony mailer now takes care of generating this.
I have not been able to manually test this out yet.

Ping @deleugpn ^

@driesvints  Can you mark this as ready when you are able to test it manually?

I will try this out on Monday and provide feedback. Thank you so much for the work!

This implementation works correctly and the ConfigurationSet is properly configured. However, when adding custom headers to the Email, they are being lost somewhere along the execution stack. I will not investigate this further because of the preference of the other PR, so I will just jump to testing that one instead. I can dig deeper into the headers being lost if there is desire to merge this one.
Here is how I'm adding custom headers
$closure = function(Email $message) use ($tenant) {
            $message->getHeaders()->addTextHeader('X-ORG-TENANT', $tenant);
        };


Updated install notes for node < 7

✅ Closes: #66

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

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


Annotated function types with more than 3 parameters fail in non-interactive mode

module Problem
#lang-pulse
open Pulse

type a =
type b =
type c =
type d =
type f =

let ok (x:a) (y:b) (z:c) (w:d) (u:f) : slprop =
  emp

let ty (x:a) (y:b) (z:c) (w:d) = u:f -> stt unit emp (fun r -> ok x y z w u)

fn foo x y z w : ty x y z w  = u {
  fold ok x y z w u;
}

This is an interesting one:

It works interactively, in vscode.
It works after removing the w:d.
But it fails on the command-line:

❯ fstar.exe --include $PULSE_HOME/lib/pulse Problem.fst
* Error 228 at Problem.fst(15,36-15,36):
  - Could not check term:
        x -> y -> z -> w -> u79: Problem.f
          -> Pulse.Lib.Core.stt Prims.unit
              Pulse.Lib.Core.emp
              (fun _ -> Problem.ok x y z u79 u79)

* Error 189 at Problem.fst(17,26-17,27):
  - Expected expression of type d got expression u9 of type f
  - Raised within Tactics.refl_instantiate_implicits
  - See also Problem.fst(15,34-15,35)

2 errors were reported (see above)

According to git bisect, this was broken by the recent gensym changes:
16b55bffd981546a19ccaa65a6da7998680aa0e5

Ouch. Looks like a name clash right? I remember some discussions about F*'s gensym and Pulse's gensym clashing, but I forget the exact details. Probably the stabler and smaller F* gensym'd numbers now clash more easily?

I think you're right about the name clash.  Making the Pulse vars start at 10000 lets the example pass:
diff --git a/src/checker/Pulse.Typing.Env.fst b/src/checker/Pulse.Typing.Env.fst
index c3fad92f1..c5ae01cd9 100644
--- a/src/checker/Pulse.Typing.Env.fst
+++ b/src/checker/Pulse.Typing.Env.fst
@@ -106,7 +106,7 @@ let rec max (bs:list (var & typ)) (current:var)

 let fresh g =
   match g.bs with
-  | [] -> 1
+  | [] -> 10000
   | (x, _)::bs_rest ->
     let max = max bs_rest x in
     max + 1

I'm not sure where we get the F* gensym variables from, though.

I'm not sure where we get the F* gensym variables from, though.

I think that was the wrong question.  The question is where F* is getting the Pulse gensym variables from and that is easy to answer.  We're running the F* type-checker on u:f -> stt unit emp (fun r -> ok x y z w u), then the F* type-checker creates a new variable to go under this binder, and this new variable clashes with the existing one previously created by Pulse.


Fix proxy hang due to held lock

#1336 removed the block around variable for the if let.
However, if let Some(handler) = self.pending.lock().remove(&id) would drop the lock at the end of the statement, which is after the if statement has ran.
(The easiest way to trigger the hand for me was to remove or create a file in the file listing)

F me... sorry about that, I thought the temporary lock would be dropped immediately after remove. TIL.


Multi-line ignore parsing in config_file

In tox.ini it is entirely possible to have multi-line lists with trailing commas, e.g.
envlist =
    py27,
    py34,

If however you do
[pep8]
ignore =
    E1,
    E2,

then options.ignore ends up as ('\nE1', \nE2', '')
The first two items of that tuple are "mildly inconvenient"; the preceding \n just means the ignore is...ignored - a consequence of the multiline
The empty string as the last item, a consequence of the trailing comma, is much more insidious, as it causes all checks to be silently ignored thanks to https://github.com/PyCQA/pep8/blob/master/pep8.py#L1890-L1901, specifically
return (code.startswith(self.options.ignore) and
                not code.startswith(self.options.select))

Currently, this PR includes some py27 tests to demonstrate this behaviour (I haven't tested my tests in other environments yet; am letting Travis do that for me) - I'll try to follow up with an actual fix.
Ultimately, the "real problem" here is probably "parsing another tool's config file"; there'll always be fun quirks etc., but that's much harder to do anything about!

(See https://github.com/doismellburning/cookiecutter-django/pull/7 for more context - many thanks to @rfleschenberg for his debugging assistance)

I think there was already a bug for this, but it wasn't on the top of anyone's todo list. With tests already written, this should be a simple one for people to fix (I would hope).

Welp, think I fixed it...

:+1: Looks good to me.

:sparkles: :cake: :sparkles: Thanks @doismellburning

Cheers!

Thanks @doismellburning !


Use trust_remote_code for dataset load

Following https://github.com/huggingface/datasets/issues/6400 and the 2.16 release of datasets you now require trust_remote_code=True for datasets with a custom builder config.
if I read the code correctly, the --trust_remote_code flag gets passed to model and tokenizer already. It does not reach the load_dataset method here.
That seems an easy fix and I can open a PR next week.
Addressing it for the finetuning examples would be more edits.

if I'm not mistaken, the only dataset that has arbitrary code in the harness now and could need this flag in the future is MultiPL-E?
It's a bit different from models where users can pass any model they want, whereas we have a limited number of carefully selected tasks so I'm not sure we need the flag for all tasks (we can add it just for MultiPL-E when it's a requirement if the authors don't update their loading script by then).

I haven't checked myself. And moving all datasets to parquet export and no builder script is the better idea anyway. Perhaps adding a notice to the new task template might be an easier "fix".
If there is just a single case it can by bypassed using the env flag much easier.
I additionally came across this with the task I am developing. But moving to parquet is on my to-do list either way.
Feel free to close this issue and reject the draft PR.

sounds good, I also talked to MultiPL-E authors and they will remove the python code in the dataset so it wouldn't require the flag.


local_auth 2.2.0 did a breaking change so should have been 3.0.0

What package does this bug report belong to?
local_auth
What target platforms are you seeing this bug on?
iOS
Have you already upgraded your packages?
Yes
Dependency versions
No response
Steps to reproduce
depending on local_auth: ^2.1.3
we use IOSAuthMessages from 'package:local_auth_ios/local_auth_ios.dart'
since yesterday 2.2.0 is released where IOSAuthMessages moved to another package
This should have been a breaking change
Expected results
It should have been release 3.0.0
Actual results
It does not compile anymore
Code sample
Code sample
This is taken from the readme:
```dart
import 'package:local_auth_android/local_auth_android.dart';
import 'package:local_auth_darwin/local_auth_ios.dart';
// ···
    final bool didAuthenticate = await auth.authenticate(
        localizedReason: 'Please authenticate to show account balance',
        authMessages: const [
          AndroidAuthMessages(
            signInTitle: 'Oops! Biometric authentication required!',
            cancelButton: 'No thanks',
          ),
          IOSAuthMessages(
            cancelButton: 'No thanks',
          ),
        ]);
```

Screenshots or Videos
No response
Logs
Logs
  error • Target of URI doesn't exist: 'package:local_auth_ios/local_auth_ios.dart' • lib/some/package/biometrics_service.dart:10:8 • uri_does_not_exist

Flutter Doctor output
Doctor output
[✓] Flutter (Channel stable, 3.16.9, on macOS 14.0 23A344 darwin-arm64, locale en-BE)
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 15.2)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2023.1)
[✓] VS Code (version 1.86.2)
[✓] Connected device (2 available)
[✓] Network resources

Target of URI doesn't exist: 'package:local_auth_ios/local_auth_ios.dart'

How does this URI not exist? local_auth_ios is still a package, it's just discontinued.
Were you importing a package that you didn't have a pubspec.yaml dependency on, relying on the transitive dependency from another package?

For reference the governing semver rule is this one:

Major version X (X.y.z | X > 0) MUST be incremented if any backwards incompatible changes are introduced to the public API.

The set of packages in the dependencies list of a package are not considered to be part of that package's public API.

@stuartmorgan does that mean if someone wants to use local_auth with an AuthMessages config, that he also should include the local_auth_darwin or local_auth_ios dependency with a ^x.x.x version reference? Maybe something to add to the README file?
I thought all the platform packages where handled by pub so that's why I did not add it here.

I'm did a test here, using version 2.2.0 and still using local_auth_ios iOSAuthMessage compiles but it doesn't work, which is even worse. it completely ignores the iOSAuthMessage from local_auth_ios

@krispypen
Can you check the 2.2.0 changelog and see if it helps in your case ?

@darshankawar it states indeed:
Clients directly importing local_auth_ios for auth strings should switch dependencies and imports to local_auth_darwin. No other change is necessary.
But that is my point, it should have been a 3.0.0 version release because on a minor release you can't expect users to check the changelog

it completely ignores the iOSAuthMessage from local_auth_ios

That should not be the case; I specifically tested for that before publishing the switchover (and I just re-tested from scratch) and I see the expected behavior, which is that a project that correctly depends on local_auth_ios and also still uses local_auth_ios in their Dart code will still pick up the strings. They should only be ignored if you are using a mix of local_auth_ios and local_auth_darwin.
Please provide:

the exact Dart code you used,
the exact pubspec, and
the output of running grep local_auth .dart_tool/flutter_build/dart_plugin_registrant.dart in your project directory after building.

But that is my point, it should have been a 3.0.0 version release because on a minor release you can't expect users to check the changelog

I did not expect users to check the changelog; that's why the entry says "should" not "must". Users whose projects were correctly configured (i.e., depended on local_auth_ios if they were importing it) should continue to work without any changes.

@stuartmorgan does that mean if someone wants to use local_auth with an AuthMessages config, that he also should include the local_auth_darwin or local_auth_ios dependency with a ^x.x.x version reference?

Yes. There is no circumstance in Flutter/Dart that I can think of where importing a package that you do not depend directly on is a good idea.

Maybe something to add to the README file?

I can file an issue to update the README to explicitly remind people to follow standard package usage practices here, sure.

I thought all the platform packages where handled by pub so that's why I did not add it here.

I'm not sure what "handled by pub" means exactly. It is the case that it's possible to import things that you only have transitive dependencies on, but it's a bad idea as explained above.


[Feature Request/Question] Controller watch namespaces based on labels (and event sources)

Description
Based on the documentation, the controller is able to dynamically adjust the watched namespaces based on explicit namespace names (often provided through a config map or similar). A convenient extension to this would be able to watch namespaces based on the labels/annotations for a given namespace. I would be helpful if this was built into the machinery of the controller itself, so it could be controlled by some high level configuration
Motivation
Sometimes the creation of new namespaces that need to interact (be watched by)  with the operator are done through workflows outside of the purview of the "operator admin". Currently, in order to ensure coverage of all namespaces, either (1) both workflows need to interact and inform the operator deployment when namespaces are added, or (2) the operator simply needs to watch all namespaces. This is where a third option, of only coordinating the appropriate labels would be beneficial
(Somewhat) Related Projects
https://github.com/kubernetes-sigs/hierarchical-namespaces/blob/master/docs/user-guide/concepts.md
Workarounds considered
Use the Kubernetes client itself to query for namespaces upon controller start, periodically poll for changes. Similarly, try to use some form of an Informer to get the same information

Hi,
The Idea with the current implementation is that allows custom use cases.
So to implement this you can simply register an informer with favric8 flient before the operator is started that watches namespaces with the target label. On change it will call the registered controller ( the current API).
Basically we don't want to support such custom scenarios on purpose, since it's a minimal effort to implement it with the current API.

I agree that it can be implemented in that fashion. I think the idea was mainly to streamline the code, as the previous case of setting namespace can be done purely at the annotation level. Happy to resolve though, as there are workarounds possible

There are several approaches users configure this, one is to watch a config map, other would be what you described. We could think about some supporting classes, but would not add it directly into the core of the Operator. Feel free to create a PR for such.

Makes sense. I will proceed with the alternative and evaluate how it could be generalized / added in


<EMAIL_ADDRESS>is not used" is displayed as an error

Issue Summary
Hello!, hope you are doing well.
On a large amount of themes we are receiving this kind of error (probably 70 - 80% of themes in the Ghost marketplace, will get this as well):

Multiple customers are assuming the theme/platform do not work as expected, so we need to explain to every customer that is a beta feature and they can safely ignore it for the moment.
After checking the info about this error: https://ghost.org/docs/themes/helpers/page/ this setting is only available when "beta editor setting" is "ON"  from the Labs section, so this error shouldn't appear or at least should be displayed as a an "information tooltip" but not as an error.
I think a quick solution would be to remove it as a "critical error", but a good alternative would be to insert a new option into "package.json" to mark the theme as compatible or not (similar to config -> "card_assets": true), and finally evaluate if the syntax is correct on the page.hbs file.
Other Ghost Authors as @fueko are getting similar issues on https://github.com/TryGhost/Ghost/issues/17745 that could be related.
Thank you very much!
Steps to Reproduce
Upload any theme that do not include:
{{#match @page.show_title_and_feature_image}} ...content... {{/match}}
Ghost Version
5.59.1
Node.js Version
v18.16.1
How did you install Ghost?
localhost
Database type
SQLite3
Browser & OS version
No response
Relevant log / error output
No response
Code of Conduct

[X] I agree to be friendly and polite to people in this repository

This being labeled as an error does feel misleading. In the past, an error would indicate the upload/activation of a theme has failed, whereas a warning could be raised by the upload/activation could still suceed.
Would it be possible to demote this error level, or better yet, only raise it if it is applicable to the current installation and/or theme? Our theme doesn't have a page.hbs partial, so doesn't seem relevant to us.

The only errors displayed in Ghost admin (when not in dev mode) are errors. We've got two flavors of those, fatal and nonfatal. Fatal errors are what you mentioned - a warning where the theme cannot be activated - while nonfatal errors allow the user to still activate the theme.
We don't currently have a way to check for use of the @page-related features when activating a theme as theme activation only runs the theme through gscan.
The intent here was to call out potential loss of functionality, as indicated in the message. We can be more clear about that in the error message that is displayed and I've updated gscan to specifically call out the beta editor for this case.
As theme devs update their themes to use the @page feature(s) we both ensure that the themes are up to date with Ghost development and that Ghost+theme users get the best experience. This is definitely our recommendation.
Also worth noting is that while this only impacts the beta editor at this moment in time, the new editor will not always be in beta.

Thank you for the clarification on the difference of errors - I wasn't aware that there was a sub-class of errors that were non-fatal - this is really helpful!
Would it be possible to more clearly differentiate between the two in the future?
On the gscan issue, would it be possible to check if the given theme has a page.hbs defined before throwing errors, or would the @page helper potentially be used outside of the page.hbs partial?

Fatal errors are rare and for the time being we don't see a need to change how they are handled, as we strictly do not allow the user to activate a theme with them.
For the gscan error originally posted, we aren't particular about the filename. It could check page.hbs, post.hbs (as a fallback), or related partials.
I've updated the error message to specifically call out the beta editor without requiring users to click into the docs to find more info. I think this is a reasonable and quick solution for the time being while themes are being updated.

Thanks for the clarification @9larsons - I think that sounds like a reasonable resolution

Glad that works for you. I'm hung up on what appears to be a yarn bug at the moment so I'm not certain this'll make it in this week's release, sorry.

Thank you very much @9larsons for all the information and fixes you shared here!
In our case, the customers first impression was: "the theme is not working". This is mainly related to the UI, is there any plan to change the wording and colors of that lightbox?
I remember in the past those warnings were marked with orange and some words as "info" or "warnings", so maybe is not a bad idea to work on that first impression for non-tech customers.

The gscan changes were incorporated a few weeks ago with that last commit. I'm going to close this and please open a new issue if you feel there's necessary changes yet.


Redirect legacy Windows node setup URLs to new page

We have a page about Windows node setup. If there are legacy links or bookmarks, send people to the new page.
example
Follows #47888
/sig windows
/kind cleanup
Done for English only

/approve


[bug] remove_dir_all RUSTSEC-2023-0018

While packaging ast-grep 0.14.2 our tooling noted that it uses remove_dir_all in a certain version and might be affected by https://rustsec.org/advisories/RUSTSEC-2023-0018.

Thanks for reporting!
It is a transitive dependency from tempdir which is now deprecated.
https://docs.rs/tempfile/latest/tempfile/ tempfile looks a promising replacement for it.

Released in 0.14.4!


List the foods that contribute to a receipe retrieval failure

In the /recipes/:id GET handler, a 500 error is returned if any of the food records
are irretrievable. It should return the specific invalid food IDs.

The same issue applies to the /recipes/at/:page GET handler


CI stripe webhook

Starts stripe webhook before playwright tests

There are some changes to the donation flow from #1133. I will take a look and change the tests. You can remove the test files from this PR!

There are some changes to the donation flow from #1133. I will take a look and change the tests. You can remove the test files from this PR! You can rebase your changes on top of master

This PR should merge to #1110 I just haven't updated the base. I can do that now

Looks good to me, but you might want to wait for @kachar :)

It's still failing 😆 I am figuring out the stripe permissions this thing needs. After that it should pass and then we can merge it into your branch


Cross compilation

Is your feature request related to a problem? Please describe.
Build for operating systems different from host system
Describe the solution you'd like
Rust, Electron all have mature cross compilation systems

Yup, it's on our roadmap.

Right now we offer a GH action to build for the big three desktops. Doing this locally for all three is complicated by the fact that to the best of our knowledge, you are required by the Apple T&C to build MacOS (and iOS) apps on 'real' Mac hardware. So from my perspective there are only three options:

Use a Mac as host and build from there, potentially using docker / VMs
Use our GH action
The community creates and maintains an unofficial cross solution for non MacOS systems.

Since #2 technically solved the problem, I am closing this issue. Feel free to drop by the community discord and continue this discussion there.


[BEAM-2803, BEAM-2706] JdbcIO improvements

This solves two issues:

https://issues.apache.org/jira/browse/BEAM-2803 by changing the strategy of breaking fusion: instead of a regular reshuffle, materializes via side input first.
https://issues.apache.org/jira/browse/BEAM-2706 by introducing JdbcIO.readAll().

Also brings the validation messages in accordance with the updated guidance in PTransform Style Guide.
R: @jbonofre

Coverage increased (+0.003%) to 69.741% when pulling e5daf608122345c36eafd010b00c4d940adbff7d on jkff:jdbcio-improvements into c9653f27056d9d4dd85f7951f4edbd9da524b894 on apache:master.

Thanks, PTAL.

retest this please

retest this please

retest this please

Coverage decreased (-0.01%) to 69.668% when pulling 1476a3fa8d2aaed2d2af9265f248d7e5f999e013 on jkff:jdbcio-improvements into 8b540d2dd43af2a0495884d8152472a7ebff8a8e on apache:master.

Coverage decreased (-0.007%) to 69.671% when pulling 1476a3fa8d2aaed2d2af9265f248d7e5f999e013 on jkff:jdbcio-improvements into 8b540d2dd43af2a0495884d8152472a7ebff8a8e on apache:master.


HELP: Training conditional generation on my own dataset

We are studying the inverse design of stochastic honeycomb structures. That is , we hope to feed the model a targeted property curve of a structure (i.e. the stress strain curve, concept in mechanic field).  And we want to first train a unconditional model for ease. However, we didn't get a nice result after trying hard. and I hope to get some suggestions from you.
The dataset are like below, the scatter with color represent the nucleus of the cells in the structures, and the color represent the cell wall thickness.

We trained 2000 imaged for unconditional generation. The image size is 64*64. I have tried batchsize=32 and batchsize=16, we also tried the mse loss and mae loss . After training for 2000 epochs, the result is still bad, and the mse loss is fluctuated around 0.0003. The training result is below
training_result_using mse loss:

training_result_using mae loss:

I dont know how to deal with it , hoping to get some suggestion from you!!!  Very thanks for your contribution.
@

Hope anyone can offer some help


Fix broken test runner

The for loop in travis.yml affected by this PR was buggy, I think.
Previous to this PR, the loop would terminate silently at the first test that ended with exit code 5, which is parsl/tests/test_flowcontrol/test_doc_config.py
I think this is because the value of $?, which is compared with the number 5, is not the exit code expected (the pytest exit code), but is the exit code of the last thing executed (which is the command [[ "$?" != 0 ]]).
This PR introduces a new named variable to store the desired $? value, and uses that in future comparisons.
It looks like this broke in PR #525.
With that change in place, several tests that are now run fail; this PR puts a skip annotation on those  so that this PR can at least get all the other tests running.

(The approval is obviously pending skipping the rest of the broken tests. We already have a 'fix broken tests' issue.)

@annawoodard  please re-approve and merge


idelib.__version__ hard-coded to (3, 0, 0)

with idelib==3.2.1:
>>> import idelib
>>> idelib.__version__
(3, 0, 0)

We could simply change the version manually, but it'd be nice if this were guaranteed to be consistent w/ the version listed in setup.py.

one option for fixing this is to use pkg_resources, which can pull out the version number from the setup.py like so:
import pkg_resources

version = pkg_resources.parse_version(pkg_resources.get_distribution("idelib").version)

However, pkg_resources is a part of the "third-party" package setuptools, so it would have to be added as a dependency and would be imported on each import of idelib.

Coincidentally, I was also looking at this just now. I've looked around, and there isn't really a great way to do it. The least-worst solution seems to be to keep a separate file with the version info, which is imported into both setup.py and the package proper.


Changing clusters keeps loading

Describe the bug

To Reproduce
Steps to reproduce the behavior:

Change between two local clusters

Desktop (please complete the following information):

OS: [e.g. iOS] MacOS
Version [e.g. 22] 1.7.3

Maybe we should have a maximum timeout for this. @andreiv1992 what do you think?


Replace act-arrange-assert with arrange-act-assert

Fix typo in act-arrange-assert in spies documentation
Arrange => Setup
Act => Exercise
Assert => Verify

Thanks!


Cannot find module 'node:path'

With only const eleventySass = require( 'eleventy-sass' ); in my .eleventy.js file I get...
[11ty] > Error in your Eleventy config file '/path/to/.eleventy.js'. You may need to run `npm install`.

`EleventyConfigError` was thrown
[11ty] > Cannot find module 'node:path'

Where have I gone wrong?

Sass options should be specified outside of compileOptions.
eleventyConfig.addPlugin( eleventySass, {
        sass: {
	        includes: './src/scss',
	        style: 'compressed',
	        sourceMap: false
        },
	compileOptions: {
		permalink: function( contents, inputPath ) {
			return ( data ) => {
				return data.page.filePathStem.replace( /^\/scss/, '/css' ) + '.min.css';
			};
		}
	}
} );

And, probably, includes options are not necessary.
I should've written this clearly in README, but includes options should be used for additional Sass/SCSS files.
For example, when you want to include another Sass/SCSS files with @use or @forward rules, and it is not in your scss directory in your case.
All of the Sass/SCSS files in input directory ("src" directory in your case) and its subdirectories will be compiled by eleventy-sass without any includes or loadPaths options.

Thanks again, that was my issue, I'm new to a lot of this and missed my wrong config setup.
Another issue I'm discovered, I like to use a _data/layout.js file with just module.exports = 'layouts/default.html'; inside to apply a default layout around all my html/md files but now the HTML layout is being wrapped around the generated stylesheet.
Not a big issue, I can define the layout in my files with layout: layouts/default.html unless you know of a way to exclude the CSS file?

Thank you, too.
I'm not good at English and not sure what is your situation and what you'd like to do.
If you want to use the layout file, but do not want to use the CSS file specified in it.
Do you have any reason that you cannot modify <link rel="stylesheet" href="path/to/css" /> line in your layouts/default.html file?
Or, using template language file (such as Nunjucks or Liquid) instead of HTML file for layouts may be useful.

Don't worry, your English is better than any other language I can speak!
I like to use a default template as described here: https://www.11ty.dev/docs/data-template-dir/#example-apply-a-default-layout-to-multiple-templates
By naming the file layout.js and placing it in _data it is applied to all files that do not have a layout defined. But by doing this the layout template is wrapped around the generated CSS file which is not wanted.

Thank you for kind words and explaining in detail.
Now I understand the problem.
I didn't realize this problem. Thank you very much for telling me.
I've just fixed it, and published v1.1.2.
Hope this works.

Thanks, that fixed it!
Thanks again for your prompt responses and loving the plugin!

Glad to hear that.
Your comments did improve the quality of the plugin a lot.
Thank you very much.


[Arch] Memory leakage - unreclaimable slab grows till system dies

Required information

Distribution: Arch Linux
The output of "lxc info" or if that fails:

Kernel version: 4.20
LXC version: 3.1.0
LXD version: 3.8
Storage backend in use: issue happens on both ext4 and btrfs, following logs/screens are from ext4

Issue description
I run two LXD instances on two KVM hosts. One uses ext4, other btrfs. I've had this issue happen since I started using LXD I believe and have been working around it by restarting the hosts every now and then.
Steps to reproduce

Install Arch Linux and AUR/lxd
Run some containers, wait a day or two
Stop containers, stop lxd, stop everything that could be consuming memory
/proc/meminfo has high SUnreclaim despite the hosts doing nothing.

Information to attach
Some/all containers are running privileged.
 /var/log/lxd/ansible/lxc.log
lxc ansible<PHONE_NUMBER>3350.634 WARN     conf - conf.c:lxc_setup_devpts:1641 - Invalid argument - Failed to unmount old devpts instance
lxc ansible<PHONE_NUMBER>1820.158 WARN     network - network.c:lxc_delete_network_priv:2589 - Operation not permitted - Failed to remove interface "eth0" with index 4

[ ] Main daemon log (at /var/log/lxd/lxd.log or /var/snap/lxd/common/lxd/logs/lxd.log)
file 'lxd.log' does not seem to be present on my system.

Small side note - is ebtables a dependency? I couldn't find so and I get this error on shutting down the containers (which shut down succesfully)
lxd[380]: t=2019-01-11T12:18:20+0100 lvl=eror msg="Unable to remove network filters" container=ansible err="Failed to run: ebtables -L --Lmac2 --Lx: "

htop + tmpfs list
/proc/meminfo - looks like Slab is taking 1.3GB
/proc/slabinfo - am out of my depth here

So at the moment I am running snap LXD on the host directly, no KVM, on Arch Linux with kernel 5.1.6.
After 3 days of uptime, SUnreclaim was 3GB+
That is after stopping all containers, running snap stop lxd and killing my DE and almost all processes I could.
meminfo_2019_06_06.txt
slabinfo_2019_06_06.txt

Would slabtop maybe give you a more readable output for slab info?
@brauner thoughts
Having all containers and processes stopped suggests a memory leak somewhere in the kernel, nothing immediately jumps at me in your slabinfo but it's kinda hard to do the mental math of active objs * size when reading through it

/me looks

I wouldn't blame the kernel so fast. This could also be snapd leaking memory or go not gcing agressively enough. Can you reproduce on a different kernel?

Also, what happens if you stop snapd?

Also, can you give us the full process list of this system after you stopped lxd and all containers?

On the initial post (which used AUR/lxd in KVM) I posted htop screen with all the processes and snapd doesn't appear to be running there.
I believe I didn't stop it for the outputs I posted today.
I've rebooted now, but I'll grab ps aux and slabtop -s c output in a few days when this reoccurs and after I really trim down the processes like I did in the initial post.
@stgraber I assume I should be sorting by CACHE_SIZE in slabtop for the most relevant info?

Kernel: 5.1.7-arch1-1-ARCH
htop:

slabtop -s c:

ps aux, meminfo and slabinfo coming momentarily in an edit

Snap LXD: 3.18
Kernel: 4.18.0-24-generic
OS: Ubuntu 18.04
Caches were dropped echo 3 > /proc/sys/vm/drop_caches, sync ran too.
meminfo-2019-11-22.log
ps-aux-2019-11-22.log
slabinfo-2019-11-22.log
df-2019-11-22.log
htop:

slabtop -s c:

unreclaimable slab has some 20GB and the rest of the 150GB taken are a mystery.

Why is LXD not showing in ps auxf?

I shut nearly everything unnecessary down to get the stats, it is normally running.

I shut nearly everything unnecessary down to get the stats, it is normally running.

Hm, but if it's the LXD daemon that's causing the issue I wonder what's pinning the memory than if it's gone.

@stgraber deduced it's a kernel bug https://github.com/lxc/lxd/issues/5405#issuecomment-454024325
The system will be running in this broken state for the next 2 hours before being nuked, if you're interested in poking around in it I could get you SSH access.


[Enhancement] render utility does not clean directories

Description
When using the -c flag to render, it does not remove directories. Unsure if bug or oversight.
Slack discussion
No response

can you provide a bit more context?

can you provide a bit more context?

Sorry for the ridiculously long delay here. To provide more context, when the -c flag is used it only cleans files from the existing directories under the destination. It does not remove those directories. This is a problem because the names of those directories corresponds to upstream directories. When this removal doesn't happen and an upstream directory is renamed it results in a duplication effect which we don't want. The only way to avoid that is to clean all files and directories and render all anew.

/assign

@chipzoller Could you please provide the steps to reproduce this issue. I am new to go lang. I am able to setup the code and run the website using github codespaces.

Clone the website repo, build render, then run it with the -c flag pointed to the directory with the policies. It does not remove the directories inside the policies folder.

I see @chipzoller, I think I found the issue. It has to do something with
https://github.com/kyverno/website/blob/f82fc7b4199349bef3dd633be264ea0c947b208a/render/render.go#L223-L226
This piece of code is not returning the files in sub-directories to clean. I will check and submit a PR soon.


Not downloading

The software used to download this kind of video whenever I want in the same conditions showed on the print. But now is not working. It is not downloading anything

See after some minutes - still downloading anything.

Video link: https://certifiquei-cnpi.club.hotmart.com/t/page/g97Ba80Lep
or
https://contentplayer.hotmart.com/video/oARKgoEmRb/source/playlist/dmlkZW8vb0FSS2dvRW1SYi9obHMvNjAwLzYwMC5tM3U4.m3u8
Browser Firefox 94.0.2 (64-bits)
My internet is really ok

I've tried in another browser

After 3 minutes nothing was downloaded

Yeah, same issue here on hotmart website! But on nutror website works fine!

I have the same issue on nugs.net
video link
https://securestream01.akamaized.net/nas5/pj/180813.hls/pj180813_hls_4200.m3u8?hdntl=exp=1640297776~acl=/*~data=hdntl~hmac=80836a0cedfcfe7783eb105aa63934d45a230100dc4c09e80d35fdd08bb0c82d
video is not downloading at all and after some time I receive a notification that hls downloader has crashed
tried edge and firefox

@israelmartins1 I managed to download several videos on hotmart. But the bug you said exists in deed. You can try clean the cache and try again. Sometimes it works. Se não conseguir, envia e-mail para mim<EMAIL_ADDRESS>


Declare correct Python version support

Hi,
I've tried your plugin in Python 3.8 and it seems that uses Type Hinting Generics in Standard Collections, a feature added in Python 3.9. In versions prior to 3.9, the next error is raised:
  File "/.../venv/lib/python3.8/site-packages/mkdocs_expose_page_metadata/helpers.py", line 29, in <module>
    def string_remove_list(text: str, olds: list[str], count: int=-1, strip: bool=False):
TypeError: 'type' object is not subscriptable

So I've declared in setup script that the minimum Python version required is 3.9. Keep in mind that after this, if you try to install the plugin in a lower Python version, the next error will be raised at installation time:
ERROR: Package 'mkdocs-expose-page-metadata' requires a different Python: 3.8.10 not in '>=3.9'

Cheers!

Hi @mondeja ,
Thanks for your contribution. I will accept your merge request.
Bye!

Hi @mondeja ,
Thanks for your contribution. I will accept your merge request.
Bye!

I released new version 1.1.5


Test bumping dune on CI.

On win:
[NOTE] Package reason is already installed (current version is 3.6.0).
The following dependencies couldn't be met:
  - dune -> ocaml >= 4.07

try a opam update

If you want you can give me right on this branch.

Might revisit later if there's a compelling advantage. No reason to dig more at the moment.

Ok we can't solve it because of: https://github.com/fdopen/opam-repository-mingw/issues/75 and latest version of dune in this repo is 2.0.0. We can move to esy to unblock this. If you don't mind changing from Circle CI to GHA you can have ci already setup of hello-reason.


Add active icon styling to link icon

Link bar link button container has active styling but the icon itself lacked the active styling.
This PR adds the active styling to the link button in EditLinkBar.tsx

@arpitv96171 Thanks for the pr!
As @GuySerfaty mentioned you just need to change the commit message to something like fix: active icon styling on link icon

@GuySerfaty will changing the PR title work? Or should I create another PR or add another commit with new commit message?

@arpitv96171 you can rebase and force push with a new message - we cannot merge without these in the commit message
Opening a new pr with the correct commit message will work too

new PR: #172


[Feat./Impr.] Many new expressions and fixes

This pull request's main purpose is to add all the current expressions that are not related to any object (like string or number expressions) from Skript to skript-parser. I am currently at the letter 'E' in the alphabet (of course I skip all Minecraft-related syntax). This means that this pull request is not complete yet, but open for review.
Currently added syntax:

EffContinue
ExprElement
SecChance (probably needed as condition as well)
ExprDifference
EffDoIf

Furthermore, I added error-handling for the Effect#run(TriggerContext) method, since some effects (like EffAsync and EffDoIf) were calling it, but this would result in an UnsupportedOperationException if the effect used was EffWait or something like that.
I also added a Comparator for durations and refactored some code to be convenient over the whole project.

Going to make a new PR with the latest request added because the new optional branch conflicts with many things.


Docker release CT-3

resolves #CT-3
Description
Github actions to release a matrix of docker images to github packages and handle tagging/untagging of latest/ minor.latest versions.
Checklist

[x] I have signed the CLA
[x] I have run this code in development and it appears to resolve the stated issue
[x] This PR includes tests, or tests are not required/relevant for this PR

It's going to take a lot of additional context gathering for me to give a useful review on this PR. In the interest of time, I'm going to pull myself off as a reviewer but if you're in a pinch later you can add me back and I'll see what I can do.


Update AUP logo

Updates the logo of AUP so it shows up better

merging this since it's just a logo URL change