build problem: ‘AV_CODEC_ID_AV1’ undeclared

on debian strech 32
ninja: Entering directory `x'
[14/62] Compiling C object app/scrcpy.p/src_demuxer.c.o
FAILED: app/scrcpy.p/src_demuxer.c.o
cc -Iapp/scrcpy.p -Iapp -I../app -I../app/src -I/usr/include/i386-linux-gnu -I/usr/include/SDL2 -I/usr/include/libusb-1.0 -flto -fdiagnostics-color=always -DNDEBUG -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -std=c11 -O3 -D_REENTRANT -MD -MQ app/scrcpy.p/src_demuxer.c.o -MF app/scrcpy.p/src_demuxer.c.o.d -o app/scrcpy.p/src_demuxer.c.o -c ../app/src/demuxer.c
../app/src/demuxer.c: In function ‘sc_demuxer_to_avcodec_id’:
../app/src/demuxer.c:36:20: error: ‘AV_CODEC_ID_AV1’ undeclared (first use in this function)
return AV_CODEC_ID_AV1;
^~~~~~~~~~~~~~~
../app/src/demuxer.c:36:20: note: each undeclared identifier is reported only once for each function it appears in
[16/62] Compiling C object app/scrcpy.p/src_icon.c.o
ninja: build stopped: subcommand failed.
thanks for any suggestions

Your FFmpeg is VERY old. What is the result of scrcpy --version?
Does it work with this additional diff?
diff --git a/app/src/compat.h b/app/src/compat.h
index 00cb72045..9209dd31c 100644
--- a/app/src/compat.h
+++ b/app/src/compat.h
@@ -25,6 +25,12 @@
 # define SCRCPY_LAVF_REQUIRES_REGISTER_ALL
 #endif

+// Not documented in ffmpeg/doc/APIchanges, but AV_CODEC_ID_AV1 was added has
+// been added by FFmpeg commit d42809f9835a4e9e5c7c63210abb09ad0ef19cfb
+// (included in tag n3.3).
+#if LIBAVFORMAT_VERSION_INT >= AV_VERSION_INT(57, 89, 100)
+# define SCRCPY_LAVC_HAS_AV1
+#endif

 // In ffmpeg/doc/APIchanges:
 // 2018-01-28 - ea3672b7d6 - lavf 58.7.100 - avformat.h
diff --git a/app/src/demuxer.c b/app/src/demuxer.c
index 5a613505d..3ed4cfce6 100644
--- a/app/src/demuxer.c
+++ b/app/src/demuxer.c
@@ -33,7 +33,12 @@ sc_demuxer_to_avcodec_id(uint32_t codec_id) {
         case SC_CODEC_ID_H265:
             return AV_CODEC_ID_HEVC;
         case SC_CODEC_ID_AV1:
+#ifdef SCRCPY_LAVC_HAS_AV1
+            LOGE("AV1 not supported by this FFmpeg version");
+            return AV_CODEC_ID_NONE;
+#else
             return AV_CODEC_ID_AV1;
+#endif
         case SC_CODEC_ID_OPUS:
             return AV_CODEC_ID_OPUS;
         case SC_CODEC_ID_AAC:

ffmpeg:
libavutil      55. 34.101 / 55. 34.101
libavcodec     57. 64.101 / 57. 64.101
libavformat    57. 56.101 / 57. 56.101
libavdevice    57.  1.100 / 57.  1.100
libavfilter     6. 65.100 /  6. 65.100
libavresample   3.  1.  0 /  3.  1.  0
libswscale      4.  2.100 /  4.  2.100
libswresample   2.  3.100 /  2.  3.100
libpostproc    54.  1.100 / 54.  1.100
with the additional diff I have same output
MESON:
The Meson build system
Version: 0.56.2
Build type: native build
Project name: scrcpy
Project version: 2.0
C compiler for the host machine: cc (gcc 6.3.0 "cc (Debian 6.3.0-18+deb9u1) 6.3.0 20170516")
C linker for the host machine: cc ld.bfd 2.28
Host machine cpu family: x86
Host machine cpu: i686
Found pkg-config: /usr/bin/pkg-config (0.29)
Run-time dependency libavformat found: YES 57.56.101
Run-time dependency libavcodec found: YES 57.64.101
Run-time dependency libavutil found: YES 55.34.101
Run-time dependency libswresample found: YES 2.3.100
Run-time dependency sdl2 found: YES 2.0.5
Run-time dependency libavdevice found: YES 57.1.100
Run-time dependency libusb-1.0 found: YES 1.0.21
Checking for function "strdup" : YES
Checking for function "asprintf" : YES
Checking for function "vasprintf" : YES
Checking for function "nrand48" : YES
Checking for function "jrand48" : YES
Checking for function "reallocarray" : NO
Header <sys/socket.h> has symbol "SOCK_CLOEXEC" : YES
Configuring config.h using configuration
Build targets in project: 3
Found ninja-1.7.2 at /usr/bin/ninja
NOTICE: You are using Python 3.5 which is EOL. Starting with v0.57, Meson will require Python 3.6 or newer
NINJA:
ninja: Entering directory `x'
[15/62] Compiling C object app/scrcpy.p/src_demuxer.c.o
FAILED: app/scrcpy.p/src_demuxer.c.o
cc -Iapp/scrcpy.p -Iapp -I../app -I../app/src -I/usr/include/i386-linux-gnu -I/usr/include/SDL2 -I/usr/include/libusb-1.0 -flto -fdiagnostics-color=always -DNDEBUG -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -std=c11 -O3 -D_REENTRANT -MD -MQ app/scrcpy.p/src_demuxer.c.o -MF app/scrcpy.p/src_demuxer.c.o.d -o app/scrcpy.p/src_demuxer.c.o -c ../app/src/demuxer.c
../app/src/demuxer.c: In function ‘sc_demuxer_to_avcodec_id’:
../app/src/demuxer.c:40:20: error: ‘AV_CODEC_ID_AV1’ undeclared (first use in this function)
return AV_CODEC_ID_AV1;
^~~~~~~~~~~~~~~
../app/src/demuxer.c:40:20: note: each undeclared identifier is reported only once for each function it appears in
[17/62] Compiling C object app/scrcpy.p/src_file_pusher.c.o
ninja: build stopped: subcommand failed.
thanks!

with the additional diff I have same output

Oops, I reversed the condition. I updated the diff in my previous comment, please re-test.

yes, now works :)
thank you!! and happy Sunday

Pushed on dev branch: 0f3af2d20b201a07ad999699e07e59cf8066e32f


Transfer tokens for client

This change is

Coverage increased (+1.3%) to 73.389% when pulling 09786a15e933f07cf673130a3f72d412fd7019c0 on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-2.06%) to 70.0% when pulling 95fb158ed5fe7da2357db58048db1f54ab8664ca on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-2.2%) to 69.87% when pulling 840b36252e789a8acf4ed5984c393a6c436d62e0 on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-0.9%) to 71.2% when pulling 665aebcd07668406a0da7d31cb8976b4a5084c99 on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-0.9%) to 71.2% when pulling 44bb8ef21150dbf4555ba91102ea7a104a36671c on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-0.9%) to 71.2% when pulling 44bb8ef21150dbf4555ba91102ea7a104a36671c on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-2.4%) to 69.643% when pulling 66ba13b3a48977a04781c7df4b25da85c31e5a60 on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-1.0%) to 71.059% when pulling 266bd77f372339a053912e18fa3dd2d515b0e65d on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-1.07%) to 70.984% when pulling e437a138f030f9cea2a44719715ca3a75ad6e768 on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage decreased (-0.04%) to 72.021% when pulling b43ae3f0e76328db3771f2ae5e521105f4f80a58 on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage increased (+2.3%) to 74.352% when pulling 0df01a94a5140caf39198e6033ea77aab29e8d84 on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage increased (+2.02%) to 74.084% when pulling 330f87ad974d8df6a1810bab359fbb0e43b6c08d on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Coverage increased (+1.7%) to 73.74% when pulling 3d6cca18a0a2c96c7d4c659190aaadb5a527eacf on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.

Review status: 0 of 7 files reviewed at latest revision, 1 unresolved discussion, some commit checks failed.

openprocurement_client/change_owner.py, line 14 at r8 (raw file):
Previously, Leits (Andrew Leitsius) wrote…
> Це має бути `_change_ownership`
>
> Йому потрібно передавати трасфер, ідентифікатор об'єкту і шлях до об'єкту
>
> У середині він буде формувати тіло запиту і шлях як `'{}/{}/ownership'.format(self.prefix_path, (тут шлях, який ти передаєш))`

Зробив.  І поправив контракт

Comments from Reviewable

Review status: 0 of 7 files reviewed at latest revision, 1 unresolved discussion, some commit checks failed.

openprocurement_client/change_owner.py, line 14 at r8 (raw file):
Previously, ivanromakh wrote…
> Зробив.  І поправив контракт

Поки буду думати як отримати trasfer який видається при створенні contract, bid ...

Comments from Reviewable

Coverage increased (+1.7%) to 73.74% when pulling 6e5d8eddda7efa711063ba07da34d1cbae022c3e on ivanromakh:a105762131939514_transfer_tokens into d0dd407a2c71126092fe7c3fc1c5377b8d9c844e on openprocurement:master.


Add onboarding tasks for users who create workspaces outside of onboarding or core invite flows

Proposal: Add onboarding tasks for users who create workspaces outside of onboarding or core invite flows that lead to workspaces (IOUs/Invoices).
For background — We’ve added onboarding for most users already in our app. This is the different initiatives we’ve addressed so far:

Stage 1 onboarding - Adding basic onboarding that 1) has a user select their intention that led to specific instructions from Concierge.
Stage 2 onboarding - used the intention in onboarding to create specific tasks design to train the user on the best steps to use Expensify and thus convert.
Stage 3 onboarding - used the intention and tasks implemented to apply to key viral use cases so users who are taken to the invite action, rather than an intention selector, also get onboarding tasks. In the case of a user being invited via an IOU/Invoice, if they pay via BBA we input the manage my team’s expenses tasks in their onboarding steps and set their NVP accordingly.

Problem: Many users who have not selected Manage my team's expenses end up creating workspaces and then overwhelmingly abandon the product immediately after they create the workspace.
The primary flows we see experiencing this problem that are not covered by onboarding or Stage 3 are:

Users who select Global Create > Track > and then either categorize or share it with their accountant using the actionable whispers
Users who did not previously select Manage my team’s expenses in onboarding who select New Workspace in Global Create or Account Settings > Workspaces > New workspace

Solution: Update our onboarding so that if a user creates their first workspace and has not seen the manage my team’s expenses tasks, we’ll add the tasks (and GBRs) to setup their workspace in their Concierge DM.

Most users will already have onboarding tasks in their Concierge DM. We will not remove those, we’ll just add to them as they are likely applicable and update the NVP to the manage my team’s NVP.
Some users will not have tasks already created (users who select Something else or some invited users might not) so if that’s the case we’ll send the manage my team’s tasks/copy and set the users intent in the NVP.

I needed to get some mocks made so am working with @dubielzyk-expensify on that here: https://github.com/Expensify/Expensify/issues/428250

Added mocks over there: https://github.com/Expensify/Expensify/issues/428250

We're ready for HL reviews on a short design doc that builds on existing onboarding cases!
High-Level design doc
Assigning the review label now. This is a HIGH so leaving it as weekly.

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc! Comments within.

Latest update here, we're going to move to detailed design: https://expensify.slack.com/archives/C07HPDRELLD/p1727392947254819?thread_ts=1727143590.177379&cid=C07HPDRELLD

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

We're in the final stages of testing on this. I think it should be closed out soon.

Correction, we're not in testing on this. I updated this thinking it was stage 3 onboarding. @francoisl is still working on the detailed design which should be out soon.

Detailed section is ready for review, going to reapply the label to get reviewers assigned.

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

Oops, closed this issue instead of my issue, sorry.

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

I have read and reviewed this Design Doc!

We have a couple more detailed reviews but we're moving to implementation in the next day or so.

I have read and reviewed this Design Doc!

@francoisl is working on the detailed. He has some predesign questions last week but we're making regular progress on this. We should be sending it out sometime this week, in the next couple days ideally.

This is being worked on and is in implementation.

Being worked on still. Issues created so we're in implementation.

@francoisl is looking for C+ to lead the front end so he can do the back end.

Latest update: https://expensify.slack.com/archives/C07HPDRELLD/p1733792917263319?thread_ts=1733789708.497349&cid=C07HPDRELLD

Backend implementation is ~85% done, waiting on a Web-E deploy to unblock failing tests on an Auth PR. Then one more smaller change that should be ready for review by EOD (from Monday).
Manan is working on the front-end changes.

Being worked on daily.


Avoid accessing invalid iterator.

@umar456 @antiagainst @AWoloszyn @dneto0 @Qining PTAL

The iterator should still be valid after the if statement. The iterator that is incremented is part of the block_info struct and not the staged vector.

It's actually top that's invalid, due to staged.emplace_back() on line 90.

'top' is a reference to the last block_info element and not an iterator.

Yes, sorry -- wrong title.  But the bug is real, and this is the fix.

I don't understand the bug. I don't create an iterator for any of the containers being updated in that if statement.

emplace_back() reallocates staged memory, invalidating the top reference.  Dereferencing top after that is invalid, and it raises an exception in the Windows debug build.

Ahh gotcha. Makes sense. +2


Add Modern UI Modded to DKG Theme Modifier

Per your DM on Discord, I've generated a update to Modern UI Modded with a unique theme ID so you can add it when you have time.
Also since your working on 1.5.0 of Modern UI, it would be best to leave Modern UI Modded settings in DKG Theme Modifier at 1.4.1 when you release that update, as while I saw your video on it and have some ideas about how I might change details view in modded the changes wont be made till sometime after you've released that update.
ID= PlayniteModernUIModded
Release Link= https://github.com/HexSupernatural/PlayniteModernUIModded/releases/tag/v3.5.0

Added support in v2.8.0 that's just released. You will need the same constants as the current Modern UI so that resetting to defaults etc works correctly. Grab a copy of the contstants from the Modern UI v1.5.0 which has just released.


onDataString can mangle multi-byte characters

onDataString is easy to use but is unfortunately a subtle foot-gun.
This function calls the underlying node API returning a buffer, and then calls Buffer.toString on the result.
But if a character would span two data events, each Buffer.toString will replace the initial/trailling code units with the replacement character.
As it stands, onDataString should be documented with a clear warning, it is not suitable for general purpose use but only streams that are either guaranteed to have single-byte encoded characters/known short lengths.
The comment on setEncoding unfortunately recommends this:

"Where possible, you should try to use onDataString instead of this function."

I think if this recommended onData, it might be more clear to the user that something fishy is going on.

If the stream has an end, you can read all the stream data and then convert to a String with https://pursuit.purescript.org/packages/purescript-node-streams-aff/1.1.0/docs/Node.Stream.Aff#v:readAll
If you know how many bytes long the string will be before you read it, then you can wait until all the bytes come in with https://pursuit.purescript.org/packages/purescript-node-streams-aff/1.1.0/docs/Node.Stream.Aff#v:readN


formula: update test_fixtures path

[x] Have you followed the guidelines in our Contributing document?
[x] Have you checked to ensure there aren't other open Pull Requests for the same change?
[x] Have you added an explanation of what your changes do and why you'd like us to include them?
[ ] Have you written new tests for your changes? Here's an example.
[ ] Have you successfully run brew tests with your changes locally?

Fix regression caused by #1364.
Example of the regression: https://bot.brew.sh/job/Homebrew Core/11621/version=any_sierra/testReport/junit/brew-test-bot/sierra/test_mpv/.

This line needs updating as well.

Done, thanks.


Limit number of unknown coverage executions

Description
Make it so minimizer limits number of executions with unknown coverage and identical result type, result model type, and exception type.
Previously 50 almost identical tests were generated whenever we fail to collect the coverage (see #2622 and #2625)
How to test
Manual tests
In scenarios described #2622 and #2625 there shouldn't be 50 identical tests with unknown coverage.
Self-check list

[x] I've set the proper labels for my PR (at least, for category and component).
[x] PR title and description are clear and intelligible.
[x] I've added enough comments to my code, particularly in hard-to-understand areas.
[ ] The functionality I've repaired, changed or added is covered with automated tests.
[x] Manual tests have been provided optionally.
[x] The documentation for the functionality I've been working on is up-to-date.

At least in tests empty coverage is always reported when generating tests for some simple methods like StringConcat::concatWithPrimitiveWrappers, meaning that we can't simply discard most of the executions with empty coverage.

Changes from this PR were included in #2710


[ButtonBase] Add stop ripple on context menu event

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

There's a weird interaction with spamming left and right click and the context menu at least in Chrome. Hopefully, this works towards fixing #7537 once and for all :)
@kgregory @gtsafas @stavlocker @oliviertassinari
Wondering if you can reproduce the issue?

I never could reproduce the issue, if someone can he can try your patch on https://deploy-preview-13740--material-ui.netlify.com/.

@joshwooding I'm closing for now, let's wait for people feedback on the original issue. Thank you for looking into it.

@oliviertassinari I can still reproduce this with my trackpad on my laptop. I was never able to produce this issue with right & left clicks though. But it's just because the trackpad registers more mouse-downs than mouse-ups:

[...] Without looking at the code, I can say that ripple is created on mouse down and removed on mouse up - but that mouse up never arrived because there are more downs than ups. [...]
Two solutions as I see it:

I suggest we put a timer on ripples? If it isn't removed after 5 seconds, auto remove it. On the UX side it needs to be considered that this potentially could confuse users who long press and see the ripple released, perhaps making them think that they pressed the button by releasing their click (when they haven't released it)?
Just create the ripple on mouse up rather than mouse down. This would obviously look different and if a user holds a button they wouldn't see a ripple but it does fix this.

- Me

I never could reproduce the issue, if someone can he can try the patch on https://deploy-preview-13740--material-ui.netlify.com/.

@oliviertassinari I'm no longer able to reproduce it.

Should we close the original issue?

@oliviertassinari I think we're okay to close it out, but with notice that encourages others to come forward with steps to reproduce the behavior if they see what @stavlocker is experiencing.  If somebody presents a way to reproduce the issue, we can always reopen.


feat: add logos to our site

Adding some first-pass logos of a few customers from the last year.  We'll update these when we next review our current customers.

Landing this based on @erickzanardo's implied review (having written his own PR on top of this).  We can tweak it further from there.


question: reconnect

Hi,
Solid work Atem18! Thank you.
Does this automatically reconnect after for example maintenance?
Thanks in advance,
p0nts

Hi @p0nt,
I am glad you like it.
If you speak about Websockets, yes it does reconnect if you don't have internet, you can test it by running the cli.py program.
It's not yet a proper CLI for kraken but it implements a dump Websockets connection.

If you speak about the API, there is not (yet?) the ability to retry because for one hand there is no proper support (yet?) in HTTPX and on a second hand, I am not sure you would want to retry all the API requests like creating an order for example.
If you have more questions, please ask.

Hi Atem18,
Thank you for the awesome quick response, sorry that I've not stated this in my question... I was indeed talking about websocket.
This means the question is answered, thank you very much!


Update step04.md

Lightly edited for clarity.

All changed packages have been documented.

You can try these changes at https://cadlplayground.z22.web.core.windows.net/typespec-azure/prs/522/
Check the website changes at https://tspwebsitepr.z22.web.core.windows.net/typespec-azure/prs/522/

@markcowl I have the microsoft/typespec submodule cloned locally and I've installed 'typespec/prettier-plugin-typespec' in addition to the Prettier extension, but I'm getting errors from Prettier due to missing deps. Do we have guidance on the proper way to set this up?
["INFO" - 3:41:01 PM] Formatting file:///c%3A/Users/marioguerra/Work/typespec-azure/docs/getstarted/azure-core/step04.md
["ERROR" - 3:41:01 PM] Error resolving prettier configuration for c:\Users\marioguerra\Work\typespec-azure\docs\getstarted\azure-core\step04.md
["ERROR" - 3:41:01 PM] Error loading node module 'c:\Users\marioguerra\Work\typespec-azure\core\packages\compiler\node_modules\prettier\index.cjs'
Error: Error loading node module 'c:\Users\marioguerra\Work\typespec-azure\core\packages\compiler\node_modules\prettier\index.cjs'

Did you follow the instruction to install dependencies in the repo https://github.com/Azure/typespec-azure/blob/main/CONTRIBUTING.md?
pnpm install, pnpm build, pnpm format

Thanks @timotheeguerin, I was able to run the formatter but there is no change to the file for me to check in after formatting. What is the failing check looking for?

I'm going to redo this PR following the guidance, closing this one.

It should have updated the file, it's weird it didn't. Formatting it in Vscode with prettier extension also should work


WIP bugfix: Fix that pouch don't support detach-keys when run "pouch run"

Ⅰ. Describe what this PR did
pouch run did't support --detach-keys
Ⅱ. Does this pull request fix one issue?

fixes #2221
Ⅲ. Why don't you add test cases (unit test/integration test)? (你真的觉得不需要加测试吗？)
Ⅳ. Describe how to verify it
$ pouch run -it --detach-keys="ctrl-x" busybox

Ⅴ. Special notes for reviews
It seems that pouch lacks a unified detach mechanism to capture custom detach keys. The following commands will be affected:

pouch run
pouch exec
pouch start

I will submit a series of pr to solve them later.

We'd better implement a mechanism to proxy container by cmd side, so we can reuse the codes in where we need attach and access the container io. I have marked a issue #2490 and will submit a pr to do that later.


microk8s is not running

karl@thor:~$ lxc launch ubuntu-daily:focal k8s
Creating k8s
Starting k8s
karl@thor:~$ lxc exec k8s bash
root@k8s:~# sudo snap install microk8s --classic
sudo: setrlimit(RLIMIT_CORE): Operation not permitted
microk8s (1.18/edge) v1.18.3 from Canonical✓ installed
root@k8s:~# microk8s status
microk8s is not running. Use microk8s inspect for a deeper inspection.

inspection-report-20200607_131456.tar.gz

Hi @kstenerud, could you try one of the lxc profiles in https://github.com/ubuntu/microk8s/tree/master/tests/lxc ?


Error when doing a slidev build

Describe the bug
When using @slidev/cli to do a build, an Error [RollupError]: Could not resolve entry module is seen and the slides don't get built.
To Reproduce
Steps to reproduce the behavior:

Install slidev cli globally using npm i -g @slidev/cli
Download example slides from https://github.com/slidevjs/themes/blob/main/packages/theme-default/example.md and rename as slides.md
Remove the  line 2 : theme: ./
On the cli in the directory with this slides.md file, run slidev build
Note the error Error [RollupError]: Could not resolve entry module

❯ head slides.md
---
layout: cover
background: https://images.unsplash.com/photo-1502189562704-87e622a34c85?ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&ixlib=rb-1.2.1&auto=format&fit=crop&w=2100&q=80
---

# Presentation title

Presentation subtitle

---
[9:28] ❯ slidev build

  ●■▲
  Slidev  v0.40.5 (global)

  theme   @slidev/theme-default
  entry   /Users/chinmay/Desktop/test/slides.md

vite v4.2.1 building for production...
✓ 0 modules transformed.
✓ built in 44ms
Could not resolve entry module<EMAIL_ADDRESS>Error [RollupError]: Could not resolve entry module<EMAIL_ADDRESS>    at error (file:///Users/chinmay/.nvm/versions/node/v16.17.0/lib/node_modules/@slidev/cli/node_modules/rollup/dist/es/shared/node-entry.js:2125:30)
    at ModuleLoader.loadEntryModule (file:///Users/chinmay/.nvm/versions/node/v16.17.0/lib/node_modules/@slidev/cli/node_modules/rollup/dist/es/shared/node-entry.js:23797:20)
    at async Promise.all (index 0) {
  code: 'UNRESOLVED_ENTRY'
}

Desktop (please complete the following information):

OS: macOS 13.2.1
Browser: Chrome 111.0.5563.64
Slidev version: 0.40.5
Nodejs version : v16.17.0

I have the same issue. It seems that it is caused by global installation. A workaround is installing it locally and run slidev build under the directory.

I have the same issue. global installation and then slidev build doesn't work.


Not getting any issues in Issues view

Found by @Tyriar when verifying https://github.com/microsoft/vscode-pull-request-github/issues/5247.
Autocomplete doesn't work for me at all on the vscode repo,
xterm.js:

VS Code:

Queries:
  "githubIssues.queries": [
    {
      "label": "My Issues",
      "query": "default"
    },
    {
      "label": "Created Issues",
      "query": "author:${user} state:open repo:${owner}/${repository}"
    },
		{
			"label": "Luna",
			"query": "is:open repo:lunapaint/luna sort:updated-desc"
		}
  ],

I expect the vscode ones to be pulled in from created issues + my issues.
FWIW The Luna query does work in the xterm.js window, not the vscode window though.

Also from @Tyriar
Mine doesn't load in the vscode window:

ghpri.log

Once https://github.com/microsoft/vscode-pull-request-github/pull/5304 is merged, I will look at this again.

@Tyriar, can you set the default  log level of "GitHub Pull Request" to "debug", reload to reproduce the issue, then share the output of "GitHub Pull Request"?


Undefined variable "ansible_ios_version" is used

We need to use "ansible_net_version".
exercises/networking/1.5-roles/README.md
exercises/networking/1.5-roles/roles/static_route/tasks/main.yml
exercises/networking/1.5-roles/roles/interface/tasks/main.yml

fixed with https://github.com/network-automation/linklight/pull/74 to ansible_net_version


Error when using with React 16.8

According to the latest package.json<EMAIL_ADDRESS>supports "react": ">= 16.3.2 < 17.0.0-0".  However, using React 16.8.1, i get the following error when compiling with Webpack:
TypeError: __chunk_1.inherits is not a function
at<EMAIL_ADDRESS>

Weird. Can't imagine why it'd fail. I won't be able to dig into this in the next few days, but happy to accept a PR from anyone interested.

@lavelle — Seems to work fine:
https://codesandbox.io/s/9oxm04wvor
Did you get this error while Create React App was running? What happens if you do yarn install --force or restart CRA (or whatever flavor of Webpack)?
Will close for now, but LMK if that doesn't fix.


Test improvements

Use require object with injected test
Fix "ineffectual assignment" linter warning
Simplify TestClientCouldConnect
Simplify range expression

Hey @ashellunts, we'd like to avoid doing require := require.New(t) for a couple reasons:

consistency (we use t explicitly in all our other tests and repos)
test suite readability (we often use t.Run("name", testfunc), and it's easier to keep track of which require is being used - it might be easy to forget to create a new require with the internal t).

Hey @ashellunts, we'd like to avoid doing require := require.New(t) for a couple reasons:

consistency (we use t explicitly in all our other tests and repos)
test suite readability (we often use t.Run("name", testfunc), and it's easier to keep track of which require is being used - it might be easy to forget to create a new require with the internal t).

ok, reverted.


test(e2e,playwright): shortcuts-modal

Checklist:

[x] I have read and followed the contribution guidelines.
[x] I have read and followed the how to open a pull request guide.
[x] My pull request targets the main branch of freeCodeCamp.
[x] I have tested these changes either locally on my machine, or GitPod.

Ref #51705

camperbot cant code


Add content negotiation for profile page

When request Header application/ld+json is sent to profile page, JSON-LD should be produced.

Done & coordinated through the web server.


Allow multiple receive counts for an expected message

Allow multiple receive counts matchers for an expected message
Only the last counter matcher in a expectation is considerer, the rest are ignored.
Your environment

Ruby version: 3.6.6
rspec-mocks version: 3.10.2

Steps to reproduce
Define an expectation with a counter range:
 it 'receives message between 5 and 6 times ' do
   expect(receiver).to receive(:message).at_least(5).at_most(6).times
   method_call
 end

Expected behavior
Expect the case to fail if message is received less than 5 times OR more than 6 times
Actual behavior
The test case fails if message is received more than 6 times, but it passes when message is received less than 5 times

Thanks for reporting.
This is a duplicate of #1426 if I'm not mistaken.
There are several problems with counts if you check comments, and a suggestion how to improve that.
Pull requests are welcome!


[YANG] Parsing and binary compilation support of 'leafref' and 'instance-identifier'

Allows schema instances that contain references to data types leafref and instance-identifier to be parsed and compiled. However, if snabb config prints out a leaf that belongs to one of those data types, an error is emitted.

Superseded by https://github.com/Igalia/snabb/pull/898


set freeze property of RigidBody2D not effect after set linear_velocity and start moving object

Godot version
v4.2.rc2.official [1ba920fad]
System information
Windows 10, Vulkan
Issue description
set freeze property of RigidBody2D not effect after set linear_velocity and start moving object and freeze_mode is static but when freeze_mode is kinematic it works ok and stops moving.
Steps to reproduce
1- Created a ball using RigidBody2D
2- Handle mouse input and set linear_velocity of ball to a custom value to start moving the ball.
3- On ball input in a Area2d event set $ball.freeze = true.
4- ball will continue moving when freeze_mode is static but that will stops moving when freeze_mode is kinematic.
Minimal reproduction project
TestRigidBody2D.zip
Test with freeze_mode = static and kinematic

I can reproduce the symptoms in both 4.2-rc2 and 4.1.3-stable.
But it doesn't seem to be a bug. When in Kinematic mode, it seems to work, but it prints an error:
ERROR: Can't change this state while flushing queries. Use call_deferred() or set_deferred() to change monitoring state instead.
   at: body_set_mode (servers/physics_2d/godot_physics_server_2d.cpp:570)

Fixing this error by doing:
func _on_area_2d_area_entered(area):
	set_deferred("freeze", true)

instead of:
func _on_area_2d_area_entered(area):
	freeze = true

solves the issue for both modes.
So the main issue here to me is why this error isn't shown when the freeze mode is Static.


cmd/vet: unnecessary diagnostics about json:"-" on unexported fields

What version of Go are you using (go version)?

$ go version
go version go1.15.6 linux/amd64

What did you do?
I like to write code such as the following:
type description struct {
	fileName       string              `json:"-"`
	loadTime       time.Time           `json:"-"`
	modTime        time.Time           `json:"-"`
	fileSize       int64               `json:"-"`
	Description    string              `json:"description,omitempty"`
        ...
}

The unexported fields have a json:"-" tag, so that the resulting behaviour doesn't change if I happen to export the fields later.  Unfortunately, this causes go vet warning:
group/group.go:567:2: struct field fileName has json tag but is not exported

There is apparently no way to disable this warning without disabling all JSON-related checks.  Please disable the warning in the particular case of a json:"-" tag, or at least provide a way to disable it without disabling all JSON-related checks.
What did you expect to see?
go vet doesn't warn about json:"-" tags on unexported fields, only about non-trivial json tags.
What did you see instead?
go vet complains, and there is no way to avoid the warning short of disabling all JSON-related checking.

I think it's fine to suppress a warning about json:"-" on unexported fields, since they're not an issue per se.

I think the change has been made in https://github.com/golang/tools/commit/73b12cab2531d716d7df68317338773313a49bac

Yep, thanks.


Build logs (from inside Docker container) do not get saved

When the build fails (and doesn't exit! https://github.com/game-ci/unity-builder/issues/325) you have no way to see the actual Unity build log anymore.
It seems to be temporarily visible while docker is running, but does not persist so you can't download it from GitHub actions to review why it failed.

Does the build log not stream to the GitHub actions console and get persisted by that even if a workflow is canceled?

I'm wondering if this is still an issue?


PR#1 First stage of project

The core modules of the project have now been largely finalized, allowing us to enter the latter stage of development. The upcoming work will mainly involve adding new features within the existing framework.
I finally decided use React + Vite + Typescript + Zustand + Zundo + pixi-react, instead of vanilla esm + dom + plain pixi.js we've planed when project begin, since the complexity of project is a bit out of control, I will explain it in future weekly post.
Check previous biweekly post here for more information:
OSPP 2024 Project: Frontend technology based OpenStreetMap PT relation editor — Biweekly Report #1
OSPP 2024 Project: Frontend technology based OpenStreetMap PT relation editor — Biweekly Report #2

Thank you for your contributions thus far. Your efforts have helped stabilize our current tech stack and code framework, which is greatly appreciated. We look forward to your continued contributions in the future.
Best regards,


Add seek_exact equivalent for seek_by_key_subkey

Describe the feature
It would be useful to have a seek_exact equivalent for the seek_by_key_subkey method, that returns None when the entry doesn't exist. This reduces the checks for when we need to conditionally delete an entry. An example:
https://github.com/paradigmxyz/reth/blob/a6c8178d7f863c360e6d24e60073b34c713705b4/crates/stages/src/stages/execution.rs#L363-L366
Also, I propose renaming seek_by_key_subkey to seek_dup, so that it's consistent with all the *_dup methods.
Additional context
No response

I'd like to take this.


Fix wrong glm inclusion

Including all the subdirectory in the darwin cmake toolchain for homebrew-installed package here, results in wrong inclusion by the preprocessor in the case the user has it installed on its machine, since this happens before the core/include inclusion. To solve it, we should only include the brew dependency we need in the project.

Looks good


Update Pages “pestinspectionsPage”

Automatically generated by Netlify CMS

👷 Deploy Preview for chic-shortbread-66a66b processing.

Name
Link

🔨 Latest commit
61bbffef9f7fc74ee768d4f5ef315cfc3e94fec3

🔍 Latest deploy log
https://app.netlify.com/sites/chic-shortbread-66a66b/deploys/65515c703a811900087c3658


updating node version from 12 to 16

action.yml would also need using: 'node16'

We can use this one  for now.


[QUESTION]While uninitialising the stream, do we need putEoFr()?

When uninitialising the stream, here's the sequence we follow (when both audio and video exists in the stream).

flush
putEofr
stop
freeStream

Should there be a putEofr necessarily available in this flow? We have a SIGABRT due to an assertion failure of the stream handle in KinesisVideoStream::putFrame consistently during the putEoFr call (only in the above said uninitialisation sequence).
Any thoughts around this would be greatly helpful.

@Subburaj47 could you please give us a little more details about the assertion? We don't have asserts in the SDK.
If you are driving the fragmentation on your side, there is no need for putEofr on teardown. StopSync should take care of properly streaming out the remainder of the buffer, receive the last persisted ACK for the last streamed fragment and only then return.

@MushMal  I meant about this line in the code where there is an assertion to check the stream_handle.
https://github.com/awslabs/amazon-kinesis-video-streams-producer-sdk-cpp/blob/3.0.0/src/KinesisVideoStream.cpp#L28
Regarding the usage we have the following which was working without any glitch in the previous SDK versions.
`    data->putFrameHelper->flush();
data->putFrameHelper->putEofr();

data->kinesis_video_stream->stop();

data->kinesis_video_producer->freeStream(data->kinesis_video_stream);`

While working with the 3.0.0 SDK, we see an assertion failure during the stream uninitialisation (with the code snippet mentioned above). FYI, we are marking the key frames in the application side to fragment the clip.
Could you pls share your thoughts on why there is an assertion failure only in the 3.0.0 SDK? Also, do you suggest to pull out the putEoFr( ) and add a stopSync( ) instead of stop( )?

I see, yes indeed we do have asserts in C++ codebase. In this case, it seems that you are trying to putFrame after the stream has been torn down or something like that.
If you are driving the fragmentation then you no longer need the putEoFr. In fact,  in multi-track it would end up with an error 0x52000084 which is specifically guarding against trying to fragment using key-frame fragmentation and at the same time using EoFR in the frame order coordinator designed to do the fragmentation itself.
Regarding stop vs stopSync. Stop API is a "prompt" API - it stops any further frame production into the stream by setting flags and changing the internal state. It doesn't await for the stream finalization. Finalization is to stream out the existing buffer contents, put EoS to trigger session teardown from the backend, await for the final persisted ACK. In the async case the applications would kick off stop and then continue as soon they either get an error callback or stream stopped callback. StopSync API does the Sync and awaiting (with a configurable timeout) for the finalization.

Thanks for the info @MushMal . I have removed the putEoFr() during the application's uninit.


Standard form field does not work correctly with datepicker toggle and select

Bug, feature request, or proposal:
Bug
What is the expected behavior?
Standard form field works well with datepicker toggle and select, similar to the legacy form field.
What is the current behavior?
Datepicker toggle is weirdly large and the select drop-down icon is aligned incorrectly in a standard form field.
What are the steps to reproduce?
https://stackblitz.com/edit/angular-material2-issue-eigucd?file=app/app.component.html
What is the use-case or motivation for changing an existing behavior?

Which versions of Angular, Material, OS, TypeScript, browsers are affected?
Material: 6.0.0
Is there anything else we should know?

any update on this issue?

I believe this is working as intended. The latest version of the spec doesn't have the underline style at all. But the previous version showed the dropdown arrow centered w.r.t. the label & value as a whole:

The larger calendar icon is again following the pattern shown in the previous version of the spec, which shows full-sized icons being used as the suffix:


ci: upgrade GitHub actions

#676  👈 (View in Graphite)
main

This stack of pull requests is managed by Graphite. Learn more about stacking.


[Improved] Add POST requests

@Colecf sorry for the delay in response, i was on a freaking long vacation. But now i'm back and had opportunity to look into your PR - https://github.com/codemanki/cloudscraper/pull/5 . Looks good thanks for contributing, i've made couple improvements, added spec and made new post method testable. Please, take a look and let me know what you think.

Looks good, but shouldn't index.js line 60 be makeRequest() as well? Though I guess your tests never return an HTTP 302 so it doesn't really matter.
It's a little disappointing that we have to use the requestMethod() workaround to get the tests working, because before that the cloudscraper.request() function could be used with any HTTP verb.
I've got another pull request after you merge this one about the encoding of the data. Currently this just encodes everything as text which was a problem when I was trying to get an image from a cloudflare site.

but shouldn't index.js line 160 be makeRequest() as well?
Yep, missed that. Fixed

It's a little disappointing that we have to use the requestMethod() workaround to get the tests working
Totally agree here, but for now i see no other option for now :(

I've got another pull request after you merge this one about the encoding of the data.
Great. I'm merging this one and will hold with release until your fix will be merged.


[Task] Fix thread safety of PendingAckHandleImpl

PendingAckHandleImpl seems to contain some thread safety issues:
individualAckOfTransaction uses org.apache.commons.collections4.map.LinkedMap which is not thread safe.
Another thread safety issue is the mutation of MutablePair instance. MutablePair is not thread safe.
HashMaps are also used as mutable state.
This state is mutated without a guarantee that the same thread is reading and writing the state or there's some other way to ensure consistency according to the Java Memory Model.
It seems that the intention would be use a single thread execution model to address this. There's a internalPinnedExecutor in
PendingAckHandleImpl which is used to run some operations on the single executor thread.
However, the thread could possibly get switched multiple times in the call chain because of asynchronous method calls.
There's also some code where synchronized blocks are used as a way to ensure consistency such as
synchronized (org.apache.pulsar.broker.transaction.pendingack.impl.PendingAckHandleImpl.this) { and synchronized (PendingAckHandleImpl.this) {.
This is bad since the thread that gets synchronized is whatever thread is completing the asynchronous call. This might for example block threads from the bookkeeper client.

@liangyepianzhou Could you please help take a look at this issue?

If the odds are not high that thread safety issue will happen, maybe no need to be proactive on this, but at least can set up mechanism to easily catch up on this.

If the odds are not high that thread safety issue will happen, maybe no need to be proactive on this, but at least can set up mechanism to easily catch up on this.

Perhaps in some software that's an acceptable way. Thread safety problems could be extremely rate. Let's say 1 out of 10 million operations fails. That is still a big problem for a messaging system.


Adding ReCharge to list of remote companies.

This is a modified version of the Contributing Guidelines.
This pull request adheres to the repository's Code of Conduct

[X] This PR contains housekeeping (URL edits, copy changes etc)
[X] You know your alphabet - company is listed in alphabetical order in the README
[X] A company profile is included - Not essential but it really helps!
[X] The company directly hires employees - This may sounds odd but while awesome, this list is not for coding bootcamps, "teaching" positions a network (Teacher positions employed directly, such as Treehouse, are allowed), or networking sites for listing a CV looking for gigs
[X] The company added hires remote employees, or positions are available to remote workers and are clearly illustrated as such
[X] A company-profile has been included for each addition to the list
[X] I am an employee of the company mentioned and confirm all details are correct
[X] Remote status has details regarding how the culture includes remote employees, how the company integrated remote workers, etc
[X] Region details any restrictions to applicants based on geography
[X] How to apply details the best approach for new applications, link to open positions, and any other help available for job hunters
[X] Any missing parts from the profile, please use <Unknown> to allow for future completion

THIS GUY! 🎉 Congrats on the PR @ashthemighty!


Polygon contains an Arc Segment, wrong reading vertices

This is the drawn polygon in cad file.

And this is the output shape after reading it using ACadSharp:

and there isn't any indicator for the arc segment like [Center, startAngle, endAngle, Radius]
I think there is a bug in reading polygon contains arc because I tried to read an arc shape [a separate arc ] like this:

1- I have drawn a closed PolyLine starting with line [I drew 3 continious lines] and closed with ARC
so the result from AcadSharp is closed polygon from 4 lines so it ignored the ARC segment
2- the second note is I tried to draw Pure ARC using arc command in cad and the result is some indicators that this is an ARC like center, radius ..etc
So the problem is when the ARC being part of a shape, it is ignored and if it is drawn separately, it is read well

The data seems to be there the problem is that Polyline vertices in Autocad create angles using this property:
/// <summary>
/// The bulge is the tangent of one fourth the included angle for an arc segment, made negative if the arc goes clockwise from the start point to the endpoint.A bulge of 0 indicates a straight segment, and a bulge of 1 is a semicircle
/// </summary>
[DxfCodeValue(DxfReferenceType.Optional, 42)]
public double Bulge { get; set; } = 0.0;

I'll open a branch linked to this issue to calculate the values of the center, radius and angle of an arc in a segment of a polyline.


HDDS-3117. Recon throws InterruptedException while getting new snapshot from OM.

What changes were proposed in this pull request?
On a cluster where an ozone client is continuously pushing data into OM, we can have cases where the OM Delta updates request timing out or failing due to some unexpected error. In that case, the expected behavior of Recon is to request the whole snapshot from OM. The bug was that we were interrupting the thread on exception from delta updates query which caused the sync process to stop. Removed the interrupt call.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-3117
How was this patch tested?
Added acceptance tests for Recon's OM related APIs.
Manually tested by creating 50 million keys on OM, and verified that Recon OM DB sync works as expected.

@swagle  / @vivekratnavel Please review.

Acceptance test failure is related to this change:
[{"fileSize":1024,"count":24},{"fileSize":2048,"count":0},{"fileSize":4096,"count":0},{"fileSize":8192,"count":0},{"fileSize":16384,"count":927},{"fileSize":32768,"count":27},{"fileSize":65536,"count":0},{"fileSize":131072,"count":0},{"fileSize":262144,"count":0},{"fileSize":524288,"count":0},{"fileSize":1048576,"count":0},{"fileSize":2097152,"count":0},{"fileSize":4194304,"count":0},{"fileSize":8388608,"count":6},{"fileSize":16777216,"count":2},{"fileSize":33554432,"count":2},{"fileSize":67108864,"count":0},{"fileSize":134217728,"count":0},{"fileSize":268435456,"count":0},{"fileSize":536870912,"count":0},{"fileSize":1073741824,"count":0},{"fileSize":2147483648,"count":0},{"fileSize":4294967296,"count":0},{"fileSize":8589934592,"count":0},{"fileSize":17179869184,"count":0},{"fileSize":34359738368,"count":0},{"fileSize":68719476736,"count":0},{"fileSize":137438953472,"count":0},{"fileSize":274877906944,"count":0},{"fileSize":549755813888,"count":0},{"fileSize":1099511627776,"count":0},{"fileSize":2199023255552,"count":0},{"fileSize":4398046511104,"count":0},{"fileSize":8796093022208,"count":0},{"fileSize":17592186044416,"count":0},{"fileSize":35184372088832,"count":0},{"fileSize":70368744177664,"count":0},{"fileSize":140737488355328,"count":0},{"fileSize":281474976710656,"count":0},{"fileSize":562949953421312,"count":0},{"fileSize":1125899906842624,"count":0},{"fileSize":9223372036854775807,"count":0}]' does not contain '"fileSize":16384,"count":10'

Filesize count is spread across many buckets because of the previous tests. We might need to change the filesize while running freon.

Thanks @avijayanhwx for the fix, @swagle and @vivekratnavel for the reviews.


Disabling Windows Task View including edge swipe

Provide a description of the new feature / enhancement
Windows allows you to remove the task view button from the taskbar but there are still multiple ways task view itself can be triggered often unintentionally, including by swiping 3/4 fingers on the touchpad (an accidental brush with the hand in passing) or dragging across the left edge of a touch screen (it's very easy to trigger this accidentally by selecting and dragging something that is partially off screen like a jigsaw piece placed next to the puzzle in Microsoft Jigsaw). There is also a Logitech keyboard that causes task view to trigger frequently.
Some users also wish to prevent deliberate activation on eg a tablet used as a kiosk device.
There are numerous support requests in official and unofficial forums from users wanting to turn off task view (usually the response is to turn off the task view button on the taskbar and the OP then explains in some frustration that they want to remove the feature, not the button).
Although you can turn off the multifinger touchpad features, this doesn't turn off edge swipe and other accidental triggers and it doesn't block the feature for kiosk cases.
Currently users have to edit the registry to set (or usually create) the HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\EdgeUI\AllowEdgeSwipe DWORD and set it to 0.
This seems like exactly the kind of thing PowerToys is there for.

Neat idea @marypcbuk!


Feature Request : Adding Splash Screen.

Description:
There is a need to add a splash screen to the Learn repository to improve the user experience and provide a more polished look and feel to the application upon startup.
Expected Behavior:

The app should display a splash screen when it is launched.
The splash screen should show the app's logo and possibly a tagline or loading indicator.
The splash screen should be displayed for a brief period before transitioning to the main app content.

Benefits:

Enhances the visual appeal and professionalism of the app.
Provides users with a brief, engaging experience while the app is loading.
Sets the tone and branding for the app right from the start.

Please assign me under GSSOC, and lable it.

@sapatevaibhav assign this issue to me.

@sapatevaibhav  Hii sir, I have been completed this issue. PR no #171 you can please verify this and merge it.


Disruptor missing events

Hello. I'm trying to use a Disruptor with a Chronicle Queue, and found that Disruptor misses or repeats some events that are passed to it.
I'm doing an debug output right before disruptor publishes events
ObjectValueEvent event = ringBuffer.nextEvent();
event.setValue(data);
ringBuffer.publish(event);
System.out.println(event.getValue());
and it's fine:
event1, event2, event3, event4 and so on. All events are unique
Second output is in handler method:
disruptorWizard.handleEventsWith(
new EventHandler()
{
@Override
public void onEvent(ObjectValueEvent event,
boolean endOfBatch) throws Exception
{
System.out.println(event.getValue());
}
});
and it's totally messed up - event1, event5, event9, event9, event9
The only thing, i'm thinking about, is that Chronicle reads data from it's storage and then passes it to disruptor so quickly, that disruptor can't process it. Because adding 100ms sleep before passing data to disruptor solves the issue, is inacceptable.
Can you please point me how to fix it?

I met the same problem when i use multi-producer/on consumer.on event handler, i got the same event repeately for some event.


[base-ui][Select] No focus-outline if focused by label

Duplicates

[X] I have searched the existing issues

Latest version

[X] I have tested the latest version

Steps to reproduce 🕹
Link to live example: https://mui.com/joy-ui/react-select/#accessibility
Steps:

Scroll to accessibility demo
Click on Label
No focus outline

Current behavior 😯
"button" of Select does not have a focus outline if it is focused by a label.
The element is in focus though, So it's just an a11y cosmetic issue.
Expected behavior 🤔
Here's a demo of the desired behavior and also a workaround:
https://codesandbox.io/s/upbeat-haze-qvxzk7?file=/Demo.tsx
Context 🔦
I want consistent a11y and cosmetic appearance of my form fields
Your environment 🌎

npx @mui/envinfo
  System:
    @emotion/react: 11.11.1 => 11.11.1
    @emotion/styled: 11.11.0 => 11.11.0
    @mui/base:  5.0.0-beta.17
    @mui/core-downloads-tracker:  5.14.11
    @mui/icons-material: 5.14.11 => 5.14.11
    @mui/joy: 5.0.0-beta.8 => 5.0.0-beta.8
    @mui/material: ^5.14.11 => 5.14.11
    @mui/private-theming:  5.14.11
    @mui/styled-engine:  5.14.11
    @mui/system:  5.14.11
    @mui/types:  7.2.4
    @mui/utils:  5.14.11
    @types/react: ^18.2.23 => 18.2.23
    react: 18.2.0 => 18.2.0
    react-dom: 18.2.0 => 18.2.0
    typescript: ^5.2.2 => 5.2.2

Browser: all are affected, since it is an issue of setting the correct class on focus

Hey I can Work on this issue please assign this to me
Thank you!

Can i submit a PR of it ? @pixelass

@harshu0026 @sujalcodes3 I'm not a member here. But I'm pretty sure that @oliviertassinari is happy about a PR on this :)
I think there are several solutions here:

use something similar to my workaround
use focus-within

This bug is related to the focus handling within useButton and useIsFocusVisible hooks in @mui/base package which are used in the joy-ui Select component.
@michaldudak I was debugging this and found that target.matches(':focus-visible') returns false when button inside the Select is focussed by clicking on it's associated label. That's why focus styling is not added as expected.

Also, in this case the parent wrapper carries the focus style. Maybe that's related. (Compare to tab focus)

This works the same as if you had
<label for="btn">Foo</label>
<button id="btn">Bar</button>

The problem here is that an HTML button (unlike select or input) does not enter the focus-visible state when you click on the associated label. So we need to think of a workaround.
@harshu0026, @sujalcodes3, can we discuss what ideas you have for fixing it first?

@michaldudak I was browsing through the code. I think the isolation of the problem can be down to this function in the Select.tsx file and I observed that at the definition of focusVisible state variable from ownerState, the boolean check is with 'focusVisible' which is in camel case, but as mentioned by @brijeshb42 in the above isolation of the problem, the function checks for 'focus-visible' class. I got stuck after that, because a simple solution seems to be the variable naming format, but I would like everyone's opinion.

The focusVisible variable comes from our polyfill (as the :focus-visible pseudoclass was not supported in Safari some time ago). However, neither the polyfill nor the actual pseudoclass makes the button focus-visible when an associated label is clicked. It's how browsers implement this.
@pixelass' workarounds make things a bit better, but they operate on the focus state, not focus-visible (so it won't work if we don't want the focus outline on a clicked button, for example).
But perhaps this is inevitable, and Joy UI focus ring styles should target the focus instead of focus-visible state (as Radix does, for example).
cc @danilo-leal, @siriwatknp

I found the bug to be internal state/ref that we maintain to indicate focus and then add appropriate focus class. The onFocus handler is being triggered by browser correctly when clicking on the label but since the target.matches() call in useIsFocusVisible is returning false, the focus state is not set to true and hence the styling is not applied.

The focusVisible variable comes from our polyfill (as the :focus-visible pseudoclass was not supported in Safari some time ago). However, neither the polyfill nor the actual pseudoclass makes the button focus-visible when an associated label is clicked. It's how browsers implement this.
@pixelass' workarounds make things a bit better, but they operate on the focus state, not focus-visible (so it won't work if we don't want the focus outline on a clicked button, for example).
But perhaps this is inevitable, and Joy UI focus ring styles should target the focus instead of focus-visible state (as Radix does, for example).
cc @danilo-leal, @siriwatknp

So Do I now check the joy-ui for the same issue, 'cause if the persists, it might be affecting other components using the polyfill.

The issue affects cases where a label is used to focus a button. I don't think we do it anywhere else except for the Select, but I may have missed something.

The issue affects cases where a label is used to focus a button. I don't think we do it anywhere else except for the Select, but I may have missed something.

Right, it's the :focus not :focus-visible. @pixelass Here is a workaround that you can apply to the sx prop or the theme:
<Select
  sx={({
    '&:has(button:focus)::before': {
      boxShadow: 'inset 0 0 0 var(--Select-focusedThickness) var(--Select-focusedHighlight)',
    }
  })}
>

@siriwatknp, have you considered changing it in Joy itself, so that the :focus state is highlighted instead of :focus-visible?

@siriwatknp, have you considered changing it in Joy itself, so that the :focus state is highlighted instead of :focus-visible?

👍 PR open!

I am currently using this in my theme, which solves the problem for now.
JoySelect: {
  styleOverrides: {
    root: {
      "&:focus-within::before": {
        boxShadow: "inset 0 0 0 var(--Select-focusedThickness) var(--Select-focusedHighlight)",
      },
    },
  },
}


Milestone 3 Feedback

Hi all,
Great app!
Things we liked:

The one line description was useful and to the point
The drop down bar being included in the description was a good idea, the user knew how to use it immediately.

Feedback:

Changing the initial profit and rating plots so that not all of the directors show, would make the plots more useful initially without having to select specific directors.

Changing the layout of the app so that the user does not need to scroll to the right to see the full names of the directors in the legend.

Compiled feedback issues: https://github.com/UBC-MDS/DSCI532_GROUP104_Movies/issues/69


Optimizing Filters and Merges

I was writing down some tests to help me think through swapping filters and merges
def test_filter_merge():
    a = pd.DataFrame({"a": range(5), "b": range(5), "c": range(5)})
    b = pd.DataFrame({"c": [0, 2, 4, 6, 8], "x": range(5), "y": range(5)})

    a = dx.from_pandas(a)
    b = dx.from_pandas(b)

    # Some simple cases
    df = a.merge(b)
    df = df[df.x > 3]
    bb = b[b.x > 3]
    expected = a.merge(bb)
    assert df.optimize()._name == expected.optimize()._name

    df = a.merge(b)
    df = df[df.b > 3]
    aa = a[a.b > 3]
    expected = aa.merge(b)
    assert df.optimize()._name == expected.optimize()._name

    # Apply to both!
    df = a.merge(b)
    df = df[df.c > 3]
    aa = a[a.c > 3]
    bb = b[b.c > 3]
    expected = aa.merge(bb)
    assert df.optimize()._name == expected.optimize()._name

    # Works with more complex expressions, and multiple columns
    df = a.merge(b)
    df = df[df.a > df.b + 1]
    aa = a[a.a > a.b + 1]
    expected = aa.merge(b)
    assert df.optimize()._name == expected.optimize()._name

    # Only apply if all columns are in the table, not if only some are
    df = a.merge(b)
    df = df[df.c > df.x + 1]
    bb = b[b.c > b.x + 1]
    expected = a.merge(bb)
    assert df.optimize()._name == expected.optimize()._name

    # Bail if we engage non-elemwise expressions in the predicates
    df = a.merge(b)
    df = df[df.x > df.y.sum()]
    bb = b[b.x > b.y.sum()]
    not_expected = a.merge(bb)
    assert df.optimize()._name != not_expected.optimize()._name

I think that what I came to is that we want to push a filter into one side or the other if

the predicate is valid when we replace the merged table with the left or right side.  Something like if predicate.subs({merged: left}) doesn't raise an error (after we figure out renaming of columns).
The predicate has only elemwise expressions (nothing like df.x < df.y.sum() for example)

And so maybe an implementation here relies on ...

Making a proxy object for left that has no expression history, but does have the same ._meta
Calling substitute and seeing if it errs
Scanning through the substituted predicate expression and seeing if everything in it is Elemwise

I think that that should cover most cases and be various robust.
Things get a bit more complex if we also want to support And clauses (there are cases where we could split a predicate into two parts and each part applies to one side) but I think that this is probably pretty rare and not important.
I don't plan to do this work, but it was interesting to think through.  I suspect that at some point we'll run into this problem, either in a benchmark or in practice and in that case I hope that the tests and discussion above help a little.

I suspect that at some point we'll run into this problem, either in a benchmark or in practice and in that case I hope that the tests and discussion above help a little.

@milesgranger and I ran into this when working on the remaining TPC-H queries.

Things get a bit more complex if we also want to support And clauses (there are cases where we could split a predicate into two parts and each part applies to one side) but I think that this is probably pretty rare and not important.

FWIW, we've had to deal with multiple of these cases and needed to manually optimize in order for queries to work.

Well I'm glad I wrote up these thoughts several months ago.  I hope that they become useful (but no worries if another approach ends up being more helpful).

This should work now


Cannot read property 'getPluralGenerator' of undefined

I'm getting the following error " Cannot read property 'getPluralGenerator' of undefined"
<FormattedPlural
                                        value={0}
                                        zero={<Text>Photo(</Text>}
                                        other={<Text>Photos</Text>} />

Have you included FormattedWrapper at the root of your app? The code you're showing is fine, but I'd need to see more to have any other suggestions.

Yes I did, I went with a different package


suggest instant-search topic too

[x] I followed the contributing guidelines: https://github.com/github/explore/blob/master/CONTRIBUTING.md

I am:

[x] Suggesting edits to an existing Topic page
[ ] Curating a new Topic page

EDITING AN EXISTING TOPIC PAGE
I'm suggesting these edits to an existing topic:

[ ] Image (and my file is *.png, square, dimensions 288x288)
[x] Content (and my changes are in index.md)

Please explain why these changes are necessary:
instantsearch and instant-search are both used in a few repositories

👌
When does it get deployed? I don't see my changes from yesterday yet 😄


adding the binding for supporting headers

Adding the headers in binding for different languages

Code looks good. fix the test fail. then I'll approve it.

@TsuyoshiUshio Test fail is fixed


overwatch in floating mode follows me through workspaces

Hyprland Version
Hyprland, built from branch HEAD at commit d74607e414dcd16911089a6d4b6aeb661c880923  (props: bump ver to 0.33.1). Tag: v0.33.1
Bug or Regression?
Bug
Description
This does not happen with fullscreen or maximize cause of nofullscreenrequest or nomaximizerequest. Is nofloatingrequest a thing?
How to reproduce
Launch Overwatch, put it in floating mode and switch between workspaces.
Crash reports, logs, images, videos
No response

fixed in git


collapseEmptyDivs parameters

So GPT's collapseEmptyDivs takes 2 parameters (https://support.google.com/dfp_premium/answer/3072674?hl=en), but your library does not allow them to be passed in.
And ideally, I'd love to be able to do this on a unit. The idea being I'd like to have a unit that usually collapsed on by default on only appears / loads when there's an ad. (rare)

According to the documentation, collapseEmptyDivs() takes one parameter, where setCollapseEmptyDivs() takes two.
I do not believe this library currently makes any call to setCollapseEmptyDiv, which is done on a per ad basis. What exactly is it you'd like to do?

I could look at implementing the per slot code - that might be handy. For now you can get the desired behaviour by using the CSS classes that my script adds to your adunits.
Depending exactly on what you want to do you can use a combination of the .adunit, .display-block and .display-none classes to do per slot or whole page collapsing... for example:
// Hide all adunits by default
.adunit {
display: none;
}
// Show ad units which have an ad in them
.adunit.display-block {
display: block;
}


Calendar exports should have timezone reference

Like  DTSTART;TZID=US-Eastern:19980119T020000
See https://tools.ietf.org/html/rfc2445#section-4.3.5 and https://productforums.google.com/forum/#!topic/calendar/pdZFX0asgZ8
Originally created by Tom Smyth at 2018-01-19 11:38, migrated from redmine-#7863

Description updated (diff)

By Tom Smyth at 2018-01-19 16:42

Version set to 5.1

By Tom Smyth at 2018-02-07 03:35

Status changed from New to Closed

By Tom Smyth at 2018-02-11 14:49


store: Querying with regex label matchers return invalid metrics in version 0.3.0

Thanos, Prometheus and Golang version used

Thanos: all components 0.3.0
Prometheus: 2.7.1

What happened
After upgrading all components from 0.2.1 to 0.3.0, some dashboards using queries with regex label matchers started showing incorrect metrics. Querying thanos store v0.2.1 from thanos query v0.3.0 works as expected. Toggling deduplication, partial response, and all downsampling options return the same incorrect results. Some query examples:

container_memory_usage_bytes{name=~"thanos-compact} returns metrics for all containers, whereas container_memory_usage_bytes{name="thanos-compact} returns metrics for only thanos-compact. In this case, the invalid results are only for a 6h window, all results outside of this window are correct. The blocks in this 6h window were uploaded with thanos 0.2.1 components.
up{job=~"thanos"} returns thanos metrics correctly, however up{invalidLabelName=~"thanos"} behaves as if the query was for only up. In this case, the query returns incorrect results for all time.

What you expected to happen
Queries return metrics that correctly match the regex in the query, just as prometheus and thanos-store v0.2.1 do.
How to reproduce it (as minimally and precisely as possible):
Should be covered by the description above, but happy to provide any information required.
Full logs to relevant components
thanos-store
level=info ts=2019-02-11T09:16:17.930002237Z caller=flags.go:75 msg="gossip is disabled"
level=info ts=2019-02-11T09:16:17.930311959Z caller=factory.go:39 msg="loading bucket configuration"
level=info ts=2019-02-11T09:16:42.611885128Z caller=main.go:256 msg="disabled TLS, key and cert must be set to enable"
level=info ts=2019-02-11T09:16:42.6122304Z caller=store.go:197 msg="starting store node"
level=info ts=2019-02-11T09:16:42.612546496Z caller=main.go:308 msg="Listening for metrics" address=<IP_ADDRESS>:19193
level=info ts=2019-02-11T09:16:42.612433471Z caller=store.go:166 msg="Listening for StoreAPI gRPC" address=<IP_ADDRESS>:19092

thanos-query
level=info ts=2019-02-11T09:30:25.069246106Z caller=flags.go:75 msg="gossip is disabled"
level=info ts=2019-02-11T09:30:25.088541595Z caller=main.go:256 component=query msg="disabled TLS, key and cert must be set to enable"
level=info ts=2019-02-11T09:30:25.088775851Z caller=query.go:468 msg="starting query node"
level=info ts=2019-02-11T09:30:25.092463697Z caller=query.go:437 msg="Listening for query and metrics" address=<IP_ADDRESS>:19192
level=info ts=2019-02-11T09:30:25.094654745Z caller=query.go:460 component=query msg="Listening for StoreAPI gRPC" address=<IP_ADDRESS>:10901
level=info ts=2019-02-11T09:30:30.096756862Z caller=storeset.go:250 component=storeset msg="adding new store to query storeset" address=<IP_ADDRESS>:19092
level=info ts=2019-02-11T09:30:30.096901412Z caller=storeset.go:250 component=storeset msg="adding new store to query storeset" address=<IP_ADDRESS>:19090

Anything else we need to know

Hm.. I think it is actually quite related to this:
https://github.com/improbable-eng/thanos/issues/834
https://github.com/improbable-eng/thanos/issues/829
This all is related to this PR: https://github.com/improbable-eng/thanos/pull/753 where we change the postings and matchers. Looking more into that, but I am on holidays, so have limited time.

In mean time try deploying thanos-store in 0.2.1.

Thanos store 0.2.1 seems to be working fine for now, enjoy your holidays!

We fixed the matchers here: https://github.com/improbable-eng/thanos/pull/839
Also we added extended test cases, but I don't think we can repro your case. Can you try master image for thanos-store?

Looks like the second scenario from the issue has been fixed! Unfortunately the first has not.
If it'd help I can provide access to the GCS bucket? DM: @BenClapp

I think just more info in what is wrong is fine for now.
So this doesn't not work?

up{job=~"thanos"} returns thanos metrics correctly, however up{invalidLabelName=~"thanos"} behaves as if the query was for only up. In this case, the query returns incorrect results for all time.

What Prometheus itself is doing? It is doing as you expect? And what you expect? Because for "invalid label" ~= the flow is that it gives all, because we filtered out what we could - nothing because label does not exist. (:

Sure :) So with the build from master, this is what I see.

Query for up{invalidLabelName=~"foo"} returns all results, like querying up
Query for up{job=~"invalidLabelValue"} returns all results, like querying up or up{job=~".+"}

In both cases Prometheus returns no results, as I would expect.
I may be mistaken, but shouldn't the logic be to use the label selectors to select series, rather than to filter away series which don't match?

To update on this scenario from the original post

container_memory_usage_bytes{name=~"thanos-compact} returns metrics for all containers, whereas container_memory_usage_bytes{name="thanos-compact} returns metrics for only thanos-compact. In this case, the invalid results are only for a 6h window, all results outside of this window are correct. The blocks in this 6h window were uploaded with thanos 0.2.1 components.

Blocks that have a successful regex match return results as I would expect, that is only series for {name=thanos-compact}. Blocks that do not have any series that match, return all series for this metric name instead.

Confirming the issue.
Another thing to note is that it works fine from thanos-query UI, for example
go_goroutines{instance=~"thanos-query"}
returns single value.
But grafana doing:
GET api/datasources/proxy/1/api/v1/query_range?query=go_goroutines%7Binstance%3D~%22thanos-query%22%7D&start=1550571840&end=1550582670&step=30

to the same thanos-query and get 174 results.

Blocks that do not have any series that match, return all series for this metric name instead.

Ok I think this is a key issue here (: let me again double check between our and tsdb matching in this detail.

Found & fixed: https://github.com/improbable-eng/thanos/pull/862
PTAL and thanks all for details input on what's broken (: Silly bug in edge case ): I wish there were more unit tests for TSDB we could get test cases from. Now our test cases are much more extended then for TSDB itself - hopefully it covers now all we need.

#862 fixed and confirmed by @benclapp :+1: closing.

Thank you, confirming the fix in master-2019-02-21-0c730c1


[SMALLFIX]remove the description

https://alluxio.atlassian.net/browse/ALLUXIO-2302
MG1633087

Can one of the admins verify this patch?

ok to test

Jenkins, add to whitelist

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Alluxio-Pull-Request-Builder/11940/
Test PASSed.

LGTM
thanks for the patch

alluxio-bot, check this again please

alluxio-bot, check this please


Remote services installer - can't load rtvs package

Needs to be installed by the remote installer?
Switching R Workspace completed
Error in base::loadNamespace("rtvs", lib.loc = ".") :
  there is no package called ‘rtvs’
>

Yes it is...

Also #2316

Done


"Internal error" from https://testnet.evm.nodes.onflow.org when calling eth_getBlockByNumber on specific blocks

Instructions
Please fill out the template below to the best of your ability and include a label indicating which tool/service you were working with when you encountered the problem.
Problem
the public RPC seems to be having some issues,, e.g.:
curl --silent --location 'https://testnet.evm.nodes.onflow.org' --header 'Content-Type: application/json' --data '{"method":"eth_getBlockByNumber","params":["0x36C5F1", false],"id":1,"jsonrpc":"2.0"}'

always returns:
{
    "jsonrpc": "2.0",
    "id": 1,
    "error": {
        "code": -32000,
        "message": "internal error"
    }
}

That was observed on multiple blocks: 3589614, 3589615, 3589616, 3589617, 3589618. There may be more.
A more random recent block is returned w/o issues, e.g.:
curl --silent --location 'https://testnet.evm.nodes.onflow.org/' --header 'Content-Type: application/json' --data '{"method":"eth_getBlockByNumber","params":["0x37831D", false],"id":1,"jsonrpc":"2.0"}'

Steps to Reproduce
As per above
Acceptance Criteria
Response should be successful and correct block data should be returned.
Context
Axelar Amplifier integration. The whole Flow integration won't work unless events can be queried from an RPC reliably.

This was fixed and will be reflected once we switch to the EVM GW that reindexed the data. Will be done today.

The fix has been released:
% curl --silent --location 'https://testnet.evm.nodes.onflow.org' --header 'Content-Type: application/json' --data '{"method":"eth_getBlockByNumber","params":["0x36C5F1", false],"id":1,"jsonrpc":"2.0"}'
{"jsonrpc":"2.0","id":1,"result":{"number":"0x36c5f1","hash":"0xeebc092ce664a31d7d562571d8ec52324cc0aa12cb32f2c15fc76d1f29be1e08","parentHash":"0x6479f9541f36886f820d591dbac5375eacd93c0dc179555addd410645cdb2953","nonce":"0x0100000000000000","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","logsBloom":"0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","transactionsRoot":"0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421","stateRoot":"0x0000000000000000000000000000000000000000000000000000000000000000","receiptsRoot":"0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421","miner":"0x0000000000000000000000030000000000000000","difficulty":"0x0","totalDifficulty":"0x0","extraData":"0x","size":"0xa3","gasLimit":"0xe4e1c0","gasUsed":"0x0","timestamp":"0x66d87f2a","transactions":[],"uncles":[],"mixHash":"0x0000000000000000000000000000000000000000000000000000000000000000","baseFeePerGas":"0x0"}}


Error: no packages are defined here

I was trying to come up with some very little project that shows, hopefully, how to use jbuilder, because at least for me it's a bit mystical; that project is here: https://github.com/alinpopa/jbuilder_example01
Trying to build it using the bellow command, and I'm getting the following error, which doesn't really make too much sense to me:
jbuilder build --debug-actions --debug-dependency-path --debug-rules --debug-findlib @install

Workspace root: /Users/alin/work/ocaml/jbuilder_example01
File "bin/jbuild", line 1, characters 0-0:
Error: no packages are defined here

I believe that I'm trying to find out what's the magical incantation to build a proper project, with some minimalistic structure, only very few modules, etc. I'd think that having an example project, more than a very simple one liner hello world, would help a bit with starting working with jbuilder (at least this would help me, but I wasn't able to find a proper simple project, without using a mix of opam/make/merlin files, which confuses me a lot).
Sorry, I'd have raise this as a question on some mailinglist/slack channel/something, but turns out that there is no such communication channel? For example, a JaneStreet OCaml mailing list, or anything... is this mailing list something I could use for such a topic? https://groups.google.com/forum/#!forum/ocaml-core
Thanks.

I've created a pull request to your project fixing up your project and giving you some tips. This should be enough for a "hello world" starter. I'm curious, did you find the information in https://github.com/janestreet/jbuilder/blob/master/doc/quick-start.org useful? It seems like a pretty complete tutorial.
As for examples, I'd look at other janestreet packages. These aren't hello world level, but should be useful to you eventually.
Regarding communication channels. #ocaml on freenode is pretty accessible to ask quick questions.

The quickstart doesn't really show how a proper project layout should look like, so I tried looking at other janestree's projects, but again, due to my lack on knowledge in this area, was a bit difficult to understand what's happening, so I went with some quick and dirty trial and error approaches, that got me to this point. Your PR works just fine, and also the extra clarifications you added regarding the opam files were quite helpful; thank you.

Following this ticket, I added an example directory with a complete project example. I also explained in the README why many projects have a toplevel Makefile

Oh, that's very nice; thank you.


APEXCORE-649 Infrastructure for user define stram event listeners.

Added a generic framework for application wide listeners as discussed in
<EMAIL_ADDRESS>Following functionality is added

listening to container heartbeat to extract stats and metrics.
listening to stram events.
committed window id move event.

@vrozov I have removed checkstyle errors.

Another example where new code was added under legacy packages. I see no reason for it.

Agreed, they can go into org.apache.apex.

Can you squash the commits

I don't see a feature description in the JIRA that would help a user to understand this feature and its use cases. Please provide this before merging the code.
https://issues.apache.org/jira/browse/APEXCORE-649

@PramodSSImmaneni @tweise Added description to the Jira about how this feature can be used.

@tushargosavi can you rebase to latest


Host-based routing for http and https requests

What steps will reproduce the problem?
Проблема строится на том, что текущая реализация роутера не предусматривает вариацию, когда запрос к домену идёт через оба протокола. Например, имеется такой конфиг:
'urlManager' => [
    'enablePrettyUrl' => true,
    'showScriptName' => false,
    'rules' => [
        "http://you-domain.net/some/path" => 'controller/action',
    ],
],

На локальном сервере всё работает как ожидается, но на продакшене, где настроен https, данный роут перестаёт распознаваться, т.к. там getHostInfo() уже возвращает https://you-domain.net.
Я пробовал указывать значение без протокола (то есть "you-domain.net/some/path" => 'controller/action'), но в таком случае роут вовсе не был добавлен в UrlManager.
What is the expected result?
Если я не укажу протокол, то сверка роута должна происходить только по имени хоста, без проверки протокола.
Additional info

Q
A

Yii version
2.0.9

PHP version
7.0.11

Operating system
Docker 1.12.1 (php:7.0.11-fpm)

Probably related to #3047.

Nope, it's different. The problem here is that in domain-relative URL rules you have to specify http or https and can't use something which works for both.

@samdark, я близок к завершению PR. Только я не привязывался только к http или https, а делаю поддержку любого протокола.

Use optional s for protocol specification:
'rules' => [
        "http(s)?://you-domain.net/some/path" => 'controller/action',
    ],

IMO UrlRule should have property like $validSchemas with value like ['https', 'http']. So if we have rules like:
['pattern' => 'login', 'validSchemas' => ['https'], ...],
['pattern' => 'http://exaple.com/home', 'validSchemas' => ['https', 'http'], ...]

then:

https://example.com/login will match first rule
http://example.com/login will NOT match first rule
http://example.com/home will match second rule
https://example.com/home will match second rule

UrlNormalizer could use UrlRule::$validSchemas to handle redirection to valid schema.

@klimov-paul, nice try, but it's don't work. Inside UrlRule Yii2 escape any characters like (, ?, ) and final regex contains something like: http\(s\)\?....

nice try, but it doesn't work. Inside UrlRule Yii2 escape any characters like (, ?, ) and final regex contains something like: http(s)?....

Sorry, this one works:
'rules' => [
        "<protocol:http|https>://you-domain.net/some/path" => 'controller/action',
    ],

@klimov-paul, ok, it works.
But I think that current behavior is not expected, because I don't see any error, or something else, that explain, why rule without scheme was not added to UrlManager. My proposal is simple and expected way to define route, that match only for specified host without reference to scheme.

My proposal is simple and expected way to define route, that match only for specified host without reference to scheme.

Sorry, but I can not see any proposal from your side - only a complain.
Protocol mention is necessary to determine whether URL rule involves host name or not.
Unless there is a syntax which allows to explicitly determine UrlRule contains domain, but do not contain protocol at the same time - there is not much can be done here.

I can not see any proposal from your side

My proposal is implement such syntax for routes:
'rules' => [
    "you-domain.net/some/path" => 'controller/action',
],

you-domain.net can be extracted by regex (any-string-with-dots)/. Or I don't see some case?

//example.com/home?

@rob006, yes, it will be better, because I found, that path can contain dots or hostname can be without dots.

My proposal is implement such syntax for routes:

Such syntax is unacceptable: string you-domain.net can be a valid URL part after domain name.
For example:
http://domain.com/another.domain.com

Or to have more real world example:
http://domain.com/file.html

//example.com/home?

Similar problem. While usually double slash (//) is not used in URLs it is still valid. For example:
http://domain.com/catalog//1

We're expecting it at the very beginning, not in the middle.

I think protocol relative URLs support is a good idea.

Perhaps, it should be possible to use :// as host involving indicator.

Perhaps, it should be possible to use :// as host involving indicator.

//example.com is standard syntax for protocol relative URLs: https://en.wikipedia.org/wiki/Uniform_Resource_Locator#prurl

Yes. //, not ://.

Resolved by 16a5777

Or not

I think not.


Add environments folder with .env-prod.example, .env-test.example, .env-dev.example

Use some library for suit .env files parsing like python-dotenv

.env-test.example, .env-dev.example - make sense
.env-prod.example - I think it's more safe to prohibit the placement of this file

Yep, you are right