Dev

I began cleaning and organizing the project! Library files (sream.hpp, eff.hpp, and task.hpp) have been moved into include/cxxeffect/, and eff.cpp was renamed to cat.cpp and moved into the examples folder. The reason I moved them is so that now you can include them as library files:
#include <cxxeffect/stream.hpp>
#include <cxxeffect/task.hpp>
#include <cxxeffect/eff.hpp>

The cat example program was updated to reflect this. It can now be compiled with:
g++ examples/cat.cpp -I include -pthread -std=c++17

Or, by using cmake! I also added a build script, build.sh, which runs cmake (I like having these build scripts b/c I sometimes don't remember cmake commands off the top of my head). Running ./build.sh will create a build directory and compile everything there.
I also updated CMakeLists.txt so that it automatically adds a target for every file in the examples folder, which means we can add more programs to examples without having to change CMakeLists.txt!
Finally, I documented these changes in the readme (although we should probably make a separate changelog file, or just something like project_log.md)
Also I got rid of stream.cpp and task.cpp as these aren't ever used as part of the build, and all they did was include the corresponding .hpp file.

One of my end goals for this project was to not distribute this as header-only and actually do everything with runtime polymorphism under the hood.
This is something that sixten does, and I wanted to accomplish it here because I don't want executable size to explode. It seems very very wasteful to duplicate code for a bunch of similar methods because slightly different types are used.
I haven't been able to accomplish this yet, but the end result would look something like
#include <functional>
#include <string>

template<typename A>
struct Show {
    std::function<std::string (A)> show;
};

std::string show_(size_t sz, void* data, Show<void*> show) {
    show.show(data);
}

template<typename A>
inline std::string show(A a, Show<A> show) {
    return show_(sizeof(A), a, show);
}

Now imagine Show is implemented for a lot of types. The templated code generated by a non-inlined show in a single-header would explode binary size. Instead, show_ could be defined once in the shared library. This current implementation has a lot of issues though, mainly it violates assumptions related to RAII and pass-by-reference and etc, so I've been looking for someone better than me at C++ to figure it out.
(The problem in cxxeffect is even worse because in something like Pull you have not just A, but F<_>+O+R.)
I've verified that implementing the better main signature works using a shared library:

Ideally we don't duplicate code across executables. I know that this is never ever done in C++, but as far as I know, neither is a functional reactive streams library.

Hi! Thank you so much for taking the time to review the pull request! You bring up some really good points, and I understand your concern about code bloat. I want to write good code, and part of that for me means ensuring that executables are efficient, and no bigger than they need to be.
I believe templates are necessary for the public interface of the project. It may be possible to avoid the use of templates in the implementation of that interface, however I believe avoiding their use at this stage of the project represents a premature optimization.
I would like to propose the following course of action.

We implement the project as header-only while developing a specification for the publicly exposed interface of the library.
As the interface becomes more stable, we implement some non-trivial example programs using the library
We use a code analysis tool to measure code bloat/code duplication.
If code bloat is an issue, we begin work reducing / eliminating the use of templates in a separate git branch.
We compare the header-only version to the more traditional version, with a templated interface but less-templated backend. We compare runtimes and the sizes of executables generated by each.

The following sections outline and discuss some of the rationale behind this course of action.
Section 1: Regarding Templates & Code Bloat
That being said, I've worked on more complicated projects in C++, and templates haven't resulted in code bloat. Even at the lowest level of optimization, -O1, compilers inline templated functions, and in the process of inlining, they can actually remove entire sections of code that are redundant or irrelevant. When using templates, the compiler has access to information and guarantees that are otherwise unaccessible via run-time polymorphism.
I've provided an example of this here. On the left side is the code, and on the right side is the assembly generated by the compiler. Using templates introduces no performance penalties or code bloat, because the template is completely inlined: https://godbolt.org/z/fYWxdG8qW
Compilers can eliminate null-pointer checks, combine multiple redundant if-statements into the same one, and do other transformations that end up reducing the size of code, and all of this is only possible because it has access to the function definition and not just the declaration. These optimizations are completely impossible to do reliably on functions or code that's virtualized or exhibits runtime polymorphism. And this isn't just a limitation of C++ - any language with runtime polymorphism experiences massive performance penalties whenever it's used. In this code sample, I've added a third function, that prints a pointer pair using runtime polymorphism via a std::function object: https://godbolt.org/z/jhrMGYE64.
The assembly necessary to support the runtime polymorphism ends up making the function bigger and more bloated than it would have otherwise been, if templates were used. This isn't always going to be the case, but the machinery surrounding runtime polymorphism tends to be heavy and expensive in comparison to allowing the compiler to inline templated functions.
Section 2: Regarding the nature of the project as a header-only library
In the example you gave with polymorphism via std::function, that implementation would still have to go in a header file b/c the class Show is templated and the function show is also templated. It would be possible to move show_ into a separate translation unit that had a was broken up into a header and cpp file, however as the actual work would be done by whatever lambda or functor was encapsulated inside Show.show, this wouldn't actually reduce the size of the executable at all.
We'd likely get a much smaller executable if we avoid premature introduction of run-time polymorphism, and instead allow the compiler to inline things as normal.
#include <functional>
#include <string>

template<typename A>
struct Show {
    std::function<std::string (A)> show;
};

std::string show_(size_t sz, void* data, Show<void*> show) {
    show.show(data);
}

template<typename A>
inline std::string show(A a, Show<A> show) {
    return show_(sizeof(A), a, show);
}

Section 3: potential workarounds
There are ways to reduce or remove templates from the internal implementation. We could, for example, represent a program as a list of std::function objects with no templates exposed:
// implementation.cpp (self-contained translation unit)
#include <vector>
#include <functional>

using instruction = std::function<void*(void*)>;
class action {
    std::vector<instruction> program;
   public:
    action(std::vector<instruction> program) : program(std::move(program)) {}
    void* do_stuff(void* state) {
        for(instruction& ins : program) {
            state = ins(state);
        }
    }
}

// Interface, using templates. This part is header-only
using instruction = std::function<void*(void*)>;
template <class... T>
action make_action(T... actions) {
    return action({instruction(actions) ... };
}

HOWEVER, I consider this to be a premature optimization that will likely result in severe performance penalties if actually implemented.
Conclusion
The interface of the library likely has to be templated. It may be possible to use runtime polymorphism in the implementation of the backend, however trying to do this from the get-go is something I believe to be a premature optimization.
P.S. I'm sorry for writing so late! My sleep schedule is just really wack right now and also I'm staying up b/c I'm in line to get a parking pass for my university (they sell out quickly)

Yeah, the front-facing user API would be implemented with templates, but they'd be inlined to runtime-polymorphic templates.
As for template optimization, in the examples you gave, the argument types were not inspected past their pointers. If we consider C++ types as a repeated application of functors, your code might look like
print_pointer_pair : forall a b. Ptr a -> Ptr b -> ()
print_pointer_pair ptrA ptrB =
  print "Pointers: (${ptrA.address}, ${ptrB.address})\n"

In C++, Ptr is invariant on (most?) types, that is, any valid *T is also valid *U (without regards to whether the underlying data is valid). So in this code, we can actually write something like
print_pointer_pair : Ptr ??? -> Ptr ??? -> ()

because we don't actually use a or b for typechecking or calling another method. It's the same with C++, the compiler knows this and will unify templated procedures that have the same underlying code.
In cxxeffect, it's rare that any templated method would have the same underlying code. Something like show in my example definitely would, but for example flat_map_output on Pull would definitely not. As soon as someone is doing more-than-basic operations on streams, with multiple types, the binary size generated from that definitely does explode.
Section 3 isn't a satisfying solution regardless, because it disregards laziness in task construction (specifically notice how flat_map on a task that never finishes will never actually be called). cats-effect has a runLoop for task fibers which is what I looked at when trying to make my implementation.
Re premature optimization: It's not really premature optimization to me, it's more of a technical goal, even if I spout a lot about benefits. What I want the most is to have been able to put templated (on the user end) code into a shared library, I think it would be really awesome to get that working.

Hi! Thank you so much for getting back to me!

What I want the most is to have been able to put templated (on the user end) code into a shared library, I think it would be really awesome to get that working.
Could you expand more on this? From what I know

It’s definitely possible to use any and all templated functions and types from inside the implementation of a SO library,
however, any templates defined as part of the interface of a SO library (or a statically linked one) have to be explicitly instantiated.

Would it be sufficient if we provided a mechanism to do type erasure? For example, we could provide a make_polymorphic function that took in any class which acted like a task, and produced a generic_task object.
This would allow people using the library to define a stable binary interface built on generic_task types, without prematurely erasing the type inside the translation unit itself (allowing the compiler to still do a lot of inlining and optimization). It would also make it easier for people to create their own custom tasks, which would still be compatible with generic_task despite exhibiting custom functionality, provided their custom task type satisfied all the requirements of a task.

The user-facing API should be type-safe. So the basic implementation is:
Header distributed to users (note the inline):
template<typename A>
inline std::string show(A toShow, Show<A> showImplementation) {
    return internal_show(sizeof(A), ???(toShow), ???(showImplementation));
}

While the library has implemented:
std::string internal_show(size_t aSize, ??? data, ??? implementationData) {
    return implementationData.show(data);
}

As for custom tasks, task should be sealed. Any tasks that are constructed should be constructed with task::delay/task::async/task::pure and etc. It'd probably be better to implement that with a tagged union instead of how I have it now with classes.

I made an example of type erasure, where a shared library function can map an array and reverse its order without having any type information. https://godbolt.org/z/1TMKTYz3T
The jist of it is that to perform an operation without access to the type, you need to make a lambda that takes void*, reinterpret_casts them into a pointer of their respective type and then dereference. The common pattern I use is
std::function<void(void*)> erased_op = [](void* ptr) {
    T val = *reinterpret_cast<T*>(ptr) // Type information has been restored.
    // Perform whatever operation you want on val
};

Then you can give erased_op to whatever system needs to perform that typed operation without type information.

Most of these should all be different PRs. One for rewriting the build system, one for adding workflow, one for redesigning + documenting task, one for documenting stream.

Most of these should all be different PRs. One for rewriting the build system, one for adding workflow, one for redesigning + documenting task, one for documenting stream.

I can't submit new PRs until this one is resolved. I tried submitting a different PR but it didn't let me since this one hasn't been resolved

You can't open multiple PRs for a single branch; these should all be different branches. fix/better-cmake-options, feature/github-workflow, feature/task-via-conduit, doc/stream. I don't use a Git GUI, but you should be able to "Cherry Pick" commits from here into new branches created from main.
Branches should be semantically named and focus on a specific topic 😄

Thank you; I'll use semantically named branches that focus on a specific topic in the future. But do you really want me to untangle the entire dev branch into separate sub-branches? There's a whole lot of interdependency between one commit to the next and it would be a lot of work to submit all the work done here as a set of separate pull requests (The updated CMakeLists, for example, depends on the updated project layout)

Yeah, if they're dependent on each other then open a PR for the one with the least dependencies first. I believe you can branch out of a branch anyways, and then it'll work fine if the original branch is merged first.

I am begging you to please accept this pull request. I've already done a ton of work on it to fix and resolve various concerns you have and issues you brought up, and at this point it is the most well-documented and well-explained code I've ever written in my life.

Superseded by #2, #3, #4, #5, #6, #7, #8.

Apologies for the long response time, I was at dinner.


[occm] Remove finalizer from Service

When the load-balancer creation is not handled
by the CCM, the Service still gets a finalizer
named "service.kubernetes.io/load-balancer-cleanup"
added to it. The finalizer existence is blocking
Services from being deleted as the finalizer is not
cleaned up when an exception is raised of load-balancer
not found. This commit fixes the issue by ensuring not
found exceptions are ignored and allowing the
finalizer to be removed.

/cc @mdbooth

/ok-to-test

openstack-cloud-controller-manager-e2e-conformance-test is irrelevant, ignore it for now
I am requesting to be granted to override the failure , will do after that

I think the issue can be described as:
occm will always add a finalizer to a Service object, even when enabled = False is set in [LoadBalancers]. This behaviour is defined in cloud-provider, and it is not desirable to change it.
When the service object is deleted, GetLoadBalancers() unexpectedly returns an IsNotFound error rather than the expected empty list. This causes the finalizer to fail, and therefore the finalizer is never removed from the Service object, which therefore can't be deleted.

I'm eager to understand how GetLoadBalancers() can return IsNotFound, because it's not at all obvious how that is possible.

Did you work out how GetLoadBalancers() is able to return IsNotFound?

@mdbooth Yes, I double checked that this exception was raised in the CCM code and I Octavia logs had the not found.
2022-04-13 22:09:39.497 25 DEBUG octavia.api.v2.controllers.base [req-911a7958-2b41-4ebc-a2df-2b5f1f3740c2 - a64676dfa4b24cc9adfb620fef7b6506 - default default] Load Balancer 7ef868b6-80eb-440f-9f01-01bebf7e173e not found _get_db_obj /usr/lib/python3.6/site-packages/octavia/api/v2/controllers/base.py:71
2022-04-13 22:09:39.497 25 DEBUG wsme.api [req-911a7958-2b41-4ebc-a2df-2b5f1f3740c2 - a64676dfa4b24cc9adfb620fef7b6506 - default default] Client-side error: Load Balancer 7ef868b6-80eb-440f-9f01-01bebf7e173e not found. format_exception /usr/lib/python3.6/site-packages/wsme/api.py:222

To summarise an offline discussion we had about this:
The error is raised because GetLoadBalancers() is trying to hit the neutron lbaas endpoint, which no longer exists. Therefore the 404 is because the endpoint doesn't exist, not because the resource doesn't exist.
GetLoadBalancers() is trying to hit the neutron endpoint instead of the Octavia endpoint because we are explicitly setting use-octavia = False in cloud.conf. This was how we disabled the service handling behaviour of KCM using the legacy cloud provider. We recognised at the time that it was 'a bit of a hack', which is why @dulek added the enabled option in the first place.

I think there are a few issues here:
Firstly I don't believe we should ignore the 404 from GetLoadBalancers(): it is reporting a missing endpoint rather than a missing resource, so it would be misleading at best to ignore it here. I think this is a genuine failure which should cause the finalizer to exit unsuccessfully. Additionally, for the default configuration where load balancer handling is enabled, ignoring this 404 would erroneously cause the finalizer to succeed without cleaning up the load balancer during a temporary outage of the Octavia endpoint.
Ideally we would not call this code at all. I understand that we deliberately decided to call the finalizer even when enabled = False because we want to handle the case of load balancers which were created by a previous configuration before it was disabled. I wonder if there is any reliable (including historically reliable) way to determine from the Service object if we previously created an LB. e.g. Did we add an annotation or update something in the Status?
As it stands, the use-octavia flag currently must reflect the underlying cloud. Therefore setting use-octavia = false on a cloud which is new enough to no longer have the neutron lbaas endoint is not correct.
Additionally, given that neutron lbaas has now gone beyond deprecation to removal, it might be worth deprecating this option and documenting that Octavia is required?

Firstly I don't believe we should ignore the 404 from GetLoadBalancers(): it is reporting a missing endpoint rather than a missing resource, so it would be misleading at best to ignore it here. I think this is a genuine failure which should cause the finalizer to exit unsuccessfully.

https://github.com/kubernetes/cloud-provider-openstack/blob/master/docs/openstack-cloud-controller-manager/using-openstack-cloud-controller-manager.md
we stated:
NOTE: Now, the openstack-cloud-controller-manager implementation is based on OpenStack Octavia, Neutron-LBaaS has been deprecated in OpenStack since Queens release and no longer maintained in openstack-cloud-controller-manager. So make sure to use Octavia if upgrade to the latest openstack-cloud-controller-manager docker image.
so I doubt whether this is a valid use case for latest OCCM

Firstly I don't believe we should ignore the 404 from GetLoadBalancers(): it is reporting a missing endpoint rather than a missing resource, so it would be misleading at best to ignore it here. I think this is a genuine failure which should cause the finalizer to exit unsuccessfully.

https://github.com/kubernetes/cloud-provider-openstack/blob/master/docs/openstack-cloud-controller-manager/using-openstack-cloud-controller-manager.md
we stated: NOTE: Now, the openstack-cloud-controller-manager implementation is based on OpenStack Octavia, Neutron-LBaaS has been deprecated in OpenStack since Queens release and no longer maintained in openstack-cloud-controller-manager. So make sure to use Octavia if upgrade to the latest openstack-cloud-controller-manager docker image.
so I doubt whether we should do any change in the OCCM side other than ask for upgrade from lbaas to octavia now

Interestingly we're not really trying to use neutron lbaas here! Setting use-octavia=false was simply a useful way to disable the legacy cloud provider's Service controller when we were managing Services with an external controller (in this case, Kuryr). However, we now have enabled=false which is explicit, so use-octavia=false should be redundant and we can stop setting it.
We do still have a problem of trying to finalize Services which we didn't create. We can probably ignore that for now, though, as long as we aren't hitting this 404 error.

I'm closing this fix since use-octavia shouldn't be set as false.


Extend allowlist & handle extend when validating

Description:
This fixes #1523.
Checklist:

[x] Does your PR pass tests?
[x] Have you written new tests for your changes?
[ ] Have you lint your code locally prior to submission?

@zricethezav There's a strange issue with this one. The tests pass if the others are commented out, but fails if they are uncommented.
Is there some sort of state being kept between classes?

Hello, this broke the ability to override the entropy of rules.
With .gitleaks.toml:
[extend]
useDefault = true

[[rules]]
id = "finicity-client-secret"
entropy = 4

$ echo "newtype FinicityDataResponse = FinicityDataResponse" | gitleaks --config=.gitleaks.toml --redact=0 --no-banner --verbose --log-level trace stdin
11:54AM DBG using gitleaks config .gitleaks.toml from `--config`
11:54AM DBG extending config with default config

Finding:     newtype FinicityDataResponse = FinicityDataResponse
Secret:      FinicityDataResponse
RuleID:      finicity-client-secret
Entropy:     3.584184

11:54AM INF scan completed in 1.72ms
11:54AM WRN leaks found: 1

Hello, this broke the ability to override the entropy of rules.

Hey @9999years, can you elaborate on what you expect to happen and which version you upgraded from? As far as I'm aware, that would have never worked.
Prior this this PR, extend only did did two things:

Merged your custom rules with the extended config, provided there were no ID conflicts
Appended values to the global allowlist.

https://github.com/gitleaks/gitleaks/blob/v8.19.2/config/config.go#L237

@rgmz Just a minimal example. Our actual configuration looks like this:
[[rules]]
description = "Finicity Client Secret"
id = "finicity-client-secret"
regex = '''(?i)(?:finicity)(?:[0-9a-z\-_\t .]{0,20})(?:[\s|']|[\s|"]){0,3}(?:=|>|:{1,3}=|\|\|:|<=|=>|:|\?=)(?:'|\"|\s|=|\x60){0,5}([a-z0-9]{20})(?:['|\"|\n|\r|\s|\x60|;]|$)'''
secretGroup = 1
entropy = 4
keywords = ["finicity"]


Create file store

Create an implementation of the Libero file API.
[Awaiting specification]
Notes

Requests can be handled synchronously for now.

Related

Blocked by https://github.com/libero/libero/issues/127 (API spec).

The object store persists the images in a publicly available location like an S3 bucket (not a responsibility of this ticket, but for clarity)
Assumption: there is no preview of articles yet
Assumption: there is no versioning (version 1 is overwritten again and again)

No longer needed.


Fix threebot payment case when pool doesn't need extension

Description

In the case of threebot restart no need for extension
Fix threebot payment case when pool doesn't need extension

Related Issues

https://github.com/threefoldtech/tf_support/issues/17

Checklist

[x] Pre-commit hook is installed to do formatting checks before committing code...etc
[ ] Tests included
[x] Build pass
[x] Documentation
[x] Code format and docstrings

returning None, None, None here will break the chatflow, is this the needed behavior?
https://github.com/threefoldtech/js-sdk/blob/development/jumpscale/sals/marketplace/apps_chatflow.py#L565-L570

returning None, None, None here will break the chatflow, is this the needed behavior?
https://github.com/threefoldtech/js-sdk/blob/development/jumpscale/sals/marketplace/apps_chatflow.py#L565-L570

In that case I think no need for payment ?. https://github.com/threefoldtech/js-sdk/blob/8997621a37e2a259194f0486ead199451a027cc2/jumpscale/sals/marketplace/deployer.py#L360 there's a None here too same case i think


Feature Request: Outer Labels on Switches

With switches you have the ability to have inner labels. I like this ability but as I was working with a site a few weeks ago I had my client say he was confused by the inner labels. Which was "on" which was "off"? Or in my case, which was yes, which was no?
So I asked on UX Stackexchange about my dilemma. What would be the best solution? The solution was, what I would call, outer labels. In other words, the labels are outside the switch but indicate which way the switch is flipped. Here is a screenshot:

I manually coded the example you see in the screenshot but I would like to request this as a feature of the switch and not one that we have to manually code.
Thank you!

Yeah, switches can be a confusing UI element. If my answer is no, I can click an element that says “No” but then it says “Yes.” Have I answered yes or no? Hmm…
It's all in how you use 'em.
Switches are most confusing when the only feedback is the switch's state (e.g. a form that must subsequently be submitted). Switches are most useful when an obvious change is instantly apparent separate from the switch itself (e.g. a content section's visibility is toggled or a feature is enabled/disabled).
Consider only using switches the way you'd use IRL ones. Something happens when you flip a light switch—a light turns on/off—regardless of whether it's labeled on/off.
If you can't determine the state of a switch, you might be better served by a different element. Maybe try <input type="radio">.


fixed subscribe button

This should fix the subscribe buttons text from looking like this example:

To this example:

Also sorry about any formatting changes.


3node/5node.

Maybe I'm misunderstanding something, but the 3-node has 3 mdm's and 2 tb's defined, the 5 node has  two mdm's and 1 tb defined.  That seems reversed to me.

I'm missing time to check this out now, but you seem to be right at first.


Update free-courses-id.md

Add framework Codeigniter3
Hacktoberfest notes:

due to volume of submissions, we may not be able to review PRs that do not pass tests and do not have informative titles.
please read our contributing guidelines
be sure to check the output of Travis-CI for linter errors
if this is your first open source contribution, make sure it's not your last!

What does this PR do?
Add Resource(s)
For resources
Description
Add framework Codeigniter3
Why is this valuable (or not)?
you can learn from youtube.
How do we know it's really free?
yes this is free from youtube
Checklist:

[x] Not a duplicate
[x] Included author(s) if appropriate
[x] Lists are in alphabetical order

Hi there,
I've fixed it.
Thanks.

For youtube, we prefer "playlist" links and the name of the producer/creator.

Hi there,
I have changed the link to a "playlist" link.
Thanks.

Thanks, and welcome to free-programming-books!


Removed code from class, small changes in readme/A1-3

Removed "code from class" folder (not needed anymore as the code we'll be going through during classes is in the folder exercices, and all the code in "code from class" was in R), removed submission links in ReadME so that learners can submit using Google Drive, changed names and deadlines in assignments notebooks, and fixed a small bug in A1 assignment.

@danielrazavi


Collection of entity not initialized with dataloaders many-to-many relation

Describe the bug
Loading a nested many-to-many relation using dataloaders throws Collection<Entity1> of entity Entity2[entityId] not initalized error.
Edit: Simpler reproduction in the comments. It doesn't need to be a nested relation.
The reproduction contains the simplest scenario where this happens.  It has a Video that belongs to a Series which have many Categories. Client calls a graphql endpoint requesting video.series.categories which triggers the load resolvers. Loading the series works as expected but when loading categories the dataloaderUtils throws this error:
Error: Collection<Series> of entity Category[79857533-922f-450f-94bc-af774759d1af] not initialized,
  at Collection.checkInitialized (/usr/src/app/node_modules/@mikro-orm/core/entity/Collection.js:327:19),
  at Collection.getItems (/usr/src/app/node_modules/@mikro-orm/core/entity/Collection.js:108:18),
  at /usr/src/app/node_modules/@mikro-orm/core/utils/DataloaderUtils.js:146:45,
  at Array.filter (<anonymous>),
  at /usr/src/app/node_modules/@mikro-orm/core/utils/DataloaderUtils.js:179:33,
  at Array.map (<anonymous>),
  at DataLoader._batchLoadFn (/usr/src/app/node_modules/@mikro-orm/core/utils/DataloaderUtils.js:171:34),

Reproduction
import {
  Collection,
  DataloaderType,
  Entity,
  ManyToMany,
  ManyToOne,
  MikroORM,
  OneToMany,
  PrimaryKey,
  Property,
  Ref,
} from '@mikro-orm/sqlite';
import { SqliteDriver } from '@mikro-orm/sqlite';

@Entity()
class Video {

  @PrimaryKey()
  id!: string;

  @ManyToOne(() => Series, { nullable: true, ref: true })
  series?: Ref<Series>;

}

@Entity()
class Series {

  @PrimaryKey()
  id!: string;

  @OneToMany(() => Video, video => video.series)
  videos = new Collection<Video>(this);

  @ManyToMany(() => Category)
  categories = new Collection<Category>(this);

}

@Entity()
class Category {

  @PrimaryKey()
  id!: string;

  @Property()
  name!: string;

  @ManyToMany(() => Series, series => series.categories, { nullable: true, ref: true })
  series = new Collection<Series>(this);

}

describe('dataloader collection initialize issue', () => {
  let orm: MikroORM;

  beforeAll(async () => {
    orm = await MikroORM.init({
      entities: [Video, Series, Category],
      dbName: ':memory:',
      driver: SqliteDriver,
      allowGlobalContext: true,
      dataloader: DataloaderType.ALL,
    });
    await orm.schema.createSchema();

    const video1 = new Video();
    video1.id = '1';

    const series = new Series();
    series.id = '1';
    series.videos.add([video1]);

    const category1 = new Category();
    category1.id = '1';
    category1.name = 'category';
    category1.series.add(series);

    await orm.em.persistAndFlush(category1);
    orm.em.clear();
  });

  afterAll(() => orm.close(true));

  test('intialize collections using dataloaders', async () => {
    const videos = await orm.em.findAll(Video);
    expect(videos).toHaveLength(1);

    const series = await videos[0].series?.load();
    expect(series).not.toBeNull();
    await series?.categories.load();
  });
});

What driver are you using?
@mikro-orm/postgresql
MikroORM version
6.3.13
Node.js version
20.12.2
Operating system
MacOS
Validations

[X] Read the Contributing Guidelines.
[X] Read the docs.
[X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
[X] Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord.
[X] The provided reproduction is a minimal reproducible example of the bug.

cc @darkbasic

Apparently ManyToMany must not have the ref: true option. Without that it works ok.

Indeed, that option is valid only on to-one relations.


Adding TokenRefreshed event to RefreshTokenHandler

As proposed in #71

The concern here is that the code that handles the event could block. Maybe it's better to spin up a task for that.

Indeed, but I think this should be the concern of the called code and not the lib. As only the handling code knows if it may be blocking.
If you think different, I'll add a task.

I think we should do it in fire & forget style.

thanks!


ARIES-1906 - Regression - export of superclass interface fails

Changed the new getInterfaces() implementation to mimic the behavior of the old implementation.

Refer to this link for build results (access rights to CI server needed):
https://builds.apache.org/job/Aries-rsa-pr/2/


traefik (or another reverse proxy) configuration

hi
there is a way to configure imagor under traefik or another reverse proxy?
thank you

If you are using Kubernetes, you may do so by setting up a Deployment for the docker image shumc/imagor:0.2.0.
By default, Imagor listens to port 8000. You can override the port number by specifying PORT environment variable.
Create a Service that exposes the http service from targetPort 8000 to port 80.
Then create the Ingress that forwards traffic to the said service at servicePort 80, which is the reverse proxy.


When using an item that requires concentration, supply appropriate context in the AbilityUseDialog for if, when, and why its use would end or replace concentration

Related to #3028.
Circumstances in which an item may affect concentration include:

It requires concentration, but you are not concentrating; using the item will initiate concentration.
It requires concentration, but you are concentrating on a different item; using the item will replace concentration.
It requires concentration, but you are concentrating on the same item at a different level; the user should be warned that concentration will end unless they cast the spell at the same level.

It requires concentration, but you are concentrating on the same item at a different level; the user should be warned that concentration will end unless they cast the spell at the same level.

Could you clarify this? It's not a rule I'm aware of.

It requires concentration, but you are concentrating on the same item at a different level; the user should be warned that concentration will end unless they cast the spell at the same level.

Could you clarify this? It's not a rule I'm aware of.

Any concentration spell being cast would end previous concentration. When the second item is the same item, it may be worthwhile considering not breaking concentration if it gets cast at the same level.
So to clarify, this is not a rule, but a convenience feature. In case a user may want to simply re-display the item, let's say they forgot to pop out the message for example.

Agreed


Migration file on different module might cause skipping.

To regenerate this problem,
Original migrations folder files
2014_10_12_000000_create_users_table
2014_10_12_100000_create_password_reset_tokens_table
2023_10_19_195203_create_cache_table (skipped)
Module B migrations files
2023_04_15_000001_create_orders_table
2023_04_15_000002_create_order_items_table
2023_10_18_195203_create_somes_table
Module C migrations files
2023_04_16_000001_create_products_table
when php artisan migrate
2014_10_12_000000_create_users_table
2014_10_12_100000_create_password_reset_tokens_table
2023_04_15_000001_create_orders_table
2023_04_15_000002_create_order_items_table
2023_04_16_000001_create_products_table
2023_10_18_195203_create_somes_table (stop here)
it seen like migration follow file label datetime, but it never go back previous folder after run into other module. Does this mean we need to rename all migration when we using this module in other project to avoid migration truncated?

my mistake, migration not skipped, is stop by some migration which using cache table stop the migration.


Ladder climbing issue in Sinakawak Shrine

I'm at 120 fps and climbing speed is very slow in the ladder at the end of Sinakawak Shrine and when I get to the top I fall back down and can't climb out.. I have FPS set to 120, resolution set to 4k and shadow resolution set to 1024x. Let me know what other info you need.

will be fixed in the future

Issue has been resolved.


Fixes release next workflow. Closes #5075

Fixes release next workflow. Closes #5075

ready to merge 🚀

Actually, this change was the same as https://github.com/pnp/cli-microsoft365/pull/5062 so it was merged along the way 🙂


input-group-addon broken for input type date

The height is huge and it looks funny.
Tested on Chrome Windows on b4a6.  Worked fine on b4a5.

@

    <input type="date" class="form-control">

Duplicate of #21651.


Add download button for lists of papers in dashboard

Suggested by @rankishore

tested on dashboard, lists are empty

Bug fixed. Ready to test

works well, closing


[Enhancement] add release version when building artifacts

What type of PR is this：

[ ] BugFix
[ ] Feature
[X] Enhancement
[ ] Refactor
[ ] UT
[ ] Doc
[ ] Tool

TEST

Verified that the release version now matches the release tag

Checklist:

[ ] I have added test cases for my bug fix or my new feature
[ ] This pr will affect users' behaviors
[ ] This pr needs user documentation (for new or modified features or behaviors)

[ ] I have added documentation for my new feature or new function

Bugfix cherry-pick branch check:

[X] I have checked the version labels which the pr will be auto backported to target branch

[X] 3.0
[X] 2.5
[ ] 2.4
[ ] 2.3

@kevincai @imay @chaoyli  PTAL. Thank you!

@Mergifyio backport branch-3.0

@Mergifyio backport branch-2.5


The module has a SERVER-94 loading issue

The firewalld code has a SERVER-94 environment loading issue due to adding code to the PuppetX global module space in Ruby.
I have a guide on mitigating this posted at https://www.onyxpoint.com/fixing-the-client-side-of-multi-tenancy-in-the-puppet-server/.
Since this is simply code loaded in the Type, it may be simpler to move it into the Type namespace itself.
As it stands, any use of the existing code in multiple environments may result in unreliable behavior if the code in the PuppetX space is ever modified.

Since this is simply code loaded in the Type, it may be simpler to move it into the Type namespace itself.

👍

In general, are custom parent properties/parameters considered evil?

Not that I know of. Things loaded into global Ruby-space just have to be treated with care per my blog post.

If you disregard the environment bleeding issue, the parent properties look elegant.  By the time you go all meta-programming to make them environment safe, perhaps not so elegant anymore.


Training doesn't work properly

When running
python scripts/image_train.py --data_dir path/to/images $MODEL_FLAGS $DIFFUSION_FLAGS $TRAIN_FLAGS
The code will run for 2 seconds and finish it without creating a /tmp folder or something similar. There isn't any error neither.

Run python datasets/cifar10.py, for example if you want to train with cifar10 dataset.
And then replace path/to/images by cifar_train for training diffusion model.

Run python datasets/cifar10.py, for example if you want to train with cifar10 dataset. And then replace path/to/images by cifar_train for training diffusion model.

What's the differences if I directly use path/to/images point to my dataset?

You need to care about the logic which is different from each datasets. Read the code for more detail. Identifying which logic best fit in your case may ensure the quality of model.

From: Josh00-Lu @.>
Sent: Friday, August 5, 2022 2:11 PM
To: openai/improved-diffusion @.>
Cc: VU LONG GIANG 20183519 @.>; Comment @.>
Subject: Re: [openai/improved-diffusion] Training doesn't work properly (#6)
Run python datasets/cifar10.py, for example if you want to train with cifar10 dataset. And then replace path/to/images by cifar_train for training diffusion model.
What's the differences if I directly use path/to/images point to my dataset?
—
Reply to this email directly, view it on GitHubhttps://github.com/openai/improved-diffusion/issues/6#issuecomment-1206121485, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AK7LB3LEHTKPTW7CJCFJ7KDVXS5DLANCNFSM5BE26VQQ.
You are receiving this because you commented.Message ID: @.***>

maybe you need a gpu?


Chat Eating Messages

Sometimes when i type something it never goes through, even when there isn't a lag spike.

This doesn't happen anymore so gonna close


introduced random_bytes for secure random generation.

Security fix for vulnerability reported at https://huntr.dev/bounties/6-other-online-invoicing-system/

Security fix for vulnerability reported at https://huntr.dev/bounties/6-other-online-invoicing-system/

Thank you for your suggested fix, which I appreciate and acknowledge. Due to the nature of OIM, being a generated app made by AppGini, I plan to apply the fix to the generator application itself soon.

Hi @bigprof, is it open source? If so, I can test it for more bugs and issues. Can you validate my report  https://huntr.dev/bounties/6-other-online-invoicing-system/ on huntr.dev? It will help me get a bounty and encourage me to submit more reports and fixes. Thanks.

Hi @bigprof, is it open source? If so, I can test it for more bugs and issues. Can you validate my report https://huntr.dev/bounties/6-other-online-invoicing-system/ on huntr.dev? It will help me get a bounty and encourage me to submit more reports and fixes. Thanks.

AppGini itself (the generator) is not open source.

Hi @bigprof, is it open source? If so, I can test it for more bugs and issues. Can you validate my report https://huntr.dev/bounties/6-other-online-invoicing-system/ on huntr.dev? It will help me get a bounty and encourage me to submit more reports and fixes. Thanks.

AppGini itself is not open source. But I just confirmed the issue is valid on hunter.dev now.

Hi @bigprof, is it open source? If so, I can test it for more bugs and issues. Can you validate my report https://huntr.dev/bounties/6-other-online-invoicing-system/ on huntr.dev? It will help me get a bounty and encourage me to submit more reports and fixes. Thanks.

AppGini itself (the generator) is not open source. But I just confirmed the issue is valid on hunter.dev now.

thanks @bigprof. I will try finding bugs in the open sourced code.


Migrate to osrm-text-instructions 0.9.0

Update for changed osrm-text-instructions v0.5 API to restore broken names highlighting introduced in #223.
New {exit} names are also highlighted now.

Migrate to osrm-text-instructions v0.9.0 to new formatToken callback instead of removed  tokenizedInstruction in "Accept callback for formatting tokens" PR


Upgrade kubernetes-incubator/service-catalog to 0.1.10

Since they are moving out of alpha quick, it's best to keep in sync with them

@etsangsplk Was this issue meant for a different repository? I don't think Metacontroller has any connection to Service Catalog.

Oops yup wrong repo


fix: jsonwebtoken usage

Description
The jsonwebtoken package doesn't provide the method to decode the token through the package exports anymore. This fixes the issue and adds types for the package to avoid such issues in the future.
Also included a minor typescript upgrade into the PR.

Coverage: 67.359% (-0.3%) from 67.69% when pulling 5ccfe3cc6179d3a2635d3703f8c93e7281f5518a on OEvgeny:fix/jsonwebtoken-usage into 68c7bd9f250347ff5d09b3a7e70d5c04f3114a54 on microsoft:main.


Add tests for ugrid integration

Add some tests for NetCDF files implementing ugrid conventions.  I will add a PR with a couple test cases once ugrid compliant NetCDF file is present in the iris test data.

Is this closed by #4058 and #4074?

Is this closed by #4058 and #4074?

@rcomer in theory yes, however that functionality is still in a feature branch, so I wouldn't consider the matter actually closed until mesh-data-model is merged to master.

So is this closed by #4313? 😇


proposal: Go 2: error handling with magic .handleErr() method

Author background

Would you consider yourself a novice, intermediate, or experienced Go programmer? Intermediate
What other languages do you have experience with? C & C++/Java/Javascript/Ruby/PHP/Rust/Assembly/Go

Related proposals

Has this idea, or one like it, been proposed before? No that I am aware of.

If so, how does this proposal differ?

Does this affect error handling? Yes

If so, how does this differ from previous error handling proposals? Not aware of another proposal like the one I am about to create

Is this about generics? No

If so, how does this relate to the accepted design and other generics proposals?

Proposal

What is the proposed change?
I propose to add a new method which can be named handleErr, unwrap or expect or  to any function operation that may return a value and an error or just an error. Currently error handling feels very repetitive in many cases. After using a function we need to add about 3 lines of code to test if err != nil. What I am proposing would allow us to accomplish the same but with less code. I am not proposing to replace the existing error handling but to enhance it.
I have been inspired by the same functionality that is available in Rust.

Who does this proposal help, and why?
It helps to handle errors with less code.

Please describe as precisely as possible the change to the language.
We would enhance the existing error handling mechanism by adding special functions which are evaluated at compile time and have the compiler either add code for us (add the classic if statements we would add) or exit the enclosing function's execution while simulating the same thing that happens when we manually return the error.

Before

func ExpelUser(userId int) error {

    err := findUserAndFlag(userId)
    if err != nil {
        return err
    }

    err = executeAction2(userId)
    if err != nil {
        return err
    }

    err = closeAccountAndPayUserOff(userId)
    if err != nil {
        return err
    }
    return nil
}

After

func ExpelUser(userId int) error {

    // Ends execution of ExpelUser and returns the error that findUserAndFlag returned if it's not nil
    findUserAndFlag(userId).handleErr()

    executeAction2(userId).handleErr()

    // Returns a different type of error
    closeAccountAndPayUserOff(userId).handleErr(errors.New("Error closing account"))

    return nil
}

Another example is when the function is supposed to return a value and an error

Before

func FindRecordOrCreateIt(data map[string]interface{}, existingId int) Record, error {
    record := new(Record)

    err := database.FindRecordById(&record, id)

     // Something else happened other than the expected NotFound
    if !err.Is(database.ErrNotFound) {
        return record, err
    }

    if record.ID != 0 {
        return record, err
    }

    err = validateUserCreateData(data)
    if err != nil {
        return err
    }

    err = createUser(&record, data)
    if err != nil {
        return err
    }

     return record, nil
}

After

func FindRecordOrCreateIt(data map[string]interface{}, existingId int) Record, error {
    record := new(Record)

    // Check if the error is not sentinel error database.ErrNotFound and return it along with record
    err := database.FindRecordById(&record, id).handleErrAgainst(record, database.ErrNotFound)

    if record.ID != 0 {
        return record, err
    }

    validateUserCreateData(data).handleErr()
    createUser(&record, data).handleErr()

    return record, nil
}

Costs

Would this change make Go easier or harder to learn, and why?
I think it would make Go more enjoyable, specially around the error handling area.
In Go we are expected to treat "Expected Errors" as error values (sentinel errors) and "Unexpected errors/Exceptions" as Error Types but we incur in a lot of IF statement repetitions to accomplish error handling. What I am proposing is to de-load the usage of if statements to check errors and return them and have a special way of dealing with that so we use IF statements to check application logic rather than both (logic and error handling).

Implementation tips
As the first pass, we can have the compiler write the if statement for us when encounters a function call followed by a call to one of the special functions. Just like we do with the * and pointers. Then, in a future implementation a more comprehensive approach could be implemented.

Thanks.  Please see #40432.  This seems fairly similar to some existing proposals.  It seems to imply somewhat hidden flow of control, as in x := f1().handleErr() + f2().handleErr(), which can return from the function after calling f1 but before calling `f2.  We've consistently rejected proposals with this kind of flow of control in the middle of an expression.

Based on the comment and the emoji voting, this is a likely decline.  Leaving open for four weeks for final comments.

No further comments.


The Thumb Icon in the Petition Card Has Been Fixed

I have fixed the thumb icon in the Petition Card to solve the issue mentioned here https://github.com/jonogon/jonogon-mono/issues/18

Why are they both thumbs down? Isn't it the same issue as before but opposite direction?

Thanks. Really appreciate it.


Custom initialization method

Currently YYModel use +new method to init instance, but in some cases, user may need their custom initialization method, especially use YYModel with other local database model.

You may creates objects with the custom initialization method, and then call -yy_modelSetWithJSON: or -yy_modelSetWithDictionary: to set the properties.


[BUG] Performance issues of Scheduler’s Reservation

What happened:

What you expected to happen:
How to reproduce it (as minimally and precisely as possible):
Anything else we need to know?:
Environment:

App version:   koordinator v1.3.0
Kubernetes version (use kubectl version):  kubernetes v1.24
Install details (e.g. helm install args):
Node environment (for koordlet/runtime-proxy issue):

Containerd/Docker version:
OS version:
Kernal version:
Cgroup driver: cgroupfs/systemd

Others:

/assign


back dated memos?

Is your feature request related to a problem?
hello,
great project, can there be a feature to change date of the memo?
Describe the solution you'd like
like back date or past date
thanks
Additional context
No response

try to double click the time of a memo.

this is awesome, thanks

update
https://github.com/usememos/memos/issues/1017#issuecomment-1537354763


Fix issue2433(支持field的key（@type）不在第一位)

fix #2433
添加对Map类型的支持，@type写在前中后都可以

有个用例没过，但是本地构建测试是没问题的 - - CI时区导致

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@40eed46). Click here to learn what that means.
The diff coverage is 78.94%.

@@            Coverage Diff            @@
##             master    #2751   +/-   ##
=========================================
  Coverage          ?   80.07%
  Complexity        ?     7080
=========================================
  Files             ?      145
  Lines             ?    26737
  Branches          ?     6383
=========================================
  Hits              ?    21409
  Misses            ?     3492
  Partials          ?     1836

Impacted Files
Coverage Δ
Complexity Δ

...com/alibaba/fastjson/parser/DefaultJSONParser.java
87.99% <78.94%> (ø)
319 <0> (?)

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 40eed46...9928beb. Read the comment docs.


Added the ability to automatically use protos in nuget packages, and to easily package protos with nuget

See https://github.com/grpc/grpc-dotnet/issues/183
Protobuf items can now be marked for packing as server, client or both, and any project using the resulting package will automatically generate partial implementations
To package a proto, set the GRPCPackAs prop on your protobuf
This can also be done via the UI in VS

To pack the project with only protos (no other files):
dotnet pack /p:PackOnlyProtos="true"
Or with a different package id (if the project already emits a package):
dotnet pack /p:PackOnlyProtos="true" /p:PackageId="YourPackage.Protos"
Generating server/client from a nuget package is as simple as referencing it and Grpc.Tools
Sample build output

@AspirinSJL

Thank you for your pull request. Before we can look at your contribution, we need to ensure all contributors are covered by a Contributor License Agreement.
After the following items are addressed, please respond with a new comment here, and the automated system will re-verify.

User @stueeey isn't covered by a CLA. They will need to complete the form at https://identity.linuxfoundation.org/projects/cncf

Regards,
CLA GitHub bot

Have signed the CLA, how do I add tags?

@jtattermusch do I need to do anything further here before it can be reviewed?

@stueeey only maintainers can add tags, I've done so.
I will try to review soon.

CC @JunTaoLuo  @JamesNK

@jtattermusch I've seen a lot of discussion about this but I haven't had time to look into it closely, and I'm not an expert when it comes to build files. Afraid I can't contribute much to this one!

@jtattermusch Please sir?
Also the CI system seems very upset since my merge commit, did I do something wrong?

@stueeey  for external contribution, we need to whitelist the PR so tests can run (I've done so a minute ago).

Thanks for the contributions. TBH don't understand the details of how this is supposed to be used.
Can you explain the use case a bit more. Also, because this seems to be a feature proposal where people will have different opinions, it would be better to start with explaining the use case and the approach used first, before actually implementing this (the MSBuild diffs aren't very readable and it's hard to understand how this should be used).

My guess what the intended use case could be (please confirm or explain)

the user implements a library that contains .proto files (besides .cs files) and wants to create a nuget out of it
when packing the project, a nuget is created that only contains the .proto files (and no code-generated code). It also contains metadata about what the intended protoc options are going to be.
in another project, someone pulls the nuget (with .proto files) as a dependency. If they also add Google.Protobuf.Tools package (not added by default), the protobuf C# code will be generated for them automatically, using the options provided in the nuget.

If this description is accurate, I think there will be some questions (it's not as simple as it looks like and there's some corner cases IMHO).  I'd also like to understand why this approach is better than simply including the generated protobuf C# code in the nuget package.

Your summary of the intention is pretty close.
The primary intention is to make packaging proto files as easy as possible and preferably not requiring the dark art of msbuild as it is not a common skill (see linked issue)
This change would allow you to build a server app with a proto in it, mark it as publish and then just pack the project to get a client, server or client + server package. Then the package can just be pulled in by the client and they are good to go. Because the code is being compiled into the client it can also use the advantages of having a partial class and extend it. Do you think we need a sample project to Illustrate this?
The package actually doesn't specify the protoc options beyond whether to generate a client or server, the consuming client project can specify the rest (see Protobuf_DefaultAccess and Protobuf_DefaultClientBaseType)
However you did point out something I missed which is that the emitted package should probably have a dependancy on GRPC.tools. what are the corner cases you are concerned about?

could you please share the status of the PR?

Stalled..

Hey @stueeey - have just run into the same issue as faced in https://github.com/grpc/grpc-dotnet/issues/183 which is how I find myself here.... any progress?

While this is a useful addition in principle, we'd need to improve our testing story for Grpc.Tools before we can accept improvements like this (the existing Grpc.Tools logic is already quite complex and it's very fragile because the combination of using non-trivial msbuild scripts and the protoc/codegen plugins being native components makes it very challenging to come up quick, reliable and easy-to-maintain tests).
So for now, I'd like to put this PR on hold. We can revive in the future if we have more solid foundations to build on top of.


bug: I can not override  in inside config/keymaps.lua

Did you check docs and existing issues?

[X] I have read all the LazyVim docs
[X] I have searched the existing issues of LazyVim
[X] I have searched the exsiting issues of plugins related to this issue

Neovim version (nvim -v)
NVIM v.0.9
Operating system/version
Linux
Describe the bug
I try to override  behavior, but it seems not working. I set it inside the config/keymaps.lua. Did I do it wrong way ??
Steps To Reproduce

Install starter pack or LazyVim
set keymap on lua/config/keymaps.lua

Expected Behavior
This should do it, I think I miss something
Repro
-- DO NOT change the paths and don't remove the colorscheme
local root = vim.fn.fnamemodify("./.repro", ":p")
-- set stdpaths to use .repro
for _, name in ipairs({ "config", "data", "state", "cache" }) do
  vim.env[("XDG_%s_HOME"):format(name:upper())] = root .. "/" .. name
end

-- bootstrap lazy
local lazypath = root .. "/plugins/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
  vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", lazypath, })
end
vim.opt.runtimepath:prepend(lazypath)

-- install plugins
local plugins = {
  "folke/tokyonight.nvim",
  "folke/LazyVim",
  -- add any other plugins here
}

vim.g.mapleader = " "

require("lazy").setup(plugins, {
  root = root .. "/plugins",
})

vim.cmd.colorscheme("tokyonight")
-- add anything else here
vim.keymap.set("n", "<C-K", "<Cmd>TmuxNavigateTop<CR>", {noremap=true,silent=true)

What does :verbose nmap <c-k> say?
You need to set it in lua/config/keymaps.lua


Fix the vagrants

Add a new, lean base box, have puppet scripts for most things to
easisly rebuild our box, and have it work out-of-the-box. YAY!
r? would be great, but please don't merge until I say it's cool (or just let me do it) -- I have to upload the box and I'm at a cafe right now, so it won't be ready for a few hours.

r? again? I fixed the issues and added some more test aliases, as well as NiceDots. Oh, and the VM is uploading now: so again, please no merge yet.

File is in place; if this is r+ just merge 'er in!

r? somebody? Tests pass on this sucker and I'd like the new VM to be usable for all.

@tallowen gave me the r+ on the IRCs.


png decoder cannot display properly

Now I follow this post https://littlevgl.com/blog/50/use-png-images-in-littlevgl to set my screen background:
my code is like this:
unsigned LoadPng(const char* filename, lv_img_dsc_t *png_dsc)
{
uint32_t error;
unsigned char * png_data;
size_t png_data_size;
unsigned ret = 1;
error = lodepng_load_file(&png_data, &png_data_size, filename);
if(error == 0)
{
unsigned char * png_decoded;
uint32_t png_width;
uint32_t png_height;
error = lodepng_decode32(&png_decoded, &png_width, &png_height, png_data, png_data_size);
if(error == 0)
{
png_dsc->header.always_zero = 0;
png_dsc->header.cf = LV_IMG_CF_TRUE_COLOR_ALPHA;
png_dsc->header.w = png_width;
png_dsc->header.h = png_height;
png_dsc->data_size = png_width * png_height * 4;
		png_dsc->data = png_decoded;
		ret = 0;
	}
}
return ret;

}
create image object and display here:
#if WALLPAPER
if(LoadPng("1:background.png", &png_dsc) == 0)
{
	imgBackground = lv_img_create(scr, NULL);
	lv_img_set_src(imgBackground, &png_dsc);
	lv_obj_set_size(imgBackground, LV_HOR_RES, LV_VER_RES);
	lv_obj_set_pos(imgBackground, 0, 0);

}

#endif
I want to display this picture:

but the result is like this:

displayed image looks not good,  does anybody know where the problem is?

Hello,
I have a similar problem. I used the decoder mentioned in the previous comment, using the test image. After the initialization using png_decoder_init() from png_decoder.c, i did this simple try in my code:
lv_obj_t* try_image = lv_img_create(scr_, NULL); lv_img_set_src(try_image, "lib/display/littlevGL/png_decoder/png_decoder_test.png");
In the decoder_info function I've set up the cf to LV_IMG_CF_TRUE_COLOR_ALPHA and got the following result:

I also tried LV_IMG_CF_TRUE_COLOR:

Any help would be appreciated, thank you.

What is your color depth? LV_COLOR_DEPTH in lv_conf.h.
By default, the png decoder in the post decompresses the images to 32 bit ARGB888 format. Which is not good if you have 16 bit RGB565 color depth.

Yes, the color depth was set to 16. Adjusting it to 32 I get the following, which is better but still not good:

I also tried using a different lodepng function for decoding in decoder_open()
error = lodepng_decode_memory(&png_decoded, &png_width, &png_height, png_data, png_data_size, LCT_RGBA, 16);
with this as a result:

Could you please explain how to use ARGB888 format, or what to do to make 16 bit RGB565 work? Thank you.

Hi,
I've just updated the png_decoder. Please download it again.
Now it converts the output image if you don't have 32 bit color depth.

https://littlevgl.com/blog/png/png_decoder.zip

Hi,
I've just updated the png_decoder. Please download it again.
Now it converts the output image if you don't have 32 bit color depth.

Thank you! I would just like to add that since the type of my image was a file, i needed to add convert_color_depth(png_decoded,  png_width * png_height); before return png_decoded; in the if (src_type == LV_IMG_SRC_FILE) block of the decoder_open function.

I added updated the decoder again by adding the converter to the file decoding as you pointed out.
This color order worked for me on PC but glad to hear you made it work.
It seems this improvement solved the issue so I close this issue. If you have remarks feel free to comment here.


Implement md velocity scaling arted

Only for use_ehrenfest_md=y, velocity-scaling is applied every step_velocity_scaling time step to control temperature.

Thank you @ayamada224 san. I will review this PR later. Since it seems to be a bit difficult for me. I think I can provide the decision by tomorrow.


Dynamic Title

Hello,
Thanks for the great module - Is their any way to dynamically change the sate of a title and navbar.
For example.
<Route key="UserCredentials" name="UserCredentials" hideNavBar={this.state.UserCredentialsNavBar} component={UserCredentials} initial={ false } title={this.state.title} schema="withoutAnimation" />
And then I would have a listener which would change the state this.state.UserCredentialsNavBar 'true' or 'false' and this.state.title 'Some title' or 'Some other title'.
I tried but didn't get any where.
Thanks in advance.
:0)

I've just added support to set properties without navigator transition using Actions.refresh(props), please try it (version 2.3.1)

Thanks aksonov.
I may not be understanding you properly.
So, for instance if I wanted to change the state of the title. I would call
Actions.refresh({title: 'Some other title'})
Many thanks for getting back to me.
:0)

My bad, its all working great. Thanks very much for your help aksonov. Much appreciated. :0)

I'm running into an issue that seems like a bug here with setting the title dynamically. It seems like Actions.refresh sets it for all routes, overriding their static titles.
In my case, I have a master-detail setup where the master route has a title prop and the detail route title is only set dynamically. When I'm in the detail route and the title changes what happens is that both the title and the back button change to the same text. When going back to the master, the dynamic title stays on (rather than going back to its schema title).
I'm new to React Native so I'm not sure if this is by design or not...?
Thanks!

Is there a way to set it for a specific scene even if I'm not currently on that scene? ie
Actions.refresh({key: 'home', title: 'My new title'})

@greatwitenorth whats your exact use case?
e.g. if you are navigating to a view with the key view2 you can set the title with the props like this
Actions.view2({ title: 'My New Title' })

My issue was that I wasn't navigating to the scene that needed it's title updated. My screen updated the user's address, but the address was displayed as a title on a completely seperate screen.

@greatwitenorth I ran into same problem. How to change the title without navigating to a new route with changed title?

OK, I should have read the documentation better, it's simply Actions.refresh{title: 'new title'}

@greatwitenorth did you find any decent solution?
I'm fetching the title from the state, so whenever the state changes, I want a specific view to have that value as a title. Sometimes people change the title and navigate via the back button, in that case I can't seem to define the {title: } parameter (and pass the state-value in the back action), or am I missing something?
Kind regards,

@JeroenNelen I had a similar issue and solved it by putting the refresh in ComponentDidMount and setting the state in Redux reducers - I tie a Redux action into every user action that changes the title, update the app state, and the props the refresh reads updates too.
So basically something like this line in ComponentDidMount:
Actions.refresh({title: this.props.state.myapp.myvalue})

@jondbm thanks for the suggestion, but we've decided to switch to a different navigator.
Kind regards,

@JeroenNelen which navigator are you using right now?

Why below setup is not refreshing right button? console.log writes the new value, but the right title never gets refreshed?
const RouterWithRedux = connect()(Router);

export class App extends Component {

  constructor(props) {
    super(props);
  }

  render() {
    let title = '(' + this.props.basket.length + ')';
    console.log(title);
    return (
      <RouterWithRedux rightTitle={title} onRight={() => alert('All right')}>
        <Scene key="root">
          <Scene key="home" component={Main} title="Main"/>
          <Scene key="page1" component={SomePage} title="SomePage"/>
        </Scene>
      </RouterWithRedux>
    );
  }
}
App.propTypes = {
  dispatch: PropTypes.func.isRequired
};

// Wrap the component to inject dispatch and state into it
export default connect(
  state => {
    return {basket: state.basket.items}
  }
)(App);

@jaynakus righttitle or right button?

The Title!

I would suggest using custom navbar, with whatever you want it to be in it.

@jaynakus try putting your rightTitle and onRight into your Scene component instead of at the top RouterWithRedux level, that might work.

@jondbm putting them to root scene didn't solve, but calling Actions.refresh() in componentWillReceiveProps did the trick ;)
const RouterWithRedux = connect()(Router);

export class App extends Component {

  constructor(props) {
    super(props);
  }

  componentWillReceiveProps(nextProps) {
    if (this.props.basket.length !== nextProps.basket.length) {
      console.log(nextProps.basket.length);
      let title = '(' + nextProps.basket.length + ')';
      Actions.refresh({rightTitle: title});
    }
  }

  render() {
    let title = '(' + this.props.basket.length + ')';
    return (
      <RouterWithRedux>
        <Scene key="root" rightTitle={title} onRight={() => alert('All right')}>
          <Scene key="home" component={Main} title="MixiPay"/>
          <Scene key="fatura" component={Fatura} title="Fatura"/>
        </Scene>
      </RouterWithRedux>
    );
  }
}
App.propTypes = {
  dispatch: PropTypes.func.isRequired
};

// Wrap the component to inject dispatch and state into it
export default connect(
  state => {
    return {basket: state.basket.items}
  }
)(App);

look here: https://github.com/aksonov/react-native-router-flux/issues/1922

If you want to dynamically put in left or right buttons, use 'right' and 'left' instead of 'renderRightButton', e.g.
componentWillMount(){
Actions.refresh({title: 'dynamic title', left: this.renderLeftButton, right: this.renderRightButton})
}
renderRightButton(){
return(

Right Button

)
}
renderLefttButton(){
return(

Left Button

)
}
For some reason, renderRightButton wouldn't work as a key in the Actions.refresh and it was just 'right' instead, found that to be a gotcha to look out for

@greatwitenorth whats your exact use case?
e.g. if you are navigating to a view with the key view2 you can set the title with the props like this
Actions.view2({ title: 'My New Title' })
```How can we access it in setup file?


Fix duplicative API API.

This fixes a duplicative "API API" string that causes a broken README link in ReST.

Codecov Report

Merging #1028 into master will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master    #1028   +/-   ##
=========================================
  Coverage     85.29%   85.29%
  Complexity     3415     3415
=========================================
  Files           352      352
  Lines         13590    13590
  Branches       1552     1552
=========================================
  Hits          11591    11591
  Misses         1552     1552
  Partials        447      447

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 e9d56c7...0b37cd5. Read the comment docs.


Multiple SSH Keys support

Description
Is a continuation of https://github.com/apache/cloudstack/pull/5215
The result of the GSoC project
Adds support for multiple SSH Keys for VMs.
Types of changes

[ ] Breaking change (fix or feature that would cause existing functionality to change)
[x] New feature (non-breaking change which adds functionality)
[ ] Bug fix (non-breaking change which fixes an issue)
[ ] Enhancement (improves an existing feature and functionality)
[ ] Cleanup (Code refactoring and cleanup, that may add test cases)

Feature/Enhancement Scale

[x] Major
[ ] Minor

Screenshots (if appropriate):

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_multiplication_x: el7 :heavy_multiplication_x: el8 :heavy_multiplication_x: debian :heavy_multiplication_x: suse15. SL-JID 2562

@blueorangutan package

@sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_multiplication_x: debian :heavy_check_mark: suse15. SL-JID 2564

@blueorangutan package

@nvazquez a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2568

@blueorangutan test

@davidjumani a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

Trillian test result (tid-3285)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 30891 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3285-kvm-centos7.zip
Smoke tests completed. 91 look OK, 1 have errors
Only failed tests results shown below:

Test
Result
Time (s)
Test File

test_01_invalid_upgrade_kubernetes_cluster
Failure
28.31
test_kubernetes_clusters.py

test_02_upgrade_kubernetes_cluster
Failure
26.92
test_kubernetes_clusters.py

test_03_deploy_and_scale_kubernetes_cluster
Failure
25.89
test_kubernetes_clusters.py

test_04_autoscale_kubernetes_cluster
Failure
27.86
test_kubernetes_clusters.py

test_05_basic_lifecycle_kubernetes_cluster
Failure
29.01
test_kubernetes_clusters.py

test_06_delete_kubernetes_cluster
Failure
35.24
test_kubernetes_clusters.py

test_07_deploy_kubernetes_ha_cluster
Failure
36.99
test_kubernetes_clusters.py

test_08_upgrade_kubernetes_ha_cluster
Failure
35.97
test_kubernetes_clusters.py

test_09_delete_kubernetes_ha_cluster
Failure
36.01
test_kubernetes_clusters.py

ContextSuite context=TestKubernetesCluster>:teardown
Error
131.59
test_kubernetes_clusters.py

Will run / fix the kubernetes tests after #5863 is merged

does that mean this is/should be still draft @davidjumani ?

@DaanHoogland Nope, just that it's not worth fixing as the CKS codebase is changed in that PR

@blueorangutan package

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2628

@blueorangutan test

@davidjumani a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

Trillian test result (tid-3363)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 30213 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3363-kvm-centos7.zip
Smoke tests completed. 91 look OK, 1 have errors
Only failed tests results shown below:

Test
Result
Time (s)
Test File

test_01_invalid_upgrade_kubernetes_cluster
Failure
33.25
test_kubernetes_clusters.py

test_02_upgrade_kubernetes_cluster
Failure
33.01
test_kubernetes_clusters.py

test_03_deploy_and_scale_kubernetes_cluster
Failure
33.96
test_kubernetes_clusters.py

test_04_autoscale_kubernetes_cluster
Failure
34.00
test_kubernetes_clusters.py

test_05_basic_lifecycle_kubernetes_cluster
Failure
31.02
test_kubernetes_clusters.py

test_06_delete_kubernetes_cluster
Failure
35.19
test_kubernetes_clusters.py

test_07_deploy_kubernetes_ha_cluster
Failure
34.20
test_kubernetes_clusters.py

test_08_upgrade_kubernetes_ha_cluster
Failure
28.82
test_kubernetes_clusters.py

test_09_delete_kubernetes_ha_cluster
Failure
27.84
test_kubernetes_clusters.py

ContextSuite context=TestKubernetesCluster>:teardown
Error
124.23
test_kubernetes_clusters.py

@blueorangutan package

@nvazquez a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2648

@blueorangutan test

@DaanHoogland a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

Ping for review @Pearl1594 @weizhouapache

Trillian test result (tid-3387)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 41827 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3387-kvm-centos7.zip
Smoke tests completed. 91 look OK, 1 have errors
Only failed tests results shown below:

Test
Result
Time (s)
Test File

test_01_invalid_upgrade_kubernetes_cluster
Failure
26.94
test_kubernetes_clusters.py

test_02_upgrade_kubernetes_cluster
Failure
28.02
test_kubernetes_clusters.py

test_03_deploy_and_scale_kubernetes_cluster
Failure
24.82
test_kubernetes_clusters.py

test_04_autoscale_kubernetes_cluster
Failure
29.78
test_kubernetes_clusters.py

test_05_basic_lifecycle_kubernetes_cluster
Failure
26.75
test_kubernetes_clusters.py

test_06_delete_kubernetes_cluster
Failure
35.11
test_kubernetes_clusters.py

test_07_deploy_kubernetes_ha_cluster
Failure
35.15
test_kubernetes_clusters.py

test_08_upgrade_kubernetes_ha_cluster
Failure
27.86
test_kubernetes_clusters.py

test_09_delete_kubernetes_ha_cluster
Failure
35.01
test_kubernetes_clusters.py

ContextSuite context=TestKubernetesCluster>:teardown
Error
131.68
test_kubernetes_clusters.py

@blueorangutan package

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2666

@blueorangutan test

@davidjumani a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@davidjumani
code looks good to me. tested ok.
I have few questions or suggestions
(1) for existing vms which has SSH.PublicKey in user_vm_details before cloudstack upgrade, would be good to add a record SSH.KeyPairNames in the table ?
(2) the URL of ssh keypair page is http://localhost:5050/#/ssh/. What if there are multiple ssh keypairs with same name on the platform ? uuid looks better than ssh keypair name.
(3) on UI, can the existing ssh keypair be checked by default when open the dialog of reset ssh keypair ?

@nvazquez @davidjumani
we can merge this PR and address the comments (https://github.com/apache/cloudstack/pull/5965#issuecomment-1046626256) afterwards. it is fine with me.

@blueorangutan package

@weizhouapache a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2684

@blueorangutan test

@weizhouapache a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

I'll address the first point in this PR since we would like to maintain backward compatibility. I can raise another for the other ones

Trillian test result (tid-3410)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 30205 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3410-kvm-centos7.zip
Smoke tests completed. 91 look OK, 1 have errors
Only failed tests results shown below:

Test
Result
Time (s)
Test File

test_01_invalid_upgrade_kubernetes_cluster
Failure
27.11
test_kubernetes_clusters.py

test_02_upgrade_kubernetes_cluster
Failure
25.86
test_kubernetes_clusters.py

test_03_deploy_and_scale_kubernetes_cluster
Failure
26.79
test_kubernetes_clusters.py

test_04_autoscale_kubernetes_cluster
Failure
27.84
test_kubernetes_clusters.py

test_05_basic_lifecycle_kubernetes_cluster
Failure
38.98
test_kubernetes_clusters.py

test_06_delete_kubernetes_cluster
Failure
34.88
test_kubernetes_clusters.py

test_07_deploy_kubernetes_ha_cluster
Failure
27.77
test_kubernetes_clusters.py

test_08_upgrade_kubernetes_ha_cluster
Failure
28.84
test_kubernetes_clusters.py

test_09_delete_kubernetes_ha_cluster
Failure
28.90
test_kubernetes_clusters.py

ContextSuite context=TestKubernetesCluster>:teardown
Error
122.99
test_kubernetes_clusters.py

@davidjumani seems like the failures are consistent, can you check if it needs fixing?

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

<IP_ADDRESS>

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_multiplication_x: el7 :heavy_check_mark: el8 :heavy_multiplication_x: debian :heavy_multiplication_x: suse15. SL-JID 2697

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan ui

@davidjumani a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress.

UI build: :heavy_check_mark:
Live QA URL: http://qa.cloudstack.cloud:8080/client/pr/5965 (SL-JID-1181)

@davidjumani code looks good to me. tested ok.
I have few questions or suggestions
(1) for existing vms which has SSH.PublicKey in user_vm_details before cloudstack upgrade, would be good to add a record SSH.KeyPairNames in the table ?
(2) the URL of ssh keypair page is http://localhost:5050/#/ssh/. What if there are multiple ssh keypairs with same name on the platform ? uuid looks better than ssh keypair name.
(3) on UI, can the existing ssh keypair be checked by default when open the dialog of reset ssh keypair ?

I've addressed points 1 & 3 in this PR. Point 2 might require a larger change since the uuid field was recently added to ssh keyparis

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2698

5151

@blueorangutan test

@davidjumani a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

Trillian test result (tid-3420)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 36647 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3420-kvm-centos7.zip
Smoke tests completed. 92 look OK, 0 have errors
Only failed tests results shown below:

Test
Result
Time (s)
Test File

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2706

@blueorangutan test

@davidjumani a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

Trillian test result (tid-3428)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 45704 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3428-kvm-centos7.zip
Smoke tests completed. 91 look OK, 1 have errors
Only failed tests results shown below:

Test
Result
Time (s)
Test File

test_07_deploy_kubernetes_ha_cluster
Failure
3622.52
test_kubernetes_clusters.py

test_08_upgrade_kubernetes_ha_cluster
Failure
0.07
test_kubernetes_clusters.py

test_09_delete_kubernetes_ha_cluster
Failure
0.04
test_kubernetes_clusters.py

ContextSuite context=TestKubernetesCluster>:teardown
Error
69.29
test_kubernetes_clusters.py

Trillian test result (tid-3428) Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7 Total time taken: 45704 seconds Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3428-kvm-centos7.zip Smoke tests completed. 91 look OK, 1 have errors Only failed tests results shown below:
Test	Result	Time (s)	Test File
test_07_deploy_kubernetes_ha_cluster	Failure	3622.52	test_kubernetes_clusters.py
test_08_upgrade_kubernetes_ha_cluster	Failure	0.07	test_kubernetes_clusters.py
test_09_delete_kubernetes_ha_cluster	Failure	0.04	test_kubernetes_clusters.py
ContextSuite context=TestKubernetesCluster>:teardown	Error	69.29	test_kubernetes_clusters.py

@davidjumani
this needs more investigation.
might it be caused by systemvm template /cloud-init ?

LGTM, tested briefly and it looks good.

@weizhouapache Seems unrelated. I'll kick the tests again

@blueorangutan test

Trillian test result (tid-3444)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 35994 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3444-kvm-centos7.zip
Intermittent failure detected: /marvin/tests/smoke/test_vpc_redundant.py
Intermittent failure detected: /marvin/tests/smoke/test_kubernetes_clusters.py

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2727

@blueorangutan test

@davidjumani a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

Trillian test result (tid-3446)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 31716 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5965-t3446-kvm-centos7.zip
Smoke tests completed. 92 look OK, 0 have errors
Only failed tests results shown below:

Test
Result
Time (s)
Test File


FindConservedMarkers implementaion

Description of feature
Hi, thanks for your efforts for developing this wonderful framework! I was wondering if there could be an implementaion of Seurat FindConservedMarkers function, which can perform DGE analysis per group(e.g datasets) then combine them. It could be extremely useful especially when batch effects exist.
Thanks in advance!

Noted! Thanks for the feature request. It will take some time because of priorities.


Remote path doesn't exist

I have just started using drive and I am trying to push a directory but I see <nil> remote path doesn't exist for every file that it tries to push. Is there something I need to do before I push?
The full output is here https://gist.github.com/bausmeier/1178ab3d857d4f1e0920.

what version of drive?

drive version 0.0.5

Gotcha so the issue is that the file 2014 was never created on the remote but you are pushing 2014/2015...
That is a bug given that it should recognize that the root is not yet on. However if your root is created, then any amount of nesting ie 2014/January/Push/Journals/..... should work.
To solve this, make sure all root directories at least get created e.g
instead of
$ drive push 2014/2014-01-25\ New\ Camera/
do
$ drive push 2014
And from then on, you can then apply the original command.
Let me know if this helps.

Great, that worked. Thanks for the quick response!
Feel free to close the issue unless you want to track the bug here.

Glad to be of help. I'll work on it when am back home in a couple of hours then we can close it. I had actually started working on this over the weekend: https://github.com/odeke-em/drive/tree/mountpoint-nesting. Feel free to reach out in case of anything.


Error 500 When Creating Organization with LDAP or Microsoft Azure AD Authentication

Description:
I have deployed Terrakube with a self-signed certificate. After logging in, I am encountering an issue when trying to create an organization. The operation fails, and in the browser's inspect section, I can see that a 500 error is being returned.
I am facing this issue with both OpenLDAP and Azure AD authentication methods
Steps to Reproduce:
Deploy Terrakube with a self-signed certificate.
Configure LDAP or Microsoft Azure AD authentication.
Log in using LDAP or Azure AD credentials.
Attempt to create an organization.
Expected Behavior:
The organization should be created successfully without any errors.
Actual Behavior:
The operation fails, and a 500 error is returned in the browser.
Additional Information:
Browser Console Errors: 500 Internal Server Error
API Container Logs: (See attached log file for reference)
Environment:
Terrakube version: [3.17.6]
Deployment method: [e.g, Azure Kubernetes Service]
Authentication method: [OpenLDAP, Microsoft Azure AD]
Browser: [e.g., Chrome, Edge]
Please let me know if you need any additional information or if there are any steps I can take to help diagnose this issue further.
terrakube-api.log

You need to upgrade your ingress setup by default is using "https://terrakube-api.minikube.net" that is just for testing
java.lang.IllegalArgumentException: Unable to resolve the Configuration with the provided Issuer of "https://terrakube-api.minikube.net/dex"
	at org.springframework.security.oauth2.jwt.JwtDecoderProviderConfigurationUtils.getConfiguration(JwtDecoderProviderConfigurationUtils.java:168) ~[spring-security-oauth2-jose-6.1.9.jar:6.1.9]

You can check the following link.
https://docs.terrakube.io/getting-started/deployment/ingress-configuration

To use self signed certificats you will also need to read the following:
https://docs.terrakube.io/getting-started/deployment/custom-ca-certs

@alfespa17 , Thank you for the response.
I've referred to the following link for using Dex with Azure AD
https://docs.terrakube.io/getting-started/user-management/azure-active-directory
As per the documentation, the Dex DNS is derived from the API DNS, i.e., https:///dex. Could you please confirm if I need to create a separate DNS entry for the Dex DNS as well? and how to configure DEX issuer

@alfespa17 , Thank you for the response. I've referred to the following link for using Dex with Azure AD https://docs.terrakube.io/getting-started/user-management/azure-active-directory
As per the documentation, the Dex DNS is derived from the API DNS, i.e., https:///dex. Could you please confirm if I need to create a separate DNS entry for the Dex DNS as well? and how to configure DEX issuer

You don't need a different domain you can have DEX in the following URL for example https://terrakube-api.minikube.net/dex ant it should work correctly, so you can reuse the API domain to expose DEX too

Hi @alfespa17 , How can I ensure that Dex is working correctly?
Additionally, when I hit the following URL >> https://terrakube-api.minikube.net/dex/.well-known/openid-configuration), I get the response shown below. Is this expected?
{
"issuer": "https://terrakube-api.minikube.net/dex",
"authorization_endpoint": "https://terrakube-api.minikube.net/dex/auth",
"token_endpoint": "https://terrakube-api.minikube.net/dex/token",
"jwks_uri": "https://terrakube-api.minikube.net/dex/keys",
"userinfo_endpoint": "https://terrakube-api.minikube.net/dex/userinfo",
"device_authorization_endpoint": "https://terrakube-api.minikube.net/dex/device/code",
"grant_types_supported": [
"authorization_code",
"implicit",
"refresh_token",
"urn:ietf:params:oauth:grant-type:device_code",
"urn:ietf:params:oauth:grant-type:token-exchange"
],
"response_types_supported": [
"code",
"id_token",
"token"
],
"subject_types_supported": [
"public"
],
"id_token_signing_alg_values_supported": [
"RS256"
],
"code_challenge_methods_supported": [
"S256",
"plain"
],
"scopes_supported": [
"openid",
"email",
"groups",
"profile",
"offline_access"
],
"token_endpoint_auth_methods_supported": [
"client_secret_basic",
"client_secret_post"
],
"claims_supported": [
"iss",
"sub",
"aud",
"iat",
"exp",
"email",
"email_verified",
"locale",
"name",
"preferred_username",
"at_hash"
]
}

That is correct if you are using https://terrakube-api.minikube.net you can use that endpoint /dex/.well-known/openid-configuration just to check if dex is returning information correctly, now you only need to test from the UI if you are able to login.

@alfespa17 , thanks for the confirmation.
Endpoint [/dex/.well-known/openid-configuration] is responding but still faced the same issue and same error logs which I shared earlier

hello @Shubham-Jawkar1 can you share the example yaml file that you are using for the deployment (without any sensitive information)

Just to confirm you are using minikube to test right?


remove Drycell dependency (shade Drycell)

This PR removes the dependency on the DryCell plugin entirely, by shading it into TerraForm during build.
I've seen a couple people complain about the additional lib, and there's no real reason to have it as a separate plugin when it can just be shaded in like this.
This does NOT remove any DryCell code from the plugin. All this PR changes is the build process.

BTW, I highly recommend getting Drycell on a Maven repository, that way we dont need to use the local directory dependency thing. Check out CodeMC, I'm sure they'd let you put DryCell on their Nexus repo.

I also agree that having Drycell as a shaded in part is better.
And I also also agree that CodeMC would really be a good option here to use. I'm pretty sure your project would be accepted.

Should I continue to merge this even though we plan to phase out drycell? Is it easy to remove later on?

If you really want to implement it into tfg, then merging this seems pointless.

Also why's paperlib still being shaded in?
I was already being shaded in, so I just changed the existing location. IDK if you are using it, it was already there so I kept it.

No longer needed, drycell removed as a dependency


0.5.0

Added customization for package user
Added takeoff details
Added notes for all models (airport, aircraft, runway, intersection)

As above

As above


Allow const assertion to be use on enum types

Search Terms
A 'const' assertion can only be applied to a string, number, boolean, array, or object literal
Suggestion
Allow const assertion to be use on enum types. Currently the const assertion can be applied to string and number literals to get the compiler to keep literal types. But enums, which also can also produce literal types are not allowed in const assertions.
This seems inconsistent.
Use Cases
The use case I wanted to use it for is creating an object that could be assigned to a discriminated union (inspired by this SO question)
Examples
enum AorB { A = 'a', B = 'b' };
const arg = { type: 1 as const }; // { type: 1 }
const arg2 = { type: "1" as const }; // { type: "1" }
const arg3 = { type: AorB.A as const }; // Expected: { type: AorB.A; }, Actual: A 'const' assertion can only be applied to a string, number, boolean, array, or object literal.

Checklist
My suggestion meets these guidelines:

[X] This wouldn't be a breaking change in existing TypeScript/JavaScript code
[X] This wouldn't change the runtime behavior of existing JavaScript code
[X] This could be implemented without emitting different JS based on the types of the expressions
[X] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, etc.)
[X] This feature would agree with the rest of TypeScript's Design Goals.

This wouldn't be a breaking change in existing TypeScript/JavaScript code

Note that as const is recursive, so this would be a potential break

@RyanCavanaugh  I don't think it would be because literal types are already inferred for enums in objects. It's just that if the const assertion is directly on the enum we get an error.
const arg3 = { type: AorB.A  } as const // typed as  { readonly type: AorB.A; }
const arg3 = { type: AorB.A as const };  // but error here

Accepting PRs for this. It should be allowed only in the case E.P where E is a literal enum; PR should include negative tests for other cases which should be disallowed (e.g. O.P where O is not a literal enum).

I'm not sure current behavior is expected....


chore: threat modeling

This PR
WIP
Related Issues

Notes

Follow-up Tasks

How to test

Codecov Report

Merging #309 (2deb8a1) into main (75bdd8b) will not change coverage.
The diff coverage is n/a.

:exclamation: Current head 2deb8a1 differs from pull request most recent head d896ec9. Consider uploading reports for the commit d896ec9 to get more accurate results

@@           Coverage Diff           @@
##             main     #309   +/-   ##
=======================================
  Coverage   54.04%   54.04%
=======================================
  Files           4        4
  Lines         507      507
=======================================
  Hits          274      274
  Misses        212      212
  Partials       21       21

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

I think this is close to being able to merge.
I would recommend that you add a bit about the filepath sync, and also mention user PII used in evaluation as an asset. The diagram looks really good IMO. I'm not sure if it's worth adding the filesync there or not, it might make it too too busy; I'll leave that to you.

I think this is close to being able to merge.
I would recommend that you add a bit about the filepath sync, and also mention user PII used in evaluation as an asset. I have a question about how you've thought about controls here. The diagram looks really good IMO. I'm not sure if it's worth adding the filesync there or not, it might make it too too busy; I'll leave that to you.

I think including the other providers in the diagram will make it overwhelming. I've made a note that the diagram pertains to the kubernetes sync provider.


reenable loading unpacked mods outside the editor

removed since #416
ref this part only checking if in the editor:
https://github.com/GodotModding/godot-mod-loader/blob/766ee3e22ea39b30e1dd5d5d2c1aca0d97df0170/addons/mod_loader/mod_loader.gd#L72-L77

Do we want to introduce a third mod source or just always load mods from mods-unpacked?

third source could be nice in any case


ioc-scan: init at 1.5.0

Description of changes
Tool to search a filesystem for indicators of compromise (IoC)
https://github.com/cisagov/ioc-scanner
Related to https://github.com/NixOS/nixpkgs/issues/81418

Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
23.05 Release Notes (or backporting 22.11 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Result of nixpkgs-review pr 219221 run on x86_64-linux 1

1 package built:

ioc-scan


fix(route-recognizer): fix bug preventing uri generation from working

I'd like to do some more cleanup and add tests, but this is a quick fix for the problems with router.generate() discussed in aurelia/router#55.

Fixed with slightly more thorough refactor in #4, but that PR includes a lot of other changes as well. This PR can be closed if #4 is acceptable.

Closing with plans to accept the other PR after I review a bit more.


failed to install py-evm after running pip install -e . -r requirements-dev.txt

py-evm Version: 0.2.0-alpha.11
OS: osx
Python Version (python --version): 2.7
Environment (output of pip freeze):

What is wrong?
Collecting hypothesis==3.44.26 (from -r requirements-dev.txt (line 3))
Using cached hypothesis-3.44.26.tar.gz
Complete output from command python setup.py egg_info:
/private/var/folders/g7/hhzznhfx6rzczkdnnfrx90hw0000gn/T/pip-build-5XDM3o/hypothesis/setup.py:39: UserWarning: This version of setuptools is too old to correctly store conditional dependencies in binary wheels.  For more info, see:  https://hynek.me/articles/conditional-python-dependencies/
'This version of setuptools is too old to correctly store '
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'python_requires'
warnings.warn(msg)
error in hypothesis setup command: 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers; Expected version spec in enum34; python_version=="2.7" at ; python_version=="2.7"
How can it be fixed
Sounds like I have multiple python versions on my mac, and some of dependencies in requirement-dev.txt is only compatible with python3
Try: python3 -m pip install -e . -r requirements-dev.txt works for me

I'd highly suggest using a virtual environment rather than your global python.  Some quick googling should find you plenty of resources on how to set them up.