npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@traeger-industry/codabix-debug-runtime

v1.0.0-beta.7

Published

Debugging Runtime for custom script logic used in Codabix Middleware projects.

Downloads

23

Readme

codabix-debug-runtime

Debugging Runtime for custom script logic used in Codabix Middleware projects. This package enables the headless development and debugging of custom scripts in the development environment of your choice.

Getting started

1. Installation

Before you can start with developing and debugging, you have to install the package as follows:

npm install @traeger-industry/codabix-debug-runtime

Please note that any required dependencies are automatically installed by npm.

2. Import Modules

In constrast to the deveolopment of a script in Codabix' integrated development environment you have to import the modules used/required on your own.

Available modules are: codabix, guid, io, logger, net, runtime, timer

To use some or more of these modules, import them at the beginning of your script as follows:

import { codabix, logger } from "@traeger-industry/codabix-debug-runtime";

3. Setup Model (optional)

The package uses by default an existing Codabix Node Model in your project directory with the name "codabix-nodes.xml". If this file is missing any use of node related operations will fail. To generate a Codabix Node Model file you just need to switch to an existing Codabix Project and export the desired node tree to interact with from the node explorer in the Codabix backend. This can be done by selecting and right-clicking the top most node and choosing "Export Nodes as XML".

You can change the file path to your XML file as follows:

// default: "./codabix-nodes.xml"
codabix.Debug.model = "./my-nodes.xml";

Please note that adding, deleting or editing nodes and their values will not change the contents of the xml file!

4. Setup Runtime (optional)

You can configure the runtime to develop and test your implementation how it behaves in different scenarios. These scenarios can be configured using several options. The package uses a set of default options to imitate the communication with a resources limited component.

4.1 Node Value Metrics

A node value provided in Codabix provides not only the value itself. In addition with the intrinsic value the codabix.NodeValue provides the codabix.NodeValue.status member to indicate whether the value could be determined successfully. In the life runtime of Codabix the status can be provided by the component communicating with as well.

To imitate the case a component provides values with bad values you can configure the codabix.Debug.defaultStatus property like follows.

// default: true
codabix.Debug.defaultStatus = false;

If this property is changed to the value false every codabix.NodeValue will use the value codabix.NodeStatusValueEnum.Bad as the value of the codabix.NodeValue.status property; otherwise the value codabix.NodeStatusValueEnum.Good.

4.2 Communication Delays

In the life runtime of Codabix you are communicating with other components which might be limited by their resources and any response to a request (send to a component) can be delayed when reading and writing information.

To imitate the case of a delayed call to codabix.readNodeValueAsync() for a read-operation performed by your code you can configure a delay in milliseconds as part of the runtime options like follows.

// default: 1000
codabix.Debug.readDelay = 2000;

To imitate the case of a delayed call to codabix.writeNodeValueAsync() for a write-operation performed by your code you can configure a delay in milliseconds as part of the runtime options like follows.

// default: 1000
codabix.Debug.writeDelay = 500;

Changes

v.1.0.0-beta.6 (2024-03-26)

  • Minor fixes.

v.1.0.0-beta.5 (2024-03-22)

  • Added event handler exceptions to prevent node changes within listeners.

v.1.0.0-beta.4 (2024-03-12)

  • Fixed bug when creating nodes.

v.1.0.0-beta.3 (2024-03-12)

  • Minor fixes.

v1.0.0-beta.2 (2024-03-12)

  • Fixed bug when using findNode on "/Nodes".

v1.0.0-beta.1 (2024-03-12)

  • Fixed Types not being exported correctly.
  • Fixed typo in README.

v1.0.0-beta.0 (2023-07-17)

  • First beta version.