ORC-176: Refactor common classes for writer and reader

This is mainly a refactoring change for ORC-176, including:

Extracted common classes and functions into Common.hh and Common.cc;
Put InputStream interface and its implementations from Compression.hh to Stream.hh;
Refactored ColumnStatistic classes to reuse code as many as possible and added setters for writer;
Added more functions in Int128 class for decimal operations;
Added buildTypeFromString() method in Type class to construct ORC type.

@majetideepak Yes I think it will be much easier if I separate it into more smaller PRs. Originally we wanted to do this large PR because it may take a lot of effort for us to split them. As I saw your PRs of ORC-87 and ORC-173, I decide to split them because your code may have conflicts with ours, e.g. in TimestampColumnStatistics. I will update this PR later to make it smaller and create more JIRAs to reflect the change.

@majetideepak Thanks for your previous review. I have replied to your comments and also have deleted some changes to make this commit more concise. Can you review it again?

@wgtmac I will provide feedback shortly. For some reason, Github is not saving my comments.

@wgtmac I made some more comments. Thanks for minimizing the patches.
I learnt the following rules of thumb for C++ apache projects, which might also help us improve the ORC C++ library significantly. I feel this is the right opportunity to do this.

An implementation must follow the PIMPL idiom. The public headers must include only the minimal API and all the class members, implementation will go in the Impl classes.
We must follow a coding style. How about we pick the google C++ coding style https://google.github.io/styleguide/cppguide.html?
We must try to disambiguate the class names and file names as much as possible so that anyone new to the code base can quickly understand the code.

Let me know what your thoughts are. Thanks.

@majetideepak I would absolutely support 2 and 3 as it will definitely improve the code quality and readability. As for 1, I would say let's do it in caution. At present we have classes like ColumnStatistics and ColumnReader which have a one-to-many inheritance relation. Particularly, class ColumnStatistics has many duplicate code which takes more effort for use when we were adding functions to it for implementing writer. This can be improved first.

I will fix the ColumnStatistics code. Templates should help here.

@majetideepak That's cool. You may create a separate JIRA for it and I will continue ORC-184 after your fix is done. Thanks!

@omalley Can you help review this change? It has no new code and our main argument is on the correct place (and naming) to put these lines. Thanks!

I'm sorry, but I committed ORC-183. Can you rebase this patch as a single commit on top of the current master.

@omalley I've created a separate PR based on the current master per your request and thus close this one.


How to grab a date picker's display date?

Hey again,
Grabbing the actual input value is pretty straight-forward, e.g. using jQuery's .val()
...but is there an easy way to grab an input's display value (altFormat)?
Thanks

If you have the flatpickr instance, you should be able to grab directly from altInput e.g.
calendar = flatpickr("#mycalendar");
// ...
alert( calendar.altInput.value );


js+cpp: Convenience method to load WebP to BitmapData asynchronously.

Thanks for the lib! Working like a charm :) The only inconvenience - it throw errors in html5 builds (also html5 not building out-of-the-box due missing import.
To make library more unified between targets, I added loading of webp bitmapdata for html5 target (via Lime). With this method webp can be loaded into bitmap data in cpp && html5 target with same code. Hope you find it useful!

Oh whoops! Thank you sososo much!!!! I didn't know it worked like that, never tested this on HTML5 targets haha.


Really lost.

Hello to everyone.
I blought one SmartEVSE 3.0 and installed my self. All went perfect but the bad news came when I saw that my solar battery was charging my cars battery...
I ask Michael Stegen for help and sed me here. I now how to update de firmware of my EVSE, but I am a little bit lost in how to make this battery use to stop. My knowlage in coding and APIs is very small... So I am asking for a little bit of help.
I don´t know if I need a HA, but I have a NAS.
Thank you.

Have a look here:
https://github.com/serkri/SmartEVSE-3/releases/tag/v1.1.0-serkri-v3


PEP 604 compatiblity to replace Optional[str] with str | None

Python 3.10 is bringing PEP 604 which will allow replace the Union[] notation with a much shorter | annotation.
This new language feature is available on Python 3.9 when the from __future__ import annotations is imported at the top of the scripts.
The pyupgrade tool support the feature and is automatically converting the old style annotations to the new style on our codebase.
Unfortunately Pydantic is unable to parse the new annotation:
  File "/Users/stephane/my/module.py", line 45, in <module>
    class MyClass(pydantic.BaseModel):     # pylint: disable=no-member
  File "pydantic/main.py", line 247, in pydantic.main.ModelMetaclass.__new__
  File "pydantic/typing.py", line 218, in pydantic.typing.resolve_annotations
    params = new_params
  File "/Users/stephane/.pyenv/versions/3.9.2/lib/python3.9/typing.py", line 283, in _eval_type
    return t._evaluate(globalns, localns, recursive_guard)
  File "/Users/stephane/.pyenv/versions/3.9.2/lib/python3.9/typing.py", line 539, in _evaluate
    eval(self.__forward_code__, globalns, localns),
  File "<string>", line 1, in <module>
TypeError: unsupported operand type(s) for |: 'type' and 'NoneType'

Output of python -c "import pydantic.utils; print(pydantic.utils.version_info())" :
> python -c "import pydantic.utils; print(pydantic.utils.version_info())"
             pydantic version: 1.7.3
            pydantic compiled: True
                 install path: /Users/stephane/.pyenv/versions/3.9.2/lib/python3.9/site-packages/pydantic
               python version: 3.9.2 (default, Mar  2 2021, 17:26:49)  [Clang 12.0.0 (clang-1<IP_ADDRESS>)]
                     platform: macOS-11.2.3-x86_64-i386-64bit
     optional deps. installed: ['typing-extensions', 'devtools']

from __future__ import annotations
import pydantic

class User(pydantic.BaseModel):     # pylint: disable=no-member
    first_name: str | None = None
    last_name: str | None = None

Changing the types back from str | None to Optional[str] fixes the issue.

Hi @sodul
Well the backport is just here for type checkers like mypy. But pydantic leverages types at runtime, which is another story.
And this cannot be backported directly. The only way to support this in versions prior to 3.10 is at interpretation time with a custom encoding. I recently wrote https://github.com/PrettyWood/future-typing for this purpose actually but it still needs quite some work to be prod ready 😅

Hi @sodul
Well it's true that a backport exists to support this new annotation for static type checkers like mypy.
But pydantic goal is to leverage annotations at runtime, which is not understood by the language prior to 3.9 !!
You can try
from __future__ import annotations

from typing import get_type_hints
from dataclasses import dataclass

@dataclass
class User:
    id: int | str

print(get_type_hints(User))

and you'll get the same error! Since we can't override builtins to add __or__, the only workaround is to add a custom encoding to change | into Union at interpretation time.
I actually already wrote a proof of concept https://github.com/PrettyWood/future-typing but it still requires a lot of work to be prod ready. I'll get back on it soon enough

You didn't understand what I said. I never said it was an external backport. I know it's the official one.
What I said is that it was not directly possible to leverage this at runtime. It's very important to differentiate static type checking and using types at runtime.
My example is pure python and has nothing to do with pydantic and showcases the issue.

Maybe I was not clear. I never said it was an external backport. I know it's the official one.
What I said is that it was not directly possible to leverage this at runtime. It's very important to differentiate static type checking and using types at runtime.
My example is pure python and has nothing to do with pydantic and showcases the issue.
PS: pydantic v2 will target at least 3.9/3.10 and will hence support postponed evaluation of annotations

Hmmm in fact I may be able to make it work for v1.9 @sodul! It won't be the best support but should help you in most cases. I keep you updated :)

@sodul You're more than welcome to try and see if that works for you https://github.com/samuelcolvin/pydantic/pull/2609!
I know future-typing is still not prod ready but I'll go back on it soon!

Sorry for the lack of reply. We are stuck on pydantic 1.7.3 due to the new hashing feature. We have some code that needed hashing that is backward incompatible with 1.8. So we need to fix that internally first.
I did try to apply the pydantic/typing.py directly to my site-packages/pydantic/typing.py file, but I still got the same stacktrace as before:
  File "pydantic/typing.py", line 218, in pydantic.typing.resolve_annotations
    params = new_params
  File "/Users/stephane/.pyenv/versions/3.9.4/lib/python3.9/typing.py", line 283, in _eval_type
    return t._evaluate(globalns, localns, recursive_guard)
  File "/Users/stephane/.pyenv/versions/3.9.4/lib/python3.9/typing.py", line 539, in _evaluate
    eval(self.__forward_code__, globalns, localns),
  File "<string>", line 1, in <module>
TypeError: unsupported operand type(s) for |: 'type' and 'NoneType'

We'll update our internal code and upgrade to pydantic 1.8 first and will get back to you on this.

We have upgraded to Python 3.10 so this issue is no longer relevant to us. I suppose you can close, unless you want to have some backward compatibility for the new syntax and older versions of python.

Closing this as I think the resolution is to upgrade to python 3.10.


Figure extraction improvements

Coverage increased (+0.02%) to 39.326% when pulling e6b0ae8031ca30dacd74db49455681a6d68c0762 on standalone-figure-extraction into 1b2338a42a6fef799ffdf7587a7a3136f3a6d40f on master.


[BUG]: prompt.Confirm prevent accidental continue

[x] I've checked docs and closed issues for possible solutions.
[x] I can't find my issue in the FAQ.

Describe the bug
You may want to patch this outright or add a kwarg. If you type enter accidentally (for example, a user might press enter twice by accident (or they might hold the enter key slightly too long) when starting a program) then when the input is read by prompt.Confirm it will breeze right on through because it accepted that input that was buffered in stdin as the input for the Confirm prompt.
This might be intended behavior but I would suggest that it is often not. If someone wants to skip confirm prompts then they could use the program yes with its 10Gb/s confirmation power...
This could be mitigated with a function that looks like this and calling it right before input is read
def clear_input():
    if platform.system() == "Linux":
        from termios import TCIFLUSH, tcflush
        tcflush(sys.stdin, TCIFLUSH)
    elif platform.system() == "Windows":
        import msvcrt
        # Try to flush the buffer
        while msvcrt.kbhit():
            msvcrt.getch()

ahh I just realized the Windows code would probably hang if you used the program yes with it--but good thing yes is not in Windows...


Compiler doesn't error if we use reserved words that will cause syntax error if rebuilt on older BC version(s) / said errors are vague

Take this code:
codeunit 50100 Test
{
    trigger OnRun()
    var
        Part: Text;
    begin
        Part := 'oh no';
    end;
}

No warnings from the latest AL language extension:
Name: AL Language
Id: ms-dynamics-smb.al
Description: AL development tools for Dynamics 365 Business Central
Version: 10.0.687650
Publisher: Microsoft
VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=ms-dynamics-smb.al

But if you try to publish it to a server running BC15 (for example, and probably others), you will get a syntax error about the use of Part, as it seems that used to be a strictly 'reserved word' in BC15 et al. - and only subsequently has become contextually allowed.
In order to replicate those errors in VS Code, we have to downgrade to an old AL extension, e.g. to:
Name: AL Language
Id: ms-dynamics-smb.al
Description: AL development tools for Dynamics 365 Business Central
Version: 4.0.249486
Publisher: Microsoft
VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=ms-dynamics-smb.al

which gets us this cluster of confusing errors:

Sorry to rant, but I keep having to report issues like this, where once something becomes OK in a later runtime/platform, the compiler 'forgets' that it didn't work - and still won't - if published/rebuilt on an older runtime/platform, where it was and still is a syntax error.
Having to do so is a huge waste - of our time as developers, of our consultants'/support's time when they find that they can't publish something we give them (because we naively assumed VSC/AL would error, if it would be an error at runtime), and of customers' time and goodwill if we can't deliver what we say we will... and the most we can tell them is 'Sorry, Computer Says No, But It Didn't Before'.

Please can you fix, and see if there's any way to get a better process in place, so that when delivering - great, hugely appreciated! - fixes for newer runtimes/platforms, you don't end up losing the knowledge that it won't work on older ones, and waste everyone's time?
And please, while fixing that, can you make such cases say something clear like

The reserved word part cannot be used in this context before runtime $BAR.

...instead of the compiler basically falling over and spewing seemingly unrelated errors?

Thank you muchly!

The only way to reliably build older versions is to use the vsix that was shipped with that version of BC. Anything else will result in faulty/missing diagnostics like you mention as well as a resulting build that is more likely to cause runtime errors.
At least that has been our experience, hence our pipeline uses the  appropriate vsix.

We don't want to have to accept that, though. We build apps that can be installed on BC15 but also need to be installable and as diagnostic-free as possible on newer versions too. Old compilers won't have new diagnostics and probably have more old bugs. Et cetera, et cetera.
I guess we have to now try to remember to, after developing and validating on latest AL compiler, also test our BC15-targeting apps against Ye Olde Version 4.x - but, and I'm sorry to say it, that's just another waste of our time, which shouldn't be required!

It's not that I don't agree, I'm just detailing the experience we've had.

We've decided to not fix this issue for now. The problem is that this is a form of backwards compatibility that we do not currently support.
Right now we (try to) guarantee that code that used to compile will continue to compile with newer compilers. I.e. a new compiler will not break existing app code.
This however is a different form of backwards compatibility: that code that used to not compile will continue to not compile.  The cost of implementing this is too high to be considered at the moment. For now, the recommendation to use the compiler that is shipped with the version you are building for if you require strict compatibility is probably the best workaround.
As usual, you can raise this on BCIdeas though. If there's enough support for this in the partner community, that would add weight to us being able to prioritize the resources required to do this.


Create Milestones to organize issues

As a project manager, I will want to create milestones to organize issues.
Is your feature request related to a problem? Please describe.
We need a way to let developers divide assigned tasks into issues that make sense for pull requests and status updates.
Describe the solution you'd like
We would like to create GH Milestones to give developers a starting point to create issues as they see fit.
Describe alternatives you've considered
We've considered assigning broad issues that developers can break up into smaller issues but that seems redundant and possibly not well organized.
Additional context
n/a
Story Points
1-3 story points

This issue is outdated since we've moved to our new user story format.


What to do after the export ?

Sry dude, i'm very new to the lua language.
I've made some animations from blender that i want to use in Garrys Mod. But i don't know what to do after i've export my animations into a lua file...

What do you mean by "Export my animations into a lua file"? Animations from Blender (for the source engine) are exported in SMD format, which are then compiled into MDL's. You don't export animations "into a lua file". I cover this in an ancient video of mine.

So i should put the inside of the lua file into my complile.qc folder ?

What?


How to use TTA in demo/inference_demo.ipynb

I saw the example using TTA in https://github.com/open-mmlab/mmdetection/blob/ecac3a77becc63f23d9f6980b2a36f86acd00a8a/tools/test.py#L125-L126
However, when I copy the code and place it in demo/inference_demo.ipynb, it does not work.
Here is my code:
config_file = './checkpoints/rtmdet_tiny_8xb32-300e_coco.py'
checkpoint_file = './checkpoints/rtmdet_tiny_8xb32-300e_coco_20220902_112414-78e30dcc.pth'
cfg = Config.fromfile(config_file)
cfg.model = ConfigDict(**cfg.tta_model, module=cfg.model)
cfg.test_dataloader.dataset.pipeline = cfg.tta_pipeline
model = init_detector(cfg, checkpoint_file, device='cuda:0')

and I got the error
Traceback (most recent call last):
  File "infer.py", line 24, in <module>
    model = init_detector(cfg, checkpoint_file, device='cuda:0')  # or device='cpu'
  File "mmdetection-3.0.0/mmdet/apis/inference.py", line 57, in init_detector
    elif 'init_cfg' in config.model.backbone:
  File "/opt/conda/envs/mmdet3/lib/python3.8/site-packages/mmengine/config/config.py", line 54, in __getattr__
    raise AttributeError(f"'{self.__class__.__name__}' object has no "
AttributeError: 'ConfigDict' object has no attribute 'backbone'

seems that after cfg.model = ConfigDict(**cfg.tta_model, module=cfg.model), cfg.model no longer have the backbone attribute

Solution: https://github.com/open-mmlab/mmyolo/blob/dc85144fab20a970341550794857a2f2f9b11564/demo/large_image_demo.py#L109-L129


Sync with conda-forge recipe - [CI skip]

Explanation of changes:

Moving back recipe from tensorflow_recipes to here.
Sync with CF.

This PR wont't be built.

@cbouss FYI I just disabled the actions.


Admin Password

Jenkins and plugins versions report

Environment

Paste the output here

What Operating System are you using (both controller, and any agents involved in the problem)?
Hello
Really sorry I am trying to find the admin password for my initial Jenkins set up - Yeah I can't remember the user I set up at the beginning too - I know :-(
I issued the following statement that I have found - also gone in terminal and I can't find the file...
docker exec<PHONE_NUMBER>e9 cat /var/jenkins_home/secrets/initialAdminPassword
cat: /var/jenkins_home/secrets/initialAdminPassword: No such file or directory
I am sorry but I am trying to learn docker etc so this is probably a daft question - just need a pointer - sorry to waste your time
Reproduction steps
I can't find the file initialAdminPassword
Now I can't log in
Expected Results
I would like the user name and password so I can log in
Actual Results
Can't find the file
Anything else?


New version: BartoszCichecki.LenovoLegionToolkit version 2.20.1

This pull request is automatically generated by 🥟 Dumplings in #3329
Microsoft Reviewers: Open in CodeFlow

/AzurePipelines run


Remove mojo shell download from dartium DEPS

This is failing on the buildbots.
Creating a temporary branch with the change, to try it on the buildbot.
Do not merge this pull request.

This pull request is a copy of https://codereview.chromium.org/2724303004/, and should be reviewed there instead.

Done by a CL instead.


Add telemetry for whether Jupyter is installed

This is a useful data point to help us understand if people are having issues with the DS experience (discoverability/usability) and the cause is/is not having Jupyter.

I think we basically have this as we send a bunch of telemetry about us needing to search for jupyter when we don't find it right away. But we'll make sure.

If anything this is a dupe of #6983, which is a bit more generalized.


Test connect cluster

What issue type does this pull request address? (keep at least one, remove the others)
/kind enhancement
What is this pull request for? Which issues does it resolve? (use resolves #<issue_number> if possible)
Even more tests
Does this pull request has user-facing changes? (e.g. config changes, new/modified commands, new/modified flags)
no
Does this pull request add new dependencies?
no
What else do we need to know?
nothing

LGTM


Discuss security-biased rating scale

This is an alternative to adding rating categories (i.e. separate ratings for security, performance, compliance, ux, etc) or adding a tag system.
Pros: keeps rating simple (this was a concern of @dpc's)
Cons: not as flexible or expressive
It turns rating into a sort of hybrid of security and overall ratings. The meanings go something like this:

strong => This is good code in all respects .
positive => This is, overall, good code. There may be minor issues (but they have no impact on security).
neutral => ?
negative => This is bad code. It has many or severe non-security issues: I recommend against using it.
dangerous => This code has reckless use of unsafe, severe security vulnerabilities, or is outright malicious.

The scale is intentionally skewed in favor of caring about security more than other aspects of code. This reflects my (limited—I only heard about it today) understanding of what crev is supposed to be. (It also aligns well with the use of the word dangerous, IMO—if code has significant vulnerabilities, it is dangerous, period.)
(This came out of an idea I had on IRC just now. Please discuss, debate, and bikeshed :D )

@Moongoodboy-K That's how things are currently supposed to work. I'm not sure if I missed the twist, or we just totally agree.
Documents here https://github.com/dpc/crev/tree/master/crev-lib/rc/doc should be updated to explain what each value is supposed to mean.

@Moongoodboy-K Please take a lookg at the files that I've just edited.

@Moongoodboy-K That's how things are currently supposed to work. I'm not sure if I missed the twist, or we just totally agree.

I think we just agree! I saw names for the places on the scale, but I didn't see descriptions, so I came up with these semantics. I think that if I ended up at the same ideas that you had, just based on reading the names, that's a good sign! :)

I'm closing then, since there's nothing actionable, Anyone: feel free keep thinking about it here, or on gitter channel. :)


Add #[speedy(non_exhaustive)] struct attribute

Hello,
I implemented #20, this allows users to have the choice to a little bit less space efficient / slower but be able to append fields to their structs without breaking the parsing of older data.
(this PR also removes the file "log", left in my previous PR).
TODO:

[X] basic implementation
[X] serialization tests
[x] benchmarks

I forked your serde-bench repo & added NonExhaustive benchmarks: https://github.com/merlleu/serde-bench

My last commit attempted to reduce the performance delta between non_exhaustive & standard speedy: approx  constant+10ns when serializing or deserializing structs.
Unfortunately, switching from varint64 to u7 when possible doesn't seems to be faster using serde-bench.


Contributors improvement

Description

Closes #56
Checklist

[x] An issue was first created before opening this pull request
[ ] The new code follows the kaos contribution guidelines
[x] I have performed a self-review of my own code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] My changes generate no new warnings
[ ] I have added tests to ensure that prove my fix is effective or that my feature works
[ ] New and existing unit tests pass locally with my changes

I'm having some trouble with the rebase, I tried to resolve the conflict. Did I solved the problem?

I think I did a successful rebase now.


[Codegen 101] Enrich getCommandProperties with the parser object

Summary

[Codegen 101] The code of getCommandProperties is almost identical in Flow and TS. There are small differences between flow/ts, so we need for it to accept a Parser object. Enrich the parser object with the required methods if necessary.

Changelog
[INTERNAL] [CHANGED] - Enrich getCommandProperties with the parser object
Test Plan
yarn test react-native-codegen

Moved propertyName to parser common file.
In Flow, from line 114 to 121 are almost the same as TypeScript. If we like to move those lines, propertyName function need to accept language param. Is this good idea? Let me know what you think.

Yes and no. If property name has to switch over the language, it should not accept a language parameter, but it should accept a Parser. The parser encapsulates the language specific logic, so the TypeScriptParser knows how to return something for TypeScript and the FlowParser knows how to work with Flow.
Does this make sense?

Yes, I actually meant Parser. Sorry for confusion.

I meant these lines. Sorry for confusion.
In Flow,
  let properties;
  try {
    properties = typeAlias.body.properties;
  } catch (e) {
    throw new Error(
      `Failed to find type definition for "${commandTypeName}", please check that you have a valid codegen flow file`,
    );
  }

In TypeScript,
  let properties;
  try {
    properties = typeAlias.body.body;
  } catch (e) {
    throw new Error(
      `Failed to find type definition for "${commandTypeName}", please check that you have a valid codegen typescript file`,
    );
  }

Added bodyProperties

/rebase


Clarify PASE and CASE session handle management on commissioning failure

Problem
It's not totally clear currently whether a user expects a pase session to persist when commissinoing fails. If they call PairDevice, it seems like it would clean up, whereas if they called EstablishPASESession and Commission separately, killing the previously opened pase session does not seem liek the right call.
Proposed Solution

add a cleanup of the pase pool in shutdown
move the PASE session cleanup on case failure to the CommissioningStageComplete function so it's called every time
add a parameter (in the commissioning parameters?) that specifically indicates whether to shut down a pase connection if commissioning fails

Also need to sort out what to do if the commisisoning complete call fails. If the device shuts down the pase connection at case establishment, there's no point in hanging on to the pase session. But the behaviour will be different.

According to the spec, all commissioning failures go back to step 2, which is after the PASE connection so we should be leaving the pase connection open in all cases. It does seem a bit odd with the API since you can call pair and end up in a half set up state. BUT at least you'll know that the commissioning failed. As long as you can call PairDevice again without issue, I think that should be OK.  The failure of the commissioning complete command is a bit of a wildcard here.
Proposed suggestion - leave the PASE session open always if there is a commissioning failure (per the spec), add an early callback / success return on EstablishPASEConnection if we already have a session open. Remove the PASE deletion on failure of the CASE session establishment and rely on the cleanup in the shutdown to remove dangling sessions.


internal/core/eval: default not selected for field used in list arg passed to builtin

What version of CUE are you using (cue version)?

$ cue version
cue version +aa61ee7f linux/amd64

Does this issue reproduce with the latest release?
Yes
What did you do?
exec cue export

-- x.cue --
package x

import "strings"

#something: {
	image:    string | *"some default"
	toString: strings.Join([image], "")
}

x: #something

What did you expect to see?
{
    "x": {
        "image": "some default",
        "toString": "some default"
    }
}

What did you see instead?
> exec cue export
[stderr]
x.toString: non-concrete value *"some default" | string for element 0 of string list argument 0:
    ./x.cue:7:12
    ./x.cue:7:26

This issue has been migrated to https://github.com/cue-lang/cue/issues/1025.
For more details about CUE's migration to a new home, please see https://github.com/cue-lang/cue/issues/1078.


OrderedDictionary does not serialize to JSON using JSONSerialization or JSONEncoder

This is not a bug but moreover, a feature request.
what I would like to see is the dictionary getting converted to JSON using the native JSONSerialization class or JSONEncoder if you can add support for that it will be really awesome.
I tried to use the OrderedDictionary and tried to convert it to JSON using the below code
let serializedData = try! JSONSerialization.data(withJSONObject: orderedDictionaryObj, options: [])
    let encodedData = String(data: serializedData, encoding: String.Encoding.utf8)

but for now if you try to do something like this the JSONSerialization throws an exception. It will be really nice if you can add an extension method or expose a property to do this like
orderedDictionaryObject.ToJSONString()
Really appreciate the work and thanks for sharing this

@codecat15: OrderedDictionary is not an object and thus cannot be used with JSONSerialization API. There is a new API based on Codable which is fully supported by OrderedDictionary. Look into JSONEncoder & JSONDecoder.


Should ExcludeSettingOptions be an enum?

Testing #223154
There are 3 options:
https://github.com/microsoft/vscode/blob/d4bb523d43261a3ec2c4c9ca01052faeb0a874e7/src/vscode-dts/vscode.proposed.findTextInFilesNew.d.ts#L112-L128
Why not searchExclude? What if we add another exclude type in the future?

What do you suggest we have instead of an enum? We could probably just add a new field for only searchExclude if we ever go that route (which is pretty unlikely I think).

excludeSettings: { files?: boolean, search?: boolean}?

Hmm. I guess this runs into the same issue as the ignore files: someone could set something that is invalid (excludeSettings: { files: false, search: true}). With this, we guide the user through valid combinations.
I guess you could argue that it's not very flexible, but after discussing with others, I don't think that there's any plans to support globs that apply to search, but show up in the explorer (at least sourced from the settings).

Why would files: false, search: true be invalid? Isn't it just atypical?

We currently don't support something like that via the UI. We would also need to tweak the code a little bit if we were to support this, as it only looks for search excludes if file excludes are enabled.
@roblourens do you think that it makes sense to support search.excludes without files.excludes via the API? I think we discussed something like this before. Someone could make the argument that, since this is an API, it should be more flexible than the UI options.

I don't think it makes sense, I think it's just assumed that search excludes build on top of file excludes. The setting says "Inherits all glob patterns from the Files: Exclude setting".

Yeah, that makes sense to me too.  I don't see us ever changing that, and findFiles/findTextInFiles are meant to very much be "leverage vscode's search" type of thing. I don't really see a use case for someone only needing the search.excludes and not the flles.exclude. Opinions @Tyriar ?

@andreamah fine here 👌


Command to output the content in selected language

Assume I have content in both Japanese and English looks like the following:
[format=asciidoc]

[lang=jp]
== Content

居住その他の目的をもって構築された建築物。

普通建物、堅ろう建物、普通無壁舎及び堅ろう無壁舎に区分する。

普通建物とは、3階未満の建物及び3階以上の木造等で建築された建物をいう。

堅ろう建物とは、鉄筋コンクリート等で建築された建物で、地上3階以上又は3階相当以上の高さのものやスタンドを備えた競技場をいう。

普通無壁舎とは、側壁のない建物、温室及び工場内の建物類似の構築物で、3階未満のものをいう。

堅ろう無壁舎とは、鉄筋コンクリート等で建築された側壁のない建物及び建物類似の構築物で、地上3階以上又は3階相当以上の高さのものをいう。

[.source]
<<gsi_ops,annex=7,付録7 公共測量標準図式>>

.bldg:Buildingの例
image::images/041.webp.png[]

LOD0からLOD3 までは、建築物の屋外の形状を表現する。
LOD4では、建築物の屋外の形状に加え、屋内の形状を表現する。

[lang=en]
== Content

Buildings constructed for residential and other purposes.

They are classified into ordinary buildings, reinforced buildings, ordinary open buildings, and reinforced open buildings.

An ordinary building refers to a building with less than 3 floors or a building constructed with wood or similar materials with 3 or more floors.

A reinforced building refers to a building constructed with reinforced concrete or similar materials, with a height of 3 floors or more or a stadium with stands.

An ordinary open building refers to a building without side walls, such as a greenhouse or a building inside a factory, with less than 3 floors.

A reinforced open building refers to a building without side walls, such as a building constructed with reinforced concrete or similar materials, with a height of 3 floors or more or a building similar to a stadium.

[.source]
<<gsi_ops, annex=7, Appendix 7 Public Survey Standard Diagram>>

.bldg: Example of a Building
image::images/041.webp.png[]

LOD0 to LOD3 represent the outdoor shape of the building.
LOD4 represents both the outdoor shape of the building and the indoor shape.

I would like to have a command to selectively output the content like:
content.output(lang: :jp)

hello @kwkwan this looks very similar to the template i have been using to paste in the content to the "Notes property" ;   what is == Content  is this an asciidoc heading or a special indicator that "content" is to follow?
do we need to support the case that only one language is present, and in that case would the [lang xx] indicator still be required?  just wondering

I have discussed with @opoudjis a few days ago about this syntax.
There are basically 2 ways we can embed AsciiDoc content in an external plain text field:

As an individual AsciIDoc document.
As an AsciiDoc "snippet" (i.e. without attributes and title).

In addition, the header line of [format=asciidoc] is also unsupported in AsciiDoc. We currently don't have a plain text syntax that differentiates between AsciiDoc and other rich text formats. We need to come up with something?
Individual AsciiDoc document

Pros: self-contained, well-defined, therefore validate-able.
Cons: need to provide unnecessary content, such as title.

Sample:
= Content (title is unnecessary)

[lang=ja]
== Content (clause heading is unnecessary)

(Japanese content)

[lang=en]
== Content (clause heading is unnecessary)

(English content)

AsciiDoc snippet

Pros: No need to provide unnecessary content.
Cons: need a mechanism to well-define supported grammar, in order to support validation.

Sample
[lang=ja]
--
(Japanese content)
--

[lang=en]
--
(English content)
--

Identifier for encoding of rich text
We need to come up with a "magic format recognizing phrase" that differentiates AsciiDoc from other rich text formats.
If we use approach 1, then the initial = ... can differentiate against # ... (Markdown).
The other approach being used is the YAML front matter format that is used by Jekyll, i.e.
---
format: asciidoc
---
= blah
...

Next
Approach 1 is definitely easier to implement because the grammar is well defined. This is the "give me all" approach, and for elements that are not supported in the user's case (e.g. if this is to be inserted in a table cell), the user will have to tailor the content to fit.
Approach 2 requires defining a "AsciiDoc profile", possibly via #74, but enumerating the possible values can be difficult. However, it will save the user from the trouble in filtering out unsupported elements.
I think both Approach 1 and 2 tell us that #74 is absolutely necessary for this task, either way.

#74

We could add a filter system to Coradoc, which would convert a Coradoc tree before outputting the result. Then we could use that in command line like so: --filter=language:pt_BR which would filter out all the nodes that are of a different language than pt_BR. Similarly we could provide an API, for instance by extending Coradoc::Converter: https://github.com/metanorma/coradoc/blob/main/lib/coradoc/converter.rb . This should be straightforward.

We currently don't have a plain text syntax that differentiates between AsciiDoc and other rich text formats
We have file extensions and/or mime types. Anything more, I'm afraid, will not be used by majority of documents. This kind of feels like UTF-8 BOM to me. If we want to deduce a type of some embedded text, I'd rather suggest extending the format of embedding to contain a mime type.

We currently don't have a plain text syntax that differentiates between AsciiDoc and other rich text formats

We have file extensions and/or mime types. Anything more, I'm afraid, will not be used by majority of documents. This kind of feels like UTF-8 BOM to me. If we want to deduce a type of some embedded text, I'd rather suggest extending the format of embedding to contain a mime type.

We've recently done away with it as unused, but the Relaton grammar had MIME types for text it would find (and it never used them): Metanorma XML and Asciidoc, of course, are custom formats.
{ ( "text/plain" | "text/html" | "application/docbook+xml" |
"application/tei+xml" | "text/x-asciidoc" | "text/markdown" | "application/x-metanorma+xml" | text ) }


fix proximity processor and seed genome issues

changes to proximity cortical area block dimensions to avoid extreme neuron sparseness (i.e. blocks w/ 1 neuron)

update proximity processor (simplify functions, remove unused functions)

I have some vague notes about needing to improve proximity processor explanations for certain constants and generally expanding on the information provided in the function docstrings. Should I include in this PR or save for another?


sql-mode(ticdc): dealing with SQL Mode more correctly

What problem does this PR solve?
Issue Number: close https://github.com/pingcap/tiflow/issues/10660
This PR is based on https://github.com/pingcap/tidb/pull/51321
What is changed and how it works?

Delete the changefeed config sql mode
Clear the logic about dealing sql mode in dmls
Parse ddl with the sql mode in ddl job
Fix the session sql mode to the default sql mode when writing into downstream.
Add tests when setting sql mode in both upsteam and downstream

Check List
Tests

Unit test
Integration test
Manual test (add detailed scripts or steps below)
No code

Questions
Will it cause performance regression or break compatibility?
Do you need to update user documentation, design documentation or monitoring documentation?
Release note
None

/retest

/retest

/cc @CharlesCheung96 @asddongmen

/hold

/unhold

/test verify

/test dm-integration-test


WIP: Implement notification sending

I have started on an effort towards enabling the ability for users to subscribe to email notifications that will send through SES.
Here is a screenshot of the added UI modal for signing up for notifications

That form will submit to a new lambda endpoint (fronted by an API gateway) that upserts into a new notifications collection the email address and lists of stores that have been subscribed to.
Within the various refresh scripts, we can implement a quick check to see if an individual store has transitioned from no openings to having openings (I have only currently done this for walgreens and walmart).
When that transition is detected, there is a new notify function created that handles finding the users to notify and sending out the emails. It takes in data about the store in question from the caller.
There is a lot of work still to be done for this. The email bodies need work, the other stores need to be implemented, there are a few things that need to get paramaterized, clean up form submission UI, etc. But figured I would share this in an early stage for any early feedback.

I also added new defined functions for the findStores handlers, since that made it easier for me to run locally with sls invoke --local. Happy to remove those if they aren't helpful.

@mattk42: Sorry I haven't gotten to this yet! I still really want to get this integrated in, since I think it would be tremendously useful, I've just been busy trying to stabilize and cleanup other things, but this looks like a great start.
I still haven't gotten to dig too deep into this, but one general thought I've had: In light of some of the database cleanup and standardization I've been working on (which I know wasn't in place at all when you started, so sorry this is so quickly changing), I'm wondering if that might make some of this easier to implement. Rather than having users select the specific stores to subscribe to, I'm wondering if it would make more sense to have users enter their zip code and then select a notification radius (eg, 10, 25, 50 miles, or the entire state). Now that most of the data is in PostgreSQL with PostGIS, this could then make this type of radius-based query pretty easy in the database. This could have the benefit of automatically including new stores within the user's desired radius, as we add new providers, rather than requiring them to explicitly subscribe to specific stores.
I can definitely lend a hand with all this if you want help, but just wanted to get your thoughts on what you think about this radius-based subscription model versus the store based approach. If you were really after a specific store, then this might have pitfalls, but I'm thinking this might help more users find new stores as we add them. I also realize none of this was easily possible when you started, but I'm hoping some of the underlying database changes could make this easier if you think it would be a good path to go down.
Thanks again and sorry I haven't gotten to this yet!

Thanks for all the work on the current package @GUI and for these updates @mattk42. I am liking the radius based approach, just created something pretty rudimentary here. Note, I will likely clean it up in the next few days or so to make it more extensible, but I found it pretty useful!

I worked on a python messaging program for my personal use to send text messages. I just wanted to note here that text-messaging could easily be incorporated in this e-mail project because most mobile companies have an e-mail address to send directly to SMS.  For example<EMAIL_ADDRESS>for US-Cellular.  Thus the user would only have to put in there number/address to receive text messages. I find that text messaging worked extremely well for getting fast notification of openings.
Here is a link to an extensive list of these e-mail addresses: [https://avtech.com/articles/138/list-of-email-to-sms-addresses/#u]. I do not know much about the accuracy of this list, but only one of the two listed for US-Cellular works.

Being able to alert on specific vaccines would be a huge plus. Much of the traffic in the local vaccine hunter FB group revolves around people trying to track down a specific shot.
A zip code and notification radius is much more useful than subscribing to individual stores. There are hundreds of pharmacies in a major metro area, and it is easier to decide how far you are willing to drive to get a shot than to pick all the pharmacies within driving distance.


How to use the "#" for multiple chromosome input

Hi, Sam,
I was looking at the documentation to figure out how I would run PRSice when I have data from multiple chromosomes. I have generated PLINK (.bim, .bed and .fam) files for each chromosome 1-22 respectively.
The documentation mentions this:
"Target genotype file. Currently support both BGEN and binary PLINK format. For multiple chromosome input, simply substitute the chromosome number with #. PRSice will automatically replace # with 1-22. A separate fam/sample file can be specified by --target ,"
I tried substituting the number of the chromosome with the "#" but it gave me the error listed below. Am I using this option incorrectly? If not what do you think is the best way to run PRSice on the combined chromosome data?
Error: -----------------------------------------------------------------------------------------------------------------------
Initializing Genotype file:
(bed)
With external fam file:

Start processing basefile
Error: Cannot open file:
***/chr#.QC.bim

I was able to use the PLINK --merge-list option and get the files that I needed!


Does this extension support linting?

Version of VSCode: 1.8.1
Version of the extension: 0.3.5
OS: OSX

@khaledkbadr,
Hi.
What exactly do you mean under linting?

I mean warnings and errors before building with Cargo.
I found that it does work when I use clippy in afteractions, but that requires me to work with rustc nightly which I don't want. Is there a way to achieve that without using clippy

@khaledkbadr,
There is a command "Cargo: Check". It does what you want.

I am closing it since there are no new questions.

@KalitaAlexey not sure if my question is for a new issue, but I think it will be good to have the error right in the IDE, something like this.

@ivaylopivanov,
Have you tried the extension yet?
It is exactly how it shows errors.

Yeah, but you have to use clippy for that; or at least how I made it to do
that.
On Fri, Feb 17, 2017 at 6:47 AM Alexey<EMAIL_ADDRESS>wrote:

@ivaylopivanov https://github.com/ivaylopivanov,
Have you tried the extension yet?
It is exactly how it shows errors.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/KalitaAlexey/vscode-rust/issues/48#issuecomment-280551246,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AFx3cb3QqNRpw6LSdcg1M2x-a27tMromks5rdSZfgaJpZM4LqJtz
.

@khaledkbadr,
If you need something more than just rustc output, then yes.
I'd suggest you to read the documentation:
https://github.com/KalitaAlexey/vscode-rust/blob/master/doc/main.md

@KalitaAlexey I can't find any doc about clippy in this repo. However I do share @khaledkbadr concern that using non-stable channel is not a solution.

@ivaylopivanov,
What mode do you use (Legacy or RLS)?
For RLS it should work fine.
For Legacy mode read to https://github.com/KalitaAlexey/vscode-rust/blob/master/doc/cargo_command_execution.md

@khaledkbadr, @ivaylopivanov,
Please read https://github.com/KalitaAlexey/vscode-rust/blob/master/doc/cargo_command_execution.md
The extension parses the output of an executed command and shows diagnostics.

@KalitaAlexey thanks!

I have opened a new issue: #90.


feat: add dotnet workshop

Adds C# workshop
Fixes exposed ARN in python workshop

Fixes #

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Note - we need to coordinate deploying the updated website AFTER the CDK release that includes aws/aws-cdk#5119 and aws/aws-cdk#5144, otherwise templates will not match!


Apply template

This PR applies the latest version of template-django which includes the necessary config to update to the latest version of Icarus. Additionally, Platform OAuth credentials and a sentry project have been set up.

Make sure to fix uwsgi setttings


feat: Add MQTT sync from Teslamate for battery_range

Re-use cast-method from odometer since they both are reported in km from Teslamate and need to be converted to miles for teslajsonpy to be happy.

@alandtse any chance of getting this merged? 🙏


Add a journal model

We need to find a good journal model and include it in the repo to remove this extra friction for new comers. Additionally, we should adjust our style and macros according to the journal model.

@jbrunelle / @yasmina85, what journal model did you use for your dissertation? This template currently uses a BibTeX format (ieeetr) that does not match yours (per #20). It would be useful to know your basis.

I've had students use this one from IEEE Transactions on Mobile Computing:
https://doi.org/10.1109/TMC.2010.208
It's mainly used for table and figure caption positioning and reference style.

Is it something we can add in this repository? I guess there will be some copyright issues as it does not seem to have open access.


remove a couple more redirecting files

:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

Exchange-Server-2013/remove-an-offline-address-book-exchange-2013-help.md
:white_check_mark:Succeeded

Exchange-Server-2013/toc.yml
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


Z Wave sensor data not transmitted

Home Assistant release with the issue:

0.67.1
Last working Home Assistant release (if known):
Operating environment (Hass.io/Docker/Windows/etc.):

hassbian
Component/platform:

zwave - https://www.home-assistant.io/components/zwave/
Description of problem:
paired a new Aeotec water sensor (DSB45) to the Aeotec Z Stick Gen 5. after pairing and restarting home assistant the sensors that are created automatically show up (binary, flood, alarm type, alarm level and source node id) in the states page and i can map them to the frontend. the problem is that none of the entities created change states when the sensor is activated.
If i look at the OZW_log.txt it shows that the data is received by the controller as an event but the data is not being forwarded to the entity states for display. all of the necessary info is populated correctly (I think) in the zwcfg_...xml file
Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):
zwave:
  config_path: /srv/homeassistant/lib/python3.6/site-packages/python_openzwave/ozw_config
  usb_path: /dev/ttyUSB-ZStick-5G
  network_key: "0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx, 0xxx"
  device_config:
    light.zw_light_1_level:
      polling_intensity: 1
      refresh_value: 2
      delay: 3
    light.zw_light_2_level:
      polling_intensity: 1
      refresh_value: 2
      delay: 3

Traceback (if applicable):
no errors in the logs. at least none that relate to this that I've found.

Additional information:
I've removed and re-added a couple of times, both secure & not. I've done a heal, test, etc to no avail.

Have a look here: https://community.home-assistant.io/t/how-to-aeotec-dsb45-water-sensor/51704

@finity69x2 Did the suggested solution work for you?


Improve version management and Git handling

@berendt seems to be a Problem which also exist in the main branch - i haven't touched that file.
The error message is not clear enough for me to just fix that, i cannot identify a reference to "openstackclient-az-list-fallback-f3207bd.diff" (despite the fact, that manual checking also didn't raised some problems other than the tls problem - see las commit)

ready for review


Anyone have any Flow definition files for redux-actions (perhaps just partial ones we can build from)?

I've created the following module definition for createAction:
declare module 'redux-actions' {
  declare type ActionType = string

  declare type Action = {
    type: ActionType,
    payload?: any,
    error?: bool,
    meta?: any,
  }

  declare function createAction<T>(
    type: ActionType,
    payloadCreator?: (...args: Array<T>) => any,
    metaCreator?: Function
  ): (...args: Array<T>) => Action
}

And I've noticed a major issue I described on StackOverflow:
http://stackoverflow.com/questions/41784525/exported-typed-functions-that-return-functions-should-not-require-the-returned-f
which is that you won't get the benefit of this type definition if you don't type the returned function. So the following won't work:
export const selectProfileTab = createAction('SELECT_PROFILE_TAB', (index: number) => {
  playSound()
  return { index }
})

but this will:
export const selectProfileTab: (index: number) => any = createAction('SELECT_PROFILE_TAB', (index: number) => {
  playSound()
  return { index }
})

The first will work if you call selectProfileTab('someString') in the same file, i.e. it will produce an error, but in another file it won't work. This is likely because of Flow's requirement that annotations are required at the "boundaries" of modules. But that defeats the whole purpose of having a module definition file for redux-actions. Now you gotta type the returned functions of all your action creators?? That's a lot of boilerplate for what should be automatic. Is anyone else experiencing this? It makes me wanna stop using redux-actions and go back to plain jane action creators.

Also, here's a version with the payload properly parameterized in return types:
declare module 'redux-actions' {
  declare type ActionType = string

  declare type Action<P> = {
    type: ActionType,
    payload?: P,
    error?: bool,
    meta?: any,
  }

  declare function createAction<T, P>(
    type: ActionType,
    payloadCreator?: (...args: Array<T>) => P,
    metaCreator?: Function
  ): (...args: Array<T>) => Action<P>
}

Here's how you would use it:
type Payload = { index: number }

export const selectProfileTab = createAction('SELECT_PROFILE_TAB', (index: number): Payload => {
  return { index }
})

I've updated your definition to use a template parameter for the payloadCreator arguments. So far it works better than original.
declare module 'redux-actions' {
  declare type ActionType = string;

  declare type Action<P> = {
    type: ActionType,
    payload?: P,
    error?: bool,
    meta?: any,
  };

  declare function createAction<T, P>(
    type: ActionType,
    payloadCreator?: T => P,
    metaCreator?: Function
  ): T => Action<P>;

  declare type State = any;

  declare function handleActions(
    reducerMap: any,
    defaultState: State
  ): (state: State, action: Action<any>) => State;
}

I've also included a (very badly defined) handleActions.

I just discovered flow-typed, which contains definitions for most libraries out there, including redux-actions.

is anyone gettting Computed property cannot be assigned with function type flow errors when using the actions creators as keys?

is anyone gettting Computed property cannot be assigned with function type flow errors when using the actions creators as keys?

@pepesenaris You can call .toString() explicitly on the action creator. It's not perfect but until the types are fixed it's good enough.


implement /api/v1/analysis/root-component

This is an experiment to address resolving a component's root-components (using petgraph) - addressing https://github.com/trustification/trustify/issues/618.
Points of interest:

included draft arch decision at docs/adrs/00001-graph-analytics.md
added a postgres func to resolve full pURL from a qualified_purl_id ... which we can rip out easier if we ever consolidate those tables
added draft implementation of api/v1/analysis/root-component
added gin index on sbom_node name and minor pg config tweaks
added PackageOf relationship (which seemed an omission to me)

The focus of this PR is correct operation - there are plenty of optimisation opportunities for consideration later.
Note - for now have "flattened out" ancestors of any matched component, we might revisit that decision at some future point.

@JimFuller-RedHat if'n you don't mind, whenever you're Really Ready for a review, re-request and/or tag us here.

we use petgraph::Directed which should error if we encounter any circular dependencies.

LGTM. A proposal to switch away from the lazy_static crate. But works either way. I'll leave it to @bobmcwhirter (or someone else) for a final +1. Consider this +1 from me. Great work!


Add validation key

Coverage increased (+1.8%) to 95.604% when pulling b14208ceb284ee0b40139b9a961439894bea83dd on VDigitall:validation_key into 7a50996837b0268fd7837995417b8c1ed55159f1 on Leits:master.

Coverage increased (+2.2%) to 96.04% when pulling a9d92cc1dec902d67bd41aa90c56e31342ecb58c on VDigitall:validation_key into 7a50996837b0268fd7837995417b8c1ed55159f1 on Leits:master.

Coverage increased (+0.4%) to 94.215% when pulling 58831d1441a8531ede7601aee9fb6c0d91a7d261 on VDigitall:validation_key into 7a50996837b0268fd7837995417b8c1ed55159f1 on Leits:master.

Coverage increased (+2.7%) to 96.581% when pulling 64ac8374f8e6c9d59c805d4b1a6ff411e60ac343 on VDigitall:validation_key into 7a50996837b0268fd7837995417b8c1ed55159f1 on Leits:master.

Coverage increased (+1.8%) to 95.652% when pulling 7366a6ccd81083885761e7e7fa6c9f9d702db8d5 on VDigitall:validation_key into 7a50996837b0268fd7837995417b8c1ed55159f1 on Leits:master.

Coverage increased (+1.7%) to 95.506% when pulling 2bbe09e0e3cf7ae0da7d733e716b114b8563d47f on VDigitall:validation_key into 7a50996837b0268fd7837995417b8c1ed55159f1 on Leits:master.


add wordpress constants

Fix: https://github.com/humanmade/psalm-plugin-wordpress/issues/1

Great, thanks!


adding material alphaMode description

Does it work with the new doc site?
Can't remember where you added those already

Yep, I check that before trying this patch :)
http://doc.babylonjs.com/classes/classes/babylon.basetexture.html#coordinatesmode from
https://github.com/BabylonJS/Babylon.js/blob/master/src/Materials/Textures/babylon.baseTexture.ts#L35
(by the way I notice that anchor links doesn't works on Firefox when accessing through http://doc.babylonjs.com/api.html?basetexture urls - works in Chrome - for coordinatesMode anchor link above, I've made right-click > copy link to get it)

Ok I'll check:)

It works for me on firefox
do you have any error in the console?

last version of firefox (59.0.1 64b) & windows 10, newly created profile (so without addons), still the issue, and no console error (here a video screen capture)

Looks like a bug to me :) but in Firefox


Typo

Title "Additional advantages of Extranet Smart Lockout in AD FS 2019" and "Pre-requisites for Extranet Smart Lockout in AD FS 2019" should be 2016 instead?

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

ID: d8634165-2ff5-9b01-e3fc-17827360a5f3
Version Independent ID: a5a91921-3193-93ad-df22-d486e65b19f8
Content: Configure AD FS Extranet Lockout Protection
Content Source: WindowsServerDocs/identity/ad-fs/operations/Configure-AD-FS-Extranet-Smart-Lockout-Protection.md
Product: windows-server-threshold
GitHub Login: @billmath
Microsoft Alias: billmath

Nevermind, I read wrong, you can close this item.

#please-close


Fix/pip

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


add lesson to 04bis advanced shell mastery

I created a course using your template on advanced Linux commands to allow students to continue progressing. I did this in an md format file.

I like this a lot!
Please rename to lessons/07a-further-steps-into-the-shell.md


Make wrap and friends generic over body type

The current definition for wrap on web::Scope doesn't specify a type parameter for the response body, forcing it to use the default BoxBody. This makes it incompatible with middlewares that don't return a box body.
    pub fn wrap<M>(
        mut self,
        mw: M,
    ) -> Scope<
        actix_web::Scope<
            impl ServiceFactory<
                ServiceRequest,
                Config = (),
                Response = ServiceResponse,
                Error = Error,
                InitError = (),
            >,
        >,
    >
    where
        M: Transform<
                T::Service,
                ServiceRequest,
                Response = ServiceResponse,
                Error = Error,
                InitError = (),
            > + 'static,

Conversely the wrap impl for service does specify this parameter
pub fn wrap<M, B>(
        self,
        mw: M,
    ) -> Resource<
        actix_web::Resource<
            impl ServiceFactory<
                ServiceRequest,
                Config = (),
                Response = ServiceResponse<B>,
                Error = Error,
                InitError = (),
            >,
        >,
    >
    where
        B: MessageBody,
        M: Transform<
                T::Service,
                ServiceRequest,
                Response = ServiceResponse<B>,
                Error = Error,
                InitError = (),
            > + 'static,

It looks like this extra parameter is missing from both scope and service response in the web3 version.
Is there a technical limitation to adding these parameters? It seems relatively straightforward to me.

hmm not that I know of @jtscuba, but I haven't looked at that for a long time..
In other words, if you'd like to work on this a PR would be most welcome :)

Closed by #457


Support custom rules for jmx prometheus exporter

What changes were proposed in this pull request?
partially resolve https://github.com/confluentinc/cp-helm-charts/issues/504 issue.
Context
I'd like to configure rules in jmx prometheus exporter.
But there is no way to customize it.
So I added .Values.prometheus.jmx.rules, .Values.prometheus.jmx.whitelistObjectNames and move default rules to there.
How was this patch tested?
helm install on eks

@gAmUssA Hello. Could you please review this PR?


Add AmandsSense dll and its accompanying folder to DEDICATED_DEFAULT_EXCLUSIONS

Accompaniment to the PR I opened in Fika-Dedicated: https://github.com/project-fika/Fika-Dedicated/pull/34

Thanks for the PR!


Rendering glitch when printing spaces with background color

Windows Terminal version
1.17.11461.0
Windows build number
10.0.22621.1848
Other Software
using System;

namespace ConsoleApp1
{
	internal class Program
	{
		static void Main()
		{
			for (int j = 0; j < 100; j++)
			{
				for (int i = 0; i < 8; i++)
				{
					Console.BackgroundColor = (ConsoleColor)((i + j + 1) / 20 % 16);
					Console.Write("   ");
				}
				Console.BackgroundColor = ConsoleColor.Black;
				Console.WriteLine();
			}

		}
	}
}

Steps to reproduce
Run the C# console program listed above a few times.
It print spaces to the console while changing background color, producing a specific pattern (see expected behavior).
From time to time, pattern appear broken (see actual behavior). This occurs randomly but it seems to be always when the terminal start to scroll vertically. Also : printing non whitespace characters (eg: letters) seems to prevent bug happening.
Expected Behavior

Actual Behavior
The pattern appear broken as it contains some black spaces :

Looks like this might be fixed by #15618

Ah sorry @carlos-zamora, I didn't mean to imply that #15618 fix this. It's more like that #15618 is in the same category of VtEngine bugs. My hope is that we'll fix this bug some other way sometime soon if I implement passthrough mode and we can slim down VtEngine.

WAIT this looks just like #14512 - Does updating to Terminal Preview, v1.18 fix this/?

WAIT this looks just like #14512 - Does updating to Terminal Preview, v1.18 fix this/?

Yes it does. I installed it from Windows Store. The "Atlas Engine" was enabled. Even when disabled, that terminal preview seems to be immune to that rendering glitch.

Thanks for letting us know! I'll close the issue then. 🙂


[BEAM-867] Add schema update options to BigQueryIO

Follow this checklist to help us incorporate your contribution quickly and easily:

[x] Make sure there is a JIRA issue filed for the change (usually before you start working on it).  Trivial changes like typos do not require a JIRA issue.  Your pull request should address just this issue, without pulling in other changes.
[x] Each commit in the pull request should have a meaningful subject line and body.
[x] Format the pull request title like [BEAM-XXX] Fixes bug in ApproximateQuantiles, where you replace BEAM-XXX with the appropriate JIRA issue.
[x] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
[ ] Run mvn clean verify to make sure basic checks pass. A more thorough check will be performed on your pull request automatically.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

This is a first attempt at solving BEAM-876. This should work for batch inserts but I haven't found a way to implement it for streaming inserts.
Note that I was not able to successfully run mvn clean verify even before I started with this PR.
Also I've not added any tests since I'm a bit uncertain on how to do this. Please advice.

SUCCESS
--none--

FAILURE
--none--

FAILURE
--none--

SUCCESS
--none--

FAILURE
--none--

Hmm I don't understand why the python stuff fails since to commit doesn't touch any python code.

SUCCESS
--none--

R: @reuvenlax

@reuvenlax Thanks for your comment. Where can I read up on the other attempt? I've also created a feature request at issuetracker.google.com to hopefully allow BigQuery to support schema updates on streaming inserts "natively".

@aaltay @reuvenlax what's the status of this issue BEAM-876 (https://issues.apache.org/jira/browse/BEAM-876)? Does anyone do it?

Has not been implemented. However there's a workaround - use
withFailedInsertRetryPolicy to detect when inserts fail due to invalid
schema, and update the schema in response to that.
On Wed, Jul 25, 2018 at 1:42 AM Oleg Skovpen<EMAIL_ADDRESS>wrote:

@aaltay https://github.com/aaltay @reuvenlax
https://github.com/reuvenlax what's the status of this issue BEAM-876 (
https://issues.apache.org/jira/browse/BEAM-876)? Does anyone do it?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/apache/beam/pull/4119#issuecomment-407680150, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AUGE1VyYl9srCeNJK09xg8C1PePbZbOgks5uKC-CgaJpZM4Qbfma
.


[1.12.2] Possible Feather Issue

https://github.com/setycz/ChickensMod/issues/117#issuecomment-368339806
This is an issue happening with Chickens.  Is Roost doing anything with feathers?

No, roost doesn't modify entity drops at all.


Tasks for initial release

Workflow
- [ ] https://github.com/web-infra-dev/rsbuild/issues/136
- [ ] https://github.com/web-infra-dev/rsbuild/issues/135
- [ ] https://github.com/web-infra-dev/rsbuild/issues/4
- [ ] https://github.com/web-infra-dev/rsbuild/issues/5
- [ ] https://github.com/web-infra-dev/rsbuild/issues/15

Decoupled from Modern.js
- [x] https://github.com/web-infra-dev/rsbuild/issues/12
- [ ] https://github.com/web-infra-dev/rsbuild/issues/53
- [ ] https://github.com/web-infra-dev/rsbuild/issues/22
- [ ] https://github.com/web-infra-dev/rsbuild/issues/3

Document
- [ ] https://github.com/web-infra-dev/rsbuild/issues/16
- [ ] https://github.com/web-infra-dev/rsbuild/issues/17
- [ ] https://github.com/web-infra-dev/rsbuild/issues/18
- [ ] https://github.com/web-infra-dev/rsbuild/issues/21
- [ ] https://github.com/web-infra-dev/rsbuild/issues/60
- [ ] https://github.com/web-infra-dev/rsbuild/issues/19
- [ ] https://github.com/web-infra-dev/rsbuild/issues/20
- [ ] https://github.com/web-infra-dev/rsbuild/issues/66
- [ ] https://github.com/web-infra-dev/rsbuild/issues/25
- [ ] https://github.com/web-infra-dev/rsbuild/issues/67
- [ ] https://github.com/web-infra-dev/rsbuild/issues/85

Plugins
- [ ] https://github.com/web-infra-dev/rsbuild/issues/65
- [ ] https://github.com/web-infra-dev/rsbuild/issues/92
- [ ] https://github.com/web-infra-dev/rsbuild/issues/23
- [ ] https://github.com/web-infra-dev/rsbuild/issues/6
- [ ] https://github.com/web-infra-dev/rsbuild/issues/7
- [ ] https://github.com/web-infra-dev/rsbuild/issues/24
- [ ] https://github.com/web-infra-dev/rsbuild/issues/207
- [ ] https://github.com/web-infra-dev/rsbuild/issues/263
- [ ] https://github.com/web-infra-dev/rsbuild/issues/167

Features
- [ ] https://github.com/web-infra-dev/rsbuild/issues/8
- [ ] https://github.com/web-infra-dev/rsbuild/issues/11
- [ ] https://github.com/web-infra-dev/rsbuild/issues/9
- [ ] https://github.com/web-infra-dev/rsbuild/issues/26
- [ ] https://github.com/web-infra-dev/rsbuild/issues/174

Others
- [ ] https://github.com/web-infra-dev/rsbuild/issues/13
- [ ] https://github.com/web-infra-dev/rsbuild/issues/14
- [ ] https://github.com/web-infra-dev/rsbuild/issues/64
- [ ] https://github.com/web-infra-dev/rsbuild/issues/73
- [ ] https://github.com/web-infra-dev/rsbuild/issues/75
- [ ] https://github.com/web-infra-dev/rsbuild/issues/96
- [ ] https://github.com/web-infra-dev/rsbuild/issues/151
- [ ] https://github.com/web-infra-dev/rsbuild/issues/37
- [ ] https://github.com/web-infra-dev/rsbuild/issues/168
- [ ] https://github.com/web-infra-dev/rsbuild/issues/72
- [ ] https://github.com/web-infra-dev/rsbuild/issues/285
- [ ] https://github.com/web-infra-dev/rsbuild/issues/183

Rsbuild v0.1.0 has been released, this issue can be closed now 😄


Add API to restrict draggable component behaviour

Add APIs to configure different component behaviour to achieve

Disabling of dragging
Restriction of edit functionality
Restriction of duplicate / remove
Control over overlay actions (custom actions, removal of existing actions)

Proposal
TBD

@chrisvxd  do we have any updates on this one ?
Also is there any way to capture the duplicateEvent? The issue i'm facing is while duplicating the component it creating copy with same id value for it and hence when trying to update my db, it throws error as there is primary key constraint of the id column.  I need some way to control this duplicate action.

This one is on our radar to implement relatively soon.
Regarding duplications - Puck should update the ID for any components caught in duplications. Is that the issue you're facing? Or is it a separate ID that you're tracking that needs updating??

my issue is not to be able to control the state when duplicate action is clicked and  be able to edit the props which gets updated to editor state .

Hi @chrisvxd, i need to disable dragging in the preview, i would like to know if there are any update on this feat? or there is a workaround i can use?

These API's need a good amount of thought and understanding of the different sceanarios where someone might want to use them.
The overlay actions seem to be very similar in nature to something like headerActions. For consistency I propose a similar API e.g.
<Puck<Config>
  config={config}
  data={data}
  onPublish={async () => {}}
  plugins={[...]}
  headerPath={path}
  overrides={{
    headerActions: ({ children }) => (...),
    overlayActions: ({ children }) => (
      <>
        <div>
          <Button onClick={()=> {}} variant="secondary">
            Lock
          </Button>
        </div>

        {children}
      </>
    ),
  }}
/>

A downside to the propsal above is that unlike AppState the dropZoneContext isn't exposed so you'd have to hack the children to alter how a pre-existing button displays/behaves or build a new button but the actions aren't publicly available are they? (For example if you wanted to adjust the icons).  Is that a problem?
I do agree with @sagarchoudhary96's point that being able to alter the data would be beneficial. However, this seems like a separate bit of functionality I will create a different issue for this.  I ran into similar problems as my implimentation which is leveraging additional metadata behind the scenes. Rather than exposing the entire Dropzone context and dispatch function perhaps we can update the duplicate action to add a flag to the duplicated in addition to changing the ID such as isDuplicate={true}?  Then when using the onPublish we could then alter the data/behaviour before sending the payload to the server.
The other parts of this issue all seem related to me as boolean toggles and whether or not.  It boils down whether or not a user can perform the following actions on an instance of a component:

Edit
Duplicate
Delete
Drag

Conceptually, I see these toggles as a similar data configuration to fields and component type.
export const ExampleComponent: ComponentConfig<ComponentProps> = {
  fields: { },
  actions: {
    isEditable,
    isDuplicatable,
    isDeleteable
    isDraggable,
  }
  defaultProps: {
  },
  render: ({}) => (),
};

In the data/initialData you could then add optional actions object. For a hero, I could see this being useful.
{
  type: "ExampleComponent",
  props: {
    ...
  },
  actions: {
    isEditable: true,
    isDuplicatable: false,
    isDeleteable: false
    isDraggable: false,
  }
},

From my perspective and having worked on integrating Puck with a CMS, there is also a need to interpret rules beyond which are provided from the data payload.
The main question I have is should these API's exist as global configuration or an individual (or a mixture of the two)? I could see this being used to change the edit state of all components on a page where a user doesn't have the correct permissions but also being able to limit some of the components rules individually.
Globally:
<Puck<Config>
  config={config}
  data={data}
  onPublish={async () => {}}
  plugins={[...]}
  headerPath={path}
  overrides={{
    componentActions:({ config, data }) => {
      // pseudo code
      if(data.user.role == "limited") {
        config.components.Text.actions.isEditable = false
      }
    }
  }}
/>

Indivdually:
export const ExampleComponent: ComponentConfig<ComponentProps> = {
  ...
  resolveActions: (data) => {
    // pseudo code
    if(data.props.size = "8px") {
      return {
        isDraggable: false
      }
    }
  }
};

Are there any preferences, thoughts, comments, alternative ideas or concerns towards the approaches above?

After much conversation with @xaviemirmon, we're going with the proposal now outlined in the ticket description


Build Status missing

It's not redirected to proper build status link, it redirects to https://travis-ci.org/maxogden/electron-packager :smile:

lol, whoops, thanks :+1:

:v: cool


Add "Edit in JOSM" Button near the existing "Edit in OpenStreetMap" in the bottom right corner

I heavily use the "OpenStreetMap" link in the lower right corner to open the OpenStreetMap and then from there open and edit the area in JOSM.
It would be great if this jump (Remote JOSM Editing) could be done directly from brouter / bikerouter.de.
Wording could be short and easy "JOSM" or "Edit in JOSM".
Screendesign Mockup:

Just my (uneducated) thoughts:

There are many OSM editors (iD, JOSM, Level0, RapiD, Potlatch, Merkaartor, ...). iD has about 10x the usage JOSM has. Why single out JOSM?
The OpenStreetMap link is only there when the OpenStreetMap base layer is selected. Should other layers also offer links to editors?
It should be relatively easy to write a bookmarklet or GreaseMonkey script to link directly to your favorite editor, even from other mapping sites like Google Maps.


Add is_ methods to edn::Value types and add tests. Fixes #197

Just a preliminary check, is this what @ncalexan @rnewman had in mind? Want to get some eyes on it before starting the as_*

@jsantell yeah, just so!  I expected serde to have an API like this but I don't see it.  In any case, looking good!

@rnewman now with handfuls of macros!


rest-firebase doesn't seem to see disconnects/downtime.

Tested using:
rest-firebase 1.0.3
rest-core 3.5.92 & 3.5.91
httpclient 2.7.1 & <IP_ADDRESS>
When a long running event source is disconnected (specifically I believe when the firebase server goes down for a few minutes -- some nodes do this! e.g. http://status.firebase.com/1363624 ) rest-firebase doesn't seem to realize it lost connection. I don't see any reconnection attempts, and so my daemon runs but is disconnected from firebase until I restart it.
Neither onerror and onreconnect are called (I log when they are).
I'm setting up the connection like this:
fb = RestFirebase.new(:site => ENV['FIREBASE_URL'],
:auth => ENV['FIREBASE_SECRET'],
:timeout => 7
)

I think we were probably also hit by this because we often saw unsynchronized data, though we didn't log it therefore we have no idea.
To be honest, I am not very familiar with IO, and I can't seem to reproduce this. My guess is that this line in rest-core:
sock.readline("\n\n")

Didn't do anything when the socket was already disconnected under some circumstance. Since I can't reproduce I can only guess it. Can you see if this patch for rest-core would make thing better?
diff --git a/lib/rest-core/event_source.rb b/lib/rest-core/event_source.rb
index 10850d6..b4d9f53 100644
--- a/lib/rest-core/event_source.rb
+++ b/lib/rest-core/event_source.rb
@@ -100,7 +100,7 @@ class RestCore::EventSource < Struct.new(:client, :path, :query, :opts,
   private
   # called in requesting thread after the request is done
   def onmessage_for sock
-    until sock.eof?
+    until sock.eof? || IO.select([sock], [], [], 30).nil?
       event = sock.readline("\n\n").split("\n").inject({}) do |r, i|
         k, v = i.split(': ', 2)
         r[k] = v

The idea is that we wait for readable event for the socket, timeout in 30 seconds. If there's no data from Firebase in 30 seconds, we close the connection on our side. If this works out, we could see how we could tweak the timeout. Firebase would send keep-alive event if there's no data around periodically. I can't seem to find how long they would send this event on their document though. Ideally our timeout should match that period.
Let me know if you have any thoughts. Thanks!

While not conclusive, as pingdom didn't show any downtime -- it appears I got a reconnect last night with this patch. I will keep running and see if I can match up verified downtime with a reconnect.
» 13 Jan 2016 19:04:52.785 2016-01-14 00:04:52.483199+00:00 app disconnected.1 - - EOFError
» 13 Jan 2016 19:04:52.861 2016-01-14 00:04:52.483248+00:00 app disconnected.1 - - Reconnecting...
» 13 Jan 2016 19:04:55.092 2016-01-14 00:04:54.786210+00:00 app disconnected.1 - - Connection refused - connect(2) for "s-dal5-nss-28.firebaseio.com" port 443 (s-dal5-nss-28.firebaseio.com:443)
» 13 Jan 2016 19:04:55.168 2016-01-14 00:04:54.786221+00:00 app disconnected.1 - - Reconnecting...
» 13 Jan 2016 19:05:59.577 2016-01-14 00:05:59.275709+00:00 app disconnected.1 - - Connection Opening...

That's certainly very helpful. Thank you!
I am wondering though, should we distinguish different exceptions?
Say, introduce a new RestCore::IOTimeout which extends from EOFError,
so that you'll have more idea was it timeout or really EOF?
Or perhaps some messages would be good enough.

Pingdom claims 3 minutes of downtime yesterday, and I didn't see a disconnect, but also can't verify if it was still connected. Sadly my daily heroku restart was 4 minutes later. I'd like to keep watching, but now I'm not convinced it is fully working yet. Will update when I know more.

Thank you for the update.

Appears it in fact does not take care of a downtime situation.
Pingdom shows a 4m downtime at 18:31 on Jan 16, and my logs show the daemon stops receiving keep-alives and does not attempt to reconnect at the same time. Nothing else happens until the daily restart at 8:12 on Jan 17.
» 16 Jan 2016 18:29:57.544 2016-01-16 23:29:57.264906+00:00 app disconnected.1 - - keep-alive
» 16 Jan 2016 18:30:27.548 2016-01-16 23:30:27.265425+00:00 app disconnected.1 - - keep-alive
» 16 Jan 2016 18:30:57.544 2016-01-16 23:30:57.265354+00:00 app disconnected.1 - - keep-alive
» 17 Jan 2016 08:12:48.788 2016-01-17 13:12:48.396037+00:00 app disconnected.1 - - Starting...
» 17 Jan 2016 08:12:49.272 2016-01-17 13:12:48.879370+00:00 app disconnected.1 - - Connection Opening...
» 17 Jan 2016 08:12:49.257 2016-01-17 13:12:48.885085+00:00 app disconnected.1 - - Disconnect User:206
» 17 Jan 2016 08:12:49.364 2016-01-17 13:12:48.887863+00:00 app disconnected.1 - - Disconnect User:209
» 17 Jan 2016 08:13:19.421 2016-01-17 13:13:19.134333+00:00 app disconnected.1 - - keep-alive

I am curious where this got stuck. Was it sock.eof?, or sock.readline("\n\n")?
Is it possible that you put the log around them so that we could know where it got stuck?
If it got stuck at sock.eof?, then perhaps we could remove it. If it got stuck at sock.readline("\n\n")... well, since we already put IO.select there, the only reason this got stuck might be missing "\n\n". For example, if Firebase kept the connection while never sending anything, then we could get stuck here forever. If this is the case, perhaps we would need to set another timeout. Unfortunately there's no timeout option for readline...

Stumbled upon this conversation because I want to use this lib to replace our existing simple request based client, and leveraging a socket pool to reduce the number of SSL handshakes.
Just curious whether this issue would impact such an implementation as well or if I could manage it by specifying a lifetime of sockets ;-)

Did you mean you want to use rest-firebase along with a customized socket pool?
The sockets used in rest-firebase are retrieved from https://github.com/nahi/httpclient
It should be responsible for keep-alive connections. (there's a connection pool in httpclient)
However, this issue is more about event stream -- which is different from regular REST API.
By using event stream, you basically keep the connection forever, so there's no point to use
any pool in this case.

So I took a day or two to research httpclient and rest-core and my feeling is that this is a larger issue with how httpclient creates the connection and how TCP sockets operate. First, i believe httpclient disgards the write pipe and only passes along the read pipe. TCP sockets normally can't tell when a remote disconnects unless it sends a signal and won't know until they attempt a write.
See where I'm going? When Firebase crashes/goes down it won't notify the remote connection, so we never know it closes. There might be some underlying things we can do like looking at some of the flags set on the TCP connection (but this is platform dependent), but IO doesn't offer them (whereas TCPSocket does). I'm also concerned about not having access to the write on the pipe.
I could be wrong about any/all of this. But I've also started using a modified version of https://github.com/firebase/EventSource-Examples/tree/master/ruby and I'm having good luck with it reconnecting (but haven't been able to 100% verify a reconnect after downtime, since Firebase all of a sudden is having less downtime...)

Yes, I am aware that we might not be able to tell if the TCP socket disconnected without writing to it. That's why I am guessing that we should have some kind of external timeout to monitor this.
However, I think it's reasonable that httpclient didn't give us any write pipe, because for event stream, we're not going to write anything after the request has been sent. I am not sure if we could write anything.
On the other hand, IO.select on read pipe might not work well. I might need to check if there's a way to retrieve the underlying socket, instead of a read pipe. If we could really retrieve the socket, perhaps IO.select would be sufficient.
As for eventmachine, that's completely a different direction. Personally I won't put any further bet on eventmachine because it's kind of abandoned with good reasons.
I'll see if I could get the socket from httpclient. If not, perhaps I would try to use TCPSocket directly or net/http or some other HTTP client which could give us the socket. (Or try to give httpclient a patch in order to get the underlying sockets)
Thanks a lot for the investigation!

If you are able to get socket options, this MAY prove useful: http://stackoverflow.com/a/959054

Thanks for the reference. Hope this would work out.

I haven't figured out how to get the socket from httpclient, nor did I figure out how other HTTP client could do this easily. Before going deeper, I decided to push a few more changes, removing the use of IO#eof? because it could probably hang. I also tried that IO.select did work for pipes.
I don't know if this could fix anything, but I think I should still try it. It would be great if you could try it out, too. Greatly appreciated.
It's lying on branch timeout-for-eventsource-socket in rest-core, referenced above.

I changed the READ_WAIT to 35, since it's 30 +/- 1/2 second and it disconnects often when it's set to 30.
Then I ran it locally, and turned off my wifi (at 23:47:00), then reconnected my wifi (at 23:47:41). I've found this is as close of an approximation as I can get to firebase going down. The good news is it times out and reconnects. It's funny because I actually tried this same change awhile back but must not have tested it well enough. Wish I had before I went and wrote a second version of this with eventmachine.
I can't verify anything, but this may work. I'll see about trying to run this version for a bit in production.
You can likely guess where these log outputs are, but here's the repo: https://github.com/volksport/rest-core/blob/timeout-for-eventsource-socket/lib/rest-core/event_source.rb#L106
Disconn OK: Connection Opening... 2016-01-26 23:45:29.456
Inside onmessage_for loop 2016-01-26 23:45:29.457
Inside readline 2016-01-26 23:45:29.458
Inside readline 2016-01-26 23:45:29.459
Inside onmessage_for loop 2016-01-26 23:45:59.455
Inside readline 2016-01-26 23:45:59.455
Inside readline 2016-01-26 23:45:59.455
Disconn OK: keep-alive 2016-01-26 23:45:59.455
Inside onmessage_for loop 2016-01-26 23:46:29.598
Inside readline 2016-01-26 23:46:29.598
Inside readline 2016-01-26 23:46:29.598
Disconn OK: keep-alive 2016-01-26 23:46:29.598
Inside onmessage_for loop 2016-01-26 23:46:59.703
Inside readline 2016-01-26 23:46:59.704
Inside readline 2016-01-26 23:46:59.704
Disconn OK: keep-alive 2016-01-26 23:46:59.704
Disconn ERROR: EOFError EOFError 2016-01-26 23:47:34.740
Disconn ERROR: Reconnecting... 2016-01-26 23:47:35.741
Disconn ERROR: getaddrinfo: Name or service not known (xxxx.firebaseio.com:443) SocketError 2016-01-26 23:47:35.750
Disconn ERROR: Reconnecting... 2016-01-26 23:47:36.752
Disconn ERROR: getaddrinfo: Name or service not known (xxxx.firebaseio.com:443) SocketError 2016-01-26 23:47:36.757
Disconn ERROR: Reconnecting... 2016-01-26 23:47:37.758
Disconn ERROR: getaddrinfo: Name or service not known (xxxx.firebaseio.com:443) SocketError 2016-01-26 23:47:37.762
Disconn ERROR: Reconnecting... 2016-01-26 23:47:38.763
Disconn ERROR: getaddrinfo: Name or service not known (xxxx.firebaseio.com:443) SocketError 2016-01-26 23:47:38.768
Disconn ERROR: Reconnecting... 2016-01-26 23:47:39.769
Disconn ERROR: getaddrinfo: Name or service not known (xxxx.firebaseio.com:443) SocketError 2016-01-26 23:47:39.774
Disconn ERROR: Reconnecting... 2016-01-26 23:47:40.775
Disconn OK: Connection Opening... 2016-01-26 23:47:41.309
Inside onmessage_for loop 2016-01-26 23:47:41.311
Inside readline 2016-01-26 23:47:41.311
Inside readline 2016-01-26 23:47:41.311
Inside onmessage_for loop 2016-01-26 23:48:11.590
Inside readline 2016-01-26 23:48:11.590
Inside readline 2016-01-26 23:48:11.590
Disconn OK: keep-alive 2016-01-26 23:48:11.590

Great, thank you! We could probably see that
Firebase would send keep-alive for every 30
seconds, and whenever we set it to 35 seconds,
it means if Firebase somehow delayed the event
for 5 seconds then we'll just reconnect it.
There should probably have an option for this
in the future.
So though we can't verify if this does fix the issue,
this should still somehow improve the situation and
reduce the chances of getting stuck.
I'll release a new version with this patch soon if there's
no further concern.

I didn't intend to close this.

After a great than 1 hour (ONE HOUR+?!) downtime tonight on ss-dal5-nss-28 http://status.firebase.com/1363624/2016/02 It seems the reconnect is working properly! But, I'd still like to point to my issue #9 which still makes my daemon unstable.

Excellent, thank you very much!
p.s. I once thought Firebase could be a great data store, however given that it's not as stable as I would expect, and it doesn't seem to scale nicely, now I think it's still a great messaging channel, but should not be used as the main data store at all.