TFDBG 'PyFunc' is not found in partition graphs.

When using tensorflow debugger, the program crashes with the following message :

Traceback (most recent call last):
File "farn_train.py", line 470, in
train()
File "farn_train.py", line 448, in train
_, loss_value = sess.run([train_op, loss])
File "/home/qiqi/anaconda2/lib/python2.7/site-packages/tensorflow/python/debug/wrappers/framework.py", line 470, in run
run_end_resp = self.on_run_end(run_end_req)
File "/home/qiqi/anaconda2/lib/python2.7/site-packages/tensorflow/python/debug/wrappers/local_cli_wrapper.py", line 275, in on_run_end
self._dump_root, partition_graphs=partition_graphs)
File "/home/qiqi/anaconda2/lib/python2.7/site-packages/tensorflow/python/debug/lib/debug_data.py", line 524, in init
self._load_partition_graphs(partition_graphs, validate)
File "/home/qiqi/anaconda2/lib/python2.7/site-packages/tensorflow/python/debug/lib/debug_data.py", line 782, in _load_partition_graphs
self._validate_dump_with_graphs()
File "/home/qiqi/anaconda2/lib/python2.7/site-packages/tensorflow/python/debug/lib/debug_data.py", line 928, in _validate_dump_with_graphs
datum.node_name)
ValueError: Node name 'PyFunc' is not found in partition graphs.

Environment info
Operating System:
Ubuntu 14.04
Installed version of CUDA and cuDNN:
(please attach the output of ls -l /path/to/cuda/lib/libcud*):

rw-r--r-- 1 root root   560184 10月 31 11:03 /usr/local/cuda/lib64/libcudadevrt.a
lrwxrwxrwx 1 root root       16 10月 31 11:03 /usr/local/cuda/lib64/libcudart.so -> libcudart.so.8.0
lrwxrwxrwx 1 root root       19 10月 31 11:03 /usr/local/cuda/lib64/libcudart.so.8.0 -> libcudart.so.8.0.27
-rwxr-xr-x 1 root root   394472 10月 31 11:03 /usr/local/cuda/lib64/libcudart.so.8.0.27
-rw-r--r-- 1 root root   737516 10月 31 11:03 /usr/local/cuda/lib64/libcudart_static.a
-rwxr-xr-x 1 root root 79337624 11月  5 08:55 /usr/local/cuda/lib64/libcudnn.so
-rwxr-xr-x 1 root root 79337624 11月  5 08:55 /usr/local/cuda/lib64/libcudnn.so.5
-rwxr-xr-x 1 root root 79337624 11月  5 08:55 /usr/local/cuda/lib64/libcudnn.so.5.1.5
-rw-r--r-- 1 root root 69756172 11月  5 08:55 /usr/local/cuda/lib64/libcudnn_static.a

If installed from binary pip package, provide:

A link to the pip package you installed:
https://ci.tensorflow.org/view/Nightly/job/nightly-matrix-linux-gpu/TF_BUILD_IS_OPT=OPT,TF_BUILD_IS_PIP=PIP,TF_BUILD_PYTHON_VERSION=PYTHON2,label=gpu-linux/lastSuccessfulBuild/artifact/pip_test/whl/tensorflow_gpu-1.0.1-cp27-none-linux_x86_64.whl

The output from python -c "import tensorflow; print(tensorflow.__version__)".
'1.0.1'

@hqqxyy It would be most helpful if you could provide a code to reproduce this issue. Thanks.

@caisq
Hi, I try to reproduce this issue in the mnist example. It also wrong in line 928 of debug_data.py. But it is wrong with

ValueError: Node name 'accuracy/correct_prediction/ArgMax/dimension' is not found in partition graphs.

My code is as follows, I only change the mnist example's data_reader with
# Copyright 2016 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# ==============================================================================
"""Demo of the tfdbg curses CLI: Locating the source of bad numerical values.

The neural network in this demo is larged based on the tutorial at:
  tensorflow/examples/tutorials/mnist/mnist_with_summaries.py

But modifications are made so that problematic numerical values (infs and nans)
appear in nodes of the graph during training.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function

import argparse
import sys
import numpy as np

import tensorflow as tf

from tensorflow.examples.tutorials.mnist import input_data
from tensorflow.python import debug as tf_debug

IMAGE_SIZE = 28
HIDDEN_SIZE = 500
NUM_LABELS = 10
RAND_SEED = 42

def test_pyfunc(x):
    return x

def main(_):
    # Import data

    with tf.Graph().as_default():
        mnist = input_data.read_data_sets(FLAGS.data_dir,
                                          one_hot=True,
                                          fake_data=FLAGS.fake_data)

        # def feed_dict(train):
        #   if train or FLAGS.fake_data:
        #     xs, ys = mnist.train.next_batch(FLAGS.train_batch_size,
        #                                     fake_data=FLAGS.fake_data)
        #   else:
        #     xs, ys = mnist.test.images, mnist.test.labels
        #
        #   return {x: xs, y_: ys}

        images, labels = mnist.train.images, mnist.train.labels

        def get_image_label():
            ind = np.random.randint(len(images))
            return images[ind].astype(np.float32), labels[ind].astype(np.float32)

        image_tensor, label_tensor, = tf.py_func(get_image_label, [], [tf.float32, tf.float32])
        image_tensor.set_shape((IMAGE_SIZE ** 2, ))
        label_tensor.set_shape((NUM_LABELS, ))

        x, y_ = tf.train.batch([image_tensor, label_tensor],
                               batch_size=FLAGS.train_batch_size,
                               num_threads=2)

        # Create the MNIST neural network graph.

        # # Input placeholders.
        # with tf.name_scope("input"):
        #   x = tf.placeholder(
        #       tf.float32, [None, IMAGE_SIZE * IMAGE_SIZE], name="x-input")
        #   y_ = tf.placeholder(tf.float32, [None, NUM_LABELS], name="y-input")

        def weight_variable(shape):
            """Create a weight variable with appropriate initialization."""
            initial = tf.truncated_normal(shape, stddev=0.1, seed=RAND_SEED)
            return tf.Variable(initial)

        def bias_variable(shape):
            """Create a bias variable with appropriate initialization."""
            initial = tf.constant(0.1, shape=shape)
            return tf.Variable(initial)

        def nn_layer(input_tensor, input_dim, output_dim, layer_name, act=tf.nn.relu):
            """Reusable code for making a simple neural net layer."""
            # Adding a name scope ensures logical grouping of the layers in the graph.
            with tf.name_scope(layer_name):
                # This Variable will hold the state of the weights for the layer
                with tf.name_scope("weights"):
                    weights = weight_variable([input_dim, output_dim])
                with tf.name_scope("biases"):
                    biases = bias_variable([output_dim])
                with tf.name_scope("Wx_plus_b"):
                    preactivate = tf.matmul(input_tensor, weights) + biases

                activations = act(preactivate)
                return activations

        hidden = nn_layer(x, IMAGE_SIZE**2, HIDDEN_SIZE, "hidden")
        y = nn_layer(hidden, HIDDEN_SIZE, NUM_LABELS, "softmax", act=tf.nn.softmax)

        with tf.name_scope("cross_entropy"):
            # The following line is the culprit of the bad numerical values that appear
            # during training of this graph. Log of zero gives inf, which is first seen
            # in the intermediate tensor "cross_entropy/Log:0" during the 4th run()
            # call. A multiplication of the inf values with zeros leads to nans,
            # which is first in "cross_entropy/mul:0".
            #
            # You can use clipping to fix this issue, e.g.,
            #   diff = y_ * tf.log(tf.clip_by_value(y, 1e-8, 1.0))

            diff = y_ * tf.log(y)
            with tf.name_scope("total"):
                cross_entropy = -tf.reduce_mean(diff)

        with tf.name_scope("train"):
            train_step = tf.train.AdamOptimizer(FLAGS.learning_rate).minimize(
                cross_entropy)

        with tf.name_scope("accuracy"):
            with tf.name_scope("correct_prediction"):
                correct_prediction = tf.equal(tf.argmax(y, 1), tf.argmax(y_, 1))
            with tf.name_scope("accuracy"):
                accuracy = tf.reduce_mean(tf.cast(correct_prediction, tf.float32))

        sess = tf.Session(config=tf.ConfigProto(
            allow_soft_placement=True))
        sess.run(tf.global_variables_initializer())

        if FLAGS.debug:
            sess = tf_debug.LocalCLIDebugWrapperSession(sess, ui_type=FLAGS.ui_type)
            sess.add_tensor_filter("has_inf_or_nan", tf_debug.has_inf_or_nan)

        tf.train.start_queue_runners(sess=sess)

        # Add this point, sess is a debug wrapper around the actual Session if
        # FLAGS.debug is true. In that case, calling run() will launch the CLI.
        for i in range(FLAGS.max_steps):
            acc = sess.run(accuracy)
            print("Accuracy at step %d: %s" % (i, acc))

            sess.run(train_step)

if __name__ == "__main__":
    parser = argparse.ArgumentParser()
    parser.register("type", "bool", lambda v: v.lower() == "true")
    parser.add_argument(
        "--max_steps",
        type=int,
        default=10,
        help="Number of steps to run trainer.")
    parser.add_argument(
        "--train_batch_size",
        type=int,
        default=100,
        help="Batch size used during training.")
    parser.add_argument(
        "--learning_rate",
        type=float,
        default=0.025,
        help="Initial learning rate.")
    parser.add_argument(
        "--data_dir",
        type=str,
        default="/tmp/mnist_data",
        help="Directory for storing data")
    parser.add_argument(
        "--ui_type",
        type=str,
        default="curses",
        help="Command-line user interface type (curses | readline)")
    parser.add_argument(
        "--fake_data",
        type="bool",
        nargs="?",
        const=True,
        default=False,
        help="Use fake MNIST data for unit testing")
    parser.add_argument(
        "--debug",
        type="bool",
        nargs="?",
        const=True,
        default=False,
        help="Use debugger to track down bad values during training")
    FLAGS, unparsed = parser.parse_known_args()
    tf.app.run(main=main, argv=[sys.argv[0]] + unparsed)

@hqqxyy , the reason for the weirdness you are seeing is because your session is used in a multi-threaded way, which is not amenable to command-line interface debugging. Particularly, you do,
tf.train.start_queue_runners(sess=sess)

after you wrap sess with LocalCLIDebugWrapperSession.
So the program will try to launch the debugger CLI from at least 3 threads (two for your queue runner and one for your main thread that runs the train_step op.
To workaround this problem, you can call start_queue_runners first, and then wrap the sess, e.g.,
tf.train.start_queue_runners(sess=sess)

if FLAGS.debug:
    sess = tf_debug.LocalCLIDebugWrapperSession(sess, ui_type=FLAGS.ui_type)
    sess.add_tensor_filter("has_inf_or_nan", tf_debug.has_inf_or_nan)

This will let the debugger CLI run only on the main (training) thread. This solution assumes that you don't want to debug the data queue threads. If that is the case, let me know and I can provide more info.
I'll let this bug open for now to remind myself to provide better documentation for this sort of issues.

Update: LocalCLIDebugWrapperSesion now has a new keyword argument that allows you to make the debugger CLI active only on selected threads. It is called thread_name_filter. For more details, please see doc at:
https://github.com/tensorflow/tensorflow/commit/eb6d9d9685c0a4be542522acf5cb3f6226a7858a#diff-1c3529a3243c362193b85b6689aa24d3
This is not available in 1.1, but will be in 1.2.

Hi,
I have a similar issue as what posted above by hqqxyy when running "tfdbg> run" to debug the issue that my code returns the value of training loss as NAN. I applied the change suggested by caisq on Mar 30 above and also I tried upgrading the version of tensorflow on my system to 1.2 to apply the "thread_name_filter" property. But still I am getting the error in the following box. I will appreciate more advice and thoughts on this error.
tfdbg> run
---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
<ipython-input-1-97d74d26c4b1> in <module>()
    166     cross_entropy, summary_string, _ = sess.run([ cross_entropy_sum,
    167                                                   merged_summary_op,
--> 168                                                   train_step ])
    169
    170     print("Current loss: " + str(cross_entropy))

C:\Users\mnematol\Anaconda3\lib\site-packages\tensorflow\python\debug\wrappers\framework.py in run(self, fetches, feed_dict, options, run_metadata)
    493
    494     # Invoke on-run-end callback and obtain response.
--> 495     run_end_resp = self.on_run_end(run_end_req)
    496     _check_type(run_end_resp, OnRunEndResponse)
    497     # Currently run_end_resp is only a placeholder. No action is taken on it.

C:\Users\mnematol\Anaconda3\lib\site-packages\tensorflow\python\debug\wrappers\local_cli_wrapper.py in on_run_end(self, request)
    310
    311       debug_dump = debug_data.DebugDumpDir(
--> 312           self._dump_root, partition_graphs=partition_graphs)
    313       debug_dump.set_python_graph(self._sess.graph)
    314

C:\Users\mnematol\Anaconda3\lib\site-packages\tensorflow\python\debug\lib\debug_data.py in __init__(self, dump_root, partition_graphs, validate)
    549     self._load_dumps(dump_root)
    550     self._create_tensor_watch_maps()
--> 551     self._load_partition_graphs(partition_graphs, validate)
    552
    553     self._python_graph = None

C:\Users\mnematol\Anaconda3\lib\site-packages\tensorflow\python\debug\lib\debug_data.py in _load_partition_graphs(self, partition_graphs, validate)
    807
    808     if validate:
--> 809       self._validate_dump_with_graphs()
    810
    811   def _process_partition_graph_node(self, node):

C:\Users\mnematol\Anaconda3\lib\site-packages\tensorflow\python\debug\lib\debug_data.py in _validate_dump_with_graphs(self)
    953       if datum.node_name not in self._node_inputs:
    954         raise ValueError("Node name '%s' is not found in partition graphs." %
--> 955                          datum.node_name)
    956
    957     pending_inputs = {}

ValueError: Node name 'adam_vars/gradients/fcn_32s/while_23/Mul_grad/mul/f_acc' is not found in partition graphs.

I am running my code on Windows 7 using cpu device. I installed tensorflow with Anaconda. And the output of tf.__version__ on my system is '1.2.1'. The actual training and debugging code are as following:
%matplotlib inline

import tensorflow as tf
from tensorflow.python import debug as tf_debug

import numpy as np
import skimage.io as io
import os, sys
from matplotlib import pyplot as plt

# Use second GPU -- change if you want to use a first one
os.environ["CUDA_VISIBLE_DEVICES"] = '1'

# Add a path to a custom fork of TF-Slim
# Get it from here:
# https://github.com/warmspringwinds/models/tree/fully_conv_vgg
sys.path.append("C:\\Users\\mnematol\\Documents\\Python Scripts\\tensorflow_notes-master\\models-master\\slim")

# Add path to the cloned library
sys.path.append("C:\\Users\\mnematol\\Documents\\Python Scripts\\tensorflow_notes-master\\tf-image-segmentation-master")

checkpoints_dir = 'C:\\Users\\mnematol\\Documents\\Python Scripts\\tensorflow_notes-master\\data\\vgg_16'
log_folder = 'C:\\Users\\mnematol\\Documents\\Python Scripts\\tensorflow_notes-master\\log_folder'

slim = tf.contrib.slim
vgg_checkpoint_path = os.path.join(checkpoints_dir, 'vgg_16.ckpt')

from tf_image_segmentation.utils.tf_records import read_tfrecord_and_decode_into_image_annotation_pair_tensors
from tf_image_segmentation.models.fcn_32s import FCN_32s_GGM, extract_vgg_16_mapping_without_fc8, General_mixture

from tf_image_segmentation.utils.sbd import pascal_segmentation_lut

from tf_image_segmentation.utils.training import get_valid_logits_and_labels

from tf_image_segmentation.utils.augmentation import (distort_randomly_image_color,
                                                      flip_randomly_left_right_image_with_annotation,
                                                      scale_randomly_image_with_annotation_with_fixed_size_output)

image_train_size = [384, 384]#[240, 320]
# IMAGE_HEIGHT = 240
# IMAGE_WIDTH = 320
number_of_classes = 8 # 21
number_of_mixtures = 2;
num_param_set={'GM': 3, 'LM': 3, 'GGM': 4} # pi, mu, stdev, 4 if beta
MIXTURE = 'GGM'
mixture_fn = General_mixture

tfrecord_filename = 'C:\\Users\\mnematol\\Documents\\Python Scripts\\tensorflow_notes-master\\SBD_segmentation_Train.tfrecords' # pascal_augmented_train.tfrecords'
pascal_voc_lut = pascal_segmentation_lut()
class_labels = list(pascal_voc_lut.keys())

filename_queue = tf.train.string_input_producer([tfrecord_filename], num_epochs=10)

image, annotation = read_tfrecord_and_decode_into_image_annotation_pair_tensors(filename_queue)

# Various data augmentation stages
image, annotation = flip_randomly_left_right_image_with_annotation(image, annotation)

# image = distort_randomly_image_color(image)

resized_image, resized_annotation = scale_randomly_image_with_annotation_with_fixed_size_output(image, annotation, image_train_size)

resized_annotation = tf.squeeze(resized_annotation)

image_batch, annotation_batch = tf.train.shuffle_batch([resized_image, resized_annotation],
                                             batch_size=1,
                                             capacity=3000,
                                             num_threads=2,
                                             min_after_dequeue=1000)

upsampled_logits_batch, vgg_16_variables_mapping = FCN_32s_GGM(image_batch_tensor=image_batch,
                                                               mixture_fn=mixture_fn,
                                                               number_of_mixtures=number_of_mixtures,
                                                               num_param_sets=num_param_set[MIXTURE],
                                                               number_of_classes=number_of_classes,
                                                               is_training=True)

# Reshapes annotations and logits to shape (#all_valid_samples,#classes)
valid_labels_batch_tensor, valid_logits_batch_tensor = get_valid_logits_and_labels(annotation_batch_tensor=annotation_batch,
                                                                                logits_batch_tensor=upsampled_logits_batch,
                                                                                class_labels=class_labels)

cross_entropies = tf.nn.softmax_cross_entropy_with_logits(logits=valid_logits_batch_tensor,
                                                          labels=valid_labels_batch_tensor)

# Normalize the cross entropy -- the number of elements
# is different during each step due to mask out regions
cross_entropy_sum = tf.reduce_mean(cross_entropies)

pred = tf.argmax(upsampled_logits_batch, dimension=3)

probabilities = tf.nn.softmax(upsampled_logits_batch)

with tf.variable_scope("adam_vars"):
    train_step = tf.train.AdamOptimizer(learning_rate=0.000001).minimize(cross_entropy_sum)

# Variable's initialization functions
vgg_16_without_fc8_variables_mapping = extract_vgg_16_mapping_without_fc8(vgg_16_variables_mapping)

init_fn = slim.assign_from_checkpoint_fn(model_path=vgg_checkpoint_path,
                                         var_list=vgg_16_without_fc8_variables_mapping)

global_vars_init_op = tf.global_variables_initializer()

tf.summary.scalar('cross_entropy_loss', cross_entropy_sum)

merged_summary_op = tf.summary.merge_all()

summary_string_writer = tf.summary.FileWriter(log_folder)

# Create the log folder if doesn't exist yet
if not os.path.exists(log_folder):
     os.makedirs(log_folder)

#The op for initializing the variables.
local_vars_init_op = tf.local_variables_initializer()

combined_op = tf.group(local_vars_init_op, global_vars_init_op)

# We need this to save only model variables and omit
# optimization-related and other variables.
model_variables = slim.get_model_variables()
saver = tf.train.Saver(model_variables)

#with tf.Session()  as sess:
sess = tf.Session()
sess.run(combined_op)
init_fn(sess)

#coord = tf.train.Coordinator()
#threads = tf.train.start_queue_runners(coord=coord)
tf.train.start_queue_runners(sess=sess)

#sess = tf_debug.LocalCLIDebugWrapperSession(sess)
sess = tf_debug.LocalCLIDebugWrapperSession(sess, thread_name_filter="MainThread$")
sess.add_tensor_filter("has_inf_or_nan", tf_debug.has_inf_or_nan)

# 10 epochs
for i in range(572 * 10): # (11127 * 10)

    cross_entropy, summary_string, _ = sess.run([ cross_entropy_sum,
                                                  merged_summary_op,
                                                  train_step ])

    print("Current loss: " + str(cross_entropy))

    summary_string_writer.add_summary(summary_string, i)

    if i % 572 == 0:
        save_path = saver.save(sess, "C:\\Users\\mnematol\\Documents\\Python Scripts\\tensorflow_notes-master\\tf-image-segmentation-master\\tf_image_segmentation\\model_fcn32s_M.ckpt")
        print("Model saved in file: %s" % save_path)

#coord.request_stop()
#coord.join(threads)

save_path = saver.save(sess, "C:\\Users\\mnematol\\Documents\\Python Scripts\\tensorflow_notes-master\\tf-image-segmentation-master\\tf_image_segmentation\\model_fcn32s_M.ckpt")
print("Model saved in file: %s" % save_path)

summary_string_writer.close()

I have to add that inside the function "FCN_32s_GGM" in the above code I am calling the following function which is my implementation of the generalized gaussian distribution. I believe the source of NAN values are inside the following function.
def general_Gaussian(net , pi, sigma, mu, beta):

    # net: Tensor("fcn_32s/vgg_16/dropout7/dropout/mul:0", shape=(1, 12, 12, 4096), dtype=float32)
    # pi: Tensor("fcn_32s/Gather_2:0", shape=(1, 12, 12, 4096), dtype=float32)
    # sigma: Tensor("fcn_32s/Gather_3:0", shape=(1, 12, 12, 4096), dtype=float32)
    # mu: Tensor("fcn_32s/Gather_4:0", shape=(1, 12, 12, 4096), dtype=float32)
    # beta: Tensor("fcn_32s/Gather_4:0", shape=(1, 12, 12, 4096), dtype=float32)

    sigma_INV = tf.reciprocal(sigma)

    beta_INV = tf.reciprocal(beta)
    gamma3_beta = tf.exp(tf.lgamma(3*beta_INV))
    gamma1_beta = tf.exp(tf.lgamma(1*beta_INV))
    gamma1_beta_INV = tf.reciprocal(gamma1_beta)

    gamma3_gamma1 = tf.multiply(gamma3_beta,gamma1_beta_INV)
    # lgamma Computes the log of the absolute value of Gamma(x) element-wise.
    # for x>0, Gamma(x) is positive so -> [absolute value of Gamma(x)]=Gamma(x)
    # however to resolve the log in tf.lgamma, we add tf.exp

    # compute the factor coeffiecient
    factor = tf.sqrt(gamma3_gamma1)
    factor = tf.multiply(factor,beta)
    factor = tf.multiply(factor,gamma1_beta_INV)
    factor = 0.5*tf.multiply(factor,sigma_INV)

    # compute general_Gaussian
    result = tf.subtract(net,mu)
    result = tf.abs(result) + 1e-10
    result = tf.multiply(result,sigma_INV)
    result = -tf.pow(result,beta)
    result = tf.multiply(result,tf.pow(gamma3_gamma1,0.5*beta))
    result = tf.exp(result)

    result = tf.multiply(result,factor)

    result = tf.multiply(result,pi)

    return result


Inline answer don't show up

I am running InlineQueryResult sample but with InlineQueryResultPhoto instead of article as shown elow:
articles = [InlineQueryResultPhoto(id='123',
    photo_url='http://www.html5rocks.com/en/tutorials/speed/img-compression/len_std.jpg',
    thumb_url='http://www.html5rocks.com/en/tutorials/speed/img-compression/len_std.jpg')
]

I've had import InlineQueryResultPhoto from telepot.namedtuple with:
from telepot.namedtuple import *

But when I test it on Telegram Desktop or mobile versions, I can't see the query answers.

Desktop view.

On Android version.
Console show this error after timeout is finish:
$ python inline_sample.py <token>
(49873, ':', 'Inline Query:', u'214204250116192', 49873, u'')
ERROR:root:on_close() called due to WaitTooLong:

Image is:

Any idea how can I solved my problem.

Put in photo_width and photo_height. That should solve the problem.
articles = [InlineQueryResultPhoto(id='123',
    photo_url='http://www.html5rocks.com/en/tutorials/speed/img-compression/len_std.jpg',
    thumb_url='http://www.html5rocks.com/en/tutorials/speed/img-compression/len_std.jpg',
    photo_width=256, photo_height=256)
]

My experience is, the width and height don't have to be accurate. They are for the purpose of displaying the results. As long as the two numbers are of the correct proportion, they should be fine. For example, this is good too:
articles = [InlineQueryResultPhoto(id='123',
    photo_url='http://www.html5rocks.com/en/tutorials/speed/img-compression/len_std.jpg',
    thumb_url='http://www.html5rocks.com/en/tutorials/speed/img-compression/len_std.jpg',
    photo_width=1, photo_height=1)
]

Thanks, that works for me. :smile:


Request charge information missing for item queries?

Is your feature request related to a problem? Please describe.
Yes, just being able to get a sense of request charges for different queries.
Describe the solution you'd like
The CosmosQueryResponse<T> type does not inherit from CosmosResponse<T>, so it is missing details like request charge. This is crucial for logging and understanding query costs.
Describe alternatives you've considered
I know of none.

In addition, item queries are not routed through registered CosmosRequestHandler instances.
This seems like a big deal to me...am I missing something?

+1 for supporting this feature. Thank you,

Fixed in PR


Error in DSACLS command

Command below generates error:
PS C:\Users\Administrator> dsacls "CN=AdminSDHolder,CN=System,DC=contoso,DC=com" /g "Contoso\Key Admins":RPWP;msDS-KeyCredentialLink
The parameter is incorrect.
The command failed to complete successfully.
msDS-KeyCredentialLink : The term 'msDS-KeyCredentialLink' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:84

... C=contoso,DC=com" /g "Contoso\Key Admins":RPWP;msDS-KeyCredentialLink

                                               ~~~~~~~~~~~~~~~~~~~~~~

CategoryInfo          : ObjectNotFound: (msDS-KeyCredentialLink:String) [], CommandNotFoundException
FullyQualifiedErrorId : CommandNotFoundException

There is no msDSKey-CredentialLink property for AdminSDHolder object...

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

ID: f50a8599-301a-5993-1a86-e722f66ffcf2
Version Independent ID: fffd0fc9-97f6-cfa9-70fb-7f1308804de0
Content: Dual Enrollment - Windows security
Content Source: windows/security/identity-protection/hello-for-business/hello-feature-dual-enrollment.md
Product: m365-security
GitHub Login: @mapalko
Microsoft Alias: mapalko

Command doesn't work in PowerShell, but works in CMD.


Remove explicit dependency on mcap libs in CLI

Perhaps if we do this, go.work will be respected by go install.

I determined that this does not work. We have since addressed the issue by documenting go install not supported.


add OS X support to open terminal here

I don't have a windows machine to test. :(

got no way of testing the windows solution
#lang racket/base
(require racket/system
         racket/path
         quickscript)

(script-help-string "Open a terminal in the current directory.")

(define-script open-terminal
  #:label "Open terminal"
  #:menu-path ("&Utils")
  #:os-types (unix macosx)
  #:output-to message-box

  (case (system-type 'os)
    [(unix) (λ (str #:file f)
              (define dir (path->string (path-only f)))
              (system (string-append "gnome-terminal"
                                     " --working-directory=\"" dir "\""
                                     " -t \"" dir "\""
                                     "&"))
              #f)]
    [(macosx) (λ (str #:file f)
                (define dir (path->string (path-only f)))
                (define osascriptdir (string-append
                                      (path->string (find-system-path 'pref-dir))
                                      "quickscript/user-scripts/"))
                (system (string-append "osascript -e 'tell app \"Terminal\" to do script \"cd \\\"" dir "\\\"\"'" ))
                #f)]
    ;[(windows) (system (string-append "cmd /c start cmd.exe /K \"cd " dir))]
    ))

forgot to run the script

Can you update the help string to say "(linux and macosx only)" ?

make-readme.sh done and added to pr

hold on - bert is helping

Thank you @bdeket for doing windows code

Great, thanks a lot Stephen!


pose estimation

please also update the readme in spot-sim2real to give pointer about how to use pose estimation
Have an assert that now we only support a specific mesh

the issue when intel camera fails
Traceback (most recent call last):
File "/home/jmmy/research/spot-sim2real/spot_rl_experiments/experiments/skill_test/test_semantic_gaze.py", line 15, in
spotskillmanager.pick(
File "/home/jmmy/research/spot-sim2real/spot_rl_experiments/spot_rl/envs/skill_manager.py", line 361, in pick
status, message = self.gaze_controller.execute(goal_dict=goal_dict)
File "/home/jmmy/research/spot-sim2real/spot_rl_experiments/spot_rl/skills/atomic_skills.py", line 197, in execute
status, message = self.execute_rl_loop(goal_dict=goal_dict)
File "/home/jmmy/research/spot-sim2real/spot_rl_experiments/spot_rl/skills/atomic_skills.py", line 156, in execute_rl_loop
observations, _, done, _ = self.env.step(action_dict=action_dict)  # type: ignore
File "/home/jmmy/research/spot-sim2real/spot_rl_experiments/spot_rl/envs/gaze_env.py", line 75, in step
observations, reward, done, info = super().step(
File "/home/jmmy/research/spot-sim2real/spot_rl_experiments/spot_rl/envs/base_env.py", line 316, in step
success = self.attempt_grasp(
File "/home/jmmy/research/spot-sim2real/spot_rl_experiments/spot_rl/envs/base_env.py", line 484, in attempt_grasp
obj_bbox = detect_with_rospy_subscriber(object_name, image_scale)
File "/home/jmmy/research/spot-sim2real/spot_rl_experiments/spot_rl/utils/rospy_light_detection.py", line 38, in detect_with_rospy_subscriber
prediction = [int(float(num) / image_scale) for num in bbox_str]
UnboundLocalError: local variable 'bbox_str' referenced before assignment

change the default to penguin?

the main concerning point is the arm is not reset after calling the pick, we will discuss this later :)


Issue to get LB working - doc for Kubernetes deployment examples/staging/selenium/

Hi,
Trying to follow the Kubernetes tutorial at https://github.com/kubernetes/examples/tree/master/staging/selenium#kubernetes-nodes-reachable.
Everything is working not so bad excepting the part on the LB and GKE. When I run the command it creates the LB but impossible to reach it through the IP:port mentioned by it.
The only solution I found is to create an Ingress on top of the Node Port "selenium-hub" but it forces me to use the 80 port (or 443).
Can you help me on this? Overall is there a way to open a port directly to a pod and reach it from outside? Without LB for instance? Thx

Nvm it was a network issue on my side...


[20495] Set mirror to 3.3.x

This pr updates mirror workflow to 3.3.x

CI workflows do not apply in this PR. CI cancelled.


Updated current status

Affected headers
(1)Friendly Dates in File Explorer (Build 18305)
Thank you for all of the feedback you provided on Friendly Dates in File Explorer. At this time, we’ve decided not to roll out Friendly Dates to users as part of the 19H1 release.
(2)Re-releasing the new Japanese IME (Build 18305)
Thank you everyone who provided feedback about the new Japanese IME. We’ve decided to take some time to continue refining this experience, so that it ships with the highest possible quality, so it will not be included with 19H1, but has been reactivated for Insiders to explore in the 20H1 builds.
(3)Updated Settings Homepage (Build 18305)
At this time the updated design is only available for Home and non-domain-joined Pro edition PCs. It’s currently in the process of rolling out to those editions – we will update this message once it’s live for everyone.

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

@nenonix @JohanFreelancer9 - kindly do the copy editor review for this PR. Thanks.

@jessyrod68 - we need your kind assistance to merge the new commit for the copy/edit review made by JohanFreelancer9 / nenonix or make the necessary changes on the PR following the suggestions made.
Thank you.

@mypil Commited

@lizap - Can you please assist to check, approve and merge the content of this PR?
Thank you.

@mypil Hi Joyce, is this still being worked on? Not seeing any changed content on the live end?
https://docs.microsoft.com/en-us/windows-insider/at-home/whats-new-wip-at-home-19h1

@jessyrod68 - the PR content has not been merged yet as we are waiting for the doc owner @lizap to review, approve and merge the content for it to be reflected in the document.
@lizap - We would like to follow up.  Can you please assist to check, approve and merge the content of this PR?
Thank you.

@lizap @AndreaBarr - Would you be able to merge the content of this PR?
cc: @dougkim

@mypil  Hi there,
I am not seeing the updates live. Did I forget to do something?

@AndreaBarr @lizap - Can you please check why the changes are not yet reflected in the live content?
Is there a need to do a manual sync from public to private?
Hope you can help with this. Thank you.

It can take up to 72 hours for the changes to reflect in the live content. It all depends on how quickly the survers update to the live content.

@mypil @AndreaBarr , 72 hours from when the ticket is closed? If so, I believe it closed almost 15 days ago? I haven't seen any activity on this for awhile so I assumed it would be live which is why I asked.

@jessyrod68 - I believe the live content is already updated to reflect the changes you made on this PR. I guess it just took some time for everything to sync. Thank you.


Add python

https://github.com/aquaproj/aqua-registry/issues/858
https://github.com/danhper/asdf-python
https://www.python.org/

Hi, thank you for your suggestion.
I didn't know that project.
I'll take a look.

https://github.com/indygreg/python-build-standalone/releases/tag/20240726
Hmm. Each release has assets for multiple Python versions (3.10.14, 3.11.9, etc).
aqua can't specify the Python version for now.
e.g.
- name: indygreg/python-build-standalone@20240726 # Can't specify python version

My idea is to enable aqua to specify parameters.
e.g.
- name: indygreg/python-build-standalone@20240726
  with:
    python_version: "3.10.14"

It seems rye indexes the releases to know which version it can download from which release.
Each release has to currently maintained version and its latest patch available.
So when updating the release the 'python_version' should also be checked to see if it needs to be updated.
https://github.com/astral-sh/rye/blob/main/rye-devtools/src/rye_devtools/find_downloads.py

Related:

Support Node.js (Dynamic $PATH manipulation): https://github.com/aquaproj/aqua/issues/2996#issuecomment-2303635157

Dynamic $PATH mamipulation is required to enable us to execute tools installed by pip

Support parameters: https://github.com/aquaproj/aqua/pull/3052

📝 After we support parameters, https://github.com/aquaproj/aqua/pull/3052
to update parameters such as python_version by aqua update command, we need additional implementation.
I'm not sure if we will address it.
We would add the setting updating python_version  to aqua-renovate-config.

Maybe you should look into https://github.com/jdx/mise. To me mise is to specify Node, Phyton, Java versions - so languages coming with an own dependency management and Aqua for single binary tools. I see aqua as version manager, I don't see that I could also put configuration next to the version E.g. for python https://mise.jdx.dev/lang/python.html

@mab I currently use mise and it is sometimes flaky to get new developers to pick it up. Because its based on ASDF plugins it is hard to add new tools. And some plugins are a bit brittle. Like checkov needed jq installed to work.
To me aqua seems simpler since it only downloads binaries and better on the front of security and managing the 'registry'.
Ideally mise would use the aqua repository by default and have several special install scripts baked in for python, java, ruby and others where it isn't trivial to install these tools.

WIP

https://github.com/aquaproj/aqua-registry/pull/26154
PIP_TARGET: https://github.com/aquaproj/aqua/issues/2996#issuecomment-2304493676

export PIP_TARGET=$(aqua root-dir)/pip-global # location where pip installs tools
export PATH=$PIP_TARGET/bin:$PATH
export PYTHONPATH=$PIP_TARGET # Without this setting, tools installed by pip didn't work

pip install mkdocs
mkdocs -V

I found an issue that even if I change the Python version, seems like mkdocs -V refers to old Python.

Install mkdocs with Python 3.11.9
Change the Python version to 3.10.14
Run mkdocs -V, then it outputs Python 3.11

$ mkdocs -V
mkdocs, version 1.6.0 from /Users/shunsukesuzuki/.local/share/aquaproj-aqua/pip-global/mkdocs (Python 3.11)

I'm not familiar with Python, but Python creates cache *.pyc.
$ ls -lh /Users/shunsukesuzuki/.local/share/aquaproj-aqua/pip-global/mkdocs/__pycache__
total 84K
-rw-r--r-- 1 shunsukesuzuki staff  237  8 23 09:02 __init__.cpython-311.pyc
-rw-r--r-- 1 shunsukesuzuki staff  20K  8 23 09:02 __main__.cpython-311.pyc
-rw-r--r-- 1 shunsukesuzuki staff 2.4K  8 23 09:02 exceptions.cpython-311.pyc
-rw-r--r-- 1 shunsukesuzuki staff 4.7K  8 23 09:02 localization.cpython-311.pyc
-rw-r--r-- 1 shunsukesuzuki staff  35K  8 23 09:02 plugins.cpython-311.pyc
-rw-r--r-- 1 shunsukesuzuki staff 8.8K  8 23 09:02 theme.cpython-311.pyc

I found an issue that even if I change the Python version, seems like mkdocs -V refers to old Python.

This is a bit confusing, but doesn't so matter.

📝 This isn't official but aqua can get the list of Python versions from this repository.
https://github.com/containerbase/python-prebuild
Python provides API, but aqua doesn't support getting versions from API.
https://www.python.org/api/v2/downloads/release/

https://github.com/aquaproj/aqua/issues/682

Remaining tasks

aqua

[ ] Release pre-release versions of aqua v2.31.0-x

https://github.com/aquaproj/aqua/pull/3052

[ ] Test aqua v2.31.0-x
[ ] Merge https://github.com/aquaproj/aqua/pull/3052
[ ] Release aqua v2.31.0

aqua-registry

[ ] Update aqua to v2.31.0 in aqua-registry
[ ] Merge https://github.com/aquaproj/aqua-registry/pull/26154
[ ] Release aqua-registry

Document aquaproj.github.io

[ ] Merge https://github.com/aquaproj/aquaproj.github.io/pull/1084

[ ] Finalize versions

aqua-renovate-config

[ ] Merge https://github.com/aquaproj/aqua-renovate-config/pull/634
[ ] Release aqua-renovate-config v2.4.0

[ ] Announcement

[ ] X
[ ] Discord
[ ] Slack

Hmm... Python works on macOS, but doesn't work on Linux container.
Set up a container according to https://aquaproj.github.io/docs/tutorial/#docker
docker run --rm -ti debian:bookworm-20231009 bash

apt update
apt install -y curl vim

mkdir ~/workspace
cd ~/workspace
export PATH="${AQUA_ROOT_DIR:-${XDG_DATA_HOME:-$HOME/.local/share}/aquaproj-aqua}/bin:$PATH"
curl -sSfL -O https://raw.githubusercontent.com/aquaproj/aqua-installer/v3.0.1/aqua-installer
echo "fb4b3b7d026e5aba1fc478c268e8fbd653e01404c8a8c6284fdba88ae62eda6a  aqua-installer" | sha256sum -c

chmod +x aqua-installer
./aqua-installer

Update aqua to v2.31.0-2.
aqua upa v2.31.0-2

aqua.yaml
registries:
- type: standard
  ref: bcc7a2c5ae39a84af41b7ca559ac619e3f85e8ed
packages:
- name: indygreg/python-build-standalone@20240726
  vars:
    python_version: 3.11.9

aqua i -l
python -V

root@bc0be027deb3:~/workspace# python
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Python path configuration:
  PYTHONHOME = (not set)
  PYTHONPATH = (not set)
  program name = 'python'
  isolated = 0
  environment = 1
  user site = 1
  safe_path = 0
  import site = 1
  is in build tree = 0
  stdlib dir = '/install/lib/python3.11'
  sys._base_executable = '/root/.local/share/aquaproj-aqua/bin/python'
  sys.base_prefix = '/install'
  sys.base_exec_prefix = '/install'
  sys.platlibdir = 'lib'
  sys.executable = '/root/.local/share/aquaproj-aqua/bin/python'
  sys.prefix = '/install'
  sys.exec_prefix = '/install'
  sys.path = [
    '/install/lib/python311.zip',
    '/install/lib/python3.11',
    '/install/lib/python3.11/lib-dynload',
  ]
Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding
Python runtime state: core initialized
ModuleNotFoundError: No module named 'encodings'

Current thread 0x0000ffff82890020 (most recent call first):
  <no Python frame>


[#115] WIP: consensus tracers to structured logging; filtering by severity

more structured logging: capturing of traced observables, filtering and output to the logging.

early filtering by severity included (depends on https://github.com/input-output-hk/iohk-monitoring-framework/pull/425)
tracers in consensus

DO-NOT-MERGE!  this remains a WIP until the upstream PR is merged into its master.

all tracing in the 'node' command/mode can be turned off with --tracing-off

rebased on master

bors r+


Write unit test cases for sql clients generated using bal persist tools

Summary
In the current support, when we do bal persist generate, Ballerina client objects with required types are generated for the persist model definition. However, we don't have a recommended way of testing the project code with the generated clients. As our generated client tries to connect to a remote DB server, we need to mock the generated client to write unit tests for the application
Goals

This proposal is to evaluate different ways and come up with the best option to mock the generated client to write unit tests for the application.
Automatically generate the mocking client object along with the actual client object.
Help developer to set up test framework easily and write test cases.

Motivation
Ballerina developers are now adapting the bal persist feature to manage the data persistence of the application. This is one of the common questions have when we are trying to write test cases for the application code which uses generated clients to connect with SQL databases. This was also asked in the discord thread[1]

https://discord.com/channels/957996897782616114/1166333932736893028/1166333932736893028

Description
In order to come up with a feasible solution, we have evaluated the following options,

Mock the resource function of the generated client to set the return values, before calling the function.
Mock the generated SQL client object with the persistent in-memory client.
Mock the generated SQL client object with the H2 DB client.

From these three options, Mocking the generated SQL client object with an H2 DB client seems to be feasible. We discussed other approaches in the Alternatives section.
Mock the generated SQL client object with the H2 DB client
In this approach, we are going to generate a mock H2 DB client along with the actual client. The mock client can be used to write test cases. At the moment, we have to use function mocking to mock the client object.
For example, In the Ballerina project, we can define a global client object and have an initializeClient function which is used to initialize the MySQL client.
final db:Client dbClient = check initializeClient();

function initializeClient() returns db:Client|error {
   return new ();
}

In the test cases, we can mock the initializeClient function and mock the MySQL client with the H2 client like below,
@test:Mock {functionName: "initializeClient"}
isolated function getMockClient() returns db:Client|error {
    return test:mock(db:Client, check new db:MockClient("jdbc:h2:./test", "sa", "", options = {}));
}

Here the MockClient is a JDBC client which generated along with the SQL client. We can set up H2 DB and a client by passing the URL, username, and password.
The next step is the table creation. We can use the BeforeSuite and AfterSuite functions to create and drop necessary tables like below,
isolated final MockClient h2Client = check new MockClient(url, username, pwd);

@test:BeforeSuite
isolated function beforeSuite() returns error? {
    _ = check h2Client->executeNativeSQL(`CREATE TABLE Doctor (id INT NOT NULL, name VARCHAR(191) NOT NULL, specialty VARCHAR(191) NOT NULL, phoneNumber VARCHAR(191) NOT NULL, PRIMARY KEY(id))`);
}

@test:AfterSuite
function afterSuite() returns error? {
    _ = check h2Client->executeNativeSQL(`DROP TABLE Doctor`);
}

We also can generate the above two functions, as we know the model definition and tables.
With these changes, the generated folder structure looks like follows,

Here, the mock_client.bal file contains the MockClient object, the mock_db_config.bal file contains the configurable variables, and the mock_init.bal file contains the BeforeSuite and AfterSuite functions.
Build options for mock client generations
We can provide this option in the bal persist init command and this will be recorded in the Ballerina.toml file as shown below.
bal persist init --module db --datastore mysql --mock-datastore h2

We can give a new option mock-datastore in the tool configuration, like below. This will apply to bal build.
[tool.persist]
id = "generate-db-client"
filePath = "persist/model.bal" // required field
targetModule = "db"
options.datastore = "mysql"
options.mock-datastore = "h2"

For one-time generation, we can give a new option will store like below,
[persist]
datastore = "mysql"
mock-datastore = "h2"
module = "hospitalsvc.db"

We only support h2 at the moment, the bal build command and bal persist generate command will fail for any other values.
Add support for seed data
[TBD]
Source Code: https://github.com/daneshk/persist-test-samples/tree/move_generated_dir/mock_with_h2
Alternatives

Mock the resource function of the generated client
The mocking resource function is not supported in Ballerina. Related issue[4]. Once it is supported, the developer can use it, like below.

@test:Config {}
function testDoctorInsert() {
   db:Client clientEndpoint = test:mock(db:Client);
   test:prepare(clientEndpoint).when("/doctors.post").thenReturn([6]);
   http:Response|http:ClientError unionResult = testClient->/hospital/doctors.post({
       "id": 6,
       "name": "Dr. House",
       "specialty": "Neurologist",
       "phoneNumber": "1234567890"
   });
   ....
}

They need to set the return value in each test case before calling the function. From the bal persist side, we don't need to make any improvements to support this.

Mock the generated SQL client object with the persist in-memory client
This is to mock the generated SQL client with the generated in-memory client.

Issues in this approach

The get all resource function in the generated SQL client has filter query parameters, but the in-memory client doesn’t have those parameters. Since we need to have the same signature for all functions, it gives an error in compilation.
The private fields in the in-memory client and SQL client are different. Which leads to a compilation error.
There are bad sad errors due to unsupported operations like accessing function pointers in client initialization.
E.g: https://github.com/daneshk/persist-test-samples/blob/main/mock_with_inmemory/tests/persist_client.bal#L21

Source Code: https://github.com/daneshk/persist-test-samples/tree/main/mock_with_inmemory
Testing
We need to write test cases with the generated mock client in different scenarios with different model definitions.
Risks and Assumptions
No Breaking changes associated with this change.
Dependencies

https://github.com/ballerina-platform/ballerina-lang/issues/41788
https://github.com/ballerina-platform/ballerina-lang/issues/41792
https://github.com/ballerina-platform/ballerina-lang/issues/41793
https://github.com/ballerina-platform/ballerina-lang/issues/40059

@sameerajayasoma please check and share your thoughts

As we talked about offline, +1 from me to go ahead with the H2 DB approach. This approach is the best so far. We need to rethink the CLI design based on how we finalize the proposal described in #5784.
I assume that this solution works only for the SQL databases (relational DBs that are accessed and managed using SQL).
Can we use the in-memory datastore for other kinds of datastores like Google sheets?

Supporting in-memory datastore for other kinds of datastores is not working because internal persistClients types used in the generated clients are different. The Ballerina test framework doesn't support mocking clients if private field types differ.

Considering the limitations in the Ballerina language and test framework, the design changed slightly. The updated design is as follows,
we are going to generate a mock H2 DB client for SQL clients(MySQL, MSSQL, and Postgres) and in-memory clients for non-SQL clients(Google sheets and Redis). The mock client can be used to write test cases. At the moment, we have to use function mocking to mock the client object.
For example, In the Ballerina project, we have to define a global client object and have an initializeClient function which is used to initialize the client.
final db:Client dbClient = check initializeClient();

function initializeClient() returns db:Client|error {
   return new ();
}

In the test cases, we can mock the initializeClient function and mock the SQL client with the H2 client like below,
@test:Mock {functionName: "initializeClient"}
isolated function getMockClient() returns db:Client|error {
    return test:mock(db:Client, check new db:MockClient("jdbc:h2:./test", "sa", "", options = {}));
}

The MockClient is a JDBC client which generated along with the SQL client. We can set up H2 DB and a client by passing the URL, username, and password.
We can't use configurable variables to pass H2 db configurations. So we have to hardcode them.

We can mock the non-SQL client with the in-memory client like below,
@test:Mock {functionName: "initializeClient"}
isolated function getMockClient() returns db:Client|error {
    return test:mock(db:Client, check new db:MockClient();
}

The next step is the table creation. We can use the BeforeSuite and AfterSuite functions to create and drop necessary tables like below,
isolated final MockClient h2Client = check new MockClient("jdbc:h2:./test", "sa", "", options = {}));

@test:BeforeSuite
isolated function beforeSuite() returns error? {
    check entities:setupTestDB();
}

@test:AfterSuite
function afterSuite() returns error? {
    check entities:cleanupTestDB();
}

public isolated function setupTestDB() returns persist:Error? {
    _ = check h2Client->executeNativeSQL(`DROP TABLE IF EXISTS "Doctor";`);
    _ = check h2Client->executeNativeSQL(`CREATE TABLE "Doctor" ("id" INT NOT NULL, "name" VARCHAR(191) NOT NULL, "specialty" VARCHAR(191) NOT NULL, "phoneNumber" VARCHAR(191) NOT NULL, PRIMARY KEY("id"))`);
}

public isolated function cleanupTestDB() returns persist:Error? {
    _ = check h2Client->executeNativeSQL(`DROP TABLE IF EXISTS "Doctor";`);
}

We are generating the above two functions(setupTestDB and cleanupTestDB), as we know the model definition and tables. So the user can use these functions in their before and after suite functions in the tests as shown below.
With these changes, the generated folder structure looks like follows,

Here, the persist_mock_client.bal file contains the MockClient object, and the persist_test_init.bal file contains the setupTestDB and cleanupTestDB functions.
Build options for mock client generations
We can provide this option in the bal persist add command and this will be recorded in the Ballerina.toml file as shown below.
bal persist add --module db --datastore mysql --with-mock-client

We can give a new option withMockClient in the tool configuration, like below. This will apply to bal build.
[tool.persist]
id = "generate-db-client"
filePath = "persist/model.bal" // required field
targetModule = "db"
options.datastore = "mysql"
options.withMockClient = "true"

For a one-time generation, we can give the option in the bal persist generate command like the below,
bal persist generate --module db --datastore mysql --with-mock-client

We will generate a mock H2 client for the SQL clients and generate a mock in-memory client for the other clients.
Once we successfully execute the command, the Following message will print with all the steps to use the generated mock client.

For SQL clients

Persist client and entity types generated successfully in the db directory.
Mock client and setup db scripts generated successfully in the db directory.

To use the generated mock client in your tests, please follow the steps below

1. Initialize the persist client in a function.
final db:Client dbClient = check initializeClient();

function initializeClient() returns db:Client|error {
    return new ();
}

2. Mock the client instance with the mock client instance using Ballerina function mocking
@test:Mock {functionName: "initializeClient"}
isolated function getMockClient() returns db:Client|error {
    return test:mock(db:Client, check new db:MockClient("jdbc:h2:./test", "sa", ""));
}

3. Call the setup and cleanup DB scripts in tests before and after suites
@test:BeforeSuite
isolated function beforeSuite() returns error? {
    check db:setupTestDB();
}

@test:AfterSuite
function afterSuite() returns error? {
    check db:cleanupTestDB();
}

For other clients

Persist client and entity types generated successfully in the entities directory.
Ballerina table based mock client is generated successfully in the entities directory.

To use the generated mock client in your tests, please follow the steps below

1. Initialize the persist client in a function.
final entities:Client dbClient = check initializeClient();

function initializeClient() returns entities:Client|error {
    return new ();
}

2. Mock the client instance with the mock client instance using Ballerina function mocking
@test:Mock {functionName: "initializeClient"}
isolated function getMockClient() returns entities:Client|error {
    return test:mock(entities:Client, check new entities:MockClient());
}

For in-memory/h2 client
Persist client and entity types generated successfully in the entities directory.
The mock client is not generated for h2 as it is not supported. Please use the generated client in your tests.

@daneshk, compared to Ballerina test mocking functionality, there is a slight difference in this approach. In mocking, we don't preserve the state; instead, we simply stub the return values in the client. However, in this case, we're actually replacing the actual datasource with an H2/in-memory datasource. Have we considered the possibility of naming this something other than MockClient?

As per the offline design review, Following changes are suggested,

As we are using different data store for the testing and not mocking the actual client. The mock work is not appropriate in this context. Agreed to use test-datastore  instead of mock-client.

The new tool command option will change to
Bal build integration
bal persist add --module db --datastore mysql --test-datastore [h2/inmemory]

The Ballerina.toml tool configuration is changed to
[tool.persist]
id = "generate-db-client"
filePath = "persist/model.bal"
targetModule = "db"
options.datastore = "mysql"
options.testDatastore = "h2"

One-time client generation
bal persist generate --module db --datastore mysql --test-datastore h2

The generated test client will change from MockClient to H2Client/InmemoryClient based on the test data store.

Remove mock word for guide print when executing the generation command.


DJS SDK 4.14 beta 1 got som issues when activating the user.

Already in the connection, there is an error. This line fails:
Can be some righs missing...

DJISDKManager.getInstance().registerApp(ConnectionActivity.this.getApplicationContext(), new DJISDKManager.SDKManagerCallback()
working on it, but ANY SUGGESTIONS????

Error found and fixed, checked in to WORK branch...


Which OCR works in inference internally ?

I wanted to know which OCR it uses internally for training or inference, It claims to OCR free VDU but how it understands the coordinates and text in that case while inferencing the image, basically getting what text is written there while inference is necessary (According to my assumption)

It's "OCR Free" because no external OCR tool is used. There is no internal tool.
Traditionally, you might use something like Tesseract to perform OCR and pass that output to another model
Donut is trained to perform OCR by itself (details in their paper), and then fine-tuned for tasks like VQA. Therefore, no external OCR tool is needed, which saves a ton of computation time and reduces error propagation. The model reads the document and performs the task in a single step.


UnzipFile cannot unzip files created by Windows

Steps to reproduce

Create a folder 'a'
Create a subfolder within 'a' called 'b'
Create a file called 'readme.txt' in subfolder 'b'
Right click on folder 'a' and send to a compressed folder
Attempt to unzip the zip file you have just created using unzip.java

Expected behaviour
The file a/b/readme.txt is created.
Actual behaviour
There is the following exception:
Exception in thread "main" java.io.FileNotFoundException: src/test/resources/unzipTest/a/b (No such file or directory)
	at java.io.FileOutputStream.open0(Native Method)
	at java.io.FileOutputStream.open(FileOutputStream.java:270)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:213)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:162)
	at com.baeldung.unzip.UnzipFile.main(UnzipFile.java:20)

Cause
Not all software creates archives with all of the original folders and subfolders.
Linux zip command would create the following entires:

a
b (path a)
readme.txt (path a/b)

Windows send to compressed folders would create the following entries:

b (path a)
readme.txt (path a/b)

From what I understand both are valid zip files, its just that the native zipping utility in Windows omits zip entries for folders in the root of the archive (I don't know why).
Apache commons have a useful example which avoids this issue by checking for and, if necessary, creating the parent directories for each zip entry.

@thomasturrell thanks for detailed information. Could you also please let us know to which article you are referring to?

I am referring to the the UnzipFile class in the Zipping and Unzipping in Java tutorial.

I have a  solution to this Problem: see attached ZipUtilities.java
It creates the not-in-zip-file-included empty path directories as well as it keeps an eye on the zip-decrompress path-traversal problem in the unzip-destination path, which would allow to decompress files from tampered zip files into your local system directories etc.. (e.g. using ../../../../file.name in zip entries path)
ZipUtilities.txt

@thomasturrell we logged an internal ticket to investigate. I'll follow up in here once we'll get this resolved.

This is a valid issue; I've added a fix in the linked PR.


allow empty RAMALAMA_CONTAINER_ENGINE

i noticed that on one laptop ramalama was running really fast and well, but on other laptop it was slow(ish) - turned out the second one was using podman container engine.
I tried to find ways to disable it so just use llama directly as my first laptop did.
turns out that ramalama will always assume I want container if podman or docker available in PATH; so I made the check that honors RAMALAMA_CONTAINER_ENGINE allow empty string so that users can set this and not have to add --no-container all the time.

@maxandersen can you sign you commit please? The DCO build failed which means the commit wasn't signed, one way it can be done is via:
git commit --amend -s # sign existing commit
git push -f

done


Feature: New Example using 2D isometric RTS Game

Hi.
It would be interesting to create an example of a small futuristic starcraft-like game using 2D isometric RTS Game, as it would involve all the other examples already presented in the /examples folder and would help very newcomers to this topic.
The bigger simple examples of small and complete game genres in the /examples folder I think there will be greater adoption of the engine, which by the way is very good in my opinion.
Sorry for basic English.

Hi,
Thank you for your suggestion! I agree such examples would be very nice. I'd be happy to review if someone could offer one.

Let's continue the discussion at #1112 .


kubelet errors

kubelet returns errors:Feb 03 09:56:55 node-02 kubelet[981]: E0203 09:56:55.048333     981 etcd.go:64] etcd failed to retrieve the value for the key "/registry/nodes/<IP_ADDRESS>/boundpods". Error: 100: Key not found (/registry/nodes) [251]
It is looking in etcd for "/registry/nodes/" but etcd only have "/registry/minions" keys

sorry, false alarm.


I am trying to create my torrent browser client and that can accept all types of torrent/magent links from places like iptorrents, piratebay, etc.

But I am having issues. The only types of torrents I can seem to download as those in the WEBRTC selection {webtorrent.io/free-torrents/ -- there's one about a bunny I think. Amway, How do I adapt webtorrent.io to allow for all other torrent files, files from the PirateBay, or iptrackers (which is a private tracker?
Also, where are these finished downloads being saved? On my computer, or on the user's computer?
Just some simple questions with I am sure more to come. But any help would be greatly appreciated. I appreciate what you guys are trying to do I am just a little confused about overall usability for mainstream torrent users.

Here is a screenshot I have taken. I used a pubic torrent from the PirateBay.


Fix a gcc fallthru warning

GCC warns here because the previous switch statement has no default label,
so technically the control flow can fall thru into the next block.

Merged.  Thanks!


Discussion - State of Daedalus in Linux

Dear colleagues,
Linux is diverse, with different distros and packages. This means that traditionally software usually is developed for one distribution of Linux (e.g. Ubuntu), not taking into consideration the whole system. This is the case of Daedalus so far. It works in Ubuntu, but it struggles with alternative distributions such as NixOS, Fedora Silverblue of QubeOS. This has created already several issues being open on this topic.
In order to solve the problem of shipping software easily to Linux, three alternatives have been developed for creating "universal linux apps":

Flatpaks. https://flatpak.org/
-AppImages. https://appimage.org/
-Snaps. https://snapcraft.io/

Considering the three options, and considering what Daedalus is doing, Flatpaks look to me like the way to go. Indeed, it has already some crypto-wallet applications.The application would run in 99% of the distros out there and it would simplfy and streamline the discussion on this topic. Moreover, the installation would be one order in the command line, and it could be accesible through stores such as Flathub (https://flathub.org/home).
Thank you for your time, and looking forward to see your thoughs on this topic :).

I prefer Snaps but there is no reason that both of packaging formats to be supported.

Traditionally open source software on Linux is packaged by the individual distribution maintainers and not by the developers themselves. This has several advantages both for the user and for the developers.
Is there any information available how to build deadalus against system libraries instead of nix? Is there anything that would prevent us from creating a regular system wide package for deadalus?

cc @disassembler

Be clear: daedalus isn't a GNU/Linux program; it's a systemd/GNU/Linux program.  Please either make it for GNU/Linux in general (like Slackware and it's large family of derivatives, and Gentoo) or specify it's for systemd OSs only.  Snaps are horrible and never should be used outside cell phones, which they originally were designed for.  Flatpaks are almost as bad as they require an installer.  AppImages don't, but what's best is a general GNU/Linux binary rather than a systemd/GNU/Linux installer.

cc @disassembler

It's been more than one year. Does Daedalus still depends on systemd?
AppImage definitely would be the proper solution here. Specially since the Download page says:
"Linux - Aimed at all Linux distributions"

It's been more than one year. Does Daedalus still depends on systemd?
AppImage definitely would be a proper solution here. Specially since the Download page says:
"Linux - Aimed at all Linux distributions"


Creases are not folding in combination with large multi-column environment

I have a relatively large file which I want to structure. To do this I use the multi-column plugin.
At the end of my file, I still have some sections which I now want to automatically fold, so I want to this plugin.
Normally, in every other file, my creases are folding. But in this file, the creases are not folding.
For context:

The creases are outside the multi-columns
There are about 100 Checkboxes in two consecutive multi-column environments.
Settings are: 'Always fold creases' and 'Start folded'
OS: Ubuntu 22.04.4 LTS

I tried to reproduce this behaviour with smaller files, but only this file, which is pretty big and takes about 1 second to completely load, has this problem.

After restarting the application, it now seems to work ... :D


StackOverflow with a JuliaBUGS model

julia> using JuliaBUGS, Tapir, ADTypes, LogDensityProblemsAD

julia> data = (
           r = [10, 23, 23, 26, 17, 5, 53, 55, 32, 46, 10, 8, 10, 8, 23, 0, 3, 22, 15, 32, 3],
           n = [39, 62, 81, 51, 39, 6, 74, 72, 51, 79, 13, 16, 30, 28, 45, 4, 12, 41, 30, 51, 7],
           x1 = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1],
           x2 = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1],
           N = 21,
       )
(r = [10, 23, 23, 26, 17, 5, 53, 55, 32, 46  …  8, 10, 8, 23, 0, 3, 22, 15, 32, 3], n = [39, 62, 81, 51, 39, 6, 74, 72, 51, 79  …  16, 30, 28, 45, 4, 12, 41, 30, 51, 7], x1 = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0  …  1, 1, 1, 1, 1, 1, 1, 1, 1, 1], x2 = [0, 0, 0, 0, 0, 1, 1, 1, 1, 1  …  0, 0, 0, 0, 0, 1, 1, 1, 1, 1], N = 21)

julia> model_def = @bugs begin
           for i in 1:N
               r[i] ~ dbin(p[i], n[i])
               b[i] ~ dnorm(0.0, tau)
               p[i] = logistic(alpha0 + alpha1 * x1[i] + alpha2 * x2[i] + alpha12 * x1[i] * x2[i] + b[i])
           end
           alpha0 ~ dnorm(0.0, 1.0E-6)
           alpha1 ~ dnorm(0.0, 1.0E-6)
           alpha2 ~ dnorm(0.0, 1.0E-6)
           alpha12 ~ dnorm(0.0, 1.0E-6)
           tau ~ dgamma(0.001, 0.001)
           sigma = 1 / sqrt(tau)
       end
quote
    for i = 1:N
        r[i] ~ dbin(p[i], n[i])
        b[i] ~ dnorm(0.0, tau)
        p[i] = logistic(alpha0 + alpha1 * x1[i] + alpha2 * x2[i] + alpha12 * x1[i] * x2[i] + b[i])
    end
    alpha0 ~ dnorm(0.0, 1.0e-6)
    alpha1 ~ dnorm(0.0, 1.0e-6)
    alpha2 ~ dnorm(0.0, 1.0e-6)
    alpha12 ~ dnorm(0.0, 1.0e-6)
    tau ~ dgamma(0.001, 0.001)
    sigma = 1 / sqrt(tau)
end

julia> initializations = Dict(:alpha => 1, :beta => 1);

julia> model = compile(model_def, data, initializations);

julia> ad_model = ADgradient(AutoTapir(false), model)
ERROR: StackOverflowError:
Stacktrace:
     [1] #s12#32
       @ ~/.julia/packages/Tapir/jt6ko/src/tangents.jl:374 [inlined]
     [2] var"#s12#32"(P::Any, ::Any, ::Any)
       @ Tapir ./none:0
     [3] (::Core.GeneratedFunctionStub)(::UInt64, ::LineNumberNode, ::Any, ::Vararg{Any})
       @ Core ./boot.jl:602
     [4] tangent_field_type(::Type{JuliaBUGS.BUGSModel}, n::Int64)
       @ Tapir ~/.julia/packages/Tapir/jt6ko/src/tangents.jl:397
     [5] #30
       @ ~/.julia/packages/Tapir/jt6ko/src/tangents.jl:360 [inlined]
     [6] iterate
       @ ./generator.jl:47 [inlined]
     [7] collect_to!(dest::Vector{DataType}, itr::Base.Generator{UnitRange{…}, Tapir.var"#30#31"{…}}, offs::Int64, st::Int64)
       @ Base ./array.jl:892
     [8] collect_to_with_first!
       @ ./array.jl:870 [inlined]
     [9] _collect
       @ ./array.jl:864 [inlined]
    [10] collect_similar
       @ ./array.jl:763 [inlined]
    [11] map
       @ ./abstractarray.jl:3285 [inlined]
    [12] backing_type(::Type{JuliaBUGS.BUGSModel})
       @ Tapir ~/.julia/packages/Tapir/jt6ko/src/tangents.jl:360
    [13] #s12#32
       @ ~/.julia/packages/Tapir/jt6ko/src/tangents.jl:384 [inlined]
    [14] var"#s12#32"(P::Any, ::Any, ::Any)
       @ Tapir ./none:0
    [15] (::Core.GeneratedFunctionStub)(::UInt64, ::LineNumberNode, ::Any, ::Vararg{Any})
       @ Core ./boot.jl:602
--- the last 15 lines are repeated 2111 more times ---
 [31681] #s12#94
       @ ~/.julia/packages/Tapir/jt6ko/src/fwds_rvs_data.jl:550 [inlined]
 [31682] var"#s12#94"(P::Any, ::Any, ::Any)
       @ Tapir ./none:0
 [31683] (::Core.GeneratedFunctionStub)(::UInt64, ::LineNumberNode, ::Any, ::Vararg{Any})
       @ Core ./boot.jl:602
 [31684] lazy_zero_rdata_type(::Type{JuliaBUGS.BUGSModel})
       @ Tapir ~/.julia/packages/Tapir/jt6ko/src/fwds_rvs_data.jl:732
 [31685] call_composed
       @ ./operators.jl:1044 [inlined]
 [31686] (::ComposedFunction{typeof(Tapir.lazy_zero_rdata_type), typeof(Tapir._type)})(x::Type; kw::@Kwargs{})
       @ Base ./operators.jl:1041
 [31687] iterate
       @ ./generator.jl:47 [inlined]
 [31688] collect_to!(dest::Vector{DataType}, itr::Base.Generator{Vector{…}, ComposedFunction{…}}, offs::Int64, st::Int64)
       @ Base ./array.jl:892
 [31689] collect_to_with_first!(dest::Vector{DataType}, v1::Type, itr::Base.Generator{Vector{…}, ComposedFunction{…}}, st::Int64)
       @ Base ./array.jl:870
 [31690] _collect(c::Vector{Any}, itr::Base.Generator{Vector{…}, ComposedFunction{…}}, ::Base.EltypeUnknown, isz::Base.HasShape{1})
       @ Base ./array.jl:864
 [31691] collect_similar
       @ ./array.jl:763 [inlined]
 [31692] map
       @ ./abstractarray.jl:3285 [inlined]
 [31693] Tapir.ADInfo(interp::Tapir.TapirInterpreter{Tapir.DefaultCtx}, ir::Tapir.BBCode, safety_on::Bool)
       @ Tapir ~/.julia/packages/Tapir/jt6ko/src/interpreter/s2s_reverse_mode_ad.jl:173
 [31694] build_rrule(interp::Tapir.TapirInterpreter{…}, sig::Type{…}; safety_on::Bool, silence_safety_messages::Bool)
       @ Tapir ~/.julia/packages/Tapir/jt6ko/src/interpreter/s2s_reverse_mode_ad.jl:779
 [31695] build_rrule
       @ ~/.julia/packages/Tapir/jt6ko/src/interpreter/s2s_reverse_mode_ad.jl:753 [inlined]
 [31696] ADgradient(::Val{:Tapir}, ℓ::JuliaBUGS.BUGSModel; safety_on::Bool)
       @ TapirLogDensityProblemsADExt ~/.julia/packages/Tapir/jt6ko/ext/TapirLogDensityProblemsADExt.jl:36
 [31697] ADgradient
       @ ~/.julia/packages/Tapir/jt6ko/ext/TapirLogDensityProblemsADExt.jl:34 [inlined]
Some type information was truncated. Use `show(err)` to see complete types.

Setup

(@turing) pkg> st
Status `~/.julia/environments/turing/Project.toml`
  [47edcb42] ADTypes v1.5.3
  [ba9fb4c0] JuliaBUGS v0.5.3
  [996a588d] LogDensityProblemsAD v1.9.0
  [07d77754] Tapir v0.2.24

So this is a standard example of tangent_type not working for a recursively-defined type, as such it's a known limitation as opposed to a bug.
@sunxd3 are there any fields in a JuliaBUGS.BUGsModel which contain things which get differentiated through? If we can just say that the whole thing has NoTangent as its tangent type, this problem will go away.

Hmm yes, the varinfo gets used actively as part of the logpdf computations, right?

Alternatively, making BUGSModel non-recursive is also acceptable.

What would be involved in this?

I believe that this specific problem has now been resolved, because @sunxd3 has refactored the JuliaBUGS implementation. @sunxd3 could you confirm, and close this if I've not missed anything?


speech.Recognize() doesn't return, throws exception after 10 minutes saying "DeadlineExceeded"

I am using this slightly modified version of the code from this repository:
public async Task<string> TranscribeSpeech(string filenameAndPath, int WAVSampleRate = 8000)
    {
        Environment.SetEnvironmentVariable("GOOGLE_APPLICATION_CREDENTIALS", Utils.GetHomeFolder() + @"\Google Speech API Key.json"); //for authentication

        var language = WebConfigurationManager.AppSettings["GoogleSpeechFromLocale"];

        var speech = SpeechClient.Create();
        var response = await speech.RecognizeAsync(new RecognitionConfig()
        {
            Encoding = RecognitionConfig.Types.AudioEncoding.Linear16,
            SampleRateHertz = WAVSampleRate,
            LanguageCode = language,
        }, RecognitionAudio.FromFile(filenameAndPath));

        return response.Results.First().Alternatives.First().Transcript;
    }

The .Recognize() or .RecognizeAsync() methods never return anything and throw an exception after 10 minutes saying Status(StatusCode=DeadlineExceeded,Detail="Deadline Exceeded")!.
Is there an issue with the code or with the API settings?

It looks like you are calling the API correctly.  How large is your input file?
Have you tried the LongRunningRecognize() for larger sound files?  A C# sample is shown here:
https://cloud.google.com/speech/docs/async-recognize#speech-async-recognize-gcs-csharp

In case your input file is too big, split it by the presence of silence into audio chunks.

It's just two or three seconds actually. This code runs as a bot on Facebook Messenger and Telegram. You record and send a voice message to the bot, it gets converted into PCM16, then it is passed to Bing Speech API and Google Cloud Speech API. (Just testing both APIs). The first one succeeds, the second doesn't return.

The same problem.
I have tried your sample:
PS C:...\dotnet-docs-samples\speech\api\QuickStart\bin\Debug> .\QuickStart.exe how old is the Brooklyn Bridge
but after few minutes " Grpc.Core.RpcException: Status(StatusCode=DeadlineExceeded, Detail="Deadline Exceeded")" message appeared.

lenzi12

but after few minutes " Grpc.Core.RpcException: Status(StatusCode=DeadlineExceeded, Detail="Deadline Exceeded")" message appeared.

Will simply calling QuickStart.exe once per minute in a loop reproduce the issue?

J3QQ4,
Can you provide a file that causes the API to report this error?

I'm still unable to reproduce.

I have just built your project https://github.com/GoogleCloudPlatform/dotnet-docs-samples/tree/master/speech/api and followed the instructions bellow i.e. ran QuickStart.exe. Black console window started, nothing's happend and after few minutes the mentioned error appeared:
Unhandled Exception: Grpc.Core.RpcException: Status(StatusCode=DeadlineExceeded, Detail="Deadline Exceeded")
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Grpc.Core.Internal.AsyncCall2.UnaryCall(TRequest msg)    at Grpc.Core.Calls.BlockingUnaryCall[TRequest,TResponse](CallInvocationDetails2 call, TRequest req)
at Grpc.Core.DefaultCallInvoker.BlockingUnaryCall[TRequest,TResponse](Method2 method, String host, CallOptions optio ns, TRequest request)    at Grpc.Core.Internal.InterceptingCallInvoker.BlockingUnaryCall[TRequest,TResponse](Method2 method, String host, Cal
lOptions options, TRequest request)
at Google.Cloud.Speech.V1.Speech.SpeechClient.Recognize(RecognizeRequest request, CallOptions options)
at Google.Api.Gax.Grpc.ApiCall.<>c__DisplayClass0_02.<Create>b__1(TRequest req, CallSettings cs)    at Google.Api.Gax.Grpc.ApiCallRetryExtensions.<>c__DisplayClass1_02.b__0(TRequest request, CallSettings c
allSettings)
at Google.Api.Gax.Grpc.ApiCall`2.Sync(TRequest request, CallSettings perCallCallSettings)
at Google.Cloud.Speech.V1.SpeechClientImpl.Recognize(RecognizeRequest request, CallSettings callSettings)
at Google.Cloud.Speech.V1.SpeechClient.Recognize(RecognitionConfig config, RecognitionAudio audio, CallSettings callS
ettings)
at GoogleCloudSamples.QuickStart.Main(String[] args) in .\dotnet-docs-sam
ples-master\speech\api\QuickStart\QuickStart.cs:line 30

It is solved ! Problem was our network configuration. I have changed some network settings and now it works. Sorry for bothering.

@lenzi12 What exactly was it? Because I'm running the bot on MS Azure and still can't get this sample to work, due to this error.

This was specific permission setting of our network.
I have switched to another network, which works. I am still waiting for details of permission which causes the problem from our network admin.

Ok, my network admin said that this sample application should set the proxy server of the network - is it possible ?

Yes.  You can specify the http_proxy (yes, all lowercase) environment variable and gRPC will use HTTP's CONNECT to tunnel through the proxy.

Hello,
We are facing an issue like Grpc.Core.RpcException: Status(StatusCode=DeadlineExceeded, Detail="Deadline Exceeded") while sending text message.
We are using Google.Cloud.Dialogflow.V2 nuget package (SDK) and we are sending request using below code
object result = client.DetectIntent(
session: new SessionName(PROJECT_ID, SESSION_ID),
queryInput: new QueryInput()
{
Text = new TextInput()
{
Text = query,
LanguageCode = languageCode
}
}
);
Notes: This error was intermittently.
Thanks,
Greg.

Hi Greg3108.  Thank you for the report.  Is the issue you are experiencing related to http_proxy or the like?  If not, please open a new, separate bug so I can track the issue separately.

Hi SurferJeff,
We've also reported this bug to the dialogflow and we got the response like it was outage from their side.
Thanks
Greg.


add TPR, cleanup support to walkthrough e2e script

Now test_walkthrough.sh will use a tpr-backed API server if you pass in --with-tpr.
--cleanup will get rid of all resources spun up during walkthrough.

Although the output is still quite ugly, this allows for people to test the walkthrough easily on their local machine.
Jenkins will still only run the etcd-based walkthrough; there is an issue outstanding ( #600 ) that prevents the deletion of TPR resources.

@kibbles-n-bytes you could use the workaround described at https://github.com/kubernetes-incubator/service-catalog/issues/600#issuecomment-288524199 to do TPR cleanup here

@kibbles-n-bytes should this be labelled jenkins?

@arschles To your second question, not the way the label was intended. The label was supposed to be a trigger for Jenkins to run on a build, but I've changed this. See my response on #591 . That means the Jenkins label now has no purpose, though could be used for Jenkins-specific changes (I suppose any edits of the Jenkinsfile?), but I think just using the testing label is enough. This PR is more meant for non-Jenkins use of the test_walkthrough.sh script anyway.
For the first question, I'll try it out!

Part of the changes here will fix #632 .

LGTM


Ansibleee refactor

Further refactoring was requested, and pretty necessary following:
https://github.com/openstack-k8s-operators/openstack-operator/pull/972
This PR is the follow up to that change and splits out logic into more specific functions, deduplicating code that was used to create Volumes and VolumeMounts.

recheck

/test openstack-operator-build-deploy-kuttl

/test openstack-operator-build-deploy-kuttl


Limit reactions to 40 to sync with mattermost-mobile

Summary

Limit the number of unique reactions on a post to be utmost 40.
Handle both Center channel and RHS

Ticket Link
Fixes https://github.com/mattermost/mattermost-server/issues/14167
Screenshots
After changes,

In RHS

In Center Channel

Creating a new SpinWick test server using Mattermost Cloud.

Mattermost test server created! :tada:
Access here: https://mattermost-webapp-pr-5222.test.mattermost.cloud

Account Type
Username
Password

Admin
sysadmin
Sys@dmin123

User
user-1
User-1@123

Thanks @rakhi2104! Can you confirm the number of reactions is capped at 40? I count 41 in your screen capture above

Sorry, the screenshot was captured earlier. Will update soon.

LGTM 2/5 I would add a unit test for this.

@esethna
Regarding the "+:emoji:" shortcut,

first we allow the user to type in his reaction
on sumbit post, if (unique) reactions limit has exceeded, we show the user an error "Reactions limit exceed for current post" and clear out the text field.

@rakhi2104 that works. But can you please update the text to
Reaction limit exceeded for this message.

@rakhi2104 that works. But can you please update the text to
Reaction limit exceeded for this message.
I tried creating an alert, but it doesn't work as expected.

Thank you @rakhi2104
Noticed one small issue with the post menu

Add Reaction menu option remains available in mobile web view, after reaching 40 emoji limit. Note: Even though it is available, it does not add another emoji over 40.

I'm confused by this

on sumbmit post, if (unique) reactions limit has exceeded, we show the user an error "Reactions limit exceed for current post" and clear out the text field.

I am not sure how to exceed the limit and trigger an alert to verify the wording?
My understanding was that it would be impossible to go over added reactions as add reaction + and link to open emoji picker are removed when limit is reached. Any suggestion on how to do this is appreciated 🙂Thanks

Hey @rakhi2104, hope you're well, any questions on the above feedback?

Hey @rakhi2104, just checking in on this, any questions?

Sorry for being unresponsive.
I've tried creating the error message but that didn't work as expected.

@rakhi2104 thanks for the update, do you need any help with this?

@rakhi2104 let us know if you need help with this?

@calebroseland can you provide some guidance to @rakhi2104 regarding how to accomplish this: https://github.com/mattermost/mattermost-webapp/pull/5222#issuecomment-606611607
cc// @jgilliam17 on how to add a reaction via the message draft area ^

Thanks to @M-ZubairAhmed and @calebroseland for helping me resolve some roadblocks.

Thanks @jgilliam17 please help retest ^

This issue has been automatically labelled "stale" because it hasn't had recent activity.
A core team member will check in on the status of the PR to help with questions.
Thank you for your contribution!
/cc @jasonblais @hanzei

I missed being mentioned while OoO last week. Will take a look on Monday.

/update-branch

Thank you @rakhi2104

Reaction button has been removed in mobile view when limit has been reached - looks good

I am seeing some additional issues:

Reaction count failing to update when adding an existing reaction to the post using +emoji add reaction button.
Steps:
i. User 1 adds an "eye" emoji to the post
ii. User 2 clicks on +emoji button and adds the same "eye" emoji to the post
Observed: Emoji count updates for the first user, but not the second. See gif.

Emoji picker appears again unexpectedly
i. User 1 adds 39 reactions to the post and opens emoji picker again
ii. User 2 adds 40th reaction (observe the emoji picker disappears for user 1 as limit is reached)
iii. Remove 40th reaction as user 2
Observed: Emoji picker for User 1 pops up open unexpectedly as the post reaction limit drops below 40

RE: error "Reactions limit exceed for current post"
@calebroseland can you please help me understand this requirement  https://github.com/mattermost/mattermost-webapp/pull/5222#issuecomment-606611607
I am not clear on when and where the user is going to be presented with the error message. On the open emoji picker after another user adds 40th emoji and limit is reached? Thanks.

@jgilliam17 that is about the +(reaction) command:

@jgilliam17 that is about the +:emoji_name: command:

Thank you @calebroseland, this whole time I was looking elsewhere 🤦🏽♀

Tested the error message and it appears on main channel view and RHS when adding reactions using +:emoji_name: via message draft after limit has been exceeded
Few UX questions:

Should the error message match our existing error message color/font for visibility? See image for comparison.

When trying to add an emoji again after error is shown, error message highlight dissolves quickly. I'm 0/5 on this, I missed it once or twice - just noting here

Emoji picker appears again unexpectedly

UX thought: maybe we could keep the + reaction button visible, but disabled with the tooltip changed to:
'Reaction limit exceeded for this message'

This issue has been automatically labelled "stale" because it hasn't had recent activity.
A core team member will check in on the status of the PR to help with questions.
Thank you for your contribution!
/cc @jasonblais @hanzei

Hi @rakhi2104,
Just wanted to touch bases and ask if you have any question? I would love to get this PR over the finish line.

I'll look into these review comments this weekend.

Thank you @rakhi2104
Re-tested and I am still seeing these two issue. Let me know if I need to add more information.

Reaction count failing to update when adding an existing reaction to the post using +emoji add reaction button.
Emoji picker appears again unexpectedly

Additionally, the Add Reaction option is available on post menu ... and mobile view, despite max reaction limit being reached.

This PR has been automatically labelled "stale" because it hasn't had recent activity.
A core team member will check in on the status of the PR to help with questions.
Thank you for your contribution!
/cc @jasonblais @jfrerich

How's it going, @rakhi2104?  Do you need any further feedback or help with this PR?

@rakhi2104 Could you merge the master branch and fix the conflicting files listed at the bottom of the PR?
@jgilliam17, Could you provide additional context or direction on how to resolve the issues that you mentioned?
@rakhi2104, thanks for reaching out!  If you are stuck, feel free to engage any of the developers reviewing this PR.  They are excellent resources!

Thank you @jfrerich
@rakhi2104
Here's some additional information
For the first 2 issues please also see my original post here

Reaction count failing to update when adding an existing reaction to the post

Adding a reaction by clicking on the existing emoji correctly increments for both users ( user1 that added the reaction initially and user2 that clicked on the existing reaction on the same post)
The increment count issue is present (e.g. for the user2 in this case) if they use any other way to increment the existing reaction: + add a reaction, emoji picker from post menu or posting +:emoji: in the text box, where emoji is an existing reaction
The count updates on refresh.

Emoji picker appears again unexpectedly -
i. User 1 adds 39 reactions to the post and opens emoji picker again
ii. User 2 adds 40th reaction (observe the emoji picker disappears for user 1 as limit is reached)
iii. Remove 40th reaction as user 2 - observe the emoji picker popup for user 1

The solution would be to prevent the emoji picker from surfacing again, once removed

Remove post menu option to "Add Reactions" after the limit is reached, in both standard and mobile web browser width. I remember seeing this fixed in mobile web view at one point, but it appears to have regressed

Let me know if you have any questions or need additional information. Thanks! 🙂

@rakhi2104 how's this going?

Hey @esethna !
Due to some office work, I'm not able to spend more time looking into this issue. Is it possible for someone to takeover from here? I'd be happy to help transfer my learning with this task.
✌🏼

Thanks @rakhi2104 I've reopened the ticket as up for grabs

Removing the cloud test server for maintenance reason. Please feel free to add it again if you need it.


IGNORE NULLS | RESPECT NULLS clauses not documented for LAG/LEAD functions

The clause for IGNORE NULLS | RESPECT NULLS was recently added to FIRST_VALUE and LAST_VALUE, however it is still not documented on LAG/LEAD, even though it is supported (I believe for both SQL SERVER 2022 and AZURE SQL)
Documented:
https://github.com/MicrosoftDocs/sql-docs/blob/live/docs/t-sql/functions/first-value-transact-sql.md
https://github.com/MicrosoftDocs/sql-docs/blob/live/docs/t-sql/functions/last-value-transact-sql.md
Not documented:
https://github.com/MicrosoftDocs/sql-docs/blob/live/docs/t-sql/functions/lead-transact-sql.md
https://github.com/MicrosoftDocs/sql-docs/blob/live/docs/t-sql/functions/lag-transact-sql.md

@clement911 -- Clement, thank you for your well-researched feedback.
@markingmyname -- Mark, please look into this issue.

@markingmyname  to prove that LAG() OVER() is supported in SQL SERVER 2022 and SQL AZURE, you can simply run the following query
SELECT LAG(value) IGNORE NULLS OVER(ORDER BY id)
FROM (VALUES (1, 'Yes'), (2, NULL), (3, 'No')) t(id, value)

It would great to add this.
This is a great new feature in sql server 2022. Unfortunately, people won't use it unless it's documented...

any updates?

@markingmyname

@clement911 This use of IGNORE NULLS | RESPECT NULLS is not documented for LAG/LEAD functions for a reason, for now. Currently, this is not supported. This is on our radar.  Thanks for bringing this up and taking the time to create this issue though, this feedback is valuable.

@WilliamDAssafMSFT What is the reason?
I'm not sure what you mean exactly by 'not supported'.
We have been using IGNORE NULLS with LAG/LEAD in both Sql server 2022 and Sql Azure for several months now.
In addition, it is mentioned in this post: https://sqlperformance.com/2022/05/t-sql-queries/windowing-improvements-sql-server-2022#:~:text=As mentioned%2C the NULL treatment clause is available to all offset window functions (FIRST_VALUE%2C LAST_VALUE%2C LAG%2C and LEAD). Here’s an example using LAG to return the previous known value%3A

I'm sorry I can't offer you any more information at this time, but it is on our radar. Will update.

@Clement911 Yes, there was an issue with IGNORE NULLS in LAG/LEAD and this has been resolved in CU4 for SQL Server 2022. https://learn.microsoft.com/troubleshoot/sql/releases/sqlserver-2022/cumulativeupdate4#2278800

I see. I guess that the documentation can be updated now it is fixed?
However, how do we track the status of this fixes in Sql Azure? Does Sql Azure have this cumulative fixes already applied?

You are correct that a doc update is in flight!
Azure SQL Database always running on the latest stable version of the SQL Server database engine and patched OS, yes. You can verify the version of your logical server via the same methods as on a SQL Server, for example.

This is what I'm seeing when querying sql azure:

If sql azure is using a Mar 30 version, are you positive that it contains the latest cumulative update which was released on May 11th?
That is completely different from we see in the docs for the cumulative update 4:

I'm even more confused.


php-status: Check if memory_limit is greater than post_max_size

In GitLab by @markuslf on Feb 8, 2022, 20:56
Otherwise WARN.

Because $_POST (and $_FILES) counts towards memory_limit, so post_max_size has to be smaller than memory_limit.


Unhandled exception when layer deleted while contextmenu open

Thanks for the great library.
I'm using the contextmenu mixin with geoJSON features.  The features are frequently updated by clearing the geoJSON layer and re-adding new features.  It sometimes happens that a feature is removed while its context menu is open.  When this happens, when the context menu is closed, an exception is thrown in Mixin.ContextMenu.js line 72 because this._map is null.  After this, the list of contextmenu items gets out of sync and future contextmenus have spurious items.
The attached patch solves this issue for me.
handle_deleted_layer.patch.txt

+1 on this patch. I am using leaflet-routing-machine with draggable markers, and I find that when I have a contextmenu associated with a marker and long-press the market on mobile, the menu sometimes gets into a messy state. It looks like it's caused by the marker being dragged firing another event that removes the marker. I tried this patch on a hunch, and it resolved my issue completely.


Double vision on Pixel XL

Using A-frame, on Nexus 5x WebVR scenes looks fine. However, when viewing WebVR scenes on a Pixel XL the stereoscopic does not match up, one of the eyes is too far apart. This causes double vision when viewing within a headset.

@btco Any chance we can update the dpdb with new Android devices?
On Thu, Nov 17, 2016 at 6:21 AM Gareth Williams<EMAIL_ADDRESS>wrote:
Using A-frame, on Nexus 5x WebVR scenes looks fine. However, when viewing
WebVR scenes on a Pixel XL the stereoscopic does not match up, one of the
eyes is too far apart. This causes double vision when viewing within a
headset.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/googlevr/webvr-polyfill/issues/176, or mute the thread
https://github.com/notifications/unsubscribe-auth/AAQ8gHFuH9-zrSLnkc1fqqJAlgg5eg-_ks5q_GLvgaJpZM4K1XJ2
.

@borismus
My android device is also not included in the dpdb_cache.js..and I do not know how to calculate it ..Could you please kindly tell me how to calculate "device"["rules"], ["bw"] and ["ac"] as well..?
Here is my device infomation, thanks in advance!!

and some js console message when test webpage based on  A-frame on Android device:

Hello,
Any progress on this. It's really disturbing not to be able to use a recent device in a cardboard.

@AdrienPoupa  yes, I add some additional information in DBPB cache file,
you can refer to this linkhttps://github.com/aframevr/aframe/issues/2117#issuecomment-265275683
I get my device information from https://play.google.com/store/apps/details?id=com.jphilli85.deviceinfo
It seems they just match 'ua' and 'res' rules , so make sure "ua"(user agent I guess) is correct.
We have to wait till Google updates that database...
Have a try to fix it locally...

In #233, the local DPDB has been updated and sync'd with the online version at webvr.rocks (once https://github.com/WebVRRocks/webvr-polyfill-dpdb/pull/7 is merged), which includes the Pixel XL. Try the latest version which should fix this -- please reopen if this does not fix the issue. Thanks!


Upgrade terraform-provider-tailscale to v0.13.6

Hello!

Vote on this issue by adding a 👍 reaction
If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)

Issue details

Affected area/feature

We should investigate why pulumi-bot didn't automatically such an issue, like #77 @t0yv0 @guineveresaenger

@thomas11 @guineveresaenger @t0yv0  It's because Zapier was set to track the wrong upstream. I believe I fixed it.


update

This PR has no Slow CI triggered yet. Please trigger it and make sure all tests passing before merge.

This PR has no Slow CI triggered yet. Please trigger it and make sure all tests passing before merge.

This PR has no Slow CI triggered yet. Please trigger it and make sure all tests passing before merge.

This PR has no Slow CI triggered yet. Please trigger it and make sure all tests passing before merge.

This PR has no Slow CI triggered yet. Please trigger it and make sure all tests passing before merge.


Fixed direct memory leak in proxy with trace logging enabled

Motivation
Running the proxy with proxyLogLevel=2 is triggering a memory leak and the proxy gets out of direct memory.

@merlimat I have already created a PR few months back to fix it:
https://github.com/apache/pulsar/pull/7963/files

@rdhabalia thanks for pointing out :) closing this


CHEBI:16244 - missing relationships

Dear Chebi curators,
Please would you add is-a relationship between CHEBI:16244 and CHEBI:29067 (a carboxylate).
Needed for Rhea reaction relationships
Thanks for your support
Anne

Hi Anne,
There is a problem with your proposal - CHEBI:29067 (carboxylic acid anion) is_a organic anion and Is_a oxoanion, but CHEBI:16244 is neither of these - it is a neutral molecule.

Hi Gareth,
The global charge is neutral (zwitterion) but CHEBI:16244 still has a carboxylate group.

Hi Anne,
The problem is that a neutral molecule cannot be also be an organic anion.
We might be able to use the relationship has_part carboxylato group (CHEBI:18245). I will check with some ontologists and see whether it would fix the problem.


Bio-Formats 7.0.0 updates

Updates to bump Bio-Formats version and add release announcement and new contributors.
PR will fail and wont be ready for full review until BF artefacts have been released

We could point to https://www.linkedin.com/in/dianecsaunders instead to fix the failure

Looks good, build is green
Please merge and tag


feat(curriculum): adding node and express challenges to cert

Checklist:

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

Closes https://github.com/freeCodeCamp/CurriculumExpansion/issues/559

now there is merge conflict, @moT01 can you fix the test so we don't have to do that?

I went through the individual sections, they seem good to go.
However, this is how the "Basic Node and Express" section is showing on the main page:

@zairahira
That is because some recent UI changes broken the the design for these challenges.
there is already a PR in the works to fix this


> and < and >>= seem to have different behaviour

Seems to be that <* has broken behavior, and different from *> and >>=.
https://try.purescript.org/?gist=ca835da363bc7475c73190b6dc43aa9b
foo1 seems to run before it should.
foo2 and foo3 run as expected.

@bbarker ^^

@bbarker ^^


Changed ShowSettingsUI to OpenSettings

Per the API docs, this should be OpenSettings() instead of ShowSettingsUI().
Addresses #1126

No problem, I looked but didn't see a matching fix. Thanks!

heh it was still in-flight. great minds think alike 😉


Customize bubble border color

I configured bubbles message color and would like to add a border around them. Is it possible ?

How did you create custom method?


INVALID PARAMS error after nearly one year of working fine. Has the API changed?

Hello,
I use pycarwings2 to do some energy-automation while charging my 2018 Leaf at my house.
Pycarwings2 has now worked for nearly a year without hiccups, refreshing the Leaf state every minute or so.
Yesterday I started getting an error message from Nissan API: {"status":404,"message":"INVALID PARAMS"}
Nothing in the script I use has been changed, also my credentials have not changed. When I entered the credentials into the Android app, the app did (eventually) update the information.
Is this happening to other people as well?
BR,
Max

Yes, same issue here. NissanConnectEV 3.5.1 still works, also QuickLeaf is still working.

It seems that the pip repository is using filcole/pycarwings2 branch.
There a ticket has been opened and a solution has been found. I expect a PR soon.