Proposal: Options for testing JSON responses

Howdy!
First off, thanks for this wonderful library! It's really nice.
So, today I've been working on refactoring a Phoenix 1.2 app to move to 1.3, including moving to Contexts. While doing that, I wanted to test the top level integration of all my contexts, and to do that I want to write some feature specs that actually go through HTTP (including the router) instead of just using Controller tests as the top level of testing.
Problem is, I'm testing a JSON API. Wallaby seems to be highly optimized for interacting with HTML responses, but less for for JSON responses. It might be nice for those of us who want to test at this level to have some more robust options for doing so. Do you think this is a direction that fits with your vision for this tool?
One thing in particular that I've been looking for for the last 20 minutes or so is some way to access the entire response so I can inspect. I'm sure I could think of other things that would be nice to have, but that's my biggest pain point at the moment.
Thanks again!

This is something thats come up before. Right now there isn't a good way for us to capture the response from a json api because its not something that the browsers exposes. We'd have to use something like HTTPoison (which is already a dependency) and then expose an api for testing apis with that. Would that actually solve for your use case @devonestes?

This may be my ignorance of browsers speaking, but I've seen that when you hit an API endpoint in pretty much every browser, it does render the response. For example, https://jsonplaceholder.typicode.com/posts/1 displays in my browser (Chrome).
The reason I thought it might be possible is because I can currently do the following, and it works!
assert session |> visit("/posts/1") |> has_text?("Lorem ipsum")

So, somewhere in there it's able to see that the session is receiving that JSON response and that it contains the given test. For now that's what I'm using, but it's not the most user friendly API - especially when the assertion fails because I just see false and not any indication of what text was in the response.
However, that aside, I think what you propose would definitely work. I don't want to sound too demanding here, but the things that I think would make for a really great user experience for this use case would be:

The ability to get at the entire response somehow (and log it to the console if you want to see what's being returned). For example, in Capybara I would do puts JSON.parse(response.body).
Matchers for has_key?/has_keys? and/or has_value?/has_values? to test the presence of some response value or just the general shape of the JSON response.

I think with just those two things, combined with the already present has_text?, and you'd have a pretty solid tool for really testing a JSON API.

I see. I didn't understand that you meant to just visit the api endpoint. A work around might be to do something like this:
test "some json", %{session: session} do
  assert session
  |> visit("some.json")
  |> text()
  |> Poison.decode!
  |> get_in(["key", "other_key"]) == "foo"
end

I'll do some thinking about what an actual api for this might look like.

:wave:
If it's all about testing APIs (that's what I understood) then I don't feel like wallaby is the right tool. It's main point is browser testing and for testing an API we don't even need a browser, something that just uses HTTPoison itself and then asserts things on it is much more suitable there I feel. Sort of like controller specs, but going through the whole stack. Or am I missing some crucial part here?
I don't see much of an overlap from the perspective of wallaby there so I see it more as a separate tool.
If it's about JS AJAX calls then I'd wanna say - capturing somehow might be nice, but in the end what's important is the effect it has for the user (somewhat like testing public vs. private methods) - as in, if the call went through somewhere there should be a different UI element which we could check to see if it's there.
My point of view from my current understanding, might have missed something though :)

Yeah, I can see how this might be outside the intended scope of this project. Makes total sense. In the absence of any other tool, though, I wanted to see if you all felt like this might be a good addition to this library so it could be a sort of "complete solution" for testing your applications in whichever way a real user might interact with them, be it through HTML or JSON. I thought that the tricky part would be the whole part about getting the tests to run in parallel given that they're all integration tests, and using that as the backbone of these API test would be useful.
That workaroud with text works for me for now, though, so I'll probably use that until I have the time to play around and try and whip up a quick library to handle this kind of testing.

If we could share the wallaby parallel testing setup, if useful, that would be a cool thing to do. Maybe I'm not too familiar yet though, but I wouldn't hope that it's the biggest hurdle. Personally I'd have nothing against a wallaby-api or whatever, but it might be better left to another project. Not sure :)

@PragTob I agree that testing apis is a bit outside of wallaby's responsibilities. Not sure if my opinion has changed but I can certainly see the value in being able to re-use Wallaby's concurrent test setup. This is something I've been thinking about for a bit so I'm going to investigate a bit. It would be nice to have concurrent api tests with a really declarative api. Having a separate package like wallaby-api might be the way to go.

As much as I'd like to do this I don't have time or energy to support it at the moment. If someone else wants to take a crack at it then that would be great. I'm going to close for now though.


Re-organize the folder structure and make upstream tests run on checked out code

The following PR organizes the existing code base for GitHub workflows
makes sure the ci images stay separately.
Further, It also fixes the bug where the tests for operator-metadata runs
on the checked out code of pull request rather than code built on the tag.

/retest

/retest

@samvarankashyap looks liek you did not get the main point from the review.
Using ENTRYPOINT, CMD or manually executing command with podman run is just cosmetic change.
The main issue is with testing itself.
ATM, the file Dockerfiles/ci/command.sh covers execution of whole testsuite and then you run "assertions"  in following "stage" in github actions. In another words, you use github actions as testing framework.
Test suite usually consist of many tests. Assertions are used directly inside each tests. Or immediately after execution test (behavior driven development).
Github action is CI/CD platform and not testing framework. We needn't use real frameworks from python, java, ...
We can use bash for that. But "assertions" should not be written in github actions.

@lslebodn PTAL

@lslebodn PTAL

last two nitpicks; otherwise lgtm


(PY-D0002) Missing class docstring

Description
Class docstring is missing. If you want to ignore this, you can configure this in the .deepsource.toml file. Please refer to docs for available options.
Occurrences
There are 16 occurrences of this issue in the repository.
See all occurrences on DeepSource → deepsource.io/gh/BAN-AI-Communications/rfc2217-gateway/issue/PY-D0002/occurrences/

3rd party / won't fix


Blogapp: Feature/api

Added API routes and post controller for api
Added comment controller for api
Added API endpoints for posts and comments
Added devise-jtw and rswag for API authorization
Added authorization configuration for API
Added fix for linters

Thanks @enaburekhan


fixed delay when Serial readString

The library doesn't use Serial.readString(), does it?
Also, AFAIK, setTimeout affects only  Serial.readBytesUntil(), Serial.readBytes(), Serial.parseInt() or Serial.parseFloat().
But the library uses available/read.


Download Link Not Clickable

The 'DOWNLOAD' link at the bottom of the results panel is visible but can't be clicked.
Expected Behavior

You should be able to click to download the results

Current Behavior

Possible Solution

Steps to Reproduce (for bugs)

Click Download Link

Context

Your Environment

Version used: 1.6.7
Environment name and application type (e.g. Chrome 39, chrome extension v1.4.7): 58.0.2 (64-bit)
Operating System and version (e.g. Linux, v1.4.7): Windows 10

I added the z-index via the browser debug  -
result__bottom-actions {
position: absolute;
bottom: 10px;
right: 10px;
z-index: 3;
}
And it became clickable. I couldn't find the .scss file for the control so I'll assume the style is generated automatically??

@sganz It's here: https://github.com/imolorhe/altair/blob/staging/src/scss/components/_editor.scss#L75


start adding some more tests for version updates

Continuing the implementation here, but potentially moving it into cf-scripts afterwards.
I've added some interesting test cases with one that is kinda hard to fix: the polars test.

OK, actually the polars test is also marked as xfail:
    pytest.param(
        "polars_mixed_selectors",
        "1.1.0",
        marks=pytest.mark.xfail(reason=VARIANT_SOURCES_NOT_IMPLEMENTED),
    ),
    pytest.param(
        "polars_name_selectors",
        "1.1.0",
        marks=pytest.mark.xfail(reason=VARIANT_SOURCES_NOT_IMPLEMENTED),
    ),
    pytest.param(
        "polars_variant_selectors",
        "1.1.0",
        marks=pytest.mark.xfail(reason=VARIANT_SOURCES_NOT_IMPLEMENTED),
    ),


Cannot use derived transparent Type as parameter

Bug Description
I have a newtype struct Id(String) that has #[derive(Type)] and #[repr(transparent)] but it can't be used directly as a text parameter value when querying with query!, as it fails to compile due to a type mismatch. I've also tried manually implementing Type, Encode, Decode, and PgHasArrayType with calls to the String implementations, to no avail. I get the following error:
error[E0308]: mismatched types
  --> src/main.rs:11:44
   |
11 |   let q = sqlx::query!("select $1 as val", id).fetch_one(&db).await.unwrap();
   |                                            ^^
   |                                            |
   |                                            expected `&str`, found struct `Id`
   |                                            expected due to the type of this binding

I've tried using $1::text and/or &id, but it still doesn't work. It only works if I provide the inner String field value directly.
Minimal Reproduction
use sqlx::{PgPool, Type};

#[derive(Type, Clone)]
#[repr(transparent)]
struct Id(String);

#[tokio::main]
async fn main() {
  let db = PgPool::connect("...").await.unwrap();
  let id = Id("abc".to_string());
  let q = sqlx::query!(
    "select $1 as val, $2 as opt, $3::text as vec",
    id.clone(), Some(id.clone()), vec![id.clone()].as_slice()
  ).fetch_one(&db).await.unwrap();
  println!("{q:?}");
}

Alternate manual implementation instead of derive (also fails):
impl Type<Postgres> for Id {
    fn type_info() -> <Postgres as Database>::TypeInfo {
        <String as Type<Postgres>>::type_info()
    }

    fn compatible(ty: &<Postgres as Database>::TypeInfo) -> bool {
        <String as Type<Postgres>>::compatible(ty)
    }
}

impl<'r> Decode<'r, Postgres> for Id {
    fn decode(value: <Postgres as HasValueRef<'r>>::ValueRef) -> Result<Self, BoxDynError> {
        let str = <String as Decode<Postgres>>::decode(value)?;

        Ok(Id(str))
    }
}

impl<'q> Encode<'q, Postgres> for Id {
    fn encode_by_ref(&self, buf: &mut <Postgres as HasArguments<'q>>::ArgumentBuffer) -> IsNull {
        <String as Encode<'q, Postgres>>::encode_by_ref(&self.0, buf)
    }

    fn size_hint(&self) -> usize {
        self.0.len()
    }

    fn produces(&self) -> Option<<Postgres as Database>::TypeInfo> {
        <String as Encode<'q, Postgres>>::produces(&self.0)
    }
}

impl PgHasArrayType for Id {
    fn array_type_info() -> PgTypeInfo {
        <String as PgHasArrayType>::array_type_info()
    }
}

Info

SQLx version: 0.6.2
SQLx features enabled: ["postgres", "runtime-tokio-rustls"]
Database server and version: Postgres 15
Operating system: Linux 5.17.5-300.fc36.x86_64
rustc --version: rustc 1.64.0 (a55dd71d5 2022-09-19)

This isn't restricted to custom types, I see the same issue with chrono::DateTime<Utc>.  I need to manually convert to/from NaiveDateTime in order to get queries to work.

I'm currently implementing the newtype pattern, and got bitten by this issue as well
For me, I can insert the wrapper type by "casting" the result & telling the sqlx what type to expect for my newtype input
#[derive(sqlx::Type)]
#[sqlx(type_name = "uuid")] // <- this
pub struct PriceId(pub uuid::Uuid);

#[tokio::main]
async fn main() -> eyre::Result<()> {

    // ...

    let db = sqlx::PgPool::connect(&config.db_primary_conn_string).await?;
    let mut db_tx = db.begin().await?;

    let inserted_id = sqlx::query!(
        r#"
        INSERT INTO "payment".prices(
            id, currency_name, currency_smallest_unit
        ) VALUES ($1, $2, $3) RETURNING id
    "#,
        PriceId(uuid::Uuid::new_v4()) as _, // <- this
        payment::Currency::Usd as _,
        bigdecimal::BigDecimal::from_f64(1000.0).unwrap()
    )
    .fetch_one(&mut db_tx)
    .await
    .map(|row| row.id)?;

    db_tx.commit().await?;

    println!("price ID: {inserted_id}");
    Ok(())
}

Output
taufik-rama@box:~/programming/payment$ cargo run --bin payment-quick -q
price ID: a4b9fb58-cea1-4224-8b25-50f0286a96eb

Guys, did you find a way? I opened:

https://stackoverflow.com/questions/74962354/how-can-i-instruct-sqlx-about-this-custom-type-im-using-for-offsetdatetime and
https://github.com/launchbadge/sqlx/discussions/2260

for I think the same reason. I'm stucked.

For future travellers, these sqlx docs solved my problem. Basically:
#[derive(sqlx::Type)]
#[sqlx(transparent)]
struct UserId(i64);


Disable any active payment link after request is closed

Need to ensure that any active payment links are disabled after a request is closed. Do not want applicant paying any outstanding fees if request is closed
Dependencies
Are there any dependencies?
DOD

[ ] Add WF logic to update submission in forms flow if request is closed
[ ]
[ ]
[ ]
[ ]

Closing, as this appears to have been resolved with #3135 - confirmed payment links are inactive when request is moved to 'Closed' (in TEST)


S2 AvatarGroup

Pushed 3 changes:

Moved to using Avatar directly instead of AvatarGroupItem. Also moved the stroke into Avatar itself (via an isOverBackground prop), since this will also be needed in other places such as Cards.
Moved to pixel-based sizing rather than t-shirt sizing (since there are so many size options). Also added back the size prop to Avatar instead of using macros for sizing, which enables us to adjust the stroke width depending on the size. Updated codemod for this change as well.
Made the stroke color automatic. This is done by making all container components with a background color set the --s2-container-bg variable. Then the stroke can automatically match the nearest container.


Support for Love2D / PyGame

Just an idea. I thought it might be cool to be able to write code in other languages like PyGame or Love2D, which are also for game development, but don't have cool editors. Of course, this type of solution would make it easier to write in these engines in my opinion, where some things could be clickable.

The reason GMEdit is (relatively) good at its job is that it's specialized - everything in the program is modeled based on how GameMaker works and how people typically use GameMaker. Without that I'd be making a VS Code replica.
That said, if you have a lot of free time on your hands, you can add support for additional languages as plugins (e.g. there's an example for INI included), but it's far easier to use existing tools.


Color heads-up notification

Here is in Nord:

And in Solarized Dark:

And what Material Theme gives is this:

Those buttons in heads-up notification (or whatever it is called) can be colored. Please provide it for all of your themes. A color for hovering on it can also be assigned.

Buttons background and foreground are bugged in the latest public 1.12.


Allow suggesting filename with uiSaveFile

I don't know if this is a standard feature on every os, but I'd like to be able to suggest a filename for the user when they save something with uiSaveFile. If it's supported with every GUI toolkit, I think it would make sense to change the uiSaveFile function to accept a pointer to an options struct. If null is passed, it will use the default values.

There is an open PR for this already, that still needs some work: https://github.com/libui-ng/libui-ng/pull/47


Efficiently check PauliSumOps for diagonality in CVaRMeasurement

Summary
Fixes #7573.
Details and comments
See #7573.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

5 of 5 (100.0%)  changed or added relevant lines in 1 file are covered.
5 unchanged lines in 2 files lost coverage.
Overall coverage decreased (-0.007%) to 83.167%

Files with Coverage Reduction
New Missed Lines
%

qiskit/extensions/quantum_initializer/uc.py
2
87.94%

qiskit/pulse/library/waveform.py
3
89.36%

Totals

Change from base Build<PHONE_NUMBER>:
-0.007%

Covered Lines:
52025

Relevant Lines:
62555

💛  - Coveralls


Update snapshots.md

Description & motivation
Per @mirnawong1's feedback, the two details blocks are not showing up in the bottom of the page. I think they might just need to include a summary?
To-do before merge

Pre-release docs
Is this change related to an unreleased version of dbt?

[ ] Yes: please

update the base branch to next
add Changelog components: <Changelog>[New/Changed] in v0.x.0</Changelog>
add links to the "New and changed documentation" section of the latest Migration Guide

[ ] No: please ensure the base branch is current
[ ] Unsure: we'll let you know!

Checklist
If you added new pages (delete if not applicable):

[ ] The page has been added to website/sidebars.js
[ ] The new page has a unique filename

If you removed existing pages (delete if not applicable):

[ ] The page has been removed from website/sidebars.js
[ ] An entry has been added to _redirects

When I come back to this:

Move content out of details tabs

Can we reconfigure this content to make it easier to read?

@runleonarun : so sorry for the delay in getting this reviewed! as you might have heard, the Docs team will be dedicating time on a regular cadence to manage our PR backlog better. in the spirit of this, i opened this PR to see what I can do to help it along.
looked at your changes to the snapshots.md file. unless you want to make more changes, happy to approve these changes for you.


RuntimeError: Output 0 of UnbindBackward is a view and is being modified inplace. This view is the output of a function that returns multiple views. Such functions do not allow the output views to be modified inplace. You should replace the inplace operation by an out-of-place one.

Traceback (most recent call last):
File "D:/1.Study/PycharmProjects/Score-CAM-master/test.py", line 50, in
basic_visualize(input_.cpu(), scorecam_map.type(torch.FloatTensor).cpu(), save_path='resnet.png')
File "D:\1.Study\PycharmProjects\Score-CAM-master\utils_init_.py", line 299, in basic_visualize
input_ = format_for_plotting(denormalize(input_))
File "D:\1.Study\PycharmProjects\Score-CAM-master\utils_init_.py", line 173, in denormalize
channel.mul_(std).add_(mean)

me too

Could you try it on Colab? I think this is caused by the update in torch.

change to this
count = 0     for channel, mean, std in zip(denormalized[0], means, stds):         denormalized[0][count] = denormalized[0][count].mul(std)         denormalized[0][count] = denormalized[0][count].add(mean)         count+=1

change to this count = 0 for channel, mean, std in zip(denormalized[0], means, stds): denormalized[0][count] = denormalized[0][count].mul(std) denormalized[0][count] = denormalized[0][count].add(mean) count+=1 the key is change channel.mul_(std).add_(mean) to denormalized[0][count] = denormalized[0][count].mul(std) and  denormalized[0][count] = denormalized[0][count].add(mean). Because these are in place. 这里的乘法和加法都是就地操作的，这里不适用，所以要拆开来。按照发的这个代码换一下就可以了。

This solution is useful, thanks!


Updated wording for the pricing tier section

Updated the wording under the "pricing tier" section to make it more clear and concise.

@tomhhealy : Thanks for your contribution! The author(s) have been notified to review your proposed change.

@laujan
Can you review this PR?
IMPORTANT: When this content is ready to merge, you must add #sign-off in a comment or the approval may get overlooked.
#label:"aq-pr-triaged"
@MicrosoftDocs/public-repo-pr-review-team

#sign-off


 To do this, the next index pointer had to be incremented by 2 (4 on PSone), as it was changing the address of 0x9AC instead of 0x9B4. I've tested it in NO$PSX with various BIOSes from 2.0 to 4.4.
I've also made a table in the readme with easy links to the built memory cards. The builder should be updated for this, but I'm not sure how you would want to specify the required offset in the index, since the builder would have to add 2 for SCPH-5xxx models. (Maybe a -bios4.x flag for SCPH-7/9xxx, and -bios3.x for SCPH-5xxx?)
Also: good job on making this! I'd found this exploit independently a few weeks ago, but I was going to have the exploit triggered on copy, which meant that all the entries had to be valid. This got me stuck since it would end up resetting the directory, causing copy operations to be disabled. Using ReadMemCardDirectory as the vector is definitely a much better strategy. Congrats!

This is still using the old method of relying on uninitialized data, right?

It's based on the memory card images currently present in the repo, which haven't been updated. Since I see there are per-BIOS settings already in the builder, I'll go update those too.

I've tried messing around with the offsets for SCPH-5501, but for some reason the target value gets reset to 0xF111DEAE before starting the increment. Further research is required, but I'm going to test with SCPH-10x models now.

Right, the old memory card images are still there. The builder has been updated with the new mechanism however.

I've tried messing around with the offsets for SCPH-5501, but for some reason the target value gets reset to 0xF111DEAE before starting the increment. Further research is required, but I'm going to test with SCPH-10x models now.

0xf111deae is the value used by no$psx to mark breakpoints, so that's probably the emulator itself resetting the value. You should try with pcsx-redux, which keeps track of active breakpoints without messing with the memory.


CentOS 8 test in CI failing with postfix service failure

Issue Type

Bug Report

Your Environment
Travis CI
Your OS

Linux

Full console output
TASK [geerlingguy.postfix : Ensure postfix is started and enabled at boot.] ****
463fatal: [localhost]: FAILED! => {"changed": false, "msg": "Unable to start service postfix: Job for postfix.service failed because the control process exited with error code.\nSee \"systemctl status postfix.service\" and \"journalctl -xe\" for details.\n"}

Summary
It looks like something doesn't start up right with postfix in the CentOS 8 environment.

Also... varnish won't install on CentOS with error No package pygpgme available.

Under Vagrant I'm not seeing an issue:
● postgresql.service - PostgreSQL database server
   Loaded: loaded (/usr/lib/systemd/system/postgresql.service; enabled; vendor preset: disabled)
   Active: active (running) since Mon 2020-07-06 16:47:44 UTC; 6s ago
  Process: 8694 ExecStartPre=/usr/libexec/postgresql-check-db-dir postgresql (code=exited, status=0/SUCCESS)

Er... that's not postfix in the comment above... that's postgres :P
Testing again.

Fixed via above commit.


Feature Request - Show target IP address in console when "Scan IP Range"

Hi Josh,
Thank you for your improved J-runner. I've been using this tool always.
For some reason, when booting into Xell-reloaded for the 1st time after writing ecc into NAND, my monitor just shows a blank screen.
(Finally the Xell-reloaded is the culprit, I'm quite sure of that.)
So every time I boot xbox360 I use "Scan IP Range" to get CPU key.
Though cpu key can be fetched eventually, but the target IP address J-runner scanned is nowhere to know.
Can you please let J-runner shows target IP address in console when finished scanning?

Glad it's helping you out.
To confirm - you're asking if I can add an output that shows the IP number it found when the scan finds a system?
-J

Yes, that will be a great help. I just want to know the exact IP address J-runner has found out in console when scanning.

-J

Brilliant! Looks nice and effective.

Implemented and completed checkout in version next.
Thanks for your suggestion! It will be included in the next release (soon).
Kind Regards,
josh


Update README to gulp test-debug (with a hyphen)

A tiny documentation fix: https://github.com/edx/edx-ui-toolkit/blob/master/gulp/tasks/test-debug.js#L9

Thanks for the pull request, @kevinrobinson! I've created OSPR-1215 to keep track of it in JIRA. JIRA is a place for product owners to prioritize feature reviews by the engineering development teams.
Feel free to add as much of the following information to the ticket:

supporting documentation
edx-code email threads
timeline information ("this must be merged by XX date", and why that is)
partner information ("this is a course on edx.org")
any other information that can help Product understand the context for the PR

All technical communication about the code itself will still be done via the GitHub pull request interface. As a reminder, our process documentation is here.
We can't start reviewing your pull request until you've submitted a     signed contributor agreement     or indicated your institutional affiliation.     If you like, you can add yourself to the AUTHORS      file for this repo, though that isn't required.     Please see the CONTRIBUTING     file for more information.

@edx-webhook Hey robot buddy!  I signed the agreement and emailed it to<EMAIL_ADDRESS>so hopefully you'll notice that soon :)

Coverage remained the same at 92.78% when pulling d24c31977d7ae9ebee669f917cec327469d2fc74 on kevinrobinson:patch-1 into 28e9a86847e3566409421a129ed25efc752aee6b on edx:master.

@andy-armstrong this seems right on the face of it, I'm merging.  Feel free to correct if this is more complex than @kevinrobinson or I knew :)

Thanks @nedbat!

Thanks, @kevinrobinson. That was my oversight when I renamed the gulp task. :+1:

@kevinrobinson I'm also intrigued as to what brings you to the UI Toolkit...

@andy-armstrong no problemo!  just poking around mostly :)

Thanks for picking up after me on your way through :-) Let me know if you have any questions about the UI Toolkit.

will do!


Fix wrong domain separator for contract versions below 1.3.0

Closes #421

Calculate domainSeparator for contract versions below 1.3.0
Add test eip1271 signing for v1.1.1

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
33 unchanged lines in 2 files lost coverage.
Overall coverage decreased (-0.02%) to 90.294%

Files with Coverage Reduction
New Missed Lines
%

gnosis/eth/ethereum_client.py
1
86.74%

gnosis/safe/safe.py
32
88.62%

Totals

Change from base Build<PHONE_NUMBER>:
-0.02%

Covered Lines:
3526

Relevant Lines:
3905

💛  - Coveralls


⚠ Bofrost.de has degraded performance

In 4867bf2, Bofrost.de (https://www.bofrost.de) experienced degraded performance:

HTTP code: 200
Response time: 966 ms

Resolved: Bofrost.de performance has improved in 5edf42d after 6 minutes.


sched: move etc romfs mount from nsh to sched/init

Summary
Usually the startup script is placed under /etc. The contents of the etc directory are compiled and linked with Nuttx binary in the form of romfs. After startup, it will be  mounted by Nsh.
etc is generated by the different boards, that use genromfs and xxd tools to generate and compile it into the Nuttx, for example: boards/arm/at32/at32f437-mini/tool/mkromfs.sh
The more common method is etc image generated from the content in the corresponding board/arch/board/board/src/etc directory, and added by Makefile for example: boards/sim/sim/sim/src/etc.
But in kernel/protected mode, Nuttx kernel and apps are run in different privileged/non-privileged mode or the isolated binarys, so as that nsh should use syscall to access Nuttx kernel by exported API. In this scenario, nsh can not mount the etc image content, because that is generated in board and as a part of Nuttx kernel.
changes:

move etc romfs mount from nsh to Nuttx, but keep the script to parse and execute.
move and rename the related CONFIG, move customized nsh_romfsimg.h to etc_romfs.c in boards, and no need declaration for romfs_img/romfs_img_len.

This commit changes and updates all configurations in Nuttx arch/board as much as possible,
but if any missing, please refer to the following simple guide:

rename CONFIG_NSH_ROMFSETC to CONFIG_ETC_ROMFS, and delete CONFIG_NSH_ARCHROMFS in defconfig
rename the etc romfs mount configs, for example CONFIG_NSH_FATDEVNO to CONFIG_ETC_FATDEVNO
move customized nsh_romfsimg.h to etc_romfs.c in board/arch/board/board/src and no need declaration for romfs_img/romfs_img_len.
delete default nsh_romfsimg.h, if ROMFSETC is enabled, should generate and compile etc_romfs.c in board/arch/board/board/src.

Impact
all boards config, could break CI need correspond to https://github.com/apache/nuttx-apps/pull/2256
Testing
qemu/sim

Please refresh boards/sim/sim/sim/configs/unionfs/defconfig @fxysunshine.

Please refresh boards/sim/sim/sim/configs/unionfs/defconfig @fxysunshine.

done

@fxysunshine This looks to be a massive breaking change.  What is the advantage of it?  What are all the implications it will have on downstream NuttX users.  What are all the steps thy will need to do to migrate to it?

@fxysunshine This looks to be a massive breaking change. What is the advantage of it?

This change is to support the mount /etc in kernel/protected mode.

What are all the implications it will have on downstream NuttX users. What are all the steps thy will need to do to migrate to it?

@fxysunshine please add a migration guide in commit message and pr.

@fxysunshine Why was this approach taken and why were all the build changes needed? Are thy needed? May be you could explain the Problem you are solving, and why this is a good solution.

@fxysunshine Why was this approach taken and why were all the build changes needed? Are thy needed? May be you could explain the Problem you are solving, and why this is a good solution.

@davids5 Thanks for your suggestions. Please refer to the problem and solution description in the updated commit and pr.

@fxysunshine Why was this approach taken and why were all the build changes needed? Are thy needed? May be you could explain the Problem you are solving, and why this is a good solution.

@davids5 Thanks for your suggestions. Please refer to the problem and solution description in the updated commit and pr.

@fxysunshine Thank you for the excellent  problem and solution description. This is super helpful!

@xiaoxiang781216 Do you know why CI is failing?

@fxysunshine I'll merge it, but I think you need to update our Documentation/, because there a lot of reference to CONFIG_NSH_ROMFSETC etc...

@xiaoxiang781216 Do you know why CI is failing?
@xiaoxiang781216 @davids5
lack of the apps corresponding commit https://github.com/apache/nuttx-apps/pull/2256, could not pass case scanftest.

Temporary ignore to check scanftest result https://github.com/apache/nuttx/pull/11498/files#diff-8c28e250b38860383a1f2e7a7610574b2358da67d92b6d523474bf30cefcf013, can pass CI.
Can we merge the PR, and revert the temp change after https://github.com/apache/nuttx-apps/pull/2256 is merged?

@fxysunshine I'll merge it, but I think you need to update our Documentation/, because there a lot of reference to CONFIG_NSH_ROMFSETC etc...

Sure.

@fxysunshine I'll merge it, but I think you need to update our Documentation/, because there a lot of reference to CONFIG_NSH_ROMFSETC etc...

@xiaoxiang781216 Do you know why CI is failing?

@xiaoxiang781216 @davids5 lack of the apps corresponding commit apache/nuttx-apps#2256, could not pass case scanftest.
Temporary ignore to check scanftest result https://github.com/apache/nuttx/pull/11498/files#diff-8c28e250b38860383a1f2e7a7610574b2358da67d92b6d523474bf30cefcf013, can pass CI.
Can we merge the PR, and revert the temp change after apache/nuttx-apps#2256 is merged?

Done, please revert the temp change.

Hi all, @xiaoxiang781216 @acassis @jerpelea
I just came accross this PR while trying to update the nuttx. Sorry to rant afterwards, I never noticed this before. This change just breaks all my configurations, and I think is wrong in many aspects

This is conceptually wrong. NSH is an application, a shell (or a combined shell and busybox kind of app...). NSH should reside ON the file ROMFS filesystem. In the end, you don't really want to "mount the romdisk from the NSH" nor even use the NSH as an "sbin/init" app (even though this is what is currently being done)
If we want a "common" mounting mechanism for "root" fs, we should have a separate simplified "init" in the kernel and NOT use NSH as an init process. You may just refer to other OSs (like linux). They are not using a shell to mount the root file system. This just doesn't make any sense!
There was no issues previously. You can just call "romdisk_register" and mount the (sbin) from your board initialization code

For sure we could adapt to this change, but I feel that it is taking us, and the role of the NSH application into a wrong direction.
I strongly suggest re-considering this approach, for now I am just reverting this change in our own branches.


M1 ?

I have the latest version, installed via brew. Still doesn't work.
dmitriyp@MBA-M1:[~]: brightness -lv
display 0: main, active, awake, online, built-in, ID 0x1
	resolution 1440 x 900 pt (2880 x 1800 px) @ 60.0 Hz, origin (0, 0)
	physical size 287 x 179 mm
	IOKit flags 0x7; IOKit display mode ID 0x8
	usable for desktop GUI, uses OpenGL acceleration
brightness: failed to get brightness of display 0x1 (error -536870201)

dmitriyp@MBA-M1:[~]: brightness -l
display 0: main, active, awake, online, built-in, ID 0x1
brightness: failed to get brightness of display 0x1 (error -536870201)

@nriley is there away to update the brew version ?


Fix asyncpg.Pool usage

Rationale
There is an error in the importing of Pool from asyncpg as it is asyncpg.pool.Pool.
Currently an error is produced
dagbot    | Traceback (most recent call last):
dagbot    |   File "/usr/local/lib/python3.8/site-packages/discord/ext/commands/bot.py", line 917, in _load_from_module_spec
dagbot    |     spec.loader.exec_module(lib)  # type: ignore
dagbot    |   File "<frozen importlib._bootstrap_external>", line 783, in exec_module
dagbot    |   File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
dagbot    |   File "/usr/local/lib/python3.8/site-packages/jishaku/__init__.py", line 15, in <module>
dagbot    |     from jishaku.cog import *  # noqa: F401
dagbot    |   File "/usr/local/lib/python3.8/site-packages/jishaku/cog.py", line 27, in <module>
dagbot    |     from jishaku.features.sql import SQLFeature
dagbot    |   File "/usr/local/lib/python3.8/site-packages/jishaku/features/sql.py", line 110, in <module>
dagbot    |     @adapter(asyncpg.Connection, asyncpg.Pool)
dagbot    | AttributeError: module 'asyncpg' has no attribute 'Pool'
dagbot    |
dagbot    | The above exception was the direct cause of the following exception:
dagbot    |
dagbot    | Traceback (most recent call last):
dagbot    |   File "/usr/local/lib/python3.8/runpy.py", line 194, in _run_module_as_main
dagbot    |     return _run_code(code, main_globals, None,
dagbot    |   File "/usr/local/lib/python3.8/runpy.py", line 87, in _run_code
dagbot    |     exec(code, run_globals)
dagbot    |   File "/dagbot/__main__.py", line 20, in <module>
dagbot    |     asyncio.run(start_bot())
dagbot    |   File "/usr/local/lib/python3.8/asyncio/runners.py", line 44, in run
dagbot    |     return loop.run_until_complete(main)
dagbot    |   File "/usr/local/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
dagbot    |     return future.result()
dagbot    |   File "/dagbot/__main__.py", line 9, in start_bot
dagbot    |     await dagbot.startdagbot()
dagbot    |   File "/dagbot/bot.py", line 147, in startdagbot
dagbot    |     await self.load_extensionsa()
dagbot    |   File "/dagbot/bot.py", line 110, in load_extensionsa
dagbot    |     await self.load_extension("jishaku")
dagbot    |   File "/usr/local/lib/python3.8/site-packages/discord/ext/commands/bot.py", line 995, in load_extension
dagbot    |     await self._load_from_module_spec(spec, name)
dagbot    |   File "/usr/local/lib/python3.8/site-packages/discord/ext/commands/bot.py", line 920, in _load_from_module_spec
dagbot    |     raise errors.ExtensionFailed(key, e) from e
dagbot    | discord.ext.commands.errors.ExtensionFailed: Extension 'jishaku' raised an error: AttributeError: module 'asyncpg' has no attribute 'Pool'

Summary of changes made
Simply switched the import. https://magicstack.github.io/asyncpg/current/api/index.html?highlight=pool#asyncpg.pool.Pool
Checklist

[x] This PR changes the jishaku module/cog codebase

[ ] These changes add new functionality to the module/cog
[x] These changes fix an issue or bug in the module/cog
[x] I have tested that these changes work on a production bot codebase
[x] I have tested these changes against the CI/CD test suite
[ ] I have updated the documentation to reflect these changes

[ ] This PR changes the CI/CD test suite

[ ] I have tested my suite changes are well-formed (all tests can be discovered)
[ ] These changes adjust existing test cases
[ ] These changes add new test cases

[ ] This PR changes prose (such as the documentation, README or other Markdown/RST documents)

[ ] I have proofread my changes for grammar and spelling issues
[ ] I have tested that any changes regarding Markdown/RST syntax result in a well formed document

I can't repro this. What version of asyncpg are you using?

Judging by https://github.com/MagicStack/asyncpg/commit/0e0eb8d35e4804f681ebac4bc0e77a538d0f4fea, this was changed in the 0.22.0 tree, nearly 2 years ago. We're currently on 0.26.0, so your asyncpg is out of date by quite a bit. I'll merge this anyway since it doesn't break the current version and extends compatibility.


fix: fix multihop gamm cli

Closes: #XXX
What is the purpose of the change
When testing osmosis multihop discount, I found that utilizing multiple pool ids and denoms in the cli was not getting parsed correctly. This fixes that issue

Hrmm, lets not merge this in v13 just yet.
I'm pretty sure that id1,id2 works, Viper does support reading arrays and a change here would break folks

I have tried it a myriad of ways and was unable to get multihop to work via CLI prior to this PR

Can anyone determine if this is in fact a required change? I would be shocked if the current CLI command works in its current form without this change

huh yeah, I am super confused. The Viper tests have string array working, but it doesn't work for me either via testing: https://github.com/spf13/viper/blob/202060b3a253bbac94795be51ca0b8e7432bf0fb/viper_test.go#L1008-L1011

So, can we merge? 😅


Example using kubernetes provider?

I am trying to get a Kubernetes provider to work with parsl.
I have a working kubernetes cluster, with kubectl setup. I can setup pods with kubectl, and open shells in them. Based on https://parsl.readthedocs.io/en/stable/stubs/parsl.providers.KubernetesProvider.html, I have set this up:
import parsl
from parsl import python_app
from parsl.config import Config
from parsl.providers import KubernetesProvider
from parsl.executors import HighThroughputExecutor

config = Config(
    executors=[
        HighThroughputExecutor(
            label='PM_HTEX_multinode',
            cores_per_worker=2,
            provider=KubernetesProvider(
                image='jkitchin/pycse',
                namespace='jkitchin',
                pod_name='jk-',
                user_id='1000',
                group_id='100'
            ),
        )
    ]
)

# load the Parsl config
parsl.load(config)

@python_app
def exc():
    import socket
    return socket.gethostname()

exc().result()

It does run, and it tries to create a pod, but the pod fails, and the logs indicate:

Traceback (most recent call last):
--
Tue, Oct 17 2023 2:09:37 pm | File "/opt/conda/bin/process_worker_pool.py", line 687, in <module>
Tue, Oct 17 2023 2:09:37 pm | os.makedirs(os.path.join(args.logdir, "block-{}".format(args.block_id), args.uid), exist_ok=True)
Tue, Oct 17 2023 2:09:37 pm | File "/opt/conda/lib/python3.9/os.py", line 215, in makedirs
Tue, Oct 17 2023 2:09:37 pm | makedirs(head, exist_ok=exist_ok)
Tue, Oct 17 2023 2:09:37 pm | File "/opt/conda/lib/python3.9/os.py", line 215, in makedirs
Tue, Oct 17 2023 2:09:37 pm | makedirs(head, exist_ok=exist_ok)
Tue, Oct 17 2023 2:09:37 pm | File "/opt/conda/lib/python3.9/os.py", line 215, in makedirs
Tue, Oct 17 2023 2:09:37 pm | makedirs(head, exist_ok=exist_ok)
Tue, Oct 17 2023 2:09:37 pm | [Previous line repeated 7 more times]
Tue, Oct 17 2023 2:09:37 pm | File "/opt/conda/lib/python3.9/os.py", line 225, in makedirs
Tue, Oct 17 2023 2:09:37 pm | mkdir(name, mode)
Tue, Oct 17 2023 2:09:37 pm | PermissionError: [Errno 13] Permission denied: '/Users'
Tue, Oct 17 2023 2:09:37 pm | /bin/bash: -c: line 4: syntax error near unexpected token `;'
Tue, Oct 17 2023 2:09:37 pm | /bin/bash: -c: line 4: `;'

I can see there is a permission error related to making a directory /Users.  I don't see anywhere obvious to change this.
Are there any examples of using Kubernetes with parsl somewhere? (I looked, but did not find anything).
addendum:
Digging in to the yaml for the pod, I see this, which seems like something isn't right. the logdir is a local directory on my machine, but the kubernetes cluster where the pod is created is a remote cluster, so that logdir won't exist there.
  process_worker_pool.py   -a Johns-iMac-4.local,<IP_ADDRESS>,<IP_ADDRESS> -p 0 -c 2 -m None --poll 10 --task_port=54918 --result_port=54542 --logdir=/Users/jkitchin/example/runinfo/034/PM_HTEX_multinode --block_id=2 --hb_period=30  --hb_threshold=120 --cpu-affinity none --available-accelerators  --start-method spawn

I guess this means something is not setup right in here.
update 2:
It does work if I run it in a pod on the kubernetes cluster. Although it seems to create 4 pods, and they don't close when the job is done. It seems like they should.
Is there a way to make it work remotely?

I have made a smidge of progress getting this to work.
Some prerequisites that weren't obvious:

The Python and parsl versions have to be the same on the local and remote machines.
You have to set a worker_logdir_root in the executor for the remote path.

Here is a minimally working example for me.
import parsl
from parsl import python_app
from parsl.config import Config
from parsl.providers import KubernetesProvider
from parsl.executors import HighThroughputExecutor

import logging
logging.captureWarnings(True)

config = Config(
    executors=[
        HighThroughputExecutor(
            label='HTE',
            cores_per_worker=2,
            worker_logdir_root='/home/jovyan/logs/',
            provider=KubernetesProvider(
                image='jkitchin/pycse',
                pod_name='jrk-',
                # this does not work
                #                persistent_volumes=[('shared-scratch', '/home/jovyan/shared-scratch/')]
            ),
        )
    ]
)

# load the Parsl config
parsl.load(config)

@python_app
def exc():
    import os, socket
    return socket.gethostname()

print('done', exc().result())

I can't get persistent volumes to work, I see messages that indicate the name can't be found (30 persistentvolumeclaim "shared-scratch" not found.) This is a volume that I mount in other pods though.
Also for some reason, this makes 4 pods. When nothing goes wrong, one of them terminates (the one that returns from the app), but the other 3 are left running. Every so often, the ones left running seem to error and restart.


[duktape] find_package_handle_standard_args argument should be lowercase

Is your feature request related to a problem? Please describe.
The following command
https://github.com/microsoft/vcpkg/blob/3c76dc55f8bd2b7f4824bcd860055094bfbbb9ea/ports/duktape/duktapeConfig.cmake.in#L22-L23
should use duktape in lowercase.
It works fine on linux but it gives me a warning on windows:
CMake Warning (dev) at .../bin/cmake/win/x64/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (Duktape)
  does not match the name of the calling package (duktape).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  build/debwithopt-msvc/vcpkg_installed/x64-windows/share/duktape/duktapeConfig.cmake:22 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  .../vcpkg/scripts/buildsystems/vcpkg.cmake:859 (_find_package)
  CMakeLists.txt:106 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

Proposed solution
Make it lowercase
Describe alternatives you've considered
Using variants of lowercase and capitalized. But it's impossible to get to a general solution this way. Capitalized name won't find the config file. Lowercase will lead to the warning.
Additional context
No response

OMG. What a mess.

Duplicates #35308.


feat: change an existing subscription plan of customer

https://github.com/raystack/proton/pull/334

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.1%) to 41.652%

Totals

Change from base Build<PHONE_NUMBER>:
-0.1%

Covered Lines:
5987

Relevant Lines:
14374

💛  - Coveralls


Update use-key-vault-references-dotnet-core.md

This is a pitfall in the documentation. "read access" may mislead users to assign "Key Vault Secrets Reader" role. However, the correct way is to assign "Key Vault Secrets User" role.

@maud-lv
When the changes are ready for publication, add a #sign-off comment to signal that the PR is ready for the review team to merge.
#label:"aq-pr-triaged"
@MicrosoftDocs/public-repo-pr-review-team

#sign-off

#sign-off

Due to the upcoming Ignite conference, all merging and publishing is on hold until the morning of 11/15.
This PR is ready for merge on 11/15.
#label: "event-triaged-to-10AM"
#label: "missed-content-complete"


F401 - Distinguish between imports we wish to remove and those we wish to make explicit-exports

Resolves #10390 and starts to address #10391
Changes to the implementation

In the body of the loop over import statements that contain unused bindings, the bindings are partitioned into to_reexport and to_remove (according to how we want to resolve the fact they're unused) with the following predicate:in_init && is_first_party(checker, &import.qualified_name().to_string()) // true means make it a reexport

Instead of generating a single fix per import statement, we now generate up to two fixes per import statement:(fix_by_removing_imports(checker, node_id, &to_remove, in_init).ok(),
 fix_by_reexporting(checker, node_id, &to_reexport, dunder_all).ok())

The to_remove fixes are unsafe when in_init.
The to_explicit fixes are safe. Currently, until a future PR, we make them redundant aliases (e.g. import a would become import a as a).

Other changes

checker.settings.ignore_init_module_imports is deprecated/ignored. Instead, all fixes are gated on checker.settings.preview.is_enabled().
Got rid of the pattern match on the import-binding bound by the inner loop because it seemed less readable than referencing fields on the binding.
[x] // FIXME: rename "imports" to "bindings" if reviewer agrees (see code)
[x] // FIXME: rename "node_id" to "import_statement" if reviewer agrees (see code)

Scope cut until a future PR

(Not implemented) The to_explicit fixes will be added to __all__ unless it doesn't exist. When __all__ doesn't exist they're resolved by converting to redundant aliases (e.g. import a would become import a as a).

Test plan

[x] crates/ruff_linter/resources/test/fixtures/pyflakes/F401_24 contains an __init__.py without __all__ that exercises the features in this PR, but it doesn't pass.
[x] crates/ruff_linter/resources/test/fixtures/pyflakes/F401_25_dunder_all contains an __init__.py with __all__ that exercises the features in this PR, but it doesn't pass.
[x] Write unit tests for the new edit functions in fix::edits::make_redundant_alias.

The ecosystem checks look concerning. We're losing fixes in preview? I think there should be no changes in stable?

Yes, yes those do look concerning. I'll look into it.

Not sure what's up with the Latch changes. I ran it locally and they are indeed classified as first-party (at least by the isort rule).

Done with this round of review. I think the outstanding issues (in order of importance) are:
(1) Incorrectly categorizing many imports as not first-party in ecosystem results.

Latest change might address this by setting level correctly

(2) Dangling `__all__` code`let dunder_all = None;``dunder_all: bool` field of `UnusedImportContext::init``dunder_all: Option` argument of `fix_by_reexporting`  `match dunder_all` in `fix_by_reexporting` which has a "not implemented" branch  branch in `fix_title` of `impl Violation for UnusedImport` which handles the case for no2

To complete this feature requires adding a new edit function and calling it at no4.

(3) Some functions still take `impl Iterator<...>` but might be better to take `&'a [...]``fix::edits::make_redundant_alias`  `fix_by_reexporting`  `fix_by_removing_imports`

latch/latchbio is still getting many imports incorrectly categorized, it seems

I think there might just be a bug in my logic somewhere, since it seems that the only things being miscategorized are bindings in the syntax
from foo.bar.baz import (bind1,bind2)

So I'll write a test for that syntax and see what happens with it.

Cool, I can help take a look at the remaining Latch categorizations tomorrow if it’s helpful!

On second glance, aren't the ecosystem changes correct? We're now offering fixes for first-party imports in __init__.py files, whereas we weren't before?

Congrats on the merge :)


eye dropper

Problem
Background colors can only be picked via the color picker
Fix
Use the Eyedropper API to make picking a background color easier.
If there are one or more elements selected, the color picker can be opened by pressing ctrl + C (same as in Sketch). Once a color has been picked, it is set as the backgroundColor prop of all selected elements. The interaction can be aborted with Esc.
Demo

What needs to happen here so this can be merged?
And does it fail gracefully (no-op, not crash) on Safari?

Pressing ctrl+c in any browser that doesn't support the eyedropper API results in a no-op (the shortcut doesn't do anything)


Add Shade and sun automation capability to covers + fixes

Hi @JoDehli,
I added the capability to enable/disable sun automation and quick shade.
Also, I found missing device_class GATE for LoxoneGate (see spec:
animation
○ 0 = Garage Door
○ 1 = Single Gate opening to the left
○ 2 = Single Gate opening to the right
○ 3 = Gate opening to both sides
○ 4 = Folding door opening to the left
○ 5 = Folding door opening to the right
)

Could this change result in problems with scenes. Since some days i have problems executing scenes with covers involved.
If the  scene is integrated in an automation this leads to an error and aborts the automation
Error [547590411712] Entity cover.fenster_kuche_arbeitsflache does not support this service.
To reproduce just add a Cover Entity or Device in a scene. Complete log attached
errorlog home assistant pyloxone.txt

@shvnrg you can try the service manually. If the service is not present anymore you can either remove it from your automation or give the cover a different animation.
Is it a shade command which you send?

I dont use the service directly. I am working over the scenes configuration.
Added a scene, added the entity, configured the height. saved the scene.
When i am using services direct in an automation there are nor errors. I use mainly cover - open, close, set position.
Tried to delete the "old" scene and recreate it, same problem. In the Scene itself i have no options for configuration.

Just did a quick check of the scenes.yaml. Looks like the Scene saves "current_tilt_position: 0"
Which is probably the problem. After deleteing it looks like there are no errors

Hi @shvnrg, can you please send us your scene? I don't know what you set up and would need this to reproduce the issue. And please add how it is set up in Loxone.

I will try to give you a complete rundown, thats probably the best way to not miss anything
Sorry, will be long ....
Loxone Config from one of the devices.
Did not touch them since installation. My stuff is all managed in Home Assistant, but maybe there is already a misconfiguration.

Creating the Scene
Home Assistant -> Settings -> Automations & scenes -> Scenes -> Add Scene

Dont mind the name of the Device, it is changed in Home Assistant via GUI
Click the Device and change value as needed:

->Save Scene
Testing
Activating the Scene now changes the cover to the position, but gives this error:

If only the scene is activated it will do what you want but throw a error in the log files. If you use the Scene in an automation it will stop the automation because of the error.
Created Scene in scenes.yaml
- id: '1699808002428'
  name: Test Scene for Tilt Problem
  entities:
    cover.fenster_buro_schreibtisch:
      current_position: 31.200000000000003
      current_tilt_position: 100
      uuid: 17fac420-026d-3d23-ffff112233445566
      device_typ: Jalousie
      platform: loxone
      room: Büro
      category: Beschattung
      current_shade_mode: ' '
      current_position_loxone_style: 69
      automatic_text: Automatik Beschattung wegen geschlossener Jalousie für heute
        inaktiv.
      auto_state: 'off'
      is_sun_automation_enabled: 'off'
      device_class: blind
      friendly_name: Fenster Büro Schreibtisch
      supported_features: 1039
      state: open
  metadata: {}

Workaround
Deleting the following line is a workaround. Then the scene activates and there are no problems:
      current_tilt_position: 100
Physical Hardware
I am not sure about the translation here so i thought i show you how the cover looks. It is used in Germany in many homes. Very simple up and down cover for the windows

Hi @shvnrg, thank you for the details you provided Based on the info you provided, you use a Jalousie type called "Shutter". I checked the Loxone structure file and PyLoxone code and I found a discrepancy/bug.
@JoDehli : https://github.com/JoDehli/PyLoxone/pull/214 created
Anyway, this afternoon I want to test it and find out if it really solves the @shvnrg's issue. It will be a little complicated as I don't have "Automatic blinds integrated" but only "Automatic blinds". Hopefully, I will be able to reproduce it anyway.

Just updated to 0.4.10 -> No change in behaviour at the moment.
If you need more infos just ping me.

@shvnrg and @JoDehli : after investigation I found the issue. I prepared a fix in https://github.com/JoDehli/PyLoxone/pull/215.
Hopefully, I was able to reproduce it with "Automatic blinds".
The property current_cover_tilt_position is propagated to scenes because
an entity has attribute/property current_cover_tilt_position with value even if it is not tiltable cover.
I add a condition to return value only if it is BLIND and return None in other cases. After that, property current_cover_tilt_position is not propagated to scenes.
@shvnrg : anyway, for already created scenes you need to delete current_cover_tilt_position manually. For new scenes, the current_cover_tilt_position should not be propagated.
One more comment: It looks like only BLIND is a tiltable cover device class. If there is another, then it needs to be added on lines 410 and 475.


Cant use left join

Hi, i have the problem with left join when i started to using db2rest. the left join turn into inner join, and i dont know how this even possible. this the screenshoot of the Log in my db2rest

and this the curl i used to generate that Log
curl 'http://localhost:8080/v1/rdbms/db/transmigran/_expand' -i -X POST \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-d '[{"table":"users","type":"LEFT","fields":["nama:updatedBy"],"on":["updated_by==id"]}]'

as you can see in the screenshoot, the query its turn to inner join instead of left join

Hi @farasjibran and welcome to DB2Rest!
Which database and version are you using? PostgreSQL 17.2?
The default join type is an INNER JOIN, so my hunch is that somehow the "type":"LEFT" is not getting picked up correctly, possibly due to some other issue in the syntax.
Are you sure you have a field in the users table that is called nama:updatedBy? not just updatedBy?

Thanks @farasjibran for bringing this to our attention, we’re looking into it.

Hi @farasjibran and welcome to DB2Rest! Which database and version are you using? PostgreSQL 17.2?
The default join type is an INNER JOIN, so my hunch is that somehow the "type":"LEFT" is not getting picked up correctly, possibly due to some other issue in the syntax. Are you sure you have a field in the users table that is called nama:updatedBy? not just updatedBy? You might try the left join against another field or change the on condition, to help us troubleshoot further and try to narrow down the problem and reproduce it. Maybe you could try creating 2 simple tables and performing the left join and see if things work better?

Hi @thadguidry, thanks for the following up this issue. i am using PostgreSQL version 14. and in the table users its not have a field name updatedBy, the updatedBy is the aliases of the nama in the table users. so i call like nama:updatedBy. i have try another table to check if the left join have the problem only in my table transmigran. but its return same like the screenshoot i attach in this issues.
I raise this issue because when i use the type LEFT in another table, its return same like that. the query show its INNER JOIN not LEFT JOIN. this the screenshoot of comparison of query in db2rest. and in my DBeaver when i test using raw query
db2rest (still same) :

this the example of the code :
const response = await apiClient.post<Transmigran[]>(      ${TABLE_TRANSMIGRAN}/_expand?filter=user_id==${id_user},       [         {           table: "alamat",           withTable: "transmigran",           fields: [             "info_lokasi_id",           ],           on: ["id==transmigran_id"],         },         {           table: "info_lokasi",           type: "LEFT",           fields: ["nama_lokasi"],           on: ["info_lokasi_id==id"],         },       ]     );
and this in my DBeaver :

Found this morning when i check one by one the log that retrieve in db2rest log, and i found some bug in the sintax. you guys must update the documentation very soon to fix this. i see the type you say in documentation is not the exactly syntax to set the type of the join. when i see the log, the syntax to set the type of join is joinType.
now the query is works like what i want. just please update the documentation, so the people who want to use db2rest will find it easier when using it and not experience things like this again.
i close this issue right now, thanks for the attention guyss.

Thanks. Yes we did recently change it. We will update the docs today.
On Thu, Nov 28, 2024, 9:50 PM Muhammad Farras Jibran <
@.***> wrote:

Found this morning when i check one by one the log that retrieve in
db2rest log, and i found some bug in the sintax. you guys must update
the documentation very soon to fix this. i see the type you say in
documentation is not the exactly syntax to set the type of the join. when
i see the log, the syntax to set the type of join is joinType.
now the query is works like what i want. just please update the
documentation, so the people who want to use db2rest will find it easier
when using it and not experience things like this again.
i close this issue right now, thanks for the attention guyss.
—
Reply to this email directly, view it on GitHub
https://github.com/9tigerio/db2rest/issues/819#issuecomment-2507043651,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAISPRBW6ZE4HCAITEDGAU32C7QCBAVCNFSM6AAAAABSU33AX6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKMBXGA2DGNRVGE
.
You are receiving this because you were assigned.Message ID:
@.***>

@farasjibran  You can update the documentation as well, isn't that great?!  Just send a pull request.

@farasjibran You can update the documentation as well, isn't that great?! Just send a pull request.

i will send a pull request to update the documentation soon, thankss for the feedback @thadguidry


Improve doc on Bring your own backend section.

What needs to be changed?
This section needs to be update: https://opentelemetry.io/docs/demo/kubernetes-deployment/#bring-your-own-backend
After discussing this PR https://github.com/open-telemetry/opentelemetry.io/pull/2876 with the SIG team, we have decided to update the docs instead of adding a new pipeline to the demo.
Creating this issue to track it.

Any update?

I don't think this change is still necessary.
Closing it, but feel free to re-open it.


fixed a mistake in get_browserfilterable_posts and wrote a test for it

The get_browsefilterable_posts function had a mistake in it that would cause an uncaught exception if one of the intermediate calls to get_page_set returned None. That was fixed. Also, tests were written for get_browsefilterable_posts and get_appropriate_descendants functions.
Additions

test for get_appropriate_descendants
test for get_browsefilterable_posts

Changes

in get_browsefilterable_posts, the filtered_controls dict accumulates the results of get_page_set via append so that it doesn't throw an error if that result is None.

Testing

two tests written as above

Review
@richaagarwal @chosak @willbarton
Checklist

[ ] Changes are limited to a single goal (no scope creep)
[ ] Code can be automatically merged (no conflicts)
[ ] Code follows the standards laid out in the front end playbook
[ ] Passes all existing automated tests
[ ] New functions include new tests
[ ] New functions are documented (with a description, list of inputs, and expected output)
[ ] Placeholder code is flagged
[ ] Visually tested in supported browsers and devices
[ ] Project documentation has been updated (including the "Unreleased" section of the CHANGELOG)

👍

:+1: This looks good to me. One minor request, can you run flake8 or something similar against test_sublanding_page.py to clean up the formatting?

Are we scrupulously observing line length? It annoys me that flake complains about a line that is 80 characters in length when splitting that line in two makes for more difficult reading than just keeping it as is. Also in some cases there is a visual indent that flake will complain about if you remove it in order to reduce line length. If people have really strong opinions about this I'll do it, but honestly I would much rather overrun the line length by a few characters and keep the visual coherence of the calls intact than try and satisfy flake.

@grapesmoker Yeah, I think those are good reasons for ignoring the line length suggestion.  AFAIK, we're treating it as a suggestion as opposed to a requirement.

There's also some previous line length discussion here. I wouldn't consider indentation a blocker, but for lines like this consider that it can be difficult to look at the code when an editor is divided horizontally into two buffers on small (laptop) screens:

I tried to cut down the line lengths as much as possible, mostly in the comments and in that one generator expression that @chosak posted a picture of. I get that line length can be an issue with an IDE like emacs (which I use too) but sometimes there just isn't a better aesthetic alternative than to run a bit over. Hopefully the changes I've made help.

@grapesmoker agreed, and thanks. :+1:

👍


Add missing Meltano sources

When submitting https://github.com/whalyapp/connector-catalog-data/pull/31 some Meltano provided connectors were not matching any existing source in the source catalog.
The list is here ⤵
npx ts-node scripts/vendor-source-check.ts data/vendors/meltano.json

abcfinancial
aconex
acuite
adyen
agilecrm
amazon-ads-dsp
amazon-associates
amazon-mws
amazon-sp
apachelog
apaleo
apparel-magic
appfigures
ask-nicely
athena
atinternet
auth0
autodesk-bim-360
awin
aws-cost-explorer
basecone
bexio
billwerk
bitso
bling-erp
bls
bold
brightpearl
bynder
carbon-intensity
ccxt
centra
chatitive
chorusai
circle-ci
clarabridge
clickcast
clockify
closeio
clover
clubhouse
coingecko
coosto
cqc-org-uk
csv
currencyfreaks
customerx
dagster
daisycon
dash-hudson
dayforce
dbf
dbt
dbt-artifacts
decentraland-api
decentraland-thegraph
degreed
density
domo
dynamics
ebay
emarsys
estoca
exactsales
exacttarget
exchangeratehost
exchangeratesapi
fabdb
facebook-posts
facebook-reviews
feed
five9
fixerio
forecast
frontapp
fulfil
getpocket
github-org-projects
gleantap
gmail-csv
harvest-forecast
hellobaton
helpshift
holidays
idealo-click-report
ilevel
immuta
indeed
insided
intacct
ireckonu
kanbanize
krow
kwanko
lastfm
lessonly
lightdash
listen360
livechat
logmeinrescue
lookml
loopreturns
lotr
maestroqa
mailgun
marketman
meltano
meltanohub
memberful
mercadopago
meshstack
mindstamp
mode
netlify
newrelic
nhl
nikabot
officernd
open-library
opensea
openweathermap
ordway
parquet
partoo
peloton
planfix
platformpurple
powerbi-metadata
process-street
procore
prometheus
pubg
purecloud
quaderno
rakuten
readthedocs
redash
responsys
rest-api-msdk
reviewscouk
richpanel
rickandmorty
rockgympro
s3-csv
search-ads
servicem8
sevenrooms
sharepointsites
signonsite
simplifi
sklik
skubana
sleeper
sling
sms
snapengage
solarvista
spotify
spreadsheets-anywhere
stackexchange
stackoverflow-sampledata
starshipit
stella
stringee
sumologic
tableau
talkable
teamwork
thinkific
thunderboard
tickettailor
tiktok-business
timebutler
toast
treez
trustpilot
trustrace
tvsquared
twinfield
twitter-streams
typo
udemy-for-business
ujet
vnda-ecommerce
walkscore
webcrawl
wonolo
wordpress-plugin-stats
wordpress-reviews
wordpress-stats
workday-raas
zenefits
zohosprints

We should create sources .json definitions files + logos for those.

Feel free to crib data and images from https://github.com/meltano/hub/tree/main/_data/meltano/extractors as well!


Initial updates

how do i mega approve this

I can't merge btw your perms are fecked

Your privs should be fixed now though.


Add drop tenant / drop schema tests to the CI build's e2e tests

Is your feature request related to a problem? Please describe.
https://github.com/IBM/FHIR/pull/2100 fixed a couple outstanding issues with our drop schema command on postgresql.  It would be nice if this was exercised on every pull request (to ensure we maintain this proper functional behavior).
Describe the solution you'd like
In the post-integration-test scripts, we should issue a --drop-schema command that exercises this logic.
Describe alternatives you've considered
Acceptance Criteria
Additional context
Could possibly be folded in to the migration tests.
Open question:  does this need to cover multi-tenant schemas within Db2 as well?

Could be done in combination with other persistence-schema tool work items like #2401

If we find issues, #2401 would be the solution for that...don't fix any existing issues under this work item.


a button in settings to save full conversation as pdf or jpg would be powerful

Maybe. Sounds a bit complicated compared to the utility.

Added in 1.4.0


Refactored Apis with correct api-version

Moved Operations Api to separate directory 2016-08-10 with examples
Added itemName: Value in Operation Apis for x-ms-pageable
Added x-ms-examples to Operations Api

This checklist is used to make sure that common issues in a pull request are addressed. This will expedite the process of getting your pull request merged and avoid extra work on your part to fix issues discovered during the review process.
PR information

[x] The title of the PR is clear and informative.
[x] There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For information on cleaning up the commits in your pull request, see this page.
[x] Except for special cases involving multiple contributors, the PR is started from a fork of the main repository, not a branch.
[x] If applicable, the PR references the bug/issue that it fixes.
[x] Swagger files are correctly named (e.g. the api-version in the path should match the api-version in the spec).

Quality of Swagger

[x] I have read the contribution guidelines.
[x] My spec meets the review criteria:

[x] The spec conforms to the Swagger 2.0 specification.
[x] The spec follows the guidelines described in the Swagger checklist document.
[ ] Validation tools were run on swagger spec(s) and have all been fixed in this PR.

No modification for NodeJS

No modification for Python

No modification for Ruby


error getting credentials for push/pull

I'm on Ubuntu 18.04 and have grabbed the img binary directly from github.
When I run "img pull" or "img push" for any image, both Docker Hub and others, I get an error complaining about not being able to get credentials.
$ img pull ubuntu
Pulling ubuntu...
rpc error: code = Unknown desc = error getting credentials - err: exit status 1, out: `Exhausted all available authentication mechanisms (tried: EXTERNAL) (available: EXTERNAL)`

$ img pull r.j3ss.co/stress
Pulling r.j3ss.co/stress...
rpc error: code = Unknown desc = error getting credentials - err: exit status 1, out: `Exhausted all available authentication mechanisms (tried: EXTERNAL) (available: EXTERNAL)`

It works fine with Docker:
$ docker pull ubuntu
Using default tag: latest
latest: Pulling from library/ubuntu
38e2e6cd5626: Pull complete
705054bc3f5b: Pull complete
c7051e069564: Pull complete
7308e914506c: Pull complete
Digest: sha256:945039273a7b927869a07b375dc3148de16865de44dec8398672977e050a072e
Status: Downloaded newer image for ubuntu:latest`

$ docker pull r.j3ss.co/stress
Using default tag: latest
latest: Pulling from stress
Digest: sha256:0897535c294b68e24db4d647b726ac6203cc1879bbc6b5093f677c46405cbd26
Status: Image is up to date for r.j3ss.co/stress:latest

Is this a bug in img or something to do with my system?

I tried to push a Image to docker hub an it fails. Tested with sucessful img login and -v $HOME/.docker:/root/.docker running inside of a docker container. So build works, but push fails.

same here. Any info how to fix this?

Same problem here, can't pull image because of credential error :
img pull redis Pulling redis... rpc error: code = Unknown desc = error getting credentials - err: exit status 1, out:Exhausted all available authentication mechanisms (tried: EXTERNAL) (available: EXTERNAL)
So  it's impossible to use this tool....

I was able to track down the Exhausted all available authentication mechanisms (tried: EXTERNAL) (available: EXTERNAL) error down to the "credsStore": "secretservice" setting in ~/.docker/config.json. That message seems to be a D-Bus message telling that the application is not entitled to get secrets from the user's credential store. If I remove the credsStore setting and login again, the error is gone and everything works as expected.
I assume this is due to the fact that img re-executes itself and enters some namespace. When the re-execed process then tries to connect to the secret store, it does so with a different uid which is not allowed to access the passwords.
I have no idea how this could be fixed, although the workaround is to not use secretservice in conjunction with img.

I was able to track down the Exhausted all available authentication mechanisms (tried: EXTERNAL) (available: EXTERNAL) error down to the "credsStore": "secretservice" setting in ~/.docker/config.json. That message seems to be a D-Bus message telling that the application is not entitled to get secrets from the user's credential store. If I remove the credsStore setting and login again, the error is gone and everything works as expected.
I assume this is due to the fact that img re-executes itself and enters some namespace. When the re-execed process then tries to connect to the secret store, it does so with a different uid which is not allowed to access the passwords.
I have no idea how this could be fixed, although the workaround is to not use secretservice in conjunction with img.


⚠ Roblox DataStore Api has degraded performance

In 0887358, Roblox DataStore Api (https://gamepersistence.roblox.com) experienced degraded performance:

HTTP code: 200
Response time: 2322 ms

Resolved: Roblox DataStore Api performance has improved in 1de75a1.


Deleting admin user fails

When my old email address became invalid, I did created a new admin user with new email address.
Then, I tried to remove the user with the invalid email, but got this error:
The User cannot be deleted as it is the only manager for the following resources: [...].
If I understand well, I have to add new managers to all the resources created by old user...not very intuitive...
Is there another way to replace email address of an existing IPT user?

I guess you could change it directly in /config/users.xml
Make a backup before. Change the email. Restart tomcat. Test it.
If it is not working, use your backup and restart tomcat.
(Not so sure about restarting tomcat, but sometimes, it looks that ipt needs it)

Yes, it's possible to change in internal IPT files (but not recommended though).
There is no another way I'm afraid. We can consider implementing that functionality in the future


Error: Vue is not defined, when i use vue-router

weex-toolkit verison:
v1.3.11 .

weexpack : v1.2.7
weex-debugger : v1.1.17
weex-builder : v0.4.0
weex-previewer : v1.5.1
platform: Mac

As the guide write, when i use vue-router,  errors: Vue is not defined.

My steps:

weex create project and yarn dev & yarn serve
add route in router.js
use router in index.vue

// index.vue

<template>
  <div class="wrapper">
    <image :src="logo" class="logo" />
    <text class="greeting">The environment is ready!</text>
    <text @click="jump">Profile</text>
    <router-view/>
  </div>
</template>

<script>
import router from './router'
export default {
  name: 'App',
  data () {
    return {
      logo: 'https://gw.alicdn.com/tfs/TB1yopEdgoQMeJjy1XaXXcSsFXa-640-302.png'
    }
  },
  methods: {
    jump () {
      router.push('about')
    }
  }
}
</script>

// router.js
/*global Vue*/
import Router from 'vue-router'
import HelloWorld from '@/components/HelloWorld'
import About from '@/about'

Vue.use(Router)

module.exports = new Router({
  routes: [
    {
      path: '/',
      name: 'HelloWorld',
      component: HelloWorld
    },
    {
      path: '/about',
      name: 'About',
      component: About
    }
  ]
})

if i delete /*global Vue*/ and add import Vue from 'Vue', errors is '[vue-router] Route with name 'about' does not exist'.
And if i restart the demo, ERROR in ./.temp/router.js Module build failed: Duplicate declaration "Vue"

@Yhspehy something wrong with the path import About from '@/about', the @ is an alias of the path src, you need to check if there has a component file on src/about.vue.

@erha19 Sorry for replaying this so late. It seems there is something wrong with my env. Today it is all right when i run yarn serve. Thx!


Implement seccomp notify

This is the first part of the change where we support seccomp notify and returning a fd for seccomp.
Next, we will implement the seccomp listeaner in the OCI spec.

Codecov Report

Merging #330 (84b9eca) into main (4224d56) will increase coverage by 0.14%.
The diff coverage is 81.69%.

@@            Coverage Diff             @@
##             main     #330      +/-   ##
==========================================
+ Coverage   71.14%   71.29%   +0.14%
==========================================
  Files          46       46
  Lines        6828     6891      +63
==========================================
+ Hits         4858     4913      +55
- Misses       1970     1978       +8

Is it possible to break the mod.rs down into a few more files?

Is it possible to break the mod.rs down into a few more files?

We can, but it is still a coherent block at the moment. The only relevant pub function here is initialize_seccomp. All the other bits are in the service of this function. Maybe next time when this file gets larger.

We can, but it is still a coherent block at the moment. The only relevant pub function here is initialize_seccomp. All the other bits are in the service of this function. Maybe next time when this file gets larger.

Ok, I agree with you.


GLSL define injection update for limits & features

Description
Described in issue #391
Testing

TODO list:

[ ] Figure out how to get every GLSL extension which shaderc/glslang could use given device enabled features(?)

wrong target branch


Update poetry lock files

Upgrade to fix some  reported vulnerabilities on github
Make versions consistent between potery lock files again

aww man this makes your added line count positive this week


Chunky Monkey: I'm returning the given solution but not solving the problem

Chunky Monkey

https://www.freecodecamp.com/challenges/chunky-monkey
Issue Description

The code I've written correctly follows the steps as described in the problem and I'm returning the correct solution to each instance. However, none of the instances are being checked off as correct.
Browser Information

Browser Name, Version: Chrome
Operating System: Windows 7
Mobile, Desktop, or Tablet: Desktop

Your Code
var segments = [];
var newArray = [];
function chunkArrayInGroups(arr, size) {
  // Break it up.
  for (var i = 0; i < arr.length; i += size) {
    segments = arr.slice(i, i+size);
    newArray.push(segments);
    console.log(newArray);
  }
  return newArray;
}

chunkArrayInGroups(["a", "b", "c", "d"], 2);

Screenshot

@gonzalezi2 your segments and newArray variables are in the global scope, which will keep state after each function call used in the tests. Locally scope them (i.e. put them within your function) and it should work. Happy coding!

Wow. That's all it took. Thank you so much!!
One question: Why would it return the correct answer though? If I had gotten an error I would know to change it but without an error, and a correct answer, it's hard to figure out what the problem is.

@gonzalezi2 when you run it just once with the Run Tests button, it runs the entire code in your editor. However, the tests just run the function you've created and so the variables you've initialized in the global scope change with each test. Yeah, I've seen many people confused about it. Maybe we could add in a note somewhere early on in the curriculum about not using global scoped variables or something.

yeah that would make it more clear. I still have trouble with it at times because sometimes it is necessary to create it globally because if I create a local variable and try to call it outside I get the "out of scope" error. So yeah some clarification on that would go a long way. Thanks for your help!

Please use the Help chat room for getting challenge related help. Happy Coding!


JXRay: Reference Chains for Bad Primitive Arrays: big overhead from netty

We started looking at YARN NodeManager GC issues and most impact comes
according to http://www.jxray.com/ comes from netty with a huge portion of buffers being all zeros:
"The problem is that Netty has various buffers managed by netty.
They may be too big, so a big portion of them stays unused, containing only zeroes"
Expected behavior
Allocated buffers' sized accordingly to workload.
Actual behavior

A lot of memory overhead for the application.
Most of buffers are all-zeros.
Huge GC overhead.

Steps to reproduce
Hard to reproduce outside of a live Hadoop Yarn application, but we can provide java heap dump,
or full jxray report.
Netty version
netty-3.10.6
JVM version (e.g. java -version)

$ java -version
java version "1.8.0_152"
Java(TM) SE Runtime Environment (build 1.8.0_152-b16)
Java HotSpot(TM) 64-Bit Server VM (build 25.152-b16, mixed mode)

OS version (e.g. uname -a)

RHEL 7.4
Linux 3.10.0-693.11.6.el7.x86_64

You're using a very outdated version. Only the 4.1 train is currently maintained.
Then, Netty 4.0 introduced new memory management mechanism and it's likely that the problem you mention has been fixed.
You need to upgrade to latest 4.1 and then report back if issue still exists.

@Tagar beside what @slandelle said this is kind expected as the PoolChunk is part of the PooledByteBufAllocator and so the memory is pooled. You may want to adjust the settings for PooledByteBufAllocator and use settings that better match your requirement / expectations.
There is really nothing wrong here.


AttributeError: readonly attribute

[user@web ~]$ termtosvg
Traceback (most recent call last):
File "/home/user/.local/bin/termtosvg", line 7, in
from termtosvg.main import main
File "/home/user/.local/lib/python3.4/site-packages/termtosvg/main.py", line 8, in
import termtosvg.anim as anim
File "/home/user/.local/lib/python3.4/site-packages/termtosvg/anim.py", line 27, in
_CharacterCell.text.doc = 'Text content of the cell'
AttributeError: readonly attribute

As stated in the readme, termtosvg requires Python >= 3.5


[HUDI-5578] Upgrade base docker image for java 8

Base Hudi image is based on pretty old openjdk:8u212-jdk-slim-stretch.
This PR upgrades it to the latest openjdk:8u342-jdk-slim-bullseye. This syncs with the existing java 11 base image distro.
openjdk:8u342-jdk-slim-bullseye comes with python3.9 available via apt-get, so it makes this image compatible with Spark 3.
Change Logs
Change base docker image for Hudi from old openjdk:8u212-jdk-slim-stretch to latest openjdk:8u342-jdk-slim-bullseye.
Impact
No impact on APIs
Risk level (write none, low medium or high below)
Low, onl updates jdk 8 and linux distro version
Documentation Update
None
Contributor's checklist

[x] Read through contributor's guide
[x] Change Logs and Impact were stated clearly
[x] Adequate tests were added if applicable
[ ] CI passed

CI timed out, I'm not sure if it makes sense to run it again considering this touches docker demo images

@hudi-bot run azure

CI failed two times due to the timeout

@hudi-bot run azure

@kazdy : Can you build the docker images locally and have the hudi  integration tests pass and paste the output here.

@bvaradar I treid to build images locally with docker/build_local_docker_images.sh it finishes with success, but no images shown when i do docker image ls -a, tried on macos and ubuntu.
Besides, how do I run integration tests with locally built images? Could you point me at some instructions how do to it, I haven't found any concise description?

@xushiyan maybe you'll be able to give some directions on how do build these images locally and run integration tests?

@kazdy : Can you look at https://github.com/apache/hudi/tree/master/docker for details on how to setup locally ? Can you try locally removing all the pulled hudi images and try ?

@kazdy : Is this PR still required ?

@kazdy : Is this PR still required ?

yes it is, I had issues running integration tests on M1, I did not have time to run these on my amd box yet


my ratings range is from 1 to 5 but when using lightgcn model the prediction values of rating range is from 5 to above 10

that happened when I used lightgcn model I hope you tell me what is the possible problems if I have a problem or tell me if its a problem in the library

I now noticed something that the problem occurs when my userID and ItemID columns are strings
so does this make a problem in this library and if it is then How can I solve it without changing the user and items strings to numbers

my input data is like this
thanks in advance

I am sorry I didnot read the resarch very well
it appears that lightgcn doesnot consider ratings to be inside range


Setup Intent Implementation (Used for reusing cards)

@NicholasBertazzonAga It is ready

@NicholasBertazzonAga It is ready

Thanks, give me some time but I think I'll publish a new release with your modification as soon as today

@miladebadi btw version published


Fix #8627: invalidate table schema cache on DDL

Fix #8627: invalidate table schema cache on DDL
Any DDL statement composed using yii\db\Command methods automatically refreshing related table schema.
Migration::execute() refreshes entire database schema, because raw SQL may contain DDL, which changes several tables.

I am unsure about naming for Command::requireTableSchemaRefreshment() and Command::refreshTableSchema(). Any suggestion is welcome.

We also have Connection::getTableSchema(). The main idea for exposing Connection::refreshTableSchema() is to make this more visible and accessible. Users are probably much more familiar with Connection than Schema.
Another arguable change is the addition of Schema::refresh() to Migration::execute(). @yiisoft/core-developers What's your opinion?

The main idea for exposing Connection::refreshTableSchema() is to make this more visible and accessible.

This can be done, but in this case Connection::refreshTableSchemaS() (or whatever the name will be) should be added as well for consistency.

Another arguable change is the addition of Schema::refresh() to Migration::execute().

I can't any other way as raw SQL may content any DDL statement. We may attempt to parse the SQL string searching for some particular keywords, but DDL syntax may vary from one DBMS to other. I don't think such appraoch will be reliable.

Refreshing schema at migration start is the safest approach I can think of.

This can be done, but in this case Connection::refreshTableSchemaS() (or whatever the name will be) should be added as well for consistency.

Well, it's very rare that you would need to refresh all table schemas.

I can't find any other way as raw SQL may content any DDL statement. ...

Our goal is to make sure schema-changing methods are working correctly. For raw SQL execution, we should emphasize by documentation that manually schema refresh is required. As you can see, refreshing schema in Migration::execute() still doesn't cover all cases (e.g. Command::execute()).

Refreshing schema at migration start is the safest approach I can think of.
Show all checks

It doesn't help in this case (e.g., you modify a table schema followed by row insertions in the same migration).

Right. Then I like the plan and PR. I see nothing wrong in having refreshTableSchemaS. Sometimes you don't care about re-reading schema (in MySQL it's fast) and don't want to name all 10 tables which schema you've affected.

Our goal is to make sure schema-changing methods are working correctly.

Disagreed. The problem, which is exposed at the issue #8627, is about unreliable DB migrations applying. Currently there are many migration written already, which may cause this problem appear at certain circumstances. We must ensure migration code as it mentioned in the docs is reliable. Enforcing developers to recheck and rewrite thier old migrations does not seem right.

For raw SQL execution, we should emphasize by documentation that manually schema refresh is required.

This is true for the DDL code written for specific business logic support inside regular application code. But for migration this will produce bad user experience: why should I manually clear table schema cache inside migration, which exists to change table schemas?

As you can see, refreshing schema in Migration::execute() still doesn't cover all cases (e.g. Command::execute()).

Yes, it does not. Still it is unlikely Command::execute() will be used inside a migration, while Migration::execute() is available. Of course, extra docs should be added, but migration should be reliable, at least in case of common usage, without extra developer work.
I don't see much harm clearing all table schemas on Migration::execute(): inside migration it will not cause sugnificant performance lost.

@klimov-paul Migration::execute() only deals with Migration::db. If a migration needs to handle multiple DBs, then you will see inconsistencies: when you call $this->execute(), you don't need to refresh schema; while when you call $db2->createCommand(...)->execute(), you have to refresh schema manually.
@samdark When you need to refresh multiple tables, $db->schema->refresh() is already very self-explanatory.

If a migration needs to handle multiple DBs, then you will see inconsistencies

Yes, it will be inconsistencies in complex cases. Sure we need to warn developers about it. But we need to handle the common migration flow automatically.
It is rather populare practice to use plain SQL for DLL inside migrations. For example: working with MySQL, people like to create tables via PHPMyAdmin interface and then create a migration for them using SQL generated by SHOW CREATE TABLE. This is not a good practice, but common one.
If I remove refresh() from Migration::execute() the following migration code will NOT work:
$this->execute('CREATE TABLE status ...');
$this->insert('status', ['name' => 'some']);
// another migration:
$this->execute('ALTER TABLE status ...');
$this->insert('status', ['title' => 'some']);

To make it work developer have to write it in following way:
$this->execute('CREATE TABLE status ...');
$this->insert('status', ['name' => 'some']);
// another migration:
$this->execute('ALTER TABLE status ...');
$this->db->refreshTableSchema('status');  // does not look right
$this->insert('status', ['title' => 'some']);

Do not forget, we are talking about migrations, which are already written! Which were promised to be working. We are fixing a bug - not creating new feature.

My point is that when you are working with multiple DBs, for one DB you don't need to refresh schema while for the other, you will have to. And even for working with a single DB, if you use Command::execute() directly (e.g. you are repeatedly executing SQLs which you don't want to use Migration::execute() to display the messages for), you still need to manually refresh schema.This is kind of hard to understand without knowing the internals. So why not just emphasizing the importance of always refreshing schema when using raw SQLs? This is the only rule that users need to remember.

why not just emphasizing the importance of always refreshing schema when using raw SQLs?

Simply because it enforces to add extra redundant code inside the migration. Migration up() and down() methods should be clean, clear of any code, which does not belong to actual database state change. Placing code like $this->db->refreshTableSchema('status'); all over migration code does not feel right - it seems redundant. It produces bad user experience - people will not accept this.
What we are going to tell to developers, which work on the at least 1 year old project? Should be ask them to review and edit all created so far migrations adding refreshTableSchema() all over them?
Currently you are saying to developer he/she must manually clear schema cache after database schema has been changed. For the migration this is noncence: migration exists for database schema changing, why it can not clear cache on its own?
I can agree on removal of Schema::refresh() from Migration::excute() in exchange of adding it at the begining (and perhaps at the end) of the migration. Migration internal code should remain clean. It may require extra effots for the complex cases, but not while developer uses only migration internal methods.

Simply because it enforces to add extra redundant code inside the migration.

That's only when you are using raw SQLs. So it really depends on how common it is that you would use raw SQLs to adjust table schemas (and if it is indeed common, then is it common to use raw SQLs to insert rows). Also when the migrations are working with a different DB or using Command::execute() to execute SQLs, this PR still won't solve the problem. It actually even hides the problem because users may think we have solved all problems. This is something I don't like.

I can agree on removal of Schema::refresh() from Migration::excute() in exchange of adding it at the begining (and perhaps at the end) of the migration.

This doesn't solve the problem if you are altering a table and inserting rows into it in the same migration.

I saw usage of SQL in migrations many times so it's indeed a common practice.

When you need to refresh multiple tables, $db->schema->refresh() is already very self-explanatory.

OK. Fine with me to leave it there.

Technically schema refresh could be solved by parsing low level requests for ALTER statement but that means doing it for every request made.

I saw usage of SQL in migrations many times so it's indeed a common practice.

What if the SQLs are executed via Command::execute()?

Technically schema refresh could be solved by parsing low level request...

What if it's done via a stored procedure?

Well, then we can't detect it. I understand what you're talking about: partial solution is worse than no solution in this case but I really don't like doing ->refresh() all the time. Especially in migrations.

This doesn't solve the problem if you are altering a table and inserting rows into it in the same migration.

For common migration - it will!
Usually developer performs all alteations to the table and then insert or update its data.
If at the begining of the migration cache is cleared, no table schema object will be created at plain execute(), which means table alteration will be applied just before insert/update.
For the single migration, while enableSchemaCache if false it works exactly this way. That is why it took so long for the issue #8627 to reveal itself.
If developer forget to clear cache after execute() inside migration and run up(), down(), up() to test it - migration will work fine - nothing will indicate anything is wrong, untill several migrations are run during same script execution.
Calling refresh() (at least) before migration apply ensures any sequence of migrations are run correctly. If extra refresing required during single migration  run - developer will realize it during migration testing.

Thanks for the explanation.
Are we currently disabling schema caching in migrations? I don't see the code there yet.

Disabling enableSchemaCache will not resolve the issue. If we disable - it we only ensures single migration applying works fine. If several migrations are applying in sequence they still may break.

I thought we already did this. Okay, I would prefer we refresh schema at the beginning of each migration.

Okay, I would prefer we refresh schema at the beginning of each migration.

refresh() has been moved to Migration::init().
Is there anything else to be changed?

A changelog entry? Codewise it looks good to me.

A changelog entry already present.

Right. Then it's complete.

:+1:

:+1:

Great work :+1:


Build error with 8.0.2-rc1

Trying to build xmonad-contrib be036f9 with ghc <IP_ADDRESS>61126:
XMonad/Layout/Groups/Helpers.hs:181:22: error:
    * Couldn't match type 'WithID l0 Window
                           -> XMonad.Util.Stack.Zipper (G.Group l0 Window)
                           -> XMonad.Util.Stack.Zipper (G.Group l0 Window)'
                     with 'G.ModifySpec'
      Expected type: (G.WithID l0 Window
                      -> XMonad.Util.Stack.Zipper (G.Group l0 Window)
                      -> XMonad.Util.Stack.Zipper (G.Group l0 Window))
                     -> G.GroupsMessage
        Actual type: G.ModifySpec -> G.GroupsMessage
    * In the second argument of '(.)' namely 'G.Modify'
      In the expression: sendMessage . G.Modify
      In an equation for 'wrap': wrap = sendMessage . G.Modify

Builds fine with 8.0.1.

On Sat, Nov 26, 2016 at 7:33 PM, Tuncer Ayaz<EMAIL_ADDRESS>wrote:

Trying to build xmonad-contrib be036f9
https://github.com/xmonad/xmonad-contrib/commit/be036f9bb9ddeb80e377cb6426d017b5108fac68
with ghc <IP_ADDRESS>61126:

You might want to hold off on rc1. They ran it against Stackage and found a
bunch of regressions like this that they are fixing for rc2.
--
brandon s allbery kf8nh                               sine nomine associates
<EMAIL_ADDRESS><EMAIL_ADDRESS>unix, openafs, kerberos, infrastructure, xmonad        http://sinenomine.net

Glad to hear that. I haven't seen the bulk build report, so didn't know that it's a regression. Do you have links to tickets/reports?

Should we close this until rc2 and try again or leave it open?

This was chatter in #ghc this morning. https://ghc.haskell.org/trac/ghc/ticket/12881 is one ticket opened as a result, but it doesn't look like the problem here. Other typechecking errors might well exist though; if something is known to work with 7.10.3 and 8.0.1 but not rc1, I would suspect an rc1 regression first --- and if there is an actual type issue the older versions let go, let the experts determine that.
(That looks like the only ticket currently open against the rc, aside from a Cabal update request.
(phab's not logging #ghc again so I can't link the discussion and suggestion of other regressions to be analyzed)

The problematic module uses ImpredicativeTypes, which has been unsupported for a while. The offending line is (https://github.com/xmonad/xmonad-contrib/blob/master/XMonad/Layout/Groups/Helpers.hs#L181)
wrap = sendMessage . G.Modify

which needs to instantiate (.) at G.ModifySpec, which I assume must be a polymorphic type. Simple eta expansion
wrap ms = sendMessage (G.Modify ms)

should avoid the need for ImpredicativeTypes.

Ok, that's fixable. (I didn't think we had any ImpredicativeTypes use in contrib. Sigh.)

Closing since there's a fix: #124.