[Task]: Is there a plan to add the DDAD、DiffusionAD or  GLASS models?

What is the motivation for this task?
Is there a plan to add the DDAD、DiffusionAD or  GLASS models?
Describe the solution you'd like
Is there a plan to add the DDAD、DiffusionAD or  GLASS models?
Additional context
No response

GLASS is on our to-do list


Remove top-level error messages in bench_repo_specification.md

It appears that the backend doesn't interpret them.
Fixes #302.

It interprets them in the way I outlined in the linked issue iff the bench script exits with exit code 0. A more faithful version of the current behaviour would be:

If an expected error occurs that prevented the benchmark script from running successfully (e.g. there was no program to benchmark), the benchmark script can exit with a zero exit code and this output:
{
    "error": <error_string>
}

<error_string> is a string describing the error.

I am not sure that's worth it though and removing that feature is fine by me. I don't know of a run that uses this format currently.

Ah, now I understand. Makes sense and my change is bogus, then.

Adding the expected exit code to the spec would be a nice change though (evidently), I'll do that later :)

It would also help if the spec clearly differentiated between script errors ("panics", which the maintainer of the script has to fix) and errors while benchmarking the commit (fixing of which is the job of the one who wrote that commit).
The former are indicated through exit codes, the latter are indicated through "error" keys.
And then state that script errors "win" over run errors in terms of how the backend interprets the run output (+exit code).


track provenance and the operations recipe

At a workshop of IPCC TG-Data this week, @aspinuso presented on "Data-Intensive and Reproducible Science", using a pyam tutorial as an example for a workflow with detailed provenance tracking: https://github.com/aspinuso/pyam-binder/blob/master/pyam.ipynb
Looking at the more advanced workflows being discussed for AR6, it might be useful to include some basic support or integration for dispel4py or another package in pyam.

@gidden @znicholls @Rlamboll, what do you think?

Looks very cool. Looks way more complex than we can include and test in our first AR6 workflow draft though haha. If we just want it for reproducibility, I think I'd prefer to make the iiasa-climate-assessment public instead (with appropriate tags) as reproducing from the output of dispel4py looks non-trivial.

Dear all
Thanks for the interest.
Just as clarification, the most up-to-date repo of the dispel4py processing library, which includes support for provenance configuration and traceability, is currently developed in the context of the DARE platform and accesible at.
https://gitlab.com/project-dare/dispel4py
Sorry for the confusion. We are in the process of migrating versions and repositories.
I agree that adopting the whole library could be at the moment too complex to address basic traceability needs. Usually libraries are used through dispel4py rather than having it integrated within the library itself. However it could help the realisation of generic and more complex traceable workflows. Especially when these require different analysis libraries, custom metadata and larger computational resources. Let me mention in this thread @rosafilgueira, who is one of the main designer and developer of the tool.
Cheers
Alessandro
Op 9 nov. 2019 06:47 schreef Zeb Nicholls<EMAIL_ADDRESS>Looks very cool. Looks way more complex than we can include and test in our first AR6 workflow draft though haha. If we just want it for reproducibility, I think I'd prefer to make the iiasa-climate-assessment public instead (with appropriate tags) as reproducing from the output of dispel4py looks non-trivial.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/IAMconsortium/pyam/issues/287?email_source=notifications&email_token=AACNZDB6FUAH4445CKVAC3LQS2POVA5CNFSM4JLES6T2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDUEG7I#issuecomment-552092541, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AACNZDGLTMI7CUYOVBOPA33QS2POVANCNFSM4JLES6TQ.

HI all - is there a good example to look at of this tool being used in the wild?

I think it's important that you identify your use case and the extent of what you want to cover in terms of traceability of the results and the analysis processes involved. If the aim is reproducing and/or tracing (these are two different problems) exclusively what pyam produces, then you should be good enough with combining notebooks and binder repositories with pyam custom lineage.
Consider that if in my  binder example I would have used exclusively a pyam-lineage-aware implementation I would have lost the information about the storage part of the workflow, which includes the location and the ID assigned to the produced image within a repository.
If you want to scale to wider use cases which involves more tools and software libraries, workflow systems are usually a better way of discretising tasks, describe and trace methods. In that case lineage comes usually for free. Have a look also at CWL Tool (https://github.com/common-workflow-language/cwltool) and PROV-ONE (http://jenkins-1.dataone.org/jenkins/view/Documentation Projects/job/ProvONE-Documentation-trunk/ws/provenance/ProvONE/v1/provone.html) as generic tools and models for workflow and provenance description in that context.


Team Page for Documentation

Expected Contents:

[ ]  Illustration
[ ] A quote about teamwork
[ ] Project Maintainer's Section
[ ] Contributors Section

Common Instructions

Please push the changes only to the documentation branch
Do not push any build files
However, you are expected to share a link of the deploy of your changes. To do this, after doing the changes locally please do:
mkdocs gh-deploy.

can i work on this?

Can I work on this issue?

Should I share a screenshot before issuing a PR?

Should I share a screenshot before issuing a PR?

You can attach it in the PR description

Okay

I am a bit confused that where should I attach this?

Kindly guide me

I am a bit confused that where should I attach this like where this team page is there on the website?

OH! Simple. Just take a screenshot, save it on your desktop. Forget about it for a while. Go the directory for this project. Change to the mkdocs branch. Once the changes are staged and committed, push it your forked repo, raise a pr. Edit the PR description.  Drag and drop the screenshot

Hey is this issue is available?

Hey @smaranjitghose  can you explain the issue a bit,
what i understand is that "I need to design a template for a page which will be inlcuded as team page on the website right?"


[ragel] add write "entry" <machine_or_label>

This would be useful for setting the state outside of the machine. Still needed :)

Have entry points written for machine instantiations. Not sure anything more is needed at this time.


Extraction bug

Warning: your code's binary would actual extract to:
/,$`p-$$
instead of:
/,$? 1$$
Please report this as it is a bug (there is supposed to be a more clear accidental extension detection, this is just a fail safe)
size = 8 nibbles (4.0 bytes)
https://ato.pxeger.com/run?1=m708LzMpKSe1eMGCpaUlaboWy_V1VOwNVVQgPKjggg3GlgZGxgaWJkbGRsbGJqaGEHEA

Thank you for reporting this. This is overloaded as an extension because because ? 1 is true so it is the same as not having an if statement at all and just having the true clause. It should have given this warning instead of getting to this fail safe though. However, I may not get around to fixing this.


Add CCTransitionFade::initWithDuration for mac

I think this is a high quality commit from a high quality pull request and should be accepted as soon as possible so ninXout from Crystal Client can release Crystal Client 4.0.2. In fact I believe the review process should be sped up from its usual procedures, so we do not risk ninXout starting work on Crystal Client 5.0.0 before this pull request gets accepted.

this commit sucks, dislike,

I think this is a low quality commit from a low quality pull request and should not be accepted as soon as possible so ninXout from Crystal Client can not release Crystal Client 4.0.2. In fact I do not believe the review process should be sped up from its usual procedures, so we risk ninXout starting work on Crystal Client 5.0.0 before this pull request gets accepted.


Fix section 5.3.1 Java code example

Fix typos from Java code example in section 5.3.1
https://beam.apache.org/documentation/programming-guide/#file-based-data

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

[ ] Choose reviewer(s) and mention them in a comment (R: @username).
[ ] Format the pull request title like [BEAM-XXX] Fixes bug in ApproximateQuantiles, where you replace BEAM-XXX with the appropriate JIRA issue, if applicable. This will automatically link the pull request to the issue.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

R: @soyrice


adapt schema response according to column types

right now we are pretty much hardcoding all operations on all columns, we need to properly set them.

Fixed.
Now each column type has the query operators it supports.


Problem with DT State-Space Response

Hi all,
First, congratulations for the wonderful work you've done by maintaining and creating the library!
I have found some issues working with DTLTI systems. More specifically, I am trying to simulate the step response of a DT system directly from its state-space representation. This realization is computed directly in the DT domain, without a sampling process. As you can see in the image below, there is a problem since the step response is blowing up. My intuition is that there is a bug since the DT system is being treated as if it were CT, but it is DT.

Exactly the same happens when the dt parameter is set to None. When I try to evaluate whether the SS representation is DT or CT, I get that it's being taken as both.

I would appreciate any guidelines on how to fix this. I can do it myself and pull it :)
Kind regards,
Sergio Dorado-Rojas

The problem is that H_ss_direct is not actually a discrete time system, even though they way you created it makes it look like it should be.  The actually calling signature for control.StateSpace is
StateSpace(A, B, C, D[, dt])

The final dt argument is not a keyword argument but a positional argument.  Hence the say to create H_ss_direct is
H_ss_direct = ctrl.StateSpace(A, B, C, D, True)

In the call that you made, H_ss_direct has timebase None which means that it can represent either a continuous time system or a discrete time system.  The various time response functions all assume that if you don't specify a timebase then it is continuous.  (If you want this type of "strict" checking in isdtime, you can use strict=True when you call isdtime.)
At a minimum, there should be an error message printed with the call that you made, saying that dt was not recognized.  Better (I think) would be to recognize the dt keyword since it is a completely natural (and perhaps even better) way to create a discrete time system.
It would be great if you want to submit a PR to fix this (remember to include docstrings and some unit tests that both capture the only case and test all new code that you add).

Confirmed that this is fixed by #431.


move extensions in separate files.

Separate extensions from a single file to own related files
context_extensions.dart,
string_extensions.dart, and
number_extensions.dart
Basic Checklist

[ ] ✨ Ran dartdoc
[ ] 🛠 Added proper documentation
[ ] ❌ No warnings or errors in the code
[ ] ✅ If added a new extension, added in Readme and example too
[ ] 🧪 If added a new extension, written proper test cases for it

Type of Change

[ ] ✨ New feature (non-breaking change which adds functionality)
[ ] 🛠 Bug fix (non-breaking change which fixes an issue)
[ ] ❌ Breaking change (fix or feature that would cause existing functionality to change)
[ ] 🧹 Code refactor
[ ] ✅ Build configuration change
[ ] 📝 Documentation
[ ] 🗑 Chore

Thanks for the PR. This fixes #13 issue.


OAK-11165 - Cache the Path field in the NodeDocument class.

Creating a Path instance from a NodeDocument is an expensive operation, so it is worth to cache it. The performance improvements are noticeable in the indexing job, which calls #getPath twice in each NodeDocument that it processes.
Similar idea as what is done here:
https://github.com/apache/jackrabbit-oak/blob/35950bec988fffe34708f635f29f7d268d54cb85/oak-store-document/src/main/java/org/apache/jackrabbit/oak/plugins/document/Path.java#L297-L306

Are there any concerns about increased memory usage by caching the Path object in memory in every case?
I understand it can improve performance on indexing job, but it could increase memory consumption during normal operations of the repository. Have you evaluated this impact?
Maybe we could have a way to enable/disable the cache of this object depending on the needs. For example, enable it as part of indexing, but keep it disabled on other parts, at least until we assess any possible impact.

Are there any concerns about increased memory usage by caching the Path object in memory in every case?
I understand it can improve performance on indexing job, but it could increase memory consumption during normal operations of the repository. Have you evaluated this impact?
Maybe we could have a way to enable/disable the cache of this object depending on the needs. For example, enable it as part of indexing, but keep it disabled on other parts, at least until we assess any possible impact.

I have not evaluated the potential increase in memory in other situations, I was hoping someone more knowledgeable in this module would be able to comment. The main place where there could be a increased in memory usages that I can think of is the NodeDocument cache. If the getPath is called in the documents in the cache and these instances would not be held otherwise anywhere else, then the memory usage will increase. I don't know if this could be an issue.
I was hoping that in most cases the lifetime of the Path instance created by calling #getPAth will be similar to the one of the NodeDocument from where it was created, so there would be no increase in memory.
I'm ok with a way to enabled/disable this feature, could be a static flag set from an env variable with a default value of disabled. And we would enable it only for the indexing. But this optimization could benefit other uses of Oak, but I'm not sure how to evaluate it.

The reason why calling getPath is so expensive are the calls to StringCache for each path segment. I am assuming this is done to save memory, as two different paths often have many path segments in common. On the other hand, this requires computing the hash of every path segment, which might not be otherwise needed in many situations. And this cache might also be ineffective because it only has capacity for 1024 elements and when traversing an Oak tree we will come across a very large number of different names. We can assume that the leaves will all have different names, so traversing 1024 nodes will completely trash the cache, pushing out the common names that appear in the parent segments. I have not done a deep analysis, but I suspect this StringCache might not be reducing significantly the memory usage and is increasing CPU usage. On the indexing job, the calls to StringCache.get are responsible for more than 10% of the total CPU usage, which seems quite high.

I think there is a very high likelihood that getPath is executed by the time it gets put into the cache, as for example getNodeAtRevision already calls it, which is very likely to be called. Perhaps having an idea by how much the memory would increase in a realistic scenario would be useful.

Compared to the "data" map, memory usage of the path is small. To implement estimateMemoryUsage, the memory usage was estimated once, and the overheads (at that time, with an old JVM) are listed: 112 bytes overhead for just an entry, 64 bytes per map entry.


fcvt.s.d instruction not working with SSR

Conversion from double to single precision (fcvt.s.d) isn't working when used in combination with ssr. It hangs indefinitely on verilator but works on banshee.
This small test demonstrates the issue.
test_fcvt.zip

This seems to be more difficult to reproduce in the latest version (https://github.com/pulp-platform/snitch_cluster/commit/11d053489df24fd6057b5d985f6aa389cd507fed). Simulation is hanging only sometimes (may require multiple reruns) when built with multithreaded support
VLT_FLAGS='--threads 16' VLT_COBJ=work-vlt/vlt/verilated_threads.o VLT_CFLAGS=-DVL_THREADED \
    make -C target/snitch_cluster bin/snitch_cluster.vlt

This seems to be solved by https://github.com/pulp-platform/snitch_cluster/pull/158.


Relation models number limits

Ok, I know those limits were discussed in depth in #10305 and #10371, and I agree with comments that having too much of IDs inside IN() statement is a bad idea, however, I don't agree with the conclusion to not do anything.
The concern raised that building up lots of models takes lots of memory and there are risks of having memory overflow exceptions. But if we don't do that, Yii2 fails miserably when trying to pull models more than the underlying database allows being put inside IN() statement. So it either always fails because of the database limitation not accounted properly in Yii2, or sometimes fails if memory thresholds for PHP are reached. Why was it decided for the former instead of a later?
As of now I just don't see any legal workarounds against that issue. I have a huge relational hierarchy defined in my application. The logic pulls 1 root model (e.g. a blog post), and then it tries to pull lots of other related things, such as comments, authors, etc, via relations. On a very rare occasion, the number of comments goes beyond 1000 at which point the logic fails to pull models related to those comments and linked via a comment primary key, and in the end the blog post cannot be displayed. I cannot batch the comments, because those are being pulled indirectly (through relations), rather than directly, thus they are always resolved with all().
$post = BlogPost::find()->with('comments')->one();

I don't want to manage comments separately from the blog post, e.g. I don't want that:
$comments = $post->getComments()->all();

Because in the above cases comments are absent from the parent model $post, and have to be resolved again if they are accessed again.
I want to handle comments like that:
$comments = $post->comments;

And I want all comments on the same page, no pagination. This is a design decision, and we can discuss in length whether it is correct or not, but right now, I just don't see how to do that in Yii2 without hacks.
I personally believe it is better to hit potential memory thresholds when trying to construct thousands of models, rather than allow a database exception from unaccounted database limitations.
Oh, and speaking of hacks, I had to change ActiveRelationTrait class to break IN() statements in batches of  1000 items to workaround the issue (in case anyone still wants to have that functionality):
    private function filterByModels($models)
    {
        $attributes = array_keys($this->link);

        $attributes = $this->prefixKeyColumns($attributes);

        $values = [];
        if (count($attributes) === 1) {
            // single key
            $attribute = reset($this->link);
            foreach ($models as $model) {
                if (($value = $model[$attribute]) !== null) {
                    if (is_array($value)) {
                        $values = array_merge($values, $value);
                    } else {
                        $values[] = $value;
                    }
                }
            }
        } else {
            // composite keys

            // ensure keys of $this->link are prefixed the same way as $attributes
            $prefixedLink = array_combine(
                $attributes,
                array_values($this->link)
            );
            foreach ($models as $model) {
                $v = [];
                foreach ($prefixedLink as $attribute => $link) {
                    $v[$attribute] = $model[$link];
                }
                $values[] = $v;
            }
        }
        // MAX 1000 items fix -- dryu
	    if (!empty($values)) {
		    $values = array_unique($values, SORT_REGULAR);
		    $condition = ["or"];
		    for ($i=0, $n=1000, $c = count($values); $i<$c; $i+=$n) {
			    $condition[] = ['in', $attributes, array_slice($values, $i, $n)];
		    }
		    $this->andWhere($condition);
	    } else {
		    $this->andWhere(['in', $attributes, array_unique($values, SORT_REGULAR)]);
	    }
	    //$this->andWhere(['in', $attributes, array_unique($values, SORT_REGULAR)]);
    }

The above results relations models in a single query where model keys are split by 1000 items and glued together via OR.
I actually wouldn't mind supporting this change in a legal way (like extending some base class and they passing my custom class to a configuration array), but there are no hooks available.
What steps will reproduce the problem?
$post = BlogPost::find()->with('comments.time')->one();

What is the expected result?
All 1000+ comments to be pulled and available via $blog->comments.
What do you get instead?
2017-04-26 12:50:16 [<IP_ADDRESS>][xxxx][hgoh96v4ifqbpicsm5ejpa30d7][error][yii\db\Exception] PDOException: SQLSTATE[HY000]: General error: 1795 OCIStmtExecute: ORA-01795: maximum number of expressions in a list is 1000
(ext\pdo_oci\oci_statement.c:159) in D:\qtool\vendor\yiisoft\yii2\db\Command.php:900
Stack trace:
#0 D:\qtool\vendor\yiisoft\yii2\db\Command.php(900): PDOStatement->execute()
#1 D:\qtool\vendor\yiisoft\yii2\db\Command.php(362): yii\db\Command->queryInternal('fetchAll', NULL)
#2 D:\qtool\vendor\yiisoft\yii2\db\Query.php(210): yii\db\Command->queryAll()
#3 D:\qtool\vendor\yiisoft\yii2\db\ActiveQuery.php(133): yii\db\Query->all(NULL)
#4 D:\qtool\vendor\yiisoft\yii2\db\ActiveRelationTrait.php(239): yii\db\ActiveQuery->all()
#5 D:\qtool\vendor\yiisoft\yii2\db\ActiveQueryTrait.php(173): yii\db\ActiveQuery->populateRelation('time', Array)
#6 D:\qtool\vendor\yiisoft\yii2\db\ActiveQuery.php(215): yii\db\ActiveQuery->findWith(Array, Array)
#7 D:\qtool\vendor\yiisoft\yii2\db\Query.php(211): yii\db\ActiveQuery->populate(Array)
#8 D:\qtool\vendor\yiisoft\yii2\db\ActiveQuery.php(133): yii\db\Query->all(NULL)
#9 D:\qtool\vendor\yiisoft\yii2\db\ActiveRelationTrait.php(239): yii\db\ActiveQuery->all()
#10 D:\qtool\vendor\yiisoft\yii2\db\ActiveQueryTrait.php(173): yii\db\ActiveQuery->populateRelation('comments', Array)
#11 D:\qtool\vendor\yiisoft\yii2\db\ActiveQuery.php(215): yii\db\ActiveQuery->findWith(Array, Array)
#12 D:\qtool\vendor\yiisoft\yii2\db\ActiveQuery.php(297): yii\db\ActiveQuery->populate(Array)
#13 D:\qtool\controllers\ViewController.php(130): yii\db\ActiveQuery->one()

Additional info

Q
A

Yii version
2.0.10

PHP version
7.0

Operating system
Windows

@dryu thank you for the detailed description of your POV.

I personally believe it is better to hit potential memory thresholds when trying to construct thousands of models, rather than allow a database exception from unaccounted database limitations.

This sounds pretty reasonable, I agree with you.
I'll think what we can do to solve this problem

$post = BlogPost::find()->with('comments')->one();

How do you manage to run into IN limitation with this query?
I would expect the queries for that to be like:
SELECT * FROM blog_post LIMIT 1;
SELECT * FROM comment WHERE blog_post_id=42;

same for $post->comments; which should result in the latter one, there should not be any IN condition involved.

The problems start to appear when I reference a model relative to comments, e.g. in the example above it is comments.time. When Yii2 tries to retrieve that, it runs the query:
SELECT * FROM CommentsTime WHERE comment_id IN (...)

And there goes all ids of all comments retrieved prior to that.

See #14065

Fixed in f6a4f3c18f9f4b3f4e6af5bbad0e297f2aa55108


non-commuting operators

importing from docs/_work_in_progress/bugs.md
The Bug
All the tests are defective becuase they use commutative operators. If a non-commuting operator is used then the order of execution is shown to be arse-backwards:
Consider:
÷/ 1 2 3

This is:
1.5

and not as you might expect/as we currently return 0.166666667.
The evaluation order should be 1÷(2÷3) and not (1÷2)÷3).

in terminal:
      ÷/1 2 3
in interpret_TEST NormalRawExprs is {[],
                                     [{'$ast¯',
                                       {'$func¯',
                                        [{'$op¯',"/",["÷"],1,2}],
                                        monadic,operator,explicit,true,first,
                                        1,1},
                                       [{'$ast¯',
                                         {'$shape¯',false,
                                          [3],
                                          none,runtime,1,3},
                                         [1,2,3],
                                         1,3}],
                                       1,1}]}
in format (8)
0.16666666666666666

we want to apply ÷ dyadically, accumulating from the right.
In dyalog, if you apply a monadic function dyadically, I believe it defaults ⍺ ← ⊣ (identity function).
see http://help.dyalog.com/17.0/Content/Language/Defined Functions and Operators/DynamicFunctions/Default Left Argument.htm
This lets you do things like:
      {÷⍵}/1 2 3
3
      {⍺⊢÷⍵}/1 2 3
3


Firrtl fix invalid parameter check in paramod

Hi,
The current firrtl backend checks for the presence of the hdlname attribute in a Cell that represents a module instantiation. The backend uses this attribute to determine the name of the module that is to be instantiated.
if (cell->type.begins_with("$paramod"))
{
  log_assert(cell->has_attribute(ID::hdlname));
  instanceOf = cell->get_string_attribute(ID::hdlname);
}

However, Yosys does not store such an attribute in a Cell, but rather in a Module. The code has an invalid assertion that requires this property (which cannot exist where it is queried) and the backend therefore crashes if run on a parameterized module (not a parameterized blackbox module though as those are handled elsewhere).
For example, running the following verilog circuit with a parameterized input register chain connected to a simple passthrough module causes an assertion to fail.
module top
(
  input          clk,
  input  [63:0]  in_top,
  output [63:0]  out_top
);

  wire [63:0] pass_in_wire;

  parametric_regchain #(2, 64) input_regchain(clk, in_top, pass_in_wire);

  nonparametric_passthrough passthrough
  (
    .pass_in(pass_in_wire),
    .pass_out(out_top),
  );

endmodule

module nonparametric_passthrough
(
  input	 [63:0]	pass_in,
  output [63:0]	pass_out,
);

  assign pass_out = pass_in;

endmodule

module parametric_regchain
#(
  parameter NUM_STG = 8,
  parameter WIDTH = 32
)
(
  input              clk,
  input  [WIDTH-1:0] in,
  output [WIDTH-1:0] out
);

  reg     [WIDTH-1:0] tmp[0:NUM_STG];
  integer             i;

  always @(*)
    tmp[0] = in;

  always @(posedge clk)
    for (i = 0; i < NUM_STG; i = i + 1)
      tmp[i+1] <= tmp[i];

  assign out = tmp[NUM_STG];

endmodule

Input yosys script:
read_verilog example.v
hierarchy -check -top top
proc
opt_clean -purge
write_firrtl example.fir

Yosys output:
5.1. Executing PMUXTREE pass.
ERROR: Assert `cell->has_attribute(ID::hdlname)' failed in backends/firrtl/firrtl.cc:698.

This PR fixes the following issues:

Remove erroneous check for the hdlname attribute and fetch the instantiated Module's name from the Module's definition.

Remove some code duplication by regrouping handling of parametric and non-parametric modules in a single place.

Remove emission of an inline comment in a cell declaration. There is a branch in the code where instances can be declared as follows:
inst x /* some comment */ of module_x

However, firrtl does not support such /* ... */ comments and this looks like a previous verilog-like interpretation of what firrtl comments look like.

The generated output for the example above is a bit large due to the wiring generated by the backend, but I'll add it here to show that the pass produces valid firrtl:
circuit top:
  module _paramod_parametric_regchain_NUM_STG_2_WIDTH_64:
    input clk: UInt<1>
    input in: UInt<64>
    output out: UInt<64>

    wire _auto_firrtl_cc_99_rename_invalid_rhs_references_18: UInt<64>
    wire tmp_1_: UInt<64>
    reg _procdff_16: UInt<64>, asClock(clk)
    reg _procdff_17: UInt<64>, asClock(clk)
    wire _0: UInt<64>

    _procdff_16 <= in
    _procdff_17 <= tmp_1_
    _0 <= _auto_firrtl_cc_99_rename_invalid_rhs_references_18

    _auto_firrtl_cc_99_rename_invalid_rhs_references_18 <= bits(_procdff_17, 63, 0)
    out <= bits(_0, 63, 0)
    tmp_1_ <= bits(_procdff_16, 63, 0)

  module nonparametric_passthrough:
    input pass_in: UInt<64>
    output pass_out: UInt<64>

    wire _auto_firrtl_cc_99_rename_invalid_rhs_references_19: UInt<64>
    wire _1: UInt<64>
    wire _2: UInt<64>

    _1 <= pass_in
    _2 <= _auto_firrtl_cc_99_rename_invalid_rhs_references_19

    _auto_firrtl_cc_99_rename_invalid_rhs_references_19 <= bits(_1, 63, 0)
    pass_out <= bits(_2, 63, 0)

  module top:
    input clk: UInt<1>
    input in_top: UInt<64>
    output out_top: UInt<64>

    wire _auto_firrtl_cc_99_rename_invalid_rhs_references_20: UInt<64>
    wire pass_in_wire: UInt<64>
    wire _3: UInt<64>

    _3 <= _auto_firrtl_cc_99_rename_invalid_rhs_references_20

    inst input_regchain of _paramod_parametric_regchain_NUM_STG_2_WIDTH_64
    input_regchain.clk <= clk
    input_regchain.in <= in_top
    inst passthrough of nonparametric_passthrough
    passthrough.pass_in <= pass_in_wire
    _auto_firrtl_cc_99_rename_invalid_rhs_references_20 <= bits(passthrough.pass_out, 63, 0)
    out_top <= bits(_3, 63, 0)
    pass_in_wire <= bits(input_regchain.out, 63, 0)

I realized this PR contains more commits than the single commit needed to fix the hdlname attribute issue. This is because I derived this branch from my previous PR (#2457) that solved different types of issues.
Would you prefer if I merge both PRs in a single larger one?

Just an update to say I have not forgotten about this. Just very busy at the moment. I'll try to get to this soon.

Hi,
Sorry, but this PR has stayed in my inbox for far too long. I thought I could come back to it, but I have since moved to another project and realistically won't have time to edit this, so I'm going to close the PR for now.


[Feature Request] Respect XDG Spec

Is your feature request related to a problem? Please describe.
Currently the promptflow tool / framework does not respect XDG directory structure (https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html)
Describe the solution you'd like
If $XDG_DATA_HOME is set, put .promptflow work directory there instead of $HOME

Please try set this env variable  PF_HOME_DIRECTORY.

hi @sashokbg , thanks for the feedback; we will follow this spec and support this.

ping to remove the stale label, will work on this recently


Problem in loading json file

`dataset_train = CocoLikeDataset()
dataset_train.load_data('dataset2/train/via_region_data.json', 'dataset2/train')
dataset_train.prepare()
dataset_val = CocoLikeDataset()
dataset_val.load_data('dataset2/val/via_region_data.json', 'dataset2/val')
dataset_val.prepare()`
I am trying to train a model using the json file which is developed based on your tutorial (book, homeplant, bottle). But when I load the training images and annotation json file, I am getting below error.

KeyError                                  Traceback (most recent call last)
 in
1 dataset_train = CocoLikeDataset()
----> 2 dataset_train.load_data('dataset2/train/via_region_data.json', 'dataset2/train')
3 dataset_train.prepare()
4
5 dataset_val = CocoLikeDataset()
 in load_data(self, annotation_json, images_dir)
16         # Add the class names using the base method from utils.Dataset
17         source_name = "coco_like"
---> 18         for category in coco_json['categories']:
19             class_id = category['id']
20             class_name = category['name']
KeyError: 'categories'

Hey @AhmadShaik, I'm really sorry I didn't see this until now. My github emails were being sent to my spam folder. Hopefully you've already solved your problem by now, but if not, it looks like a pretty straightforward error. Your JSON file needs a 'categories' section. You may find this video helpful: https://youtu.be/h6s61a_pqfM


Update podspec source_files to only include .h and .swift files (fixes error in the new build system)

The new build system throws an error if there are plist files in the target's sources. By changing the source_files regex we ensure the Info.plist is not added when we pod install.

This is also fixed in #41.

Indeed https://github.com/ink-spot/UPCarouselFlowLayout/pull/41 fixes that as well and has just been merged.
Thanks anyway @tiagomnh 👍


Crash on Android 10

Please help me to resolve this problem, I cannot run this source on Android 10

Please help me to resolve this problem, I cannot run this source on Android 10

@tranvanphay This project is not maintained anymore.


Error Reporting on add_cti_file

Describe the bug
Harvesters will not throw an exception in add_cti_file even when you pass it a path to a file that does not exist.
To Reproduce
Steps to reproduce the behavior:

Create a new harvesters instance h = Harvester()
Add a path that does not exist h.add_cti_file("I don't exist")

Expected behavior
Function should throw an exception indicating that it failed and the file does not exist or is not a CTI file.
Desktop (please complete the following information):

OS: Windows 10
Python: 3.8
Harvester: 1.0.4
GenTL Producer: Matrix Vision
Camera: Prosilica GC650

Update: I have also tested on the most recent release of Harvesters available on pypi for Windows (1.2.6).  Same issue appears here, but replace with the newer interface (add_file instead of add_cti_file).
The reason I ran into this problem was that I was debugging an issue where I was unable to see gige cameras attached to my device while using the Matrix Vision producer.  It ended up being the same problem as in issue #132 where the path to my CTI file had control characters in it.  Python's string handling would convert them and the path passed to harvesters no longer pointed to a real file.
What is your policy on contribution, by the way?  I like this project and this seems like a simple code change.  If you're OK with it and I have the time, I could look into making a pull request.

@electronsandstuff Hi, thank you for your comment. I would like to tell you that my intention is different from the one you have. It is totally okay to add anything through the add_file method and I want users to recognize if they have available devices after calling the update method. If there's no available device then you will notice len(h.device_info_list) returns 0. In short, I do not want to block users just because they set invalid files. Of course, I understand your demand to have an exception thrown but for now, I do not see it's necessary to be honest. Could you tell me if you still have a demand on your usage? /Kazunari

I did not realize that this was the intended function.  Thank you for clarifying.
I was expecting to see a warning or error message from the library when I gave it an invalid parameter.  I saw that Harvesters will check if the CTI file exists and log a warning if it does not.  However, when I followed the example code in the README file, it never gets displayed.  That is what tripped me up.  The string I was entering was visually correct and the library silently failed to open it after conversion by python.  I thought that there was no way that the path I was entering could be the issue.
If the library uses a custom error handling solution, then maybe it would be a good idea to display warning messages by default and then ask more advanced users to manually disable them.  I will understand if you do not want to change this since I am, at this point, making a feature request.  However, not seeing any feedback from the library is what cost me a couple of days worth of debugging and caused a lot of frustration.  If I was not already familiar with Harvesters and just porting code to a different OS, then I am not sure I would have resolved it without a lot of help.

@electronsandstuff Hi. Thank you for your comment. I see your point so let me have time to find a better solution that fits Harvester.

caused a lot of frustration

Please do not drop such words on me. Does it always enforce such a terrible situation while you are working with it? Is Harvester really always annoying for you?
I've dedicated my spare time to Harvester since 2018 to create something valuable to people all over the world. So far, so many people gave me their kind words for Harvester even if it was a feature request or a bug report. However, now I am very sad about having such uncooperative feedback.
/Kazunari

@electronsandstuff Hi. I have just improved Harvester so that it can cover your use case introducing two parameters, check_existence=False and check_valididty=False to the add_cti_file/add_file method. Note that I set False as their default value because I need to take care of backward compatibility. I hope it works for you. Thank you again for your feature request. /Kazunari


Improved navbar and fixed it at top

Related Issue

Improve the navbar and make it a fixed navbar at the top.

Describe the changes you've made
I have used bootstrap to make the changes, improved the navbar by adding an icon from flaticon.com, and also fixed it at the top.
Describe if there is any unusual behavior of your code(Write NA if there isn't)
'NA'
Checklist:

[✓] My code follows the style guidelines of this project.
[✓] I have performed a self-review of my own code.
[✓ ] I have commented on my code, particularly in hard-to-understand areas.
[ ✓] I have made corresponding changes to the documentation.
[ ✓] New and existing unit tests pass locally with my changes.

Screenshots
Put any screenshot(s) of the project here.
About Section (before)

About Section (after)

@signifershrey the website has been updated recently and you made changes to older version so merging your PR will break the existing code.so kindly look for improvements in the latest version or any existing project :)


View rendering and Passport challenges in Advanced Node/Express created

Batch 1 of the Advanced Node/Express challenges

[x] View Engines & Modules (batch 1)
[x] Passport with local strategy (batch 1)
[ ] OAuth strategies impl (batch 2)
[ ] Web Sockets (batch 2)
[ ] Bcrypt impl for local (batch 3 after adding Bcrypt challenges in info sec section)

Pre-Submission Checklist

[x] Your pull request targets the staging branch of freeCodeCamp.
[x] Branch starts with either fix/, feature/, or translate/ (e.g. fix/signin-issue)
[x] You have only one commit.
[x] All new and existing tests pass the command npm test. Use git commit --amend to amend any fixes.

Checklist:

[x] Tested changes locally.

Notes

This is a complete rewrite of the file- deletions can basically be ignored, it was all deleted and rewritten
Checkpoint Gists and Boilerplate will be moved to camperbot when beta becomes production ready

This looks great! I loaded it up and checked out the challenges and everything seems to run well. I'm merging so this can be deployed and campers can start working through these challenges.
Thank you again for designing all of these challenges. I'm looking forward to seeing what you come up with for Oauth, Websockets and Bcrypt!


[Feature Request]: Active current page NavItem button of Navbar

Is there an existing issue for this?

[X] I have searched the existing issues

Feature Description
when the user clicks the current page then nav item should be show active on this current pagethe
Use Case
User better understanding which navItem clicked.understandunderstand
Benefits
it is a friendly experience and understanding
Add ScreenShots
https://github.com/MAVRICK-1/e-commerce_website/assets/121508628/c30dd4be-ee95-4c1d-9d12-dfed5093468a
I am GSSOC24 Contributor
please assign me, I would like to work on it
Priority
High
Record

[X] I have read the Contributing Guidelines
[X] I'm a GSSOC'24 contributor
[X] I have starred the repository

@SrinivasDevolper okay go Ahead


models: fix search aliases

Coverage remained the same at 79.82% when pulling 73fdc4e036a3d8a2b1cec2720d41921dcbfb78b6 on ppanero:search into 40f4e447d82f971e6cc32892519af64199a484ad on inveniosoftware:master.

Coverage remained the same at 79.82% when pulling 73fdc4e036a3d8a2b1cec2720d41921dcbfb78b6 on ppanero:search into 40f4e447d82f971e6cc32892519af64199a484ad on inveniosoftware:master.


Only build subset of archs

Would be great if a flag could be passed to build-libssl.sh to only build certain archs – my project for example does not need armv7s / tvOS.
Right now I use a fork but would ideally not have the maintenance overhead.

I have created a version of the script for use with OpenSSL 1.1.0 (see my fork). I still intend to create a couple of pull requests for my changes (which are both related to the script process itself as well as the specifics for OpenSSL 1.1.0). One of those changes includes selectable targets (although it'll probably be a variable in the script file).
I cannot promise any timeframe though, my schedule is packed at the moment.

yes, it would just need a way to pass in variables to the script, that's quite easy with conditional assignments, along the lines of
: ${archs:="i386 arm64"}
Then some logic to conditionally include the lips in the lipo step. There isn't really much more to it.

Fixed by #111


Allow locking assets/drawings to prevent erasing.

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
My players and I like to have an image that we draw on every time we roll a natural 20.
When adding an image, if they want to erase a mark they've made, they almost always erase the underlying image as well.
Describe the solution you'd like
A clear and concise description of what you want to happen.
Allow selection and locking of certain assets/brush strokes, preventing eraser tool from removing them.

That's a feature on the latest Tldraw version which I guess is more unstable. I have considered backporting which I believe takes a lot of effort.


First documentation draft

This PR adds some information in the README file to indicate how to use this library.
@XdoctorwhoZ does it seems sufficiently explanatory?

It's much better 😄  but only time will answer your question 🚶♂


can't import hsl colors properly

because it contains , it is wrapped in  quotes and then if you use it with fade-out for example would get error:
argument `$color` of `fade-out($color, $amount)` must be a color

https://github.com/Updater/node-sass-json-importer/blob/v1.0.3/src/index.js#L41

i think we should first match if contains parentheses .match(/[()]/) and then for comma and whitespace

or update the line to this
} else if (_lodash2['default'].isString(value) && value.match(/[\s,]/) && !value.match(/[()]/)) {

@safareli What does the JSON look like?

{
white: "hsl(0,0%,100%)"
}

If solution is ok I can create PR

some edge cases:
in: { "namedColor" : "gold" }
out: $namedColor: "gold";
User of this library may thought to use it as color but it is compiled to string so she can't.

in:  { "containingQuotes" : "\"qu'ote"}
out: $containingQuotes: "qu'ote;
Desired output will be to wrap in quotes.

in: { "escapedChar" : "\\26"}
out: $escapedChar: \26;
It's desired behaviour

in: { "escapedCharWithSpace" : "bar \\26 foo"}
out: $escapedCharWithSpace: "bar \26 foo";
if it's quoted and $escapedChar not it's confusing

I think simplest and most consistent way will be to not wrap any value in quotes and if user wants it to be wrapped will put it in quotes like this.
in: { "foo": "'some , text \\26 foo'" }
out: $foo: 'some , text \26 foo'
or
in: { "foo": "\"some , text \\26 foo\"" }
out: $foo: "some , text \26 foo"
so user can control output himself if he wants to use rgb(0,0,0) as string will wrap it in quotes
in: { "foo": "\"rgb(0,0,0)\"" }
out: $foo: "rgb(0,0,0)"
or if he wants could embed sass map in it too or function call or whatever
i'll close this issue and PR of this and create another one for this solution

I think we should just apply  PR #5 and it will solve this issue. also I have commented solution that issue


refactor(button): move styling from themes package to component

Describe pull-request

moved styling from themes package to component package
replaced $prefix to --sdds

Solving issue
Fixes: AB#1681
How to test

Go to storybook button story
Check buttons if it looks same as current ones

why remove this file from the repo? (package-lock.json)

it was an accident, meant to not add the file :P  fixed now


CI isn't running on merge to main

We just merged https://github.com/neurobagel/query-tool/pull/199 with a failed linter check (not sure how tbh, we have branch protection on). Obviously linter check isn't breaking things - so no major harm done. But the main branch remained green after this. This made me realize that we aren't running any checks on push/merge to the main branch here - we only run the deployment.
That's no good. If instead of a linter we had ignored a failed test then main should not be looking green anymore (and we also shouldn't deploy). If you break main, you need to know this (and then fix it right away).
I think all tests have to run on main, but the linter should run because why not.
We should then also confirm that if for some reason we push broken stuff to main and the tests fail, that we don't deploy!

To resolve this we'll update the workflows to also trigger on push to main branch.


feat: add opentelemetry 1.0.2beta2, couchbase 4.2.0 releases

update opentelemetry with release 1.0.2beta2
update couchbase with release 4.2.0

:tada: This PR is included in version 1.306.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Optimize empty IN subquery and empty INNER/RIGHT JOIN.

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en
Category (leave one):

Performance Improvement

Short description (up to few sentences):
If the subquery is empty can quickly return.
https://github.com/yandex/ClickHouse/issues/6615

Some tests have failed.

This is the normal result:
SELECT count()
FROM
(
    SELECT *
    FROM system.numbers
    LIMIT 1000
)
WHERE 1 IN
(
    SELECT 0
    WHERE 0
)

┌─count()─┐
│       0 │
└─────────┘

1 rows in set. Elapsed: 0.008 sec. Processed 1.00 thousand rows, 8.00 KB (117.63 thousand rows/s., 941.06 KB/s.)

This is the result of this pr:
SELECT count()
FROM
(
    SELECT *
    FROM system.numbers
    LIMIT 1000
)
WHERE 1 IN
(
    SELECT 0
    WHERE 0
)

Ok.

0 rows in set. Elapsed: 0.014 sec.

Expression
 Expression
  CreatingSets
   Lazy
   Aggregating
    Concat
     Expression
      Filter
       Limit
        Expression
         Expression
          Numbers

Maybe should not be doing CreatingSetsBlockInputStream return quickly? Because "conut 0" is Aggregating the return, should we do something  during IN or JOIN Expression?

This is the normal result:
SELECT count()
FROM
(
    SELECT *
    FROM system.numbers
    LIMIT 1000
)
WHERE 1 IN
(
    SELECT 0
    WHERE 0
)

┌─count()─┐
│       0 │
└─────────┘

1 rows in set. Elapsed: 0.008 sec. Processed 1.00 thousand rows, 8.00 KB (117.63 thousand rows/s., 941.06 KB/s.)

This is the result of this pr:
SELECT count()
FROM
(
    SELECT *
    FROM system.numbers
    LIMIT 1000
)
WHERE 1 IN
(
    SELECT 0
    WHERE 0
)

Ok.

0 rows in set. Elapsed: 0.014 sec.

Expression
 Expression
  CreatingSets
   Lazy
   Aggregating
    Concat
     Expression
      Filter
       Limit
        Expression
         Expression
          Numbers

Maybe should not be doing CreatingSetsBlockInputStream return quickly? Because "conut 0" is Aggregating the return, should we do something before the IN or JOIN Expression?

@nicelulu That becomes more interesting.
To get proper result for aggregation query, you have to provide empty data stream before Aggregating and not after CreatingSets. Let's think how to do it...

Maybe should not be doing CreatingSetsBlockInputStream return quickly?

Yes, this is not the correct way of implementation.
We need to check if the set is empty deeper in query execution pipeline.

@alexey-milovidov Maybe I can use the action sequence in ExpressionActions to determine an IN or JOIN?

SELECT count()
FROM system.numbers
WHERE (number IN
(
    SELECT toUInt64(1)
    WHERE 0
)) AND (number != 1)

In fact, for IN, I need to consider short-circuit AND operation. If it is OR, I can't use this optimization.

For Functional stateless tests "00017_in_subquery_with_empty_result"
This PR result :
SET output_format_write_statistics = 0

Ok.

0 rows in set. Elapsed: 0.004 sec.

SELECT count()
FROM
(
    SELECT *
    FROM system.numbers
    LIMIT 1000
)
WHERE 1 IN
(
    SELECT 0
    WHERE 0
)
FORMAT JSON

{
	"meta":
	[
		{
			"name": "count()",
			"type": "UInt64"
		}
	],

	"data":
	[
		{
			"count()": "0"
		}
	],

	"rows": 1,

	"rows_before_limit_at_least": 0
}

1 rows in set. Elapsed: 0.015 sec.

00017_in_subquery_with_empty_result.reference result:
{
	"meta":
	[
		{
			"name": "count()",
			"type": "UInt64"
		}
	],

	"data":
	[
		{
			"count()": "0"
		}
	],

	"rows": 1,

	"rows_before_limit_at_least": 1000
}

Maybe it's normal?

Maybe it's normal?

Yes, it's perfect.


testdata: Fix the HTTPTestServer handling of ZSTD

Fix the ZSTD feature included in the HTTPTestServer.
Adds proper ZSTD compression handling for NAR files by:

Adding WriteHeader method to zstdResponseWriter to set compression headers
Adding support for uncompressed NAR file endpoints
Fixing header writing logic to prevent duplicate headers
Adding tests to verify both compressed and uncompressed NAR file serving

#108
#114
#113  👈 (View in Graphite)
main

This stack of pull requests is managed by Graphite. Learn more about stacking.

Merge activity

Dec 14, 3:10 AM EST: A user started a stack merge that includes this pull request via Graphite.


Log directly to Console

Bypass the logging framework and log directly to Console

Bloked, waiting #61 to be completed.


eta repeatedly prints on newline above progressbar

Description
The eta is repeatedly printed above the progress bar.

Code
import progressbar
from time import sleep

widgets = [
          'Test: ', progressbar.Percentage(),
          ' ', progressbar.Bar(),
          ' ', progressbar.ETA(),
          ' ', progressbar.FileTransferSpeed(),
      ]
bar = progressbar.ProgressBar(widgets=widgets, max_value=1000).start()
for i in range(100):
    # do something
    bar.update(10 * i + 1)
    sleep(1)
bar.finish()

Versions

Python version: 2.7.13
Python distribution/environment: Anaconda
Operating System: El Capitan
Package version: 3.20.1

Oops.. It seems the release today accidently kept a print statement inside

The new release is now on pypi. Thanks for letting me know!


Add new fields to Application

Codecov Report

Merging #180 (9bdf4f3) into develop (be82372) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff            @@
##           develop     #180   +/-   ##
========================================
  Coverage    94.70%   94.71%
========================================
  Files          100      100
  Lines         3099     3101    +2
  Branches       252      252
========================================
+ Hits          2935     2937    +2
  Misses         117      117
  Partials        47       47

Impacted Files
Coverage Δ

application_form/api/serializers.py
100.00% <ø> (ø)

application_form/services/application.py
94.11% <ø> (ø)

application_form/models/application.py
100.00% <100.00%> (ø)

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 be82372...9bdf4f3. Read the comment docs.


Implemented #4215: New-TemporaryFile to have -Extension parameter

#4215: Add ability to create a temporary file with a specific extension to New-TemporaryFile
Implemented exactly as described by adding an optional -Extension parameter to specify the extension e.g. as .csv or just csv.
Because of the required change to call different .NET APIs, the cmdlet had to be slightly rewritten to cater for the special case that the file to be created already exists in the temp folder.

@bergmeister,
Thanks for having already signed the Contribution License Agreement. Your agreement was validated by Microsoft. We will now review your pull request.
Thanks,
Microsoft Pull Request Bot

I have addressed the main suggestions but would like to wait until we have reached a consensus on the preferred approaches with the issues of the possibility of not being able to create a temp file and how to deal with it

We could use a Guid for the filename to minimise the probability of a file name clash instead of Path.GetRandomFileName(). @iSazonov has suggested to use this existing pattern as an alternative but I struggle to see why as it suffers from the same problem and also does not deal with other exceptions due to e.g. insufficient permissions, disk space. Maybe you can elaborate more on it?
We could simply let it fail and not have a retry mechanism

I think in general it is good that we move away from Get-TempFileName due to it's limitations (see e.g.
here) but I am wondering if this is not a also a case for the coreclr to improve the current implementation and possible offer an extension overload...

A GUID based filename would certainly solve the problem but after thinking about it some more I am Ok with the retry loop.  It feels like a reasonable compromise to write an error and fail after 10 tries.  Also I am fine with initializing the new property with ".tmp".  Using GUIDs feels like overkill.  But maybe we could add a switch to allow it as an option.  Something like:
New-TemporaryFile -GuidBasedName

Yes, we could easily add a GuidBasedName without making the code complicated. But I am wondering if we are not over-engineering this cmdlet and trying to solve problems that have not been reported yet? One should also keep in mind that users still have the full set of .Net methods available to handcraft something that meets their special needs in a few lines of code. I was also thinking about the problem on a higher level. Should someone not be able to create a temporary file and would need a Guid based approach, then to me this is either:

Bad luck -> We have the retry logic for that
Their temp folder is so full of temp files that there aren't many possible file names left -> There seems to be a more serious problem that needs to be addressed and therefore it might be good to see an error before files worth of TB are written.
Just let me know what you want me to do at the end.

@PaulHigin

A GUID based filename would certainly solve the problem but after thinking about it some more I am Ok with the retry loop.

Why do you think this problem exists?
Why hasn't this been corrected in .Net Framework in the last 15 years and has not been corrected in CoreFX now?
Do we actually have scripts that create more than 50000 temporary files without removing them?
Are there real support cases on this problem?
Does anyone really need temporary file names based on GUIDs?
If so, right way is - we have to open Issue in CoreFX and fix the problem there without complicating PowerShell Core code.

After further thinking, I believe that if the CoreFX algorithm is bad, it must be corrected in CoreFX, not here.
So our code should be simple:
try
{
    var tempFile = GetTempFileName();
    if (parameter Extension present)
    {
         replace extension in tempFile
    }

    WriteObject(tempFile);
}
catch
{
    WriteError(...) or write terminating error;
}

@iSazonov In the beginning I was thinking that a fix in corefx would be nicer as well since this is a common problem that also others have (see e.g. here).
If you look at my links above to the actual implementations, then you can see that it would be trivial to improve the corefx algorithms (Windows & Unix) to have an overload with a non-default extension but it would require more work to improve the file name uniqueness limitation to 65,535 files due to the Windows API that it calls at the end, etc.
The reason why I was hesitating to ask for a change in corefx is because corefx is probably not very happy with adding an overload that is not part of .net standard (which would then also require an implementation of the new overload in Xamarin and full .Net). What do others think?

Sorry for being unclear - I meant that it is better to fix "the file name uniqueness limitation to 65,535 files" algorithm in CoreFX not extension - adding new overload for extension require .Net Standard change - it is very long process. Also it will be not approved without real business case - mentioned issue is unuseful because don't contains any arguments.

@lzybkr Could you please clarify about used algorithm (my comments here and here)? I still think we're making an unreasonable complication trying to "fix" CoreFX without justifying and business case and adding  -UseGuid.

Oh, I think -UseGuid is overkill, but the retry logic is necessary at some layer, and in the case of wanting an extension that differs from what .Net uses, we can't simply replace the extension, .Net guarantees the original filename is safe, but not the basename + any other extension.

@PaulHigin @lzybkr I have made all the requested changes for the test syntax, error message and removed the switch parameter for the Guid file name. The only thing that I noticed at the end was the fact that the cmdlet has always always (before this PR) overridden the EndProcessing() method and I was wondering if it should not rather be ProcessRecord()?

For cmdlets that do not accept any pipeline input, EndProcessing is the correct place for the core logic.

Ok. Thanks for explaining it.

Current algorithm is bad and have security hole on Unix.

@iSazonov
Please explain the security hole.

@PaulHigin Sorry for being short - I was busy.
Disposition. We use CoreFX method to get a temp file. CoreFX uses system calls to get one (links above) - both Windows and Unix have the functions implemented many years ago and they is well-tested and used everyone without claims. Now we want make the thing better than Windows kernel team and glibc team. We haven't Windows sources (we have a comment from MSDN, see above) but we can review glibc implementation and read mkstemps docs.
With the PR's algorithm we get two classic problem for both platforms - for Unix they is critical.

Race condition. We create a file name then create a file with ten attempts - glibc do >16000 attempts. It is critical for Unix because all processes creates temp files in shared folder /temp.
Security. We create file with [0666 permissions](https://github.com/dotnet/coreclr/blob/ /src/mscorlib/shared/System/IO/FileStream.Unix.cs#L50) by default. On Unix all temp files is created in shared folder /temp and security is critical.  In glibc implementation on Unix all temp files is created in shared folder /temp with 0600 permissions to block access to the file from other accounts.
It also explains why our attempt to use Guids is bad too.

So my conclusion - we can not get better solution than CoreFX. We only can reimplement glibc mstemps() and customize it to support any suffix. I believe that our efforts are not worth the result - I don't see the urgent need to create temp files with a different extension (business case?). We should close the PR and Issue with Won't fix.

Thanks @iSazonov for the analysis - I had your intuition in the back of my mind, but no specifics.
I do believe there is a real customer need and that the workarounds are probably worse than what is currently implemented in this PR.
If we addressed the permissions and the race condition, then I think it's an improvement over the status quo even if it isn't perfect.

@iSazonov:

As for the business case: Remember that GNU mktemp already allows you to specify a custom extension (suffix), via its far more flexible XXX... templating feature;  e.g, something like
mktemp -t XXX.csv yields something like /tmp/kLJ.csv. (BSD mktemp works differently and is less flexible - it only allows you to specify a custom prefix.)

All great technical points.

A simple way of rewriting this PR in order to keep Path.GetTempFileName() in charge is to:

Always start out with filePath = Path.GetTempFileName()  - this will ensure the proper permissions.

Only if -Extension was specified:

Use filePathWithCustomExt = Path.ChangeExtension(filePath, Extension) and then  rename that file (File.Move(filePath, filePathWithCustomExt)) in a retry loop.

A retry loop is then only necessary in the -Extension case, which means we have to pick a retry count; picking a high count should be fine, as collisions are unlikely.

@lzybkr @mklement0 Thanks for the discussion!
Without MSFT CRM 😄  I can not disprove "I do believe there is a real customer need" - so we want -Extention.
About implementation. We could implement simple workaround as @mklement0 suggested to only "close the hole". I prefer "perfect" solution 😄
I have no doubt that the right place is CoreFX. This requires an exhancement of the .Net Standard and subsequent implementation - it is a long process - we should open a Issue in CoreFX.
Today we could implement this in PowerShell Core but we have an Issue to create temp directories either in the cmdlet or in new one. And we see a symmetrical situation - Unix has a richer API than Windows. We again should ask CoreFX to enhance API to create temp directories.
Hence we should create the proposed API and implement it in our Core Facade block to easily migrate to CoreFX implementations later - nothing new - we used such approach in .Net Core 1.0 time and continue currently with 2.0.
Thus we suggest to get Unix mktemp-like functions and re-implement them for both platforms.

@iSazonov: 👍

I cannot disprove "I do believe there is a real customer need"

Well, I'm a customer, and I have that need.
Q.E.D.
😜

@iSazonov
Sorry but I am still unclear on the issues.  The latest algorithm in this PR seems Ok to me.  It makes ten attempts to a) generate a random file name then b) create the file.  Each attempt either succeeds or fails.
But it sounds like the dotNet implementation of file creation is susceptible to race and file access permission errors where a) two processes end up with access to the same temp file and b) file access permission is incorrect and possibly detrimental to one of the processes owning the file causing a security hole.
Is this correct?
So the conclusion is that currently there is no way to safely create a new file until these dotNet layer bugs are fixed.  You are suggesting that we create our own native layer file creation for both Windows and Linux platforms that do not have these weaknesses, and then try and get these changes into dotNet.  Correct?
Thanks!

@PaulHigin

The latest algorithm in this PR seems Ok to me

Formally it is Ok. Really it has race and security hole.

until these dotNet layer bugs are fixed.

It is not CoreFX bugs. This is due to the misuse of these functions. With glibc we can get the same - that's why mkstemps() was added.
My suggestion for CoreFX is add something like:
public static string GetTempFileName(string Suffix)
public static string GetTempFileName(string Prefix)
public static string GetTempFileName(string InTempDirectory)
public static string GetTempFileName(string Prefix, string Suffix)
public static string GetTempFileName(string Prefix, string Suffix, int VariableLength)
public static string GetTempFileName(string Prefix, string Suffix, int VariableLength, string InTempDirectory)

// And API to create temp directory

Yes, my suggestion is implement the APIs temporary in PowerShell.

I think it would be best  to modify the existing algorithm using the proposal of @mklement0 , which sounds like an overal improvement and closes the  'hole' (assuming that the rename method does not change  the file permissions). I am not sure if this 'hole' is a bit superficial because on Windows any other process can edit the generated temporary file and it would only affect security if a developer directly injected content of the temporary file into other methods in their program or script(please correct me if i'm wrong). Any decent developer should know that any input has the possibility of being a vulnerability for injection methods and therefore needs to assess the risk and potentially defend against it. We should probably have a chat with corefx (maybe we don't have enough understanding of the security model that underlines corefx) but trying to do all the low level stuff ourselves makes it look like to me that we are either overegging the pudding or that corefx is unsafe.

@bergmeister Sorry for the delay.
Based on @lzybkr and @mklement0 conlusion and we can continue to follow the @mklement0  proposal:

A simple way of rewriting this PR in order to keep Path.GetTempFileName() in charge is to:

Always start out with filePath = Path.GetTempFileName()  - this will ensure the proper permissions.

Only if -Extension was specified:

Use filePathWithCustomExt = Path.ChangeExtension(filePath, Extension) and then  rename that file (File.Move(filePath, filePathWithCustomExt)) in a retry loop.

@iSazonov @lzybkr I have committed the change in the algorithm as agreed in the last comment, the only subtle difference was that the retry logic always applies because it was 'free' and allowed to have less and more elegant code this way.

I addressed the main points made in the review:

If the extension is '.tmp', then it goes through the same codepath as before this PR and only otherwise use the new algorithm
cater for failure if file deletion fails in catch block
improve tests and add Unix specific test for '.TMP' where we expect the file ending in '.tmp' to not exist. Unfortunately this test fails on the Mac build and I am not sure why. Could this be a bug in Pester/PowerShell? Any ideas?

I addressed the main points made in the review:

If the extension is '.tmp', then it goes through the same codepath as before this PR and only otherwise use the new algorithm
cater for failure if file deletion fails in catch block
Usage of Ordinal string comparison
improve tests and add Unix specific test for '.TMP' where we expect the file ending in '.tmp' to not exist. Unfortunately this test fails on the Mac build and I am not sure why. Could this be a bug in Pester/PowerShell? Any ideas?

I have updated the test to pass since one test did not make sense on Mac due to the the fact that Mac sees files with different casing as the same file similar to Windows.

Currently we have new API request in CoreFX and CoreFX team has post 2.1 plans to enhance the API. Feel free to vote for the API.
I believe we can close the PR as non-critical and wait CoreFX implementation.


Recurring expenses

Implement list recurrence and add recurrence features.
Adding a recurrence creates and adds multiple expenses to expenses in model. At the same time it also creates a recurrence contain a list of the expenses added, adds to the recurrence list in model.
Add recurrence does not save recurrences to json file, so recurrence info will be lost upon restart of application. Expenses will remain in the model.
Add recurrence currently does not support undo and redo.
@waynefong0401 Regarding the concern of adding multiple future expenses affecting statistics, I feel that it should be the same as manually adding future expense, so it is not a problem arising from recurrence feature. A possibility will be to have FutureExpense instances that does not show up in the user interface.
I am still adding more code so you guys don't need to help me merge.

Test for new classes not added yet

This version is should be okay to merge


UI: Respond to state change signal in all tabs

[x] 18) Respond to state change signal in "Overview" tab
[ ] 19) Respond to state change signal in "Balances" tab
[ ] 20) Respond to state change signal in "Send" tab
[ ] 21) Respond to state change signal in "Transactions" tab
[x] 22) Respond to state change signal in "Toolbox" tab edit: it pulls, so no auto-update required.

As mentioned via email:
I tested every tab and instant feedback is given everywhere, if the own client is the active party, wether it's balances or something else and this seems to be very solid.
Testing with two clients was a bit more tricky, but the behavior is as follows:
Simple Send:

A sends some MSC to B
B receives the Bitcoin transaction, but, while unconfirmed, has no information about the MSC part, nor a balance update or alike
After a block is mined, all balances update and the transaction shows up in the Omni history

Send to Owners:

A sends to MSC owners
B gets no feedback of any kind
After a block is mined the overview tab updates, while the others need a manual refresh, e.g. by selecting a currency explicitly to force an update, which is not possible for the transaction history

This can create a very strange impression, when considering the situation without signals:

Block 105: A sends MSC to B, B sees a Bitcoin transaction, but no MSC
Block 106: The MSC shows up for B, A sends MSC to MSC owners
Block 107: B sees no update in the tx history, even though a block was mined
Block 108: B still sees no update in the tx history, until A sends some MSC to B - the STO transaction pops up, triggered by the incoming BTC, but the MSC send remains invisible at this point
Block 110: Finally B sees the STO transaction as well as the Simple Send

Quick info, since you're online: I'm currently testing signals on all tabs, basically just connecting alongside the balanceChanged signal to refreshOmniState, to handle internal and external state updates.

Quick info, since you're online: I'm currently testing signals on all tabs, basically just connecting alongside the balanceChanged signal to refreshOmniState, to handle internal and external state updates.

Lovely, lovely, lovely - thank you mate :)  Let me know how it goes, I'm just still sorting the column width and resizing issue on Omni transaction history...

It works, but I'm not sure about approach. There are two models: WalletModel and ClientModel. The OmniStateChanged signal is associated with the ClientModel, which is only available for the "Overview" tab, while the others are only linked to the WalletModel.
Is there any harm in connecting the other tabs with the ClientModel as well?

Or alternatively: move the signal into the WalletModel.

Yeah, originally I think the idea was for Bitcoin Core to support multiple wallets so you have the client model which handles things blockchain related (notify of new blocks etc) and the wallet model which handles things related to the wallet.
I felt clientmodel was the right place, as the signal was notifying of a new block with Omni transactions (wallet contents were irrelevant) but we can look at a move sure.
There is also something else to bear in mind - we still need to update certain parts of the display on a block change even without any Omni transactions (for example the icons indicating number of confirmations).
Thanks
Z

Yes, I ended up to subscribe to both models, to continue to handle outgoing, unconfrimed transactions as well. PR incoming in a few minutes.

Should be addressed by #29.

I have the impression all those signals and extreme processing of everything has a significant effect on the performance, at least when running the test suite the UI appears to freeze for a moment. Not sure about the real world impact, but this is certainly something to address rather sooner than later, to avoid creating huge overheads.

100% agree, efficiency is nowhere to be found at this stage sadly.  The processing is heavy, and there are likely lots of avenues for optimization.  On top of that I think we're updating probably more often than we need to.
I usually do things with timers to time each function, but holistically as an overall thing that's time consuming and cumbersome - this may sound like a bit of a dumb question, but are there any profilers out there that could give us a list of functions as they're called and how long they take?  Alternatively I can manually time each function with timers and printfs etc.
Thanks
Z

FYI updateHistory for example takes 0.38 secs.

On top of that I think we're updating probably more often than we need to.

Yes, way to often, and even when not required. But this is no deal-breaker, because the UI can still be optimized, and it's fine, as long as it doesn't break, at least in my opinion. It would be different, if we'd slow down the server deamon though.

Profiling

This would really help to identify bottlenecks. Unfortunally I'm not into this topic, but I stumbed upon Valgrind a few times, and as low level tool there is gprof, as far as I know.

FYI updateHistory for example takes 0.38 secs.

As far as I can see each time UpdateHistory() is called transactions are fetched from the wallet and parsed. Let me say it this way: I have a few ideas to optimize this, or to optimize how updates are handled, or to work further towards plain transaction objects and serialization (https://github.com/mastercoin-MSC/mastercore/issues/283#issuecomment-72756268), but I'm not sure, how to prioritize here.
As mentioned at the beginning, I think it would be best to solve all cricial issues first, e.g. wrong order, missing updates, if there are any, ..., then start to cleanup, and finally start to optimize or replace components. :)
What exactly did you measure?

Yep agreed, let's regroup on this for <IP_ADDRESS> (or if it's major surgery, perhaps the UI for 0.0.10 since we'll have extra stuff for MetaDEx there anyway).
I just stuck a boost timer at the beginning of the function, and then pumped it out at the end of the function (I like using timer because it gives elapsed time not CPU time which can be skewed eg with thread sleeps and so on).
Completely agree on the criticals, I've tried to run through all the low hanging fruit and think that's pretty much it now - all that's left is to address the criticals relating to ordering and signalling which I'm diving into now.
Just wanted to say thanks for all your help on this dude and how much I appreciate it - with all the feedback over the last week I've been able to really make some progress so just wanted to say thanks :)
Z

Thanks for the feedback. :)
There are basically three broader problems, all somewhat connected to each other:

Pulling and parsing a part or the whole history each time adds a significant overhead of many, many results that were basically already available
The number of STO related iterations is nTxs * nFilteredReceipts * nReceipts, if I'm not mistaken, and with only a few larger ones huge delays could be created.
Passive effects in general are a troublesome. It's not just STO, but we also have exodus purchases, additional grants via crowdsale bonus, dex trading, etc.

The problem is by no means that the building blocks are bad, and each step is quite fast, but it seems like tackling the problem from the wrong direction. Instead, we may try to create OmniTxHistoryEntry objects which are stored/cached and inserted, updated or deleted, once it's state changes. For most parts those objects should be immutable, except the number of confirmations, ...
... so what would be the best way to describe effects? A Simple Send is static and straight forward - a movement of tokens from A to B. A creation of a property with fixed supply is somewhat straight forward as well, but how about crowdsales for example?
There is an upside though: this is pretty related to something that might become an audit ledger at some point.

Let's use this issue for further discussion.
I really have a bad feeling about the impact of the STO handling, though I did not yet test it on mainnet, but I counted nearly 30000 iterations of txhistorydialog.cpp#L297-L341 while running the regtests. My concern is that one may spam the network with large STO transactions and basically shutdown all Qt clients.

Wow. Yikes.  Well that's obviously not acceptable!

Another note: we are pretty wasteful regarding transaction processing in general, and I'm referring to things like going through all Omni transactions to find one, or to count them, etc., so we likely might get away with this.
It basically comes down to the following:
We need access to transactions in some form, which ultimately provides:

bool valid (or maybe not.. I don't support invalid transactions.. :P)
bool bInbound
std::string txTimeStr
std::string displayType
std::string displayAddress
std::string displayAmount
std::string txidStr
bool fundsMoved

Maybe with raw values instead of strings, but this is a minor detail. The number of confirmations can be updated or fetched on the fly, when a new block is found.
What if we do a simple check such as CheckIfTransactionAffectsMe() once a new transaction is processed, and if true, the transaction is transformed into an object with the values stated above and held in memory?
The UI could then use those objects, instead of parsing and processing everything over and over again.
During startup, while the cache is still empty, the most recent transactions could be fully re-processed.

Imho it works. And we may start a new thread when it comes to creating a new model, etc., but for now, the intiial issue is solved.


[SUGGESTION] Ability to add and remove dataviews in the GUI

Currently, users have to first create a project by adding all relevant data sources via functions like snub.io.add_video, snub.io.add_scatter etc. Once a project is created and opened, there is no way to add more data sources as views directly in the GUI. It would be nice to initialise a project with a few views, and be able to add more as you see fit.
In other words, I would like for the add_ methods to be exposed in the GUI, perhaps under the "File" menu.  It would also be nice to have the option to close data views in the GUI (e.g. via an 'X' button on each panel).
This is more of an idea for a possible future direction. Feel free to dismiss if you think it would complicate things too much.

I like this idea! Adding an "X" button for closing a widget is easy and will be included in the next release (implemented here https://github.com/calebweinreb/SNUB/pull/25).
Adding new widgets through the GUI is a little more of a lift so I may wait to see if it is requested by anyone else. But in principle I could definitely imagine a generic widget that programmatically exposes the args/kwargs for each respective add_ function.

I agree that this would be a great functionality to add!


DX errors

Reporting usability errors as I have them to improve the developer experience.
Wasn't sure what database was included in this project. Assumed I would have to add it myself. No where in the README.md or Hitchhiker Guide does it say "database", which is what I searched (ctrl + F) the page for.
Will try to stay motivated to report more usability errors while using your project. Looks awesome!

Not sure if including a database, or any other back-end specific features, would be reasonable for a front-end boilerplate?
Front-end apps can be connected to various data sources, usually via an external API / WebSockets, so adding that (via redux-saga in this case) should probably stay a responsibility on the developers side for each project separately.

Thanks @mjurczyk. Should the docs clarify this at all? Also, had a lot of trouble styling a custom component and eventually just moved the component from npm modules to the container folder. Not sure how to fix this, but I made a SO question about it https://stackoverflow.com/questions/46045746/how-to-change-the-css-on-a-component-using-styled-components

@TylerL-uxai well, that is exactly why README suggests that this is a really bad repository to learn new things from (Please note that this boilerplate is production-ready and not meant for beginners!). And it's not there to offend anyone with less experience - simply the amount of frameworks and their combination here make it really easy to get lost in the code, unless you know what is going on.
In fact, if you clone and launch the boilerplate app example, you should get almost the thing that you are asking for - the example app fetches data of a user from github using redux-saga. To integrate the boilerplate with any database, you should first prepare a back-end application that serves some API endpoints for the database - and for that you will need to use either a separate framework and / or language. After you have such an API app running, all you need to do is to change the redux saga to fetch data from your API instead of Github's.
Regarding the styled components I will reply on the stackoverflow - since that is a separate topic 🙂

Awesome work, MJ! Thanks for the SO response as well.

Just wanted to thank you for your response again. I referenced it while building a database with the question "Where should I put the routes for server side req/res?" I see now that it should integrate with react saga. Still not sure where to put the database folder, though (if it should go in 'app' or 'server')

Next DX error: unclear from documentation how to add a route with a parameter

@TylerL-uxai Do you mean this?
https://github.com/react-boilerplate/react-boilerplate/blob/master/docs/js/routing.md#dynamic-routes

Closing this since it's not an issue with RBP (yet).


add accessibility statement to website

dryad had statement that accessibility doesn't apply to assets themselves
we can mention also that the libraries we use we try to acquire VPATS or accessibility statements. but may not be completely accessible to standard we expect

https://github.com/dulibrarytech/digitaldu-frontend/pull/292


Review: names of the encoding/decoding views confusing

I find the names of the encoding/decoding views confusing. I would
expect a "decoded_view" to refer to underlying encoded data and
return equivalent decoded data when it is read from, but you seen to
call that an "encoded_view".

I agree that some uses might be confusing, like in
pct_encoded_view decoded_host = u.host();

When we replaced const_string, everyone who looked at this view proposed one of  decode_view, decoded_view, pct_decoded_view, or decoded_view.
If we follow the convention used in std::ranges, then it would be pct_decode_view, because it's always a verb:
https://en.cppreference.com/w/cpp/ranges/transform_view
https://en.cppreference.com/w/cpp/ranges#Range_adaptors

More comments:

I do feel that pct_encoded_view is an unfortunate choice for a view that
actively decodes URL-encoded characters. I'd prefer pct_decode_view or
pct_decoding_view. Views names should probably  describe the semantics of the
view itself, not what kind of underlying sequence is being adapted/transformed.

More comments:

I did also find the naming situation for encoded/decoded a bit confusing. In
particular, url::path returns pct_encoded_view, but url::encoded_path returns
string_view. I would expect the opposite. Maybe this needs additional
explanation in the docs?

We are going to do decode_view


DTM : Same device can be used in multiple hierarchies, which should not be allowed.

Currently in DTM application the below issues are observed with respect to hierarchy creation and hierarchy structure :

Adding same device for different assets should be restricted. User is able to assign the same device to multiple Assets, which is not logical. This should be restricted.

Moving an asset outside it's parent should be restricted. Currently user can move an asset outside the parent and place it in a totally different asset hierarchy, which should be restricted.
Eg : User can move the printer asset from under a Building and place it in Production line which is not relevant/ logical.

When user tries to move an asset, it is observed that alert popup is getting displayed. Currently the following message is getting displayed on the popup "Do you want to move the group?", this has to be changed like "Do you want to move the asset?".

A generic isseue observed throughou the application is that, user can create duplicate labels / names or names with whitespaces only. Both should be restricted.

Working as per the design.


Route Advertisement support

After AS support #127 it would probably be useful to track IP assignments & their routing given client assignments may not be directly connected for MSPs.
This support could include advertised, received, and accepted routes.

I don't think NetBox is a suitable tool for maintaining routing policy. BGP policy especially can get very, very complex and probably deserves its own tool.


home: handle a badge race

the badge race, I believe, happens when you visit home right around the same time an announcement is being introduced
in this case, your view of home doesn't show the announcement, but the queued rerender of your server-side home state does pick the announcement up
which drives your badge state +1
the issue, previously, was that you could keep stale home state even after your badge is driven for up to 1 hours
so now we clear home cache on badge state, if appropriate
might result in some flickering, so let's be on the lookout for that and readdress if so

ping @jakob223


[T3A4][F11-A2] Le Minh Duc

Ready for review

Since we've discussed it in detailed during the tutorial ~ this was marked as accepted w/o review :)


[cli] Make it easier to deduplicate dependencies with yarn resolutions

I'm creating this feature request for others to learn how to do this and in case someone wants to implement this improvement.
Context
The Backstage project releases new releases every few months. Between those releases are pre-releases with next tag. Sometimes consumers of the Backstage project want to use the pre-releases to experiment with the new changes or get the newly merged code sooner. Unfortunately, this process of getting a pre-release is complicated and error-prone.
For example, if I want to upgrade to<EMAIL_ADDRESS>I'll get the following output with yarn backstage-cli versions:check
The following packages must be deduplicated by updating dependencies in package.json

  @backstage/plugin-catalog-backend @ ^1.4.0 should be changed to ^1.4.1-next.0

The following packages can be deduplicated by updating dependencies in package.json

  @backstage/backend-common @ ^0.15.0-next.1 should be changed to ^0.15.2-next.0
  @backstage/backend-common @ ^0.15.1 should be changed to ^0.15.2-next.0
  @backstage/backend-plugin-api @ ^0.1.2 should be changed to ^0.1.3-next.0
  @backstage/backend-tasks @ ^0.3.2 should be changed to ^0.3.6-next.0
  @backstage/backend-tasks @ ^0.3.5 should be changed to ^0.3.6-next.0
  @backstage/catalog-client @ ^1.0.3 should be changed to ^1.1.1-next.0
  @backstage/catalog-client @ ^1.0.4 should be changed to ^1.1.1-next.0
  @backstage/catalog-client @ ^1.1.0 should be changed to ^1.1.1-next.0
  @backstage/catalog-model @ ^1.0.3 should be changed to ^1.1.2-next.0
  @backstage/catalog-model @ ^1.1.0 should be changed to ^1.1.2-next.0
  @backstage/catalog-model @ ^1.1.1 should be changed to ^1.1.2-next.0
  @backstage/config-loader @ ^1.1.2 should be changed to ^1.1.5-next.0
  @backstage/config-loader @ ^1.1.4 should be changed to ^1.1.5-next.0
  @backstage/config @ ^1.0.1 should be changed to ^1.0.3-next.0
  @backstage/config @ ^1.0.2 should be changed to ^1.0.3-next.0
  @backstage/errors @ 1.1.1 should be changed to ^1.1.2-next.0
  @backstage/errors @ ^1.0.0 should be changed to ^1.1.2-next.0
  @backstage/errors @ ^1.1.0 should be changed to ^1.1.2-next.0
  @backstage/errors @ ^1.1.1 should be changed to ^1.1.2-next.0
  @backstage/integration @ ^1.2.1 should be changed to ^1.3.2-next.0
  @backstage/integration @ ^1.3.1 should be changed to ^1.3.2-next.0
  @backstage/plugin-auth-node @ ^0.2.5 should be changed to ^0.2.6-next.0
  @backstage/plugin-catalog-common @ ^1.0.3 should be changed to ^1.0.7-next.0
  @backstage/plugin-catalog-common @ ^1.0.6 should be changed to ^1.0.7-next.0
  @backstage/plugin-catalog-node @ ^1.1.0 should be changed to ^1.1.1-next.0
  @backstage/plugin-permission-common @ ^0.6.2 should be changed to ^0.6.5-next.0
  @backstage/plugin-permission-common @ ^0.6.4 should be changed to ^0.6.5-next.0
  @backstage/plugin-permission-node @ ^0.6.2 should be changed to ^0.6.6-next.0
  @backstage/plugin-permission-node @ ^0.6.5 should be changed to ^0.6.6-next.0
  @backstage/plugin-scaffolder-common @ ^1.1.1 should be changed to ^1.2.1-next.0
  @backstage/plugin-scaffolder-common @ ^1.2.0 should be changed to ^1.2.1-next.0
  @backstage/plugin-search-common @ ^1.0.1 should be changed to ^1.0.2-next.0

I upgraded to a new package, which installed new dependencies with next.0 tag. To prevent unexpected problems, I have to force each dependency to use the same version yarn resolutions.
Here is the process for deduping each dependency.

Take the first package in the list and run yarn why @backstage/backend-common
See which package is using the wrong version. In this case, it's all of the package in the workspace.
Add "@backstage/backend-common": "0.15.2-next.0" to resolutions in package.json
Repeat for the next package on the list

Feature Suggestion
It would be very nice if this could be done when running yarn backstage-cli versions:bump --release next --pattern=@backstage/backend-common, maybe behind --resolutions flag.
Possible Implementation
I'm not sure if there is a better way to do this, but we could use the list of generated packages, iterate through each package and add it to the resolutions.

Hi Taras, these warnings in the cli should probably be removed entirely, we have removed a fair bit of these false warnings previously and this should likely be removed as well.
Having transient dependencies on older versions of the packages mentioned above is not be a problem. However adding resolutions that lock them to a specific version could definitely introduce bugs and problems as behaviours inside the package you add resolutions for might have change. We should probably reword this into a bug report and make sure the CLI is updated to not introduce confusion about this.

@jhaals I'm not sure they're entirely just warnings.
For example, I just ran  yarn backstage-cli versions:bump --release next --pattern=@backstage/core-app-api on http://github.com/thefrontside/backstage and I get this.
yarn backstage-cli versions:check

yarn why @backstage/core-app-api

"_project_#app#@backstage#app-defaults#@backstage#core-app-api" can't be updated by changing package.json because it's transient dependency.
I could fix that with resolutions but I don't know another way.

Very specific bumps like this is not really why we have the pattern, it's more for bumping a specific namespace or plugins. For this example with just bumping @backstage/core-app-api you must bump the app defaults package as well as it depends on it.

@jhaals thank you for discussing this issue with me. My goal was to surface this scenario in case others might find themselves in a similar situation. We've done that now, so we can close this issue :)

@jhaals I forgot that you suggested we rephrase this feature request as a bug to remove the extra warnings. Do you still want me to do that?

How did this fixed


[SR-778] Forgetting the in keyword can sometimes lead to compiling code

Previous ID
SR-778

Radar
None

Original Reporter
chriseidhof (JIRA User)

Type
Bug

Status
Reopened

Resolution

Additional Detail from JIRA

Votes
0

Component/s
Standard Library

Labels
Bug

Assignee
None

Priority
Medium

md5: 0093a5f05b0f3ded251f13fdd054fe04

relates to:

SR-245 Missing @warn_unused_result attributes in Standard Library

Issue Description:
Try the following code:
var x = 0
let capture: () -> Int = { [x]
  return x
}
x++
capture()

Expected result: because there is a capture list [x] that should capture x by value, we expect the result of the final call to be 0. However, it is 1. This is because we forget the in keyword, and [x] gets parsed as an array literal.
A possible solution would be to warn about [x] being an unused expression.

Would be nice to have a special warning for when the opening brace is followed on the same line by something that successfully parses as a capture list, and the alleged capture list is followed by neither in nor a type. Sounds like a decent starter bug.


Reverse the tray icon order

At the moment when a new appindicator is added, the icon gets added to the end which isn't very good if the tray is positioned on the right of the bar.
With reverse-direction set to true, new app indicators get added to the start

Thanks, can you also update GitHub wiki? :)

Ofc! :)

The wiki is now updated


Support question - calling client.search() in the same tick as client.bind()

This is a support question :)
I am wondering if it's totally safe to use this pattern:
client.bind(dn,pwd, function(e){
});

 // search is called in the same tick - without waiting for bind to complete
client.search('foo', function(res){
});

does ldapjs handle this for us, or should only call client.search (and similar methods) after the bind callback fires?

Why would it be okay? You need to bind first and see if the bind war successful.
You need to move the client.search into the bind callback to have a proper workflow.
Thing is the bind connection might be slower than the search query. This is when you get race conditions.

⚠ This issue has been locked due to age. If you have encountered a recent
problem that seems to be covered by this issue, please open a new issue.
Please include a minimal reproducible example
when opening a new issue.


support BitBucket and other Git repositories for Dockerfiles and Dockstore.cwl

Bitbucket Cloud (looks relatively simple, documented API here https://confluence.atlassian.com/bitbucket/use-the-bitbucket-cloud-rest-apis-222724129.html oauth and third party applications documented here https://confluence.atlassian.com/bitbucket/oauth-on-bitbucket-cloud-238027431.html )

This feature exists in production


events for data-remote requests not firing

I'm using $rails.handleRemote to run remote calls on dynamically created remote links.
However, even though I attach these links to the document, none of the events ajax:complete, ajax:success, ajax:error are fired.
My controller returned javascript and updated the page accordingly but I changed it to return html content it so I can better handle user input errors and so on in the ajax:success and suchlike events.
I tried adding
    $(document).delegate('a[data-remote]', 'confirm:complete', function(e, answer) {
        console.log('confirmed!', answer);
    }).delegate('a[data-remote]', 'ajax:before', function() {
        console.log('sending!');
    }).delegate('a[data-remote]', 'ajax:complete', function() {
        console.log('complete!');
    }).delegate('a[data-remote]', 'ajax:success', function() {
        console.log('success!');
    });

but nothing shows up.
No javascript errors are shown on the console either.
During debugging I have seen the line is run, but the event is not fired!
success: function(data, status, xhr) {
            element.trigger('ajax:success', [data, status, xhr]);
          },

Any tip to narrow down the problem?

Hi. Just saw this. I wonder if it's related to what I just filed: #408

I am having this same problem. I have a few forms on the page, no required elements. The forms submit with ajax, but not getting any events fired.


make nimibPreviewCodeAsInSource the default and add nimibCodeFromAst

The official release of 0.3 seems very close now. It make sense it will include the great work by @HugoGranstrom on finally bringing js backend based interactivity to nimib (one of the big milestone in the roadmap). I think it might be a good moment also to make default the CodeAsInSource (until now available through flag nimibPreviewCodeAsInSource, also excellent work by @HugoGranstrom btw).
We know it has edge cases where it will fail but it does not seem to be an issue for code as it is usually formatted (and the alternative CodeFromAst also has some issue - which did raise bugs directly in nim). The current default option would then be made available behind switch nimibCodeFromAst.
My idea would be to make it the default, testing if issues arises in nimibook and scinim/getting-started, and if no issues arise keep it for 0.3.
Thoughts?

I definitely think we should test it on a wider corpus to be able to iron out the bugs that exist. And if there aren't any major ones that are really hard to solve I'd say we do the switch.

you mean wider than nimibook and scinim/getting-started? my blogposts for advent of nim 2021 were all using the flag and I did not see issues.


Polymode deferred installation doesn't work

See #21.
Polymodes require two passes to get right. However, find-alternate-file is sufficient, while it is not for TeX.

This was probably fixed during #49!


✨ auto-expanding editor title input

closes https://github.com/TryGhost/Ghost/issues/8463

move generic text input handling into text-input mixin so it applies to text inputs and textareas
adds autoExpand property to gh-textarea that accepts a selector to watch for resize changes, if the property is set then auto-expanding behaviour is triggered any time the textarea value is changed or when the selector element is resized (this prevents change in textarea width after toggling nav/split screen mode causing textarea content to become hidden or the textarea to be taller than it's contents)
adds ember-element-resize-detector addon to allow watching of element resizes rather than window resizes (this was already included as a sub-dependency via ember-light-table->ember-scrollable->ember-element-resize-detector)
retains Tab and Enter behaviour from the <input type="text"> input

Coverage increased (+0.06%) to 71.45% when pulling 2be8190894c5e1e8cd10f1361a78050cd5a8de17 on kevinansfield:multiline-title into fac2560bcb42f8f5eb1fb38b7a34e395d4f9d5b2 on TryGhost:master.