Program memory should not store JSON

Background
KCL program memory can store various different values, defined by the MemoryItem enum.
One case is "UserVal" which ultimately just stores serde_json::Value (see definition of UserVal). User values are serialized into JSON before storing them in program memory. Reading from memory deserializes the value into its expected type, and returns a KCL type error if the value couldn't be deserialized into the right type.
Problem
This works OK but leads to bugs when developing the modeling-app wasm-lib. Why? Because so many types implement serde::Deserialize and you can try to deserialize a memory item into any of them. Even if those types never get written to memory ever! E.g. we never store a SocketAddrV4 in KCL program memory, but the rust compiler won't warn you if you try to request that from KCL memory. But it should! It should be a rust-compile-time error to request something we'd never expect to find in KCL memory.
Solution
We should remove the UserVal variant from MemoryItem and add new variants for KCL primitive types (numbers, strings, the KCL none type, etc).
This way, you ensure that reading values from memory requires that the value can at least be stored in memory.

I learned that in KCL, 0 / 0 is null! I learned this trying to make a test case that uses NaN or infinity. Couldn’t figure out those, but I got something else :smiling_imp: This happens because we represent all our numbers with a JSON type, and JSON doesn’t support NaN or infinity.
Slack thread

Trying to use null as a number:

We basically want a model for what sorts of values exist in KCL. Here's my proposal.

Integers
Fractional numbers
Strings
Tag (ID and declaration)
Closure (i.e. function + captured environment)
Imported geometry
KclArray (i.e. Vec)
KclObject (i.e. HashMap<String, KclValue>)

If we do this, then KclValue's variants for SketchGroup, SketchGroupSet etc would be removed. Instead, SketchGroup would be serialized into KclObject. Functions which take a sketch group would have to check the KCL value being passed as an argument is a KclObject, then deserialize that object into a SketchGroup.

As a KCL user, I like the idea of making SketchGroup and other things be Objects like any other user-defined object. My only concern would be whether we can represent all the things we need internally. But if we can do that, I think this is a good idea.

I'm looking at the definition of SketchGroup et al now. The first thing that jumps out at me is that one of its fields is its Paths. A Path contains all the coordinates of the path, whether each segment is a line, tangential arc, angled line, etc. So this would need to be represented as KclObjects too, in addition to Plane, Face, and ExtrudeGroup.
If I were doing this, it seems big enough that I'd probably do it as a separate change, i.e. one PR to replace JSON with booleans, integers, floats, and strings. Then after it's merged, a second PR to collapse the rest into KclObjects.
Even just the first PR should fix #3338 and other issues.

To clarify, this is what I propose as a first step to reduce the downstream impact. I believe this would fix #3338 because the SketchGroup would be stored as a value in the Object's HashMap, as a KclValue::SketchGroup (or possibly KclValue::SketchGroups plural). This avoids serialization to JSON. The serialization to JSON is problematic because nothing in executor knows how to deserialize again.
If you're doing the change, it's up to you whether you want to try to do it all at once, like in your comment above.
pub enum KclValue {
    // I don't want to get hung up on this.  I think we use null in a couple
    // places.  This is a replacement for that.  It would be nice to have
    // something for when a function has no meaningful return value, instead of
    // Option::None.
    Unit,
    Boolean(bool),
    String(String),
    Integer(i64),
    Float(f64),
    Array(Vec<KclValue>),
    Object(HashMap<String, KclValue>),

    // Everything below is unchanged.
    TagIdentifier(Box<TagIdentifier>),
    TagDeclarator(Box<TagDeclarator>),
    Plane(Box<Plane>),
    Face(Box<Face>),
    SketchGroup(Box<SketchGroup>),
    SketchGroups {
        value: Vec<Box<SketchGroup>>,
    },
    ExtrudeGroup(Box<ExtrudeGroup>),
    ExtrudeGroups {
        value: Vec<Box<ExtrudeGroup>>,
    },
    ImportedGeometry(ImportedGeometry),
    #[ts(skip)]
    Function {
        #[serde(skip)]
        func: Option<MemoryFunction>,
        expression: Box<FunctionExpression>,
        memory: Box<ProgramMemory>,
        #[serde(rename = "__meta")]
        meta: Vec<Metadata>,
    },
}

The experiment of "serialize all values into JSON and just store JSON everywhere" is not looking good. Lee's L-system program is very slow because it spends most of its time repeatedly deserializing sketchgroups. I also don't think this approach will let us store KCL functions -- how would you serialize a KCL function into JSON?
So, I think we should return to the proposal above, i.e. a KclValue enum with no UserValue variant. We'd replace it with variants for each primitive type (e.g. numeric types, string, bool) and collections (i.e. object and array).


ERROR: Unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

ERROR: Unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

youtube-dl --verbose https://youtu.be/VB9yrn1VTRM?si=AQxaqTnAEiZlFMsZ

I'm having it as well, figured I'd actually include the verbose output.
bash-3.2$ youtube-dl https://www.youtube.com/watch?v=****** --buffer-size 16K --verbose
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['https://www.youtube.com/watch?v=******', '--buffer-size', '16K', '--verbose']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2021.12.17
[debug] Git HEAD: 7f745d04d
[debug] Python version 3.12.0 (CPython) - macOS-14.0-arm64-arm-64bit
[debug] exe versions: none
[debug] Proxy map: {}
[youtube] cfmocAG3Ik4: Downloading webpage
WARNING: unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
[debug] Default format spec: best/bestvideo+bestaudio

#30839 !
Also, why would you think that that is a sensible issue title?


Package Deployer missing dependency.

While working on using 'pac package deploy' following the documentation a dependency on a Microsoft.Deployment.Compression.Cab keeps coming up and I can't seem to see where that was to be installed in the documentation. Here is the error log.
deploy.log
I have been able to use Import-CrmDataFile to successfully import the file.
Any help on what I am missing would be helpful. Thanks.

Resubmitting after testing lates tool version and to code repo, not doc repo.


If session not found in Memcache, create a new one

This happens when a user has a stored session cookie from a prior
run of memcached.  eg the memcached server/cluster has been restarted
When the user returns, their session cookie is successfully decoded
but the memcache value it refers to doesn't exist.

Note... I'm not at all sure this is the right approach. :smile:

Ahhh.  Ignore this.  Looks like I should be detecting memcache.ErrCacheMiss returned by the higher level Get(), [doing stuff] (eg looking for session data persisted to PostgreSQL), then calling sess.Save() to create a new session.
Something like:
sess, err := store.Get(r, "dbhub-user")
if err == memcache.ErrCacheMiss {

	DoStuffHere()

	err = sess.Save(r, w)
	if err != nil {
		return err
	}
}

Yup, that looks right to me.  I'm not totally sure if it makes more sense to let the caller figure out how to handle the case of it's memcache session data having been blown away, or have it transparently create an empty session.  There are benefits to both (e.g. the need to show a "you've been logged out due to blah blah, please log back in" message, or conversely just making the session code simpler and not have to worry about it.)  If support for this is added I think should be a configurable option.

Yeah, not 100% certain on the best approach either.
Haven't gotten around to implementing more persistent backend session storage (eg PG) yet, so just went with "detect the cache miss, queue up cookie deletion instead, then reload the page":
    https://github.com/sqlitebrowser/dbhub.io/blob/b71b335503b984a79424f5977993973f1d640b06/webui/main.go#L2056-L2071
Note - not stellar coding as we're still really just getting foundation pieces in place.  Don't want to over engineer things too badly at this stage. :wink:
The above approach should let me slot in PG-enabled-backend code at some point without too much hassle.
But having a config option instead does sound appealing.  The transparent session creation approach upon memcache miss would save the needed page reload (for us).  Might look into that down the track, when looking back at this again. :smile:

I see - yeah that all makes sense and sounds good :)  One other thing you might want to check out is there are other storage mechanisms that "speak memcache".  Many many years ago I used this https://meta.wikimedia.org/wiki/Tugela_Cache - but I'm sure there are others with similar functionality (i.e. memcache that survives a restart) and are newer.  Also, speaking from some experience, memcached is generally pretty darned stable.  In a complex system I build a few years ago we relied heavily on memcached and generally speaking, it was the least of our worries.

/me nods 😁
Yeah, memcached crashing isn't the issue.  It's more "Justin killing the live beta server by doing dumb things".  eg running it out of swap by buffering large uploads in memory (fixed by using streaming writes instead), and similar learning-on-the-fly experiences.
Obviously not treating it live a prod server (yet). 😁


Scaffold movie pages not work

Describe the bug
When I follow the document Add MVC Controller with views, using Entity Framework. it return me an error
Finding the generator 'controller'...
Running the generator 'controller'...
No database provider found. Using 'SqlServer' by default for new DbContext creation!
Minimal hosting scenario!
Generating a new DbContext class 'MyFirstMVC.Data.MyFirstMVCContext'
startIndex cannot be larger than length of string. (Parameter 'startIndex')
at Microsoft.VisualStudio.Web.CodeGeneration.ActionInvoker.b__6_0()
at Microsoft.Extensions.CommandLineUtils.CommandLineApplication.Execute(String[] args)
at Microsoft.VisualStudio.Web.CodeGeneration.ActionInvoker.Execute(String[] args)
at Microsoft.VisualStudio.Web.CodeGeneration.CodeGenCommand.Execute(String[] args)
To Reproduce
Steps to reproduce the behavior:
follow the document Part 4, add a model to an ASP.NET Core MVC app
Screenshots

Desktop (please complete the following information):

OS: Window 10
Browser chrome
Version 22H2
dotnet 7.0.4

Additional context
Add any other context about the problem here.

@gewarren  how can we close this issue? https://github.com/MicrosoftDocs/feedback/issues has become a bit bucket.


Implementation string concat

Which issue does this PR close?

Closes #1540 .
Rationale for this change

What changes are included in this PR?
Add an implementation for string concat and a single test.

Are there any user-facing changes?

Codecov Report

Merging #1720 (9e6a0f2) into master (7b164a0) will increase coverage by 0.01%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #1720      +/-   ##
==========================================
+ Coverage   83.32%   83.33%   +0.01%
==========================================
  Files         195      195
  Lines       56044    56059      +15
==========================================
+ Hits        46698    46718      +20
+ Misses       9346     9341       -5

Impacted Files
Coverage Δ

arrow/src/compute/kernels/concat.rs
100.00% <100.00%> (ø)

parquet/src/encodings/encoding.rs
93.65% <0.00%> (+0.19%)
:arrow_up:

arrow/src/array/transform/mod.rs
87.02% <0.00%> (+0.22%)
:arrow_up:

parquet_derive/src/parquet_field.rs
65.98% <0.00%> (+0.22%)
:arrow_up:

arrow/src/datatypes/datatype.rs
65.79% <0.00%> (+0.37%)
:arrow_up:

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 7b164a0...9e6a0f2. Read the comment docs.

@tustvold Thank you for the review and guidance!
I've pushed something that is faster and close to your implementation.
I'm still unfamiliar with the codebase, so I'm sure there are still some mistakes.
I'll add more test cases and support for non-zero offset later.

@Ismail-Maj Really a good start! Thank you for contributing.

Looking good :smile: I think the major thing this now needs to handle is sliced inputs, and tests.

@Ismail-Maj could you possibly merge the latest master to bring in #1743

@tustvold it should be good now.


Save Corruption

Is it a mod compatibility issue?
No
If it's a mod compatibility issue, please provide the link(s) to the incompatible mod(s)
No response
Minecraft version
1.20.1
Describe the issue
I'm running a heavily modded minecraft version with both forge and fabric. I decided to try and add Immersive Portals, just to test if it'd work.
When joining the world it said to install Sodium to go around a Nvidia driver bug, that I use many mods, that its incompatible with Bobby and compatibility issues with nvidium. So without even taking a step, I closed the world, and removed the mod.
And now my save is corrupted.
I didn't do anything other than open the save. As soon as I saw the erros, I read them, closed it, removed the mod. And now I can only open the world if I reinstall immersive portals but due to its compatibility issues, I want to remove it. Help me, please.

Explain what do you mean by "now I can only open the world if I reinstall immersive portals"? Did it crash or show any error message?

Old versions of iPortal adds dimensions. It's recommended to install Fabric API and open the world once without dimension mods, to clear the dimension data in level.dat so that vanilla MC can open the world.

When I removed the Immersive Portals mod and tried to open the world it says there's problem with resource packs and gives me the option to use Safe Mode or go back to Title Screen. If I try to use Safe Mode it crashes. If I go back to the title screen i can enter any world which I didn't open with Immersive Portals. By reinstalling Immersive Portals there's no problem when entering the said world, but it stops other mods of mine of working.
If by open the world without dimension mods you mean without any mods that create or change dimensions, Immersive Portals was the only one I've had, and opening said world without it, isn't allowed.

Are you using the latest version of Fabric API in 1.20.1? If so, provide the log and screenshot when not being able to open the world.

I cannot reproduce the file corruption issue in 1.20.1.

Nevermind. I didn't know you'd need an NBTeditor to alter the level.dat to remove the mod completely. After turning my search for answers more general instead of related to immersivePortals I found the answer. I thought since I hadn't used any of the mod, no files like that would've been created, but I was wrong

Are you using Sinytra Connector in Forge? Fabric API already have the functionality of removing wrong data from level.dat but Forge maybe doesn't yet support that.

I am. I see, then that might be the cause of the trouble!


Support throttle option in ClientOptions

What would you like to be added:
Support throttle option in ClientOptions when defining clients.
Why is this needed:
Throttling update rate on client/doc will prevent both client and server to be overloaded.
For example, animating multiplayer cursors may invoke client/doc updates for every 1ms, which will overload both client and server.
For more information about animating multiplayer cursors, check this article: How to animate multiplayer cursors
To avoid this, throttling update rate is necessary for both client and server.
Currently liveblocks support this option on client definition.
Here's liveblocks API reference:
import { createClient } from "@liveblocks/client";

const client = createClient({
  /* ... other options ... */
  throttle: 80,
});

it may be related to yorkie-team/yorkie#288


AttributeError: module 'triton' has no attribute 'jit'

Hi friends:
I installed triton from the source. But the triton compiler generates an error which is "AttributeError: module 'triton' has no attribute 'jit'". Someone knows how to solve this? Thank you!
Best

same problem

Solved by python setup.py install
https://github.com/openai/triton/issues/1693


A benchmark problem

the most time of this benchmarks spend on HASHSUM operation, instead of regular operations ADD/REMOVE/FIND, therefore results can't provide much valuable information.
e.g. enable operation HASHSUM
BENCH_PAYLOAD_TYPE=0

Generating 65536 elements and 65536 actions
Generating reference result...

Running bench BSD RB tree
===========================
Running stresstest: 3.263s

Running bench SIL 2-pointer Red-black tree
===========================
Running stresstest: 2.326s

Running bench SIL 3-pointer Red-black tree
===========================
Running stresstest: 3.210s

Running bench Linux RB tree
===========================
Running stresstest: 3.437s

Below are results without it (replaced by FIND):
BENCH_PAYLOAD_TYPE=0

Generating 65536 elements and 65536 actions
Generating reference result...

Running bench BSD RB tree
===========================
Running stresstest: 0.008s

Running bench SIL 2-pointer Red-black tree
===========================
Running stresstest: 0.009s

Running bench SIL 3-pointer Red-black tree
===========================
Running stresstest: 0.006s

Running bench Linux RB tree
===========================
Running stresstest: 0.008s

Thank you for reporting! I'm not sure what I was doing there. Will look into it.

I've changed the bench, maybe it's more useful now. It's still pretty bad code admittedly. By the way, in your output there is no AVLtree (which has a bug anyway) and there is the Linux RB tree. Did you make an adapted version?  And if you have any ideas to improve the bench, let me know.


Missing icon and website on Windows

Please note that the Vagrant issue tracker is reserved for bug reports and
enhancements. For general usage questions, please use the Vagrant mailing list:
https://groups.google.com/forum/#!forum/vagrant-up. Thank you!
Vagrant version
Run vagrant -v to show the version. If you are not running the latest version
of Vagrant, please upgrade before submitting an issue.
-> 1.8.1
Host operating system
This is the operating system that you run locally.
-> Windows
Expected behavior
What should have happened?
-> There should be an icon and link to the website
Actual behavior
What actually happened?
-> There is nothing
Steps to reproduce

Install
Vagrant
On Windows

Refs https://github.com/mitchellh/vagrant/issues/7111

Hey @chrisroberts - do you see this on your Windows machine too? Any ideas?

@sethvargo see #86. There's a mention of providing a URL. Where is that expected to be displayed?

@chrisroberts that should be the actual Vagrant icon (just like on mac)

Resolved via #86


Documentation effort

As we know, the nom documentation is not that great. It has been improving, but not fast enough, and not with a satisfying quality. It's getting to the point where anytime someone talks about nom, someone else chimes in to say the documentation is crap. This is unacceptable and a big failure on my part.
So, let's improve things:

the first page is daunting. There's a big example that uses advanced features like fold_many0, that does not help comprehension. Maybe the JSON example would be better? (provided we remove the float parsers and replace with the builtin ones). There should be an obvious path: "where do I go if I want to parse this kind of format?" "I know how to create a first parser, how do I find the combinators I need?" "I got this error, how do I fix it?"
the big list of combinators is not helpful to beginners. Once you know how nom works, displaying a kind of function definition works to explain what it does, but it's not enough in a lot of cases. It does not help that we have limited room for the text of each macro on the first page. We could add more documentation inside modules, like the whitespace module, but how do we make sure beginners will check those out instead of going directly to the macros list?
the guides have broken links. They're available on my own doc hosting, but docs.rs cannot render them, so the links are broken.
the story around named!, named_args!, custom functions, methods, is confusing. Those combinators were designed to hide how the input is passed to parsers and reduce confusion, but they do not help much. Since they're the first combinators people will use, they need to be explained clearly.
most combinators only have a one liner as documentation. I don't think large code examples will help so much there, they don't improve readability. But some small examples, with maybe some kind of table with the expected result for some inputs, would be better to get a feel of how combinators work.

This will be a lot of work, and I probably won't be able to do it all alone, but it has to be done.

@Geal Like I said on reddit, it needs a lot of work. I also said that I'd do a PR, but for now I've just rewritten the lib.rs file - if you could look over it, that'd be nice: https://github.com/sharazam/nom-documentation-readme/blob/master/README.md
It's not finished, largely based on a transcript of the Toronto video.
I think it would be OK to make a shortcodes for parsers in the macros first sentence (to deal with the space issue). Like: "call!(p1) runs parser p1" or something like that - without the huge IResult thing.
For example, you told me to use the u64! macro, but I cannot for my life figure out how to use it, everything results in an error. The documentation says that it takes the endianness as an argument, but doesn't say if it's the first or second argument or how to use it. All I ended up doing was this: http://play.integer32.com/?gist=4ba80134e419b2cbbbe4191d404194ce&version=stable
The docs for the u64! macro say that it has two inputs: the bytes it operates on and the endianness. But it doesn't work and I don't understand how I can insert the endianness that I want.
Basically, all I want to know is what parsers are "compatible" and how I have to (syntactically) combine them to do what I want. I surely don't need hand-holding with everything, but the learning curve is very steep right now.

Regarding u64!, calling u64!(endianness) should work in your code. The input / output parameters are implicit when using a macro this way.

@ekse Thanks for the help, but why is this not documented when what options are implicit. How should I have guessed that?
Any comments regarding my proposal for the main documentation? https://github.com/sharazam/nom-documentation-readme/blob/master/README.md

This is great! I was just about to file an issue about this, and I'm really glad you're on top of this. I agree with all the points.
Some specific things that come to mind:

Every combinator should have a summary line trying to describe it; skip the signature because they're not easily readable. The main point is to make it possible to scan the list and find something that matches the problem at hand.
Every combinator should have a prose description of its function and a code example for each of its variants. The macro pattern soup rustdoc generates is useless. (This is mentioned in the OP, but I think its worth repeating, esp covering all the variants.)
There need to be some larger worked examples which are not trivial "infix calculator" level, but touch on techniques like using custom error types, streaming, etc. Pointing to 3rd-party projects using nom is great, but they're not necessarily good teaching examples, using most appropriate techniques, or even up to date with the API. And even if they are good in all those ways, its hard to find examples that match something specific.

@sharazam this looks good, but I think I will actually reduce the readme to more general statements, like what you can achieve with nom, and move what looks more like a tutorial to the crate level docs. It's possible to make more long form documents in https://github.com/Geal/nom/tree/master/doc and they'll end up on http://rust.unhandledexpression.com/nom/home.html (docs.rs does not support that way of generating docs yet).
Putting the tutorial in crate docs makes it easier to keep in sync with the code. Readme examples are not compiled and tested.
A big issue right now is compiling a list of the combinators and parsers by context. Something like "use those for characters", "use those for parsing a sequence of things", etc.

I've read through the macros and here are the ones that lack an example:

[x] alt_complete
[ ] apply_m
[ ] call_m
[ ] char
[ ] closure
[ ] cond_with_error
[ ] consumer_from_parser
[ ] eat_separator
[ ] eof
[ ] error_code
[ ] error_node
[ ] error_node_position
[ ] error_position
[ ] expr_res
[ ] flat_map
[ ] i16
[ ] i32
[ ] i64
[ ] length_bytes
[ ] length_count
[ ] length_data
[ ] length_value
[ ] map
[ ] map_opt
[ ] map_res
[ ] named_args
[ ] none_of
[ ] one_of
[ ] pair
[ ] parse_to
[ ] preceded
[ ] sep
[ ] separated_list
[ ] separated_list_complete
[ ] separated_nonempty_list
[ ] separated_nonempty_list_complete
[ ] separated_pair
[ ] tag_bits
[ ] take_str
[ ] take_till
[ ] take_till1
[ ] take_till1_s
[ ] take_till_s
[ ] take_until
[ ] take_until1
[ ] take_until_and_consume
[ ] take_until_and_consume1
[ ] take_until_and_consume_s
[ ] take_until_either
[ ] take_until_either_and_consume
[ ] take_until_s
[ ] take_while1
[ ] take_while1_s -> broken
[ ] terminated
[ ] u16
[ ] u32
[ ] u64
[ ] wrap_sep

I can start to work on these.
As Geal said for some a table with input / output would also be helpful.

And here is a list of functions that lack an example (and sometimes even a documentation)

[ ] alpha
[ ] alphanumeric
[ ] anychar
[ ] be_f32
[ ] be_f64
[ ] be_i16
[ ] be_i24
[ ] be_i32
[ ] be_i64
[ ] be_i8
[ ] be_u16
[ ] be_u24
[ ] be_u32
[ ] be_u64
[ ] be_u8
[ ] begin
[ ] code_from_offset
[ ] crlf
[ ] digit
[ ] double
[ ] double_s
[ ] eol
[ ] error_to_u32
[ ] float
[ ] float_s
[ ] hex_digit
[ ] hex_u32
[ ] is_alphabetic
[ ] is_alphanumeric
[ ] is_digit
[ ] is_hex_digit
[ ] is_oct_digit
[ ] is_space
[ ] le_f32
[ ] le_f64
[ ] le_i16
[ ] le_i24
[ ] le_i32
[ ] le_i64
[ ] le_i8
[ ] le_u16
[ ] le_u24
[ ] le_u32
[ ] le_u64
[ ] le_u8
[ ] line_ending
[ ] multispace
[ ] newline
[ ] non_empty
[ ] not_line_ending
[ ] oct_digit
[ ] print
[ ] print_codes
[ ] reset_color
[ ] rest
[ ] rest_s
[ ] shift
[ ] sized_buffer
[ ] slice_to_offsets
[ ] space
[ ] tab
[ ] tag_cl
[ ] write_color

I've also noted that some examples use
```rust,ignore

and some use
```ignore

which one should be prefered ?
Ideally all examples should run as test cases. I can try to do this for the new ones and move the existing ones afterwards.

I took a shot at improving the documentation starting with the bits module at https://github.com/bheisler/nom/blob/master/src/bits.rs.
So far I've:

Added a short (prose) description to the beginning of the documentation for each macro, which shows up on the main index page. This should help with finding the macro that does what you need. It also moves the detailed signature to the macro-specific page along with any other detailed notes.
Modified the examples to be more understandable
Added an example for tag_bits, which didn't have one.

If this sounds good to the maintainer(s) and if time permits, I'll carry on to make the same changes for the other files and start submitting pull requests.

closing this in favor of #914


Force the Error/Success callbacks to be called on the main thread.

This issue is fixed by 85fb726a127eb1afe6ec5b04ba418f6c29bbc8f4.


Custom base class for SOAP responses?

In particular, I'd like to implement a non-fatal get() on one.

Seems to require messing around with suds.client.Factory, and isn't well documented. Closing for now.


Move Repo for RHEL systems to EPEL

powerstack.org no longer exists
Redis is now in EPEL

Closes #103

// , I think EPEL only has ReDiS 2 for CEntOS 6, right?
Anyway, IUS appears to host a copy of ReDiS 3.2 for CEntOS 6:
https://dl.iuscommunity.org/pub/ius/stable/Redhat/6/x86_64/repoview/letter_r.group.html


Fix #1798 -  Disable UndoLastCommit when no commits

This makes Undo Last Commit action in Git Integration if there are no commits (usually just after git init)
Unfortunately UndoLastCommit will also fail if there is only one commit (HEAD~ is not defined in such case). But it looks like that currently git integration doesn't provide information about HEAD parent (or commit list, or anything like that) so it would require more "deep" changes.
CC: @joaomoreno as assignee to #1798

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

Coverage remained the same at 61.185% when pulling 51e43765885c74b303491d0318dbc26668418140 on Krzysztof-Cieslak:fix_1798 into 8911a6a6404ce58937b9f5fa60a7705601c28136 on Microsoft:master.

This makes Undo Last Commit action in Git Integration if there are no commits (usually just after git init)

Cool, thank you! This bug held a special place in my heart, since it lost me a little bit of data in my first hour or two of trying vscode.

Unfortunately UndoLastCommit will also fail if there is only one commit (HEAD~ is not defined in such case).

Does gitservice throw an error that you can trap if HEAD~ is not available? I see an IGitServiceError defined in https://github.com/Microsoft/vscode/blob/master/src/vs/workbench/parts/git/common/git.ts
but I can't dig in right now...
In such a case (deleting the first and only commit), I think the right thing to do would be to fall back to delete the branch. Perhaps with a confirmation prompt. Thoughts?

Thanks!


User workflow when already set up one team

As a user who already set up an account and also added a search for a team, I don't want to be send through the whole registration process again when returning to the website or starting again from the homepage even if I click on "offer employees"

Don't go to personal data, but jump to teams right away

There is currently no other possibility to edit your profile. The jump-start is via top "Deine Partner". Also, if you re-login, you will be directly pushed to the dashboard.
We have to postponed this.

duplicate of #220


500 internal error - cPanel version 68.0.23

Hi
This error has been shown after install plugin and go to WHM>Plugins > Let's Encrypt :
Internal Server Error
500
No response from subprocess (/usr/local/cpanel/whostmgr/docroot/cgi/letsencrypt/letsencrypt.pl): The subprocess reported error number<PHONE_NUMBER>4 when it ended.
How can I solve? already tried to unistall and reinstall and problem has not been solved.

How do we uninstall this?

Hi,
This fixed my issue:
Login WHM > Tweak Setting > Security > Allow deprecated WHM accesshash authentication > Enable ( On )


Classifier-related data processing

AS A Product Owner
I WANT TO have data manipulation for the Classifier covered
SO THAT different relevant systems could be integrated into the Classifier
Acceptance Criteria

[ ] #20
[ ] #16
[ ] #30
[ ] #89
[ ] #107

Remove #90 as it's been covered as part of other similar, already groomed issues.


The link for System.Transactions is wrong

Hi Guys,
In the documentation listed here: https://blogs.msdn.microsoft.com/dotnet/2018/05/30/announcing-net-core-2-1/
the link to System.Transactions points to Querytypes.
Kindly resolve

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: ace630fc-7310-10b7-39bb-26fcfe3f3950
Version Independent ID: dbe96b32-0589-0f8c-6558-11a065d84dff
Content: Query Types - EF Core
Content Source: entity-framework/core/modeling/query-types.md
Product: entity-framework
GitHub Login: @anpete
Microsoft Alias: anpete

Blog link: https://blogs.msdn.microsoft.com/dotnet/2018/05/30/announcing-entity-framework-core-2-1/
@richlander Can you give access to @divega so he can fix this in the blog?

The blog post is now updated.


On Windows, the sidebar needs to be widened to accomodate for the width of the buttons

https://imgur.com/a/RzMmcTr

Fixed in dac6c23

Fixed in dac6c23


UI is passing incorrect values for EKS custom node group node roles

Setup

Rancher version: v2.7-head
Browser type & version: Safari

Describe the bug

When testing the custom node group node role feature in EKS for issue https://github.com/rancher/dashboard/issues/4568, different rand strings get passed to the backend for each custom node role selected. This results in a AccessDeniedException: Cross-account pass role is not allowed getting thrown on the CreateNodeGroup call from EKS because EKS sees that the node role specified was not created in this AWS account.
To Reproduce

Run Rancher v2.7 (or use dev rainbow v2.7)
Add EKS creds
Create an EKS cluster with a non-default custom node role for a 2-count node group
Check out config.Spec.NodeGroups[0].NodeRole in the cluster mgmt object in the Rancher UI. It will have a string that looks vaguely like an AWS access key, but not the role

The eks operator are spammed with logs
ERRO[1961] error syncing 'cattle-global-data/c-gvrl4': handler eks-controller: AccessDeniedException: Cross-account pass role is not allowed., requeuing
ERRO[1961] Error removing metadata from failure message: message body not formatted as expected

Result
Expected Result

The NodeRole should've been ablender-test-custom-NodeInstanceRole which was the custom role I created in EKS but that value did not show up.

Note: Also, from the test plan, the mock value I sent to EKS when backend testing was arn:aws:iam::<AWS account ID>:role/ablender-2nodegroups-node-instanc-NodeInstanceRole-SBF895G87LLA so this entire string needs to be sent for the role to be applied correctly. Only the role title can be selected. We don't want the pre-str to show up in the ui because that is sensitive info so this may need a minor update on the backend to close that gap.

FYI @nwmac @gaktive

Ticket #7754 - Test Results - ✅
With Docker on a single-node instance:
Verified on rancher v2.7-e54432ebcfba5cfdf92cf055b89a7ebff2537ef7-head:
Testing was conducted in parity w/ related rancher/issue/29071.
Test Scenarios + Results may be viewed here: https://github.com/rancher/rancher/issues/29071#issuecomment-1379638475
All scenarios pass ✅; as expected
AccessDeniedException: Cross-account pass role is not allowed - this error is no longer seen; all roles accurately represented in YAML


Bug: plugin tries to modify frozen data

Describe the bug
When supplying charts with a frozen dataset, this plugin uses dataPoint objects given in the dataset. It then tries to overwrite x or y of this frozen object (see lines 150 and 155 of index.js), leading to an error.
To Reproduce
https://codesandbox.io/s/react-chartjs-2-line-chart-example-forked-6fq13e
Expected behavior
If we return false from the callback, the plugin shouldn't modify the existing data. Thus the dataPoint objects need to be copied instead of modified directly.
https://github.com/chrispahm/chartjs-plugin-dragdata/blob/ce6d694f8a16a8d84436545186b07765bbd7c3c7/src/index.js#L150
https://github.com/chrispahm/chartjs-plugin-dragdata/blob/ce6d694f8a16a8d84436545186b07765bbd7c3c7/src/index.js#L155

On further thought, this behaviour leads to another issue:
As you can see in this codesandbox, even though we return false from the callback, the point still gets changed. The dataPoint is updated inside calcPosition, which gets called before the callback. So we can't disable this automatic update, even when returning false from the callback.

Hey @rohrz4nge,
Thanks a lot for investigating and even creating a fix in #97.
I'm quite behind in reviewing PR's, just wanted to let you know that I have it on my todo!

Thanks @rohrz4nge, we will have this in 2.3.0.

Fixed by #97


This script doesn't work on LG Smart TV

Hi, im using this script to create a mini widgets to display some weather places on a dashboard that i use to present information on the LG Smart TV, it uses Netcast 4.0.
(ref http://developer.lge.com/webOSTV/discover/webostv-vs-netcast/).
I not a very dev person, but somehow i created an HTML Dashboard to present videos, slide news, dollar conversion, weather. Last time i used "zweatherfeed" script, but Yahoo had some changes and this is no longer working. So googl'n i found this SimpleWeather that is awesome, easy to configure. But this SmartTv i think cant deploy the jquery or some code.
Cheers!

Honestly I'm not familiar with the smart TV or Netcast. Your best bet would be posting over on http://stackoverflow.com/ to get help from those who do have experience with it.


Run pre-commit with GitHub Actions

Running pre-commit with GitHub Actions now gives us more tests and coverage
Remove duplicate GitHub Actions for merge conflicts and trailing whitespace
Remove duplicate checks for markdownlint and yamllint from the GitHub Super-Linter
Add new custom pre-commit hook running with a shell script to sort alphabetically and uniquify codespell.txt
Add new pre-commit hook to check spelling with codespell
https://github.com/codespell-project/codespell

I have removed the conflicts now.  Sorry for the delay.
Ready for review now @matz


Fix BOM issue

Had a quick play and this is what I have, works for me 🤷
Fix for #21

You wrote many lines just to warn the user that there is a BOM header, right?
If we add to open() the encoding='utf-8-sig' then it works for all files, with and without BOM header.
Question is: BOM doesn't seem to be an error so I'd just not warn users at all and handle it.
The files cjio will save will always be without the BOM.
Agreed?

I agree that if you just open it with encoding='utf-8-sig' it's fine and any output from cjio will not have it. At the same time, technically speaking, a BOM is not allowed and if the user only uses cjio for info, for example, they'll never know that they have an "illegal" JSON which can cause issues later down the line. Anyways I don't insist, I just think it's a useful warning.

But my question is: is it really "illegal"?

According to this passionate answer, yes 😅

OK instead of asking you I went looking for the answer:
from the official specs:
> Implementations MUST NOT add a byte order mark to the beginning of a JSON text.  In the interests of interoperability, implementations that parse JSON texts MAY ignore the presence of a byte order mark rather than treating it as an error.

Thanks for having faith in me 😏

well was more meant as I should check myself and not ask you to...
but anyway, I'll just add the handling and make it silent, "in the interests of interoperability", innit?

Cool 👍

added to merge() too baf169a2a283cae4bf9f9b9e26ff83b51646ff7e


[core] Exclude undefined className from render fn props

Fixes https://github.com/mui/base-ui/issues/993

[x] I have followed (at least) the PR section of the contributing guide.

Test would be nice

Added ~


[incubator/cassandra] Pods CrashLoopBackOff Using configmap

Describe the bug
When adding the following config map:
configOverrides:
  cassandra.yaml: |
    auto_bootstrap: false
    cluster_name: staging
    endpoint_snitch: GossipingPropertyFileSnitch

Pods will not start and log the following output:
chown: changing ownership of '/etc/cassandra/cassandra.yaml': Read-only file system
Version of Helm and Kubernetes:
helm 2.11
kubernetes: 1.11.5
Which chart:
incubator/cassandra
What happened:
Added config map which caused pods to crash on start
What you expected to happen:
Config map to be added and successfully start the pod.
How to reproduce it (as minimally and precisely as possible):
Add something similar to the configOverrides:
configOverrides:
  cassandra.yaml: |
    auto_bootstrap: false
    cluster_name: staging
    endpoint_snitch: GossipingPropertyFileSnitch

Anything else we need to know:

Sorry to re-open this issue, but it seems valid. I'm having the same problem and not sure what's the solution for it?

I believe this is happening because the chart is trying to mount the overriden cassandra.yaml as a config map into the pod's filesystem. Then as Cassandra tries to start it detects that the file has read-only permissions (kubernetes enforces that for config maps after v1.9.4 I think) and stops.
I don't have a solution unfortunately.

This bug is affecting me as well, and I would like to suggest it be reopened.  @hampos is correct, as far as I can tell.  However, there are other issues, which I'd like to bring up.

Every config file must be provided if using configOverrides.  This is because the entire directory is deleted if you mount configmaps as files in that directory.
Certain config files cannot be provided because of their names containing an underscore.  For example, commitlog_archiving.properties will cause an error at deploy-time.

I think a better solution is to mount the configmaps as a volume in some scratch directory and then use an init container to copy the ones that are present over to the regular read/write cassandra config directory, with a transparent renaming scheme to deal with the underscores.  This would require changes to the chart's templates and cannot be achieved using the chart as-is.
I could take a crack at doing this and make a pull request, provided this sketch of a design is approved.

Please note it is still very painful to override just one or two parameters of cassandra.yaml...
As mentioned by @Fizzixnerd we have to copy/paste ALL the config files already present in /etc/cassandra/ into configOverrides to build the full configmap, and allows cassandra to start.
It would be good to only replace the overridden files, and keep the other ones.
Even better, only replace the overridden properties values, at least for properties files..


Mouse input doesn't work

Which operating system does the issue occur on?
Void Linux
If on linux, are you using X11 or Wayland?
X11
Which version of Alacritty?
Master (f298ebb2179eff947cdb9cb7a4bd96e9739eac5c)
Applications which accept mouse input either don't react at all or react in a broken way. For example: Cmus and Ranger; both support mouse input for selecting items in their interfaces but this doesn't work in a bare Alacritty terminal. However, running tmux inside Alacritty and using any mouse-enabled application through tmux, mouse input works perfectly fine.
It seems Alacritty is sending input, but incorrect input? In Neovim, with mouse input enabled, clicking a line shows 23m in the command window in the bottom right (where "23" corresponds to the line being selected). And does nothing else.
What's strange is I've been using Alacritty for about 3 weeks and I had this problem when I first installed it, but it went away after a few days and I have no idea what changed. Alacritty's been working fine until a few days ago and, again, I have no idea what changed.
Oh and for comparison, xterm works as expected on my machine (without tmux).

Does https://github.com/jwilm/alacritty/pull/1141 fix this?

#1141 does not fix the problem.

I'll look into this once I've got the time, might be able to include it into #1141 if the fix isn't too complicated.

@terrybrashaw Please try running #1141 again and make sure you remember to recompile it before executing the binary. Inside ranger mouse support should work with #1141.

I've tested cmus too and it doesn't work in xterm either, so it seems like mouse is not (or at least not properly) supported inside cmus.

Oh no, my mistake. I assumed the changes were merged to your master branch.
#1141 does fix the problem. :tada:
Sorry @chrisduerr!

No problem, glad this PR was able to help you! :)

Does it work inside of xterm but not alacritty (with the PR)? Maybe I'm just using cmus wrong, I haven't used it before.

Correct. In fact, both Cmus and Ranger work as expected inside xterm, but not Alacritty without #1141.
However, Neovim still doesn't work inside Alacritty even with #1141. But Neovim doesn't work inside xterm either.

Also, you have to :set mouse=true in cmus for mouse input.

You have to use :set mouse=a to make xterm or alacritty work with neovim.
Looks like everything is working then when #1141 is merged. Awesome!

Hmm...I've got :set mouse=a in Neovim and it doesn't work in Alacritty or xterm on my machine.
Neovim works in either one through tmux though.

I confirm, using pull request #1141, mouse doesn't work in either tmux nor neovim nor neovim in tmux.

That's odd, I tested it and it worked at one point, I've probably made a change to break it again, thanks for the notice.

Turns out not only does 1000 activate mouse clicks, but 1002 does too, should be fixed now.

Neovim, Cmus and Ranger all work inside Tmux with those changes but now Cmus and Ranger are broken in bare Alacritty.
Here's what's happening on my end: https://www.youtube.com/watch?v=p99O8V0QWag

I've tested the latest commit in that PR with ranger, htop, vim and kakoune.
All of them seem to work just fine.
Please make sure you're testing the commit 237ac468750d9f536819dbd2d973c1598c6074b7.

Looks good.
Neovim in Alacritty without Tmux is still broken but at least most things work now.

If you use :set mouse=a in neovim with the last commit of that PR neovim should work. I don't use tmux and it works great for me, make sure your neovim config isn't messing with things or something like that.
It should all be good.

I have set mouse=a in my nvim config and I've tried manually setting it as well. Still broken.
I show what's happening in nvim inside and outside of tmux here: https://youtu.be/p99O8V0QWag?t=1m25s
That part is still accurate even on https://github.com/jwilm/alacritty/pull/1141/commits/237ac468750d9f536819dbd2d973c1598c6074b7

Now everything works for me as well.

Something on my machine is messing with nvim then.
This issue can be closed when https://github.com/jwilm/alacritty/pull/1141 is pulled. Good work @chrisduerr!

@terrybrashaw try launching neovim with vim -u NORC and then manually do :set mouse=a to verify that nothing in your config / your plugins mess with your vim =)

@NickeZ Tried that already with the same result. :/
Maybe I need nightly neovim.

Problem solved. I needed nightly neovim, or there was an optional dependency left out in my package manager's version of neovim. :D

Is there any issue left @terrybrashaw? If not, please close this issue.

If it's merged into jwilm/alacritty, then all's good. :+1:

work in neovim but not in vim 8.1

if has('mouse')
    set mouse=a
endif

if !has('nvim')
  set ttymouse=xterm2
endif


Browse Dataset - Back to search results

Describe the enhancement
Feedback Véronique:
I have a question about the "Back to the list" button. After selecting a dataset in a result list, I would like to be able to return to that result list and not to the list of all datasets. But currently the button leads to the list of all datasets. I'm annoyed to have to redo my search. If I am interested in the list of all datasets, I can always delete my search criteria.
Expected behavior
User would like to get back to the search results list and not the full dataset list

I can't reproduce the problem ?
https://user-images.githubusercontent.com/465582/152537777-9431660c-fdfd-43ae-91e5-ee4407ac6459.mp4

@ptbrowne just received this feedback from Véronique:
Sorry Annina Walker I made a confusion with the next step in which you can choose another dataset.

I ask me if it wouldn't make sense to go back to the result list at this step as well.
I am currently testing different MFM-U cubes in INT and have this reflex to want to go back to my result list when I am already at the step of choosing the graph. but I admit that I am not a standard user as I am testing.
So I don't want to disturb your whole concept and I leave it to you to decide.

I think it should stay as it is and just go back to the complete data set list. Keeping the search results at this point I'd find a bit confusing.

(As a work around, the back button of the browser works here)
On 8 February 2022 at 10:00:42, AnninaWalker @.***)
wrote:
I think it should stay as it is and just go back to the complete data set
list. Keeping the search results at this point I'd find a bit confusing.
—
Reply to this email directly, view it on GitHub
https://github.com/visualize-admin/visualization-tool/issues/320#issuecomment-1032366970,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AADRVLVVGHHBHHPVXHUOCBTU2DLTVANCNFSM5NOG7TNA
.
You are receiving this because you were mentioned.Message ID:
@.***>

Thanks for your feedback. I'll close this ticket for now


Ability to get cast and directors as hashes

Added a way to get actor and director arrays of hashes.

Thanks for this. I'll review it later this week.


HV-1529 Add dynamic payload to HibernateConstraintValidator

@marko-bekhta and @gsmet probably are the persons who should take a look at this :wink:
All the information can be found here: https://hibernate.atlassian.net/browse/HV-1529
Basically we can now pass a dynamic payload to a (Hibernate)ConstraintValidator via:
someValidator
    .unwrap(ValidatorImpl.class)
    .withDynamicConstraintValidatorInitializationPayload(payloadObject)
    .validate(objectToValidate)

And retrieve it via getDynamicPayload:
public class MyFutureValidator implements HibernateConstraintValidator<MyFuture, Instant> {

	private SomeType dynamicPayload;

	@Override
	public void initialize(ConstraintDescriptor<MyFuture> constraintDescriptor,
			HibernateConstraintValidatorInitializationContext initializationContext) {
		this.dynamicPayload = initializationContext.getDynamicPayload(SomeType.class);
	}

	@Override
	public boolean isValid(Instant instant, ConstraintValidatorContext constraintContext) {
		// Here I can use the dynamic payload now
		dynamicPayload.getSomeData();
		//...
	}
}

Hi @mkurz, a couple of comments/questions:

What's the use case this is trying to address? In the issue you mention a country/language, but that's where the message interpolator and its locale handling comes in. The code example shows a temporal constraint, but no actual usage of the proposed feature.
j.v.Validator is not meant to be recreated for every call to validate(), which I think your proposal implies. Instead it seems a context parameter would have to be added to the validate() method.
ValidatorImpl is an internal class, i.e. it shouldn't be exposed to clients. So if we wanted to provide some additional functionality, we'd have to do so via a new interface which one then can unwrap to.

Note there are two existing ways for passing in contextual information:

Use a class-level constraint, allowing you to obtain e.g. a language from the bean hosting the constrained property; admittedly that may be complex, but then again it'd help to better understand the usecase this is about.
Use dependency injection into constraint validators via a custom ConstraintValidatorFactory, which e.g. returns CDI or Spring enabled validator instances. They could have request-scoped contextual information injected, e.g. the locale of the current request's users.

@gunnarmorling

What's the use case this is trying to address?

Matthias gave an example in the JIRA issue: "think of zip codes which differ for each country".

j.v.Validator is not meant to be recreated for every call to validate(), which I think your proposal implies. Instead it seems a context parameter would have to be added to the validate() method.

That's not what the PR does (and it indeed introduces concurrency issues I mentioned in my review). Frankly, taking a look at the ValidatorImpl constructor, I don't think it would be that bad to instantiate a Validator for each call. And we could imagine a CHM of Validator per country code if required.
Do you think it would be better to add a parameter to the various validate...() calls? I don't like that very much.

ValidatorImpl is an internal class, i.e. it shouldn't be exposed to clients. So if we wanted to provide some additional functionality, we'd have to do so via a new interface which one then can unwrap to.

Yup, I didn't mention it because we can't introduce the feature here anyway (concurrency issues).

Btw, I think it makes sense to consider it Validator scoped.
If the same user makes several validate() calls at once, I would expect them to be run with the same payload.

"think of zip codes which differ for each country".

Ok, so the requirement is then:
public class Address {
    @ValidZipCode // acts differently based on the country
    String zipCode;

    Country country;

?
As said, I think the easiest would be to use a class-level constraint or context injection into the validator then.

Do you think it would be better to add a parameter to the various validate...() calls? I don't like that very much.

Actually, the problem with either approach is that the user typically isn't in the business of obtaining a validator (in the context of one request/transaction etc.) nor of calling validate().
Instead this will be done by some framework for them. I.e. usually passing in such context will not be available to them, whereas the other two approaches allow to get hold of contextual information also in such managed environment.
In a way it's related to BVAL-237, too, i.e. the idea of making the root or leaf bean (or at least their properties in a detyped manner) available to constraint validators.

Btw. there already is a way for passing Validator-scoped metadata: ValidatorFactory#usingContext(). HibernateValidatorContext could be expanded to allow for the propagation of arbitrary data, but as said I'm not convinced that this helps the discussed use case much.

Btw. there already is a way for passing Validator-scoped metadata: ValidatorFactory#usingContext(). HibernateValidatorContext could be expanded to allow for the propagation of arbitrary data, but as said I'm not convinced that this helps the discussed use case much.

Yeah, that's exactly what I proposed in my review :).

@gunnarmorling I thought about it a bit more and I don't think having the ability to pass some context to constraint validators is useless.
It might be handy to manage differences between 2 environments or 2 different apps using the same jars.
Having them at VF and context level would be enough.
@mkurz could you give us more details about your use case? As you might have noticed, @gunnarmorling is a bit skeptic about the usefulness of such addition so having more details on why it's not practical for you to use class level constraints and some data in the model would help.
Thanks!

@gsmet and @gunnarmorling thank you both very much for your comprehensive replies. I really appreciate that.
So what is my use case?
In my free time I work as an open source contributor for the Play Framework. Right now Play stores various information about a request in a play.mvc.Http.Context object. That would be e.g. the locale of the current request (or the one the user has set explicit via a cookie) and various other things, e.g. there is an args map in which a framework user can put various other stuff inside that context.
Right now that http-context is stored in a ThreadLocal and therefore we can access the current http-context from basically everywhere, including the isValid method of a ConstraintValidator.
However in near future that ThreadLocal will be removed an that http-context has to be passed to every method were it is needed. That means we somehow have to pass that http-context (or just parts of it, e.g. the locale) inside the isValid method because right now we use e.g. the locale of the current request for validation (like the zip code example @gunnarmorling gave). And therefore that has to be done for each request - therefore it has to be "dynamic".
That is how hibernate-validator is set up in Play righ now
We bind the components we need via dependency injection. We set up a Validator Factory that provides us a new validator each time we need one. (I know now these validators could be cached, but that is not the point here. I will probably add caching soon. Because I didn't know caching them is allowed is why I stumpled into that concurrency issues in my pull request....) The ConstraintValidatorFactory simply returns us a new instance of the desired constraint.
So now a Validator gets injected into the FormFactory here and eventually we call the validate(...) method that javax.validation.Validator (we don't unwrap it right now) provides here.
Actually at first I was thinking the same like what @gunnarmorling proposed - to add a parameter to all the various (unwrapped) validate...() calls. However I also don't like that approach, that is why I came up with the with...Dynamic...Payload() method.
About the suggestions @gunnarmorling mentioned

Using a class-level constraint
I am aware of that feature, however I don't think this is what we are looking for here. The only way I can think of to get that working is that a user would have to pollute his/her form classes with "special" properties into which the framework sets e.g. the locale. (A form class in Play is simply a POJO that represents a HTML form on the server side and that uses bean validation/hibernate constraints annotations for validation). However that would mean the framework would have to provide the user some kind of contract of how he/she has to set up that "special" properties (which values will later set by the framework) e.g. the user woud have to sub-class his/her forms of a specific super-class that the framework provides and where the locale can be set on... I really don't like that. For users, nothing should change and everything should just work out of the box as simple as possible (without a framework user having taking care of this)
So I think with the design Play is following this approach isn't really working.

Request-scoped DI
Play wont work with request-scoped dependencies (right now). See https://github.com/playframework/playframework/pull/6798 - it was closed this year and it looks like that wont happen. So that is also not an option for us.

Status quo of this pull request
(First of all I had to rebase against the latest master because of the changes introduces for HV-1531).
I updated the pull request as suggested so the dynamic payload is now at ValidatorFactory and HibernateValidatorContext level. As far as I can tell in Play we now would have to inject the ValidatorFactory instead of a Validator itself into the FormFactory and then just before calling validate(...) unwrap the context and set the http-context (or parts of it): validatorFactory.usingContext().dynamicPayload(ctx.getLocale()).getValidator() like shown in the docs.
I think that should work for us.
However I just set up another branch which - like my original idea - adds a withConstraintValidatorDynamicPayload (on top of that pull request here) which now returns a new validator instance - which is basically a copy of the origin one - but with the given payload set. For that I just added a private ValidatorImpl() constructor and a copy constructor for ValidatorScopedContext. I think that way concurrency isn't a problem anymore.
This way setting a dynamic payload is really dynamic. You can just "copy" your validators and set the payload you need. That would also work when caching the validators. I think this is what we are really looking for here for the Play Framework.
What do you think about all of this? Am I missing something?
I really would like to find a solution for this and get it into one of the next HV releases. Frankly I think that stuff makes sense, not just for Play.

This way setting a dynamic payload is really dynamic. You can just "copy" your validators and set the payload you need. That would also work when caching the validators. I think this is what we are really looking for here for the Play Framework.

I don't understand what is the value of that. I think it's better to pass the ValidatorFactory and create new validators from it using a context. Which benefits do you see in your approach?
You could either have a Validator cache per locale, or at least try to reuse the same Validator for the whole request.

I don't understand what is the value of that. I think it's better to pass the ValidatorFactory and create new validators from it using a context. Which benefits do you see in your approach?

In case we don't pass a locale as dynamic payload but e.g. the whole play request context which could contain different data on each request we can't cache that validator like we could when just passing the locale as payload. So when no caching is possible, "copying" a validator and passing the payload is cheaper than using ValidatorFactory.getValidator() each time? Only of course if we could cache a "base" Validator which would be copied each time. What do you think? Or am I wrong?

@mkurz just to let you know that I'm thinking about this. Will get back to you shortly.

@gsmet I finally found time to update this pull request. Please check the commits I added (the last one probably is the important one).
And about commit f0418e0 - is that what you meant by "...I think we can reduce the overhead of creating a brand new Validator a bit by making the ValidationOrderGenerator global to the ValidatorFactory..."?
Also CI does not pass. Do you know what's going on? Can you help out and checkout my branch and see if you get it working? Thanks!

@mkurz Hi, about that build failure I think it's because of this error in javadoc:
[ERROR] /var/lib/jenkins/workspace/hibernate-validator-PR/distribution/../engine/src/main/java/org/hibernate/validator/HibernateValidatorConfiguration.java:305: error: @param name not found

there's a mismatch between the param name in javadoc dynamicPayload and the name of the actual param constraintValidatorPayload

@marko-bekhta Thanks! I fixed the problem (squashed the fix into the last commit were it belongs)

Thanks for cleaning up my code! Great work!

There is one BIG thing missing: we need tests. I let you add them?

I can have a look, but I don't know when I find time. Maybe this weekend? But I can't promise.

I can have a look, but I don't know when I find time. Maybe this weekend? But I can't promise.

Well, you're the one who wants this in ;).
I think it's the only piece missing. It should be added in the org.hibernate.validator.test.internal.constraintvalidators package (at the root). You can take a look at TemporalValidationToleranceTest to see how you can initialize the validators in the test (yours will be a lot simpler, it's just a matter of checking that the payload is passed to the constraint validator when we use the different ways to pass a payload).
I think the easiest way to do this is to:

create a specific constraint that takes a class as a parameter (this way you will be able to inject different payloads and check that the payload has the right class - might be useful if you want to test that the one of the VC overrides the one of the VF)
declare a custom validator testing the payload in src/test/resources/META-INF/services/javax.validation.ConstraintValidator
(see the classes in the same package as ConstraintDefinitionContributorTest)

I don't think it will take a lot of time. Feel free to ask for help if you have any issue, I'll help!

Found a better way to declare your validator, just use this when initializing your Validator (it will avoid declaring another global validator):
HibernateValidatorConfiguration configuration = Validation
				.byProvider( HibernateValidator.class )
				.configure();

ConstraintMapping constraintMapping = configuration.createConstraintMapping();
constraintMapping
		.constraintDefinition( YourConstraint.class )
		.validatedBy( YourConstraintValidatorTestingThePayload.class );

configuration.addMapping( constraintMapping );

@gsmet Please have a look at my last commit and let me know what you think :wink:

I had to rebase, build passes now.

@gsmet Updated! Removed final and the tab. Please check the testPayloadViolation test.
BTW: Seems link travis doesn't start...

Alright, it's green now....

@mkurz thanks, I'll take it from here (I would like to add something to the documentation about this feature but I still need to figure out where).
I'll try to get this done this week so that we can merge it before the end of the week.

@gsmet Great! Thank you very much for your help :+1: Looking forward to the next release :stuck_out_tongue:

@gunnarmorling @mkurz I added a commit with some documentation. Feedback welcome.
Once the dust is settled on the documentation, we can (finally) merge this feature.
Thanks.

@gsmet Had a quick look at the documentation you added, LGTM. :shipit:

Rebased and applied. Also added a commit for some JavaDoc adjustments. Thanks, everyone!

:tada: Woohoo! Thanks everyone for your feedback and the time you invested! You do a real great job :+1: :smile:

@mkurz thanks for your contribution.

@mkurz just a heads up that we released 6.0.8.Final today with the constraint validator payload feature. Time to use in the Play framework :).

@gsmet Thanks for letting me know! Hopefully next week I will find time to set up a pull request for Play :+1:

@gsmet I tried to make use the hibernate constraint validator payload feature within the Play Framework this week, however I ran into an issue with the caching behaviour of HibernateConstraintValidator instances. I am pretty sure it's broken.
See https://hibernate.atlassian.net/browse/HV-1589 and for a fix #939.


pipenv fails to find venv unless parent python in path

Be sure to check the existing issues (both open and closed!).
Describe the issue briefly here.
pipenv can't find the virtualenv it built unless the version of python the virtual env was created from is in the current path.
Please run $ python -m pipenv.help, and paste the results here.
$ python -m pipenv.help output
Pipenv version: '11.10.0'
Pipenv location: '/usr/local/lib/python3.5/dist-packages/pipenv'
Python location: '/usr/bin/python3'
Other Python installations in PATH:

2.7: /usr/bin/python2.7

2.7: /usr/bin/python2.7

3.5: /usr/bin/python3.5m

3.5: /usr/bin/python3.5

2.7.12: /usr/bin/python

2.7.12: /usr/bin/python2

3.5.2: /usr/bin/python3

PEP 508 Information:
{'implementation_name': 'cpython',
 'implementation_version': '3.5.2',
 'os_name': 'posix',
 'platform_machine': 'x86_64',
 'platform_python_implementation': 'CPython',
 'platform_release': '4.4.0-17134-Microsoft',
 'platform_system': 'Linux',
 'platform_version': '#81-Microsoft Sun May 20 01:14:00 PST 2018',
 'python_full_version': '3.5.2',
 'python_version': '3.5',
 'sys_platform': 'linux'}

System environment variables:

LS_COLORS
LANG
TMUX_PANE
MOZ_USER
PYTHONDONTWRITEBYTECODE
XDG_DATA_DIRS
PWD
PATH
SHLVL
LESSCLOSE
NAME
LOGNAME
TMUX
DISPLAY
LESSOPEN
HISTCONTROL
SHELL
_
TMUX_PLUGIN_MANAGER_PATH
BASH_FUNC_tmux%%
EDITOR
PYTHONUNBUFFERED
USER
TERM
HOME
HOSTTYPE
PASTEBIN_NAME
SSH_AUTH_SOCK
SSH_AGENT_PID
GOPATH
PIP_PYTHON_PATH
VISUAL
PIP_REQUIRE_VIRTUALENV

Pipenv–specific environment variables:
Debug–specific environment variables:

PATH: /home/hwine/.cargo/bin:/home/hwine/bin:/home/hwine/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/mnt/c/Program Files/Docker/Docker/resources/bin:/mnt/c/Windows/System32:/mnt/c/Windows:/mnt/c/Windows/System32/wbem:/mnt/c/Windows/System32/WindowsPowerShell/v1.0:/mnt/c/Windows/System32/OpenSSH:/mnt/c/Users/Hal Wine/AppData/Local/Microsoft/WindowsApps:/mnt/c/Users/Hal Wine/AppData/Local/Keybase:/mnt/c/Program Files/Microsoft VS Code/bin:/usr/local/bin:/snap/bin
SHELL: /bin/bash
EDITOR: nvim
LANG: en_US.UTF-8
PWD: /home/hwine

Expected result
pipenv shell should work regardless of which python is in the path.
Actual result
E.g: after a pipenv environment has been created, and a fresh shell (login) initiated, the virtualenv can not be found:
$ pipenv shell
Warning: Python 3.6 was not found on your system…
You can specify specific versions of Python with:
  $ pipenv --python path/to/python
1 [hwine@hwine-surface MY_PROJECT]
$ pipenv --venv
No virtualenv has been created for this project yet!
1 [hwine@hwine-surface MY_PROJECT]

In fact, the virtualenv is exactly where it should be:
$ ~/.ve/MY_PROJECT-j72jD_YQ/bin/python --version
Python 3.6.4

But it can't be found until the parent python is available in the path (I use pyenv, but only activate it when I need a non-system python in my path)
$ use Pyenv
source /home/hwine/bin/usePyenv
0 [hwine@hwine-surface MY_PROJECT]
$ pipenv --venv
/home/hwine/.ve/MY_PROJECT-j72jD_YQ
0 [hwine@hwine-surface MY_PROJECT]
$ pipenv shell
Spawning environment shell (/bin/bash). Use 'exit' to leave.
. /home/hwine/.ve/MY_PROJECT-j72jD_YQ/bin/activate

My expectation when I use a virtualenv is that only the virtualenv need be in my path, which is usually accomplished by sourcing the activate script (as pipenv shell does above). Requiring the parent python to be in the path just to activate the virtualenv is a new hurdle I'd prefer not to climb.
Steps to replicate

create a pipenv environment using a non-system python (called the "parent python" below)
start a new shell (login)
ensure the path does not contain the parent python
attempt to run pipenv shell

Hmm, I personally does not have Pipenv’s parent Python in my path, but never ran into any problems. But I don’t usually pipenv shell often either, so it’s hard to say.
To clarify:

What platform are you on? (I’m guessing it is WSL on Windows? What distribution?)
How do you install Pipenv’s parent Python and Pipenv itself?
Do things other than shell work?

Pipenv uses pew on the backend to enter a virtualenv. As a step during the process of entering a shell session pipenv ensures that the project and the virtualenv exist. Part of this involves Pipfile validation, but if it can’t find the python version specified I guess it gets stuck.
I’m not totally sure what the implications of changing this behavior would be, but I’m guessing they are probably more significant than it seems at first glance. I’d recommend keeping pyenv on your path even if it’s at the back while we untangle this.
As an FYI you can use pyenv all the time and tell it to globally prefer the system python

Accept

I actually can't reproduce this, and I noticed you are on a outdated version of pipenv.  I saw version 11.10 mentioned, so you probably should upgrade that.  Closing for now but let us know if this persists

ftr: after upgrade to pipenv, version 2018.05.18, I could not reproduce. \o/


Update from template - test fixes and PR check script

Pulls in changes from the template repository to:

Fix Jest config and ensure all tests pass
Add a script for a GitHub Action to run linting, project structure check, and unit tests on pull requests

Wrong repo 🤦🏻♀


v1.5.0

linter thorough is taking hours. running in background. dont necessarily see this as a blocker to release.


[CSL-255] Add block list request endpoint

@georgeee
Blocks are now getting spread via SendBlockHeader messages. Though for client-like nodes, which have no ports open we won't have such capability. So we new endpoint, which would serve blockchain parts:
Add new enpoint

Input param: head block (optional)
If client wants to acquire previous blocks, ending with some known head block, it specifies this param

Input param: bottom block (optional)
If client wants to acquire subsequent blocks, starting with some known bottom block, it specifies this param

Input param: length (optional, default 10, max 300)
Maximal length of output

Output: list of block head hashes

Modify node behavior
If node doesn't receive blocks for some time (timeout is to be specified in constants.yaml), it queries neighbors for blocks by itself, using this new endpoint

@flyingleafe
Node behavior on getting queried part of blockchain is to be discussed. How the node should merge this blockchain to its existing one?
I might suggest the following. We say that ''last block'' is the lowest block in given blockchain part, and we say that ''bottom block'' is a block previous to ''last block''.

Node '''A''' requests from node '''B''' a blockchain part whose ''bottom block'' is ''k+1''-th deep block on current best blockchain. That way the requested blockchain part, if succeeded to be fetched, is guaranteed to be a valid fork of current best chain.

Node '''B''' looks for requested bottom block in its best chain. If it manages to find it, then it sends back a part of blockchain of length length, starting with the node which follows given ''bottom block''. If it doesn't, then it does nothing.

If node '''A''' have successfully received a new chain part, then we treat different suffixes of new chain (suffNew) and current best chain (suffOld) in the following way:
2.1) If suffNew is '''significantly longer''' than suffOld, then we replace suffOld with suffNew.
2.2) If it's not, than start an alternative chain with suffNew.

Also, if we already have several alternative branches, then we should probably match received chain part against all of them, repeating the step (2) N times.

Actually, the case when no node has answered with a valid blockchain part shouldn't occur, because no forks deeper than ''k'' should exist, and requested bottom block should be present in every node's blockchain. However, there might be some network/load problems which prevented the answer to be delivered, so node '''A''' should simply repeat its request after some timeout.

Some additional suggestions:

Seems like ''head block'' input parameter is useless, I can't make up a meaningful use case for it.
The output should probably contain also hasMore flag, or even blocksLeft counter, which indicate, if some blocks are still yet to send/how much of them.

Things which are unclear to me:

Notion of being '''signigicantly longer''' is yet to be defined; e.g. everything is significantly longer than suffix of length 0, obviously. Also it's clear that if length suffNew >= length suffOld + k, then suffNew is significantly longer - suffOld is too old to survive in blockchain. But what about other cases? e. g. if suffNew has length 5, and suffOld has length 1, should we replace suffOld with suffNew right away?
When should we actually merge all the altchains we spawned after receiving sereval responses from the nodes? And how should we do it? Should we try to make additional requests for alternative chains, if the last adopted response for it stated that there's more blocks to send? Or should we try to merge this chain inb4?

@gromak
Hmmm, someone is already working on this issue :/
Ok, I will read it today.

@gromak

Seems like head block input parameter is useless, I can't make up a meaningful use case for it.
Bitcoin has it (optional too), I don't know whether it's really used for anything.
The output should probably contain also hasMore flag, or even blocksLeft counter, which indicate, if some blocks are still yet to send/how much of them.
Bitcoin doesn't have it. I suppose they just check whether result has limit blocks. If it does, then peer is considered to have more blocks. Probability of not having more blocks is very small, because limit is 500 (and 2000 for getheaders).

@georgeee

Some additional suggestions:

Seems like head block input parameter is useless, I can't make up a meaningful use case for it.
The output should probably contain also hasMore flag, or even blocksLeft counter, which indicate, if some blocks are still yet to send/how much of them.

Agree

@gromak
Regarding this issue in general.

This endpoint will specified in CSL-5. It will be similar to Bitcoin's version. In Bitcoin there are multiple locators (bottom blocks) and it's cool. Let's do it this way too. Also there are two endpoints: getblocks and getheaders. I haven't yet decided whether we need these two, but getheaders seems more useful (you propose getblocks). Also in Bitcoin there is no length parameter and I don't know whether it's useful just like head block. Unfortunately, I couldn't make significant progress with CSL-5, because I had to postpone it in favor of CSL-265.
I don't recommend you to implement it before we switch to RocksDB (and rewrite a lot of code). If priority of this issue is not too big, I want you to postpone it for a while and do CSL-5 and CSL-265. Probably CSL-5, because there are two people on CSL-265 already. But CSL-265 can be split into more people too.

@flyingleafe
Okay then, for now I'll push into master the stuff I already wrote and switch to another task.

@gromak
I suppose all 4 endpoints (GetHeaders, GetBlocks, Headers and Block) should be implemented within this issue, is it ok? Logic of GetHeaders and GetBlocks should be very similar, Headers and Block are needed to respond to these messages.

@gromak
At the same time processing of Block message is beyond this issue. Well, for Block message we already have handler. In this issue I only want handlers of GetHeaders and GetBlocks to be implemented.


Cannot clone a repository from within Sublime Text 3

Hi,
I Cannot clone a repository from within Sublime Text 3, from the PowerShell cloning works fine, what could be missing in my Sublime Text configuration? And I looked into the GitSavvy help, but there isn't a command like "git clone", what am I doing wrong?
Greetings
liszca

Hi @liszca thank you for reporting the issue; to help narrow it down, kindly provide more info:

Sublime Text version number
Git version number
OS type and version
A description of the problem.
Steps to reproduce, if possible
Do you see any error alerts?
Any sublime text console errors (hit ctrl+~)?
Please provide a GitSavvy debug log

Your hint with the console helped, the directory wasn't empty.


Typescript

When adding this lib to my project, I see no declaration file, therefor Im getting

These are the installed files (node_modules)

Help?

Alright, seems like the typings are not generated. I will investigate

v3.0.0-alpha.17 should fix this. Thanks for filling this issue

@JPeer264 Thanks for the quick response!
Looks good, works great :)

Glad to hear that 💯


IR Support for rgb_stereo_node

Added parameters for setting the brightness of the IR dot projector and flood light on the OAK-D-Pro.
Parameters can be set at launch and updated during runtime.

Example usage:
ros2 launch depthai_examples rgb_stereo_node.launch.py dotProjectormA:=200.0 floodLightmA:=200.0
Changing brightness during runtime:
ros2 param set /rgb_stereo_node dotProjectormA 250.0

Thanks Roni.
@roni-kreinin is it good to update the parameter like done here or a service would be better ?

Yep, this is the recommended way to update parameters at runtime. See https://docs.ros.org/en/galactic/Concepts/About-ROS-2-Parameters.html#manipulating-parameter-values-at-runtime

Please, add this to the rest examples, they are very fragmented, difficult chose some of them without lose basic options, like this one in example

Agreed. Ultimately it would be great to combine all of the existing nodes into a single customizable node.

Yes, I requested that for long time, just like realsenses.

Agreed. Ultimately it would be great to combine all of the existing nodes into a single customizable node.

Yes. I agree too. it is on my to-do list but I have way too many things on the list..  (Very likely my next priority after the release.)


fix rocketmq-proxy does not work properly in k8s nodePort mode

Make sure set the target branch to develop
What is the purpose of the change
  When deploying rocketmq in self-built k8s, if nodePort is used, if the port of nodePort is inconsistent with the port of proxy grpcServerPort, it will result in failure to obtain information normally from rocketmq-proxy
  This submission is to use the port that the addressList adds to address as the port that the user connects to endPoint, so that it can work compatible with the nodePort of k8s

Brief changelog
change  RouteActivity#convertToAddressList
XX
Verifying this change
You can compare the changed versions before and after. Build a k8s cluster by yourself, deploy a rocketmq cluster in it, use the nodePort mode of k8s, keep the port of nodePort mode different from the proxy grpcServerPort, and try to send and receive messages to verify
XXXX
Follow this checklist to help us incorporate your contribution quickly and easily. Notice, it would be helpful if you could finish the following 5 checklist(the last one is not necessary)before request the community to review your PR.

[x] Make sure there is a Github issue filed for the change (usually before you start working on it). Trivial changes like typos do not require a Github issue. Your pull request should address just this issue, without pulling in other changes - one PR resolves one issue.
[x] Format the pull request title like [ISSUE #123] Fix UnknownException when host config not exist. Each commit in the pull request should have a meaningful subject line and body.
[x] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
[x] Write necessary unit-test(over 80% coverage) to verify your logic correction, more mock a little better when cross module dependency exist. If the new feature or significant change is committed, please remember to add integration-test in test module.
[x] Run mvn -B clean apache-rat:check findbugs:findbugs checkstyle:checkstyle to make sure basic checks pass. Run mvn clean install -DskipITs to make sure unit-test pass. Run mvn clean test-compile failsafe:integration-test  to make sure integration-test pass.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

Codecov Report

Merging #6259 (dcfd2ab) into develop (236d4a1) will increase coverage by 0.00%.
The diff coverage is 33.33%.

@@            Coverage Diff             @@
##             develop    #6259   +/-   ##
==========================================
  Coverage      43.17%   43.18%
  Complexity      8849     8849
==========================================
  Files           1094     1094
  Lines          77192    77191    -1
  Branches       10068    10068
==========================================
+ Hits           33331    33336    +5
+ Misses         39691    39687    -4
+ Partials        4170     4168    -2

Impacted Files
Coverage Δ

...rg/apache/rocketmq/common/message/MessageType.java
0.00% <0.00%> (ø)

...he/rocketmq/proxy/grpc/v2/route/RouteActivity.java
91.89% <100.00%> (-0.06%)
:arrow_down:

...controller/impl/DefaultBrokerHeartbeatManager.java
82.27% <0.00%> (-3.80%)
:arrow_down:

...ache/rocketmq/broker/client/ConsumerGroupInfo.java
69.29% <0.00%> (-3.51%)
:arrow_down:

...a/org/apache/rocketmq/filter/util/BloomFilter.java
60.43% <0.00%> (-2.20%)
:arrow_down:

...mq/store/ha/autoswitch/AutoSwitchHAConnection.java
70.43% <0.00%> (-1.35%)
:arrow_down:

.../rocketmq/broker/filter/ConsumerFilterManager.java
72.19% <0.00%> (-0.90%)
:arrow_down:

...he/rocketmq/client/impl/consumer/ProcessQueue.java
62.11% <0.00%> (-0.89%)
:arrow_down:

...che/rocketmq/test/lmq/benchmark/BenchLmqStore.java
50.24% <0.00%> (-0.50%)
:arrow_down:

...rocketmq/broker/processor/PopMessageProcessor.java
36.68% <0.00%> (-0.46%)
:arrow_down:

... and 14 more

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


Uptime kuma appears to only bind to primary nic

⚠ Please verify that this question has NOT been raised before.

[X] I checked and didn't find similar issue

🛡 Security Policy

[X] I agree to have read this project Security Policy

📝 Describe your problem
Likely related to #3194

I am using the binary installation of uptime kuma in an LXC running on Proxmox. My LXCs tend to have 2 Nics. 1 for non-vm  traffic (IE, google, other physical machines on my LAN, etc etc) and 1 for internal traffic (virtual machines).
In this case, it seems my primary Nic for my LXC is my Virtual Machine interface (for the sake of this post, lets call that eth1). My secondary Nic (eth0) is unaccessible within uptime-kuma it seems
Uptime Kuma can communicate over eth1 just fine, talking to all devices available on there, and resolving DNS over this Nic with no issues. However, it cannot talk over eth0.
I validated this by setting up a ping test with uptime kuma to a machine with a hardcoded IP address.

As we see in the screenshot, uptime kuma cannot reach this. The logs indicate this as well
Oct 28 03:56:40 uptime-kuma node[2279]: 2024-10-27T22:56:40-05:00 [MONITOR] WARN: Monitor #2 'Nas': Failing:  | Interval: 30 seconds | Type: ping | Down Count: 0 | Resend Interval: 0

To sanity check, I pinged this IP from the uptime-kuma host

As we see in the screenshot, it is completely accessible.
I went so far as to run tcpdump on the host, binding specifically to eth1 (as that is the nic it would need to communicate over to get to nas) and there is absolutely no traffic during that ping test in uptime-kuma.
As a second sanity check, I setup a DNS check for google.com, using <IP_ADDRESS> as the DNS server. This too would have to go through eth1 in order to resolve.

And indeed it also cannot complete

The logs show that it is unable to complete the DNS query
Oct 28 03:56:57 uptime-kuma node[2279]: 2024-10-27T22:56:57-05:00 [MONITOR] WARN: Monitor #5 'Google.com': Failing: queryA ETIMEOUT google.com | Interval: 60 seconds | Type: dns | Down Count: 0 | Resend Interval: 0
Oct 28 03:58:21 uptime-kuma node[2279]: 2024-10-27T22:58:21-05:00 [MONITOR] WARN: Monitor #5 'Google.com': Failing: queryA ETIMEOUT google.com | Interval: 60 seconds | Type: dns | Down Count: 0 | Resend Interval: 0

Is there anything I can do to make uptime-kuma not bind to 1 nic?
📝 Error Message(s) or Log
No response
🐻 Uptime-Kuma Version
1.23.15
💻 Operating System and Arch
Ubuntu 22.04
🌐 Browser
NA
🖥 Deployment Environment

Runtime: Node JS 20.18.0
Database: Sqlite I assume? I didn't set one up
Filesystem used to store the database on: xfs
number of monitors: Irrelevant

Quick edit, I did also try using 'PING' on another service on the eth0 (the known functioning nic) and it also failed. It appears that the ping health check is not providing ICMP packets? The tcpdump looks different when uptime-kuma sends its pings as opposed to when I execute a ping from the cli.
For reference, I do have other healthchecks working (https seems to be working just fine), so there may just generally be some weirdness with how the Ping health check works?
To clarify, this second attempt at Ping is using the proper NIC, I can see the communication on both sides, but it doesn't seem like an ACK is ever provided on either side. So I am not exactly sure what is going on with PING here. Possibly a different issue than the one I reported which is related to not binding to all available NICs

It could be Docker's limitation.
Try to ping inside the container:
https://github.com/louislam/uptime-kuma/wiki/Troubleshooting

I am using the binary installation of uptime kuma in an LXC running on Proxmox. My LXCs tend to have 2 Nics. 1 for non-vm traffic (IE, google, other physical machines on my LAN, etc etc) and 1 for internal traffic (virtual machines).

You should be able to configure which IP-Adress (thus also which interface) Uptime Kuma is served on via the HOST Environment variable.
Having multiple nic's is not something which we have a testcase for notification providers and monitors.
We use node and don't set localAddress => We use the defaults.
I don't know if the defaults work with the networking configuration you need. Hard to tell from the docs.
I also would CURRENTLY prefer to not add this as a feature to not further complicate this part.
That code is already thoroughly undertested and pretty messy.
Trying to solve your issue:
It should be possible to simply link aggregate your two nics into one nic and then use that one going foreward as your default nic.

I'll check that recommendation out :)
Ya I wouldn't recommend allowing NIC configuration, I would assume it has access to all NICs, though that doesn't seem to be the case.
I haven't heard of a link aggregate, I'll have to check that out.

I'll have to check that out

My networking knowlege is pretty basic..
Please remember to post your findings

if (and how) it works out,
or why it does not work out ^^

I went down the rabbit hole of trying to setup a bond with the 2 NICs using systemd-network and while I was able to get it "setup", I could not get the bond NIC to come online.
I eventually just gave up and decided to have everything go through the main LAN NIC. I am not fond of this solution as that is alot of "internal" traffic (all the VMs are on the same physical hardware) but I don't want to dick around with bond NICs more.
It would be pretty cool if this behaved like most other systems in how it talks to the network :/

It would be pretty cool if this behaved like most other systems

seems like this has not been reported to the node team
https://github.com/nodejs/node/issues?q=is%3Aissue+nic
Feel free to request this feature there if you need it
Issue seems resolved as and I don't have more resources to throw at the problem => closing as resolved


custom_components.xiaomi_miot.climate

hello
my  lumi.acpartner.v3 do not work
why ?
Air Conditioner: Set miot property {'did': '134963433', 'siid': 3, 'piid': 1, 'value': 1} failed, result: {'did': '134963433', 'siid': 3, 'piid': 1, 'code': -706010002, 'exe_time': 0}

Error code -706010002 means Service does not exist, it is returned by Xiaomi cloud. Maybe you can check whether the device firmware is up-to-date.

yes the firmware is up to date
lastest version  1.4.1_162.0149

do you need more log?

Maybe you can try: https://github.com/syssi/xiaomi_airconditioningcompanion

Unfortunately, the miot-spec protocol used in this component can only support the device in the cloud mode, but Xiaomi cloud can not normally control the fan level, so there is nothing to do about it.


Begin shifting to use podman rather then docker

Signed-off-by: Daniel J Walsh<EMAIL_ADDRESS>
- What I did
- How I did it
- How to verify it
- Description for the changelog

/test all

@giuseppe @wking PTAL


[maistra-1.1-future] Mixer

Hey Rob, the permissions for authentication.maistra.io and rbac.maistra.io will be part of the upcoming PR that re-introduces those CRs. The SMMR permissions are being patched in by the operator scripts: https://github.com/Maistra/istio-operator/blob/6fee5c2ad170d5532976805ffc57bbc73ca9640a/tmp/build/patch-charts.sh#L232

Merging by hand because mergify won't


Trouble building Middleman project on Windows 10

I'm using Middleman to distribute the examples for my book, and a few of my customers running Windows mentioned they've had issues getting Middleman up and running. I downloaded Windows 10 on my Macbook and have been trying to get my repo to compile since. Here's what I've done so far:

I switched Middleman to the v3-stable branch in the Gemfile after experiencing the errors mentioend in #1601 and reading about the fix in #1640.
I added a missing require to the default_helpers.rb file. (I'll send out a PR for this shortly.)

Running bundle exec middleman build fails with this error:
C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/sprockets-2.12.4/lib/sprockets/base.rb:153:in `resolve': couldn't find file 'C:\Users\landonschropp\unraveling_flexbox\source\images\chapter14\close.svg' (Sprockets::FileNotFound)
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/middleman-sprockets-3.4.2/lib/middleman-sprockets/asset.rb:12:in `initialize'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/middleman-sprockets-3.4.2/lib/middleman-sprockets/extension.rb:99:in `new'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/middleman-sprockets-3.4.2/lib/middleman-sprockets/extension.rb:99:in `block in manipulate_resource_list'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/middleman-sprockets-3.4.2/lib/middleman-sprockets/extension.rb:98:in `each'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/middleman-sprockets-3.4.2/lib/middleman-sprockets/extension.rb:98:in `manipulate_resource_list'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/sitemap/store.rb:217:in `block (2 levels) in ensure_resource_list_updated!'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/sitemap/store.rb:216:in `each'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/sitemap/store.rb:216:in `block in ensure_resource_list_updated!'
        from C:/Ruby21-x64/lib/ruby/2.1.0/monitor.rb:211:in `mon_synchronize'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/sitemap/store.rb:208:in `ensure_resource_list_updated!'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/sitemap/extensions/on_disk.rb:31:in `block in initialize'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/uber-0.0.15/lib/uber/options.rb:96:in `instance_exec'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/uber-0.0.15/lib/uber/options.rb:96:in `proc!'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/uber-0.0.15/lib/uber/options.rb:82:in `evaluate_for'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/uber-0.0.15/lib/uber/options.rb:60:in `call'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/hooks-0.4.1/lib/hooks/hook.rb:59:in `evaluate_callback'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/hooks-0.4.1/lib/hooks/hook.rb:55:in `execute_callback'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/hooks-0.4.1/lib/hooks/hook.rb:40:in `block in run'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/hooks-0.4.1/lib/hooks/hook.rb:39:in `each'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/hooks-0.4.1/lib/hooks/hook.rb:39:in `inject'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/hooks-0.4.1/lib/hooks/hook.rb:39:in `run'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/hooks-0.4.1/lib/hooks.rb:55:in `run_hook_for'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/hooks-0.4.1/lib/hooks/instance_hooks.rb:6:in `run_hook'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/core_extensions/request.rb:57:in `inst'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/cli/build.rb:95:in `shared_instance'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/cli/build.rb:62:in `build'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/cli.rb:72:in `method_missing'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor/command.rb:29:in `run'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor/command.rb:126:in `run'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
        from C:/Users/landonschropp/middleman/middleman-core/lib/middleman-core/cli.rb:20:in `start'
        from C:/Users/landonschropp/middleman/middleman-core/bin/middleman:18:in `<top (required)>'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/bin/middleman:23:in `load'
        from C:/Ruby21-x64/lib/ruby/gems/2.1.0/bin/middleman:23:in `<main>'

@tommysanterre mentioned the same issue in #1640. If I delete close.svg, I get the same Sprockets::FileNotFound error on the next file.
If there's anything I can to do help with this issue, please let me know. I'm happy to contribute, especially if it helps resolve this issue quicker.

My #1674 PR helps to address this, but it doesn't solve the Sprokets::FileNotFound issue. I'd like to keep this open until that's fixed if you wouldn't mind.

I still have this issue as well
On Nov 3, 2015 02:21, "Landon Schropp"<EMAIL_ADDRESS>wrote:

My #1674 https://github.com/middleman/middleman/pull/1674 PR helps to
address this, but it doesn't solve the Sprokets::FileNotFound issue. I'd
like to keep this open until that's fixed if you wouldn't mind.
—
Reply to this email directly or view it on GitHub
https://github.com/middleman/middleman/issues/1673#issuecomment-153276289
.

@tdreyno Oops, I forgot to tag you above. Would you mind reopening this?

I've been tracking this down and I think it might be related to this issue in Sprockets. It looks like they've fixed the problem and added support for Windows file systems in 3.3. However, the current version of middleman-sprockets is using 2.12. I've noticed the master branch of middleman-sprockets has been bumped to 3.x, but it doesn't seem to be widely released yet. Is there any ETA on when that will be ready to go?

The master version of middleman-sprockets will be released along-side Middleman 4 and won't be back ported to v3.
I find it hard to believe this is an issue with all Windows, we've had windows users for years. is this only on windows 10?

Honestly I'm not sure. I'm a Mac user myself, so I couldn't really speak to that. I was testing on a clean install of Windows 10, and I installed Ruby with RubyInstaller, so it seems unlikely to be specific to my setup.

@LandonSchropp
Did you also install the dev kit? This is necessary for Gems that have native extensions, which may include some of those used in Middleman. You can download the dev kit from the same place as RubyInstaller. (This is just a guess, as I'm also a Mac user, but I recall having to help a colleague build a Middleman project on Windows).

@jimothyGator I did install the dev kit. Good suggestion though. :smiley:

The FileNotFound is caused by the underscore in unraveling_flexbox. Sprockets seems to have problems with symbols. See rails/sprockets#75
I'm having a similar problem on Windows 10. Guess I'll be going back to my Linux VM for now. :disappointed:

I'm doing some issue-gardening 🌿🌷🌾 and came across this issue.
Sorry that this has lingered for quite a while! With Middleman 4 the external pipeline is preferred method for assets. I'd suggest closing this issue.
If it's still a problem it should be filed in https://github.com/middleman/middleman-sprockets

Makes sense.