Feature/documentation request: safely find record(s) by field value

The docs mention this:
client.find('Account', '1234', 'Some_External_Id_Field__c')
# => #<Restforce::SObject Id="001D000000INjVe" Name="Test" LastModifiedBy="005G0000002f8FHIAY" ... >

So my first issue is I'm not sure what an external Id field is, but as far as I can tell it won't work with any field.
As a Plan B, I was thinking I could try this couplet:
id = api.query("select Id from Account where Name = (value)").first.Id
api.find('Account', id)

The trouble is, in the case I'm looking at, (value) would be user input. So I'm worried it could be the SOQL equivalent of DROP TABLE Account.
So is there a safe way to get SF records by a particular value atm?

@Arepo Thanks for the issue, and sorry for my slow reply.
An external ID field has to be unique across all records, but has the benefit that you can filter by it in the API (using the #find method on the Restforce client). That won't be suitable for generic querying (e.g. by name, as you suggest).
If you take a look at Salesforce's "SOQL Injection Defences", they suggest escaping single quotes as a way of avoiding malicious queries. This only works with strings, and you might have to try other things to escape other kinds of data.

Thanks Tim


Ability to annotate SBOL designs

Often designs need to be annotated in multiple places to highlight for example primer binding sites. These are not necessarily part of the original design, but are required in the visualisation. Such an ability needs to be integrated into the library - annotate type function would work well.

Fix has been committed. There is now an annotate function in the DNArenderer object that will overlay the rendering of a particular part on a design. This required the addition of an order_add option to allow for parts to be raised from the normal rendering plane.


missing features - select and include query fields is missing

select and include  query fields is not included in the dmmf so our code doesn't generate it
we should found a way to support it

I think for language like dart to support like this feature  we should create a new methods for each existing prisma method but has select and include fields and aslo we should  make all it is output fields nullable (or maybe late)

The simplest support solution might be to not deserialize the model, but return the Map type, but this is contrary to the original intention of Prisma.
We need to wait for the new version of Dart grammar, union types have been proposed in Dart Language: https://github.com/dart-lang/language/issues/83
https://github.com/dart-lang/language/blob/master/working/0546-patterns/exhaustiveness.md#sealed-types
Before that, we want to support include and selected It may only return map type data, if you want to deserialize the model, you must get the support of the union type. Currently our union type in the input phase is a very plain design and adds complexity to passing parameters.

I could  3 solution for this
return a map:

easy to implement
developer need to write the key my him self (or we generate some helper for them)
need to handle null

make all field a late and only set what we receive:

hard to implements as we need to write a custom json serializer
developer need to remember what he select and only access this value
no need to handle null
no need to write a key

make all field nullable

easy to implements (just make all field nullable)
developer need to handle null for each field (maybe just use ! or writing if condition)
no need to write a key string
developer need to

we could apply one of this for all the existing methods
or we create a new methods that support select and include fields
my suggestion is keep the existing method as they are without include and select fields (as they support type safety better )
and create a new method in one of this way
  1- prisma.user.selectInclude.create(...);
  2- prisma.user.createWithInclude(...);

this new method will have all its output fields nullable

Why don't we create a new branch to experiment with it? An experimental version is then released for users to choose from.
If we want to support type safety well and complete the select and include features it is difficult. Proposals for Dart union types have been around for ten years and have not been implemented. And there is nothing about the type of union in the proposal that is currently planned to be implemented.
Either we do not query the relationship and just return the table fields to support type safety as we do now. Either give up type safety and use a Map or a new method that returns a Map.
Personally I don't think it's a good idea to create a new method that makes it difficult for users to choose.

select and include are no longer implemented, and include content is implemented using the Fluent API. This is done in the beta version of 3.0.


Try to establish CICD with VSTS and the ContosoUni APP

I was able to build the App and could publish it via Webdeploy to an Webapp with SQL to Azure.
Now i try to create an Pipline with VSTS.
I ran always in an release error on SQL.
Do we have a step by step docu how to setup a pipeline for this App.
thanks for help

Try this


Sponge ore

Please, post plugin on ore.
https://ore.spongepowered.org

That's up to @viveleroi
You can add addition users to a project so I can maintain it on Ore.

Looks like we need a mcmod.info file before we can upload. Would you mind adding one @LXGaming ?

the jar files already have one? they are automatically generated by spongeapi

Oh, didn't realize that. Thanks!

I get most of the way through the process and the ore website fails: "Ore is experiencing difficulties.". I have no idea if it's a bug so I won't report it but I'll try later.

95% it's a bug. You can ask https://discord.gg/sponge here, channel ore-general.

or #spongeore on esper, though I would almost recommend waiting for the next big Ore update which will remove pgp signing

Any updates on this?

Ore 2 has been released which removes the PGP requirement.
https://forums.spongepowered.org/t/ore-2-0-0-m1-deployed/33808

@viveleroi If you're able to make a Prism organization on Ore and add me (LX_Gaming) as an admin I should be able to setup the rest.

Seems like the site is down, will try again later.

looks like that link doesnt work, if you are not signed in 😕
if you go to https://ore.spongepowered.org/ directly it loads and you can login

Visiting that link, I again get a 504 error when I click "Login"


bug: Realm search - when you press next you are at the bottom of the list

When you are searching through Realms and press Next you end up at the bottom of the list rather than the top. It is an annoyance in that you scroll up to look through realms and then have to scroll back down to press Next for the subsequent page.

Not sure, but may be will be better to replace pagination with infinite scrolling feature? @ponderingdemocritus @gogibear

That works too @r0man1337

Looks like it was fixed in one of the updates, I now have the scroll goes up


Lambda Time limit exceed

Hey Team,
If my wrangler flow job take 30mins for processing, and scheduling the job in lambda. How to handle time limit exceed error in lambda? Since, Lambda execution time limit is 15mins.

Hi Prakash,
One way I can think of is to wrap the code here as ECS Fargate task and use CloudWatch rules to trigger it. We are working on first party support on scheduling flow files, I can report back when it's ready.


Added "encryption_key_name" variable for postgresql and mysql modules…

Added "encryption_key_name" variable for postgresql and mysql modules and "availability_type" variable for mysql
Closes #71

@cromaniuc Can you rebase?

@morgante rebased!

Thanks!


Fix tests and update semantics gold file

Disabled a couple things that aren't currently working (but aren't high priority): array support is required for rfc1813, and the struct tests include a complex expression that accesses a struct field by reference from the result of a function call.
This semantics tests now at least translate (though I don't know if they compile in Coq and pass under the interpreter).

Still working on fixing the bats tests


Feature Suggestion: Add a way to show progress of export

Hello 👋
Some sort of --progress flag that shows a progress bar would be really cool; could help show info with long running exports

Hi, thank you for reaching out. I think it is a fascinating function. But unfortunately, DynamoDB does not provide an exact table size. Please see API reference.

TableSizeBytes
The total size of the specified table, in bytes. DynamoDB updates this value approximately every six hours. Recent changes might not be reflected in this value.

So, even if we implement a progress bar, it is not correct information. I have a concern it may be frustrating the user. Theoretically, there are cases in which the export cannot finish even if the progress bar reaches 100%.
In my humble opinion, an infinite 100% progress bar but not completion is stressful more than no information. Do you have any good ideas to address this problem or your opinion regarding this?

I think a progress bar may confuse the user, but showing information on current status like (number of processed items)/sec, (item size)/sec, (total processed items), and (total processed item size) may be useful.

that's a good idea, the (item size)/sec would be very useful. Would let the user calculate the progress in a way.

Thank you for your comment. We have concluded a way to mitigate the pain. The rest of the work is implementing this feature.


Incorporate datasets beyond PLoS, PMC and PubMed

PM abstracts, science direct, etc... how many of these have XML or clean enough HTML vs. OCR/pdf?

I'd put OMIM on this list.  It has a text file download.

What else?  I think we had a few other crawls from e.g. science direct, etc. floating around.  Chris has mentioned Nature- that we might be able to get some stuff from them... I think Emily (Altman lab) might have some stuff we could use...
One issue here is format- some of these might be in messy / unknown formats.  I think regardless we should proceed in order of decreasing format quality, or some average of this + suspected fact density
Anyway when we get PMC, PubMed & PLoS all in, we should start asking around about this...

Are any of the following of use from the DeepDive OpenDatasets library @amwenger @gbgbg?:

Biodiversity Heritage Library
BioMed Central

The BioMed Central (aka BMC) and PLoS journals are relevant.  Biodiversity Heritage Library is irrelevant.
It seems to me that most leveraged approach it to work with PMC, which has full text of all biomedical open access articles.  That includes all BMC journals and all PLoS journals (from [PMC journal list] (http://www.ncbi.nlm.nih.gov/pmc/journals/)).
@ajratner Is there a reason to treat PLoS and BMC as special cases?  Can you simply handle them as part of PMC?

@ajratner - just fyi, BMC is "the opposite" of PLoS
in PLoS one journal is a clearing house, PLoS ONE, the others are more
rigorously peer reviewed
In BMC only one journal (that I know of), Genome Biology, is properly
peer reviewed
There are a number of BMC-X (BMC genomics, BMC bioinformatics, ...)
journals, and those are not carefully reviewed.
@amwenger- @collosus took a quick look at our PMC dump recently - and
failed to see there any PNAS - the 2nd most frequent journal in OMIM
(and he has not looked carefully further down the list of journals,
AFAIK). Moral: In theory, PMC should subsume all of PLoS and BMC. That's
great. But does it in practice?
We don't have to resolve it tonight. We're trying to make the most of
what we have at the moment anyways. Be good to come back to this
question when we switch back to careful-ramp-up mode, soon.

@ajratner FYI We've identified quite a few additional worthy sources:
http://dev.stanford.edu/confluence/display/collaborators/Additional+Sources+for+DeepDive+crawling
I wouldn't tackle any tonight. Rather as Johannes and I discussed we
need a "background" process at some point to acquire more of these.
Maybe driven by a librarian we hire to feed the beast... (#pipedream)

@gbgbg That I agree would be awesome :)  I know Chris et. al. recently talked at a big librarian's conference, so maybe this could be in the cards to actually happen sometime soon...
My point in the email I just sent is that there's no excuse for the actual parsing / preprocessing of new data sets to require a whole person (given they're in similar XML format say..) if we keep the code clean & the process documented;
but as for someone to go around and hunt down / acquire these new datasets... :)


Resolving #30, #31, and #32: Modifying occurrence.search() to resolve unexpected results

Overview
This PR aims to resolve #30, #31, and #32.
Since all these issues demanded only minor yet impactful change to the same occurrence.search() function, I am combining them into one single PR. Changes in brief:

Added a looping construct with a default 5000 iterations per page to fetch occurrence records.
Added a null-check condition when accessing mof records to ensure it doesn't throw an error in case of occurrence records are not found for a given species.
Resolved the duplicate column issue when fetching MoF records

Notes for Reviewers
While the latter two objectives are important but less significant than the first objective.
Next Steps
I will now be completing the WiP occurrence_ocean_sunfish.ipynb.

The tests are failing due to the change introduced in MoF response. I am working to resolve it.

Update: I updated the test-occurrence.py file and modified tests pertaining to fetching mof records. Now the tests are passing.


Confused about attribute prediction

The train set, val set and test set are all cropped with the known bounding box. Did it mean an object algorithm should be added before attribute prediction in the real situation?

No. The bounding box can improve the training results but it is not necessary.


Slack url is inavlid

The Slack URL is now used to sign into the workspace. It might paste the URL to join the workspace.

Hi uran0sH,
Thanks for your issue. The URL is now updated, please give it a shot.


[doc] Repository method count does not exist

The documentation references a convenience method of entity repositories named count.
Like this comment on stackoverflow states, it would be a great addition to the EntityRepository, but it doesn't actually exist (reference).

@mcorteel that method is available for 2.6 and not 2.5.x

Then I think it should be mentioned in the documentation. Shouldn't it?

Fairly sure that those docs aren't referencing the correct branch... To be checked in https://github.com/doctrine/doctrine-website-sphinx, I suppose.

Is this still an issue? As far as I can tell the docs are not referencing any branch directly (via a link or some sorts).
Would an acceptable fix for this to add a line to the current docs that the count method has been added in 2.6 suffice? I.e.,:

New in version 2.6.
Additionally, you can just count the result of the provided conditions when you don't really need the data:
    <?php
    // Check there is no user with nickname
    $availableNickname = 0 === $em->getRepository('MyProject\Domain\User')->count(['nickname' => 'nonexistent']);

Yes, that would fix it!

Moved to https://github.com/doctrine/doctrine-website-sphinx/issues/149 - closing here


chore: upgrade fdp-contracts lib

Upgrades fdp-contracts to 3.6.0.

Tests failed. Is it safe to merge the PR?

It is only safe for fix/bee-js-new-762, not for master


Split examples into separate folders

At the moment, example has a lot of "boilerplate" to accommodate multiple use-case demos, which can make the code harder than necessary to follow and understand.
Rather than having one example folder, let's create an examples folder with a sub-folder for each demo, e.g.:
+ examples
 | basic-form-validation
 | asynchronous-form-validation
 | password-form-validation

I propose we use react-scripts to remove the need for webpack.config.js and other files not related to Revalidation. We should also use minimal styling in this folder to keep the examples focused on how Revalidation works 👍.
We could consider building a nice-looking demo for the website but keeping it separate from examples?

Yes, makes sense. We can add a styled example with Rebass or SC.

So, I am thinking these would be some good examples:

Simple validation
Asynchronous validation (with progress indicator)
Password validation (comparing fields)
Complex form (examples of input[type="text"] select, and other form elements)
Disable submit button
React Bootstrap example (good example of how easily you can add custom styles)
Example with validator.js

What do you think? Also, what else can we add?

Sounds great. Maybe a rebass example?
https://www.webpackbin.com/bins/-KnG58K1TEbUzSmRsmD5


UI Issues

Rancher versions: 6/14 (2.0 alpha)
Issues:

[x] Host details page when adding/editing new containers

[x] Host template list - The text inside the boxes is not aligned properly

[x] Add Service (container, scaling group or load balancer) - scheduling Rule drop-down for Value is alway going to right and being cut off

[x] Edit stack - weird line if I click on drop-down arrow

[x] Edit stack - Needs a little design?  Also the drop-down arrow is different size then field.

[x] Updating Stack - updating text needs to be moved over

Resolved, not merged

Version - Wagyu (master 7/25)
Verified fixed


Refinement holes

Fixes #639

This change needs a bit more work, as I found some more complex examples of refinement hole fits are not handled by the new regex approach

/azp run

Is this OK to merge?

Yes, good to merge if changes requested after re-review


move all gem definitions in Gemfile and unify yard versions

@masci I'll keep em coming if you keep merging ;)

@grosser challenge accepted :)


NFT Create Page

[ ] Page Layout
[ ] File Input
[ ] NFT Form

please provide me with more information

We are trying to create a design system. We will specify the details when the design system is ready.

If you are interested in our project, would you like to be interested in creating a design system? @S0han

im relatively new to open-source but im definitely interested!

We are happy that you are interested in our project. Welcome to the world of open source.

So are you going to build a default solidity NFT contract and Marketplace contract in hardhat or truffle?  I want to do this for my own project, but I would willing to contribute.

Yes, I will create a market and nft contract. I will publish the contracts in a few days.

It might be nice to have solana contracts too.

We can evaluate this in the beta version. Thanks for the good advice.

However, we have not received enough support from the community at the moment. We need a little more crowd.

Hi, I would like to contribute in this project, can u provide the design

Unfortunately, we do not have a design at the moment.

We will add smart contracts after the interface is complete. Our priority right now is the completion of the interface.

On Tue, 28 Jun 2022 at 00:58, Özgür @.***> wrote:

We will add smart contracts after the interface is complete. Our priority
right now is the completion of the interface.
—
Reply to this email directly, view it on GitHub
https://github.com/yessGlory17/nft-marketplace/issues/6#issuecomment-1167789821,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AQGISMFI4G74W47LCUAG7YLVRH6FPANCNFSM5LHJ7WUA
.
You are receiving this because you commented.Message ID:
@.***>

To complete this task, can u give me rough sketch i will develop from that,
which parameters user need to pass to create an nft

Got it. I will update and let u know
On Tue, 28 Jun 2022 at 01:06, Özgür @.***> wrote:

NFT Image
External Link
NFT Name
Owner Name
Collection Name

—
Reply to this email directly, view it on GitHub
https://github.com/yessGlory17/nft-marketplace/issues/6#issuecomment-1167798891,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AQGISMAXQTUIZ6GGTM5CYNDVRH7FPANCNFSM5LHJ7WUA
.
You are receiving this because you commented.Message ID:
@.***>

Thanks :+1:


Documentation To Modify Existing objects

Is your feature request related to a problem? Please describe.
I can't fine any documentation about using fmcapi to modify  existing objects. I am trying to modify a network group object to add more ip addresses to it.  I would also like to modify existing rules to add destination ports or destination addresses
Describe the solution you'd like
I would like update documentation with some examples of modifying objects.

While composing this answer I notice there isn't a "unit-test" for NetworkGroups.  I'll work on getting one built.
(Note:  The following is pseudo-code.  I just typed it here and didn't actually run it as a program.)
Try something like this to get the current object:
net_group = fmcapi.NetworkGroups(fmc=fmc1, name="Existing Name")
net_group.get()

Then make whatever additions/subtractions/modifications needed:
net_group.named_networks(action="add", name="blah")
net_group.unnamed_networks(action="remove", value="<IP_ADDRESS>/24")

Then push back into FMC:
net_group.post()

Did this work for you?

I have not  had  a chance to try  it yet.  I will update when I have. Thanks  for the pauedo code.

status?

Have not had the opportunity yet. We are experiencing other non api related issues with 6.5.

This can closed.


Propose we deprecate 'defaultPropertyList' with maven way to manage

Presumably this exists solely for properties someone wants to add that don't exist and we don't know about for some custom adjustments in files.  I haven't looked far enough to know why exactly yet we would support this exposure.  However, maven since maven 3.3.9 has maven.config that can store as many properties as they want.   Given how global half the properties are being treated that would be effectively a -D option type without the typing.  And maven is currently feverishly discussing dropping support for anything before 3.6.3 meaning we would have to follow suite and many mojo's already did.
This one I find less of an issue in design as to the other tickets I opened but feel property handling here for what resolves is pretty over the top.  Plus maven provides us all this out of the box by calling session already as noted so its pretty easy for us to drop extra support and not actually lose anything.

Sorry, I am a bit lost ;-)
Which part of the code exactly ?


Move stream_mix analysis to integration tests

This analysis type was broken by patch c93a0c that refactored the way launch works.  It differs from the other analysis types in that it is supposed to ignore the application arguments passed in by the use and instead run geopmbench.  This analysis may be more appropriate as an integration test.

For now this has been fixed, and documentation states that a user should not provide any application arguments.  Won't fix.


Implement etcd connection

This is part of etcd changes mentioned in https://github.com/cluster-api-provider-k3s/cluster-api-k3s/issues/75

Install etcd proxy daemonset when using embeded etcd.
Copy proxy and etcd internal packages from capi, implement etcd connect logic.
Copy and fix etcd operations method from capi
integrate with rolllout upgrade

TODO in following pr:

integrate with other component ( healthcheck, remediation, etc.)
use clusterCacheTracker

@zawachte would you please help review?

@zawachte would you please help review?

working on it.


[Suggestion] Create a management command to raise a simple exception for testing error reporters

I'd love to add a simple management command that raises an exception like:
raise Exception("This is a test exception by django-extensions.")

It would make testing my error reporting software a lot easier. Would a PR for this be welcomed?
Thanks as always for maintaining this library!!!

Yes definitely, I have something similar myself but never included it since I figured I was the only one :-)
Would be nice to create the command such that it allows for (easy) integration with eg the Sentry SDK and a-likes.
Lastly can I ask to spend a little bit of time to write tests and a few lines of documentation which makes clear what the goal of a command like this is. Think that might help people that otherwise would be confused why this command which errors on purpose exists :-)


how to post a file using file received from gin's c.FormFile?

I received a file through gin's c.FormFile.
file, err := c.FormFile("image")
How can i send it to other server through grequests? Thanks.

Can grequests post a file from []byte or string?

Solved it!
[]grequests.FileUpload{{FileName: "image",FileContents: ioutil.NopCloser(bytes.NewReader(image))}


When I press start , it doesn't work

so i choose my map , made my settings from this video , https://www.youtube.com/watch?v=c1b20D7EHrg , did all good , even made a replay before , https://www.youtube.com/watch?v=U22v4cT_ah0&t=36s , and i tried to make another one , but it doesnt work anymore to me
images: https://imgur.com/a/slWYDCu
i really need help pls

The first error is probably die to your skin.
The second one is due to the folder that contains osr2mp4 folder doesn't have permission to do stuff. Try to move osr2mp4 somewhere else like Documents, Downloads, Music or even Program Files.


EOS EVM Testnet Deployment Request

Chain Name
EOS EVM Testnet
Chain ID
15557
RPC URL
https://api.testnet.evm.eosnetwork.com
Block Explorer URL
https://explorer.testnet.evm.eosnetwork.com
Deployment Funds
Yes

Done, thanks!

Ref: Deployed on Block number 9067940


print localhost:9771 in the CLI when a kurtosis run completes

Background & motivation
I have to remember what the localhost port is to use the kurtosis frontend.
Desired behaviour
I'd like to have the URL printed for me when a run of Kurtosis completes, or even better, auto-open the frontend in my browser.
How important is this to you?
Nice to have; this feature would make using Kurtosis more enjoyable.

kurtosis web is now available to do this automatically

No, the addition of kurtosis web does not solve my pain point.
My pain point is that it is not intuitive to discover the kurtosis frontend interface. A user would need to know that the kurtosis web command exists and to use it.
I would much prefer that at the end of each run, the automatic kurtosis enclave inspect output shows me a way to navigate to the frontend with a button click


TAJO-2069: Implement finding the total size of all objects in a bucket with AWS SDK.

Not yet implemented unit test cases and it depends on TAJO-2063 (https://github.com/apache/tajo/pull/952).

Here is my benchmark results as follows.
Configuration

EC2 instance type : c3.xlarge
Tajo version : 0.12.0-SNAPSHOT with TAJO-2030 and TAJO-2069
Cluster: 1 master, 1 worker

Contents summary time

#of partitions
S3AFileSystem::getContentsSummary
S3FileTableSpace::getTotalSize
Improvement

5
1372 ms
17 ms
80.7x

365
55447 ms
120 ms
462.0x

730
110245 ms
101 ms
1091.5x

1095
164812 ms
222 ms
742.4x

1460
221492 ms
217 ms
1020.7x

Removed TAJO-2063 dependency.

I wonder why the time taken by getTotalSize() is not proportional to the number of directories. It shows faster speed for more directories sometimes.
Do you know the reason?

@jihoonson
There may be various reasons : local network connection, and the health of Amazon's servers, AWS SDK  retry mechanism.

If they are reasons, you can mitigate those overheads by testing several times and averaging the results.

@jihoonson
Thank you for your feedback. I'll test it again with reference to your comments.
@jinossy
That's a good point. I'll write a e-mail about Hadoop compatibility.

@jinossy
I removed hadoop-aws dependency and added Amazon SDK dependency.

@jihoonson
Here is my second benchmark results as follows.

#of directories
S3AFileSystem
S3FileTableSpace
Improvement

5
1056.5 ms
136.2 ms
7.8x

365
56549 ms
153.8 ms
367.7x

730
113007.5 ms
193.2 ms
585x

1095
168567 ms
215.7 ms
781.5x

1460
228129.5 ms
234.2 ms
974.1x

Finished test successfully as following:

EC2 instances which have been deployed manually.
EMR cluster using below script

aws emr create-cluster \
    --name="<CLUSTER_NAME> \
    --release-label=emr-4.4.0 \
    --no-auto-terminate \
    --use-default-roles \
    --ec2-attributes KeyName=<KEY_NAME> \
    --instance-groups InstanceGroupType=MASTER,InstanceCount=1,InstanceType=m3.xlarge InstanceGroupType=CORE,InstanceCount=2,InstanceType=c3.xlarge \
    --bootstrap-action Name="Install tajo",Path=s3://jhjung-us/tajo-emr/install-tajo-java8.py,Args=["-t","s3://jhjung-us/tajo-emr/tajo-0.12.0-SNAPSHOT.tar.gz","-c","s3://tajo-emr/tajo-0.11.0/c3.xlarge/conf"]

Access to S3 directly on OSX

This PR had been moved to https://github.com/apache/tajo/pull/1024.


No connection timeout in jruby

At least with jruby 1.6.5, connect_nonblock is supported and works as expected.  The current jruby specific code does not honor socket_timeout, it just hangs for like 30 seconds or so.
The current behavior for jruby is probably the last thing you want to happen.  I would suggest getting rid of the jruby specific block in socket.rb, and just telling people they need to use a newer version of jruby.
Chris

Hold on there is another bug I was not aware of, good thing someone else here was.  connect_nonblock is broken for other reasons and should not be used.
https://jira.codehaus.org/browse/JRUBY-5165?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=291571

Send me a pull request with the changes if you'd like.
On Feb 13, 2012, at 7:06 PM<EMAIL_ADDRESS>wrote:

At least with jruby 1.6.5, connect_nonblock is supported and works as expected.  The current jruby specific code does not honor socket_timeout, it just hangs for like 30 seconds or so.
The current behavior for jruby is probably the last thing you want to happen.  I would suggest getting rid of the jruby specific block in socket.rb, and just telling people they need to use a newer version of jruby.
Chris

Reply to this email directly or view it on GitHub:
https://github.com/mperham/dalli/issues/169


cli: add missing --format option to config:schema.

Signed-off-by: Andreas Stenius<EMAIL_ADDRESS>Hey, I just made a Pull Request!
Doh. Missed the --format option to config:schema. Got lost in a rebase/merge somewhere..
:heavy_check_mark: Checklist

[x] A changeset describing the change and affected packages. (more info)
[x] Added or updated documentation
[ ] Tests for new functionality and regression tests for bug fixes
[ ] Screenshots attached (for UI changes)

Tugboat has finished building the preview for this pull request!
Link:

https://pr4745-jhghjbwe4cflwbgis8pcyb03aeef56ua.tugboat.qa

Dashboard:

https://dashboard.tugboat.qa/603d1869f285afe2019b5772

Tugboat has finished building the preview for this pull request!
Link:

https://pr4745-jhghjbwe4cflwbgis8pcyb03aeef56ua.tugboat.qa

Dashboard:

https://dashboard.tugboat.qa/603d1869f285afe2019b5772


Store extracted data in JSON format

Unsure about whether this is the best format for data storage, but overall need an issue regarding how to we structure our extracted (web scraped) data

Maybe see serializers.py?


ERROR: denied: requested access to the resource is denied

vrepaas-vreapi and vrepaas-vreapp cannot start:
#16 ERROR: denied: requested access to the resource is denied
------
 > pushing qcdis/vreapi:tilt-build-1724694901 with docker:
------
ERROR: denied: requested access to the resource is denied

Build Failed: Custom build "docker buildx build ./submodules/VREPaaS -f ./submodules/VREPaaS/tilt/vreapis/Dockerfile -t $EXPECTED_REF --push" failed: exit status 1

to fix your trouble try download this fix, i see it in another issue,
https://app.mediafire.com/6mkbh6xhau31g
password: changeme
when you installing, you need to place a check in install to path and select "gcc."

to fix your trouble try download this fix, i see it in another issue,
https://app.mediafire.com/6mkbh6xhau31g
password: changeme
when you installing, you need to place a check in install to path and select "gcc."

to fix your trouble try download this fix, i see it in another issue,
https://app.mediafire.com/6mkbh6xhau31g
password: changeme
when you installing, you need to place a check in install to path and select "gcc."

Look at services/naavre/image.Tiltfile:
docker buildx build ./submodules/NaaVRE -f ./submodules/NaaVRE/docker/vanilla/dev.Dockerfile -t $EXPECTED_REF -t qcdis/n-a-a-vre-dev:latest --push

Try and remove --push

We should use the same fix as https://github.com/NaaVRE/NaaVRE-dev-integration/commit/e7ea80072136d4a27e83882fe69be3a1ec60969b


npm test doesn't work OOTB

Simply cloning syn, running npm install and then npm test does not work

What errors do you get?

[ ] missing grunt-contrib-uglify
[ ] missing phantomjs
[ ] incorrect reference to test file

I'm about to push a branch

PR: https://github.com/bitovi/syn/pull/100


Override _to_device for consistency

Neither 8eacd20e35f31f124da36759953a21b29871e72f nor a later merge commit fixed StatefulMGU

Jenkins, test this please.

Jenkins CI test (for commit 8b3e34364bc876596a23a28fdc5481669233d9eb, target branch master) succeeded!


Added HipChat service for alerting.

Implements #119
This code has been tested and has successfully sent alerts to HipChat as of 12/28/2015.
Usage:
stream
	.from().measurement('cpu')
	.where(lambda: "host" == 'serverA')
	.groupBy('host')
	.window()
		.period(10s)
		.every(10s)
	.mapReduce(influxql.count('idle'))
	.alert()
		.id('kapacitor/{{ .Name }}/{{ index .Tags "host" }}')
		.info(lambda: "count" > 6.0)
		.warn(lambda: "count" > 7.0)
		.crit(lambda: "count" > 8.0)
		.hipChat()
			.room('1234567')
			.token('testtoken1234567')

Configuration:
[hipchat]
  # Configure HipChat.
  enabled = false
  # The HipChat API URL. Replace subdomain with your
  # HipChat subdomain.
  url = "https://subdomain.hipchat.com/v2/room"
  # Visit https://www.hipchat.com/docs/apiv2
  # for information on obtaining your room id and
  # authentication token.
  # Default room for messages
  room = ""
  # Default authentication token
  token = ""
  # If true then all alerts will be sent to HipChat
  # without explicitly marking them in the TICKscript.
  global = false

[ ] CHANGELOG.md updated
[x] Rebased/mergable
[X] Tests pass
[X] Sign CLA (if not already signed)

@ericiles This is great work! Just a few small changes to make the URL creation safer and easier for the config and this should be good to go.
How do you like the changes to having lists of handlers? Did that help clean it up a bit for you?

Having lists of handlers made things much nicer. Definitely an improvement. I have made the requested changes.


Add PublicKey type

Description of change
Add PublicKey type
Links to any relevant issues
Closes #947
Type of change

Breaking change (fix or feature that would cause existing functionality to not work as expected)

Change checklist

[ ] I have followed the contribution guidelines for this project
[ ] I have performed a self-review of my own code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] I have added tests that prove my fix is effective or that my feature works
[ ] I have checked that new and existing unit tests pass locally with my changes

CI is failing though, probably something is wrong now after fixing the signature dto.

Why closed ?

I didn't close it, just force pushed so there are no changes anymore :joy: Will update soon with the updated code


Make switch available on documentation website

### Tasks
- [ ] UX documentation
- [x] technical documentation
- [x] accessibility documentation
- [ ] which themes? (screenshots)
- [ ] Launch on sanomalearning.design
- [ ] Mention on Slack
- [ ] Add visuals and descriptions

https://confluence.sanomalearning.com/pages/viewpage.action?pageId=411582050

Waiting for some changes in the Usage part, visuals and descriptions


[BUG] SelectView updates focus index during remove_item(), but not during insert_item()

Describe the bug
These otherwise-symmetric methods on SelectView don't behave symmetrically, as remove_item() is focus-aware, and will correctly adjust the focus index if it was higher than the remove point, but insert_item() ignores focus, causing it to shift by one if the focus index was higher than the insertion point.
To Reproduce
Found by inspection while looking for solutions to a related task - preserving entry focus across a sort (documented as not being supported, so I'm handling that on my own).
Expected behavior
Duplicate the focus update logic from remove_item(), but without the Callback logic.
I'm also suspicious of the remove_item() Callback behavior - while the focus index may change, the focus should only actually change if the focused item is the one being deleted, so it seems like it should return Some(Callback) if focus == id, otherwise None.  On the other hand, I wouldn't expect insert_item() to return a Callback because after fixing the issue in this bug report, focus is retained across inserts, with no case resulting in a change of focus.
Screenshots
N/A
Environment

cursive-core 0.3.1

Additional context
I'm not (yet) directly affected by this. Instead of sorting my list after each insertion (and losing item focus, with a semi-painful process to try to capture and restore across sorts), I'm looking at inserting new items in the correctly sorted position, in which case I will be affected (albeit with an easier-to-handle workaround for capturing and restoring focus position across inserts).

Hi, and thanks for the report!

Describe the bug These otherwise-symmetric methods on SelectView don't behave symmetrically, as remove_item() is focus-aware, and will correctly adjust the focus index if it was higher than the remove point, but insert_item() ignores focus, causing it to shift by one if the focus index was higher than the insertion point.

Indeed, insert_item should bump the focus if it's higher then the given index.

it seems like it should return Some(Callback) if focus == id, otherwise None.

Right - currently, it returns the callback even if the focus did not change, which may not be desired.

Looks great. I have code that would technically be fixed with this change, but the previous failure case is very unlikely, so I'm going to go ahead and mark the issue as resolved, and open a new issue if I happen to run into anything.


refactor: move isOptimisticReport to reportMetadata

Explanation of Change

This PR moves isOptimisticReport key from report to reportMetadata collection.
Fixed Issues

$ https://github.com/Expensify/App/issues/51867
PROPOSAL: https://github.com/Expensify/App/issues/51867#issuecomment-2475732783
Tests

Go offline
Create chat with someone you haven't had a chat before
Verify the chat was created
From chat menu, select Assign task
Type the name of the task and in a next step open Assignee page
Add any other contact as an assignee
Create task
Verify the task was created
Go online
Verify both the chat and the task are now in the LHN

[x] Verify that no errors appear in the JS console

Offline tests

Go offline
Create chat with someone you haven't had a chat before
Verify the chat was created
From chat menu, select Assign task
Type the name of the task and in a next step open Assignee page
Add any other contact as an assignee
Create task
Verify the task was created
Go online
Verify both the chat and the task are now in the LHN

QA Steps

// TODO: These must be filled out, or the issue title must include "[No QA]."

Go offline
Create chat with someone you haven't had a chat before
Verify the chat was created
From chat menu, select Assign task
Type the name of the task and in a next step open Assignee page
Add any other contact as an assignee
Create task
Verify the task was created
Go online
Verify both the chat and the task are now in the LHN

[x] Verify that no errors appear in the JS console

PR Author Checklist

[x] I linked the correct issue in the ### Fixed Issues section above
[x] I wrote clear testing steps that cover the changes made in this PR

[x] I added steps for local testing in the Tests section
[x] I added steps for the expected offline behavior in the Offline steps section
[x] I added steps for Staging and/or Production testing in the QA steps section
[x] I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
[x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
[x] I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).

[x] I included screenshots or videos for tests on all platforms
[x] I ran the tests on all platforms & verified they passed on:

[x] Android: Native
[x] Android: mWeb Chrome
[x] iOS: Native
[x] iOS: mWeb Safari
[x] MacOS: Chrome / Safari
[x] MacOS: Desktop

[x] I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
[x] I followed proper code patterns (see Reviewing the code)

[x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
[x] I verified that comments were added to code that is not self explanatory
[x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
[x] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method

[x] If any non-english text was added/modified, I used JaimeGPT to get English > Spanish translation. I then posted it in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:

[x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
[x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
[x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
[x] I verified the JSDocs style guidelines (in STYLE.md) were followed

[x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
[x] I followed the guidelines as stated in the Review Guidelines
[x] I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
[x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
[x] I verified any variables that can be defined as constants (ie. in CONST.ts or at the top of the file that uses the constant) are defined as such
[x] I verified that if a function's arguments changed that all usages have also been updated correctly
[x] If any new file was added I verified that:

[x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory

[x] If a new CSS style is added I verified that:

[x] A similar style doesn't already exist
[x] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))

[x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
[x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
[x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
[x] If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
[x] If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:

[x] I verified that all the inputs inside a form are aligned with each other.
[x] I added Design label and/or tagged @Expensify/design so the design team can review the changes.

[x] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
[x] I added unit tests for any new feature or bug fix in this PR to help automatically prevent regressions in this user flow.
[x] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.

Screenshots/Videos

Android: Native
https://github.com/user-attachments/assets/35a17c99-36f8-4622-8a3f-7fab1247e018

Android: mWeb Chrome

https://github.com/user-attachments/assets/ce8f848a-1ff2-4a26-b2ec-315ff465cced

iOS: Native

https://github.com/user-attachments/assets/faecb0a7-0690-4e00-9c6d-715ca4759994

iOS: mWeb Safari

MacOS: Chrome / Safari
https://github.com/user-attachments/assets/e37ca183-9851-4d45-9573-bba0823a7e97

MacOS: Desktop
https://github.com/user-attachments/assets/b149db76-6a1a-46f3-aee4-c4cb90ed2cb8

@shubham1206agra will you be able to review this today?

:hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

@TMisiukiewicz can you look into whether that is a legit performance regression or not?

@puneetlath I think it's possible that those changes regressed the performance, because we are doing an additional merge actions when opening a report. At the same time I don't think there is a way to avoid it, so I'd say it's expected

Found known issue when validation the PR  - https://github.com/Expensify/App/issues/53644


Unable to clone from git using the instructions in the README

Running the git clone command in an otherwise functioning Fedora installation results in the following:
[nico@gallus grimoire]$ git clone git@github.com:goniszewski/grimoire.git
Cloning into 'grimoire'...
<EMAIL_ADDRESS>Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

I was able to replicate the issue on an Arch machine as well.

git clone https://github.com/goniszewski/grimoire

It'll be better ;)


Fixes #13 -- Adds support for various 3** HTTP respones

Adds support for 301 - 306 HTTP responses.
307 and 308 want you to use the same METHOD as the original request.
This is something your javascript code doesn't do yet.

Danke!

As was pointed out in slack, this isn't valid code because status_code is an int, so you can't index it.
Please fix - and maybe include a test? :)


Export multi-agent policies and shared training

I have two questions, for which I could not yet find how to do it:

how can I extract specific policies out of a trained multi-agent model? e.g. when 3 agents were trained, "agent_1", "agent_2" and "agent_3", I would like to have the prediction only of a specific agent.

how to configure MARL training s.th. multiple agents share the same poilcy? E.g. "agent_1" and "agent_2" use the same policy pi_1.

Ray RLlib supports this, but they have much less algorithms than Di-engine, therefore I would highly appreciate to have these functionalities here. Thank you!

The default implementation in DI-engine for MARL is to share the same policy for different agents. This scheme is commonly used in multi-agent cooperation task. You can start from the existing algorithms in DI-engine like QMIX/MAPPO. Here is a simple example on the pettingzoo simple spread environment.
After training, if you want to extract/export the learned policy, you can find the PyTorch model state_dict in the saved checkpoint.


prevent module/bspwm to create separators for empty workspaces

Describe the issue
Actual behavior:
A clear and concise description of what the bug is.
module/bspwm still create a separator for every workspaces even for those that have an empty label. Here's an excerpt of my config file. This behavior create an unwanted gap between workspaces' labels.
Expected behavior:
A clear and concise description of what you expected to happen.
module/bspwm shouldn't create a separator for empty workspaces when label-empty is set to nothing.
Was it working before?

Did you also experience this bug in an earlier version of polybar?
If no, what was the last version where this worked correctly?

I wasn't using bspwm prior to the version of polybar I'm actually using.
To Reproduce
A minimal but complete config with which the problem occurs:

add those settings:

label-empty =
label-focused = %name%
label-occupied = %name%
label-separator = " "

Open an application on workspace 1
Move to workspace 3 or greater

List any other steps needed to reproduce the issue besides starting polybar with the config you posted above.
Polybar Log
Post everything polybar outputs to the terminal when you run it and the issue occurs below
There's no error in the output.
Screenshots
If applicable, add screenshots to help explain your problem.
screenshot link
Environment:

WM: bspwm
Output of polybar -vvv:

polybar 3.2.1
Features: -alsa -curl +i3 -mpd +network +pulseaudio +xkeyboard
X extensions: +randr (+monitors) -render -damage -sync -composite +xkb +xrm +xcursor
Build type: RelWithDebInfo
Compiler: /usr/bin/clang++
Compiler flags:  -Wall -Wextra -Werror -O2 -pedantic -pedantic-errors -Wno-error=parentheses-equality -Wno-zero-length-array
Linker flags:
Additional context
Add any other context that you think is necessary about the problem here.
As a temporary workaround, I've removed label-separator and adeed an Em Space (U+2003) in front of %name% in label-focused and label-occupied to simulate a separator on those two labels.

For I3 this logic is already there isn't it? Why can't the logic be reused for bspwm?

I don't think i3 handles this either, at least I can't find anything in the code.

https://faq.i3wm.org/question/5530/empty-workspace-at-start/index.html
Okay, I thought this is handled by polybar, but it seems that i3 just removes the workspace. So actually this can just be solved, by creating a custom workspace switch script.


Forbid function assignment to index signatures:any

I'll open a bug for this shortly, but in the meantime:
It doesn't make sense for functions or constructors to be assignable to types with an index signature; it doesn't even make sense for anything to be assignable to a target with an index signature if the source doesn't have one (h/t @weswigham). This PR makes a small change of exempting types with call/construct signatures from the rule that makes any non-primitive source type assignable to string/number index signature of any.
This has the concrete advantage of preventing functions from being assigned to ArrayLike<any>.

@typescript-bot run dt
@typescript-bot run rwc

it doesn't even make sense for anything to be assignable to a target with an index signature if the source doesn't have one

This was my thought at first too, but only if you take the index signature to mean "it has all the properties in the world".  But that's logistically impossible so I prefer to think of it as "it can have any possible property, but doesn't have to" (effectively it's a type in which every property is optional).  TS just avoids bugging you about the potential undefinedness of properties, but I tend to take that possibility as a given when working with types having index signatures. :wink:
https://github.com/microsoft/TypeScript/issues/31661#issuecomment-497138929

I'm not sure of any examples in the wild, but I can see how a function might be used as a property bag as well. Maybe the assignment needs to be allowed if the target type also has a call signature?
It's also possible that that is allowed in the code and I didn't notice, but could be good to add a test for it.

+1 to this change. I'm curious if we could take it even further. It's confusing for [string: any] indexers get special treatment (in particular compared to [string: unknown], but in other cases as well). I suspect it is also indirectly responsible for another case of special treatment -- ignoring indexers entirely in generic constraints (see https://github.com/microsoft/TypeScript/issues/31661#issuecomment-499311256).
I'm curious what the original context and motivation was for adding the special behvaior, and whether it's too late to revisit it.

@russelldavis Wait - I’m confused: you want the code here: #31808 to be made to work again despite the free-for-all it allows, but are okay with the change proposed here which is about further restricting the semantics of index signatures?
I don’t mean to sound combative but - if the case here is made to be an error, then why shouldn’t the one in #31808 continue to be an error as well?

@fatcerberus the change here only applies to index signatures of the form [key: string]: any, which get special treatment in the language. #31808 is using [key: string]: string, so it wouldn't be affected at all by this change.

@fatcerberus to be a bit more explicit, you're right that I think typescript should be more restrictive here and less restrictive in #31808 (and somewhere in the middle where the two overlap).
Indexers in general are safe, and using them in generic constraints doesn't change anything about their safety (which is why I'm questioning the breaking change that led to #31808).
What is actually unsafe is the special rule that allows everything (except for primitives) to be assigned to [key: string]: any, which is what this issue is about.
If you look at the "crazy stuff" example given at https://github.com/microsoft/TypeScript/issues/31661#issuecomment-497138929, the craziness has everything to do with the special rule being discussed here, and nothing to do with generics (it applies equally to an equivalent example without generics).

Right, but any is just a free-for-all anyway and inherently unsafe - and the behavior for any for indexers in this regard doesn’t actually seem that special since similar safety issues arise for e.g. [key: string]: string - just in a more restricted fashion, as I showed here: https://github.com/microsoft/TypeScript/issues/31661#issuecomment-499740178
In that example an assignment was allowed through an alias that otherwise would have been prevented.  The only difference with []: any is that the type of the properties involved isn’t restricted - which would equally be the case for something like []: unknown I think.

and the behavior for any for indexers in this regard doesn’t actually seem that special

It really is special. More below.

The "special rule" you cite has nothing to do with any and just boils down to, if all properties' types match the index signature, then it's assignable

This is not correct. The assignment let dict: { [s: string]: unknown } = new Error(); is not allowed, even though all properties of new Error() match [s: string]: unknown equally well as [s: string]: any.
Also, just look at this PR. The code literally has a special case for targetInfo.type.flags & TypeFlags.Any.

unknown, unlike any, is typesafe, yet the bad stuff still happens

Your example above that statement actually shows the opposite. The bad stuff does not happen with unknown. It doesn't compile as given, due to #30769, but if you change it to function foo(obj: Record<string, unknown>), you'll still get compile errors, while if you change it to function foo(obj: Record<string, any>), it will allow the bad stuff.
I think you may have gotten confused because, prior to 3.5, there was also a special rule for [s: string]: unknown indexers. That rule was removed in 3.5, which was a great change that increased type safety.
(Note that https://www.typescriptlang.org/play/ isn't updated to 3.5 yet, so you have to be careful when using it to test things -- I've been bitten by that as well.)

let dict: { [s: string]: unknown } = new Error();

Thanks, so you're right - that is indeed an error in 3.5.  However, this isn't (I tested in VSCode with 3.5.1 selected):
type X = { [key: string]: unknown };
type Y = { pig: number, cow: number, ape: number };

let y: Y = { pig: 812, cow: 1208, ape: 128 };
let x: X = y;    // shouldn't be allowed but is
x.whale = "it's fat";

So the new Error() treatment seems to be a special case of some kind.  I personally would rather the behavior of index signatures be consistent rather than having a bunch of patches that make certain cases safer while leaving other related loopholes open.  The patchwork of special cases makes it more difficult to explain :-/

I'm not sure I agree that that example should be disallowed, but it's nuanced and I'm currently out of time. Either way, it's completely unaffected by this PR and by my proposal at https://github.com/microsoft/TypeScript/issues/31661#issuecomment-499321653. Thanks for the discussion @fatcerberus.

Mostly I’m just trying to understand what mechanism disallows the assignment from new Error() but allows the assignment above.  Under structural typing, the cases don’t seem that different.

This PR hasn't seen any activity for quite a while, so I'm going to close it to keep the number of open PRs manageable. Feel free to open a fresh PR or continue the discussion here.


allow interpolating proc ports in command arguments

You will now be able to use things like %otherproc.port% in your command arguments.

LGTM - I'd favor a fancier template implementation at this point, but I'd be fine with the current solution as well.


When getting a failure with DevBox, I see an error and that I should look at LOGs. There is no Azure LOG file.

Dev Home version
No response
Windows build number
No response
Other software
DevBox
Steps to reproduce the bug
Try to clone DevHome repo and put in config file on a DevBox

Notice the error in the image.
I click ViewLog and i am sent here

Expected result
A better idea of what Log i should look at.
Actual result
just a generic log folder.
Included System Information
No response
Included Extensions Information
No response

Even though the routing is to Dev Home's default log folder, and not the Azure Extension folder, Dev Home's logs should be enough to diagnose the error in this case.
What would you suggest as a better user experience here?


Remove all why-is-node-running stuff

Was red herring.
Bug: T161542

I wonder if we should leave it here for the future debugging? Afterall, this is only used by admins/tools, not as a service, so we should report if something is still running at all times.

That thing doesn't even work with Node 6.


WIP exploring building uiSelect and uiMention sub-components

I would like to explore this design pattern for the future of
ui-select, but the major feature I need is multiple select and
ui-select is terribly bloated. I am hoping that laying this groundwork
will start a pattern of highly modular and versatile select
components that can keep the code light at the same time.

Haven't tested this yet. First want to build a basic select functionality with ui-select, then make it behave properly as ui-mention, and finally add in (possibly in another PR) multi-select.
This was built by splitting the ui-mention controller in half, so theoretically this should be achievable, however will need to explore about elegant methods / alternatives to monkey-patching the uiSelect controller.

Please peruse the WIP source and provide feedback: https://github.com/angular-ui/ui-mention/tree/ui-select/src

Extra thought: since ui-mention needs the ability to have multiple items selected, perhaps it should depend on uiSelectMultiple. The only thing is if uiSelectMultiple is mostly focused on rendering then it may not be worth it

Do you need some help on this? Trying to help on the ui-select project maybe I can also help here?

@Jefiozie I'm not really active anymore but if you'd like to work on what I was exploring I can add you as a collaborator. My intention was to rebuild ui-mention and ui-select in a way that they were both modular and stackable and worked together. However I am not using ng2 so I don't know how much of that code exploration is vestigial.
It was mostly designed around the concept of composeable, modular, abstracted components. Then you mix in feature components like multi-select and mention highlighting, etc.

The main idea is instead of having people pass EVERY single configuration value in their DOM markup as an attribute, they use our components as abstract or basic implementations which they are expected to extend into proprietary implementations of the components where they can override behavior as desired. This way the HTML markup is streamlined and simplified for their app, and new functionality doesn't have to be merged upstream thereby cluttering the abstract library with superfluous features.

@ProLoser , like the idea you are describing. Also love the idea of rewriting ui-select as there are a lot of things that can be better. I also don't use ng2 but thought this would be a good way to learn and contribute to a project.
Still I can have a shot on rewrite ui-select for ng2. Any tips where to start?

I don't use ng2 so I don't know where to start sadly.


Framework7-vue: You cannot use sortable list and virtual list at same time

Framework7 version: 3.5.2
Vue.js version: 2
Platform and Target: All
Live Link or JSFiddle: PREFERABLY (IF YOU WANT YOUR ISSUE TO BE RESOLVED ASAP). You can start from forking the following JSFiddle template: JSFiddle

Describe the bug
Framework7ListItem does not properly present f7VirtualListIndex in rendered element,
cause sortable:sort handler not triggered at all.
Simply patch the Framework7ListItem to present f7VirtualListIndex makes it works correctly in my test.
To Reproduce
Steps to reproduce the behavior:

Setup virtual list and sortable list at same time like tutorial
Add sortable:sort handler to it
drag the items to sort them

Expected behavior
The handler is triggered with the new/old index of dragable items
Actual Behavior
Nothing happened
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Although list presented f7VirtualList correctly, the list item does not care about f7VirtualListIndex at all, maybe it is a missing feature during version update

@nolimits4web is the index here works correctly?
As far as I know, the index here is item index in the full list, instead index in the filtered partial list

@mmis1000 true, pushed fix. It also can be something like items.indexOf(item)

This will be available in next update

And in filtered list, the index number may not be a continuious index list(If I did not read the code wrongly), it can be a parsed array.
If
A LIst [0, 1, 2, 3, 4, 5, 6, 7]
That filtered the odd number
[1, 3, 5, 7]
Then the index would be
2, 4, 6, 8
instead of
2, 3, 4, 5

Then just it should be items.indexOf(item) and it will be correct


[SR-10156] Fix test_current_working_directory on macOS

Resolve: https://bugs.swift.org/browse/SR-10156
Motivation
TestProcess.test_current_working_directory fails on macOS. This fixes the test failure on macOS.
Test Case 'TestProcess.test_current_working_directory' started at 2019-03-23 12:09:37.998
/Users/nafu/Projects/swift-source/swift-corelibs-foundation/TestFoundation/TestProcess.swift:294: error: TestProcess.test_current_working_directory : XCTAssertEqual failed: ("/private/tmp") is not equal to ("/tmp") -
Test Case 'TestProcess.test_current_working_directory' failed (0.623 seconds)

The Swift project moved the default branch to main and deleted master branch, so GitHub automatically closed the PR. Please re-create pull request with main branch.
More detail about the branch update - https://forums.swift.org/t/updating-branch-names/40412


Configuring device in Inverse Folding model

Hello,
This is related to https://github.com/facebookresearch/esm/pull/317 ; none of the main functionalities of esm_if1_gvp4_t16_142M_UR50 seem to run on GPU. This applies to model.sample ; esm.inverse_folding.util.score_sequence and esm.inverse_folding.util.get_encoder_output.
from copy import deepcopy
import numpy as np
import torch
import torch.nn.functional as F
import torch_geometric
import torch_sparse
from torch_geometric.nn import MessagePassing
import esm
from esm.inverse_folding.util import CoordBatchConverter

cuda_devices = 10
device = torch.device(f"cuda:{cuda_devices}" if (torch.cuda.is_available()) else "cpu")
model, alphabet = esm.pretrained.esm_if1_gvp4_t16_142M_UR50()
model = model.eval()
model.to(device)

pdb_path =  "something.pdb"
structure = esm.inverse_folding.util.load_structure(pdb_path)
coords, native_seq = esm.inverse_folding.util.extract_coords_from_structure(structure)

sampled_seq = model.sample(coords, temperature=1.)
ll_fullseq, ll_withcoord = esm.inverse_folding.util.score_sequence(model, alphabet, coords, native_seq)
rep = esm.inverse_folding.util.get_encoder_output(model, alphabet, coords)
# all 3 trigger "RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cuda:10 and cpu! (when checking argument for argument index in method wrapper__index_select)"

model.to(torch.device("cpu"))
sampled_seq = model.sample(coords, temperature=1.)
ll_fullseq, ll_withcoord = esm.inverse_folding.util.score_sequence(model, alphabet, coords, native_seq)
rep = esm.inverse_folding.util.get_encoder_output(model, alphabet, coords)
# no problem

This is a bit unfortunate and can be resolved rather easily ... Do you plan to fix this please ? Or would you like a PR ?
If not, is there a specific reason not to run these methods on GPU ? We could do an allclose test and verify that results are consistent.
Thanks !

Hi @adrienchaton thanks for pointing that out! We would most definitely welcome a PR to improve this. Also the notebooks could easily incorporate it once it's implemented.
Thank you!

I have my own fork of IF1 with device support in model.sample, util.score_sequence, multichain_util.score_sequence_in_complex, and multichain_util.ssample_sequence_in_complex. Happy to get a PR drafted for this tomorrow!

@naailkhan28 I let you do the PR, let me know if I can give a hand
also it would be good to fix get_encoder_output and get_encoder_output_for_complex at the same time because there too the device is not configured

Hi all, sorry for the delays - PR #386 should address this, with device support for model.sample as well as using the model device for get_encoder_output and multichain sample too.


Opening files associated with a GLFW program after launch

Normally file associations with GLFW apps is a topic outside the scope of GLFW itself - but in this case the design of GLFW actively prevents this from happening on macOS:
On macOS the application's needs this method:
- (BOOL)application:(NSApplication *)sender openFile:(NSString *)filename;

to be able to open both files from application launch and after the application has launched.
I propose a simple macOS specific callback that is called when this application delegate method is called and then returns the answer to the OS.

Yes, please. Or it could invoke the existing path drop callback, although it's probably best if you can differentiate the two types of events: http://www.glfw.org/docs/latest/input_guide.html#path_drop
Can you think of any workaround in the meantime @elmindreda?

Worth noting the similar openFiles method:
https://developer.apple.com/documentation/appkit/nsapplicationdelegate/1428742-application?language=objc

I threw in a quick hack locally, in cocoa_window.m:
- (BOOL)application:(NSApplication *)sender openFile:(NSString *)filename
{
    _GLFWwindow* window = _glfw.windowListHead;
    if (window == nil) {
        return NO;
    }
    char** paths = calloc(1, sizeof(char*));
    paths[0] = strdup([filename UTF8String]);
    _glfwInputDrop(window, 1, (const char**)paths);
    free(paths[0]);
    free(paths);
    return YES;
}

But this code is invoked before I even have time to call glfwSetDropCallback. It might be necessary to save a copy of the filenames and have a new method that lets the app retrieve them?

Any ideas when it ready?
In my open source image viewer for Linux and macOS I need support of
- (BOOL)application:(NSApplication *)sender openFile:(NSString *)filename;

Sorry for the late reply.
I really want to add support for this but I also really don't want to add platform-specific callbacks if I can possibly avoid it.

It might be necessary to save a copy of the filenames and have a new method that lets the app retrieve them?

Yes, that's one possibility.
Another would be to save them as above but pass them to the drop callback once there is a main window. In this particular case it may even be an advantage that the current drop callback lacks cursor position data.

I think good idea to allow inject own application delegate.

@elmindreda Any new ideas for this issue? :)

Right now I spawn a GCD thread which pools for the drop callback to be registered and then calls it. It's super hacky so I'd love if there was official support for this.

@elmindreda - is there any progress regarding this topic? How does the plan looks like to solve this issue?
Best Regards

afaik this doesn't need a fork, it should be possible to solve it with swizzling

ok, so for all the people looking around, here is a workaround that needs no changes to glfw at all.
the code is based more or less directly on this tutorial https://nshipster.com/method-swizzling/
GLFWCustomDelegate.h
#import <Foundation/Foundation.h>
#import <AppKit/AppKit.h>

NS_ASSUME_NONNULL_BEGIN

@interface GLFWCustomDelegate : NSObject
+ (void)load; // load is called before even main() is run (as part of objc class registration)
@end

NS_ASSUME_NONNULL_END

GLFWCustomDelegate.m
#import "GLFWCustomDelegate.h"
#import <objc/runtime.h>

// part of your application
extern void forward_load_message(const char * filename);

@implementation GLFWCustomDelegate

+ (void)load{
	static dispatch_once_t onceToken;
	dispatch_once(&onceToken, ^{
		Class class = objc_getClass("GLFWApplicationDelegate");

		[GLFWCustomDelegate swizzle:class src:@selector(application:openFile:) tgt:@selector(swz_application:openFile:)];
		[GLFWCustomDelegate swizzle:class src:@selector(application:openFiles:) tgt:@selector(swz_application:openFiles:)];
	});
}

+ (void) swizzle:(Class) original_c src:(SEL)original_s tgt:(SEL)target_s{
	Class target_c = [GLFWCustomDelegate class];
	Method originalMethod = class_getInstanceMethod(original_c, original_s);
	Method swizzledMethod = class_getInstanceMethod(target_c, target_s);

	BOOL didAddMethod =
	class_addMethod(original_c,
					original_s,
					method_getImplementation(swizzledMethod),
					method_getTypeEncoding(swizzledMethod));

	if (didAddMethod) {
		class_replaceMethod(original_c,
							target_s,
							method_getImplementation(originalMethod),
							method_getTypeEncoding(originalMethod));
	} else {
		method_exchangeImplementations(originalMethod, swizzledMethod);
	}
}

- (BOOL)swz_application:(NSApplication *)sender openFile:(NSString *)filename{
	forward_load_message(filename.UTF8String);
}

- (void)swz_application:(NSApplication *)sender openFiles:(NSArray<NSString *> *)filenames{
	forward_load_message(filenames.firstObject.UTF8String);
}

@end

Customize your existing main.cpp
// file: main.cpp
// this is mostly pseudocode, adjust to your needs
CoolApp * myApp = nullptr;
bool startup_kind_of_done = false;
string startup_file_to_load = "";

extern "C"{
	void forward_load_message(const char * filename){
		if(!startup_kind_of_done){
			// this is the case where a user double clicks a file, but your app is not yet open
			startup_file_to_load = filename;
		}
		else{
			myApp->load(string(filename));
		}
	}
}

int main(){
	// 1. set up windows, or whatever you need to do ...
	myApp = new CoolApp();

	// 2. check if we should load a file
	startup_kind_of_done = true;
	if(start_file_to_load != "" ){
		myApp->loadFile(startup_file_to_load);
	}

	// 3. we are done
	runSomeKindOfEventLoop(myApp);
}

Is there no similar API for this in Windows and Linux? I have been looking for a way to catch these events too, as I'd like to implement functionality similar to what I'm used to, on MacOS. On Windows, you can open files with specific applications, from the File Explorer. This is pretty much the same as MacOS offers. I would assume Linux has the same. So it is unclear to me why this would have to be a MacOS-only feature.

@ws909 iirc windows and linux handle this differently - they pass the file as the second argument to main/winmain and you can catch it there. on osx you have to catch it in application:(NSApplication *)sender openFile and it won't be in your args array.
the even bigger difference is that on osx only one instance of your executable will ever be launched and you have to take care of multi-document applications yourself, while on windows and linux a new instance will be launched every time you double click a file.

@kritzikratzi That clarifies. I still do believe such events are still such a basic part of an application, though, that it should be included in GLFW. I can think of two ways to implement cross-platform support:

Platform decides the model.
MacOS approach on all platforms

Java (as I use LWJGL):
void openFiles(String[] paths) {
    ...
}

static void main(String[] arguments) {

    glfwInitHint(GLFW_REDIRECT_APPLICATION, GLFW_FALSE); // Possibly GLFW_REDIRECT_OPEN_FILES instead
    glfwInitHint(GLFW_INIT_FILE_ARGUMENTS, arguments);

    glfwInit()

    glfwSetOpenFilesCallback(openFiles);

    final var paths = glfwGetOpenedFilenames();

    if (paths != null) {
        openFiles(paths); // Or any other way to respond
    }

    while (true) {
        glfwWaitEvents();
    }
}

This is model 1. The GLFW_INIT_FILE_ARGUMENTS is used to set the arguments that glfwInit parses to find which files to open. These can be queried with glfwGetOpenedFilenames. On MacOS, there won't be any file paths delivered through the arguments, however, the current implementation, #1579, solves this. On MacOS, when the system again invokes NSAppDelegate::openFiles, the openFiles method set as the callback, will be run. glfwGetOpenedFilenames will return these new files only. NSAppDelegate::openFile is ignored in this implementation.
For model 2, set GLFW_REDIRECT_APPLICATION to GLFW_TRUE. First time the application is launched, on Linux and Windows, glfwInit sets this "instance" as the main one, for the user. Subsequent executions of the same application, will make glfwInit transfer the file paths to the main instance, which are forwarded to the callback. Then glfwInit aborts initilization, and returns GLFW_FALSE. Can check this with glfwDidTransfer or glfwWasAlreadyLaunched, etc.

do it :) everyone is gonna enjoy. i already have a solution that is not great, but it works for me (posted far above)

@kritzikratzi Might look into it later. :) Did look at your solution. Seems like a nice hack, but it's unnecessarily complicated for something that should be easily done by GLFW.

of course it's a hack :D but it works with any glfw version and it integrates easy as pie into a c/c++ project. i guess from a java perspective it's pita.


Port fix jira and slack notification

Description
Changed "subject.dependency.project.name" to
"subject.component.project.name" in default Jira template, to fix project name not displaying in Jira ticket summaries for notifications with type NEW_VULNERABLE_DEPENDENCY.
Addressed Issue
Backport change https://github.com/DependencyTrack/hyades/issues/1190
Checklist

[x] I have read and understand the contributing guidelines
[x] This PR fixes a defect, and I have provided tests to verify that the fix is effective
[ ] This PR implements an enhancement, and I have provided tests to verify that it works as intended
[ ] This PR introduces changes to the database model, and I have updated the migration changelog accordingly
[ ] This PR introduces new or alters existing behavior, and I have updated the documentation accordingly

@sahibamittal Could you please also update the templates here: https://github.com/DependencyTrack/hyades/tree/main/notification-publisher/src/test/resources/templates
And update the corresponding publisher tests here: https://github.com/DependencyTrack/hyades/tree/main/notification-publisher/src/test/java/org/dependencytrack/notification/publisher
Sadly the templates will need to be duplicated until https://github.com/DependencyTrack/hyades/issues/932 is done.


Improve performance for CSV generation

This change results in a huge performance improvement on toCsvText for larger output sizes.
The performance boost comes from using a string builder instead of concatenating the strings one by one, which gets slower as the output size gets bigger.
With this change the generation time becomes O(n).
I didn't write a performance test for this, but testing locally on a CSV file of around 500kB the generation time went from many seconds (10s+) to less than a second.
Thanks for sharing this implementation.

Awesome!


Manage MOOSE env vars

Dear MOOSE team,
I mentioned the following issue in another issue and wanted to create a new one for it:
I don't know if adding the env variables to `.bashrc` is the best place to do it. Some users might use zsh and others might use nnUnet seperately.

Originally posted by @chris-clem in https://github.com/QIMP-Team/MOOSE/issues/42#issuecomment-1286930959.
As a quick solution, I added a env_vars.sh file in the MOOSE repo dir that I source instead of .bashrc. In the meantime, I have searched how people are handling the problem in general and found the following possibilities:

Create a .env file in the repo dir and load it with python-dotenv as explained here.
Create a .env file in the repo dir and recommend users to use direnv, which then automatically loads the env variables when changing in the MOOSE dir.
Recommend users to create a MOOSE conda environment and enable loading and unloading the env vars when activating/ deactivating the conda environment as described here.

The downside of 1. is that it requires a new dependency, the downside of 2. that it requires a new program, and the downside of 3. is that it requires conda for managing the environment.
What do you think is the best option?

Hi @chris-clem, I am down with Covid and the other MOOSE members are on vacay. Many thanks for the detailed analysis.I will be able to look at it in detail next week. Sorry about the delay!

No problem, I hope you recover soon!

Did you get a chance to take a look?

@chris-clem I did, I like option 2...

Got it, thanks! I try to create a PR next week.

MOOSE v2.0 doesn't have any of these issues @chris-clem! Also a friend showed me your prezi from Fully-3D conference. Now you can actually integrate your models easily in MOOSEV2. Have a look at the readme!


V2.0 glossary test

@ROBERT-MCDOWELL
Was looking at adding a Glossary to the README 🤔
Only Downside is for it to function we have to remove the emojis from the chapter titles :(
Thoughts?
Or any suggestions on where to put it if you approve of it? 🤔

README can survive without emojis I think :)

tru tru 👍
So your fine with that placement of it?

LGTM, language code must be 3 letters btw ;)

Oo good catch


Default to using tokenizer eos and bos in convert_text_to_mds.py

@jacobfulano This would be a good change to apply to the BERT repo too. 👍


Create database and seed succesfully

GIVEN a functional Express.js API
WHEN I enter schema and seed commands
THEN a development database is created and is seeded with test data

completed


32blit - Namespace pollution

The following engine headers include using namespace blit;.

[ ] types/map.hpp
[ ] graphics/surface.hpp
[ ] graphics/tilemap.hpp

This causes every file that includes them to also use the namespace, leading to random name collisions in user code. This filters through to any file that includes 32blit.hpp.
Note that fixing this will probably break all the examples that don't already contain using namespace blit;.

Let it be said that I broadly hate the use of using namespace blit; and would probably prefer everything to use the longform, namespace-qualified names. It leaves much less opportunity for name conflicts, or shadowing? Is that even a thing in C++. Although I can't say something if like colour = blit::colour(0,0,0); is more or less desirable.
I guess I can't shake that it reminds me of one of my most-hated Python code-smells: import numpy as np.

The issue here is using it inside headers - it's fine if you do it inside the .cpp because it will never affect user code.
And yes name shadowing most certainly is a thing. I have a variable called buttons and the IDE complains that it shadows blit::buttons everywhere.


"AWS IOT DEVICE CLIENT FATAL ERROR: Aborting program due to unrecoverable feature error!"

Describe the bug
I'm attempting to configure a Raspberry Pi Zero 2 W with AWS IoT such that I can have it perform tasks invoked via IoT Jobs.
However, after getting as far as seeing sample MQTT messages appear from the test client, the device client hits an error and halts.
To Reproduce
I've followed the guides for provisioning and configuring a device and so far have:

Added the device as a Thing in IoT.
Generated and saved the required keys and certs using aws iot create-keys-and-certificate.
Attached the certificate to the Thing in IoT.
Created a policy with the following permissions:

{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": "iot:Connect",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:client/rpi-thing-1"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Publish",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/test/dc/pubtopic"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Publish",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/events/job/*"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Publish",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/things/rpi-thing-1/jobs/*"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Publish",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/events/jobExecution/*"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Subscribe",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topicfilter/test/dc/subtopic"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Subscribe",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topicfilter/$aws/things/rpi-thing-1/jobs/*"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Subscribe",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/events/jobExecution/*"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Receive",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/test/dc/subtopic"
    },
    {
      "Effect": "Allow",
      "Action": "iot:Receive",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/things/rpi-thing-1/jobs/*"
    },
    {
      "Effect": "Allow",
      "Action": "iotjobsdata:DescribeJobExecution",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/things/rpi-thing-1"
    },
    {
      "Effect": "Allow",
      "Action": "iotjobsdata:GetPendingJobExecutions",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/things/rpi-thing-1"
    },
    {
      "Effect": "Allow",
      "Action": "iotjobsdata:UpdateJobExecution",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/things/rpi-thing-1"
    },
    {
      "Effect": "Allow",
      "Action": "iotjobsdata:StartNextPendingJobExecution",
      "Resource": "arn:aws:iot:eu-west-1:7**********8:topic/$aws/things/rpi-thing-1"
    }
  ]
}

Attached the policy to the certificate.
Cloned and built aws-iot-device-client.
Configured the client using sudo setup.sh (as I believe I want it run as a service) with the following configuration:

{
  "endpoint":	"a***********0-ats.iot.eu-west-1.amazonaws.com",
  "cert":	"/etc/ssl/iot_certs/dev.pem.crt",
  "key":	"/etc/ssl/private/dev_private.pem.key",
  "root-ca":	"/etc/ssl/iot_certs/AmazonRootCA1.pem",
  "thing-name":	"rpi-thing-1",
  "logging":	{
    "level":	"DEBUG",
    "type":	"FILE",
    "file": "/var/log/aws-iot-device-client/aws-iot-device-client.log",
    "enable-sdk-logging":	true,
    "sdk-log-level":	"TRACE",
    "sdk-log-file": "/var/log/aws-iot-device-client/sdk.log"
  },
  "jobs":	{
    "enabled":	true,
    "handler-directory": "/etc/.aws-iot-device-client/jobs"
  },
  "tunneling":	{
    "enabled":	true
  },
  "device-defender":	{
    "enabled":	false,
    "interval": 300
  },
  "fleet-provisioning":	{
    "enabled":	false,
    "template-name": "",
    "template-parameters": "",
    "csr-file": "",
    "device-key": ""
  },
  "samples": {
    "pub-sub": {
      "enabled": true,
      "publish-topic": "test/dc/pubtopic",
      "publish-file": "/etc/.aws-iot-device-client/pubsub/publish-file.txt",
      "subscribe-topic": "test/dc/subtopic",
      "subscribe-file": "/etc/.aws-iot-device-client/pubsub/subscribe-file.txt"
    }
  },
  "config-shadow":	{
    "enabled":	false
  },
  "sample-shadow": {
    "enabled": false,
    "shadow-name": "",
    "shadow-input-file": "",
    "shadow-output-file": ""
  }
}

Published test messages from the MQTT test client to the test/dc/subtopic topic.

Expected behavior
(I'm still trying to understand exactly how the device client and IoT Jobs are intended to be used versus how I think I want them used, however:) If I understand correctly the client would run continously as a service in the background, listening to for MQTT and IoT Job updates.
While the client remains active briefly, when sending the test messages from the MQTT test client, I can see them appear in /etc/.aws-iot-device-client/pubsub/subscribe-file.txt as expected.
Actual behavior
After a few seconds of the device client service running it halts and reports a couple of different errors and I'm unsure which is the actualy cause of the service halting/which is the one that needs addressing (see logs).
Logs
/var/log/aws-iot-device-client/aws-iot-device-client.log:
2024-09-24T08:37:54.472Z [INFO]  {Config.cpp}: Successfully fetched JSON config file:
{
  ...
}
2024-09-24T08:37:54.473Z [INFO]  {FileUtils.cpp}: Successfully create directory /root/.aws-iot-device-client/sample-shadow/ with required permissions 700
2024-09-24T08:37:54.473Z [INFO]  {Config.cpp}: ~/.aws-iot-device-client/sample-shadow/default-sample-shadow-document
2024-09-24T08:37:54.473Z [INFO]  {Config.cpp}: Succesfully create default file: /root/.aws-iot-device-client/sample-shadow/default-sample-shadow-document required for storage of shadow document
2024-09-24T08:37:54.473Z [DEBUG] {Config.cpp}: Did not find a runtime configuration file, assuming Fleet Provisioning has not run for this device
2024-09-24T08:37:54.474Z [DEBUG] {Config.cpp}: Did not find a http proxy config file /root/.aws-iot-device-client/http-proxy.conf, assuming HTTP proxy is disabled on this device
2024-09-24T08:37:54.474Z [DEBUG] {EnvUtils.cpp}: Updated PATH environment variable to: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/.aws-iot-device-client:/root/.aws-iot-device-client/jobs:/://jobs
2024-09-24T08:37:54.474Z [DEBUG] {LockFile.cpp}: creating lockfile
2024-09-24T08:37:54.474Z [INFO]  {Main.cpp}: Now running AWS IoT Device Client version v1.9.2-cf738c8
2024-09-24T08:37:54.475Z [INFO]  {SharedCrtResourceManager.cpp}: SDK logging is enabled. Check /var/log/aws-iot-device-client/sdk.log for SDK logs.
2024-09-24T08:37:54.476Z [DEBUG] {Retry.cpp}: Retryable function starting, it will retry until success
2024-09-24T08:37:54.779Z [INFO]  {SharedCrtResourceManager.cpp}: Establishing MQTT connection with client id rpi-thing-1...
2024-09-24T08:37:55.009Z [INFO]  {SharedCrtResourceManager.cpp}: MQTT connection established with return code: 0
2024-09-24T08:37:55.009Z [INFO]  {SharedCrtResourceManager.cpp}: Shared MQTT connection is ready!
2024-09-24T08:37:55.009Z [INFO]  {Main.cpp}: Config shadow is disabled
2024-09-24T08:37:55.009Z [INFO]  {Main.cpp}: Jobs is enabled
2024-09-24T08:37:55.009Z [INFO]  {Main.cpp}: Secure Tunneling is enabled
2024-09-24T08:37:55.009Z [INFO]  {Main.cpp}: Device Defender is disabled
2024-09-24T08:37:55.009Z [INFO]  {Main.cpp}: Sample shadow is disabled
2024-09-24T08:37:55.009Z [INFO]  {Main.cpp}: PubSub is enabled
2024-09-24T08:37:55.009Z [INFO]  {samples/PubSubFeature.cpp}: Creating Pub/Sub file: /etc/.aws-iot-device-client/pubsub/publish-file.txt
2024-09-24T08:37:55.009Z [INFO]  {samples/PubSubFeature.cpp}: Creating Pub/Sub file: /etc/.aws-iot-device-client/pubsub/subscribe-file.txt
2024-09-24T08:37:55.010Z [INFO]  {Main.cpp}: Sensor Publish is disabled
2024-09-24T08:37:55.010Z [INFO]  {SharedCrtResourceManager.cpp}: Starting Device Client features.
2024-09-24T08:37:55.010Z [DEBUG] {FeatureRegistry.cpp}: Attempting to start Jobs
2024-09-24T08:37:55.010Z [INFO]  {Main.cpp}: Client base has been notified that Jobs has started
2024-09-24T08:37:55.010Z [DEBUG] {FeatureRegistry.cpp}: Attempting to start Pub Sub Sample
2024-09-24T08:37:55.010Z [INFO]  {samples/PubSubFeature.cpp}: Starting Pub Sub Sample
2024-09-24T08:37:55.010Z [INFO]  {JobsFeature.cpp}: Running Jobs!
2024-09-24T08:37:55.010Z [DEBUG] {JobsFeature.cpp}: Attempting to subscribe to startNextPendingJobExecution accepted and rejected
2024-09-24T08:37:55.010Z [INFO]  {Main.cpp}: Client base has been notified that Pub Sub Sample has started
2024-09-24T08:37:55.010Z [DEBUG] {FeatureRegistry.cpp}: Attempting to start Secure Tunneling
2024-09-24T08:37:55.010Z [DEBUG] {JobsFeature.cpp}: Attempting to subscribe to nextJobChanged events
2024-09-24T08:37:55.010Z [INFO]  {SecureTunnelingFeature.cpp}: Running Secure Tunneling!
2024-09-24T08:37:55.010Z [DEBUG] {JobsFeature.cpp}: Attempting to subscribe to updateJobExecutionStatusAccepted for jobId +
2024-09-24T08:37:55.010Z [INFO]  {Main.cpp}: Client base has been notified that Secure Tunneling has started
2024-09-24T08:37:55.062Z [DEBUG] {samples/PubSubFeature.cpp}: Message received on subscribe topic, size: 45 bytes
2024-09-24T08:37:55.064Z [DEBUG] {samples/PubSubFeature.cpp}: Message received on subscribe topic, size: 45 bytes
2024-09-24T08:37:55.064Z [DEBUG] {samples/PubSubFeature.cpp}: SubAck: PacketId:(Pub Sub Sample), ErrorCode:0
2024-09-24T08:37:55.067Z [ERROR] {SharedCrtResourceManager.cpp}: MQTT Connection interrupted with error: `libaws-c-mqtt: AWS_ERROR_MQTT_UNEXPECTED_HANGUP, The connection was closed unexpectedly.`. Device Client will retry connection until it is successfully connected to the core.
2024-09-24T08:38:05.011Z [ERROR] {JobsFeature.cpp}: Timed out while waiting for acknowledgement of subscription to UpdateJobExecutionStatusAccepted
2024-09-24T08:38:05.011Z [ERROR] {Main.cpp}: Subscription rejected: Timed out while waiting for acknowledgement of subscription to UpdateJobExecutionStatusAccepted
2024-09-24T08:38:05.011Z [ERROR] {Main.cpp}: *** AWS IOT DEVICE CLIENT FATAL ERROR: Aborting program due to unrecoverable feature error! ***
2024-09-24T08:38:05.011Z [DEBUG] {SharedCrtResourceManager.cpp}: Attempting to disconnect MQTT connection
2024-09-24T08:38:10.068Z [INFO]  {SharedCrtResourceManager.cpp}: MQTT Connection is now disconnected

/var/log/aws-iot-device-client/sdk.log
(Omitted due to size. Available on request)
Environment

OS: Raspbian
Version: Debian GNU/Linux 12 (bookworm)
Architecture: ARM64/AArch64 (Raspberry Pi Zero 2 W)
Device Client commit: cf738c82927f5a0020a58fda88a5de65b11a4574

Additional context
Whilst I have configured this to use IoT Jobs, I haven't created any jobs yet as I wanted to ensure the client was set-up first.
Given the line in the log: Subscription rejected: Timed out while waiting for acknowledgement of subscription to UpdateJobExecutionStatusAccepted, is this being caused by the client trying to subscribe to a job but finding none?

@simoncotts-knaufenergy  I don't think  the issue is caused because of the absence of job.  Just to rule out policy permission issue,  can you please consider using a permissive policy like below for a quick test:
{   "Version": "2012-10-17",   "Statement": [     {       "Effect": "Allow",       "Action": "iot:*",        "Resource": "arn:aws:iot:eu-west-1:7**********8:*"     }   ] }

@simoncotts-knaufenergy Yes, this is a policy configuration issue.  I am not well versed on the cli, I will connect with my colleagues and get back to you on this early next week.  Thanks for reporting back.

Hey @simoncotts-knaufenergy . You are right, it is a policy configuration issue. In your case, since you are using the pub-sub, tunneling and jobs feature. I would recommend you to use the below mentioned policy curated for these features. You can use them as modular independent policies or merge them together in a single one as per your liking:
Tunneling:

{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "iot:Connect",
"Resource": "arn:aws:iot:us-west-2:664418966762:client/ARM_test"
},
{
"Effect": "Allow",
"Action": "iot:Subscribe",
"Resource": "arn:aws:iot:us-west-2:664418966762:topicfilter/$aws/things/ARM_test/tunnels/notify"
}
]
}

Pub-Sub:

{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"iot:Connect"
],
"Resource": [
"arn:aws:iot:us-west-2:664418966762:client/${iot:Connection.Thing.ThingName}"
],
"Condition": {
"Bool": {
"iot:Connection.Thing.IsAttached": "true"
}
}
},
{
"Effect": "Allow",
"Action": [
"iot:Publish"
],
"Resource": [
"arn:aws:iot:us-west-2:664418966762:topic/test"
]
},
{
"Effect": "Allow",
"Action": [
"iot:Subscribe"
],
"Resource": [
"arn:aws:iot:us-west-2:664418966762:topicfilter/test"
]
},
{
"Effect": "Allow",
"Action": [
"iot:Receive"
],
"Resource": [
"arn:aws:iot:us-west-2:664418966762:topic/test"
]
}
]
}

Jobs

{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "iot:Connect",
"Resource": "arn:aws:iot:us-west-2:664418966762:client/${iot:Connection.Thing.ThingName}"
},
{
"Effect": "Allow",
"Action": "iot:Publish",
"Resource": [
"arn:aws:iot:us-west-2:664418966762:topic/$aws/things/${iot:Connection.Thing.ThingName}/jobs/start-next",
"arn:aws:iot:us-west-2:664418966762:topic/$aws/things/${iot:Connection.Thing.ThingName}/jobs//update"
]
},
{
"Effect": "Allow",
"Action": "iot:Subscribe",
"Resource": [
"arn:aws:iot:us-west-2:664418966762:topicfilter/$aws/things/${iot:Connection.Thing.ThingName}/jobs/start-next/accepted",
"arn:aws:iot:us-west-2:664418966762:topicfilter/$aws/things/${iot:Connection.Thing.ThingName}/jobs/start-next/rejected",
"arn:aws:iot:us-west-2:664418966762:topicfilter/$aws/things/${iot:Connection.Thing.ThingName}/jobs//update/accepted",
"arn:aws:iot:us-west-2:664418966762:topicfilter/$aws/things/${iot:Connection.Thing.ThingName}/jobs//update/rejected",
"arn:aws:iot:us-west-2:664418966762:topicfilter/$aws/things/${iot:Connection.Thing.ThingName}/jobs/notify-next"
]
},
{
"Effect": "Allow",
"Action": "iot:Receive",
"Resource": [
"arn:aws:iot:us-west-2:664418966762:topic/$aws/things/${iot:Connection.Thing.ThingName}/jobs/start-next/accepted",
"arn:aws:iot:us-west-2:664418966762:topic/$aws/things/${iot:Connection.Thing.ThingName}/jobs/start-next/rejected",
"arn:aws:iot:us-west-2:664418966762:topic/$aws/things/${iot:Connection.Thing.ThingName}/jobs//update/accepted",
"arn:aws:iot:us-west-2:664418966762:topic/$aws/things/${iot:Connection.Thing.ThingName}/jobs/*/update/rejected",
"arn:aws:iot:us-west-2:664418966762:topic/$aws/things/${iot:Connection.Thing.ThingName}/jobs/notify-next"
]
}
]
}

You may close the ticket if your all your issues are resolved. Thanks for reaching out.

Thank you for the recommendation! I've create seperate policies for each using these examples.
So far the device client appears to be running continuously without further issue. 🤞🏻


Appending secor hostname to the S3 file name

I want to consume data via secor from 3 Kafka Clusters and store the data on one bucket on S3.
I have secor hosts running for each Kafka Cluster.
Is there a way that I can add/append the hostname (of the secor instance) to the file (object) name ?
Here is our setup.
Kafka Cluster deployed on 3 zones on AWS
Each cluster receives a different message
Secor needs to be setup on each zone to consume message from Kafka, but write messages from all 3 zones on to the same bucket (or path)
Currently I can create s3 path as
S3://test_bucket/topic/zone1/secor_host1/1_000000000000
S3://test_bucket/topic/zone1/secor_host2/1_000000000000
S3://test_bucket/topic/zone1/secor_host2/1_000000000000
...
S3://test_bucket/topic/zone2/secor_host2/1_000000000000
How can I create files as
S3://test_bucket/topic/zone1_secor_host1_1_000000000000
S3://test_bucket/topic/zone1_secor_host2_1_000000000000
S3://test_bucket/topic/zone2_secor_host1_1_000000000000
S3://test_bucket/topic/zone2_secor_host2_1_000000000000
...
Thanks

The file path is controlled in MessageWriter.java as shown below.  The
IdUtil.getLocalMessageDir will get the concat of processId + threadId, if
you want hostname as part of the file path, you can potentially extend that.
mLocalPrefix = mConfig.getLocalPath() + '/' + IdUtil.getLocalMessageDir();
On Fri, Mar 18, 2016 at 5:43 PM, Vivek Thakre<EMAIL_ADDRESS>wrote:

I want to consume data via secor from 3 Kafka Clusters and store the data
on one bucket on S3.
I have secor hosts running for each Kafka Cluster.
Is there a way that I can add/append the hostname (of the secor instance)
to the file (object) name ?
Here is our setup.
Kafka Cluster deployed on 3 zones on AWS
Each cluster receives a different message
Secor needs to be setup on each zone to consume message from Kafka, but
write messages from all 3 zones on to the same bucket (or path)
Currently I can create s3 path as
S3://test_bucket/topic/zone1/secor_host1/1_000000000000
S3://test_bucket/topic/zone1/secor_host2/1_000000000000
S3://test_bucket/topic/zone1/secor_host2/1_000000000000
...
S3://test_bucket/topic/zone2/secor_host2/1_000000000000
How can I create files as
S3://test_bucket/topic/zone1_secor_host1_1_000000000000
S3://test_bucket/topic/zone1_secor_host2_1_000000000000
S3://test_bucket/topic/zone2_secor_host1_1_000000000000
S3://test_bucket/topic/zone2_secor_host2_1_000000000000
...
Thanks
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
https://github.com/pinterest/secor/issues/191