TFLite 2.16.1 conversions fail with "AttributeError: 'Sequential' object has no attribute '_get_save_spec'"

1. System information

OS Platform and Distribution (e.g., Linux Ubuntu 16.04):
Debian 13 - Trixie
TensorFlow installation (pip package or built from source):
pip
TensorFlow library (version, if pip package or github SHA, if built from source):
2.16.0-rc0 & 2.16.1

I am brand new to TensorFlow and welcome any suggestions.
I tested the exact same code on 2.15.0.post1 and 2.16.x. It runs on 15 and errors out on 16
2. Code
Provide code to help us reproduce your issues using one of the following options:
Option B: Paste your code here or provide a link to a custom end-to-end colab

def main():

    # Removed dependance on argsparser()
    # args = argsparer()

    # batch_size = args.batchSize # 32
    batch_size = 32
    # img_height = args.height    # 128
    img_height = 128
    # img_width = args.width      # 128
    img_width = 128
    activation1 = 'swish'
    activation2 = 'elu'
    optimizer = tf.keras.optimizers.AdamW(learning_rate=0.0005)
    # epochs = args.epochs        # 1
    epochs = 1

    train_data_dir = pathlib.Path("{}/{}/".format(args.inputDir, args.trainingSubDir)).with_suffix('')
    val_data_dir = pathlib.Path("birds/birds/valid/".format(args.inputDir, args.validationSubDir)).with_suffix('')

    # assume all files in training directory are readable image files.
    image_count = len(list(train_data_dir.glob('*/*.*')))

    AUTOTUNE = tf.data.AUTOTUNE

    train_ds = tf.keras.utils.image_dataset_from_directory(
        train_data_dir,
        seed=random.randint(1, 10000),
        image_size=(img_height, img_width),
        batch_size=batch_size)

    val_ds = tf.keras.utils.image_dataset_from_directory(
        val_data_dir,
        # validation_split=0.1,
        # subset="validation",
        seed=random.randint(1, 10000),
        image_size=(img_height, img_width),
        batch_size=batch_size)

    num_classes = len(train_ds.class_names)
    print("Training directory '{}' contains {} images in {} categories.".format(train_data_dir, image_count, num_classes))

    normalization_layer = layers.Rescaling(1. / 255)
    train_ds_norm = train_ds.map(lambda x, y: (normalization_layer(x), y),
                                num_parallel_calls=tf.data.AUTOTUNE,
                                deterministic=False)
    val_ds_norm = val_ds.map(lambda x, y: (normalization_layer(x), y),
                                num_parallel_calls=tf.data.AUTOTUNE,
                                deterministic=False)

    # train_ds = train_ds.shuffle(1000).prefetch(buffer_size=AUTOTUNE)
    # val_ds = val_ds.prefetch(buffer_size=AUTOTUNE)

    data_augmentation = tf.keras.Sequential(
        [
            layers.RandomFlip("horizontal",
                              input_shape=(img_height,
                                           img_width,
                                           3)),
            layers.RandomRotation(0.1),
            layers.RandomZoom(0.1),
        ]
    )

    model = Sequential([
        data_augmentation,
        # layers.Rescaling(1./255, input_shape=(img_height, img_width, 3)),
        # layers.Conv2D(16, 3, padding='same', activation=activation1),
        # layers.MaxPooling2D(),
        layers.Conv2D(32, 3, padding='same', activation=activation1),
        layers.MaxPooling2D(),
        layers.Conv2D(48, 3, padding='same', activation=activation2),
        layers.MaxPooling2D(),
        layers.Conv2D(64, 3, padding='same', activation=activation1),
        layers.MaxPooling2D(),
        layers.Dropout(0.15),
        layers.Flatten(),
        layers.Dense(128, activation=activation2),
        layers.Dense(num_classes)
    ])

    model.compile(optimizer=optimizer,
              loss=tf.keras.losses.SparseCategoricalCrossentropy(from_logits=True),
              metrics=['accuracy'])

    history = model.fit(
        train_ds_norm,
        validation_data=val_ds_norm,
        epochs=epochs)

    # Convert the model.
    converter = tf.lite.TFLiteConverter.from_keras_model(model)
    converter.experimental_new_converter = True
    converter.target_spec.supported_ops = [
        tf.lite.OpsSet.TFLITE_BUILTINS,  # enable TensorFlow Lite ops.
        tf.lite.OpsSet.SELECT_TF_OPS  # enable TensorFlow ops.
    ]
    tflite_model = converter.convert()

    # Save the model.
    with open('model.tflite', 'wb') as f:
        f.write(tflite_model)

(You can paste links or attach files by dragging & dropping them below)

Include code to invoke the TFLite Converter Python API and the errors.
Provide links to your TensorFlow model and (optionally) TensorFlow Lite Model.

3. Failure after conversion
Conversion completely fails with "AttributeError: 'Sequential' object has no attribute '_get_save_spec'. Did you mean: '_set_save_spec'?" See below for complete log and traceback.
I have had to revert to 2.15.0.post1 to get model to convert and save as TFLite.
5. (optional) Any other info / logs
024-03-18 09:24:25.859843: I tensorflow/core/util/port.cc:113] oneDNN custom operations are on. You may see slightly different numerical results due to floating-point round-off errors from different computation orders. To turn them off, set the environment variable `TF_ENABLE_ONEDNN_OPTS=0`.
2024-03-18 09:24:25.884237: I tensorflow/core/platform/cpu_feature_guard.cc:210] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: AVX2 AVX512F AVX512_VNNI AVX512_BF16 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.
2024-03-18 09:24:26.564689: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.569165: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.569272: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.570638: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.570740: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.570825: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.616558: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.616674: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.616763: I external/local_xla/xla/stream_executor/cuda/cuda_executor.cc:998] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero. See more at https://github.com/torvalds/linux/blob/v6.0/Documentation/ABI/testing/sysfs-bus-pci#L344-L355
2024-03-18 09:24:26.616839: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1928] Created device /job:localhost/replica:0/task:0/device:GPU:0 with 11308 MB memory:  -> device: 0, name: NVIDIA RTX A4000, pci bus id: 0000:01:00.0, compute capability: 8.6
Found 84635 files belonging to 525 classes.
Found 2625 files belonging to 525 classes.
Training directory 'birds/birds/train' contains 84635 images in 525 categories.
/home/jschwefel/repositories/aiml/TensorFlow/tfbase/lib/python3.11/site-packages/keras/src/layers/preprocessing/tf_data_layer.py:19: UserWarning: Do not pass an `input_shape`/`input_dim` argument to a layer. When using Sequential models, prefer using an `Input(shape)` object as the first layer in the model instead.
  super().__init__(**kwargs)
2024-03-18 09:24:29.337903: E tensorflow/core/grappler/optimizers/meta_optimizer.cc:961] layout failed: INVALID_ARGUMENT: Size of values 0 does not match size of permutation 4 @ fanin shape inStatefulPartitionedCall/sequential_1_1/dropout_1/stateless_dropout/SelectV2-2-TransposeNHWCToNCHW-LayoutOptimizer
2024-03-18 09:24:29.937251: I external/local_xla/xla/stream_executor/cuda/cuda_dnn.cc:465] Loaded cuDNN version 8907
2645/2645 ━━━━━━━━━━━━━━━━━━━━ 46s 17ms/step - accuracy: 0.0066 - loss: 6.1631 - val_accuracy: 0.0579 - val_loss: 5.2888
Traceback (most recent call last):
  File "/home/jschwefel/repositories/aiml/TensorFlow/Test001/imageclassifier.py", line 129, in <module>
    main()
  File "/home/jschwefel/repositories/aiml/TensorFlow/Test001/imageclassifier.py", line 122, in main
    tflite_model = converter.convert()
                   ^^^^^^^^^^^^^^^^^^^
  File "/home/jschwefel/repositories/aiml/TensorFlow/tfbase/lib/python3.11/site-packages/tensorflow/lite/python/lite.py", line 1175, in wrapper
    return self._convert_and_export_metrics(convert_func, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/jschwefel/repositories/aiml/TensorFlow/tfbase/lib/python3.11/site-packages/tensorflow/lite/python/lite.py", line 1129, in _convert_and_export_metrics
    result = convert_func(self, *args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/jschwefel/repositories/aiml/TensorFlow/tfbase/lib/python3.11/site-packages/tensorflow/lite/python/lite.py", line 1641, in convert
    self._freeze_keras_model()
  File "/home/jschwefel/repositories/aiml/TensorFlow/tfbase/lib/python3.11/site-packages/tensorflow/lite/python/convert_phase.py", line 215, in wrapper
    raise error from None  # Re-throws the exception.
    ^^^^^^^^^^^^^^^^^^^^^
  File "/home/jschwefel/repositories/aiml/TensorFlow/tfbase/lib/python3.11/site-packages/tensorflow/lite/python/convert_phase.py", line 205, in wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/jschwefel/repositories/aiml/TensorFlow/tfbase/lib/python3.11/site-packages/tensorflow/lite/python/lite.py", line 1582, in _freeze_keras_model
    input_signature = _model_input_signature(
                      ^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/jschwefel/repositories/aiml/TensorFlow/tfbase/lib/python3.11/site-packages/tensorflow/lite/python/tflite_keras_util.py", line 84, in model_input_signature
    input_specs = model._get_save_spec(  # pylint: disable=protected-access
                  ^^^^^^^^^^^^^^^^^^^^
AttributeError: 'Sequential' object has no attribute '_get_save_spec'. Did you mean: '_set_save_spec'?

    model = Sequential([
        data_augmentation,
        # layers.Rescaling(1./255, input_shape=(img_height, img_width, 3)),
        # layers.Conv2D(16, 3, padding='same', activation=activation1),
        # layers.MaxPooling2D(),
        layers.Conv2D(32, 3, padding='same', activation=activation1),
        layers.MaxPooling2D(),
        layers.Conv2D(48, 3, padding='same', activation=activation2),
        layers.MaxPooling2D(),
        layers.Conv2D(64, 3, padding='same', activation=activation1),
        layers.MaxPooling2D(),
        layers.Dropout(0.15),
        layers.Flatten(),
        layers.Dense(128, activation=activation2),
        layers.Dense(num_classes)
    ])

Sequential here might be imported from something other than tf.keras. Please take a look at #39001

Hi @schwefeljm,
Please provide complete reproducible code to debug the issue.
Thank You

    model = Sequential([
        data_augmentation,
        # layers.Rescaling(1./255, input_shape=(img_height, img_width, 3)),
        # layers.Conv2D(16, 3, padding='same', activation=activation1),
        # layers.MaxPooling2D(),
        layers.Conv2D(32, 3, padding='same', activation=activation1),
        layers.MaxPooling2D(),
        layers.Conv2D(48, 3, padding='same', activation=activation2),
        layers.MaxPooling2D(),
        layers.Conv2D(64, 3, padding='same', activation=activation1),
        layers.MaxPooling2D(),
        layers.Dropout(0.15),
        layers.Flatten(),
        layers.Dense(128, activation=activation2),
        layers.Dense(num_classes)
    ])

Sequential here might be imported from something other than tf.keras. Please take a look at #39001
@Aloqeely

I went through and forced 'tf.keras.models.Sequential' and it had no effect. Thank you for the suggestions, though.
Jason

I was able to replicate on tf-nightly as well as 2.16.1. gist, I reduced the reproducible sample to what mattered i.e. the training process is actually irrelevant. This appears to happen when using Keras with the TFLite converter in 2.16.1 onward.
Hi @haozha111, can you please take a look?

I'm experiencing the same error  here
converter = tf.lite.TFLiteConverter.from_keras_model(model)
tfmodel = converter.convert()
open ("mobilenetv2_finetuned.tflite" , "wb") .write(tfmodel)
```, is gonna help if I downgrade to an older version of Tensorflow?

I'm experiencing the same error here
converter = tf.lite.TFLiteConverter.from_keras_model(model)
tfmodel = converter.convert()
open ("mobilenetv2_finetuned.tflite" , "wb") .write(tfmodel)

Is it gonna help if I downgrade to an older version of Tensorflow?

@Takudzwamz
For me it did.

Hi @Takudzwamz, it seems like 2.15 does not exhibit this behavior currently.

@pkgoogle I downgraded to 2.15 and it worked, thanks.

As @Lerxp stated, using Legacy Keras is the preferred workaround for now:
import os;os.environ["TF_USE_LEGACY_KERAS"]="1"

I'm having the same issue, but Legacy Keras isn't working either.

Hi @gusbernard, do you have a notebook or code snippet to share? Additionally have you tried using 2.15 for now? Thanks for any information you can provide.

I  met the same problem when I using tensorflow2.6.1 in python3.12.3, I tried to downgrade tensorflow to 2.15.0, while it not support python3.12.3. I am trying to downgrade python now...

I have the same issue when trying to convert a keras model to TFLite exactly like in the docs.
Python     3.12.3
Keras      3.3.3
Tensorflow 2.16.1

I used model.export() to solve this problem.
# Export the keras model to a saved model format
model.export("saved_model")

# Convert the saved model to TensorFlow Lite
converter = tf.lite.TFLiteConverter.from_saved_model("saved_model")
tflite_model = converter.convert()

# Save the TensorFlow Lite model to a file
with open("model.tflite", "wb") as f:
    f.write(tflite_model)

Hi @schwefeljm, have you heard of AI-Edge-Torch?, you can find more information here: googleblog.
I have created a script for converting your model here:
import torch
import torch.nn as nn
import ai_edge_torch

class CustomCVModel(nn.Module):
    def __init__(self, num_classes, img_height, img_width, activation1=nn.SiLU, activation2=nn.ELU):
        super().__init__()

        self.feature_extractor = nn.Sequential(
            nn.Conv2d(3, 32, kernel_size=3, padding="same"),
            activation1(),
            nn.MaxPool2d(2),
            nn.Conv2d(32, 48, kernel_size=3, padding="same"),
            activation2(),
            nn.MaxPool2d(2),
            nn.Conv2d(48, 64, kernel_size=3, padding="same"),
            activation1(),
            nn.MaxPool2d(2),
            nn.Dropout(0.15),
            nn.Flatten(),
        )

        self.classifier = nn.Sequential(
            nn.Linear(64 * (img_height // 8) * (img_width // 8), 128),
            activation2(),
            nn.Linear(128, num_classes)
        )

    def forward(self, x):
        x = self.feature_extractor(x)
        x = self.classifier(x)
        return x

img_height = 128
img_width = 128
model = CustomCVModel(1000, img_height, img_width, nn.SiLU, nn.ELU)
sample_inputs = (torch.randn(1, 3, img_height, img_width),)

edge_model = ai_edge_torch.convert(model.eval(), sample_inputs)
edge_model.export("custom_cv_model.tflite")

You will still need to modify your training code but I have tested this and the conversion does work w/o issue.
If you want to, you can actually try visualizing the result in model-explorer as well.
Please try them out and let us know if this resolves your issue. If you still need further help, feel free to open a new issue at the respective repo.

@pkgoogle I downgraded to 2.15 and it worked, thanks.
I am facing trouble in downgrading my TF, can you share how you did and what was your python version?

I have the same issue with a Keras 3 model saved into .keras format and reloaded with keras.models.load_model():
import keras as ks
import tensorflow as tf

model = ks.models.load_model("model.keras")
converter = tf.lite.TFLiteConverter.from_keras_model(model)

This is the error message:
Traceback (most recent call last):
  File "/home/bartoli/Projects/deeplab/deploy.py", line 29, in <module>
    deployment.deploy(args.model, args.output, args.quantize, quant_ds)
  File "/home/bartoli/Projects/deeplab/lib/deployment.py", line 67, in deploy
    converted = converter.convert()
                ^^^^^^^^^^^^^^^^^^^
  File "/home/bartoli/miniconda3/envs/dl/lib/python3.12/site-packages/tensorflow/lite/python/lite.py", line 1175, in wrapper
    return self._convert_and_export_metrics(convert_func, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/bartoli/miniconda3/envs/dl/lib/python3.12/site-packages/tensorflow/lite/python/lite.py", line 1129, in _convert_and_export_metrics
    result = convert_func(self, *args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/bartoli/miniconda3/envs/dl/lib/python3.12/site-packages/tensorflow/lite/python/lite.py", line 1641, in convert
    self._freeze_keras_model()
  File "/home/bartoli/miniconda3/envs/dl/lib/python3.12/site-packages/tensorflow/lite/python/convert_phase.py", line 215, in wrapper
    raise error from None  # Re-throws the exception.
    ^^^^^^^^^^^^^^^^^^^^^
  File "/home/bartoli/miniconda3/envs/dl/lib/python3.12/site-packages/tensorflow/lite/python/convert_phase.py", line 205, in wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/home/bartoli/miniconda3/envs/dl/lib/python3.12/site-packages/tensorflow/lite/python/lite.py", line 1582, in _freeze_keras_model
    input_signature = _model_input_signature(
                      ^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/bartoli/miniconda3/envs/dl/lib/python3.12/site-packages/tensorflow/lite/python/tflite_keras_util.py", line 84, in model_input_signature
    input_specs = model._get_save_spec(  # pylint: disable=protected-access
                  ^^^^^^^^^^^^^^^^^^^^
AttributeError: 'Sequential' object has no attribute '_get_save_spec'. Did you mean: '_set_save_spec'?

I'm having this issue as well.

Some folks are mentioning that the legacy keras switch doesn't work for
them.  If you're having trouble with it, confirm that it is placed before
your keras import statements.  For reference, I am using Python 3.12.3 and
Keras 3.2.1 and have no issues when the flag is set at the top of my script
as
import os
os.environ["TF_USE_LEGACY_KERAS"] = "1"
On Thu, Jul 18, 2024 at 7:34 AM Luke Xu @.***> wrote:

I'm having this issue as well.
—
Reply to this email directly, view it on GitHub
https://github.com/tensorflow/tensorflow/issues/63867#issuecomment-2236384110,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AHGB4LZBE7KPV7CEF4PPYJ3ZM6Y7DAVCNFSM6AAAAABE3W6JW6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMZWGM4DIMJRGA
.
You are receiving this because you were mentioned.Message ID:
@.***>

I coudn't downgrade tf version beacuse of python version ;however upgrading tf to 2.17 solves the problem.

downgrading to the following versions resolved the issue:
TensorFlow version: 2.13.0
Here's how you can install these versions:
pip install tensorflow==2.13.0

Hi All, this more or less has been fixed with the 2.17 release, that is the preferable method. If you are having problems with the latest release like this, please create a new issue for it. Thanks.


RxMoya multiple requests breaks chain. Only last request is fired

Libraries used

pod 'Moya/RxSwift', '~> 14.0'

I'm doing a first network request then save information and for every element in that array do a details network request.
Now everything works fine when the first call only has 1 element. When it has multiple elements the chain stops working.
    self.dependencies.apiService.getOrganisation()
        .flatMap { $0.organisations.sync(coreDataStack: self.dependencies.coreDataStack, user: self.input.currentUser) }
        .asObservable()
        .flatMap { objects in Observable.from(objects) }
        .filter { !$0.templateIds.isEmpty }
        .flatMap { object in
            self.dependencies.apiService.getTemplateDetails(ids: object.templateIds)
        }
        .subscribeOn(SerialDispatchQueueScheduler(qos: .background))
        .observeOn(MainScheduler.instance)
        .subscribe(onNext: { result in
            print("event \(result)")
        }, onError: { error in
            print("error \(error)")
        }, onCompleted: {
            print("completed")
        }, onDisposed: {
            print("disposed")
        }).disposed(by: self.disposeBag)

func getOrganisation() -> Maybe
func getTemplateDetails(ids: [String]) -> Maybe

Network
    func request<T: TargetType, D: Decodable>(
        _ target: T,
        outputClass: D.Type
    ) -> Maybe<D> {
        return provider.rx.request(MultiTarget(target)).filterSuccessfulStatusCodes().map(outputClass).asMaybe()
    }

What happens is that only the last details call is really fired the first detail call is lost somehow.
When I remove the getTemplateDetails and just switch in a Maybe that always returns success the chain works perfect. So it seems that it has something to do with multiple calls that the first one is cancelled or something like that?

Use .debug() for debugging all rx flows.
Try to debug call:
.....
self.dependencies.apiService
    .getTemplateDetails(ids: object.templateIds)
    .debug("getTemplateDetails \(object.[something])")
.....

What do you get in the logs?
Also show method func getTemplateDetails(ids: [String]) -> Maybe for more details

        self.dependencies.apiService.getOrganisation()
            .flatMap { $0.organisations.sync(coreDataStack: self.dependencies.coreDataStack, user: self.input.currentUser) }
            .asObservable()
            .flatMap { objects in Observable.from(objects).debug("DEBUG TO OBJECTS") }
            .filter { !$0.templateIds.isEmpty }
            .flatMap { object in
                self.dependencies.apiService.getTemplateDetails(ids: object.templateIds).debug("DEBUG Details call for objects \(object.templateIds)")
            }
            .subscribeOn(SerialDispatchQueueScheduler(qos: .background))
            .observeOn(MainScheduler.instance)
            .subscribe(onError: { error in
                print("Error syncing \(error.localizedDescription)")
                self.action.onNext(.showMessage(.warning(error.localizedDescription)))
            }) {
                print("Completed syncing")
                self.action.onNext(.showMessage(.success("Sync complete")))
            }.disposed(by: self.disposeBag)

    func getTemplateDetails(ids: [String]) -> Maybe<TemplateWrappedOutput> {
        return network.request(API.getTemplateDetails(ids), outputClass: TemplateWrappedOutput.self)
    }

    func request<T: TargetType, D: Decodable>(
        _ target: T,
        outputClass: D.Type
    ) -> Maybe<D> {
        return provider.rx.request(MultiTarget(target)).filterSuccessfulStatusCodes().map(outputClass).asMaybe().debug("DEBUG Call \(target)")
    }

This is the log:
2020-12-03 19:15:01.152: DEBUG Call getOrganisation -> subscribed
2020-12-03 19:15:03.037: DEBUG Call getOrganisation -> Event next(OrganisationWrappedOutput(organisations: [Organisation output ["8a7480b575b1f1aa017608e5cc330291"], Organisation output ["8a7480be73ca06e20174213294c30011"]]))
2020-12-03 19:15:03.052: DEBUG TO OBJECTS -> subscribed
2020-12-03 19:15:03.052: DEBUG TO OBJECTS -> Event next(Organisation output ["8a7480b575b1f1aa017608e5cc330291"])

2020-12-03 19:15:03.052: DEBUG Details call for objects ["8a7480b575b1f1aa017608e5cc330291"] -> subscribed
2020-12-03 19:15:03.053: DEBUG Call getTemplateDetails(["8a7480b575b1f1aa017608e5cc330291"]) -> subscribed

2020-12-03 19:15:03.067: DEBUG TO OBJECTS -> Event next(Organisation output ["8a7480be73ca06e20174213294c30011"])

2020-12-03 19:15:03.067: DEBUG Details call for objects ["8a7480be73ca06e20174213294c30011"] -> subscribed
2020-12-03 19:15:03.067: DEBUG Call getTemplateDetails(["8a7480be73ca06e20174213294c30011"]) -> subscribed

2020-12-03 19:15:03.079: DEBUG TO OBJECTS -> Event completed
2020-12-03 19:15:03.079: DEBUG TO OBJECTS -> isDisposed

2020-12-03 19:15:03.080: DEBUG Call getOrganisation -> Event completed
2020-12-03 19:15:03.080: DEBUG Call getOrganisation -> isDisposed

2020-12-03 19:15:03.735: DEBUG Call getTemplateDetails(["8a7480be73ca06e20174213294c30011"]) -> Event next(TemplateWrappedOutput(templates: [Detail Output 8a7480be73ca06e20174213294c30011]))
2020-12-03 19:15:03.736: DEBUG Details call for objects ["8a7480be73ca06e20174213294c30011"] -> Event next(TemplateWrappedOutput(templates: [Detail Output 8a7480be73ca06e20174213294c30011]))

2020-12-03 19:15:03.736: DEBUG Call getTemplateDetails(["8a7480be73ca06e20174213294c30011"]) -> Event completed
2020-12-03 19:15:03.736: DEBUG Details call for objects ["8a7480be73ca06e20174213294c30011"] -> Event completed
2020-12-03 19:15:03.736: DEBUG Details call for objects ["8a7480be73ca06e20174213294c30011"] -> isDisposed
2020-12-03 19:15:03.736: DEBUG Call getTemplateDetails(["8a7480be73ca06e20174213294c30011"]) -> isDisposed

As you can see there is a call fired for 8a7480b575b1f1aa017608e5cc330291 but nothing happens.

Anyone that can help me on this? The call is working perfectly in postman so that's not the problem.


How did you pre-process the dataset

Hi, thank you for this repository. How did you pre-process the dataset? Would you please share the method or upload the preprocessed dataset to another storage service (like google drive, for instance)? I am having trouble with LFS. I think it would be more useful if you share the preprocessing steps. Thank you!

Hi Carlos,
thank you for spending your time visiting and reviewing this repo.
1 - DATASET
I've used the UCF101 dataset that I found at this Kaggle page (but i noticed it doesn't exist anymore): https://www.kaggle.com/ash81197/vid-classification-ucf101/version/1
2 - PREPROCESSING
As you can see from this piece of code in data_loader.py
self.train_ds = tf.keras.preprocessing.image_dataset_from_directory(
            self.training_data_path,
            validation_split=0.2,
            subset="training",
            seed=345,
            image_size=(self.image_shape[0], self.image_shape[1]),
            batch_size=self.batch_size,
            label_mode='categorical',
            class_names=self.classes
        )

        self.val_ds = tf.keras.preprocessing.image_dataset_from_directory(
            self.training_data_path,
            validation_split=0.2,
            subset="validation",
            seed=345,
            image_size=(self.image_shape[0], self.image_shape[1]),
            batch_size=self.batch_size,
            label_mode='categorical',
            class_names=self.classes
        )

        self.test_ds = tf.keras.preprocessing.image_dataset_from_directory(
            self.test_data_path,
            seed=123,
            image_size=(self.image_shape[0], self.image_shape[1]),
            batch_size=self.batch_size,
            label_mode='categorical',
            class_names=self.classes
        )

        normalization_layer = tf.keras.layers.experimental.preprocessing.Rescaling(1. / 255)
        self.train_ds = self.train_ds.map(lambda x, y: (normalization_layer(x), y))
        self.val_ds = self.train_ds.map(lambda x, y: (normalization_layer(x), y))
        self.test_ds = self.test_ds.map(lambda x, y: (normalization_layer(x), y))

preprocessing is just a resizing of the images to whatever dimension you like + a simple normalization of pixel values.
I've  uploaded the dataset to this GDrive Link: https://drive.google.com/file/d/1cLC1ie8uVr51RBtQaDnEmI8kfO0oZy9Y/view?usp=sharing
Make sure to save this dataset as i'm finishing space on Drive and i'll remove it soon.

Hi Carlos,
thank you for spending your time visiting and reviewing this repo.
1 - DATASET
I've used the UCF101 dataset that I found at this Kaggle page (but i noticed it doesn't exist anymore): https://www.kaggle.com/ash81197/vid-classification-ucf101/version/1
2 - PREPROCESSING
As you can see from this piece of code in data_loader.py
self.train_ds = tf.keras.preprocessing.image_dataset_from_directory(
            self.training_data_path,
            validation_split=0.2,
            subset="training",
            seed=345,
            image_size=(self.image_shape[0], self.image_shape[1]),
            batch_size=self.batch_size,
            label_mode='categorical',
            class_names=self.classes
        )

        self.val_ds = tf.keras.preprocessing.image_dataset_from_directory(
            self.training_data_path,
            validation_split=0.2,
            subset="validation",
            seed=345,
            image_size=(self.image_shape[0], self.image_shape[1]),
            batch_size=self.batch_size,
            label_mode='categorical',
            class_names=self.classes
        )

        self.test_ds = tf.keras.preprocessing.image_dataset_from_directory(
            self.test_data_path,
            seed=123,
            image_size=(self.image_shape[0], self.image_shape[1]),
            batch_size=self.batch_size,
            label_mode='categorical',
            class_names=self.classes
        )

        normalization_layer = tf.keras.layers.experimental.preprocessing.Rescaling(1. / 255)
        self.train_ds = self.train_ds.map(lambda x, y: (normalization_layer(x), y))
        self.val_ds = self.train_ds.map(lambda x, y: (normalization_layer(x), y))
        self.test_ds = self.test_ds.map(lambda x, y: (normalization_layer(x), y))

preprocessing is just a resizing of the images to whatever dimension you like + a simple normalization of pixel values.
I've  uploaded the dataset to this GDrive Link: https://drive.google.com/file/d/1cLC1ie8uVr51RBtQaDnEmI8kfO0oZy9Y/view?usp=sharing
Make sure to save this dataset as i'm finishing space on Drive and i'll remove it soon.


CL release v2024-04-05

CL release v2024-04-05

All the CL edits PRs are reflected in the diff file.


Hive engine can't work property

Describe the bug
A clear and concise description of what the bug is.

SET export PS1='<\u@\h $PWD $>' to .bashrc of user's environment for pretty show.
Running the hql on dss which  failed due to timeout.

To Reproduce
Steps to reproduce the behavior:

Go to 'dss'
Click on 'hql excute'
Scroll down to 'waiting for result'
See error and not result

Expected behavior
A clear and concise description of what you expected to happen.
Would like to get the result from the hql.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):

OS: CentOS Linux release 7.7.1908
Browser  chrome
Version wedatasphere-dss-web-0.7.0  wedatasphere-linkis-0.9.3

Smartphone (please complete the following information):

Device: None
OS: None
Browser None
Version None

Additional context
Optimize the logic of  script rootScript.sh to make dss  more reliable for customer.

Ok, this issue has been fixed


I want to give my opinion on version 2

good afternoon, I'll start by saying that your documentation is very good. and I chose you by comparing with many options
i am using the first version of your documentation
you are now actively developing version 2. but why then did I install the first version for myself?
I don't like the design of version 2. The first version was nicer to the eye. I'm talking specifically about the documentation pages
in general, while you haven't finished the second version, it may not be too late to fix the design. It's hard for me to explain what exactly is wrong, I'm not a designer. in version 2, the fonts, text sizes, colors are different and as a result it is not read as pleasantly as it was in version 1
sorry my bad english, i translated in translator
who agree with me, write +
maybe I'm not the only one who thinks so, thank you all again. your service is great (version 1)

good afternoon, I'll start by saying that your documentation is very good. and I chose you by comparing with many options

Thanks

you are now actively developing version 2. but why then did I install the first version for myself?

How can I answer that 😅  we advise to use v2

I don't like the design of version 2. The first version was nicer to the eye. I'm talking specifically about the documentation pages

The v2 is fully customizable, so even if the default look-and-feel does not please you, you can achieve what you want anyway.
Look at the showcase for v2 site examples:
https://v2.docusaurus.io/showcase
With custom designs:

https://reactnative.dev/
https://vector.dev/
https://developers.diem.com/
https://questdb.io/

in general, while you haven't finished the second version, it may not be too late to fix the design. It's hard for me to explain what exactly is wrong, I'm not a designer. in version 2, the fonts, text sizes, colors are different and as a result it is not read as pleasantly as it was in version 1

Changing everything about the current design will annoy many v2 users. We have way more v2 users than v1 users (https://www.npmtrends.com/docusaurus-vs-@docusaurus/core)
We'll definitively try to improve (I share some of your opinions about text readability), but it's hard to do changes if you don't have any concrete suggestions to make
I'm closing as I'm not sure about the value of leaving this issue open. Please discuss a specific detail you want to be changed if you have a more concrete idea regarding what we should do.

ok, so here's a suggestion: make the background darker like it did in version 1 and / or make the text color lighter. because when completely black text on a completely white background, it looks too contrast
for example, these themes look nicer to me than the standard one:
https://infinum.github.io/eightshift-docs/docs/basics/basics
https://support.hashnode.com/docs/mapping-domain/


How to create a uvc_frame_t in c++

How can I create a uvc_frame_t type in c++?

Import libuvc.h, then make sure to link against libuvc at compile time. In the code itself you can just treat it as any C struct - I.E. you can just malloc memory for it. Keep in mind that when start_streaming is called, it expects a callback function that receives a uvc_frame_t pointer as a parameter, and this is generated by the library itself, not by you.

You don't malloc a uvc_frame_t*, it must be made using uvc_allocate_frame. This can be called from C++ as well as C.


Mocker is undefined

I'm trying to unit test a token service, but I get the error:
TypeError: Cannot read property 'getAllMatchingActions' of undefined
    at MethodStubVerificator.times (/Users/ryuuji3/Projects/Node/restaurant-manager/restaurant-manager-server/node_modules/ts-mockito/src/MethodStubVerificator.ts:32:63)
    at MethodStubVerificator.once (/Users/ryuuji3/Projects/Node/restaurant-manager/restaurant-manager-server/node_modules/ts-mockito/src/MethodStubVerificator.ts:20:14)
    at Object.<anonymous> (/Users/ryuuji3/Projects/Node/restaurant-manager/restaurant-manager-server/src/services/token.spec.ts:46:11)
    at Generator.next (<anonymous>)
    at fulfilled (/Users/ryuuji3/Projects/Node/restaurant-manager/restaurant-manager-server/src/services/token.spec.ts:4:58)
    at <anonymous>

Here is my test:
  describe('issue()', () => {
    let mockRepository : TokenRepository, repository : TokenRepository
    let user : User
    let jwt : string
    let token: Token
    let service : TokenService

    before(async () => {
      mockRepository = mock(TokenRepository)
      user = mockUser('example')

      let payload : PayloadI = Token.createPayload(user)
      jwt = await Token.sign(payload)
      token = await Token.create(user, jwt)

      when(mockRepository.register(user, jwt)).thenResolve(token)

      repository = instance(mockRepository)
      service = new TokenService(repository)
    })

    it('should call repository.register()', async () => {
      await service.issue(user)
        verify(
          repository.register(user, jwt)
        ).once()
    })
  })

Any idea of what's going wrong?
EDIT:
It appears I should have read the documentation better.
In order to check for behaviour, rather than return, you must verify the mocker method not the instance method.
Sorry!

Verify should be called on mock not on instance. Looks similar to #90 issue

Thank you, just noticed that when I re-read the documentation. Sorry about that!

No problem, this just shows that we got not too good API and got to do something with that.

Or if it's common enough of an issue, perhaps a helpful "Did you mean to call the mocker method instead?" would help. It makes much more sense now that I know, I don't think it's that bad.

Ohh! Sometimes the simplest ideas are the best. I'll try to add this as "work around" for now if it will be possible. Thanks!

No, thank you for your hard work! Maybe even easier would just be to add a note on the README, then no code changes need to be made. The error message makes sense already, just didn't realize it at the time.


doc: add tutorial to convert input ts to tilted

Say you receive a ts that includes
ghi
or
ghi, dhi, dni
would be nice to demonstrate how to convert the values to poa_global.
It would be complementary to the  existing or a variation thereof:
https://github.com/jforbess/pvlib-python/blob/master/docs/tutorials/tmy_and_diffuse_irrad_models.ipynb

I don't understand your proposal. Plane of array calculations are documented in the tutorial you linked to, the irradiance.ipynb notebook, and the documentation.
Feel free to create a pull request with improvements.

That's what I plan.
But you can keep it closed since it's not a bug...


feat(cadl): support literal type model property

change json coverter for InputModelProperty to set the DefaultValue property if the property type is a literal type

update ObjectTypeProperty so that DefaultValue is set if it's from literal type

change ModelTypeProviderFields:

exclude literal properties from constructor parameter list
literal properties are internal readonly

change ModelTypeProvider, update the criteria on properties to be serialized, now literal type property will be serialized regardless it's read-only
fix a issue in emitter that boolean literal type is not identified
minor refactoring
update test projects

resolve #3035
Description
Add your description here!
Checklist
To ensure a quick review and merge, please ensure:

[ ] The PR has a understandable title and description explaining the why and what.
[ ] The PR is opened in draft if not ready for review yet.

If opened in draft, please allocate sufficient time (24 hours) after moving out of draft for review

[ ] The branch is recent enough to not have merge conflicts upon creation.

Ready to Land?

[ ] Build is completely green

Submissions with test failures require tracking issue and approval of a CODEOWNER

[ ] At least one +1 review by a CODEOWNER
[ ] All -1 reviews are confirmed resolved by the reviewer

Override/Marking reviews stale must be discussed with CODEOWNERS first

A couple of changes since last review:

Modify emitter to add basic support of differentiating integer from float. We'll not try to identify the full list of CADL number types. Instead, we just support int32 for integer value and double for float value.
Remove literal type properties from generated deserialization codes
Add E2E test case

@m-nash I've committed change to treat literal type operation parameters as constant parameters (see the last 2nd commit). However, I think it's still better to handle that in the emitter, because:

By the meaning, it's a constant. It's more like a compiler optimization, v.s. type/name mapping which should be handled in generator.
Previously it's handled outside generator. When autorest passes in the parameters, their types are already decided.
We don't have a neat encapsulation on this issue. I have to change a few places in the codes, instead of one line code change in the emitter.
Another option is to write a Json converter to transform the Kind property. But that's almost equal to change in the emitter.


Makes add and explain policy rest APIs use new metadata service

Issue #, if available:
Description of changes:
SPI

Makes IndexMetadataService.getMetadata into a suspend method
Adds indexCreationDate to ManagedIndexMetadata
Adds loadExtensions code to populate the list of action parsers and metadata providers from the plugin extensions
Creates the DefaultIndexMetadataService to use a cluster state rest call to get a map of index names to index uuid and creation date given a list of index names
Adds IndexMetadataProvider class to manage the map of index types to metadata services

if an IndexMetadataService is added for an index type which is already mapped, an error is thrown, the cluster would fail to start

Add Policy

Makes add policy rest API use the default index metadata service provided by the IndexMetadataProvider.
As the metadata service resolves index names, the index name resolver was removed from the add policy transport
Following that, validating index permissions needed to occur before other validations, as we don't want to include the resolved index name of an index which the user does not have permissions to view in the failedIndices response

Explain

Combines ExplainAll into Explain, making totalManagedIndices and enabledState included in all explain responses.
Adds typealias and constants to the TransportExplainAction class
Uses indexMetadataProvider to resolve index names and get index names and types from the provider specific to the index type

Change

Uses indexMetadataProvider to resolve index names and get index names and types from the provider specific to the index type

CheckList:

[X] Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Codecov Report

Merging #245 (a2d3e0e) into development-extension (a902b37) will increase coverage by 3.63%.
The diff coverage is 70.97%.

@@                     Coverage Diff                     @@
##             development-extension     #245      +/-   ##
===========================================================
+ Coverage                    66.47%   70.11%   +3.63%
- Complexity                    1586     1657      +71
===========================================================
  Files                          249      250       +1
  Lines                         9996    10112     +116
  Branches                      1552     1568      +16
===========================================================
+ Hits                          6645     7090     +445
+ Misses                        2531     2141     -390
- Partials                       820      881      +61

Impacted Files
Coverage Δ

...anagement/indexstatemanagement/ISMActionsParser.kt
75.00% <0.00%> (-5.49%)
:arrow_down:

...ment/indexstatemanagement/util/RestHandlerUtils.kt
100.00% <ø> (+36.66%)
:arrow_up:

...ment/indexstatemanagement/IndexMetadataProvider.kt
15.38% <15.38%> (ø)

...ent/indexstatemanagement/util/ManagedIndexUtils.kt
72.03% <41.66%> (+7.41%)
:arrow_up:

...agement/indexstatemanagement/ManagedIndexRunner.kt
46.75% <50.00%> (+16.96%)
:arrow_up:

...statemanagement/resthandler/RestAddPolicyAction.kt
76.19% <50.00%> (+1.19%)
:arrow_up:

...temanagement/resthandler/RestChangePolicyAction.kt
90.00% <50.00%> (+37.36%)
:arrow_up:

...ent/transport/action/addpolicy/AddPolicyRequest.kt
70.00% <55.55%> (-14.62%)
:arrow_down:

...ansport/action/changepolicy/ChangePolicyRequest.kt
70.00% <55.55%> (+0.76%)
:arrow_up:

...agement/transport/action/explain/ExplainRequest.kt
86.20% <63.63%> (-13.80%)
:arrow_down:

... and 43 more

Continue to review full report at Codecov.

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


After successful purchase on iOS: Purchased Stream is not firing

Steps to reproduce

Request a purchase by buying a consumable or non-consumable product.
Enter necessary credentials if needed (e.g., email, password).
Click on Sign In.

Expected results
The 'Purchased' stream should fire after a successful purchase on iOS.
Actual results
The 'Purchased' stream is not firing after a successful purchase on iOS and Bottom sheet to purchase the product is popping up again after the purchase is complete.
Code sample
Future purchaseSubscription({required String subscriptionId}) async {
final bool available = await InAppPurchase.instance.isAvailable();
if (available) {
log(available.toString(), name: "Yes available");
Set kIds = {subscriptionId};
final ProductDetailsResponse response = await InAppPurchase.instance.queryProductDetails(kIds);

  if (response.productDetails.isEmpty) {
    log("No products found");
  } else {
    log(response.productDetails.first.title);
  }
  List<ProductDetails> products = response.productDetails;

  if (products.isNotEmpty) {
    try {
      // final isPurchased =
      await InAppPurchase.instance.buyNonConsumable(
        purchaseParam: PurchaseParam(productDetails: products.first),
        // autoConsume: false,
      );
    } catch (e) {
      log(e.toString());
      try {
        await InAppPurchase.instance.restorePurchases();
      } catch (e) {
        log(e.toString());
        if (context.mounted) {
          Utils.showSnackBar(context, const Text("Something went wrong"));
        }
      }
    }
  }
  // The store cannot be reached or accessed. Update the UI accordingly.
}
}

void listenToPurchase() {
// InAppPurchase.instance.getPlatformAddition();
purchaseStreamSubscription = InAppPurchase.instance.purchaseStream.listen(onPurchaseData, onDone: () {
Utils.showSnackBar(context, const Text("Purchase Done"));
// purchaseStreamSubscription?.cancel();
}, onError: (error) {
Utils.showSnackBar(context, Text(error.toString()));
});
}

void onPurchaseData(List event) {
for (var purchaseDetail in event) {
if (purchaseDetail.pendingCompletePurchase) {
InAppPurchase.instance.completePurchase(purchaseDetail);
log("Pending complete Purchase");
}
switch (purchaseDetail.status) {
case PurchaseStatus.pending:
Utils.showSnackBar(context, const Text("Purchase Pending"));
case PurchaseStatus.purchased:
log("message");
Utils.showSnackBar(context, const Text("Purchased"));
case PurchaseStatus.error:
Utils.showSnackBar(context, const Text("Purchase Error"));
case PurchaseStatus.restored:
Utils.showSnackBar(context, const Text("Purchase Restored"));
case PurchaseStatus.canceled:
Utils.showSnackBar(context, const Text("Purchase Cancelled"));
}
}
}

Screenshots or Video

Screenshots / Video demonstration
[Upload media here]

Logs
Logs
[Paste your logs here]

Flutter Doctor output
Details

[✓] Flutter (Channel stable, 3.16.8, on macOS 14.3 23D56 darwin-arm64, locale en-IN)
    • Flutter version 3.16.8 on channel stable at /Users/mubashshir/Developer/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 67457e669f (2 weeks ago), 2024-01-16 16:22:29 -0800
    • Engine revision 6e2ea58a5c
    • Dart version 3.2.5
    • DevTools version 2.28.5

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/mubashshir/Library/Android/sdk
    • Platform android-34, build-tools 34.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.7+0-17.0.7b1000.6-10550314)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.2)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15C500b
    • CocoaPods version 1.14.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2023.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.7+0-17.0.7b1000.6-10550314)

[✓] VS Code (version 1.85.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.81.20231227

[✓] Connected device (5 available)
    • sdk gphone64 arm64 (mobile)          • emulator-5554                        • android-arm64  • Android 12 (API 32) (emulator)
    • Android SDK built for arm64 (mobile) • emulator-5556                        • android-arm64  • Android 10 (API 29) (emulator)
    • iPhone 15 Plus (mobile)              • C4241C4F-4449-470A-8016-BA7D3CFBC45A • ios            • com.apple.CoreSimulator.SimRuntime.iOS-17-2
      (simulator)
    • macOS (desktop)                      • macos                                • darwin-arm64   • macOS 14.3 23D56 darwin-arm64
    • Chrome (web)                         • chrome                               • web-javascript • Google Chrome 121.0.6167.85

[✓] Network resources
    • All expected network resources are available.

• No issues found!

Thanks for filing this @mubashshirfirdausispacetotech.
Looking through https://github.com/flutter/flutter/issues/139415, it seems to be similar/related to your issue, can you please check this out?


Setting cacheAsBitmap=true on a Container translates positions on its children if they have a mask

Setting cacheAsBitmap=true on a Container that contains a child that's a Graphic masked with a Sprite offsets the Graphic to the bottom right.
(Container->Graphic->Sprite mask)
Expected Behavior
cacheAsBitmap should maintain the Graphic's position. No visual difference should occur after setting cacheAsBitmap=true
Current Behavior
Setting cacheAsBitmap=true on the container translates the Graphic to the bottom right.
Steps to Reproduce
See: https://www.pixiplayground.com/#/edit/cuRi6fT3x7QHWL7cNxRNM
This example:

Creates a circle Graphic
Sets the Pixi rabbit Sprite as the mask for this graphic
Puts both in a Container
Waits 5 seconds and sets cacheAsBitmap to true on the Container

On Chrome this will show the Pixi rabbit masked in the top left of the container. The example waits 5 seconds and then sets cacheAsBitmap=true. This shifts the Graphic to the lower right eliding parts of the rabbit. Poor rabbit.
Environment
This was working as expected in versions <5 but seems to be consistently reproducible for versions >= 5.0.4.

pixi.js version: 5.1.4
Browser & Version:  Chrome 67
OS & Version: Ubuntu 18.04
Running Example: https://www.pixiplayground.com/#/edit/cuRi6fT3x7QHWL7cNxRNM

Good catch! Reproduced it on dev.

Actually that's a bigger problem: any filter that calculates sprite position doesn't account for projection transform stuff.


Conduct a timeboxed investigation for running a developer image on Google Cloud to build .bdb files

Closing this for now since - for the time being - .bdb files will be built by the lab.


[BUG] InvalidSubscriptionId whenconnectingtoArc #49

use of the env variable that gets set during the azcm installation is not available in the process context. So sourcing it from the machine explicitly always.

fix for #49


If the page doesnt exist the script gives error

can this be fixed somehow? Thank you

I think the page should exist if this code is executed :
webdriver.get('https://www.instagram.com/accounts/login/?source=auth_switcher')


SOLR-16811: fix echo and mapUniqueKeyOnly params at /update/json/docs.

https://issues.apache.org/jira/browse/SOLR-16811

@mkhludnev I assume you saw the precommit errors!

Absolutely, @epugh


problem at "python setup.py build develop"

I follow the INSTALL.md, but got a problem at last step like:
$ python setup.py build develop
running build
running build_py
running build_ext
Traceback (most recent call last):
File "setup.py", line 68, in
cmdclass={"build_ext": torch.utils.cpp_extension.BuildExtension},
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/site-packages/setuptools/init.py", line 143, in setup
return distutils.core.setup(**attrs)
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/distutils/core.py", line 148, in setup
dist.run_commands()
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/distutils/command/build.py", line 135, in run
self.run_command(cmd_name)
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/distutils/cmd.py", line 313, in run_command
self.distribution.run_command(command)
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/site-packages/setuptools/command/build_ext.py", line 78, in run
_build_ext.run(self)
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/site-packages/Cython/Distutils/old_build_ext.py", line 186, in run
_build_ext.build_ext.run(self)
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/distutils/command/build_ext.py", line 339, in run
self.build_extensions()
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/site-packages/torch/utils/cpp_extension.py", line 210, in build_extensions
self._check_abi()
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/site-packages/torch/utils/cpp_extension.py", line 333, in _check_abi
check_compiler_abi_compatibility(compiler)
File "/mnt/lvdisk1/gongtao/software/Anaconda3-5.3.0/envs/maskrcnn_benchmark/lib/python3.7/site-packages/torch/utils/cpp_extension.py", line 188, in check_compiler_abi_compatibility
compiler = '{} {}'.format(compiler, version.group(0))
AttributeError: 'list' object has no attribute 'group'
my environment is:
ubuntu 14.04
gcc version is 7.3.0
pytorch-nightly-gpu installed, version: 1.0.0.dev20181119
cuda 8.0
cudnn v5.1
Is this the reason of cuda and cudnn?
Thank you!

Your gcc version might be not compatible. I also have problems with gcc7 before. Pls check with gcc 5.4 to see if it helps.

Your gcc version might be not compatible. I also have problems with gcc7 before. Pls check with gcc 5.4 to see if it helps.

Yes. I change to gcc 4.9.4 and the problem is solved

Hi,
I'm opening an issue in main PyTorch to keep them aware of this issue, which happens with PyTorch C++ extensions itself.

I solve this problem by changing pytorch-nightly version 1.0.0.dev20181119 to 1.0.0.dev20181116

@olgaliak I just opened a new issue in PyTorch to get this fixed https://github.com/pytorch/pytorch/issues/14502
The fix is pretty simple, and just requires removing the .group() I believe.
But you'll still have the warning due to ABI incompatibility

This PR should fix it https://github.com/pytorch/pytorch/pull/14505

Fixed in latest version of PyTorch


feat: add feature pills to ios/android sdks

🚀 Deployed on https://66f4983b9b626105b576ddca--cozy-fox-0defec.netlify.app


force onMonthChange with setMonth

Hello
I am adding events with ajax, with the onMonthChange event, like sugested in the issue #120.
onMonthChange is fired after changing month, OK. But it is not fired on the initialization of the calendar, and even after executing
myCalendar.setMonth("February", { withCallbacks: true });

The problem I think is, onChangeMonth is not fired if the month in setMonth is the same as the current month.
Is there a way to force onChangeMonth with setMonth, or is there a better method to add events with ajax? Thank you.
Kind regards

@nicomollet you are correct and this is by design— onMonthChange only gets called when the month changes. I would suggest taking whatever logic you have inside of onMonthChange, putting in its own function, and calling that function when you instantiate your clndr instance.
In other words...
function getEventsForMonth(month) {
  // take the `month` object and use it to request the correct month
  $.ajax({
    // request something like `/events/2016/04`
    url: '/events/' + month.format('YYYY/MM'),
    success: function(events) {
      clndr.setEvents(events);
    }
  });
}

var clndr = $('#my-calendar').clndr({
  onMonthChange: getEventsForMonth
});

// initial call to `getEventsForMonth` with the current month
getEventsForMonth(moment());

Thanks for your reply, I will do it your way.


Admin endpoints not using authentication

Upon doing this lab at re:Invent 2022, I noticed that admin endpoint for tenant-management (/api/tenants) is not using claims for authentication, being exposed. I suggest this being addressed for more become more adequate to how real-life apps would work.

Great catch, thanks for reporting. We'll get that in.


FEAT: transform all 200-level responses

Extract the first 200-level response (as opposed to only 200), and use that for validation.
Use case: POST that returns the newly created entity, or a runningJobId (for example).

also requires changes to the templates
https://github.com/acrontum/generate-it-typescript-server/pull/44

also this is going to master again not develop

oops - updated the base.
Makes sense, but should I tag it before or after the merge?

doesn't really matter than much.
but once you release the core and tpl try and tag the tpl as quick as possible to prevent issues.


Line chart: fixed the check dataColors options array for emptyness

Related issue
Fix #42
Due to options wasn't passed in Line object, it was getting options.dataColors as the [ ] empty due to which it wasn't getting any colors to plot
Screenshot before and after this change
I was using index.html charts example to test things out, so i had used the empty options for Line chart to replicate
before

after

@timqian Just wondering if you get chance to see this PR?

@ajduke Thabks for the PR. And sorry for the late reply. I was doing some other stuff recently and haven't spent much time on this project recently. I will put more time in this repo after next week.
Abou this PR, after a quick look at the change. I failed to tell if this is the best way or not. I will review it again soon

Using object.assign to define default values seems a better way: https://github.com/nfriedly/express-rate-limit/blob/master/lib/express-rate-limit.js#L5

Using object.assign to define default values seems a better way: https://github.com/nfriedly/express-rate-limit/blob/master/lib/express-rate-limit.js#L5

https://github.com/timqian/chart.xkcd/pull/47/files#diff-fbc43a77b4e8fe64398aa79145272a6bR151-R152
Is that comment for the above code? instead of function for checking empty array, use Object.assign. Is my understanding correct?

Hi @ajduke
I fixed this issue on https://github.com/timqian/chart.xkcd/commit/cef9ba26d5e27fb75ae028c536dabd3a4d143489#diff-fbc43a77b4e8fe64398aa79145272a6bR33
By using Object Spread( the Object.assign in es6).


Adding Android 13 Permissions into PermissionsAndroid

Android 13 introduces multiple new permission.
This PR aims to updates the documentation for multiple new permission that android 13 introduce that have been merged to master in the core repo.
- `BODY_SENSORS_BACKGROUND`: 'android.permission.BODY_SENSORS_BACKGROUND'
- `READ_MEDIA_IMAGES`: 'android.permission.READ_MEDIA_IMAGES'
- `READ_MEDIA_VIDEO`: 'android.permission.READ_MEDIA_VIDEO'
- `READ_MEDIA_AUDIO`: 'android.permission.READ_MEDIA_AUDIO'
- `POST_NOTIFICATION`: 'android.permission.POST_NOTIFICATIONS'
- `NEARBY_WIFI_DEVICES`: 'android.permission.NEARBY_WIFI_DEVICES'

Related PR
https://github.com/facebook/react-native/pull/33471
Based on the commit, this should be available in React Native starting from v0.70.0-rc.0

Updated the docs with more Android 13 related permissions
Ref: https://github.com/facebook/react-native/pull/33965/files

Thank you <3 @Simek


Travis fixes

This upgrades slog and distributary to fix the build failure we saw on Travis earlier. Also checked in Cargo.lock and added a few sleep()s after mutations in the tests.

@ms705: wanna merge this? :) removed the commits that are already in master, so it's basically just the extra sleep() calls needed for the tests.

Bah.. Missed what repo this was on. But still, seems fine :p

yeah, should be good 👍 thanks :)


Per-layer prior precision for linear last layer

Hi,
Thank you for this great library :-)
I was wondering, if there is a reason you cannot specify per-layer prior precisions for the last-layer Laplace approximation? I know this sounds contradictory, but for e.g. a linear last layer I think the n_layers attribute is actually 2, since you have one parameter group for the weights and one for the biases.
In my case, I was trying to set different prior precisions for the weights and biases but got an error from prior_precision_diag in LLLaplace when calling fit_laplace. I could implement this with a full diagonal prior, but I guess I would be optimizing over n_params parameters in opimize_prior_precision later instead of just 2.

How about doing it "manually", similar to the one in the example? https://github.com/AlexImmer/Laplace/blob/8f24a72cfbcd0829c8cdce5452fda5c696693026/examples/regression_example.py#L38-L44
In your case, it would be something like:

Define your 2 scalar variables tau_w, tau_b to optimize.
Define your optimizer opt
Repeat
3.1. Create a diagonal prior precision based on the two scalar. E.g. the first n_w prior precisions are all tau_w and the remaining are all tau_b. Make sure that this is differentiable, e.g. use torch.ones and indexing.
3.2. Feed this diagonal prior prec. into la.log_marginal_likelihood and call backward.
3.3. opt.step() on tau_w and tau_b.

Thank you for the quick reply and suggestion. That seems like a good way to do it, thanks!


Feature/upload file

CSV file load support

This change is

Just remembered we need to up the version too.


xfce4 in WSL2 crashed without access to the internet

Version
Microsoft Windows [Version 10.0.19044.1586]
WSL Version

[X] WSL 2
[ ] WSL 1

Kernel Version
5.4.71
Distro Version
Ubuntu 20.04
Other Software
I use xfce4-session and there nothing special just Pycharm IDE and chrome

That how I run GUI

%windir%\system32\cmd.exe /c start ubuntu2004.exe run "if [ -z \"$(pidof xfce4-session)\" ]; then export XDG_RUNTIME_DIR=~/XDG; export DISPLAY=$(awk '/nameserver / {print $2; exit}' /etc/resolv.conf 2>/dev/null):0 ; sudo /etc/init.d/dbus start &> /dev/null; xfwm4 & xfce4-session ;  pkill '(gpg|ssh)-agent' ; fi;" /high

So, if I run dbus it ask a password and if I forgot enable hotspot before do that it will not just launch

Repro Steps

Tether internet from a mobile phone and connect to the shared network via host OS
run WSL2
disable hotspot or go range away
that will crash in a minutes

OR

run WSL2 without connection to the internet
that will crash in a minutes, or even won't launch xfce

**I have an access point between host OS and mobile phone, so even I go out of range computer always connected to router
but WSL crash if no internet connection
** there no some special logs
Expected Behavior
That should not crash without internet
Actual Behavior
But that crash always I take my phone and go out of range
Just disable hospot and after a minute I see only black screen in wsl
Diagnostic Logs
No logs, just nothing. At least in ubuntu2004.exe output
UPD: after hours this was logged

Gdk-Message: 10:19:05.564: wrapper-2.0: Fatal IO error 11 (Resource temporarily unavailable) on X server <IP_ADDRESS>:0.

Gdk-Message: 10:19:05.564: wrapper-2.0: Fatal IO error 11 (Resource temporarily unavailable) on X server <IP_ADDRESS>:0.

Gdk-Message: 10:19:05.564: wrapper-2.0: Fatal IO error 11 (Resource temporarily unavailable) on X server <IP_ADDRESS>:0.

Gdk-Message: 10:19:05.564: wrapper-2.0: Fatal IO error 11 (Resource temporarily unavailable) on X server <IP_ADDRESS>:0.

Gdk-Message: 10:19:15.805: wrapper-2.0: Fatal IO error 11 (Resource temporarily unavailable) on X server <IP_ADDRESS>:0.

/logs


systemd-ctl uplifts

This is a series of patches which helps get systemctl-win easier to maintain, compile and some also contains some fixes.

Closing this PR due to branch name.
New PR available on: https://github.com/dcos/dcos-windows/pull/116.


Version Update to Cucumber v2

The javascript Cucumber package updated to v2 and this package is no longer compatible with the new approach to defining step definitions.  There is likely other potential updates needed as well.
Just wanted to bring this to the attention of the maintainers.  I am thinking I may take a quick stab at this this weekend and see what I can do but ultimately this will likely need a major version bump and I'm not sure how you want to handle it.
Thanks for the great package.

Hi @michaelshaffer37 - thanks!
Yes we are aware of the underlying changes to cucumber. Possible workaround is to use ^1 for the cucumber version in package.json but we must upgrade apickli to be compatible.
There is also 1 other PR (that changes the openapi wording in gherkin statements) which will also go in apickli V2. I don't think I will be able to work on this for the next 3 weeks but after I return from holidays this will be at the top of my list.
This backwards incompatible work will also give us an opportunity to get community feedback to see what other things people want to be changed in apickli. So comments welcome!

#106 is coming to fix this.

fixed by 58a347d4cc62046149ace65dd90d763866f69014


Machine pool scheduler hints

Allow a MachinePool to specify its capacity and its allocatable resources
Update docs, openapi & generated code

As per offline discussion with @afritzler we should consider how to correctly represent a MachinePool being able to schedule a Machine with a MachineClass either with 'mode' = Distinct (i.e. a whole integer resource being consumed) or 'mode' = Shared (i.e. deduct resources from memory / cpu).


Usage with render()?

Hi,
I'm trying to integrate this component into my project, but I can't get it to render. I've read through the Usage and README, but it doesn't seem to include any examples of how to render the grid inside a component's render() function. I'm using react 15.x
Here's my render function:
render: function() {
        const {unit} = this.props;
        const AbsoluteGrid = createAbsoluteGrid(DraggableItem);

        return (

                    <button type="button">Add new... </button>

                    <AbsoluteGrid items={unit.items}
                                  keyProp="id"
                                  sortProp="displayOrder"
                                  responsive={true}
                                  dragEnabled={true}/>

        )
    }

And here's my DisplayComponent:
class DraggableItem extends React.PureComponent {

    render() {
        const {item} = this.props;

        return (

{item.name}

        );
    }
}

Running the project and that page just gives me an empty div where the AbsoluteGrid should be.
However, when making an edit and triggering a re-build, it re-renders the page, and the grid shows (although it's not functional). Is there something I'm doing wrong?

The const AbsoluteGrid = createAbsoluteGrid(DraggableItem); should only need to be done once outside of the render, other then that I don't see anything wrong.

@jrowny I too am
render() {
    const AbsoluteGrid =  createAbsoluteGrid(RegistryItemCell);
    return(
      <AbsoluteGrid items={this.props.registryTileData}
                    onMove={onMoveDebounced}
                    dragEnabled={true}
                    zoom={zoom}
                    responsive={true}
                    verticalMargin={42}
                    itemWidth={230}
                    itemHeight={409}/>
    )
  }

I get an error Warning: setState(...): Can only update a mounted or mounting component. This usually means you called setState() on an unmounted component. Can you advise on the proper way to render the grid when including in a React.Component?

@richessler this component uses composition to create the actual grid component. This composition is done once, by placing it inside the render() you're doing it every time it renders. It needs to be somewhere else even outside your component. It's the same idea as when you use connect() in Redux... you're composing that component.


fix: don't merge all resolver msg

This is combining the buffer and json object

 (1/1) [database] New Lease Lender Field


Documentation issue with ConnectCondition

The documentation is conflicted about the ConnectCondition.
In basic_stream::connect it says:

A function object that is called prior to each connection attempt. The signature of the function object must be:
bool connect_condition(
error_code const& ec,
typename Protocol::endpoint const& next);

In basic_stream::async_connect it says:

A function object that is called prior to each connection attempt. The signature of the function object must be:
bool connect_condition(
error_code const& ec,
Iterator next);

Depending on my code, the compiler says one or the other:
        stream_.async_connect(
            begin,
            end,
            [this](boost::beast::error_code const& ec, auto const& next)
            {
                std::cout << "Trying: " << next << std::endl;
                return true;

            },
            std::move(handler));

connector.cpp:32:41: error: no match for ‘operator<<’ (operand types are ‘std::basic_ostream’ and ‘const boost::asio::ip::basic_resolver_iteratorboost::asio::ip::tcp’)
32 |                 std::cout << "Trying: " << next << std::endl;

So it's an iterator?
But with this:
        stream_.async_connect(
            begin,
            end,
            [this](boost::beast::error_code const& ec, auto const& next)
            {
                std::cout << "Trying: " << next->endpoint() << std::endl;
                return true;

            },
            std::move(handler));

connector.cpp:32:44: error: base operand of ‘->’ has non-pointer type ‘const boost::asio::ip::basic_resolver_entryboost::asio::ip::tcp’
32 |                 std::cout << "Trying: " << next->endpoint() << std::endl;

So now it's a resolver_entry?

Interesting.
Do I take it that you are suggesting that the timeout should be per-connect-attempt rather than overall for the entire connect operation?
In the past I have written code to attempt to connect to all resolved enpoints simultaneously and accept the first successful connected socket. It's a little antisocial though.

when you say "depending on my code", what do you mean exactly?

when you say "depending on my code", what do you mean exactly?

Assuming that it is supposed to be an endpoint then this should work: std::cout << "Trying: " << next << std::endl;
However, the compiler says it can't, because next is an endpoint iterator.
So when I change the code to derefence the endpoint it is pointing to like so: std::cout << "Trying: " << next->endpoint() << std::endl;,
it now says next is an endpoint.
I am sure auto const& next is the problem, because when I replace that by endpoint const& next, then << next << works.

Interesting.
Do I take it that you are suggesting that the timeout should be per-connect-attempt rather than overall for the entire connect operation?

I don't know about should, but yes, that is what I would prefer. However, that would conflict with Asio, would it not?
In my production code, I have a class that solves this by taking an iterator from the resolver and trying one at a time, until a succesful connect, or until reaching boost::asio::ip::tcp::resolver::iterator().
A timer is set for every attempt and if it goes of, the next in line is attempted.

when you say "depending on my code", what do you mean exactly?

Assuming that it is supposed to be an endpoint then this should work: std::cout << "Trying: " << next << std::endl;
However, the compiler says it can't, because next is an endpoint iterator.
So when I change the code to derefence the endpoint it is pointing to like so: std::cout << "Trying: " << next->endpoint() << std::endl;,
it now says next is an endpoint.
I am sure auto const& next is the problem, because when I replace that by endpoint const& next, then << next << works.

Without seeing the context of the code, I'm shooting in the dark. It's possible that neither overload has been selected because they would be ambiguous.
I tend to find with asio that it's better to specify the handler arguments explicitly. Otherwise about 1 time in 10 I have a problem.

Interesting.
Do I take it that you are suggesting that the timeout should be per-connect-attempt rather than overall for the entire connect operation?

I don't know about should, but yes, that is what I would prefer. However, that would conflict with Asio, would it not?
In my production code, I have a class that solves this by taking an iterator from the resolver and trying one at a time, until a succesful connect, or until reaching boost::asio::ip::tcp::resolver::iterator().
A timer is set for every attempt and if it goes of, the next in line is attempted.

This seems like a sensible solution. I think it would be diffucult to try to provide a fully generic solution without pushing developers into corners in which they'd rather not be pushed.

On 20-04-2020 16:49, Richard Hodges wrote:

Without seeing the context of the code, I'm shooting in the dark. It's
possible that neither overload has been selected because they would be
ambiguous.
I tend to find with asio that it's better to specify the handler
arguments explicitly. Otherwise about 1 time in 10 I have a problem.

Yes, never mind, I have found the same. It is more likely than not
indeed a problem with template deduction. I have double checked the code
just to be sure and next is supposed to be an endpoint.

On 20-04-2020 16:53, Richard Hodges wrote:

    Interesting.
    Do I take it that you are suggesting that the timeout should
    be per-connect-attempt rather than overall for the entire
    connect operation?

I don't know about should, but yes, that is what I would prefer.
However, that would conflict with Asio, would it not?

In my production code, I have a class that solves this by taking
an iterator from the resolver and trying one at a time, until a
succesful connect, or until reaching
|boost::asio::ip::tcp::resolver::iterator()|.
A timer is set for every attempt and if it goes of, the next in
line is attempted.

This seems like a sensible solution. I think it would be diffucult to
try to provide a fully generic solution without pushing developers
into corners in which they'd rather not be pushed.

My former solution was specific to tcp::socket, because that was what I
was working with at the time.
I have since refactored the code into a generic solution, that takes a
stream as a template argument. The only requirement is that the stream
class has an async_connect member that takes an endpoint and a
completion handler as arguments, and that has a close member. Like
tcp_stream and tcp::socket for instance.
Here is its interface, I can provide full source if anyone is interested:
explicit connector(StreamType& stream) noexcept;
template <
        typename EndpointSequence,
        typename Handler>
    void async_connect(
        EndpointSequence endpoints,
        Handler&& handler) noexcept;
template <
        typename EndpointSequence,
        typename ConnectCondition,
        typename Handler>
    void async_connect(
        EndpointSequence endpoints,
        ConnectCondition condition,
        Handler&& handler) noexcept;
void cancel() noexcept;
void expires_after(std::chrono::seconds expiry_time) noexcept;
I have only implemented the async_connect case, but adding a synchronous
connect would be trivial. The expires_after member defines how long
before an individual connection attempt will time out.

I copied the javadoc from Asio, so it might need adjusting.

@ErikvLinstee
Hi Eric, it's been a little while since you reported this issue.
Is there specific action you'd like me to take, or can I go ahead and close the issue?

Fix the documentation, I guess. If I recall correctly, the ConnectCondition is using an endpoint, not an iterator.


Add Python3 compatible Python Remote Library

The official list of remote libraries (https://code.google.com/p/robotframework/wiki/RemoteLibrary) lists PythonRemoteServer as the reference for a Python-based remote server.
This server code works great with Python2, but is not compatible with Python3.  I attempted to port the code to Python3, and got through the simple changes, but am now running into "TypeError: a bytes-like object is required, not 'str'" when running tests.
I would submit this issue under the PythonRemoteServer project, but the project looks abandoned.  I believe it is the responsibility of the RF community to have an example Python-based remote keyword server available for folks to reference.

PythonRemoteServer project is not abandoned. Nobody just had need and time to add any new features to it. Python 3 support is a good idea. It may require dropping support for versions prior to 2.6, though. Anyway, this discussion belongs to that project's tracker, not here.

Since I see much faster response in this forum, quick plug for https://github.com/robotframework/PythonRemoteServer/issues/29.  I even uploaded code that works for me, but needs some additional testing.
Thanks!


CAMEL-10798 Splitted hazelcast component into 11 which correspond to …

…each of endpoints
For post 2.19 release

Oops, I'll also update the camel-example-hazelcast-kubernates here soon

OK, good to go

Thanks we should wait till 2.19.0 is released so the master branch is "free" for such big changes

No problem, I can rebase it again once master get ready for 2.20 :)

@igarashitm do you mind rebase against master just in case something changed broke something, so we can get this merged?

Thanks for reminding me, done!

Ready to merge IMO

lgtm

I'm going to merge.

@igarashitm thanks the PR has been merged, can you close this?

Thanks! closing


Conditionally bundling assets based on flavor make tests to fail

Steps to reproduce

Create a new Flutter project (no need to create native flavors as this also fails with normal projects too)
Add a new asset image and register it under pubspec.yaml as a flavor asset
Create your app with an Image that references the image asset you just added to your project
Write your UI tests asserting the image will be there
Run your tests (with or without the --flavor param)
Tests are failing: Unable to load asset

Expected results

Create a new Flutter project (no need to create native flavors as this also fails with normal projects too)
Add a new asset image and register it under pubspec.yaml as a flavor asset
Create your app with an Image that references the image asset you just added to your project
Write your UI tests asserting the image will be there
Run your tests (with or without the --flavor param)
Tests are passing and assets are properly rendered under UI tests

Actual results
Unable to load assets, no matter if you pass or not the flavor parameter.
Also, if you don't configure conditional imports under pubspec.yaml, tests work like a charm:

Create a new Flutter project (no need to create native flavors as this also fails with normal projects too)
Add a new asset image and register it under pubspec.yaml
Create your app with an Image that references the image asset you just added to your project
Write your UI tests asserting the image will be there
Run your tests (with or without the --flavor param)
Tests are passing

Code sample
Code sample
import 'package:flutter/material.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
        useMaterial3: true,
      ),
      home: const MyHomePage(),
    );
  }
}

class MyHomePage extends StatelessWidget {
  const MyHomePage({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(),
      body: Center(
        child: Image.asset('assets/flavor/image.png'),
      ),
    );
  }
}

import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';

import 'package:flavor_assets_test/main.dart';

void main() {
  testWidgets('Expect Image', (tester) async {
    await tester.pumpWidget(const MyApp());

    expect(find.byType(Image), findsOneWidget);
  });
}

name: flavor_assets_test
description: "A new Flutter project."
publish_to: 'none'
version: 1.0.0+1

environment:
  sdk: '>=3.4.1 <4.0.0'
dependencies:
  flutter:
    sdk: flutter
dev_dependencies:
  flutter_test:
    sdk: flutter
  flutter_lints: ^3.0.0
flutter:
  uses-material-design: true

  assets:
    - path: assets/flavor/
      flavors:
        - flavor

Screenshots or Video
No response
Logs
Logs (with flavor argument)
fvm flutter test --flavor flavor
00:00 +0: loading /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart                                                                                00:01 +0: loading /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart                                                                                00:02 +0: loading /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart                                                                                00:03 +0: loading /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart                                                                                00:04 +0: loading /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart                                                                                00:04 +0: Expect Image                                                                                00:04 +0: Expect Image
══╡ EXCEPTION CAUGHT BY IMAGE RESOURCE SERVICE ╞════════════════════════════════════════════════════
The following assertion was thrown resolving an image codec:
Unable to load asset: "assets/flavor/image.png".
The asset does not exist or has empty data.

When the exception was thrown, this was the stack:
#0      PlatformAssetBundle.load (package:flutter/src/services/asset_bundle.dart:332:7)
#1      PlatformAssetBundle.loadBuffer (package:flutter/src/services/asset_bundle.dart:359:36)
#2      AssetBundleImageProvider._loadAsync (package:flutter/src/painting/image_provider.dart:754:33)
#3      AssetBundleImageProvider.loadImage (package:flutter/src/painting/image_provider.dart:714:14)
#4      ImageProvider.resolveStreamForKey.<anonymous closure> (package:flutter/src/painting/image_provider.dart:520:39)
#5      ImageCache.putIfAbsent (package:flutter/src/painting/image_cache.dart:377:22)
#6      ImageProvider.resolveStreamForKey (package:flutter/src/painting/image_provider.dart:517:81)
#7      ScrollAwareImageProvider.resolveStreamForKey (package:flutter/src/widgets/scroll_aware_image_provider.dart:104:19)
#8      ImageProvider.resolve.<anonymous closure> (package:flutter/src/painting/image_provider.dart:366:9)
#9      ImageProvider._createErrorHandlerAndKey.<anonymous closure> (package:flutter/src/painting/image_provider.dart:479:24)
#10     SynchronousFuture.then (package:flutter/src/foundation/synchronous_future.dart:43:39)
#11     ImageProvider._createErrorHandlerAndKey (package:flutter/src/painting/image_provider.dart:476:9)
#12     ImageProvider.resolve (package:flutter/src/painting/image_provider.dart:363:5)
#13     _ImageState._resolveImage (package:flutter/src/widgets/image.dart:1111:16)
#14     _ImageState.didChangeDependencies (package:flutter/src/widgets/image.dart:1061:5)
#15     StatefulElement._firstBuild (package:flutter/src/widgets/framework.dart:5636:11)
#16     ComponentElement.mount (package:flutter/src/widgets/framework.dart:5463:5)
...     Normal element mounting (28 frames)
#44     Element.inflateWidget (package:flutter/src/widgets/framework.dart:4340:16)
#45     MultiChildRenderObjectElement.inflateWidget (package:flutter/src/widgets/framework.dart:6904:36)
#46     MultiChildRenderObjectElement.mount (package:flutter/src/widgets/framework.dart:6916:32)
...     Normal element mounting (338 frames)
#384    Element.inflateWidget (package:flutter/src/widgets/framework.dart:4340:16)
#385    MultiChildRenderObjectElement.inflateWidget (package:flutter/src/widgets/framework.dart:6904:36)
#386    MultiChildRenderObjectElement.mount (package:flutter/src/widgets/framework.dart:6916:32)
...      See exception logs above.
  The test description was: Expect Image

To run this test again: /Users/angeloavv/fvm/versions/3.22.1/bin/cache/dart-sdk/bin/dart test /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart -p vm --plain-name 'Expect Image'
00:04 +0 -1: Some tests failed.

Logs (without flavor argument)
 fvm flutter test
Resolving dependencies...
Downloading packages...
  collection 1.18.0 (1.19.0 available)
  flutter_lints 3.0.2 (4.0.0 available)
  leak_tracker 10.0.4 (10.0.5 available)
  leak_tracker_flutter_testing 3.0.3 (3.0.5 available)
  lints 3.0.0 (4.0.0 available)
  material_color_utilities 0.8.0 (0.12.0 available)
  meta 1.12.0 (1.15.0 available)
  test_api 0.7.0 (0.7.2 available)
  vm_service 14.2.1 (14.2.4 available)
Got dependencies!
9 packages have newer versions incompatible with dependency constraints.
Try `flutter pub outdated` for more information.
00:00 +0: loading /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart                                                                                00:01 +0: loading /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart                                                                                00:01 +0: Expect Image                                                                                00:01 +0: Expect Image
══╡ EXCEPTION CAUGHT BY IMAGE RESOURCE SERVICE ╞════════════════════════════════════════════════════
The following assertion was thrown resolving an image codec:
Unable to load asset: "assets/flavor/image.png".
The asset does not exist or has empty data.

When the exception was thrown, this was the stack:
#0      PlatformAssetBundle.load (package:flutter/src/services/asset_bundle.dart:332:7)
#1      PlatformAssetBundle.loadBuffer (package:flutter/src/services/asset_bundle.dart:359:36)
#2      AssetBundleImageProvider._loadAsync (package:flutter/src/painting/image_provider.dart:754:33)
#3      AssetBundleImageProvider.loadImage (package:flutter/src/painting/image_provider.dart:714:14)
#4      ImageProvider.resolveStreamForKey.<anonymous closure> (package:flutter/src/painting/image_provider.dart:520:39)
#5      ImageCache.putIfAbsent (package:flutter/src/painting/image_cache.dart:377:22)
#6      ImageProvider.resolveStreamForKey (package:flutter/src/painting/image_provider.dart:517:81)
#7      ScrollAwareImageProvider.resolveStreamForKey (package:flutter/src/widgets/scroll_aware_image_provider.dart:104:19)
#8      ImageProvider.resolve.<anonymous closure> (package:flutter/src/painting/image_provider.dart:366:9)
#9      ImageProvider._createErrorHandlerAndKey.<anonymous closure> (package:flutter/src/painting/image_provider.dart:479:24)
#10     SynchronousFuture.then (package:flutter/src/foundation/synchronous_future.dart:43:39)
#11     ImageProvider._createErrorHandlerAndKey (package:flutter/src/painting/image_provider.dart:476:9)
#12     ImageProvider.resolve (package:flutter/src/painting/image_provider.dart:363:5)
#13     _ImageState._resolveImage (package:flutter/src/widgets/image.dart:1111:16)
#14     _ImageState.didChangeDependencies (package:flutter/src/widgets/image.dart:1061:5)
#15     StatefulElement._firstBuild (package:flutter/src/widgets/framework.dart:5636:11)
#16     ComponentElement.mount (package:flutter/src/widgets/framework.dart:5463:5)
...     Normal element mounting (28 frames)
#44     Element.inflateWidget (package:flutter/src/widgets/framework.dart:4340:16)
#45     MultiChildRenderObjectElement.inflateWidget (package:flutter/src/widgets/framework.dart:6904:36)
#46     MultiChildRenderObjectElement.mount (package:flutter/src/widgets/framework.dart:6916:32)
...     Normal element mounting (338 frames)
#384    Element.inflateWidget (package:flutter/src/widgets/framework.dart:4340:16)
#385    MultiChildRenderObjectElement.inflateWidget (package:flutter/src/widgets/framework.dart:6904:36)
#386    MultiChildRenderObjectElement.mount (package:flutter/src/widgets/framework.dart:6916:32)
...      See exception logs above.
  The test description was: Expect Image

To run this test again: /Users/angeloavv/fvm/versions/3.22.1/bin/cache/dart-sdk/bin/dart test /Users/angeloavv/StudioProjects/flavor_assets_test/test/widget_test.dart -p vm --plain-name 'Expect Image'
00:01 +0 -1: Some tests failed.

Flutter Doctor output
Doctor output
 fvm flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[!] Flutter (Channel stable, 3.22.1, on macOS 14.5 23F79 darwin-arm64, locale it-IT)
    ! Warning: `dart` on your path resolves to /opt/homebrew/Cellar/dart/3.2.3/libexec/bin/dart, which is not inside your current Flutter SDK checkout at /Users/angeloavv/fvm/versions/3.22.1. Consider adding /Users/angeloavv/fvm/versions/3.22.1/bin to the front of your path.
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 15.4)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2024.1)
[✓] IntelliJ IDEA Community Edition (version 2024.1.3)
[✓] Connected device (5 available)
[✓] Network resources

! Doctor found issues in 1 category.

Thanks for the detailed report @AngeloAvv

Write your UI tests asserting the image will be there
Run your tests (with or without the --flavor param)
Tests are failing: Unable to load asset

Since you are trying to run flutter test, according to https://github.com/flutter/flutter/pull/132985, the use case you are trying to achieve currently supports flutter run and flutter build only, so it may not be applicable to flutter test that you can check.
Also, /cc @andrewkolos for thoughts on the issue report.

Thanks for filing this (and thanks for tagging me)!
I think it's fair to call this a bug (or surprising behavior at the very least). If --flavor is supported in flutter test, then flavor-conditional asset bundling should work for it as well. I'll try to patch this.

I looked at the code that builds and writes the asset bundle for flutter test, and it looks like we pass along the flavor correctly. I got confused, because I originally thought I was able to repro this, but I must have made a mistake when setting up my test project. I attempted to repro again using a fresh project, and I was unable to.
@darshankawar would you mind trying to repro this?

Ok, @andrewkolos this looks weird. I was trying to share with you a repo to reproduce the code, so that's what I did.

I ran the tests one more time, they were failing both with or without the flavor arg
Init a .git repo
Run the tests again: for some reason this time "flutter test" did a pub get under the hood which also cleaned something, tests were working fine with both parameters

I wasn't able to reproduce the bug anymore!
So here's what I did.

I ran flutter clean
Run flutter test without flavor param, tests failed
Run flutter test with flavor param, tests are failing again

But if you do the opposite

I ran flutter clean
Run flutter test with flavor param, tests pass
Run flutter test without flavor param, tests are passing

Looks like the assets files are not updated or something like that every time you switch from one run to another.
Here's a repo with a Flutter project I created for you where I'm able to reproduce the bug

Ah okay, this could be a caching bug. I will take a second look.

Yeah, it looks like we don't take --flavor into account when invalidating the asset bundle used in tests. We only look at the asset files and pubspec:
https://github.com/flutter/flutter/blob/5e448f4ce57723ac0792ae822ebac69df3188ba1/packages/flutter_tools/lib/src/commands/test.dart#L709

Thank you @andrewkolos @darshankawar


Linting to unpollute metadata pull request

Changes in metadata expand/collapse PR had included linting, making reading the changes difficult. This commit contains all of the linting and none of the changes, so should make that PR more readable once merged

@andysellick looks fine


Documentation and wiki

The repo needs documentation of steps to follow up for replicating the project locally.

Wiki has been updated for kubernetes cluster creation


Consider splitting update of "devon-ide-scripts" and "settings+tools"

As discussed in #212 we maybe should split devon ide update into two separate things:

update of devon-ide-scripts (if available)
update of settings git repo and software according to «TOOL»_VERSION

How should we name the two new things then?

devon ide upgrade or devon ide update-scripts
devon ide update or devon ide update-project

I do not like the long versions update-bla-bla-bla very much. However short arguments will make it hard to distinguish the two and keep them properly in mind without mixing or confusing them.

An alternative would be to parameterize the command:

devon ide update scripts checks for updates of devon-ide-scripts
devon ide update settings updates the settings via git pull
devon ide update software checks the installed tools and their versions and installs updates/downgrades accordingly.
devon ide update without any further args would "only" update settings and software.
devon ide update all would be the current behavious: run all updates sequentially, if scripts get updated on windows, then this will run async and stop the further processing.

I think this would be a better kind of API for the CLI.
Also, I think that projects might want to avoid uncontrolled updates of devon-ide-scripts that have not been properly tested. Stability is one of the key features of devon-ide so decoupling this by default is IMHO a good idea while with the proposed change it is still easy and intuitive to update the scripts as well (but avoid accidental untested updates that may break a project in the future).
I would love to get some feedback and other point of views on such topics to more reflect the community.
WDYT?

Maybe I am too fast for others to react or too impatient to wait for feedback, but I have already implemented the latter suggestion as it made sense to me and is better that what we had before.
I am still happy to receive your feedback.
If you have a much better proposal even feel free to reopen the issue.
For the moment done with PR #233 and released with beta21.


Standardise tracking for MD toolbar buttons

https://trello.com/c/B9rVHJTh/876-audit-and-fix-gtm-ga-issues
Previously we set the same data-gtm attribute for all MD toolbar
buttons, which was used to scope the associated GTM trigger. This
modifies the data-gtm attributes to consistently reflect the action
performed, making events for these elements equivalent to other
data-gtm actions, avoiding premature grouping. Using the common
'markdown-toolbar' prefix to scope the GTM trigger should suffice.

@kevindew I didn't encounter that issue when I tried it. Presumably the extensions work the same as a normal button with it's content 🤷♂.

@kevindew I didn't encounter that issue when I tried it. Presumably the extensions work the same as a normal button with it's content 🤷♂.

Great thanks for checking it 👍It's possible I'm muddling memories.


React Native CLI loading indicator on iPhone X simulator

Its a little bug that on iPhone X simulator the loading screen goes off.
It hides behind the top part of iPhone, so the percentage of App Loaded can't be seen.
I think on iPhone X bringing it to the bottom would do the job. Or can be done with SafeAreaView  API

Well, sometimes automation sucks 😂

HI guys, react native cmd+D open debug menu for any simulator. But not working in iphone x. any idea?

It does work for me CMD+D


Progress feedback cleanup: make ProgressEventDispatcher API clearer

Originally from #1297
Make ProgressEventDispatcher API clearer (https://github.com/GoogleContainerTools/jib/pull/1330#discussion_r240724667)

This is too general, and it's not clear what the action items are. I'll close this. If we have a tangible proposal, we can create a new issue later.


Typo:  -> []

<file> is an optional parameter and, as such, should be enclosed in square brackets.

Nice catch, thanks @Sebelino!
This text comes from the --help of the buildkite-agent, so I've opened a corresponding PR over there. I'll merge this once that's gone out 😊

Thanks @Sebelino!! I merged your fix in fadc5ec ❤