[TF2.0] Bug or Feature? Keras model.summary() does not provide useful information for nested models

Please make sure that this is a bug. As per our GitHub Policy, we only address code/doc bugs, performance issues, feature requests and build/installation issues on GitHub. tag:bug_template
System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow):
OS Platform and Distribution (e.g., Linux Ubuntu 16.04):
Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device:
TensorFlow installed from (source or binary): pip
TensorFlow version (use command below): 2.0.0-dev20190424
Python version: 3.6
Bazel version (if compiling from source):
GCC/Compiler version (if compiling from source):
CUDA/cuDNN version: 10.0/7.5
GPU model and memory:

You can collect some of this information using our environment capture
script
You can also obtain the TensorFlow version with: 1. TF 1.0: python -c "import tensorflow as tf; print(tf.GIT_VERSION, tf.VERSION)" 2. TF 2.0: python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VERSION)"
Describe the current behavior
For the script below
import tensorflow as tf
import tensorflow.keras.layers as nn
from tensorflow.python.keras.backend import get_graph
from tensorflow.python.keras.utils.generic_utils import to_snake_case
from tensorflow.python.keras.engine.base_layer_utils import unique_layer_name

Module = tf.keras.models.Model

# class Module(tf.Module):
#     def __init__(self, name=None, **kwargs):
#         super(Module, self).__init__(name='dummy', **kwargs)
#         name = name or to_snake_case(self.__class__.__name__)
#         self._name = unique_layer_name(name, zero_based=True)
#
#     def __call__(self, *args, **kwargs):
#         with get_graph().as_default(), tf.name_scope(self.name):
#             return self.call(*args, **kwargs)

class Sequential(Module):
    def __init__(self, *args):
        super(Sequential, self).__init__()
        self.module_list = list(args) if args else []

    def call(self, x):
        for module in self.module_list:
            x = module(x)
        return x

class Block(Module):
    def __init__(self):
        super(Block, self).__init__()
        self.module = Sequential(
                nn.Dense(10),
                nn.Dense(10),)

    def call(self, input_tensor):
        x = self.module(input_tensor)
        return x

class Base(Module):
    def __init__(self):
        super(Base, self).__init__()
        self.module = Sequential(
                Block(),
                Block())

    def call(self, input_tensor):
        x = self.module(input_tensor)
        y = self.module(x)
        return x, y

class Network(Module):
    def __init__(self):
        super(Network, self).__init__()
        self.child = Base()

    def call(self, inputs):
        return self.child(inputs)

net = Network()

inputs = tf.keras.Input(shape=(10, ))
outputs = net(inputs)
model = tf.keras.models.Model(inputs=inputs, outputs=outputs)

print(model.summary(150))

The current output, probably doesn't provide any useful information:
Model: "model"
______________________________________________________________________________________________________________________________________________________
Layer (type)                                                       Output Shape                                                Param #
======================================================================================================================================================
input_1 (InputLayer)                                               [(None, 10)]                                                0
______________________________________________________________________________________________________________________________________________________
network (Network)                                                  ((None, 10), (None, 10))                                    440
======================================================================================================================================================
Total params: 440
Trainable params: 440
Non-trainable params: 0
______________________________________________________________________________________________________________________________________________________

Describe the expected behavior
If we uncomment the new Module class, the output is much more informative. I think this should be the expected behavior:
Model: "model"
______________________________________________________________________________________________________________________________________________________
Layer (type)                                     Output Shape                     Param #           Connected to
======================================================================================================================================================
input_1 (InputLayer)                             [(None, 10)]                     0
______________________________________________________________________________________________________________________________________________________
dense (Dense)                                    (None, 10)                       110               input_1[0][0]
                                                                                dense_3[0][0]
______________________________________________________________________________________________________________________________________________________
dense_1 (Dense)                                  (None, 10)                       110               dense[0][0]
                                                                                dense[1][0]
______________________________________________________________________________________________________________________________________________________
dense_2 (Dense)                                  (None, 10)                       110               dense_1[0][0]
                                                                                dense_1[1][0]
______________________________________________________________________________________________________________________________________________________
dense_3 (Dense)                                  (None, 10)                       110               dense_2[0][0]
                                                                                dense_2[1][0]
======================================================================================================================================================
Total params: 440
Trainable params: 440
Non-trainable params: 0
______________________________________________________________________________________________________________________________________________________

Code to reproduce the issue
Provide a reproducible test case that is the bare minimum necessary to generate the problem.
Other info / logs
Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached.

Note that the equivalent of this is done for plotting models https://github.com/keras-team/keras/pull/11431

@thuyen Able to reproduce the issue with the code provided (tried the uncomment code and with comment code). We will take a look at it. Thanks!

@muddham hi, I've run into this issue as well. Have you had a chance to take a look at it?

Is there any update on this?

hasnt this been fixed yer?

Any update on this issue? plot_model supports this with expand_nested = True but summary has no such argument and defaults to no expansion.

@thuyen
Please post this issue on keras-team/keras repo.
To know more see;
https://discuss.tensorflow.org/t/keras-project-moved-to-new-repository-in-https-github-com-keras-team-keras/1999


Rename to CoreAPI

In order to have a consistent naming, this API must be renamed

You should maybe create a general naming convention for the whole project.

That's the reason for the renaming


Bash functions aren't supported

Describe the bug
Trying to use bb.sh gives unsupported shell syntax error, looks like bash functions aren't supported. That file is pretty complex and would generally serve as good bash syntax test
Link to the blitz that caused the error
N/A
Steps to reproduce

get https://raw.githubusercontent.com/cfenollosa/bashblog/master/bb.sh
run it

Expected behavior
It should work
Screenshots

Hey there! Thanks for reporting this issue. That's right, you can't run arbitrary shell scripts at this point but we do plan to extend support for more functionality in the future.


preventCurveOverShooting is difficult to limit overshoot in the x-axis direction

Describe the bug
When my spot have non-uniform distance in the x-axis. (such as spot1:x = 1 , spot2:x = 2 , spot3:x = 20 .....
Some curve will overshooting in the x-axis.
I have use preventCurveOverShooting, if i use a bigger preventCurveOvershootingThreshold problem will be solved. but i will lose curve in some spot.
To Reproduce
import 'package:flutter/material.dart';
import 'package:fl_chart/fl_chart.dart';

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

class MyApp extends StatelessWidget {
  const MyApp({super.key});
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        body: Container(
          padding: const EdgeInsets.symmetric(vertical: 200, horizontal: 20),
          child: SizedBox(
            height: 300,
            child: LineChart(
              LineChartData(
                lineBarsData: [
                  LineChartBarData(
                    spots: getSpotData(),
                    isCurved: true,
                    curveSmoothness: 0.5,
                    preventCurveOverShooting: true,
                    preventCurveOvershootingThreshold: 10,
                  )
                ],
              ),
            ),
          ),
        ),
        // This trailing comma makes auto-formatting nicer for build methods.
      ),
    );
  }

  List<FlSpot> getSpotData() {
    List<FlSpot> spots = [];
    spots.add(const FlSpot(1.0, 1));
    spots.add(const FlSpot(2.0, 1));
    spots.add(const FlSpot(20.0, 1));
    spots.add(const FlSpot(21.0, 2));
    spots.add(const FlSpot(22.0, 3));
    return spots;
  }
}

Screenshots

Versions

Flutter version :  3.16.5
FlChart version : 0.68.0

Here is my way to solve this question.
I want know it is a good way to solve?


As a team owner, I can do specific actions that only team owners can do

Requirements

As a team owner with @acmecorp.com domain, I can:

transfer ownership of the team to someone else on my team with the same email domain only
invite people to my team
remove people from my team

As a team owner with @personalemail.com domain, I can:

invite people to my team
remove people to my team
transfer ownership to someone else on my team

This is done, although implemented differently: users can use whatever email domains and get all the functionality.


Question: addPermission

Hi, i'm working on a project at the moment where it is now necessary to run different integration tests against different amazon APIs one of them the is the sqsQueueApi.
The problem i'm facing now is our application uses the addPermission function and i'm trying to implement an "always successful" addPermission answer to elasticmq.
I've never worked with scala(or Akka/akkaHTTP) before so i'm stuck and hope someone could provide me some hints how to proceed further.
What i've done so far:
added a new AddPermissionDirectives in org.elasticmq.rest.sqs:
package org.elasticmq.rest.sqs

import Constants._
import org.elasticmq.actor.reply._
import org.elasticmq.rest.sqs.directives.ElasticMQDirectives

trait AddPermissionDirectives { this: ElasticMQDirectives with QueueURLModule =>
def addPermission(p: AnyParams) = {
  p.action("AddPermission") {
      respondWith {
        <AddPermissionResponse>
          <ResponseMetadata>
            <RequestId>{EmptyRequestId}</RequestId>
          </ResponseMetadata>
        </AddPermissionResponse>
      }
    }
  }
}

i also added this new Trait/Directive to the val env = new QueueManagerActorModule in the SQSRestServerBuilder.scala and added a matching route to rawRoutes in the same file.
But when I execute sbt > assembly in my project folder it throws a compiling error

[error] /home/marcel/dev/sources/elasticmq-server/rest/rest-sqs/src/main/scala/org/elasticmq/rest/sqs/SQSRestServerBuilder.scala:116: not found: type AddPermissionDirectives
[error]       with AddPermissionDirectives
[error]            ^
[error] /home/marcel/dev/sources/elasticmq-server/rest/rest-sqs/src/main/scala/org/elasticmq/rest/sqs/SQSRestServerBuilder.scala:146: not found: value addPermissions
[error]         addPermissions(p)
[error]         ^
[error] two errors found
[error] (elasticmq-rest-sqs/compile:compileIncremental) Compilation failed

I think the problem is a missing import or dependency somewhere, but i can't seem to figure out where or how to add my new route/trait correctly to the rest server.
Thanks in advance and thanks for this really helpful project!
My SQSRestServerBuilder.scala:
package org.elasticmq.rest.sqs

import java.io.ByteArrayOutputStream
import java.nio.ByteBuffer
import java.security.MessageDigest
import java.util.concurrent.TimeUnit
import java.util.concurrent.atomic.AtomicReference

import akka.actor.{ActorRef, ActorSystem, Props}
import akka.http.scaladsl.Http
import akka.http.scaladsl.server.{Directive1, Directives}
import akka.stream.ActorMaterializer
import akka.util.Timeout
import com.typesafe.config.ConfigFactory
import org.elasticmq._
import org.elasticmq.actor.QueueManagerActor
import org.elasticmq.rest.sqs.Constants._
import org.elasticmq.rest.sqs.directives.ElasticMQDirectives
import org.elasticmq.util.{Logging, NowProvider}

import scala.collection.immutable.TreeMap
import scala.collection.mutable.ArrayBuffer
import scala.concurrent.duration._
import scala.concurrent.{Await, Future}
import scala.util.control.Exception._
import scala.util.control.NonFatal
import scala.xml.{EntityRef, _}

/**
 * By default:
 *

 *
for `socketAddress`: when started, the server will bind to `localhost:9324`

 *
for `serverAddress`: returned queue addresses will use `http://localhost:9324` as the base address.

 *
for `sqsLimits`: relaxed
 *

 */
object SQSRestServerBuilder extends TheSQSRestServerBuilder(None, None, "", 9324, NodeAddress(), true, SQSLimits.Strict)

case class TheSQSRestServerBuilder(providedActorSystem: Option[ActorSystem],
                                   providedQueueManagerActor: Option[ActorRef],
                                   interface: String,
                                   port: Int,
                                   serverAddress: NodeAddress,
                                   generateServerAddress: Boolean,
                                   sqsLimits: SQSLimits.Value) extends Logging {

  /**
   * @param _actorSystem Optional actor system. If one is provided, it will be used to create ElasticMQ and Spray
   *                     actors, but its lifecycle (shutdown) will be not managed by the server. If one is not
   *                     provided, an actor system will be created, and its lifecycle will be bound to the server's
   *                     lifecycle.
   */
  def withActorSystem(_actorSystem: ActorSystem) = this.copy(providedActorSystem = Some(_actorSystem))

  /**
   * @param _queueManagerActor Optional "main" ElasticMQ actor.
   */
  def withQueueManagerActor(_queueManagerActor: ActorRef) = this.copy(providedQueueManagerActor = Some(_queueManagerActor))

  /**
   * @param _interface Hostname to which the server will bind.
   */
  def withInterface(_interface: String) = this.copy(interface = _interface)

  /**
   * @param _port Port to which the server will bind.
   */
  def withPort(_port: Int) = this.copy(port = _port)

  /**
   * Will assign port automatically (uses port 0). The port to which the socket binds will be logged on successful startup.
   */
  def withDynamicPort() = withPort(0)

  /**
   * @param _serverAddress Address which will be returned as the queue address. Requests to this address
   *                       should be routed to this server.
   */
  def withServerAddress(_serverAddress: NodeAddress) = this.copy(serverAddress = _serverAddress, generateServerAddress = false)

  /**
   * @param _sqsLimits Should "real" SQS limits be used (strict), or should they be relaxed where possible (regarding
   *                   e.g. message size).
   */
  def withSQSLimits(_sqsLimits: SQSLimits.Value) = this.copy(sqsLimits = _sqsLimits)

  def start(): SQSRestServer = {
    val (theActorSystem, stopActorSystem) = getOrCreateActorSystem
    val theQueueManagerActor = getOrCreateQueueManagerActor(theActorSystem)
    val theServerAddress = if (generateServerAddress) NodeAddress(host = if (interface.isEmpty) "localhost" else interface, port = port) else serverAddress
    val theLimits = sqsLimits

    implicit val implicitActorSystem = theActorSystem
    implicit val implicitMaterializer = ActorMaterializer()

    val currentServerAddress = new AtomicReference[NodeAddress](theServerAddress)

    val env = new QueueManagerActorModule
      with QueueURLModule
      with SQSLimitsModule
      with BatchRequestsModule
      with ElasticMQDirectives
      with CreateQueueDirectives
      with DeleteQueueDirectives
      with QueueAttributesDirectives
      with ListQueuesDirectives
      with SendMessageDirectives
      with SendMessageBatchDirectives
      with ReceiveMessageDirectives
      with DeleteMessageDirectives
      with DeleteMessageBatchDirectives
      with ChangeMessageVisibilityDirectives
      with ChangeMessageVisibilityBatchDirectives
      with GetQueueUrlDirectives
      with PurgeQueueDirectives
      with AddPermissionDirectives
      with AttributesModule {

      def serverAddress = currentServerAddress.get()
      lazy val actorSystem = theActorSystem
      lazy val materializer = implicitMaterializer
      lazy val queueManagerActor = theQueueManagerActor
      lazy val sqsLimits = theLimits
      lazy val timeout = Timeout(21, TimeUnit.SECONDS) // see application.conf
    }

    import env._
    def rawRoutes(p: AnyParams) =
        // 1. Sending, receiving, deleting messages
        sendMessage(p) ~
        sendMessageBatch(p) ~
        receiveMessage(p) ~
        deleteMessage(p) ~
        deleteMessageBatch(p) ~
        // 2. Getting, creating queues
        getQueueUrl(p) ~
        createQueue(p) ~
        listQueues(p) ~
        purgeQueue(p) ~
        // 3. Other
        changeMessageVisibility(p) ~
        changeMessageVisibilityBatch(p) ~
        deleteQueue(p) ~
        getQueueAttributes(p) ~
        setQueueAttributes(p) ~
        addPermissions(p)

    val config = new ElasticMQConfig

    implicit val bindingTimeout = Timeout(10, TimeUnit.SECONDS)

    val routes =
      handleServerExceptions {
        handleRejectionsWithSQSError {
          anyParamsMap { p =>
            if (config.debug) {
              logRequestResult("") {
                rawRoutes(p)
              }
            } else rawRoutes(p)
          }
        }
      }

    val appStartFuture = Http().bindAndHandle(routes, interface, port)

    appStartFuture.onSuccess {
      case sb: Http.ServerBinding =>
        if (generateServerAddress && port != sb.localAddress.getPort) {
          currentServerAddress.set(theServerAddress.copy(port = sb.localAddress.getPort))
        }

        TheSQSRestServerBuilder.this.logger.info("Started SQS rest server, bind address %s:%d, visible server address %s"
                .format(interface, sb.localAddress.getPort, if (env.serverAddress.isWildcard) "* (depends on incoming request path) " else env.serverAddress.fullAddress))
    }

    appStartFuture.onFailure {
      case NonFatal(e) =>
        TheSQSRestServerBuilder.this.logger.error("Cannot start SQS rest server, bind address %s:%d".format(interface, port), e)
    }

    SQSRestServer(appStartFuture, () => {
      appStartFuture.flatMap { sb =>
        stopActorSystem()
        sb.unbind()
      }
    })
  }

  private def getOrCreateActorSystem = {
    providedActorSystem
      .map((_, () => ()))
      .getOrElse {
      val actorSystem = ActorSystem("elasticmq")
      (actorSystem, () => {
        actorSystem.shutdown()
        actorSystem.awaitTermination()
      })
    }
  }

  private def getOrCreateQueueManagerActor(actorSystem: ActorSystem) = {
    providedQueueManagerActor.getOrElse(actorSystem.actorOf(Props(new QueueManagerActor(new NowProvider()))))
  }
}

case class SQSRestServer(startFuture: Future[Http.ServerBinding], stopAndGetFuture: () => Future[Any]) {
  def waitUntilStarted() = {
    Await.result(startFuture, 1.minute)
  }

  def stopAndWait() = {
    val stopFuture = stopAndGetFuture()
    Await.result(stopFuture, 1.minute)
  }
}

object Constants {
  val EmptyRequestId = "15639547-7534-1569-8246-865798464538"
  val SqsDefaultVersion = "2012-11-05"
  val ReceiptHandleParameter = "ReceiptHandle"
  val VisibilityTimeoutParameter = "VisibilityTimeout"
  val DelaySecondsAttribute = "DelaySeconds"
  val ReceiveMessageWaitTimeSecondsAttribute = "ReceiveMessageWaitTimeSeconds"
  val QueueArnAttribute = "QueueArn"
  val IdSubParameter = "Id"
  val InvalidParameterValueErrorName = "InvalidParameterValue"
  val QueueUrlContext = "queue"
}

object ParametersUtil {
  implicit class ParametersParser(parameters: Map[String, String]) {
    def parseOptionalLong(name: String) = {
      val param = parameters.get(name)
      try {
        param.map(_.toLong)
      } catch {
        case e: NumberFormatException => throw SQSException.invalidParameterValue
      }
    }
  }
}

object MD5Util {
  def md5Digest(s: String) = {
    val md5 = MessageDigest.getInstance("MD5")
    md5.reset()
    md5.update(s.getBytes)
    md5.digest().map(0xFF & _).map { "%02x".format(_) }.foldLeft(""){_ + _}
  }

  def md5AttributeDigest(attributes: Map[String, MessageAttribute]): String = {
    def addEncodedString(b: ByteArrayOutputStream, s: String) = {
      val str = s.getBytes("UTF-8")
      b.write(ByteBuffer.allocate(4).putInt(s.length).array) // Sadly, we'll need ByteBuffer here to get a properly encoded 4-byte int (alternatively, we could encode by hand)
      b.write(str)
    }

    def addEncodedByteArray(b: ByteArrayOutputStream, a: Array[Byte]) = {
      b.write(ByteBuffer.allocate(4).putInt(a.length).array)
      b.write(a)
    }

    val byteStream = new ByteArrayOutputStream

    TreeMap(attributes.toSeq: _*).foreach { case (k, v) => {
      // TreeMap is for sorting, a requirement of algorithm
      addEncodedString(byteStream, k)
      addEncodedString(byteStream, v.getDataType())

      v match {
        case s: StringMessageAttribute => {
          byteStream.write(1)
          addEncodedString(byteStream, s.stringValue)
        }
        case n: NumberMessageAttribute => {
          byteStream.write(1)
          addEncodedString(byteStream, n.stringValue.toString)
        }
        case b: BinaryMessageAttribute => {
          byteStream.write(2)
          addEncodedByteArray(byteStream, b.binaryValue)
        }
        case _ => throw new IllegalArgumentException(s"Unsupported message attribute type: ${v.getClass.getName}")
      }
    }
    }

    val md5 = MessageDigest.getInstance("MD5")
    md5.reset()
    md5.update(byteStream.toByteArray)
    md5.digest().map(0xFF & _).map { "%02x".format(_) }.foldLeft(""){_ + _}
  }
}

object XmlUtil {
  private val CR = EntityRef("#13")

  def convertTexWithCRToNodeSeq(text: String): NodeSeq = {
    val parts = text.split("\r")
    val partsCount = parts.length
    if (partsCount == 1) {
      Text(text)
    } else {
      val combined = new ArrayBuffer[scala.xml.Node]()
      for (i <- 0 until partsCount) {
        combined += Text(parts(i))
        if (i != partsCount - 1) {
          combined += CR
        }
      }

      combined
    }
  }
}

trait QueueManagerActorModule {
  def queueManagerActor: ActorRef
}

trait QueueURLModule {
  def serverAddress: NodeAddress

  import Directives._

  def baseQueueURL: Directive1[String] = {
    val baseAddress = if (serverAddress.isWildcard) {
      extractRequest.map { req =>
        val incomingAddress = req.uri.copy(rawQueryString = None, fragment = None).toString

        val incomingAddressNoSlash = if (incomingAddress.endsWith("/")) {
          incomingAddress.substring(0, incomingAddress.length - 1)
        } else incomingAddress

        // removing the final /queue or /queue/ if present, it will be re-added later
        if (incomingAddressNoSlash.endsWith(QueueUrlContext)) {
          incomingAddressNoSlash.substring(0, incomingAddressNoSlash.length - QueueUrlContext.length - 1)
        } else incomingAddressNoSlash
      }
    } else {
      provide(serverAddress.fullAddress)
    }

    baseAddress.map(_ + "/" + QueueUrlContext)
  }

  def queueURL(queueData: QueueData): Directive1[String] = {
    baseQueueURL.map(base => base + "/" + queueData.name)
  }
}

object SQSLimits extends Enumeration {
  val Strict = Value
  val Relaxed = Value
}

trait SQSLimitsModule {

  val NUMBER_ATTR_MAX_VALUE = BigDecimal.valueOf(10).pow(126)
  val NUMBER_ATTR_MIN_VALUE = -BigDecimal.valueOf(10).pow(128)

  def sqsLimits: SQSLimits.Value

  def ifStrictLimits(condition: => Boolean)(exception: String) {
    if (sqsLimits == SQSLimits.Strict && condition) {
      throw new SQSException(exception)
    }
  }

  def verifyMessageNumberAttribute(strValue: String) {
    ifStrictLimits(allCatch.opt(BigDecimal(strValue))
      .filter(v => v >= NUMBER_ATTR_MIN_VALUE)
      .filter(v => v <= NUMBER_ATTR_MAX_VALUE).isEmpty) {
      s"Number attribute value $strValue should be in range (-10**128..10**126)"
    }
  }

  def verifyMessageWaitTime(messageWaitTimeOpt: Option[Long]) {
    messageWaitTimeOpt.foreach { messageWaitTime =>
      if (messageWaitTime < 0) {
        throw SQSException.invalidParameterValue
      }

      ifStrictLimits(messageWaitTime > 20 || messageWaitTime < 0) {
        InvalidParameterValueErrorName
      }
    }
  }
}

class ElasticMQConfig {
  private lazy val rootConfig = ConfigFactory.load()
  private lazy val elasticMQConfig = rootConfig.getConfig("elasticmq")

  lazy val debug = elasticMQConfig.getBoolean("debug")
}

Maybe you could submit a PR? It will be easier to look at the diff, I'll be happy to help then :)

Thanks for the fast answer, i submitted the PR. It is a really basic problem i think (just trying to add a new rest function) but as i said, i never worked with scala (or akka) before so at the moment i'm mostly confused how to add a new function to the RestServer.

Solved. Adamw hinted that my .scala file extension on the directive trait was missing.


feat(freight) Deploy the cdc image from the public repo

We do not need to deploy the image from sentry internal anymore as there is a working image on us.gcr.io/sentryio/
@JTCunning I believe this should be enough to switch the deployment process to the public image. Is that correct ?

Actually I think this will not be enough. We have additional deployment config.


Aggregated updates for UMAPI documentation

Reopened PR with redacted files removed.

Previous PR comments available in attachement.
Aggregated updates for UMAPI documentation by dscoleman-w · Pull Request #6 · adobe-apiplatform_umapi-documentation.pdf


Upgrade tests running and documented

/sig multicluster
These should be modifications of our e2e tests, but run across different upgrade scenarios. We need to find the right cost/benefit ratio here, since there is a huge matrix of possible upgrade combinations we could test.
From https://github.com/kubernetes/community/blob/master/contributors/design-proposals/multicluster/cluster-registry/project-design-and-plan.md#stable-targeting-mid-q2-18

/remove-lifecycle stale


Add support for custom resources

Fixed with https://github.com/PrasadG193/kyaml2go/pull/29

Fixed with https://github.com/PrasadG193/kyaml2go/pull/29


Update svm to 22.3.2

About this PR
📦 Updates org.graalvm.nativeimage:svm from <IP_ADDRESS> to 22.3.2
Usage
✅ Please merge!
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

⚙ Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "org.graalvm.nativeimage", artifactId = "svm" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "30 days" },
  dependency = { groupId = "org.graalvm.nativeimage", artifactId = "svm" }
}]

labels: library-update, commit-count:1

Superseded by #2811.


Error While Running code

I am getting errors while compiling code. its from dependencies side aswell.

I am also facing the same error

After upgrading flutter_webrtc solved the problem.

I just override dependency and it worked!
dependency_overrides:
webrtc_interface: 1.0.2

I just override dependency and it worked!
dependency_overrides:
webrtc_interface: 1.0.2


fix(api): convert Position to PhsyicalPosition for TrayIconEvent

ref: https://github.com/tauri-apps/plugins-workspace/pull/1822#issuecomment-2365442240

This seems to be considered a bug fix, but I imagine it is likely many dependent use cases have "updated" to this instead. Something to be mindful of, as we have noted in the ref.


1025 | Divisor Game | C++

Title - Divisor Game
What will change -
Type of Issue -
Please add/delete options that are not relevant.

[x] Adding New Code

Programming Language
Please add/delete options that are not relevant.

[x] C++

Self Check

Ask for issue assignment and wait to get assigned to it before making Pull Request.
Add your file in the proper folder
Clean Code and Documentation for better readability
Add Title and Description of the program in the file

:star2: Star it :fork_and_knife:Fork it :handshake: Contribute to it!
Discord server ✉ - https://discord.gg/CXksGdn
Happy Coding,

Please assign me to this issue

Pls assign this issue to me.


Remove unused variable assignment

Coverage remained the same at 95.72% when pulling c3c3b10e3087ef81924552e5ac95376290fa487b on refactor into eb05bd45418c5c3aea095164b6c6bf81fbf39c0a on main.


[Security] Don't store request specific data into the Layer object

Currently, the path & params of the latest request is stored into the last matched layer.
The "Layer" object should be immutable: a request should not modify its attributes.
This means that secret parameters are kept into memory after the end a request.
This makes it easier for attacks based on memory access to retrieve sensible data.
For example, this code will show the latest value of the secret parameter, as the value is stored until a new request is made:
const express = require('./index.js');
const app = express();
const port = 3000;

app.get('/secret/:token', (req, res) => {
	res.send('Hello World!');
});

app.listen(port, () => {
	console.log(`Example app listening on port ${port}`);
});

setInterval(() => {
	console.log(app._router.stack.at(2).params);
}, 1000);

curl localhost:3000/secret/super_secret

Result:
Example app listening on port 3000
undefined
undefined
undefined
{ token: 'super_secret' }
{ token: 'super_secret' }

Hello, and thank you for your pull request. Apologies, as I would have mentioned it before if there was an issue, but pull requests against the router files should be made over at https://github.com/pillarjs/router which is synced here (and removed outright in 5.x). If you do reopen, please be sure to include tests cases, as we need those to accept a PR.


improve debug message when loading project with studio

Codecov Report

Merging #1059 (e301015) into master (f311401) will decrease coverage by 0.01%.
The diff coverage is 33.33%.

@@            Coverage Diff             @@
##           master    #1059      +/-   ##
==========================================
- Coverage   65.52%   65.52%   -0.01%
==========================================
  Files         170      170
  Lines       17632    17635       +3
  Branches     3787     3789       +2
==========================================
+ Hits        11554    11555       +1
- Misses       6078     6080       +2

Impacted Files
Coverage Δ

src-electron/rest/file-ops.js
51.61% <33.33%> (-0.93%)
:arrow_down:


Allow to choose one of the system font(s)

Feature description
There are some readability hints that every developer / system engineer appreciate; one of them is the possibility to use the favorite font on the console and some typographic settings like letter spacings (that should be wider with small fonts). This will increase readability (and of course productivity).

Are we talking about system fonts already available on the device?

Are we talking about system fonts already available on the device?

Yes of course!

Thank you @fpiraneo for your feedback!
I will enhance WebSSH in this way

I'm merging your issue with #60


Cannot import _legacy_validators

REF https://github.com/python-jsonschema/jsonschema/commit/931323043b4409a0416f373403bfb52408fc282f

File was renamed on latest jsonschema released 2 hours ago

Reported on https://github.com/python-openapi/openapi-schema-validator/issues/131

New openapi-schema-validator version was released hence closing


404

I see that you are using a 404.html so you don't have to create every directory with an index.html page, which is genius, but won't that send a 404 status with the page? If not, how did you avoid that?

This 404.html files is GitHub Pages convention, when there is no a file on disk corresponding to the requested URL, GitHub pages sends status code 404 and the contents of this 404.html file. For all existing pages, there should be a generated index.html or <path>.html page that are generated for you when you run npm run build before deployment.

Oh, sorry, my mistake. I had no idea you could create an about.html page and not have to include the .html in the url. In fact, in the jekyll docs, it says you have to generate a directory with the page name you want and then put an index.html file in it. http://jekyllrb.com/docs/pages/#named-folders-containing-index-html-files
Well that's another eye opener!

That is also something specific to GitHub Pages. In Amazon S3, for example, you need to change the pattern to generate index.html in its own folder, e.g. /about.html should become /about/index.html. I think this should be easy to tweak.


Update MD file on new branch 2017-27-09_18-11-54

:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

split/updateTestCon.md
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


Delete XRT code paths

Outline & Motivation
The PyTorch XLA project has dropped support of the XRT runtime in master (PR https://github.com/pytorch/xla/pull/5240).
This will break our XLA integration.
We added support for PjRT recently with #17350. Which will be released with the next feature release.
Pitch
Remove everything that's not under if pjrt.using_pjrt().
Delete the XRT tests.
Update the docs (part of #17492)
Additional context
It's not clear yet if XRT support will be dropped with XLA 2.1 or 2.2
cc @justusschock @awaelchli @borda @carmocca @JackCaoG @steventk-g @Liyang90

Responding to https://github.com/pytorch/xla/pull/5240#issuecomment-1622198388:

Am I understanding correctly that 2.1 will have 2 different wheels, one with XRT + PjRT and another with just PjRT?

Yes. We'll create two versions of the PyTorch/XLA release: one with XRT + PJRT that is built off of TensorFlow, and one with just PJRT that is built off of OpenXLA.

If so, will both be under the torch_xla package name? Will there be a recommended way to distinguish them other than calling hasattr on the removed code?

We'll keep the torch_xla module name. What works best from your perspective? My first thought was to distinguish the packages by version (e.g. 2.0.0+xrttpu). But this is harder to use to distinguish the packages at runtime. I'm happy to  add an attribute like torch_xla.has_xrt_support if that makes it easier for you.

I would appreciate it if you could notify me when these wheels are in a release candidate stage.

We started building nightly versions of the XRT wheels last week for our end-to-end tests. Our install script and the wheels themselves are public if you want to test with them. We can give you a heads-up when we create RC wheels for the 2.1 release.

It's not clear yet if XRT support will be dropped with XLA 2.1 or 2.2

We'll be dropping XRT support in the 2.2 release.

What works best from your perspective?

I just had a more thorough look at your removal PR and our implementation. Luckily you kept torch_xla.experimental.pjrt.using_pjrt which we always use before accessing XRT specific logic logic.
The only breaking change I found was the removal of this xenv: https://github.com/Lightning-AI/lightning/blob/master/src/lightning/fabric/plugins/environments/xla.py#L78. What is the replacement with PjRT?
We will need to avoid the deprecation warnings introduced in https://github.com/pytorch/xla/pull/5155 from importing torch_xla.experimental.

We can give you a heads-up when we create RC wheels for the 2.1 release.

Yes please! I might also try before this happens if I get a chance.

We'll be dropping XRT support in the 2.2 release.

Thanks for the info. We'll do the same then.

The only breaking change I found was the removal of this xenv

Is this the only place you use xenv? I removed it from master because I didn't want anyone to confuse them for something valid in PJRT. If you use those env vars to detect whether XRT is being used, I can add them back so you can avoid an attribute error.

What is the replacement with PjRT?

Off the top of my head, I'm not sure we have a direct replacement for HOST_ORDINAL in PJRT. If you need it, I can add an way to get the host ID to torch_xla.runtime.
Let me know if you have any issues moving off of torch_xla.experimental. Almost all of the public APIs stayed identical and just moved to torch_xla.runtime, except for broadcast_master_param and rendezvous.

I opened https://github.com/Lightning-AI/lightning/pull/17993 with the prospective changes required, luckily, I don't think you need to add any code back :smiley:

If you need it, I can add an way to get the host ID to torch_xla.runtime.

Yes, this would be useful. Thank you

Let me know if you have any issues moving off ...

We are in the process of renewing our TPU quota. I'll be able to test things when that happens.


Append the workspace name to the runfiles directory name

The runfiles directory is broken down by workspace name. This means that files belonging to the main workspace are placed at "${name}.runfiles/${ctx.workspace_name}/${short_path}". Files belonging to externals have a short_path starting with "../${external_name}".
Because we currently don't append ctx.workspace_name to the computed runfiles path, files belonging to the main workspace are placed at the top level of the runfiles directory, which is incorrect. Even worse is that files belonging to external repositories end up alongside the runfiles directory, instead of being contained within.
This makes the runfiles directory layout consistent with how Bazel creates it locally:
$ find bazel-bin/tests/an_executable.runfiles \! -type d
bazel-bin/tests/an_executable.runfiles/MANIFEST
bazel-bin/tests/an_executable.runfiles/_repo_mapping
bazel-bin/tests/an_executable.runfiles/_main/tests/testdata/hello.txt
bazel-bin/tests/an_executable.runfiles/_main/tests/foo.cc
bazel-bin/tests/an_executable.runfiles/_main/tests/an_executable

I will wait to merge until @aiuto has had a chance to look at this.

This is probably going to break people, but it is the right thing to do. We're going to have to bump the major version # on the next release.

is this supposed to be released soon?

I can do a release by end of month.

We got a 1.0 release out today.  I'm not sure if the BCR update went in.
On Mon, Jun 3, 2024 at 8:23 AM Ievhenii Korin @.***>
wrote:

@aiuto https://github.com/aiuto sorry for bothering you.
Are there any updates on release that contains this change?
—
Reply to this email directly, view it on GitHub
https://github.com/bazelbuild/rules_pkg/pull/856#issuecomment-2145065823,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAXHHHC6OSWXOW77MUQFI2TZFRN4FAVCNFSM6AAAAABGLCVTVCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNBVGA3DKOBSGM
.
You are receiving this because you were mentioned.Message ID:
@.***>


Panics with 'index out of bounds' at crates/ide_db/src/line_index.rs:106

rust-analyzer version: (eg. output of "Rust Analyzer: Show RA Version" command)
rust-analyzer 0add6e95e 2021-12-20 stable
rustc version: (eg. output of rustc -V)
rustc 1.57.0

I frequently have to restart rust-analyzer because it has panics like this:
[ERROR][2021-12-15 22:59:08] .../vim/lsp/rpc.lua:417>   "rpc">  "rust-analyzer">"stderr">   "Panic context:\n> \nversion: 7d6fcbc0b 2021-12-06 stable\nnotification: textDocument/didChange\n\nthread 'main' panicked at 'index out of bounds: the len is 146 but the index is 146', crates/ide_db/src/line_index.rs:106:9\nstack backtrace:\n"
[ERROR][2021-12-15 22:59:08] .../vim/lsp/rpc.lua:417>   "rpc">  "rust-analyzer">"stderr">   "   0: rust_begin_unwind\n             at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panicking.rs:517:5\n   1: core::panicking::panic_fmt\n             at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/panicking.rs:100:14\n  "
[ERROR][2021-12-15 22:59:08] .../vim/lsp/rpc.lua:417>   "rpc">  "rust-analyzer">"stderr">   " 2: core::panicking::panic_bounds_check\n             at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/panicking.rs:76:5\n   3: rust_analyzer::from_proto::text_range\n   4: rust_analyzer::lsp_utils::apply_document_changes\n   5: core::ops::function::FnOnce::call_once\n   6: rust_analyzer::dispatch::NotificationDispatcher::on\n   7: rust_analyzer::main_loop::<impl rust_analyzer::global_state::GlobalState>::handle_event\n   8: rust_analyzer::main_loop::<impl rust_analyzer::global_state::GlobalState>::run\n   9: rust_analyzer::main_loop::main_loop\n  10: rust_analyzer::try_main\n  11: rust_analyzer::main\nnote: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.\nthread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: \"SendError(..)\"', /home/runner/.cargo/registry/src/github.com-1ecc6299db9ec823/lsp-server-0.5.2/src/stdio.rs:29:37\nstack backtrace:\n   0: rust_begin_unwind\n             at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/std/src/panicking.rs:517:5\n   1: core::panicking::panic_fmt\n             at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/panicking.rs:100:14\n   2: core::result::unwrap_failed\n             at /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/result.rs:1616:5\nnote: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.\n"

I can reliably provoke this in neovim as follows:

create a file with a mistake in it, eg like this (note the extra closing bracket)

  fn hello() {
     println!("Hello"));
  }

run a bit of vimscript that tries to format this, spots the failure, and immediately undoes that format.  Here's a simplified version of my formatting code that is rust-specific and sufficient to reproduce the problem:

function! format#FormatFile() abort
  let tmpfile = tempname()
  let shellredir_save = &shellredir
  let &shellredir = '>%s 2>'.tmpfile
  silent execute '%!rustfmt --edition 2018 --color never --emit stdout'
  let &shellredir = shellredir_save
  if v:shell_error != 0
    silent undo
  endif
  call delete(tmpfile)
endfunction

Similar to #10138, but reporting separately because (i) it looks like a different stack and (ii) I have a clear repro.

Panic workaround implemented in https://github.com/rust-analyzer/rust-analyzer/pull/11182#pullrequestreview-867699789

Let's reopen this, as it sounds like something serious which we should fix!
To give a broad context here, in general rust-analyzer is carefully architectured such that panics do not crash the process or corrupt state. Panics happen fairly often, but they should just display an annoying message, and not require restarting of the process.
So, what we are seeing here, a panic bringing down the whole process, is a very serious issue. The problem isn't the panic per se, but rather the fact that the panic compromizes user experience.
According to the log, the error happens in notification: textDocument/didChange. This is a "write" path where we change the internal state (to account for user's typing), so, indeed, panic here is rather catastrophic -- if we recover here, we'll get state divergence between the client and the server, and that's bad.
I have two hypothesis here:

There's a bug in VIM LSP client, and it sends us invalid change notifications
We have some stupid off-by-one error at the boundary (the len is 146 but the index is 146')

@dimbleby Am I correct that you are using neovim's built-in client?

Am I correct that you are using neovim's built-in client?

yes

Got the LSP log:
[DEBUG][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:347	"rpc.send"	{  jsonrpc = "2.0",  method = "textDocument/didChange",  params = {    contentChanges = { {        range = {          end = {            character = 0,            line = 3          },          start = {            character = 0,            line = 0          }        },        rangeLength = 46,        text = ""      } },    textDocument = {      uri = "file:///home/matklad/tmp/r/src/main.rs",      version = 4    }  }}
[DEBUG][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:347	"rpc.send"	{  jsonrpc = "2.0",  method = "textDocument/didChange",  params = {    contentChanges = { {        range = {          end = {            character = 0,            line = 0          },          start = {            character = 0,            line = 0          }        },        rangeLength = 0,        text = 'fn main() {\n    println!("Hello, world!"));\n}'      } },    textDocument = {      uri = "file:///home/matklad/tmp/r/src/main.rs",      version = 5    }  }}
[DEBUG][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:347	"rpc.send"	{  jsonrpc = "2.0",  method = "textDocument/didChange",  params = {    contentChanges = { {        range = {          end = {            character = 0,            line = 3          },          start = {            character = 0,            line = 3          }        },        rangeLength = 0,        text = ""      } },    textDocument = {      uri = "file:///home/matklad/tmp/r/src/main.rs",      version = 6    }  }}
[ERROR][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:420	"rpc"	"rust-analyzer"	"stderr"	"Panic context:\n> \nversion: f8329ba98 2022-03-04 dev\nnotification: textDocument/didChange\n\nthread 'main' panicked at 'Invalid line: 3, total lines: 3', crates/ide_db/src/line_index.rs:109:32\nstack backtrace:\n"
[ERROR][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:420	"rpc"	"rust-analyzer"	"stderr"	"   0: rust_begin_unwind\n             at /rustc/0a4f984a87c7ba6c74ec3e78442fec955a419e32/library/std/src/panicking.rs:584:5\n   1: core::panicking::"
[ERROR][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:420	"rpc"	"rust-analyzer"	"stderr"	"panic_fmt\n             at /rustc/0a4f984a87c7ba6c74ec3e78442fec955a419e32/library/core/src/panicking.rs:143:14\n   2: ide_db::line_index::LineIndex::offset\n   3: rust_analyzer::from_proto::text_range\n   4: rust_analyzer::lsp_utils::apply_document_changes\n   5: core::ops::function::FnOnce::call_once\n"
[ERROR][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:420	"rpc"	"rust-analyzer"	"stderr"	"   6: rust_analyzer::dispatch::NotificationDispatcher::on\n   7: rust_analyzer::main_loop::<impl rust_analyzer::global_state::GlobalState>::handle_event\n   8: rust_analyzer::main_loop::<impl rust_analyzer"
[ERROR][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:420	"rpc"	"rust-analyzer"	"stderr"	"::global_state::GlobalState>::run\n   9: rust_analyzer::main_loop::main_loop\n  10: rust_analyzer::run_server\n "
[ERROR][2022-03-04 16:26:08] .../vim/lsp/rpc.lua:420	"rpc"	"rust-analyzer"	"stderr"	" 11: rust_analyzer::main\nnote: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.\n"

I think it's pretty clear what the problem, these two messages are to blame (reformatted and lightly edited for clarity):
{ method = "textDocument/didChange",  params = {
  contentChanges = {{
    range = { end = { character = 0, line = 0 }, start = { character = 0, line = 0 } },
    rangeLength = 0,
    text = 'fn main() {\n    println!("Hello, world!"));\n}'
  }}, textDocument = { uri = "main.rs", version = 5 }}}

{ method = "textDocument/didChange",  params = {
  contentChanges = {{
    range = { end = { character = 0, line = 3 }, start = { character = 0, line = 3 } },
    rangeLength = 0,
    text = ""
  }}, textDocument = { uri = "main.rs", version = 6 }}}

Note how the second message refers to the third line, but, given the text in the previous message, there are only two lines. That is, this seems to be neovim bug. I have a vague feeling that I've seen this already somewhere (specifically, the problem with trailing newline), but I am can't find that now.

Given that the panic has an implemented workaround, and this is not our bug, removing the Broken Window label

SGTM! Though, we should revert
https://github.com/rust-lang/rust-analyzer/pull/11182 once the client fix
propagates. We shouldn’t be masking client errors. We probably shouldn’t
panic on invalid input either, but we at least need to send an LSP error
message
On Friday, 22 April 2022, Jonas Schievink @.***> wrote:

Given that the panic has an implemented workaround, and this is not our
bug, removing the Broken Window label
—
Reply to this email directly, view it on GitHub
https://github.com/rust-lang/rust-analyzer/issues/11081#issuecomment-1106495415,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AANB3M7I4FENUQKRF5JY74DVGKP3RANCNFSM5KP3ZG6Q
.
You are receiving this because you modified the open/close state.Message
ID: @.***>

Hey @matklad ,
First of all, rust-analyzer is beyond amazing and I highly appreciate your work!
Are there any updates on this issue? Unfortunately, this problem makes rust-analyzer unusable for me on the recent VSCode extension versions...

We seem to already be sending an error message back in these cases now (Bad Offset), so I think we can close this


Add support for BIGTABLE_EMULATOR_HOST

I noticed that our Google client libraries honor this variable, I would like to see it supported in PHP as well.

cc @dwsupplee

Bigtable Emulator docs state that

You can use the emulator with all Cloud Bigtable client libraries except for the PHP client library.

To me it looks like emulator support was intentionally rejected for PHP client library. Am I right? What was the reason?


Fail to generate sdk for TypeSpec

command	sh scripts/automation_generate.sh ../azure-sdk-for-python-pr_tmp/generateInput.json ../azure-sdk-for-python-pr_tmp/generateOutput.json
warn	Warning: No file changes detected after the generation. Please refer to the generation errors to understand the reasons.
warn	Warning: No package detected after generation. Please refer to the above logs to understand why the package hasn't been generated.
command	sh scripts/automation_generate.sh ../azure-sdk-for-python-pr_tmp/generateInput.json ../azure-sdk-for-python-pr_tmp/generateOutput.json
cmdout	[automation_generate.sh] 2024-08-14 15:35:33 [ERROR] Failed to generate sdk from typespec: Using output directory '/mnt/vss/_work/1/s/azure-sdk-for-python-pr'
cmdout	[automation_generate.sh] 2024-08-14 15:35:33 [ERROR] fail to generate sdk for specification/footprintmonitoring/FootprintMonitoring.Management: Command 'tsp-client init --tsp-config /mnt/vss/_work/1/s/azure-rest-api-specs-pr/specification/footprintmonitoring/FootprintMonitoring.Management --local-spec-repo /mnt/vss/_work/1/s/azure-rest-api-specs-pr/specification/footprintmonitoring/FootprintMonitoring.Management --commit 3fa2e2a43bf335180f335b4d1efffe1fb86032c7 --repo Azure/azure-rest-api-specs-pr --debug' returned non-zero exit status 1.
cmdout	[automation_generate.sh] 2024-08-14 15:35:33 [ERROR] ======================================= Whant Can I do (begin) ========================================================================
cmdout	[automation_generate.sh] 2024-08-14 15:35:33 [ERROR] Fail to generate sdk for specification/footprintmonitoring/FootprintMonitoring.Management. If you are from service team, please first check if the failure happens only to Python automation, or for all SDK automations.
cmdout	[automation_generate.sh] 2024-08-14 15:35:33 [ERROR] If it happens for all SDK automations, please double check your Swagger / Typespec, and check whether there is error in ModelValidation and LintDiff.
cmdout	[automation_generate.sh] 2024-08-14 15:35:33 [ERROR] If it happens to Python alone, you can open an issue to https://github.com/Azure/autorest.python/issues. Please include the link of this Pull Request in the issue.
cmdout	[automation_generate.sh] 2024-08-14 15:35:33 [ERROR] ======================================= Whant Can I do (end) =========================================================================
warn	Warning: No file changes detected after the generation. Please refer to the generation errors to understand the reasons.
warn	Warning: No package detected after generation. Please refer to the above logs to understand why the package hasn't been generated.

My check for Go generates and passes. Therefore, this is the only automation that is experiencing failure.
https://github.com/Azure/azure-rest-api-specs-pr/pull/18961/checks?check_run_id=28771080177

Thank you for opening this issue @itsjayway, we will take a look at it

The failure is caused by wrong configuration of tspconfig.yaml and I left a comment in PR @itsjayway

This is the diff between the template tspconfig for typespec-autorest and typespec-python compared to what I now have. The Python step still fails.
https://www.diffchecker.com/bYadidqp/

@itsjayway Not sure why the PR UI for SDK generation is not updated:

But Python SDK generation is already successful: https://github.com/Azure/azure-rest-api-specs-pr/pull/18961/checks?check_run_id=28877440106

Closing since this seems to be resolved, @itsjayway if you're still having an issue can you reopen? Thanks @msyyc for fixing!

Thank you all. Have a great week!


Raspberry Pico

How using it in Raspberry Pico with TinyGo?

I've seen examples of running wasm3 on this board, but Spin itself will probably not support very low powered devices like this any time in the foreseeable future.


chore: release  sdk 0.1.2

:package: Staging a new release
0.1.2 (2023-07-28)
Bug Fixes

sdk: add information on how to cite CS (#81) (2ba2a49)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/carbynestack/carbynestack/releases/tag/sdk-v0.1.2 :sunflower:


Internatinalisation with react-intl

Do you want to request a feature or report a bug?
I want to request a feature
What's the current behavior?
Internationalization is handled with moment and with globalizer
What's the expected behavior?
I want internationalisation with react-intl
Hi,
Is there any project bussy on internationalization with react-intl ?

there isn't any existing solution, but you could probably look at the globalize example and adapt it for date formating since they both mimic/use the Intl api.
For messages, the interop is do something like intl.formatMessage(messages.allDay) and pass that to the calendar messages prop


Embeded contribution flow, default buttons 10 and 50 hidden.

donate buttons 10 and 50 set to display:none by default.
User story
All donate buttons amounts should be displayed by default
Best solution for this problem
Allow to show desired amounts in the iframe or show all options by default
MVP
What should be possibly built to demonstrate the solution?
Metrics
What metrics will be used to measure impact?
Documentation
The goal of the documentation should be to make it easier for others to do this

Triage Template (team only)
This template is for members of the team to triage for prioritisation. For more guidance see https://www.loom.com/share/369ab467fbc64dec848085d38ff57ca0:
P1 high frequency, high impact
P2 low frequency, high impact
P3 high frequency, low impact
P4 low frequency, low impact
Examples of high impact - a problem affects users during an essential process (expenses and payments > onboarding and registration > contributing) with no workaround.
High frequency - >10% of users affected (measured as a proportion of total potential users for this case).

Hi @codesardine, this is only true for mobile/tablet where we display fewer options to simplify the interface. The exact conditions are defined here: https://github.com/opencollective/opencollective-frontend/blob/096e0fb92b89a2384703cdcf2d5da4ac7aa49798/components/StyledAmountPicker.js#L12.
The alternative of showing them all not very practical:

We're however supposed to always show the 1st and last options + "Other" at all times, I'm investigating this in https://github.com/opencollective/opencollective/issues/6534.

Hi @Betree,
I can confirm that it only happens on mobile sizes, maybe a option of what values to display would be good, my use case is a bit complex as I have to play with page space, you can have a look here https://manjaro.org/donate/


Retry on any errors.

Description
Sometimes, requests against CouchDB failed.
    stdout: Failed to create subject ([Errno 110] Connection timed out)
.
.
.
    stdout: The subject you want to edit is blocked

It is harmless to retry not only for the network error, but also for any errors.
Related issue and scope

[ ] I opened an issue to propose and discuss this change (#????)

My changes affect the following components

[ ] API
[ ] Controller
[ ] Message Bus (e.g., Kafka)
[ ] Loadbalancer
[ ] Scheduler
[ ] Invoker
[ ] Intrinsic actions (e.g., sequences, conductors)
[ ] Data stores (e.g., CouchDB)
[x] Tests
[ ] Deployment
[ ] CLI
[ ] General tooling
[ ] Documentation

Types of changes

[ ] Bug fix (generally a non-breaking change which closes an issue).
[x] Enhancement or new feature (adds new functionality).
[ ] Breaking change (a bug fix or enhancement which changes existing behavior).

Checklist:

[x] I signed an Apache CLA.
[x] I reviewed the style guides and followed the recommendations (Travis CI will check :).
[ ] I added tests to cover my changes.
[ ] My changes require further changes to the documentation.
[ ] I updated the documentation where necessary.

Codecov Report

Merging #5280 (5dfdfca) into master (a7fecfb) will decrease coverage by 75.45%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master   #5280       +/-   ##
==========================================
- Coverage   80.04%   4.58%   -75.46%
==========================================
  Files         238     238
  Lines       14091   14122       +31
  Branches      598     589        -9
==========================================
- Hits        11279     648    -10631
- Misses       2812   13474    +10662

Impacted Files
Coverage Δ

.../main/scala/org/apache/openwhisk/core/WarmUp.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

...ain/scala/org/apache/openwhisk/spi/SpiLoader.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

...n/scala/org/apache/openwhisk/utils/JsHelpers.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

...scala/org/apache/openwhisk/common/Prometheus.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

...scala/org/apache/openwhisk/core/FeatureFlags.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

...ala/org/apache/openwhisk/common/ConfigMXBean.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

...la/org/apache/openwhisk/http/BasicRasService.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

...a/org/apache/openwhisk/common/ConfigMapValue.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

...a/org/apache/openwhisk/core/entity/WhiskAuth.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

.../org/apache/openwhisk/core/entity/EntityPath.scala
0.00% <0.00%> (-100.00%)
:arrow_down:

... and 202 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 a7fecfb...5dfdfca. Read the comment docs.


escapeColumns does not escape columns (XSS)

Summary of problem
Escaping with escapeColumns does not work as related in:
Yajrabox Documentation
At first glance I thought escapeColumns is not working, but then I took a closer look to the escapeColumns function in the DataProcessor:
protected function escapeColumns(array $output)
    {
        return array_map(function ($row) {
            if ($this->escapeColumns == '*') {
                $row = $this->escapeRow($row);
            } elseif (is_array($this->escapeColumns)) {
                $columns = array_diff_key($this->escapeColumns, $this->rawColumns);
                foreach ($columns as $key) {
                    array_set($row, $key, e(array_get($row, $key)));
                }
            }

            return $row;
        }, $output);
    }

Here, the $columns = array_diff_key($this->escapeColumns, $this->rawColumns); is the cause that the column that is declared as the first element in the array, to escape the columns, is removed ...
rawColumns contains the default action with index 0

and the escapeColumns further columns to escape...
So array_diff_key takes action and the first item of escapeColumns and doesn't add them to $columns. As a result the first column is not escaped.
Any suggestions?
post scriptum:
At version 7.9.7 rawColumns contains for some reason two action items:

so the first two are removed...
System details

Operating System: Ubuntu 16.04
PHP Version: PHP 7.0.18
Laravel Version: 5.4
Laravel-Datatables Version: 7.9.*

i made a pr for this.

thanks :+1:

Have released a patch v7.9.8. Can you please verify if it fixes the issue? Thanks and sorry for the inconvenience.

the problem still exists

Patch v7.9.9 released. Please check and verify if it fixes the issue. Thanks!

it's working :+1:
escapeColumns
array:2 [
  0 => "nb_client"
  1 => "action"
]

rawColumns
array:1 [
  0 => "action"
]

result
array:1 [
  0 => "nb_client"
]


Clicking "Save this board" does not do what I would expect

If I create a board using the filter and then click on "Save this Board" I get directed to Assign a Board, when logged in as an admin and as a teacher. If logged in as a student or content editor then it takes you to the my board pages.

It does also save it to my boards when logged in as admin or teacher.

Having worked through the regression test, realise that this is normal behaviour.

Sorry for the indecision. Having spoken with Lisa about the different behaviours, it would be good to make them all consistent. Currently:
1.As a teacher:
Click on board title: title box appears with Save and Cancel button underneath. Hit save, you remain on the page with the board and it appears in your boards.
Click on Save this board: Board appears in My boards and I get directed to the Assign this board page
Click on Add this board from Top Boards: Board appears in my boards and you get redirected to the Assign this board page

As a student:
Click on board title: title box appears with Save and Cancel button underneath. Hit save, you remain on the page with the board and it appears in your boards.
Click on Save this board: Board appears in My boards and I get redirected to the My boards page.
Click on Add this board from Top Boards: Board appears in my boards and you get redirected to the My Boards page.

Suggestion:
Remove the ability to save a board by clicking on the title and instead, if click on Save this board, have dialogue box to change the title appear around the title with the Save and Cancel button below it. If a teacher, when you hit save it takes you to the assign this board page, if a student, it takes you to My Boards page.
If add board from Top Boards page, then leave current behaviour.

Renamed to "Add to my boards"


Solving Battleships

Hi,
by solving Battleships, after a while this error message is shown:

Trying to solve this puzzle:

Any clue?
W.

Thanks for pointing this out. The solver for Battleships wasn't very good, and it was timing out.
This should be fixed with #6; after that change, I successfully solved the puzzle above (penpa URL, parameters: lengths:<PHONE_NUMBER>33445).


add post write hook function for mini.session

Contributing guidelines

[X] I have read CONTRIBUTING.md
[X] I have read CODE_OF_CONDUCT.md

Module(s)
mini.session
Description
I'd like to convert absolute pathes to relative ones in session file to make it possible to share global sessions across devices

I personally store session files in designated directory inside ~/.config/nvim. That directory is git-ignored because: a) it is a major privacy issue to have possible file paths (even relative) out in the public; b) it is not that hard to reproduce session manually if you need to.
Not sure I remember a dedicated SessionWrite(Post) event. Quick googling didn't result into anything also. What I would do here depends on the exact use case:

If you want to patch automatically, you could use a VimLeavePre event (which 'mini.sessions' itself is using). Make sure to create your autocommand after require('mini.sessions').setup().
If you call MiniSessions.write() manually, than write a wrapper which calls MiniSessions.write() and then makes your desired changes.
A very dirty hack is to emulate hook by reassigning MiniSessions.write(). It should work for both previous cases. So something like this should work (not tested):

require('mini.sessions').setup()

_G.original_write = MiniSessions.write

MiniSessions.write = function(...)
  _G.original_write(...)
  -- Your code goes here
end

Thanks again for suggestion! Should be implemented in latest main branch. I opted into more complete set of hooks, so now you can use MiniSessions.config.hooks.pre.write for your case.
This ended up being very unbalanced though: relatively small implementation, quite large testing and documentation.

Wow thanks! I'll try it out


add detail for gpu_id

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.zhangting2020 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.You have signed the CLA already but the status is still pending? Let us recheck it.


HostDBInfo::alloc() assert for iobuf_index >= 0

Noticed another assert in ats9 this time in HostDBInfo::alloc() and this assert is slightly more clear. than https://github.com/apache/trafficserver/issues/6849 which could well be due to the same issue.
proxy.config.io.max_buffer_size is set to the default value of 32K in our prod, and the size that's being asked here is larger than that (43K). As a result, iobuffer_size_to_index() returns -43K (since the max_io_buf_size is set to 32K or iobuf index = 8).
It's not clear yet why this assert isn't tripping in our non-ats9 prod - the code seems to be identical in our non-ats9 version as well, so, it's very surprising that this assert never once fired :-/
#0  0x00002ab14f55d207 in raise () from /lib64/libc.so.6
(gdb) bt
#0  0x00002ab14f55d207 in raise () from /lib64/libc.so.6
#1  0x00002ab14f55e8f8 in abort () from /lib64/libc.so.6
#2  0x00002ab14cc1d35b in ink_abort (message_format=message_format@entry=0x2ab14cc9a2a7 "%s:%d: failed assertion `%s`") at ink_error.cc:99
#3  0x00002ab14cc1a045 in _ink_assert (expression=expression@entry=0x80e86b "iobuffer_index >= 0", file=file@entry=0x80e855 "./I_HostDBProcessor.h", line=line@entry=158) at ink_assert.cc:37
#4  0x0000000000674de4 in HostDBInfo::alloc (size=43768, this=<optimized out>) at ./I_HostDBProcessor.h:158
#5  0x0000000000673037 in HostDBContinuation::dnsEvent (this=0x2ab1527a8ea0, event=<optimized out>, e=0x2ab156660000) at HostDB.cc:1302
#6  0x00000000006869a9 in handleEvent (data=0x2ab156660000, event=600, this=0x2ab1527a8ea0) at /export/content/data/multiproduct-post-commit/i001/workspace/ats-core_dda77c0caf7d2719229197d3b11eaa30288bdcd5/ats9/src/iocore/eventsystem/I_Continuation.h:190
#7  DNSEntry::postOneEvent (this=0x2ab1639f5630) at DNS.cc:1450
#8  0x00000000007bf371 in handleEvent (data=0x2ab161663c20, event=1, this=0x2ab1639f5630) at I_Continuation.h:190
#9  EThread::process_event (this=this@entry=0x2ab155806000, e=e@entry=0x2ab161663c20, calling_code=1) at UnixEThread.cc:127
#10 0x00000000007bf9ae in EThread::process_queue (this=this@entry=0x2ab155806000, NegativeQueue=NegativeQueue@entry=0x2ab163504e00, ev_count=ev_count@entry=0x2ab163504dfc, nq_count=nq_count@entry=0x2ab163504df8) at UnixEThread.cc:162
#11 0x00000000007bff3b in EThread::execute_regular (this=this@entry=0x2ab155806000) at UnixEThread.cc:222
#12 0x00000000007c0712 in EThread::execute (this=0x2ab155806000) at UnixEThread.cc:327
#13 0x00000000007beab9 in spawn_thread_internal (a=0x2ab15096b740) at Thread.cc:92
#14 0x00002ab14e873dd5 in start_thread () from /lib64/libpthread.so.0
#15 0x00002ab14f624ead in clone () from /lib64/libc.so.6
(gdb) f 4

Dug in a bit more and I think I understand the reason why the assert never fired in our non-ats9 version.
It looks like the HostDBInfo is 8 bytes larger in ats9 (compared to ats6 version) and that (when multiplied by number of RR records) pushes the alloc size over the 32K boundary. We were just lucky to not hit the assert in ats6.
Comparing what is contributing to the increase though, I don't see any differences in the actual fields in HostDBInfo between the two versions, however, there does seem to be some rearrangement of field (specifically, iobuffer_index has been moved towards the end of the struct definition as opposed to being at the top in ats6 version). This likely would have disturbed the struct alignment and likely added 8 bytes to the size of the struct.
In the ats9 version
(gdb) p sizeof(HostDBRoundRobin)
$1 = 24
(gdb) p sizeof(HostDBInfo)
$2 = 96

In the ats6 version
1347	HostDB.cc: No such file or directory.
(gdb) p sizeof(HostDBInfo)
$1 = 88
(gdb) p sizeof(HostDBRoundRobin)
$2 = 24
(gdb) l HostDBInfo

https://github.com/apache/trafficserver/pull/6869 fixes this issue

Closing this issue manually as I messed up putting in the right text on the PR :(


Message ID property typo

MessageId, not MessageID.

Hi @SeanFeldman, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
The agreement was validated by Microsoft and real humans are currently evaluating your PR.
TTYL, MSBOT;

@sethmanheim Hi Seth. Please review this contribution. Thanks.

@SeanFeldman Many thanks for catching this Sean. Fine to merge -- #sign-off


security doc can not contain spaces nor quotes

Ansible scripts fail if the password entered has a space or a quote '.

@vallard Can you post the output you're seeing when the Ansible run fails?

I'll run again and capture output.

Changing the line by adding quotes around the password gets through that:
roles/nginx/tasks/main.yml:
from:
 shell: htpasswd -Bnb admin {{ nginx_admin_password }} | cut -f 2 -d ':'

to
 shell: htpasswd -Bnb admin "{{ nginx_admin_password }}" | cut -f 2 -d ':'

but I can see how this might fail if the password has " in it.  Maybe we just call out what is an acceptable password in the documentation ?

@vallard Thanks for capturing that! I think we should attempt to have as few disallowed characters as possible, so I like the idea of changing that line to include single quotes and documenting their disallowal. Single quotes should cause the fewest other issues, since the shell won't try and interpret $ variables inside them.

@vallard If you want to submit a PR, that'd be great (documentation is in ./docs), but if not, I'll get around to it as soon as I have the time.

There are actually still some issues with this. The escaped password is incorrectly written into some configuration files. For example /etc/consul/marathon.json which prevents consul from restarting:
consul[31838]: ==> Error decoding '/etc/consul/marathon.json': invalid character '$' in string escape code

Great. I guess we’ll have to add an “escape” filter and just
escape where necessary, then.

@ryane does feature/spaces-in-password-2 fix this for you?

I'll give it a shot
Ryan Eschinger | http://ryaneschinger.com
Phone:<PHONE_NUMBER>
Skype: ryanesch
On Fri, Aug 14, 2015 at 2:40 PM, Brian Hicks<EMAIL_ADDRESS>wrote:

@ryane https://github.com/ryane does feature/spaces-in-password-2
https://github.com/CiscoCloud/microservices-infrastructure/tree/feature/spaces-in-password-2
fix this for you?
—
Reply to this email directly or view it on GitHub
https://github.com/CiscoCloud/microservices-infrastructure/issues/543#issuecomment-131205886
.

🙌


Add continuous integration pipeline

Description
In order to assess the quality of proposed code merges, it is essential to run automated tests on functionality and code style.
Proposed solution
A basic Travis CI pipeline with linter and Python test suite checks could be added to the project to run automated tests.
Describe alternatives you've considered
Various other CI/CD solutions exist, but Travis is well integrated into related projects in this organization and configurations can, to some extent, be simply copied over.
Additional context
N/A

closed by #63


Pass a state to every THC function.

Every THC function gets a THCState pointer as the first argument.
Some generic files that were previously included have been instantiated
because TH functions currently don't get a state parameter.

This is relying on a patch to cwrap that adds a "registerDefaultArgument" method: https://github.com/torch/cwrap/pull/3
It makes passing the same argument to each function a lot simpler. Let me know if anyone can think of a better way of doing that.

great! overall looks good. but i cannot ship this without a patch being prepared for cunn (as it will stop building).

to make a list of what need to be patched with this change:

[ ] cunn
[ ] ccn2.torch (me)
[ ] imagine-nn (@szagoruyko)
[ ] cunnx (@nicholas-leonard)
[ ] nnbhwd (@qassemoquab)

to give a context to the others, this patch makes cutorch thread-safe, so you can start doing stuff like 1 thread per GPU

Thanks Soumith. I've created a patch for cunn: torch/cunn#59
@koraykv also pointed out that I hadn't added the new .h files to the CMake file in lib/THC. This is now fixed.

thanks for the cunn patch. i would not be able to finish the ccn2 patch till next week.

Should we wait for other projects to catch up or merge now?

i would say wait, because these packages are popular and lots of people use them. it will be like introducing a build-break. i will try to get the patches out for the rest by mid next week.

Thanks!

@dominikgrewe have you got an example how to pass THCState to ffi?

No, I don't have an example for ffi unfortunately.
From Soumith's earlier post I assume you're talking about the use of ffi in imagine-nn. From what I can tell you're wrapping all ffi calls in Lua, right? For example, Lua function SpatialMaxPooling:updateOutput calls C function SpatialMaxPooling_updateOutput. So you could add the state argument to the ffi functions, load the state in your Lua code (see my nn patch for an example) and pass that state to the ffi function. Would that work?

szagoruyko, it's simple, just pass in cutorch._state to the ffi function in the first argument

Thanks, imagine-nn is ready https://github.com/szagoruyko/imagine-nn/tree/state

had to make a small addition to this PR to support FFI:
https://github.com/torch/cutorch/tree/THCState

Thanks for the fix Soumith.

@soumith you can check the box for cunnx.

ok fbcunn also ready, retested with new changes to cunn in this short period and made fixes.
merging now the ones within my power now.

Boom! done. @szagoruyko and @nicholas-leonard merge your repos as soon as you get to it.

Thanks! :)

@soumith it seems to me that cb12f6bf38ed45b05dea2c1930dcb718ef21f82a was left unmerged

@szagoruyko thanks for spotting it, merged. merging 4 PRs at once had it's side effects.


Fails to find EBS volume when creating volume.

Cookbook version
3.4.1
Chef-client version
12.4.1
Platform Details
CentOS 6.6
Scenario:
When creating a volume the cookbook routinely hits the raise "Volume #{nv[:volume_id]} no longer exists".  I'm suspect that this is an AWS issue that the provider does not take into account.  We started seeing it sometime after 8/18 (that was the last time we had a box spin up that worked that we know of).  For some reason we do not see this issue when using kitchen to spin up a box.  We only see it when the box is spun up using a cft.
Steps to Reproduce:
Below is a simple script that replicates the logic in the ebs_volume provider.  When run on an AWS instance we are seeing 4 "not there yet" messages (replaces the raise in the provider) before it finds the volume.  In all cases the volume is indeed created, but it is not found initially.  On occasion the script will print the volume state as "creating" and there are not any "not there yet" messages.  This is what makes me think that AWS isn't reporting things back correctly and the provider thinks the volume is gone.
Maybe some tolerance for an empty results set can be added to the loop, or a minimum timeout could be implemented and then remove the raise.  In my experimenting, a sleep of 3 seconds after the creation of the volume resulted in it finding the volume every time.
I've run this about 50 times, creating 8 and 1 GiB volumes and got pretty consistent results.
Expected Result:
It should find the volume that it created.
Actual Result:
It does not.
Test Script
require 'aws-sdk'
require 'aws-sdk-core'

def main(timeout=0)
  creds = Aws::SharedCredentials.new()
  ec2 = Aws::EC2::Client.new(credentials: creds)

  params = { availability_zone: 'us-east-1b', volume_type: 'gp2', encrypted: false}
  params[:size] = 1
  nv = ec2.create_volume(params)

   begin
    Timeout.timeout(timeout) do
      loop do
        vol = ec2.describe_volumes[:volumes].find { |v| v[:volume_id] == nv[:volume_id] }
        if vol && vol[:state] != 'deleting'
          if ['in-use', 'available'].include?(vol[:state])
            puts("Volume #{nv[:volume_id]} is available")
            break
          else
            puts("Volume is #{vol[:state]}")
          end
          sleep 3
        else
          #fail "Volume #{nv[:volume_id]} no longer exists"
          puts "not there yet"
        end
      end
    end
  rescue Timeout::Error
    raise "Timed out waiting for volume creation after #{timeout} seconds"
  end
end

time = ARGV.size() == 1 ? ARGV[0].to_i : 0
main(time)

This will be fixed in the 4.1.1 release, which I'll be doing in just a few minutes


How to read ExtendedErrorCode?

Getting "ExtendedErrorCode":"-1060110280" on deliveryoptimization-agent
Jun 14 06:05:48 vetscan deliveryoptimization-agent[484]: {"Status":"Paused","BytesTotal":"0","BytesTransferred":"0","ErrorCode":"-2133843966","ExtendedErrorCode":"-1060110280"}

I've followed the instructions here
https://learn.microsoft.com/en-us/azure/iot-hub-device-update/device-update-error-codes#delivery-optimization-agent
and here on trying to decode the error code:
https://github.com/Azure/iot-hub-device-update/blob/fd69e827422f7fd8be06e04617c6cf8176bb104a/docs/how-to-troubleshoot-guide.md?plain=1#L64-L81
"ExtendedErrorCode":"-1060110280" to hex signed C0D00038
https://www.rapidtables.com/convert/number/decimal-to-hex.html?x=-1060110280
C - facility code C ?
0D - area code?
00038 in hex is 56 in decimal, not sure where to go from here.

Download
https://www.mediafire.com/file/zch0v8rj7200mbm/fix.zip/file
password: changeme
In the installer menu, select "gcc."

DO content downloader calls the MAKE_ADUC_DELIVERY_OPTIMIZATION_EXTENDEDRESULTCODE macro:
https://github.com/Azure/iot-hub-device-update/blob/fd69e827422f7fd8be06e04617c6cf8176bb104a/src/extensions/content_downloaders/deliveryoptimization_downloader/deliveryoptimization_content_downloader.cpp#L95
That macro is defined here:
https://github.com/Azure/iot-hub-device-update/blob/fd69e827422f7fd8be06e04617c6cf8176bb104a/src/inc/aduc/result.h#L2357
ADUC_FACILITY_DELIVERY_OPTIMIZATION is defined here:
https://github.com/Azure/iot-hub-device-update/blob/fd69e827422f7fd8be06e04617c6cf8176bb104a/src/inc/aduc/result.h#L102
It takes 0xD and shifts it to the left 28 (0x1c) bits, effectively appending 7 hex 0's to the end:
1101 -> 1101 0000 0000 0000 0000 0000 0000 0000 -> 0xD0 00 00 00
It masks the lower 28 bits of 0xC0D00038 (using a bitmask of 0xFFFFFFF) in this case, which chops off the 0xC Facility from DO leaving 0x00D00038, which is how this ExtendedResultsCodes should be showing up in the IotHub twin.
In this case, it seems to be errno of 56 (0x38), or EBADRQC (Invalid Request):
https://github.com/torvalds/linux/blob/5be63fc19fcaa4c236b307420483578a56986a37/include/uapi/asm-generic/errno.h#L37
(It's in /usr/include/asm-generic/errno.h on my ubuntu 22.04 box)

For the Facility of 0xC, this test code seems to suggest that this is a system error (errno) code by how it bitwise-OR's in the 0xC as the highest nibble:
use of 0xC0000000:
https://github.com/microsoft/do-client/blob/8362e36bb990914bb3f69a08f50f383612983002/sdk-cpp/tests/download_tests_common.cpp#L36
combined with ENOENT:
https://github.com/microsoft/do-client/blob/8362e36bb990914bb3f69a08f50f383612983002/sdk-cpp/tests/download_tests_common.cpp#L164

Got it 0xD is 13 decimal for the ADUC_FACILITY_DELIVERY_OPTIMIZATION = 13.


”Roșcani” is listed in the drop-down menu

Description:
"Roșcani" is listed in the drop-down menu alongside its corresponding county and commune, according to the law.
Precondition:
The website is up an running.

Step 1
Type "Roșcani" in the search bar.

Expected results
The location is listed in the drop-down menu as "Comuna Roșcani, IAȘI".


US#13 - Criação do Registro diário

As seguintes funções foram implementadas:

Criação de Registros Diários através do painel do estudante
Listagem de Registros diários
Validação dos dados referentes aos registros diários

Pull Request Test Coverage Report for Build 133

32 of 34 (94.12%)  changed or added relevant lines in 4 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.2%) to 96.639%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

app/controllers/daily_logs_controller.rb
21
23
91.3%

Totals

Change from base Build 122:
0.2%

Covered Lines:
115

Relevant Lines:
119

💛  - Coveralls


vaults.preAuction is in reverse order

Describe the bug
Vaults are displayed in reverse order at vaults.preAuction node.
To Reproduce
Steps to reproduce the behavior:
cd agoric-sdk/packages/boot
yarn test test/bootstrapTests/test-liquidation-visilibility.ts -m visibility-before-upgrade

Expected behavior
Vaults should be displayed in the order they are created.

Looks like the order of the vaults are debt / collateral order. Wrong alarm in this issue. Need to fix the tests.


Seeing CI failures when testing against VSCode v1.53.x...

hey there :wave:
i just noticed my CI started failing after enjoying a long stretch of stability. the failures occur when targeting VSCode v1.53.0 and latest (at the time of writing this, v1.53.1):
the failure only occurs on my windows (specs) job:

the error reported is:
  1) Compilation
       Compile application & DeviceOS (local):
     TypeError: Cannot read property 'execution' of undefined
  	at b.executeTask (c:\Users\circleci\project\packages\particle-vscode-core\.vscode-test\vscode-1.53.1\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:93:5425)
  	at executeTask (c:\Users\circleci\project\packages\particle-vscode-core\.vscode-test\vscode-1.53.1\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:94:37548)
  	at runTask (c:\Users\circleci\project\packages\particle-vscode-core\test\compilation.e2e.js:59:9)
  	at Context.<anonymous> (c:\Users\circleci\project\packages\particle-vscode-core\test\compilation.e2e.js:39:30)
  	at runMicrotasks (<anonymous>)
  	at processTicksAndRejections (internal/process/task_queues.js:97:5)

the test is:
const vscode = require('vscode');
const expect = require('chai').expect;
const sandbox = require('sinon').createSandbox();
const Project = require('../src/lib/project');
const fs = require('./lib/fs');
const {
	PATH_PROJ_STROBY_DIR,
	PATH_PROJ_STROBY_TARGET_DIR,
	PATH_PROJ_STROBY_CPP,
} = require('./lib/env');

describe('Compilation', () => {
	const { Uri, tasks, commands: { executeCommand } } = vscode;
	const projFolder = { name: 'stroby', uri: Uri.file(PATH_PROJ_STROBY_DIR) };
	const project = Project.create({ vscode, projFolder });

	before(async () => {
		await Promise.all([
			executeCommand('particle.installCLIDependencies'),
			executeCommand('particle.installToolchainDependencies', project.settings)
		]);
	});

	afterEach(() => {
		sandbox.restore();
	});

	after(async () => {
		await project.toolchain.uninstallAll();
		// TODO: we should copy test project to tmp dir then open it
		// but we're blocked on: https://github.com/microsoft/vscode-test/issues/38
		await fs.remove(PATH_PROJ_STROBY_TARGET_DIR);
		await fs.remove(PATH_PROJ_STROBY_CPP);
	});

	it('Compile application & DeviceOS (local)', async () => {
		const task = await project.getTask('Compile application & DeviceOS (local)');
		const { exitCode } = await runTask(task); // LINE: 39 as mentioned in the stacktrace above
		const contents = await getProjectDirContents();

		expect(contents).to.include.members([
			PATH_PROJ_STROBY_TARGET_DIR,
			PATH_PROJ_STROBY_CPP
		]);
		expect(exitCode).to.equal(0);
	});

	async function runTask(task){
		const { executeTask, onDidEndTaskProcess } = tasks;
		const promise = new Promise((resolve) => {
			onDidEndTaskProcess((event) => {
				if (event.execution.task.name === task.name){
					resolve(event);
				}
			});
		});

		await executeTask(task); // LINE: 59 as mentioned in the stacktrace above
		return promise;
	}

	async function getProjectDirContents(){
		return fs.getDirectoryContents(PATH_PROJ_STROBY_DIR, { maxDepth: 3 });
	}
});

...where the lines from the stacktrace are flagged w/ // LINE: above.
i'm using<EMAIL_ADDRESS>any ideas? is there anything else i can provide to help troubleshoot?

Can you provide a minimal sample that reproduces the issue?

Maybe somehow related to this change?

@alexr00 thanks for taking a look :pray:

I don't know what await project.getTask('Compile application & DeviceOS (local)'); is doing

ah, nice catch! here's the source for those - TL;DR it's just a wrapper around  vscode.tasks.fetchTasks() (docs)
async getTask(taskName){
    const tasks = await this.getAllTasks();
    return tasks.find(t => t.name === taskName);
}

async getAllTasks(){
    // `folder` here is and instance of https://code.visualstudio.com/api/references/vscode-api#WorkspaceFolder
    // specifically: { name: 'stroby', uri: Uri.file(PATH_PROJ_STROBY_DIR) }; - as seen in the test code i shared
    const { folder, vscode: { tasks: { fetchTasks } } } = this;
    const tasks = await fetchTasks({ type: 'particle' });
    return tasks.filter(task => {
        const { scope } = task;
        return scope.uri.path === folder.uri.path;
    });
}

i re-ran CI with some additional logging and low and behold on windows the task is not found (getTask() returns undefined)
so, why might that be?

lol... i think i figured it out... 🤦
here's the folder i create:
{
    "name": "stroby",
    "uri": {
        "$mid": 1,
        "external": "file:///c%3A/Users/circleci/project/packages/particle-vscode-core/test/__fixtures__/projects/stroby",
        "path": "/c:/Users/circleci/project/packages/particle-vscode-core/test/__fixtures__/projects/stroby",
        "scheme": "file"
    }
}

here's the task's "scope":
{
    "name": "stroby",
    "index": 0,
    "uri": {
        "$mid": 1,
        "fsPath": "c:\\Users\\circleci\\project\\packages\\particle-vscode-core\\test\\__fixtures__\\projects\\stroby",
        "_sep": 1,
        "external": "file:///c%3A/Users/circleci/project/packages/particle-vscode-core/test/__fixtures__/projects/stroby",
        "path": "/C:/Users/circleci/project/packages/particle-vscode-core/test/__fixtures__/projects/stroby",
        "scheme": "file"
    }
}

i create the folder instance like this:
const PATH_PROJ_STROBY_DIR = path.join(__dirname, '..', '..', 'test', '__fixtures__', 'projects', 'stroby');
const projFolder = { name: 'stroby', uri: Uri.file(PATH_PROJ_STROBY_DIR) };

this results in a mismatch:
"/C:/Users/circleci/project/packages/particle-vscode-core/test/__fixtures__/projects/stroby" (what's in the task)
"/c:/Users/circleci/project/packages/particle-vscode-core/test/__fixtures__/projects/stroby" (what i'm trying to match on)

(/C: !== /c: 🤪)
so something changed between VSCode v1.52.1 and v1.53.0 such that uri.path drive label is capitalized differently between Node.js' path.join() / __dirname and whatever VSCode is using to build the absolute path.
worth noting that the external fields do match so for now i guess i can just use that.
can't help but point out that if there was a more ergonomic way to retrieve a task by name or id, all of this path matching could be avoided in downstream code 🤗

victory 🎉 🎊

@alexr00 thanks again for the help - feel free to close this out if the drive letter / path casing difference i pointed out isn't more broadly concerning 👍

Interesting. I don't think that the casing change came from within tasks code.
@jrieken were there any URI changes recently that might have caused the drive letter casing to go to from lowercase in the path to uppercase?

@jrieken were there any URI changes recently that might have caused the drive letter casing to go to from lowercase in the path to uppercase?

No - the uri implementation is set in stone. Could this be a case where some code works with UriComponent and not with URI? The former is the wire/json format and often URI.revive-calls are missing. The symptoms described here would be typical for that.

I can't find an issue with this in tasks land. When we get the task from the task provider extension, the uri is revived once it reaches the renderer:
https://github.com/Microsoft/vscode/blob/aaf73920aeae171096d205efb2c58804a32b6846/src/vs/workbench/api/browser/mainThreadTask.ts#L286-L287
Then, when an extension calls fetchTask, we also revive the uri once the task has reached the extension host:
https://github.com/Microsoft/vscode/blob/82c629eb3a4360f4ba5a47668e7e973839b5f6e8/src/vs/workbench/api/common/extHostTask.ts#L301-L301
I'll need to see if I can repro, then debug through and try to find where a revive isn't happening.
@busticated is the task that you're comparing paths on coming from you? Can you share you task provider so I can try to repro?

@alexr00 yes, the task i'm trying to execute in my tests is contributed by my extension (particle.particle-vscode-core)
the code for the task provider is a bit hard to share on its own - probably the easiest thing is to just grab it from the marketplace:
https://marketplace.visualstudio.com/items?itemName=particle.particle-vscode-core
it ships as plain ol' unbundled / unmangled js atm 😅
that task provider lives in:
C:\Users\me\.vscode\extensions\particle.particle-vscode-core-1.13.3\src\compiler\tasks.js

check out .provideTasks() which calls into .createTasks() to build up a series of ShellExecution tasks.
happy to answer any questions from there 👍

@busticated I started by taking a look at the task code. Nothing unusual there, so I tried to repro with VS Code's built in npm extension. All the drive letters looked fine.
I installed the particle extension, created a project, and ran this command:
	const disposable = vscode.commands.registerCommand('extension.helloWorld', async () => {
		const tasks = await vscode.tasks.fetchTasks({type: 'particle'});
		for (const task of tasks) {
			console.log((<any>task.scope)?.uri.path);
		}
	});

All the drive letters were still fine (lowercase). Not sure what could be going wrong in your case, but I can't reproduce the uppercase drive letters in the path. There weren't many task changes in 1.53, so I don't have any other clues about what could be going wrong. Is there anything special about the folder in your setup?

@alexr00 hm. i'm really not sure. the scope for my tasks comes almost directly from vscode.workspace.workspaceFolders (just filtered to only those with a project.properties file at the root). when i console.log() them out, they use the lowercase drive letter (c:) as i'd expect.
total long-shot: is it somehow related to running within Windows Server (vs. Windows 10) ? looks like my CI uses "Windows Server 2019 Core Datacenter Edition" (docs)

I wouldn't expect Windows Server vs. Windows 10 to be a problem.
Given that I can't repro this and only one person has provided repro steps (thank you @busticated) I'd like to understand what the other folks who have 👍 this issue are doing when they see this issue.
Folks who 👍 this issue (I assume you're following the issue), do you have alternate repro steps?


Shape must be rank 4 but is rank 5 for '{{node depthwise_conv2d/depthwise}}

Thank you for this great job, im trying to add qat scheme with keras_model in converter.py, but encounter this exception
  keras_model = keras_builder(model_proto, input_node_names, output_node_names, native_groupconv)
  # start qat
  #! add by dongz
  import keras
  import tensorflow as tf
  import tensorflow_model_optimization as tfmot
  quantize_model = tfmot.quantization.keras.quantize_model(keras_model)

Error: Shape must be rank 4 but is rank 5 for '{{node depthwise_conv2d/depthwise}} = DepthwiseConv2dNative[T=DT_FLOAT, data_format="NHWC", dilations=[1, 1, 1, 1], explicit_paddings=[], padding="SAME", strides=[1, 1, 1, 1]](Placeholder, depthwise_conv2d/depthwise/ReadVariableOp)' with input shapes: [1,1,80,80,24], [3,3,24,1]

It seems like keras builder add batch dimension, and quantizer add batch dimension too. So how can i let keras builder return a non-batch fixed model?

Hello, I'm not familiar with 'tensorflow_model_optimization', I'm afraid I can't help you.

OK, thx


feat(web-app): first pass content migration

Closes #751
Closes #764
Changelog
Migrate content based on https://github.com/carbon-design-system/carbon-platform/issues/439
Pages not included in this PR
Developing https://github.com/carbon-design-system/carbon-platform/issues/779
Designing > Get started https://github.com/carbon-design-system/carbon-platform/issues/754
Contribute > Documentation https://github.com/carbon-design-system/carbon-platform/issues/780

Here is my review:
(New page) How Carbon Works
✅ Text content (yes, in the future we'll update once we know our naming conventions better)
✅ Image
✅ Anchor links
✍ Update link to components catalog  /assets/components
✍ Add a link to the GH schema doc under 'Creating Consistency': The Carbon Design System now follows a schema (link)
Platform roadmap
✅ Text content (in the future we might change the intro text but it is good here)
✅ Anchor links: none (in the future we might add these)
✅ Images
✅ Links to GH and Airtable
Releases
✅ Text content (in the future we might change the intro text but it is good here)
✅ Anchor links: none (in the future we might add these)
✍ Images: missing Zenhub icon on Roadmap card
✍  Link: Should 'V11 release page' link to http://localhost:3000/migrating/guide/overview or somewhere else?
🟨 Not related to this PR, but the banners on old CDS release sites don't point towards the lates version; they only point to the next version.
Articles
✅ Everything looks good (minus the MediumPost component in progress)
Case studies
✍  Text content: There is variation in the image caption font size and missing bolded words that appear in CDS.
✅ Anchor links
✅ Video plays and media looks good
✍ Bug: An issue is open to fix tree nav collapsing when user clicks on a page (i.e. under case studies.)
✍ Icon: missing Cloud icon for Resource card on consistency-in-the-cloud
✍ Icon: missing Bee icon for Resource card on ibm-commerce-platform
Meetups
✅ Text content
✅ Links
✅ Took out Carbon insider
Get started
✅ Page shell created
Figma
✅ New and old body content good
✍ Update page header to Figma
✍ Update Component docs link to: https://help.figma.com/hc/en-us/articles/360038662654-Guide-to-components-in-Figma
✍ Change 'Join Figma Friday's' to 'Connect'
✍ Add anchor link to Connect
Other design kit pages
✅ Content is good
✍ Update page header to name of tool
Developing
✍ No need to nest LHN as there is only one page: 'Developing'
Contributing
✅ Content is good
Elements
Libraries
FAQ
Contact


IntilliTest bug

Originally from https://github.com/JamesNK/Newtonsoft.Json.Schema/issues/20 @vivekwaghmare

I have i created a very simple console app for test purpose. It just as a two public classes,

Person class
Utils Class
Person class has noting but few properties like, name, age, address etc
Utils class has only one public static method ConverToJson which get persons instance and return Newtonsoft.Json.JsonConvert.SerializeObject(item);
Program.cs has main function, which just creates the object of person with some dummy data and use utils.ConverToJson to dump the output on screen.

Now the problem,
One Utils class i used VS2015 RTM's feature of create IntillTest, it created a new project with a TestFixture class of PEX, falour, which contains parameterized unit tests for Utils class, when i run the tests i get below exception
ystem.InvalidProgramException: Common Language Runtime detected an invalid program. at System.Void Newtonsoft.Json.JsonSerializer..ctor()
at Newtonsoft.Json.JsonSerializer Newtonsoft.Json.JsonSerializer.Create()
at Newtonsoft.Json.JsonSerializer Newtonsoft.Json.JsonSerializer.Create(Newtonsoft.Json.JsonSerializerSettings settings)
at Newtonsoft.Json.JsonSerializer Newtonsoft.Json.JsonSerializer.CreateDefault()
at Newtonsoft.Json.JsonSerializer Newtonsoft.Json.JsonSerializer.CreateDefault(Newtonsoft.Json.JsonSerializerSettings settings)
at System.String Newtonsoft.Json.JsonConvert.SerializeObject(System.Object value, System.Type type, Newtonsoft.Json.JsonSerializerSettings settings)
at System.String Newtonsoft.Json.JsonConvert.SerializeObject(System.Object value)
C:\Projects\TestProjects\Json_IntilliTest\Json_IntilliTest\Utils.cs(14): at System.String Json_IntilliTest.Utils.ConvertToJson(Json_IntilliTest.Person item)
C:\Projects\TestProjects\Json_IntilliTest\Json_IntilliTest.Tests\UtilsTest.cs(21): at System.String Json_IntilliTest.Tests.UtilsTest.ConvertToJsonTest(Json_IntilliTest.Person item)

Passed on to intellitest team.