CRI Pinned image support

Signed-off-by: Aditi Sharma<EMAIL_ADDRESS>This PR marks containerd sandbox/pause image as Pinned image, pinned images are not garbage collected by Kubelet.
Currently it only marks sandbox image as pinned.
fixes: https://github.com/containerd/containerd/issues/6352

@dcantah Thanks for review, do you have any idea why sandboxed tests are getting failed? they are failing in general or only on this PR?

cc @SergeyKanzhelev @mikebrow

@dcantah Thanks for review, do you have any idea why sandboxed tests are getting failed? they are failing in general or only on this PR?

The sandboxed test will run the same integration test with sandbox servers. So I think you need to make the same changes on pkg/cri/sbserver as well.

@adisky

do you have any idea why sandboxed tests are getting failed? they are failing in general or only on this PR?

The new test you added is failing:
=== RUN   TestContainerdSandboxImage
    containerd_image_test.go:215: make sure the pause image exist
    containerd_image_test.go:218: ensure correct labels are set on pause image
    containerd_image_test.go:219:
        	Error Trace:	/home/runner/work/containerd/containerd/containerd_image_test.go:219
        	Error:      	Not equal:
        	            	expected: ""
        	            	actual  : "pinned"

        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -1 +1 @@
        	            	-
        	            	+pinned
        	Test:       	TestContainerdSandboxImage
    containerd_image_test.go:221: pause image should be seen by cri plugin
    containerd_image_test.go:225: verify pinned field is set for pause image
    containerd_image_test.go:226:
        	Error Trace:	/home/runner/work/containerd/containerd/containerd_image_test.go:226
        	Error:      	Should be true
        	Test:       	TestContainerdSandboxImage
--- FAIL: TestContainerdSandboxImage (0.00s)

@ruiwen-zhao is correct; the test will run for both the server and sbserver implementations.  It looks like you haven't implemented your changes for sbserver yet, so the new test fails.

@ruiwen-zhao is correct; the test will run for both the server and sbserver implementations. It looks like you haven't implemented your changes for sbserver yet, so the new test fails.

@ruiwen-zhao @samuelkarp
I haven't read the sandbox API proposal but heard it wont require the pause container ? So Does it makes sense to add these changes in sbserver?

@ruiwen-zhao is correct; the test will run for both the server and sbserver implementations. It looks like you haven't implemented your changes for sbserver yet, so the new test fails.

@ruiwen-zhao @samuelkarp I haven't read the sandbox API proposal but heard it wont require the pause container? So Does it makes sense to add these changes in sbserver?

The proposal is here: https://github.com/containerd/containerd/issues/4131
I think the current requirement is that all new changes to cri/server will need to be made on cri/sbserver as well. You just need to copy your changes under cri/server over to cri/sbserver.

@ruiwen-zhao @pacoxu can you take a look again? added implementation to sbserver as well

Details

Thanks @adisky for updating the code! Looks good except for one comment above.

/ok-to-test

looks like flake
/test pull-containerd-node-e2e

ERROR: (gcloud.auth.activate-service-account) There was a problem refreshing your current auth tokens: ('invalid_grant: Invalid JWT Signature.', {'error': 'invalid_grant', 'error_description': 'Invalid JWT Signature.'})
/test pull-containerd-node-e2e

LGTM except for the comment around preventing pinned image from being GC'ed by containerd. IMO we can add the GC part in a separate PR, if the change is not trivial.

asked for additional review from Derek and Fu Wei .. I'm concerned over doing a partial implementation with a follow up though we are passed the 1.7 release now so probably time enough to do it all in the main branch for 2.0.. and only revert if we don't get the 2nd part (auto GC skip) done. If we did allow gc/delete we should probably delete the pinned tag as well?

Thanks for the mention! I need time to check discussion and will update my comments later.

We (EKS) have encountered an issue where kubelet inadvertently garbage collects the sandbox_image; and this PR would resolve our issue. @adisky can you address the conflicts and get this mergeable again?

@cartermckinnon sure, will address the conflict and review comments by next week

a couple lint issues to address:20

Running [/home/runner/golangci-lint-1.52.2-linux-amd64/golangci-lint run --out-format=github-actions --timeout=8m] in [] ...
21
Error: const imageLabelKey is unused (unused)
22
Error: const imageLabelValue is unused (unused)

cri-o related PR https://github.com/cri-o/cri-o/pull/6903

Thank @mikebrow for review, rebased
Also linking the discussion we had on containerd slack
https://cloud-native.slack.com/archives/CGEQHPYF4/p1685533468086829

@mikebrow @dmcgowan Any objection to backporting this (or at least the logic setting the pinned property based on the io.cri-containerd.pinned label) to 1.7 and 1.6?

Thanks @ruiwen-zhao for opening https://github.com/containerd/containerd/pull/8718 and https://github.com/containerd/containerd/pull/8720.


Fixed ID tag name in AD test

Signed-off-by: Amit Galitzky<EMAIL_ADDRESS>Description
Changed data-test-subj tag for 'Redirect to create detector' test to correct ID tag that is used in AD dashboards-plugin
Check List

[x] Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

https://github.com/opensearch-project/opensearch-dashboards-functional-test/runs/5427453854?check_suite_focus=true
AD all passed!

Great work!
Will #95 help mitigate such issue?

Yes that PR should have the most up to date ID tags with any new or old tests.


nothing changed at all

i installed the theme in kali linux 2023.1 but when i rebooted the machine , the grub theme still the same
any help ??  , thanks in advance

idem XD


Increase Layout cache size

When we reimplemented the cache to not grow infinitely we chose an arbitrarily small size of 16. This is too small.
https://github.com/ratatui-org/ratatui/blob/11e4f6a0ba71b7adad44af5866a2b0789175aafa/src/layout/layout.rs#L104
The cache helps apps have stable user interfaces when the layout is provided with constraints that could be satisfied multiple ways.
We should bump this up about an order of magnitude (and measure the memory impact of it - it's likely small)

For reference, on my machine, the flex example starts at about 1.4MB, a cache of 9800 fully grown makes it go to 3.5MB.
That's ~2.3 times the initial memory, but this is a ridiculous value and in general not that much memory.
Concerning by how much we should increase the value I'd go for 32ish. flex and  constraints run about fine with 100 and there are ridiculous/overcomplicated layouts.
I want to go more in depth on this and check out some projects to see how much layout to they use.

It would be good to add some sort of metric around the cache size and hits. Possibly just logged using the tracing library, but perhaps worth investigating https://docs.rs/metrics/0.22.0/metrics/

9800

that's also about how many cells I have on my terminal screen. I suspect a good ballpark figure to use is Rows + Columns, not Rows * Columns. This allows for a layout to be specified for every row and column of the screen (which is likely rare, but may become more common if we start moving to using layout for e.g. each row of a table or similar.
So that's 171+51 = 222 for my laptop so why not make this arbitrarily double that amount and a bit more (500)?


discussion: next elephant in the room: auto-update checks

I want to enable auto-update checking - ie checking only - for both application and extensions. I understand we're all big girls here and by our very nature know all about manually updating and we never miss out because we're all firefox nerds, well done us. I am thinking of the bigger picture - namely, everyone including newbies and people who can't read.
There is nothing I can think of that hurts privacy or security by auto-checking - in fact, by it's very nature, it can help increase it - i.e up to date software and all that brings eg exploit fixes etc. It's absolutely nothing in terms of traffic.
I expect fighting and bitching in the comments, and people arguing (I have popcorn). That said, you have to convince ME to not do this if you are dead set against it. Have fun :)

Enabling auto-update checking (checking only) is what I've always done in my own instance of user.js. I see no downside for me because I believe that beyond a certain threshold, keeping the browser from communicating with Mozilla starts to tip the balance against security, with no appreciable gain in privacy (ie. there may already be a record of your browser instance installing the extension in the first place)
I do disable internet access from the background installer service since the update process goes just fine without it (post download, during install) but that probably goes beyond what user.js can do.

user.js can disable background installer - see 0301b
/* 0301b: disable background update service
 * [SETTING] Options>Advanced>Update>Use a background service to install updates ***/
user_pref("app.update.service.enabled", false);

@Thorin-Oakenpants  Thanks. I'm aware of this. I use the installer (couldn't think of a reason not to -- wonder whether you have one); I just cutoff that executable from the internet using my firewall rules.

I have this, first for my folks, but then I gave up and start using it too:
/* 0301a */ user_pref("app.update.enabled", true);
/* 0304  */ user_pref("extensions.update.enabled", true);
/* 0305  */ user_pref("extensions.update.autoUpdateDefault", true)
So... auto update for extensions and check only for FF with notification.
Check only for FF to avoid a sudden restart after update, but didn't test it doe.

I expect fighting and bitching in the comments, and people arguing (I have popcorn)

Came here looking for some bitches fighting but instead everyone's hugging and kissing. lamest. fight. ever.

Note to self: fix title (remove part 1 wording, maybe a better title) and edit description.

So, a quick question (since I do not have it on at all, and am up to date).

App (FF application) update check - how does it let you know? Does it pop up a message of some sort? Or is it just displayed on the about firefox dialog (which can be done anyway by clicking "check for updates"). In other words, this is almost useless (with not auto-applying said update) if it doesn't directly inform the end-user IMO.

It pops-up a window informing there is new version. You can choose to do it now or later.

Sweeet. And if you choose "later" does it ever ask again - eg is it session only and a new FF start re-informs you? Not that it really matters - I guess I can find out myself after I apply the commit, but feel free to answer : )

IDK, didn't payed attention, but I am almost 100% sure it asks every time FF is started. So, it does not nag you all the time.
Will pay more attention in future.

Installed just now FF 52.0,2, and will see what happens... but it didn't ask me when FF started.
Will report back ASAP I will know more.

OK... FF asked me a few minutes after the start... see screenshot
I have choose later... FF does not ask me after restart, it looks like "later" sets some timeout value.

hi guys! - excellent job all around
personally i think checking for updates is fine as long as we can be assured that it is only checking
the only little niggle i might have is whether the update mechanism also downloads the update(s) in the background (without applying them)? i don't know the answer to that

app.update.interval = default 43200 = 12 minutes I guess - this will just be the checking period, not how often it would inform you
app.update.promptWaitTime;691200 = 192hrs ? = 8 days => I guess this is the timer setting if you click "later" ... should we wait 8 days and see if crssi gets another reminder? heh :)
I don't think we need to change any intervals. 8 days seems reasonable to not be an annoyance. Will probably do a review patch tomorrow. Auto-update checks will become inactive but still be set as "quieting" FF if used, in keeping with the section. It will involve some renumbering and re-ordering of the 0301-0307 numbers
@atomGit - no DLs take place, it is only a check

GJ... but I think 8 days is long time... user will click twice later and there we go with 16 days.
Some upgrades are because of security and I think 1 day should be much better... I would set even shorter.

Actually I would propose to set app.update.promptWaitTime = 14400 = 4hrs.
Its not every 5 min to nag, but often enough to remember user.
The major version update should not be the problem, but minor are often for a security reason.

Hi, there is a single minor problem with app.update.enabled = true: if you are using an ESR release, even up-to-date, the page stating your browser is out of date will still be shown (this is obviously wrong and should be reported to Mozilla). I have experienced this problem with Firefox 45 ESR on Debian.
Another thing to note is that it may be pointless to show this page on Linux installations, since software upgrades/upgrade notifications are usually managed at the OS package management level (unless you installed Firefox manually from a zip)

Another thing to note is that it may be pointless to show this page on Linux installations, since software upgrades/upgrade notifications are usually managed at the OS package management level ...

that's true for FF when installed from the repo, as you said, but not for extensions - good point though - seems like app update and add-on update should have different default settings on Linux where it should only check for extension updates

I think it's probably best to leave it as is, due to the problems mentioned.
For 0301b: disable background update service afaik you need to have installed the optional maintenance service and that service is Windows-only (app.update.service.enabled)
Having everything disabled also prevents the system addons from being installed/updated.

disable background update service - it's actively disabled (but will add a [WINDOWS] tag). I'm only talking about making the two checks inactive (not forcing them, just encouraging default checking). i.e, as it has been since it was added, it helps those with the service, it has no affect on those without the service, and causes zero harm on non windows systems
system addons - having the browser check for updates (which is not being forced here) for itself and add-ons has nothing to do with system addon's being bundled with the actual update package
linux issues re installed vs OS package management (plus ESR annoying update bug when actually up to date) - making the two update check prefs inactive does not affect default linux prefs. The ESR users need to bitch at Mozilla to fix the update error, and linux distros should auto fix update checks themselves - ie you install it the pref should be true, you unpack it the pref shoudl be false. This change of not forcing a value in this user.js should actually be better for Linux users.
roxkilly mentioned mozilla having info on your extensions etc - just to add to that: but when you do a manual check, they get that anyway. The only way around it would be to manually download and install each xpi every time (on a different ip maybe?). At some stage you have to trust mozilla - personally I trust them to probably use this info if they do collect it, to be aggregated and anonymized (not that they know who I am) and this bit of telemetry I do not begrudge, as it can be used to help the add-on ecosystem

first draft (had to rope in all the way to 0308 due to re-numbering)
/*** 0300: QUIET FOX
     It is important to do updates for security reasons. If you don't auto-CHECK for updates,
     make sure you do so manually. We choose not to enforce disabling auto-CHECKS (0301a+0301b).
     There are many legitimate reasons to turn off auto-UPDATES, including hijacked or
     monetized extensions, time constraints, legacy issues, and fear of breakage/bugs ***/
user_pref("ghacks_user.js.parrot", "0300 syntax error: the parrot's not pinin' for the fjords!");
/* 0301a: disable auto-update checks for Firefox
 * [NOTE} Firefox currently checks every 12 minutes and allows 8 day dismissals
 * [SETTING] Options>Advanced>Update>Never check for updates ***/
   // user_pref("app.update.enabled", false);
/* 0301b: disable auto-update checks for add-ons ***/
   // user_pref("extensions.update.enabled", false);
/* 0302a: disable Firefox auto update installing (after the check in 0301a)
 * [SETTING] Options>Advanced>Update>Check for updates but let you choose whether to install them
 * [NOTE] The UI checkbox also controls the behavior for checking, the pref only controls auto installing ***/
user_pref("app.update.auto", false);
/* 0302b: disable add-ons auto update installing (after the check in 0301b)
 * [SETTING] about:addons>Extensions>Settings[cog wheel]>Update Addons Automatically (toggle) ***/
user_pref("extensions.update.autoUpdateDefault", false);
/* 0303: disable search update
 * [SETTING] Options>Advanced>Update>Automatically update: Search Engines ***/
user_pref("browser.search.update", false);
/* 0304: disable background update service [WINDOWS]
 * [SETTING] Options>Advanced>Update>Use a background service to install updates ***/
user_pref("app.update.service.enabled", false);
/* 0305: disable background update staging ***/
user_pref("app.update.staging.enabled", false);
/* 0306: enforce update information is displayed
 * This is the update available, downloaded, error and success information ***/
user_pref("app.update.silent", false);
/* 0307: disable add-on metadata updating
 * sends daily pings to Mozilla about extensions and recent startups ***/
user_pref("extensions.getAddons.cache.enabled", false);
/* 0308: disable auto updating of personas (themes) ***/
user_pref("lightweightThemes.update.enabled", false);

system addons - having the browser check for updates (which is not being forced here) for itself and add-ons has nothing to do with system addon's being bundled with the actual update package

What I meant was this

if the automatic update setting is set to "Check for updates, but let me choose whether to install them", it doesn't look like it will ever look for system addon updates at all, much less ask to install them.
When changed to "Automatically install updates", it did successfully grab the HSTS addon from aus5.mozilla.org and toggle the prefs as intended.

line in readme section

Shouldn't that be (section 0302s) instead of (section 0301s)?
} Firefox currently checks every 12 minutes - wrong bracket and where did you get the 12 minutes?
app.update.interval;43200 is in seconds and that's 12 hours, right? 12 minutes would be nuts.
I like the rest of your draft. I was thinking to maybe make subgroups for App updates and Extensions, Search Engines and Themes updates but your 0301 + 0302 is pretty nice too. Maybe 0303 would be better towards the end, after the remaining 3 app.update.* prefs and 0307.
Also very nice that you were able to keep the description about the potential risks in the main description of 0300 - it's indeed the auto-INSTALLS that are the problem, not the checks. :thumbsup:

Addons follow /* 0302b while Plugins have their own 'Check to see if your plugins are up to date' link on top of Addons Manager > Plugins.
The Gear button on top is for addons only. I did a 'Check for Updates' and the Available Updates are addons.
Talking about system addons instead of plugins may lead to miscomprehensions.

Did I read it wrongly on the bugzilla link?

Idk, I still don't understand what you're saying. I quoted from a bugzilla that talks about system addons not updating, and that has nothing to do with plugins. No plugins are bundled with FF afaik, they are downloaded to the profile if that's not disabled.

where did you get the 12 minutes

From my earlier comment where I said minutes not hours (now corrected), had the right pref

line in readme section - Shouldn't that be (section 0302s) instead of (section 0301s)?

Yup, corrected

@Atavic wrote

I do not know what they are referring as sytem addons there.

see here. Most of those change one or more pref values between FF's major releases. If app.update.* stuff is fully disabled then those system addons also won't get installed

TBH, my browser has been open for over 24 hrs and not a single addon has an update notification. They are all set to "default" . The default is to not "auto-update", but the settings are as per the js - i.e checking should be happening. As soon as I manually checked for updates, I had 4. So something is not quite right.

Ooh ... not sure what the period is for checking addons for updates .. but it finally auto-happened, only took 2 days.. I should have been more patient


Feature/shooter

Codecov Report

:exclamation: No coverage uploaded for pull request base (develop@c28a91d). Click here to learn what that means.
The diff coverage is 0%.

@@            Coverage Diff            @@
##             develop     #73   +/-   ##
=========================================
  Coverage           ?   5.06%
  Complexity         ?       6
=========================================
  Files              ?       8
  Lines              ?     237
  Branches           ?      12
=========================================
  Hits               ?      12
  Misses             ?     225
  Partials           ?       0

Impacted Files
Coverage Δ
Complexity Δ

src/main/java/org/usfirst/frc/team4828/Robot.java
0% <ø> (ø)
0 <ø> (?)

src/main/java/org/usfirst/frc/team4828/Ports.java
0% <ø> (ø)
0 <ø> (?)

...rc/main/java/org/usfirst/frc/team4828/Shooter.java
0% <ø> (ø)
0 <ø> (?)

...main/java/org/usfirst/frc/team4828/ServoGroup.java
0% <ø> (ø)
0 <ø> (?)

Continue to review full report at Codecov.

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


🔨  Implement script to deploy the contracts

Closes #119
I made it in js, I think it will be easier to make evolutions. I would like to avoid bash since it is very relying on tools prompt outputs and the smaller change from these tools could break everything.
I did not made it in typescript since I though it was a bit overkill for a script, but if it comes to be bigger we may want to change this.
Notes:

I had some issues to have an account and a RPC working with the latest starknet.js version.
I had to use starkli to deploy a fresh new account (cannot make it works with braavos or argentx accounts).
I had to use juno free RPCs for deploying the accounts with starkli
I had to use infura RPC for deploying contracts through starknet.js

Workload ~ 6h

@enitrat ready for review

I had to use starkli to deploy a fresh new account (cannot make it works with braavos or argentx accounts).

just fyi - it should work with Braavos accounts, but you need to instanciate them in StarknetJS with the "0" version

Done, thank you


Date localization in posts pages

In the Posts page, and in each post page, the date locale is always English (e.g. "November 11, 2018"). It should be possible to change it according to the current language.
I read the method in the tutorial https://gohugo.io/content-management/multilingual/#customize-dates but I don't see how to adapt to the posts pages.

Hi @wail-fajr-rd .
Thank you for report.
I'm sorry to hear reply late.
Please wait a little more until it fix:+1:


Add a SBOM template in CycloneDX format

Hi,
My name is Richard Hughes and I'm a developer at Red Hat. I'm the maintainer of fwupd and LVFS, and am trying to improve software supply chain security by encouraging OEMs, ODMs and IBVs to ship Software Bill of Materials with each firmware binary blob (SBOMs).
I'm working alongside lots of other companies proactively trying to do the right thing. The reason I've opened this pull request is because your project is either used in the build process of a firmware we care about (e.g. EDK II, or coreboot) or is built into the firmware binary itself. Although my personal focus is on firmware, the SBOM file is in CycloneDX format (one of the most popular industry standards) which makes it also useful when building containers or OS images too.
I would like to contribute this template SBOM file into your project that gets included into source control with substituted values that get populated automatically. I'm not super familiar with OpenSSL, and so I've done my best populating the project values -- but please point out any that are incorrect and I'll fix them up. I've also put the sbom.cdx.json file in what I feel is the right place, but please say if you want me to put it somewhere different or name it a different thing; the directory and sbom prefix are unimportant.
The various firmware build tools will take these incomplete SBOM files and then build them into a complete composite SBOM to represent the firmware. Having an upstream reference to what the PURL and CPE values should be means we have something we can trust; I could quite easily spin up a web-service that we say "what CPE do we use for X" -> "cpe:2.3:a:Y:Z::::::::` but we don't actually know if that's still true, up to date, or what the maintainer actually wants them to be. Putting the template upstream means we can trust the values we find in the checked out code during the build process.
Also, if you’re not happy with being labelled a supplier (which seems more appropriate from a SBOM point of view, but makes some open source maintainers uncomfortable) we can remove that bit.
I've written a bit more about this proposal here https://blogs.gnome.org/hughsie/2024/11/14/firmware-sboms-for-open-source-projects/ and there's also lot more information about firmware SBOMs here: https://lvfs.readthedocs.io/en/latest/sbom.html – many thanks for your time and all the work that you do.

I've just asked my manager to approve me signing the ICLA, so hopefully "paperwork" incoming soon.

I'd say this should end up in doc/ rather than the source root

I'd say this should end up in doc/ rather than the source root

Moved, PR updated -- thanks.

CLA signed, so doing the open and close dance.

This PR is in a state where it requires action by @openssl/committers but the last update was 30 days ago


Automatic Gas rewrite for unstable branch

Rewrite of the changes in Web3+MutatingTransaction from PR #547  for the unstable branch. Promises have been replaced with Async/Await

It have failed the Carthage building.

It have failed the Carthage building.

Yes, that's because it was dependent on your merge from develop to bring in the updates to the tests.

I see what's going on... it's having ambiguity with BigUInt did the freeze on CryptoSwift get removed?

Looks like even the rebase won't fix the issue. Not sure why Carthage wants to use 1.5.0 when it's not the latest, and it's not what is in the resolved file

Actually we didn't froze it on Carthage. I'll fix that with next bug fix

even if not frozen, then it should be trying to pull 1.5.1 then, which has the issue fixed.


The file type ".uf2" of saved program is not same with the the file type ".hex" of "import File"

Repro steps:
• Navigate to https://makecode.adafruit.com/
• drag the block "show ring" under "LIGHT" and put it under the loop "forever"
• input the name "test" to save this program, it will display the file type of saved program, the type is ".uf2"
• click "PROJECT" and select the function "import File", it writes "select a .hex file to open"
Expected result:
1.the file types should be same
2. the saved file name should be "test"
Actual result:
1.the file types are not same
2. the saved file name is "circuitplayground-test"

We need to add a case here for UF2:
https://github.com/Microsoft/pxt/blob/master/webapp/src/app.tsx#L1164

Fixed in #2397


ZK Primitives

This issue is meant to describe a series of primitives in Pact needed for working generally with zero knowledge (ZK) proofs. The requirements are broken up into two sections: general elliptic curve (EC) arithmetic (initially over bn128), and the backend support for proof verification as provided by a third party API.
Motivation
The rationale for inclusion here follows roughly the rationale described in the following Ethereum EIP's:

https://github.com/ethereum/EIPs/blob/master/EIPS/eip-196.md
https://github.com/ethereum/EIPs/blob/master/EIPS/eip-197.md

As Kadena scales up its work with L2 proof systems like Electron Labs, we'll need to support general EC arithmetic computations, as well as support L2 verification systems as a backend hook in the Pact language.
ECC Arithmetic
The following functions need to be added in order to support pairing curves:

addition
(scalar) multiplication
negation
pairing

Initially, we want to support the bn128 pairing curve, but in the future we may want to extend this for other backends that require other curves.
Backend Support
In the vein of the SPV support provided in Pact for the Kadena Mainnet chain, Pact needs to have a similar capability exposed for verifying L2 proofs provided as an entry in any cont msg. The backend support should be as follows:

A new pact native, called verify-zk, which provides a hook for Pact integrations to implement and provide L2 proof verification support.
Additions to the cont msg format with an entry called zkProof which can be optionally supplied through API request metadata and run through the backend support.

In the vein of the SPV support provided in Pact for the Kadena Mainnet chain, Pact needs to have a similar capability exposed for verifying L2 proofs provided as an entry in any cont msg.

Additions to the cont msg format with an entry called zkProof which can be optionally supplied through API request metadata and run through the backend support.

Is this functionality only supposed to work with defpacts?

I'm confused by the cont support. In crosschain Pact this is needed because defpacts start on one chain and end on another, meaning there needs to be baked-in SPV support. However with L2 there is no need for the external oracle. Or is this to support starting an L2 on one chain and completing it on another?

Addressed by #1052


chore: fix trivy workflow by using mcr image instead

What type of PR is this?
/kind cleanup

What this PR does / why we need it:
Fix trivy workflow failure due to ghcr throttling.
2024-10-28T23:06:23Z	ERROR	[vulndb] Failed to download artifact	repo="ghcr.io/aquasecurity/trivy-db:2" err="OCI repository error: 1 error occurred:\n\t* GET https://ghcr.io/v2/aquasecurity/trivy-db/manifests/2: TOOMANYREQUESTS: retry-after: 849.127µs, allowed: 44000/minute\n\n"
2024-10-28T23:06:23Z	FATAL	Fatal error	init error: DB error: failed to download vulnerability DB: OCI artifact error: failed to download vulnerability DB: failed to download artifact from any source

Which issue(s) this PR fixes:

Fixes #
Special notes for your reviewer

coverage: 80.775%. remained the same
when pulling 910403bd41e11f3bd0ad460f0c8f10691b42f36d on jwtty:jwtty/fix-trivy
into 35aa30858eb1a322ce4576e645a8d64388e6c04a on Azure:main.


signer_last_* not present in all signers

With the last 3.2.2 version signer_last_* are not present in all signers
LEADER
signer01:~# curl -sS  localhost:6021/metrics  | grep signer_last | grep -v "# "
signer01:~#

OTHER
signer02:~# curl -sS  localhost:6021/metrics | grep "signer_last_" | grep -v "# "
signer_last_precommit_height{chain_id="meme-1"} 8.814679e+06
signer_last_precommit_round{chain_id="meme-1"} 0
signer_last_prevote_height{chain_id="meme-1"} 8.814679e+06
signer_last_prevote_round{chain_id="meme-1"} 0
signer_last_proposal_height{chain_id="meme-1"} 8.814676e+06
signer_last_proposal_round{chain_id="meme-1"} 0

OTHER
signer03:~# curl -sS  localhost:6021/metrics | grep "signer_last_" | grep -v "# "
signer03:~#

VERSIONS
horcrux-test version
{
  "version": "3.2.2",
  "commit": "4fe383e7310f12aa3b2bd4365d37c048419b3912",
  "go_version": "go1.21.4 linux/amd64",
  "cosmos_sdk_version": "v0.50.1",
  "cometbft_version": "v0.38.0"
}

Update:
This is a test environment and I'm only using 1 sentry with 3 signers.
Apparently (compared to previous versions) only a signer per sentry will get this data.
Not the leader, but whoever connects first to the sentry.
Was this change wanted?
Thanks


Discussion: Compilation Albums

I might be in over my head, but I think the solution for compilation has been somewhat over complicated.
[please correct me if I'm wrong]
Original implementation
We record artist info at the album level, which presented an issue when it came to compilation albums as it would separate the song into multiple albums, this was caused by albums being depended on Artists artist->album->song
Current solution
We always ignore song artist and simply store that at the album level We use the albumArtist tag to determine if a song is part of compilation album.
If it is part of a compilation we record the artist on the song level as contributing_artist and on the album level we set it to various artists.
We present the album in the following manner.
In the Artist view
contributing_artist->album, Issue is, songs are still being separated.
In the Album view
variousArtists->album.
The issue is that the album is still not being presented in the artist section, and even if we were to implement in the Artist view variousArtist->album it still would not be listed under the albumArtist.
Suggested solution

We always record on the song level the contributing_artist, every song has one.
We also record the albumArtist on the song level, and if a albumArtist is not present we set it to the contributing_artist.
we continue recording if a song is part of a compilation as we do now,

In the views we will present them as follows.
In the Artist view
albumArtist->albums, a possible issue might be if a album has songs with different albumArtist [have yet to see one myself], in that case we still have the compilation column and if is_compilation we then do variousArtits->album.
In the Album view
albumArtist->album
Of course on the song item we display the contributing_artist.

In conclusion, I think there are ways of solving compilation albums while removing much of the complexity that there seems to be around it.

Thanks for the proposal. You're absolutely right, the "compilation albums" feature is buggy and over complicated, admittedly due to my short sight at the beginning of the project. Solving the problem from scratch (like what you proposed above, even though I'd need some time to wrap my head around it), though, is not the biggest issue; keeping the migration path simple and straightforward is. The more changes we introduced into the data structure, the less smooth migration becomes.
With that said, the proposal looks promising. I'll spend the next couple of days to think about it when I have time. Thanks again for the contribution 👍

Let's take an example here, with a virtual album Classical music with 2 songs (Vivaldi - Summer, Mozart - Requiem). The usual tags you'll find in the files are: album which will be set to Classical Music and artist (one will be Vivaldi and the other Mozart).
Currently, it shows twice in the album list because there are 2 different artists (each containing a single song)
In your proposal, what would be the albumArtist ?
In the artist view, should it list under Mozart and Vivaldi or only under Various Artists ?

In your proposal, what would be the albumArtist?

Well, that depends on what the albumArtist tag is, see example below where the there are different artists for each song but the same albumArtist

However, in your case a virtual album I wouldnt expect there to be a albumArtist so it will be presented under variousArtists.
You do bring up a valid point that I forgot to mention,

should it be listed twice under Mozart and Vivaldi

As I said this would be listed under variousArtists, but, what if someone wants to play all the music by Mozart? why should the particular song not be part of the play list?
So, personally I'm open to the idea that any given song should always be displayed under the contributing_artist even if its already listed under the albumArtist.
Explanation
As I wrote above in the artist view we would present albumArtist->album wich mean that it will be listed only under variousArtits.
What we could do in addition to that is, that once we click on an artist, technically speaking its an artistID, so in addition to "grouping" all the albums that the artistId is the albumArtist for, we also list any songs that ArtistID is the contributing_artist`.
With that, in your case, it will be listed under VariousArtists, but if you click on Mozart it will be listed there as well under the Album Classical music.

I'm not sure I've my song tagged with albumArtist or contributingArtistbut simply artist and album, and I think I'm unlikely to retag all of them like this. Thus, I don't understand how the scheme you are proposing would work.

artist and contributingArtist are the same, you can use a tag editor software to see if you have any additional tags on the song.
You can use something like MP3TAG.

Ok, I didn't know about it.
But for album ?  If I have an album for an artist, albumArtist will not be set (album will). I don't want all my albums been located under "Various Artist".

We also record the albumArtist on the song level, and if a albumArtist is not present we set it to the contributing_artist.

I don't think we need to set albumArtist at the song level, as we can always refer to $song->album->artist_id. In other words, if I get it right, the new solution has one critical difference: contributing_artist_id is always present, and refers to the real performing artist. With this, we can always rely on this column for artist information, and album_id for album information.

Migration should also be straightforward if this is the case. @bdgold can you confirm my understanding?

@phanan consider the following 2 scenarios.

Having an album that each song has a different contributing_artist but no albumArtist is present.
Having an album that has conflicting albumArtist's between the songs.

My thought was that if we record albumArtist on the song level we would be able to detect them and place the Album under variousArtist's in the view.

@phanan I see that you included Genre, could https://github.com/phanan/koel/pull/318 be considered again? especially Year.

@bdgold There shouldn't be the case of one album with different album artists. That just doesn't make sense, and Koel's parser will create multiple albums instead.

I agree that even if it would, its a failure on the users side, I was just thinking of the "what if".
What about the other scenario?

For the other scenario, we have a default "Various Artists" as the album artist, no?

Ah, Correct.

If a song as the same album tag as some other song but a different contributing_artist, then can the album be marked as a compilation automatically ?
Said differently, is it correct to consider the album name as a unique key to an album id ?
I've numerous compilations where the songs don't have the compilation or part_of_compilation tag, and it's a pain to select all the songs in the GUI to click the "is a compilation" checkbox each time I'm syncing the library.

I'm asking this, because I could not figure out what way is proper.
Currently, if you have songs like this:

Title:One Artist:Bob Compilation:1 Album:Live 2014 Path: /path/to/Festival/Live 2014/One.mp3

Title:Two Artist:Alice Compilation:1 Album:Live 2014 Path: /path/to/Festival/Live 2014/Two.mp3
...

Title:Another Artist:John Compilation:1 Album:Live 2014 Path: /path/to/John/Live 2014/John - Another.mp3

Title:Brick Artist:John Compilation:1 Album:Live 2014 Path: /path/to/John/Live 2014/John - Brick.mp3

Title:In ft B and John Artist:B Compilation:1 Album:Live 2014 Path: /path/to/John/Live 2014/John - In feat B.mp3

Koel will merge them in a single compilation album with "Various Artist" (which is correct for the 2 first songs, but not the 3 last songs) because compilation tag is set for all of them (cf. line 57 of Album.php).
So, it acts exactly like if album tag was a key to the album table (artist_id will be set to VARIOUS_ID by compilation tag presence).
In that case, why not mark all of them as compilation as soon as an album is the same and artist is different ?
Also, for example for The Pink Floyd, you've numerous album with the same name, they are not a compilation, only the year changes between them (and the year is ignored, AFAIK). Koel will merge all songs in a single album.

Or, would the current folder be used to distinguish them, like so (pseudo code):
$artist = Artist::get($info['artist']);

// Check if the current song is part of a compilation
$album = Album::getFromAlbumName($info['album']);
$albumArtist = Album::getArtistFromAlbumName($info['album']);
if ($album->getIsCompilationAttribute())
    $isCompilation = true;
else if ($albumArtist != $artist && $this->isInSameFolder($album, $albumArtist)) {
    $album->setArtistId(Album::VARIOUS_ID); // Make the previous song a compilation too
    $isCompilation = true;
}
// Ok, then add the album or fetch it from DB
$album = Album::get($artist, $info['album'], $isCompilation);

Generally I don't like the idea of using the folder structure to determine organization, but maybe we should implement something for compilation albums.

See PR #414 for an implementation that does that. It's yet to include the changes @phanan proposed 3 days ago for fixing the model too.

@X-Ryl669 in regards to #414 I agree with @phanan that we should not rely on the folder structure.
Although that it would be lumped into variousArtits the individual songs will still be listed under the contributing_artist, the only thing that I see as an issue is that in the album view they will be lumped into one album and probably have duplicate tack numbers.
having sad that, maybe there is a way that we could use the track number to figure out that there are 2 separate albums, I'm not sure though how it would work or be implemented, let me know what you guys think.

I'm not sure I'm getting it. Can you give an example here ?

Can you give an example here ?

for which part?

@bdgold As far as the tracks being lumped into one album, would adding the metadata for album year fix this issue? I've run into an issue where I have 2 releases of an album (ex: Pink Floyd's The Wall (1979) and The Wall Box Set (2011)) where unless the album year is a subsort on the listing, they are listed as track 1, track 1, track 2, track 2.
I have already done the work, it just needs to be agreed upon that it is a useful piece of metadata: https://github.com/phanan/koel/pull/318

That will work when you have 2 albums from 2 separate years, but in his case they are from same year. Using track numbers will us at the least determine that there is something weird, maybe we can introduce a section to resolve conflicts.

Just my 2 cents, but if you only expect to discriminate a song based on its metadata (and not its folder information), then you must support all metadata (and not only some of them) as a unique key to identify a song. Else, you'll have duplicate and you can't tell which is which (example: Pink Floyd from @alex-phillips).
Also, because it's not convenient to have a folder full of tens of thousands of files, I think most people use folder structure to sort their files (and the OS is encouraging to do so, having 40000 files in a folder takes forever to browse in a file explorer etc...), so ignoring this fact is simply
burying our heads in the sand stupidly. I'm not saying it should be the rule, but I'm saying (like I did in the #414) that in case of conflicts, the file hierarchy is precious and use it to solve it. If you store all your file in a single folder, well, it does not break, you can't tell which is which. But if you do use some hierarchy, then Koel'll be able to sort this out by itself.
The issue with using all metadata comes from the fact that some tags are not clearly defined about what they do/are for, and many song have a different philosophy about what to store in them (if they even store something in them), and this creates conflict (see for example, the albumartist that's set equal to the artist for each song of an album), some tags are missing (like the track number for some songs etc...)
Anyway, why would it have duplicate track number ?
What would be the most convenient way to see the track ? Via the "Various Artist" (is it where you would expect the song ?), or in the original album (and the contributing_artist) only ?
I would prefer the last case.
In that case, when listing the album, you could filter by song id (since there's only a single song in this case), by preferring showing the original contibutingArtist other the Various Artist
All begin because "artist has one or more album has one or more song" is not always true.
In case of complete changes, then I think the relation "song is in album" and "song is from one or more artist" is the only version that's always true.
So the database should say:

song : has an id, album_id, title, path, + the rest
artist: has an id, song_id, name, + the rest, the primary key being the pair idand song_id
album: has an id, name, year + the rest

When listing by songs, it's easy to join the query and have both the artist + album + song for each song.
When listing by albums, just select the song based on the album id, and join the query to get the artist for each song_id.
When listing by artists, just join the songs based on song_id, and join the query on the album_id for each song found.
A compilation is defined when the number of artists for songs with the same album id is greater than one (no need to have a column in DB for this, you can deduce it).

Using meta data is not discrimination, its the quite opposite, it allows the song to speak for itself, using the folder structure, is essentially allowing an outsiders influence.
We are planning to bring in more meta data, we just need to figure out which ones are useful, too much is sometimes just too much.
In regards to the folder structure, I understand both sides of the coin, maybe we could compromise and use the .env to enable or disable the feature.

Anyway, why would it have duplicate track number ?

You misunderstood that part I believe, I'm referring too the track number, meaning, if Koel thinks that 2 albums are 1 album, the album will end up having to track #1 and so forth, we could use that to tell us that there are 2 live albums in your case.
The entire last part you wrote I simply don't understand, can you try to clarify more?

if Koel thinks that 2 albums are 1 album, the album will end up having to track #1 and so forth, we could use that to tell us that there are 2 live albums in your case.

This problem shall not happen if you use the complete set of metadata instead of a fewer one (like alex's said). If you ignore a single tag that's present in a file, then you'll end up with conflicts and Koel will think songs are similar.
Using the tracknumber will not cut it, since you could have the 2 songs with the same title, tracknumber, album, artist but different discyear. The only way to solve this is not to ignore any tag in the initial file and use all of them for identifying a song.
The last part of my last comment says that currently, Koel's song sorting algorithms expects this relation artist>album>song. This is wrong IMHO, and it's probably the cause for all the mismatch and misorder in the album view.
Because compilation album with different artists exists, because songs with different artists exists, the relation is bad.
It should be split in 2 distinct relations, song are part of album and artist participated in song.
Then you can explain all cases from the basic artist > albums > songs, to more complex compilation album with many songs of different artists.
The database format thus should be changed to reflect this, and I wrote how I would do it if I had to do it.
With such a structure, it would also imply that the /api/data is modified to have 3 main keys (instead of a single one), starting from songs, albums and artists, and remove all the clunky sorting JS code that tries to build album/artist from a list of songs. The sorting would be done by the database with 3 complex queries (that could be cached since the media library does not change often, so it'll even be faster to boot the JS code) I've described. The JS code would then follow the "songs" key of the data when browsing by songs, the "albums" key with browsing by albums, and "artists" key when browsing by artists.
I did the same think in my fork for folders (except that I created a new route for it that's only fetched on first access, instead of when loading the page), and I think it's clean. You don't pay the cost of downloading the folder structure if you don't use it. The same could be done for albums, artists, genres ?, .... Only the songs must be downloaded once to be refered by UID by other structures.
Please notice that I'm not duplicating the data, since they refer to each other by uid, I'm just writing down the relations between element in the JSON object sent (instead of a big 1D list you need to re-parse in JS to figure out the relation between elements, I'm storing the relation in the JSON object and refer to songs by ID).

This problem shall not happen if you use the complete set of metadata instead of a fewer one (like alex's said). If you ignore a single tag that's present in a file, then you'll end up with conflicts and Koel will think songs are similar.

Having all tags does not help us if we don't use it, so the question remains, what tags are helpful? we know that year is, hopefully that will be implemented.
An important note is, that even the year tag could just mean that its a compilation of one artists greatest hits, so even here the logic needs to be worked out. Update Actually since its all the same artist it should never be detected as a compilation and therefore not use the year tag.
In regards to redesigning the DB, I'm not a super admin when it comes to it, so I will leave it for @phanan and the others to look at, but I can tell you that we would want the migration process to be simple and work, so take that into account with any proposals.
I hope we can all agree on some things soon and get them implemented, we don't need to fix it all immediately but rather come to agreements, implement, then work on the next thing, and we will ultimately get there.
I will try to compile a summary of all that we discussed, so that we can wrap our heads around all of it.

The proposal has been implemented on master branch. @YakovGoldberger if you have time, can you take a look and see if it works according to our discussion? Thanks!

@phanan yes, will take me though a couple of days, I'll keep you posted.
Thank you.

@phanan did anything change in the DB? Do i need to run php artisan migrate?

Yes, there are a couple of db changes. Please make a backup before
proceeding.
On Mon, May 8, 2017 at 00:51 YakovGoldberger<EMAIL_ADDRESS>wrote:

@phanan https://github.com/phanan did anything change in the DB? Do i
need to run php artisan migrate?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/phanan/koel/issues/403#issuecomment-299722575, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AHrt0rzmMupL2SLu05VD67cXZ5KrvC7wks5r3gSlgaJpZM4Jhvd1
.

The upgrade commands would be
git fetch
git checkout master
composer install
php artisan koel:init

Hmm,
@phanan there doesn't seem to be any change, I also tried a test version with a new database, no change.

No change is a good thing, it means functionality wise the app is still OK.
On Fri, May 19, 2017 at 22:38 YakovGoldberger<EMAIL_ADDRESS>wrote:

Hmm,
@phanan https://github.com/phanan there doesn't seem to be any change,
I also tried a test version with a new database, no change.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/phanan/koel/issues/403#issuecomment-302737032, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AHrt0gfwVkyZpZz-NW_Lpj2qR4hr4o6Kks5r7beFgaJpZM4Jhvd1
.

True :+1:


formatting on console.log of look logging

need space after moment().format() timestamp before colon and padEnd(30)
2017-06-27 23:53:21 : patrick                        !stat mantooth
2017-06-28 00:19:25: eddiejerky                     Logged 'Tterror'
2017-06-28 00:30:29 : normstorm                      !who Tterror

Believe already fixed in ParseEqLook, need to validate before closing
                      hands,shield,about,waist,pouch,rwrist,lwrist,primary,secondary,held,both,pSubmitter,null, (arg) => {
                      console.log(`${moment().format(MYSQL_DATETIME_FORMAT)} : ${pSubmitter.padEnd(30)} Logged '${arg}'`);
                    });```

addressed in 533c13f


Datetime Common

Tasks

Create a Common called Datetime.
Do the datetime formatting inside a method called get_value which should return the datetime passed to Datetime __init__  method.
Use the Datetime common inside SensorsRecord entity __post_init_ method like:

@dataclass
class SensorsRecord(Entity):
    soil_humidity: int = None
    ambient_humidity: int = None
    temperature: int = None
    water_volume: int = None
    created_at: Datetime = None

   def __post_init__(self) -> None:

        if self.created_at is not None:
            datetime = Datetime(self.created_at)
            self.created_at = datetime.get_value()

but why do this if it can be done by simply formated by doing date.strftime("%d-%m-%Y %H:%M:%S")

Because Datetime will be use for the checklist records too so you will need write date.strftime("%d-%m-%Y %H:%M:%S") only once


Buffered parse

Add parsing of iterators with the str::parse function.
Allows re-use of a datatype's FromStr implementation and easily changing the temporary buffer type so allocations can be done on the stack (no_std compatible) using ex. heapless::String or crate::buffered::StackString instead of naively using a std::string::String on the heap.

It might not be worth having StackString in the crate and instead linking to heapless and using that for the tests.

Changed. Now buffer has an associated type which is selected by the particular Tokens implementation. This allows re-using the buffer that StrTokens and SliceTokens have without having to copy anything. IterTokens has to copy because it doesn't already have an in-memory buffer, but it is parametrized over the user-decided buffer type when constructed.

Closed in favor of #13


Is backward pagination supported?

Hello!
First of all... this library is just awesome!! It simplifies a lot working with dynamo when it comes to one table design.
I'm new to dynamodb-onetable and I'm evaluating its use in my developments. So far, everything is almost covered. However I  haven't found in the documentation how to retrieve the previous page while paginating (it might be there though). I saw find results include a start property to help with next page management. After digging a bit into the code, I saw it maps to LastEvaluatedKey.
There are use cases in which backward navigation is quite useful (for instance when displaying live feed). Is there a straight API to do so within dynamodb-onetable? I guess I can get the first item of a collection and use it as ExclusiveStartKey; and then perform a query by negating the reverse flag (based on ScanIndexForward, this might require to reverse results). However, since the library hides key attributes. This add some extra logic.
It would be nice if the library could handle this scenario in the same fashion it handles forward pagination. Maybe find results could include a first property with the key attributes of the first item. That way is would be easy to paginate backwards:
let items: any = await User.find({accountId}, {limit: 10, start});

// Then, to get the previous page we could do:
await User.find({accountId}, {limit: 10, start: items.first, reverse: true}));

Would this make sense?

Thanks very much for your feedback and suggesions. Let me dig into this as this may be possible already. start indicates the key to being the query. reverse already supported sets the ScanIndexForward.  Are you saying this does not work, or are you saying you'd like to see reverse implemented?
Can I please ask why would the design need a first vs start if reverse is set to true which would indicated that the pagination should happen in reverse?  Is this just a bug or is the design lacking?

I believe the design is missing a feature.
Maybe I should have given an example.. here it is:
Assume you have a partition with 100 items. SK is composed somehow that the partition is sorted in ascending order, lets say:
item 1
item 2
item 3
.
.
.
item 100

It's clear to me that you can use start property to navigate forward -->

[item 1, item 2, ..., item 10]
[item 11, item 12, ..., item 20]
[item 21, item 22, ..., item 30]
and so forth.

Now imaging you are in page n and you want to get page n-1. You can't use start property here as it stores the key attributes of the last item in page n. You would need the first item's key attributes as LastEvaluatedKey, set ScanIndexForward to false, and finally reverse the returned list (otherwise results would be reversed --> [item n-1, item n-2, ..., item n-limit]).
ScanIndexForward: false can be easily set using dynamodb-onetable's reverse property. But I haven't seen any way to get first item's key attributes as easily as I can get last item's key attributes through the start property.
Similarly, imagine now the partition is sorted in descendent order (for instance using dates and you want more recent first). The partition would look like:
item 100
.
.
.
item 3
item 2
item 1

Now, iterate through this collection you would set reverse: true by default. That would give you pages like:

[item 1, item 2, ..., item 10]
[item 11, item 12, ..., item 20]
[item 21, item 22, ..., item 30]
and so forth.

Again, if you wanted page n-1, you would need page's first item's key properties, set reverse: false, and finally reverse the returned list.
So, summarizing, start property stores a page's last item's key properties which easy forward pagination. For backward pagination, the starting point isn't a page's last item's key properties, but a page's first item's key properties.
Am I missing anything? Can this be done and I haven't seen it?

Thanks for the extra detail -- appreciated, let me play around a bit and see what is possible.

Just completed a test.
See the sample below. We create 1000 users with the schema below. We simply set reverse to true and use start to mean the start point of the reverse scan.
export default {
    indexes: {
        primary: { hash: 'pk', sort: 'sk' },
    },
    models: {
        User: {
            pk:         { type: String, value: 'user#' },
            sk:         { type: String, value: 'user#${name}' },
            id:         { type: String, uuid: true },
            name:       { type: String, required: true },
        }
    }
}

You can scan backwards using start.
        await User.create({name: `user-${zpad(i, 4)}`})
    }
    let items = await User.scan()

    //  Scan forwards
    let start = null
    do {
        let items = await User.find({}, {limit: 100, start, reverse: true})
        print(`GOT ${items.length}`)
        start = items.start
    } while (start)

Thanks for the example @mobsense !
As far as I can tell, that will traverse the table in backward order. However that's not backward pagination. The example above always asks for the next page. Backward pagination means the ability to ask for the previous page, i.e. once you get page n, being able to get page n-1.
In your example, once you get page n, you always asks for page page n+1

I don't think so. Each find gets the page before the current page. So you are stepping backwards in pages. The items are in reverse order, but you can do an items.sort() to get each page in forward order if you need.
When you use a start that will be the starting key, and reverse will then get the items before that. That is the best dynamo can do I think.
Or am I missing something?

There are two different things here. On the one hand, you have the order: forward or backward. You can set that order using reverse flag (which directly maps to dynamo's ScanIndexForward property). This gives you the ability to traverse a collection in one direction or the other.
On the other hand, you have pagination, which can be forward (give me the next page), or backward (give me the previous page).
To ask for the next page, you set ExclusiveStartKey to the last item within the current page and you keep ScanIndexForward as it was. That means keep the same order and return items from the last one I know.
To ask for the previous page, you set ExclusiveStartKey to the first item within the current page, you flip ScanIndexForward and call response.Items.reverse(). That means traverse the collection in the opposite order as it was and return items from the first one I know. That will return the previous page in the wrong order, that's why you need the extra response.Items.reverse().
This pattern is specially useful when you feed an API. Your clients might not cache previous pages or content within the collection might be added to a previous page (live feed for instance). So, you must provide clients with a way to get previous pages.
For instance:

client app requests a page of users (GET /users). The backend does:

items = await User.find({}, {limit: 100});
return pageResponse(items);

which returns the list of items plus cursors to get the prev and next page. Something like:
{
   items,
   prev: "encoded string", // encodes the key attributes of the first item plus a flag, isBackward=true
   next: "encoded string", // encodes the key attributes of the last item plus isBackward=false
}

client app now wants to know next or previous page, so it calls GET /users?cursor="prev or next cursor". The backend does:

{key, isBackward} = decryptCursor(cursor);
items = await User.find({}, {limit: 100, start: key, reverse: isBackward});
if (isBackward) {
   return pageResponse(items.reverse());
}

return pageResponse(items);

With dynamodb-onetable is easy to compose the next cursor, I can just use items.start (which is indeed the key attributes of item[item.length - 1]), however I can't compose the prev cursor easily. There is no shortcut to get the key attributes of items[0].
Hopefully this clarifies the use case I'm missing in the library.

Thank you for the extra detail.
Can you try Params.hidden == true. Then you will get the PK/SK values for all items. Then construct the start value using the items[0] keys.
If this works, we could then do that internally and return an items.prev set to the primary key of the first item.
Does that make sense?

Sure!
I'll build a working example using hidden=true and get back to you.
I think I'll have some time to spend on this during this week. I know this pattern works as I have implemented it many times using aws-sdk directly.

I've checked in a prototype where items.prev is set to the pk/sk of items[0].
To page backwards, set reverse == true and params.start == items.prev

Here is a working example of what I meant by forward and backward paging:
https://github.com/cjuega/dynamodb-onetable-backward-pagination-example
It basically does what I described in my previous comment.
TLTR:
prevPage = (
    await User.find(
        {},
        {
            limit: 20,
            // It would be nice to have a shortcut in the same fashion as when paginating forward
            start: { pk: nextPage[0].pk, sk: nextPage[0].sk },
        }
    )
).reverse();

Thank you for the working example, that helps.
A question about the high level API usage:
It looks like this:
let page = await User.find({}, {limit})
let nextPage = await User.find({}, {limit, start: page.start})
let prevPage = await User.find({}, {limit, start: page.prev, reverse: true}).reverse()

Perhaps we could dry it up with a Params.prev which would imply the double reverse.
let page = await User.find({}, {limit})
let nextPage = await User.find({}, {limit, start: page.start})
let prevPage = await User.find({}, {limit, prev: page.prev})

And then, since Params.next is deprecated, we could alias Params.start to Params.next and then we have a nice symmetrical next/prev cursor?
One other issue:
If doing a Params.fields which defines a ProjectionExpression to return a subset of fields, you may not have access to the keys in the returned items. next/prev can only work if the result set includes both keys.  If you use Params.fields, you must include the keys or set hidden: false.

Perhaps we could dry it up with a Params.prev which would imply the double reverse.

Sure! That would be helpful. I can't think of a use case in which you wanted the collection without reversing. And if it exists, we can always reverse it manually.
Are you also saying to manage reverse: true implicitly? That can be done, but it's tricky. We must know in advance the direction in which we are traversing the partition (which I guess we know as clients must set reverse property anyway):

If we are traversing the partition forward, i.e. reverse: false when fetching the current page, then, to get prev page reverse must be true.
If we are traversing the partition backward, i.e. reverse: true when fetching the current page, then, to get prev page reverse must be false.

So, we have to negate reverse value to get prev page. If you want dynamodb-onetable to do it automatically, then whenever Params.prev is set, the library must do something like reverse = !Params.reverse.
That would be helpful because it's easy to mess things up if the library delegates that responsibility to clients.
The high level API would be:
// when traversing the partition forward
let page = await User.find({}, {limit})
let nextPage = await User.find({}, {limit, start: page.start})
let prevPage = await User.find({}, {limit, prev: page.prev}) // this will set Params.reverse to true and it will also reverse the resulting list

// when traversing the partition backward
let page = await User.find({}, {limit, reverse: true})
let nextPage = await User.find({}, {limit, start: page.start, reverse: true})
let prevPage = await User.find({}, {limit, prev: page.prev, reverse: true}) // this will set Params.reverse to false and it will also reverse the resulting list

Would that make sense?

And then, since Params.next is deprecated, we could alias Params.start to Params.next and then we have a nice symmetrical next/prev cursor?

Yes, that makes much more sense as next/prev are more semantic.

If doing a Params.fields which defines a ProjectionExpression to return a subset of fields, you may not have access to the keys in the returned items. next/prev can only work if the result set includes both keys. If you use Params.fields, you must include the keys or set hidden: false.

This issue happens also with the current implementation, doesn't it? I mean, if somebody uses Params.fields, page.start won't work unless fields include key attributes, right? Would it make sense to you to always include key attributes regardingless Params.field? That would always enable pagination without impacting too much performance.

I think the code for handling params.reverse and params.prev is an XOR.
args.ScanIndexForward = (params.reverse != null ^ params.prev != null) ? false : true

I'm not sure about the Parmas.fields yet and want to think a bit more about it. I don't want to ignore the user Params.fields and add extra fields under the hood. Users typically only use that in really performance sensitive cases where minimizing the I/O is worth it. I can definitely warn about it in the doc. It is hard to detect as every scan/find is meant to return the next/prev keys.

I've checked in a prototype and updated the test/pagination test case to demonstrate similar to your sample

I have updated my tests to use next/prev and everything seems to work fine 🥳
I totally understand your point about Param.fields, and you are right, not all use cases require pagination. Explicitly adding key attributes to Params.fields looks a good tradeoff.
Regarding documentation, I would clarify these points:

The params.fields may be set to a list of properties to return. This defines the ProjectionExpression.

The params.fields may be set to a list of properties to return. This defines the ProjectionExpression. Be aware that key attributes must be included in order to enable pagination.

If params.next is set to a map that contains the primary hash and sort key values for an existing item, the query will commence at that item.

I would extend that phrase or add a new paragraph for params.prev. Furthermore, I assume they can't be used at the same time, so I would clarify that too:
If params.next or params.prev is set to a map that contains the primary hash and sort key values for an existing item, the query will commence at that item. These two properties are mutually exclusive, both of them can't be set at the same time.

BTW I would like to thank you, not only for the library which is pretty awesome, but also for your dedication and quick replies/implementation 😃
Thank you!


OSim KIT 24.08

Description
Added

Adoption View:

Added new Chapter Product documentation with a link to the document.

Changed

Adoption View:

Updated the aspect model references to the newest version.

Development View:

Updated the API descriptions in accordance with the newest OSim standardization document CX-133

Removed

Adoption View:

References to the obsolete OSim Standards.

Pre-review checks
Please ensure to do as many of the following checks as possible, before asking for committer review:

[x] DEPENDENCIES are up-to-date. Dash license tool. Committers can open IP issues for restricted libs.
[x] Copyright and license header are present on all affected files

/cc @theodorisinger

Hi @dominikoeh can you please provide the API file as an .yaml

Hi @dominikoeh can you please provide the API file as an .yaml

@maximilianong API file as been added as .yaml

Discussed with @jSchuetz88 can be merged


[l10n] Improve cs-CZ locale

Ref #20656

[x] I have followed (at least) the PR section of the contributing guide.

I was also thinking about having those localization strings in imperative form. The original English strings are in imperative form, but not sure if it would be appropriate for cs-CZ.
Ukázat -> Ukaž
Jít -> Jdi
What do you think about that @honzajavorek  ?

@char0n What's the status of the pull request, do you plan to make changes to the translations?

@oliviertassinari it's good to go!

@char0n Thanks 🙏


Span duration not captured

Though the trace captures the command and details. the duration of span is not captured in the trace.

Thank you for bug report! I see you have already fixed the issue. Do you mind to create a PR with it?

i have opened the PR #5. The travis CI fails, because the newer go-redis client (v7) deprecated WrapProcess/WrapProcessPipeline in favor of newer AddHook. But this version may still be required by many like me. So, for keeping this still compatible with older go-redis, and success in CI, may be we can lock the go-redis version to 6.5.x. and include it in the CI.

fixed by #5


add search command

Create a search command for searching text for every column in every table. It can take a while in a large database.

@hasankhan will do, is there a command i can look at for the "Searching..." console output?

There isn't an example unfortunately, your command would be the first one to do so. You can use the messages object passed to the method.

@hasankhan is the test for the search good enough?


ask for go get from code.gitea.io/gitea and change gogs to gitea on m…

LGTM

LGTM

Current coverage is 3.03% (diff: 100%)

Merging #146 into master will not change coverage

@@            master      #146   diff @@
========================================
  Files           33        33
  Lines         8096      8096
  Methods          0         0
  Messages         0         0
  Branches         0         0
========================================
  Hits           246       246
  Misses        7830      7830
  Partials        20        20

Powered by Codecov. Last update a1c5f02...33b6a8c


Native Editor - Clear All Output Button

Add a clear all outputs button in the top toolbar
Icon TBD from Kaitlyn

For execution counts, do the same thing jupyter lab does.

Validated


Avoid warning message fatigue

Our current strategy with making an application "not nais"/yellow might not have the effect we want. Most teams have >70% not-nais applications for various reasons, and the prospect of fixing everything might seem a bit a bit overwhelming.
A suggested strategy was to introduce a new level of naisness, only achievable if every aspect is a-ok. The level of naisness can be on a pr. workload basis, but also aggregated to the team level.
What makes a workload drop in terms of naisness will vary over time. It might be things that are deprecated, wrong-sized workloads, or other errors.
The key metric for us, would be to see that the level of naisness increases.
Related issue https://github.com/nais/console-backend/issues/22 - this will give us a good tool to measure the progress of our deprecations.

Tror en mulighet for å lage en PR med fix fra console ville gjort det enklere for team å tatt stegene mot å bli mer nais.

duplicate https://github.com/nais/console-backend/issues/25


Create harness shepherding thread to shut down the test in asynchronous failures

This should address the issues of hangs in testing, seen earlier in the week.

Local tests against ehcache3/master with a mod to create a bad configuration in EhcacheClientEntityFactoryIntegrationTest demonstrate that a failed server initialization no longer causes a test hang.  In the test, an java.lang.IllegalStateException: Active process did not appear is raised to cause a test failure when the server start fails.


Use f-strings

Replace % and .format syntax with f-strings where appropriate. Also replace the text indentation code with stdlib's textwrap.indent method call.

Please don't force push @eumiro. It hides your changes and means I need to review them from the start again. Only add new commits so that the audit trail of what changed is clear.

Sorry for the forcepush. I had difficulties running tests on my host, so I waited for the CI (that you had to approve). The only change I did now was the black reformat of one line.
In the first CI run I also saw one test fail and wanted to check it after the re-run of CI.

@eumiro There's a single test failure in test_change_log_message. Can you have a look at that?

Thanks for the contribution!


Problem with residuals / cost function when running PEtab / Catalyst on actual data

Hi! I'm having an issue with using PEtab with Catalyst, and I think there's something going wrong in the residual calculation. I can set up the problem as in the docs, including with data taken from actual measurement sources. There are no errors being thrown, and if I ask the PEtab problem to compute the simulated values for some reasonable parameter vector, I get a reasonable result. However, when I ask for the residuals or the cost function, I get non-numerical values (-Inf and NaN, respectively). Not sure what is going wrong there - any ideas?
This ties in to another question I have - would it be possible to allow definition of custom loss functions that could be supplied by the user? Or would that break other parts of the PEtab code?
Here's the code, as well as an example file for the experimental measurements.
using Catalyst, PEtab
using OrdinaryDiffEq, CSV, DataFrames
rs = @reaction_network begin
10.0^k1, PdCat + ArBr --> PdCatArBr
10.0^k2, PdCatArBr + NaOTMS --> PdCatArOTMS + NaBr
10.0^k3, PdCatArOTMS + Amine --> PdCatArAmine + HOTMS
10.0^k4, PdCatArAmine --> PdCat + ArAmine
10.0^kd2, PdCatArBr --> PdCatArylated
end;
simulation_conditions = Dict("cond_2" => Dict(:NaOTMS=>0.373, :ArBr=>0.355, :PdCat=>0.003, :Amine=>0.426),
"cond_3" => Dict(:NaOTMS=>0.361, :ArBr=>0.688, :PdCat=>0.003, :Amine=>0.413),
"cond_1" => Dict(:NaOTMS=>0.373, :ArBr=>0.355, :PdCat=>0.003, :Amine=>0.426))
params = [PEtabParameter(p, lb=1e-6, ub=1e8, scale=:log10) for p in rs.ps]
@parameters sigma
_sigma = PEtabParameter(:sigma)
push!(params,_sigma)
@unpack ArAmine = rs
obs_ArAmine = PEtabObservable(ArAmine, sigma * ArAmine,transformation=:lin)
observables = Dict("obs_ArAmine" => obs_ArAmine)
measurements = CSV.read("example.csv", DataFrame)
measurements[!,"measurement"] = [maximum([x,1.0e-10]) for x in measurements[!,"measurement"]] # tried to see if forcing the measurements to be at least small positive numbers would fix things - it didn't
measurements[!,"time"] = [x for x in measurements[!,"time"]] # random workaround to make sure the columns are formatted correctly - not sure why they don't read right.
measurements[!,"simulation_id"] = [x for x in measurements[!,"simulation_id"]]
measurements[!,"obs_id"] = [x for x in measurements[!,"obs_id"]]
petab_model = PEtabModel(rs, simulation_conditions, observables, measurements, params, verbose=false)
petab_problem = PEtabODEProblem(petab_model, verbose=false)
sim_vals = petab_problem.compute_simulated_values([1.0 for i in eachindex(params)]) # returns a reasonable vector of floats
petab_problem.compute_residuals([1.0 for i in eachindex(params)]) # returns -Inf
petab_problem.compute_cost([1.0 for i in eachindex(params)]) # returns NaN
example.csv

Thanks for reporting! You are correct that something is wrong with the residuals, but technically the code is not incorrect :) What causes problems is your noise-formula,
obs_ArAmine = PEtabObservable(ArAmine, sigma * ArAmine,transformation=:lin)

If either sigma or ArArmine is zero, the noise formula is evaluated to 0, and since when computing the likelihood we divide with the nose-formula:
residuals^2 / noise_formula

you are dividing by 0 and therefore get the NaN in compute_cost. How to solve this? Often a combined noise formula is used on the form:
noise_formula = sigma1 + sigma2*ArAmine

Here you would never be able to divide by zero, and there is only one more parameter to estimate (and typically the dataset holds enough information to estimate noise parameters so you should not have any identifiabillity issues).
Your code also errors because your parameter vector x = [1.5 for i in eachindex(params)] is on the log10 scale, in particular
# sigma = x[end]
x[end] == 1.0 # log10(sigma) = 1 thus sigma = 0

You defined sigma as zero, which again makes the measurement noise formula to evaluate to zero. To generate a startguess within the bounds, you can do:
x0 = PEtab.generate_startguesses(petab_problem, 1)

As for a custom objective function, what kind of function do you have in mind? Currently, it is often not possible to use a custom objective, because some formulas for the gradient computations are hard-coded (but there might be workarounds). I am further currently updating PEtab.jl, and one of my aims is to make a custom objective possible.

Thanks! That makes sense - hadn't quite realized how the variable transformation was working in the rest of the code. This fixes the problems in the minimal problem, there's still something else wrong in my actual problem. Let me see if I can figure out what that is and I'll get back to you on that.
In terms of loss functions: I've previously added time derivatives or similar terms (such as the slope of a line fit to the first n datapoints - experimental chemists use this as a measure of initial rates pretty frequently) into the loss function for kinetic models. I've found this somewhat useful for making sure that the solutions converge rapidly towards a minimum in which not only the general outline of the trace is reproduced, but also the slopes of the traces are well defined. In principle it should all be the same minimum, but I think the loss landscape becomes a bit more convex and I think doing this might eliminate some local minima that I've gotten stuck in sometimes.

Thanks! That makes sense - hadn't quite realized how the variable transformation was working in the rest of the code. This fixes the problems in the minimal problem, there's still something else wrong in my actual problem. Let me see if I can figure out what that is and I'll get back to you on that.

Happy this solved the problem, hope you manage to fix the big problem (otherwise feel free to reach out!)

In terms of loss functions: I've previously added time derivatives or similar terms (such as the slope of a line fit to the first n datapoints - experimental chemists use this as a measure of initial rates pretty frequently) into the loss function for kinetic models. I've found this somewhat useful for making sure that the solutions converge rapidly towards a minimum in which not only the general outline of the trace is reproduced, but also the slopes of the traces are well defined. In principle it should all be the same minimum, but I think the loss landscape becomes a bit more convex and I think doing this might eliminate some local minima that I've gotten stuck in sometimes.

You cannot add things like this directly, but there are workarounds. For example, lets say you want to compare the time-derivative of the ODE-solution against a linear slope, you could split your cost function into two parts. In the first you compute the cost with PEtab.jl (standard cost), and in the second part you compute your custom cost (compare against slope) with help of the utility functions. As an example:
petab_problem = PEtabModel(...)
function cost_p1(x)
    return petab_problem.compute_cost(x)
end
function cost_p2(x)
    # id is the simulation condition
    odesol = get_odesol(x, petab_problem; condition_id = id)
    # do things to compute custom slope
end
cost_total(x) = cost_p1(x) + cost_p2(x)

Similarly, for cost_p2 you can build a gradient function with using for example ForwardDiff and combine with the PEtab.jl gradient function (gradients are linear operators so adding a new function is not a problem). There are some pitfalls when adding custom factors like these (e.g. easy to mess up gradient computations), but feel free to reach out if you want to test something like this later and have any problems (and hopefully when done updating PEtab.jl I can figure out some easier way to add custom things in the objective :)


Config Function

Describe the problem
Much like vite, some configuration options for svelte kit are dependent on the mode you're running in. In particular the hostHeader which is rarely wanted when you're running locally (some docker-configs excepted). Currently we have to rely on environment variables which are OK, but less smooth a path than vite's strategy of accepting either a function or a config object.
Describe the proposed solution
I'd love for svelte to accept either a config object, or a function that receives some environment information and returns the config object. I brainlessly spent about an hour this morning confusing the Vite and svelte configurations and assuming I could use a function for both. The hour wasted was my fault, but it did reveal a feature that would be simple and nice.
Alternatives considered
Environment variables.
Importance
would make my life easier
Additional Information
No response

Today for something like hostHeader, you can do something like:
const config = {
    kit: {
        target: "#svelte",
        hostHeader: process.env.NODE_ENV !== "development" ? "x-forwarded-host" : "",
    }
}

export default config;

And by checking the process.env.NODE_ENV, I guess you could write a function that could return a custom config object.
const config = yourCustomFunction(process.env.NODE_ENV)

export default config;

fyi: this RFC https://github.com/sveltejs/rfcs/pull/59 describes a solution for svelte config with builtin function support.

Given that top-level await is a thing, do we need function support?

Perhaps a function would make more sense if we implement https://github.com/sveltejs/kit/issues/1258

@Rich-Harris valid question. I think the consistency across APIs would make it more usable, but I'm easily persuaded here. I think I'm just too old - forgot top level await was allowed.

Going to close this for the sake of tracker hygiene unless another use case presents itself


Does this work with css-modules (or icss) specification ?

or do I still need to use jspm-loader-css-modules ?

Closing this since plugin-css loads pure css files.


Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at (Reason: CORS header ‘Access-Control-Allow-Origin’ missing)

I have code :
app.request.setup({
crossDomain: 'true',
headers: {
'Access-Control-Allow-Origin': '',
'Access-Control-Allow-Headers': 'Origin, X-Requested-With, Content-Type, Accept'
},
beforeSend: function(xhr){
console.log("in before send !!!");
xhr.setRequestHeader('Access-Control-Allow-Origin', '');
xhr.setRequestHeader('Access-Control-Allow-Headers', 'Origin, X-Requested-With, Content-Type, Accept');
},
});
app.request.json('https://tiengnhateasy.com/test.json', function (data) {
// app.request.json('http://localhost/html/tiengnhateasy_f7/www/test.json', function (data) {
console.log("pageInit 00000000");
resolve(
// How and what to load: template
{
componentUrl: './pages/catalog.html',
},
{
context: {
myData: data,
},
}
);
});
}
But err : Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at (Reason: CORS header ‘Access-Control-Allow-Origin’ missing)
Any idea how to fix it. Thanks so much!!!!!

You need to use the forum for issues like this: https://forum.framework7.io . also, CORS headers need to be set on top  of your server/API scripts. Google on how to do it in PHP or use the cors package in Node JS. I have faced the same issue in the passed but setting these headers in the origin was so helpful.


loadFile doesn't accept Query Parameters with URL

[:heavy_check_mark:] I have read the Get Started - Installation section
[:heavy_check_mark:] I have read and done the Get Started - Setup Android section
[:heavy_check_mark:] I have read and done the Get Started - Setup iOS section
[:heavy_check_mark:] I have already searched for the same problem

Environment

Technology
Version

Flutter version
2.5.2

Plugin version
5.3.2

Android version
not using

iOS version
15.0

Xcode version
13

Device information: iPad mini 6th gen
Description
Expected behavior: I want to pass query parameters with local file path. For example, assets/board/index.html?letter=5&mode=1
Current behavior: Like, currently I am passing assets/board/index.html and Its loading file successfully. but Its not working If I pass as above path (assets/board/index.html?letter=5&mode=1).
P.S. It is working for same URL if I host somewhere and use initialUrlRequest.
Do let me know if any other information you need. Kindly help.

👋 @pratik7span
NOTE: This comment is auto-generated.
Are you sure you have already searched for the same problem?
Some people open new issues but they didn't search for something similar or for the same issue. Please, search for it using the GitHub issue search box or on the official inappwebview.dev website, or, also, using Google, StackOverflow, etc. before posting a new one. You may already find an answer to your problem!
If this is really a new issue, then thank you for raising it. I will investigate it and get back to you as soon as possible. Please, make sure you have given me as much context as possible! Also, if you didn't already, post a code example that can replicate this issue.
In the meantime, you can already search for some possible solutions online! Because this plugin uses native WebView, you can search online for the same issue adding android WebView [MY ERROR HERE] or ios WKWebView [MY ERROR HERE] keywords.
Following these steps can save you, me, and other people a lot of time, thanks!

Thank you for instant auto-generated message. I tried everything everywhere on google. I found some solutions but that was different than what I want. I need it only when I load file from assets with query paratmeters.

I have the same problem, how can I solve it?  @pichillilorenzo

Yes, I also have same problem loading files from Internal storage

Maybe you can use In-App Localhost Server.
Like this:
InAppWebView(                 initialUrlRequest: URLRequest(                     url: Uri.parse("http://localhost:8080/assets/index.html?letter=5&mode=1")                 ),                 onWebViewCreated: (controller) {},                 onLoadStart: (controller, url) {},                 onLoadStop: (controller, url) {},               ),

I have the same problem, how can I solve it?

did anyone got solution for this?


Feature: Keyboard Shortcut

Add the ability to have a keyboard shortcut to merge windows. Default is Alt+Shift+M but can be changed by the user.
Screenshot on Mac.

Thanks @sindresorhus for all the OS work you do.

You can already do this without this PR:

The only thing this change is that it adds a default shortcut, which I don't think is a good idea as the user should choose one themselves.

Ah, I didn't see that. Sorry about that/


Add ci.yml github action

BigQuery does not have e2e tests, so this only includes Build, lint and unit tests test.

@yesoreyeram @gwdawson if you have a time, would you check this PR that just adds ci.yml github action so it checks lint, typechecks and unit tests - to prevent us from having type errors.


Allow themes to specify number of columns in index

The number of columns in the index is currently hard-coded to 2. When a document contains lots of very long terms, there is a lot of wrapping and it isn't a great end result visually. The changes made by #645 have exacerbated the problem by introducing unwanted blank lines before wrapping such long entries and the added hanging indent actually makes the wrapping even worse. See screenshots of previous result using 1.5.0 (not sure of exact version) and now using the 1.5.3 release.
asciidoctor-pdf 1.5.0 (or thereabouts):

asciidoctor-pdf 1.5.3:

As a workaround for the above and maybe even a better permanent way to address it, being able to control the number of columns in the index would be great. I've done some local experimenting and it would seem fairly straightforward to enable themes to specify the number of columns. Please forgive the crude way of providing the code, I'm heavily focused on getting the published version of a book released in the next few days. Here's my slightly modified version of convert_index_section which lives in converter.rb:
      def convert_index_section _node
        unless @index.empty?
          space_needed_for_category = @theme.description_list_term_spacing + (2 * (height_of_typeset_text 'A'))
          index_columns = @theme.index_columns || 2
          column_box [0, cursor], columns: index_columns, width: bounds.width, reflow_margins: true do

The above would be a backward-compatible change. It also gives weight to the broader suggestion of giving the index its own theme settings instead of re-using the description list theme details.

The changes made by #645 have exacerbated the problem by introducing unwanted blank lines before wrapping

Eek! That wasn't supposed to happen.

being able to control the number of columns in the index would be great.

Seems like a reasonable idea to me. Thanks for suggesting it.

The first problem is now solved in master by #1665.


Import snapshot

Code Enhancement
Description
Enhanced EC2 to maintain code consistency across project
Status

done, ready for review

Checklist (tick everything that applies)

[ ] Code linting (required, can be done after the PR checks)
[ ] Documentation
[ ] Tests
[ ] ICLA (required for bigger changes)

Can you change this to point to the ena_support branch?

I specifically selected your branch while starting the pull req #2. I don't
know what happened there but I assume, pull req #1 was still open between
these two branches
and so it did not let me create a duplicate one and selected the main one
as default.
Anyway here it is,
https://github.com/amisstea/libcloud/pull/3
On Fri, Feb 24, 2017 at 7:53 AM, Alex Misstear<EMAIL_ADDRESS>wrote:

Can you change this to point to the ena_support branch?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/amisstea/libcloud/pull/2#issuecomment-282284332, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AIpbpzNLiRKprUZdev--Zv52QcVpCbYAks5rftLagaJpZM4MKl5h
.


ExportRecord hook

Use case: Polyfilling built-in modules like fs, path, or std:....
Use case: Able to support WASM module, CSS module, ...etc
Example:
class MyRealm extends Realm {
    async exportRecord(specifier) {
        if (specifier === "fs") return require("fs")
        // Skip this hook, fallback to native implementation
        return null
    }
}
const x = new MyRealm()
x.import("data:text/javascript,export { readFileSync } from 'fs'")
// Module { readFileSync() { [native function] } }

The Compartment proposal as written today accommodates this use case with the moduleMap argument of the constructor.
import * as fs from "fs";
const moduleMap = { fs };
new Compartment(globals, moduleMap, options);

Can we consider this issue closed @jack-works?

@kriskowal Can I pass a Proxy as the moduleMap so I can dynamically decide what moduleMap I can provide? For example, a dynamically generated module based on the import specifier. If I can use a Proxy, then the problem is resolved partly.
Another question is, what if I need to load the part of the moduleMap on-demand, meanwhile asynchronously?
For example:
const moduleMap = new Proxy({}, {
    get(_, key) { return import("std:" + key) } // it's async
    has(_, key) { return isBuiltinLikeSpecifier(key) }, // even this might be async
});
const compartment = new Compartment(globals, moduleMap, options);
await compartment.import("./some.js");

Current API can do this! 🙌


:sparkles: new: create Intake Subsystem

@DaviFSilva please just verify the code of build season if is needed a commit to update motor configs


[ci-skip] workflow for alpine-utils:latest image

Signed-off-by: RaviKiranJanjanam<EMAIL_ADDRESS>Changelog
Added the workflow for alpine-image:latest
fixed the repository name to be in lowercase for below files under workflow
.github/workflows/corda_images_build.yml
.github/workflows/docker_build.yml
.github/workflows/indy_image_build.yaml
.github/workflows/quorum_images_build.yml
modified platforms/hyperledger-besu/configuration/roles/create/helm_component/templates/crypto_tessera.tpl to include alpne-utils with latest tag instead of 1.1
Reviewed by
@sownak @suvajit-sarkar @jagpreetsinghsasan
Linked issue
#2147

Kindly check the acceptance criterion https://github.com/hyperledger/bevel/issues/2147

I'm resolving the conversation and closing this PR