Can't build Node.js gRPC Library

I used latest io.js v1.4.3, but with node v0.12.0 can't to build too
cd ~/grpc/src/node
node-gyp build
gyp info it worked if it ends with ok
gyp info using<EMAIL_ADDRESS>gyp info using<EMAIL_ADDRESS>| linux | x64
child_process: customFds option is deprecated, use stdio instead.
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
make: Entering directory `/root/grpc/src/node/build'
  CXX(target) Release/obj.target/grpc/ext/byte_buffer.o
In file included from ../ext/byte_buffer.cc:38:0:
../node_modules/nan/nan.h:481:19: error: ‘NanNew’ declared as an ‘inline’ variable
       v8::String::ExternalAsciiStringResource *resource) {
                   ^
../node_modules/nan/nan.h:481:19: warning: ‘always_inline’ attribute ignored [-Wattributes]
../node_modules/nan/nan.h:481:19: error: ‘v8::Local<v8::String> NanNew’ redeclared as different kind of symbol
../node_modules/nan/nan.h:475:36: error: previous declaration of ‘v8::Local<v8::String> NanNew(v8::String::ExternalStringResource*)’
   NAN_INLINE v8::Local<v8::String> NanNew(
                                    ^
../node_modules/nan/nan.h:481:7: error: ‘ExternalAsciiStringResource’ is not a member of ‘v8::String’
       v8::String::ExternalAsciiStringResource *resource) {
       ^
../node_modules/nan/nan.h:481:48: error: ‘resource’ was not declared in this scope
       v8::String::ExternalAsciiStringResource *resource) {
                                                ^
../node_modules/nan/nan.h: In function ‘bool _NanGetExternalParts(v8::Handle<v8::Value>, const char**, size_t*)’:
../node_modules/nan/nan.h:2103:12: error: ‘class v8::String’ has no member named ‘IsExternalAscii’
   if (str->IsExternalAscii()) {
            ^
../node_modules/nan/nan.h:2104:11: error: ‘ExternalAsciiStringResource’ in ‘class v8::String’ does not name a type
     const v8::String::ExternalAsciiStringResource* ext;
           ^
../node_modules/nan/nan.h:2105:5: error: ‘ext’ was not declared in this scope
     ext = str->GetExternalAsciiStringResource();
     ^
../node_modules/nan/nan.h:2105:16: error: ‘class v8::String’ has no member named ‘GetExternalAsciiStringResource’
     ext = str->GetExternalAsciiStringResource();
                ^
../ext/byte_buffer.cc: At global scope:
../ext/byte_buffer.cc:47:15: error: namespace ‘node::Buffer’ not allowed in using-declaration
 using ::node::Buffer;
               ^
../ext/byte_buffer.cc: In function ‘grpc_byte_buffer* grpc::node::BufferToByteBuffer(v8::Handle<v8::Value>)’:
../ext/byte_buffer.cc:57:16: error: ‘Buffer’ has not been declared
   int length = Buffer::Length(buffer);
                ^
../ext/byte_buffer.cc:58:16: error: ‘Buffer’ has not been declared
   char *data = Buffer::Data(buffer);
                ^
In file included from ../ext/byte_buffer.cc:38:0:
../ext/byte_buffer.cc: In function ‘v8::Handle<v8::Value> grpc::node::ByteBufferToBuffer(grpc_byte_buffer*)’:
../node_modules/nan/nan.h:504:33: error: ‘args’ was not declared in this scope
 # define NanReturnNull() return args.GetReturnValue().SetNull()
                                 ^
../ext/byte_buffer.cc:69:5: note: in expansion of macro ‘NanReturnNull’
     NanReturnNull();
     ^
../ext/byte_buffer.cc: In function ‘v8::Handle<v8::Value> grpc::node::MakeFastBuffer(v8::Handle<v8::Value>)’:
../ext/byte_buffer.cc:85:30: error: ‘GetCurrent’ is not a member of ‘v8::Context’
   Handle<Object> globalObj = Context::GetCurrent()->Global();
                              ^
../ext/byte_buffer.cc:89:48: error: ‘Buffer’ has not been declared
                                 NanNew<Number>(Buffer::Length(slowBuffer)),
                                                ^
make: *** [Release/obj.target/grpc/ext/byte_buffer.o] Error 1
make: Leaving directory `/root/grpc/src/node/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack     at emitTwo (events.js:87:13)
gyp ERR! stack     at ChildProcess.emit (events.js:169:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:1044:12)
gyp ERR! System Linux 3.13.0-43-generic
gyp ERR! command "node" "/usr/local/bin/node-gyp" "build"
gyp ERR! cwd /root/grpc/src/node
gyp ERR! node -v v1.4.3
gyp ERR! node-gyp -v v1.0.2
gyp ERR! not ok

Please, help me! Which version should I use?

I just published grpc 0.5.2 to npm. It should build on all versions of io.js and Node 0.10.13+. It currently crashes when it finishes on Node 0.11+, which I am investigating in issue #958.

@murgatroid99, Thank you very much!!!


removed extra feedback hard-coding at bottom of page in d4win release…

Proposed changes
Removed extra code for feedback links from d4win release notes
Please take a look
@mstanleyjones
Signed-off-by: Victoria Bialas<EMAIL_ADDRESS>

Deploy preview ready!
Built with commit c13b8d6269abce3d5b54e27e310c3a62d81680ee
https://deploy-preview-822--docker-docs.netlify.com

LGTM, merging!


Generic filter/etc

The collection packages are monomorphic for functions like (but not limited to) filter with a couple pain points:

They're inconvenient to use in conjunction without aliasing (e.g. List vs Array) also noted by @aspidites in tfausak/purescript-batteries#1.
They're inconvenient to change out collection types to compare relative performance (thus encouraging Array use). The primary reason is type signatures must include the specialized type instead of class.

I implemented a naive approach (technically for partition) using a Cons-able class. @michaelficarra took the same approach except with empty (called zero) instead of singleton. I considered that but wanted to support nonempty types. @tfausak noted (or I incorrectly inferred) Cons-able looks strikingly like Clojure's seq and @Gabriel439 pointed to his Foldl in Haskell for inspiration.
@jdegoes suggested an Unfoldable (“refoldable”) Foldable along with @joneshf commenting on purescript/purescript-monoid#6 but I encountered issues trying it. Hardy also recommended Witherable in Haskell (compelling to me) and implemented a lens-based Cons himself.
@paf31 believes the answer lies in profunctor-lenses with examples from Hardy again in purescript/purescript#607. On IRC with @garyb he postulated the following potential issues with a type class solution:

Degraded performance because type class instances are currently never inlined (even when safe to do so).
More complex type signatures because of type class constraints. I'll add to that occasionally ambiguous inference and less friendly type errors but those are also true of this package.

CC:

purescript/purescript#1075
@bodil
@drboolean

@AppShipIt Filter cannot be implemented on non-empty types, as filter (const false) must always produce the empty instance.

My gist returned Maybe although not necessarily as friendly.

You don't need Consable if you already have Alternative:
cons :: Alternative f => a -> f a -> f a
cons x xs = pure x <|> xs

filter can be implemented in terms of MonadPlus (see Haskell's Control.Monad.mfilter) or the Witherable class (which has nice laws)
The main issue with Consable is that it lacks an elegant mathematical basis

@Gabriel439 I started out implementing partition with Alternative but @paf31 pointed out it's unperformant because cons is potentially quadratic (e.g. List). I did leave an instance for Plus however (gist):
instance consPlusApplicative :: (Plus a, Applicative a) => Cons a where
  cons = alt <<< singleton
  singleton = pure

Lawlessness is Phil's concern too and thinks optics are the answer (e.g. @joneshf's Cons). I'm keen on reading into Withering and your Foldl too. Just looking for the best solution to my two pain points.

The nice thing about Witherable is that there are two very obvious laws for filter, which are functor laws:
filter (pure True) = id
filter (liftA2 (&&) f g) = filter f . filter g

... and if Purescript had Semiring instances for Booleans and functions, then this would just be:
filter one = id
filter (f * g) = filter f . filter g

Thanks so much for your input! It looks like a strong contender. Regarding laws I also read about their pertinence to transducers.

My suggestion for Unfoldable / Foldable was more pedagogical (it can be done but it is not performant).
My real 2 cents: if you want performant, generic collection methods, you need to take a type class based approach. Because no matter what abstraction you choose to build methods like partition, nub, etc., you can't achieve good performance across the different base collection types (Array, List).
class (Monad f) <= Collection f where
  partition :: forall a. (a -> Boolean) -> f a -> Tuple (f a) (f a)
  ...

You may cry, "Duplication!" Indeed, every different type of data structure will need its own definition of these functions. But that's sort of the point: every different data structure is optimized for certain use cases, so if you want a bunch of the same functions to work across them, they're going to have to be specialized (look at optimized definitions of partition for List and Array; they're totally different).
Even this approach will not achieve optimal performance when chaining collection methods, because it's too eager: you'd like to be able to fuse various operations together. For that case, you could require the user convert from a base data structure into a lazy, fuseable representation, and then from there into a polymorphic target representation via a builder class that allows efficient ST-based collection building.
It will be more verbose for the user (e.g. [1, 2, 3] # stage >>> filter (_ > 2) >>> map (_ % 2) >>> build), but you will have more predictable performance and less duplication.
For the case where we only care about reuse and not performance, I think PureScript needs a good recursion schemes library based on fixed point data, which could be used to build a lot of very generic and reusable collection-style methods (generalized to more types of data structures).
That's 3 totally different approaches that I think could all exist and find use in different scenarios. :smile:

@jdegoes My main goal is too be able to switch out implementations at mid-development without rewriting type signatures (e.g. trying Array, List, Seq, and considering Set). Duplication isn't a concern but default implementations would be nice (e.g. Folable's or my Alternative instance). There remains a potential issue passing an extra dictionary around but I suspect that'll lessen in the future with safe inlining. Regarding lazy chaining I recently read about lawful transducers.

Yep!  The foldl library has almost the exact same type, but it's called Handler:
http://hackage.haskell.org/package/foldl-1.1.5/docs/Control-Foldl.html#t:Handler
type Handler a b = forall x. (b -> Constant (Endo x) b) -> a -> Constant (Endo x) a

The nice thing about this type is that any lens or traversal will type-check as the above type, so you can reuse all existing lenses or transversals as transducers, too.

Gabriel has a nice implementation of lawful transducers: https://hackage.haskell.org/package/foldl-1.1.2/docs/Control-Foldl.html
There's another package that adds some more goodies on top of that one: https://hackage.haskell.org/package/foldl-transduce-<IP_ADDRESS>

Carefully note that the Handler type is the real analog to Clojure's transducers (not the Foldl type)

I was wrong about the quadratic performance of using <|>, or thinking of something else. My main problem with using Alt to build cons is that it doesn't allow for things like streams. This makes me wonder if <|> is the wrong sort of higher-order monoidal structure we want, although I'm really not sure. I think of Alt as modeling non-determinism, and how the semantics of how that interacts with the Monoid structure on things like List is unclear to me.
If lawfulness is the main concern, then we can always add more operations and laws, so I'm not sure how much faith to put in a type class just because it has some laws. I think it is better to judge a type class based on how time-tested its mathematical basis is, so something like a group or lattice or functor etc. makes a good type class, but Consable is a bit more shaky.
Although, if we extend Consable to assert that a container c is isomorphic to a coproduct of something with the product of itself with the identity functor, then that certainly has a solid mathematical basis, and extends nicely to streams. This is a lot like @joneshf 's Cons class approach based on Prism.
I'm also interested in Witherable.

Actually, using (<|>) for cons does work with streams, or at least it does in Haskell.
Thinking of Alt as non-determinism is just as misleading as thinking of Monoid as multiplication.  The only property that matters for the Alt class is that (<|>) is associative and empty is its identity.  The fact that it's named Alternative doesn't really mean anything and is just an artifact of its history.  I just think of it as a higher-kinded Monoid class.

I'm thinking of infinite streams so that you can't define any pure such that cons a is pure a <|>.

Yes, but it interacts with Applicative too.

Yeah, I think the Applicative super-class of Alternative is a mistake.  A super-class should always be implementable from the methods of the sub-class.
Here's a possible suggestion for a Cons-like class:
{-| Laws:

> prepend [] = id
> prepend (xs ++ ys) = prepend xs . prepend ys
-}
class Prepend f where
    prepend :: [a] -> f a -> f a

cons :: Prepend f => a -> f a -> f a
cons x = prepend [x]

I was wrong about the quadratic performance of using <|>

@paf31 My original implementation without Cons did suffer from it.
@ALL I rewrote my description to capture the various approaches to make more collection functions polymorphic. I plan to delve into optical Cons, Witherable, and Foldl. Can anyone articulate pros/cons between those three (perhaps naive Cons too)? I think “refoldable” incurs a performance penalty and MonadPlus an unacceptable constraint. I do view laziness as highly desirable to reduce iteration.

Yeah, I think the Applicative super-class of Alternative is a mistake.

I don't know, Applicative says "I want both" where Alt says "I want one", and I think that interaction is useful, compared to just a Monoid at kind * -> *.
So perhaps the better instance context for the Alt approach is something like (Applicative f, Semigroup1 f) => ..., since we don't require the interaction with Applicative.
Thinking about laws, some things we might want to prove which could act as benchmarks:

filter (pure true) = id
filter (lift2 (&&) f g) = filter f <<< filter g

My main problem with using Alt to build cons is that it doesn't allow for things like streams.

@paf31 This just clicked for me this morning. A requirement in my opinion should be filter and scan for Signal and Rx.Observable too. Cons (optical or otherwise) is out but I want to compare MonadPlus.

Yes, but it interacts with Applicative too.

@paf31 Alt interacts with Applicative? That went over my head.

There's one other thing I wanted to mention: you should be very careful about making type classes for every operation.  If you do this users will begin to get ambiguous type errors everywhere.  You have the most risk of this happening when you have functions with a return type that is polymorphic over one class that are fed into a function that is polymorphic over another class like the classic show . read example.
For example, any Cons-like class is at a high risk of clashing with the Foldable class and leading to ambiguous type errors.  In fact, the Foldable class in general tends to cause lots of issues with type inference.

I considered that. I'd rather tackle explaining errors better (an area I'd like to contribute) than make it hard to switch out data structures (updating signatures everywhere). Haskell disambiguates by prefix (e.g. fmap vs map) which I found confusing starting out (“Why two? Fwhat does ‘f’ mean?”). I wonder if there's a clever compromise hiding.

So in the case of Haskell we have a workaround in ghc-8.0 that will greatly alleviate the solution, which is type application.  So, for example, if you want a length function specialized to lists you would just write length @[] and now it's monomorphic instead of polymorphic over Foldable.
If Purescript had something similar then I would have much fewer reservations about type-classing everything.

PS has asTypeOf but that sounds much nicer. CC @paf31?

Witherable is motivated similarly in design to Unfoldable and looks like the right fit for standard Prelude. Foldl adds the benefit of laziness and working with optics.

I added my personal conclusion in the issue description. @paf31 May I move Witherable/Foldl to the roadmap and close this one?

Witherable should be implemented in a contrib project, and then we can decide if it's a good fit for core.

That makes sense. Is contrib in roadmap too? Closing regardless since it's beyond the scope of FTP.

@AppShipIt Please post a link to the repo here once you create it so we can follow the progress of this issue.

I will thanks @michaelficarra! It won't be until after LambdaConf because I'm working on 3 tools until then but making more list-like combinators polymorphic is on my personal todo.


[ModuleCatalog] Deprecate .spec.channel in ModuleTemplate

Description
In https://github.com/kyma-project/lifecycle-manager/issues/1681 it has been decided that ModuleTemplates are tied to versions and not to channels. In https://github.com/kyma-project/lifecycle-manager/issues/1591 we already made .spec.channel optional. We can also mark this attribute as deprecated and remove it in the future.
Reasons
Clean API from unused fields.
Acceptance Criteria

[ ] Marked .spec.channel attribute as deprecated
[ ] Added an entry to https://github.com/kyma-project/lifecycle-manager/issues/776 that .spec.channel can be removed in a future major API version

[ ] includes removal of operator.kyma-project.io/channel label from manifests (see https://github.com/kyma-project/lifecycle-manager/issues/1477)

[ ] Note down the deprecation in the relevant documentation

Feature Testing
No response
Testing approach
No response
Attachments
No response

Proposal to be discussed: once deprecated, we can already update modulectl to issue an error when trying to provide a channel.


Updating the package

Updated the jsonwebtoken package as per the security issue.

Thanks for opening this! Closing in favor of #5503 to ensure our full test suite is run against this change.


(bug) pressing Shift+Enter or Ctrl+Enter submits solution without running code

When Shift+Enter or Ctrl+Enter is pressed on a page, the solution is simply submitted without even running the code. This works with both the Python Basics and Machine Learning paths.
video

@greysome thanks for letting us know! this is related to the recent PR 73117d81e0f086940925295daf1920585b9a0e0d
We will try to find a solution to this issue soon.

@Brainenjii pressingthe keyboard shortcut Shift+Enter or Ctrl+Enter will now clear the whole block

The keyboard shortcuts should only activate the "RUN" button without clearing the whole solution block.


the results of roi-transformer

Notice
There are several common situations in the reimplementation issues as below

Reimplement a model in the model zoo using the provided configs
Reimplement a model in the model zoo on other dataset (e.g., custom datasets)
Reimplement a custom model but all the components are implemented in MMDetection
Reimplement a custom model with new modules implemented by yourself

There are several things to do for different cases as below.

For case 1 & 3, please follow the steps in the following sections thus we could help to quick identify the issue.
For case 2 & 4, please understand that we are not able to do much help here because we usually do not know the full code and the users should be responsible to the code they write.
One suggestion for case 2 & 4 is that the users should first check whether the bug lies in the self-implemted code or the original code. For example, users can first make sure that the same model runs well on supported datasets. If you still need help, please describe what you have done and what you obtain in the issue, and follow the steps in the following sections and try as clear as possible so that we can better help you.

Checklist

I have searched related issues but cannot get the expected help.
The issue has not been fixed in the latest version.

Describe the issue
A clear and concise description of what the problem you meet and what have you done.
Reproduction

What command or script did you run?

A placeholder for the command.

What config dir you run?

A placeholder for the config.

Did you make any modifications on the code or config? Did you understand what you have modified?
What dataset did you use?

Environment

Please run python mmdet/utils/collect_env.py to collect necessary environment infomation and paste it here.
You may add addition that may be helpful for locating the problem, such as

How you installed PyTorch [e.g., pip, conda, source]
Other environment variables that may be related (such as $PATH, $LD_LIBRARY_PATH, $PYTHONPATH, etc.)

Results
If applicable, paste the related results here, e.g., what you expect and what you get.
A placeholder for results comparison

Issue fix
If you have already identified the reason, you can provide the information here. If you are willing to create a PR to fix it, please also leave a comment here and that would be much appreciated!
您好，请问RoI Transformer在DOTA数据集上的Result会给出吗？

模型库将会在后续工作中陆续补全


POA network stuck in SyncState block 0

POA network stuck in SyncState block 0
Description
i am experiencing issues where running Polygon edge nodes in POA does not get past the
polygon.consensus.ibft: state change: new=SyncState

status
I have setup for nodes with the following genesis bootstrap command
node 1
polygon-edge genesis --consensus ibft \
--ibft-validator=0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4 \
--bootnode=/ip4/<IP_ADDRESS>/tcp/1478/p2p/16Uiu2HAky6cpqQJFneebjfFDWJRUiEtk6UfgpSE6NoPwMfufe1JT \
--ibft-validator=0x7D4fbc4B6C29f47AECE060A533Aee5821FC84f66 \
--bootnode=/ip4/<IP_ADDRESS>/tcp/1478/p2p/16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8 \
--premine=0xBa59A0EF89Cce1aB7437036dbF55A6Ee8A6E5d6C:100000000000000000000000 \
--premine=0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C:100000000000000000000000 \
--premine=0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4:100000000000000000000000 \
--premine=0x7D4fbc4B6C29f47AECE060A533Aee5821FC84f66:100000000000000000000000

node2
polygon-edge genesis --consensus ibft \
--ibft-validator=0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C \
--bootnode=/ip4/<IP_ADDRESS>/tcp/1478/p2p/16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ \
--ibft-validator=0x7D4fbc4B6C29f47AECE060A533Aee5821FC84f66 \
--bootnode=/ip4/<IP_ADDRESS>/tcp/1478/p2p/16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8 \
--premine=0xBa59A0EF89Cce1aB7437036dbF55A6Ee8A6E5d6C:100000000000000000000000 \
--premine=0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C:100000000000000000000000 \
--premine=0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4:100000000000000000000000 \
--premine=0x7D4fbc4B6C29f47AECE060A533Aee5821FC84f66:100000000000000000000000

node3
polygon-edge genesis --consensus ibft \
--ibft-validator=0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C \
--bootnode=/ip4/<IP_ADDRESS>/tcp/1478/p2p/16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ \
--ibft-validator=0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4 \
--bootnode=/ip4/<IP_ADDRESS>/tcp/1478/p2p/16Uiu2HAky6cpqQJFneebjfFDWJRUiEtk6UfgpSE6NoPwMfufe1JT \
--premine=0xBa59A0EF89Cce1aB7437036dbF55A6Ee8A6E5d6C:100000000000000000000000 \
--premine=0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C:100000000000000000000000 \
--premine=0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4:100000000000000000000000 \
--premine=0x7D4fbc4B6C29f47AECE060A533Aee5821FC84f66:100000000000000000000000

node4
polygon-edge genesis --consensus ibft \
--ibft-validator=0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C \
--bootnode=/ip4/<IP_ADDRESS>/tcp/1478/p2p/16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ \
--ibft-validator=0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4 \
--bootnode=/ip4/<IP_ADDRESS>/tcp/1478/p2p/16Uiu2HAky6cpqQJFneebjfFDWJRUiEtk6UfgpSE6NoPwMfufe1JT \
--premine=0xBa59A0EF89Cce1aB7437036dbF55A6Ee8A6E5d6C:100000000000000000000000 \
--premine=0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C:100000000000000000000000 \
--premine=0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4:100000000000000000000000 \
--premine=0x7D4fbc4B6C29f47AECE060A533Aee5821FC84f66:100000000000000000000000

all four nodes are being started with the following command
polygon-edge server --data-dir kmc --chain genesis.json  --libp2p <IP_ADDRESS>:1478 --jsonrpc <IP_ADDRESS>:8545 --seal --block-time 2 --ibft-base-timeout 15 --grpc-address <IP_ADDRESS>:9632

all four nodes find each other and establish peer connections
node1
2022-07-06T01:13:49.237Z [INFO]  polygon.consensus.ibft: state change: new=SyncState
2022-07-06T01:13:50.106Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAm5aBhDtepHyptqC3vyQnGQ7rTMmWXdcQGCN9PRVn67eKY
2022-07-06T01:13:50.129Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8

root@node-1:~# polygon-edge peers list

[PEERS LIST]
Number of peers: 3

[0] = 16Uiu2HAm5aBhDtepHyptqC3vyQnGQ7rTMmWXdcQGCN9PRVn67eKY
[1] = 16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8
[2] = 16Uiu2HAky6cpqQJFneebjfFDWJRUiEtk6UfgpSE6NoPwMfufe1JT

node2
2022-07-06T01:14:05.590Z [INFO]  polygon.consensus.ibft: state change: new=SyncState
2022-07-06T01:14:06.153Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8
2022-07-06T01:14:06.263Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ
2022-07-06T01:14:09.484Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAm5aBhDtepHyptqC3vyQnGQ7rTMmWXdcQGCN9PRVn67eKY

root@node-2:~# polygon-edge peers list

[PEERS LIST]
Number of peers: 3

[0] = 16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8
[1] = 16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ
[2] = 16Uiu2HAm5aBhDtepHyptqC3vyQnGQ7rTMmWXdcQGCN9PRVn67eKY

node3
2022-07-06T01:14:05.590Z [INFO]  polygon.consensus.ibft: state change: new=SyncState
2022-07-06T01:14:06.153Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8
2022-07-06T01:14:06.263Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ
2022-07-06T01:14:09.484Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAm5aBhDtepHyptqC3vyQnGQ7rTMmWXdcQGCN9PRVn67eKY

root@node-3:~# polygon-edge peers list

[PEERS LIST]
Number of peers: 3

[0] = 16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ
[1] = 16Uiu2HAm5aBhDtepHyptqC3vyQnGQ7rTMmWXdcQGCN9PRVn67eKY
[2] = 16Uiu2HAky6cpqQJFneebjfFDWJRUiEtk6UfgpSE6NoPwMfufe1JT

node4
2022-07-06T01:13:49.289Z [INFO]  polygon.consensus.ibft: state change: new=SyncState
2022-07-06T01:13:50.060Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ
2022-07-06T01:13:54.583Z [INFO]  polygon.network: Peer connected: id=16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8

root@node-4:~# polygon-edge peers list

[PEERS LIST]
Number of peers: 3

[0] = 16Uiu2HAkuiq1xd2eZ3pYWT7oiU55TEQcdghgb852ALEE8Gg5gsTJ
[1] = 16Uiu2HAm48J3m7UyB5oKpxK4vQsks3kDdFDs2yhcYct4TN8EoZG8
[2] = 16Uiu2HAky6cpqQJFneebjfFDWJRUiEtk6UfgpSE6NoPwMfufe1JT

polygon-edge IBFT for each node shows it is at a block height of 0
node1
root@node-1:~# polygon-edge ibft snapshot

[IBFT SNAPSHOT]
Block = 0
Hash  = 0x3913389a3e2c901f1d28b8ddc67e812427f988031113ef5c0d0251149e29f044

[VOTES]
No votes found

[VALIDATORS]
ADDRESS
0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4
0x7D4fbc4B6C29f47AECE060A533Aee5821FC84f66

node2
root@node-2:~# polygon-edge ibft snapshot

[IBFT SNAPSHOT]
Block = 0
Hash  = 0xa320e7ef2f0b52419ff9f76056439fde38bb9a670c4da430571c4fd4aa87b66d

[VOTES]
No votes found

[VALIDATORS]
ADDRESS
0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C
0x7D4fbc4B6C29f47AECE060A533Aee5821FC84f66

node3
root@node-3:~# polygon-edge ibft snapshot

[IBFT SNAPSHOT]
Block = 0
Hash  = 0xee486f45377317c30e3e8b36ba52600572d4323b7556b347e7a333fb6c84860e

[VOTES]
No votes found

[VALIDATORS]
ADDRESS
0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C
0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4

node4
root@node-4:~# polygon-edge ibft snapshot

[IBFT SNAPSHOT]
Block = 0
Hash  = 0xee486f45377317c30e3e8b36ba52600572d4323b7556b347e7a333fb6c84860e

[VOTES]
No votes found

[VALIDATORS]
ADDRESS
0x99dBB17c5Cf65daBCDFD736BA5b7Dc909086328C
0x583Df7f66F748e1471C44b6776692C3D1eDB9CB4

I can broadcast transactions to the nodes but they sit in the node tx pool as pending
for example
curl  http://<IP_ADDRESS>:8545 -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"txpool_content","params":[],"id":1}'
{"jsonrpc":"2.0","id":1,"result":{"pending":{},"queued":{"0xBa59A0EF89Cce1aB7437036dbF55A6Ee8A6E5d6C":{"2":{"nonce":"0x2","gasPrice":"0x3b9aca00","gas":"0x5208","to":"0x8170E9C54470b94F70b1ca7eB68C2184A91cAC49","value":"0x8ac7230489e80000","input":"0x","hash":"0xb232f1bda192ec8b7aaef3179c95e0a4a0e3ba05b23281f32dad9be86e446df0","from":"0xBa59A0EF89Cce1aB7437036dbF55A6Ee8A6E5d6C","blockHash":"0x0000000000000000000000000000000000000000000000000000000000000000","blockNumber":null,"transactionIndex":null}}}}}%

curl  http://<IP_ADDRESS>:8545 -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"txpool_inspect","params":[],"id":1}'
{"jsonrpc":"2.0","id":1,"result":{"pending":{},"queued":{"0xBa59A0EF89Cce1aB7437036dbF55A6Ee8A6E5d6C":{"2":"10000000000000000000 wei + 21000 gas x<PHONE_NUMBER> wei"}},"currentCapacity":1,"maxCapacity":4096}}%

curl  http://<IP_ADDRESS>:8545 -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"txpool_status","params":[],"id":1}'
{"jsonrpc":"2.0","id":1,"result":{"pending":0,"queued":1}}%

Your environment

OS and version

Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.4 LTS
Release:	20.04
Codename:	focal

version of the Polygon Edge

v0.4.1+82442a45

branch that causes this issue

develop commit 82442a454a55dbb790a6d087ea95ae8ec83a48c5

Steps to reproduce

Tell us how to reproduce this issue
build from develop commit hash above and run genesis command and server run command provided

Where the issue is, if you know
nodes not coming to quorum in POA, processing transactions and producing new blocks

Which commands triggered the issue, if any

Expected behaviour
Nodes should form a quorum and produce blocks processing broadcasted tx
Actual behaviour
nodes do not move past SyncState, no blocks produces no transactions verified
Logs
Please paste any logs here that demonstrate the issue, if they exist
Proposed solution
If you have an idea of how to fix this issue, please write it down here, so we can begin discussing it

Hello @nshCore ,
Thank you for opening this issue!
Firstly, I would kindly ask you to make sure you are running all the nodes with the same config file. You can use the command polygon-edge server export  , which will generate the config file. After this, you can modify the config file to your needs and use it for all the nodes.
Please let me know how it goes.

@nshCore Hello, each genesis file seems to have different validator set, which is given by --ibft-validator. This validators is stored in genesis header, so the headers with different IBFT validator set returns different hashes. Validator can't join consensus if their genesis hashes are different. Ideally all nodes should have same genesis.json (or the genesis.json generated by genesis command with same arguments) Could you please try to generate genesis.json and run nodes again?

@nshCore Please note that genesis block is set in localstorage when node starts. I recommend you to delete all data-dir before regenerating genesis.json

Hey @nshCore,
Were you able to reproduce this issue with the latest develop branch and @Kourin1996's instructions?

@nshCore
Closing this issue as it seems to be a misconfig.
Please open a new one if it persists 🙏


Were you able to fix iServices?

When i log into imessage it kicks me out 2 seconds in and i enter a login loop

Hi AlluraRed,
To fix iServices you have to generate your own SMBIOS info and add it to the PlatformInfo in the config.plist as per this part of the  Opencore Guide.
I didn't include the data to it - except the SystemProductName entry - in the repository as each user has to generate its own SMBIOS, else it may create conflicts between Apple IDs I guess.
Regarding the SystemProductName  entry I've set it to "MacBookPro16,1" as it is matching my config, but I "MacBookPro16,4" should work too. Feel free to test it.
Please try that and give me a feedback, it'll help me add a section for that in the Readme.
Don't forget to stare the repo to give it more visibility.


Issue assignee option not working

I think filtering by assignee option should be assignee, not assigner here:
https://github.com/nvim-telescope/telescope-github.nvim/blob/master/lua/telescope/_extensions/gh_builtin.lua#L21

Fixed in https://github.com/nvim-telescope/telescope-github.nvim/commit/abe424a49a5d3ba8532d4c245611874626795f24


add douban to the orgs.

Coverage remained the same at 69.269% when pulling 0f40b4ba49422d055a15127ede27ca0a3dec0dc3 on luchuan:master into d7e419127c71c97580b00c8dae5fc14eb054a312 on apache:master.

Coverage remained the same at 69.269% when pulling 0f40b4ba49422d055a15127ede27ca0a3dec0dc3 on luchuan:master into d7e419127c71c97580b00c8dae5fc14eb054a312 on apache:master.


Fix monkey patching in Django 1.7 and newer

django.db.backends.util was deprecated and replaced with django.db.backends.utils in Django 1.7.
Here we import util in Django 1.6 and older, and utils otherwise.

Pushed a new version to PyPI as 0.3.3


Problem with SwiftUI DragGesture onEnded

In some cases  DragGesture onEnded not triggered...
It leads to the following situation when some cells not fully opened

fix in 0.4.0


Skeletron Prime Bugged

In general. I once decided to take down skeletron prime and then I noticed that his head looks different, namely straight from the Master mode, even though I am currently playing in the Expert + Revergence combination (although I myself am in the Master + Death didn't play, so I could be wrong). And after I stripped his hands, I noticed that some attack patterns were missing.

P.S. I have already applied the Calamity discord server and after a short discussion it was decided that the problem was in Cal overhaul.

There's also more to the bug as well, if you're on Death-Master, Skeletron prime only has one head, and doesn't summon the other mech bosses later in the fight, definitely doesn't behave as intended
Skeletron Prime had new behavior in 2.0.4 (behavior being him having two head and summoning the other mechanical bosses), and Calamity overhaul seems to break it. This also links to the first part of the bug report, where Skeletron Prime's head used a different sprite, which may be a side effect from the bug

Well, in that case, I'll wait patiently for the patch, hoping that I won't stumble into more pressing problems.
Thank you for the detailed answer.

I know, this issue comes from an unfinished AI modification. It will be fixed


Minor changes to da_DK

Updated your name in the credits section.
Not sure when or if there will be another build.


FAQs page

This issue tracks the drafting, review and approval for adding a new page to the Catalyst website (a separate template issue for blog posts is coming soon).
This issue is complete when: the copy of this FAQs page is approved and published on the website.
Google doc for drafting copy: https://docs.google.com/document/d/1wynnvQQ1_CAUxmmVuDZFHXWi0RLkVeaDKoerXKdjCOc/edit#heading=h.d5tnu211dtng
Roles

[ ] Drafting content: @jnywong and @katiepratt
[ ] Sub-team review: <@corresponding project sub-team reviewer> (see The Catalyst Project Blog - Project Planning Doc in Team Drive > Communication)
[ ] Handoff: @katiepratt to provide editorial review
[ ] Draft website preview: @jnywong to prepare a preview for website publishing
[ ] Final sign-off: @katiepratt
[ ] New page is published: @jnywong

Hi, I added some questions the communities asked during the onboarding process to the document.

@jnywong and @LouWoodley what timeline are we looking at? I am going to be away from my desk from 2-18 August

Hey @elletjies ! If you could aggregate the common FAQs you have encountered from onboarding Catalyst community partners into the doc by July 31 that would be fantastic.
If you already have a collection a bank of questions from elsewhere, please share and signpost so that I can extract them :)

@jnywong I have added a couple of questions I have been asked :)


Consider using torsocks --isolate

Hi!
Recent torsocks has a --isolate option, that should allow you to drop the code that generates a unique SOCKS user/password etc. :)

Done in 6e91543c5c409714767af77bda140d8969a8ac7f. Thanks!


Highlight-preview loses transparency

Highlight preview loses transparency when changing the color using the mouse wheel ("V" key) until you set the color manually using "C".

Fixed in 20210403_1.


Unable to open promptfoo link from promptfoo share

Uncaught (in promise) QuotaExceededError: Failed to execute 'setItem' on 'Storage': Setting the value of 'ResultsViewStorage' exceeded the quota.
    at Object.setItem (921-ea4bddb5c25058ea.js:44:2429)
    at v (921-ea4bddb5c25058ea.js:44:4601)
    at 921-ea4bddb5c25058ea.js:44:4715
    at setTable (712-08d720048b34c52c.js:1:859)
    at e (712-08d720048b34c52c.js:1:42556)

oh maybe related to this issue https://github.com/promptfoo/promptfoo/issues/1731#issue-2540416297


[feature] Optimize memory usage

I alway notice that "memory not enough, XX classes not index, please increase heap size and restart"   when input a big file and search some thing.

Is it possible to  use file cache replace with memory to decrease memory usage.

Have you read our Wiki section about memory problems? https://github.com/skylot/jadx/wiki/Troubleshooting-Q&A#out-of-memory-problems
Additionally I strongly recommend you not to use Java 8. Use Java 11 or 17 instead. Since Java 9 strings usually have a reduced memory footprint (up to 50%). All the code you see in Jadx are strings in memory so using Java 11/17 can reduce memory usage a lot.
@skylot As far as I know Oracle Java 8 is EOL February 2022. Some OpenJDK Java 8 versions are supported a little longer but Java 8 in general seems to come to an end. What do you think about how long we should continue Jadx support Java 8?

I installed java11 ,my memoy only has 8G.
even if i increase memory to  4G, it still has the problem, if i increase more , my pc will crash.

Jadx is designed to decompile everything in RAM as this is way faster and easier to implement.
A file-based database may be implemented in future.
The only way to decrease memory usage at the moment is to exclude packages you are not interested in or to only selectively decompile classes.

Thx

@b0123456789

Is it possible to use file cache replace with memory to decrease memory usage ?

Sure, this can be done, this will also help to continue work on project after jadx reopen (related to #784).
I already implemented POC some time ago, but it shows a lot of issues in performance (especially in search) and in overall jadx internal architecture, so this needs a lot of preparations and changes.
@jpstotz

As far as I know Oracle Java 8 is EOL

Yeah, I also want to move to newer java releases. I already change required java version to 11 in download section and encourage people to use the latest version in release notes. But still some people use Java 8 for some reason :neutral_face: (issues like #1373 and #1280).
Also, I need to mention that runtime java version and compilation target version are different issues. For runtime, it is always better to use the latest Java version, but compilation target version can be still be old and this not affect performance much. Using old java API is not a big deal, so using Java 8 for jadx library is fine for now. And as I see, only small amount of libraries on maven central moved to java 11, so I also will not rush things on this part.

@b0123456789 forget to say: If possible, please share your apk, so I can profile it, and maybe I will find some issues which causes increased memory usage.

classes.dex.all.zip

sorry for later
The app can't upload becouse of it is to big. if you need this, i'll upload tomorrow。
the app has a shell to hide dex files.
the classes.dex.all.zip is dump from the app  by frida_dump.
i use this to analyse.

@b0123456789 thanks for the sample!
I commit several tweaks to improve memory usage, also processing threads count will be reduced on low memory automatically.
These changes allow me to successfully decompile your sample with 4 GB on Java 17.

Thx,it work


Add some medium level problems in cpp

Select the Day of Content
Day 22
What information is missing?
i am adding some medium level cpp questions

please merge PR #412 @subhadipbhowmik


Primitives, enum and CIM_datatype

Enum classes
Correctly defining classes with defined values, using Enum. (Issue: #38 )
Examples: UnitSymbol or UnitMultiplier
Primitives classes
The current model generates classes for primitives, which are then rarely used to define the other classes.
Instead of creating individual classes for each primitives, a generic Primitive class is created.
Examples:
Float = Primitive(name="Float", type=float, profiles=[Profile.EQBD, Profile.OP, Profile.SSH, Profile.EQ, Profile.DY, Profile.DL, Profile.SV, Profile.SC, ])
Common CIMDatatype class
The current model generates datatypes that are then never used in the cim classes (example: CurrentFlow).
Instead of creating multiple unused classes with the same attributes (multiplier, unit, value), this pr creates a generic CIMDatatype class. (Issue: #38 )
Examples:
CurrentFlow = CIMDatatype(name="CurrentFlow", type=float, symbol=UnitSymbol.A, multiplier=UnitMultiplier.none, profiles=[Profile.SSH,Profile.EQ,Profile.SV,Profile.SC,])
Annotation of the data type
As said above, the newly created datatypes are added as annotation (data_type) when creating the other classes.
@dataclass
class CurrentLimit(OperationalLimit):
    """
    Operational limit on current.

    normalValue: The normal value for limit on current flow. The attribute shall be a positive value or zero.
    value: Limit on current flow. The attribute shall be a positive value or zero.
    """

    normalValue : float = Field(default=0.0, data_type = CurrentFlow, json_schema_extra={"in_profiles":[Profile.EQ, ]})

    value : float = Field(default=0.0, data_type = CurrentFlow, json_schema_extra={"in_profiles":[Profile.SSH, ]})

    @cached_property
    def possible_profiles(self)->set[BaseProfile]:
        """
        A resource can be used by multiple profiles. This is the set of profiles
        where this element can be found.
        """
        return { Profile.EQ, Profile.SSH,  }

@HUG0-D not necessarily linked to this PR, but it seems we have lot of annotations that may be redundant in attributes:
"""
Generated from the CGMES files via cimgen: https://github.com/sogno-platform/cimgen
"""

from functools import cached_property
from typing import Optional

from pydantic import Field
from pydantic.dataclasses import dataclass

from ..utils.profile import BaseProfile, Profile
from .Conductor import Conductor
from .Conductance import Conductance
from .Susceptance import Susceptance
from .Resistance import Resistance
from .Reactance import Reactance
from .Temperature import Temperature

@dataclass
class ACLineSegment(Conductor):
    """
    A wire or combination of wires, with consistent electrical characteristics, building a single electrical system,
      used to carry alternating current between points in the power system. For symmetrical, transposed 3ph lines,
      it is sufficient to use  attributes of the line segment, which describe impedances and admittances for the
      entire length of the segment.  Additionally impedances can be computed by using length and associated per
      length impedances. The BaseVoltage at the two ends of ACLineSegments in a Line shall have the same
      BaseVoltage.nominalVoltage. However, boundary lines  may have slightly different BaseVoltage.nominalVoltages
      and  variation is allowed. Larger voltage difference in general requires use of an equivalent branch.

    b0ch: Zero sequence shunt (charging) susceptance, uniformly distributed, of the entire line section.
    bch: Positive sequence shunt (charging) susceptance, uniformly distributed, of the entire line section.  This value
      represents the full charging over the full length of the line.
    g0ch: Zero sequence shunt (charging) conductance, uniformly distributed, of the entire line section.
    gch: Positive sequence shunt (charging) conductance, uniformly distributed, of the entire line section.
    r: Positive sequence series resistance of the entire line section.
    r0: Zero sequence series resistance of the entire line section.
    shortCircuitEndTemperature: Maximum permitted temperature at the end of SC for the calculation of minimum short-
      circuit currents. Used for short circuit data exchange according to IEC 60909
    x: Positive sequence series reactance of the entire line section.
    x0: Zero sequence series reactance of the entire line section.
    """

    b0ch: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Susceptance,
		},
    )

    bch: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Susceptance,
		},
    )

    g0ch: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Conductance,
		},
    )

    gch: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Conductance,
		},
    )

    r: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Resistance,
		},
    )

    r0: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Resistance,
		},
    )

    shortCircuitEndTemperature: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Temperature,
		},
    )

    x: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Reactance,
		},
    )

    x0: float = Field(
        default=0.0,
        json_schema_extra={
            "in_profiles": [
                Profile.EQ,
            ],
            "is_used": True,
            "is_class_attribute": False,
            "is_enum_attribute": False,
            "is_list_attribute": False,
            "is_primitive_attribute": False,
            "is_cim_datatype": True,
            "cim_data_type": Reactance,
		},
    )

    @cached_property
    def possible_profiles(self) -> set[BaseProfile]:
        """
        A resource can be used by multiple profiles. This is the set of profiles
        where this element can be found.
        """
        return {
            Profile.EQ,
        }

    @cached_property
    def recommended_profile(self) -> BaseProfile:
        """
        This is the profile with most of the attributes.
        It should be used to write the data to as few as possible files.
        """
        return Profile.EQ

"is_enum_attribute": False could be defined clearly by the linked type;
"is_primitive_attribute": False, "is_cim_datatype": True, "cim_data_type": Reactance,: seems overlapping.
When "is_list_attribute": True, we have anyhow pydantic annotations stating that:

  Cut: list = Field(
        default_factory=list,

@HUG0-D I have noticed that you have two "rebase branch" commits in this PR. Why do these commits exist? Usually there should not be a new commit introduced by the rebase process. I am referring to 01729efce4a62f202c6299d8dc7bc4b0157ffc02 and bdd09b416ba43390c838b74e22638a5f989ba123

@m-mirz thank you for pointing that out! This was my first time using rebase, and I realize now that I might not have followed the correct process, which led to those extra “rebase branch” commits. I tried to handle some merge conflicts manually, and doing so, I think I mistakenly created those additional commits.

During the rebase process, I encountered several issues that resulted in a messy commit history. To ensure the PR is clean and easy to review, I created a new branch from main and reapplied my changes with a clean commit structure.
The functionality and content of the PR remain the same as before, but now the history is more streamlined. Please let me know if you have any questions or concerns.
Thanks for your understanding!

it seems we have lot of annotations that may be redundant in attributes:

Most of these annotations comes from my PR https://github.com/sogno-platform/cimgen/pull/36 to provide information about the disjoint attribute types. Now, including "datatype" there are 5 disjoint attribute types:

is_class_attribute
is_enum_attribute
is_datatype_attribute
is_list_attribute
is_primitive_attribute

Maybe a single "attribute_type" (class, enum, ...) would be less noisy. But these booleans could easily used in chevron templates.

I know it's not caused by your changes, but I think this import in base.py is wrong:
from pycgmes.utils.constants import NAMESPACES
This should be:
from .utils.constants import NAMESPACES
In the same way "pycgmes" should be removed from chevron_writer.py.
And the comment in cimpy_cgmesProfile_template.mustache should be changed to:
All CGMES objects requiring a Profile are actually asking for a BaseProfile.


Fix view on small screens

There is an issue on the bottom on small screens:

The old version looks much better:

Hmmm,
I think you might need to add something like this for IOS:
body {     padding-bottom: env(safe-area-inset-bottom); }
But I cant test it

Where exactly should I add this row?

style.css

Actually, maybe something like this its probably better:
#_pages_content {     padding-bottom: env(safe-area-inset-bottom); }

It doesn't work

Line 61 in app.py
'content': 'width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, viewport-fit=cover'
Im sure there is a way to make it work, if you are willing to take the time, google "env(safe-area-inset-bottom)" and "not working" or something like that, sadly I cant make the testing myself.
If not, set this to 34pixels or so.
#_pages_content {     padding-bottom: 34px; }

Change line 61 in app.py to: 'content': 'width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, viewport-fit=cover'
Im sure there is a way to make it work, if you are willing to take the time, google "env(safe-area-inset-bottom)" and "not working" or something like that, sadly I cant make the testing myself. If not, set this to 34pixels or so. #_pages_content { padding-bottom: 34px; }

Yes, this is the same solution that I found as well. If you don't have the viewport-fit=cover, then the safe-area-inset-bottom doesn't work. With the viewport-fit=cover, it does apply the padding needed. Might have to find the right place to put that extra padding.

No, I can't see this problem on real device. All pages work as one page app

Ok, good. Then, yeah from my testing adding viewport-fit=cover and #_pages_content { padding-bottom: env(safe-area-inset-bottom); } as @ShadedSelf suggested, seems to work well. That style should take care of all pages when using the app in this add to home screen mode on iphone.

Thaks for help. It looks great again!

Glad we found the more correct solution vs adding padding to all devices.
By the way, if you decide you want a little more or less padding, you can also use the calc function to adjust that a bit. For example, something like this padding-bottom: max(0, calc(env(safe-area-inset-bottom) - 4px)) would adjust what ends up being a 34px padding to 30px without impacting other devices.
One other thing worth mentioning is that there are other safe-area variables we may need to revisit if we ever care about using a mobile device in landscape orientation, but at this point it doesn't seem super usable in that layout due to the other elements that constrain the plot too much.


[BUG] NV is not capable of detecting CVE-2020-8554.

Environment
Platform: Kubernetes
Kubernetes/Platform Version(s): 1.20.15
Describe the bug
NeuVector is capable of detecting orchestrator like Kubernetes vulnerabilities, but specifically for CVE-2020-8554 it still exist in latest recent k8s release and nv is not able to detect it.
To Reproduce
Steps to reproduce the behavior:

deploy NV with the latest version and enable platform scan.
in the platform ui we do not even see any vulnerabilities.

It will be included in the coming scanner release after 2.780.


[Regen] Implement Regeneration

Implements regeneration of code if temple generate is called in a directory that already contains some files that were previous generated by temple. Confirms with the user before actually deleting anything.
Implemented by generating everything as normal, but before writing anything to a file, checking if any of the generated files already exist. If they do and the user wants to overwrite, it simply removes any business logic files (setup.go and datastore.go) from the list of generated files to be outputted, the rest get overwritten.
Test Plan
Unit tests are written, but can test for yourself by trying to generate a templefile in a directory it's already been generated in before, make a change to a setup.go and it should still be there after generating again.

As mentioned in Slack, there's currently an awful hack in the filesUnderDirectory function - needs replacing

Also just a thought, what happens if they change the go module name between generations? I think if they've changed setup.go and added imports they'll break?

Also just a thought, what happens if they change the go module name between generations? I think if they've changed setup.go and added imports they'll break?

@jaylees14 yeah they will break, but there's not really a way around that unless we delve into the file itself, which would be a lot more work


HL-12 | Enable authentication

Description :sparkles:
Issues :bug:
Testing :alembic:
Screenshots :camera_flash:
Additional notes :spiral_notepad:

Codecov Report

Merging #261 (1760cae) into develop (d62630b) will decrease coverage by 1.42%.
The diff coverage is 95.78%.

@@             Coverage Diff             @@
##           develop     #261      +/-   ##
===========================================
- Coverage    95.64%   94.22%   -1.43%
===========================================
  Files          140      100      -40
  Lines         4726     3530    -1196
===========================================
- Hits          4520     3326    -1194
+ Misses         206      204       -2

Impacted Files
Coverage Δ

backend/benefit/applications/tests/factories.py
100.00% <ø> (ø)

backend/benefit/helsinkibenefit/settings.py
94.05% <ø> (ø)

backend/benefit/helsinkibenefit/urls.py
90.00% <ø> (ø)

backend/benefit/companies/api/v1/views.py
92.30% <71.42%> (-0.15%)
:arrow_down:

backend/benefit/applications/api/v1/views.py
90.47% <75.00%> (-5.45%)
:arrow_down:

backend/benefit/users/utils.py
85.71% <85.71%> (ø)

backend/benefit/applications/api/v1/serializers.py
94.82% <100.00%> (+0.46%)
:arrow_up:

backend/benefit/applications/tests/conftest.py
95.91% <100.00%> (+1.04%)
:arrow_up:

...t/applications/tests/test_application_batch_api.py
100.00% <100.00%> (ø)

...enefit/applications/tests/test_applications_api.py
99.80% <100.00%> (+0.02%)
:arrow_up:

... and 51 more

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 d62630b...1760cae. Read the comment docs.


Can't send push notification to iOS from POST

hi,
I only have one problem left.
Push notifications are working on android and iOS now when I use the firebase console in the browser.
When I try to you Postman to send a message only my android device gets the notfication.
I'm using this POST body:
 {     "notification" : {     "body" : "hello!",     "title": "afruz",     "sound": "default"   },     "priority": "high",     "condition": "'general' in topics" }
and I'm subscribing to the general topic in the OnStart() function in the App.xaml.cs file.
Another question, where do I get device-IDs?

When you are sending from firebase portal, are you using topics too?

yes also from firebase portal with topic only the android device gets the push notification.
Only when I choose both apps directly from the portal both devices gets them.

Send me your AppDelegate.cs

`
using System;
using System.Collections.Generic;
using System.Linq;
using Foundation;
using Plugin.FirebasePushNotification;
using UIKit;
namespace TestGPSBackround.iOS
{
    [Register("AppDelegate")]
    public partial class AppDelegate : global::Xamarin.Forms.Platform.iOS.FormsApplicationDelegate
    {
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            global::Xamarin.Forms.Forms.Init();

            LoadApplication(new App());

            FirebasePushNotificationManager.Initialize(options, true);

            return base.FinishedLaunching(app, options);
        }

        public override void RegisteredForRemoteNotifications(UIApplication application, NSData deviceToken) {
            #if DEBUG
            FirebasePushNotificationManager.DidRegisterRemoteNotifications(deviceToken, FirebaseTokenType.Sandbox);
            #endif
            #if RELEASE
            FirebasePushNotificationManager.DidRegisterRemoteNotifications(deviceToken,FirebaseTokenType.Production);
            #endif

        }

        public override void FailedToRegisterForRemoteNotifications(UIApplication application, NSError error)
        {
            FirebasePushNotificationManager.RemoteNotificationRegistrationFailed(error);

        }
        // To receive notifications in foregroung on iOS 9 and below.
        // To receive notifications in background in any iOS version
        public override void DidReceiveRemoteNotification(UIApplication application, NSDictionary userInfo, Action<UIBackgroundFetchResult> completionHandler)
        {
            // If you are receiving a notification message while your app is in the background,
            // this callback will not be fired 'till the user taps on the notification launching the application.

            // If you disable method swizzling, you'll need to call this method.
            // This lets FCM track message delivery and analytics, which is performed
            // automatically with method swizzling enabled.
            FirebasePushNotificationManager.DidReceiveMessage(userInfo);
            // Do your magic to handle the notification data
            System.Console.WriteLine(userInfo);
        }

        public override void OnActivated(UIApplication uiApplication)
        {
            FirebasePushNotificationManager.Connect();

        }
        public override void DidEnterBackground(UIApplication application)
        {
            // Use this method to release shared resources, save user data, invalidate timers and store the application state.
            // If your application supports background exection this method is called instead of WillTerminate when the user quits.
            FirebasePushNotificationManager.Disconnect();
        }
    }
}

`

Can you check the console logs to see if you get any errors?

Please let me know if anything related to an error shows up on your apllication outout

sorry I will check it out directly later today

so I checked now and I don't get any errors in my application output.
I'm subscribing in my App.xaml.cs in the OnStart() method. That is the right place for it, isn't it?

Yes is a good place to do it.
You can get the token on:

  CrossFirebasePushNotification.Current.OnTokenRefresh += (s,p) =>
  {
        System.Diagnostics.Debug.WriteLine($"TOKEN : {p.Token}");
  };

btw, maybe the reason you are not getting the notifications is that you are using the GoogleService-Info.plist of the sample. I got a few push notifications some hours ago, not sure if were your tests:

I don't think so because I receive the push notifications when I'm using my firebase GUI online.
I will test the sending with the device token later and if that works it will solve my problem I think

how are you sending the payload?

so my payload looks like this:
`{
"notification" : {
    "body" : "hello!",
    "title": "afruz",
    "sound": "default",
            "click_action":"request"

  },

 "priority": "high",

     "condition": "'general' in topics"

}`

Are you subscribing to general topic?

yes I'm subscribing to general like this in the App.xaml.cs:
`
namespace TestGPSBackround
{
public partial class App : Application
{
public App()
{
InitializeComponent();
MainPage = new TestGPSBackroundPage();
    }

    protected override void OnStart()
    {
        // Handle when your app starts
        CrossFirebasePushNotification.Current.Subscribe("general");
        CrossFirebasePushNotification.Current.OnTokenRefresh += (s, p) =>
        {
            System.Diagnostics.Debug.WriteLine($"TOKEN : {p.Token}");
        };
        System.Diagnostics.Debug.WriteLine($"TOKEN: {CrossFirebasePushNotification.Current.Token}");

    }

    protected override void OnSleep()
    {
        // Handle when your app sleeps
    }

    protected override void OnResume()
    {
        // Handle when your app resumes
    }
}

}
`

Are you getting a token?

Yes I do,
when I try to sind directly to the device with
{   "to" : "ejPGNUR476.......1QX2P6vKfFIoOH-2jz",   "priority" : "high",   "notification" : {     "body" : "Hello world",     "title" : "FCM Message",   } }
I'll get:
{     "multicast_id":<PHONE_NUMBER>908174964,     "success": 0,     "failure": 1,     "canonical_ids": 0,     "results": [         {             "error": "MismatchSenderId"         }     ] }
I have checked that this token ist the last one written in the Debig console

Still having this issue?

With a complete new setup and installation of the solution it works now.
Dont know where the problem was.


"error [object Arguments]" when running spec/features/interest_gathering_spec.rb

I've figured out how to set up this app, but there's still one hitch.  During the spec/features/interest_gathering_spec.rb tests, I get the message "error [object Arguments]" 3 times.

When I disable both scenario statements (and everything within them), the error message does not appear.  When I enable both scenario statements but disable everything within them, the error message appears twice.
When I enable the second scenario and everything in it but disable the first scenario and everything in it, I get the error message 3 times.  When I enable the first scenario and everything in it but disable the second scenario and everything in it, I get the error message once.

Removing the "js: true" specification causes actual test failures, just as expecting the page to have the content "BLAH" causes actual test failures.  Given that all tests pass in spite of the "error [object Arguments]", I can see why you've decided to let this slide for now.


[atom-reason] Remove useless menu items

OS X bar and right click, they all have these boilerplate toggle commands.

Did the same over at https://github.com/chenglou/atom-reason-loader/commit/9b2ce374d47df4d4abaa265a7db22604bcb78175
cc @frantic. Thanks for discovering these.


identity :type => Integer and string attributes

This works:
class Library
  include Mongoid::Document
  identity :type => Integer
end
class Book
  include Mongoid::Document
  belongs_to :library
end

Library.delete_all
Book.delete_all

library = Library.create!(:id => 1)
Book.create!(:library_id => 1)
p Book.first.library

prints
#<Library _id: 1, _type: nil>

But if you change it to this:
Book.create!(:library_id => "1")

It fails:
nil

Why does this matter? Oftentimes in Rails you use params to create/update Mongoid objects. Params are always strings. So if you change your identity type from BSON::ObjectId to Integer, things suddenly stop working. You can workaround the bug by using callbacks to set the correct type, but that seems like a hack.

The relation in Book isn't examining the target model's identity field, and casting the value as needed.

Here's my workaround, for you lazyweb types:

module Mongoid
  module FixIds
    extend ActiveSupport::Concern

    # see https://github.com/mongoid/mongoid/issues/1399

    included do
      before_validation :fix_ids
    end

    private

    def fix_ids
      attributes.each_pair do |key, value|
        if key =~ /_id$/ && value.is_a?(String)
          write_attribute(key, value.to_i)
        end
      end
    end
  end
end

I took a stab at this one.  I basically took your ideas and put them into Mongoid::Extensions::ObjectId::Conversions.convert
With my code as is, it will convert Integers -> Strings, and Strings -> Integers (which breaks spec ./spec/unit/mongoid/extensions/object_id/conversions_spec.rb:321 ).  Is that trying to do too much?  The fact that it breaks existing spec indicates that it might be.  Should it only be converting Strings to Integers when the identity type is Integer, nothing more and nothing less?
I'm still pretty new to Mongoid, so any feedback on the code change and/or spec is welcome.
https://github.com/dsachitano/mongoid/compare/e7e699d35f...5958438

I wish I could be more helpful here. I think Durran needs to chime in and give us some advice. :)

@dsachitano Yeah, the conversion should only occur if the identity type is Integer.


Rename AdaptiveSkillDialog => BeginSkillDialog as an action

Rename $kind Microsoft.SkillDialog => Microsoft.BeginSkillDialog
Rename class AdaptiveSkillDialog => BeginSkillDialog
Move files into actions folders
replace all $kind => new $kind
update test schema

"Rename $kind Microsoft.SkillDialog => Microsoft.BeginSkillDialog"
Can we please call this 'Microsoft.BeginSkill" vs SkillDIalog?
For 2 reasons:

Duplication and confusion prevention. Is it a skill or a dialog? I this case it's a skill, the 'remote skill' type, which is immutable. Dialogs are 'mutable' (this is the whole essence of the SDK!) so let's not merge the concepts.

PVA uses Topics and this is a concept that is very important to them and so far it resonates with their audience. Dialogs are 'holy' for the SKD/Composer
Skills is a mechanism for us to connect PVA and Composer. So let's please keep the terms around calling/launching a Skill as neutral as possible and not add Dialog unless absolutely necessary. Which imo it is not in this case.

@cwhitten @tomlm @sangwoohaan @cleemullins

@cwhitten - for terms and terminology, could you please include myself and VIsh as approvers as we both work on this from the SDK and Composer UX perspective?

Given that half of us thought BeginSkilll was a fine name, and Marieke has put her weight strongly behind BeginSkill we are going to snap to that.  Update pending.

thank you @tomlm (-:


Would be rad if you could pass a github repo url instead of a directory

As lovely as the Github language percentage statistics are, they don't actually tell you how many lines of code are written in each language.

This is an awesome idea! Do you know any libs that could help us to implement this feature?

Don't I'm afraid. To be honest, I actually found your tool because I was looking for something that would do this. Still haven't found one yet though.

@flosse I am not quite sure what would be stopping you. AFAIK implementing this would just mean

cloning the repo to some temporary directory
using the existing code to traverse the repo
aggregate the results per language (taking the json-output or similar)

Am I missing something? Everyone has git installed, so you would not have to install nodegit. I created a little utility tool that has some relevant code you could just copy to achieve the first step.

@flosse I am not quite sure what would be stopping you.

the missing time ;-)

Everyone has git installed, so you would not have to install nodegit (which I found a bit buggy ...)

yes, I agree. I'd prefer to use native git and if git is not installed, sloc should just exit with an error

I created a little utility tool that has some relevant code you could just copy to achieve the first step.

that sounds good :)
...so I'm looking forward for the first PR :)

or make a feature request to github

Delivering a master thesis in a week, so I'll have a vacation before doing anything else, but a PR might arrive in August :-) Just wanted to be clear about the show stoppers before doing anything.

If you really are specific to github, there's the API: https://api.github.com/repos/flosse/sloc/languages
Otherwise, general git support would be appreciated (not just github).


nghttp2: 1.34.0 -> 1.35.0

Motivation for this change
https://nghttp2.org/blog/2018/11/23/nghttp2-v1-35-0/
Things done

[x] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
Built on platform(s)

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Fits CONTRIBUTING.md.

Success on aarch64-linux (full log)
Attempted: nghttp2
Partial log (click to expand)
stripping (with command strip and flags -S) in /nix/store/kbc7wx4m6kipjkywq7890p3dnrfvvdvj-nghttp2-1.35.0-dev/lib
patching script interpreter paths in /nix/store/kbc7wx4m6kipjkywq7890p3dnrfvvdvj-nghttp2-1.35.0-dev
checking for references to /build/ in /nix/store/kbc7wx4m6kipjkywq7890p3dnrfvvdvj-nghttp2-1.35.0-dev...
shrinking RPATHs of ELF executables and libraries in /nix/store/6gc463lgqp95hy2pnyydkpr3imazs269-nghttp2-1.35.0-lib
shrinking /nix/store/6gc463lgqp95hy2pnyydkpr3imazs269-nghttp2-1.35.0-lib/lib/libnghttp2.so.14.17.1
strip is /nix/store/yyx28sl7a9n4xs9f82v0llpvrmryanan-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/6gc463lgqp95hy2pnyydkpr3imazs269-nghttp2-1.35.0-lib/lib
patching script interpreter paths in /nix/store/6gc463lgqp95hy2pnyydkpr3imazs269-nghttp2-1.35.0-lib
checking for references to /build/ in /nix/store/6gc463lgqp95hy2pnyydkpr3imazs269-nghttp2-1.35.0-lib...
/nix/store/vifbwfz78j0825b1xbpk2aixzgba9dn3-nghttp2-1.35.0-bin

Success on x86_64-linux (full log)
Attempted: nghttp2
Partial log (click to expand)
strip is /nix/store/br51frm28n8n85bs9wrcx6g8rpa42ain-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/qg5pkd21j3mzp34a26xb23yhrjgg2i5w-nghttp2-1.35.0-dev/lib
patching script interpreter paths in /nix/store/qg5pkd21j3mzp34a26xb23yhrjgg2i5w-nghttp2-1.35.0-dev
checking for references to /build/ in /nix/store/qg5pkd21j3mzp34a26xb23yhrjgg2i5w-nghttp2-1.35.0-dev...
shrinking RPATHs of ELF executables and libraries in /nix/store/bsfh4bzxxaq5fz0ddxzvd1dkgddlz5yv-nghttp2-1.35.0-lib
shrinking /nix/store/bsfh4bzxxaq5fz0ddxzvd1dkgddlz5yv-nghttp2-1.35.0-lib/lib/libnghttp2.so.14.17.1
strip is /nix/store/br51frm28n8n85bs9wrcx6g8rpa42ain-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/bsfh4bzxxaq5fz0ddxzvd1dkgddlz5yv-nghttp2-1.35.0-lib/lib
patching script interpreter paths in /nix/store/bsfh4bzxxaq5fz0ddxzvd1dkgddlz5yv-nghttp2-1.35.0-lib
checking for references to /build/ in /nix/store/bsfh4bzxxaq5fz0ddxzvd1dkgddlz5yv-nghttp2-1.35.0-lib...

Timed out, unknown build status on x86_64-darwin (full log)
Attempted: nghttp2
Partial log (click to expand)
strip is /nix/store/2ws9cmamvr7xyvdg4d2nnd1bmr1zjrrq-bootstrap-tools/bin/strip
patching script interpreter paths in /nix/store/ir59rqmyzvbhas3dwyfi3yhc58dws1nn-swift-corefoundation
cannot build derivation '/nix/store/fw14vh27ia8bjd10mnmlacizw44ak55c-stdenv-darwin.drv': 7 dependencies couldn't be built
cannot build derivation '/nix/store/sqy375bq6g2frm6vlzizv9gg6yl00lpc-c-ares-1.15.0.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/c5g9wbhs42adh0iqlijy5v4dsc3bg0gw-libev-4.24.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/zhr26mflrz29s270ai45wn8wnzb1m3dk-perl-5.28.0.drv': 3 dependencies couldn't be built
cannot build derivation '/nix/store/cl0wrs3s7gaf1l0h631c9rbd5y5ksk8y-pkg-config-0.29.2.drv': 1 dependencies couldn't be built
cannot build derivation '/nix/store/x71yy96x3ya42y2nm0rjhykxaq0gci3a-openssl-1.0.2q.drv': 2 dependencies couldn't be built
cannot build derivation '/nix/store/vqw4nw662pxvqy2lf5vlfh2ijpdkvnii-nghttp2-1.35.0.drv': 5 dependencies couldn't be built
error: build of '/nix/store/vqw4nw662pxvqy2lf5vlfh2ijpdkvnii-nghttp2-1.35.0.drv' failed


Add support for Javascript template literals

Pull request in order to allow the extraction of template strings (String enclosed in back-tick) in Vue JS.

The travis CI build failed is caused by twig line numbering not matching in PHP 7.X

Many thanks 👍


[FR.] send caller application info regardless of sampling rate

Which module is your feature request related to?
agent
Is your feature request related to a problem?
When a request is not sampled, we can still capture(tcpdump)/record the request header Pinpoint-pAppName to know who is calling my app. If both applications have different sampling rate, the caller may be identified by "User", if we send the caller application info and use the recording request header feature, then we could know who is calling from a call tree.

If the trace is not sampled, it's an optimization that removes unnecessary information, so it's not a bug.
I agree with your pr.
It seems appropriate to add a new option.

It's not a bug but a feature(FR.=Feature Request). A configuration was added later and this feature is disabled by default, not breaking existing behavior.

Closed. Related to #8557. Use a new configurable header to pass caller application name.


Burning out incompletely carved canoes leads to burnt-out canoe blocks remaining behind

When a canoe is carved out incompletely (screenshot 1) it can be lit up, which will lead to the whole assembly remaining intact (screenshot 2). breaking the uncarved block also breaks the middle block (screenshot 3) but leaves one of the burnt out blocks behind.

Ah, i forgot to mention it: This issue occured with TerraFirmaCraft 2.2.15, Pachouli 71.1 and Firma: Civilization 0.0.20 installed. I used a standard Curseforge profile, so Forge 40.2.0 was installed (assume further helpers that cf automatically adds, im not sure how much it really does beyond basic Forge)


Touchscreen support

Hi,
I've been using sway for a couple of weeks but I'm missing touch support, so I posted an issue here: https://github.com/SirCmpwn/sway/issues/721. They say this is probably something that can be implemented in WLC.
I have a Lenovo Yoga 3 14'', which has a touchscreen. It seems to be supported with different X desktops like LXDE, Unity, i3, but not on sway. It can scroll and sometimes pinch and zoom, but the focused element is usually wrong. I can't tap on any button because of this focus issue.
I just installed Weston, and it seems like touch works pretty well on weston-terminal, but I opened pcmanfm and I couldn't even hit the close button (pretty much what happens on sway). However, a weston-terminal window in sway doesn't work well.
I'd be happy to help testing a development version including changes for touch support.
Thanks,
Martín.

https://github.com/Cloudef/wlc/pull/143 @Hummer12007 has open touch related code.
I don't have touchscreen myself, but extracting from your comment. Touch screen seems to work partially in wlc? (Same as in weston?). Pcmanfm sounds like x11 client and it may be they don't respond to touch events but only mouse events. Technically wlc could send both mouse and touch events though.

Installed packages that may be related: xf86-input-evdev, xf86-input-libinput, libinput
In Weston, I can use some apps with pretty decent touch support. So far:

the desktop itself: open a terminal by touching the icon and moving windows around by dragging the title bar
weston-terminal: lets me select text (but not scroll)
pcmanfm: lets me tap. lets me scroll, but sometimes it tries to select files. doesn't let me open folders by double tapping. it crashes pretty often.

In Sway, it feels like the touchscreen is being emulated as a mouse, but the behavior is not very consistent:

I can sometimes scroll (in Google Chrome) with one finger, sometimes with two
I can sometimes pinch and zoom (in Google Chrome) with two fingers, sometimes with three
I don't have any touch response from pcmanfm
The focus seems to be where the cursor is, and not where the touch happens
Touching a window doesn't focus it
Tapping doesn't do anything (no click, nothing), even if the cursor is over a link or button

Also, I hit pkill weston in a terminal and I can see the following message in the terminal after the desktop goes away: deactivating sessionut device '/dev/input/event5' .agged as input devicehpadudev as: Touchpad Touchscreen.

Information pertaining to touch/gesture support in Plasma 5.10 (on Wayland): https://blog.martin-graesslin.com/blog/2017/04/how-input-works-touch-screen-edge-swipe-gestures/ and https://blog.martin-graesslin.com/blog/2016/12/how-input-works-pointer-input/


ImportError: /lib64/libc.so.6: version `GLIBC_2.28' not found

          Dear sir, I have solved the problem occured before using command 'conda install -c conda-forge ffmpeg';   But I met a new problem: when  I was running training procedure by "python3 mm_video/run_net.py --cfg configs/compressed_video/msrvtt_captioning.yaml" , I got error "ImportError: /lib64/libc.so.6: version `GLIBC_2.28' not found (required by /home/qysu/anaconda3/envs/cocap/lib/python3.9/site-packages/cv_reader/api.cpython-39-x86_64-linux-gnu.so)", what can I do to solve it? Thanks.

Hello!
Here is a compiled wheel package: Google Drive This was built by running python3 setup.py bdist_wheel under the root folder of this project after preparing the ffmpeg. You can compile it yourself if your environment does not match mine.
To install it, run pip3 install cv_reader-1.1.0-cp39-cp39-linux_x86_64.whl.

Hello! Thanks for your reply, I have installed the package in the requriement.txt and then installed cv_reader-1.1.0-cp39-cp39-linux_x86_64.whl by pip3 install cv_reader-1.1.0-cp39-cp39-linux_x86_64.whl. Unfortunately, when I tap "cv_reader", I got the error in the picture 1 below : "ImportError: libbz2.so.1.0: cannot open shared object file: No such file or directory"; Second, when I was running code: "python3 tools/video_convert.py --codec=libx264 --keyint=60 --resize=240 -i dataset/msrvtt/videos -o dataset/msrvtt/videos_h264_keyint_60" according to the Cocap/dataset/README.md, I got the error: FileNotFoundError: [Errno 2] No such file or directory: '/usr/bin/ffmpeg', Any other problem with my environment? How to fix them? Thanks, sir.

Originally posted by @Suqingyong in https://github.com/acherstyx/Compressed-Video-Reader/issues/2#issuecomment-1913593555

sorry, I do not kown how to quote last issue, so I opened an new issue, sorry to disturb you,sir.


Python 3.9 support

Running the asynctest unittests under Python 3.9 yields a bunch of test case failures.
Example:
======================================================================
ERROR: test_patch_generator_with_multiple_scopes (test.Test_patch_decorator_coroutine_or_generator_scope)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/asynctest-0.13.0/test/test_mock.py", line 1650, in test_patch_generator_with_multiple_scopes
    self.assertEqual((True, True), next(gen))
  File "/builddir/build/BUILD/asynctest-0.13.0/asynctest/mock.py", line 995, in patched_generator
    return (yield from patched_factory(*args, **kwargs))
  File "/builddir/build/BUILD/asynctest-0.13.0/asynctest/mock.py", line 985, in patched_factory
    patching.__exit__(*exc_info)
  File "/usr/lib/python3.9/unittest/mock.py", line 1536, in __exit__
    return exit_stack.__exit__(*exc_info)
  File "/usr/lib/python3.9/contextlib.py", line 471, in __exit__
    received_exc = exc_details[0] is not None
IndexError: tuple index out of range
======================================================================
ERROR: test_deactivate_patch_when_generator_exec_fails (test.Test_patch_decorator_coroutine_or_generator_scope_GLOBAL)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/asynctest-0.13.0/test/test_mock.py", line 1739, in test_deactivate_patch_when_generator_exec_fails
    self._test_deactivate_patch_when_generator_exec_fails(asynctest.GLOBAL)
  File "/builddir/build/BUILD/asynctest-0.13.0/test/test_mock.py", line 1348, in _test_deactivate_patch_when_generator_exec_fails
    run_coroutine(tester())
  File "/builddir/build/BUILD/asynctest-0.13.0/test/utils.py", line 9, in run_coroutine
    return loop.run_until_complete(coroutine)
  File "/usr/lib/python3.9/asyncio/base_events.py", line 642, in run_until_complete
    return future.result()
  File "/builddir/build/BUILD/asynctest-0.13.0/test/test_mock.py", line 1341, in tester
    yield from a_coroutine()
  File "/builddir/build/BUILD/asynctest-0.13.0/asynctest/mock.py", line 995, in patched_generator
    return (yield from patched_factory(*args, **kwargs))
  File "/builddir/build/BUILD/asynctest-0.13.0/asynctest/mock.py", line 1044, in __next__
    self._stop_global_patchings()
  File "/builddir/build/BUILD/asynctest-0.13.0/asynctest/mock.py", line 1032, in _stop_global_patchings
    if _is_started(patching):
  File "/builddir/build/BUILD/asynctest-0.13.0/asynctest/mock.py", line 124, in _is_started
    return unittest.mock._is_started(patching)
AttributeError: module 'unittest.mock' has no attribute '_is_started'
-------------------- >> begin captured logging << --------------------
asyncio: DEBUG: Using selector: EpollSelector
--------------------- >> end captured logging << ---------------------
[..]
======================================================================
FAIL: test_patch_as_decorator_uses_CoroutineMock_on_async_coroutine_function (test.test_mock.Test_patch)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/asynctest-0.13.0/test/test_mock.py", line 940, in test_patch_as_decorator_uses_CoroutineMock_on_async_coroutine_function
    test_mock_coroutine()
  File "/usr/lib/python3.9/unittest/mock.py", line 1337, in patched
    return func(*newargs, **newkeywargs)
  File "/builddir/build/BUILD/asynctest-0.13.0/test/test_mock.py", line 937, in test_mock_coroutine
    self.assertIsInstance(mock, asynctest.mock.CoroutineMock)
AssertionError: <MagicMock name='an_async_coroutine' id='4125941040'> is not an instance of <class 'asynctest.mock.CoroutineMock'>

See https://kojipkgs.fedoraproject.org//work/tasks/8916/45078916/build.log for the full log.
The _is_started error is already reported in #149.

Related: Currently, asynctest doesn't support Python 3.8, either, cf. #132 and #144


System.ArgumentException on creation of XMLSerializer

Describe the bug
At the moment I am trying to parse an XML into an C# object. (link to the XML)
So I made 3 objects:
[XmlRoot("astronomical-tide")]
public class Tide
{
    [XmlElement("location")]
    public string Location;

    [XmlElement("reference")]
    public string Reference;

    [XmlElement("timezone")]
    public string Timezone;

    [XmlElement("source")]
    public string Source;

    [XmlArray("values")]
    [XmlArrayItem("value")]
    public TideValue[] TideValues;
}

public class TideValue
{
    [XmlElement("datetime")]
    public DateTimeValue DateTimeValue;

    [XmlElement("tide")]
    public string Tide;

    [XmlElement("val")]
    public int Value;

    [XmlIgnore]
    public DateTimeOffset Date
    {
        get
        {
            var dateTime = DateTime.ParseExact(DateTimeValue.CurrentDateTime.Trim(), "yyyyMMddHHmm", CultureInfo.InvariantCulture);

            TimeSpan timeZone;
            if(DateTimeValue.SummerTime == "yes")
                timeZone = new TimeSpan(2, 0, 0);
            else
                timeZone = new TimeSpan(1, 0, 0);

            return new DateTimeOffset(dateTime, timeZone);
        }
    }
}

public class DateTimeValue
{
    [XmlAttribute("summertime")]
    public string SummerTime;

    [XmlText]
    public string CurrentDateTime;
}

Edit: Fixed the serializer
However if I now try to construct a XML Serializer
using(var fs = new FileStream("./Westkapelle2022.xml", FileMode.Open))
{
    var serializer = new XmlSerializer(typeof(Tide));
}

I get an Error: System.ArgumentException: Identifier 'Submission#8' is not CLS-compliant. (Parameter 'ident').
Is this a bug in my code or in .net interactive?
Notes:

All the usings are in place
Both of the blocks of code are in the same code field
I tried to add an [DataContract] attribute, this had the same result

Please complete the following:
Which version of .NET Interactive are you using?:
Version: 1.0.260601+9d1ecd3c06ba93e59bfef3842d2660c08d9e2ce5

OS

[ ] Windows 11
[x] Windows 10
[ ] macOS
[ ] Linux (Please specify distro)
[ ] iOS
[ ] Android

Frontend

[ ] Jupyter Notebook
[ ] Jupyter Lab
[ ] nteract
[x] Visual Studio Code
[ ] Visual Studio Code Insiders
[ ] Visual Studio
[ ] Other (please specify)

Screenshots
Well not a screenshot, but a dump of the stacktrace.
Error: System.ArgumentException: Identifier 'Submission#8' is not CLS-compliant. (Parameter 'ident')
at System.Xml.Serialization.CodeIdentifier.CheckValidIdentifier(String ident)
at System.Xml.Serialization.CodeIdentifier.EscapeKeywords(String identifier, StringBuilder sb)
at System.Xml.Serialization.CodeIdentifier.GetCSharpName(Type t, Type[] parameters, Int32 index, StringBuilder sb)
at System.Xml.Serialization.CodeIdentifier.GetCSharpName(Type t, Type[] parameters, Int32 index, StringBuilder sb)
at System.Xml.Serialization.CodeIdentifier.GetCSharpName(Type t)
at System.Xml.Serialization.TypeDesc.get_CSharpName()
at System.Xml.Serialization.SourceInfo.CastTo(TypeDesc td)
at System.Xml.Serialization.XmlSerializationWriterILGen.WriteElements(SourceInfo source, String enumSource, ElementAccessor[] elements, TextAccessor text, ChoiceIdentifierAccessor choice, String arrayName, Boolean writeAccessors, Boolean isNullable)
at System.Xml.Serialization.XmlSerializationWriterILGen.WriteMember(SourceInfo source, String choiceSource, ElementAccessor[] elements, TextAccessor text, ChoiceIdentifierAccessor choice, TypeDesc memberTypeDesc, Boolean writeAccessors)
at System.Xml.Serialization.XmlSerializationWriterILGen.GenerateTypeElement(XmlTypeMapping xmlTypeMapping)
at System.Xml.Serialization.XmlSerializationWriterILGen.GenerateElement(XmlMapping xmlMapping)
at System.Xml.Serialization.TempAssembly.GenerateRefEmitAssembly(XmlMapping[] xmlMappings, Type[] types, String defaultNamespace)
at System.Xml.Serialization.TempAssembly..ctor(XmlMapping[] xmlMappings, Type[] types, String defaultNamespace, String location)
at System.Xml.Serialization.XmlSerializer.GenerateTempAssembly(XmlMapping xmlMapping, Type type, String defaultNamespace, String location)
at System.Xml.Serialization.XmlSerializer..ctor(Type type, String defaultNamespace)
at System.Xml.Serialization.XmlSerializer..ctor(Type type)
at Submission#8.<<Initialize>>d__0.MoveNext()
--- End of stack trace from previous location ---
at Microsoft.CodeAnalysis.Scripting.ScriptExecutionState.RunSubmissionsAsync[TResult](ImmutableArray`1 precedingExecutors, Func`2 currentExecutor, StrongBox`1 exceptionHolderOpt, Func`2 catchExceptionOpt, CancellationToken cancellationToken)

One note I wild like to add is that, while attempting to fix my serialization objects, I needed to enable "Use a non-collectible load context for this query" in LINQPad 7.
However since I don't have the full version of LINQPad I can't use the nuget packages I need for the rest of the code.

I wonder whether the serializer can be configured to work around this issue.
In both of these cases, the problem is that the underlying compiler implementation produces non-CLS compliant symbol names. These are behaviors (for differing reasons) of the C# and F# compilers, which is why I marked the issue as external. I don't expect we would be able to address them any time soon but opening issues in those repos might provide more insight.

But why do you need to produce a CLS Compliant assembly?

It is a script. It can be non compliant

It is non-compliant. It's the XML serializer that has a problem with that.

Do you mean that the XML serializer creates an assembly on the fly and marks it as CLS Compliant?
Makes sense

The script engines create assemblies as code is run. Those assemblies are non-CLS compliant. From the stack trace, it looks to me like the XML serializer doesn't like that. I'm not sure why that restriction would be in place. There might be a way to configure it to ignore it.


cabal index doesn't provide necessary info

According to https://github.com/berberman/arch-hs/issues/84, cabal index doesn't provide necessary info.

I'm not sure what this means. I think what the other person meant is that Cabal doesnt provide this info in general, so you have to run a separate command to expose the info to arch-hs. I think you have to call gen-setup before running the command that's failing. It's not a bug in toml-reader, you have to do this for any package that doesnt provide Setup.hs (which is an optional file)

@felixonmars so It's also not the bug of tmol-reader? Is it possible to gen-setup automatically in PKGBUILD generated by arch-hs.

@Freed-Wu It's not a bug of any individual packages not providing Setup.hs. It's also not possible for arch-hs to know whether gen-setup is needed because the Cabal index doesn't carry information about it (and downloading the tarball to analyze is way more expensive). So I don't really see how we could improve the situation :(


Added a new FAQ about iOS and Android device registration limitation

Please review and approve as appropriate.

@sdabbiru : Thanks for your contribution! The author, @MarkusVi, has been notified to review your proposed change.

#sign-off


Limiting plots

[x] This issue isn't duplicated - you can check if it is by using the search bar located at the top left hand corner and select "Issues" on the left.
[ ] This issue includes appropriate markdown for sections - e.g. code blocks for crash dumps.
[x] This issue is understandable - feel free to use your native language to write issues if you are not comfortable with English.

The permission node to limiting amount of plots player can claim does not work.

Try to use the permission node - -plot.claimplots.2 in pureperms, it doesn't deny a player from claiming 2 plots.

Using the permission '- -plot.claimplots.2' doesn't deny the player from claiming two plots.

This is an issue with PurePerms, not MyPlot


Added options plugins afterEach and beforeEach

example
require('postcss-each')({
  plugins: {
    afterEach: [
      require('postcss-at-rules-variables')
    ],
    beforeEach: [
      require('postcss-custom-properties')
    ]
  }
})

@GitScrum Thanks! Published.


Allow to show status bar entries with an id and name

This would allow us to hide/show individual entries from an extension to the status bar as opposed to hiding them all.
PS: this concept may be useful also for notifications to allow fine grained filtering.

Current idea:
/**
 * Options to configure the status bar item.
 */
export interface StatusBarItemOptions {

	/**
	 * A unique identifier of the status bar item.
	 */
	id: string;

	/**
	 * A human readable name of the status bar item.
	 */
	name: string;

	/**
	 * The alignment of the status bar item.
	 */
	alignment?: StatusBarAlignment;

	/**
	 * The priority of the status bar item. Higher value means the item should
	 * be shown more to the left.
	 */
	priority?: number;
}

/**
 * Creates a status bar [item](#StatusBarItem).
 *
 * @param options The options of the item.
 * @return A new status bar item.
 */
export function createStatusBarItem(options?: StatusBarItemOptions): StatusBarItem;

@bpasero what's the fallback name/id when options isn't specified?

@Tyriar it will be the extension identifier and the extension name. See https://github.com/microsoft/vscode/commit/3d91fa8c278cff8d4838357fdcf8e3c265c1b27d

We could also consider grouping id/name into a separate object and explain its purpose and (maybe) reuse that object elsewhere (notification & don't show again)?

@jrieken yeah, I am not sure I can come up with a good name though unless we make this very specific to what it is used (filtering). To be honest, we already talk about identifiers in certain places, e.g. viewId in createTreeView, so it seems statusEntryId and notificationId are not too far off. Problem is that it needs a label too..

Pushed as proposed API but we should only have the discussion about finalizing the API when we looked at notifications too where we have an interest to hide based on id.

		export function createStatusBarItem(id: string, alignment?: StatusBarAlignment, priority?: number): StatusBarItem;

export interface StatubarItem {
  readonly id: string;

  description?: string;
}

Slight update to the proposal: I went with name and not description because I feel description is being used in many places to indicate further verbose text for an item (e.g. in custom trees). I think the risk is that extensions would fill in lots of text for a description property.
With name, it becomes more obvious that we want a short value. We also use name internally in the workbench.
export interface StatusBarItem {

	/**
	 * The identifier of this item.
	 *
	 * *Note*: if no identifier was provided by the {@link window.createStatusBarItem `window.createStatusBarItem`}
	 * method, the identifier will match the {@link Extension.id extension identifier}.
	 */
	readonly id: string;

	/**
	 * The (short) name of the entry, like 'Language Indicator', 'Git Status' etc.
	 */
	name: string | undefined;
}

/**
 * Creates a status bar {@link StatusBarItem item}.
 *
 * @param id The unique identifier of the item.
 * @param alignment The alignment of the item.
 * @param priority The priority of the item. Higher values mean the item should be shown more to the left.
 * @return A new status bar item.
 */
export function createStatusBarItem(id: string, alignment?: StatusBarAlignment, priority?: number): StatusBarItem;

How will this be rendered in the menu? Will it be prefixed with the extensions name or should the name be descriptive enough to make it clear which extension it's for? (For example if I'm showing the Dart SDK Version in the status bar, should I use "SDK Version" and assume it'll render like "Dart: SDK Version" or should I set it to "Dart SDK Version"?)

@DanTup that is a good point, currently it will not be prefixed. I feel this is something we can always add later when we think it is needed.
To be honest, we do not prefix in other locations so I think we should not just do it without good reasons. E.g. here an extension provides the "GitHub" view and it is not treated any different from other views:

@bpasero sounds good to me. It may be worth noting that in the doc to encourage people to make the names descriptive enough.
It does raise a question about what if there are dupes from different extensions, although it seems like even if they had the same labels here it'd be fairly easy to know which is which by just toggling.

Yeah good point, updated the JSDoc to:
/**
 * The name of the entry, like 'Python Language Indicator', 'Git Status' etc.
 * Try to keep the length of the name short, yet descriptive enough that
 * users can understand what the status bar item is about.
 */
name: string | undefined;