Feature/cc/do not write image

Pulling from @ChrisCinelli 's fork, this eliminates concurrency on loading, however, it fixes several bugs in the process (Fixes #105, #106 , #44 ). This also sets up for removing jotframe which will make dive cross platform and takes care of issue #95 .

You anticipated me... since I wrote it already...
Before this PR dive was caching in a temp file the docker image. It was also allocating a few memory buffers that increased memory use and in case of large images created even more disk access because of memory being swapping out to disk by the kernel.
I have a lot faster performances on my machine after this change. Memory buffers have also be eliminated. This keeps the memory down even more and the CPU does not have to spend time copying memory around.
In order to achieve this I had to remove the parallel processing of layers. But, for what I can see, the code in this PR is a lot faster regardless and it does not wear out my SSD.
Because we do not use go routines anymore, the race condition on writing on layerMap is also removed that fixes #44.


simplify parsing mechanism

woops, pressed ENTER once to often.
i've added some comments to #31 and this is the corresponding code to that :)
since i wanted your thoughts on that and did not want to take any credits for your cool work, i thought PR for the PR would be best :)

nvm, found that github allows to do this direclty :)


treat failures to resolve module name as missing packages

// CC @mhegazy, @billti

can we add another check to filterTypings to check this.packageNameToTypingLocation[packageName]

and in master as well.


are their known issues with remote.require('nodobjc')?

Hey,
Do you think there would be an issue particularly with remotely requiring nodobjc?  I try to do it in an electron app i'm loading via a webview and this line later ends up being invalid...
const remote = require('remote');
const $ = remote.require('nodobjc');
//...later on in the code
$.NSAutoreleasePool('alloc')('init');
saying that NSAutoReleasePool isn't a function essentially when I wrap in a try/catch
Thanks,
Phillip

It's definitely not working when I use it within the renderer process. I resorted to only using it within the main process and using ipcRenderer.sendSync when I needed synchronous operations.


Reformatting of date (leading zero inconsistencies) should be in the ' data cleaning' program.

Reformat date_string col using datetime column to solve inconsistencies
This is in eventhistory_record_progression.ipynb but is data cleaning so should be in the program forming the clean csv, so then wouldn't be required in other data processing programs.

Done and removed from record progression script.


[WIP] Collection level (un)mapping

This is a WIP to add mapping / unmapping on a collection level.
This can give document-mapper libraries a quicker way to map documents so that they don't have to wrap every collection's methods. (i.e. type-mongo-mapper)
Features to be implemented:

Mapping: Allow all collection methods that return plain documents (ignoring aggregations) to be "mapped" (i.e. converting a document to a class).
Unmapping: Allow all collection methods that insert or update plain documents (without update modifiers) to be unmapped (i.e. converting a class to a document).

Basic Example:
class User {
    public _id;
    public firstName;
    public lastName;
    public createdAt;

    constructor(doc) {
        this._id = doc._id || new ObjectID();
        this.firstName = doc.firstName;
        this.lastName = doc.lastName;
        this.createdAt = doc.createdAt || new Date();
    }

    get id() {
        return this._id.toString();
    }

    get fullName() {
        return `${this.firstName} ${this.lastName}`;
    }
}

const collection = db.collection('users', {
    map: (doc) => new User(doc),
    unmap: (user) => ({
        _id: user._id,
        firstName: doc.firstName,
        lastName: doc.lastName,
        createdAt: doc.createdAt,
    })
});

const user = await collection.findOne({ /* ... */ });
assert.true(user instanceof User); // true

const cursor = await collection.find({ /* ... */ }).toArray();
assert.true(user[0] instanceof User); // true

const { ok, value } = await collection.findOneAndUpdate({ /* ... */ });
assert.true(value instanceof User); // true

const user = new User({ firstName: 'John', lastName: 'Doe' });
await collection.insertOne(user); // calls unmap option.. createdAt & the ID were created on the constructor, so it'd already exist.

Discussion: https://jira.mongodb.org/projects/NODE/issues/NODE-1450?filter=allissues
Related: https://github.com/mongodb/js-bson/issues/211
Also, my heart wants this to belong in the bson library, but right now BSON serialization seems to be handed over any javascript object instead of just the documents, so it's (de)serializing more than it should? (I'm unsure of how the internals work exactly).  I know the C# BSON driver has advanced class mapping, so that's what made me believe this type of thing can go there.  And I believe the serialization option above can be done through a toBSON() function on the class., but it'd still be nice to be more explicit on the collection level and let mapping libraries handle it for you.

/ping @mbroadst thoughts?

@j heads up: @mbroadst is on vacation for the next few weeks, so it may take a while to circle around to this.

@daprahamian Okay, I'd happily make these changes.
And It's good news to be told to use more modern syntax.  Are the drivers going to be rewritten using ES6 classes?  It hurt my brain sometimes navigating through this code.
And I'm definitely down with map / unmap.  I'd be for serialize/unserialize if it was BSON specific, but currently, it's too hard to get this into BSON.  I just ended up committing to what I had already prototyped.
Another option I thought of, which is to be like another one of the drivers (I don't have time to look at which one at the moment), but it can look something like this:
const collection = db.collection('users');
const mappedCollection = collection.asMapCollection(mapFn, unmapFn);

// ... or

const mappedCollection = db.mappedCollection('users', mapFn, unmapFn);

And I can create a new MappedCollection class.  I think for the most part, I'd just have to wrap most functions.
What are your thoughts or preferences?

@j we're currently taking a piecemeal approach to rewriting the driver in ES6; when we touch a file or do a major refactor, we try to bring it as up to date as possible. There are already some portions of the code rewritten with ES6 classes, and we will likely continue in the future.
I'd hold off on the additional helpers you mentioned for right now, since it's basically sugar for db.collection('users', { map, unmap});

@j I can't think of any other places that need the mapping.

@daprahamian should I stick to await/async (in tests) or keep it vanilla callback style?

@j Do not use async/await. Our tests are run against Node 4, Node 6, Node 8, and Node 10, and async/await can't be parsed by Node 6 or Node 4.
Other than that, you can use either callbacks or Promises.

@daprahamian I added unmap as well.  I kind of want to add an option on the collection method so that you can opt out of the collection mapping if you want.
I ended up doing an "instanceof" check on the unmap function as you can see in the tests to allow me to sort of over-ride it.
I have to head out, so I'll get back on it tomorrow.

@daprahamian I added unmap for over-riding or disabling collection level mapping.  I didn't add an over-ride for finding but I can.  If unmapping is really needed on a collection level, I figure you can just use the cursor directly.  But if you want me to add that for consistency I can!
Let me know what you think.

Now that I think about it, should I remove the ability to over-ride on the collection method level?  If someone wants an unmapped collection, they can do:
// collection with mapping
const mappedCollection = db.collection('users', {
    map: /* ... */,
    unmap: /* ... */,
});

// collection without mapping if they want to do things with raw documents
const collection = db.collection('users');

@daprahamian  I went ahead and removed the unmap option from the cursor methods since you can just create another unmapped collection.  I can bring it back.
If these changes all look good, I can clean up the commits into one and be good to go!

@daprahamian i have some time to finalize any changes today if you feel there are any, otherwise I can squash the commits and clean it up.  Let me know.

🤘 done!

@daprahamian sorry forgot to make the mention.

@j we unfortunately have to back this change out of the 3.1.0-beta branch before our next release. With mongodb/js-bson#253 and other approaches to document-class mapping on the table, we'd like to have further discussion before committing to any one API approach.
My plan right now is as follows:

Fork a branch with your changes
Remove the changes from master
Create a new PR between your branch and master

This is really cool! We use something similar but it's sometimes a pain to maintain. Love this implementation @j <3

@julien-c it’s coming! We just wanted a little more time to make a measured decision about it, sorry for the wait :smile:

@daprahamian @mbroadst Quick question... I was working on top of the beta branch for a while and everything got borked and didn't realize it's because my feature was removed.  I saw that PR in BSSON, which is an OK start?  I just can't get the "target" option in the collection commands to be passed down to the BSON deserialize.  Also, that PR didn't serialize either, so that might be a good one to add.  I'd like to help with this, but I'm finding it a pain to figure out how to pass a client option down to the BSON methods.
Any clue where I should look?  Code bounces around quite a lot and I want to put it in the right place.
PS. After working on top of my merged/reverted feature, everything was working pretty well :)

@j we are not actively working on the feature, but will be focusing on it next quarter (read: later this summer). We will make sure to keep you apprised, as we want feedback from those who it will be useful to, but in the meantime I recommend making an intermediary module to monkey patch your support into the driver. Sorry for the delay, but we want to make sure this is done right the first time, as we are on the hook for maintaining the feature in the future.

Sounds good.  The PR right now in js-bson, he's using firstBatch and nextBatch to determine that it's a document.  Is this the best way or are there other thoughts on how you'll want to do the class mapping? (https://github.com/mongodb/js-bson/pull/253)


Fix code scanning alert - Missing rate limiting

Tracking issue for:

[x] https://github.com/athrael-soju/whisperChat/security/code-scanning/1

Resolved


Infra improvements

Forgot to push these changes from #121

Updates
@patricksimonian followed on your work to add in a play for DB backup. Also moved all vars to the group var file instead, so no duplication.


Subtasks for milestones

Considering the new updates, system is considering tasks as milestones.
It can be a problem with the "duration" field. In general, when duration=0, project software consider it a milestone.

The reason it's because the milestone icon it's showed when the start DateTime and end DateTime are the same. I'm changing the property StartDate and DueDate from %Date to %DateTime to taking into consideration the estimation in hours.


codegen: Explicitly align unions if needed.

Also adds a test header I missed from the previous PR.
Fixes #1393

 Warning

These commits modify unsafe code. Please review it carefully!

r? @fitzgen

@bors-servo r+

:pushpin: Commit cb12a31 has been approved by fitzgen

:hourglass: Testing commit cb12a31c885d6b32011f0295c9144e021296ee61 with merge<PHONE_NUMBER>0b734b6f8f83ddddb37a391354f2d4...

:broken_heart: Test failed - status-travis

Was a fluke.


Broken hyperlinks

The readme and Github's description link to http://python-hyper.org/hpack/ which returns 403.  Pypi's homepage link to http://hyper.rtfd.org/ which redirect to Hyper's docs: https://hyper.readthedocs.io/en/latest/.
https://hpack.readthedocs.io/en/latest/ is probably to be used instead.

This should be fixed now.


Review #6

The resulting PDF with the proposed changes from #6 attached: UAVCAN_Specification.pdf
The following changes have not been implemented:

Time is meaningless without releases. We should specify that the type will be removed with the next minor release after two years of deprecation. If a type is then deprecated but no further releases occur for that major version it is not removed. We should furthermore reserve the right to remove all deprecated types from a previous major release in the next regardless of time elapsed.

The objective was rather the opposite. Equipment vendors do not care about versions, they care about the longevity of the data types they use. There must be some sort of a time-bound guarantee that the data types that were used to build a product today will remain valid and usable for a predefined period of time. In this setting, the vendor doesn't care how many protocol revisions will happen in that time frame.
Furthermore: although this is debatable, it may not be necessary to tie data type modifications with releases - with the new versioning proposal in place we can manage standard data types independently from the rest of the specification as long as the specification itself is not affected by that. For example, none of the data types defined in the uavcan.equipment namespace are mentioned in the specification (although there are a few examples that merely refer to the fact of their existence), so they can be modified within the same specification release. On the other hand, fundamental data types like uavcan.protocol.NodeStatus are extremely coupled with the fundamentals of the protocol, so they are unlikely to be changeable unless the specification is updated accordingly.
What do you think?

except for the !response bit, correct?

The response bit implements the distinction between requests and responses, it's a low-level concept, it is not even mentioned in that part of the specification because it is concerned with a very high-level overview. The response bit is going to be introduced in the chapter "CAN bus transport layer".

https://github.com/UAVCAN/specification/issues/4

The diagram has been updated; not to the exact version you provided, but a slightly modified one. The only meaningful difference is that I avoided the separation of Standard data types from Core data types. Considering the fact that there is only one mandatory data type (uavcan.protocol.NodeStatus), such separation does not offer much value. Do you agree?

I stopped at chapter 3 because I didn't realize that the datatype identifiers for top-level types were optional and this has me really confused. How do you envision such a feature is used? If a type id is determined at runtime then which node determines it and how do the other nodes know what typeid was chosen? I feel like I'm missing something big here because I can't envision how this could possibly work.

You're seemingly talking about default data type IDs. They are provided for all standard data types; as stated in the new specification, default DTIDs are not to be changed for the standard data types as that jeopardizes compatibility.
Vendor-specific data types, however, do not have a centralized way of agreeing upon their data type ID values, because there aren't (and seemingly can't be, although this question is probably worth exploring) a global repository of vendor-specific types. Therefore, items of equipment from different vendors are prone to re-using the same data type identifiers for different vendor-specific messages. This is why the specification requires vendors to provide for a way of reconfiguring the data type ID mapping for all vendor-specific data types. Here's a relevant excerpt from the section 3.7:
All UAVCAN nodes must use the same data type ID mapping for the standard data types,
as defined by the default data type ID values provided for each of the standard data types.
Since the standard data type ID mapping is immutable, all standard-compliant nodes can always
use standard data types conflict-free.

Vendor-specific data types, however, do not enjoy the lack of conflict guarantee,
because by virtue of being vendor-specific, such data types cannot use a global
fixed agreed upon mapping like the standard data types do.
As such, whenever vendor-specific data types are used, there is always a risk that
different nodes may map different data types to the same data type ID.

It is the responsibility of the system integrator to ensure that if vendor-specific data types are
used, the data type ID mappings are configured on all nodes identically.
Vendors of UAVCAN equipment must provide the integrator with a way to change the data type ID
of any vendor-specific data type leveraged by the node\footnote{Nodes that fail to provide a way of
altering the data type ID mapping for vendor-specific data types cannot be considered standard-compliant}.

I found that it is necessary to have this merged so that I could continue with my work on master. So I am merging this now. We can get back to the review later.


[FR] PWWS without named entity swap

Hey there,
it seems that the PWWS implementation here does not include the named entity (NE) substitution from the original paper [1]. It would be nice to add this, or helpful to add a note about its absence for users of OpenAttack.
Cheers!
[1] https://aclanthology.org/P19-1103/

Thanks for pointing that out! We will work on this soon.


Let toDateTime call fall through for Duration Granularity

Added test for the same. Fix #3994

:+1:

Looks good @praveev. A couple questions,

did you test this in a live cluster?
could you please add a query test to one or more of the query runner tests that uses a DurationGranularity? Like GroupByQueryRunnerTest or equivalents for timeseries, topN. Right now there are no tests that make sure duration granularities work well in the query engines. This should be doable by copying one of the existing tests that uses hour, day, etc gran and replacing the gran with new DurationGranularity(86400L, 0L) or similar

@gianm yup we've tested this fix on live cluster yesterday. i forgot about the GroupByQueryRunnerTest. Added now.


Improve MS Graph Performance

Extracted from #15648, and builds upon #15883
Hey, I just made a Pull Request!
This PR improves the performance of the Microsoft Graph Plugin

Increases the page size in general used by MS Graph, up to the maximum of 999 records per page, rather than the default 100.
Improves the performance when loading users by batch loading the user objects, rather than making a call to list all group members, then loading each user one by one.

This also fixes a bug that could cause a user to temporarily disappear from the catalogue if there was a transient failure loading that one user.  (The user would be missing fromt he entity provider's full data, so would be removed, then the next run successfully restores the user)
https://github.com/backstage/backstage/blob/9c37b7c000c8a029b072640d921ca904af20877a/plugins/catalog-backend-module-msgraph/src/microsoftGraph/read.ts#L204-L210

:heavy_check_mark: Checklist

[X] A changeset describing the change and affected packages. (more info)
[ ] Added or updated documentation
[X] Tests for new functionality and regression tests for bug fixes
[ ] Screenshots attached (for UI changes)
[X] All your commits have a Signed-off-by line in the message. (more info)

Oh. I see there's a conflict with a file now.

Does the merging of this final PR close #15648?


Jest doesn't recognize snarkyjs

Running tests that include snarkyjs imports (eg Field) fails, more precisely, jest crashes with the following error message:
https://pastebin.com/LpHXr5gn
Note the long mysterious error produced by snarkyjs before the actual error
    SyntaxError: Unexpected token 'export'
    > 1 | import { Field } from 'snarkyjs';

This error only occures when functions are being tested that use snarkyjs imports, eg Field, like the example below
import { Field } from 'snarkyjs';

export function foo(): number {
  let f = Field(0); // this causes jest to crash
  return 1;
}

the following example works fine
import { Field } from 'snarkyjs';

export function foo(): number {
  // I removed the Field(0) constructor here!
  return 1;
}

Steps to re produce:
Using the snapp cli to create a new project with snapp project new_project
Write a test that tests the following function

// index.ts
import { Field } from 'snarkyjs';

export function foo(): number {
  let f = Field(0); // this causes jest to crash
  return 1;
}

// index.test.ts
import { foo } from './index';

describe('index.ts', () => {
  describe('foo()', () => {
    it('should be correct', () => {
      expect(foo()).toEqual(1);
    });
  });
});

run yarn test
Using mocha to test the exact same files work
see the mocha config used in a working example here https://github.com/Trivo25/mina-zk-rollup/blob/main/.mocharc.json

Hey Trivo!
What is the current version of the snapp-cli you are running? I suspect that you are pulling an old version and not getting all the files that are needed to run the Jest tests. There should be a resolver.cjs file in your repo after running snapp project new_project, can you confirm this is the case?

Hey Trivo!
What is the current version of the snapp-cli you are running? I suspect that you are pulling an old version and not getting all the files that are needed to run the Jest tests. There should be a resolver.cjs file in your repo after running snapp project new_project, can you confirm this is the case?

Hey Martin, thanks for the fast reply. I did in fact not have a resolver.cjs. I double-checked my snapp-cli version (0.1.30) and re-installed the cli and created a new project again, just to be sure - I still don't have resolver.cjs
snapp system output
  System:
    OS: Linux 5.13 Ubuntu 21.10 21.10 (Impish Indri)
    CPU: (8) x64 Intel(R) Core(TM) i7-7700K CPU @ 4.20GHz
  Binaries:
    Node: 16.13.1 - /usr/local/node-v16.13.1-linux-x64/bin/node
    Yarn: 1.22.15 - /usr/local/node-v16.13.1-linux-x64/bin/yarn
    npm: 8.1.2 - /usr/local/node-v16.13.1-linux-x64/bin/npm
  npmPackages:
    snarkyjs: ^0.1.9 => 0.1.9
  npmGlobalPackages:
    snapp-cli: 0.1.30

same issue persists on my windows machine - is 0.1.30 perhaps not the correct version? I double checked the package.json of this repo, it seems to be the correct version

I suspect this is a problem with how files are being fetched from Github and then being cached on the system.
There should be a .gittar/ directory in your home directory. If there is, could you remove that and then try reusing the snapp-cli?

Awesome, deleting .gittar fixed it. Thank you very much for your help :)


Test tag user callback with discarded return

We were recently inquired by a user whether relying only on the ucs_status_t passed to the user callback and discarding the ucxx::RequestTag return from ucxx::Endpoint::tagSend and ucxx::Endpoint::tagRecv is valid.  This turns out to be a valid usage, although I'm unsure whether encouraging this is a good idea, since requests such as ucxx::Endpoint::amRecv require that the user retrieve the resulting buffer from the returned ucxx::RequestAm, and if this is discarded the buffer is lost. This PR adds a test for the aforementioned use case but makes no changes to documentation to prevent encouraging this pattern until we can decide whether we should support it or not.
For requests such as ucxx::Endpoint::amRecv, it might be worth studying whether we could pass the resulting buffer and any other attributes associated with it to the callback, in that case we may be able to provide a safe pattern to always use the callback if the user doesn't want to keep a reference to the returned ucxx::Request object.

Thanks @wence- for approving, since this is only adding a test, I'll go ahead and merge it even though we're in code freeze already.

/merge

Oh, actually we need admin merge. Since this isn't critical for 24.10 I'll then retarget and merge it once tests pass.


[feature request] Add relatsionship creation to draw view

Creating relationships between tables should be possible from the main draw page without having to go to table page. Creating a relation should create a new row named ${targetTableName}_id or ${targetTableName}_id# where # is a number starting from 2 if the previous name was already in use. Relationship creation should show a preview of the relation. Creation begins by dragging from the FK row to the PK table. For now let the relation be many (drag start - source) to one (drag end - target).

The options for starting node connections are:

context menu on node click
node "more actions" button (3 dots) on node table and the table rows
always visible connection points
connection points that turn visible while having some tool selected

I would like to have a context menu on node click, but this requires the right click to be disabled on the draw view, which makes debugging difficult. Might go with a "more actions" button.

Solved in #24


NoSuchMethodError，what happening？？？

public class Test {
public static void main(String args[]) {
System.out.println("test!!!!");
Db ezdb = new EzLevelDb(new File("./data"));
Table<Integer,Integer> dataTable = ezdb.getTable("test", IntegerSerde.get,  IntegerSerde.get);
dataTable.put(1, 2);
}
}

https://github.com/google/guava/issues/1846
I am going to upgrade the leveldb dependencies to fix this issue.

Maven repository:
http://invesdwin.de/artifactory/invesdwin-oss-remote

com.github.criccomini
ezdb-leveldb
0.1.12

Please try the new release. The guava incompatibility should be fixed by the newer leveldb dependencies.

Closing this issue. If something new pops up, please reopen.


Document issues with CORD-19 5/19 version

hey @edwinzhng can you remember to document the issues with the 5/19 data drop here?
https://github.com/castorini/anserini/blob/master/docs/experiments-cord19.md

@edwinzhng closeable?


It is important to start thinking about payment systems.

The Problem
I have worked on a few payment systems so far and I can say that marketplace transaction systems are both difficult to program and potentially expensive. As FOSS, we obviously can not go for an enterprise solution, however I believe it's important to start prototyping solutions.
My Idea
I was thinking that as an option on signup or when editing a profile, a person would add their  PayPal.me account. This would then allow people to purchase by direct PayPal transactions through the payment widget.
Suggest More
My idea was quite rudimentary so it wouldn't be too hard to make a better one. Please reply and if the owner see this, please set this up in the more long-term projects page for this repo.
Thank you and good luck :smile:

Moved to Project.


[stable/mm-te] bump MM-te to 5.6.2

What this PR does / why we need it:
bump MM 5.6.2
Checklist

[x] DCO signed
[x] Chart Version bumped
[x] Variables are documented in the README.md

/test pull-charts-e2e

/lgtm


Does Dip support objective-c?

I haven't seen anything on the documentation or issues referring this.

No, sorry, Dip is designed only for Swift.

If i create the container in swift, will it be able to do constructor initialization to objective c classes?

Yes, as long as they are visible for Swift code. But the container itself you can use only from Swift code.


catch import required state

📝 Changed routes:

/evm/[...paths]

(view full size)

Commit e9417b44db620ee7c3b84b06515a351387a85282 (https://thirdweb-p4p3lvo2v.thirdweb-preview.com).


Update/change query type

Updates queries to deal with deprecation of postBy and pageBy.
To test:

yarn dev
Click around the site
There should be no console errors

works perfectly, thanks @doingandlearning


Dynamic discovery of changes in resource types

https://github.com/clusterpedia-io/clusterpedia/issues/168 needs to support wildcards and be able to collect all resources.
spec:
  syncResources:
  - group: "*"

or
spec:
  sycnResources:
  - group: "apps"
    resources: "*"

This feature requires clusterpedia to be able to dynamically discover changes in resource types in the cluster.
When does a resource type change occur?
There are four cases:

kube-apiserver disables or enables a group/version or groups https://kubernetes.io/docs/tasks/administer-cluster/enable-disable-api/
kube upgrades result in changes to built-in resources, such as the addition or deprecation of a resource.
creation/deletion/update of a crd resource, resulting in a change of resource type
creation/deletion of aggregated resources(APIServices), where the specific resources under the aggregated

GroupVersion are controlled and provided by a specific third party component and are theoretically subject to dynamic change at will
For the third case, changes to the crd are actually easier to detect and we only need to listen for changes to the crd, so clusterpedia provides support for synchronising all custom resources first https://github.com/clusterpedia-io/clusterpedia/pull/112
The other three cases are actually a little more complex.
In the first case, we can watch changes to APIService to detect when group/version is disabled or enabled.
In the second case, kube's built-in resources will only change if there is a version change, so we need to monitor for version changes.
In the fourth case, the handling is less graceful than in the other cases.
Firstly, the aggregated resource‘s Group/Version can also watch the APIService to get a coarse sense of changes to the aggregated resource at the GroupVersion level
For resource changes within versions, we need to poll regularly to monitor them.
Some limitations of the restmapper
Firstly, the official RESTMapper(client-go) is a rather static implementation, we can usually use the dynamic rest mapper provided by controller-runtime in order to get access to new resources in the cluster.
However, the dynamic rest mapper has some minor limitations. When a crd resource is deleted, the dynamic rest mapper will not be aware of the deleted resource, but will still be able to get it through the rest mapper.
In addition, every time we look up a non-existent resource from the dynamic rest mapper, it will trigger a rebuild of the restmapper, requesting a lot of Discovery API, which is still a significant overhead despite the rebuild limit.
How do we do it?
As clusterpedia is a multi-cluster tool, the additional losses in each cluster are multiplied by the number of clusters managed, so we need to try to avoid losses that can be avoided when implementing any of the features.
So how do we implement the monitoring of changes in cluster resource types?
Firstly, we didn't use a tool like dynamic restmapper, which could easily generate a lot of Discovery requests.
We should watch the APIService and CRD, so that we can detect changes in the kube apiserver's disabled resources and CR resource types.
In addition, by watching to these two resources, we can also distinguish which resource the group is: a kube built-in resource, a custom resource, or an aggregated resource.
By distinguishing between these three types of resources, when getting a resource type that is not recorded locally, we have four cases:

if the group is a kube built-in resource, and if the cluster version has not changed, then this resource type does not exist
if the group is a custom resource, which is not available locally because we are listening for changes to the CRD, then it does not exist
if the group is an aggregated resource, then we just need to refetch the resource information for the aggregated resource
if the group does not belong to any of the types, then it means that the resource does not exist

The only API requests in these four cases are to check if the cluster version has changed or to query for changes to resources under the aggregated resource’s group/version. This saves a lot of requests compared to the dynamic rest mapper rebuild
Even though we listen to APIService, we are still only aware of group and version changes, but we are still not able to actively detect kube version upgrades and intra-version resource changes due to aggregated resources
In fact the polling of cluster versions is done in order to handle seamless upgrades of cluster services without interruption, clusterpedia actually does a version check during the health check of the cluster from notready -> ready.
These two types of polling generally result in no more than 10 requests and can be relatively long in duration, which is very economical compared to the polling rebuild of the rest mapper

@ycsk02 @27149chen PTAL, Thanks

Should we exclude Pediacluster from custom resources?  HandleResourceEvent always reports context Canceled Timeout error when Pediacluster resource synchronization is canceled by synchro.cancel() in ResourceSynchro.Close .

Should we exclude Pediacluster from custom resources? HandleResourceEvent always reports context Canceled Timeout error when Pediacluster resource synchronization is canceled by synchro.cancel() in ResourceSynchro.Close

After troubleshooting, I found that the error was wrapped in a layer in storage that caused the errors.Is to always return false, so even if it was due to context closure it would still cause the log to print.
https://github.com/clusterpedia-io/clusterpedia/blob/85f7337d510656df0b57a0b751a12bf4a564f74e/pkg/synchromanager/clustersynchro/resource_synchro.go#L344-L352
should return err directly
https://github.com/clusterpedia-io/clusterpedia/blob/85f7337d510656df0b57a0b751a12bf4a564f74e/pkg/storage/internalstorage/errors.go#L42-L43

LGTM


Example of usage

Hi!
I'm writing a chatbot with watson and node-red but i didn't understand how to use this node ... i'm kinda new to this type of things.
Could you provide a simple and working example of flow using this node?
I don't know how to "link" node-red to messenger, especially with the HTTP GET part because i need a webhook to make it works. I already have a page access token.
Summary:
I have:

working conversation and working node of IBM watson.

page access token

node-red deployed on bluemix

I don't know how to use:

HTTP GET to get the message of a user from messenger (I need a webhook and a verify token too)

This node to send the message to the user as a response (coming from Watson node)

Thank you in advance!

There is a whole course dedicated to this - https://developer.ibm.com/courses/all-courses/node-red-basics-bots/


Installing yoga 0.0.0 podspec not using versions

Description
Yogo podspec seems to be using 0.0.0 for its version when yoga 3.x.x is expected for react native 0.74.5 to 0.76.3. Is this expected for the podspec to have a 0.0.0 version?
Steps to reproduce

Install a fresh clone of react native
run pod install (with no pods installed otherwise delete the iOS/Pods folder).

React Native Version
0.76.3
Affected Platforms
Build - MacOS
Output of npx react-native info
N/a

Stacktrace or Logs
When running pod install I always see

Installing Yoga (0.0.0)

### Reproducer

https://github.com/FrederickEngelhardt/react-native-issue-yoga-0-0-0/tree/main/ReproducerApp

### Screenshots and Videos

![20241204_180839](https://github.com/user-attachments/assets/a3950c20-9a87-4d78-9d4d-ce93294881fe)

The Yoga version built as part of RN is versioned independently of OSS Yoga releases (its whatever commit matches in the monorepo). So it makes sense that it doesn't snap to Yoga public versions.
I'm not sure if there is any consequence of it not e.g. snapping to RN versions though (like if that has any potential to cause stale build or the like).
There was also some recent change to expose the headers from Yoga to full app, which may get weird if another library brings in public version of Yoga for its own use.

Closing as answered

I guess the consequence could be when looking at the podfile if someone required yoga at a specific version it could pull in the public version on top of the react native version even if they were equivalent.
To me it just looks weird having a 0.0.0 version install. Makes sense though if this is not a direct copy of the public library.
Thanks for clarifying 👍


date: format date to correct date format before parsing

closes #6392

After looking at the code, there is this snippet in the parse_datetime_at_date function that checks 1999-1-4 against the ISO 8601 pattern.
For some reasons (I may not have all the context about it), we add "0000" to the candidate and "%H%M" to the string, which makes us check 1999-1-40000 against %Y-%m-%d%H%M.
I could understand why parsing 40000 as %d%H%M could fail, so maybe the error comes from here.
Maybe a workaround would be to add respectively " 0000" and " %H%M" to the candidate and pattern, so the parsing does not eat a 0 as part of the day.
This would require a change to the parse_datetime crate.

You mean the bug is in parse datetime crate? @RenjiSann

Yes, it most probably is.

The following example isolates the bug being on the parsing of the last single digit. It has no issue parsing -1- as a month.
use parse_datetime::parse_datetime;

fn main() {

    let one = parse_datetime("2001-01-04");
    let two = parse_datetime("2001-1-04");
    let three = parse_datetime("2001-01-4");
    let four = parse_datetime("2001-1-4");

    println!("Result:\n{:?}\n{:?}\n{:?}\n{:?}", one, two, three, four);
}

❯ cargo run
   Compiling test_parse_date_time v0.1.0 (/tmp/test_parse_date_time)
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.47s
     Running `target/debug/test_parse_date_time`
Result:
Ok(2001-01-04T00:00:00+02:00)
Ok(2001-01-04T00:00:00+02:00)
Err(InvalidInput)
Err(InvalidInput)

Here is a PR for the fix in parse_datetime https://github.com/uutils/parse_datetime/pull/76

Waiting for https://github.com/uutils/parse_datetime/pull/76 to be released

#6423 was merged, from what I am testing, this is fixed.
Maybe we can still add tests to make sure there are no regressions afterwards ?
@ahmadabd do you want to give it a shot ? You can take a look at the tests I added in parse_datetime


[Suggestion] Show all characters in "Select a champion" if Game Pass is active

All characters are unlocked if Riot Games and Xbox Game Pass accounts are linked.
If it is possible to do that, I would really appreciate it.
More information: https://www.xbox.com/en-US/xbox-game-pass/riot-games

I don't mind doing this but I don't have an Xbox Game Pass subscription. Could you compile a build and test if it works?

I made a new tree named xboxgp and updated some code. Could you try running it to see if it works as intended?

It just works perfect as intended, thank you! It really helped a lot.

Merged the tree into main then. It will be fixed next version once I'm done working on some other stuff.


How to access two methods in unity by sending a message from react native?

Use UnityMessageManager class as outlined in the README


ENH: Include 'filled' key in events.

This is the final step in making a RunEngine and a Broker
(configured with a suitable prepare_hook) return identical
documents. It should remove some annoying edge cases for
consumers that want to receive from both.
This also includes some commits to update bluesky to the new
databroker API.

The pip-based build passed. The conda-based builds failed because they got an old version of databroker.

Our dev conda builder seems to be 19 hours behind, hence the test failures on the conda build.


Why not a sass version

Hello,
thanks for your awesome theme.
Knowing next major version of bootstrap will be sass only (at least on the alpha : http://v4-alpha.getbootstrap.com/), why not a sass/scss version ?
I know there is a fork (https://github.com/aguegu/AdminLTE) but its not up to date.

Next version od AdminLTE will probably use both Bootstrap 4 and SCSS.

@enumag is right.

some users need sass with bootstrap 3 not 4


CRC non starting after succesful setup.

I'm trying to setup a study environment with crc.
I've just downloaded crc 1.23.
After a succesfull setup :
"Setup is complete, you can now run 'crc start' to start the OpenShift cluster"
when starting I get:
INFO Checking if running as non-root
INFO Checking if podman remote executable is cached
INFO Checking if admin-helper executable is cached
INFO Checking minimum RAM requirements
INFO Checking if Virtualization is enabled
INFO Checking if KVM is enabled
INFO Checking if libvirt is installed
WARN Preflight checks failed during crc start, please try to run crc setup first in case you haven't done so yet
Could not find a x86_64 hypervisor with 'hvm' capabilities
The underlying OS is CENTOS:
[utente@oc-crc crc-linux-1.23.1-amd64]$ cat /etc/eleas
CentOS Linux release 8.1.1911 (Core)
Derived from Red Hat Enterprise Linux 8.1 (Source)
crc.log
That's the last ( of four ) processor info:
processor       : 3
vendor_id       : GenuineIntel
cpu family      : 6
model           : 45
model name      : Intel(R) Xeon(R) CPU E5-4610 0 @ 2.40GHz
stepping        : 7
microcode       : 0x71a
cpu MHz         : 2400.000
cache size      : 15360 KB
physical id     : 6
siblings        : 1
core id         : 0
cpu cores       : 1
apicid          : 6
initial apicid  : 6
fpu             : yes
fpu_exception   : yes
cpuid level     : 13
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss syscall nx rdtscp lm constant_tsc arch_perfmon nopl xtopology tsc_reliable nonstop_tsc cpuid pni pclmulqdq vmx ssse3 cx16 pcid sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes xsave avx hypervisor lahf_lm pti ssbd ibrs ibpb stibp tpr_shadow vnmi ept vpid tsc_adjust arat md_clear flush_l1d arch_capabilities
bugs            : cpu_meltdown spectre_v1 spectre_v2 spec_store_bypass l1tf mds swapgs
bogomips        : 4800.00
clflush size    : 64
cache_alignment : 64
address sizes   : 43 bits physical, 48 bits virtual
power management:
The test machine is a VM on an VmWare <IP_ADDRESS>000
Any hint ?
Thanks

Can you check the user of  /dev/kvm ls -al /dev/kvm or while checking  virsh
--connect qemu:///system capabilities | grep baselabel
On Thu, Mar 11, 2021 at 3:13 AM Pigi-102 @.***> wrote:

I'm trying to setup a study environment with crc.
I've just downloaded crc 1.23.
After a succesfull setup :
"Setup is complete, you can now run 'crc start' to start the OpenShift
cluster"
when starting I get:
INFO Checking if running as non-root
INFO Checking if podman remote executable is cached
INFO Checking if admin-helper executable is cached
INFO Checking minimum RAM requirements
INFO Checking if Virtualization is enabled
INFO Checking if KVM is enabled
INFO Checking if libvirt is installed
WARN Preflight checks failed during crc start, please try to run crc setup
first in case you haven't done so yet
Could not find a x86_64 hypervisor with 'hvm' capabilities
The underlying OS is CENTOS:
@.*** crc-linux-1.23.1-amd64]$ cat /etc/eleas
CentOS Linux release 8.1.1911 (Core)
Derived from Red Hat Enterprise Linux 8.1 (Source)
crc.log https://github.com/code-ready/crc/files/6118295/crc.log
That's the last ( of four ) processor info:
processor : 3
vendor_id : GenuineIntel
cpu family : 6
model : 45
model name : Intel(R) Xeon(R) CPU E5-4610 0 @ 2.40GHz
stepping : 7
microcode : 0x71a
cpu MHz : 2400.000
cache size : 15360 KB
physical id : 6
siblings : 1
core id : 0
cpu cores : 1
apicid : 6
initial apicid : 6
fpu : yes
fpu_exception : yes
cpuid level : 13
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat
pse36 clflush mmx fxsr sse sse2 ss syscall nx rdtscp lm constant_tsc
arch_perfmon nopl xtopology tsc_reliable nonstop_tsc cpuid pni pclmulqdq
vmx ssse3 cx16 pcid sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes
xsave avx hypervisor lahf_lm pti ssbd ibrs ibpb stibp tpr_shadow vnmi ept
vpid tsc_adjust arat md_clear flush_l1d arch_capabilities
bugs : cpu_meltdown spectre_v1 spectre_v2 spec_store_bypass l1tf mds swapgs
bogomips : 4800.00
clflush size : 64
cache_alignment : 64
address sizes : 43 bits physical, 48 bits virtual
power management:
The test machine is a VM on an VmWare <IP_ADDRESS>000
Any hint ?
Thanks
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/code-ready/crc/issues/2084, or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAAAOZV7GMXECTRXPTKX253TC7AHHANCNFSM4Y6WF4LQ
.

--
Gerard Braad | http://gbraad.nl
STEM is the source, but BUILD is how you develop!
[ Better Understanding Involves Learning and Doing ]

This check is based on libvirt capabilities an match if os_type is hvm and also the arch is same as host arch. @Pigi-102 Can you provide the output of virsh capabilities | grep -A5 guest one?
$ virsh capabilities | grep -A5 guest
  <guest>
    <os_type>hvm</os_type>
    <arch name='i686'>
      <wordsize>32</wordsize>
      <emulator>/usr/bin/qemu-system-i386</emulator>
      <machine maxCpus='255'>pc-i440fx-5.1</machine>
--
  </guest>

  <guest>
    <os_type>hvm</os_type>
    <arch name='x86_64'>
      <wordsize>64</wordsize>
      <emulator>/usr/bin/qemu-system-x86_64</emulator>
      <machine maxCpus='255'>pc-i440fx-5.1</machine>
--
  </guest>

Hello !
All command as normal user. No root here :)
[utente@oc-crc ~]$ ls -l /dev/kvm
crw-rw-rw-. 1 root kvm 10, 232 Mar 10 20:07 /dev/kvm
[utente@oc-crc ~]$ virsh --connect qemu:///system capabilities | grep baselabel
system_u:system_r:svirt_t:s0
system_u:system_r:svirt_tcg_t:s0
+107:+107
+107:+107
[utente@oc-crc ~]$ sudo yum install qemu-kvm
CentOS-8 - AppStream                                                                                13 kB/s | 4.3 kB     00:00
CentOS-8 - Base                                                                                8.3 kB/s | 3.9 kB     00:00
CentOS-8 - Extras                                                                                4.1 kB/s | 1.5 kB     00:00
Package qemu-kvm-15:4.2.0-34.module_el8.3.0+704+02c27f72.3.x86_64 is already installed.
Dependencies resolved.
Nothing to do.
Complete!
[utente@oc-crc ~]$
This last don't output nothing:
[utente@oc-crc ~]$ virsh capabilities | grep -A5 guest
[utente@oc-crc ~]$
Thanks !

Could you paste the full virsh capabilities output, as well as rpm -qa |grep libvirt?

Here you are !
[utente@oc-crc ~]$ sudo virsh -c qemu:///system capabilities

7c300e42-9eed-4c0c-078e-569533c82da2

x86_64
SandyBridge-IBRS
Intel

tcp
rdma

14192440
3548110
0

selinux
0
system_u:system_r:svirt_t:s0
system_u:system_r:svirt_tcg_t:s0

dac
0
+107:+107
+107:+107

[utente@oc-crc ~]$ sudo rpm -qa |grep libvirt
libvirt-daemon-driver-nwfilter-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-iscsi-direct-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-scsi-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-iscsi-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-gluster-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-client-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-secret-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-nodedev-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-network-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-config-nwfilter-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-disk-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-logical-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-rbd-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-interface-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-libs-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-config-network-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-core-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-storage-mpath-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-driver-qemu-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-bash-completion-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64
libvirt-daemon-kvm-6.0.0-28.module_el8.3.0+555+a55c8938.x86_64

after the <host> section, there should be one or several <guest> sections corresponding to the qemu binaries libvirt was able to detect on your system. You could try restarting libvirtd in case qemu was installed after libvirt, and the libvirt daemon failed to detect these binaries (systemctl restart libvirtd). Can you also make sure you can run the qemu binary installed on your system? Running /usr/libexec/qemu-kvm should be enough to check the binary is working.

Intresting:
[root@oc-crc ~]# /usr/libexec/qemu-kvm
qemu-kvm: cannot initialize crypto: Unable to initialize gcrypt
libvirtd was dead, after restarted is  running but has some of the previous errors:
root@oc-crc systemctl status libvirtd
â libvirtd.service - Virtualization daemon
Loaded: loaded (/usr/lib/systemd/system/libvirtd.service; enabled; vendor preset: enabled)
Active: active (running) since Thu 2021-03-11 15:21:02 CET; 7s ago
Docs: man:libvirtd(8)
https://libvirt.org
Main PID: 6540 (libvirtd)
Tasks: 21 (limit: 32768)
Memory: 91.5M
CGroup: /system.slice/libvirtd.service
ââ2328 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq/crc.conf --leasefile-ro --dhcp-script=/usr/libexec/libvirt_leaseshelper
ââ2329 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq/crc.conf --leasefile-ro --dhcp-script=/usr/libexec/libvirt_leaseshelper
ââ2390 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq/default.conf --leasefile-ro --dhcp-script=/usr/libexec/libvirt_leaseshelper
ââ2391 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq/default.conf --leasefile-ro --dhcp-script=/usr/libexec/libvirt_leaseshelper
ââ6540 /usr/sbin/libvirtd --timeout 120
Mar 11 15:21:05 oc-crc dnsmasq-dhcp[2328]: read /var/lib/libvirt/dnsmasq/crc.hostsfile
Mar 11 15:21:05 oc-crc dnsmasq[2390]: read /etc/hosts - 2 addresses
Mar 11 15:21:05 oc-crc dnsmasq[2390]: read /var/lib/libvirt/dnsmasq/default.addnhosts - 0 addresses
Mar 11 15:21:05 oc-crc dnsmasq-dhcp[2390]: read /var/lib/libvirt/dnsmasq/default.hostsfile
Mar 11 15:21:05 oc-crc libvirtd[6540]: libvirt version: 6.0.0, package: 28.module_el8.3.0+555+a55c8938 (CentOS Buildsys<EMAIL_ADDRESS>2020-11-04-01:04:00, )
Mar 11 15:21:05 oc-crc libvirtd[6540]: hostname: oc-crc
Mar 11 15:21:05 oc-crc libvirtd[6540]: internal error: Failed to start QEMU binary /usr/libexec/qemu-kvm for probing: qemu-kvm: cannot initialize crypto: Unable to initialize gcrypt
Mar 11 15:21:05 oc-crc libvirtd[6540]: Failed to probe capabilities for /usr/libexec/qemu-kvm: internal error: Failed to start QEMU binary /usr/libexec/qemu-kvm for probing: qemu-kvm: cannot initialize crypto:>
Mar 11 15:21:05 oc-crc libvirtd[6540]: internal error: Failed to start QEMU binary /usr/libexec/qemu-kvm for probing: qemu-kvm: cannot initialize crypto: Unable to initialize gcrypt
Mar 11 15:21:05 oc-crc libvirtd[6540]: Failed to probe capabilities for /usr/libexec/qemu-kvm: internal error: Failed to start QEMU binary /usr/libexec/qemu-kvm for probing: qemu-kvm: cannot initialize crypto:>
It seems I'm hitting the bug:
https://bugzilla.redhat.com/show_bug.cgi?id=1828681
which refer to
https://bugzilla.redhat.com/show_bug.cgi?id=1762765
where it seems that updating from [RH]Centos 8.3 to a newer one could probably fix.
What do you think ?

Up to date EL8.3 system with respect to qemu/libgcrypt/... should be enough, I don't think you need something newer than 8.3. Which version of libgcrypt do you have installed?

After  a yum udpate it seems better now.
[utente@oc-crc ~]$ sudo virsh capabilities | grep -A5 guest

<os_type>hvm</os_type>

32
/usr/libexec/qemu-kvm
pc-i440fx-rhel7.6.0

hvm

64
/usr/libexec/qemu-kvm
pc-i440fx-rhel7.6.0
--

Unfortunally your message has come in just few second after my update so I can't tell you which version was.
If you need to know I can check for it in ISO

Now it seems to work:
[utente@oc-crc ~]$ sudo virsh capabilities | grep -A5 guest

<os_type>hvm</os_type>

32
/usr/libexec/qemu-kvm
pc-i440fx-rhel7.6.0

hvm

64
/usr/libexec/qemu-kvm
pc-i440fx-rhel7.6.0
--

Well, works "kinda of":
INFO 2 operators are progressing: kube-apiserver, operator-lifecycle-manager-packageserver
ERRO Cluster is not ready: cluster operators are still not stable after 11m5.037512962s
INFO Updating kubeconfig
WARN Skipping the kubeconfig update. Cluster operator authentication still not ready after 2min.
WARN The cluster might report a degraded or error state. This is expected since several operators have been disabled to lower the resource usage. For more information, please consult the documentation

But that's anothr subject :)

The update to lastest 8.3.2011 fixed the problem.
Thanks for assistance.

Which version of libgcrypt do you have installed?

The version of CentOS 8.2 is 1.8.3.
After I upgraded libgcrypt to 1.8.5 and restarted libvirtd, crc start worked fine.


[WIP]Az/update postgres

Motivation and context

How has this been tested?

Checklist

[x] I submit my changes into the develop branch
[ ] I have added a description of my changes into CHANGELOG file
[ ] I have updated the documentation accordingly
[ ] I have added tests to cover my changes
[ ] I have linked related issues (read github docs)
[ ] I have increased versions of npm packages if it is necessary (cvat-canvas,
cvat-core, cvat-data and cvat-ui)

License

[x] I submit my code changes under the same MIT License that covers the project.
Feel free to contact the maintainers if that's a concern.

/check

@azhavoro , I think a little bit and I propose another solution. Could you please think and give me your opinion?
Let's have a health check endpoint for CVAT. Thus we can use it in our UI and show that the server is not ready yet. Of course, we don't know the reason why, but we can show possible reasons and recommendations, a link to our documentation. I believe it is a step in the right direction.
I will recommend to integrate https://github.com/revsys/django-health-check app. Also we can write small custom plugins and detect some popular problems. For example, OPA isn't running. The problem already can be shown in UI.

/check

/check

Probably we can try to speed up our tests by simplifying restore.sql script:
I would suggest:
DROP DATABASE IF EXISTS :to WITH FORCE;

instead of current:
SELECT pg_terminate_backend(pg_stat_activity.pid)
FROM pg_stat_activity
WHERE pg_stat_activity.datname = 'cvat' AND pid <> pg_backend_pid();

DROP DATABASE IF EXISTS :to;

@azhavoro , healthcheck django package provides a command health_check. It can be used to implement https://docs.docker.com/compose/compose-file/compose-file-v3/#healthcheck. Thus we will have a status for cvat_server.

Need to document the command as well.

Need to improve the initial page

No need to write the header one more time in the body. Also at the end there is no a space between the and Upgrade Guide.

/check


refactor update Agg stats derive method

Proposed changes
This pr has no effect on tpch queries.
Some tpcds queries are impacted.
They are 4/11/23/24/47/51/57/65/74

Issue Number: close #xxx

Further comments
If this is a relatively large or complex change, kick off the discussion at<EMAIL_ADDRESS>by explaining why you chose the solution you did and what alternatives you considered, etc...

run buildall

run buildall

run buildall

run buildall


YJDH-149 | Audit logging

Description :sparkles:
Implements a shared audit logger for the YJDH project.
Loosely based on: City-of-Helsinki/apartment-application-service#68
This audit logger allows you to save log messages from Django Rest Famework CRUD events. The serializer works by defining a DRF model viewset with the subclass AuditLoggingModelViewSet.

Adds audit logging to the applicaiton viewset CRUD events.
Add tests.
Refactor testing tools to common shared.utils.testing package.

Issues :bug:
YJDH-149
Testing :alembic:
Screenshots :camera_flash:
Additional notes :spiral_notepad:

Codecov Report

Merging #130 (9c97277) into develop (c4e42ec) will increase coverage by 18.54%.
The diff coverage is 92.73%.

@@             Coverage Diff              @@
##           develop     #130       +/-   ##
============================================
+ Coverage    76.56%   95.11%   +18.54%
============================================
  Files          195       61      -134
  Lines         3871     1741     -2130
  Branches       197        0      -197
============================================
- Hits          2964     1656     -1308
+ Misses         848       85      -763
+ Partials        59        0       -59

Impacted Files
Coverage Δ

backend/shared/shared/oidc/admin.py
100.00% <ø> (ø)

backend/shared/shared/oidc/auth.py
88.15% <ø> (ø)

...red/shared/oidc/jobs/hourly/clear_user_sessions.py
100.00% <ø> (ø)

backend/shared/shared/oidc/models.py
92.59% <ø> (ø)

backend/shared/shared/oidc/services.py
97.36% <ø> (ø)

...kend/shared/shared/oidc/tests/test_auth_backend.py
100.00% <ø> (ø)

...hared/shared/oidc/tests/test_clear_sessions_job.py
100.00% <ø> (ø)

...d/shared/shared/oidc/tests/test_eauth_rest_auth.py
100.00% <ø> (ø)

...ckend/shared/shared/oidc/tests/test_eauth_views.py
100.00% <ø> (ø)

...ackend/shared/shared/oidc/tests/test_mock_views.py
100.00% <ø> (ø)

... and 169 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 c4e42ec...9c97277. Read the comment docs.


Why is dominate an optional requirement?

It's also mentioned in the dewarp README but I can't see any use of it in the codebase.

dominate is a requirement by pix2pixHD. Since, we are unsure about the pix2pixHD licensing, we kept it as an optional requirement to run the dewarp code.


added disclosure widget issue_48

Closes #48
Type of Change
Put x inside the square bracket to specify what type of change your PR is:

[x] New Feature
[ ] Bug Fix
[ ] Code Refactor
[ ] Documentation Update
[ ] Other (please specify):

Description of Change
Disclosure widget feature has been created.
Demo
Screencast from 2024-12-28 01-23-12.webm

Hi @disvid,
i'm sorry, but we will have to close this PR as the issue was not assigned to you. as previously mentioned, contributors are required to discuss their approach and announce their intention to work on an issue before submitting a pull request.
please ensure to follow this process for future contributions.
thank you for your understanding!


feat: renaming symmetric MvPolynomials

Co-authored-by: Junyan Xu<EMAIL_ADDRESS>

bors merge

bors r-

bors merge

bors delegate+


F&P dual dishwasher, fails to init with ValueError in UserCycleSetting

I'm setting up the integration for the first time and ran into an issue with a new F&P dual-drawer dishwasher, model DD24DTX6PX1  (DD613US in app).
Installing the integration via HACS and logging in went well but after setup no entitites showed up. Here's what showed up in the logs.
2023-06-10 11:47:05.323 ERROR (MainThread) [gehomesdk.erd.converters.dishwasher.erd_user_setting_converter] Could not construct user setting, using default.
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/gehomesdk/erd/converters/dishwasher/erd_user_setting_converter.py", line 28, in erd_decode
    cycle_mode = UserCycleSetting((i & 14) >> 1),   #missing brackets added by Nick
  File "/usr/local/lib/python3.10/enum.py", line 385, in __call__
    return cls.__new__(cls, value)
  File "/usr/local/lib/python3.10/enum.py", line 710, in __new__
    raise ve_exc
ValueError: 7 is not a valid UserCycleSetting
2023-06-10 11:47:05.323 ERROR (MainThread) [gehomesdk.erd.converters.dishwasher.erd_user_setting_converter] Could not construct user setting, using default.
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/gehomesdk/erd/converters/dishwasher/erd_user_setting_converter.py", line 28, in erd_decode
    cycle_mode = UserCycleSetting((i & 14) >> 1),   #missing brackets added by Nick
  File "/usr/local/lib/python3.10/enum.py", line 385, in __call__
    return cls.__new__(cls, value)
  File "/usr/local/lib/python3.10/enum.py", line 710, in __new__
    raise ve_exc
ValueError: 7 is not a valid UserCycleSetting
2023-06-10 11:47:05.324 ERROR (MainThread) [gehomesdk.erd.converters.dishwasher.erd_user_setting_converter] Could not construct user setting, using default.
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/gehomesdk/erd/converters/dishwasher/erd_user_setting_converter.py", line 28, in erd_decode
    cycle_mode = UserCycleSetting((i & 14) >> 1),   #missing brackets added by Nick
  File "/usr/local/lib/python3.10/enum.py", line 385, in __call__
    return cls.__new__(cls, value)
  File "/usr/local/lib/python3.10/enum.py", line 710, in __new__
    raise ve_exc
ValueError: 7 is not a valid UserCycleSetting
2023-06-10 11:47:05.325 ERROR (MainThread) [gehomesdk.erd.converters.dishwasher.erd_user_setting_converter] Could not construct user setting, using default.
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/gehomesdk/erd/converters/dishwasher/erd_user_setting_converter.py", line 28, in erd_decode
    cycle_mode = UserCycleSetting((i & 14) >> 1),   #missing brackets added by Nick
  File "/usr/local/lib/python3.10/enum.py", line 385, in __call__
    return cls.__new__(cls, value)
  File "/usr/local/lib/python3.10/enum.py", line 710, in __new__
    raise ve_exc
ValueError: 7 is not a valid UserCycleSetting
2023-06-10 11:47:05.326 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/config/custom_components/ge_home/update_coordinator.py", line 303, in on_device_initial_update
    self.maybe_add_appliance_api(appliance)
  File "/config/custom_components/ge_home/update_coordinator.py", line 135, in maybe_add_appliance_api
    api.build_entities_list()
  File "/config/custom_components/ge_home/devices/base.py", line 135, in build_entities_list
    e for e in self.get_all_entities()
  File "/config/custom_components/ge_home/devices/dual_dishwasher.py", line 22, in get_all_entities
    GeErdSensor(self, ErdCode.DISHWASHER_RINSE_AGENT, erd_override="lower_rinse_agent", icon_override="mdi:shimmer"),
  File "/usr/local/lib/python3.10/enum.py", line 437, in __getattr__
    raise AttributeError(name) from None
AttributeError: DISHWASHER_RINSE_AGENT

I wanted to be helpful and see if I could get a PR submitted here or in the gehome repo alongside the issue but I haven't played with this API before and it looks like the API docs are behind a registration wall that I don't have the time to jump over this weekend.
The first issue, the ValueError, looks like a simple missing state ID in the enum. The appliance itself is currently off, so I'm not sure exactly what the UserCycleSetting ID of 7 actually refers to, although it may be in the API docs.
The second issue, the AttributeError, looks like a missing value in the ErdCode enum, which looks like it's already been fixed in #161 according to issue #166. So that's good! :)
Let me know if any more information is required, I'll be happy to help.

I haven't created a formal release, but the latest version on the dev branch should have something to patch this.  I just gave it the name "FP_UNKNOWN" for now since we don't know what it is.  If you figure it out, let me know.

Cool, just saw the commit in the lib repo. Thanks! Looks like everything should be working in my HA instance once a new release is pushed that includes #161.
As far as what the UserCycleSetting of 7 is, I'm still scratching my head. It was freshly installed and was idle but may have recently completed its first cycle, or possibly a self-cleaning cycle. Was kinda hoping the vendor API docs would have something but couldn't just casually browse without signing up. 🤷

New release created, let me know if I need to reopen this if something goes amiss.

Finaly had time to test this out, things worked as expected during setup this time. Thanks!


Translating workflow

Fixes #1530

I am wondering if this is something we have to fix on the backend. If I am not mistaken the workflow states come from the backend. I have to double-check though.

superseded and implemented in Volto 16.


Reset to the previous state if a new state is cancelled.

Otherwise the current state will be inconsistent e.g. Iron.Location.get().path will not
reflect the actual URL.

Closing this to clean up my open-PR dashboard in GitHub, also because I haven't used this project in awhile, also because this would probably need some fixups before merging.


Fetch calls integrated

Description
Integrate caching to all our fetch calls so we don't get blocked by github

Can you assign me to screen flickering in /MD

Can you assign me to screen flickering in /MD

It already got assigned sorry


0.0.27 release retagged?

Hi! I'm a volunteer with the Homebrew package management project, and noticed that the release tarball checksum has changed since we packaged it shortly after release:
$ brew install -s uutils-coreutils
[...]
==> Downloading https://github.com/uutils/coreutils/archive/refs/tags/0.0.27.tar.gz
==> Downloading from https://codeload.github.com/uutils/coreutils/tar.gz/refs/tags/0.0.27
Error: uutils-coreutils: SHA256 mismatch
Expected: 28d537a5210e8593ff30c566192c7f63eb60db9ae76cd4612c2ab131e2c112d2
  Actual: 3076543a373c8e727018bd547cc74133f4a6538849e4990388f2bbea9a9aff6b

Was this release retagged? If so, it would be better to just cut a new release in future, to avoid confusing downstream packagers, and raise fears of a supply chain compromise. Thanks much!

I believe it was indeed. We tagged it outside of any public branch and fixed that later once another package maintainer notified us about it. @sylvestre could you confirm?

yeah, only Cargo.lock changed. Sorry about that :(

OK thanks, we'll update our formula accordingly.


quay.io lists v2.51.2 but i see no 2.51.2 release (with tarballs) on github

What did you do?
Just got a dependabot PR to update to v2.51.2, but when I checked github, I see no release and no artifacts.
There is a tag though:
https://github.com/prometheus/prometheus/releases/tag/v2.51.2
What did you expect to see?
I expected to find a release with all the tarballs for different architectures.
What did you see instead? Under which circumstances?
No release.
System information
Github
Prometheus version
No response
Prometheus configuration file
No response
Alertmanager version
No response
Alertmanager configuration file
No response
Logs
No response

Thanks, I see the release being marked as a draft and I don't know if it's intentional.
cc @bboreham

Sorry, I forgot to push the “Publish release” button.


Use shared ViewModel in Fragments

The WeatherApp sample does not work correctly, because the Fragment uses a different ViewModel than the Activity. It seems like it was forgotten to be updated after 0.9.1.
Since the sampleapp-arch was also created before updating to 0.9.1, I guess it was also meant to be used with a shared ViewModel.

👍 we need this PR


Added Mod Testing Automation Scripts

Added some mod testing automation scripts for easy C++ dll modding setup. Essentially to use, you bring the bat file, up into your MyMods folder, and edit the build_and_testing.py, for your game then running the bat should handle the rest
I've tested it with several games
Remnant 2, Amid Evil, and Lies of P Demo

I'm not sure this is needed.
It seems it just builds the mod and copies the files to a hard-coded path.
Building the mod shouldn't be a problem to do manually in an IDE or using CLI, I don't think we need yet another script for that.
Copying the files might be a good idea but it might be better as a post-build command in CMake so that it happens automatically when the mod is built.
In any case, there has been talk of a mod template and if such a thing is ever made, this should probably go in there instead.
Here's a list of issues I have with the scripts:

I don't like how much hard-coding of paths there is. At least, MSBuild shouldn't need to be hard-coded since we're dependent on it being in PATH for other scripts.
There's no reason to create debug/release specific versions of generate_vs_solution_internal.bat, you should pass Debug or Release to it instead.
The PDB files do not need to be copied to the game directory. Symbols should be loaded from the build directory without problems.

Furthermore, when it comes to supplying the path to the game directory, instead of having a build script that every dev of a mod must modify, I think it's better to have a separate config file that stores the path and this file can be untracked to avoid making a mess when committing.
Having a separate file would also avoid conflicts in cases where the build script is updated for other reasons.

Thanks for the in depth explanation
I'll try and polish this up in the coming days


feat: Add support of using keyword for driver and session management

Feature Request
Describe the Feature Request
The YDB SDK, like many database SDKs, offers interfaces for establishing sessions and
interacting with the database through a driver. The addition of TypeScript support, specifically for a using
keyword, would introduce several benefits for developers working with YDB.
As the support of this keyword was introduced
in Typecscript 5.2, it would be great if its support will be added to the SDK.
Resource Management: The primary advantage of a using construct is automatic resource management. In the context of YDB, this would ensure that database sessions and connections are properly closed or disposed of once they are no longer needed, reducing the risk of resource leaks that could lead to performance issues or exceeding resource limits.
Code Clarity and Maintenance: Using a using construct makes the scope of resource usage clear. It delineates where resources are started to be used and where they are released, making the code easier to understand and maintain. This is particularly beneficial in complex applications where resource management is critical.
Promote Best Practices: Encouraging the use of a using pattern or similar construct can promote best practices among developers. It makes resource management a more integral part of the development process, encouraging developers to think about the lifecycle of the resources they use.
Asynchronous Support: With the modern TypeScript ecosystem heavily relying on asynchronous operations, especially in the context of database operations, integrating using with async/await patterns would make managing asynchronous database sessions and connections more intuitive. This would allow developers to write non-blocking code while ensuring resources are automatically managed.
Describe Alternatives
I personally find callback approach for managing sessions a little bit cumbersome and I think that developer experience will be much smoother after this change.
Additional Context
Short introduction into using
If the feature request is approved, would you be willing to submit a PR?
No

Symbol.dispose and Symbol.asyncDispose appear in fresh builds of NodeJS 18 and 20.  If NodeJS is not later updated, these symbols may be missing.
So including this functionality in the SDK will require adding a polyfill.  So far the polyfill that is found has some issues itself

Node 16 reached its end of life September 16th, 2023. blog
So there's nothing wrong to drop its support.


Fix some test methods in SimulatePipelineRequestParsingTests never run and fix test failure

Description
Backport #10496 to 2.x branch.
Related Issues
https://github.com/opensearch-project/OpenSearch/issues/10493
Check List

[ ] New functionality includes testing.

[ ] All tests pass

[ ] New functionality has been documented.

[ ] New functionality has javadoc added

[x] Commits are signed per the DCO using --signoff
[ ] Commit changes are listed out in CHANGELOG.md file (See: Changelog)
[ ] Public documentation issue/PR created

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

Change log is not needed for this test related PR, and all other tests have passed yet, @dblock , please help to review this backport PR, thanks!


[followup] Local GraphQL schema

This is a followup from https://github.com/Kong/insomnia/pull/3803. Closes INS-814.

Were we not planning on putting in dropdown-dividers between the docs/remote/local options?

ahh, right, right, dividers added in https://github.com/Kong/insomnia/pull/3847/commits/41acf622471e99798a01ee2550d777a8229dd005, but I'm not 100% remembering if this is what we talked about.


Support default values for options

This should resolve the default value portion of this ticket, https://github.com/dthree/vorpal/issues/52

Convert command.js to es6
Change signature of option method to option(flags, description, options) backwards compatibility with previous signature
Fixed linting errors in a couple of files
Added an options.default property that allows for setting default values
Added two tests for default values

Thanks. I like the idea, as well as your handling of autocomplete, which is taking the third parameter. Please fix the conflicts and the points I brought up and we should be good to go!

Was just about to file an issue about this and saw the PR. 👏

@dthree changes made and conflicts avoided :)

@jbrumwell Can you rebase off master and make sure everything still works? I added Yarn support and updated all deps.

I'll go ahead and merge this and fix any inconsistencies, seeing as how the 2.0 version is a ways out. Thanks for the work!


Correct backend given by RuntimeJob.backend()

Summary
Fixed bug where the RuntimeJob.backend() did not return the correct backend.
Details and comments
When running on channel ibm_cloud, it is possible not to specify
the backend. In this case, the system selects one of the available
backends for this service.
As reported in the issue below, the the backend returned by job.backend() was not always the actual backend on which the job was run. This PR fixes
this bug.
In the previous version, the RuntimeJob._backend was assigned when the job was created. If the backend was not given as a parameter, the backend selected was simply the first in the list of QiskitRuntimeService.backends(). But the server later selects an actual backend to run the job on, and this may be a different one.
The fix is to not assign a backend if not passed as a parameter. And to assign the backend after the job has completed.
I did not add a test, because these test may take a very long time to run, and the results are not predictable.
Fixes #625 .

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

2 of 3 (66.67%)  changed or added relevant lines in 2 files are covered.
No unchanged relevant lines lost coverage.
Overall first build on wrong_backend at 74.064%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

qiskit_ibm_runtime/runtime_job.py
1
2
50.0%

Totals

Change from base Build<PHONE_NUMBER>:
74.1%

Covered Lines:
2433

Relevant Lines:
3285

💛  - Coveralls

@mriedem -  - Can you please try this on your failing test case?


Add header ids to all h tags

This is a hesitant pull request. I want to do more testing around international characters and ensuring that there aren't some weird edge cases. Still thought it's better to show progress early to get any feedback on things that might not be to your vision.

I've got to clean this up (code formatting) and fix merge conflicts.

Finally got to review this, sorry that it took so long. So, this is a good start! Comments here:

We should aim for having the same behavior as GitHub in general. See vsch's comment in #26 for some hints:

The implementation should not only handle ASCII, but check the Unicode properties. One way to do it would be using Character.isAlphabetic. Or use a Pattern to match all the allowed characters. bär should result in the ID bär. While we're at it, it should also be able to handle a followed by U+0308 COMBINING DIAERESIS.

Test that # heading\n# heading\n# heading-1 results in the IDs heading, heading-1, heading-1 (I think that's already the case due to how the code works).

I think it would be useful if the logic of calculating the IDs (including keeping a map of previous IDs) was in its own self-contained public class. That way, users can reuse it even if they want to do something else than add an ID attribute to the tag (some implementations add an inner  element for example).

Given that the change adds a new artifact for this with -ext in its name, it should probably also provide an FooExtension class that registers the AttributeProvider.

I think that should have fixed up what you've outlined. Let me know what other improvements should be made. I didn't go as far as to support every unicode combining character. If you'd like to do that, do you know of any general approach that's a good idea, or should I just be using unicode ranges like i've done so far?

The checks seem to be on Licenses for the internal modules. Would you like me to set a license on the module i've added?

Please move the code from IdAttribute to UniqueIdentifierProvider as well, that's the most tricky part of the logic. Just collect the Text and Code literals into one string (separated by spaces) and then pass it do UniqueIdentifierProvider and let it do all the replacement.

Getting all the right character classes is tricky. I would use the UNICODE_CHARACTER_CLASS flag of Pattern instead:
         Pattern p = Pattern.compile("[\\w-]+", Pattern.UNICODE_CHARACTER_CLASS);
         Matcher matcher = p.matcher(s);
         while (matcher.find()) {
             sb.append(matcher.group());
         }

There's some more test cases that work with this:
 assertRendering("# a\u1DC0", "
a\u1DC0
\n");
 assertRendering("# undertie \u203F", "
undertie \u203F
\n");

It looks like GitHub converts foo  bar to foo--bar (doesn't collapse spaces). We should do the same.

Can you change the artifact name to ext-heading-anchor and the package to ext.heading.anchor? I looked at extensions for other libraries and they all had "anchor" in the name.

Don't worry about the build, that's something they (versioneye) introduced just recently without asking. I've removed the hooks that do this now, should go away next time you push.

The only thing (i think) that i haven't quite done is the ext-heading-anchor artifact id. Each of the other artifact ids are prefixed with commonmark- so therefore i set it as commonmark-ext-heading-anchor. If you'd rather I switched from convention i'm happy to do so.

Only just realised i had to do the upstream sync! Sorry!


Bug: Scrubs won't sell you Bombs

Basically the same issue shops had where scrubs won't sell you explosives unless you've cleared Dodongo's Cavern. Apparently this is still an issue? I thought you would have addressed this with scrub shuffle but someone in discord reported having it happen in a recent seed.

Glad I didn't do scrubsanity yet ... I almost started a dev seed yesterday. Thanks for reporting.

Pretty sure it's not a thing - I replaced the whole function that checks for requirements for scrubs with the same one I use for shops, and in my testing I bought bombs fine (I had bomb bag but not DC clear).

Pretty sure it's not a thing - I replaced the whole function that checks for requirements for scrubs with the same one I use for shops, and in my testing I bought bombs fine (I had bomb bag but not DC clear).

Ah then the person must have been referring to an older seed without scrub shuffle, probably from weeks ago I'd hazard a guess. I'll close this issue then until more people report it as an issue. I sort of jumped the gun I guess, I dunno lol.


font used for function signature could be more bold

The font used for rendering signature of a function, e.g https://docs.minio.io/docs/golang-client-api-reference#RemoveBucket, where minio/doctor is deployed to serve minio's docs, could be bolder. In it's current form, it is difficult to distinguish from surrounding text.

Rushan can you look at this.

This is now configurable via dashboard.


Dutch FancyZones editor error

Microsoft PowerToys version
0.62.0
Utility with translation issue
FancyZones Editor
🌐 Language affected
Dutch
❌ Actual phrase(s)
"Afstand markeren".

✔ Expected phrase(s)
"Markeerafstand"
ℹ Why is the current translation wrong
The original string is: "Highlight distance", both nouns. The current translation reads as "Afstand (noun) markeren (verb)".
The translation should reflect this.

https://microsoft.visualstudio.com/OS/_workitems/edit/42589385

This should be fixed in a newer build such as .70.1, can you please verify? /needinfo

This should be fixed in a newer build such as .70.1, can you please verify? /needinfo

Confirmed fixed. Thanks!


@PollableBean doesn't support Kotlin lambda

Describe the issue
@PollableBean doesn't support Kotlin lambda while other spring-cloud-function features support it.
To Reproduce
✅ @PollableBean in the following code works as intended.
@SpringBootApplication
class StreamApplication {
	@Bean
	@PollableBean
	fun produceNames(): Supplier<Flux<String>> = Supplier {
		Flux.just(
			Human("human#foo"),
			Human("human#bar"),
			Human("human#baz"),
		)
	}

	@Bean
	fun logName(): (String) -> Unit = { name ->
		println("Received humans: $name")
	}
}

fun main(args: Array<String>) {
	runApplication<StreamApplication>(*args)
}

❌ But if using Kotlin lambda(kotlin.jvm.functions.Function0), it doesn't work.
@SpringBootApplication
class StreamApplication {
	@Bean
	@PollableBean // it doesn't work with Kotlin lambda
	fun produceNames(): () -> Flux<String> = {
		Flux.just(
			Human("human#foo"),
			Human("human#bar"),
			Human("human#baz"),
		)
	}
}

Version of the framework

spring-cloud-stream: 3.2.4
spring-cloud: 2021.0.3

Additional context
After some debugging, I found it was caused by this check which returned null for Kotlin lambda: https://github.com/spring-cloud/spring-cloud-stream/blob/779ebfcf887faf386e4c610537362f69826b56c8/core/spring-cloud-stream/src/main/java/org/springframework/cloud/stream/function/FunctionConfiguration.java#L382-L384
Just guess whether it should use functionWrapper.isSupplier() from:
https://github.com/spring-cloud/spring-cloud-stream/blob/779ebfcf887faf386e4c610537362f69826b56c8/core/spring-cloud-stream/src/main/java/org/springframework/cloud/stream/function/FunctionConfiguration.java#L235
Possible fix

Option 1 pass in functionWrapper and check isSupplier.

return (functionWrapper != null ? functionWrapper.isSupplier() : factoryMethod.getReturnType().isAssignableFrom(Supplier.class))
    ? AnnotationUtils.findAnnotation(factoryMethod, PollableBean.class)
    : null;

Option 2 check it in the caller
https://github.com/spring-cloud/spring-cloud-stream/blob/779ebfcf887faf386e4c610537362f69826b56c8/core/spring-cloud-stream/src/main/java/org/springframework/cloud/stream/function/FunctionConfiguration.java#L233

private PollableBean extractPollableAnnotation(...) {
  // don't check isSupplier here
  return AnnotationUtils.findAnnotation(factoryMethod, PollableBean.class)
}
PollableBean pollable = isSupplier ? extractPollableAnnotation(functionProperties, context, proxyFactory) : null;

It may have been fixed already with the previous and unrelated Kotlin work, but it s working and I added your test with this fix to verify.

It is also back-ported to 3.2.x which will be released shortly

Just tested it locally with Spring Cloud 2021.0.4 and Spring Cloud Stream 3.2.5, and it seems not working.


[EventRequest] Codeunit 5804 ItemCostManagement - OnCalculateAverageCostOnAfterExcludeOpenOutbndCosts

Requesting a new event publisher on Codeunit 5804 ItemCostManagement
Event
OnCalculateAverageCostOnAfterExcludeOpenOutbndCosts(Item : Record Item;VAR AverageCost : Decimal;VAR AverageCostACY : Decimal;VAR AverageQty : Decimal)
Code
[External] CalculateAverageCost(VAR Item : Record Item;VAR AverageCost : Decimal;VAR AverageCostACY : Decimal) : Boolean
OnBeforeCalculateAverageCost(Item,AverageCost,AverageCostACY,AvgCostCalculated);
IF AvgCostCalculated THEN
  EXIT;

AverageCost := 0;
AverageCostACY := 0;

IF CalledFromAdjustment THEN
  ExcludeOpenOutbndCosts(Item,AverageCost,AverageCostACY,AverageQty);

>>> New Code
OnCalculateAverageCostOnAfterExcludeOpenOutbndCosts(Item, AverageCost, AverageCostACY, AverageQty)

<<< New Code End
AverageQty := AverageQty + CalculateQuantity(Item);

IF AverageQty <> 0 THEN BEGIN
  CostAmt := AverageCost + CalculateCostAmt(Item,TRUE) + CalculateCostAmt(Item,FALSE);
  IF (CostAmt <> 0) AND (ABS(CostAmt) = GLSetup."Amount Rounding Precision") THEN BEGIN
    NeedCalcPreciseAmt := TRUE;
    CostAmt := AverageCost;
  END;

  GetGLSetup;
  IF GLSetup."Additional Reporting Currency" <> '' THEN BEGIN
    Currency.GET(GLSetup."Additional Reporting Currency");
    CostAmtACY := AverageCostACY + CalculateCostAmtACY(Item,TRUE) + CalculateCostAmtACY(Item,FALSE);
    IF (CostAmtACY <> 0) AND (ABS(CostAmtACY) = Currency."Amount Rounding Precision") THEN BEGIN
      NeedCalcPreciseAmtACY := TRUE;
      CostAmtACY := AverageCostACY;
    END;
  END;

  IF NeedCalcPreciseAmt OR NeedCalcPreciseAmtACY THEN
    CalculatePreciseCostAmounts(Item,NeedCalcPreciseAmt,NeedCalcPreciseAmtACY,CostAmt,CostAmtACY);

  AverageCost := CostAmt / AverageQty;
  AverageCostACY := CostAmtACY / AverageQty;

  IF AverageCost < 0 THEN
    AverageCost := 0;
  IF AverageCostACY < 0 THEN
    AverageCostACY := 0;
END ELSE BEGIN
  AverageCost := 0;
  AverageCostACY := 0;
END;
IF AverageQty <= 0 THEN
  EXIT(FALSE);

EXIT(TRUE);

In Our Solution we need to deduct values from Job Purchases, these costs may not be taken into account for the Average Cost Calculation of an Item. Please add this publisher.

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. We will update this issue with information about availability.


if your python is installed in a path which is a valid octal character code, runtest.py fails

This issue was originally created at: 2009-10-28 14:57:00.
This issue was reported by: bdbaddog.
bdbaddog said at 2009-10-28 14:57:00

Greetings,
Found this nice one today:
Python installed in :
t:\python\240\
%(python)s in test.write() expands to
cccom = '"T:\python\240\python.exe" fake_cl.py $_MSVC_OUTPUT_FLAG $CHANGED_SOURCES'
For example.
The \240 gets translated to octal character, and then python can't be found.
Need to change string to raw?
cccom = r'"T:\python\240\python.exe" fake_cl.py $_MSVC_OUTPUT_FLAG $CHANGED_SOURCES'
Maybe?

gregnoel said at 2009-12-16 15:39:26

Bug party triage.

I suspect this is fixed, there's been a lot of care to make sure rawstrings are used everywhere where Python is launched. Assign to self to check later.


Django-q-rollbar & django-q-sentry dependency contact author

Hi.
So django-q has the extensions django-q-rollbar and django-q-sentry.
Both libraries do not have the sentry or rollbar as a dependency in the setup.py. Additionally sentry is moving away from the raven sdk to sentry-sdk.
I have opened a pull request for both, but not sure if the author is still active on the projects.
Any ways of contacting the author or any ideas on progessing?

I don't know the author personally, so I don't have another way of
contacting him other than through Github.
What I can do is send @danielwelch a message and wait till I am back from
holidays in a few weeks.
He might just be on holidays too. If not, I can always think about moving
the code and maintaining it myself.
On Wed, Jul 22, 2020 at 1:58 PM crypticGøøse<EMAIL_ADDRESS>wrote:

Hi.
So django-q has the extensions django-q-rollbar and django-q-sentry.
Both libraries do not have the sentry or rollbar as a dependency in the
setup.py. Additionally sentry is moving away from the raven sdk to
sentry-sdk.
I have opened a pull request for both, but not sure if the author is still
active on the projects.
Any ways of contacting the author or any ideas on progessing?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/Koed00/django-q/issues/461, or unsubscribe
https://github.com/notifications/unsubscribe-auth/AA6AQNKOYGOCNCW4KUKENMTR43H55ANCNFSM4PEUESHQ
.

Its not overly complex code and not hard to maintain, just want it updated at some point, as we are currently installing from forked company github.
Also could be confusing to other users as missing sentry/rollbar library not reported by django-q.

Don't mind helping with some of the maintenance and admin myself, but also want credit to remain with original author

Sorry for the delay and thanks for the heads up. I've merged the changes. I don't use this personally anymore, but I'd be happy to add someone else who is actively using it / invested in the project as a contributor.

No worries!.
Welcome to add me. Currently using the sentry version of the extension. Would like to update pypi as well.

@danielwelch can you add me as a maintainer on https://pypi.org/project/django-q-sentry/ and https://pypi.org/project/django-q-rollbar/ ?
I want to add more functionality and update the pypi


is this project necessary?

On Treq, we have these three lines of tox.ini:
setenv =
    # Avoid unnecessary network access when creating virtualenvs for speed.
    VIRTUALENV_NO_DOWNLOAD=1
    PIP_DISABLE_PIP_VERSION_CHECK=1

https://github.com/twisted/treq/blob/c579f7366bd372322d04d013f088dceee6aeba6a/tox.ini#L20-L23
which seem to accomplish the same thing that this project does - at least, with a warm cache I can run my tox treq tests entirely offline.
Does this plugin do anything other than that?

It has two purposes:

in an enterprise setting you never want the default and so this is better than copy pasting to all repositories
I also believe (need to double check since I'm on my phone) that setenv is too late?

Just checked and it's equivalent 👍
https://github.com/tox-dev/tox/blob/332f4ca0680cbf80c10a9df5e5cfafc7e0b7c2c4/tox/venv.py#L404

So yes, it's mostly equivalent -- the only functional difference is this extension only exports VIRTUALENV_NO_DOWNLOAD=1 during virtualenv creation whereas setenv will set it for the entire test sequence (virtualenv creation, dependency installation, and test execution).
An example of how we deployed this at $previous_employer was to create a dh-virtualenv debian package with tox, tox-virtualenv-no-download (and a few other extensions such as tox-pip-extensions) installed.  This debian package would be installed preferentially over the tox package provided by ubuntu (because we picked a higher version number).  This would ensure that any tox invocation on $previous_employer machines wouldn't download from the internet independent of whether they had copy-pasted a setenv configuration.  (we got burned by a setuptools upgrade several months earlier and this was the simplest way to roll this out to the thousand+ repositories using tox).
As I also find this behaviour desirable and work on many many projects (many which aren't mine!) I also set up a virtualenv at ~/opt/venv and install tox extensions and symlink tox into ~/bin.
Also note that I've suggested tox do something about this as well: https://github.com/tox-dev/tox/issues/448 (I'm a tox maintainer too, so I could just make it happen -- though tox tends to lean towards "least surprise" and not overriding default behaviours of virtualenv / pip implicitly).

Thanks for the issue!  Hopefully this was helpful -- comment below if additional clarification is needed :)

Thanks so much for the thorough explanation!

I would say not anymore 👍

indeed, in latest tox this is obsolete 🎉

Maybe we should mention it in the README and archive the repository.

yep, did that

thanks 😎


Update Library to use latest revolist/revogrid

Please update the library

Updated to 4+
New renders, standalone components and full angular support