Spec: we need to solve non-determinism for floating point columns

This is just a mirror issue for the discussion happening in Notion.

Just going to pull some of the linked Notion discussion here for visibility.

TL;DR Floating point math is, by definition an approximation, so how are we going to deal with that in a blockchain scenario where a network of validators abhors non-determinism!
The problem
Recently, our core detectives (ahem, developers) discovered an issue with floating point math when testing our validator network: How we detected a surprising non-deterministic cause of execution. In the subsequent research, they even found a reference to an article that doubts we can trust floating point math on Apple silicon. That’s not great, but it isn’t entirely surprising, because it turns out floating point math is hard. Lots of people know this, which is probably why they aren’t used for storing currencies or with blockchains very often.
Some “solutions”

Don’t support floating point values (and suggest something else like text)
Forcefully truncate things to some reasonable precision that we can safely support
Just live with it, and expect validators to only support specific architectures/hardwares
Find some code-based solution to work around the issue
Others?

Some initial thoughts
I’m really not a fan of not supporting FLOAT. This is a pretty big DX step backward. Additionally, expecting people to think about integer math is asking a lot. Which reminds me of another issue. This discussion is actually a lot bigger than just representing floating point numbers… it is also about floating point math. If folks have two numbers in a table, they are going to want to do math on those numbers, and probably in the database. So something like…
select cast(5 as int) / cast(2 as int);
-- 2
select cast(5 as float) / cast(2 as float);
-- 2.5

… seems like a pretty intuitive expectation for most devs, and something they should be able to do. Note that the even more intuitive behavior of…
create table math_is_hard (a_r real, a_i int, b_r real, b_i int) strict; -- added strict here just to make sure i'm doing it right
insert into math_is_hard values (5, 5, 2, 2);
select a_r / b_r from math_is_hard;
-- 2.5
select a_i / b_r from math_is_hard;
-- 2.5
select a_i / b_i from math_is_hard;
-- 2
select a_r / b_i from math_is_hard;
-- 2.5

… is slightly less explicit, but equally valid if they’re into analytics and not computer science!

🤔 While we’re at it, representing big integers is also not supporting in SQLite, and this is starting to look like an issue as well. Right now we’re recommending folks adopt an alternatively representation (text). We *can* help to address this using our SDK (opaquely convert BigInt to text on ingest), and we *can* do something similar with floats (e.g., `Number.isInteger` with Javascript helps in the SDK).

What does SQLite have to say about this?
With all that in mind, here’s what SQLite docs have to say about floating point numbers:

SQLite stores integer values in the 64-bit twos-complement format. This gives a storage range of -9223372036854775808 to +9223372036854775807, inclusive. Integers within this range are exact.

So-called "REAL" or floating point values are stored in the IEEE 754 Binary-64 format. This gives a range of positive values between approximately 1.7976931348623157e+308 and 4.9406564584124654e-324 with an equivalent range of negative values. A binary64 can also be 0.0 (and -0.0), positive and negative infinity and "NaN" or "Not-a-Number". Floating point values are approximate.
Pay close attention to the last sentence in the previous paragraph:
**Floating point values are approximate.**

If you need an exact answer, you should not use binary64 floating-point values, in SQLite or in any other product. This is not an SQLite limitation. It is a mathematical limitation inherent in the design of floating-point numbers.
Furthermore, “SQLite promises to preserve the 15 most significant digits of a floating point value. However, it makes no guarantees about the accuracy of computations on floating point values, as no such guarantees are possible.” This might suggest that truncation is a totally reasonable thing for us to do?
The docs do mention that there are extensions for dealing with floating point numbers, but again, these are based on alternative representations of floating point numbers, namely as text. They are a good idea, and we could support these in our Validators (they aren’t included by default), and add docs to suggest that folks leverage this.
But at the end of the day, we do still need to deal with the fact that floating point math is hard.

I'm not going to mirror the discussions from that Notion doc (I can provide a summary if that is helpful later). However, the outcome of that was essentially that we can't really support REAL values in our spec safely.

Thanks to some initial sleuthing by @jsign we know that there are only really 87 "tables" that leverage REAL column data types, and after deduplication, that leaves us with really only ~41 tables affected. Some of these tables appear to be stale, or unused, and some should be pretty easy to identify their owners.

For those following along, the proposal is now to drop support for REAL data types in our spec. If you have an issue with this proposal/decision, please speak now or forever hold your peace.

Ok, so I'm going to consider this discussion "passed" and I'm going to address it with a PR to this repo with the changes to the spec to reflect the fact that we no longer support REAL values in our spec.

@carsonfarmer one thing we did not explicitly discuss it is that we have to drop also support for literal float number. For example, SELECT 2.333 / column FROM table. The 2.333 is a literal float as is subject to the same problem.

Just curious why any of these rules to avoid non-determinism matter for read statements? Haven't been a part of the conversation, so I'm probably just not aware of something basic. Just read that last message and it's counter intuitive to me. I'd imagine that determinism is only required for writing data to tables and for read queries that are used to validate state (which the protocol should define and have control over).

Good point. We haven't really discussed read queries tbh. Most of the discussion revolved around the storage class types. But my take on that is that one of the things we want to guarantee is that different gateways return the exact same data. Even though the data stored can be exactly the same, we cannot guarantee with float operations on that data that the result will be the same across different validators.
We face the same problem whether SQLite is doing float operation before write or after write.

Just throwing another kind of unrelated comment. I think this is related to why we need two kinds of proof. One is proof of the correct stored state and another is proof of retrieval/queries.

Also another reason is perhaps just avoiding confusion. If we allow things like FLOAT literals in read queries, someone is going to ask "why here but not there", or "why do I get this result from one validator, and this from another". Better to just avoid REAL values altogether and add them back later if we find a solution.

Ok good points. I hadn't considered the importance of consistent query results from different validators or proof of retrieval.


problem in emment

Issue Type: Performance Issue
Hello.
When creating an html page, auto-writing does not work when clicked!
emmet not working
VS Code version: Code 1.69.0 (Universal) (92d25e35d9bf1a6b16f7d0758f25d48ace11e5b9, 2022-07-07T05:28:41.511Z)
OS version: Darwin arm64 21.5.0
Restricted Mode: No

it can be fixed?

/duplicate of https://github.com/microsoft/vscode/issues/154375

Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for similar existing issues. See also our issue reporting guidelines.
Happy Coding!


How to create a sql query to get this kind of result?

I got a few problems when trying to fetch only specific data. First I don't know how to create a sql query (current sql query I can grab only one user) so I can grab the data like this.

Second I want to grab 1 year data until current date. Below is my sql query done so far (I need to do it manual one by one).
SELECT type,  COUNT(*) FROM (
  TABLE_DATE_RANGE([githubarchive:day.events_],
    TIMESTAMP('2013-1-01'),
    TIMESTAMP('2015-08-28')
  )) AS events
WHERE type IN ("CommitCommentEvent","CreateEvent","DeleteEvent","DeploymentEvent","DeploymentStatusEvent","DownloadEvent","FollowEvent",
"ForkEvent","ForkApplyEvent","GistEvent","GollumEvent","IssueCommentEvent","IssuesEvent","MemberEvent","MembershipEvent","PageBuildEvent",
"PublicEvent","PullRequestEvent","PullRequestReviewCommentEvent","PushEvent","ReleaseEvent","RepositoryEvent","StatusEvent","TeamAddEvent",
"WatchEvent") AND actor.login = "datomnurdin"
GROUP BY type;

Please advice. Thank you.

TABLE_DATE_RANGE should already care of the "1 year until current date".. That said, note that events_ tables start on Jan 1 of this year.
Re, multiple users: drop the AND actor.login clause and GROUP BY actor,type?

Like this right?
SELECT actor.login,
ifnull(sum(if(type='CommitCommentEvent',1,null)),0) as CommitCommentEvent,
ifnull(sum(if(type='CreateEvent',1,null)),0) as CreateEvent,
ifnull(sum(if(type='DeleteEvent',1,null)),0) as  DeleteEvent,
ifnull(sum(if(type='DeploymentEvent',1,null)),0) as  DeploymentEvent,
ifnull(sum(if(type='DeploymentStatusEvent',1,null)),0) as  DeploymentStatusEvent,
ifnull(sum(if(type='DownloadEvent',1,null)),0) as  DownloadEvent,
ifnull(sum(if(type='FollowEvent',1,null)),0) as  FollowEvent,
ifnull(sum(if(type='ForkEvent',1,null)),0) as  ForkEvent,
ifnull(sum(if(type='ForkApplyEvent',1,null)),0) as  ForkApplyEvent,
ifnull(sum(if(type='GistEvent',1,null)),0) as  GistEvent,
ifnull(sum(if(type='GollumEvent',1,null)),0) as  GollumEvent,
ifnull(sum(if(type='IssueCommentEvent',1,null)),0) as  IssueCommentEvent,
ifnull(sum(if(type='IssuesEvent',1,null)),0) as  IssuesEvent,
ifnull(sum(if(type='MemberEvent',1,null)),0) as  MemberEvent,
ifnull(sum(if(type='MembershipEvent',1,null)),0) as  MembershipEvent,
ifnull(sum(if(type='PageBuildEvent',1,null)),0) as  PageBuildEvent,
ifnull(sum(if(type='PublicEvent',1,null)),0) as  PublicEvent,
ifnull(sum(if(type='PullRequestEvent',1,null)),0) as  PullRequestEvent,
ifnull(sum(if(type='PullRequestReviewCommentEvent',1,null)),0) as  PullRequestReviewCommentEvent,
ifnull(sum(if(type='PushEvent',1,null)),0) as  PushEvent,
ifnull(sum(if(type='ReleaseEvent',1,null)),0) as  ReleaseEvent,
ifnull(sum(if(type='RepositoryEvent',1,null)),0) as  RepositoryEvent,
ifnull(sum(if(type='StatusEvent',1,null)),0) as  StatusEvent,
ifnull(sum(if(type='TeamAddEvent',1,null)),0) as  TeamAddEvent,
ifnull(sum(if(type='WatchEvent',1,null)),0) as  WatchEvent,
FROM (
  TABLE_DATE_RANGE([githubarchive:day.events_],
    TIMESTAMP('2013-08-27'),
    TIMESTAMP('2015-08-28')
  )) AS events
WHERE type IN ("CommitCommentEvent","CreateEvent","DeleteEvent","DeploymentEvent","DeploymentStatusEvent","DownloadEvent","FollowEvent",
"ForkEvent","ForkApplyEvent","GistEvent","GollumEvent","IssueCommentEvent","IssuesEvent","MemberEvent","MembershipEvent","PageBuildEvent",
"PublicEvent","PullRequestEvent","PullRequestReviewCommentEvent","PushEvent","ReleaseEvent","RepositoryEvent","StatusEvent","TeamAddEvent",
"WatchEvent")
GROUP BY 1
limit 100

Another quick question, how I can focus only 1 location such as "Malaysia"? BTW, i'm not really understand this one "TABLE_DATE_RANGE should already care of the "1 year until current date"". How I can achieve this?
For location column I cant find it in Google Big Query repository.

Don't worry about the date, I already figure it out. How about the location issue?

I'm not sure what location means in this context.. Also, I don't think GitHub exposes such data. You can see example payloads here: https://developer.github.com/v3/activity/events/types/ - none of those specify location.


CFR Form - Review/Approve Fee Estimate

As an IAO User
I want to be able to approve a fee
so that I can proceed to putting a request on hold

Assumptions & Scope
Primarily a FE change to #2195 to make current checkbox into a dropdown menu
This story reflects the need for IAO to signal to the Ministry the stage it is at when a request is in fee estimate, and whether or not clarification is required. If a user updates the state to "Needs Clarification" the Ministry will be able to edit the estimated figures. IAO will communicate concerns to the Ministry through the comments feature.
What is IN scope?
IAO permissions and abilities to modify the CFR Form Status
What is NOT in scope?
Notifications/Comments for updates to state
Placing request on hold
Sending payment instructions to applicant
processing payments
Acceptance Criteria
Scenario 1: CFR Form Status - In Review Upon Viewing

GIVEN an IAO analyst is on a request in the 'Fee Estimate' state
WHEN they click on CFR Form
THEN they will be taken to the CFR form with overall fee estimate
AND the CFR form status will automatically update to "In Review"
AND the form will be editable for the IAO analyst

Scenario 2: CFR Form Status - Drop Down Options

GIVEN an IAO analyst is on the CFR form page
WHEN they activate the drop down for the CFR status
THEN they will see 3 options they can select: "In Review (default), Approved, Needs Clarification"

Scenario 3: Change of Status Modal - Needs Clarification

GIVEN an IAO analyst is  on the CFR form page, and has activated the drop down for CFR Status
WHEN they change the status to "Needs Clarification"
THEN a modal will pop out and ask "Are you sure you want to change the status to needs clarification? The CFR form will be locked for editing and only the Ministry coordinator can change it back"
AND there will be an option to 'Save' and 'Cancel'

Scenario 4: Change of Status Modal - Activate Save - Needs Clarification

GIVEN an IAO analyst is on the Change of Status Modal for Needs Clarification
WHEN the analyst clicks save
THEN the modal will close
AND a toast will appear indicating the save was successful
AND the new CFR form status will now display for both Ministry and IAO

Scenario 5: Change of Status Modal - Approved

GIVEN an IAO analyst is  on the CFR form page, and has activated the drop down for CFR Status
WHEN they change the status to "Approved"
THEN a modal will pop out and ask "Are you sure you want to change the status to approved? The CFR form will be locked for editing, and can only be unlocked by changing the status back"
AND there will be an option to 'Save' and 'Cancel'

Scenario 6: Activate Save - Approved

GIVEN an IAO analyst is on the Change of Status Modal for Approved
WHEN the analyst clicks save
THEN the modal will close
AND a toast will appear indicating the save was successful
AND the new CFR form status will now display for both Ministry and IAO

Scenario 7: Change of CFR Status Modal - Cancel

GIVEN an IAO analyst is on the change of status modal for either approved OR needs clarification
WHEN the analyst clicks cancel
THEN the modal will close and the status will revert to the prior status

Scenario 8: Form editable in  Needs Clarification

GIVEN an ministry coordinator is on the CFR Form Page
WHEN the form has been put in Clarification by the IAO analyst
THEN the form will be editable by ministry coordinator

Scenario 9: Estimated hours on form not editable in Approved

GIVEN an ministry coordinator is on the CFR Form Page
WHEN the form has been put in the Approved state by the IAO analyst
THEN the estimated hours on the form will NOT be editable by the ministry coordinator

Dependencies? What is the impact of this dependency? (If so, link dependency in the ticket, make it visible in a team´s backlog)
Validation Rules? (If yes, list here)
Design
https://jacklyn808742.invisionapp.com/console/share/3W2O64AP5C/915277140
Definition of Ready

[ ] Is there a well articulated User Story?
[ ] Is there Acceptance Criteria that covers all scenarios (happy/sad paths)?
[ ] If there is a user interface, is there a design?
[ ] Does the user story need user research/validation?
[ ] Does this User Story needs stakeholder approval?
[ ] Design / Solution accepted by Product Owner
[ ] Is this user story small enough to be completed in a Sprint? Should it be split?
[ ] Are the dependencies known/ understood? (technical, business, regulatory/policy)
[ ] Has the story been estimated?

Definition of Done

[ ] Passes developer unit tests
[ ] Passes peer code review
[ ] If there's a user interface, passes UX assurance
[ ] Passes QA of Acceptance Criteria with verification in Dev and Test
[ ] Confirm Test cases built and succeeding
[ ] No regression test failures
[ ] Test coverage acceptable by Product Owner
[ ] Ticket ready to be merged to master or story branch
[ ] Developer to list Config changes/ Update documents and designs
[ ] Can be demoed in Sprint Review
[ ] Tagged as part of a Release
[ ] Feature flagged if required
[ ] Change Management activities done?

CFR form review/approve fee estimate story - ready for review, hoping to get this in for refinement on friday.
Comments welcome @lmullane @JHarrietha-AOT @KaraBeach @mpilchar

Looks good, @m-prodan. This is ready for refinement IMO.

I agree with @lmullane - The process makes sense. @m-prodan

This ticket is only focused on the front end changes of the state of the CFR Form, and how it will desplay

@m-prodan sorry didn't catch this update to the AC until now, though the modal changes would come in a separate ticket. Will need an extra day or so to complete this

@m-prodan @lmullane  Can the IAO change from "On Hold" to "CFR" even if payment is not done.
Assuming yes; considering the scenario of waiver.
Can you please explain this scenario.

@m-prodan @lmullane  Can the actuals go above estimated values in terms of hours .

Closing ticket as AC is met.
@sumathi-thirumani-aot - sorry missed your questions here. Yes - actuals can go above estimate, sometimes the estimates are under-estimated.
And also yes re: no payment - a fee can be waived. There is a seperate flow for that that we will need to go through/map


Move back IExperimentalDebuggerBanner to where it was

I believe this type was in the debugger folder. Currently its in the common folder.
Its not common.
We need to fix these oddities before things get confusing.

This might have something to do with the debugger tests hanging.

Unlikely

I'll check what causing then to hang.

Thanks, I'm looking too, but cannot repro on Linux (the debugger tests progress in Linux for some reason, but not in Mac nor Windows). I'm putting together a VM at the moment to try it out on Windows.

I thought we confirmed the fact that all was ok, nothing is getting blocked. I can't see any blockages on VSTS!

You are correct, sir. I was thinking about yesterdays builds. Confirmed for myself. Thanks Don!

@d3r3kk I'm assigning this to myself. Need this done to get #2073 merged


Full of bugs (please update)

Error when downloading compressed files, Electron stopping to work, and output files being saved in AppData\Local\Electrify\Electrify\files.
@jyapayne

I can't do that. I don't have time or money to work on this. If someone would sponsor work on it, I would be happy to continue, but right now I just don't have the time. Alternatively, I would be willing to transfer ownership of the repo to someone if there is an interested party.

I would accept ownership, but I don't have enough knowledge.

Do you know another easy/graphical alternative to Electrify?

Unfortunately, I'm not aware of an alternative.

@DaniellMesquita I found one such project that may interest you. https://github.com/PhilippLgh/electron-toolkit, have you heard of it?


Deny access on specific files/folders within space

There is no option to deny access to specific users / groups on specific files/folders within a space.
Would be nice to have...

There is an experimental feature.
FRONTEND_OCS_ENABLE_DENIALS=true is the config to use.
Note: It is currently considered as not supported but will be in the future.


Basic training failure?

Q1：ImportError: cannot import name '_NewEmptyTensorOp' from 'torchvision.ops.misc'
Q2：PermissionError: [Errno 13] Permission denied: './basetrain.sh'
For the above two questions, can the owner answer them?

Q1 is related to torchvision version. Please ensure you install PyTorch == 1.7.1+cu102, TorchVision == 0.8.2+cu102
Q2 is related to the permission of basetrain.sh. To fix the permission denied error in Linux, one needs to change the file permission of the script. Use the “chmod” (change mode) command for this purpose.
Run the following command:
chmod u+x ./basetrain.sh
should solve the problem.

Q1：ImportError: cannot import name '_NewEmptyTensorOp' from 'torchvision.ops.misc' Q2：PermissionError: [Errno 13] Permission denied: './basetrain.sh' For the above two questions, can the owner answer them?

I also met Q1 question, if you don't want to change pytorch version, you can delete these codes from misc.py. This method can run all codes correctly. But I am not sure if it's OK to use different pytorch version with authors. Maybe different versions will affect results performance.

Q1：ImportError: cannot import name '_NewEmptyTensorOp' from 'torchvision.ops.misc' Q2：PermissionError: [Errno 13] Permission denied: './basetrain.sh' For the above two questions, can the owner answer them?

I also met Q1 question, if you don't want to change pytorch version, you can delete these codes from misc.py. This method can run all codes correctly. But I am not sure if it's OK to use different pytorch version with authors. Maybe different versions will affect results performance.

Thanks for your comments! I will check this issue after CVPR deadline.

Q1：ImportError: cannot import name '_NewEmptyTensorOp' from 'torchvision.ops.misc' Q2：PermissionError: [Errno 13] Permission denied: './basetrain.sh' For the above two questions, can the owner answer them?

About Q2 question, I agree with author's reply, in Meta-DETR-main folder, I input 'chmod 777 ./basetrain.sh' in terminal

Q1 is related to torchvision version. Please ensure you install PyTorch == 1.7.1+cu102, TorchVision == 0.8.2+cu102
Q2 is related to the permission of basetrain.sh. To fix the permission denied error in Linux, one needs to change the file permission of the script. Use the “chmod” (change mode) command for this purpose.
Run the following command: chmod u+x ./basetrain.sh should solve the problem.

According to your request, I executed it step by step, but I still found the error, the error is as follows OSError: [Errno 8] Exec format error: '. /basetrain.sh'

'''
## needed due to empty tensor bug in pytorch and torchvision 0.5
import torchvision
if float(torchvision.__version__[:3]) < 0.5:
    import math
    from torchvision.ops.misc import _NewEmptyTensorOp
    def _check_size_scale_factor(dim, size, scale_factor):
        # type: (int, Optional[List[int]], Optional[float]) -> None
        if size is None and scale_factor is None:
            raise ValueError("either size or scale_factor should be defined")
        if size is not None and scale_factor is not None:
            raise ValueError("only one of size or scale_factor should be defined")
        if not (scale_factor is not None and len(scale_factor) != dim):
            raise ValueError(
                "scale_factor shape must match input shape. "
                "Input is {}D, scale_factor size is {}".format(dim, len(scale_factor))
            )
    def _output_size(dim, input, size, scale_factor):
        # type: (int, Tensor, Optional[List[int]], Optional[float]) -> List[int]
        assert dim == 2
        _check_size_scale_factor(dim, size, scale_factor)
        if size is not None:
            return size
        # if dim is not 2 or scale_factor is iterable use _ntuple instead of concat
        assert scale_factor is not None and isinstance(scale_factor, (int, float))
        scale_factors = [scale_factor, scale_factor]
        # math.floor might return float in py2.7
        return [
            int(math.floor(input.size(i + 2) * scale_factors[i])) for i in range(dim)
        ]
elif float(torchvision.__version__[:3]) < 0.7:
    from torchvision.ops import _new_empty_tensor
    from torchvision.ops.misc import
'''

import torchvision
from packaging import version
if version.parse(torchvision.__version__) < version.parse('0.7'):
    from torchvision.ops import _new_empty_tensor
    from torchvision.ops.misc import _output_size

您好！您发给我的信件已经收到,我将尽快处理


Hey.

Devs will propably don't even fix that ... Good find anyway didn't think about that aproach.
i found a glitch with pocket map with like 2000+ commits back at version 11.7.3333 .. its still not fixed. I even posted all things what they need to do to patch it out on their reddit ...

The did not fix it, but BE will flag you.
I built my own wallhack/esp using the same NLog bug.
Got banned after 3 days.
https://github.com/fipso/EST-Player-Item-ESP

BE scans dll's btw ...

so is this trainer detected by BE or it's not detected ?

@petitfilou974 It's detected dude, what do you think

@PedroLuz89 have fun being BEd after 1-3 week's xD

can someone help me make this work on Just emu tarkov, i've zero knowledge in this plz

@ghost i have no idea weather this still works

@鬼我不知道这是否仍然有效
I want to know how to use these codes, because it's a beginner or something

can someone help me make this work on Just emu tarkov, i've zero knowledge in this plz

Not only are you bad at the game, but you also don't even know how to cheat when it's laid at your feet.
If you spent the time you are trying to cheat into actually playing the game you wouldn't need to cheat


Creating/Editing Gateway config throws exception if Client ID is empty

As in Title if you try to create or edit gateway config and will not put nothing in ClientId you will get an error

https://github.com/CommerceWeavers/SyliusTpayPlugin/pull/144 should solve this issue


Spec include_all_networks and third_party_instance_id on federation and c2s /publicRooms

Both appear in the query string. include_all_networks is a boolean, and third_party_instance_id is of the format "appservice_id|network_id" - unclear as to how someone gets the appservice ID.

Duplicate of https://github.com/matrix-org/matrix-doc/issues/869


Add NetBSD as a valid OSName and BuildOS type

Hi @krytarowski, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
The agreement was validated by .NET Foundation and real humans are currently evaluating your PR.
TTYL, DNFBOT;

Done!

Could you please s/XXX/TODO/? It is our convention (and XXX has non-zero chance of getting flagged by scans for offensive words that are run periodically).

Done!


Stability issue

Hej, I came throw a stability issue during the day. I don't know if this issue is from fortune or from the test framework. I am using this models
const user = {
    email: String,
    password: String,
    phone: String,
    avatar: String,
    role: String,
    customer: ['customer', 'users'],
};

const customer = {
    name: String,
    address: String,
    apikey: String,
    role: String,
    users: [Array('user'), 'customer'],
};

const adapter = [
    postgresAdapter, {
        url: `postgres://${config.get('DATABASE_USER')}:${config.get('DATABASE_PASSWORD')}@${config.get('DATABASE_HOST')}:${5432}/${config.get('DATABASE_NAME')}`,
        useForeignKeys: true,
        generatePrimaryKey: () => uuid.v4(),
    },
];

const store = fortune({
    // Put models here
    customer,
    user,
}, {
    adapter,
});

and mocha as a test framework. In my tests, the beforeEach hook cleans tables and inserts some data.
describe('/customers', function () {
  beforeEach(function () {
    return Promise.all([store.delete('customer'), store.delete('user')])
      .then(() => store.create('customer', {
        id: '0987654321234567890',
        name: 'Combain',
        address: 'Scheelevägen 15, 223 63 Lund',
        apikey: '01234567899876543210',
        role: 'admin',
      }))
      .then(() => store.create('user', {
        id: 'qwertyuioppoiuytrewq',
        customer: '0987654321234567890',
        email<EMAIL_ADDRESS>        password: 'demo',
        phone: 'demo',
        avatar: 'demo',
        role: 'admin',
      }));
  });

  describe('#GET', function () {
    it('should get all customers', function (done) {
      done();
    })
  });

  describe('Title 1', function () {
    it('name 1', function (done) {
      done();
    })
  });

  describe('Title "', function () {
    it('name 2', function (done) {
      done();
    })
  });

  describe('Title 3', function () {
    it('name 3', function (done) {
      done();
    })
  });
});

The first test is always working, but the second and third (and the others one) are not stable : they are working sometime (around 50%). I get this error from the beforeEach hook and as far as I understand the message, fortune is trying to reference a customer that does not exist.

BadRequestError: A related record for the field "customer" was not found.
at node_modules/fortune/lib/dispatch/check_links.js:59:29
at process._tickCallback (internal/process/next_tick.js:103:7)

I debugged it, an the customer is here (and in the database). And the tests are working sometimes. I'm thinking on a problem on the promises returned by fortune. Do you think it is a bug ?

The problem is not related to fortunejs but to Promise.all. See this thread for more details


No License

Hi, how are you? I have been looking at your code since around last November in 2016, and I would like to upload some of my own exercises which have been derived from a variety of your programs. The format would look similar to code academy and hacker rank. However, individuals would copy and paste the code that I upload, and fill in the blanks missing in the program in order to get it to work. Each uploaded code would basically function like a tutorial.
However, I have noticed that you do not have a license. This means that I am unable to use anything that has been derived from your code. I am writing to you hoping that you respond and that you allow me to upload code onto github that has been derived from your programs.
Thank you for your time.

Hi Stephens. I am good thank you. Please feel free to use my codes. That
will not be problem for me. Are you looking for teammate for your system ?
If yes, I would be happy to help you. Have nice day !
2017-02-13 23:27 GMT+03:00 JStephens33<EMAIL_ADDRESS>
Hi, how are you? I have been looking at your code since around last
November in 2016, and I would like to upload some of my own exercises which
have been derived from a variety of your programs. The format would look
similar to code academy and hacker rank. However, individuals would copy
and paste the code that I upload, and fill in the blanks missing in the
program in order to get it to work. Each uploaded code would basically
function like a tutorial.
However, I have noticed that you do not have a license. This means that I
am unable to use anything that has been derived from your code. I am
writing to you hoping that you respond and that you allow me to upload code
onto github that has been derived from your programs.
Thank you for your time.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/jsquared21/Intro-to-Java-Programming/issues/8, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AT4OrHPnurjufkDxIyVLV4V8ofukXsZSks5rcLzKgaJpZM4L_rqw
.

Hi, I am good. I have added a MIT License to my repo. Please feel free to use my code.


i think that someone stole your code

https://github.com/the-deepnet/ddos
see this

it looks like this guy really stole the idea and code 1 in 1

it looks like this guy really stole the idea and code 1 in 1

I Agree he is skid the main topic where is MHPRODEV

So yeah Steal version has no credit.
that is bad bro.


GEOMESA-2251 Kafka - event time

[ ] TODO needs support for initial bulk load by event time

tests are failing...

need to update the docs with the new config option too

replacing this with https://github.com/locationtech/geomesa/pull/1956


[markdown] cell interpretation online for Notebooks

feature to view markdown cell as you type.
a good extantion that does this for .md files is markdown-all-in-one

I believe this is either asking for a wysiwyg editor for markdown cells or a side by side preview while writing the cell. Closing this as I  believe both cases are out of scope for VS Code core at this time


Translation of 'set channel to' block to Polski

Describe the bug
Translation of 'set channel to' block to Polski doesn't display an input space instead it shows %!
To Reproduce
Steps to reproduce the behavior:

Go to Open Roberta Lab
Use Calliope mini or micro:bit
Go to Extended Blocks (Click on the number 2)
Go to messages, use "set channel to" block
Change language to Polski

Expected behavior

The "set channel to" block should display a space for an input parameter like with the English language

Screenshots

Issue in Polski:

Expected reference in English:

Device information

Type Desktop
OS: Ubuntu 22.04.3 LTS
Browser: Chrome Version 120.0.6099.224 (Official Build) (64-bit)

resolved


$relatedQuery().insert() race condition

return SomeTable
                .query()
                .select(...)
                .limit(1)
                .first()
                .then((someTable) => {
                    return someTable
                        .$relatedQuery('values')
                        .delete()
                        .then(() => Promise.map(someTableValues, (someTableValue) =>
                            someTable
                                .$relatedQuery('values')
                                .insert(someTableValue))
                });

The query runs in mysql which doesn't support batch insert so I'll have to manually map over the object and add it as a $relatedQuery. It works fine if I try to insert a single element, because it will assign that newly created element to the values array. But if there are multiple elements added, each of them will overwrite the current values array, therefore I'm going to end up with a single element in my array.
I will end up with a single element array in the someTable instance. Is there a way to work around this problem without refetching the data?

Maybe this:
SomeTable
  .query()
  .limit(1)
  .first()
  .then(someTable => {
    return someTable.$relatedQuery('values').delete().then(() => {
      return someTable.$relatedQuery('values').insertGraph(someTableValues);
    });
  });

? Don't know if it works. If it doesn't, you can always just manually assign the return value of the Promise.map operation to someTable.values.
This would get fixed with #323.

manually assigning is not good enough because .toJSON breaks in that case. I'd have to manually convert each of them to json.

You are doing something wrong. There is absolutely no magic in what relatedQuery.insert does with the models. All it does is assign them to the property named after the relation. If you have a relation named foo and you assign a model (or a list of models) to a property foo toJSON will get called for them also. If you really have a problem with this, please post a code snippet that reproduces the bug.

Closing due to lack of activity. Please reopen if the problem remains.


[Bug Report] The preview item does not show custommodeldata

Describe the bug
If you give yourself the following item /give @p gold_nugget{CustomModelData:2} 1
(My resourcepack does have a gold_nugget custommodeldata on 2, the first picture shows this)
And add it to the crate by holding it in your hand and using the command /cc additem testcrate 7
The item is added to the crate and the custommodeldata meta data is present in the configuration. But the crate preview does not show the item with the custom model.
If a player wins the price, the item given to the player does have and show the custom model.
Versions (please complete the following information):

Minecraft Server Version: 1.19
Plugin Version: 1.10.5 3 (This also happens in 1.10.3)

Pastebin any errors in console
There is no errors in the console.
Screenshots

Item:# - Try this.


RDKDEV-253: WebkitBrowser changes sync up from metro version to rdkservices repo

Looks good to me. Please cherry-pick to sprint/2203 as well.

Sure. I waiting for the merge of one the previous dependent PR from Pradeepta. Will do after that :)


Add Flutter to Existing App Fails, Flutter Tools Generates Incorrect Files

The generated files created by Flutter Tooling do not work.
https://github.com/flutter/flutter/wiki/Add-Flutter-to-existing-apps
View sample project here -> https://github.com/searchy2/FlutterAndroid
Steps to Reproduce

Create new Android project using Kotlin and targeting SDK v28.
Follow the steps at "Add Flutter to existing apps"
Build project. Flutter tooling generates .android files.
Generated files cannot find android packages.

I think the issue is the generated Flutter build.gradle doesn't match the packages used by the generated files.
Flutter.java and FlutterFragment.java use android.arch.lifecycle components and the android.support.annotation package.

The generated build.gradle file does not import the correct packages.

So the package imports aren't found because the Android project uses AndroidX.

Manually changing the imports to
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

Let the project successfully compile.

Hmm, it seems that sometimes the files get regenerated and overwritten. The only way to continue working is to save a backup and apply the changes everytime the generated files get overwritten.

Closing to open a new ticket later requesting update to AndroidX or a way to match the generated files with the version the project is using or not overwrite generated files at all.


Apply the current stable Rustfmt to the whole code base.

Also check formatting as part of CI runs to avoid future changes that
would lead to large reformatting again.

This one will need to be redone since the merging of the other PRs.

This one will need to be redone since the merging of the other PRs.

Rebased onto current master.

Thanks!


Translate windows waitlist

Task/Issue URL:
Description
Steps to test this PR
Feature 1

[ ]
[ ]

UI changes

Before
After

!(Upload before screenshot)
(Upload after screenshot)

Current dependencies on/for this PR:

develop

PR #2897   👈

This comment was auto-generated by Graphite.


new versions not compiling

Describe your bug here.
when i run lime test windows it says something about the song.hx having characters in the wrong spots and when that stops it says the characters are broken
Command Prompt/Terminal logs (if existing)
No response
Are you modding a build from source or with Lua?
Source
What is your build target?
Windows
Did you edit anything in this build? If so, mention or summarize your changes.
no i did nothing to the code and didnt even add a file

UPDATE HAXE 4.2.4

@ShadowMario

will still be able to use 04.2?

will still be able to use 04.2?

yes

See my answer in #2724.

Update your Haxehttps://haxe.org/ to 4.2.4!


CMake cannot find target "unofficial::sqlite3::sqlite3" when using port oatpp::oatpp-sqlite

Describe the bug
CMake cannot find target "unofficial::sqlite3::sqlite3" when using port oatpp::oatpp-sqlite.
Environment

OS: Windows 11
Compiler: Visual Studio 2022 17.7.6

To Reproduce
Steps to reproduce the behavior:
Create a CMake project with a vcpkg manifest that specifies "oatpp::oatpp-sqlite" as a dependency.
Configure the project.
Example: https://github.com/oatpp/example-crud
Expected behavior
CMake finds unofficial::sqlite3::sqlite3.
Failure logs
1> [CMake]   The link interface of target "oatpp::oatpp-sqlite" contains:
1> [CMake]
1> [CMake]     unofficial::sqlite3::sqlite3
1> [CMake]
1> [CMake]   but the target was not found.  Possible reasons include:
1> [CMake]
1> [CMake]     * There is a typo in the target name.
1> [CMake]     * A find_package call is missing for an IMPORTED target.
1> [CMake]     * An ALIAS target is missing.
1> [CMake]
1> [CMake] Call Stack (most recent call first):
1> [CMake]   C:/dev/vcpkg/installed/x64-windows/share/oatpp-sqlite/oatpp-sqliteConfig.cmake:18 (include)
1> [CMake]   C:/dev/vcpkg/scripts/buildsystems/vcpkg.cmake:859 (_find_package)
1> [CMake]   CMakeLists.txt:30 (find_package)
1> [CMake] -- Generating done (0.0s)
1> [CMake] CMake Generate step failed.  Build files cannot be regenerated correctly.

@Brouilles, Thanks for posting this issue, this issue could be reproduced with vcpkg 2023-11-16-4c1df40a3c5c5e18de299a99e9accb03c2a82e1e and VS2022 17.6.6


Release for django 2.0.8

It's been a while since you tagged a new version for release.  Can you please tag/package a release for django 2.0.8 at this commit? https://github.com/pydanny/cookiecutter-django/commit/36f3558ccc934e19ba54cfe16c92abb5d720b5bd

Good question - I don't remember why there.  Looks like the most recent version should be fine and the build failed on the commit I pointed to...

I've tagged all the recent commits to when we updated the Django version. The latest commit is also tagged to 2.0.8-01.


Corrections to help screen text

Additionally a few changes to the operations/attributes:
clone restore -> clone recreate
print-licences -> print-licenses
--accept-agreements -> --accept-license-agreements

@honza-kasik FYI a few changes to the operations/attribute names suggested in the review (see in prospero-cli/src/main/java/org/wildfly/prospero/cli/commands/CliConstants.java)

@yersan I don't think of this changes affect the Wildfly integration, but could you take a quick look?

Hi @spyrkob, the integration doesn't use the help pages or output generated by Prospero, so we should be fine with this.

Yes, right @spyrkob , I confirm we are not using those commands


Automated cherry pick of #1038: fix imported bm server start

Cherry pick of #1038 on release/2.9.0.
#1038: fix imported bm server start

Codecov Report

:exclamation: No coverage uploaded for pull request base (release/2.9.0@f491a57). Click here to learn what that means.
The diff coverage is 0%.

@@               Coverage Diff               @@
##             release/2.9.0   #1040   +/-   ##
===============================================
  Coverage                 ?   7.67%
===============================================
  Files                    ?     334
  Lines                    ?   53710
  Branches                 ?       0
===============================================
  Hits                     ?    4122
  Misses                   ?   49210
  Partials                 ?     378

Flag
Coverage Δ

#aFlag
7.67% <0%> (?)

Impacted Files
Coverage Δ

pkg/compute/models/guests.go
0.66% <0%> (ø)

Continue to review full report at Codecov.

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

/lgtm
/approve


First layer of model output always has 0 on all the indices

First layer of model output always has 0 on all the indices when I do model.predict(input). I get the training accuracy of 0.99 but when I use predict function it outputs all 0s in predicted sequence. Please guide

I can't figure out it's the problem of CRF layer or your model/data according to your description.
Could you please offer a simple test code.

I can't figure out it's the problem of CRF layer or your model/data according to your description.
Could you please offer a simple test code.


How to Use laravel Echo with a Decoupled Laravel and Nuxt

On the Documentation of Laravel Echo, we need the csrf token
Any Help with this?
First Question if disbling csrf token , the best choice?
Or We need to make an endpoint to fetch on the initial page load
The Csrf token and simply add it to your store...
I wanna here your reaction to this approach... and ho w you would do it on your SSR version that is decoupled laravel and nuxt

I don't think you need a csrf token since you're using jwt for authentication.


Read .env files

Buffalo takes advantage of .env files that exist in the working directory. buffalo-azure currently ignores those values.
As part of init(), buffalo-azure should override existing environment variables with the ones found in the .env file.

For reference, Buffalo use envy for this.


scaleway-cli: init at v1.14

Utility to manage scaleway servers

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

[x] NixOS
[ ] macOS
[ ] Linux

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

Thanks!


Add screen sharing

Add a screen sharing example which uses the new (as of yet unreleased) screen sharing APIs for Chrome.

This should not be merged until the related changes to Respoke.js get deployed.

LGTM :+1:

Same here.
Only thing that held me up running it locally was knowing to use HTTPS. I
couldn't figure out why nothing worked......So we certainly should make
that part apparent IMHO!
On Thu, Jan 22, 2015 at 11:23 AM, Chad McElligott<EMAIL_ADDRESS>wrote:

LGTM [image: :+1:]
—
Reply to this email directly or view it on GitHub
https://github.com/respoke/web-examples/pull/6#issuecomment-71081280.

--
Phone: +1-916-801-6693
Skype: jeffhparrish
Hangouts<EMAIL_ADDRESS>

Hmm. It looks like https://respoke.github.io/web-examples/ redirects to non-SSL.

@erinspice that link doesn't redirect for me, i stay SSL'd

Ship It!

Oh, strange. I must have made a mistake yesterday. It is also redirecting for me. Great!


Feature: Approximate 1Q synthesis

cc @levbishop , @1ucian0
Summary
This (draft) PR synthesizes 1Q operators up to approximation. Aside from inherent utility, I hope that this stems the warnings reported in #7033 and #7042. This carries on (though in a different direction) from Lev's comment.
Details and comments
The changed regions of code are:

_circuit_psx_gen takes (optional) fidelity estimates for the circuit generated by xfun and xpifun and selects a circuit from a few templates based on best approximation + fidelity distance from the target + operational cost.
The _circuit_* wrappers take an (optional) fidelity_mapping argument which reports fidelity estimates for operations appearing on the relevant qubit. ~At the moment, this is a Callable so that I can bind the qubit index in the backend property lookup, but passing around anonymous lambdas is not totally desirable.~ At the moment, this takes the form of a defaultdict, typically populated from whatever BackendProperties is around.
Optimize1qGatesDecomposition receives a BackendProperties object and threads that information through to the decomposition calls.
When checking whether the returned synthesis is worse than the synthesis already prepared, it compares the two fidelity costs rather than gate count (except in degenerate cases, e.g., when no error info is available).

Some missing features are:

I haven't installed the initial couple of pipes (e.g., in the default pass manager constructors) which provide the backend property objects to the 1Q synthesis passes. Without these, the 'default' synthesis route proceeds functionally as before, without considering the per-gate cost of the steps in a 1Q circuit, with some vague preference for shorter strings when they're available.
It's mildly (but not completely) undertested.

I would particularly appreciate comments on:

The data flow which pipes the relevant error metrics down to the synthesis routine feels clumsy to me.
I avoided installing the generic 'approximation' knob present in the cousin 2Q synthesis routines, which may or may not have been a good idea. As written, this PR explicitly assumes that the error rates reported are average gate fidelities, which is a stronger assumption than promised by the backend, and without which I'm not sure this really suffices to mute the warning.

As written, this comes with significant performance degradation. I haven't run asv, but here's stestr run on main:
Ran: 11510 tests in 288.6423 sec.
 - Passed: 11422
 - Skipped: 81
 - Expected Fail: 0
 - Unexpected Success: 0
 - Failed: 7
Sum of execute time for each test: 1840.2396 sec.

versus on this branch:
Ran: 11411 tests in 575.9220 sec.
 - Passed: 11328
 - Skipped: 81
 - Expected Fail: 0
 - Unexpected Success: 0
 - Failed: 2
Sum of execute time for each test: 3376.0384 sec.

Not great.

As written, this comes with significant performance degradation. I haven't run asv, but here's stestr run on main:

Ouch.

As of bfba8b5, this is now
Ran: 11411 tests in 352.9015 sec.
Sum of execute time for each test: 2258.7966 sec.

which is still noticeably worse, but perhaps tolerably so.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

114 of 125 (91.2%)  changed or added relevant lines in 3 files are covered.
5 unchanged lines in 2 files lost coverage.
Overall coverage decreased (-0.003%) to 82.378%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

qiskit/quantum_info/synthesis/one_qubit_decompose.py
50
51
98.04%

qiskit/transpiler/passes/optimization/optimize_1q_decomposition.py
61
71
85.92%

Files with Coverage Reduction
New Missed Lines
%

qiskit/extensions/quantum_initializer/uc.py
2
88.65%

qiskit/pulse/library/waveform.py
3
90.38%

Totals

Change from base Build<PHONE_NUMBER>:
-0.003%

Covered Lines:
49721

Relevant Lines:
60357

💛  - Coveralls

@javabster My employer's attention is elsewhere, so I am no longer working on this. :) The main outstanding thread of work was some performance degradation, but who knows how the code has drifted in the intervening 18mo.

Thanks for letting us know @ecpeterson, I'll close this PR but if you'd like to return to it at a later date just let us know and we can reopen


update README.md

Current coverage is 76.37%

Merging #161 into master will not affect coverage as of 15ec218

@@            master    #161   diff @@
======================================
  Files           26      26
  Stmts          381     381
  Branches         0       0
  Methods         83      83
======================================
  Hit            291     291
  Partial          0       0
  Missed          90      90

Review entire Coverage Diff as of 15ec218

Powered by Codecov. Updated on successful CI builds.


Pyperclip not working in Win10 Python 3.5.3

Big fan of your book, by the way! But regarding Pyperclip -
Pyperclip installs fine. Copies OK to the Win clipboard. BUT --
When I try to paste anything FROM the clipboard, whether copied from within Pyperclip or from within Win, as in:
pyperclip.paste()
I get this:
'<function init_windows_clipboard..paste_windows at 0x000002CD1B289400>'
This is not quite what I need. Do you have any suggestions? I really do need to get this working.

Are you sure you're including the brackets in pyperclip.paste()?
I get a similar output if I omit the brackets pyperclip.paste, but it works fine with brackets.

@heliophagus, check out @ghost response.  That's not an error message, it's the correct response from Python if parenthesis aren't included at the end of the function.  When used without parenthesis, the response you get is the representation of pyperclip.paste as an object.
Regardless, I made a Python 3.5.3 conda environment to test this just to verify, and pyperclip.paste() works as intended.

simple workaround
i am having problem with pyperclip.paste() too
import pyautogui
import pyperclip
'x' 'y' coordinates of mouse
pyautogui.click(x=1755, y=673, duration = 1)
copying text to clipboard
pyperclip.copy('github.com')
now paste it
pyautogui.hotkey('ctrl', 'v')

i am having problem with pyperclip.paste() too


Issue encrypting on iOS then decrypting on PHP

Hi I'm having a problem when encrypting my data on iPhone then decrypting it on PHP. My iPhone code throws no errors and neither does my PHP, but when I put them together, it throws out a bunch of errors. I used a wrapper class to encrypt because using the kRNCryptorAES256Settings constant threw a bunch of errors for me.
Here's my encryption code:
var myMessage = "This is my top secret message!"
let myPassword = "cool"
let myData = myMessage.dataUsingEncoding(NSUTF8StringEncoding, allowLossyConversion: false)!
let eData = ACEncryptor.encryptData(myData, password: myPassword, error: nil)

//Send to server
Decryption code:
require DIR.'/autoload.php';
$aes = new \RNCryptor\Decryptor();
$data = $aes->decrypt($eData, $password);
The error that the php throws out is below. It returned it in the terminal of my app so there are a lot of html tags.

Fatal error:  Uncaught exception 'Exception' with message 'Unsupported schema version 211' in /home/u350976909/public_html/lib/RNCryptor/Cryptor.php:70
Stack trace:
#0 /home/u350976909/public_html/lib/RNCryptor/Decryptor.php(66): RNCryptor\Cryptor->_configureSettings(211)
#1 /home/u350976909/public_html/lib/RNCryptor/Decryptor.php(49): RNCryptor\Decryptor->_parseHeaders('\xD3}5\xD7V\xF4s\xBD\x9B\xE9\xB6\xFC\xDD\xEE\xFA...')
#2 /home/u350976909/public_html/lib/RNCryptor/Decryptor.php(22): RNCryptor\Decryptor->_unpackEncryptedBase64Data('<030111b0 c72b6...')
#3 /home/u350976909/public_html/Decrypt.php(62): RNCryptor\Decryptor->decrypt('<030111b0 c72b6...', 'cool')
#4 {main}
  thrown in /home/u350976909/public_html/lib/RNCryptor/Cryptor.php on line 70
Thanks in advance!

Looks like your message is corrupt. You need to make sure that you're decrypting exactly the output of the encryptor. The common mistake is to fail to correctly convert between data and base64 encoded strings.

On Jun 23, 2015, at 2:07 AM, ad1269<EMAIL_ADDRESS>wrote:
Hi I'm having a problem when encrypting my data on iPhone then decrypting it on PHP. My iPhone code throws no errors and neither does my PHP, but when I put them together, it throws out a bunch of errors. I used a wrapper class to encrypt because using the kRNCryptorAES256Settings constant threw a bunch of errors for me.
Here's my encryption code:
var myMessage = "This is my top secret message!"
let myPassword = "cool"
let myData = myMessage.dataUsingEncoding(NSUTF8StringEncoding, allowLossyConversion: false)!
let eData = ACEncryptor.encryptData(myData, password: myPassword, error: nil)
//Send to server
Decryption code:
require DIR.'/autoload.php';
$aes = new \RNCryptor\Decryptor();
$data = $aes->decrypt($eData, $password);
The error that the php throws out is below. It returned it in the terminal of my app so there are a lot of html tags.
Fatal error: Uncaught exception 'Exception' with message 'Unsupported schema version 211' in /home/u350976909/public_html/lib/RNCryptor/Cryptor.php:70
Stack trace:
#0 /home/u350976909/public_html/lib/RNCryptor/Decryptor.php(66): RNCryptor\Cryptor->_configureSettings(211)
#1 /home/u350976909/public_html/lib/RNCryptor/Decryptor.php(49): RNCryptor\Decryptor->_parseHeaders('\xD3}5\xD7V\xF4s\xBD\x9B\xE9\xB6\xFC\xDD\xEE\xFA...')
#2 /home/u350976909/public_html/lib/RNCryptor/Decryptor.php(22): RNCryptor\Decryptor->_unpackEncryptedBase64Data('<030111b0 c72b6...')
#3 /home/u350976909/public_html/Decrypt.php(62): RNCryptor\Decryptor->decrypt('<030111b0 c72b6...', 'cool')
#4 {main}
thrown in /home/u350976909/public_html/lib/RNCryptor/Cryptor.php on line 70
Thanks in advance!
—
Reply to this email directly or view it on GitHub.

Oh! I didn't realize that I forgot to convert my data to a base64 encoded string before sending it to the server! I added this line:
let eStr = eData.base64EncodedStringWithOptions(NSDataBase64EncodingOptions(0))
and it now works. Thank you!


added object type for array

Proposed changes
Added object(ignored) type for array. Fix for issue #147
Types of changes
What types of changes does your code introduce to the project: Put
an x in the boxes that apply

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

Checklist
Put an x in the boxes that apply. You can also fill these out after
creating the PR. If you're unsure about any of them, don't hesitate to
ask. We're here to help! This is simply a reminder of what we are going
to look for before merging your code.

[x] I have read the CONTRIBUTING doc
[x] I have signed the CLA
[ ] I have added tests that prove my fix is effective or that my
feature works
[ ] I have added necessary documentation (if appropriate)
[ ] Any dependent changes have been merged and published in
downstream modules

Further comments
If this is a relatively large or complex change, kick off the discussion
by explaining why you chose the solution you did and what alternatives
you considered, etc...

@c0c0n3 @chicco785 Please confirm about the changes. Does it fits our need or I need to look into other approach.
I tried to fix failing test cases but unable to do so. I will update the test cases after changes are confirmed and CircleCI issue is fixed.

@pooja1pathak please also add tests and update the changelog. many thanks.

the new type breaks something in the code

the new type breaks something in the code

Yes, I am looking into it. I'll update once I fix this


Update README to add aws s3 reference

Current coverage is 64.65% (diff: 100%)

Merging #19 into master will not change coverage

@@             master        #19   diff @@
==========================================
  Files             5          5
  Lines           365        365
  Methods           0          0
  Messages          0          0
  Branches          0          0
==========================================
  Hits            236        236
  Misses           90         90
  Partials         39         39

Powered by Codecov. Last update 43be4b2...6509cc5


daemon/k8s: fix k8s API watched status report

In case of an error when setting up the CRD, cilium status would wrongly
present as it was watching CRD resources.
Signed-off-by: André Martins<EMAIL_ADDRESS>Related with https://github.com/cilium/cilium/issues/3093
Fix wrong cilium status of k8s CRD watcher in case of an error when setting up the CRD client

test-me-please


EE-1105: auction: remove Delegators map

Ref: https://casperlabs.atlassian.net/browse/EE-1105
This PR removes the Delegators map stored at DELEGATORS_KEY.
IMPORTANT:
This PR depends on #517.  Please review the diff here: https://github.com/henrytill/casper-node/compare/EE-1101+1103...henrytill:EE-1105

bors r+


Authentication issues with PCF

When deploying with BOSH:
Ferdy, the manage link is not working. One thing I noticed is that the manifest refers to it to cf-containers-broker.<root_domain>, but I could not find a job step that actually creates a route on PCF.
So this ends on the route never being found. I tried to replace it by the broker ip (and that's how I registered it), but after being challenged by PCF (1.2.0) auth screen, it redirects back to the console application. I can't reach the manage endpoint.
I guess I could break this into two "mini issues"

Auth issues
How to register the broker application with cf

Regards

Added some comments about how the route is registered at https://github.com/cf-platform-eng/cf-containers-broker/commit/59b666b55629cdbd6a04a15394c820cd8a9c2a89.


Repeated important note removal from Live Events in limits-specifications-teams.md

Closes https://github.com/MicrosoftDocs/OfficeDocs-SkypeForBusiness/issues/7247.
I agree. This important note appears twice in the article. Let's leave it only in the Live Events section.
@Larryngolog Do you agree? I see that you requested the addition to this section 1 year ago. Thanks!

@JohanFreelancer9 Copy editing is needed for this PR. Thanks.

@SerdarSoysal PR has been copyedited and is ready for final review, could you please check and merge? Thanks!


WSL: libcuda.so: cannot open shared object file

Hello, I'm on a completely fresh Windows Subsystem for Linux with CUDA support installation of Ubuntu. What I've done so far:

Installed MiniForge/Conda
Made a new env in a folder
Ran conda install cudatoolkit
Pip installed pytorch, transformers, accelerate, and bitsandbytes
Attempted to run the HF Pipeline demo with 8 bit quant enabled.

When running a model, I get the following error:
CUDA SETUP: CUDA runtime path found: /home/zaptrem/bigmodels/env/lib/libcudart.so
Traceback (most recent call last):
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/cuda_setup/main.py", line 57, in get_cuda_lib_handle
    cuda = ctypes.CDLL("libcuda.so")
  File "/home/zaptrem/bigmodels/env/lib/python3.8/ctypes/__init__.py", line 373, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: libcuda.so: cannot open shared object file: No such file or directory

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/utils/import_utils.py", line 1030, in _get_module
    return importlib.import_module("." + module_name, self.__name__)
  File "/home/zaptrem/bigmodels/env/lib/python3.8/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 843, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/models/bloom/modeling_bloom.py", line 34, in <module>
    from ...modeling_utils import PreTrainedModel
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/modeling_utils.py", line 88, in <module>
    from .utils.bitsandbytes import get_key_to_not_convert, replace_8bit_linear, set_module_8bit_tensor_to_device
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/utils/bitsandbytes.py", line 10, in <module>
    import bitsandbytes as bnb
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/__init__.py", line 6, in <module>
    from .autograd._functions import (
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/autograd/_functions.py", line 4, in <module>
    import bitsandbytes.functional as F
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/functional.py", line 14, in <module>
    from .cextension import COMPILED_WITH_CUDA, lib
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/cextension.py", line 41, in <module>
    lib = CUDALibrary_Singleton.get_instance().lib
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/cextension.py", line 37, in get_instance
    cls._instance.initialize()
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/cextension.py", line 15, in initialize
    binary_name = evaluate_cuda_setup()
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/cuda_setup/main.py", line 130, in evaluate_cuda_setup
    cuda = get_cuda_lib_handle()
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/bitsandbytes/cuda_setup/main.py", line 60, in get_cuda_lib_handle
    raise Exception('CUDA SETUP: ERROR! libcuda.so not found! Do you have a CUDA driver installed? If you are on a cluster, make sure you are on a CUDA machine!')
Exception: CUDA SETUP: ERROR! libcuda.so not found! Do you have a CUDA driver installed?

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "largemodels.py", line 25, in <module>
    pipe = pipeline(model=name, model_kwargs= {"device_map": "auto", "load_in_8bit": True}, max_new_tokens=max_new_tokens)
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/pipelines/__init__.py", line 676, in pipeline
    framework, model = infer_framework_load_model(
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/pipelines/base.py", line 229, in infer_framework_load_model
    _class = getattr(transformers_module, architecture, None)
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/utils/import_utils.py", line 1021, in __getattr__
    value = getattr(module, name)
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/utils/import_utils.py", line 1020, in __getattr__
    module = self._get_module(self._class_to_module[name])
  File "/home/zaptrem/bigmodels/env/lib/python3.8/site-packages/transformers/utils/import_utils.py", line 1032, in _get_module
    raise RuntimeError(
RuntimeError: Failed to import transformers.models.bloom.modeling_bloom because of the following error (look up to see its traceback):
CUDA SETUP: ERROR! libcuda.so not found! Do you have a CUDA driver installed?

Like I said before, I ensured this wasn't an environment issue by completely resetting the Linux environment. CUDA works fine otherwise.

Here is a workaround for the issue:
export LD_LIBRARY_PATH=/usr/lib/wsl/lib

Great !
Yes, you need to manually specify the LD_LIBRARY_PATH for some OS systems

Great ! Yes, you need to manually specify the LD_LIBRARY_PATH for some OS systems
I haven't found this to be necessary for PyTorch or any other libs that require CUDA. Do they use a superior lib detection mechanism bitsandbytes could adopt? Thanks!

I believe this issue is caused by a missing reference to the multi-arch path to the CUDA driver. You likely can solve the problem via calling sudo ldconfig. See here for more information.

I haven't found this to be necessary for PyTorch or any other libs that require CUDA. Do they use a superior lib detection mechanism bitsandbytes could adopt? Thanks!

Since we do an automatic detection of the right CUDA library at runtime, we check your CUDA compute capability during runtime via the CUDA driver. The automatic detection helps you to do a single install if you have multiple GPUs with different compute capabilities. But for this to work, the CUDA driver needs to be discoverable on a system which is not the case here. We are still figure out how to smooth these things out and errors like these will likely be fixed soon.

I believe this is fixed in the latest version. It prints instructions on how to debug the situation and alternatively prints out compilation instructions which should fix the issue.

I had no luck with exporting the variable, but I did manage to copy over the file from my tensorflow environment to my pytorch environment, which solved that problem, now.. onto other problems...
cp /home/me/miniconda3/envs/tf/lib/libcudart.so /home/me/miniconda3/envs/pytorch/lib/


EOS-21424: Cortx-HA conflicts with hax systemd unit

JIRA ticket: EOS-21424
Solution: when deploying via mini provisioner, Hare must update hax'
systemd unit so that the following statements get commented out:

Requires=
After=
Restart=

As per the ticket the 3-Node VM deployment was successful.
https://jts.seagate.com/browse/EOS-21424?focusedCommentId=2148376&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-2148376


Crash while duplicating layer

Crash while duplicating layer, removing previous layer, and renaming duplicated layer to previous layer
Stack:
LEd version: 0.5.0-beta
Missing layer instance for 21
Error

Log:
[WARNING]      Full render requested
[EVENT]        LevelResized
[WARNING]      All rules applied in Instance[#47,AutoLayer:AutoLayer]
[WARNING]      All rules applied in Instance[#21,Collisions:IntGrid]
[WARNING]      All rules applied in Instance[#89,Background:IntGrid]
[WARNING]      Full render requested
[EVENT]        LevelResized
[WARNING]      All rules applied in Instance[#47,AutoLayer:AutoLayer]
[WARNING]      All rules applied in Instance[#21,Collisions:IntGrid]
[WARNING]      All rules applied in Instance[#89,Background:IntGrid]
[WARNING]      Full render requested
[EVENT]        LevelResized
[WARNING]      All rules applied in Instance[#47,AutoLayer:AutoLayer]
[WARNING]      All rules applied in Instance[#21,Collisions:IntGrid]
[WARNING]      All rules applied in Instance[#89,Background:IntGrid]
[WARNING]      Full render requested
[FILE]         Reading HTML template editLayerDefs from cache
[EVENT]        LayerInstanceSelected
[RENDER]       Rendered bg
[EVENT]        LayerInstanceSelected
[RENDER]       Rendered bg
[TIDY]         Added missing layer instance Collisions2 in data.Level.FirstLevel(#22)
[TIDY]         Added missing layer instance Collisions2 in data.Level.DNFirstLevel(#0)
[GENERAL]      "Updating auto-layers...", 2 operation(s):
[GENERAL]        - FirstLevel.Collisions2 (50%)
[EVENT]        LayerDefAdded
[WARNING]      All rules applied in Instance[#101,Collisions2:IntGrid]
[GENERAL]        - DNFirstLevel.Collisions2 (100%)
[WARNING]      All rules applied in Instance[#101,Collisions2:IntGrid]
[EVENT]        LayerInstanceSelected
[RENDER]       Rendered bg
[EVENT]        LayerInstanceSelected
[RENDER]       Rendered bg
[EVENT]        LayerInstanceSelected
[RENDER]       Rendered bg
[EVENT]        LayerInstanceSelected
[RENDER]       Rendered bg
[WARNING]      Last chance for: Layer Collisions deleted
[TIDY]         Removed lost layer instance in data.Level.FirstLevel(#22)
[TIDY]         Removed lost layer instance in data.Level.DNFirstLevel(#0)
[EVENT]        LayerInstanceSelected
[EVENT]        LayerDefRemoved
[RENDER]       Rendered bg
[EVENT]        LayerInstanceSelected
[RENDER]       Rendered bg
[EVENT]        LayerDefChanged
[FILE]         Loading HTML template crash
[ERROR]        Missing layer instance for 21 (Error)
[ERROR]        undefined)

I see the problem 🤔  It's because you have an Auto layer that uses the deleted IntGrid layer as source for its int values.
I'll support this kind of operation in 0.5.0 . I'll try to push the update asap :)

Fixed in 0.5.0 (not released yet)


If ":finally" failure mode configured incorrectly then "FailureMode.Retry" will retry forever

In my case :finally had invalid configuration: finally: Honeydew.FailureMode.Move and this led to an interesting behaviour when honeydew tried to retry job forever. I had log entries like this:
..retrying 0 more times, job: %Honeydew.Job{...}
and then
..retrying -1 more times, job: %Honeydew.Job{...}
..retrying -2 more times, job: %Honeydew.Job{...}
and so on.

hey @dkataskin, thanks for the bug report.
try out version 1.0.4, it'll validate failure mode arguments to prevent that from happening again.
let me know how it works for you. :)


Fix missing underscore

See here

Sorry, this would be my first PR...  ;-)
I pushed to master in my fork of your repo, but of course I forgot to pull in your changes first, so I have an extra merge commit on top of the actual (single-character) fix commit.... Would you mind giving me some hints of how to remedy this?
Do I need to undo the last commit in my fork? And then start again making sure I first pull your changes first?

Sorry, this would be my first PR... ;-)

All good - figured I'd make the suggestion and see if you'd done a rebase before or if you wanted some help with it :-)

I pushed to master in my fork of your repo, but of course I forgot to pull in your changes first

Super common when starting out - not something to worry about :-)

Do I need to undo the last commit in my fork? And then start again making sure I first pull your changes first?

Normally it's best to make any changes/fixes in a new branch, and keep any branches from the project you've forked clean/use them to track changes in the original project. That makes it easier to restart things if you need to, but also means it's a bit easier for you to start separate branches from a clean branching point rather than basing them off other changes you may not have finalised yet.
Regardless, to fix the current situation you can use an interactive rebase to rewrite/modify your history. Assuming you're using git from the command-line,

git pull the latest changes (since you did the merge in github)

then run git rebase -i HEAD~2 to interactively rebase from 2 commits before your current state(HEAD). That will then bring up a window showing the changes from those commits, e.g.:
pick c2be7fe fix missing underscore in OpenCVSource.get()
pick 1255eb1 vidIO: improve timestamp clarity
pick 3a120ac README: add Contributors section

# ... a bunch of instructions on what can be done in a rebase

You want to move your commit down to the bottom so it's the most recent one, e.g.
pick 1255eb1 vidIO: improve timestamp clarity
pick 3a120ac README: add Contributors section
pick c2be7fe fix missing underscore in OpenCVSource.get()

# ...

If your rebase is happening in vim (generally the default), navigate with your arrow keys to the line with your commit, then press dd (d, twice) to cut that line, then move the cursor down to the line with the latest commit, and press p to paste (automatically on the next line below). Then to confirm type the command :wq (: -> 'command', w -> 'write', q -> quit), and press Enter.

Once the rebase is complete, you'll need to push the changes back up to your github repo, but in this case because you've changed the history you'll need to "force" the push (git push --force).
As a note, force pushing is generally bad practice once others are using the code, but since this is your own fork and in a pull request it's fine (although as before it's preferable if this kind of thing happens in its own branch)

Once changes have been pushed to the branch your pull request originates from, they should automatically show up here :-)

Wow, thanks for this detailed explanation. I'll do it as soon as I have the
opportunity. It's a little busy atm.
I assumed that in order to be able (at least using the auto mechanism in
github) to create pull requests in upstream repositories, I'd need to
commit to branches that exist in the upstream. So the idea is?:

work with new branches within my fork
when done, pull newest upstream changes
3a) rebase (or merge, based on the wishes of the maintainer) the changes
from the new branch on top of my fork's master (or other branch that exists
upstream) and create PR

OR?
3b) push the new branch to my fork and create PR for the upstream branch
directly from this new branch (is it possible?)
Note, that I don't want to steal your time, so no worries if you don't want
to waste it on me. I'll figure it out eventually...
ES-Alexander @.***> schrieb am Mi., 17. Nov. 2021,
09:43:

Sorry, this would be my first PR... ;-)
All good - figured I'd make the suggestion and see if you'd done a rebase
before or if you wanted some help with it :-)
I pushed to master in my fork of your repo, but of course I forgot to pull
in your changes first
Super common when starting out - not something to worry about :-)
Do I need to undo the last commit in my fork? And then start again making
sure I first pull your changes first?
Normally it's best to make any changes/fixes in a new branch, and keep any
branches from the project you've forked clean/use them to track changes in
the original project. That makes it easier to restart things if you need
to, but also means it's a bit easier for you to start separate branches
from a clean branching point rather than basing them off other changes you
may not have finalised yet.
Regardless, to fix the current situation you can use an interactive rebase
to rewrite/modify your history. Assuming you're using git from the
command-line,

git pull the latest changes (since you did the merge in github)
2.
then run git rebase -i HEAD~2 to interactively rebase from 2
commits before your current state(HEAD). That will then bring up a window
showing the changes from those commits, e.g.:
pick c2be7fe fix missing underscore in OpenCVSource.get()
pick 1255eb1 vidIO: improve timestamp clarity
pick 3a120ac README: add Contributors section
... a bunch of instructions on what can be done in a rebase

You want to move your commit down to the bottom so it's the most
recent one, e.g.
pick 1255eb1 vidIO: improve timestamp clarity
pick 3a120ac README: add Contributors section
pick c2be7fe fix missing underscore in OpenCVSource.get()
...
If your rebase is happening in vim (generally the default), navigate
with your arrow keys to the line with your commit, then press dd (d,
twice) to cut that line, then move the cursor down to the line with the
latest commit, and press p to paste (automatically on the next line
below). Then to confirm type the command :wq (: -> 'command', w ->
'write', q -> quit), and press Enter.
4.
Once the rebase is complete, you'll need to push the changes back up
to your github repo, but in this case because you've changed the history
you'll need to "force" the push (git push --force).
As a note, force pushing is generally bad practice once others are
using the code, but since this is your own fork and in a pull request it's
fine (although as before it's preferable if this kind of thing happens in
its own branch)
Once changes have been pushed to the branch your pull request originates
from, they should automatically show up here :-)
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/ES-Alexander/pythonic-cv/pull/20#issuecomment-971359375,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ADS4QMUJIO7QMIIXOJTXM2DUMNTKVANCNFSM5H2DOXXQ
.


Chore fix type issues

This PR provides a first batch of type fixes (see #929, "pyright" section). I will follow up with a further issue about the outstanding issues that I could not figure put how to fix without a better understanding of the current behavior.

Codecov Report

Merging #1139 (d66da8a) into master (f969d39) will decrease coverage by 2.18%.
The diff coverage is 49.40%.

Additional details and impacted files

Flag
Coverage Δ

packit-e2e
69.94% <40.49%> (-2.47%)
:arrow_down:

testsuite
53.62% <33.33%> (-0.52%)
:arrow_down:

unittests
14.65% <13.09%> (+0.04%)
:arrow_up:

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

Impacted Files
Coverage Δ

keylime/backport_dataclasses.py
0.00% <0.00%> (ø)

keylime/ca_impl_openssl.py
93.65% <0.00%> (ø)

keylime/common/cli_opts.py
0.00% <0.00%> (ø)

keylime/config.py
75.94% <0.00%> (ø)

keylime/revocation_actions/update_crl.py
0.00% <0.00%> (ø)

keylime/tpm_bootlog_enrich.py
37.59% <0.00%> (-0.29%)
:arrow_down:

keylime/api_version.py
85.18% <11.11%> (-10.65%)
:arrow_down:

keylime/ima/ima.py
67.51% <25.00%> (-4.37%)
:arrow_down:

keylime/cloud_verifier_common.py
68.53% <33.33%> (-11.89%)
:arrow_down:

keylime/cloud_verifier_tornado.py
59.67% <33.33%> (-7.51%)
:arrow_down:

... and 28 more

@mdrocco can you do a clean rebase on master, this makes it easier to review?

I merged master into the branch, let me know it that works.

/packit retest-failed

@THS-on I rebased on master and squashed, as I screwed up with commit signatures, let me know if you have concerns with that. I will now move to debugging what I broke with those type "fixes".

Thanks for checking, I changed the author.

/packit retest-failed

My general suggestion would be to split this PR up into many small easy-to-digest patches and PRs. There are some things that could go in very easily (changes in crypto.py for example) and others may not be so easy to digest...

Sure, let us split the PR. Can you please mark the not-so-easy-to-digest changes? This would also help isolating what is making CI tests fail. Thanks!

It looks like there are many different types of changes bunched together in this PR. I would split it by individual types of changes.

This would also help isolating what is making CI tests fail

For that I would rebase on master.

Thanks @stefanberger for the thorough review, I will rebase on master.

closing as split into #1164 #1173 #1180


ADD Loadn and Grant page

as of now clicking on the button takes us no where i propoise to add a page dedicated o loans and grants
hey @Vin205 please assign me this task

@shubhagarwal1 ASSIGNED! LONE PAGE ALREADY EXIST PLEASE LINK IT UPDATE IT IF YOU WANT!


Feat/support weights passed from dataframe

I'll copy what I said in Discord

I think we shouldn't use weights, since that would make it easy to game the metrics just by choosing some oddly specific weighting function.
And the value of logloss would become essentially arbitrary since it depends on the choice of the weighting function
That being said, I do see a good usecase for this - finally making a proper "Ignore reviews before"
By setting weights for all reviews before a selected date to 0
In that case, the weights would have to be passed to RMSE as well, not just to logloss

I think we shouldn't use weights, since that would make it easy to game the metrics just by choosing some oddly specific weighting function.

The PR doesn't game the metrics. The weights are used for the optimization. In the evaluation, all reviews' weights are set to one.

Good to know. I'll be eagerly waiting for you to update the benchmark code in other.py


added detailed player status section

renders below guild info

Hi @Arjun99ab , thanks for taking the time to do this! I'll review soon.


shadowsocks-libev: supports darwin

Motivation for this change
shadowsocks-libev is supported on darwin
Things done

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

[X] NixOS
[X] macOS
[ ] other Linux distributions

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

@LnL7 thanks for reviewing, fixed

@GrahamcOfBorg  build shadowsocks-libev

Success on x86_64-darwin (full log)
Attempted: shadowsocks-libev
Partial log (click to expand)
/nix/store/387jabdjm9v4wi0m9r0fgnq1w78pc3hs-shadowsocks-libev-3.2.0

Success on x86_64-linux (full log)
Attempted: shadowsocks-libev
Partial log (click to expand)
shrinking /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0/lib/libcork.so
shrinking /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0/lib/libbloom.so
shrinking /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0/lib/libshadowsocks-libev.so
shrinking /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0/lib/libipset.so
gzipping man pages under /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0/share/man/
strip is /nix/store/21ymadblbmsbb2bk4q7gl4kjasp8zmgd-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0/lib  /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0/bin
patching script interpreter paths in /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0
checking for references to /build in /nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0...
/nix/store/6srwwmkpyl0nbhsm6zri2rb7d8z986wx-shadowsocks-libev-3.2.0

Success on aarch64-linux (full log)
Attempted: shadowsocks-libev
Partial log (click to expand)
shrinking /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0/bin/ss-local
shrinking /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0/bin/ss-redir
shrinking /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0/bin/ss-tunnel
shrinking /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0/bin/ss-server
gzipping man pages under /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0/share/man/
strip is /nix/store/qg2agrqkf240s656d207zqhipl0bc2id-binutils-2.30/bin/strip
stripping (with command strip and flags -S) in /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0/lib  /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0/bin
patching script interpreter paths in /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0
checking for references to /build in /nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0...
/nix/store/imkrm01kyr42c9d0l77sd0rsa9a67yvm-shadowsocks-libev-3.2.0


Restructure crate to simplify usage/contributing

Hi! Thank you for helping out with SSD1306 development! Please:

[x] Check that you've added documentation to any new methods
[x] Rebase from master if you're not already up to date
[x] Add or modify an example if there are changes to the public API
[x] Add a CHANGELOG.md entry in the Unreleased section under the appropriate heading (Added, Fixed, Changed, etc)
[x] Run rustfmt on the project with cargo fmt --all - CI will not pass without this step
[x] Check that your branch is up to date with master and that CI is passing once the PR is opened

PR description
This PR heavily refactors the crate structure. It does away with the builder, now requiring the passing in of all 4 config params. It also changes how modes work; instead of wrapping Properties in various other structs, it now has various impl blocks on the Ssd1301 struct with different modes in the type params. IMO this makes the code a lot cleaner whilst still allowing switching between modes easily.
The code structure is a lot more approachable now. The "entry point" Ssd1306 struct is a good jumping off point for contributors. Previously, there was a bunch of Properties and *Mode stuff to dig through, without a clear structure.
I'm interested to hear peoples' thoughts on the changes here.
One thing we miss in terms of type safety is a particular mode still allows raw draw() calls on the display. This allows e.g. drawing stuff with embedded-graphics in GraphicsMode, but also allows blatting whatever you've drawn by writing garbage to the display with display.draw(&[0xab; 1024]) whilst in the same mode. This was a deliberate choice to give users the freedom to do "in-band" stuff in whatever mode they're in, but with an escape hatch to do naughtier things if required.
The noise_i2c example demonstrates a "raw" mode:
let mut display = Ssd1306::new(
    interface,
    DisplaySize128x64,
    NoMode,
    DisplayRotation::Rotate0,
);

GraphicsMode and TerminalMode look similar:
let interface = I2CDIBuilder::new().init(i2c);
let mut display = Ssd1306::new(
    interface,
    DisplaySize128x64,
    TerminalMode::new(),
    DisplayRotation::Rotate0,
);
display.init().unwrap();

let interface = I2CDIBuilder::new().init(i2c);
let mut display = Ssd1306::new(
    interface,
    DisplaySize128x64,
    BufferedGraphicsMode::new(),
    DisplayRotation::Rotate0,
);
display.init().unwrap();

I'm not very familiar with this crate and this is only based on the initial comment: Did you consider multiple constructors instead of having to pass a mode object to new?
let raw = Ssd1306::new( // or new_raw
    interface,
    DisplaySize128x64,
    DisplayRotation::Rotate0,
);

let terminal = Ssd1306::new_terminal(
    interface,
    DisplaySize128x64,
    DisplayRotation::Rotate0,
);

let graphics = Ssd1306::new_graphics(
    interface,
    DisplaySize128x64,
    DisplayRotation::Rotate0,
);

This wouldn't be scalable to lots of modes, but for three modes it might be easier to use. And you could still have a Ssd1306::with_mode constructor if necessary.

I did consider that, but decided to go with a single constructor and a mode argument. I'm not sure if there are any benefits between these two approaches, but if there's a drawback to mine I've missed please let me know. Otherwise, I think I'm going to leave it as is.

I'm not sure if there are any benefits between these two approaches, but if there's a drawback to mine I've missed please let me know.

No, it probably is just personal preference.
But if I try to dig deep this would be the only objective advantage I can come up with (so feel free to just ignore it): The constructors are easier to discover by using code completion, while the values that can be used for the mode parameter in new are unclear without looking at the docs or an example. And the slight inconsistency between NoMode, which can be used without calling new, and the other modes, which require new to be called, is another thing to remember.
You did write that you modeled the code based on the types states in the HAL crates. How about removing the mode from new entirely and rely on into_mode (or into_graphics and into_terminal) to set the actual mode? This would be similar to how HAL handle GPIO pin modes.
If you want to keep the current solution I would suggest to change the order of the new arguments. IMO the display size and rotation should be next to each other.

I've just pushed a commit which updates the initialisation to the following:
let mut display = Ssd1306::new(interface, DisplaySize128x64, DisplayRotation::Rotate0)
    .into_buffered_graphics_mode();

(plus into_terminal_mode). I quite like this as it's simple to switch between modes, but still retains most of the other benefits of the original design. I'd be interested to hear everyone's thoughts on this approach.

I like it.
Is there a way to get rid of the separate init call, which is required after changing the mode? IMO this is something that could easily be missed.

I did think about that. I left it as a separate method to give some flexibility to the user if they wanted to init the display in another place (e.g. an RTIC interrupt on device wakeup) but that might be too contrived and it's a better idea to initialise the display inside into_*_mode. Thoughts?

Maybe mode and display initialization should be separated from each other. Like this:
Ssd1306::new(...) -> Result<Self, DisplayError> initializes the basic display settings (everything in init_with_addr_mode). This will need to use some default addressing mode, but changing it later has only minimal overhead. And the into_..._mode methods change the addressing mode and any other required settings.
If directly initializing the display in Ssd1306::new later turns out to be a problem we could also add a new_uninitialized method, which returns a Ssd1306 with a new Uninitialized mode.

Methods like Ssd1306::draw are currently available for all modes. Shouldn't these only be available in basic mode?

Sweet!

Maybe mode and display initialization should be separated from each other. ...

That's a good idea. I'll write that up and see what it looks like.

Methods like Ssd1306::draw are currently available for all modes. Shouldn't these only be available in basic mode?

That was a deliberate choice I described in the PR description:

One thing we miss in terms of type safety is a particular mode still allows raw draw() calls on the display. This allows e.g. drawing stuff with embedded-graphics in GraphicsMode, but also allows blatting whatever you've drawn by writing garbage to the display with display.draw(&[0xab; 1024]) whilst in the same mode. This was a deliberate choice to give users the freedom to do "in-band" stuff in whatever mode they're in, but with an escape hatch to do naughtier things if required.

Personally I think this is ok, although there may be some methods that could be moved to BasicMode. Do you have any suggestions?

OK, sorry I had missed to comment in the PR description. IMO using draw together with the partial flushing in the buffered mode could result in hard to predict results. But I guess as long as possible side effects are documented it's OK.
Is there a way to force a full flush to restore the image to the buffer content after draw is used? Should there also be a method that is similar to draw, but which changes the buffer instead?

Here are some random comments/questions about the Ssd1306 struct I noticed while reading the docs:

Why does set_pixel use a u8 for value, instead of a bool or an enum?
get_position in terminal mode should be called position according to the naming conventions and all other getters also don't use a get_ prefix.
Is there a reason why it is change_addr_mode instead of set_addr_mode?
display_on(&mut self, on: bool) is a bit confusing. As a setter it should have a set_ prefix and if it is a command I would expect separate display_on and display_off methods instead of a bool argument.
There is a possible integer underflow in set_draw_area if end.0 or end.1 is zero
Does the reset method need to be part of Ssd1306? A simple function in the crate root would also work. I don't think the reset is exclusive to the SPI interface. It might not be exposed in the cheap SSD1306 modules, but the signal can still be used for I2C and parallel interfaces.
set_rotation exists in Ssd1306 and DisplayConfig. I'm surprised that the compiler doesn't complain if this method is called, but maybe I'm missing something. Is it ensured that the correct version is called if someone uses display.set_rotation?

As I said these are just some things I noticed and are I wanted to leave them as a comment to give some outside perspective on the API. There might be good reasons for the current implementation I simply don't know about.

One more thing I noticed: set_row and set_column currently panic if the addressing mode isn't page. But the commands also work in the other addressing modes.

And the column part of set_draw_area would also be useful for page mode.

set_row and set_draw_area can panic if row is >= 64, which isn't documented.
But perhaps it would be better to use Page parameters in this case? IMO this would make it clearer that the row can only be set to multiples of 8px. If someone is using the low level API they should be familiar with the memory layout and what a page is.

The basic mode could also use a clear method.

I was taking a look at moving the init around and realised it results in two unwrap()s (or two Results anyway):
let mut display = Ssd1306::new(interface, DisplaySize72x40, DisplayRotation::Rotate0)
    .unwrap()
    .into_buffered_graphics_mode()
    .unwrap();

Which is quite cumbersome IMO, so maybe it's a better idea to add Ssd1306::new_basic (or just new), Ssd1306::new_buffered_graphics, Ssd1306::new_terminal as previously suggested, as well as keep the .into_* methods for conversions at runtime.

Here are some random comments/questions about the Ssd1306 struct I noticed while reading the docs:

Thanks for looking this over. Most of this is old stuff and inconsistencies that should be fixed indeed. Responding in order:

Good question. It's a bool now.
Changed, it should indeed be just position
None at all, I've reverted it back to set_addr_mode as in master
Personal preference could lean this either way, but IMO set_display_on that takes a bool is fine, but I've added the set_ prefix at least.
Well spotted! I'm using saturating_sub now.
IMO it's nicer to provided it as part of the Ssd1306 impl as all the methods are then attached to the instance.
Uhh... magic? I still need to test this, but hopefully rustc is smart enough to figure it out. As a half-joke: if it compiles, should it not run correctly?

One more thing I noticed: set_row and set_column currently panic if the addressing mode isn't page. But the commands also work in the other addressing modes.

Hm, maybe there was a historic reason for this but I don't recall. @therealprof can you remember? Either way, I've pushed a commit to allow them to be used in any mode which I can revert if it's incorrect.

IMO it's nicer to provided it as part of the Ssd1306 impl as all the methods are then attached to the instance.

OK, but should it be limited to SPI?

Which is quite cumbersome IMO, so maybe it's a better idea to add Ssd1306::new_basic (or just new), Ssd1306::new_buffered_graphics, Ssd1306::new_terminal as previously suggested, as well as keep the .into_* methods for conversions at runtime.

Or: Ssd1306::new returns a mode Uninitialized display, which doesn't require any communication and cannot fail. And then use into_..._mode methods, which can fail and return a Result. In contrast to my last suggestion this would also require a into_basic_mode method.

Regarding set_draw_area: The docs for this method don't explain that the end coordinates are not included in the drawing area.

I've made a couple of different attempts at the init API now and either they don't work or I'm not happy with them. This crate has seen a lot of downloads, and I haven't come across people having issues forgetting to call init(), so I think I'm going to leave that API as is and merge this refactor PR unless there are any strong objections to it.
This crate doesn't have the highest quality docs for sure, but this PR was originally focussed on the structure of the code more than anything else.

I've made a couple of different attempts at the init API now and either they don't work or I'm not happy with them. This crate has seen a lot of downloads, and I haven't come across people having issues forgetting to call init(), so I think I'm going to leave that API as is and merge this refactor PR unless there are any strong objections to it.

OK.

This crate doesn't have the highest quality docs for sure, but this PR was originally focussed on the structure of the code more than anything else.

Sorry for all the off topic comments.

Sorry for all the off topic comments.

Not a problem! You brought up some good points which I've added in, so thank you for those :)


Close chatRoomFragment when I am attaching a file ?

When I use from attach file in ChatRoomFragment for upload a video,Image... it redirect me to Recent for select a video,image or ... but for example when I select a video, close chatRoomFragment and redirect me to chatRoomsFragment and I can't upload for example a video and I should try again for upload.(For upload a video I try this way several times)
What can I do?

I didn't understand the problem... can you send us more detailed information or a video/GIF?


Chore remove unecessary code

Pull Request Test Coverage Report for Build 848745319

4 of 4 (100.0%)  changed or added relevant lines in 1 file are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.04%) to 96.084%

Totals

Change from base Build 848743644:
-0.04%

Covered Lines:
7831

Relevant Lines:
7839

💛  - Coveralls

:tada: This PR is included in version 6.49.3 :tada:
The release is available on:

v6.49.3
GitHub release

Your semantic-release bot :package::rocket:


first review of Indonesian 4.0 translation

Received comments back. Need to review and send summary to Diane for her review.

Finished my review and passing baton to @peterspdx for her sign-off before public comment. Shared translation worksheet in google doc.

Ok to move forward.