cmd/compile: optimize x * const == const (and friends)

package p

func f(n int) bool {
	return n*8 == 64
}

Currently compiles to:
"".f t=1 size=21 args=0x10 locals=0x0
	0x0000 00000 (x.go:3)	TEXT	"".f(SB), $0-16
	0x0000 00000 (x.go:3)	FUNCDATA	$0, gclocals·f207267fbf96a0178e8758c6e3e0ce28(SB)
	0x0000 00000 (x.go:3)	FUNCDATA	$1, gclocals·33cdeccccebe80329f1fdbee7f5874cb(SB)
	0x0000 00000 (x.go:4)	MOVQ	"".n+8(SP), AX
	0x0005 00005 (x.go:4)	SHLQ	$3, AX
	0x0009 00009 (x.go:4)	CMPQ	AX, $64
	0x000d 00013 (x.go:4)	SETEQ	AL
	0x0010 00016 (x.go:4)	MOVB	AL, "".~r1+16(SP)
	0x0014 00020 (x.go:4)	RET

Instead of multiplying (shifting), we should just compare to 8.
Real world example, from code I'm writing right now:
func (ctxt *Link) RegWidth() int {
	return ctxt.Arch.RegSize * 8
}

func foo(ctxt *Link) {
  if ctxt.RegWidth() == 64 {  // should inline and compile to ctxt.Arch.RegSize == 8
    // ...
  }
}

This is one of a family of generic optimizations. Care required in some cases (overflow, div by zero, etc.).
cc @randall77 @philhofer @martisch

I'm not entirely sure how much we can improve here, unfortunately.
C can optimize this because (signed) integer overflow is undefined behavior. Assuming x is a signed integer, x * 8 == 64 can only be true for x == 8.
In Go, if x is int32, then x * 8 == 64 is true for x == 8, but also x == 0x20000008, x == 0x40000008, etc.

Indeed. I don't know why I thought we could in the first place.

Just a thought, but couldn't this be done if the Go compiler did some sort of value range propagation and could statically ensure no overflows?
I don't know if VRP is in the roadmap like SSA was, though.

There's basic VRP around bounds check elimination. Larger VRP was considered and tabled because it didn't offer enough benefits for the compilation time.

After we deal with many other things, it might make sense to revisit VRP. I think if we're careful about evaluation order, etc, we might be able to get the bang-for-buck high enough -- but that would be after we had args in registers, after we get better inlining turned on, after loop unrolling, etc.


[Samples] Generate non-templated samples from templated samples

Version of SDK
latest
Details
Currently, any sample updates require changes to the non-templated JSON and the template JSON. This is easy to forget and hard to detect, so samples go out of sync.
Instead, the non-templated JSON's should be automatically generated (either by the build process or by a script run by dev) by binding the data to template.

Plain (template expanded) samples can be generated the same way we generate the schema docs (see Pipelines -> Tools -> Generate Specs), by pushing changes directly into PR's.


[MGS 3] Game won't launch after installing v2.1

v2 worked like a charm but after installing v2.1, game won't launch :/
I deleted DXVK Files & it worked but I have to use DXVK bc the game will be slow mo on my CPU :(
here is the log
MGSHDFix.log
tnx Lyall 💕👊

v2 worked like a charm but after installing v2.1, game won't launch :/ I deleted DXVK Files & it worked but I have to use DXVK bc the game will be slow mo on my CPU :( here is the log MGSHDFix.log tnx Lyall 💕👊

well ... I realized something ... v2.1 by default in MGSHDFix.ini ,Borderless = true  ... so I changed it into False & it worked :/
it doesn't have anything with DXVK !!!
Actually the main reason was this ### Borderless = true :O

I'll have to do a deeper dive in to checking compatibility with DXVK and Reshade. Glad you got it working at least.


[Designer] Incorrect warnings when templating expressions are used

Platform

Designer

Details
When card templates using binding expressions, e.g., the Stock card, it shows a Parse error for enum values.

We should suppress this error/warning if a templating expression is used
Linked issue
Re this bug filed from our docs: https://github.com/MicrosoftDocs/AdaptiveCards/issues/323

@dclaux are you able to pick this one up for 20.09?

@shalinijoshi19 absolutely not :) This is a huge feature with lots of work behind it, including a huge change in the parser logic.

To be more precise, doing this work will fit in the "live data binding" feature that we've been talking about and have on our roadmap for 2021+.


ui: call logout before login to clear old sessionkey cookies

This handle edge cases of upgrades and when legacy UI is used along with
Primate or any UI sharing cookies. The specific case it fixes involves
removal of duplicate sessionkey cookies.
Fixes #4324
Types of changes

[ ] Breaking change (fix or feature that would cause existing functionality to change)
[ ] New feature (non-breaking change which adds functionality)
[x] Bug fix (non-breaking change which fixes an issue)
[ ] Enhancement (improves an existing feature and functionality)
[ ] Cleanup (Code refactoring and cleanup, that may add test cases)

How Has This Been Tested?

Logout and create a fake sessionkey cookie using $.cookie('sessionkey', '123')
Try to login, login will fail and in the request two sessionkey cookies will be seen passed:

With the fix, when logout is called the API will clear sessionkey cookie (which is httponly so only the backend/server can remove it); and login works. This will cover issues after upgrades and when using legacy UI with Primate:

Please review - @Pearl1594 @davidjumani @utchoang @andrijapanicsb  @svenvogel and rest. Thnx

@blueorangutan package

@utchoang a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Sorry @utchoang the blueorangutan package for old UI wont' setup a live demo to test that

@rhtyd OK. I'll run and test on my local. Thnks

Packaging result: ✖centos7 ✖centos8 ✖debian. JID-2008

Unable to log in from an upgrade / restart of the management server without clearing cookies


I don't quite understand...

Checklist

[X] Checked the issue tracker for similar issues to ensure this is not a duplicate
[X] Read the documentation to confirm the issue is not addressed there and your configuration is set correctly
[X] Tested with the latest version to ensure the issue hasn't been fixed

How often does this bug occurs?
always
Expected behavior
TO WORK.
Actual behavior (suspected bug)
I flashed the factory image for my EPS32-WROOM.
I use the esptool-js (but I get the same result with esptool.py).
After successful flashing, if I reboot it it shows:
ets Jun  8 2016 00:22:57

rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:5916
ho 0 tail 12 room 4
load:0x40078000,len:15844
load:0x40080400,len:3548
entry 0x40080600
I (29) boot: ESP-IDF v5.0.6-dirty 2nd stage bootloader
I (29) boot: compile time 04:45:59
W (29) boot: Unicore bootloader
I (32) boot: chip revision: v1.0
I (36) boot.esp32: SPI Speed      : 40MHz
I (40) boot.esp32: SPI Mode       : DIO
I (45) boot.esp32: SPI Flash Size : 4MB
I (49) boot: Enabling RNG early entropy source...
I (55) boot: Partition Table:
I (58) boot: ## Label            Usage          Type ST Offset   Length
I (66) boot:  0 phy_init         RF data          01 01 0000f000 00001000
I (73) boot:  1 otadata          OTA data         01 00 00010000 00002000
I (81) boot:  2 nvs              WiFi data        01 02 00012000 0000e000
I (88) boot:  3 at_customize     unknown          40 00 00020000 000e0000
I (96) boot:  4 ota_0            OTA app          00 10 00100000 00180000
I (103) boot:  5 ota_1            OTA app          00 11 00280000 00180000
I (111) boot: End of partition table
I (115) esp_image: segment 0: paddr=00100020 vaddr=3f400020 size=1a114h (106772) map
I (162) esp_image: segment 1: paddr=0011a13c vaddr=3ff80063 size=00008h (     8) load
I (162) esp_image: segment 2: paddr=0011a14c vaddr=3ffbdb60 size=050d0h ( 20688) load
I (176) esp_image: segment 3: paddr=0011f224 vaddr=40080000 size=00df4h (  3572) load
I (178) esp_image: segment 4: paddr=00120020 vaddr=400d0020 size=129b5ch (1219420) map
I (625) esp_image: segment 5: paddr=00249b84 vaddr=40080df4 size=1ee10h (126480) load
I (677) esp_image: segment 6: paddr=0026899c vaddr=400c0000 size=00064h (   100) load
I (694) boot: Loaded app from partition at offset 0x100000
I (694) boot: Disabling RNG early entropy source...
no external 32k oscillator, disable it now.
at param mode: 1
AT cmd port:uart1 tx:17 rx:16 cts:15 rts:14 baudrate:115200
module_name: WROOM-32
max tx power=78, ret=0
v<IP_ADDRESS>

I used: factory_WROOM-32.bin version <IP_ADDRESS>
Now if I try the WEB IDE, nothing happens.
It says it connects but then nothing.
Nothing using WEBUSB seems to work.
If instead I flash micropython on it, it works without any problem.
What am I doing wrong?
Error logs or terminal output
Pasted above.

Steps to reproduce the behavior
Already described above
Project release version
latest
System architecture
Intel/AMD 64-bit (modern PC, older Mac)
Operating system
Windows
Operating system version
Windows 10
Shell
CMD
Additional context
No response

Could you share the tracing output ?


Bug Report: Freeplay menu skips songs and selecting one chooses the wrong song

If you are playing a downloaded version of the game, what operating system are you using?
Windows (x86_64)
What version of the game are you using? Look in the bottom left corner of the main menu.
AppVeyor compiled version of 293df1e2b87e61b00df97a67fcb6ab5e72a9f961
Have you identified any steps to reproduce the bug? If so, please describe them below. Use images if possible.

Go to Freeplay
Press down
Press enter

Please describe your issue. Provide extensive detail and images if possible.
In the Freeplay menu, the selection will only select every other song. Selecting the song will actually take you to the next song.
I have tested this on a blank save file to ensure it wasn't an issue with the save.
https://user-images.githubusercontent.com/15317421/124340132-dbc27200-db67-11eb-9e54-b25a440eac11.mp4

yeah I noticed that, but was to lazy to create an issue today so thanks I guess

same here

Fixed in the pr above this msg


Jweber allow ssh external ip

This PR implements a change so that you may SSH to the external node IP with the rancher CLI
rancher -e node-name
Most changes are actually from jeremyweber, in https://github.com/rancher/cli/pull/185 but that PR has gone stale.
I have also implemented the feedback on that PR (reverted login name back to -l flag). (Also found that one description line was duplicated)

The functionality looks good, some small comments.

https://github.com/rancher/rancher/issues/13556


openapi-fetch: example for extending api client methods

Hello! First of all, thanks for this tool, I find it very useful!
I have a question regarding modification to api client methods. Let's say I want to always return the data property after calling the GET request. How do I declare the correct parameter and return types for this method?
const apiClient = createClient<paths, 'application/ld+json'>({ /* removed for brevity */ })

const getData = (...args: any /* TODO: get argument types */): Promise<any /* TODO: get return type */> => {
  return (await apiClient.GET(...args))?.data
}

I tried to implement it based on the types in the package and got to something like this:
const getData = async <
    Path extends PathsWithMethod<paths, 'get'>,
    Init extends MaybeOptionalInit<paths[Path], 'get'>,
  >(
    url: Path,
    ...init: HasRequiredKeys<Init> extends never
      ? [(Init & { [key: string]: unknown })?]
      : [Init]
  ): Promise<
    FetchResponse<paths[Path]['get'], Init, 'application/ld+json'>['data']
  > => {
    return (await apiClient.GET(url, init)).data
  }

but there are two errors:

and my attemt is not really ideal because it depends on many internal types, so I am looking for a more ideomatic way to accomplish this. It would be nice if an example for stuff like this would be in the docs.
Sorry if the issue is formatted wrongly, I will update it if needed.

Hey @Amixx,
I've done something similar for the openapi-react-query package, maybe you will find what you need with the following type: https://github.com/openapi-ts/openapi-typescript/pull/1717/files?diff=unified&w=0#diff-50b08a9645fe85e543902c82e96b837307b0d80b1717eec7c465e63c838ff090R15

Thanks @kerwanp! This looks like what I needed.


Common Generator?

Also, you might want to backlog using a common generator to generate sync and async versions of the same method, instead of needing to copy the code over.
Originally posted by @Arithmomaniac in https://github.com/viceroypenguin/SuperLinq/issues/2#issuecomment-1186999476

Migrated the generation code to Scriban. With this change, there's no need to use a common generator.


Add Angular CLI update schematic

Is your feature request related to a problem? Please describe.
No
Describe the solution you'd like
I would like to be able to update to the latest version using the ng update command
Describe alternatives you've considered
N/A
Additional context
N/A

What would you like to see in the first version of the update schematic?

What would you like to see in the first version of the update schematic?

I think that the update should make the following modifications:

Remove the library from the dependencies section of the package.json, which it is currently
Install the new version of the library

I think that the update should make the following modifications:

Remove the library from the dependencies section of the package.json, which it is currently
Install the new version of the library

This sounds like a great idea. Let's make it happen 💪

This sounds like a great idea. Let's make it happen 💪

@Jefiozie I think that the 1st point is not needed since new users of the library will install the correct version with devDependencies and existing ones cannot use ng update. Is my assumption correct?

There is currently no need for any migration action with ng update.


How to prepend  custom path to script bundle or style

Is it possible to putt scripts to deferent folders in one form same config file?
Here is what I have:
// bundle.config.js
module.exports = {
  bundle: {
    main: {
      scripts: [
        './assets/src/js/**/*.js',
      ],
      options: {
        rev: false
      },
    },
    vendor: {
      scripts: [
        {
          // jQuery
          src: './assets/src/bower_components/jquery/dist/jquery.js',
          minSrc: './assets/src/bower_components/jquery/dist/jquery.min.js',
          watch: false
        }
      ],
      options: {
        useMin: true,
        rev: false
      },
    },
    //would like to putt this file in to views folder in dist
    views:{
      scripts: [
        './assets/src/js/views/**.js',
      ],
      options: {
        rev: false
      },
    }
  },
  copy: [
    {
      src: './assets/src/bower_components/bootstrap/dist/fonts/**/*.*',
      base: './assets/src/bower_components/bootstrap/dist/',
      watch: false
    },
    {
      src: './assets/src/img/**/*.*',
      base: './assets/src/',
      watch: true
    }
  ]
};

// gulpfile.js
var gulp = require('gulp'),
  bundle = require('gulp-bundle-assets');

gulp.task('bundle', function() {
  return gulp.src('./assets/src/js/bundle.config.js')
    .pipe(bundle())
    .pipe(gulp.dest('./assets/dist'));
});

gulp.task('watch', function(){
    gulp.watch('assets/src/js/**/*.js', ['bundle']);
  });

gulp.task('default', ['bundle']);

Thank you.

Yes. Simply make the bundle name a relative url path.
bundle: {
    //would like to put this file in to views folder in dist
    'views/my-js-bundle':{
       scripts: [
          './assets/src/js/views/**.js',
        ]
        //...
    }
}

See this example for more details.
On a side note, you can use the built in bundle.watch, which provides better performance for incrementally building only the bundle(s) that changed, see: examples/full/gulpfile.js
If this doesn't answer your question, feel free to reply back


Slow calculation and memory leaking with 0.5.1

Hi all,
I am using pvlib to calculate many pv arrays and do this by looping over the individual system specs. Since updating on 0.5.1, I noticed much longer calculation times and a steady increase in memory usage.
From a quick glance at the changes from 0.5.0 I couldn't determine an obvious cause for this behavior. Did I miss something?
My parameters for the calculation are
ModelChain(system, location, dc_model='singlediode', ac_model='snlinverter',                             spectral_model='no_loss', temp_model='sapm', aoi_model='ashrae',                             solar_position_method='nrel_numba', transposition_model='haydavies',                             losses_model='pvwatts', clearsky_model='simplified_solis', orientation_strategy=None)

It could be related to fixing ModelChain to actually use solar_position_method, especially since you're specifying nrel_numba. See #377 and #379. I suggest setting it to nrel_numpy and retesting the performance of your code. Also make sure that you're consistently using nrel_numba for every single solar position calculation in your whole script. This is because the spa module needs to be reimported when the method changes, and this takes some time, especially when the module needs to be JIT compiled again. Note that methods such as Location.get_clearsky will use the default solar position method (nrel_numpy) unless explicitly told otherwise.
Is pvlib the only thing that's changed in your environment?

Thanks for your suggestions! I will look into them.
Updating pvlib was not the only change that occurred, but after reverting to 0.5.0 the behavior was normal again.

Looks like you are using the single diode model, so it also could be my changes to support ideal devices.

@jkfm any reports back from your investigation?  We'd like to fix the issue you experienced, if we can narrow down the cause.

Hey all, sorry for the delay. I am now looking into the problem.
I wrote a script which replicates my actual use case but is much simpler: https://gist.github.com/jkfm/6c5668da8f28403bf37268cda4afeb05
The code for following memory usage is from here.
With 30 iterations (my RAM can't handle more ;-) ), the code has the following stats:
0.5.0:
duration 4s,
memory usage:

0.5.1:
duration: 1min 47s
memory usage:

I realise, that the memory usage is not really representative as such, but I guess the trend is clear.

As the script with 0.5.1 also throws different warnings I suspected the reason for the lag to be in v_from_i and i_from_v in pvsystem.py
I manually changed only those two functions back to their state from 0.5.0 et voilà:
Duration: 4.8s
Memory usage:

So I guess the error has to do with changes in v_from_i and i_from_v

Confirmed.  I get different numbers for mem_usage using your script, and not as dramatic as your results for v0.5.1, but the trend is the same: since v0.5.1 we have a memory leak.

Thanks @jkfm for this very detailed report!

good candidate for #530

Looked into this a bit more with tracemalloc, the memory leak appears to depend on using numba with spa, because the memory usage is stable with solar_position_method = nrel_numpy.  That is with pvlib v0.6.0.

Interesting. I thought the earlier report put the blame on iv functions.
On Tue, Nov 6, 2018 at 8:43 AM Cliff Hansen<EMAIL_ADDRESS>wrote:

Looked into this a bit more with tracemalloc, the memory leak appears to
depend on using numba with spa, because the memory usage is stable with solar_position_method
= nrel_numpy. That is with pvlib v0.6.0.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/pvlib/pvlib-python/issues/401#issuecomment-436298896,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AELiRw63XnnDQOzqd3ihJSj7qf3uWdhsks5usa4egaJpZM4RCDHw
.

Looking at the v0.5.1 release notes, maybe the issue was obscured in earlier releases and exposed by #482

@cwhanse can you reproduce using only solarposition.spa_python(how='numba')?

Doesn't leak when using solarposition.spa_python(how='numba') directly.
Doesn't leak when using Location.get_solarposition(how='numba').
Leaks when using ModelChain.location.get_solarposition(how='numba').

https://gist.github.com/cwhanse/02bb64c551af2083ffee587674ab966e

That's a helpful report + gist.
@jkfm previously said

I also checked your suggestion regarding solar_position_method. There is no significant difference between nrel_numba and nrel_numpy.

@cwhanse what do your modelchain-based script report when changing the method?

@wholmgren when the model chain script has method=numpy there is no memory leak.

Still leaks with result['output'] += mc.ac commented out.

I think I know why this memory leak happens, and I think there's an issue for us but I haven't quite got the issue nailed down.  In @jkfm script, mc.solar_position is computed twice each loop, once explicitly using the Location.get_solarposition method, and again inside ModelChain.run_model at the prepare_inputs step:
for i in range(rg):
    system = get_system()
    location = get_location()
    mc = get_mc(system, location)
    mc.solar_position = mc.location.get_solarposition(times)
    weather = get_weather(mc, times)
    mc.run_model(times=times, weather=weather)

The memory leak only happens when both calculations are in the loop: comment either one out, and no leak.
The leak appears to be caused by cycling between nrel_numpy and nrel_numba values for the solar_position_method kwarg.
When mc is created, solar_position_method is set to nrel_numba.  However, that attribute is NOT used by the attached Location object's method
mc.solar_position = mc.location.get_solarposition(times)

As a consequence, the first time solar position is calculated, nrel_numpy (the default) is used.  The next time is via this line in ModelChain.prepare_inputs:
       self.solar_position = self.location.get_solarposition(
            self.times, method=self.solar_position_method)

which passes the value self.solar_position_method='nrel_numba', assigned when the ModelChain instance is created.
The issue for us, is that ModelChain.location brings a method get_solarposition that does not inspect ModelChain.solar_position_method and hence if called, defaults to nrel_numpy.  How to fix this, or whether to fix it, is where I'm unclear.

Ah, that is very interesting. pvlib tells python to reload the spa module when the method is changed. This is required due to how the numba jit function works.
An easy thing would be to emit a user warning each time the spa module is reloaded.

Cause confirmed.  Adding the method argument
mc.solar_position = mc.location.get_solarposition(times, method=mc.solar_position_method)

stops the leak.

Maybe a ModelChain.get_solarposition method would prevent this mishap, by simply wrapping ModelChain.location.get_solarposition.
I'm guessing @jkfm has the solar position computed explicitly because it's not obvious that prepare_inputs will do this for you.  Maybe also we could inspect ModelChain and only compute solar position if it's not already there:
if not self.solarposition:
 ....

It also takes a few seconds for python to reload the spa module when jitting it. Users should be discouraged from doing this. I don't think this is a ModelChain issue.
I once ran into a similar problem in some code in which I ran solarposition.get_solarposition and then later ModelChain.run_model. In my case I only noticed an unexplained slowness, not a memory leak, but it's possible there was a memory leak problem too. My point is only that there are multiple ways for users to accidentally switch between numba and non-numba calls, and we should try to prevent that from happening at a lower level.

Yes, the performance hit for numpy/numba swapping is noticeable.  Unless you object I'll prepare a PR with:

a ModelChain.get_solarposition method, that wraps the Location method.  That way we can propagate the solar_position_method attribute.  It can be bypassed, but at least we've made it convenient not to do so.

add a warning when spa is reloaded.

I thought better of an if/then around that statement in prepare_inputs, there's no guarantee that solarposition is consistent with times if solarposition is calculated elsewhere.

I once ran into a similar problem in some code in which I ran solarposition.get_solarposition and then later ModelChain.run_model. In my case I only noticed an unexplained slowness, not a memory leak

That's basically what @jkfm was doing.

@cwhanse thanks for volunteering to make a PR.

add a warning when spa is reloaded.

+1. Warning should probably go here and here.

a ModelChain.get_solarposition method, that wraps the Location method. That way we can propagate the solar_position_method attribute. It can be bypassed, but at least we've made it convenient not to do so.

I moderately object to this because the reload problem would already be covered by the new warning and ModelChain is already too complicated. I would be in favor of it if we could list a handful of compelling use cases (other than this numba issue). That might be a separate issue.

I thought better of an if/then around that statement in prepare_inputs, there's no guarantee that solarposition is consistent with times if solarposition is calculated elsewhere.

I agree that this could easily lead to trouble and should be avoided.

I agree with ModelChain being busy, but I don't see it as complicated. I'm in favor of taking the solar position calculation out of prepare_inputs as its own method, if an issue like this arises again.
If there was an easy way to access the solar_position_method attribute from mc.location instance (where mc is an instance of ModelChain), we could smooth out this wrinkle.  But I don't see how to do it without changing ModelChain.location = location to use inheritance.


Support role ids for Modmail roles/auth

Add support for checking if a user is part of any Discord role ids that are set as Modmail Roles (Supporter, Adminstrator etc...)

Will start implementing this after I've got the current frontend changes in a mostly stable state to build off of. Hopefully will be able to make it into the next release.
For my future reference:
It looks like adding the
guilds.members.read scope will allows us to use the<EMAIL_ADDRESS>endpoint to retrieve the roles the user has and match them against the allowed roles.

Just pushed an initial implementation of this to the develop branch (if you decide to test this, be aware that develop currently has a substantial number of changes awaiting v0.6.0). There are some quirks to document about the implementation of this feature that users should be aware of:

The user's Discord Roles are stored within their auth token.

This means that if a users roles change after they authenticate, this change is not reflected until the user is issues a new authentication token, which happens upon sign in through discord. For instance, if you assign a user a new role (such as a supporter being given a moderator role), this won't be reflected unless they sign out and back in. If you revoke a users access by removing their role, it will take up to 3 hours for that user to lose access to the website (when their token expires).
Tokens are not easily revocable (you may globally revoke tokens by changing your secret key (MODMAIL_VIEWER_DISCORD_GUILD_ID))

The user's highest modmail role should always be used based on both discord roles and manually assigned roles.

Discord role permissions are synced with your MongoDB database

Changing the modmail role of a Discord role will be reflected in the website within 5 minutes. (same as all config changes)

Could you move or add the abillity to check role/user whitelist on the ?oauth command of modmail.
It is patreon only but the bot still saves the whitelist in the db so this could be used instead of the modmail perm levels. Or make us choose what whiltelists we would like to use maybe?

Could you move or add the abillity to check role/user whitelist on the ?oauth command of modmail. It is patreon only but the bot still saves the whitelist in the db so this could be used instead of the modmail perm levels. Or make us choose what whiltelists we would like to use maybe?

Hey @martinbndr, this is out of scope for this issue (and it's now closed), could you make a new issue for this?


Difference in package dependencies

Node v14.5.0
Yarn v.1.22.4
When i update package to 2.8.1-0 version, structure of node_modules directory changed
Before:
node_modules
vue-full-calendar
fullcalendar
After:
node_modules
vue-full-calendar
node_modules
fullcalendar
So, previous code with direct import of fullcalendar package will be incorrect.
I think, need to pay attention

The latest releases have been to fix versions of the fullcalendar and jquery dependencies as it seems like that the latest version of these packages have broken this package.


Why is reconnectionStrategy internal?

Not sure if it's a bug or something planned.

Good question. Will take a look at this and make it open.

Fixed. 0.2.2.


Add missing auxilary variables to initial stack frame

The ELF loader is supposed to set various auxiliary variables in the initial stack frame, which are subsequently used by the libc runtime. We currently just set AT_PAGESZ (used by malloc), but there are many others that need to be set as well. This should probably be done proactively rather than as needed, since weird things happen when the runtimes are expecting a value that isn't there (speaking from experience from when I needed to add AT_PAGESZ).
https://github.com/UoB-HPC/SimEng/blob/1765300058152d09585142cd3ef17af2d299f729/src/lib/kernel/LinuxProcess.cc#L110

After #300 entries AT_PHDR, AT_PHENT, AT_PHNUM, AT_PAGESZ, AT_ENTRY and AT_NULL are populated. This is far from all possible entries described here.
Entries that could/should be populated in the future:
AT_BASE: base address of dynamic linker
AT_PLATFORM: used by the dynamic linker
AT_SECURE: used by the dynamic linker
AT_SYSINFO/_EHDR: entry point to VDSO which does exist for AArch64 and RISC-V
AT_CLKTCK: the frequency at which times() counts, possibly useful for codes which time themselves?
AT_DCACHEBSIZE/ICACHEBSIZE/UCACHEBSIZE: should be easy to populate with new memory hierarchy
All group and user ID's: might be needed for threading?
AT_EXECFD/FN: file descriptor and pathname of program
AT_HWCAP: may be able to generate this from the yaml file but not sure the format
AT_RANDOM: pointer to random 16 bytes
A couple more entries are listed here.


test_classes: Skip OpenAPI validation on exceptions

This gives more helpful error tracebacks from failing tests.
Discussion.

Nice, merged, thanks @andersk!


[BUG]multi-channel-sample (error: the token value is invalid)

multi-channel-sample (error : the token value is invalid)

I am following the website: https://www.agora.io/en/blog/connecting-to-agora-with-tokens-using-unity/
to use the dynamic fetch token. however, I would like to use this feature in the WebGL platform.following this sdk: https://github.com/AgoraIO-Community/Agora_Unity_WebGL
and i try the dynamic token example scene there and it's not working (multi-channel-sample - token client that one ). i create the server in the Heroku ( following : https://github.com/AgoraIO-Community/agora-token-service) , but it appear error when i play in the editor ( the token value is invalid)
then i try to implement the script following the doc connecting-to-agora-with-tokens-using-unity, to the WebGL sdk but now it's become so messy.
and facing two errors:

Assets\API-Example\tokenchannel\TokenChannel.cs(67,13): error CS7036: There is no argument given that corresponds to the required formal parameter 'newToken' of 'TokenChannel.FetchToken(string)'

Assets\API-Example\tokenchannel\TokenChannel.cs(126,20): error CS7036: There is no argument given that corresponds to the required formal parameter 'options' of 'IRtcEngine.JoinChannel(string, string, string, uint, ChannelMediaOptions)'

ANY suggestion to solve the problem!! any guideline of using multi-channel-sample ( with server URL) or any sample of implementing the dynamic token feature ourselves in WebGL

Hi @Nelsonlala ,  where did you find the tokenchannel code? It doesn't exist in the API-Examples that we are providing.  I read the developer blog again and agree that it needs some updates.  For now, my best advise is to use this prefab project on the client side to talk to the Heroku server instance.  Simply download and import prefab and drag it into the scene.  You may need to do some extra work to comment out RTM related code and only retrieve the RTC tokens for use.  The rest is just filling in your server URL in the Inspector, as the README file shows.

hi, thx for replying,
I follow the code from the example scene "JoinChannelVideoToken" with the token script "HelloVideoTokenAgora.cs"
from the following GitHub web:
https://github.com/AgoraIO/Agora-Unity-Quickstart/tree/master/API-Example-Unity/Assets/API-Example/examples/advanced/JoinChannelVideoToken
btw I figure out the problem and now can use the multichannelNewdemo scene from ur project. using the tokenclient prefab and tokeclient , tokenrequest script there, it now has a video+voice feature shown on a channel. however, when the time expire, it didn't renew the token. I wonder how to solve it.

@Nelsonlala did this happen on WebGL only? Or on native as well?

@icywind
I just use the multichanneldemonew scene, even in the unity editor, after the expiration time, it doesn't renew the token.
it just keep showing the follow error:
Channel Error: channel key expired
UnityEngine.Debug:LogWarning (object)
AgoraChannelPanelNew:HandleChannelError (string,int,string) (at Assets/API-Example/multi-channel-sample/Scripts/AgoraChannelPanelNew.cs:631)
agora_gaming_rtc.AgoraChannel/<>c__DisplayClass107_0:b__0 () (at Assets/AgoraEngine/Scripts/AgoraGamingSDK/AgoraChannel.cs:1846)
agora_gaming_rtc.AgoraCallbackQueue:Update () (at Assets/AgoraEngine/Scripts/AgoraGamingSDK/tools/AgoraCallbackQueue.cs:54)

ah, I see.  The usage of TokenClient is wrong here because it was written for main engine, not the multichannel instance.  We will see if we can fix it in the sample code.

HI, @icywind
sorry, I was busy with another implement, just get back to testing the multi-channel token,
I use the latest refactor6,
I set the expired s : 10 , then i still get the error below
is there sth i missed ?
( i tested it at the unity editor)
Channel Error: channel key expired
UnityEngine.Debug:LogWarning (object)
AgoraChannelPanelNew:HandleChannelError (string,int,string) (at Assets/API-Example/multi-channel-sample/Scripts/AgoraChannelPanelNew.cs:631)
agora_gaming_rtc.AgoraChannel/<>c__DisplayClass112_0:b__0 () (at Assets/AgoraEngine/Scripts/AgoraGamingSDK/AgoraChannel.cs:1927)
agora_gaming_rtc.AgoraCallbackQueue:Update () (at Assets/AgoraEngine/Scripts/AgoraGamingSDK/tools/AgoraCallbackQueue.cs:54)


can.Model should support serialization override

Currently, json responses from the server can be massaged in a model's parseModel override. However, there is no way to customize the serialization before the data is sent in a put/post. Our rest api has a bad habit of wanting to deal with nest responses; e.g.
{todo: {id: 1, name: "fix it"}}
Supporting a serializeModel() overridable method seems to close the loop in the API.
Discussed:
https://forum.javascriptmvc.com/topic/compliment-to-parsemodel-to-massage-data-before-sending#32525000001806001

Oh, I forgot.  can.Model does call .serialize and passes that to updated/ created.  Does that work for you?

Seems like you found .serialize too.  Closing b/c I think that should be "good enough" not to warrant an API addition.  Thanks!

:+1: http://jsfiddle.net/digger69/t1b20j2b/4/


Update latest version to v0.8.3

What type of PR is this?
/kind documentation
What this PR does / why we need it:
Which issue(s) this PR fixes:

Part-of https://github.com/kubernetes-sigs/kueue/issues/3441
Special notes for your reviewer:
Does this PR introduce a user-facing change?

NONE

/hold for official release
/assign @mimowo

/cherry-pick website

/hold cancel

/lgtm
/approve


Case translations

change cases data.json` and refactor code to support translated content
TODO:

when content is available, runmanage.py to get actual translated content from directus

resolves #106

Noice. Translations integrated.


Couldn't find file /horr/jpn/24.tmd (might be related to the order of things)

edit: Sorry if this is annoying, just trying to help :D
Version
3.2.3
Seed
R710-NL9M-XNQA00N7ZUY0C07JJKWKM49M5ZZJZQ26ZXZZZZZQ7JWZZZZZZ
Scenario
RE 1 (Jill)
Player Character
Claire RE2 remake
What happened?
I know it was closed before, because someone else had the same error, but maybe my hint might actualy help figure this out as I did some more investigation (in the edits below)
Original problem: When going to the cave for the first time, the first door to the right after going down the ladder to enter in the caves is giving me this message and the game crashes (I played with chris the previous night without a problem)
Thanks for BioRand, it's amazing :D
edit1: Could it be related to the fact that I went tio the basement first before going to the guardhouse and then the cave?
With Chris, Rebecca was nowhere to be found after I told her to stay in the mansion (didn't show in the guardhouse, didn't show back in the mansion and was just gone for the rest of the playthrough)
Could the same thing ( or something similar) kinda of have happened with Jill? Because Barry was supposed to be right after that door, and seeing as He was also gone after the mansion (no sight of him in the guardhouse either) so maybe the game didn't know what to do when He was supposed to spawn for the cutscene in that first room in the cave.
Just food for thought :D
edit 2: So, just by loading a really old save (with the same seed?) that one room loaded up fine, but just like you said, just by opening the game without the randomizer it was also crashing.
It seems like it is related to the sequence of events that happened in that seed like I mentioned above.
P.S. loaded an even older save, and the sequence (I loaded before going to that room, with the first save state that is in the cave)
and by going through the door, the sequence played normally (with Claire RE2 being barry and my Claire RE2R being Jill)
In both saves, the order of the game was maintained ( this was the first time I got the key that forced me to go to the basement earlier to proceed throughout the mansion, leading to the guardhouse, and leading to me going back to the mansion and have nothing changed in there because the game probably thought I was done due to going to the basement earlier or something )
Anyway, thanks for the reply, I am pretty sure you guys will figure it out later :D

You don't need to open a new issue, I close the last one as a duplicate so that we just moved the conversation to the first issue that got posted. As this one now has the most information, I will close the other one.
Do you know exactly what event triggers or doesn't trigger the issue?


LWIP Update- Function called without core lock

Since the LWIP update LWIP_TCPIP_CORE_LOCKING now defaults to 1. From what I've been able to find, this is to allow the application to avoid a few context changes by providing its own mutex.
The client is supposed to call LOCK_TCPIP_CORE() etc, but I'm not entirely clear on where that's supposed to happen in esp-free-rtos. I see it peppered throughout the project, but not in any examples.
The end result is the message "Function called without core lock" being repeated on the uart.

Is this my responsibility? If so, we need some examples showing use.
Is this esp-open-rtos's responsibility? If so, it looks like several calls are missing. If someone could help clarify I'd be happy to work on this.

The option LWIP_TCPIP_CORE_LOCKING was already enabled, it is just that checking has been added to lwip. If it is reporting problems then there are likely thread safety issues in the app code. If it is just at start up then you might get away with it.
We should correct any problems in the esp-open-rtos code. An attempt was made try to guard all the calls into lwipl, but perhaps there are still some calls into lwip from the sdk binary for which we do not have source code. If you could narrow down an example that would help.
Lwip has a range of APIs, callbacks, and sockets. Probably best to study lwip to learn more. The esp-open-rtos fork of lwip is very close to the upstream version.

Once I finish up my extras/timekeeping for a pull request, I'll probably dive into this deeper. I'm tempted to replace the nagging message with a forced crash so I can get a stack dump. Is there a better way to get a stack dump printed than sdk_system_restart_in_nmi(); ?
I get the messages even when only calling LWIP-supplied code and it doesn't appear to be part of the DHCP negotiation:
void
sntp_task(void *pvParameters) {

    while (sdk_wifi_station_get_connect_status() != STATION_GOT_IP) {
        vTaskDelay(10);
    };

    sntp_setoperatingmode(SNTP_OPMODE_LISTENONLY);
    sntp_init();

    while (1) {
        vTaskDelay(60 * 60 * (1000 / portTICK_PERIOD_MS));
        printf("gettimeofday(NULL, NULL)\n");
        gettimeofday(NULL, NULL);
    }
}

void user_init(void)
{
    uart_set_baud(0, 115200);
    sdk_wifi_set_opmode(STATION_MODE);
    /*
     * Run at a high enough priority so that the initial time-set doesn't get interrupted
     * Later calls and listen-only mode calls run in the high-priority "tcpip_thread" (LWIP)
     */
    xTaskCreate(sntp_task, "SNTP task", 256, NULL, 6, NULL);
}

The "SNTP:" line is printed within the implementation of #define SNTP_SET_SYSTEM_TIME_US(S, F) which is a call-back executed by the LWIP SNTP code running in the tcpip_thread
connected with ESP, channel 1
dhcp client start...
ip:<IP_ADDRESS>,mask:<IP_ADDRESS>,gw:<IP_ADDRESS>
Function called without core lock
Function called without core lock
Function called without core lock
Function called without core lock
Function called without core lock
SNTP:<PHONE_NUMBER>.771761    delta:<PHONE_NUMBER>601.887 ms
SNTP:<PHONE_NUMBER>.771809    delta:  -0.225 ms
SNTP:<PHONE_NUMBER>.771803    delta:  -0.389 ms
SNTP:<PHONE_NUMBER>.771817    delta:  -0.415 ms
ip:<IP_ADDRESS>,mask:<IP_ADDRESS>,gw:<IP_ADDRESS>
SNTP:<PHONE_NUMBER>.771813    delta:  -0.379 ms

Ooh, I have been meaning to implement SNTP a little better...
I did just force a crash real quick out of curiosity. The only thing I see in the stack so far is tcpip_timeouts_mbox_fetch, reported as line 91 of lwip/lwip/src/api/tcpip.c. The only place this is called is in a while(1) loop in tcpip_thread.
There's calls to UNLOCK_TCPIP_CORE() and LOCK_TCPIP_CORE() wrapping sys_arch_mbox_fetch. I expected it to be the other way around, but I clearly am not familiar with the lwIP codebase yet.

Fwiw I went through a similar thought process, but with the mdns code. I started submitting patches to make the mdns api thread safe, and added support to the netif-api code, which can either using locking or message passing. It was patiently explained that lwip has different styles of code, some are thread safe such as the sockets api, and then there is the callback style. The callback style assumes that it all runs in one thread. When mixing multiple threads with the callback style of interface it is necessary to acquire the lwip lock around calls into lwip. There was even mention that the message passing approach might be deprecated as it was a big burden compared with locking, but no decision was made. They added the core lock checks to help developers write safe code. Perhaps that discussion would help to see their perspective: https://savannah.nongnu.org/bugs/index.php?52770

If I've found the right spot, from sys_arch.c it looks like the lock is recursive and also checks that the the lock can only be "extended" or released by the thread that originally obtained the lock.
Phew!
Other than potentially locking out another thread that is using LWIP, there doesn't look to be any "harm" in taking the lock.
(The TZ_LOCK in newlib is not recursive.)


Fix TestKit encoding where ByteBuffer.array may not exactly represent UTF8 encoded bytes

Issue description
Testkit correction:
backing array ByteBuffer.array may not exactly represent UTF8 encoded bytes.
PR permit to ensure test is valid whatever the JVM is used
Example using jdk8:

"test-value".getBytes(StandardCharsets.UTF_8) => 0x746573742D76616C7565
StandardCharsets.UTF_8.encode("test-value").array() => 0x746573742D76616C756500 having an additional ending 0x00

Signed-off-by: diego<EMAIL_ADDRESS>

Thanks a lot for the fix. Going to merge it for 0.8, 0.9 and main development lines.


sqlitebrowser: 3.11.2 -> 3.12.0

Motivation for this change
General update
Things done

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

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

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

passed nixpkgs-review and launched ok


[social network] accelerate build process by adding ccache

Hi! @cdelimitrou , I'm a student researcher from UMich, working on a project which heavily dependent on DeathStarBench. Thank y'all for contributing this great project to community :)
One thing I found that might be beneficial to researchers(users) is to config ccache(that utility for compiler cache) in the Dockerfile to greatly reduce the compilation time(by nearly 10x in my case) on building images. This saves me a lot of waiting time between developing and carrying out experiments.
Do you think it's a possible improvement? If you're interested, I may submit a PR for this.

@Hilbert-Yaa - I think it's a great idea, can you provide PR?

@Hilbert-Yaa - I think it's a great idea, can you provide PR?

Thanks Przemek! I talked with professor Christina a while ago about this idea; I'll sort out the changes and make a PR after finishing the work at hand. :)


[hotfix][README] Update the contribution section.

Since Stateful Functions is now part of Apache Flink, the contribution process should follow the official guidelines of the project.
Rephrased the "Contributing" section to reflect this.

Looks good, thanks for updating this.


Include external .mmd files?

Please document
See pull request: Feature/external mmd file #9

From the author of the pull request (https://github.com/fralau/mkdocs-mermaid2-plugin/pull/9/files#r476260320):

Sometimes mermaid diagrams can get quite large and having them inline with your main markdown doc can make it hard to manage. If you prefer to keep your diagrams in seperate .mmd files, you can put the file path to your .mmd file where you would like to insert the diagram.

@maschmi1 I am not sure there is an incentive to include that change in the plugin, since there is already a straightforward possibility to do that, using includes provided by the mkdocs-macros plugin.
## Paragraph
{% include 'snippet.md' %}

Where the snippet could contain arbitrary markdown, including mermaid diagrams.
All it would take would be to install the plugin from pypi. mkdocs-macros can do much, much more, but that comes out of the box.
Did you know about this possibility? Is there a particular reason why it would be better to create a specific include mechanism for Mermaid?

@fralau  I wasn't aware of the mkdocs-macros plugin, but if you include the mermaid code fence inside of the .mmd it breaks compatibility with the mmdc tool which they're originally intended and you get the Syntax error in graph message instead.
The purpose of doing it in .mmd files is not only to save space in markdown, but it also allows for maximum reusability. That said, the best landing place for this feature would probably be in that repository, but I'd have to dig into how that plugin works.

@maschmi1 Is my understanding correct that a .mmd file for you, would simply be a text file containing a diagram in mermaid syntax?
In that case, the following works:
```mermaid
{% include diagrams/mydiagram.mms %}
```

In that case it would load the file docs/diagrams/mydiagram.mms.
You would have this in your mkdocs.yml file:
plugins:
  - search
  - macros:
  - mermaid2

I included a full working example, which works for me.
mms.zip

Note The include_dir argument in the example is sugar, so that the relative path to the files does not start from docs dir. In your case, its purely optional (it is usefuly for files with .md extensions, because they tend to generate pesky warnings if they are under the docs directory but not listed in the config file).

Would that work for you?

@fralau agreed. That solution makes more sense and is more elegant. I’ll close #9 now.

I am glad this could be of help.


Add additional pubber opts

Adds option for an extra point
Adds ability to run additional opts in pubber cli - extra_field and extra_point, e.g.
bin/pubber sites/udmi_site_model project_id AHU-1 123 extra_point=blahblah
bin/pubber sites/udmi_site_model project_id AHU-1 123 extra_point extra_field

@grafnu I had to make a change because if extraField is in the pubber config then it's included by pubber, so I made a change to only include extraField if it's set.


python3Packages.jupyterhub: 0.9.4 -> 1.0.0

Motivation for this change
update jupyterhub to the latest version.
Things done

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

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

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

Notify maintainers
cc @jonringer @FRidh

@GrahamcOfBorg build python3Packages.jupyterhub


[docs] Verifying provenance with Kyverno

Docs on how to verify provenance generated by the generic workflow with Kyverno.
Kyverno docs on verifying images is here: https://kyverno.io/docs/writing-policies/verify-images/

cosign attest sets the intoto statement's subject to the "repo" name which I assume is the image path (e.g. ghcr.io/ianlewis/myimage) and the repo sha256 digest. We should be able to reproduce how cosign attest works and allow it to work with Kyverno.
https://github.com/sigstore/cosign/blob/a2e1c1d1f3f1835d70e1138ca4ac6156215d20dd/pkg/cosign/attestation/attestation.go#L171-L179
Will test more early next week.

I'd be glad to provide assistance/review here.

I tested out Kyverno with the generic workflow and it currently doesn't work because of how we store the certificate use to sign the attestations.
Kyverno seems to call VerifyImageAttestations from the cosign API here.
I have the following cluster policy set:
apiVersion: kyverno.io/v1
kind: ClusterPolicy
metadata:
  name: check-slsa-attestations
spec:
  validationFailureAction: enforce
  webhookTimeoutSeconds: 30
  rules:
    - name: check-all-keyless
      match:
        any:
          - resources:
              kinds:
                - Pod
      verifyImages:
        - imageReferences:
            # Replace with your image. Wildcard values are supported.
            - "ghcr.io/ianlewis/actions-test:*"
          attestors:
            - entries:
                - keyless:
                    subject<EMAIL_ADDRESS>                    issuer: "https://token.actions.githubusercontent.com"
          attestations:
            - predicateType: https://slsa.dev/provenance/v0.2
              conditions:
                - all:
                    - key: "{{ invocation.configSource.uri }}"
                      operator: Equals
                      value<EMAIL_ADDRESS>                    - key: "{{ invocation.configSource.entryPoint }}"
                      operator: Equals
                      value: ".github/workflows/generic-container.yaml"
                    - key: "{{ regex_match('^https://github.com/slsa-framework/slsa-github-generator/.github/workflows/generator_generic_slsa3.yml@refs/tags/v[0-9].[0-9].[0-9]$','{{ builder.id}}') }}"
                      operator: Equals
                      value: true

When I try to create the following Pod:
apiVersion: v1
kind: Pod
metadata:
  name: actions-test
spec:
  containers:
    - name: actions-test
      image: ghcr.io/ianlewis/actions-test:v0.0.11
  restartPolicy: Never

I get the following error:
$ kubectl apply -f actions-test-pod.yaml
Error from server: error when creating "actions-test-pod.yaml": admission webhook "mutate.kyverno.svc-fail" denied the request:

resource Pod/default/actions-test was blocked due to the following policies

check-slsa-attestations:
  check-all-keyless: |-
    failed to verify signature for ghcr.io/ianlewis/actions-test:v0.0.11: .attestors[0].entries[0].keyless: no matching attestations:
    no certificate found on attestation

I'm not sure yet why it's failing but I suspect it has to do with how we are storing the cert w/ Rekor.
It's the same error you get locally if you try to verify using keyless:
$ COSIGN_EXPERIMENTAL=1 cosign verify-attestation ghcr.io/ianlewis/actions-test:v0.0.11
Error: no matching attestations:
no certificate found on attestation
main.go:52: error during command execution: no matching attestations:
no certificate found on attestation

A really simple way to get around this might be to have the generic generator just spit out the predicate and then run cosign attest --type slsaprovenance --predicate predicate.json $IMAGE to upload the provenance.
We can only do that if we know it's a container though.

And this is when you generate the in-toto attestation file and attach it with cosign attach attestation? If so, yes, it's the same issue. I guess I'm not clear though where your code comes into play if all you're doing is pumping out the attestation file and it's up to cosign to attach it.

I'd be glad to provide assistance/review here.

+1. Would it beneficial to add a section directly in https://kyverno.io/docs/writing-policies/verify-images/?
We could simplify our doc in this repo and link to the official doc, in order to avoid duplication. Let us know what you think.

Would it beneficial to add a section directly in https://kyverno.io/docs/writing-policies/verify-images/?
Sure, we could do that. I think it would make sense to add that process once the "official" container image provenance generator is released and tested, also probably needs cosign fixes or "enablements" per the issue I created.

A really simple way to get around this might be to have the generic generator just spit out the predicate and then run cosign attest --type slsaprovenance --predicate predicate.json $IMAGE to upload the provenance.

any reason we would not use this command/API? (It has a different format from the one we use for binaries, but that's not a problem since we need to know we're signing a container image vs an arbitrary artifact anyway, right?)
We could have a generic base64-oci-subject, which would be a list of OCI names?

Oh right, you're not Ian :) Issue reference: https://github.com/sigstore/cosign/issues/2027

Fyi https://nirmata.com/2022/07/14/securing_base_images/. May be interesting to build on top of this post to showcase our SLSA generators / builders

We could probably do that!

Other interesting links:
https://boxboat.com/2021/12/06/secure-supply-chains-kyverno/
https://kyverno.io/docs/writing-policies/verify-images/

I think in order to properly showcase this, though, we would need some resolution on that linked Cosign issue. We (everyone, really) needs to be able to fetch all the attestations to consider in policy decisions without prior knowledge of how they may have been supplied to an image (attest vs attach).

@chipzoller I think for now our workflow can use cosign attest to sign and upload the provenance. We created a separate workflow to be container aware for that reason. The new workflow works with Kyverno and others that expect it provenance to be uploaded this way.
I will push a bit more on the issue you linked since I think it's necessary for consistency in cosign but I don't think it's a blocker for the container workflow.

Agreed, and even if there's no resolution on that thread, as long as you're using cosign attest and passing the un-attested predicate, there should be no issues.


"chef-automate diagnostics run" fails with IAMv2

Describe the bug
Reported by customer and verified with A2 build<PHONE_NUMBER>3438
With a clean install of A2 with IAMv1 enabled A2 diagnostics pass (with 2 skips related to IAMv2) as expected.
After migrating to IAMv2, A2 diagnostics fail.
To Reproduce

Perform a fresh install of A2
Run chef-automate diagnostics run and observe tests pass, or are skipped as expected.
 Received unexpected status code 400
      Response Body:
       {"error":"authz-service set to v2","code":9,"message":"authz-service set to v2","details":[{"@type":"type.googleapis.com/chef.automate.domain.authz.common.ErrorShouldUseV2"}]}
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/integration.(*mustJSONDecodeSuccess).WithValue
      	/src/components/automate-cli/pkg/diagnostics/integration/helpers.go:59
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/integration.CreatePolicyOnToken
      	/src/components/automate-cli/pkg/diagnostics/integration/api.go:97
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/integration.CreateAuthPoliciesDiagnostic.func1
      	/src/components/automate-cli/pkg/diagnostics/integration/auth_policies.go:30
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/runner.(*Runner).Run
      	/src/components/automate-cli/pkg/diagnostics/runner/runner.go:181
      main.runDiagnosticsRunCmd
      	/src/components/automate-cli/cmd/chef-automate/diagnostics.go:129
      github.com/spf13/cobra.(*Command).execute
      	/src/vendor/github.com/spf13/cobra/command.go:762
      github.com/spf13/cobra.(*Command).ExecuteC
      	/src/vendor/github.com/spf13/cobra/command.go:852
      github.com/spf13/cobra.(*Command).Execute
      	/src/vendor/github.com/spf13/cobra/command.go:800
      main.Execute
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:87
      main.EarlyUpdate.func1
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:75
      main.nextCLIOrElse
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:199
      main.EarlyUpdate
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:73
      main.main
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:66
      runtime.main
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/proc.go:203
      runtime.goexit
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/asm_amd64.s:1357
      Could not create policy
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/integration.CreatePolicyOnToken
      	/src/components/automate-cli/pkg/diagnostics/integration/api.go:100
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/integration.CreateAuthPoliciesDiagnostic.func1
      	/src/components/automate-cli/pkg/diagnostics/integration/auth_policies.go:30
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/runner.(*Runner).Run
      	/src/components/automate-cli/pkg/diagnostics/runner/runner.go:181
      main.runDiagnosticsRunCmd
      	/src/components/automate-cli/cmd/chef-automate/diagnostics.go:129
      github.com/spf13/cobra.(*Command).execute
      	/src/vendor/github.com/spf13/cobra/command.go:762
      github.com/spf13/cobra.(*Command).ExecuteC
      	/src/vendor/github.com/spf13/cobra/command.go:852
      github.com/spf13/cobra.(*Command).Execute
      	/src/vendor/github.com/spf13/cobra/command.go:800
      main.Execute
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:87
      main.EarlyUpdate.func1
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:75
      main.nextCLIOrElse
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:199
      main.EarlyUpdate
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:73
      main.main
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:66
      runtime.main
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/proc.go:203
      runtime.goexit
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/asm_amd64.s:1357
[✓] Generating data for auth-teams
[✓] Generating data for auth-users
[✓] Generating data for cfgmgmt-actions
[✓] Generating data for cfgmgmt-ccr
[✓] Generating data for cfgmgmt-jobs-config
[✓] Generating data for cfgmgmt-liveness
[✓] Generating data for compliance-node
[✓] Generating data for compliance-profile
[✓] Generating data for compliance-report
[✓] Generating data for compliance-scanning
[✓] Generating data for compliance-scan-job
[✓] Generating data for compliance-secret
[✓] Generating data for deployment
[✓] Generating data for iam-v2
[✓] Generating data for license
[✓] Generating data for notification-rules
[✓] Generating data for ingest-purge
[✓] Generating data for compliance-purge
[✓] Generating data for event-feed-purge
[✗] Cleaning up auth-policies
      Key not found
      github.com/chef/automate/components/automate-cli/pkg/diagnostics.init
      	/src/components/automate-cli/pkg/diagnostics/context.go:20
      runtime.doInit
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/proc.go:5222
      runtime.doInit
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/proc.go:5217
      runtime.main
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/proc.go:190
      runtime.goexit
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/asm_amd64.s:1357
      Could not load generated context
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/integration.CreateAuthPoliciesDiagnostic.func3
      	/src/components/automate-cli/pkg/diagnostics/integration/auth_policies.go:57
      github.com/chef/automate/components/automate-cli/pkg/diagnostics/runner.(*Runner).Run
      	/src/components/automate-cli/pkg/diagnostics/runner/runner.go:240
      main.runDiagnosticsRunCmd
      	/src/components/automate-cli/cmd/chef-automate/diagnostics.go:129
      github.com/spf13/cobra.(*Command).execute
      	/src/vendor/github.com/spf13/cobra/command.go:762
      github.com/spf13/cobra.(*Command).ExecuteC
      	/src/vendor/github.com/spf13/cobra/command.go:852
      github.com/spf13/cobra.(*Command).Execute
      	/src/vendor/github.com/spf13/cobra/command.go:800
      main.Execute
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:87
      main.EarlyUpdate.func1
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:75
      main.nextCLIOrElse
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:199
      main.EarlyUpdate
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:73
      main.main
      	/src/components/automate-cli/cmd/chef-automate/chef-automate.go:66
      runtime.main
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/proc.go:203
      runtime.goexit
      	/hab/pkgs/core/go/1.13.1/20191001233339/src/runtime/asm_amd64.s:1357
[✓] Cleaning up auth-teams
[✓] Cleaning up auth-users
[✓] Cleaning up cfgmgmt-ccr
[✓] Cleaning up cfgmgmt-jobs-config
[✓] Cleaning up cfgmgmt-liveness
[✓] Cleaning up compliance-node
[✓] Cleaning up compliance-profile
[✓] Cleaning up compliance-scanning
[✓] Cleaning up compliance-scan-job
[✓] Cleaning up compliance-secret
[✓] Cleaning up deployment
[✓] Cleaning up iam-v2
[✓] Cleaning up license
[✓] Cleaning up notification-rules
[✓] Cleaning up ingest-purge
[✓] Cleaning up compliance-purge
[✓] Cleaning up event-feed-purge
DiagnosticsError: One or more diagnostics checks failed: Could not create policy: Failed to POST https://localhost/api/v0/auth/policies. Received unexpected status code 400
Response Body:
 {"error":"authz-service set to v2","code":9,"message":"authz-service set to v2","details":[{"@type":"type.googleapis.com/chef.automate.domain.authz.common.ErrorShouldUseV2"}]}; Could not load generated context: Key not found

Sorry you hit this! This should be resolved by the time of our force-upgrade in a few weeks. We're probably going to port those auth_ generators to the IAM v2 specific diagnostic.

The core issue here is that there are no way to add a node and credentials from the Automate UI. This is where I've noticed it first. While trying to add node or credentials it returns HTTP Code 400.

@pag-r did you mean to add this comment to a different issue?

@susanev no, this is what I noticed when I saw this error in my environment. At least in my case adding creds and nodes is impossible no more. Only way to make it work again is to chef-automate reinstall

@pag-r do you mind opening a new issue that describes how to reproduce the error you're seeing in your environment? It sounds like the error you're describing may be a separate problem we should investigate

@susanev and @bcmdarroch, I was wrong, there is no connection between diagnostics run and HTTP 400. I just checked it when diagnostics failed after switching to v2 but forgot that I've applied policyfile. tl;dr: please ignore my comment from  Feb 10th.

work in progress: https://github.com/chef/automate/pull/2842

#2842 was merged, the updated diagnostics should land in the next Automate release after the current<PHONE_NUMBER>1437

we confirmed this is fixed in acceptance, closing.


CDN for caching static assets / deprecation of fresh/runtime

I want to cache static assets using Varnish Cache as a proxy layer (deployed to fly.io), but currently it seems that due to the nature of Fresh (2.0.0-alpha.25), assets to be marked at runtime using asset/assetSrcSet from fresh/runtime. Varnish doesn't seem to be able to cache such assets. What could be wrong?
Also, is there a plan to get rid of the fresh/runtime entirely to reduce the js bundle, as we already have a prebuild step for files in outdir at /_fresh, but no file hashes for now?
Dockerfile:
FROM denoland/deno:debian

WORKDIR /app

RUN apt-get update -qq && \
    apt-get install --no-install-recommends -y supervisor varnish varnish-modules && \
    rm -rf /var/lib/apt/lists /var/cache/apt/archives

COPY ./web .

RUN deno task build

COPY ./supervisord.conf /etc/supervisor/conf.d/supervisord.conf

ENV VARNISH_SIZE=128M
ENV VARNISH_HTTP_PORT=80
COPY ./varnish/default.vcl /etc/varnish/
COPY ./varnish/entrypoint.sh /usr/local/bin/varnish/entrypoint.sh
RUN chmod +x /usr/local/bin/varnish/entrypoint.sh

EXPOSE 80
CMD ["supervisord", "-c", "/etc/supervisor/conf.d/supervisord.conf"]

supervisord.conf:
[supervisord]
logfile=/dev/stdout
logfile_maxbytes=0
loglevel=info
pidfile=/tmp/supervisord.pid
nodaemon=true
user=root

[unix_http_server]
file=/tmp/supervisor.sock

[program:varnish]
command=/usr/local/bin/varnish/entrypoint.sh
stdout_logfile=/dev/stdout
stderr_logfile=/dev/stderr
stdout_logfile_maxbytes = 0
stderr_logfile_maxbytes = 0

[program:app]
command=/bin/bash -c "deno run -A main.ts"
stdout_logfile=/dev/stdout
stderr_logfile=/dev/stderr
stdout_logfile_maxbytes = 0
stderr_logfile_maxbytes = 0

default.vcl:
vcl 4.1;

sub vcl_recv {
    // ...

    // Mark static files with the X-Static-File header, and remove any cookies
    if (req.url ~ "^[^?]*\.(7z|avi|bmp|bz2|css|csv|doc|docx|eot|flac|flv|gif|gz|ico|jpeg|jpg|js|less|mka|mkv|mov|mp3|mp4|mpeg|mpg|odt|ogg|ogm|opus|otf|pdf|png|ppt|pptx|rar|rtf|svg|svgz|swf|tar|tbz|tgz|ttf|txt|txz|wav|webm|webp|woff|woff2|xls|xlsx|xml|xz|zip)(\?.*)?$") {
        set req.http.X-Static-File = "true";
        unset req.http.Cookie;
        return (hash);
    }

    return (hash);
}

// ...

sub vcl_backend_response {
    // ...

    // If the file is marked as static and no custom Cache-Control max-age specified, cache it for 1 year
    if (bereq.http.X-Static-File == "true" && !beresp.http.Cache-Control) {
        unset beresp.http.Set-Cookie;
        set beresp.http.Cache-Control = "public, max-age=31536000, immutable";
        set beresp.ttl = 1y;
    }

    return (deliver);
}

sub vcl_deliver {
    // Check if the object has been served from cache (HIT) or fetched from the backend (MISS)
    if (obj.hits > 0) {
        // For cached objects with a TTL of 0 seconds but still in grace mode, mark as STALE
        if (obj.ttl <= 0s && obj.grace > 0s) {
            set resp.http.X-Cache = "STALE";
        } else {
            // For regular cached objects, mark as HIT
            set resp.http.X-Cache = "HIT";
        }
    } else {
        // For uncached objects, mark as MISS
        set resp.http.X-Cache = "MISS";
    }

    // Set the X-Cache-Hits header to show the number of times the object has been served from cache
    set resp.http.X-Cache-Hits = obj.hits;
}

And for some unknown reason, some HTML pages got caching working properly, while others have identical headers (also cache control) but always have Age: 0. Using the same Varnish configuration for all projects on Node.js - never seen such an error. 🤔


fix: make optional fields only undefined, not null

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

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


String.concat casts to an array before concatenating

In String.concat, the elements to concatenate are first passed through Seq.toArray, see:
https://github.com/Microsoft/visualfsharp/blob/master/src/fsharp/FSharp.Core/string.fs#L23
String.Join has an overload of IEnumerable, so why are we casting it to an array first? I did some benchmarks for my PR https://github.com/Microsoft/visualfsharp/pull/2558#issuecomment-285490560 and noticed that String.concat is really slow with large sequences. Using String.Join is significantly faster, and I it's because we're doing Seq.toArray first.
@dsyme do you have any comments as to why we convert the sequence to an array first? I wonder if the String.Join overload was added after this function was written.

Good catch, wasn't String.Join overload added in .Net 4.0?

Looks that way: https://msdn.microsoft.com/en-us/library/dd783876(v=vs.110).aspx
.NET Framework
Available since 4.0
So we should be able to use it in FSharp.Core :)


icon.png not consistent with logo.png

In the vss-extension.json the following line:
"path": "images/logo.png", "addressable": true
should be
"path": "images/icon.png", "addressable": true
To be consistent

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

ID: 14955ee9-29f2-46fe-3a8d-a42666f53ffc
Version Independent ID: 5d417cd0-a671-ee30-8fca-5f8b0addd328
Content
Content Source
Service: unspecified

Ah, great catch @StevenTCramer , implementing that change now!


Can't Launch ClickCrystals

Fabric loader and fabric api are all up to date
Game crashes every time you try to launch it
Exit Code is 255

Sure I'll take a look at it, please send the crash log to either here or the ClickCrystals discord server. Thank you for reporting this to me.

https://github.com/ItziSpyder/ClickCrystals/assets/141660693/5e231dde-13bf-4217-8f78-24ea1a4acdb3

https://github.com/ItziSpyder/ClickCrystals/assets/141660693/5e231dde-13bf-4217-8f78-24ea1a4acdb3

I am sorry but sending a screenshot of the game crashed screen doesn't tell me much information. Can you please check crash logs? It should be under .minecraft/crash_reports.

closed as no reply in over a month


Feat/centered large asset

Context
Link to Notion ticket
Testing (tester)
The reviewer should check on this branch:

The code
The component in Bookshop browser
The site in CloudCannon (link here)

Before merge (PR owner)

[ ] Delete the test site in CloudCannon
[ ] For "generic" components only: remove - content_blocks from structures in the YAML file (this was added for testing).

@AlyshaNolan this looks great - as per our discussion, I will make these changes:

removed the content_alignment preview option from the yml file
moved the if statements in the HTML outside of the elements, so that they disappear as well, not just the content

Otherwise, happy to accept :)


Rewrite this without vue-template-compiler and vue-server-renderer

how is it going for this issue?

@egoist I'm really interested in this, did it go anywhere?


IE problem using directive to uppercase input v-model

Version
2.5.2
Reproduction link
https://jsfiddle.net/ktycksy6/
Steps to reproduce
Using Internet Explorer, type on the input anything that ends with a letter [eg: asdas, 1234r, w1e2d] and remove the focus from the input.
What is expected?
Input keeps new value typed.
What is actually happening?
The input value goes back to previous value.

I'm working on a project where some input[type=text] values must be uppercase, and so, I created a directive that as the user types a value it would automatically uppercase the letter.
It works on Chrome, by the way, but it doesn't on IE.

While the behaviour may seem weird, you should never directly modify the value of the input if you use v-model because it's splitting up the source of truth.
Instead, you should use a computed property with a setter that sets the text to an uppercase value: https://jsfiddle.net/s3qrsnyp/
if you want to keep the lazy behaviour, you will have to play with two variables

Thanks @posva for your reply.
I'll do as you say.


Bold is not applying for a text in Choice Prompt - BOT Framework

We have various prompts in BOT Framework and trying to apply the bold for text by using double asterisk symbols (**) and it is applying for all prompts except for Choice Prompt. How can we apply the same bold text style for Choice Prompt as well?
It is reddening like blow:

This bold is working as expected in BOT Framework Emulator but not in Web Chat.

Thank you for the question, @Ramesh-Pachunuri
That doesn't look like any choice prompt I've ever seen. What list style are you using? Can you provide the code you're using to instantiate and begin the choice prompt, as well as screenshots of the messages displayed in Emulator and Web Chat?

@v-kydela  We have 5 style sheets found here and I am using HeroCard but the bold is applying in emulator but not in webchat. I tried with remaining 4 styles as well but none of them are working properly.
In Web Chat :

In Emulator:

@Ramesh-Pachunuri - Thank you for the screenshots. It looks like Web Chat isn't rendering Markdown in the text of a hero card, but it's strange that it would work in Emulator since Emulator uses Web Chat. Can you provide the code I asked for so we can try reproducing the problem on our end? A minimal example would be best.

@v-kydela

In GetPromptOptions I am applying HeroCard style.

@Ramesh-Pachunuri - Please provide code as text and not screenshots

@v-kydela
internal async Task SeverityStepAsync(
WaterfallStepContext stepContext,
CancellationToken cancellationToken)
{
var botSession = stepContext.Options as BotSession;
        if (botSession.Incident.Severity == null)
        {
            var msg = ConfigStringResolver.Instance.GetConfigString("AskSeverity");
            var option1 = ConfigStringResolver.Instance.GetConfigString("Severity3Msg");
            var option2 = ConfigStringResolver.Instance.GetConfigString("Severity2Msg");

            this.Logger.LogBotMessage(botSession, msg);
            return await stepContext.PromptAsync(
                nameof(ChoicePrompt),
                PromptBuilder.GetPromptOptions(
                    stepContext.Context.Activity, msg, option1, option2),
                cancellationToken);
        }

        return await stepContext.NextAsync(botSession, cancellationToken);
    }

GetPromptOptions method to apply style sheet.
public static PromptOptions GetPromptOptions(
Activity activity,
string replyMsg,
string option1,
string option2,
ListStyle style = ListStyle.HeroCard)
{
var choices = GetChoiceList(option1, option2);
return CreatePromptOptions(activity, replyMsg, choices, style);
}

@v-kydela Yes, we are reading the text from JSON file as a string. Sure I will try your suggestion as well. But if the bold is applying in emulator then it should also apply for Web Chat as well right? Why only having an issue with Web Chat?

@Ramesh-Pachunuri - It's possible to add components to or remove components from Web Chat. There are a few different Web Chat "bundles" which have different components. Not all Web Chat implementations have Markdown, and not all Web Chat implementations have cards. Can you provide your HTML so we can see how your Web Chat is configured?
It's worth noting that Markdown not working in cards has been a problem in the past, but it should work now. I should have asked this earlier, but can you render Markdown in normal activity text outside of a card? The fact that it's in a card may be a red herring, so we should determine that.

@v-kydlea if it can show Adaptive Card and hero card, it must be full bundle, which includes Markdown.

@v-kydela :  Please let me know if you have the availability to discuss on teams?

@v-kydela correct, AC can be added like in the Markdown sample. I think compulim was just pointing out that it's not available by default.

@Ramesh-Pachunuri - Are you still working on this?

@v-kydela : I fixed the issue by moving the text out of the card.

Can you please share the sample code which fixes this issue?

Can you please share the sample code which fixes this issue?


ABP settings not available for users that are not global admins

Hi, I have found a bug with permissions.
If a user is a global admin he can set ABP settings, but if the user is Organisation admin - ABP settings is not available for him (grey).

Thanks for reporting this. I've confirmed this issue and will fix it asap :-)

Hmmm, I've checked this but still issue is there.

Sorry, my wrong, it works.


Slides

Hi @grantmcdermott ,
Thanks again for the really cool workshop — already starting to integrate it in my workflow, and it's working really well! I think you mentioned at some point you were going to include your slides? I wanted to check the slide you had on the way columnar data storage protocols and DuckDB-style data base engines worked well together.
Cheers

Thanks @vronizor that’s great to hear. I definitely plan to add the slides (plus a few more changes that I wanted to add). But unfortunately I’ve been slammed at work these last few weeks, so have had to push all hobbyist/OSS stuff to the backburner. I’ll get to it at some point in the next few weeks, though.

Closed by f4f8357ccda6e393b334f315349b02ee3137e22c
(Sorry that this took me so long)


Properly support nDPI 1.8

Trying to use ljndpi with nDPI 1.8 always causes the following error to be printed to stderr.
[NDPI] ndpi_init_protocol_defaults(missing protoId=226)
INTERNAL ERROR: not all protocols have been initialized

Also, there are high chances that ndpi/protocol_ids.lua may need to be recreated for version 1.8 — probably the best way to go is having a different table of protocol identifiers per nDPI version, and try to detect the version of libndpi.so being loaded.

The above error message seems to be an issue of the of the Arch PKGBUILD for ndpi 1.8: building the library manually from the 1.8 tag, or using the ndpi-git PKGBUILD makes the internal error message go away.

As of 782a6b606cdf3e876fc9641e031e3822a9ca1422 nDPI 1.8 is supported, closing.


Point labelling

Hello,
I would be interested in the option of simply adding points for labelling, would it be easily possible ?
Thank you

This tool purposely focused on areas rather than points. No plans to add support for points at this time. Note that there are a lot of other free tools that can easily be used for points, such as https://geojson.io/


Docker dev

Only dockerRunner.sh, Dockerfile.dev, and server/gradle.build were changed as part of this work. The rest of the file changes to resources/* and server/* are from the master branch of HL7-Davinci.  These changes can be filtered down under "Files Changes" > "Changes from all commits" > Holding Shift + clicking the last four commits (all by Sahil Malhotra)


Add readiness to PR template

Added a section to the top of the PR template presenting checkboxes to
mark the "readiness" of the merge.
No QA steps taken, no related issue.
Signed-off-by: Katrina Prosise<EMAIL_ADDRESS>Overview
Current PR template does not include options to state readiness, and was suggested in PR #380.
Adding this option explicitly may prevent undesired merges.
Checklist
Optional. Add a 'x' to steps taken.
You can fill this out after opening the PR. "Did I..."

[ ] Run spelling and grammar check, preferably with linter.
[x] Avoid changing any header associated with a link/reference.
[x] Step through instructions (or ask someone to do so).
[x] Review for wordiness
[x] Match tone and style of page/section.
[ ] Run make linkcheck.
[ ] View HTML in a browser to check rendering.
[x] Use semantic newlines.
[x] follow best practices for commits.

[x] Descriptive title written in the imperative.
[x] Include brief overview of QA steps taken.
[x] Mention any related issues numbers.
[x] End message with sign off/DCO line (-s, --signoff).
[x] Sign commit with your gpg key (-S, --gpg-sign).
[x] Squash commits if needed.

[x] Request PR review by a technical writer and at least one peer.

Comments

[x] Ready to merge (pending PR review).

Docs for 3f1b719409295f82e81a89565e8d6024e378876c are browsable at: https://ci.foundries.io/projects/fio-docs/builds/1459/docs/artifacts/html/index.html

LGTM
It would be great to have a similar template for code repos.

@MrCry0 I would be happy to help.
Code repo templates that include docs and QA/testing stuff would be helpful.


Search in storefinder always returns identical results

Searching anything in store finder always returns the same list with 23 stores.

checked in postman: no matter what query we use backend response is the same (23 items)

Should also adjust the "storefinder e2e test" if needed.


There is a problem with card display.

After entering the interface, the card cannot be clicked. When the mouse moves over it, it starts to flicker. After a longer time, the card is misaligned.
My device is Macbook Air M1, the plugin is the newest, and the theme is default.
https://github.com/user-attachments/assets/7a659848-1bbc-4d88-8af4-ab3537402a83

Thats a strange error, I didnt faced such an issue, I am on latest Obsidian and tested with the latest version of Cards View.

I am currently working on enhancing this plugin further and have submitted the new developed version to the author of this plugin. But meanwhile, if you are comfortable you can try installing the Beta version and check if you are facing the same issue : Cards View (Beta), its easy to install using BRAT, check the installation section.


Add Rancher app for install

This adds the rancher app for install. For now it supports installing either generating TLS certs self-signed by rancher (--ingress-source rancher) or by using Let's Encrypt (--ingress-source letsEncrypt default value).

Description
Motivation and Context

[x] I have raised an issue to propose this change (required)
Actually was raised by #79 and then gave me permission to take it over in #81

How Has This Been Tested?
Deployed to a new cluster doing:
./arkade install rancher --hostname arkade.gq --letsencrypt-email<EMAIL_ADDRESS>--replicas 1

./arkade install rancher --hostname <domain> --ingress-source rancher --replicas 1

And later could access the rancher interface at <domain>
Types of changes

[ ] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

[x] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[x] I've read the CONTRIBUTION guide
[x] I have signed-off my commits with git commit -s
[ ] I have added tests to cover my changes.
[ ] All new and existing tests passed.

[x] I have tested this on arm, or have added code to prevent deployment

@saiyam1814 please could you take a look and compare to #81? The main blocker on #81 was not using helm.
@Waterdrips can you take a look at the approach and give your take?

Checking if I understand, you mean to use this?
		lokiOptions := types.DefaultInstallOptions().
			WithNamespace(namespace).
			WithHelmPath(path.Join(userPath, ".helm")).
			WithHelmRepo("loki/loki-stack").
			WithHelmURL("https://grafana.github.io/loki/charts").
			WithOverrides(overrides)

@saiyam1814 please could you take a look and compare to #81? The main blocker on #81 was not using helm.
@Waterdrips can you take a look at the approach and give your take?

Hostname was the issue earlier for which we were blocked so unless we give a hostname Rancher won't get deployed. I was thinking of a way to deploy it even for development purposes. But now the hostname becomes mandatory else it returns an error. This might be like if you have hostname then you can try the rancher app else not.
Also Cert-manager check is missing, as per Rancher Docker Cer-manager has to be installed first. So arkade install cert-manager if not already there should be included.

I've added the last --ingress-source option secret for using your own certificates and a couple flags to create the secrets as explained by Rancher
@Waterdrips made the change to use chart_app let me know if its what you expected
@saiyam1814 regarding the domain, it is required because Rancher requires it. But you can put anything and then set it in your /etc/hosts/, no need to actually own a domain.
One thing I'm not sure is how to check for cert-manager before installing and install it if not present.
PS: I forgot to sign-off a middle commit, should I do something about it?

PS: I forgot to sign-off a middle commit, should I do something about it?

If you could squash the 3 commits into 1 signed commit that would be preferable.
something like
 git rebase -i HEAD~3 and follow the instructions in the interactive rebase

How popular is --ingress-source for a self-signed cert vs. LE?

No idea, on which is used more. Personally I've always used LE

I've added the last --ingress-source option secret for using your own certificates and a couple flags to create the secrets as explained by Rancher
I tested it by creating my own certificates and CA following this guide
@Waterdrips made the change to use chart_app let me know if its what you expected
@saiyam1814 regarding the domain, it is required because Rancher requires it. But you can put anything and then set it in your /etc/hosts/, no need to actually own a domain.
One thing I'm not sure is how to check for cert-manager before installing and install it if not present.
PS: I forgot to sign-off a middle commit, should I do something about it?

I think the best way to check for cert-manager would be to check for arkade install cert-manager (if it's done then proceed)

Let's get the first release out without the check

One thing I'm not sure is how to check for cert-manager before installing and install it if not present.

We can add a mention in the app's description that cert-manager is required, and think about this more after.
Your commits will need rebasing onto master, so please could you do that? Make sure you don't introduce a merge commit at the same time. I tend to use git pull origin master --rebase myself.

@Waterdrips any further comments at this time?

Thank you @AminArria
Could you rebase this PR again please?

@alexellis  rebase done :D

@AminArria are you still intrested?
May I ask you to rebase the PR again?

Hi @Shikachuu I'll do the rebase later this weekend

Hey @AminArria are you still intrested to do that rebase?

@AminArria are you still interested in completing this app or do you want to close your PR?

Hey @alexellis yeah sorry don't have the time for it, I'll close it


Add type hinting to secrets

What is the context of this PR?
This PR will add type hinting to secrets
Also removed an odd char on the end of a line in test_feedback.py
How to review

Changes make sense
Run run_mypy.sh see that theres no errors

Checklist

[ ] New static content marked up for translation
[ ] Newly defined schema content included in eq-translations repo

 Add type hinting for secrets (1 SP)


Issue: Role is not available anymore  hetzner/create_context

Issue
This role does not exist anymore: https://github.com/snowdrop/k8s-infra/blob/master/hetzner/ansible/hetzner-init-context.yml#L17
  roles:
    - role: hetzner/create_context
      context_name: "{{ hetzner_context_name }}"

Roles path was not defined correctly


LDAP Group Sync Doc

This is a large one.  Appreciate your review and feedback.

Thank you so much @mkraft and @jasonblais!  I believe I have all your feedback incorporated.  Please let me know if there is anything else you see that could be improved.

Thank you so much @lfbrock !  Appreciate your perspective with fresh eyes.  Please let me know if there is anything else that may be confusing.  I have added the items you want to discuss on our 1-1 agenda.

There is just one last thing you recommend that is being confirmed by testing - I will add as soon as I have it available.  Thanks again for your review @lfbrock !


Jobs only are scheduled to one node while most of the nodes are idle

Inspecting the node info yields the following results. QmT9AvEq, QmT69eMH, and Qmd1LXFU are running outdated versions of the binary and may not be accepting on jobs due to this. Meaning there are only 5 nodes capable of accepting work. It's also worth noting that QmXaXu9N is too running jobs, although it is not as tasked as QmdZQ7Zb. Lastly, and this is a guess, lexicographical nodeID QmdZQ7Zb sorts before QmXaXu9N, so for jobs that require a concurrency of 1 it may be returned first from the listed nodes. QmdZQ7Zb isn't necessarily overloaded either so it seems reasonable for it to accept work given the above usage.
It would be helpful to understand the nature of the jobs being ran by QmdZQ7Zb
{
  "key": "QmT9AvEq",
  "gitversion": "v0.3.23",
  "labels": {
    "owner": "docs-quick-start"
  },
  "RunningExecutions": 0,
  "EnqueuedExecutions": 0
}
{
  "key": "QmT69eMH",
  "gitversion": "v0.3.25",
  "labels": {
    "Architecture": "amd64",
    "GPU-0": "NVIDIA GeForce RTX 3090",
    "GPU-0-Memory": "24576 MiB",
    "GPU-1": "NVIDIA GeForce RTX 3090",
    "GPU-1-Memory": "24576 MiB",
    "Operating-System": "linux",
    "env": "prod",
    "git-lfs": "False",
    "name": "saturnia_len20"
  },
  "RunningExecutions": 0,
  "EnqueuedExecutions": 0
}
{
  "key": "Qmd1LXFU",
  "gitversion": "v0.3.25",
  "labels": {
    "Architecture": "amd64",
    "GPU-0": "NVIDIA A10",
    "GPU-0-Memory": "23028 MiB",
    "Operating-System": "linux",
    "git-lfs": "False"
  },
  "RunningExecutions": 0,
  "EnqueuedExecutions": 0
}
{
  "key": "QmXaXu9N",
  "gitversion": "v0.3.28",
  "labels": {
    "Architecture": "amd64",
    "Operating-System": "linux",
    "git-lfs": "True",
    "owner": "bacalhau"
  },
  "RunningExecutions": 5,
  "EnqueuedExecutions": 0
}
{
  "key": "QmYA2p8Q",
  "gitversion": "v0.3.28",
  "labels": {
    "Architecture": "amd64",
    "Operating-System": "linux",
    "git-lfs": "False",
    "who": "FORREST"
  },
  "RunningExecutions": 0,
  "EnqueuedExecutions": 0
}
{
  "key": "QmYgxZiy",
  "gitversion": "v0.3.28",
  "labels": {
    "Architecture": "amd64",
    "Operating-System": "linux",
    "git-lfs": "True",
    "owner": "bacalhau"
  },
  "RunningExecutions": 0,
  "EnqueuedExecutions": 0
}
{
  "key": "QmdZQ7Zb",
  "gitversion": "v0.3.28",
  "labels": {
    "Architecture": "amd64",
    "Operating-System": "linux",
    "git-lfs": "True",
    "owner": "bacalhau"
  },
  "RunningExecutions": 3,
  "EnqueuedExecutions": 0
}

The above json was produced using the following jq command: jq 'to_entries | sort_by(.value.BacalhauVersion.gitversion) | .[] | {key: .key[0:8], gitversion: .value.BacalhauVersion.gitversion, labels: .value.Labels, RunningExecutions: .value.ComputeNodeInfo.RunningExecutions, EnqueuedExecutions: .value.ComputeNodeInfo.EnqueuedExecutions}'


EventBus should not extend StreamableMessageSource

The EventBus currently extends the StreamableMessageSource interface. However, this would require that the Events are reliably accessible for a longer period of time (preferably indefinite). This is generally the behavior of the EventStore.
Therefore, extending the StreamableMessageSource should be done by the EventStore, instead.
As a side-effect, defaulting to tracking processors by the EventProcessingConfiguration will not work if the message source is an EventBus (and not EventStore). Therefore, the default should become dependent on the type of message source provided. The configuration must default to tracking when the message source implements StreamableMessageSource.

Closing this issue as I am assuming it has been resolved in commit 23abcf7.


copr: add vectorize substring_2_args, substring_3_args

Signed-off-by: FateTHarlaown<EMAIL_ADDRESS>
What problem does this PR solve?
add vectorize substring_2_args, substring_3_args
Issue Number:  #9016
Problem Summary:
What's Changed:
add push-down & test of substring_2_args, substring_3_args
Check List
Tests

Unit test

Side effects
Release note

/cc @andylokandy

/merge

/merge


The question about 'gen_result' and 'greedy_res'?

Hi, ruotian,
I am confused why the 'gen_result' in the (line1)[https://github.com/ruotianluo/self-critical.pytorch/blob/master/train.py#L125] and 'greedy_res' in the (line2)[https://github.com/ruotianluo/self-critical.pytorch/blob/master/misc/rewards.py#L32] are different.
I find both of them run the same code, 'model.sample()'.
Another issue is that I run the code 'greedy_res, _ = model.sample(Variable(fc_feats.data, volatile=True), Variable(att_feats.data, volatile=True))' twice, and I get two different outputs. Can you explain that? Thanks very much.

Difference is at sample_max
Because the model is in training mode, so the dropout will produce different results.

In my opinion, the 'greedy_res' should be extracted in the inference. Maybe it is better to turn off the training when computing the 'greedy_res'. Isn't it?

It may. You can potentially try, see how the results differ.

Since I find the original paper said that "the reward obtained by the estimated sentence under the test-time inference procedure(greedy inference depicted)" in the Figure1.

OK, I will try.


maven project without package name fails

creates this:
package ;
import java.io.IOException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
public class HelloAppEngine extends HttpServlet {
public void doGet(HttpServletRequest request, HttpServletResponse response)
throws IOException {
response.setContentType("text/plain");
response.getWriter().println("Hello App Engine!");

}
}
either archetype needs to be changed or package made required

When using the archetypes from the command line the package is set to the group so there doesn't appear to be a way to have a null package there. We should probably do somehting similar here.


[Docs] Google search console verification

The current Google verification file is the one from keptn.github.io. This means it serves no purpose in this repository.
If we want to use Google Search Console to improve our SEO and ensure accessibility, we must change it. We do have two options:

a file within the repository, as it is now, with the Google verification
a TXT entry on the DNS record

If we set this up, we should also grant certain individuals access to this information (please extend this list)

@keptn-bot
@thisthat
@mowies
@aepfli (as i am focusing my efforts on this)

Proposal
Changing to DNS record reduces the files within the repository - hence, it will also reduce the clutter and remove unimportant files.
Agreement:

[ ] do we want to track: yes
[ ] how do we want to track: via file within the repo

I don't think we really need the google console

We used in the past to know on which website pages we should put more focus on improving our documentation

Did this become important again with the removal of scarf?


mix tilex:hdb: Copy Heroku-hosted DB to app DB

The output from the fetch_heroku_dsn function, which runs:
  heroku run -a <heroku_app> --no-notify --no-tty -x sh -c 'echo $DATABASE_URL'

Is:
 ›   Warning: heroku update available from 7.16.0 to 7.16.5
Running sh -c "echo $DATABASE_URL" on ⬢ tilex-staging... up, run.7607 (Free)
postgres://<someuser>:<somepass>@<databaseurl>/<databasename>

The warning throws the parse_dsn function off, and that function returns an :error atom.

@chriserin Thanks for catching that, I've updated to separate stderr from stdout in the checked commands. It's nice to see the entire output in the Logger message, but I'm not seeing a way to capture stderr with System.cmd/3, so those errors will be interleaved with task output as previously.

Thank you! :heart: :yellow_heart: :green_heart: :blue_heart: :purple_heart: -JW


[docs] GettingStarted: Send readers to ci.swift.org for the min Xcode version

This inline Xcode version is a maintenance bother with no apparent justification, and shall it ever fall out of sync (like right now), it can start causing build failures for newcomers.

@swift-ci please smoke test


Issue in generating multiple vendor bundle

I am new to webpack, I am using webpack3 with angular 4. I have added dependencies in package.json. I have mentioned dependencies below. For each dependency i want to create respective vendor bundle. Like i have 5 dependencies i want 5 vendor bundles.
"dependencies": {
    "@angular/common": "4.4.6",
    "@angular/compiler": "4.4.6",
    "@angular/core": "4.4.6",
    "@angular/forms": "4.4.6",
    "@angular/http": "4.4.6",
    "@angular/platform-browser": "4.4.6",
    "@angular/platform-browser-dynamic": "4.4.6",
    "@angular/router": "4.4.6",
    "codelyzer": "^4.1.0",
    "core-js": "2.5.3",
    "rxjs": "5.5.6",
    "zone.js": "0.8.9"
  }

Please help me in creating multiple bundle for each dependency.
if possible please share the pros and cons with this approach.
Thanks in advance.

Please submit support requests and questions to StackOverflow using the tag [webpack]. StackOverflow is better suited for this kind of support. The issue tracker is for bug reports and feature discussions. See also our CONTRIBUTING guidelines.