text:
Referenced entities are missing or not currently available

Home Assistant version 2024.2.5
SmartIR version : 1.17.9
SmartIR configuration
SmartIR Climate with ESPHome
ESPHome config:
`esphome:
  name: aircon01
  friendly_name: Aircon 01

esp32:
  board: esp32dev
  framework:
    type: arduino

# Enable logging
logger:

# Enable Home Assistant API
api:
  encryption:
    key: "##############"
  services:
  - service: send_raw_command
    variables:
      command: int[]
    then:
      - remote_transmitter.transmit_raw:
          code: !lambda 'return command;'

ota:

wifi:
  networks:
  - ssid: !secret wifi_ssid
    password: !secret wifi_password
  - ssid: !secret wifi_ssid2
    password: !secret wifi_password2

  ap:
    ssid: "Esphome-Web-537Ec4"
    password: "#########"

captive_portal:

remote_transmitter:
  pin: 25
  carrier_duty_percent: 50%`

HA configuration.yaml
default_config:

tts:
  - platform: google_translate

automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
media_source: /media/local

smartir:

climate:
  - platform: smartir
    name: Office AC
    unique_id: office_ac
    device_code: 1386
    controller_data: esphome.aircon_01_send_raw_command

Describe the bug
When the service from SmartIR is called to ESPHome it says the entity is missing, but if i test it through the developer console it works fine, i have hooked up a LED to see if the board is not defective but it is working fine.
Only through SmartIR it does not work.
Debug log
`2024-03-06 10:38:35.552 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration hacs which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-03-06 10:38:35.554 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration tplink_router which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-03-06 10:38:35.556 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration smartir which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-03-06 10:38:35.557 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration sonoff which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-03-06 10:38:35.560 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration frigate which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-03-06 10:38:35.562 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration alarmo which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-03-06 10:38:41.904 WARNING (MainThread) [homeassistant.components.climate.const] HVAC_MODE_OFF was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use HVACMode.OFF instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:41.907 WARNING (MainThread) [homeassistant.components.climate.const] HVAC_MODE_HEAT was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use HVACMode.HEAT instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:41.908 WARNING (MainThread) [homeassistant.components.climate.const] HVAC_MODE_COOL was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use HVACMode.COOL instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:41.909 WARNING (MainThread) [homeassistant.components.climate.const] HVAC_MODE_DRY was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use HVACMode.DRY instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:41.911 WARNING (MainThread) [homeassistant.components.climate.const] HVAC_MODE_FAN_ONLY was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use HVACMode.FAN_ONLY instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:41.912 WARNING (MainThread) [homeassistant.components.climate.const] HVAC_MODE_AUTO was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use HVACMode.AUTO instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:41.918 WARNING (MainThread) [homeassistant.components.climate.const] SUPPORT_TARGET_TEMPERATURE was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use ClimateEntityFeature.TARGET_TEMPERATURE instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:41.920 WARNING (MainThread) [homeassistant.components.climate.const] SUPPORT_FAN_MODE was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use ClimateEntityFeature.FAN_MODE instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:41.922 WARNING (MainThread) [homeassistant.components.climate.const] SUPPORT_SWING_MODE was used from smartir, this is a deprecated constant which will be removed in HA Core 2025.1. Use ClimateEntityFeature.SWING_MODE instead, please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:44.066 ERROR (MainThread) [homeassistant.helpers.config_validation] The media_source integration does not support any configuration parameters, got /media/local. Please remove the configuration parameters from your configuration.
2024-03-06 10:38:49.849 WARNING (MainThread) [homeassistant.helpers.entity] Entity None (<class 'custom_components.smartir.climate.SmartIRClimate'>) is using deprecated supported features values which will be removed in HA Core 2025.1. Instead it should use <ClimateEntityFeature.TARGET_TEMPERATURE|FAN_MODE: 9>, please report it to the author of the 'smartir' custom integration and reference https://developers.home-assistant.io/blog/2023/12/28/support-feature-magic-numbers-deprecation
2024-03-06 10:38:49.850 WARNING (MainThread) [homeassistant.components.climate] Entity None (<class 'custom_components.smartir.climate.SmartIRClimate'>) does not set ClimateEntityFeature.TURN_OFF but implements the turn_off method. Please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:49.850 WARNING (MainThread) [homeassistant.components.climate] Entity None (<class 'custom_components.smartir.climate.SmartIRClimate'>) does not set ClimateEntityFeature.TURN_ON but implements the turn_on method. Please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:49.850 WARNING (MainThread) [homeassistant.components.climate] Entity None (<class 'custom_components.smartir.climate.SmartIRClimate'>) implements HVACMode(s): off, cool, heat and therefore implicitly supports the turn_on/turn_off methods without setting the proper ClimateEntityFeature. Please report it to the author of the 'smartir' custom integration
2024-03-06 10:38:58.506 WARNING (MainThread) [homeassistant.components.homeassistant.triggers.numeric_state] Error initializing 'Bell alarm ' trigger: In 'numeric_state' condition: unknown entity sensor.camera_02_all_count
2024-03-06 10:39:01.046 WARNING (MainThread) [hass_nabucasa.cloud_api] Fetched https://remotestate.nabucasa.com/request_sync (500)
2024-03-06 10:56:19.038 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities esphome.aircon_01_send_raw_command are missing or not currently available
2024-03-06 10:56:19.508 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities esphome.aircon_01_send_raw_command are missing or not currently available

I can confirm. The same thing is happening on my end.

same here...
debug logs
2024-09-03 17:38:24.992 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:25.932 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:26.434 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:26.733 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:27.233 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:27.234 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:55:48.737 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 17:59:14.224 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:59:14.726 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:59:23.634 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 17:59:24.135 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 18:00:33.562 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 18:00:34.760 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:54.975 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:55.476 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:57.907 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:59.756 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:06:00.257 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:06:01.400 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available

same here...
debug logs
2024-09-03 17:38:24.992 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:25.932 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:26.434 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:26.733 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:27.233 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:27.234 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:55:48.737 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 17:59:14.224 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:59:14.726 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:59:23.634 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 17:59:24.135 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 18:00:33.562 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 18:00:34.760 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:54.975 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:55.476 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:57.907 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:59.756 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:06:00.257 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:06:01.400 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available

I found the solution,  basically each controller has its own file for each device. So I just had to reference code above 7000 for esphome devices so maybe let me know which code you are looking for and we can look for the right, file and what controller you using

Hi

same here...
debug logs
2024-09-03 17:38:24.992 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:25.932 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:26.434 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:26.733 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:27.233 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:38:27.234 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:55:48.737 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 17:59:14.224 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:59:14.726 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 17:59:23.634 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 17:59:24.135 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 18:00:33.562 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm3_gio_remote are missing or not currently available
2024-09-03 18:00:34.760 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:54.975 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:55.476 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:57.907 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:05:59.756 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:06:00.257 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available
2024-09-03 18:06:01.400 WARNING (MainThread) [homeassistant.helpers.service] Referenced entities remote.rm4c_matrim_remote are missing or not currently available

I found the solution, basically each controller has its own file for each device. So I just had to reference code above 7000 for esphome devices so maybe let me know which code you are looking for and we can look for the right, file and what controller you using

Hi Burstofinsanity, thanks for your reply. I'm not using esphome but RM3 ir controllers. I have 4 configured and two of them are working out of the 4 configured.

authors: Burstofinsanity Vizualni ringhio80

repo: smartHomeHub/SmartIR


text:
ccip - define service provider interfaces and relevant types

Defining CCIP related types and interfaces for eventually migrating to the LOOPP architecture.
Relevant CCIP PR: https://github.com/smartcontractkit/ccip/pull/489

merging to unblock grpc work

source: gharchive/pull-request

authors: dimkouv krehermann

repo: smartcontractkit/chainlink-common

license: MIT

license_type: permissive

license_source: github-api


text:
[WIP]Feature/app resumption activation

Progress towards the app resumption, storing previous session IDs.

Codecov Report

Merging #545 into develop will decrease coverage by 0.09%.
The diff coverage is 1.96%.

@@             Coverage Diff              @@
##             develop     #545     +/-   ##
============================================
- Coverage      39.74%   39.64%   -0.1%
  Complexity      2253     2253
============================================
  Files            310      310
  Lines          13782    13817     +35
  Branches        1431     1439      +8
============================================
+ Hits            5477     5478      +1
- Misses          8106     8140     +34
  Partials         199      199

Impacted Files
Coverage Δ
Complexity Δ

...n/java/com/smartdevicelink/proxy/SdlProxyBase.java
6.44% <0%> (-0.01%)
6 <0> (ø)

...om/smartdevicelink/transport/SdlRouterService.java
5.76% <0%> (-0.1%)
3 <0> (ø)

...com/smartdevicelink/transport/TransportBroker.java
21.21% <7.14%> (-0.36%)
15 <1> (ø)

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 97c3b2a...1c13218. Read the comment docs.

authors: codecov-io matwszedybyl

license_source: bigquery


text:
Telemetry

Proposed changes
The telemetry package: Thread-safe, low memory footprint, efficient collection of time-varying quantities in 286 lines of code. Using this module you can easily:

time the duration of selected code blocks;
turn on the Python built-in profiler (cProfile);
gather garbage collection and OS resource usage metrics---memory, user/kernel time, etc.

Telemetry data collection works seamlessly across process boundaries so even if the main process forks children, you can still be sure there won't be nasty race conditions and no overhead either as it would happen when using a DB backend.
Duration, GC and OS measurements are assembled in time series. Every time you sample a duration, a corresponding measurement is added to an underlying duration series at the current time point. GC and OS metrics, if enabled, work similarly, except they're automatically gathered in a background thread every second. Notice we use a nanosecond-resolution, high-precision timer under the bonnet. Time series data are collected in a memory buffer which gets flushed to file as soon as the buffer fills. Files are written to a directory of your choice.
Types of changes

[ ] Bugfix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected)

Checklist

[x] I have read the CONTRIBUTING doc
[x] I have signed the CLA
[x] I have added tests that prove my fix is effective or that my
feature works
[x] I have added necessary documentation (if appropriate)
[x] Any dependent changes have been merged and published in
downstream modules

Further comments
Concurrency and performance
The whole data collection process, from memory to file, is designed to be efficient and have a low memory footprint in order to minimise impact on the runtime performance of the process being monitored and guarantee accurate measurements. At the same time, it is thread-safe and can even be used by multiple processes simultaneously, e.g. a Gunicorn WSGI app configured with a pre-forked server model. (See the documentation of the flush module about parallel reader/writer processes.)
As a frame of reference, average overhead for collecting a duration sample is 0.31 ms. Memory gets capped at 1 MiB as noted below. (You can use the overhead gauge script in the tests directory to experiment yourself.)
Output files
Time series data are collected in a memory buffer which gets flushed to file when the buffer's memory grows bigger than 1 MiB. Files are written to a directory of your choice with file names having the following prefixes: the value of DURATION_FILE_PREFIX for duration series, the value of RUNTIME_FILE_PREFIX for GC & OS metrics, and PROFILER_FILE_PREFIX for profiler data. The file format is CSV and fields are arranged as follows:

Timepoint: time at which the measurement was taken, expressed as number of nanoseconds since the epoch. (Integer value.)
Measurement: sampled quantity. (Float value.)
Label: name used to identify a particular kind of measurement when sampling. (String value.)
PID: operating system ID of the process that sampled the quantity.

Out of convenience, the CSV file starts with a header of: Timepoint, Measurement, Label, PID.
Usage
You start a monitoring session with a call to the start function
import server.telemetry.monitor as monitor

monitor.start(monitoring_dir='/my/output/',  # where to output files
              with_runtime=True,             # enable GC & OS sampling
              with_profiler=False)           # but keep profiler off

This function should be called exactly once, so it's best to call it from the main thread when the process starts. There's also a stop function you should call just before the process exits to make sure all memory buffers get flushed to file:
monitor.stop()

This function too should be called exactly once. With set-up and tear-down out of the way, let's have a look at how to time a code block:
sample_id = monitor.start_duration_sample()       # start timer
try:
    # do stuff
finally:
    key = 'my code block id'      # unique name for this series
    monitor.stop_duration_sample(key, sample_id)  # stop timer

Now every time this block of code gets hit, a new duration sample ends up in the "my code block id" series. If you later open up the duration file where the series gets saved, you should be able to see something similar to
Timepoint, Measurement, Label, PID
    ...
1607092101580206000, 0.023, "my code block id", 5662
    ...
1607092101580275000, 0.029, "my code block id", 5662
    ...

Since timing functions is a pretty common thing to do, we have a shortcut for that
from server.telemetry.monitor import time_it

@time_it(label='my_func')
def my_func():
    # do stuff

The time_it decorator wraps the function you annotate to basically run the same timing instructions we wired in manually earlier. With runtime metrics collection enabled (see start method), a background thread gathers GC and OS data (CPU time, memory, etc.) as detailed in the documentation of GCSampler and ProcSampler. Another thing you can do is turn on the profiler when calling the start function. In that case, when the process exits you'll have a profile data file you can import into the Python profiler's stats console, e.g.
python -m pstats profiler.5662.data  # 5662 is the process' PID

Finally, here's a real-world example of using this module with Gunicorn to record the duration of each HTTP request in time series (one series for each combination of path and verb) as well as GC and OS metrics. To try it out yourself, start Gunicorn with a config file containing
import os
import server.telemetry.monitor as monitor

bind = "0.0.0.0:8080"
workers = 2               # pre-fork model (two processes)
worker_class = 'gthread'  # with threads,
threads = 2               # two of them for each process
loglevel = 'debug'

monitoring_dir = '_monitoring'  # output files go in ./_monitoring

# init monitoring with duration and runtime samplers just after Gunicorn
# forks the worker process.
def post_worker_init(worker):
    os.makedirs(monitoring_dir, exist_ok=True)
    monitor.start(monitoring_dir=monitoring_dir,
                  with_runtime=True,
                  with_profiler=False)

# start the request timer just before Gunicorn hands off the request
# to the WSGI app; stash away the sample ID in the request object so
# we can use it later.
def pre_request(worker, req):
    req.duration_sample_id = monitor.start_duration_sample()

# stop the request timer as soon as the WSGI app is done with the
# request; record request duration in a time series named by combining
# HTTP path and verb.
def post_request(worker, req, environ, resp):
    key = f"{req.path} [{req.method}]"
    monitor.stop_duration_sample(key, req.duration_sample_id)

# flush any left over time series data still buffered in memory just
# before the process exits.
def worker_exit(server, worker):
    monitor.stop()

Customisation
For common telemetry scenarios (timing, profiling, GC) you should just be able to use the monitor module as is. See there for details and usage.
For more advanced scenarios or writing your own samplers, familiarise yourself with the observation module (core functionality, comes with lots of examples) first, then have a look at the samplers in the sampler module to see how to write one, finally you can use the implementation of the monitor module as a starting point for wiring together the building
blocks to make them fit for your use case.
Prod monitoring
We can use this module as is to gather prod telemetry data. Ideally we'd add a couple of tweaks though, just to make it more convenient to use with K8s pods:

Make buffer flushing configurable: time intervals and memory thresholds.
Sidecar to move telemetry files to a place where they can be easily analysed. Importing into Crate or Timescale could be as simple as a COPY FROM. Another option is to copy them to a local directory and then import them into Pandas or any other data analytics framework.
Turning on/off of telemetry without restarting containers.

Data analysis with Pandas
Out of convenience I've added a pandas_import module to, you guessed it, import telemetry files into Pandas frames and series. This module doesn't really belong in the telemetry package but I couldn't find a better home for it just now. If you want to use it to analyse data produced during benchmark sessions (see src/tests/benchmark), you'll have to install Pandas and Matplotlib, which you can do easily with pipenv since I've added those packages to the dev dependencies:
$ pipenv install --dev

Notice those packages and their dependencies won't wind up in the Docker image.

I have read the CLA Document and I hereby sign the CLA

@chicco785 I've just pushed a commit (8af5e67) with some cosmetic changes to keep Code Climate happy. But it looks like there's a problem with how Code Climate counts lines of code:

File observation.py has 299 lines of code (exceeds 250 allowed).
Consider refactoring. NEW

That's bogus. Real count is 84:
$  cloc src/server/telemetry/observation.py
-------------------------------------------------------------------------------
Language                     files          blank        comment           code
-------------------------------------------------------------------------------
Python                           1             93            248             84
-------------------------------------------------------------------------------

I've double checked the figure by tallying up lines of code myself and still got 84. (Well 80 if I exclude imports.) We should probably disable the check?

@c0c0n3 can you update documentation about running load tests and refer to this addition and ditch k6?
https://github.com/smartsdk/ngsi-timeseries-api/blob/master/docs/manuals/admin/benchmarks.md
very briefly, just to let people know how to run benchmarks.

I've added a new section to the manual to detail telemetry features and how to use them:
https://github.com/smartsdk/ngsi-timeseries-api/blob/profiling/docs/manuals/admin/telemetry.md

can you update documentation about running load tests and refer to this addition and ditch k6?

Sure, I can update that section too, but do you also want me to zap all the k6 related stuff too in the code base? i.e. scripts & friends?

Sure, I can update that section too, but do you also want me to zap all the k6 related stuff too in the code base? i.e. scripts & friends?

yep, clearly your shell script is less resource intensive and give burst (k6 provides more a user like dynamic behaviour)

@c0c0n3 can we finalise this PR?

can we finalise this PR?

I think it's ready to go. I haven't updated the benchmark manual section, I opened a separate issue for that: #415.

repo: smartsdk/ngsi-timeseries-api


text:
How do you set the log level?

By default the Level in LogManager is LogLevel.All. I do not see where I can change that to increase the level past debug.

In case anyone finds this (old) issue, a very detailed answer is available in https://github.com/smeshlink/CoAP.NET/issues/46

source: gharchive/issue

authors: billpratt mfalkvidd


text:
Question: Shell pipe also copies to system clipboard

Hello! 👋
Praise: Love the ideas, love the editor, would love to learn more about it and use it more! Well done 👏
Question: when piping selected text to an external program, the selected text is also copied to the system clipboard. Wanted to ask if that's intentional, understand a bit more why, and whether it'd make sense to provide a way to pipe without copying to the clipboard? 💭 When I do the same thing in vim, the contents is not copied to the clipboard, and that's more in line with my expectations. But I'm open to learning about why ad does it differently and potentially adjusting my expectations. 😄
Here's a GIF:

I found this and this in the source code, and I think they connect here. Is that right?
Thanks again! 🙇

(Just a fellow ad user here.)
I checked what ends up in the clipboard, and it's the previous selection. So it behaves consistently with, say, d to delete the selection: what was selected previously is yanked (into the system clipboard because that's the only clipboard ad has, I suppose?).

Hi @izuzak :wave: Thank you very much for the kind words!
It's still reasonably early days for the project in terms of it being actually usable for day-to-day tasks so I suspect there are likely going to be several behaviour changes over the coming months as more people test it out and let me know where things do / don't make sense.
In this case @srenatus is correct both in terms of the observed behaviour and the intended behaviour: all delete actions within ad will set the content of the system clipboard. This applies to explicit delete of ranges (not single characters) and inserts while the current selection is a range which is what you are seeing here. ad does not maintain any internal clipboards or buffers in the way that vim does and I want (as far as possible) for actions that manipulate the buffer state to be as self-consistent as possible. That said, I could see the argument for not setting the clipboard state in this way when you are replacing the current selection. One particular case I can see where this would be annoying is if you wanted to repeatedly paste something into the buffer as a replacement for other regions of text, as you'd end up pasting pack the text you just removed. And now that I think about it, I'm not setting the clipboard in a consistent way if you use Edit commands either, as you'll end up with the contents being the final selection that was deleted (if any) which probably isn't overly useful(!)
So overall, I think it's probably best to update the handling you've linked to here to simply remove the current selection and not pass it back for insertion into the system clipboard.

I forgot to say thank you for the detailed explanation and for the quick change -- many thanks! 🙇

authors: izuzak sminez srenatus

repo: sminez/ad


text:
FAST hub server unreachable for download

When executing the python code:
model = fast.DataHub().download('nuclei-segmentation-model')
I get the error:
Traceback (most recent call last):   File "C:\Users\etiennp\PycharmProjects\RACE\utils\npy_dataset_no_render.py", line 14, in <module>     model = fast.DataHub().download('nuclei-segmentation-model')   File "C:\Users\etiennp\PycharmProjects\venvs\venv3810\lib\site-packages\fast\fast.py", line 18982, in download     return _fast.DataHub_download(self, itemID, force) RuntimeError: Failed to retrieve data from FAST DataHub. Server could be down, or you may have no internet access. Please try again later.
You can also execute
runPipeline --datahub breast-tumour-segmentation --file /path/to/WSI
in command line to get the same error.
This behavior was repeated by someone else on another computer.
System:

Windows 11
FAST v4.8.0
Python 3.8.10

@e-platini I think the FAST Data hub is down (see image below).
Sadly, @smistad will be away for a while, so I am not sure when this will be fixed.

@andreped that's what I was afraid of... Thanks for the answer

authors: andreped e-platini

repo: smistad/FAST


text:
[enhancement] Allow source/content attributes for dynamic zones (create zonefile if they not exists)

Hello!
I tried to create dynamic _acme-challenge zone  for letsencrypt + dns, but currently it not possible create dynaimic zone with source/content.
So we need create zonefile manually ( which is inconvenient, because we want puppet to do everything for us, right? )
Or we need run puppet twice
first run for create primary zonefile:
bind::zones::primary:
  _acme-challenge.example.com:
    view: 'zones'
    content: |
      $ORIGIN _acme-challenge.example.com.
      $TTL 10800      ; 3 hours
      @ IN SOA ns1.example.com. webmaster.example.com (1595157292 300 60 86400 60)
      @ NS      ns1.example.com

and second run to enable dynamic zone:
bind::zones::primary:
  _acme-challenge.example.com:
    view: 'zones'
    update_policy: ['grant certbot name _acme-challenge.example.com. txt']

I want to suggest to allow use source/content options with update_policy together, but to create a zonefile for dynamic zones only if they not exists.
For resolution just need to add an replace attribute for zonefile like this:
file { $zonefile:
  replace      => ( !empty($update_policy) ) ? { true => false, default => true },
}

Thanks for this enhancement. I've just included it in the code and will be pushing a new module release to the forge later.

authors: rayderua smoeding

repo: smoeding/puppet-bind


text:
v3.5.0

Use the epoll backend when RedoxOS is enabled. (#190)

I think it would be safer to raise the minor version since this could potentially cause a subtle change in behavior. (I have in mind the previous regression of async-proces due to a change in implementation on Linux introduced in the patch version.)
Otherwise LGTM.

I think it would be safer to raise the minor version since this could potentially cause a subtle change in behavior. (I have in mind the previous regression of async-proces due to a change in implementation on Linux introduced in the patch version.) Otherwise LGTM.

I doubt that any significant infrastructure has been built on polling in Redox, as no one noticed it was using the inefficient polling backend until now. Still, it's probably safer.

authors: notgull taiki-e

repo: smol-rs/polling


text:
EXPERIMENTAL: IPLD Amend

This PR implements a possible solution for incrementally modifying IPLD nodes.

[x] @warpfork's patch implementation does wholesale, history-less Node updates but needs further optimization.
[x] Draft implementation to accumulate updates and internal state for map-type top-level "add" operation.
[x] Draft implementation to provide a Node "lens" for copy-on-write during Encode.
[x] Implement multi-level "add".
[x] Implement map-type "remove" operations.
[x] Pass TestSpecFixtures/removing-map-entry.
[x] Pass TestSpecFixtures/replacing-map-entry.
[x] Pass TestSpecFixtures/copy.
[x] Pass TestSpecFixtures/move.
[x] Create Amender interface.
[ ] Implement list-type "add" operation.
[ ] Pass TestSpecFixtures/inserting-into-a-list.
[ ] Pass TestSpecFixtures/test-and-conditional-modify.
[ ] Implement list-type "remove" operation.
[ ] Add more comments.

This is superwild and very interesting!!
As an outline it definitely seems plausible that this can work.  So I'll say no more about that.
What's most interesting here is promoting the "patch" operations and structures...
... from where I drafted them in the traversal/patch package -- a leaf node, which is not necessary to use (and thus we can evolve for a while with a more "alpha"-like attitude, and even build alternatives to in parallel)...
... into the core datamodel package -- which is the bottom of all imports (you can't avoid having in your import graph, and anything there almost immediately becomes highly change-resistant as a result of being so loadbearing).
I'm a little nervous about that, to say the least. :sweat_smile:
The feature overlap is pretty high, so it makes sense in that regard.  But it's not 100% -- for example, I can't imagine what use the "test" operation would be here (which we have in turn largely just because it's specified in the JSON Patch RFC, and I was rolling with compatibility with that in mind when writing that patch package).  I'm also not sure if a path to patch op target makes sense; just a pathsegment for where to update the value within the current node (no deeper) should suffice?  And for a third, "move" and "copy" might be a little strange -- from a single node's perspective, when we're working with the in-memory handles to other nodes already, we don't really need those ops, do we?
More important is the change coupling and inertia we'd be stuck with.  I can't really provide evidence that would be bad, but I don't know if I would want to take a bet that it would be fine, either.
I wonder if something very like this, but declaring new, unrelated types in the data model package, would be slightly more ideal.  It would be more code, and some of it alarmingly similar looking, but it would decouple things more, and I suspect it might end up more refined in the end.

More important is the change coupling and inertia we'd be stuck with. I can't really provide evidence that would be bad, but I don't know if I would want to take a bet that it would be fine, either.
I wonder if something very like this, but declaring new, unrelated types in the data model package, would be slightly more ideal. It would be more code, and some of it alarmingly similar looking, but it would decouple things more, and I suspect it might end up more refined in the end.

That makes sense. I'll try to play around with some options here. I didn't want to branch out too drastically, but more decoupling definitely seems like the better path.

The feature overlap is pretty high, so it makes sense in that regard. But it's not 100% -- for example, I can't imagine what use the "test" operation would be here (which we have in turn largely just because it's specified in the JSON Patch RFC, and I was rolling with compatibility with that in mind when writing that patch package). I'm also not sure if a path to patch op target makes sense; just a pathsegment for where to update the value within the current node (no deeper) should suffice? And for a third, "move" and "copy" might be a little strange -- from a single node's perspective, when we're working with the in-memory handles to other nodes already, we don't really need those ops, do we?

This is very interesting, thanks for thinking about this, @warpfork. I can see how patch operations don't fully overlap with datamodel.
I'm coming to the realization of patch and traversal being somewhat related abstractions - both are interested in Node relationships, traversal in looking at them, and patch in modifying them.  So maybe inside traversal is the right place for patch lol...
I'll think about and play around with this some more soon.

If you look at this code anytime soon (no rush from my side), @rvagg, I'm working on a better strategy for list-type nodes.
The current approach appears to be working reasonably well for map-type nodes but I need to use an underlying mods type that supports the types of operations possible on a list (perhaps using an arraylist or linkedlist instead).
I also have a question about what to do when an entirely new hierarchy gets created with a path that has a mixture of string and int segments. For example, for a node with these contents:
{
	"foo": ["bar", "baz"]
}

...does this operation:
{ "op": "add", "path": "/foo/1/0", "value": "qux" }

...result in this node (my preference):
{
	"foo": [
		"bar",
		["qux"],
		 "baz"
	]
}

...or this node?
{
	"foo": [
		"bar",
		{
			"0": "qux"
		},
		 "baz"
	]
}

Basically, I'm trying to determine the "right" type for a parent Node when constructing a nested hierarchy. The code currently blindly assumes a map-type parent, but that doesn't seem correct.
I thought of using the "type" of the segment, but it doesn't seem safe to assume that an int type segment implies a list-type Node since it's quite possible for a map key to be an integer string representation.
It also doesn't seem safe to use the underlying storage type of PathSegment to infer the Node type because:

The storage type is currently hidden (for good reason since it's an implementation detail).
A string storage type does not necessarily imply a map-type Node since it could just as easily be the string representation of a list-type Node index.

Hello, we're thinking of merging the initial version of the Patch APIs in go-ipld-prime.
Would you like to sync up before we do so? https://github.com/ipld/go-ipld-prime/pull/350
If we don't hear back we'll merge in a couple of weeks.

Hello, we're thinking of merging the initial version of the Patch APIs in go-ipld-prime.
Would you like to sync up before we do so? ipld#350
If we don't hear back we'll merge in a couple of weeks.

Thanks for the note, @RangerMauve.
It's cool from my side to merge ipld#350 whenever you're ready. I've intentionally kept my current implementation separate and parallel to Eric's implementation. Can chat about this on the next IPLD team sync, if needed.
I should have my implementation in a testable/reviewable state in a week or so, and be ready to benchmark both implementations.
Assuming, of course, that the fundamental approach makes sense to @rvagg and @warpfork. It's still a WIP but my next iteration should be closer to the final state I have in mind.

@smrz2001 Sweet. Lets talk on the next call and I'll merge the PR after that. 😁

@smrz2001 there's some overlapping discussion on PathSegment type stuff over @ https://github.com/ipld/ipld/pull/195 which is also looking at patch-like semantics but for URLs.
I think I'm mostly of the opinion that if you use paths, then you should just put up with what paths give you - which is basically something like: integers become indexes of lists and everything else is map keys. If you want to break out of this then you have to use an alternative mechanism. Which I think might be a case for either planning for a future extension to add more sophisticated specifiers than just plain paths, or building in an escaping mechanism to path semantics (although it could be argued that we're far too late for changing path semantics at all).

@smrz2001 there's some overlapping discussion on PathSegment type stuff over @ https://github.com/ipld/ipld/pull/195 which is also looking at patch-like semantics but for URLs.
I think I'm mostly of the opinion that if you use paths, then you should just put up with what paths give you - which is basically something like: integers become indexes of lists and everything else is map keys. If you want to break out of this then you have to use an alternative mechanism. Which I think might be a case for either planning for a future extension to add more sophisticated specifiers than just plain paths, or building in an escaping mechanism to path semantics (although it could be argued that we're far too late for changing path semantics at all).

Thanks, @rvagg, this is very helpful!

Sorry for the force pushes... I detest git submodules - I just took a clean branch from master, copied over my code, and pushed to the same PR.

@rvagg @RangerMauve, just pushed some crude benchmarking tests comparing the two implementations (calling them amend (mine) vs patch (from master) for convenience).
I see some patterns already based on the size of the base Node, the type of the Node, and the number of update operations, but obviously need to dig deeper. I'm also unable to get some of the tests to run with patch, but that could just be me using the API incorrectly.
My choice of how to implement the test was purely based on how quick/easy it was to write lol, but I might have unintentionally introduced some bias and will refine the tests some more.
I should probably also add a check at the end of each test to make sure the serialized results are correct/consistent.
The only operation I was able to consistently run with both implementations and using both recursive types was "replace". Here are some results for a 10000-entry map/list -> 100/1000/10000 replacements (1% / 10% / 100%) -> dagjson.Encode.
I only did 10 runs to start with to save some time iterating on the longer tests.
goos: windows
goarch: amd64
pkg: github.com/ipld/go-ipld-prime/traversal/amend
cpu: Intel(R) Core(TM) i7-10870H CPU @ 2.20GHz

BenchmarkAmend_Map_Replace/inputs:_{100_1}-16                 10                                   18034 B/op        155 allocs/op
BenchmarkAmend_Map_Replace/inputs:_{100_10}-16                10            106110 ns/op           20196 B/op        228 allocs/op
BenchmarkAmend_Map_Replace/inputs:_{100_100}-16               10            104230 ns/op           48069 B/op        917 allocs/op
BenchmarkAmend_Map_Replace/inputs:_{1000_10}-16               10            363680 ns/op          209056 B/op       1591 allocs/op
BenchmarkAmend_Map_Replace/inputs:_{1000_100}-16              10            360850 ns/op          235906 B/op       2400 allocs/op
BenchmarkAmend_Map_Replace/inputs:_{1000_1000}-16             10           1064380 ns/op          470792 B/op      10955 allocs/op
BenchmarkAmend_Map_Replace/inputs:_{10000_100}-16             10           3255110 ns/op         1876971 B/op      15914 allocs/op
BenchmarkAmend_Map_Replace/inputs:_{10000_1000}-16            10           4800090 ns/op         2211872 B/op      24874 allocs/op
BenchmarkAmend_Map_Replace/inputs:_{10000_10000}-16           10          14986830 ns/op         4387252 B/op     111311 allocs/op

BenchmarkPatch_Map_Replace/inputs:_{100_1}-16                 10                                   26357 B/op        157 allocs/op
BenchmarkPatch_Map_Replace/inputs:_{100_10}-16                10            201810 ns/op          106917 B/op        299 allocs/op
BenchmarkPatch_Map_Replace/inputs:_{100_100}-16               10           1399930 ns/op          917560 B/op       1719 allocs/op
BenchmarkPatch_Map_Replace/inputs:_{1000_10}-16               10           1604240 ns/op         1356875 B/op       1644 allocs/op
BenchmarkPatch_Map_Replace/inputs:_{1000_100}-16              10          13435200 ns/op        11714030 B/op       2987 allocs/op
BenchmarkPatch_Map_Replace/inputs:_{1000_1000}-16             10         114251820 ns/op       115289158 B/op      17308 allocs/op
BenchmarkPatch_Map_Replace/inputs:_{10000_100}-16             10         130025820 ns/op        94455943 B/op      16507 allocs/op
BenchmarkPatch_Map_Replace/inputs:_{10000_1000}-16            10        1274962210 ns/op       927959630 B/op      30980 allocs/op
BenchmarkPatch_Map_Replace/inputs:_{10000_10000}-16           10       13097512140 ns/op      9262888342 B/op     175272 allocs/op

BenchmarkAmend_List_Replace/inputs:_{100_1}-16                10                                   21885 B/op        240 allocs/op
BenchmarkAmend_List_Replace/inputs:_{100_10}-16               10             52140 ns/op           23181 B/op        303 allocs/op
BenchmarkAmend_List_Replace/inputs:_{100_100}-16              10             52340 ns/op           36141 B/op        933 allocs/op
BenchmarkAmend_List_Replace/inputs:_{1000_10}-16              10            251410 ns/op          229202 B/op       2386 allocs/op
BenchmarkAmend_List_Replace/inputs:_{1000_100}-16             10            200060 ns/op          242608 B/op       3098 allocs/op
BenchmarkAmend_List_Replace/inputs:_{1000_1000}-16            10            599950 ns/op          381330 B/op      11109 allocs/op
BenchmarkAmend_List_Replace/inputs:_{10000_100}-16            10           2103530 ns/op         2215564 B/op      23809 allocs/op
BenchmarkAmend_List_Replace/inputs:_{10000_1000}-16           10           2599990 ns/op         2358320 B/op      31900 allocs/op
BenchmarkAmend_List_Replace/inputs:_{10000_10000}-16          10           7623890 ns/op         3796463 B/op     112816 allocs/op

BenchmarkPatch_List_Replace/inputs:_{100_1}-16                10                                   17962 B/op        141 allocs/op
BenchmarkPatch_List_Replace/inputs:_{100_10}-16               10                                   37488 B/op        240 allocs/op
BenchmarkPatch_List_Replace/inputs:_{100_100}-16              10            199960 ns/op          225060 B/op       1230 allocs/op
BenchmarkPatch_List_Replace/inputs:_{1000_10}-16              10            300060 ns/op          321248 B/op       1421 allocs/op
BenchmarkPatch_List_Replace/inputs:_{1000_100}-16             10           1499960 ns/op         1822284 B/op       2492 allocs/op
BenchmarkPatch_List_Replace/inputs:_{1000_1000}-16            10          14401930 ns/op        16836381 B/op      14104 allocs/op
BenchmarkPatch_List_Replace/inputs:_{10000_100}-16            10          17175120 ns/op        17877569 B/op      14206 allocs/op
BenchmarkPatch_List_Replace/inputs:_{10000_1000}-16           10         153638090 ns/op       165624367 B/op      25906 allocs/op
BenchmarkPatch_List_Replace/inputs:_{10000_10000}-16          10        1620529000 ns/op      1643242624 B/op     143041 allocs/op

Would it make sense to replace the current patch implementation with this instead?
e.g. expose an API to apply a patch set using the schema, but to have the underlying stuff using these new APIs / expose the raw APIs for when folks don't want to use patch sets?

Hey @RangerMauve, I think it'd probably be good to wait till @warpfork is back and also has a chance to review the code and some of the design choices.
There are also a few items that are not yet implemented in this version of the code that are available in patch, e.g. budgets, link traversal, etc. (and perhaps others I've missed?)
I can take a stab at implementing those as well before considering the PR finalized so that we don't regress what's currently available.

authors: RangerMauve rvagg smrz2001 warpfork


text:
Configuration API not reading strings with "true" or "false" correctly

Leaf Version:3.10.0
To fix you can wrap them in quotes.
But will look into sometime Monday~Thursday
Example fix
vanish_colour:
  condition: "MATCH:<vanished>"
  options:
    'Default': "<#ffffee>"
    'true': "<#c0fce6>"
    'false': "<#ffffee>"

Will be fixed with 311.0

repo: smuddgge/Leaf


text:
Workflow disappeared from catalog

Hi @johanneskoester,
this catalog is a great idea and since its inception, I've worked a bit to adjust my workflow (ARPEGGIO) to follow all the formatting and linting standards.
Unfortunately the last action fix caused my workflow to disappear from the catalog and I'm not sure why. I tried to look into this, but I wasn't able to find any clue.
Best,
Stefan

My repo https://github.com/nikostr/dna-seq-deepvariant-glnexus-variant-calling is not showing up, even though it seems to fulfill the criteria specified. I tried cloning this repo and running the generate_catalog.py script locally, limiting the search to each of our repos, as well as the repos matching the pattern snakemake-deepvariant. The two latter ones do show up in the actual catalog, neither of ours do, but when running the script, they give the same logfile output. Very strange.

Okay, I've looked closer at this, and it lead me here:
https://github.com/snakemake/snakemake-workflow-catalog/runs/2506448252?check_suite_focus=true
It seems as if the action handles about 1000 repos before failing quietly. This might be related to the 1000 API requests/hour limit mentioned here: https://docs.github.com/en/actions/reference/usage-limits-billing-and-administration
Not sure how to work around this.

Good catch @nikostr!
I tried to find out ways to confirm what you found and it seems like this issue has been present since earlier. This is the action run from before my workflow got removed and you can see that my repository is the last one processed before the quiet failure:
https://github.com/snakemake/snakemake-workflow-catalog/runs/1876964779?check_suite_focus=true
A possible workaround, in theory, would be to split the >2000 API requests in blocks of 1000. So basically there should be 3 actions (or more), with each one processing different chunks of repos at 1 hour distance.
I don't have a lot of time these weeks, but I'll test some solutions at some point.

I've started looking into this here:
https://github.com/nikostr/snakemake-workflow-catalog/tree/update-latest-workflows
I think there might be a smart workaround simply by sorting the repo search results based on update time. Haven't quite got it to work yet, but I think that should have multiple up-sides.

authors: nikostr supermaxiste

repo: snakemake/snakemake-workflow-catalog


text:
Snakemake API throws RuntimeError related to asyncio when used within Jupyter

Snakemake version 6.6.1

Describe the bug Asyncio related. I believe it is because both Jupyter's kernel and snakemake uses an asyncio loop.

Logs

Building DAG of jobs...
Traceback (most recent call last):
  File "/tmp/test/venv/lib/python3.9/site-packages/snakemake/__init__.py", line 699, in snakemake
    success = workflow.execute(
  File "/tmp/test/venv/lib/python3.9/site-packages/snakemake/workflow.py", line 750, in execute
    dag.init()
  File "/tmp/test/venv/lib/python3.9/site-packages/snakemake/dag.py", line 195, in init
    self.update_needrun(create_inventory=True)
  File "/tmp/test/venv/lib/python3.9/site-packages/snakemake/dag.py", line 916, in update_needrun
    self.workflow.iocache.mtime_inventory(self.jobs)
  File "/tmp/test/venv/lib/python3.9/site-packages/snakemake/io.py", line 136, in mtime_inventory
    async_run(self._mtime_inventory(jobs))
  File "/usr/lib/python3.9/asyncio/runners.py", line 33, in run
    raise RuntimeError(
RuntimeError: asyncio.run() cannot be called from a running event loop

Minimal example

import os

rule a:
        resources:
                nproc=os.cpu_count()
        shell:
                "echo {resources.nproc}"

Run the following  in a Jupyter notebook
from snakemake import snakemake

snakemake('Snakefile', targets=['a'])

Additional context
ipykernel           6.0.3
ipython             7.25.0
notebook            6.4.0

❯ python --version
Python 3.9.6

I tried the same in the simple Python console and the IPython console. There does not seem to be an issue.
I develop a package called snek5000 which relies on the snek5000 API.

Related: https://stackoverflow.com/questions/55409641/asyncio-run-cannot-be-called-from-a-running-event-loop

This seems to be a well known problem. Which was does not exist IPython but is unavoidable in Jupyter (?)
In IPython
In [1]: import asyncio

In [2]: asyncio.get_running_loop()
---------------------------------------------------------------------------
RuntimeError                              Traceback (most recent call last)
<ipython-input-2-8edbd6ad7d71> in <module>
----> 1 asyncio.get_running_loop()

RuntimeError: no running event loop

In jupyter console or notebook or lab
n [1]: import asyncio

In [2]: asyncio.get_running_loop()
Out[2]: <_UnixSelectorEventLoop running=True closed=False debug=False>

See also: https://github.com/jupyter/notebook/issues/3397
Would it be possible to reuse the running asyncio loop, if it is already running?

repo: snakemake/snakemake


text:
.append() does not exist anymore in pandas

Hello,
I am using SATURN to integrate cross-species scRNA-Seq data. I am able to run train-saturn.py and it seems to be doing well until I get this error :
"../../train-saturn.py", line 820, in trainer
scores_df = scores_df.append(mmd_row, ignore_index=True)
AttributeError: 'DataFrame' object has no attribute 'append'. Did you mean: '_append'?
I have pandas version '2.0.1' and apparently df.append() is not available anymore after pandas '1.4'.
Would that be possible to specify which version of pandas you are using ?
Otherwise I would suggest to use pd.concat() which is the alternative proposed by pandas (this is what I am currently trying to do).
Thank you !
Anaëlle

Hi, thanks for pointing out this issue!
You should be able to replace that line with:
scores_df = pd.concat((scores_df, pd.DataFrame([mmd_row])), ignore_index=True)
Please let me know if that works!

Hi, yes it worked ! Thank you for your help. This issue is at lines 818, 820 and 847.
I take this opportunity to tell you as well that so far I found SATURN easy to use. The only thing I could suggest would be to specify that the var_names of the adata objects should be the gene names in the README file. Otherwise it is really clear.
Thank you again !

Glad to hear that, thanks for the feedback!

Hi, yes it worked ! Thank you for your help. This issue is at lines 818, 820 and 847. I take this opportunity to tell you as well that so far I found SATURN easy to use. The only thing I could suggest would be to specify that the var_names of the adata objects should be the gene names in the README file. Otherwise it is really clear. Thank you again !

Meet the same issue, thanks

Hi, I had the same issue and replaced the lines 818, 820 and 847, but I am still getting an issue
 line 818, in trainer
    scores_df = pd.concat((scores_df, pd.DataFrame([mmd_row])), ignore_index=True)
UnboundLocalError: local variable 'mmd_row' referenced before assignment

Hi. Can train_saturn.py be updated with these changed?

repo: snap-stanford/SATURN


text:
Dynamically added dropdown as selectpicker

Hi there,
I have a page where i have some kind of query builder. That is using 2 selectpickers to choose where to filter on and the condition.

        <select name="search_key[]" class="selectpicker search-key" data-width="100%" data-style="btn-success" data-max-options="1">
            <option value="product_name">Product Name</option>
            <option value="product_ean">EAN</option>
            <option value="product_sku">SKU</option>
        </select>

        <select name="search_condition[]" class="selectpicker search-condition" data-width="100%" data-style="btn-default" data-max-options="1">
            <option value="sw">Starts with</option>
            <option value="ew">Ends with</option>
            <option value="co">Contains</option>
            <option value="ex">Exact</option>
        </select>

`

This works perfect.
But when i press a button to add a filter (an ajax call which gets this template) the selectpickers are not showing.
I tried to do $(".selectpicker").selectpicker('refresh');
But no luck.
Any idea how i can enable dynamically created select boxes as an selectpicker?
Thanks in advance.
Matthijs

Do you appending bootstrap.js with this template?

No not in the template itself. I do an ajax call and append the template to a div. On the page itself the where it is appended the bootstrap.js is loaded.

After completing your ajax call, You might be appending the option to the select list conditionally. After that only you need ton use following code.
$(".selectpicker").selectpicker('refresh')
If you use it before the option of the select list getting updated its of no use. You need to do after rendering the options conditionally. That would work for you.

Ok it is working now I already did $(".selectpicker").selectpicker('refresh'); this after appending the html. But had to add another class like filter-selector and then $(".filter-selector").selectpicker('refresh'); works. Thanks.

I have same problem but my problem is resolved with
$(".selectpicker").selectpicker('refresh')

After completing your ajax call, You might be appending the option to the select list conditionally. After that only you need ton use following code. $(".selectpicker").selectpicker('refresh')
If you use it before the option of the select list getting updated its of no use. You need to do after rendering the options conditionally. That would work for you.

Thanks

repo: snapappointments/bootstrap-select


text:
Resize / Scroll listeners added each time select is clicked

Each time a bootstrap select is clicked, two event listeners are added to the window: resize, and scroll.
From the bootstrap select Examples page: After clicking one of the selects eight times, you get sixteen listeners:

Live, simplified example here:
https://michaelsweeney.github.io/bootstrap-select-resize-scroll/
As might be expected, calling 'destroy' on the selects doesn't remove them, nor does manually removing the select. This might not be an issue for small projects, but I'm working on a single-page app designed to stay open for relatively long periods of time, with dynamically-created selects each having several hundred options, and I'm concerned about potential memory leaks and/or bloat.
Is there any way to remove these references periodically -- or ideally, not duplicate them in the first place?

Looks like this was actually a Bootstrap issue that was fixed in Bootstrap v4.4.0. Not sure which issue/commit specifically.

authors: caseyjhol michaelsweeney


text:
feat: Support for Optimistic Quorum

Changes from https://github.com/snapshot-labs/snapshot/pull/4625 are also included in this PR,
so make sure it is merged to avoid confusion, with that PR you should be able to configure different types of quorum on proposals
This PR adds support for an optimistic quorum with which spaces can reject some proposal if the reach certain threshold
How to test:

Post proposals with different with different quorum types
default quorum should work same as before
Optimistic quorum should only consider 2nd choice and reject proposal if it reaches quorum value
for example if you go to this proposal

on proposals pages you see the % of quorum rejection

Can we rebase this branch to remove the unrelated changes from #4625 ?

repo: snapshot-labs/snapshot


text:
opcache problem with Stopwatch

Because stopwatch is a dev depenendency class doesn't exists in production I have this error:

PHP message: PHP Fatal error:  Failed to load class Symfony\Component\Stopwatch\Stopwatch used by typed property Snc\RedisBundle\Logger\RedisCallInterceptor::$stopwatch during preloading in Unknown on line 0

Not sure why is PHP crashing here, since property is optional. Can you craft a reproducer?

Probably this one is the same https://github.com/symfony/symfony/issues/44364
There is a problem with opcache and type hinted class properties in 7.4

Yeah. We can't do much in here. You should upgrade your php version.

authors: koekaverna ostrolucky

repo: snc/SncRedisBundle

license: mit


text:
docs: Fix simple typo, combosable -> composable

There is a small typo in README.md.
Should read composable rather than combosable.

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@845881a). Click here to learn what that means.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master      #53   +/-   ##
=========================================
  Coverage          ?   99.37%
=========================================
  Files             ?        1
  Lines             ?      319
  Branches          ?       75
=========================================
  Hits              ?      317
  Misses            ?        2
  Partials          ?        0

Continue to review full report at Codecov.

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

repo: snd/url-pattern


text:
Revert changing ownership and running game from docker-compose.yml

This command is failing when run from the docker-compose.yml file on the prod and test servers, despite working on my dev computer's Docker setup.
Seems to have something to do with commands in the docker-compose file being run by the container's root user inside the container, whereas commands in the Dockerfile are run by the Docker's host OS as root.

Just going to self-approve and merge this, as it's simply reverting some changes back to their previous state.

repo: sneezymud/sneezymud-docker

license: unlicense


text:
Apostrophe included in banned separators

It says in the readme that the apostrophe is not included in banned separators but for some reason it is marking the word he'll as profain.

Hi, can you provide the full string you use ? It would be easier for us to debug :)


text:
SNOW-743643:  Some functionality is available in the snowpark_extensions_py project

What is the current behavior?
Some functionality is available in the snowpark_extensions_py project
What is the desired behavior?
To integrate some of this functionality in the main library. For example:

Function Name
Description

functions.format_number
formats numbers using the specified number of decimal places

function.daydiff
this function returns the difference in days between two dates. This function will be direct equivalent of the spark datediff. You can simple replace spark datediff by daydiff

functions.date_add
returns the date that is n days days after

functions.date_sub
returns the date that is n days before

functions.bround
This function receives a column with a number and rounds it to scale decimal places with HALF_EVEN round mode, often called as "Banker's rounding" . This means that if the number is at the same distance from an even or odd number, it will round to the even number.

How would this improve snowflake-snowpark-python?
It improves the overall functionality and also will make easier to enable people moving code from spark
References, Other Background
https://github.com/MobilizeNet/snowpark-extensions-py

Thanks @orellabac :)

authors: orellabac sfc-gh-achandrasekaran

repo: snowflakedb/snowpark-python


text:
SNOW-628244: Create a style guide for snowpark python api

Please answer these questions before submitting your pull requests. Thanks!

What GitHub issue is this PR addressing? Make sure that there is an accompanying issue to your PR.
Fixes #SNOW-628244

Fill out the following pre-review checklist:

[ ] I am adding a new automated test(s) to verify correctness of my new code
[ ] I am adding new logging messages
[ ] I am adding a new telemetry message
[ ] I am adding new credentials
[ ] I am adding a new dependency

Please describe how your code solves the related issue.

create a style guide like: https://github.com/palantir/pyspark-style-guide

thanks @sfc-gh-mabrennan , I've addressed all your comments


text:
Snowpack not loading css sourcemap

As the title suggests, snowpack is not serving css sourcemap (it was compiled from scss). When I open index.html file directly sourcemap loads properly. I used create-snowpack-app with @snowpack/app-template-react-typescript.
When I try to open style.css.map file directly in the browser I get regular style.css file

Same here. It seems this issue is related to #1340.
In my case, GETting http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css.map results in http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css being served.
This causes the following warning in the Firefox Web Console:
Source map error: Error: JSON.parse: unexpected character at line 1 column 1 of the JSON data
Resource URL: http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css
Source Map URL: bootstrap.min.css.map

Same here. It seems this issue is related to #1340.
In my case, GETting http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css.map results in http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css being served.
This causes the following warning in the Firefox Web Console:
Source map error: Error: JSON.parse: unexpected character at line 1 column 1 of the JSON data
Resource URL: http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css
Source Map URL: bootstrap.min.css.map

did you manage to find some sort of solution? this is the only thing preventing me from completely switching to snowpack since I work with a team of juniors, I need that CSS map :D

Same here. It seems this issue is related to #1340.
In my case, GETting http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css.map results in http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css being served.
This causes the following warning in the Firefox Web Console:
Source map error: Error: JSON.parse: unexpected character at line 1 column 1 of the JSON data
Resource URL: http://localhost:8080/assets/bootstrap-4.5.2/css/bootstrap.min.css
Source Map URL: bootstrap.min.css.map

did you manage to find some sort of solution? this is the only thing preventing me from completely switching to snowpack since I work with a team of juniors, I need that CSS map :D

I did not look for a workaround.

We're looking into this as a part of v3.0 release next month! This suffers a bit from a conflict with how we handle source maps of generated build files, but agreed that a .map file on disk should take priority here and be served directly at that URL in dev.
Also related, is that we don't automatically detect a sourceMappingURL comment inside of an npm package CSS file when we install it. So if you were to use our automatic npm package handling like this:
import 'bootstrap/dist/bootstrap.css';
//or
@import 'bootstrap/dist/bootstrap.css';

We're looking into this as a part of v3.0 release next month! This suffers a bit from a conflict with how we handle source maps of generated build files, but agreed that a .map file on disk should take priority here and be served directly at that URL in dev.
Also related, is that we don't automatically detect a sourceMappingURL comment inside of an npm package CSS file when we install it. So if you were to use our automatic npm package handling like this:
import 'bootstrap/dist/bootstrap.css';
//or
@import 'bootstrap/dist/bootstrap.css';

you would get the CSS file automatically added in your project but without the referenced source map. We should either strip that file, or automatically include it.

Well, i am including compiled css in index.html (public directory), so i hope there will be fix for that

There will definitely be a fix for this in v3, but hopefully sooner

There will definitely be a fix for this in v3, but hopefully sooner

Thats great. Thank you for reaching out. Keep up with awesome work!

I see the same issue for a normal javascript source map from a javascript file generated by an external tool (in this case ScalaJS).
When I request /_dist/main.js.map, I get served /_dist/main.js.
I have tried mounting /_dist with static: true, but that doesn't change anything.

I see the same issue for a normal javascript source map from a javascript file generated by an external tool (in this case ScalaJS).
When I request /_dist/main.js.map, I get served /_dist/main.js.
I have tried mounting /_dist with static: true, but that doesn't change anything.

You're right, I can reproduce as well. Our sourcemap support has some known limitations that we'd hoped to get fixed for v3.0, but slipped to v3.1. We already have that source map work prioritized for next week, will add this as a part of that.

You're right, I can reproduce as well. Our sourcemap support has some known limitations that we'd hoped to get fixed for v3.0, but slipped to v3.1. We already have that source map work prioritized for next week, will add this as a part of that.

I also have this issue a few minutes ago and it seems no body have a solution for now.
My workaround is by renaming the sourcemap's extension like:
/dir/library.js.map into /dir/library.js.map_
and also inside of /dir/library.js you will need to scroll to the bottom and modify the sourceMappingURL into
//# sourceMappingURL=library.js.map_

I also have this issue a few minutes ago and it seems no body have a solution for now.
My workaround is by renaming the sourcemap's extension like:
/dir/library.js.map into /dir/library.js.map_
and also inside of /dir/library.js you will need to scroll to the bottom and modify the sourceMappingURL into
//# sourceMappingURL=library.js.map_

I tried reproducing this bug here, and it seems gone on the main branch.

@halcaponey thanks for the repo, I ran it with the upcoming release (npm install snowpack@next) and looks like it's working? Let me know if I'm testing it wrong though

@melissamcewen it seems to be working with snowpack@next (3.1.0-pre.13): sourcemaps will be served correctly

authors: FredKSchott StefansArya aeons halcaponey martinburger melissamcewen pho7on

repo: snowpackjs/snowpack


text:
[BUG] Tailwind JIT Compiler don't rebuild stylesheet

Bug Report Quick Checklist

[x] I am on the latest version of Snowpack & all plugins.
[x] I use package manager yarn
[x] I run Snowpack on OS Windows
[x] I run Snowpack on Node.js v14 LTS

Describe the bug
TailwindCSS JIT Compiler doesn't pick up changes.
To Reproduce

Clone:
https://github.com/verbose9/tlwind

Install dependencies and spin up dev server:

npm i

npm run dev

Try changing tailwindcss classes(try adding text-red-500 class) in index.html file line 12.
You will see a change for removing classes but no change in adding classes.

Expected behavior
Dev Server should reflect the class changes.

@lukejacksonn this could be a good one to look at to get you started

@lukejacksonn this could be a good one to look at to get you started

are saying this in context of this issue?

I believe this has been fixed in #3326, and will be available in the v3.5.0 release. Please see the updated docs to enable this new setting. Please give it a try and let me know if it fixes your problem!

authors: FredKSchott drwpow verbose9


text:
NPE when subject is null

Crash
 Caused by: java.lang.NullPointerException
        at com.snowplowanalytics.snowplow.tracker.Tracker.addDefaultContextData(Tracker.java:180)
        at com.snowplowanalytics.snowplow.tracker.Tracker.completePayload(Tracker.java:149)
        at com.snowplowanalytics.snowplow.tracker.Tracker.trackUnstructuredEvent(Tracker.java:371)
        at com.snowplowanalytics.snowplow.tracker.Tracker.trackScreenView(Tracker.java:585)
        at com.snowplowanalytics.snowplow.tracker.Tracker.trackScreenView(Tracker.java:547)
        at com.chefsfeed.Analytics.activityStart(Analytics.java:191)

This is the code of tracker creation
        RequestCallback callback = new RequestCallback() {
            @Override
            public void onSuccess(int successCount) {
                Log.d(TAG, "Buffer length for POST/GET:" + successCount);
            }
            @Override
            public void onFailure(int successCount, int failureCount) {
                Log.d(TAG, "Failures: " + failureCount + "; Successes: " + successCount);
            }
        };

        Emitter e2 = new Emitter
                .EmitterBuilder("com.chefsfeed", context)
                .callback(callback)
                .build();

        // Create a Tracker with all options
        mTracker = new Tracker
                .TrackerBuilder(e2, context.getPackageName(), context.getApplicationInfo().name)
                .base64(true) // Optional - defines if we use base64 encoding
                .platform(DevicePlatforms.Mobile) // Optional - defines what platform the event will report to be on
                .build();

Notice the absence of an optional subject setter.
NPE is raised during trackScreenView in
String idScreen = cfActivity.getClass().getCanonicalName();
tracker.trackScreenView(cfActivity.getActivityName(), idScreen);

Thanks for raising @n-belokopytov.  Need to wrap a check for Subject == Null around this block: https://github.com/snowplow/snowplow-android-tracker/blob/master/snowplow-android-tracker/src/main/java/com/snowplowanalytics/snowplow/tracker/Tracker.java#L180-L189

authors: jbeemster n-belokopytov

repo: snowplow/snowplow-android-tracker


text:
Automatically resend failed data when connection is re-established

migrated from https://github.com/snowplow/snowplow/issues/3918

Closing because it has been with no activity for a long time.
Please, feel free to reopen or comment this issue, whether it's of your interest or you want to contribute on this.
The automatic resending will be improved in the next versions adopting a common pattern for many of the trackers.

authors: AlexBenny BenFradet


text:
Attempting to use both the Java and Android tracker in the same project causes DuplicateClass errors

Describe the bug
I have a library A that uses the java-tracker as a dependency. It's a pure Java project because it needs to be shared with other pure Java projects. That is to say it uses the Gradle java plugin.
I also have an application B that uses the android-tracker as a dependency. This uses the Gradle android-application plugin but otherwise contains a mix of Android libraries and Java libraries.
Both scenarios are valid until you try and use library A in application B as dependency. Gradle then complains that there is a DuplicateClass error.
Duplicate class com.snowplowanalytics. snowplow. tracker. DevicePlatform
found in modules
snowplow-android-tracker- 6. 0. 3. aar -> snowplow-android-tracker- 6. 0. 3- runtime (com.snowplowanalytics: snowplow-android- tracker: 6. 0. 3)
and
snowplow-java-tracker- 2. 1. 0. jar -> snowplow-java-tracker- 2. 1. 0 (com.snowplowanalytics: snowplow- java- tracker: 2. 1. 0)

To Reproduce

Publish a pure Java library that depends on the Snowplow java-tracker to your Maven Local repo.
Configure an Android application to additionally check your Maven Local repo.

repositories {
    mavenLocal()
    ... // Other repos you might need
}

Add to your Android application a dependency on the library that you published in Step 1.
Add to your Android application a dependency on the Snowplow android-tracker.
Build application.

Expected behaviour
The Android application can be successfully compiled with both the java-tracker and the android-tracker side by side.
Additional context
I originally wanted to use the android-tracker as a dependency to the library I am building (library A) but I cannot import an Android .aar into a project that only depends on Java. The usage of Snowplow in Library A is to send events about Library A independently of whatever application Library A may be embedded in - be that Java or Android.
It looks to me that it is only DevicePlatform (in the Java tracker, in the Android tracker) that causes the issue due to the matching namespace and class name.
I really like the android-tracker compared to the java-tracker as I mainly write Kotlin, but there isn't a way for me to build a pure Java SDK that can depend on the android-tracker at the moment and I realise refactoring the android-tracker to separate Android dependencies into another artefact (perhaps two Kotlin written SDKs called snowplow-core and snowplow-android) is a bit much to ask.
As a quick win would you consider renaming DevicePlatform in the java-tracker? Or moving it to a package that won't cause a collision?

Hi @mezpahlan, thank you for raising this! We haven't seen this type of use case before.
I would advise against using both the Java and Android trackers in one project. Mainly because then the events will have different properties – each tracker will have different user and session identifiers (the Java tracker may even be missing those) and context entities. It will be difficult to make sense of these events in the warehouse and join them.
One option to consider would be for the library A to accept a tracking interface that would be implemented in the application B. So for example, you could define an interface in library A that could look like:
interface TrackingInterface {
   void trackScreenView();
    ...
}

Then the application would implement this using the Android tracker and pass an instance to the library to use to track events.
In this setup, the library doesn't need any dependency on the Java or Android trackers.

Thanks @matus-tomlein 🙏

I would advise against using both the Java and Android trackers in one project. Mainly because then the events will have different properties – each tracker will have different user and session identifiers (the Java tracker may even be missing those) and context entities. It will be difficult to make sense of these events in the warehouse and join them.

It might sound odd but this is what we're trying to achieve. Apologies I should have elaborated a bit more in the original post.
We want the java-tracker embedded into Library A to send events that are completely independent of anything that may or may not exist in Application B. To be more precise, we want Library A to send Telemetry style Events about Library A only. So having different user or session identification is acceptable for us in that narrow use case. We wouldn't be looking to join these to anything that Application B might be sending.
An example of this is:

We distribute Library A to multiple teams internally and expect them to update to supported versions in a timely manner (for support and critical bug fix reasons). We want to know what the actual versions of Library A being used in the wild without having to ask multiple teams.
We want to collect timing data for certain functions within the SDK in production so that we can validate our performance assumptions.
We want to understand the usage of Library A's public API with a view to improving it based on actual usage.

None of these Events need to be joined back to the user that might be using Application B.

One option to consider would be for the library A to accept a tracking interface that would be implemented in the application B. So for example, you could define an interface in library A that could look like:

Another question we had was "What if Application B didn't have any Snowplow dependencies? In that scenario we still want our Library A Telemetry Events to be sent via the Snowplow java-tracker that is a dependency of Library A.
I appreciate this is a very niche use case 😅, but what we're looking for is:

Library A can run on both Java and Android projects (implies using only the java-tracker).
Library A can send Events independent of whatever Snowplow infrastructure Application B has or doesn't have.

This works if Application B is another Java application (for example a Spring Boot backend application), or if Application B is an Android application that doesn't yet depend on the android-tracker.

Ah, I see, thanks for the context @mezpahlan!
In that case, I think you're correct in wanting to use both the Java and Android tracker and I don't see other solution than changing the namespace of the DevicePlatform (or the whole Java tracker). Unfortunately that's a breaking change so will need to go in the next major version. That might take a bit longer for us to put together as we prefer to limit the number of major versions.
For the short term, if you are able to fork the repo, change the namespace and build a jar that you can use in your library, that might be a better option.

Totally understandable. Yup, thanks I'll see about forking the repo for the time being.

authors: matus-tomlein mezpahlan

repo: snowplow/snowplow-java-tracker


text:
Error: A device attached to the system is not functioning.

Another weird error message that we received from a website using the snowplow tag. Just to let you know. I don't even have an idea to reproduce that error.
stracktrace says it's happening here:
https://github.com/snowplow/snowplow-javascript-tracker/blob/9db3104548c6e762eba65fd28bd4c3de48bba8a9/src/js/lib/detectors.js#L220
{
  "userAgent": "Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; rv:11.0) like Gecko",
  "userAgentInfo": {
    "browserName": "Internet Explorer",
    "browserVersion": "11.0",
    "engineName": "Trident",
    "engineVersion": "",
    "isBot": false,
    "isMobile": false,
    "os": "Windows 7",
    "platform": "Windows"
  }

Closing as browser-features is now a deprecated plugin and we've never quite managed to reproduce this.

authors: christoph-buente paulboocock

repo: snowplow/snowplow-javascript-tracker


text:
Save System (Old & New) Won't save character last position when saved in the middle of moving/tweening

Describe the bug
Saving a game while the character is in the middle of movements will make the character not appearing after being loaded. I tried this with the default Fungus Save System and The new Save System (cherry picked from related PR)
To Reproduce
Save the game when a character is tweening/moving between stages, then load the game back, the character is missing/not showing on screen.
Expected behavior
Would appear at the right position

I know this is not really a solution to your problem the way you would prefer fixing it, but it might be worth considering working around this issue by disallowing saving while a character is moving, because saving character position the way you have in mind is probably more complicated than its worth.

Hello, thanks for your input. But that's not a feasible solution when the game itself consists lots of tweening (moving characters, characters expression, moving UI elements, etc...)

The new save system (targeting 3.14) doesn't attempt to save positions and does not make any attempt to save tweens. It does save character state though.
Can you give more detail on the repro circumstance so I can add test case for it to the new save system.

I should've clarified that I was using a custom command via LeanTween to make sorta like character expression. For example, when the character is happy, the portrait would jump up and down etc.
And yes those custom commands work under Fungus Stage system, with slight adjustment to it.

authors: TheEmbracedOne breadnone stevehalliwell

repo: snozbot/fungus


text:
Add Socket::recv_with_meta to read loopback status

Wanted to check the transmission confirmation/loopback flag (e.g. the MSG_CONFIRM flag). This required quite a bit of changes, but they might be a nice first step towards getting the timestamps (https://github.com/socketcan-rs/socketcan-rs/issues/22).

Do you agree with the implementation, and think this makes sense? I tried to follow the logic of the commented out read_frame_with_timestamp.
I'm a bit unsure about the usage of socket2::MaybeUninitSlice. Can this be implemented without needing unsafe code? Already implemented this suggestion: https://github.com/rust-lang/socket2/issues/270
Do you want three separate implementations for read_frame_raw (read), read_frame (read) and read_frame_with_meta (recvmsg)? They could share a common implementation and  and throw away the metadata if it's not needed.
Includes fixes from https://github.com/socketcan-rs/socketcan-rs/pull/61 as they were needed for local testing.

@fpagliughi Any thoughts on this?

Apologies, I have been busy with work and cycling through some other open-source projects. The next item that I do want to tackle in this project is timestamps, so this may be timely. But it may take me a week or two before I have time to evaluate this.

@fpagliughi A new socket2 version was released, so this PR is now ready for review.

repo: socketcan-rs/socketcan-rs


text:
TypeError: this.adapter.add is not a function

I'm using socket.io "^1.7.1", and "socket.io-redis": "^6.0.1" when I am doing the following
var io = require('socket.io')(server, {
	pingTimeout: 60000,
	cookie: false,
	handlePreflightRequest: (req, res) => {
		res.writeHead(200, {
			'Access-Control-Allow-Origin': '*',
			'Access-Control-Allow-Methods': 'GET,POST',
			'Access-Control-Allow-Headers': ['authorization', 'sessionId'],
			'Access-Control-Allow-Credentials': true,
		})
		res.end()
	},
})
const redisAdapter = require('socket.io-redis')

io.adapter(redisAdapter({ host: config.server, port: config.port }))

then I am getting this error
 this.adapter.add(this.id, room, function(err){
               ^

TypeError: this.adapter.add is not a function
    at Socket.join (/Users/Desktop/project/node_modules/socket.io/lib/socket.js:242:16)
    at Socket.onconnect (/Users/Desktop/project/node_modules/socket.io/lib/socket.js:295:8)
    at /Users/Desktop/project/node_modules/socket.io/lib/namespace.js:172:16

Any idea what's not write in my code?

@darrachequesne

So, I was doing some reading and it turned out that my socket.io-redis version was not compatible with socket.io. I have updated my socket.io version to 2.4.1 and not this issue is resovled


text:
Support Ruby 2.3

I see that Ruby 2.3 was in the Travis files for async and async-http. Any chance Falcon could also support 2.3 or is there a blocker?

I am planning to drop 2.3 across all gems soon. It's already EOL. What's your use-case?

It turns out we don't need it after all.... Airbnb has a service on which I was going to test Falcon and the service uses 2.3. But I asked the lead maintainer of the service and he's going to upgrade it it to 2.6.

Even thought you closed this issue can you comment on what kind of strategy makes He most sense?

Background: I'm not talking about any one particular company, but I've found it's common for businesses to deprioritize language upgrades, leaving them stuck on older versions unless engineers want to take initiative on their own time to do upgrades. Ruby upgrades are pretty straightforward but Rails upgrades are not, and each version of Rails only supports a limited set of Ruby versions. So if a business has a lot of Rails services, they can easily end up behind. A couple of engineers might take the initiative to upgrade a couple of services, but that still leaves all the other services out.
I understand Ruby core has no responsibility to support such use cases. Nor do gem maintainers. At the same time, if it's low-overhead to keep testing older Ruby versions in Travis for a gem, I don't see any reason not to. It can help some users.

authors: BMorearty ioquatix

repo: socketry/falcon


text:
XS Moto America (motohax)

XS Moto is basically a re-skin of Superbike so it was quite simple to port.
Supports both single race and championship.
Thanks again to AcidSnake!

Tested and working perfectly, thank you!

license: WTFPL


text:
Pair of bugfixes

One noticed by alejandro, one by @znep

socrata-http #115 SUCCESS
This pull request looks good

authors: cloudbees-pull-request-builder rjmac

repo: socrata/socrata-http


text:
Unexpected behavior of some metrics

Describe the bug
During the process of testing each metric to confirm which data type is works with (number, text, date), I encountered some behaviors that were unexpected. Detailed list below.
Also, a few questions about usage:
a. Does the configuration key valid_min_length not apply to min_length metric?
b. Does the configuration key valid_max_length not apply to max_length metric?
c. How does one use the missing_format configuration key? What are the expected values for that key?
d. What does one use valid_min and valid_max for in a text column? (Doesn't valid_min_length and valid_max_length fulfill the valid parameters?
To Reproduce
I was using the Demodata warehouse that is part of the Quick start tutorial so can reproduce all issues using that db. For reference, the schema is:
[{"name": "id", 	"type": "character varying"},
{"name": "name", 	"type": "character varying"},
{"name": "size", 	"type": "integer"},
{"name": "date", 	"type": "date"},
{"name": "feepct", "type": "character varying"},
{"name": "country","type": "character varying"}]}
Context

Why do the tests on the size and date columns pass? Pass by default if no valid_values defined? (The test that fails is accurate.)

columns:
  id:
    valid_format: number_whole
    tests:
      - invalid_count == 0
  size:
    tests:
      - invalid_count == 0
  date:
    tests:
      - invalid_count == 0

  | Test column(id) test(invalid_count == 0) failed with metric values {"invalid_count": 65}
  | Test column(size) test(invalid_count == 0) passed with metric values {"invalid_count": 0}
  | Test column(date) test(invalid_count == 0) passed with metric values {"invalid_count": 0}
  | Executed 2 queries in 0:00:00.034919
  | Scan summary ------
  | 74 measurements computed
  | 3 tests executed
  | 1 of 3 tests failed:
  |   Test column(id) test(invalid_count == 0) failed with metric values {"invalid_count": 65}
  | Exiting with code 1

What is missing_count counting if I have not provided a definition of what qualifies as missing?

columns:
  id:
    tests:
      - missing_count == 0
  size:
    tests:
      - missing_count == 0
  date:
    tests:
      - missing_count == 0

  | Test column(id) test(missing_count == 0) passed with metric values {"missing_count": 0}
  | Test column(size) test(missing_count == 0) passed with metric values {"missing_count": 0}
  | Test column(date) test(missing_count == 0) passed with metric values {"missing_count": 0}
  | Executed 2 queries in 0:00:00.034437
  | Scan summary ------
  | 68 measurements computed
  | 3 tests executed
  | All is good. No tests failed.
  | Exiting with code 0

If I haven't specified a valid_format for the id column (a text column)  shouldn't the test fail?  Shouldn't all three tests fail here?

columns:
  id:
    tests:
      - valid_count > 1
  size:
    tests:
      - valid_count > 1
  date:
    tests:
      - valid_count > 1

  | Test column(id) test(valid_count > 1) passed with metric values {"valid_count": 65}
  | Test column(size) test(valid_count > 1) passed with metric values {"valid_count": 65}
  | Test column(date) test(valid_count > 1) passed with metric values {"valid_count": 65}
  | Executed 2 queries in 0:00:00.041611
  | Scan summary ------
  | 68 measurements computed
  | 3 tests executed
  | All is good. No tests failed.
  | Exiting with code 0

If I haven't specified a valid_values  for the id column (a text column)  shouldn't the test fail?  Shouldn't all three tests fail here?

columns:
  country:
    tests:
      - values_count > 1
  size:
    tests:
      - values_count > 1
  date:
    tests:
      - values_count > 1

  | Test column(size) test(values_count > 1) passed with metric values {"values_count": 65}
  | Test column(date) test(values_count > 1) passed with metric values {"values_count": 65}
  | Test column(country) test(values_count > 1) passed with metric values {"values_count": 65}
  | Executed 2 queries in 0:00:00.043434
  | Scan summary ------
  | 68 measurements computed
  | 3 tests executed
  | All is good. No tests failed.
  | Exiting with code 0

OS: MacOS Big Sur 11.2.3
Python Version: 3.8.8
Soda SQL Version: 2.1.0b2
Warehouse Type: PostgreSQL

a. Does the configuration key valid_min_length not apply to min_length metric?
b. Does the configuration key valid_max_length not apply to max_length metric?

valid_min/max_length are applied to the results and the min_length and max_length are calculated after applying that validity tests.

c. How does one use the missing_format configuration key? What are the expected values for that key?
Missing format can be empty or whitespace. This key specifies how to identify missing values.

d. What does one use valid_min and valid_max for in a text column? (Doesn't valid_min_length and valid_max_length fulfill the valid parameters?
valid_min and valid_max should only be applicable to numeric columns, valid_min/max_length are applicable to text column.

To answer other scenarios by default non-null values are considered to be valid.

authors: janet-can vijaykiran

repo: sodadata/soda-sql