text:
Incorrect EXTRA_ARGS in samples/subsys/tracing/sample.yaml

Describe the bug
Extremely trivial. EXTRA_ARGS section has CONF_FILE parameters defined with quotes which causes build failure.
e.g.
 extra_args: CONF_FILE="prj_user.conf"

Please also mention any information which could help others to understand
the problem you're facing:

What target platform are you using?
Linux.
What have you tried to diagnose or workaround this issue?
Yes, removed the quotes and voila.

-    extra_args: CONF_FILE="prj_user.conf"
+    extra_args: CONF_FILE=prj_user.conf

Is this a regression? If yes, have you been able to "git bisect" it to a
specific commit?
Not really a regression, because there seems to be multiple EXTRA_ARGS that use quotes from multiple authors, so somehow this makes me think that I'm doing something wrong. So please let me know...

To Reproduce
Steps to reproduce the behavior:
 west build -p -b qemu_riscv32 -T samples/subsys/tracing/sample.tracing.user
Expected behavior
Successful configuration.
Impact
Technically a "showstopper" but really an annoyance because it's trivial at worst.
Logs and console output
-- Including generated dts.cmake file: /home/asayin/zephyr_sdks/microblaze_devel/zephyr/build/zephyr/dts.cmake
CMake Error at /home/asayin/zephyr_sdks/microblaze_devel/zephyr/cmake/modules/kconfig.cmake:275 (message):
  File not found:
  /home/asayin/zephyr_sdks/microblaze_devel/zephyr/samples/subsys/tracing/"prj_user.conf"
Call Stack (most recent call first):
  /home/asayin/zephyr_sdks/microblaze_devel/zephyr/cmake/modules/zephyr_default.cmake:115 (include)
  /home/asayin/zephyr_sdks/microblaze_devel/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:66 (include)
  /home/asayin/zephyr_sdks/microblaze_devel/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
  CMakeLists.txt:9 (find_package)

-- Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: /home/asayin/zephyr_sdks/microblaze_devel/cmake/bin/cmake -DWEST_PYTHON=/home/asayin/zephyr_sdks/microblaze_devel/python/bin/python3.8 -B/home/asayin/zephyr_sdks/microblaze_devel/zephyr/build -GNinja -DBOARD=qemu_riscv32 '-DCONF_FILE="prj_user.conf"' -S/home/asayin/zephyr_sdks/microblaze_devel/zephyr/samples/subsys/tracing

Environment (please complete the following information):
Linux, SDK 0.16.1
Additional context
Somewhat relates to #60295

This doesn't look right, @PerMac any clue what's going on, since quotes are needed when testing elsewhere e.g. https://github.com/zephyrproject-rtos/zephyr/pull/59747 ?

I believe it is an issue with west_commands for -T where it tries to load twister's configs from yaml. Calling this test through twister passes and has CONFIG_TRACING_USER=y in its .config.

I can look at it further after the weekend

authors: PerMac alpsayin nordicjm


text:
logging: support alternative print formatting function pointers

Is your feature request related to a problem? Please describe.
For some use cases, it is helpful to support alternative string formatting function calls. For example, when dealing with logging in other programming languages (e.g. Rust).
Describe the solution you'd like
Support an additional field in e.g. struct log_source_const_data (or perhaps somewhere else that is more appropriate) that allows users to specify a function pointer to a custom string-formatting function.
For traditional logging, this could just be left as NULL for the default behaviour (or populated, if that is preferred).
If the function pointer is non-NULL, the log core would use the provided print formatter instead of the default.
Use of this feature could be gated via Kconfig.
It would be great if this could be declared via LOG_MODULE_REGISTER().
Describe alternatives you've considered
Additional context
Related RFC #65837

Want to bump this feature request -- it would be very helpful for a project I am working on that takes the logs from zephyr and processes them using an existing program that prefers a specific log format that differs from zephyr's. format.

source: gharchive/issue

authors: cfriedt nonas-hunter

repo: zephyrproject-rtos/zephyr

license_type: permissive

license_source: github-api


text:
doc: Documentation issue in 'boards/beagle/beaglev_fire/doc/index' missing command for openOCD settings

Describe the bug
<< Please describe the issue here >>
<< You may also want to update the automatically generated issue title above. >>
The steps provided in the "Flashing" section of the page are missing a command which is required for openOCD to run:
sudo LD_LIBRARY_PATH=<softconsole_path>/openocd/bin \ <softconsole_path>/openocd/bin/openocd  --file \ <softconsole_path>/openocd/share/openocd/scripts/board/microsemi-riscv.cfg
should be:
sudo LD_LIBRARY_PATH=<softconsole_path>/openocd/bin \ <softconsole_path>/openocd/bin/openocd --command "set DEVICE MPFS" --file \ <softconsole_path>/openocd/share/openocd/scripts/board/microsemi-riscv.cfg
without '--command "set DEVICE MPFS"' openOCD fails to connect to some targets.
Environment

Page: boards/beagle/beaglev_fire/doc/index
Version: main
SHA-1: 8dc3f856229ce083c956aa301c31a23e65bd8cd8

@hughbreslin Can you submit a PR for fixing this, please?

Hey @henrikbrixandersen
I created a PR for it #76723

authors: con-pax henrikbrixandersen hughbreslin


text:
test/kernel: timer_api: Remove 'build_only' on tickless variant

Based on #20905
Checking if #20905 if fixing the CI issue that the 'build_only' directive was meant to bypass

What is, effectively, different in prj_tickless.conf, compared to prj.conf?

@andrewboie ?

@erwango this PR seems to have developed conflicts with upstream which needs resolving, so could you please rebase? @andrewboie there seems to be a question to you in the latest comments.

source: gharchive/pull-request

authors: erwango jhedberg


text:
sanitycheck: Use logger and avoid using global options

Move away from custom output functions and use logging module instead. Cleanup
most usage of global options and instead pass arguments and/or use class
variables. This is needed to make unittesting of sanitycheck easier, right now
everything is being controlled via command line options.

@nashif will you add --pre-test and --post-test options to the sanitycheck to let before and after west flash run additional program?

@nashif will you add --pre-test and --post-test options to the sanitycheck to let before and after west flash run additional program?

after this PR get merged, and I am not adding --pre-test and --post-test, those will have to be per platform and part of the hardware map for that platform.

@nashif will you add --pre-test and --post-test options to the sanitycheck to let before and after west flash run additional program?

after this PR get merged, and I am not adding --pre-test and --post-test, those will have to be per platform and part of the hardware map for that platform.

Do I need to start modifying sanitycheck script to add that kind of options to let Microchip board be added into the Sanitycheck testing? Microchip requires that options. Because during programming board must be in the reset mode. If nobody will add that kind of options, Microchip will not work with Sanitycheck.

@nashif will you add --pre-test and --post-test options to the sanitycheck to let before and after west flash run additional program?

after this PR get merged, and I am not adding --pre-test and --post-test, those will have to be per platform and part of the hardware map for that platform.

Do I need to start modifying sanitycheck script to add that kind of options to let Microchip board be added into the Sanitycheck testing? Microchip requires that options. Because during programming board must be in the reset mode. If nobody will add that kind of options, Microchip will not work with Sanitycheck.

Now I understand what do you mean about hardware map. Generate hardware map for the Microchip board, and then in the hardware map write path to the program, then sanitycheck can read hardware map and execute that program. Sorry for my misunderstanding. Unfortunately, hardware map is not available for the Microchip board.

@nashif
I have a performance issue.

During running of your branch's sanitycheck
sanitycheck --device-testing --device-serial /dev/ttyACM0 -p reel_board -T ../tests/kernel/fifo -v -v
it freezes in that place
DEBUG   - run test: reel_board/tests/kernel/fifo/fifo_api/kernel.fifo.poll DEBUG   - run test: reel_board/tests/kernel/fifo/fifo_api/kernel.fifo DEBUG   - run test: reel_board/tests/kernel/fifo/fifo_usage/kernel.fifo.usage DEBUG   - run test: reel_board/tests/kernel/fifo/fifo_timeout/kernel.fifo.timeout DEBUG   - run test: reel_board/tests/kernel/fifo/fifo_timeout/kernel.fifo.timeout.poll DEBUG   - run test: reel_board/tests/kernel/fifo/fifo_usage/kernel.fifo.usage.poll
Run of the sanitycheck
sanitycheck --device-testing --device-serial /dev/ttyACM0 -p reel_board -T ../tests/kernel/critical/ -v -v
freezes too DEBUG   - Building /home/maksim/zephyrproject/zephyr/tests/kernel/critical for reel_board DEBUG   - run test: reel_board/tests/kernel/critical/kernel.common.critical

Build log says:
 [ 96%] Linking C executable zephyr_prebuilt.elf  Memory region         Used Size  Region Size  %age Used             FLASH:       32732 B         1 MB      3.12%              SRAM:        7448 B       256 KB      2.84%          IDT_LIST:          72 B         2 KB      3.52%  [ 96%] Built target zephyr_prebuilt  Scanning dependencies of target linker_pass_final_script_target  [ 96%] Generating linker_pass_final.cmd                                            [ 96%] Built target linker_pass_final_script_target  [ 97%] Generating isr_tables.c  Scanning dependencies of target zephyr_final  [ 98%] Building C object zephyr/CMakeFiles/zephyr_final.dir/misc/empty_file.c.obj  [ 98%] Building C object zephyr/CMakeFiles/zephyr_final.dir/isr_tables.c.obj  [100%] Linking C executable zephyr.elf  Generating files from zephyr.elf for board: reel_board  [100%] Built target zephyr_final
What can be the reason that during the run process just got stuck?

While reworking the logging functionality, would it also be possible to fix the issue with colors on Windows with cmd.exe?
https://github.com/zephyrproject-rtos/zephyr/issues/21409

Do I need to start modifying sanitycheck script to add that kind of options to let Microchip board be added into the Sanitycheck testing? Microchip requires that options. Because during programming board must be in the reset mode. If nobody will add that kind of options, Microchip will not work with Sanitycheck.

I am not sure how this is related to this PR.

@maksimmasalski  try again.

While reworking the logging functionality, would it also be possible to fix the issue with colors on Windows with cmd.exe?

yeah, will take a look at this after this gets merged.

yeah, will take a look at this after this gets merged.

just fixed this here :)

@maksimmasalski try again.

Now it works.

authors: JordanYates maksimmasalski nashif


text:
drivers: lora: sx1276: rework gpio configuration

Introduce sx1276_configure_pin() helper macro, which hide lots of
boilerplate preprocessor and C code. Doing so allows to uncover
inconsistent gpio initialization flow and prevent such in future.
It seems like output of gpio_pin_configure() for several
gpios (antenna_enable, rfi_enable, rfo_enable) was assigned to variable,
but its values was never checked. Return value from gpio_pin_configure()
of tcxo_power gpio was even not catched. The only output gpio
configuration that was handled properly was actually reset gpio.
Fix that inconsistent behavior by always checking return value of
sx1276_configure_pin().

Any chance you could move the macro and helper function to sx12xx_common.{c,h}? That'd simplify reuse it in the sx126x driver.

authors: andysan mniestroj


text:
BLE GATT Object Transfer Service

PR changes:

Added Object Transfer Service library
Added Peripheral OTS sample which demonstrates how to use service library.

The sample lacks some mandatory components (Readme and yaml files). I'm planning to add them once review for the library is finished.

@Thalley, @joerchan, thank you for your reviews - I addressed all your comments.
I have been marking them as resolved so that it is easier for me to track remaining work items. However, if you think that something is still missing after my response or fix in code, you can unresolve your review comment.

I tagged the OTS API as experimental so that we can still make changes to the API after it is merged.

This PR contains commits from another PR in order to work:
https://github.com/zephyrproject-rtos/zephyr/pull/27830
They will be removed after linked PR is merged.

This PR contains commits from another PR in order to work:
#27830
They will be removed after linked PR is merged.

One of them are also part of https://github.com/zephyrproject-rtos/zephyr/pull/27840

@Thalley, in the last patch, I addressed all comments except the unresolved one from your last review round.

I would appreciate if we could get this in before the Zephyr freeze. There are still two unresolved comments regarding naming discussion. I hope we can resolve them soon.

authors: Thalley kapi-no


text:
doc: release: 2.5: Add notes about Atmel, Cypress, UpdateHub, Inventek, TagoIO, Bossac

Atmel boards and drivers
Cypress SoC, boards and drivers
UpdateHub improvements
Inventek es-WIFI shield
TagoIO Network Cloud sample
West bossac runner improvements

Rebased and fixed both comments from @ioannisg.

Rebased and fixed both comments from @ioannisg.


text:
samples: bluetooth: Fix scan filter

We should use no filter filter to process adv data
according to code comment above.
Signed-off-by: Lingao Meng menglingao@xiaomi.com

https://github.com/zephyrproject-rtos/zephyr/blob/main/samples/bluetooth/central_ht/src/main.c#L226


text:
Bluetooth: Support setting long periodic advertising data

If the data is longer than what can fit in one fragment, the data is sent to the controller in multiple operations.

Updated the PR to use ad_stream created in https://github.com/zephyrproject-rtos/zephyr/pull/41537


text:
cmake: Fix "Loading Zephyr module(s)" message

Modules' names would get concatenated together into single
string, making the message hard to read.
Signed-off-by: Dominik Ermel dominik.ermel@nordicsemi.no
Was:
Loading Zephyr module(s) (Zephyr base (cached)): extensionssysbuild_extensionspythonwestrootzephyr_moduleboardsshieldssysbuild_kconfig

after fix:
Loading Zephyr module(s) (Zephyr base (cached)): extensions sysbuild_extensions python west root zephyr_module boards shields sysbuild_kconfig

Or

Would it be simpler to use string(JOIN) ? https://cmake.org/cmake/help/latest/command/string.html

Or actually list(JOIN) for this case. https://cmake.org/cmake/help/v3.20/command/list.html#join

Or

Would it be simpler to use string(JOIN) ? https://cmake.org/cmake/help/latest/command/string.html

Or actually list(JOIN) for this case. https://cmake.org/cmake/help/v3.20/command/list.html#join

Good point. Fixed.

authors: de-nordic jeremybettis


text:
drivers: video: video_mcux_csi: removed camera device check

Camera device cannot be checked in CSI driver since the CSI driver enables the CLK signal required by camera to work. Besides, the VIDEO_INIT_PRIORITY must be lower than CONFIG_KERNEL_INIT_PRIORITY_DEVICE to initialize the CSI driver before the camera driver.
fixes #55278

Hi @jeronimoagullo. It looks like the mt9m114 sensor communicates over an I2C bus, specifically LPCI2C1 on the RT1064 EVK. This device would be clocked (and have pin settings applied) by the LPI2C driver (https://github.com/zephyrproject-rtos/zephyr/blob/main/drivers/i2c/i2c_mcux_lpi2c.c), which initializes with priority CONFIG_I2C_INIT_PRIORITY, which defaults to KERNEL_INIT_PRIORITY_DEVICE. Shouldn't the mt9m114 sensor driver therefore have its initialization priority raised to be between CONFIG_VIDEO_INIT_PRIORITY, and CONFIG_I2C_INIT_PRIORITY, so that I2C is ready and the MMT9M114 driver can initalize? Then removing the dependency check would not be required.

#53381 appears to be trying to address the same thing

#53381 captured the same changes plus some additional items.

authors: danieldegrasse dleach02 jeronimoagullo


text:
drivers: lpadc: Make DT props match Reference manual and hardware instead of SDK enum identifiers

Change the DT property value meanings for the LPADC power level and voltage reference to match what is documented for the hardware in the SOC reference manual, instead of corresponding to NXP SDK enum names.
Remove all of the build asserts in favor of devicetree enums

@mmahadevan108 updated with your suggestion

@decsny please resolve the merge conflict and we can then merge tis

@decsny please rebase

authors: carlescufi decsny dleach02


text:
tests: mcuboot: pytest: Add image swap test with mcumgr

Added application based on SMP Server Sample. Application is build together with MCUboot using sysbuild and is flashed onto device in one step. Second application (smp_srv) is only build with sysbuild (not flashed). Tests are automated with pytest - new harness of Twister. Second application is uploaded by mcumgr into device and tested. Automated scenarios to test upgrades (image upload, test, revert, confirm), and to test downgrade prevention mechanism (separated in testcase.yaml, because needs to have changed some configuration options).
Added also scenario to test upgrade with an invalid signatures (for that case added helper method to wrap west sign command).
Run test with Twister:
./zephyr/scripts/twister -vv --west-flash -T zephyr/tests/boot/with_mcumgr -p nrf9160dk_nrf9160 --device-testing --device-serial /dev/ttyACM0
*mcumgr must be installed on the system ancd mcumgr command available.

One more observation - during running those tests by following command:
./scripts/twister -vv --inline-logs -p nrf52840dk_nrf52840 -T tests/boot/with_mcumgr --device-testing --device-serial /dev/ttyACM0 --west-flash

I got following warning from pytest at the end of test:
...
DEBUG   - PYTEST: =============================== warnings summary ===============================
DEBUG   - PYTEST: ../../.local/lib/python3.8/site-packages/_pytest/config/__init__.py:747
DEBUG   - PYTEST: /home/redbeard/.local/lib/python3.8/site-packages/_pytest/config/__init__.py:747: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: twister_harness.fixtures.mcumgr
DEBUG   - PYTEST: self.import_plugin(import_spec)
DEBUG   - PYTEST: -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
DEBUG   - PYTEST: - generated xml file: /home/redbeard/zephyrproject/zephyr/twister-out/nrf52840dk_nrf52840/tests/boot/with_mcumgr/boot.with_mcumgr.test_downgrade_prevention/report.xml -
DEBUG   - PYTEST: 1 passed, 5 deselected, 1 warning in 49.69s
...

It doesn't look so dangerous but it would be nice to know what is a root cause or what could be done to avoid it.

@gopiotr thanks for review!
Regarding PytestAssertRewriteWarning, I missed it, because I was testing with installed pytest-twister-harness plugin, then there is no warning, The rootcause is described here:
https://docs.pytest.org/en/latest/how-to/writing_plugins.html#requiring-loading-plugins-in-a-test-module-or-conftest-file
I will add pytest.register_assert_rewrite('twister_harness.fixtures.mcumgr') to __init__.py file and it should be enough for that warning.

@gopiotr thanks for review! Regarding PytestAssertRewriteWarning, I missed it, because I was testing with installed pytest-twister-harness plugin, then there is no warning, The rootcause is described here: https://docs.pytest.org/en/latest/how-to/writing_plugins.html#requiring-loading-plugins-in-a-test-module-or-conftest-file I will add pytest.register_assert_rewrite('twister_harness.fixtures.mcumgr') to __init__.py file and it should be enough for that warning.

Thanks for explanation - maybe do this adding pytest.register_assert_rewrite('twister_harness.fixtures.mcumgr') in separate commit?

Thanks for explanation - maybe do this adding pytest.register_assert_rewrite('twister_harness.fixtures.mcumgr') in separate commit?

I've added this to the current PR, but if we need this fix faster, I will move it later

I've added this to the current PR, but if we need this fix faster, I will move it later

I'm fine with have it in this PR - I propose to have it in separate commit - changes in pytest-twister-harness are connected with test tool, not directly with "mcuboot validate invalid signatures test", and thus now commit description for those changes are inadequate.

I'm fine with have it in this PR - I propose to have it in separate commit - changes in pytest-twister-harness are connected with test tool, not directly with "mcuboot validate invalid signatures test", and thus now commit description for those changes are inadequate.

Done. Moved to separate commit.

@nordicjm @de-nordic Can you have a look if the test scenarios makes sense to you?

The comment is just for a minor detail. In general LGTM. I am not happy that it has to use 'platform_allow' but it seems to be the only way. There is already an open ticket for figuring out how to properly filter on mcuboot availability https://github.com/zephyrproject-rtos/zephyr/issues/58122

@gchwier could you add a MAINTAINER entry for the new test directory so that followup PRs gets assigned by the bot? Or should this be under tests/subsys/mgmt/ instead?

@gchwier could you add a MAINTAINERS.yml entry for the new test directory so that followup PRs gets assigned by the bot? Or should this be under tests/subsys/mgmt/ instead?

I do not know where is good place for these tests. Rather not tests/subsys/mgmt/, we are not testing mcumgr, but using it as a tool.
Here we want to test upgrade with MCUboot and we use sysbuild and pytest. In MAINTAINERS.yml I found section with tests/boot/test_mcuboot/, maybe could be better to extend that section.
https://github.com/zephyrproject-rtos/zephyr/blob/e1e4fcc70135e30e7634df80391edd77f5f3ba98/MAINTAINERS.yml#L3107
@de-nordic, @nordicjm, @d3zd3z what do you think about that?

authors: PerMac fabiobaltieri gchwier gopiotr


text:
Bluetooth: mesh_shell: Increase L2CAP TX buffer count

In case of split host & controller we may need to do ACL segmentation
of packets. Sending the composition data will already have allocated
three TX buffers, so trying to segment the first one further will
result in a deadlock. Increase the buffer count from the default (3)
to 4 to work around this risk.
Signed-off-by: Johan Hedberg johan.hedberg@intel.com

Codecov Report

Merging #5933 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #5933   +/-   ##
=======================================
  Coverage   54.05%   54.05%
=======================================
  Files         461      461
  Lines       43739    43739
  Branches     8369     8369
=======================================
  Hits        23643    23643
  Misses      19955    19955
  Partials      141      141

Continue to review full report at Codecov.

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

authors: codecov-io jhedberg


text:
boards: shields: fix support for rk055hdmipi4ma0 on RT595

In 42c6f3311be (boards: stop using kscan for LVGL touch input), GT911
node label was renamed for rk055hdmipi4ma0 shield. The node label rename
was missed in the RT595 EVK overlay, fix this.
Fixes #69302
Commit 4844d015a4d (drivers: mipi_dsi: dsi_mcux_2l add msg flag for
low power mode) changed the behavior of the dsi_mcux_2l driver to always
use high speed mode unless low speed mode was selected. Restore the
previous behavior, where high speed mode is only the default for long
transfers, and not used for short transfers.
(FYI @mjchen0)

Is the reason my earlier change broke the rk055 display because it only supports high speed mode for DCS_LONG_WRITES and not for the other transfer types?
Since it's now possible to specify the speed/mode to use per transfer, it seems a bit odd that the speed default changes depending on the cmd/transfer type, and that the flag is ignored by the other transfer types.
If it's a limitation of the rk055 that some transfers should be high speed and some must be low speed, then it should use the msg flag to specify explicitly which mode to use (either high or low) for the particular cmd. Other MIPI DSI devices might be fine with always high speed cmds, which is the case for the display I was working with.

Is the reason my earlier change broke the rk055 display because it only supports high speed mode for DCS_LONG_WRITES and not for the other transfer types?

Since it's now possible to specify the speed/mode to use per transfer, it seems a bit odd that the speed default changes depending on the cmd/transfer type, and that the flag is ignored by the other transfer types.

I don't see anything in the datasheet for the HX8394 specifying that, but it is definitely possible I missed it. Some of the initialization commands for the HX8394 panel are long enough they should be sent in high speed mode, so I don't think there is an issue with the transition sequence to HS mode. I'll put a DNM on this until I get a chance to update the HX8394 panel driver to use low power mode for short commands.

hx8394 driver has been updated, removing DNM

@erwango, can you help review

@erwango friendly ping :)


text:
scripts/ci/pylintrc: Disable consider-using-enumerate

This "convention" report ("C0200: Consider using enumerate instead of iterating with range and len") is overbroad.  It wants to detect the case of code that is looping over an iterable by index but is also extracting the item itself by index; enumerate() gives you both, so it's preferred.
But sometimes that's just an artifact, and the index is being used symmetrically to index into two arrays, for example it wants to turn this fairly obvious and idiomatic array copy construction:
for i in range(len(input)):
    output[i + offset] = input[i]

Into this, which is asymettric, and obscures the clarity of what's happening (you'll not it also involves more bytes of code, not fewer!):
for i, elem in enumerate(input):
    output[i + offset] = elem

Turn it off, as it's otherwise blocking CI on clean idiomatic code.

I'm throwing a minor tantrum over this particular warning.  Please merge to unblock #72766
Really I think we need to more seriously consider the impact of our current pylint setup.  There are a lot of these "consider convention" reports being promoted to merge-blocking errors, and IMHO that's just not appropriate for a tool that is this strict.  There is a lot of subjectivity in these, it's not like checkpatch or coverity or whatever where there's usually fire where there's smoke.

I see https://github.com/zephyrproject-rtos/zephyr/pull/72766 merged.  Is this PR still needed?

I was hoping to get purchase, but if not we can close it.  Just in general I'm arguing for the paradigm of "We have coding standards and use tooling to discover points that require human decisions."[1], vs. "We have tooling to make decisions about coding standard violations and require humans to modify or annotate their code instead of deciding"[2]
I mean, I write a ton more C than Python, so for me personally this isn't going to be much of a hardship either way.  But I will say I really don't like the smell of a code base being constantly updated with warning #pragmas to evade a tool we trust a little too much.
[1] Our checkpatch usage tends to be in this category, with lots of warning conditions that are non-fatal to CI.
[2] Which is how our pylint setup works, with lots of subjective tests that produce merge blocking failures.

I mean, I write a ton more C than Python, so for me personally this isn't going to be much of a hardship either way. But I will say I really don't like the smell of a code base being constantly updated with warning #pragmas to evade a tool we trust a little too much.

I find only ~70 instances of pylint: disable in the tree, split roughly between samples and scripts.  So overrides of pylint doesn't seem to be abused at this point.

No interest found.  Closing.

authors: andyross keith-zephyr


text:
Carousel Html

Pull Request Template

Please provide all of the details below. Pull requests missing any of the information below will be closed!
Providing the issue number/url helps us identify the problem being solved and keep the issues tab clean and tidy

What issue does this fix?
Summarize what this PR fixes:-
What issue is it attached to?
Fixes #
Checklist
(Add an x between the brackets to check the items)

[ ] I have summarize what this PR fixes above
[ ] I have provided the issue ID/URL above
[ ] I have not added Bootstrap or jQuery and used correct styling guide.
[ ] This PR fixes only the issue mentioned above (create separate PRs for separate issues)
[ ] I was the first one to claim the issue or I created the issue

@Manoj13-coder this is not a carousel like in the mockup and there is no issue linked. I recommend starting with a clean copy, setting the upstream, and running git pull upstream master before pushing changes. I can't really tell that anything has been changed in this pull request, so I'm closing it for now.

repo: zero-to-mastery/Keiko-Corp

license: MIT


text:
Duplicate filename different modules overwrites output

Consider following situation:
Two slice files with the same name but different modules:
Test.ice
module AModule {     struct Test {         bool active;     }; }
Test.ice
module AnotherModule {     struct Test {         bool active;     }; }
The output file Test.h will be overwritten by the last .ice file compilation so that only one header file gets produced. This error usually occur when you use multiple services where possible .ice files have the same name. Our Solution is to use a custom compile script to run slice2cpp and appending the Module name to the output files. E.g. Test.AModule.h and Test.AnotherModule.h. Would be nice to have that as the default behaviour in this msbuild package :).

You can customize the output directory by setting the SliceCompile.OutputDir item metadata
see https://github.com/zeroc-ice/ice-builder-msbuild#customizing-the-slice-to-c-compilation-1

We are adding the .ice files via nuget content files. This would force us to touch .vcxproj and change it manually before we are operatable. Is there a better way while adding the ice files via nuget to the project?

We are adding the .ice files via nuget content files

Not sure what you mean

Files in a nuget package declared as content files as follow:
Package.nuspec
 ....
	<files>
		<file src="Slice\*.ice" target="content\native\Slice" />
	</files>

Will add the defined files during the package installation to the .vcxproj resulting in
Project.vcxproj
...
  <ItemGroup>
    <SliceCompile Include="SliceFiles\AModule\Test.ice" />
    <SliceCompile Include="SliceFiles\AnotherModule\Test.ice" />
  </ItemGroup>
...

Entries.

You can try to add a targets file to your NuGet package, that setups the OutputDir, in the target file you can have something like
    <ItemGroup>
        <SliceCompile Update="**\*.ice">
            <OutputDir>generated/%(SliceCompile.RelativeDir)</OutputDir>
        </SliceCompile>
    </ItemGroup>

This update syntax requires MSBuild version 16.6 and later, see https://learn.microsoft.com/en-us/visualstudio/msbuild/msbuild-items?view=vs-2022#updating-metadata-on-items-in-an-itemgroup-outside-of-a-target

This kinda works. It generates the following physical file output:
generated/%(SliceCompile.RelativeDir)/Test.h         0kb
generated/%(SliceCompile.RelativeDir)/Test.cpp     0kb
generated/AModule/Test.h                                      12kb
generated/AModule/Test.cpp                                  20kb
generated/AnotherModule/Test.h                           12kb
generated/AnotherModule/Test.cpp                        20k
Unfortunate the 0kb versions of the file are the ones which get added in Visual Studio. Whatever task creates those 0kb files does not expand the %(SliceCompile.RelativeDir) Macro.

it is difficult to follow without a complete example to reproduce the issue

Test2.zip
Check the generated folder in the project folder after building the project.

I see the problem, I think the Visual Studio IceBuilder plugin isn't expanding the item metadata correctly.
This will work well for a pure MSBuild build, as a workaround you can try something like
<ItemGroup>
        <SliceCompile Update="SliceFiles\AModule\*.ice">
            <OutputDir>generated/AModule</OutputDir>
        </SliceCompile>
         <SliceCompile Update="SliceFiles\AnotherModule\*.ice">
            <OutputDir>generated/AnotherModule</OutputDir>
        </SliceCompile>
    </ItemGroup>

Thanks for the effort. I will wait for the fix because I would need to touch a lot of projects to implement the workaround.

authors: Gulum pepone

repo: zeroc-ice/ice-builder-msbuild


text:
fix: go issue 16206

p2c.subConn int64字段未对其，导致在Pick中choose(p.conns[0], nil)报错，p2c.go:153

不是很懂，这里字段定义顺序会有什么影响？

不是很懂，这里字段定义顺序会有什么影响？

https://pengrl.com/p/21030/
32位系统int64初始化要求地对齐的，subConn初始化，上面一个结构图和接口先分配内存，不能保证下面的int64地址无误的，这个是go的问题。

不是很懂，这里字段定义顺序会有什么影响？

https://pengrl.com/p/21030/
32位系统int64初始化要求地对齐的，subConn初始化，上面一个结构图和接口先分配内存，不能保证下面的int64地址无误的，这个是go的问题。

repo: zeromicro/go-zero


text:
Spark SQL?

Spark SQL is pretty similar to normal SQL. Unfortunately, there are a couple keywords that don't format. Example:
SELECT *
FROM titus_logs LATERAL VIEW json_tuple(other_properties['fields'], 'MESSAGE', '_TRANSPORT', '_HOSTNAME')
fields as message,
                             transport,
                             hostname
                LATERAL VIEW json_tuple(other_properties['environment'], 'ec2Region', 'ec2AZ')
                environment as region,
                                                   az
WHERE dateint >= 20181006
  AND dateint <= 20181010
  AND message LIKE "Linux version%"
LIMIT 10;

LATERAL VIEW should be on two different lines. Should I create a new SQL dialect, or somehow extend standard sql?

Currently there's no good way of extending one dialect from another. So an easier route is to just create a new dialect.

Spark support is now present in 3.1.0 release.

Spark support is now present in 3.1.0 release.

authors: nene sargun

repo: zeroturnaround/sql-formatter

license: mit

license_source: bigquery


text:
Finish name resolution

The resolver introduced in https://github.com/zetah11/zippy/commit/ef207545523bd7c4218f7a859e56cf2c5f6e37e7 is a good starting point, but quite lacking in actual features. Notably, there's no namespacing, multi-file support, or whole-program name-to-def info.

[ ] #6
[ ] Scope info (mostly just simple conversions from the decl pass)
[ ] Multiple files

[ ] Folder-wide modules

[ ] Flatten hierarchies (probably a job for the typing pass?)
[ ] Deuglify scopes

Scopes no longer need to use recursive scope ids for root scopes (https://github.com/zetah11/zippy/commit/8bd6ae280e1cb961e0d31f4933c1582f3a0c064f)


text:
fix ANSI escape code for cursor backward

related https://github.com/mattn/go-colorable/commit/3fa8c76f
上記コミット以降の go-colorable に対応するための修正です。
逆に go-colorable が上記コミットより前の状態でビルドすると、Ctrl-A 等でカーソルを移動した時に意図と逆方向にカーソルが移動します。

ありがとうございます。Windows10 のエスケープシーケンス を見ても、ESC[nDで左が正しいみたいですね。

あざます！

authors: tyochiai zetamatta

repo: zetamatta/nyagos


text:
Root resource returning 200 for QL request if no server provided

If you send a QL request to the root resource but don't specify the "server" parameter, a 200 response is returned with zero entities.  I would think this should return a 400 bad request or maybe for convenience it could assume that the "server" value was "*" if not provided.

+1 for defaulting to "*"

Hey @kyork-cl, Thanks for filing this.
We're going to have this API remain as is. Using the "*" parameter can actually be a very expensive piece of functionality depending on the number of hubs connected to a system. So making it's use as intentional as possible is important for us.
Returning a 400 doesn't make a whole lot of sense in this case either. It was a valid request issued to the API, but didn't find any results. It's not a bad request. It's just a request without data.
Let me know if you have any questions.
-Matt

If you do not provide a server parameter, will the query ever return something other than an empty set?

Yes. Two cases come to mind.

Having a device directly connected to a zetta server in the cloud.
This could return devices based on a query.
Querying a hub API directly can also return a set of devices.
Remember the APIs exposed in the cloud are also APIs exposed on the hub.

-Matt
--
Matthew Dobson | apigee https://apigee.com/ | m: +1.734.634.5472 |
twitter @mdobs http://twitter.com/mdobs @apigee
https://twitter.com/apigee | Apigee Community
http://community.apigee.com/ for answers, ideas and support!
On Wed, Jan 27, 2016 at 11:06 AM, William K notifications@github.com
wrote:

If you do not provide a server parameter, will the query ever return
something other than an empty set?
—
Reply to this email directly or view it on GitHub
https://github.com/zettajs/zetta/issues/286#issuecomment-175713063.

Ahh..I see. Thanks.

No problem. Seems like we have a resolution here. Going to close. Feel free to re-open if there is anything else to address.

I feel the current implementation is unintuitive.  The Siren data you get back when you query the root is
    "actions": [
    {
        "fields": [
            {
                "name": "server",
                "type": "text"
            },
            {
                "name": "ql",
                "type": "text"
            }
        ],
        "href": "http://localhost:1338/",
        "method": "GET",
        "name": "query-devices",
        "type": "application/x-www-form-urlencoded"
    }
    ],

Which implies that "server" is required.  The current implementation basically defaults the server value to "the locally running zetta server".  It is basically a silent redirect to /servers/{id}?ql=..., which the user might not be expecting.
I'm ok with * not being the default, but I think an error should be returned if server is not provided at the root level.

Siren doesn't have a concept of field validations. Sending a request with parameters server=&ql=where%20type%20%3D%20%27led%27 is perfectly valid. We've decided to keep it as is.
-Matt

authors: kyork-cl mdobson wooliet

repo: zettajs/zetta


text:
gltfPack ： Error during model conversion

RuntimeError: memory access out of bounds,RuntimeError: memory access out of bounds

This issue needs more information:

Presumably this is using gltfpack from npm?
Can you specify the command line used in the conversion?
Most importantly, can you attach the model file used?

Since there's no actionable information here I'm going to close this. Feel free to reopen and provide more information requested above (also if this is using node.js I'd need the node version).

authors: foreverliu zeux

repo: zeux/meshoptimizer


text:
[wip] proposal for content type plugin manager

Idea from #26 @bnppl
Instead of handling a specific list of content types use a plugin manager to cycle through each content type.
The plugin manager is in place but the service config / onBootstrap isn't running.  Maybe unit tests don't configure the app correctly?

I'm closing this, as we won't address this for 1.1, and already have another potential approach for v2 (middleware).

authors: TomHAnderson weierophinney

repo: zfcampus/zf-content-negotiation


text:
Question related Puppeteer-real-browser

FingerPrint
which one is best ?
"fingerprint-generator": "^2.1.30",
"fingerprint-injector": "^2.1.30",
or
puppeteer-afp

Extra-plugins
dose Puppeteer-real-browser need puppeteer-extra & puppeteer-extra-plugin-stealth or its can mask all parameters its self without extra plugins ?

Puppeteer Version and Cluster tool
my bot using "puppeteer": "^21.5.0" with  Puppeteer Cluster Puppeteer-real-browser work fine with any version or need any specific version ?

thank you in advance :)

Hello, puppeteer-real-browser creates a real browser and does not need any fingerprint plugin. You can go through bot detection tools without using any plugins. https://fingerprint.com/demo/ Fingerprint plugins are to avoid getting caught by sites like this that detect if it is the same browser. I recommend using puppeteer-afp. I haven't checked Puppeteer Cluster, sorry. I will check it out. Thank you

thank you so much for your attention.  i really appreciated your help.

Good evening sir,
when my developer try to implement real browser in our project.
my developer say puppeteer real browser uses deprecated option for puppeteer so we can't use args , but without args can't changing proxy and other settings.
Please advice.

Good evening sir, when my developer try to implement real browser in our project. my developer say puppeteer real browser uses deprecated option for puppeteer so we can't use args , but without args can't changing proxy and other settings. (browserWSEndpoint, is no longer supported) Please advice. thanks in advance.

Hi, I just tested it and I didn't have any problem using a proxy. The problem may be caused by your code. You can check the video below. Please provide video about the problem you are having.
https://github.com/zfcsoftware/puppeteer-real-browser/assets/123484092/efbb7e13-06e9-4b01-9b4f-af7db5f4e32b

Thanks for this awesome library, here is related error:

Thanks for this awesome library, here is related error:

This error seems to be Typescript specific. Can you try the Typescript version @CrispyyBaconx created? I didn't encounter an error when using Commanjs. Thank you for using the library.
https://github.com/zfcsoftware/puppeteer-real-browser/tree/Type-Script

Thanks for this awesome library, here is related error:

The puppeteer.launch function doesn't take browserWSEndpoint as an arg according to their docs (https://pptr.dev/api/puppeteer.puppeteerlaunchoptions)
The way you are currently using it by launching it is creating two browser instances since you are launching Chrome with the library and also launching a puppeteer instance of Chrome. The Websocket Endpoint is used to control an already launched instance of Chrome. Use puppeteer.connect in that case.

Thanks for this awesome library, here is related error:

The puppeteer.launch function doesn't take browserWSEndpoint as an arg according to their docs (https://pptr.dev/api/puppeteer.puppeteerlaunchoptions)
The way you are currently using it by launching it is creating two browser instances since you are launching Chrome with the library and also launching a puppeteer instance of Chrome. The Websocket Endpoint is used to control an already launched instance of Chrome. Use puppeteer.connect in that case.

Exactly, but in that case, we cannot pass args when using connect option.

Hello. Did you manage to make browser.newPage work again? Can you share a snippet? Thanks

Hello. Did you manage to make browser.newPage work again? Can you share a snippet? Thanks

You may use my fork of this repo. Which allows passing args, potentially solving this issue.

@mubaidr yes, i tried. Same problem. await browser.newPage() never resolves
console.log('Try to open new tab');
let page2 = await browser.newPage();
console.log('New page opened, try an alert!');
await page2.evaluate(() => { alert(33) })
await page2.goto('https://nopecha.com/demo/cloudflare#1');

This issue has been resolved please try the latest version of the library. If the problem persists you can start a new discussion.

authors: Biswajit96 CrispyyBaconx marcusdiy mubaidr zfcsoftware

repo: zfcsoftware/puppeteer-real-browser


text:
第11期内容推荐

这里可以填写推荐到第11期的内容。

https://github.com/RichardLitt/standard-readme#readme README的书写规范

goodmanwen.github.io

https://github.blog/2021-05-19-ludum-dare-48-staff-picks/

https://www.screensizes.app/?source=iphone&type=displays&id=015 Screen Size的汇总，可视化查看

https://www.freecodecamp.org/ 一个开源且免费的教学网站

https://explainshell.com/ 帮助解释shell命令，你可以在这里输入任何shell命令，它会分析各个参数的含义

https://timingapp.com/?lang=en 记录mac使用情况

https://github.com/brunophilipe/Cakebrew Cakebrew

https://regex101.com 有quick reference，还有对正则表达式的逐个解释，方便快速做出所需正则表达式

https://qwerty-learner.vercel.app/ 用来锻炼打字速度的英语单词学习网站！还有适合程序员的专门单词方案！

https://github.com/JohnSundell/Publish Swift 语言版本的静态网站生成器

https://jsisweird.com/ JS is weird!!!

repo: zhangferry/iOSWeeklyLearning


text:
nodejs（eggjs框架）项目执行初始化voerkai18n init命令报错

eggjs项目，执行命令voerkai18n init 初始化报错
PS E:\nodejs-dev\dataWish_serve\app> voerkai18n init
工程目录：E:\nodejs-dev\dataWish_serve
语言目录：languages
node:internal/errors:464
    ErrorCaptureStackTrace(err);
    ^

TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received null
    at new NodeError (node:internal/errors:371:5)
    at validateString (node:internal/validators:119:11)
    at Object.join (node:path:429:7)
    at getCurrentPackageJson (C:\Users\vobea\AppData\Local\Yarn\Data\global\node_modules\@voerkai18n\utils\index.js:212:32)
    at Object.initializer (C:\Users\vobea\AppData\Local\Yarn\Data\global\node_modules\@voerkai18n\cli\init.command.js:87:32)
    at Command.<anonymous> (C:\Users\vobea\AppData\Local\Yarn\Data\global\node_modules\@voerkai18n\cli\init.command.js:204:27)
    at Command.listener [as _actionHandler] (C:\Users\vobea\AppData\Local\Yarn\Data\global\node_modules\@voerkai18n\cli\node_modules\commander\lib\command.js:482:17)
    at C:\Users\vobea\AppData\Local\Yarn\Data\global\node_modules\@voerkai18n\cli\node_modules\commander\lib\command.js:1283:65
    at C:\Users\vobea\AppData\Local\Yarn\Data\global\node_modules\@voerkai18n\cli\node_modules\commander\lib\command.js:1174:33
    at async Command.parseAsync (C:\Users\vobea\AppData\Local\Yarn\Data\global\node_modules\@voerkai18n\cli\node_modules\commander\lib\command.js:935:5) {
  code: 'ERR_INVALID_ARG_TYPE'
}

可以尝试一下修改语言文件夹位置：
// package.json
{
    "voerkai18n":{
        "entry":"i18n"
    }
}

更改语言目录

可以尝试一下修改语言文件夹位置：
// package.json
{

    "voerkai18n":{
        "entry":"i18n"
    }
}

更改语言目录

尝试了，并不行哦

可以尝试一下修改语言文件夹位置：
// package.json
{

    "voerkai18n":{
        "entry":"i18n"
    }
}

更改语言目录

另外，请问一下，node接口返回给前端的sql表数据，能不能翻译了，我看了文档描述是不行的。还请大佬帮忙给个实现方案，感谢。

我的项目中，voerkai18n init -m cjs还是会报错找不到path...，重新建一个eggjs项目，能正常。尝试无果，最后的可行方式：将其他项目的languages文件夹复制过来，执行voerkai18n extract ==> voerkai18n compile -m cjs 能正常使用。

authors: vobear zhangfisher


text:
Color input image support

I wanted to know if the matlab code supports color image compression.
From the code it looks like images are converted to grayscale before conversion.

Hi, one way to apply the method to colorful images is to apply the algorithm to independent channels.

Great! Thank you! If I wanted to use Microshift on 64x64 images, do I just make the following changes in example_testbench_low_power.m:
ActivePixels = 64; % from 216
ActiveLines = 64; % from 256
...
origIm = imresize(origIm, [64, ActivePixels]);

How can I get the dictionary obtained by training 98 natural images? Thank you!

authors: ajboloor longnguyen2607 zhangmozhe


text:
啊

啥新特性，跨域吗。

PWA相关技术

authors: sqqihao zhangxinxu

repo: zhangxinxu/https-demo


text:
在 Electron 环境下 对一个 External 执行 restorePointer，程序直接闪退了

Current ffi-rs version
{
  "name": "ffi-rs",
  "version": "1.0.83",
  "main": "index.js",
  "types": "index.d.ts",
  "description": "A module written in Rust and N-API provides interface (FFI) features for Node.js",
  "napi": {
    "name": "ffi-rs",
    "triples": {
      "additional": [
        "aarch64-apple-darwin",
        "aarch64-unknown-linux-gnu",
        "aarch64-unknown-linux-musl",
        "i686-pc-windows-msvc",
        "x86_64-unknown-linux-musl",
        "aarch64-pc-windows-msvc"
      ]
    }
  },
  "author": "zhangyuang",
  "homepage": "https://github.com/zhangyuang/node-ffi-rs#readme",
  "repository": {
    "type": "git",
    "url": "git+https://github.com/zhangyuang/node-ffi-rs.git"
  },
  "keywords": [
    "ffi",
    "rust",
    "node.js",
    "napi"
  ],
  "files": [
    "index.js",
    "index.d.ts",
    "README.md"
  ],
  "license": "MIT",
  "dependencies": {},
  "devDependencies": {
    "@napi-rs/cli": "^2.15.2",
    "@types/node": "^20.8.7",
    "benny": "^3.7.1",
    "conventional-changelog-cli": "^4.1.0",
    "esno": "^4.0.0",
    "ffi-napi": "^4.0.3",
    "koa": "^2.14.2",
    "shelljs": "^0.8.5",
    "typescript": "^5.4.5"
  },
  "scripts": {
    "artifacts": "napi artifacts",
    "build:c": "node scripts/compile.js",
    "build:dev": "env=development node scripts/build.js",
    "build": "node scripts/build.js",
    "publish:npm": "node scripts/publish.js",
    "test": "esno ./test.ts",
    "changelog": "conventional-changelog -p angular -i CHANGELOG.md -s -r 0 && git add . && git commit -m \"docs: update changelog.md\" && git push origin master",
    "pub": "npm version patch && git push origin master --tags && npm run changelog",
    "pub:alpha": "npm version prerelease --preid=alpha && git push origin master --tags"
  },
  "optionalDependencies": {
    "@yuuang/ffi-rs-darwin-arm64": "1.0.83",
    "@yuuang/ffi-rs-darwin-x64": "1.0.83",
    "@yuuang/ffi-rs-linux-arm64-gnu": "1.0.83",
    "@yuuang/ffi-rs-linux-arm64-musl": "1.0.83",
    "@yuuang/ffi-rs-linux-x64-gnu": "1.0.83",
    "@yuuang/ffi-rs-linux-x64-musl": "1.0.83",
    "@yuuang/ffi-rs-win32-arm64-msvc": "1.0.83",
    "@yuuang/ffi-rs-win32-ia32-msvc": "1.0.83",
    "@yuuang/ffi-rs-win32-x64-msvc": "1.0.83"
  }
}

Current Node.js arch
x64 win32
Descibe your problem in detail
const point  = {
  x: 0,
  y: 0,
};
const Point = {
  x: DataType.I32,
  y: DataType.I32,
  ffiTypeTag: DataType.StackStruct,
}l
const pointer = wrapPointer(createPointer({
  paramsType: [Point],
  paramsValue: [point],
}));
const isCatch = load({
    library: "user32",
    funcName: "GetCaretPos",
    retType: DataType.Boolean,
    paramsValue: pointer,
    paramsType: [DataType.External]
  });

const p = restorePointer({
    paramsValue: pointer,
    retType: [Point],
  })

这行 restorePointer 会导致程序闪退（提示： [12828:0704/002445.028:ERROR:crashpad_client_win.cc(868)] not connected）
What's your expect result
期望得到 caret 的坐标，如果有的话
The reproduction repo address

不需要加wrapPointer

不需要加wrapPointer

const pointer = createPointer({
  paramsType: [Point],
  paramsValue: [point],
});

这样吗?
还是闪退

不需要加 ffiTypeTag: DataType.StackStruct,

不需要加 ffiTypeTag: DataType.StackStruct,

const point  = {
  x: 0,
  y: 0,
}
const Point = {
  x: DataType.I32,
  y: DataType.I32,
}
const pointer = createPointer({
  paramsType: [Point],
  paramsValue: [point],
});
const pos = load({
      library: "user32",
      funcName: "GetCaretPos",
      retType: DataType.Boolean,
      paramsValue: pointer,
      paramsType: [DataType.External]
    });

还是同样的问题

const pos = load({
library: "user32",
funcName: "GetCaretPos",
retType: DataType.Boolean,
paramsValue: wrapPointer(pointer),
paramsType: [DataType.External]
});

wrapPointer

程序正常了，但是值却不是期望
 const isCatch = await this.getCaretPos();
      const p = restorePointer({
        paramsValue: pointer,
        retType: [Point],
      })
      console.log(isCatch, point, p);

true { x: 0, y: 0 } [ { x: 0, y: 0 } ]

给出完整代码

给出完整代码

let timer;
const point = {
  x: 0,
  y: 0,
}
const Point = {
  x: DataType.I64,
  y: DataType.I64,
}
const pointer = createPointer({
  paramsType: [Point],
  paramsValue: [point],
});

const getForegroundWindow = async () => {
  const hwnd = load(
    {
      library: 'user32',
      funcName: 'GetForegroundWindow',
      retType: DataType.I32,
      paramsType: [],
      paramsValue: []
    }
  )
  return hwnd
}

const getCaretPos = async () => {
  const pos = load({
    library: "user32",
    funcName: "GetCaretPos",
    retType: DataType.Boolean,
    paramsValue: wrapPointer(pointer),
    paramsType: [DataType.External]
  });
  return pos;
}
const loop = () => {
  open({
    library: 'user32', // key
    path: 'user32.dll' // path
  })
  if (timer) {
    clearInterval(timer);
  }
  timer = setInterval(async () => {
    const hwnd = await this.getForegroundWindow();
    console.log('hwnd', hwnd);
    if (hwnd) {
      const isCatch = await this.getCaretPos();
      const p = restorePointer({
        paramsValue: pointer,
        retType: [Point],
      })
      console.log(isCatch, point, p);
      // console.log(p)
    }
  }, 2000);
}

loop()

这里

给出完整代码

let timer;
const point = {
  x: 0,
  y: 0,
}
const Point = {
  x: DataType.I64,
  y: DataType.I64,
}
const pointer = createPointer({
  paramsType: [Point],
  paramsValue: [point],
});

const getForegroundWindow = async () => {
  const hwnd = load(
    {
      library: 'user32',
      funcName: 'GetForegroundWindow',
      retType: DataType.I32,
      paramsType: [],
      paramsValue: []
    }
  )
  return hwnd
}

const getCaretPos = async () => {
  const pos = load({
    library: "user32",
    funcName: "GetCaretPos",
    retType: DataType.Boolean,
    paramsValue: wrapPointer(pointer),
    paramsType: [DataType.External]
  });
  return pos;
}
const loop = () => {
  open({
    library: 'user32', // key
    path: 'user32.dll' // path
  })
  if (timer) {
    clearInterval(timer);
  }
  timer = setInterval(async () => {
    const hwnd = await this.getForegroundWindow();
    console.log('hwnd', hwnd);
    if (hwnd) {
      const isCatch = await this.getCaretPos();
      const p = restorePointer({
        paramsValue: pointer,
        retType: [Point],
      })
      console.log(isCatch, point, p);
      // console.log(p)
    }
  }, 2000);
}

loop()

这里

结果输出的坐标和原始值一样 {x: 0, y: 0}

看起来没什么问题，你应该根据GetCaretPos的返回值以及调用load方法时设置errno:true来自行debug

看起来没什么问题，你应该根据GetCaretPos的返回值以及调用load方法时设置errno:true来自行debu

看起来没什么问题，你应该根据GetCaretPos的返回值以及调用load方法时设置errno:true来自行debu
加上了，GetCaretPos 的返回值是 true，也没有报错。就是 pointer 的值没发生变化

getcarepos的返回值是int而不是boolean，你应该去查询这个函数的文档来根据errno信息debug

getcarepos
嗯？我查到的是返回 BOOL

谢谢，我会了

问题定位了吗

repo: zhangyuang/node-ffi-rs


text:
重新安装依赖，ts错误

详细描述你的问题
nextjs + vue3项目，删除项目node_modules和yarn.lock，重新安装依赖，开发环境yarn start运行项目后（没有用vite）大量ts错误，问下这个怎么解决

期望的结果
当前使用的版本
warning package.json: "dependencies" has dependency "eslint" with range "^8.35.0" that collides with a dependency in "devDependencies" of the same name with version "^8.34.0"
warning nestjs-vue3-ssr@1.0.0: "dependencies" has dependency "eslint" with range "^8.35.0" that collides with a dependency in "devDependencies" of the same name with version "^8.34.0"
warning Filtering by arguments is deprecated. Please use the pattern option instead.
├─ ssr-common-utils@6.2.161
├─ ssr-core-vue3@6.2.21
├─ ssr-deepclone@1.0.1
├─ ssr-mini-css-extract-plugin@1.6.10
├─ ssr-plugin-nestjs@6.2.26
├─ ssr-plugin-vue3@6.2.119
│  └─ ssri@7.1.1
├─ ssr-serialize-javascript@6.0.4
├─ ssr-server-utils@6.2.69
├─ ssr-types@6.2.65
├─ ssr-vite-plugin-style-import@2.0.1
├─ ssr-webpack@6.2.17
├─ ssr-webpack4@4.46.2
├─ ssr-window@3.0.0
├─ ssr@6.2.82
└─ ssri@6.0.2

默认example没有问题，可以升级typescript到5.x试试

默认example没有问题，可以升级typescript到5.x试试

升级了问题依旧存在，还有其他方法么

repo: zhangyuang/ssr


text:
🛑 ZY is down

In a0536a9, ZY (https://ziyuan.baidu.com) was down:

HTTP code: 0
Response time: 0 ms

Resolved: ZY is back up in f719a1c.

repo: zhaodylan/uptime-ziyuan


text:
Streaming evaluator returns exit code 0 even if evaluation fails

Steps to reproduce

echo '{ host-a = { ... }: {}; }' > eval-fail.nix
colmena build --evaluator streaming -f $(realpath ./eval-fail.nix)

Expected Behavior
Colmena should return a nonzero exit code to indicate an error, as it does with non-streaming evaluation.
Actual Behavior
Colmena outputs an error:
[INFO ] Using configuration: /home/wanja/src/colmena/eval-fail.nix
[INFO ] Enumerating nodes...
[INFO ] Selected all 1 nodes.
[WARN ] Streaming evaluation is an experimental feature
       ✅ 2s All done!
host-a ✅ 2s Evaluated host-a
host-a ❌ 0s Evaluation failed: No message
[ERROR] Failed to evaluate host-a - Last 7 lines of logs:
[ERROR]  created)
[ERROR]    state) Running
[ERROR]   stderr) error:
[ERROR]   stderr)        Failed assertions:
[ERROR]   stderr)        - The ‘fileSystems’ option does not specify your root file system.
[ERROR]   stderr)        - You must set the option ‘boot.loader.grub.devices’ or 'boot.loader.grub.mirroredBoots' to make the system bootable.
[ERROR]    state) Failed

but returns with exit code 0, indicating success.
Additional Information
This happens on current main (872949504befb9b5540e69f846c6965def7150f9) and stable (4fca657c4e6fca3edb1e04ae645855ec833852ee), the issue is present in both.

Update: I debugged this a little and found out that, in the case from my repro, the Vec of futures in this line is empty. This makes sense, because the error branch that's being taken never pushes to it.
The comment there seems to indicate that some failing future ought to be pushed here, but I'm not sure what that would look like.

repo: zhaofengli/colmena


text:
Intrinsics init working

Fixed 2 comments in X86IntrinBinOp class that mislabeled the functions.

thanks!


text:
About hyperparameters

Hi, thanks for sharing your great works.
I'm trying to reproduce the result of ERM(3rd row in Table.1 from your paper), but I got a bit lower performance on OfficeHome dataset. I ran your source code with hyperparameters described in your paper(lr=1e-05, weight_decay=1e-02, last dropout=0.1), and I got 72.767% of target accuracy averaged on 3 different random seeds. I think I'm missing some other hyperparameters such as classifier LR multiplier or attention dropout probability in vision transformer which are not clarified in the paper.
Could you kindly share the searched hyperparameters on each dataset?

Thanks. I'll try again with the updated command.
By the way, I found that hparams['lr_classifier'] does not affect the learning rate in the optimizer for ERM in https://github.com/zhengzangw/DoPrompt/blob/main/domainbed/algorithms.py#L111. I think this should be fixed.

Thank you for pointing this out. I have modified the code to match our experiment version.

repo: zhengzangw/DoPrompt


text:
申请完权限仍无法拍照

Describe the bug
java.lang.SecurityException: UID 10550 does not have permission to content://com.zhihu.matisse.sample.fileprovider/my_images/test/JPEG_20190725_173859.jpg [user 0]
To Reproduce
Steps to reproduce the behavior:
点击拍照图标后闪退
Smartphone (please complete the following information):

Device:MI 5X
Version MIUI 10.3

已解决~  没写fileprovider的问题

我写了fileter拍照还是报错，是包名

repo: zhihu/Matisse


text:
TypeError: ('Keyword argument not understood:', 'input')

I run the main.py. But I got this error, how can I fix this

Hey, did u solved the problem?

No unfortunately

do u have another recomendations for image segmentation tools?

see this website, change the input to inputs, https://stackoverflow.com/questions/63497874/typeerror-keyword-argument-not-understood-input

In the model definition, change the input to inputs and output to outputs

Changing the input to inputs and output to outputs still can't work, how can I fix this?

In the model definition, change the input to inputs and output to outputs

Changing the input to inputs and output to outputs still can't work, how can I fix this?

Try removing input and output altogether and just use positional arguments? That did it for me

In the model definition, change the input to inputs and output to outputs

3Q，I do it.

see this website, change the input to inputs, https://stackoverflow.com/questions/63497874/typeerror-keyword-argument-not-understood-input

3Q，it is useful.

repo: zhixuhao/unet


text:
求助 unidbg-iOS如何补方法

求助搞过 unidbg-iOS的大佬。我替换自己的ipa后， run IpaLoaderTest
文件，然后就报错了。
看起来好像是方法没找到， iOS要怎么补方法呢？
Aug 17 17:05:11 unidbg.local xxxxxx4iPhone[10856] <Warning>: *** NSForwarding: warning: selector (0x10d9499c2) for message 'instancesRespondToSelector:' does not match selector known to Objective C runtime (0x10c97eba0)-- abort
2022-08-17 17:05:10.913 xxxxxx4iPhone[10856:3] *** NSForwarding: warning: selector (0x10d9499c2) for message 'instancesRespondToSelector:' does not match selector known to Objective C runtime (0x10c97eba0)-- abort
Aug 17 17:05:11 unidbg.local xxxxxx4iPhone[10856] <Error>: +[NSProcessInfo instancesRespondToSelector:]: unrecognized selector sent to class 0x10ca3ba20
2022-08-17 17:05:11.616 xxxxxx4iPhone[10856:3] +[NSProcessInfo instancesRespondToSelector:]: unrecognized selector sent to class 0x10ca3ba20
objc[10856]: EXCEPTIONS: throwing 0x10e122718 (object 0x10e105dc0, a NSException)
0   libobjc.A.dylib                     0x000000010cb802d8 objc_exception_throw + 280
1   CoreFoundation                      0x000000010ce634f0 __CFExceptionProem + 0
2   CoreFoundation                      0x000000010ce61330 ___forwarding___ + 912
3   CoreFoundation                      0x000000010cd8108c _CF_forwarding_prep_0 + 92
4   libswiftCore.dylib                  0x000000010d92310c _ZZZ36_swift_stdlib_operatingSystemVersionENK3$_0clEvENUlPvE_8__invokeES0_ + 56
5   libdispatch.dylib                   0x000000010bdc3fd4 _dispatch_client_callout + 16
6   libdispatch.dylib                   0x000000010bdc4e7c dispatch_once_f + 60
7   libswiftCore.dylib                  0x000000010d9230d0 _swift_stdlib_operatingSystemVersion + 92
8   libswiftCore.dylib                  0x000000010d8c4140 _swift_isBackDeploying + 20
9   libswiftCore.dylib                  0x000000010d8c419c _ZL12checkVersionv + 16
10  ???                                 0x00000007ffff0000 0x0 + 34359672832

补ios环境涉及较多，实验性质仅支持自己研究
On Thu, Aug 18, 2022 at 10:40 sunisland @.***> wrote:

求助搞过 unidbg-iOS的大佬。我替换自己的ipa后， run IpaLoaderTest
文件，然后就报错了。
看起来好像是方法没找到， iOS要怎么补方法呢？
Aug 17 17:05:11 unidbg.local xxxxxx4iPhone[10856] : *** NSForwarding: warning: selector (0x10d9499c2) for message 'instancesRespondToSelector:' does not match selector known to Objective C runtime (0x10c97eba0)-- abort
2022-08-17 17:05:10.913 xxxxxx4iPhone[10856:3] *** NSForwarding: warning: selector (0x10d9499c2) for message 'instancesRespondToSelector:' does not match selector known to Objective C runtime (0x10c97eba0)-- abort
Aug 17 17:05:11 unidbg.local xxxxxx4iPhone[10856] : +[NSProcessInfo instancesRespondToSelector:]: unrecognized selector sent to class 0x10ca3ba20
2022-08-17 17:05:11.616 xxxxxx4iPhone[10856:3] +[NSProcessInfo instancesRespondToSelector:]: unrecognized selector sent to class 0x10ca3ba20
objc[10856]: EXCEPTIONS: throwing 0x10e122718 (object 0x10e105dc0, a NSException)
0   libobjc.A.dylib                     0x000000010cb802d8 objc_exception_throw + 280
1   CoreFoundation                      0x000000010ce634f0 __CFExceptionProem + 0
2   CoreFoundation                      0x000000010ce61330 forwarding + 912
3   CoreFoundation                      0x000000010cd8108c _CF_forwarding_prep_0 + 92
4   libswiftCore.dylib                  0x000000010d92310c _ZZZ36_swift_stdlib_operatingSystemVersionENK3$0clEvENUlPvE_8__invokeES0 + 56
5   libdispatch.dylib                   0x000000010bdc3fd4 _dispatch_client_callout + 16
6   libdispatch.dylib                   0x000000010bdc4e7c dispatch_once_f + 60
7   libswiftCore.dylib                  0x000000010d9230d0 _swift_stdlib_operatingSystemVersion + 92
8   libswiftCore.dylib                  0x000000010d8c4140 _swift_isBackDeploying + 20
9   libswiftCore.dylib                  0x000000010d8c419c _ZL12checkVersionv + 16
10  ???                                 0x00000007ffff0000 0x0 + 34359672832
—
Reply to this email directly, view it on GitHub
https://github.com/zhkl0228/unidbg/issues/468, or unsubscribe
https://github.com/notifications/unsubscribe-auth/AOWRPOMSP7Y6ST5NYU5PX5LVZWPBPANCNFSM563R3LXA
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>


text:
🛑 腾讯云 COS 节点 is down

In 3bdda4b, 腾讯云 COS 节点 (https://lisz.ink) was down:

HTTP code: 0
Response time: 0 ms

Resolved: 腾讯云 COS 节点 is back up in 1360ea9.

repo: zhonger/upptime


text:
神秘选项更新了“被诅咒的宝藏”、“额外的战利品”，运行至新的神秘选项会导致卡死。有考虑更新吗

神秘选项更新了“被诅咒的宝藏”、“额外的战利品”，运行至新的神秘选项会导致卡死。有考虑更新吗

已更新，现已可用。此问题关闭


text:
🛑 API - core - forms/1 is down

In 26db0d1, API - core - forms/1 (https://community.ibm.com/zsystems/api/core/forms/1) was down:

HTTP code: 404
Response time: 10278 ms

Resolved: API - core - forms/1 is back up in 72f7252 after 41 minutes.

repo: zhujunyong/upptime


text:
Use HttpClientFactory for calling external HTTP services

https://github.com/zhukovdm/smartwalk/blob/1f09d789e668311639e1cd780e98244c161ff991/app/backend/SmartWalk.Infrastructure/RoutingEngine/Osrm/Fetchers/OsrmFetcherBase.cs#L28
HttpClient has a connection pool and is IDisposable (quite a surprise).

https://www.stevejgordon.co.uk/introduction-to-httpclientfactory-aspnetcore

The current implementation is, in fact, really bad. It allocates new HttpClient for every request. Perhaps, handler itself shall be stateful and Transient.

repo: zhukovdm/smartwalk


text:
Implementation of service tests.

I used your system in a college course, so I ran some tests to help me out, so I decided to share those tests. I hope you enjoy it.

Thanks for your contribution!

authors: Bhyan zhulinn


text:
Level.destroyBlock(false); doesn't work

Well, just try this:
function destroyBlock(x,y,z,blockId,itemId){
var blockId = Level.getTile(x,y,z);
if(blockId==1){
Level.destroyBlock(false);
clientMessage(":v);
}
}

You're... trying to destroy a block while destroying a block? Destroyception?

function destroyBlock(x,y,z,blockId,itemId){
if(blockId==1){
Level.destroyBlock(false);
clientMessage(":v);
}
}
It's just that with destroyBlock(false) in the code still drops it

thanks - will fix.

Fixed in latest beta.

authors: TheViictor zhuowei

repo: zhuowei/MCPELauncher


text:
Adding info for BEP20 token 'EuropaCoin'.

Adding info for BEP20 token 'EuropaCoin'.
PR created by TW Assets Management
Ursprünglich gepostet von @EuropaCoinFun in https://github.com/trustwallet/assets/pull/29882

Hello @Xyvern26
Thanks for reporting this
This will be review on pull request!
Use the official support to get more information reading this via support

Hello @Xyvern26 Thanks for reporting this This will be review on pull request! Use the official support to get more information regarding this via support

Hello, what is this repository responsible for ?

authors: EuropaCoinFun Xyvern26 Zainmor-tech

repo: ziadoz/awesome-php

license: WTFPL


text:
Auto start?

How can I start this extension automatically?

@rostamiani there is no way to start this extension automatically. You need to start it manually.

authors: rostamiani ziishaned

repo: ziishaned/livereload-vscode


text:
Support a non-interactive mode so that it is possible to build scripts with the milvus_cli

I would like to create a bash script that does something like this:

MY_INDEX_VALUE=$1

milvus_cli connect -uri http://localhost:19530
milvus_cli use database my_database

milvus_cli query \
    --collection my_collection
    --query "MY_INDEX=$MY_INDEX_VALUE"
    --fields "MY_INDEX, MY_EMBEDDING"

Currently only interactive mode is supported.

This would also make it easier to use the currently unusable commands like query.  See #78.

CLI is designed for interactive applications base on pymilvus.
You can using pymilvus directly in bash. Is that meet your requirements？

@nameczz

You can using pymilvus directly in bash. Is that meet your requirements？

Can you provide me with an example?

@JakeSummers Sure
https://milvus.io/api-reference/pymilvus/v2.4.x/MilvusClient/Vector/query.md

authors: JakeSummers nameczz


text:
the demo "starwars" doesn't work because websocket_client

../../../../flutter/.pub-cache/hosted/pub.dartlang.org/graphql-5.0.1/lib/src/links/websocket_link/websocket_client.dart:208:9: Error: The method 'unawaited' isn't defined for the class 'SocketClient'.

'SocketClient' is from 'package:graphql/src/links/websocket_link/websocket_client.dart' ('../../../../flutter/.pub-cache/hosted/pub.dartlang.org/graphql-5.0.1/lib/src/links/websocket_link/websocket_client.dart').
Try correcting the name to the name of an existing method, or defining a method named 'unawaited'.
unawaited(_closeSocketChannel());
^^^^^^^^^

reviewing this error, I think it would be good to add more examples using this packages I have a while to use it, I have some on my github, I have examples using artemis to generate the static classes in dart based on my graphql shema, and after that I have those classes I do the magic with this package 😎
https://github.com/manuelduarte077/pokemon_graphql

The problem is that you are using a public API and the public API died somehow, like in the case of the prev example!
The optimal idea is to provide an example with the API, and these API are used inside the test too.
And all the tests are possible to reproduce with a docker image not only in the CI, because the CI dies somehow (e.g travis)
Working on this idea https://github.com/zino-hofmann/graphql-flutter/issues/1162#issuecomment-1182946910
In addition, closing this issue because there is already a discussion https://github.com/zino-hofmann/graphql-flutter/discussions/1165
P.S: You can add your message here :)

The problem is that you are using a public API and the public API died somehow, like in the case of the prev example!
The optimal idea is to provide an example with the API, and these API are used inside the test too.
And all the tests are possible to reproduce with a docker image not only in the CI, because the CI dies somehow (e.g travis)
Working on this idea #1162 (comment)
In addition, closing this issue because there is already a discussion #1165
P.S: You can add your message here :)

Thank you very much for your reply

repo: zino-hofmann/graphql-flutter


text:
Update zio, zio-test, zio-test-magnolia, ... to 2.1.13

About this PR
📦 Updates

dev.zio:zio
dev.zio:zio-test
dev.zio:zio-test-magnolia
dev.zio:zio-test-sbt

from 2.1.11 to 2.1.13
📜 GitHub Release Notes - Version Diff
Usage
✅ Please merge!
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

⚙ Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "dev.zio" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "30 days" },
  dependency = { groupId = "dev.zio" }
}]

labels: library-update, early-semver-patch, semver-spec-patch, commit-count:1

Superseded by #105.

repo: zio/zio-bson


text:
Create extension methods on Remote[Instant]

Implement extension methods in zio.flow.RemoteInstantSyntax
Issue: #76
Have in mind

there are no tests for the methods using Remote[TemporalField], Remote[TemporalUnit], Remote[TemporalAmount] since I did not find any Generators for this types.
it uses the AmountToDuration of #85

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

Important! Let's merge #85 first and after I rebase, merge this one

authors: CLAassistant koukoustath

repo: zio/zio-flow


text:
Enable Fundamentals data support [enhancement]

I know, that you already planned to support fundamentals data.
I just wanted to point your attention to a small project I started sometime ago to provide fundamentals data support to zipline: https://github.com/alphaville76/Fundamentals
I'd also like to help in implementing this feature, in zipline-live: let me know, how I could help.
Last but not least: An important question is how to feed the data. Of course it would be great to continue to support Morningstar as source, but I don't know how expensive their data are and how they could be licensed to individual investors.

I have a code that ingests fundamental data into the bundle from csv files in a format name,date,value
I can share it if the approach makes sense.

I have contacted Morningstar for a quote and will report back on the findings.

@alphaville76 : Your work on fundamental looks really nice, thanks for sharing!
In order to not to deviate too much from Q's interface I'd propose that we provide a pipeline-aware interface: similar to USEquityPricing or morningstar package at Q.
The UsEquityPricing & UsEquityPricingLoader classes could be taken as an example for this workitem.
Do you guys agree to this approach?

I agree, we should deviate from the original Q's interface as less as possible.
Give a look to https://github.com/alphaville76/Fundamentals/blob/master/query_data.py
It's exaclty the same API like Q's get_fundamentals, even for the field names.
I could not use Morningstar as datasource, but I mapped the data from SHARADAR_SF1 (https://www.quandl.com/data/SF1-Core-US-Fundamentals-Data) to the Mornigstar naming, when possible. This happens in : https://github.com/alphaville76/Fundamentals/blob/master/insert_data.py

Some other information:

Actually the backend for the data is a relational DB like mysql or sqlite (see https://github.com/alphaville76/Fundamentals/blob/master/core/dao.py, db_session()). You don't have to import the schema, it will be created by sqlalchemy
Of course, because of licensing issue, I could not commit the data from Quandl SF1. For testing purpose I will push to the git repo some fake testdata.

@vprelovac Very good! To continue using Mornigstar it the best thing for a lot of reason!

Here is my code that i mentioned yesterday: https://github.com/bartosh/zipline/commits/fundamentals
The approach is quite generic as the data is loaded from simply structured cvs files and ingested into the bundle. The data can be used in Pipeline.

Well, we already have a basis to implement both the get_fundamentals and Pipeline API!
@bartosh Where did you get the fundamentals data to ingest?
It's important to consider that the datasource must also contains delisted companies to avoid survivor bias and the data should not be restated.

@alphaville76 I used set of fundamental datasets from quandl.
However, I don't think we should be attached to any data provider. That's why i used very simple data structure: cvs files with only 3 fields: name, date, value. Almost anything can be easily converted to this format. This approach would save us a lot of time if we choose to use it. Instead of developing support for multiple data provider formats we can support only one. Converting more complex formats to the simple format is much more easy task than developing support for them, I believe.

@bartosh and how do you pass the sid/ticker? Is it the file name? Could you provide some sample data to ingest?
And what about the naming to use the data in a Pipeline, for example what does morningstar.valuation_ratios.pe_ratio become using the Quandl dataset?
An useful approch could be the possibility to define alias for the field names, I'd like to run in zipline-live as much as possible the same code as in Quantopian, included the names of the fundamental data.

yes, ticker is a file name, e.g. JNJ.csv contains all available fundametal data for JNJ.
Here is an example of earnings/basic share and total assets data for JNJ. I took this data from example datasets on quandl.com
name,date,value
EPS_MRQ,2017-07-02,1.42
EPS_MRQ,2017-04-02,1.63
EPS_MRQ,2017-01-01,1.46
EPS_MRQ,2016-10-02,1.56
EPS_MRQ,2016-07-03,1.46
EPS_MRQ,2016-04-03,1.62
EPS_MRQ,2016-01-03,1.17
EPS_MRQ,2015-09-27,1.21
EPS_MRQ,2015-06-28,1.63
EPS_MRQ,2015-03-29,1.55
ASSETS_MRQ,2017-07-02,152807000000.0
ASSETS_MRQ,2017-04-02,144918000000.0
ASSETS_MRQ,2017-01-01,141208000000.0
ASSETS_MRQ,2016-10-02,140369000000.0
ASSETS_MRQ,2016-07-03,139814000000.0
ASSETS_MRQ,2016-04-03,136230999999.99998
ASSETS_MRQ,2016-01-03,133410999999.99998
ASSETS_MRQ,2015-09-27,133266000000.0
ASSETS_MRQ,2015-06-28,132036000000.0
ASSETS_MRQ,2015-03-29,128590000000.0
I don't see any need to define aliases. you can just put whatever name you want into the csv.
Regarding usage of this data I'm afraid it would require additional code. You can read detailed explanations here: https://www.quantopian.com/posts/possible-to-simulate-inputs-to-pipeline-in-the-research-platform#56e6e2713008a94b5200058f and here https://github.com/quantopian/zipline/issues/911

I see, it's of course a meaningful approach for Pipeline but it makes difficult to use the same database to replicate the get_fundamentals SQLAlchemy API.
To leverage the power of SQLAlchemy my project's data model takes the field name as single column and the financial statement as table. Take a look at https://github.com/alphaville76/Fundamentals/blob/master/core/model.py
I know, in this way we are anchored to the M* data format but there also also some vantages, like 100% compatibility with Quantopian, simples queries and, I believe, also better performance.
By the way, gurufocus.com provides M* data (fundamentals and daily prices) for a reasonable fee. There both an XLS export and JSON API: https://www.gurufocus.com/api.php
I confirm that I am willing to make a commitment to help developing this feature, but a maintainer of zipline-live should coordinate our efforts and decide how to what to do.

Well, the get_fundamental API is now official deprecated on Quantopian:
https://www.quantopian.com/posts/faster-fundamental-data#59a1f4273cdcc8000dca608f
I think, we have to concentrate our effort only on the Pipeline API.
@bartosh In my opinion, you approach is fine. The only problem was the integration with get_fundamentals... but now this argument is gone. Could you merge your code or there is something else, that kept you from doing that?
@tibkiss You wrote on the Q forum, tha M* is cheaper than Quantconnect. Did you mean a subscription the M* Premium membership or to the Equity API (http://equityapi.morningstar.com/)?

@alphaville76 We still need to decide what would be the right way to go. My approach generalises data source, but it's quite verbose and requires additional code in the algorithm. Yours is bound to one data provider, but allows to use Q algos without modifications at least as far as I understood.
Can we come up with something that is not bound to M* or another provider and still allows to use unmodified Q algos?
@tibkiss It would be great to know your opinion on this as well.

JFYI: Q are changing fundamentals API: https://www.quantopian.com/posts/faster-fundamental-data

Sorry for not coming back earlier on this.
@alphaville76 : I was referring to morningstar's financial's webpage at quantopian: http://financials.morningstar.com/
To me compatibility is something really important. Extending beyond Q's capabilities is fine, but an algo taken from Q's website should work out of the box.
Can we achieve this by taking Ed's generalized CSV reader, and build the pipeline.data.Fundamentals field dynamically, based on the content of the CSV?
With a well formatted CSV file we could provide the same fields as Q.
I'm sorry if this is a bad idea, I did not had time to try out your code.

@tibkiss Thanks for the reply. Also for me, it's compatibility very important, therefore as I wrote above we could abandon my get_fundamentals project because the API will be removed by Q in a month.
I agree to take Ed's generalized CSV reader and improve his approach.
@bartosh What has to be done, in order to avoid the additional code in the algorithm?
A big question remain the data. For example the problem with http://financials.morningstar.com/ is that the "filing date" field is not available, and this is bad for the backtesting. Delisted stocks are also not available.
Gurufocus has "filing date" and delisted stocks, but the data are restated and not "as reported" making them also not suitable to backtesting... SHARADAR_SF1 (https://www.quandl.com/data/SF1-Core-US-Fundamentals-Data) has everything but no pricing data for delisted stocks :-(
Anywaly for the beginning and only for live trading financials.morningstar.com should be okay. I've to check if they are updated timely after company filings.

Even though I recommended financials.morningstar, I don't think it is the best option.
I wasn't able to find a proper API for that site, people are accessing it through web scraping -which may broke if they change the page structure.
Regarding SF1:
It is really bad that they do not include delisted ones. Nonetheless for live trading it should be 'okay', as we'll be considering tradable stocks anyways.
@pbharrin : Do you have an opinion about this?

@alphaville76 Does Shardar_SF1 have any data for delisted stocks?  It seems from your comment that they don't have pricing (OHLCV), but we are interested in fundamental data not pricing.  Did I misunderstand your statement?  BTW, thanks for your help on fundamentals.
@tibkiss Morningstar doesn't even provide data downloads in .csv?
****I actually don't like Q's approach of putting fundamental data in the pipeline as you are effectively oversampling the data ~60x.  (The fundamentals only change 4x per year but you have to get 252 points.)  It would be a mute point if you can just throw hardware at the problem, but it is actually quite limiting.  Up until the recent speedup you couldn't' get more than a year's worth of fundamental data in an algorithm.  I had to do some crazy shit to calculate 5 year growth metrics in Research.
I see the logic of being compatible with Quantopian, go for it.  The interface should be fairly generic so that any source of fundamental data can be used.  I like Ed's flat files.

Shardar_SF1 has "as reported" fundamentals data also for delisted stocks. The problem is getting the pricing (OHLCV) for symbols that don't exist anymore and thus perform a full backtest.
For example the gurufocus API provides both financial and pricing data, and also for delisted companies but unfortunatly the financial data are "restated". I wrote them, to know if the could extend their service to offer also the data "as reported" (that they're already using for their own backtester).
I also like Ed's flat files: it's the simplest and most flexible form for ingesting the data.
An I also don't like the Q's approach: for example for TTM data, you have set windows_lenght=196 and then sum the data with index 1, 65, 130 and 195.
I've an API suggestion: Why don't add a timeframe for the CustomFactor? for example to get the last 4 quarters, you could simply set windows_lenght=196 and timeframe=quarterly. So we remain compatible with Quantopian (default timeframe=daily), at least in one direction.

@alphaville76 The quantopian-quandl bundle has pricing for delisted tickers.  In the past I have paid for the Zacks historical pricing data that also has delisted tickers.  (The problem with Zacks is that they don't tell you when dividends are paid.)   Can we not get the pricing data from the  quantopian-quandl bundle?

@pbharrin Maybe there are some delisted stocks, but I tried some tickers without success.
For example FABU (FAB Universal Corp, delisted from the Nasdaq in 2014): it had  3 other tickers in the  Shardar_SF1 (FU,WZD,WZE) but none of them is in the quantopian-quandl bundle.
The same for Yongye International Inc (YONG).
The Zacks  ZEP dataset (that costs $300 a quarter) has both:
https://www.quandl.com/data/ZEP/FABU-FAB-UNIVL-CP-FABU-Stock-Price
https://www.quandl.com/data/ZEP/YONG-Yongye-International-Inc-YONG-Stock-Price-Delisted

As I wrote also on the Google Group, finally provides the Vendor of SF1 also a dataset with historical prices, included delisted companies:
https://www.quandl.com/databases/SEP
Using his SF1 and SEP Quandl databases is the lowest-cost solution for reliable backtesting data

authors: alphaville76 bartosh pbharrin tibkiss vprelovac

repo: zipline-live/zipline


text:
Detection Radius Too Large

Right now the detection radius for NPCs to notice you soiling yourself is a bit unbalanced. For example, people will notice if you  try going pee in your underwear, even if you don't succeed. And the radius multipliers seem rather large in general.

Relevant to detection, monsters in the mines and skull cave now notice you wetting/messing on the ground or in your diapers. No impact on the game itself, obviously, but it's always a laugh to be told off by a slime for going potty on the ground like a barbarian...in a cave of all places.


text:
Login: Login with MFA

As an enduser I want to be able to login my user with multi factor.
Acceptance Criteria

[x] Ui checks what kind of authentication methods should be shown depending on the settings of the organization or instance and the configuration the user has
[x] If settings tell to have mfa and user doesn't have it configured, step up is shown
[x] If otp is configured, input field for code is shown
[x] If webauthn is configured challenges should be started automatically without the user clicking a button
[x] If only one possiblity we show it directly
[x] If both options are configured we show webauthn per default and then otp
[ ] If options are in package, we want to be able to configure the check order  of the factors
[ ] u2f should be implemented as highest priority

If both options are configured we show webauthn per default and then otp
-> a selection option is shown instead. we can implement this at a later point but I'd reduce the overhead for the beginning

authors: hifabienne peintnermax

repo: zitadel/typescript


text:
[Bug]: Active Directory / LDAP external IDP fails when using objectGUID as the ID attribute

Preflight Checklist

[X] I could not find a solution in the documentation, the existing issues or discussions
[X] I have joined the ZITADEL chat

Environment
Self-hosted
Version
2.48.0
Database
PostgreSQL
Database Version
16.x, 14.x
Describe the problem caused by this bug
When the objectGUID value is selected as the ID attribute for an Active Directory IDP, Zitadel fails to convert the value from a binary / byte array into a GUID string value before attempting to store it as a json object in the auth.auth_requests.request field. Postgres throws an error with the following message: "invalid byte sequence for encoding "UTF8""
A related issue (and solution) for another project can be found on StackOverflow at:
https://stackoverflow.com/questions/18383843/how-do-i-convert-an-active-directory-objectguid-to-a-readable-string
To reproduce

Configure an Active Directory / LDAP IDP (either at the global or org level).

Configure the ID attribute as "objectGUID"

Attempt to authenticate via the Zitadel login using a valid AD / LDAP user.

Get an error message

Check the zitadel logs at the timestamp of the login to find the "invalid byte sequence for encoding "UTF8"" message.

time="2024-03-20T19:19:22Z" level=error auth_req_id=259147125936357754 caller="/home/runner/work/zitadel/zitadel/internal/api/ui/login/renderer.go:341" error="ID=QUERY-C1E4D Message=Errors.Internal Parent=(ERROR: invalid byte sequence for encoding \"UTF8\": 0xbc (SQLSTATE 22021))"

Screenshots
No response
Expected behavior
Expected behavior would be to convert the binary / byte array to a string GUID value before attempting to store it in as a json object.
Any future comparison of the LDAP objectGUID would also need to be converted before comparing to the json value in the auth_requests table.
Operating System
Zitadel: Docker image running on Linux (TrueNas Scale)
Client: Windows 10, FireFox 123.0.1, Chrome 122.0.6261.129
Relevant Configuration
No response
Additional Context
No response

need to check if the id is utf-8 safe, otherwise we need to base64 encode it -> small bugs

I run into the same problem. Never got Samba4 LDAP (like Active Directory) working with Zitadel.
Perhaps the following should be considered:
https://central.owncloud.org/t/ocis-with-samba-ldap-without-owncloud-schema/41377/19

Thanks, works. But using Zitadel still for testing. Would be so cool if Zitadel integrate LDAP like the other ones (Keycloak, Authelia, Authentik).

authors: helmut72 hinmanjp livio-a

repo: zitadel/zitadel


text:
doc: add severity example

I only found out how to use this after reading all the test cases.
I think it's better to appear in the readme. hah~

I believe this should be added to lib.rs instead, then using cargo readme to generate the README.md (maybe there should be a CI to check that lib.rs and README.md stay in sync?)

oh lol yes I always forget about that. Thanks. @attila-lin do you mind doing that?

TIL.
Let  me try~

authors: Nahor attila-lin zkat

repo: zkat/miette


text:
Make zlib library produced by cmake and configure identical

zlib binaries really ought to be identical regardless of whether you build them with cmake or configure.
This pull request verifies that, and makes it so, on four platforms, at least for plain old and --zlib-compat builds, as long as you are careful to specify same optimization.
Here's what it took:

canonicalize CHOST in configure
rearrange source file order in cmake and configure to match (at least for i686, amd64, aarch64, ppc, and ppc64le)
don't link shared libraries explicitly with -lc (shouldn't be needed; caused differences between configure and cmake)
name .so same in cmake as in configure for -compat case
update pkgcheck.yaml to test on -m32, armel hf, aarch64 and ppc/ppc64le, too
update pkgcheck.sh to verify that cmake and configure create identical libraries
change CMakeLists.txt to check for CPU features the same way configure does
(unless WITH_NATIVE_INSTRUCTIONS is on, in which case it also does a
build-time runtime check, as it did before this pull request).

Along the way, it turned out that the configure sections for 32 and 64 bit x86 were
essentially identical, so this pull request merges them to reduce chance of
accidental divergence later.
Partially fixes #638; fixes #666 and #681.
Known issues left for future pull requests:

There may still still differences between cmake and configure on architectures not yet tested by .github/workflows/pkgcheck.yaml

Rebased.

This is ready to go, I think.

I think the problem with configure script for PPC should be fixed.
And configure and cmake should be set to -O2.
That should fix some workarounds that were needed I believe, also you won’t need to check CMakeCache.txt.

Also an additional comment in the Usage string of test/pkgcheck.sh saying that the example commands are for Ubuntu/Debian-like distros would be nice. Since the instructions use apt and the names of the dependency packages may change on other distros. Something simple like For example, on Ubuntu:.

Resolved except maybe for the %% and the "on ubuntu" wording in test/pkgcheck.sh comments.
Tomorrow morning I'll push an update for those and anything else that comes up tonight.

@dankegel have you encountered the issue with -mfpu=neon is set on all files when Neon is present in configure, but in CMake we only set it per file that uses neon?

Yes.  That's why I wimped out and only test aarch64, not 32 bit arm...

See #669 and #668. Maybe you can cherry pick those and see if they solve the problems?

cherry-picking #668 and #669 still leaves us with configure applying -march=armv8-a+crc hither and yon for
arm-linux-gnueabihf, e.g. on adler32.c.

@dankegel are there also problems with configure using powerpc? I noticed we don't have a CI test for powerpc for configure..

powerpc seems ok.  arm is more attached to -march flags than powerpc is, I think...

The cmake O2/O3 issue seems beyond the goals of this pull request; my strategy of letting the wookie, er cmake, win seems like enough for the moment.
And I'm not sure this pull request should be blocked waiting for the 32 bit -march disagreement between cmake and configure to be solved...?  A later pull request can expand the list of architectures tested by pkgcheck.
Other than those, I think the pull request now covers the feedback received, and it's ready for merging.

I think we should wait until some of the cmake/configure issues are resolved and then add more configurations to the pkgcheck. Sometimes these things take time. I have had PRs that take 3-4 months so I know how it is.

h'ok.  Landing the other three pull requests first is fine.

Let's do this :-)

This overlaps with #676 ?

Only trivially.  git will do the right thing.

As long as @Dead2 knows the correct order of merging pull requests...

@dankegel thank you for adding the new architectures. Are there any remaining outstanding issues that we haven't cataloged? The only other thing I noticed was in configure that the line LDFLAGS=${LDFLAGS-"-L."} adds -L. which is not added in CMake.

-L. appears to do nothing and could be omitted.  I looked through git history and found it may have originally been
added in f6194ef3, but even then, it was a no-op (unless there is some strange ld out there
that searches the library search path even when you provide the filename of the library).
Likewise, the -L.. could be omitted from test/Makefile.in.
But as it does not cause configure and cmake to generate different bits,
I hesitate to remove it as part of this pull request... perhaps it could be a followon.

OK, I updated config.sub's comment to explain what it does better, and to
mention using autotools' config.sub as a workaround in case this one is too limited.
I think that (and my replies above) resolves all the feedback received today sufficiently.
If the magic dd for macos seems unacceptable, I can remove macos support from pkgcheck.sh.
Once this is approved, please merge #676 first; then git will ignore the commit that duplicates the fix in #676 .

h'ok, it passes on mac now, too, without the dastardly dd hack.
How do people feel about the way the mac AVX2 problem was
solved by overloading WITH_NATIVE_INSTRUCTIONS ?
I could have introduced a new option, but WITH_NATIVE_INSTRUCTIONS
is such a close match.

Is that code coverage decrease real?

This is now ready for rebase.

@dankegel I noticed that this leaves directories btmp1, btmp2, pkgtmp1 and pkgtmp2 after running the script. Maybe add them to make clean? Another option would be to erase them after the check is done, but it might be useful to be able to check them in case of error. This could easily be part of a future clean up PR as well.

@mscastanho I added clean and .gitignore entries for pkgcheck's detritus, and made pkgcheck clean up after itself except on failure.

Ready for final review and landing.

The coverage changes seem spurious.  Could they be related to the optimization change?

Let's land #692 first, then I'll rebase and figure out that coverage problem.

It seems I already asked the question about config.sub. I think it would be better if it was merged into configure in some way. That way configure script is more self contained.

I removed the questionable set of CFLAGS in test/pkgcheck.sh, and moved config.sub out of the top level directory.
I think it really is good to go now...?

Can't have it in a 'configure' subdirectory, there's a bit of a name clash there :-)

Push the button @Dead2 :-)

I am in no condition to review stuff right now, with 5 holes in my abdomen and recovering from surgery that did not go quite as planned (it turned out OK, but means a much longer and more painful recovery). I hope to be able to read without my eyes constantly crossing in a couple of days, after that I can probably get some more testing and reviewing done.
That said, this PR has been reviewed multiple times by me and others, and although I see only 1 current review approval, I'll merge this now so we can keep things moving along and get the rest rebased on top of this as well. The other PRs will have to wait a bit longer though, unless there are more-or-less trivial changes that get at least TWO review approvals in addition to me.

Thank you and get well soon!

repo: zlib-ng/zlib-ng

license: Zlib


text:
RuntimeError: Attempted to set the storage of a tensor on device "cuda:0" to a storage on different device "cpu".

Right now the Pytorch with CUDA 10.2 is not available for the Windows OS.
When I am running this project with the CUDA 11.3 for the Windows OS, then I am getting the following ERRORs.
  File "F:\Restart_08122021\my_project\module_x\test.py", line 51, in evaluate
    net = BiSeNet(n_classes=n_classes)
  File "F:\Restart_08122021\my_project\module_x\model.py", line 235, in __init__
    self.cp = ContextPath()
  File "F:\Restart_08122021\my_project\module_x\model.py", line 97, in __init__
    self.resnet = Resnet18()
  File "F:\Restart_08122021\my_project\module_x\resnet.py", line 69, in __init__
    self.init_weight()
  File "F:\Restart_08122021\my_project\module_x\resnet.py", line 83, in init_weight
    state_dict = modelzoo.load_url(resnet18_url)
  File "C:\ProgramData\Anaconda3\envs\my_project\lib\site-packages\torch\hub.py", line 595, in load_state_dict_from_url
    return torch.load(cached_file, map_location=map_location)
  File "C:\ProgramData\Anaconda3\envs\my_project\lib\site-packages\torch\serialization.py", line 713, in load
    return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args)
  File "C:\ProgramData\Anaconda3\envs\my_project\lib\site-packages\torch\serialization.py", line 905, in _legacy_load
    return legacy_load(f)
  File "C:\ProgramData\Anaconda3\envs\my_project\lib\site-packages\torch\serialization.py", line 841, in legacy_load
    tensor = torch.tensor([], dtype=storage.dtype).set_(
  RuntimeError: Attempted to set the storage of a tensor on device "cuda:0" to a storage on different device "cpu".  This is no longer allowed; the devices must match.

Please help me in solving this error.

Could you try modifying this line: state_dict = modelzoo.load_url(resnet18_url) to state_dict = modelzoo.load_url(resnet18_url,  map_location=lambda storage, loc: storage.cuda())