Internal Server Error

Describe the bug
Internal server error when opening web UI.
It might be something in my config file but I am unsure where to look. I have split up my config and automations into separate folders/files.
To Reproduce
Steps to reproduce the behavior:

Go to 'Web UI'
Click on 'Web UI'
???
Look at Error message

Expected behavior
See UI
Screenshots

Desktop (please complete the following information):

OS: Windows 11
Browser: Chrome
Version 104.0.5112.80 (Official Build) (64-bit)

Additional context
  File "/usr/local/lib/python3.9/site-packages/fastapi/applications.py", line 269, in __call__
    await super().__call__(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/applications.py", line 124, in __call__
    await self.middleware_stack(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/middleware/errors.py", line 184, in __call__
    raise exc
  File "/usr/local/lib/python3.9/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/usr/local/lib/python3.9/site-packages/starlette/middleware/cors.py", line 92, in __call__
    await self.simple_response(scope, receive, send, request_headers=headers)
  File "/usr/local/lib/python3.9/site-packages/starlette/middleware/cors.py", line 147, in simple_response
    await self.app(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/exceptions.py", line 93, in __call__
    raise exc
  File "/usr/local/lib/python3.9/site-packages/starlette/exceptions.py", line 82, in __call__
    await self.app(scope, receive, sender)
  File "/usr/local/lib/python3.9/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
    raise e
  File "/usr/local/lib/python3.9/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 670, in __call__
    await route.handle(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 266, in handle
    await self.app(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 65, in app
    response = await func(request)
  File "/usr/local/lib/python3.9/site-packages/fastapi/routing.py", line 227, in app
    raw_response = await run_endpoint_function(
  File "/usr/local/lib/python3.9/site-packages/fastapi/routing.py", line 162, in run_endpoint_function
    return await run_in_threadpool(dependant.call, **values)
  File "/usr/local/lib/python3.9/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool
    return await anyio.to_thread.run_sync(func, *args)
  File "/usr/local/lib/python3.9/site-packages/anyio/to_thread.py", line 31, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "/usr/local/lib/python3.9/site-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread
    return await future
  File "/usr/local/lib/python3.9/site-packages/anyio/_backends/_asyncio.py", line 867, in run
    result = context.run(func, *args)
  File "/app/src/api/routes/automations.py", line 20, in list_autos
    return ListData(
  File "pydantic/main.py", line 339, in pydantic.main.BaseModel.__init__
  File "pydantic/main.py", line 1038, in pydantic.main.validate_model
  File "pydantic/fields.py", line 868, in pydantic.fields.ModelField.validate
  File "pydantic/fields.py", line 899, in pydantic.fields.ModelField._validate_sequence_like
  File "/app/src/automations/manager.py", line 25, in find
    yield from load_automation(auto, tags.get(auto.get("id", ""), {}))
AttributeError: 'str' object has no attribute 'get'
ERROR:hypercorn.error:Error in ASGI Framework
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/hypercorn/asyncio/task_group.py", line 21, in _handle
    await invoke_asgi(app, scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/hypercorn/utils.py", line 247, in invoke_asgi
    await app(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/fastapi/applications.py", line 269, in __call__
    await super().__call__(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/applications.py", line 124, in __call__
    await self.middleware_stack(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/middleware/errors.py", line 184, in __call__
    raise exc
  File "/usr/local/lib/python3.9/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/usr/local/lib/python3.9/site-packages/starlette/middleware/cors.py", line 92, in __call__
    await self.simple_response(scope, receive, send, request_headers=headers)
  File "/usr/local/lib/python3.9/site-packages/starlette/middleware/cors.py", line 147, in simple_response
    await self.app(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/exceptions.py", line 93, in __call__
    raise exc
  File "/usr/local/lib/python3.9/site-packages/starlette/exceptions.py", line 82, in __call__
    await self.app(scope, receive, sender)
  File "/usr/local/lib/python3.9/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
    raise e
  File "/usr/local/lib/python3.9/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 670, in __call__
    await route.handle(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 266, in handle
    await self.app(scope, receive, send)
  File "/usr/local/lib/python3.9/site-packages/starlette/routing.py", line 65, in app
    response = await func(request)
  File "/usr/local/lib/python3.9/site-packages/fastapi/routing.py", line 227, in app
    raw_response = await run_endpoint_function(
  File "/usr/local/lib/python3.9/site-packages/fastapi/routing.py", line 162, in run_endpoint_function
    return await run_in_threadpool(dependant.call, **values)
  File "/usr/local/lib/python3.9/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool
    return await anyio.to_thread.run_sync(func, *args)
  File "/usr/local/lib/python3.9/site-packages/anyio/to_thread.py", line 31, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "/usr/local/lib/python3.9/site-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread
    return await future
  File "/usr/local/lib/python3.9/site-packages/anyio/_backends/_asyncio.py", line 867, in run
    result = context.run(func, *args)
  File "/app/src/api/routes/automations.py", line 20, in list_autos
    return ListData(
  File "pydantic/main.py", line 339, in pydantic.main.BaseModel.__init__
  File "pydantic/main.py", line 1038, in pydantic.main.validate_model
  File "pydantic/fields.py", line 868, in pydantic.fields.ModelField.validate
  File "pydantic/fields.py", line 899, in pydantic.fields.ModelField._validate_sequence_like
  File "/app/src/automations/manager.py", line 25, in find
    yield from load_automation(auto, tags.get(auto.get("id", ""), {}))
AttributeError: 'str' object has no attribute 'get'

This appears in general error logs when I click Open UI

hmmm, so based on the error, it seems that Shortumation failed to locate a valid automation file.
yield from load_automation(auto, tags.get(auto.get("id", ""), {}))
AttributeError: 'str' object has no attribute 'get'

means that at least one of the automations is not an object...
do you mind sharing a bit more about your setup?

Yes I am. I have an empty automations.yaml file and config for the split files looks like this

Here's an example of my folder structure and an automation

HAOS using the Add On store, no docker etc

Ok, I see. In that case this is something I need to fix. I have had a chance to test split configs properly, and now this seems like something that I need to address asap. Related https://github.com/asosnovsky/Shortumation

Hmm maybe but I just commented out my automation config so that I was left with a blank automations.yaml and it still did the same thing.
I restarted the add on and I had the same errors before and after.

I have same problem.
https://xxxx.duckdns.org:8123/api/hassio_ingress/C-s7eJ3nyk4ZRgYPW0IlL5qRzXAz33nDZfNva6JWKNw/automations/list
richiesta: POST
Codice di stato: 500 Internal Server Error
Indirizzo remoto: <IP_ADDRESS>:8123
Criterio relativo al referrer: strict-origin-when-cross-origin
in browser:
{"detail":"Method Not Allowed"}

Hmm maybe but I just commented out my automation config so that I was left with a blank automations.yaml and it still did the same thing.
I restarted the add on and I had the same errors before and after.

I see. I am undergoing a refactor of the automation loader, gonna add a few tests for empty automation files

I have same problem. https://xxxx.duckdns.org:8123/api/hassio_ingress/C-s7eJ3nyk4ZRgYPW0IlL5qRzXAz33nDZfNva6JWKNw/automations/list richiesta: POST Codice di stato: 500 Internal Server Error Indirizzo remoto: <IP_ADDRESS>:8123 Criterio relativo al referrer: strict-origin-when-cross-origin
in browser: {"detail":"Method Not Allowed"}

Yea, I am gonna try to get the refactor out soon. I had a long work week, but I will try to address these issues asap.

@swap83 @Sku1ly Take a look at the new release v0.6.1

@asosnovsky perfect thank you, straight in after correcting a few missing ID files.
Appreciate the fix

Thank you. Now it’s work!


Migrate helm agent to 3.x.x

What this PR does / why we need it:
Migrate litmus-helm-agent to use version 3.x.x of litmus.
Upgrading to litmusctl 1.2.0.
Which issue this PR fixes
fixes #450
Special notes for your reviewer:
Should we change the change of the litmus-helm-agent to litmus-helm-infra ?

LGTM, Thanks @Calvinaud for contribution!!


New data plane contract proposal

Signed-off-by: Francesco Guardiani<EMAIL_ADDRESS>Fixes #142

Proposed Changes

New data plane contract, in order to support the future re-implementations of kafka source and kafka channel
Propagated changes across all project
Changed protobuf docker to the original one (the jaegertracing one is a fork)
Changed protobuf package used in golang

LGTM for the contract.

/retest

/test pull-knative-sandbox-eventing-kafka-broker-unit-tests

/retest

It seems to be flaky as this one: https://github.com/knative-sandbox/eventing-kafka-broker/issues/179#issuecomment-693294685


:wa (write all) only saves current buffer

The :wa command will only save the buffer you are currently viewing/editing, but not any others.

I can reproduce this 100% of the time by just having two buffers open with unsaved changes, typing :wa and only the one I'm on is saved.

This should be fixed now as part of the work for https://github.com/onivim/oni2/pull/3419/


parser.y: Always populate SelectField offset

👋 This is my time contributing code to this project, so please let me know if I need to do more work to get this approved. I'm happy to add tests, documentation, etc.
What problem does this PR solve?
This is a partial solution to #910
What is changed and how it works?
ast.SelectField already has an Offset field. I've updated parser.y to populate this field whenever an ast.SelectField is created.

 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.

Any feedback for this pull request? Is this something you'd be interested in merging if I fixed the test failures?

Any feedback for this pull request? Is this something you'd be interested in merging if I fixed the test failures?

Sorry for the late reply. I thought this is still WIP..

Sorry for the late reply. I thought this is still WIP..

No worries! I was hoping to get feedback before I did too much work. Thanks for explaining how Offset is currently being populated, as I think it makes this PR unnecessary.

I finally got around to testing this; the current behavior works perfectly.


revert animation block change

Reverting animation block work around and deferring fix to Franklin core team.
Should expect to see the animation blocks breaking again on the preview page, compared to stage.
Resolves: MWPW-137872
Test URLs:

Before: https://stage--express--adobecom.hlx.live/express/learn/blog/android-users-meet-adobe-spark-post?martech=off
After: https://revert-animation-change--express--adobecom.hlx.page/express/learn/blog/android-users-meet-adobe-spark-post?martech=off

Codecov Report

Merging #362 (cae4275) into stage (d143358) will decrease coverage by 0.03%.
Report is 2 commits behind head on stage.
The diff coverage is 12.50%.

@@            Coverage Diff             @@
##            stage     #362      +/-   ##
==========================================
- Coverage   31.12%   31.09%   -0.03%
==========================================
  Files         122      122
  Lines       25065    25062       -3
==========================================
- Hits         7801     7793       -8
- Misses      17264    17269       +5

Files
Coverage Δ

express/scripts/scripts.js
37.67% <ø> (-0.26%)
:arrow_down:

express/blocks/animation/animation.js
23.43% <12.50%> (ø)

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


Air blower can't accept heat except from heatpipes.

I have been playing around with the air blower and I was experimenting with trying to get it to work in 1.20. It seems that the only way that I have found is to use a piece of heat pipe attached to the heat source in order to transmit the heat. Would it be possible to amend this behavior? Eg the blaze burner directly heats the refinery above but needs a piece of heat pipe to transmit into the blower.

Edit: Nevermind. It started working?

I should probably rebalance how heating works and also make it more clear in the in-game book, so thank you for the feedback!


The core atpm algorithm is not... quite right

So, I'm hitting some edge cases in our core atpm algorithm and I think we have some design issues.
Notation
I use A->B to mean "A depends on B"
Greedy approach is insufficient
Currently our approach to dependency resolution is "greedy", that is we proceed vaguely as follows:

Parse A's manifest, learn A->B, A->C
Choose a version of B
Parse B's manifest, find no dependencies
Parse C's manifest, learn C->B, but with particular version constraints on B
If the version constraints were not satisfied by the earlier choice in 2, fail.
There may be a version of B that satisfies both requirement 2 and 4, but because 2 was processed first, we never "backtrack" to a version of B that also meets requirement 4.

It's not clear to me what the right solution here is.  Fundamentally, we are not able to see the path A->C->B before we fetch C, so we cannot merely reorder them up front to resolve the issue.  Nor can we know, when we hit condition 6, whether or not a satisfactory version of B exists, because the satisfactory version of B may introduce new dependencies, violating 3 and altering the system further.
Perhaps I need to research how other people solve this problem, but the obvious algorithms to me are to backtrack and try again, which has awful worst-case performance and may not even halt (!)
Atlock
The next problem is that we have an interaction with the above and the atlock.
I believe we currently ignore the atlock completely for packages that aren't the outermost, which may be the most sensible thing we can do.  However I don't think we've thought through the details:

Suppose we have an end-user application, App
The application depends on two libraries, Logging and Network
Network also depends on Logging
Network developers are aware of some bugs in new Logging versions and so they pin to a particular commit in Network/build.atlock
App developers will see no effect of this, because external/Network/build.atlock is not consulted during atpm fetch of App.
They are then running Network in an unsupported configuration and who knows what happens now.

I see no obvious solution here either.
ping @owensd @dunkelstern

Concerning atlock: This is by design, only the toplevel atlock is used so the user of the libs can fix a conflict by pinning a specific version. When a sub-library finds a bug in a dependency it is supposed to use the follow up version (x.y.z+1 or x.y+1.z) as it's dependency. If you have to pin a commit there you'll have to manually specify that in a readme or something currently. So the problem with the greedy approach can be fixed by pinning on the toplevel (which is not optimal but workable)


Add support for SSL Keystores

Introduce an GemfireSslProperties (gemfire.security.ssl.*)
Extends GemfireClientCacheConfiguration to covert the GemfireSslProperties into native Gemfire/Geode SSL properties.
Added SslGemfireSinkIntegrationTests test for the sink gemfire app. But had to disable the existing GemfireSinkIntegrationTests due to test infrastructure racing conditions.

Resolve #12

@artembilan , i've pushed couple of commits to address most of the issues above. Still the interfering ITests is not solved.

@tzolov ,
Let me know if you are going to do anything else here, otherwise it is good to go for merging.

@artembilan have somehow wrongly assumed that this issues resolved.
Just pushed the latest changes. Since it is been a while you may consider re-reviewing it again :(


Start adding irmin with eio

Should go in ocaml5.nix

ah, this will need to be updated to eio v0.12

Since I'm not using this I'll just close in hopes that someone actually fixes irmin + eio and we can add it then


Dependency not found, relative module was not found

I installed anime with npm install anime and require it in my assets/js/homepage.js file to later bundle it using webpack-encore and I get the following output after running npm run dev:
> @ dev /path/to/project
> encore dev

Running webpack ...

 ERROR  Failed to compile with 5 errors                                                                                12:19:11

This dependency was not found:

* fs in ./node_modules/anime/auth.js, ./node_modules/request/lib/har.js

To install it, you can run: npm install --save fs

This relative module was not found:

* ./api in ./node_modules/anime/auth.js, ./node_modules/anime/search.js and 1 other
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! @ dev: `encore dev`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the @ dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/user/.npm/_logs/2018-06-21T17_19_11_575Z-debug.log

The fs package is already installed in my project, however, acording to the package's README (node_modules/fs/README.md) fs is "not currently in use"
The following is my webpack.config.js:
var Encore = require('@symfony/webpack-encore');

Encore
    .setOutputPath('public/assets/')
    .setPublicPath('/assets')
    .cleanupOutputBeforeBuild()
    .enableSourceMaps(!Encore.isProduction())
    .addEntry('js/app', './assets/js/app.js')
    .addStyleEntry('css/app', './assets/sass/app.sass')
    .addEntry('js/homepage', './assets/js/homepage.js')
    .addStyleEntry('css/homepage', './assets/sass/homepage.sass')
    .enableSassLoader()
;

module.exports = Encore.getWebpackConfig();

Is there any way to fix the dependency and relative module error?

Wrong package, sorry


chore: Bump version to 3.4.0

Detail

Prepare version for the 3.4.0 release

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

AWS CodeBuild CI Report

CodeBuild project: GitHubDistributedCodeBuild6-jWcl5DLmvupS
Commit ID: 0360e8a6d2b83b3ebc83d176cd4d9406ac9e7f7c
Result: SUCCEEDED
Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

AWS CodeBuild CI Report

CodeBuild project: GitHubCodeBuild8756EF16-4rfo0GHQ0u9a
Commit ID: 0360e8a6d2b83b3ebc83d176cd4d9406ac9e7f7c
Result: SUCCEEDED
Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository


HystrixCommandMetrics metrics overide

The metrics hash map used to store command metrics in HystrixCommandMetrics is using the HystrixCommandKey.name() as the map key.
When we have 2 commands with the same HystrixCommandKey but from different HystrixCommandGroupKey they collide and only one is saved to the metrics.
@ezraroi

Yes, this sounds like it's working as expected.  In practice, we've not seen collisions of the sort you're describing.

Is there a way to change your command names to avoid the collision?
Adding group key would reduce the possibility of collisions, but of course you could still have the same group and command name.
Doing some string manipulation to get a key is straightforward, but happens at high-volume, so might affect performance.

Hi,
Of course there is a way to give different names and that is the way i fixed it now.
But when using @HystrixCommamd the default name is the method name. By chance we had 2 methods with the aame name from different groups os they colided... I think that it would be better to differ the commands by a composite key of key and group, just like you won't assume that 2 people are the same juat by their first name.
What do you think?
E. G.
Using feign client this scenario is not possible as the command names are already composed of the class name and method name

Yeah, possibly the difference is that we don't use Javanica internally.  Maybe Javanica could use class+method name?  That seems like a reasonable solution - what do you think?

Yes that will also make sense. I wonder what is the use of the group anyways...

@regevbr It's intended to provide grouping above and beyond thread pools.  We haven't gotten much mileage out of it internally, though, so I mostly agree with you.

But thread poola are configured individually of groups. I can mix and match them as I please. My common sense led me to believe that it is uswd to distinguish between commands with same name

The intent was for for:

commands to be at the call level
groups to be at the system level
threadpools to be an implementation detail that often matches group but sometimes does not

I can't speak for usage outside of Netflix, but internally, most of our dashboards only display command name, so people have gotten into the habit of putting distinct long names into the command.

Closing due to inactivity


Added filtering of emails and websites

Now user can choose to filter only profanity via previous syntax or filter additional content such as website and/or emails.

Ok so now it should work in both Swift and Objective C.

I used Dictionaries for Objective C and I am using that dictionary to make an array of enums which is working in the tests.


facebook workplace action

adds the Facebook Workplace action
adds install endpoint to deliver Workplace access token

@jdavidson @wilg @nickfogler Please look this over and hit me with comments or change requests. Can hop on a call if needed. (btw, I tried rebasing this but ran into some issues with the directory name integrations vs. actions. Lemme know if you want me to work through that.)


Added connect middleware for less that supports force mode

The middleware that comes with connect doesn't support a force mode, so if you do any imports it won't regenerate your css file when you just change the imported files; this is a port of the stylus middleware to properly support both force and compress modes, as well as allowing the optimization setting.

+1

This really should be pulled in, seriously.


Unable to run "make generate" - fails due to Golang version issues

Bug Report
What did you do?

Upgraded the operator-sdk to version 1.3 from version 1.0
Followed the upgrade steps and updated my code
Run make generate

What did you expect to see?
Expected make generate to work properly
What did you see instead? Under which circumstances?
Got the following, I was on Go version 1.13
go: creating new go.mod: module tmp
go: found sigs.k8s.io/controller-tools/cmd/controller-gen in sigs.k8s.io/controller-tools v0.3.0
# encoding
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# sync/atomic
flag provided but not defined: -p
usage: asm [options] file.s ...
Flags:
  -D value
    	predefined symbol with optional simple value -D=identifier=value; can be set multiple times
  -I value
    	include directory; can be set multiple times
  -S	print assembly and machine code
  -V	print version and exit
  -debug
    	dump instructions as they are parsed
  -dynlink
    	support references to Go symbols defined in other shared libraries
  -e	no limit on number of errors reported
  -gensymabis
    	write symbol ABI information to output file, don't assemble
  -o string
    	output file; default foo.o for /a/b/c/foo.s as first argument
  -shared
    	generate code that can be linked into a shared library
  -trimpath string
    	remove prefix from recorded source file paths
# unicode
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# internal/race
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# runtime/internal/atomic
flag provided but not defined: -p
usage: asm [options] file.s ...
Flags:
  -D value
    	predefined symbol with optional simple value -D=identifier=value; can be set multiple times
  -I value
    	include directory; can be set multiple times
  -S	print assembly and machine code
  -V	print version and exit
  -debug
    	dump instructions as they are parsed
  -dynlink
    	support references to Go symbols defined in other shared libraries
  -e	no limit on number of errors reported
  -gensymabis
    	write symbol ABI information to output file, don't assemble
  -o string
    	output file; default foo.o for /a/b/c/foo.s as first argument
  -shared
    	generate code that can be linked into a shared library
  -trimpath string
    	remove prefix from recorded source file paths
# unicode/utf8
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# runtime/internal/sys
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# internal/cpu
flag provided but not defined: -p
usage: asm [options] file.s ...
Flags:
  -D value
    	predefined symbol with optional simple value -D=identifier=value; can be set multiple times
  -I value
    	include directory; can be set multiple times
  -S	print assembly and machine code
  -V	print version and exit
  -debug
    	dump instructions as they are parsed
  -dynlink
    	support references to Go symbols defined in other shared libraries
  -e	no limit on number of errors reported
  -gensymabis
    	write symbol ABI information to output file, don't assemble
  -o string
    	output file; default foo.o for /a/b/c/foo.s as first argument
  -shared
    	generate code that can be linked into a shared library
  -trimpath string
    	remove prefix from recorded source file paths
# internal/nettrace
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# math/bits
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# k8s.io/apimachinery/pkg/selection
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# unicode/utf16
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# container/list
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# crypto/subtle
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# crypto/internal/subtle
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# vendor/golang.org/x/crypto/cryptobyte/asn1
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# golang.org/x/tools/internal/semver
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# vendor/golang.org/x/crypto/internal/subtle
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# internal/goversion
compile: version "go1.13.15" does not match go tool version "go1.15.7"
# vendor/golang.org/x/crypto/curve25519
flag provided but not defined: -p
usage: asm [options] file.s ...
Flags:
  -D value
    	predefined symbol with optional simple value -D=identifier=value; can be set multiple times
  -I value
    	include directory; can be set multiple times
  -S	print assembly and machine code
  -V	print version and exit
  -debug
    	dump instructions as they are parsed
  -dynlink
    	support references to Go symbols defined in other shared libraries
  -e	no limit on number of errors reported
  -gensymabis
    	write symbol ABI information to output file, don't assemble
  -o string
    	output file; default foo.o for /a/b/c/foo.s as first argument
  -shared
    	generate code that can be linked into a shared library
  -trimpath string
    	remove prefix from recorded source file paths
# runtime/cgo
flag provided but not defined: -p
usage: asm [options] file.s ...
Flags:
  -D value
    	predefined symbol with optional simple value -D=identifier=value; can be set multiple times
  -I value
    	include directory; can be set multiple times
  -S	print assembly and machine code
  -V	print version and exit
  -debug
    	dump instructions as they are parsed
  -dynlink
    	support references to Go symbols defined in other shared libraries
  -e	no limit on number of errors reported
  -gensymabis
    	write symbol ABI information to output file, don't assemble
  -o string
    	output file; default foo.o for /a/b/c/foo.s as first argument
  -shared
    	generate code that can be linked into a shared library
  -trimpath string
    	remove prefix from recorded source file paths
make: *** [controller-gen] Error 2

Following the error I thought I needed to upgrade Go, did it and now i'm at 1.15, same error
Environment
Operator type:
/language go
Kubernetes cluster type:
Google Kubernetes Engine 1.17
$ operator-sdk version
operator-sdk version: "v1.3.0", commit: "1abf57985b43bf6a59dcd18147b3c574fa57d3f6", kubernetes version: "v1.19.4", go version: "go1.15.6", GOOS: "darwin", GOARCH: "amd64"
$ go version (if language is Go)
Was
go version go1.13.5 darwin/amd64
Now
go version go1.15.7 darwin/amd64
$ kubectl version
Client Version: version.Info{Major:"1", Minor:"17+", GitVersion:"v1.17.14-dispatcher", GitCommit:"766e62361387c284022a97270f0997d67ae792d0", GitTreeState:"clean", BuildDate:"2020-12-01T16:16:00Z", GoVersion:"go1.13.9", Compiler:"gc", Platform:"darwin/amd64"}
Server Version: version.Info{Major:"1", Minor:"17+", GitVersion:"v1.17.16-gke.1600", GitCommit:"e68636cfa1f22582957abefcc274c576d87e69b3", GitTreeState:"clean", BuildDate:"2021-01-12T09:19:41Z", GoVersion:"go1.13.15b4", Compiler:"gc", Platform:"linux/amd64"}

Possible Solution
No idea
Additional context
My operator's go.mod is:
module github.com/test/operator

go 1.15

require (
	github.com/go-logr/logr v0.1.0
	github.com/hashicorp/consul/api v1.7.0
	github.com/vmware-tanzu/velero v1.4.3
	k8s.io/api v0.18.6
	k8s.io/apimachinery v0.18.6
	k8s.io/client-go v0.18.6
	k8s.io/klog v1.0.0
	k8s.io/klog/v2 v2.0.0
	sigs.k8s.io/controller-runtime v0.6.4
)

replace k8s.io/api v0.0.0 => k8s.io/api v0.18.6

Hi @zonnie,
Operator-SDK 1.3 should be having controller-runtime upgraded to 0.7.0 and controller-tools to 0.4.1. Can you bump these two versions and check again?

I am also facing the same issue.

@rajendragosavi can you cross check that the decencies of the project are as required for the latest operator sdk version. If you are still facing issues, please feel free to raise an issue.


amplify.yml backend phase in monorepo

Environment information
System:
  OS: Windows 11 10.0.22631
  CPU: (16) x64 13th Gen Intel(R) Core(TM) i7-13620H
  Memory: 2.14 GB / 31.68 GB
Binaries:
  Node: 20.14.0 - C:\Program Files\nodejs\node.EXE
  Yarn: undefined - undefined
  npm: 10.8.1 - C:\Program Files\nodejs\npm.CMD
  pnpm: undefined - undefined
NPM Packages:
  @aws-amplify/auth-construct: 1.3.0
  @aws-amplify/backend: 1.2.1
  @aws-amplify/backend-auth: 1.1.3
  @aws-amplify/backend-cli: 1.2.5
  @aws-amplify/backend-data: 1.1.3
  @aws-amplify/backend-deployer: 1.1.0
  @aws-amplify/backend-function: 1.4.0
  @aws-amplify/backend-output-schemas: 1.2.0
  @aws-amplify/backend-output-storage: 1.1.1
  @aws-amplify/backend-secret: 1.1.1
  @aws-amplify/backend-storage: 1.1.2
  @aws-amplify/cli-core: 1.1.2
  @aws-amplify/client-config: 1.3.0
  @aws-amplify/deployed-backend-client: 1.4.0
  @aws-amplify/form-generator: 1.0.1
  @aws-amplify/model-generator: 1.0.5
  @aws-amplify/platform-core: 1.1.0
  @aws-amplify/plugin-types: 1.2.1
  @aws-amplify/sandbox: 1.2.1
  @aws-amplify/schema-generator: 1.2.1
  aws-amplify: 6.6.0
  aws-cdk: 2.156.0
  aws-cdk-lib: 2.156.0
  typescript: 5.5.4
AWS environment variables:
  AWS_NODEJS_CONNECTION_REUSE_ENABLED = 1
  AWS_SDK_LOAD_CONFIG = 1
  AWS_STS_REGIONAL_ENDPOINTS = regional
No CDK environment variables

Describe the bug
When running a build in amplify my backend phase never triggers from this amplify.yml
version: 1
applications:
  - appRoot: .
    backend:
      phases:
        preBuild:
          commands:
            - echo "Backend preBuild step started"
            - amplify --version
            - echo "Backend preBuild step finished"
        build:
          commands:
            - echo "Backend build step started"
            - amplify status
            - amplifyPush --simple
            - amplify codegen models
            - mkdir -p cloud/lib/amplify/lib
            - amplify export --out cloud/lib/amplify/lib
            - echo "Backend build step completed"
        postBuild:
          commands:
            - echo "Custom postBuild step completed"
      artifacts:
        baseDirectory: cloud/lib/amplify
        files:
          - '**/*'
  - appRoot: ui/corvision
    frontend:
      phases:
        preBuild:
          commands:
            - echo "Frontend preBuild step started"
            - export FLUTTER_ROOT=$HOME/flutter
            - mkdir -p $FLUTTER_ROOT
            - curl -o flutter.tar.xz https://storage.googleapis.com/flutter_infra_release/releases/stable/linux/flutter_linux_3.24.2-stable.tar.xz
            - tar xf flutter.tar.xz -C $HOME
            - export PATH="$PATH:$FLUTTER_ROOT/bin"
            - flutter precache
            - flutter --version
            - echo "Frontend preBuild step completed"
        build:
          commands:
            - echo "Frontend build step started"
            - flutter pub get
            - flutter build web --release --verbose
            - echo "Frontend build step completed"
      artifacts:
        baseDirectory: build/web
        files:
          - '**/*'

Not sure if there is something wrong with my amplify.yml or what but I've tried a bunch of different commands and formats in the backend phase and none of them trigger/get called.
appID: d1gwep07t2uubt Region: use-east-2
Reproduction steps
try to deploy in amplify

Hi @scott-elgaard 👋 , thanks for reaching out. I observed that the AMPLIFY_MONOREPO_APP_ROOT environment variable is set to ui/corvision for the app d1gwep07t2uubt. Thus, the commands that are present under the appRoot: ui/corvision defined in the amplify.yml file will be executed i.e. the frontend build phase.
To ensure the backend build phase is executed, you will need to update the amplify.yml file as follows:
version: 1
applications:
  - appRoot: ui/corvision
    backend:
      phases:
        preBuild:
          commands:
            - echo "Backend preBuild step started"
            - amplify --version
            - echo "Backend preBuild step finished"
        build:
          commands:
            - echo "Backend build step started"
            - amplify status
            - amplifyPush --simple
            - amplify codegen models
            - mkdir -p cloud/lib/amplify/lib
            - amplify export --out cloud/lib/amplify/lib
            - echo "Backend build step completed"
        postBuild:
          commands:
            - echo "Custom postBuild step completed"
    frontend:
      phases:
        preBuild:
          commands:
            - echo "Frontend preBuild step started"
            - export FLUTTER_ROOT=$HOME/flutter
            - mkdir -p $FLUTTER_ROOT
            - curl -o flutter.tar.xz https://storage.googleapis.com/flutter_infra_release/releases/stable/linux/flutter_linux_3.24.2-stable.tar.xz
            - tar xf flutter.tar.xz -C $HOME
            - export PATH="$PATH:$FLUTTER_ROOT/bin"
            - flutter precache
            - flutter --version
            - echo "Frontend preBuild step completed"
        build:
          commands:
            - echo "Frontend build step started"
            - flutter pub get
            - flutter build web --release --verbose
            - echo "Frontend build step completed"
      artifacts:
        baseDirectory: build/web
        files:
          - '**/*'

Please note that if your amplify directory exists at the root, you can run cd command to adjust/switch the directories.
You can learn more about the monorepo yaml syntax here: https://docs.aws.amazon.com/amplify/latest/userguide/monorepo-configuration.html#monorepo-yml-syntax.


Broken links on cloud ducumentation

The are some links to images and notebooks on the Cloud documentation that are broken
e.g:
curl https://raw.githubusercontent.com/ploomber/projects/master/guides/cloud-notebook-simple/plot.ipynb -o plot.ipynb

Different repo


out-of-the-box @angular/core not found from @ngrx

Steps to reproduce and a minimal demo of the problem
Following the Getting Started guide.

clone the angular2-seed-advanced repo
npm install
npm start

What steps should we try in your demo to see the problem?

/Users/lorenerickson/Source/cw/composer-web/node_modules/@ngrx/store/ng2.d.ts(1,39): error TS2307: Cannot find module '@angular/core'.
[17:10:06] TypeScript: 1 semantic error
[17:10:06] TypeScript: emit succeeded (with errors)
[17:10:06] Finished 'build.js.dev' after 3.35 s
[17:10:06] Starting 'build.index.dev'...
[17:10:06] gulp-inject 5 files into index.html.
[17:10:06] gulp-inject 4 files into index.html.
[17:10:06] gulp-inject 1 files into index.html.
[17:10:06] Finished 'build.index.dev' after 56 ms
[17:10:06] Finished 'build.dev' after 3.95 s
[17:10:06] Starting 'server.start'...
[17:10:06] Finished 'server.start' after 27 ms
[17:10:06] Starting 'watch.dev'...
[17:10:06] Finished 'watch.dev' after 52 ms
[17:10:06] Finished 'serve.dev' after 4.03 s
[BS] Access URLs:
 ---------------------------------------
       Local: http://localhost:5555/
    External: http://<IP_ADDRESS>:5555/
 ---------------------------------------
          UI: http://localhost:3001
 UI External: http://<IP_ADDRESS>:3001
 ---------------------------------------
[BS] Serving files from: dist/empty/

Observe correlating error in javascript console of browser running app

<EMAIL_ADDRESS>Failed to load resource: the server responded with a status of 404

Current behavior
Out of the box, with no other changes, I would expect the seed project to build and serve something.  It doesn't.
Expected/desired behavior
Clone, build, serve.  Show me something awesome.
Other information

I'll try to update to RC tonight or at some point tomorrow. In meantime you can lock angular version to beta.17 and ngrx to 1.4.0

Thanks, I've been involved in a laying the foundation for what will be a very large project, and ng2/typescript seem great, but I can appreciate that trying it keep up with ng2 builds can be a full time job.

@lorenjerickson I have the versions locked for time being but will get this updated to RC as soon as I get a chance.

Update to rc.1 should be complete at some point today. Just awaiting @ocombe to merge a PR for ng2-translate. https://github.com/NathanWalker/angular2-seed-advanced/issues/62

You can now use v2.1 of ng2-translate :)

Thank you sir!

Master is now updated to rc.1 👍

gratzi!


jupyter_notebook_version

Here is a list of the changes I made:

Most notably, I converted your README file to a Jupyter Notebook. This gives the ability to use Markdown and have runnable Python code as well. If a user wants to download it, they can edit and run the code examples on their own computer. It is also possible to view it on GitHub but the notebook is read-only.

Currently, the code examples can be run using both Python 2 & 3. I imported print_function from __future__ so the code examples could use the print function in both versions of Python. If you didn't want to use the print function (or statement in Python 2) you could always change the examples to use assert. Example: assert 1 + 1 == 2. If there is an error, it would be displayed below the corresponding cell.

I added a couple other ways to reverse a list and one other way to reverse a string.

I added a bit of explanation about the slice syntax to your copy section. I also added a couple examples using copy.copy() and copy.deepcopy().

I added a list comprehension version of creating a list out of a string.

I modified your for/else loop example. It seemed too vague to me as an example of why someone would want to use else. I think my changes make it clear why for/else is used.

I added two small example on list comprehensions. The first is the classic list comprehension to get only even numbers. The second example shows how to write a nested for loop. I added that because some people get confused as to the order of arguments in a nested list comprehension. Hopefully that is a clear example.

I raised an issue on your original repo detailing some of these things (I'll probably go and close it now). I saw you fixed the variable names (nice!) and I thought maybe it would be better for you to see an example of the Jupyter Notebook.
It is up to you which direction you want your python-tips repo to go. You can choose to keep it as a markdown file or switch to Jupyter notebook that has markdown AND runnable code (with syntax highlighting).
Either way, good luck!

Hi
Thanks for your contributing. I'm glad to see your suggestion and useful changes.I saw your issue before but I don't have enough time to answer it, just applied your changes.
Actually I'm new to Python and I have some questions.
If I want to add a new section, do I have to edit both README and Jupyter Notebook? if yes how can I do this?
thanks

You are correct, that is the problem with having two different versions of the same thing. Right now you would have to edit both.
I didn't want to delete your README in case you didn't want to use the Jupyter notebook version. Basically, it comes down to a choice of the markdown file or the notebook. I wanted to leave that decision up to you.
If you choose to go with the notebook, you should probably just modify your README to be a standard description for the python-tips repo and then do the editing of the tips inside the Jupyter notebook.

Thanks
Could you please apply the changes to the README file as well as Jupyter Notebook?
I think its good if we have both README and Jupyter Notebook. But maybe it's hard to edit and contributing for others. README has more readability and easy to use.

Sure, I can apply the changes to README. I think it would be better to just choose one though.
How about I just delete the Jupyter notebook but apply the changes to the README? I can't think of a way to update them both at the same time (there might be a way, I just don't know). It just doesn't seem right to make people have to edit two files.
[D]on't [R]epeat [Y]ourself

Yes that's right. So please send a pr after apply the changes.

Ok, I'll close this one and send you a different pull request when I'm done.
I'm heading to bed though, so it won't be for at least 8 hours!

Hey
I'm waiting for your PR. if you don't have enough time please let me know then I'll added your tips.
thanks for contributing.


topics: Fix topic order after moving message without automated notice.

Previously, when a message was moved between two topics without sending an automated notice, the ordering of these topics in the left sidebar was not updated.
This is because the updated max_message_id of stream_topic_history was always computed before the moved message object's channel/topic were updated. This caused the max_message_id of stream_topic_history which determines the ordering of topics to always be the same.
This is fixed by making sure that the channel/topics of the objects of the messages which were supposed to be moved were updated before we compute this max_message_id.

Fixes https://chat.zulip.org/#narrow/channel/9-issues/topic/topic.20order.20after.20moving.20messages/near/1976960

Self-review checklist

[x] Self-reviewed the changes for clarity and maintainability
(variable names, code reuse, readability, etc.).

Communicate decisions, questions, and potential concerns.

[x] Explains differences from previous plans (e.g., issue description).
[x] Highlights technical choices and bugs encountered.
[x] Calls out remaining decisions and concerns.
[ ] Automated tests verify logic where appropriate.

Individual commits are ready for review (see commit discipline).

[x] Each commit is a coherent idea.
[x] Commit message(s) explain reasoning and motivation for changes.

Completed manual review and testing of the following:

[x] Visual appearance of the changes.
[x] Responsiveness and internationalization.
[ ] Strings and tooltips.
[ ] End-to-end functionality of buttons, interactions and flows.
[ ] Corner cases, error conditions, and easily imagined bugs.

Can you clarify which specific code you're trying to move this past? I feel like the existing structure seemed pretty intentional (of having a fixed point where we edit the message object's attributes), and it might be the case we should instead move the relevant stream_topic_history logic down instead of moving this up.

@amanagr how do you think we should fix this?

We actually needed to move the stream_topic_history.remove_messages to happen after the message property update. I verified that fix manually.

Merged, thanks @roanster007 and @amanagr!


Add qmin and qmax parameters to the codec context

Allows applications to control the min and max quantisers used for encoding.
Also add a test to ensure the encoder is behaving as we expect.
(Just to explain the context here a bit, we're making much more use of PyAV in our standard Raspberry Pi software, so hopefully this will generate quite a few new users. I'm keen to get the tweaks and small new features on our fork back onto mainline here, because that's better for everyone, so there will probably be "a few" small pull requests like this. Thanks!)

You need to add type stubs. You might want to think about when the user tries to access it when it's a decoder.
Other than that, it looks good.

You need to add type stubs. You might want to think about when the user tries to access it when it's a decoder. Other than that, it looks good.

Hi, thanks for the quick reply! Just a couple of questions...

By "type stubs" do you mean putting new entries into the corresponding codeccontext.pyi file? I'll push an update with that change!

I was wondering about the decoder side of things. So far as I can tell, I don't think the decoder knows directly about qmin and qmax - they're just directives to the encoder, does that sound right? In principle I would have expected the decoder to be able to tell you the quantiser used for a frame (which would obviously bound the limits the encoder must have had), but I couldn't see it in the underlying AVFrame struct. Have I maybe missed something?

Thanks!


Use EKS-like status

What this PR does / why we need it:
Updates EKS deployment guide to make it more EKS-like
Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #493
Special notes for your reviewer:
The PROXY_IP name is now a misnomer, but shouldn't matter in practice as it'll resolve under the hood. Left as-is since we use that same variable name elsewhere and changing it would probably do more harm than good.
Github doesn't appear to want to let me add non-org member reviewers of my choice, but @harshal-shah does this look good to you? I don't have an EKS cluster ready to check myself, so this is a combination of the suggested change from the issue and a status that looks more or less like examples I can find in AWS docs.

LGTM


[Bug]Unexpected input when hold down Backspace

Bug reports
go version go1.16.2 linux/amd64
I just use this for recording command history,so only Input and Prefix being used as follow
func completer(t prompt.Document) []prompt.Suggest {
	return []prompt.Suggest{}
}

func executor(cmdstr string) {
}
......
	client := jsonrpc.NewClient(conn)
	// reader := bufio.NewReader(os.Stdin)
	opts := new(prompt.Option)
	p := new(prompt.Prompt)
	flag := true
	for {
		// reader := bufio.NewReader(strings.NewReader("env"))
		if *mode == "local_cmd" {
			*opts = prompt.OptionPrefix("LOCAL CMD>")
		} else if *mode == "remote_cmd" {
			*opts = prompt.OptionPrefix("REMOTE CMD>")
		} else if *mode == "sql" {
			*opts = prompt.OptionPrefix("SQL>")
		}
		if flag {
			p = prompt.New(executor, completer, *opts)
			flag = false
		}
		cmdstr = (*p).Input()
		// lineBytes, _, _ := reader.ReadLine()
		statment := strings.Replace(string(cmdstr), "\n", "", -1)
		if statment == "exit" {
			client.Close()
			conn.Close()
			handleExit()
			break
		} else if statment != "" {
			process(mode, &statment, client)
		} else {
			fmt.Println()
		}
	}

Expected Behavior
when I hold down backspace to delete characters before the cursor, it keeps moving forward, even prompt-string like "SQL>" be deleted and reprint forwarded
Current Behavior and Steps to Reproduce

Context
Please provide any relevant information about your setup. This is important in case the issue is not reproducible except for under certain conditions.

Operating System:
CentOS Linux release 7.7.1908 (Core)
TERM Xterm/vt100
Terminal Emulator: (i.e. iTerm2)
mobaXterm v20.5
tag of go-prompt or commit revision:
github.com/c-bata/go-prompt v0.2.6

It worked fine with Xshell...


Refactor of sequence collections and alignments

The problem
First, let's define the sequence collection classes. These are classes that allow manipulations of multiple sequences, either as unaligned or aligned groups.
The current implementations of classes in cogent3/core/alignment.py are excessively complex. We have 2 classes for alignments, that have the same API but differ in two important aspects:

ArrayAlignment can be sliced with a stride, e.g. aln[::3] works, but Alignment does not support this
Alignment can be annotated but ArrayAlignment does not support this

There are performance differences too, ArrayAlignment is based on numpy arrays and so feasibly more memory efficient.
So we need to reduce these to a single class that has the union of features, but is more efficient. In addition, the SequenceCollection class will also be updated.
The solution
We will decouple the interfaces (i.e. SequenceCollection and Alignment) from the details of their implementation. We will do this through two types of objects:

a SeqData class which handles the underlying storage of sequences (and it's counterpart AlignedSeqData for aligned sequences)
a single sequence "view" class, e.g. the SeqView class which is already in use for sequences

Objects under (1) and (2) will satisfy an interface defined by abstract base classes.
The purpose of (1) is classes that return views [i.e. (2)] on their data. Those views are bound to the Sequence (as is done currently) and Aligned instances that belong to their SequenceCollection and Alignment containers.
Responsibilities of SeqData classes
These classes provide storage of sequence name indexed data. They provide methods for getting a view of an individual member of the storage. They also provide methods used by those views to select subsets of individual members (e.g., a slice of a sequence) for different return types, e.g., string and numpy arrays. These classes also have a moltype etc...
Responsibilities of SeqDataView classes
These are views into the SeqData classes and are bound to a .data (or .seq) attribute of Sequence and Aligned.
Objects are sliced as per SeqView; that is, the operation is used to update the slice state, but the underlying data is only modified when needed.
The view classes have a .parent attribute, the SeqData container that generated the view.
Qualifiers
SeqData is immutable, and it knows nothing of the enclosing class.
Refactor of SequenceCollection
At present, the SequenceCollection.seqs attribute points to Sequence instances. The Sequence._seq attribute is a SeqView instance that contains the actual string.
We will change the above so that:

SequenceCollection has a ._seqdata attribute which is a  SeqData instance.

SequenceCollection.seqs is a property that indexes into the  SeqData instance,  either via sequence name or integer.

Indexing returns a Sequence, but now Sequence._seq is a SeqDataView, which is linked to the parent storage

We need to modify SequenceCollection to take a SeqData instance. All conversions of standard sequence data into a SeqData instance should be handled via make_unaligned_seqs(new_style=True).
Refactor of Alignment and Aligned
At present, the Alignment.seqs attribute points to Aligned instances. The Aligned.data attribute is a Sequence and the Aligned.map attribute is an IndelMap instance.
The challenge here is that alignment's can be sliced, e.g. aln[::3]. If we mirror the design for unaligned sequences then we would make Alignment.seqs an AlignedSeqData instance and that means slicing of the Alignment needs to be recordable somehow by AlignedSeqData. One way to handle this is to have a single attribute which is a SliceView (perhaps called SliceRecord) but can be applied to data not bound to it, e.g.
seq = ...
slice_record = SliceRecord(start, stop, step)
new_slice_record = slice_record[2:4:3]
sliced = new_slice_record.apply(seq)

The advantage of this approach is that the slice operation only needs to be applied to a single SliceRecord object.
When a user indexes Alignment.seqs, AlignedSeqData returns an Aligned instance which has a single .seq attribute. This is now an AlignedSeqDataView. This view does not record slicing, but relies on that being done by AlignedSeqData when the AlignedSeqData.get_seq_str() or AlignedSeqData.get_seq_array() methods are called. Those methods return both the IndelMap and the Sequence
Tasks

[x] discuss designing an abstract base class to define an interface for recording slice history
[x] merge in changes from develop branch into seq-collections-refactor
[ ] Write out the state flow for a slicing operation on an Alignment

Refactor of Alignment and Aligned - in more detail
Old API

Alignment.seqs attribute points to Aligned instances.
The Aligned.data attribute is a Sequence, and the Aligned.map attribute is an IndelMap instance.

New API

Alignment.seqs an AlignedData instance.
When a user indexes Alignment.seqs, AlignedData creates and returns an Aligned instance.
Aligned has a .seq attribute, which points to an AlignedDataView.
AlignedData has a single attribute to record the slicing of an alignment, which is a SliceRecord
AlignedData handles slicing via.get_seq_<str>/<array>() methods - which return an IndelMap and the Sequence

The Challenge
The challenge here is that alignments can be sliced, e.g. aln[::3]. So, slicing of an Alignment needs to be recordable somehow by AlignedData. One way to handle this is to have a single attribute which is a SliceRecord but can be applied to data not bound to it, e.g.
seq = ...
slice_record = SliceRecord(start, stop, step)
new_slice_record = slice_record[2:4:3]
sliced = new_slice_record.apply(seq)

The advantage of this approach is that the slice operation only needs to be applied to a single SliceRecord object.

The other challenge is the construction of the Aligned, which needs to be able to construct an appropriate Sequence and IndelMap instances. So if <alignment instance>.seqs[0] returns <aligned instance>, then <aligned instance>.data is the < aligned data view >instance. This makes me think that it's theAlignedclass that should have the responsibility to construct theSequenceclass instance and theIndelMapinstances, the former comes fromAligned.moltype.make_seq`.
One thought is to pick a single Aligned method that needs a method on the Sequence class and consider how that would be implemented.


[USMON-1250] usm: Fix USM termination to avoid panics

What does this PR do?
Re-organize USM shutdown procedure, to prevent us from causing a panic to system-prboe
Motivation
Avoid panics in the agent's termination
Describe how to test/QA your changes
Possible Drawbacks / Trade-offs
Additional Notes

/merge


How to make a custom Model with a stateful LSTM

System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow): The Decoder part in the official example: https://www.tensorflow.org/tutorials/text/nmt_with_attention
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 18.04
TensorFlow installed from (source or binary): pip
TensorFlow version (use command below): 2.0.0
Python version: 3.6.9
CUDA/cuDNN version: 10.0
GPU model and memory: GTX 1080Ti, 12 GB

Describe the current behavior
ValueError: If a RNN is stateful, it needs to know its batch size. Specify the batch size of your input tensors:

If using a Sequential model, specify the batch size by passing a batch_input_shape argument to your first layer.
If using the functional API, specify the batch size by passing a batch_shape argument to your Input layer.

Describe the expected behavior
I want to make a custom decoder layer with a stateful LSTM and a pre-net which is a simple Dense, but I do not want to use Sequential or functional API, because I want to control with reset_states() when the LSTM states will be reset. It always shows the error above. How should I give the input shape in this custom layer?
Code to reproduce the issue
class Decoder(Model):
    def __init__(self, dim):
        super(DecoderCell, self).__init__()
        self.input = Sequential([
            Input(batch_shape=(32, 1, num_mels)),
            Dense(128, activation='relu')
        ])

        self.rnn = LSTM(256, stateful=True)

    def call(self, x):
        x = self.input(x)

        x = self.rnn(x)

        return x

@njellinas ,This is not Build/Installation or Bug/Performance issue. Please post this kind of support questions at Stackoverflow. There is a big community to support and learn from your questions. GitHub is mainly for addressing bugs in installation and performance. Thanks!

@njellinas Did you ask on Stackoverflow? Did you solve your problem? I have similar problem


Handle :missing modifier in access policy check utility

Fixes #2811

coverage: 94.167% (+0.003%) from 94.164% when pulling 55edb903c97452d300bed1336e763867b7324c0c on axspol-missing-modifier into 1c9060b5812a6a3151e523caaf2d2a1de5367407 on main.


feat: override DOMWidgetModel.serializer to support binary data

The recent release of ipywidgets breaks existing anywidgets with binary traits. This PR overrides the serializer to enforce the use of structuredClone and binary data.

@hamelin, this was part of the selection bug you were experiencing at SciPy and we will fix it here for jupyter-scatter.

@hamelin, this was part of the selection bug you were experiencing at SciPy and we will fix it here for jupyter-scatter.

Great job!


Modify Sharepoint policies to only execute when applicable

🗣 Description

Several of the Sharepoint policies execute even in cases when they are not applicable. The policies for Sharepoint 1.3, 3,1, 3.2, and 3.3 have been updated to produce N/A messages when warranted. If the configuration settings apply, then the policy executes normally.
Policy 1.3

Executes normally when the external sharing slider is set to any value other than Only people in your organization.
Produces N/A message when set to Only People in your organization.
Unit tests updated.
Functional tests updated.

Policy 1.4

Not complete

Policy 3.1

Executes normally when the external sharing slider is set to Anyone.
Produces N/A message when set to Only people in your organization, Existing guests, or New and existing guests.
Unit tests updated.
Functional tests updated.

Policy 3.2

Executes normally when the external sharing slider is set to Anyone.
Checks that both file and folder link types equal 1 (View)
Produces N/A message when set to Only people in your organization, Existing guests, or New and existing guests.
Unit tests updated.
Functional tests not complete, they currently fail because input.OneDrive_PnP_Flag == false is checked in the configuration code which can't be pulled from Set-SPOTenant cmdlet.

Policy 3.3

Executes normally when the external sharing slider is set to Anyone or New and existing guests.
Produces N/A message when set to Only people in your organization or Existing guests.
Unit tests updated.
Functional tests updated.

💭 Motivation and context

Epic: https://github.com/cisagov/ScubaGear/issues/1064
closes https://github.com/cisagov/ScubaGear/issues/1062
closes https://github.com/cisagov/ScubaGear/issues/952
closes https://github.com/cisagov/ScubaGear/issues/951
closes https://github.com/cisagov/ScubaGear/issues/950
closes #892
Output in the reports was not accurately depicting tenant configuration settings.
🧪 Testing

Check that unit tests pass:
.\RunUnitTests.ps1 -p sharepoint

Check that functional tests pass for each policy ID:

MS.SHAREPOINT.1.3v1
MS.SHAREPOINT.3.1v1
MS.SHAREPOINT.3.2v1
MS.SHAREPOINT.3.3v1

$TestContainers = @()
$TestContainers += New-PesterContainer -Path "Testing/Functional/Products" `
-Data @{
    Thumbprint = "<your-thumbprint>";
    TenantDomain = "<tenant-domain>";
    TenantDisplayName = "<display-name>";
    AppId = "<app-id>";
    ProductName = "sharepoint";
    M365Environment = "gcc";
    Variant = "<spo/pnp>"
}
$PesterConfig = @{
        Run = @{Container = $TestContainers}
        Filter = @{Tag = @("<Policy ID>")}
        Output = @{Verbosity = 'Detailed'}
    }

$Config = New-PesterConfiguration -Hashtable $PesterConfig
Invoke-Pester -Configuration $Config

✅ Pre-approval checklist

[x] This PR has an informative and human-readable title.
[x] PR targets the correct parent branch (e.g., main or release-name) for merge.
[x] Changes are limited to a single goal - eschew scope creep!
[x] Changes are sized such that they do not touch excessive number of files.
[ ] All future TODOs are captured in issues, which are referenced in code comments.
[x] These code changes follow the ScubaGear content style guide.
[x] Related issues these changes resolve are linked preferably via closing keywords.
[x] All relevant type-of-change labels added.
[x] All relevant project fields are set.
[x] All relevant repo and/or project documentation updated to reflect these changes.
[x] Unit tests added/updated to cover PowerShell and Rego changes.
[x] Functional tests added/updated to cover PowerShell and Rego changes.
[x] All relevant functional tests passed.
[x] All automated checks (e.g., linting, static analysis, unit/smoke tests) passed.

✅ Pre-merge checklist

[ ] PR passed smoke test check.

[ ] Feature branch has been rebased against changes from parent branch, as needed
Use Rebase branch button below or use this reference to rebase from the command line.

[ ] Resolved all merge conflicts on branch

[ ] Notified merge coordinator that PR is ready for merge via comment mention

✅ Post-merge checklist

[ ] Feature branch deleted after merge to clean up repository.
[ ] Verified that all checks pass on parent branch (e.g., main or release-name) after merge.

Unit test review 1.3
The unit tests for policy 1.3 are missing the following two _Incorrect test scenarios - both of these should produce a false.
{
                "SharingCapability": 2,
                "SharingDomainRestrictionMode": 0
            }

{
                "SharingCapability": 3,
                "SharingDomainRestrictionMode": 0
            }

Inconsistencies in functional test plan
The following issues were found with the functional test plans sharepoint.spo.testplan.yaml and sharepoint.pnp.testplan.yaml.

Some of the test scenarios are named incorrectly. Notice in the screenshot below that the test case "MS.SHAREPOINT.2.2v1 Non-compliant - DefaultSharingLinkType = Edit" should be named "MS.SHAREPOINT.2.2v1 Non-compliant - DefaultLinkPermission = Edit"

Some of the test scenarios change field values that are unrelated to the specific policy being tested. For example the policy 3.1 test scenarios reference the field "DefaultSharingLinkType" but the 3.1 policy check has nothing to do with that field. Fields that are unrelated to the policy should be removed from the tests as they are unnecessary and make maintenance more challenging.

Improving the functional & unit tests for N/A cases
When testing N/A scenarios, I recommend setting the policy field to both compliant and non compliant values so that we can ensure the N/A works as expected. Let's take policy 3.1 as an example. Write N/A test scenarios that exercise the following conditions. Since Only people in your organization is configured, both scenarios produce N/A.

set the RequireAnonymousLinksExpireInDays < 30 & external sharing slider to Only people in your organization
set the RequireAnonymousLinksExpireInDays > 30 & external sharing slider to Only people in your organization

currently getting this error message when running through the scenarios described in this pr:


Status of this project

I created this plugin, in another way (different from gridsome/gridsome#167), for convenient and organized PWA config, and the support for serving manifest during development (rishabh3112/gridsome-plugin-pwa#21).
Many things still suck :

config logic
test coverage (I mean real coverage, not line coverage :smile: )
it generates icons on every reload ( update: will be fixed in v0.4.0)

However, this plugin meets my own needs. And all over GitHub, no other repo depends on this plugin. I may fix some of problems, but I will no longer actively develop this plugin like this month.
And yes, feel free to create issues and PRs, and I will respond ASAP. I am glad that you like this plugin.
(Or leave a kind reaction / comment on this issue if you like this plugin)

Edit:
PWA for gridsome is harder than I thought. Plan to read gatsby-plugin-offline's source code and try creating app shell if I have time. Gridsome seems not support app shell because it reads query data from window.__INITIAL_STATE__...

Hi, today I tried to use this PWA plugin which seems to be more customizable. (Because I saw your reference link at gridsome/gridsome#1032
But after I completed the configuration step by step according to the document, an error occurred.
Service worker registration failed, error:
TypeError: Failed to register a ServiceWorker for scope ('https://www.example.com/') with script ('https://www.example.com/service-worker.js'): ServiceWorker script evaluation failed

Then I went to see your blog's repo and blog, hoping to find help, but I found that your blog also has this error.
I turn to google and find this https://developers.google.com/web/ilt/pwa/introduction-to-service-worker . So I write this:
// src/registerServiceWorker.js
register(`./service-worker.js`, { scope: '/' }, { ... })

Now I get another error Uncaught TypeError: Super expression must either be null or a function , Google seems to try to tell me that this is due to a spelling error, but I really don't know what is wrong.
If you have time to fix your blog's problems, I will check the changes in the repo myself. I will try to fix my problem by myself, and I would be very grateful if you have time to guide me.

comment on this issue if you like this plugin 🥰

@monsterxcn Sorry for that. I have fixed the bug in my blog, and planned to release patch with other fixes.
Blog released v1.4.2 just now and the bug is fixed. :tada:
If you are not familiar with service worker, use generateSW mode instead of injectManifest mode. e.g. https://github.com/AllanChain/blog/blob/v1.4.0/gridsome.config.js

Thank! After leaving that comment, I did try another mode( generateSW ) and succeeded. I got a perfect score in the Chrome Lighthouse PWA test. Nice plugin 🤣
By the way, I also solved the problem of「Hash did not match」that was probably caused by incorrect cache rules before!

@AllanChain Its working fine but I am facing a small issue. After every Netlify deploy, the pages don't update. Is there any way to clear pwa cache or sync after every deploy ?

@milindsingh That's how PWA typically works:
page update -> user visit, browser update in the background -> user close tab -> user next time visit, update applied

@milindsingh @AllanChain In a previous application (pure Vue not Gridsome) I used the following approach to support the user with retrieving a new version without manually refreshing or making a later page visit. It looks like this plugin has some good options exposed for setting up the following in your application. Hopefully this will serve as a good guide.
// in registerServiceWorker.js, dispatch a custom event when sw updates in the background i.e. skipWaiting() enabled
updated(registration) {
    console.log('New content is available; please refresh.')
    document.dispatchEvent(new CustomEvent('swUpdated', { detail: registration }))
},

// listen for that event somewhere, and once it occurs, run some code to tell user they should update/reload
document.addEventListener('swUpdated', promptUserToReload(), { once: true })

// show an alert / modal / toast / prompt / etc. for user experience. then call window.location.reload() once user confirms.
promptUserToReload() {
    // .. some kind of prompt or toast to user for confirmation. you shouldn't just reload their page randomly
    window.location.reload()
}

I've had a chance to try out this plugin and it's gone smoothly, here is exactly how I integrated the update part from previous post.
// registerServiceWorker.js
/...
updated(registration) {
    console.log('New content is available; please refresh.')
    document.dispatchEvent(new CustomEvent('swUpdated', { detail: registration }))
},
//...

// custom App.vue
<script>
import DefaultLayout from<EMAIL_ADDRESS>
export default {
  name: 'App',
  components: {
    DefaultLayout,
  },
  mounted() {
    document.addEventListener('swUpdated', this.promptUserToReload, {
      once: true,
    })
  },
  methods: {
    promptUserToReload() {
      const reload = confirm(
        'Our site has an update! Reload the page now (recommended)?'
      )
      if (reload) {
        window.location.reload()
      }
    },
  },
}
</script>

using prompt() is a very crude way of doing it, but it's great for a quick test / adding the feature in dev. In production, display a modal or toast or something a bit nicer and non blocking.

Thanks, @cameronrr I implemented similarly but no idea why the updated hook trigger on every page load.
Any suggestion would be very helpful.
https://dev.adapttive.com/

I'd probably check the function in the event listener is just a reference and that it's not actually calling it.
like this - promptUserToReload
just the name of the function that would run
document.addEventListener('swUpdated', this.promptUserToReload, {
      once: true,
    })

not like this - promptUserToReload()
note the trailing () that would run the function
document.addEventListener('swUpdated', this.promptUserToReload(), {
      once: true,
    })

Thanks @cameronrr
The problem is updated() getting triggered on every page reload.
/* eslint-disable no-console */

import { register } from 'register-service-worker'

register('/service-worker.js', {
  ready () {
    console.log(
      'App is being served from cache by a service worker.\n' +
            'For more details, visit https://goo.gl/AFskqB'
    )
  },
  registered () {
    console.log('Service worker has been registered.')
  },
  cached () {
    console.log('Content has been cached for offline use.')
    setTimeout(() => {
        const event = new Event('pwa.loading.done');
        document.dispatchEvent(event);
    }, 1000);
  },
  updatefound () {
    const event = new Event('pwa.loading');
    document.dispatchEvent(event);
    console.log('New content is downloading.')
  },
  updated () {
    setTimeout(() => {
        const event = new Event('pwa.loading.done');
        document.dispatchEvent(event);
    }, 1000);

    setTimeout(() => {
        const event = new Event('pwa.refresh.notify');
        document.dispatchEvent(event);
    }, 1000);
    console.log('New content is available; please refresh.')
  },
  offline () {
    console.log('No internet connection found. App is running in offline mode.')
  },
  error (error) {
    console.error('Error during service worker registration:', error)
  }
})

@milindsingh Would you mind moving to Disscussions? I think this issue is getting off topic...


oVirt volume populator cannot find secret

          Alright, so made some progress but now I'm having issues creating the volumes

Here's the output of oc get events
87s         Warning   FailedScheduling        pod/xnet-migration-1-d7d27526-aa88-45d7-9451-a33406638d1f-pvci92tbb   running PreBind plugin "VolumeBinding": binding volumes: timed out waiting for the condition
83s         Normal    ExternalProvisioning    persistentvolumeclaim/a95f2952-f020-45eb-9d5c-e62cae09fa8e            waiting for a volume to be created, either by external provisioner "topolvm.io" or manually created by system administrator
65s         Normal    Provisioning            persistentvolumeclaim/a95f2952-f020-45eb-9d5c-e62cae09fa8e            Assuming an external populator will provision the volume
65s         Normal    Provisioning            persistentvolumeclaim/a95f2952-f020-45eb-9d5c-e62cae09fa8e            External provisioner is provisioning volume for claim "xnet-infra/a95f2952-f020-45eb-9d5c-e62cae09fa8e"
63s         Warning   FailedMount             pod/populate-f134c3a2-f87a-47a7-a6cc-b91b1ba89277                     MountVolume.SetUp failed for volume "secret-volume" : secret "xnet-migration-1-d7d27526-aa88-45d7-9451-a33406638d1f-hf96x" not found

It appears to be working in theory. However, the volumes aren't being created, and the PVCs are stuck on "Pending". I'm not having issues creating PVCs for VMs that aren't being migrated. Been skimming through the events and I'm unable to find anything that might showcase why the external provisioner is either taking so long or not working at all.
Originally posted by @tekkifygamer in https://github.com/kubev2v/forklift/issues/316#issuecomment-1529853450

@tekkifygamer
It looks like it cannot find the secret, does this secret exist:
$oc get secrets/"xnet-migration-1-d7d27526-aa88-45d7-9451-a33406638d1f-hf96x -n <target namespace>
Also, can you fetch the must-gather logs and upload them?

Error from server (NotFound): secrets "xnet-migration-1-d7d27526-aa88-45d7-9451-a33406638d1f-hf96x" not found
Doesn't appear that the secret is there, grabbing logs now

The logs are a little too big for github, I have uploaded them as a onedrive download link. If this doesn't work let me know.
https://1drv.ms/u/s!Agxxibm-w79UhYJf_2ciaDp4jK9Z8Q

Thanks, I think the issue is a leftover from your previous attempt:
2023-04-30T21:21:07.933780449Z {"level":"info","ts":1682889667.9337704,"logger":"plan|mhx6s","msg":"Migration [STARTED]","plan":"openshift-mtv/xnet-migration-1","migration":
"openshift-mtv/xnet-migration-1-1682889663270"}
2023-04-30T21:21:07.933867551Z {"level":"info","ts":1682889667.9338493,"logger":"plan|mhx6s","msg":"Migration [RUN]","plan":"openshift-mtv/xnet-migration-1","migration":"ope
nshift-mtv/xnet-migration-1-1682889663270","vm":" id:d7d27526-aa88-45d7-9451-a33406638d1f name:'nginx.xnet.local' ","phase":"Started"}
2023-04-30T21:21:07.933879300Z {"level":"info","ts":1682889667.9338632,"logger":"plan|mhx6s","msg":"Migrating VM (definition).","plan":"openshift-mtv/xnet-migration-1","migr
ation":"openshift-mtv/xnet-migration-1-1682889663270","vm":" id:d7d27526-aa88-45d7-9451-a33406638d1f name:'nginx.xnet.local' "}
2023-04-30T21:21:07.943771438Z {"level":"info","ts":1682889667.9437408,"logger":"plan|mhx6s","msg":"Deleted secret.","plan":"openshift-mtv/xnet-migration-1","migration":"ope
nshift-mtv/xnet-migration-1-1682889663270","secret":"xnet-infra/xnet-migration-1-d7d27526-aa88-45d7-9451-a33406638d1f-hf96x","vm":" id:d7d27526-aa88-45d7-9451-a33406638d1f name:'nginx.xnet.local' "}

The secret is deleted shortly after the migration started, so it looks like it is likely referencing the old OvirtVolumePopulator CRs, which reference the secret that was removed.
Because the secret is specified on the CR you can see the secret used for your current migration is:
2023-05-01T15:42:02.258949011Z {"level":"info","ts":1682955722.2589183,"logger":"plan|hzmgp","msg":"Secret created.","plan":"openshift-mtv/xnet-migration-1","migration":"ope
nshift-mtv/xnet-migration-1-1682955684510","secret":"xnet-infra/xnet-migration-1-d7d27526-aa88-45d7-9451-a33406638d1f-qgt56","vm":" id:d7d27526-aa88-45d7-9451-a33406638d1f n
ame:'nginx.xnet.local' "}

You can either edit the CRs with the new secret names:
$ oc get ovirtvolumepopulators -n <target namespace>
and then use $ oc edit or remove cancel the plan, archive it, remove all the leftovers and start over.
We have a PR in progress to improve the cleanup https://github.com/kubev2v/forklift/pull/223

Yup, looks like that was the issue. Had to jump through a few hoops to get the half-created PVs to be deleted, but in the end, got them removed.
Moved over a test VM now, everything is working great! Thank you for the assistance 😄

Duplicate of #223


Strikethrough not rendering (Markdown editor)

Describe the bug
The same issue as described and fixed in #2452 still seems to occur with text that is marked as being striked through.
Steps To Reproduce

Configure BookStack to use the Markdown editor
Create a new page anywhere and text marked as being striked through, e.g. ~~test~~
Save the page
The page view displays ~~test~~ literally

Expected behavior
test should be displayed as striked through.
Your Configuration (please complete the following information):

Exact BookStack Version (Found in settings): v0.31.2
PHP Version: 7.4.3
Hosting Method (Nginx/Apache/Docker): Apache

BTW, thank you very much for your work, @ssddanbrown! BookStack is amazing! I've migrated from Confluence, and administration and updates of BookStack are so much easier and performance is so much better :)!

Thanks for raising @marianrh, That's another part thing I'm surprised is not part of the commonmark spec. Should be an easy thing to add back in though.
And thanks for the feedback, good to hear from another confluence migrator!

Thanks for raising @marianrh, That's another part thing I'm surprised is not part of the commonmark spec. Should be an easy thing to add back in though.
And thanks for the feedback, good to hear from another confluence migrator!

This has now been patched and released as part of v0.31.3 so I'll therefore close this off.
Thanks again for reporting.

This has now been patched and released as part of v0.31.3 so I'll therefore close this off.
Thanks again for reporting.

with version v0.31.3, the problem still exists for me

with version v0.31.3, the problem still exists for me

@badsmoke Even when following the exact steps/syntax above, saving a new page?

@badsmoke Even when following the exact steps/syntax above, saving a new page?

thanks, that has fixed it

thanks, that has fixed it


Images in use are being deleted

After purging images I had a sense some images had dissapeared/errors. Then I made an experiment, sort of.
I added images to my ghost site by various means. I uploaded images by clicking on the add image variant, and by simply dropping them. I uploaded to galleries, and I dropped many images at once. I also uploaded images the ghost-markdown-card-way. I did it on published posts, on pages and with drafts.
The results are that images are dissapearing that should have been left alone. It seems very random and I can't see a pattern. Some images have been removed in a random way. the only pattern I might possibly see is that on a few occasions where I dropped a lot (10+) pics on the post at once, all had been purged.
So obviously something here is not working. I'm on the digitalocean droplet-variant, latest ghost.

Additioonal info, very unsure if it can possibly be related:
Background: I'm one of those with zero experience doing things in terminal/console, ssh and all that.
That means I was fiddling around by trial and error when A trying to install ghost-purge-images, and B trying to execute the purge command. At root, doing cd /var/www/ghost and all that, and so on. Could this possible have made any difference?
On a side note, I would like to suggest a few more instructions in the readme:

Where and how (exactly) to install on a droplet, for example.
Where and how, exactly, to execute the purge command. For people like me that would be a great help.

@Caucasus-and-Mercury currently it's already on the README, you can find:

How to install  (it installs globally, don't care the current folder)
How to execute it in your Ghost folder, where you installed it.
Both for display and purge commands, you will see the files list. When purge, also at the end if each file was removed or not

Still trying to reproduce the issue

Well that's kind of what I meant. It only says Run npm install -g ghost-purge-images to install, not explicitly where. As I tried to say, those things aren't that intuitive to some of us. I was also at a loss as to whether I should run the sudo -i -u ghost-mgr that Ghost suggests at the beginning, I'm still not sure. I agree the instruction of how to execute is sufficient.
Pls let me know if I could help you reproduce somehow. I now realised that I saved the terminal results after running, would you need it?

@Caucasus-and-Mercury yes, the terminal results may help to debug. After purge the images, did you check any post or page on your blog and detect that any image was removed?
For now, I can reproduce it for draft posts & draft pages, working on a fix

@Caucasus-and-Mercury also please note Ghost creates optimized images, so when you upload one picture, Ghost creates another one optimized with the same name but adding _o at the end. So you can get more images to delete that uploaded.
The issue about deleting images that are being used in drafts is fixed in the latest version 2.1.0, which requires Ghost +2.16 in order to use Ghost Admin API to fetch drafts.
Also the README was updated I hope you find it clearer and more useful 🙂 Feedback is welcome


dom-ifs

Do we need the data-binding annotation [[ ]] or {{ }} for the dom-ifs since its always going to be evaluated when the property changes?

Please follow the guidelines for creating issues at https://github.com/Polymer/polymer/blob/master/CONTRIBUTING.md#filing-bugs


Every time I start an web app, where I have AnimatedSplash as a Splash screen, I get an error.

flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel beta, 1.25.0-8.1.pre, on Microsoft Windows [Version 10.0.19042.685], locale en-US)
[√] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
[√] Chrome - develop for the web
[√] Android Studio (version 4.1.0)
[√] Connected device (2 available)
• No issues found!
This is the error:
The following assertion was thrown while finalizing the widget tree:
_AnimatedSplashState#c4b49(ticker active but muted) was disposed with an active Ticker.
_AnimatedSplashState created a Ticker via its SingleTickerProviderStateMixin, but at the time dispose() was called on the mixin, that Ticker was still active. The Ticker must be disposed before calling super.dispose().
Tickers used by AnimationControllers should be disposed by calling dispose() on the AnimationController itself. Otherwise, the ticker will leak.
The offending ticker was: Ticker(created by _AnimatedSplashState#c4b49(lifecycle state: created))
The stack trace when the Ticker was actually created was:
*Here in between, a great amount of links to different files like : " packages/flutter/src/scheduler/ticker.dart , packages/flutter/src/animation/animation_controller.dart, packages/flutter/src/widgets/framework.dart"
As I understand, the main lines causing error are:
packages/flutter/src/scheduler/ticker.dart 67:40
packages/flutter/src/scheduler/ticker.dart 68:14                                                                      new
packages/flutter/src/widgets/ticker_provider.dart 129:15                                                              createTicker
packages/flutter/src/animation/animation_controller.dart 247:20                                                       new
packages/animated_splash/animated_splash.dart 49:32
Error: Looking up a deactivated widget's ancestor is unsafe.
At this point the state of the widget's element tree is no longer stable.
To safely refer to a widget's ancestor in its dispose() method, save a reference to the ancestor by calling dependOnInheritedWidgetOfExactType() in the widget's didChangeDependencies() method.
at Object.throw_ [as throw] (http://localhost:52766/dart_sdk.js:4354:11)
at http://localhost:52766/packages/flutter/src/widgets/widget_span.dart.lib.js:24929:21
at framework.StatefulElement.new.[_debugCheckStateIsActiveForAncestorLookup] (http://localhost:52766/packages/flutter/src/widgets/widget_span.dart.lib.js:24932:23)
at framework.StatefulElement.new.findAncestorStateOfType (http://localhost:52766/packages/flutter/src/widgets/widget_span.dart.lib.js:25021:69)
at Function.of (http://localhost:52766/packages/flutter/src/widgets/widget_span.dart.lib.js:21262:63)
at http://localhost:52766/packages/animated_splash/animated_splash.dart.lib.js:328:29
at _RootZone.runUnary (http://localhost:52766/dart_sdk.js:37854:58)
at _FutureListener.then.handleValue (http://localhost:52766/dart_sdk.js:32815:29)
at handleValueCallback (http://localhost:52766/dart_sdk.js:33363:49)
at Function._propagateToListeners (http://localhost:52766/dart_sdk.js:33401:17)
at _Future.new.[_complete] (http://localhost:52766/dart_sdk.js:33234:25)
at http://localhost:52766/dart_sdk.js:32381:30
at internalCallback (http://localhost:52766/dart_sdk.js:24144:11)

Is there anyone who can help me with the issue?

Is there anyone who can help me with the issue?


[Question] How do I use it in Home Assistant?

I wanted to test a little bit this new library at Home Assistant, but I don't have too much knowledge about how to implement it.
I have tried this at core's Home Connect component api.py file:
class AsyncConfigEntryAuth(AbstractAuth):
    """Provide Home Connect authentication tied to an OAuth2 based config entry."""

    def __init__(
        self,
        hass: HomeAssistant,
        oauth_session: config_entry_oauth2_flow.OAuth2Session,
    ) -> None:
        """Initialize Home Connect Auth."""
        self.hass = hass
        super().__init__(oauth_session, host="https://simulator.home-connect.com")
        self.session = oauth_session

    async def async_get_access_token(self) -> str:
        """Return a valid access token."""
        await self.session.async_ensure_token_valid()

        return self.session.token

Then at __init__.py async_setup_entry method:
from aiohomeconnect.client import Client as HomeConnectClient

async def async_setup_entry(hass: HomeAssistant, entry: HomeConnectConfigEntry) -> bool:
    # [...]
    session = config_entry_oauth2_flow.OAuth2Session(hass, entry, implementation)
    config_entry_auth = AsyncConfigEntryAuth(hass, session)
    home_connect = HomeConnectClient(config_entry_auth)
    return True

But because OAuthSession2 doesn't have a request method (it has async_request) which is used at all the Client requests I found some troubles and I had to add the following method to the AsyncConfigEntryAuth class:
    async def request(
        self, method: str, url: str, **kwargs: Any
    ) -> client.ClientResponse:
        """Make a request.

        The url parameter must start with a slash.
        """

        headers = kwargs.pop("headers", None)
        headers = {} if headers is None else dict(headers)
        headers = {key: val for key, val in headers.items() if val is not None}

        access_token = await self.async_get_access_token()
        headers["authorization"] = f"Bearer {access_token}"

        return await self.session.async_request(
            method,
            f"{self.host}/api{url}",
            **kwargs,
            headers=headers,
        )

Although it works because both, aiohttp.client.ClientResponse and httpx.Response, does have json method, I think this is too complex and breaks the strict typing (As requests return aiohttp.client.ClientResponse instead of httpx.Response)
Additional info
I tried to create a question at discussions, but they are not enabled 😅
Version
Any
Platform
Debian 12
Code of Conduct

[X] I agree to follow this project's Code of Conduct.

No Duplicate

[X] I have checked existing issues to avoid duplicates.

But because OAuthSession2 doesn't have a request method

Why does this matter?
You should not overwrite the AbstractAuth.request method.

I see what you're doing wrong. The AbstractAuth accepts an httpx client as first parameter, not an OAuthSession2 instance.
You can see an example of how to implement a client in the included CLI.
https://github.com/MartinHjelmare/aiohomeconnect/blob/main/src/aiohomeconnect/cli/client.py

Sorry, I forgot about this issue.
Thank you for referring to the included API (it helped a lot in the PR development!).
About how it should be integrated with Home Assistant, Is the following code right?
class AsyncConfigEntryAuth(AbstractAuth):
    """Provide Home Connect authentication tied to an OAuth2 based config entry."""

    def __init__(
        self,
        hass: HomeAssistant,
        oauth_session: config_entry_oauth2_flow.OAuth2Session,
    ) -> None:
        """Initialize Home Connect Auth."""
        self.hass = hass
        super().__init__(
            get_async_client(hass), host=API_ENDPOINT
        )
        self.session = oauth_session

    async def async_get_access_token(self) -> str:
        """Return a valid access token."""
        await self.session.async_ensure_token_valid()

        return self.session.token

Or is there any other way to use httpx and oauth2 in Home Assistant?

That looks correct.


#78 serialization issue when setting elements to elements

weird bug, somehow merged but didn't update this pull


Fix unstable fanin test

As far as I understand, the local storage MetricsForLabelMatchers() implementation will create a few new maps along the way with fingerprints as the key. Therefore, we can't rely on any order and getting the two time series back in the expected order is a 50/50 chance. Or am I missing something here?
@juliusv
OT: I was surprised to see that fanin calls local storage and each remote storage sequentially. What's the reason for that?

:+1: Thanks! Funny that the test sometimes passes 30 times without failing. I thought Go would really randomize map ranges now so that it would be closer to 50/50...
Yeah, unless I'm forgetting something, the different storage queries can be parallelized. I just wanted to get it working and keep it simple for a first iteration.


Newsfeed module: Add option to display title as url

Added new config option showTitleAsUrl to newsfeed module.
If set, the diplayed title is a link to the article which is useful when running in a browser. If you now want to read the displayed article you can just click on it and it will open in a new browser tab/window.
There are no optical changes, except when showTitleAsUrl is set a mouse curser is displayed when moving over the title so you can click.
Will update documentation if this is accepted and merged here.

Codecov Report

Merging #2794 (c4e7e42) into develop (d181365) will decrease coverage by 0.37%.
The diff coverage is n/a.

@@             Coverage Diff             @@
##           develop    #2794      +/-   ##
===========================================
- Coverage    69.05%   68.67%   -0.38%
===========================================
  Files            8        8
  Lines          265      265
===========================================
- Hits           183      182       -1
- Misses          82       83       +1

Impacted Files
Coverage Δ

js/server.js
85.18% <0.00%> (-1.86%)
:arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d181365...c4e7e42. Read the comment docs.

btw I love this Codecov Report, its claiming about a decrease of coverage in js/server.js but this file is not changed in this PR ...


Wishing....Feature

[x] I have checked that a similar feature request does not already exist.

Hi,...
I wish
There Should be virtual Phone Button... Power, Back, minimize, Home, Volume with Samsung or Huwaei face.. And i want One click Wireless connected TCP (Physical Key press ex. CTRL+F1)☺

#7

And i want One click Wireless connected TCP (Physical Key press ex. CTRL+F1)

Hmm, it would make more sense to add a parameter --adb-connect-wifi or similar than a shortcut.

A good icon plz..... 😎


Unclear how to integrate in typescript projects

I'm trying to use jest-light-runner on a testing project, and can't really understand the process I'm supposed to be following, if there is support for such a setup.
What I'm currently doing is adding the   runner: "jest-light-runner" option to my jest config (which by itself will output errors for  Unknown file extension ".ts").
I understand this is due to on-the-fly compilation not being supported, as mentioned by the docs. It is mentioned that I should use something like ts-node/esm, which I set up with the flag --loader ts-node/esm as part of NODE_OPTIONS.
Doing so is getting me random errors (from pino, our logger, not sure why). Is there anything else I should do? Does typescript support actually rely on this experimental node option, or is there anything else I'm missing?

@kace91  You can just compile your typescript files with tsc and then instruct jest to run the compiled javascript files.


Change return of get_public_key(NIP-55) from npub to hex

When I run this URI nostrsigner:?compressionType=none&returnType=signature&type=get_public_key returns a npub, could be better if returns a public key as hex instead of npub to following the NIP-7.

Fixed in 225cba295b295b312bb26114956a55ae839e2c3d
it will be available in the next release


Correct Events.scala location on README

The previous link was broken :D

Thanks for the correction.


PLEASE READ MAY HELP Ipad 5th gen boot issue ios15.7 panic same sa ipx

Ssh connected This happen after mounting like iphone x
It will disconnect phone ssh

Isee dropber[22] error = 3 no such process

Can you show me the full screen when it panics

Can you show me the full screen when it panics


Team section

Upper row with h2, line, p
Lower row with images
When hoverede person info (h4, h5, linkable icons)


Finish group contract

Estimate: 4 hours
Once completed, this updates #3 and is a part of both the project plan delivery and the final report. Remember that Cecilia moved it to a new Overleaf document
Sections in the group contract

[x] Role and Responsibilities
[x] Expectations of the Workflow
[x] Distribution of the Workload
[x] Contact Information

I don't think I have anything else to add to the group contract. I cleaned up minor errors, added some details, and have also put a signature section on the bottom. Could you guys take a look at it and approve it tomorrow? @Didgy74 @EimenOueslati

This has been completed, but feel free to make minor edits if something is missing.


docs revert

Description
Please include a summary of the changes and the related issue. Please also include relevant motivation and context. List any dependencies that are required for this change.

revert docs from docsOverview
make this folders inside the app

docs/accounts/api-reference/
docs/instances/api-reference/
/docs/authentication/api-reference/

Type of change
Please delete options that are not relevant.

[ ] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[x] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update

How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list the simulator and android emulators used.

[ ] Manual Test
[ ] Unit Test
[x] E2E Test

Screenshots / Screen recording
Please add screenshots or recording if applicable

screencast-bpconcjcammlapcogcnnelfmaeghhagj-2023.08.03-23_59_24.webm
Checklist:

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[x] My changes generate no new warnings
[x] I have added tests that prove my fix is effective or that my feature works
[x] New and existing unit tests pass locally with my changes
[ ] Any dependent changes have been merged and published in downstream modules

@darwin808 "Tour" should only appear when the user is viewing "Parsley" docs (not in Instances, Accounts, etc)

@darwin808