[BUGS-0.2.0] Renew Authentication tokens

When connecting to external systems, we assume that connections are persistent and last forever.
This is not always the case. For example, the snowflake authentication token expires after 1h and the connection returns an exception.
We have to capture this exception and re-establish the connection.
The snowflake log:
{"error":"ProgrammingError","messages":"<IP_ADDRESS>:37902 - \"GET /db/show\"                    500 Internal Server Error <ProgrammingError:                    (snowflake.connector.errors.ProgrammingError) 390114 (08001): Authentication token has expired.  The user must authenticate again.\n(Background on this error at: https://sqlalche.me/e/14/f405)>","traceback":"Traceback (most recent call last):\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/network.py\", line 755, in _post_request\n    ret = self._renew_session()\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/network.py\", line 529, in _renew_session\n    return self._token_request(REQUEST_TYPE_RENEW)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/network.py\", line 584, in _token_request\n    raise ReauthenticationRequest(\nsnowflake.connector.network.ReauthenticationRequest: 390114 (08001): Authentication token has expired.  The user must authenticate again.\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/base.py\", line 1094, in _commit_impl\n    self.engine.dialect.do_commit(self.connection)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/default.py\", line 686, in do_commit\n    dbapi_connection.commit()\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/connection.py\", line 824, in commit\n    self.cursor().execute(\"COMMIT\")\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/cursor.py\", line 977, in execute\n    ret = self._execute_helper(query, **kwargs)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/cursor.py\", line 694, in _execute_helper\n    ret = self._connection.cmd_query(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/connection.py\", line 1309, in cmd_query\n    ret = self.rest.request(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/network.py\", line 493, in request\n    return self._post_request(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/network.py\", line 758, in _post_request\n    raise ex.cause\nsnowflake.connector.errors.ProgrammingError: 390114 (08001): Authentication token has expired.  The user must authenticate again.\n\nThe above exception was the direct cause of the following exception:\n\nTraceback (most recent call last):\n  File \"/home/superduper/superduperdb/superduperdb/server/app.py\", line 35, in dispatch\n    return await call_next(request)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/middleware/base.py\", line 165, in call_next\n    raise app_exc\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/middleware/base.py\", line 151, in coro\n    await self.app(scope, receive_or_disconnect, send_no_error)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/middleware/exceptions.py\", line 65, in __call__\n    await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/_exception_handler.py\", line 64, in wrapped_app\n    raise exc\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/_exception_handler.py\", line 53, in wrapped_app\n    await app(scope, receive, sender)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/routing.py\", line 756, in __call__\n    await self.middleware_stack(scope, receive, send)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/routing.py\", line 776, in app\n    await route.handle(scope, receive, send)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/routing.py\", line 297, in handle\n    await self.app(scope, receive, send)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/routing.py\", line 77, in app\n    await wrap_app_handling_exceptions(app, request)(scope, receive, send)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/_exception_handler.py\", line 64, in wrapped_app\n    raise exc\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/_exception_handler.py\", line 53, in wrapped_app\n    await app(scope, receive, sender)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/routing.py\", line 72, in app\n    response = await func(request)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/fastapi/routing.py\", line 278, in app\n    raw_response = await run_endpoint_function(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/fastapi/routing.py\", line 193, in run_endpoint_function\n    return await run_in_threadpool(dependant.call, **values)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/starlette/concurrency.py\", line 42, in run_in_threadpool\n    return await anyio.to_thread.run_sync(func, *args)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/anyio/to_thread.py\", line 56, in run_sync\n    return await get_async_backend().run_sync_in_worker_thread(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/anyio/_backends/_asyncio.py\", line 2144, in run_sync_in_worker_thread\n    return await future\n  File \"/home/superduper/.local/lib/python3.10/site-packages/anyio/_backends/_asyncio.py\", line 851, in run\n    result = context.run(func, *args)\n  File \"/home/superduper/superduperdb/superduperdb/rest/app.py\", line 82, in db_show\n    return app.db.show(\n  File \"/home/superduper/superduperdb/superduperdb/base/datalayer.py\", line 272, in show\n    out = self.metadata.show_components()\n  File \"/home/superduper/superduperdb/superduperdb/backends/sqlalchemy/metadata.py\", line 397, in show_components\n    with self.session_context() as session:\n  File \"/usr/lib/python3.10/contextlib.py\", line 142, in __exit__\n    next(self.gen)\n  File \"/home/superduper/superduperdb/superduperdb/backends/sqlalchemy/metadata.py\", line 146, in session_context\n    session.commit()\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/orm/session.py\", line 1454, in commit\n    self._transaction.commit(_to_root=self.future)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/orm/session.py\", line 839, in commit\n    trans.commit()\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/base.py\", line 2469, in commit\n    self._do_commit()\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/base.py\", line 2659, in _do_commit\n    self._connection_commit_impl()\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/base.py\", line 2630, in _connection_commit_impl\n    self.connection._commit_impl()\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/base.py\", line 1096, in _commit_impl\n    self._handle_dbapi_exception(e, None, None, None, None)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/base.py\", line 2134, in _handle_dbapi_exception\n    util.raise_(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/util/compat.py\", line 211, in raise_\n    raise exception\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/base.py\", line 1094, in _commit_impl\n    self.engine.dialect.do_commit(self.connection)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/sqlalchemy/engine/default.py\", line 686, in do_commit\n    dbapi_connection.commit()\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/connection.py\", line 824, in commit\n    self.cursor().execute(\"COMMIT\")\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/cursor.py\", line 977, in execute\n    ret = self._execute_helper(query, **kwargs)\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/cursor.py\", line 694, in _execute_helper\n    ret = self._connection.cmd_query(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/connection.py\", line 1309, in cmd_query\n    ret = self.rest.request(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/network.py\", line 493, in request\n    return self._post_request(\n  File \"/home/superduper/.local/lib/python3.10/site-packages/snowflake/connector/network.py\", line 758, in _post_request\n    raise ex.cause\nsqlalchemy.exc.ProgrammingError: (snowflake.connector.errors.ProgrammingError) 390114 (08001): Authentication token has expired.  The user must authenticate again.\n(Background on this error at: https://sqlalche.me/e/14/f405)\n"}

show.json

If we reconnect will it work or do we need to fetch the token from somewhere?

I 'm guessing that reconnect should work (since it works on the first connection, I don't see why it shouldn't work on reconnect)

https://community.snowflake.com/s/article/Authentication-token-has-expired-The-user-must-authenticate-again
Specifically for snowflake, there is the possibility to allow the session to stay active indefinitely by setting CLIENT_SESSION_KEEP_ALIVE=TRUE.

Idea: retain a self.connect() callback in meta-data store and data-backend to reconnect without caching credentials.

The same problem exists in the apiserver in golang.


how to deploy a etcd cluster in different IDC

l want to understand  how to deploy a etcd cluster in different IDC
                                                                                thank you

Can you please provide more information?

What is your use case

What do you want to achieve for multi DC deployment? (Simple master slave backup? Consistent replication? Eventual consistent replication?)

Any other requirements?

@xiang90  our Micro service run in different idc，so l want to deploy a etcd cluster in different IDC，each Mirco service can connect one of member of the etcd cluster.

@huangsanye You want the etcd member to accept writes in both DC?

@xiang90  yes  in different dc

OK. Please read https://github.com/coreos/etcd/blob/master/Documentation/tuning.md#time-parameters. All you can do is to tune the timeout parameter. You have to accept the additional latency due to cross DC communication. Max throughput wont be affect a lot though.


Make Brakeman ignore recent SQL injection warnings

Add them to brakeman.ignore by running brakeman -I

Coverage remained the same at 85.823% when pulling 06b53bd9af74bc1239dd55306ec8ffef132a8d47 on ignore-description-sql-injection-182485007 into 138166b32d43186b6a09c70e104004f6bd9953e8 on master.


No alaska timezone

It should be covered by some other region with the same timezone. If you need Alaska anyway, you may provide overrides with timezones prop (more details in README)


fix(kube): Use KubeClusterAccessService for Helm operations [EE-2500]

Closes EE-2500
Changes:

Rename KubeConfigService and its usages to KubeClusterAccessService (is currently used for helm actions).
Modify api/http/handler/kubernetes/kubernetes_config.go to also use the KubeClusterAccessService, reduce duplicated logic.
Fix in KubeClusterAccessService to use the Host from incoming request (which is what is currently done for kubeconfig file generation), instead of hardcoding "localhost".
Remove unused variables handlerActivityContext

Closes https://github.com/portainer/portainer/issues/6742


[Quality] More informative error message when an argument is None in TensorDictModule

Description
TensorDictModule allows some arguments to be missing in the input tensordict, in which case a None value is used.
The error message that occurs if that value is actually necessary is misleading, always being something like "NoneType has no attribute shape" or similar.
We now capture errors, check if any input is None and if the error contains None, and turn the error message to something more indicative of what is going on.
Similarly, we capture errors like
td = TensorDict({"a": torch.zeros(())}, [])
td["a", "b"]

to let users know what is going on with the wrongful indexing.
Suggestions are welcome!

Codecov Report
Patch coverage: 90.90% and project coverage change: -1.93 :warning:

Comparison is base (e732ae3) 88.27% compared to head (06cc490) 86.34%.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #261      +/-   ##
==========================================
- Coverage   88.27%   86.34%   -1.93%
==========================================
  Files          28       28
  Lines        9593     9603      +10
==========================================
- Hits         8468     8292     -176
- Misses       1125     1311     +186

Flag
Coverage Δ

linux-cpu
86.27% <90.90%> (+<0.01%)
:arrow_up:

linux-gpu
?

linux-macos-cpu
86.22% <90.90%> (-0.08%)
:arrow_down:

linux-stable-cpu
86.30% <90.90%> (+<0.01%)
:arrow_up:

linux-stable-gpu
?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

tensordict/nn/common.py
77.77% <85.71%> (+0.22%)
:arrow_up:

test/test_nn.py
99.35% <100.00%> (+<0.01%)
:arrow_up:

test/test_tensordict.py
91.30% <0.00%> (-6.31%)
:arrow_down:

test/_utils_internal.py
96.92% <0.00%> (-3.08%)
:arrow_down:

tensordict/memmap.py
84.70% <0.00%> (-1.77%)
:arrow_down:

tensordict/tensordict.py
80.98% <0.00%> (-1.16%)
:arrow_down:

test/test_memmap.py
86.76% <0.00%> (-0.62%)
:arrow_down:

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

Tests are not passing let me have a look


New version: FMMLIB2D v0.3.2

Registering package: FMMLIB2D
Repository: https://github.com/ludvigak/FMMLIB2D.jl
Created by: @ludvigak
Version: v0.3.2
Commit: 3588b4021c79373ba688884128cf3c7ff5146962
Reviewed by: @ludvigak
Reference: https://github.com/ludvigak/FMMLIB2D.jl/commit/3588b4021c79373ba688884128cf3c7ff5146962#commitcomment-49261575

Right, another old package that needs some cleaning up! Let's see if I can manage to fix this.
[noblock]


feat: Replace the Figerona font with Poppins

Description

Related Issue

https://github.com/Pool-Of-Tears/Myne/issues/208
Type of change

feature
Pull Request checklist

[x] The commit message uses the conventional commiting method.
[x] Made sure that your PR is not duplicate
[x] Tests: This PR includes thorough tests or an explanation of why it does not (for bug fixes/features). Your PR should pass all CI checks in our Gtihub Actions Workflow
[ ] Screenshots: This PR includes screenshots or GIFs of the changes made or an explanation of why it does not (optional)

Thanks for your efforts. Overall, the changes look good. If possible, could you post some screenshots of the UI?

Sure. Here is one example

Sure. Here is one example

Thanks, it looks pretty good, I'll make some UI adjustments (if needed) after merging this successfully,

Also, please make sure to update the PR with the base (main) branch by resolving any conflicts, as I've made a few changes to the base branch since this PR was created. If you'd like, I can hold off on adding any more commits until this is merged, so you don't have to resolve conflicts again.

@licaon-kter Just pinging to let you know that the problematic font has been removed.

@starry-shivam feel free to ping when the next release is ready so we can remove the AF

@starry-shivam feel free to ping when the next release is ready so we can remove the AF

https://github.com/Pool-Of-Tears/Myne/releases/tag/v4.2.0

thanks https://gitlab.com/fdroid/fdroiddata/-/commit/bd4351ead156157a9bfc4a17d1990f8a351151c5


System.UnauthorizedAccessException: Access to the path 'C:\Users{My Name}\AppData\Local\Bloxstrap\Bloxstrap.exe' is denied. [BUG]

Acknowledgement of preliminary instructions

[X] I have read the preliminary instructions, and I am certain that my problem has not already been addressed.

What problem did you encounter?
I was installing base bloxstrap and got this error:
System.UnauthorizedAccessException: Access to the path 'C:\Users{My Name}\AppData\Local\Bloxstrap\Bloxstrap.exe' is denied.

https://github.com/pizzaboxer/bloxstrap/wiki/"Access-to-the-path-is-denied"-error-when-trying-to-reinstall-Bloxstrap


postinstall hook disappearing

Hi, several times I've been faced with this when trying to deploy to Heroku, and everytime I lost one night trying to solve the issue (call me goldfish but I tend to forget solutions to issues after 6 months): I don't know why or when or how, but sometimes the postinstall hook disappears from package.json, leading to the cryptic error EmberCli::BuildError:  has failed to build: TypeError: Cannot read property 'option' of undefined in the heroku logs. ember build --environment=production works well in the console so it's especially tricky to debug. Is there a way to add a warning from ember-cli-rails when the postinstall hook is missing?
Disclaimer: using ember-cli-rails-addon version 0.7.0 so apologies if this has been fixed in further releases.
https://github.com/thoughtbot/ember-cli-rails/issues/80

not sure that's my problem, closing


[tech-debt] Remove usage of OCS feature flags

For more details: https://issues.redhat.com/browse/RHSTOR-4531

https://github.com/red-hat-storage/odf-console/pull/1099


start with docker-compose fails

Expected Behavior
All run ))
Current Behavior
Not run ((
Steps to Reproduce

git clone repo
docker-compose build
docker-compose up

Error
$ sudo docker-compose up
Starting gpt4all-ui_webui_1 ... done
Attaching to gpt4all-ui_webui_1
webui_1  | Traceback (most recent call last):
webui_1  |   File "/srv/app.py", line 809, in <module>
webui_1  | Personality file not found. Please verify that the personality you have selected exists or select another personality. Some updates may lead to change in personality name or category, so check the personality selection in settings to be sure.
webui_1  | Checking discussions database...
webui_1  |     bot = Gpt4AllWebUI(app, socketio, config, personality, config_file_path)
webui_1  |   File "/srv/app.py", line 62, in __init__
webui_1  |     super().__init__(config, personality, config_file_path)
webui_1  |   File "/srv/pyGpt4All/api.py", line 53, in __init__
webui_1  |     self.chatbot_bindings = self.create_chatbot()
webui_1  |   File "/srv/pyGpt4All/api.py", line 73, in create_chatbot
webui_1  |     return self.backend(self.config)
webui_1  |   File "/srv/backends/llama_cpp/__init__.py", line 32, in __init__
webui_1  |     self.model = Model(
webui_1  |   File "/usr/local/lib/python3.10/site-packages/pyllamacpp/model.py", line 73, in __init__
webui_1  |     raise Exception(f"File {model_path} not found!")
webui_1  | Exception: File ./models/llama_cpp/gpt4all-lora-quantized-ggml.bin not found!
gpt4all-ui_webui_1 exited with code 1

@antirek was the docker build working for you?

you need to download model first, as it dont do it on its own, you have to choose how you download it..

you need to download model first, as it dont do it on its own, you have to choose how you download it..

Ok, @andzejsp, great thanks!
I don't understand it from readme.md and webui's error don't say me "download it independently" ))

@andzejsp
Oh, I see that webui.sh contain lines code which load gpt model, but in Dockerfile independent install code. May be use webui.sh for Dockerfile?

i dont think that webui.sh will work in dockerfile, cuz dockerphile loads assets from python directly, but the webui.sh has many different checks to see if you have python venv and other stuff.. also the webui.sh gives option to download default model. dockerfile does not, so you have to download any of the models https://github.com/nomic-ai/gpt4all-ui#llama_cpp-models and put in models/llama_cpp folder, mount the folder in docker and youre golden..


Plot a convex hull based on custom compositions

I created a notebook to plot a  convex hull for custom compositions. In the 3rd cell, users need to specify the input data such as elements, compositions, and cryspy-related parameters (I didn't provide the detailed information for these parameters. Please refer to the cryspy document.). This notebook assumes that the system compose of two elements, and doesn't support the scalability for larger systems including 3 or 4 elements. The calculation mode is set to crystal_u0 and the model version is set to 6.0.0. If users want to change these settings, they need to fix the code in utility.py.

投稿ありがとうございます。
MP_APIを利用されている場合、Versionによって大きく挙動が変わるため、以下のような動作確認Verをノートブックに記載いただけませんでしょうか。
Confirmed Version:
Python: 3.9.16
mp_api: 0.40.0
pymatgen: 2024.2.8


[BUG] Alerting not honouring PUT method

 Issue by thenom
Friday Jul 17, 2020 at 15:33 GMT
Originally opened as https://github.com/opendistro-for-elasticsearch/alerting/issues/228

Describe the bug
Cannot PUT a new monitor with a specified ID for a non-existant monitor:
PUT _opendistro/_alerting/monitors/flibble
{
  "type": "monitor",
  "name": "flibble",
  "enabled": true,
  "schedule": {
    "period": {
      "interval": 10,
      "unit": "MINUTES"
    }
...

Results in:
{
  "Message" : "Monitor with flibble is not found"
} {
  "_index" : ".opendistro-alerting-config",
  "_type" : "_doc",
  "_id" : "flibble",
  "found" : false
}

Is there any reason for this as this means that a search is required before hand to find if it exists in the cluster and then to perform a second call (either POST or PUT) based on the results of the search.  I am just in the process of setting up OpenDistro so not sure if this issue appears elsewhere.
https://tools.ietf.org/html/rfc2616#section-9.6

If the Request-URI does not point to an existing resource, and that URI is
capable of being defined as a new resource by the requesting user
agent, the origin server can create the resource with that URI.

If this method was allowed as stated then this would remove that extra step in automation and you could just overwrite the monitor.  I initially thought this might have been to inject the additional fields that appear in the monitor after the initial POST but this cant be the case because you still inject those fields during subsequent PUT operations when providing an existing _id.
Thanks,

 Comment by skkosuri-amzn
Wednesday Aug 19, 2020 at 16:32 GMT

Thanks for creating this issue. PUT _opendistro/_alerting/monitors/{id} : needs to create new monitor, if the given {id} is not present.

 Comment by aditjind
Wednesday Jun 02, 2021 at 03:26 GMT

Hi @thenom
According to the latest RFC7231, the PUT method definition states that:
A service that selects a proper URI on behalf of the client, after receiving a state-changing request, SHOULD be implemented using the POST method rather than PUT.
Since the ID for the monitors the plugin creates via POST method has the ID generated randomly (the document ID for the monitor document), we think this change would break the contract.
Let me know your thoughts.
Reference

Wanted to mention that @thenom made a comment in the old repo after this issue was migrated so that their response isn't missed. Please continue any further discussions in this issue.


[Feature]If you want to ask a question, use the shortcut keys

such as：ctrl + enter

Same demand，looking forward to follow-up.


Remove extra newlines from formatting which resulted in necessary double newlines

PR Summary
When formatting, the Group start and end added unnecessary newlines which resulted in double newlines in many cases.  Formatting changes are not considered breaking.
(get-module | out-string).replace("`n","\n`n")

Before:
\n
ModuleType Version    Name                                ExportedCommands\n
---------- -------    ----                                ----------------\n
Manifest   <IP_ADDRESS>    Microsoft.PowerShell.Management     {Add-Content, Clear-Content, Clear-Item, Clear-ItemProperty...}\n
Manifest   <IP_ADDRESS>    Microsoft.PowerShell.Utility        {Add-Member, Add-Type, Clear-Variable, Compare-Object...}\n
Script     2.0.0      PSReadLine                          {Get-PSReadLineKeyHandler, Get-PSReadLineOption, Remove-PSReadLineKeyHandler, Set-PSReadLineKeyHandler...}\n
\n
\n

After:
\n
ModuleType Version    Name                                ExportedCommands\n
---------- -------    ----                                ----------------\n
Manifest   <IP_ADDRESS>    Microsoft.PowerShell.Management     {Add-Content, Clear-Content, Clear-Item, Clear-ItemProperty...}\n
Manifest   <IP_ADDRESS>    Microsoft.PowerShell.Utility        {Add-Member, Add-Type, Clear-Variable, Compare-Object...}\n
Script     2.0.0      PSReadLine                          {Get-PSReadLineKeyHandler, Get-PSReadLineOption, Remove-PSReadLineKeyHandler, Set-PSReadLineKeyHandler...}\n
\n

There are still a few cases where the final output has two newlines (but not three anymore!).  This is a bit more complicated to fix and would need to track state that either a newline was the last thing output or the item is the last in a collection and doesn't need a separator.
Fix https://github.com/PowerShell/PowerShell/issues/7186
PR Checklist

[x] PR has a meaningful title

Use the present tense and imperative mood when describing your changes

[x] Summarized changes
[x] Change is not breaking
[x] Make sure all .h, .cpp, .cs, .ps1 and .psm1 files have the correct copyright header
[x] This PR is ready to merge and is not Work in Progress.

If the PR is work in progress, please add the prefix WIP: to the beginning of the title and remove the prefix when the PR is ready.

User-facing changes

[x] Not Applicable
OR
[ ] User-facing Documentation needed

[ ] Issue filed - Issue link:

Testing - New and feature

[ ] Not Applicable or can only be tested interactively
OR
[x] Make sure you've added a new test if existing tests do not effectively test the code changed

[x] Add [feature] if the change is significant or affects feature tests

Before:

    Directory: /Users/steve/repos/PowerShell

Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----           11/4/18  7:47 AM                assets

    Directory: /Users/steve/repos/PowerShell

Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----          10/26/18 10:24 AM                demos

    Directory: /Users/steve/repos/PowerShell

Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----          10/26/18 10:24 AM                docker

After:

    Directory: /Users/steve/repos/PowerShell

Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----           11/4/18  7:47 AM                assets

    Directory: /Users/steve/repos/PowerShell

Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----          10/26/18 10:24 AM                demos

    Directory: /Users/steve/repos/PowerShell

Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----          10/26/18 10:24 AM                docker

Here's example of get-process pwsh | format-list
Before:

Id      : 1626
Handles : 0
CPU     : 5688.4889976
SI      : 422
Name    : pwsh

Id      : 18927
Handles : 0
CPU     :<PHONE_NUMBER>
SI      : 18920
Name    : pwsh

Id      : 18928
Handles : 0
CPU     :<PHONE_NUMBER>
SI      : 422
Name    : pwsh

After:

Id      : 1626
Handles : 0
CPU     : 5688.0544032
SI      : 422
Name    : pwsh

Id      : 18927
Handles : 0
CPU     :<PHONE_NUMBER>
SI      : 18920
Name    : pwsh

Id      : 18928
Handles : 0
CPU     :<PHONE_NUMBER>
SI      : 422
Name    : pwsh

@iSazonov you are asking if it's ok to separate the groups with just a single newline vs two?  Seems fine to me and just as readable visually.  In the future, we should leverage vt100 as a way to provide visual indicators rather than rely on whitespace only.

@iSazonov  Reminder to add CL-XXX labels.


Release nginx ingress controller 0.9.0-beta.12

This change is

Coverage remained the same at 43.892% when pulling a90a641971dea73bf815919f01db70ee63488490 on aledbf:release-beta-12 into b791460206f81ab5870d2f588e15fe1bcbdecb76 on kubernetes:master.


[WFLY-14025] Added tests for cases when default datasource binding is removed from ee subsystem

Issue: https://issues.redhat.com/browse/WFLY-14025
This PR added some tests against the fix for WFLY-14025, which covers the following cases:

@Resource() DataSource ds; injection without name and lookup
@Resource(name="ds") DataSource ds; injection with name specified
@Resource(name="ds") DataSource ds; injection with name specified, and lookup is specified in jboss-web.xml
@Resource(name="ds") DataSource ds; simulates injection done in ServletContextListener

What I added in last push was adding permissions to be able to run with security manager enabled. :)

@bstansberry  The downstream PR has been merged(with approval of this one), can this one be merged as well ? thanks :)

@bstansberry  The downstream PR has been merged(with approval of this one), can this one be merged as well ? thanks :)


gemspec runtime dependencies not included in DEPENDENCIES section of Gemfile.lock

I am seeing this error in 1.10.6.  Seems to be a regression of bug #1041
Steps to reproduce:
$ bundle gem bundler_bug_test
add 'spec.add_runtime_dependency "httpclient"' before default development dependencies.
$ bundle install --path .bundle

And now you can see that httpclient is not required if you do "Bundler.require" in e.g. bundle exec irb, or just look at the Gemfile.lock.

Reading through the previous thread again, seems this is WONTFIX.  Count me as one more for the behavior being unintuitive.


Release/0.0.2

Changes in 0.0.2

@eopa: Add grunt bump for versioning (#3)

Coverage remained the same at 100.0% when pulling 7421e009002813371f58007b4a73b8e539a13edd on release/0.0.2 into 67292455b9b0abcc30f6e21e920edcb8c6903b37 on master.


max_drawdown incorrect if drawdown begins on first day of returns time series

Because we take cum_returns(returns, starting_value=1) to form the NAV time series off of which we calculate max drawdown, the first value of the NAV used in the max drawdown calculation is the portfolio value at the end of the first trading day. This means that when the first trading day is the first day of the max drawdown, we are not counting that day's loss in that max drawdown stat.
For example:
If the first trading day results in a 10% loss and subsequent trading days lead to a total 25% loss, we will be calculating max drawdown as:
(.90 - 0.75) / 0.90  = 0.16666666
when we should be calculating it as:
(1.0 - 0.75) / 1.0 =  0.25
I think the fix might be to append a dummy day with a value of 1 to the beginning of the df_cum time series in cum_returns in the case where there is no NaN in the first iloc.

I think this issue can be closed.

:+1:


Provide test:debug script out-of-the-box

Closes #3711

@gaearon is this still needed? If not, that's ok. I just would not like to devote time to fix the merge conflicts in case it's not.


Serverless chatterbot is here

I've tried to bring the chatterbot to serverless world and tried deployed in AWS Lambda function.
Check out this repo serverless-chatterbot deployed in AWS Lambda.

@gunthercox Can you link this example to Chatterbot Readme. Or may be add new page in docs regarding the community project. i.e)  channels community project

@rajasimon can you make PR to address this issue?

@vkosuri thanks I'm making the changes for the pull request. Also I've plan to do the DynamoDB storage adapter for Chatterbot. Just started out let's see how this thing goes...


VLAN options causing exceptions

When specifying VLANs during knife softlayer server create the Fog::Service.validate_options method is returning an exception. Specifically the following,
ERROR: ArgumentError: Missing required arguments: softlayer_username, softlayer_api_key
It looks like this method is getting called twice (possibly for Network.new and Service.new although I'm not too familiar with Fog internals) and the requirements remain the same but the options hash is empty the second time around.
Using pry-stack_explorer I'm able to get the following:
Showing all accessible frames in stack (18 in total):
--
=> #0  validate_options <Fog::Service.validate_options(options)>
#1 [method]  handle_settings <Fog::Service.handle_settings(settings)>
#2 [method]  new <Fog::Service.new(config=?)>
#3 [method]  new <Fog::Network.new(attributes)>
#4 [method]  [] <Fog::Network.[](provider)>
#5 [method]  vlan= <Fog::Compute::Softlayer::Server#vlan=(value)>
#6 [block]   block in merge_attributes <Fog::Attributes::InstanceMethods#merge_attributes(new_attributes=?)>
#7 [method]  merge_attributes <Fog::Attributes::InstanceMethods#merge_attributes(new_attributes=?)>
#8 [method]  initialize <Fog::Model#initialize(new_attributes=?)>
#9 [method]  initialize <Fog::Compute::Softlayer::Server#initialize(attributes=?)>
#10 [method]  new <Fog::Collection#new(attributes=?)>
#11 [method]  create <Fog::Collection#create(attributes=?)>
#12 [method]  run <Chef::Knife::SoftlayerServerCreate#run()>
#13 [method]  run_with_pretty_exceptions      <Chef::Knife#run_with_pretty_exceptions(raise_exception=?)>
#14 [method]  run <Chef::Knife.run(args, options=?)>
#15 [method]  run <Chef::Application::Knife#run()>
#16 [top]     <top (required)>
#17 [main]    <main>

The code ultimately raising the exception can be found at https://github.com/fog/fog-core/blob/master/lib/fog/core/service.rb#L236-L253 but perhaps https://github.com/fog/fog-softlayer/blob/master/lib/fog/softlayer/models/compute/server.rb#L201-L207 is the real culprit? As I said I haven't much dug into Fog ever, so this was where I ended up.
If you need any more info, just let me know. This one is thorny!

Here is my backtrace of the exception as well (e.backtrace)
=> ["/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/service.rb:246:in `validate_options'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/service.rb:270:in `handle_settings'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/service.rb:99:in `new'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/network.rb:16:in `new'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/network.rb:4:in `[]'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-softlayer-0.3.26/lib/fog/softlayer/models/compute/server.rb:205:in `vlan='",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/attributes.rb:118:in `block in merge_attributes'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/attributes.rb:113:in `each_pair'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/attributes.rb:113:in `merge_attributes'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/model.rb:20:in `initialize'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-softlayer-0.3.26/lib/fog/softlayer/models/compute/server.rb:53:in `initialize'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/collection.rb:112:in `new'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/collection.rb:112:in `new'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/fog-core-1.27.2/lib/fog/core/collection.rb:49:in `create'",
"/Users/hugespoon/.chefdk/gem/ruby/2.1.0/gems/knife-softlayer-0.3.6/lib/chef/knife/softlayer_server_create.rb:297:in `run'",
"/opt/chefdk/embedded/apps/chef/lib/chef/knife.rb:493:in `run_with_pretty_exceptions'",
"/opt/chefdk/embedded/apps/chef/lib/chef/knife.rb:174:in `run'",
"/opt/chefdk/embedded/apps/chef/lib/chef/application/knife.rb:139:in `run'",
"/opt/chefdk/embedded/apps/chef/bin/knife:25:in `<top (required)>'",
"/usr/bin/knife:33:in `load'",
"/usr/bin/knife:33:in `<main>'"]

Just realized this could be related to https://github.com/softlayer/knife-softlayer/issues/12

@hugespoon ,
Agreed, looks like the same issue at least at first glance.  Can you confirm that creating a ~/.fog file with softlayer credentials makes it go away?  That's both an immediate workaround as well as confirmation that it is being caused as per #12 .
Thanks.

Yeah, it did correct things for me.

@hugespoon thanks for letting me know.  So that's your workaround for now.  Marking this as a duplicate and closing it.  Will push a release with a fix today.

@hugespoon can you do me a favor reply with the --various --arguments you were using when you saw this error, I'm having trouble duplicating the error despite removing my ~/.fog file.

@hugespoon never mind I've got it happening for me now.

Might also be helpful to see your fog.yml file (with dummy values of course)

@cphrmky Sweet! Thanks for the quick fix.


Code 126: /bin/bash: ./alfred-chromium-workflow: Bad CPU type in executable

I just upgraded from 0.2.7 to 0.2.8 and got this error:

I deleted and reinstalled 0.2.7 to confirm something changed, and the error goes away, and cht works perfectly.
Steps to reproduce:

Download alfred-chromium-workflow.alfredworkflow 0.2.8
Open debugger in workflow.
In Alfred: cht anything
Notice "Code 126: /bin/bash: ./alfred-chromium-workflow: Bad CPU type in executable" error in debug console.

Workaround: revert to 0.2.7.
My system:
macOS Monterey 12.3.1 (21E258) on Intel chip.
Alfred 4.7 [1306] then upgraded to Alfred 5.0.2 [2073] and experienced the same issue.
It doesn't look like much changed in 0.2.8 executable-wise, but maybe the magefile version changes had some effect? ‾_(ツ)_/‾

I think this would be resolved on 0.2.9, but I can't test it because I don't intel mac now..
Would you mind testing if it works on intel mac if you are okay?

It works. Thanks again. 🙏

This issue is still present in the latest 0.3.0, the rollback using 0.2.9 is normal.


container without app container

How do i create a new container without inherit app container effect. Sometime we need the page that dont like other page (without old header or something like that.)

One of solutions is removing views from global App container and make your containers in child routes with index route:
return [
    {
      getComponent(nextState, cb) {
        const importModules = Promise.all([
          System.import('containers/YourMainContainer'),
        ]);

        const renderRoute = loadModule(cb);

        importModules.then(([component]) => {
          renderRoute(component);
        });

        importModules.catch(errorLoading);
      },
      indexRoute: {
      getComponent(nextState, cb) {
        const importModules = Promise.all([
          System.import('containers/Page/reducer'),
          System.import('containers/Page/sagas'),
          System.import('containers/Page'),
        ]);

        const renderRoute = loadModule(cb);

        importModules.then(([reducer, sagas, component]) => {
          injectReducer('page', reducer.default);
          injectSagas(sagas.default);

          renderRoute(component);
        });

        importModules.catch(errorLoading);
      },
      }
    },
];

It means that you can create your own main containers for page, for example, you need to have pages with header and pages without header, you create two containers AppWithHeader and AppWithoutHeader and make child routes inside them. Also read about IndexRoute to understand it's behavior.


MecanumDrive system does not have a test

Desired behavior
The existing system should be tested.
Alternatives considered

Implementation suggestion
Use the example world with the suggested commands in the XML comments at the top of the file.

https://github.com/gazebosim/gz-sim/blob/gz-sim7/examples/worlds/mecanum_drive.sdf

Additional context

I also have this issue, that It just does nothing.

Nevermind, I realized that the simulation was just not running, just press the orange play button on the bottom left. Or if you want  the simulation to run as soon as you launch gazebo, you need to add the -r flag which stands for run.
gz sim -r mecanum_drive.sdf


B-17809 Ability To Submit Empty Pro Gear

Agility ticket
Summary
When editing a ppm shipment either through the office api or the prime api, we can’t blank out the "Pro Gear Weight" and "Spouse Pro Gear Weight" fields.
How to test

Access officelocal
Login as a TOO
Select a PPM
Click edit shipment
Clear spouse pro gear input field
Save and continue
'0' should be saved as spouse pro gear amount

Frontend

[ ] There are no aXe warnings for UI.
[ ] This works in Supported Browsers and their phone views (Chrome, Firefox, Edge).
[ ] There are no new console errors in the browser devtools.
[ ] There are no new console errors in the test output.
[ ] If this PR adds a new component to Storybook, it ensures the component is fully responsive, OR if it is intentionally not, a wrapping div using the officeApp class or custom min-width styling is used to hide any states the would not be visible to the user.
[ ] This change meets the standards for Section 508 compliance.

Warnings

:warning:
Please add the JIRA issue key to the PR title (e.g. MB-123)

:warning:
This PR does not include changes to unit tests, even though it affects app code.

  Generated by :no_entry_sign: dangerJS against b6e70cbe7d7b49be5a73e87fda284a16c8ac0a03


Bug: env var priority: CLI value should override all others

I would expect the order of env var priority would be (highest taken first):

CLI
.env file
Defaults from env_var_or_default(...)

However the .env value clobbers the value given on the CLI
Reproduction:
justfile:
export SOME_VAL := env_var_or_default("SOME_VAL", "default")

@test:
    echo "SOME_VAL=$SOME_VAL"

.env:
SOME_VAL=from-file

just gives:
SOME_VAL=from-file

which is to be expected, but
SOME_VAL=fromcli just gives:
SOME_VAL=from-file

instead of:
SOME_VAL=fromcli

So there's no way to set env vars on the CLI if they are already set in the .env file.

Thanks for opening this issue! I agree that this is a bug. I believe that most dotenv implementations don't set environment variables that are already present in the environment.
As a workaround for now, what does just SOME_VAL=fromcli do? Just supports arguments of the form NAME=VALUE, which can override justfile variables. (Note that it's after just, not before it, so it's interpreted by Just and not the shell.)

imo the change is very welcome, even if it's breaking. i think most people would probably expect that this behavior already is implemented in the first place too

I'm definitely leaning towards doing this. Is this the norm across other .env implementations? I think it is, but I don't have a ton of experience with any of them.

So i did some digging to be certain, and it looks to be the norm
for node's dotenv they don't override existing variables

We will never modify any environment variables that have already been set. In particular, if there is a variable in your .env file which collides with one that already exists in your environment, then that variable will be skipped.

for go's godotenv, their Load function (which is used in the usage example), has the same behavior (they also have an Overload function that does override though)

It's important to note that it WILL NOT OVERRIDE an env variable that already exists - consider the .env file to set dev vars or sensible defaults

and the same for ruby

By default, it won't overwrite existing environment variables as dotenv assumes the deployment environment has more knowledge about configuration than the application does. To overwrite existing environment variables you can use Dotenv.overload.

so in all these cases if the user supplies the variable themselves, it "wins" over what is in the dotfile

Thank you very much for the research, eankeen! I think keeping Just's dotenv functionality close to other dotenv implementations is probably what users would most expect, so I added this in #649
Although I don't expect this to be disruptive, this is technically a breaking change, since users could have relied on the .env file overriding environment variables. To reflect this, I bumped the version from 0.6.1 to 0.7.0, and cut a new release with this change.
I just tagged 0.7.0, so binaries should be built and uploaded soon by continuous integration.
This don't technically fix this issue, since the issue is about CLI vs env variables. However, Just variables, set with just foo=bar, just --set foo bar, or foo := "bar", are distinct from .env and environment variables, so I don't think a just var set on the command line should necessarily override an environment variable, or vice versa. So, I'm going to go ahead and close this issue, although feel free to reopen or comment if I've overlooked something.

This change makes sense but only if it includes the overridability used by other tools as well. I believe the .env thing was started with the Ruby project mentioned above. It would be great if we could add something like set dotenv-override := true to match what was done with #469 and could be noted in the docs to achieve the prior behavior before v0.7.0.

@runeimp, so if set dotenv-override := true is set, variables from the .env would override set environment variables? Are there other tools that have this functionality? I'm also curious what the use case is, just so I understand the motivation. Adding a setting would be a pretty easy change, so I'm definitely not opposed to it.

I am using just to wrap a legacy build system, which is based on Makefiles.  The current workflow is heavily reliant on developers sourcing configuration scripts (ex: Yocto) before running make. This is unpractical for at least two reasons:

Configuration scripts tend to interfere with each other  in confusing ways
Tweaking the configuration requires restarting the user shells

This is why I am trying to move towards a just-based workflow with .env for shared configurations and explcit configuration script sourcing only in the relevant recipes.
Right now, I am trying to override the PATH from the .env file to expose basic utility tools (starting with make...) to every one. But my modifications are ignored because PATH is already defined in the environment.
Would this feature help in my use case? Could you suggest another approach?

@rohel01 Please don't comment on a 3-year-old issue asking for help. This repository has the "Discussions" tab enabled - you can also go to StackOverflow, various programming Discords, etc.

@hyperupcall The comment just above mine was asking for a use-case so I was providing one.
Opening a new discussion as you suggested anyway...

Oh sorry, that's my bad - then it's my appologies for misunderstanding and cluttering this discission


Traccar doesn't respond to received MXT protocol messages, causing disconnection.

As in other protocols, MXT protocol requires the server to give some feedback to the device from time to time. In the case of MXT protocol the feedback is an ACK message to be sent as soon as a position message is received. Without it, the device stops sending messages, the connection is broken and only reestablished a few minutes later.
Here is Traccar log for a device configured to send messages every 30 seconds:
2017-01-28 17:25:09  INFO: [B960ADB9] connected
2017-01-28 17:25:09 DEBUG: [B960ADB9: 5087 < ...
2017-01-28 17:25:09  INFO: [B960ADB9] id: ***
2017-01-28 17:26:22  INFO: [B960ADB9] disconnected

2017-01-28 17:26:23  INFO: [97587D17] connected
2017-01-28 17:26:23 DEBUG: [97587D17: 5087 < ...
2017-01-28 17:26:23  INFO: [97587D17] id: ***

2017-01-28 17:30:52  INFO: [FC01AD82] connected
2017-01-28 17:30:52 DEBUG: [FC01AD82: 5087 < ...
2017-01-28 17:30:52  INFO: [FC01AD82] id: ***
2017-01-28 17:33:52  INFO: [FC01AD82] disconnected

2017-01-28 17:33:53  INFO: [842D23D6] connected
2017-01-28 17:33:53 DEBUG: [842D23D6: 5087 < ...
2017-01-28 17:33:53  INFO: [842D23D6] id: ***

2017-01-28 17:38:15  INFO: [6F815030] connected
2017-01-28 17:38:17 DEBUG: [6F815030: 5087 < ...
2017-01-28 17:38:17  INFO: [6F815030] id: ***
2017-01-28 17:41:16  INFO: [6F815030] disconnected

2017-01-28 17:41:17  INFO: [3F276A4B] connected
2017-01-28 17:41:17 DEBUG: [3F276A4B: 5087 < ...
2017-01-28 17:41:17  INFO: [3F276A4B] id: ***

The ACK is like this:
0x01 + (device_descriptor + 0x02 + device_id + CRC_from_message + CRC_to_ACK) + 0x04
If there are any occurrence of bytes 0x01, 0x04, 0x10, 0x11 or 0x13 in the section between ( ), they must be changed to 0x1021, 0x1024, 0x1030, 0x1031 and 0x1033 respectively before transmission.
I checked this information monitoring the conversation between an MXT device and MXT PCtool (a software to configure the device). Here is an example:

I would need protocol documentation to check.

I don't have it. In fact it is super ultra high classified, for some reason I can't understand.
But I can send you all the packets I captured, de decoding made by PCtool and other intel I gathered.
I can even point the device to any IP and port you need so you can check yourself.
By the way, how did you implement the protocol decoder without the documentation?

I think I had the documentation somewhere, but it would be hard to find and it probably also out of date.
Where did you get the response format if you don't have the documentation?

@tananaev here: https://groups.google.com/d/msg/traccar-pt-br/KJclP_SzTQI/k9DGWYStCAAJ

DOCS:
2.2. Byte stuffing
The used byte stuffing method on this protocol is the insertion of one token byte (0x10), followed by the real byte added to 0x20. The bytes coded by this method are only: 0x01, 0x04, 0x10, 0x11 and 0x13.
Example
With Byte Stuffing process: 01 AC 33 CB D3 6A 00 20 10 2110 21 3D 8E 04 Without Byte Stuffing process: 01 AC 33 CB D3 6A 00 20 0101 3D 8E 04
3.1. ACK
This is the general acknowledgment command. Used for confirmation of position packets and other packets when necessary.
MT: 0x02; DATA FIELD: 2 bytes; UINT16 CRC_received;
CRC: The CRC16-CCITT calculation from DD until the last byte of DATA. CRC is calculated before the byte stuffing process.
Hope it helps

@drecchia

MT: 0x02; DATA FIELD: 2 bytes; UINT16 CRC_received;

This doesn't seem complete. MT might be "message type".

calculation from DD until

Where is DD? Might be "device descriptor".

The full frame is SOF + DD + MT + DEVID + DATA + CRC + EOF
SOF: Start of Frame, 0x01, 1 byte. This byte starts every packet sent;
DD: Device descriptor, according to the following table: If no encrypt:
0xA0: MXT-100 (portable, no 2.4Ghz transceiver)
0xA1: MXT-101 (portable, 2.4Ghz enabled)
0xA2: MXT-150 (automotive, no 2.4Ghz transceiver)
0xA3: MXT-151 (automotive, 2.4Ghz enabled)
0xA4: MXT-120
0xA5: iMXT
0xA6: MXT-140
0xA7: MXT-141
0xA8: MXT-100N
0xA9: MXT-101N
0xAA: G-100
0xAB: Reserved
0xAC: MXT-142
0xAD: MXT-130D
0xAE: Reserved
MESSAGE TYPE: Message type, 1 byte, described more ahead in this document.
DEVID: Device ID, 4 bytes;
For encrypted packets: the high 4 bit of the high byte is using to indicate the encrypt data added bytes, because the encrypt data must be 16 bytes align, so if the original data is not, it need added some bytes to align.
DATA: Reserved for data, size-varying according with message type and destination device type. This field is coded by the byte stuffing method explained on the next topic;
CRC: The CRC16-CCITT calculation from DD until the last byte of DATA. CRC is calculated before the byte stuffing process.
EOF: End of Frame, 0x04, 1 byte. This byte ends every packet sent.

Here is a related topic - #1633.

I have implemented the response. It needs to be tested though.

Took the messages below from Traccar log file.
           ST DD MT DEVIC_ID DATA      CRC  EN
received:  01 a6 31 ddccbbaa [omitted] f362 04
sent:      01 a6 02 aabbccdd 62f3      591c 04
should be: 01 a6 02 ddccbbaa f362      40ab 04

           ST DD MT DEVIC_ID DATA      CRC  EN
received:  01 a6 31 ddccbbaa [omitted] a3e4 04
sent:      01 a6 02 aabbccdd e4a3      b2d7 04
should be: 01 a6 02 ddccbbaa a3e4      b154 04

Explanation:

device id bytes are inverted
received crc bytes are inverted
the calculated CRC

is being calculated from ST until DATA (should be from DD ultil DATA)
is using 0xFFFF initial value (should use Xmodem 0x0000)
bytes are inverted

@gustavofcalmeida, thanks for the information. Please check if it works now.

Almost there. Check the pull request.

Gustavo, bom dia.
Você conseguiu resolver o problema com o rastreador da maxtrack?
Eu consegui fazer funcionar o modelo MXT 140, mas o modelo MXT 151 não funcionou. Aparece a seguinte mensagem no debug:
2018-08-02 08:40:52 DEBUG: [f5ad29f8: 5087 < <IP_ADDRESS>] HEX: 01a331de6b50000867ba07f4e61024351d46d3fedde1fffc10213a1030000000000000000000000000102112173100003002000000222a00002a5104 2018-08-02 08:40:52  WARN: [f5ad29f8] error - readerIndex(53) + length(4) exceeds writerIndex(56): UnpooledByteBufAllocator$InstrumentedUnpooledUnsafeHeapByteBuf(ridx: 53, widx: 56, cap: 60) - IndexOutOfBoundsException (... < MxtProtocolDecoder:153 < ExtendedObjectDecoder:51 < ... < WrapperContext:102 < ...)
Base o que pode estar acontecendo?
Grato.


I'd father's house

Checklist

[ ] I'm reporting a site feature request
[ ] I've verified that I'm running youtube-dl version 2021.12.17
[ ] I've searched the bugtracker for similar site feature requests including closed ones

Description

WRITE DESCRIPTION HERE

I wonder what it is?


switch to webpack 4

Upgrade to webpack 4
Reduce bundle size
Reduce build complexity (get rid of demos in build chain)

Closes #327, #324


test: add Magic Sea test and example

[x] add Magic Sea test and example
[x] use token info from common package
[x] yarn changeset

LGTM


Null pointer in RendererAdapter

When trying to create a Recyclerview in a Fragment I get the following null pointer exception. I'm sure I have missed something, but the documentation/example were using an activity, and I'm trying to do it from a Fragment, so I could not reuse everything from the example.
04-12 23:08:09.370    9172-9172/se.speedle.android E/AndroidRuntime﹕ FATAL EXCEPTION: main
java.lang.NullPointerException
        at me.alexrs.recyclerviewrenderers.adapter.RendererAdapter.onCreateViewHolder(RendererAdapter.java:66)
        at me.alexrs.recyclerviewrenderers.adapter.RendererAdapter.onCreateViewHolder(RendererAdapter.java:35)
        at android.support.v7.widget.RecyclerView$Adapter.createViewHolder(RecyclerView.java:4121)
        at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:3431)
        at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:3340)
        at android.support.v7.widget.LinearLayoutManager$LayoutState.next(LinearLayoutManager.java:1810)
        at android.support.v7.widget.LinearLayoutManager.layoutChunk(LinearLayoutManager.java:1306)
        at android.support.v7.widget.LinearLayoutManager.fill(LinearLayoutManager.java:1269)
        at android.support.v7.widget.LinearLayoutManager.onLayoutChildren(LinearLayoutManager.java:523)
        at android.support.v7.widget.RecyclerView.dispatchLayout(RecyclerView.java:1988)
        at android.support.v7.widget.RecyclerView.onLayout(RecyclerView.java:2237)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1671)
        at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1525)
        at android.widget.LinearLayout.onLayout(LinearLayout.java:1434)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.support.v4.widget.DrawerLayout.onLayout(DrawerLayout.java:890)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1671)
        at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1525)
        at android.widget.LinearLayout.onLayout(LinearLayout.java:1434)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1671)
        at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1525)
        at android.widget.LinearLayout.onLayout(LinearLayout.java:1434)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
        at android.view.View.layout(View.java:14289)
        at android.view.ViewGroup.layout(ViewGroup.java:4562)
        at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:1976)
        at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1730)
        at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1004)
        at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:5481)
        at android.view.Choreographer$CallbackRecord.run(Choreographer.java:749)
        at android.view.Choreographer.doCallbacks(Choreographer.java:562)
        at android.view.Choreographer.doFrame(Choreographer.java:532)
        at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:735)
        at android.os.Handler.handleCallback(Handler.java:730)
        at android.os.Handler.dispatchMessage(Handler.java:92)
        at android.os.Looper.loop(Looper.java:137)
        at android.app.ActivityThread.main(ActivityThread.java:5103)
        at java.lang.refle

My code is available at https://github.com/matt1as/speedleandroid2 and i think the offending code is in https://github.com/matt1as/speedleandroid2/blob/master/src/main/java/com/bryderi/speedle/android/fragments/DashboardFragment.java
Thanks in advance

Hi Mattias,
I have found the error in your code! As you have noticed, the classes that contains the data you want to display must implement Renderable. In your case, you want to show the data contained in Classified, and you have implemented Renderable in that class, the method getRenderableId must return the layout you will show in the RecyclerView. Everything okay until here. Now, this layout is used in the Factory to select the Renderer. Change this in your Factory and your code will work:
case R.layout.fragment_splash:
         return new ClassifiedRenderer(id);

for this
case R.layout.classified:
         return new ClassifiedRenderer(id);

I have also found another bug related with your layout. You can not use android:layout_weight with a RelativeLayout. Fix this in classified.xml.

Hello,
Great,thanks,now everything is working.
Regards
Mattias
Skickat från min iPhone

13 apr 2015 kl. 00:25 skrev Alejandro Rodríguez Salamanca<EMAIL_ADDRESS>Hi Mattias,
I have found the error in your code! As you have noticed, the classes that contains the data you want to display must implement Renderable. In your case, you want to show the data contained in Classified, and you have implemented Renderable in that class, the method getRenderableId must return the layout you will show in the RecyclerView. Everything okay until here. Now, this layout is used in the Factory to select the Renderer. Change this in your Factory and your code will work:
case R.layout.fragment_splash:
return new ClassifiedRenderer(id);
for this
case R.layout.classified:
return new ClassifiedRenderer(id);
I have also found another bug related with your layout. You can not use android:layout_weight with a RelativeLayout. Fix this in classified.xml.
—
Reply to this email directly or view it on GitHub.


fix：sticky column cover other column

Fix: #1914
1.First column add fixed attribute
2.right fixed column properties
Before

After

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.


Hide Menubar Icon

First of all, nice app and website.
Since the TouchBar is the primary place to use this, it would be great if we can disable the menu bar icon, to unclutter the menu bar.
Keep up the good work!
Cheers,
Michael

Thank you @MichMich! Already in tasks list, will add this feature very soon

Fixed by the PR https://github.com/pixel-point/mute-me/pull/9
@MichMich Happy to announce that we finally added that option.


Testing a cookbook that uses chef-vault in test-kitchen and chef-zero

moved from https://github.com/Nordstrom/chef-vault/issues/146

Trying to create some tests in test-kitchen for a cookbook that uses chef-vault. The cookbook actually executes ChefVault::Item.load(...). So I need to create that vault item in my test recipe.
I found chef_vault_item lwrp and trying to use it to create new vault:
chef_vault_secret 'testitem' do
  data_bag 'testbag'
  admins 'hello-world-ubuntu-1204'
  raw_data({ key: 'data' })
  search '*:*'
  action :nothing
end.run_action(:create)

include_recipe "my-cookbook-to-test"

However it fails with
ChefVault::Exceptions::AdminNotFound
------------------------------------
FATAL: Could not find hello-world-ubuntu-1204 in users or clients!

And there're actually no clients or users in chef-zero:
root@5a51fe47d4ca:~# knife client list -c /tmp/kitchen/client.rb -z

root@5a51fe47d4ca:~# knife user list -c /tmp/kitchen/client.rb -z

root@5a51fe47d4ca:~# knife node list -c /tmp/kitchen/client.rb -z
hello-world-ubuntu-1204

Any ideas on how to work it around?

You need to add the appropriate fixtures to your cookbook. For example, the chef-vault cookbook itself tests the LWRP with a 'hydroelectric' client

https://github.com/opscode-cookbooks/chef-vault/tree/master/test/integration/clients
https://github.com/opscode-cookbooks/chef-vault/tree/master/test/integration/nodes
https://github.com/opscode-cookbooks/chef-vault/blob/master/test/fixtures/cookbooks/test/recipes/chef_vault_secret.rb#L40

Got it, thanks!

The first two links are 404ing now. Can you update this post for other people like me who are finding this through searching?

Those were moved into fixtures. See .kitchen.yml:
https://github.com/chef-cookbooks/chef-vault/blob/d9961507a629bf6619780f399c73fa90546b7a5c/.kitchen.yml#L6-L7


“기타: 지원 리소스 공급자 등록” need to change “기타: Registers Support Resource Provider”

Module: LAB_02a_Manage_Subscriptions_and_RBAC_Entra.md
Lab/Demo: LAB02a
Task: 03
Step: 00
Description of issue
“기타: 지원 리소스 공급자 등록” need to change “기타: Registers Support Resource Provider”

Repro steps:

Hello contributor,
Thank you for your contribution! We are processing your suggestions and we will update you shortly.
Kind regards,
Microsoft Worldwide Learning Team


add chaining function Discovery to disable/enable discovery feature for package gclient; fix issue #2737

Codecov Report
Patch coverage: 100.00% and project coverage change: +0.01 :tada:

Comparison is base (740dfa5) 78.85% compared to head (300bfd5) 78.86%.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2738      +/-   ##
==========================================
+ Coverage   78.85%   78.86%   +0.01%
==========================================
  Files         633      630       -3
  Lines       51970    51635     -335
==========================================
- Hits        40980    40723     -257
+ Misses       8961     8899      -62
+ Partials     2029     2013      -16

Flag
Coverage Δ

go-1.15-386
?

go-1.15-amd64
?

go-1.16-386
78.86% <100.00%> (-0.01%)
:arrow_down:

go-1.16-amd64
?

go-1.17-386
?

go-1.17-amd64
?

go-1.18-386
?

go-1.18-amd64
?

go-1.19-386
?

go-1.19-amd64
?

go-1.20-386
?

go-1.20-amd64
?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

net/gclient/gclient_chain.go
100.00% <100.00%> (ø)

... and 18 files with indirect coverage changes

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.


Setting stroke width of StrokedRoundedRectView to 0.0f colors entire shape

Stroke width works for very small, non-zero values like 0.001f, but ends up covering entire shape at 0.0f. Can be seen in ViewTypesSample app by setting stroke width to zero and turning off timeline animations.

Thanks for testing @adielfernandez! Fixed in the latest commit on https://github.com/bluecadet/Cinder-BluecadetViews/pull/121.


Added downloading proper file extensions

For example, if a video stream source is m3u8 intead of downloading the file as x.m3u8 and renaming it to {anime_title}/{anime_title}{ep_no}.mp4, we download it as x.m3u8 and dont rename the extension so the extension will stay but the name will change to the configured value: {anime_title}/{anime_title}{ep_no}.m3u8. (except for nyaa which I have set to always be mkv bc that is almost always the file ext used)

This is fine, someone should do some testing first.

tested, also found out alot of sites dont work lmao
gogoanime: works,
kisscartoon: got EOF from server?,
twist: works,
animeflv: No supported Host on the 3 tested maybe broken?,
Itsaturday: nonetype error,
animefreak: Network error? maybe bc im using VPN
(Edit: nope)
animeout: works,
animixplay: works,
animesimple: has other issues,
ryuanime: has other issues,
animerush: has issues with node sandboxing,
animeflix: resource not found?,
kickass: works,
Dreamanime: times out,
erai-raws: 403 forbidden?,
watchmovie: works,
animekisa: node sandbox issue,
animedaisuki: vidlink domain name not found,
animevibe: cloudflare?,
yify: fuck yify... it timed out,
animefree: http 400 bad request?
voiranime: node sandbox issue,
vidstream: works

I'll do some tweaking to solve https://github.com/vn-ki/anime-downloader/issues/428 too.

I'll do some tweaking to solve #428 too.

you could essentially just not rename it when downloading from nyaa or a downloader specific site like animeout

waka waka waka waka waka waka waka waka I'm pacman

Closing in favor of #519

ah yes in favor of something that hasn't gone anywhere in a while
I also haven't done anything with this so it's partially my fault


New section: B-spline

Thank you for maintaining this cool website!
I would like to open a PR to create a new section B-spline.

BSplines.jl
BSplineKit.jl
BasicBSpline.jl (My package!)
NURBS.jl

I'm not familiar with these packages except for mine, so I'm planning to request reviews from the package authors for fairness.

I am all for it! Are the how-to resources sufficient to get you started on making a page, or would you require some help to initially create the page?

I am all for it! Are the how-to resources sufficient to get you started on making a page, or would you require some help to initially create the page?

I think the current how-to resources are sufficient! I will create a new page after #39 is approved.


wasm-pack test doesn't add $MY_CRATE/.cargo/config automatly

🐛 Bug description
When I follow this guide, it tells me to skip that step while wasm-pack test will do this for me, but when I run cargo test --target=wasm32-unknown-unknown, it gives me this error
error: could not execute process `C:\Users\34937\Desktop\learning-rust\wasm-pack-learn\target\wasm32-unknown-unknown\debug\deps\wasm_pack_learn-439f502539aed329.wasm` (never executed)

Caused by:
  %1 不是有效的 Win32 应用程序。 (os error 193)  # %1 is not a valid win32 program.   (os error 193)

after I manually added $MY_CRATE/.cargo/config, it compiles the test and work fine
🤔 Expected Behavior
The wasm-pack test should add the .cargo/config file as  the guide is said
👟 Steps to reproduce

run cargo generate --git https://github.com/rustwasm/wasm-pack-template, and imput a name( In my case is "wasm-pack-learn"
add a sample test in  $MY_CRATE/tests:

// test_answer.rs
use wasm_bindgen_test::*;
// use wasm_pack_learn;

#[wasm_bindgen_test]
fn it_answers() {
    assert_eq!(42, 42);
}

run wasm-pack test. This step should run the test
run cargo test --target=wasm32-unknown-unknown. This step should give error

🌍 Your environment
Include the relevant details of your environment.
wasm-pack version: 0.5.0
rustc version: 1.30.0-nightly (bb0896af1 2018-09-29)

To clarify, does step (3) successfully run the test? You shouldn't need to run (4) at all, (3) is doing it for you with the configuration knobs dialed in correctly.

@fitzgen Yes, Step (3) works, but according to the guide, I can also run tests with cargo test --target=wasm32-unknown-unknown after once the wasm-pack test had run?

I need to clarify the docs a bit, but here is the take away: you should just run wasm-pack test.
cargo test --target wasm32-unknown-unknown will only work if you set up the config yourself. What wasm-pack test is doing is running it configured ephemerally (through env vars). But you don't need to run cargo test after wasm-pack test -- wasm-pack test is running cargo test for you.
Going to close this issue since everything seems to be working as expected, except the docs are confusing. Thanks for opening this issue!


Remove redefinition of notification method in XRInterfaceExtension

XRInterfaceExtension was re-exposing the _notification method which resulted in a new _notification method that shadowed the inherited one.

Thanks!


My temp's file path is divided by '\', but the following if - statement need '/' is in the file path, causes the error template not  found. In fact, the file exists.

Environment:

Python version: 3.6.5
Jinja version:3.0.3
OS: Windows11

My temp's file path is divided by '\', but the following if - statement need '/' is in the file path, causes the error template not  found. In fact, the file exists.

Jinja uses forward slashes, regardless of the underlying OS. You cannot use backslashes unless you implement your own template loader (don't dot hat).