Can SP.MoveCopyUtil.MoveFileByPath calls be batched using SPHttpClientBatch?

Category

[x] Question
[ ] Typo
[ ] Bug
[ ] Additional article idea

Expected or Desired Behavior
SP.MoveCopyUtil.MoveFileByPath method should work with the SPHttpClientBatch. I'm able to do a single move using spHttpClient but I've found that I need to set odata-version to 3.0. If I was to try the same using the Batch client, the call would fail.
Observed Behavior
I can see that the $batch session returns code 200 but the files don't move. The responses read

The property '__metadata' does not exist on type 'SP.ResourcePath'. Make sure to only use property names that are defined by the type.

[HTTP]:400 - Bad Request [CorrelationId]: [Version]:

The modern UI view Move To command batch call looks very similar to the call I get from running my code below. One thing that stands out for me is that my $batch session has this parameter

accept: application/json

Whereas the SharePoint Move To header has this:

application/json;odata=verbose

I can set the headers for the calls nested inside the batch call but not on the batch call's own header.
Finally, if I set the odata version to 3.0 (which works with SPHttpClient and I can achieve a single file move), I get the following error.

The value '3.0' of the OData-Version HTTP header is invalid. Only '4.0' is supported as values for the OData-Version header.

Steps to Reproduce
I'm running the code below in the onExecute method of a ListView Command Set extension
const currentWebUrl: string = this.context.pageContext.web.absoluteUrl;
const spBatchCreationOpts: ISPHttpClientBatchCreationOptions = { webUrl: currentWebUrl };
const spBatch: SPHttpClientBatch = spHttpClient.beginBatch(spBatchCreationOpts);

let bodyOptions0 = {
  "srcPath": {
    "__metadata": {
      "type": "SP.ResourcePath"
    },
    "DecodedUrl": srcFileUrl0
  },
  "destPath": {
    "__metadata": {
      "type": "SP.ResourcePath"
    },
    "DecodedUrl": dstFileUrl0
  }
};

let bodyOptions1 = {
  "srcPath": {
    "__metadata": {
      "type": "SP.ResourcePath"
    },
    "DecodedUrl": srcFileUrl1
  },
  "destPath": {
    "__metadata": {
      "type": "SP.ResourcePath"
    },
    "DecodedUrl": dstFileUrl1
  }
};
const opt0: ISPHttpClientBatchOptions = {
  headers: {
    "Content-Type": "application/json;odata=verbose"
  },
  body: JSON.stringify(bodyOptions0)
};

const opt1: ISPHttpClientBatchOptions = {
  headers: {
    "Content-Type": "application/json;odata=verbose"
  },
  body: JSON.stringify(bodyOptions1)
};
const moveDoc0 = spBatch
  .post(
    `${currentWebUrl}/_api/SP.MoveCopyUtil.MoveFileByPath()`,
    SPHttpClientBatch.configurations.v1,
    opt0
  );

const moveDoc1 = spBatch
  .post(
    `${currentWebUrl}/_api/SP.MoveCopyUtil.MoveFileByPath()`,
    SPHttpClientBatch.configurations.v1,
    opt1
  );

spBatch
  .execute()
  .then(() => {
    moveDoc0
      .then((response: SPHttpClientResponse) => {
        console.log('response0: ', response);

        response.json()
          .then((props: any) => {
            console.log('props0: ', props);
          });
      });

    moveDoc1
      .then((response: SPHttpClientResponse) => {
        console.log('response1: ', response);

        response.json()
          .then((props: any) => {
            console.log('props1: ', props);
          });
      });
  });

What is the response header/body and what is the output of console log?

There's no errors shown on the console but I've included a screenshot of the console logs from the code snippet in my OP. I assume you need both response and request headers? I've truncated what I think is unnecessary for brevity.

Response header/body as requested
Request Header

:authority: .sharepoint.com
:method: POST
:path: /sites//_api/$batch
:scheme: https
accept: application/json
accept-encoding: gzip, deflate, br
accept-language: en-US,en;q=0.9
cache-control: max-age=0
content-length: 1171
content-type: multipart/mixed; boundary=batch_aab9d10b-56c8-46ee-8f69-8c140ff7285d
cookie: databaseBtnText=0; databaseBtnDesc=0; stsSyncAppName=Client; stsSyncIconPath=; MicrosoftApplicationsTelemetryDeviceId=e5106212-a131-4aa4-9a45-39015cd01626; MicrosoftApplicationsTelemetryFirstLaunchTime=2018-10-16T10:56:59.268Z; rtFa=; odbn=1; WSS_FullScreenMode=false; FedAuth=; SPWorkLoadAttribution=Url=https://.sharepoint.com/sites//_api/web/GetList(@listUrl)/RenderListDataAsStream&AppId=E0D3C05D-9133-40D1-8413-1C4522A4E7C2
odata-version: 4.0
origin: https://.sharepoint.com
referer: https://.sharepoint.com/sites//Folders/Forms/AllItems.aspx?debugManifestsFile=https%3A%2F%2Flocalhost%3A4321%2Ftemp%2Fmanifests%2Ejs&loadSPFX=true&customActions=%7B%22411396f4%2D7237%2D4fbc%2D986a%2D636586e983cf%22%3A%7B%22location%22%3A%22ClientSideExtension%2EListViewCommandSet%22%2C%22properties%22%3A%7B%22sampleTextOne%22%3A%22One%20item%20is%20selected%20in%20the%20list%22%2C%22sampleTextTwo%22%3A%22This%20command%20is%20always%20visible%2E%22%7D%7D%7D&sortField=LinkFilename&isAscending=false
user-agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.100 Safari/537.36
x-requestdigest: ,16 Oct 2018 13:38:13 -0000

Response Header

cache-control: private, max-age=0
content-disposition: attachment
content-type: multipart/mixed; boundary=batchresponse_7143ff7b-6b24-45a6-ae49-344a575ddb96
date: Tue, 16 Oct 2018 13:40:42 GMT
expires: Mon, 01 Oct 2018 13:40:42 GMT
last-modified: Tue, 16 Oct 2018 13:40:42 GMT
microsoftsharepointteamservices: <IP_ADDRESS>03
ms-cv: npj0hIOgAHAa82X7t6h6hw.0
odata-version: 4.0
p3p: CP="ALL IND DSP COR ADM CONo CUR CUSo IVAo IVDo PSA PSD TAI TELo OUR SAMo CNT COM INT NAV ONL PHY PRE PUR UNI"
request-id: 84f4989e-a083-7000-1af3-65fbb7a87a87
set-cookie: FedAuth=; expires=Sun, 21-Oct-2018 13:24:49 GMT; path=/; secure; HttpOnly
set-cookie: SPWorkLoadAttribution=Url=https://.sharepoint.com/sites//_api/$batch&AppId=E0D3C05D-9133-40D1-8413-1C4522A4E7C2; expires=Tue, 16-Oct-2018 13:41:12 GMT; path=/
set-cookie: SPWorkLoadAttribution=Url=https://.sharepoint.com/sites//_api/$batch&AppId=E0D3C05D-9133-40D1-8413-1C4522A4E7C2; expires=Tue, 16-Oct-2018 13:41:12 GMT; path=/
set-cookie: rtFa=; domain=sharepoint.com; expires=Sun, 21-Oct-2018 13:24:49 GMT; path=/; secure; HttpOnly
spclientservicerequestduration: 23
sprequestduration: 53
sprequestguid: 84f4989e-a083-7000-1af3-65fbb7a87a87
status: 200
strict-transport-security: max-age=31536000
x-aspnet-version: 4.0.30319
x-content-type-options: nosniff
x-download-options: noopen
x-frame-options: SAMEORIGIN
x-ms-invokeapp: 1; RequireReadOnly
x-msedge-ref: Ref A: 0F9A479C1575444FA6EF7182AF94958C Ref B: LON21EDGE0121 Ref C: 2018-10-16T13:40:42Z
x-powered-by: ASP.NET
x-requestdigest: ,16 Oct 2018 13:40:42 -0000
x-sharepointhealthscore: 1
x-sp-serverstate: ReadOnly=0

Response Body
--batch_aab9d10b-56c8-46ee-8f69-8c140ff7285d
Content-type: application/http
Content-Transfer-Encoding: binary
POST https://.sharepoint.com/sites//_api/SP.MoveCopyUtil.MoveFileByPath() HTTP/1.1
accept: application/json;odata=verbose
content-type: application/json;oodata=verbose
{"srcPath":{"__metadata":{"type":"SP.ResourcePath"},"DecodedUrl":"https://.sharepoint.com/sites//Folders/F2.txt"},"destPath":{"__metadata":{"type":"SP.ResourcePath"},"DecodedUrl":"https://.sharepoint.com/sites//Folders/Dest folder/F2.txt"}}
--batch_aab9d10b-56c8-46ee-8f69-8c140ff7285d
Content-type: application/http
Content-Transfer-Encoding: binary
POST https://.sharepoint.com/sites//_api/SP.MoveCopyUtil.MoveFileByPath() HTTP/1.1
accept: application/json;odata.metadata=full
content-type: application/json;oodata.metadata=full
{"srcPath":{"__metadata":
{"type":"SP.ResourcePath"},"DecodedUrl":"https://.sharepoint.com/sites//Folders/F1.txt"},"destPath":{"__metadata":{"type":"SP.ResourcePath"},"DecodedUrl":"https://.sharepoint.com/sites//Folders/Dest folder/F1.txt"}}
--batch_aab9d10b-56c8-46ee-8f69-8c140ff7285d--

[https://i.imgur.com/KF1Ho5T.png](console log screenshot)

Please change the bodyOptions0 and bodyOptions1 to the following code, it works well on my side:
let bodyOptions0 = {
        srcPath: {
               DecodedUrl: srcFileUrl0
        },
       destPath: {
              DecodedUrl: dstFileUrl0
       }
};
let bodyOptions1 = {
       srcPath: {
              DecodedUrl: srcFileUrl1
       },
      destPath: {
             DecodedUrl: dstFileUrl1
};

Ok that kind of works but I get an error on the execute method.
This is what I get a in the catch

TypeError: Failed to construct 'Response': Response with null body status cannot have body
at e._parseResponsesFromBody (listview-host-assembly_default_35738d0f0518e801c91a02fcc1966538.js:563)
at listview-host-assembly_default_35738d0f0518e801c91a02fcc1966538.js:563

This is what I get in the console
2 times this:

Uncaught (in promise) TypeError: This request was part of an SPHttpClientBatch that failed
at listview-host-assembly_default_35738d0f0518e801c91a02fcc1966538.js:563

The documents move fine though but
.execute().then(() => {// nothing in here runs}).catch(error => {// this runs instead})

I had a typo in my headers so now I'm just using "Content-Type": "application/json;odata=verbose" (doesn't make a difference either way).
BTW, the OOTB MoveTo modern experience uses the {"__metadata":{"type":"SP.ResourcePath"} information when I look at the request batch body so that's why I was trying to do it that way as well.

The execute works well with response id 204 and without response body. You are try to convert the value, so you get the exception.
Response with null body status cannot have body

I'm sorry I don't understand how to avoid getting the exception? What value do I need to convert and how do I convert it?

moveDoc1
.then((response: SPHttpClientResponse) => {
// The reponse is null. So you should not do any logic on it. Instead, you need to put your own logic here. Such as   console.log('response0: ', "Success");
});
And handle the exception on the exception.

I'm currently trying to just do a console log just after .execute().then(() => { and nothing gets logged, goes straight to catch. Also, I'm getting a 200, not 204 (unless I'm looking in the wrong place)

No matter 200 or 204, all means success. I get the 204 on my side. If you get 200, you can see what is the content in the response body. And you need to handle both 200 and 204 in your code.

Not sure how to handle it. Could you paste in the code that gives you the 204 so I can try it as well?
spBatch
  .execute()
  .then(() => {
     console.log('it worked'); //does not get logged
  })
  .catch((responseError) => {
    console.log('did not work'); //this gets logged
  });

I just use the code you provided.

I've tried my original code and as well but I just can't get a 204 and none of the console log commands run that I've inserted before opening up the individual responses. The exception happens at execute(). The exception for me does not happen in 'my' code i.e. execute().then(() => //nothing happens here). Yet the batch operation returns 200...

Ok I've simplified this as much as I can. I've just pasted the below code in the render method of a HellowWorld webpart in HelloWorldWebPart.ts. So as soon as you drop the webpart on a page, it fires off the action.
    const currentWebUrl: string = this.context.pageContext.web.absoluteUrl;
    const spBatchCreationOpts: ISPHttpClientBatchCreationOptions = { webUrl: currentWebUrl };
    const spBatch: SPHttpClientBatch = this.context.spHttpClient.beginBatch(spBatchCreationOpts);
    let srcFileUrl0 = `<Old File Path>`;
    let dstFileUrl0 = `<New File Path>`;
    let bodyOptions0 = {
      "srcPath": {
        "DecodedUrl": srcFileUrl0
      },
      "destPath": {
        "DecodedUrl": dstFileUrl0
      }
    };

    const opt0: ISPHttpClientBatchOptions = {
      headers: {
        "Content-Type": "application/json;odata=verbose"
      },
      body: JSON.stringify(bodyOptions0)
    };

    const moveDoc0 = spBatch
      .post(
        `${currentWebUrl}/_api/SP.MoveCopyUtil.MoveFileByPath()`,
        SPHttpClientBatch.configurations.v1,
        opt0
      );

    spBatch
      .execute()
      .then(() => {
        console.log(`Yay, it worked`);
      })
      .catch(batchError => console.log(`Batch Error: `, batchError));

My batch session returns a response of 200 (not 204) and on the console I see this:

Whatever I'm doing wrong, I just can't spot it.

Can SP.MoveCopyUtil.MoveFileByPath calls be batched using SPHttpClientBatch?
Your initial question have been fix.

Your latest question is not related to the original, it'd better you submit new issue, so any one else can help you and retrieved it easier for other people

Done
https://github.com/SharePoint/sp-dev-docs/issues/2857


[Large] Create UI for metadata editing workflow

This PR creates the main part of the UI for editing file metadata from BFF based on the Figma designs. Does not include any backend logic.
Temporarily deployed to staging
Part of #96
Reviewing
Lots of changes with a slightly complicated file structure, so here's suggested review order:

Entrypoint: added edit to the dropdown menu in packages/core/hooks/useFileAccessContextMenu.ts
This opens the modal, which is packages/core/components/Modal/EditMetadata/index.tsx
The modal renders the actual editing component (packages/core/components/EditMetadata/index.tsx), which is a wrapper for both the "new" and "existing" annotation pathways

Pathway for editing files' values for an existing annotation: packages/core/components/EditMetadata/ExistingAnnotationPathway.tsx
Pathway for creating a new annotation on the files: packages/core/components/EditMetadata/NewAnnotationPathway.tsx

BOTH pathways then point at packages/core/components/EditMetadata/MetadataDetails.tsx, which displays the current values for the files and provides an input field to enter the desired replacement values

There's also a brand new 'ComboBox' component (dropdown selector with search), which is a styled wrapper for the FluentUI combo box
To Dos (UI only)

Render different input fields depending on the type of the annotation (date, number, yes/no, etc)
Prevent users from creating a new annotation that shares a name with an existing annotation. This most likely looks like adding fuzzy search to the text field where the user enters the new name
Password
Check combobox logic -- Ideally should open on click and react to users hitting enter, but has been behaving inconsistently
Unit tests
Warn users on exit w/ unsaved changes
Add disabled annotations (e.g., from labkey)

Screenshots
Existing annotation pathway:

New annotation pathway:

UX bugs from @lynwilhelm :

[ ] Arrow down with menu open changes file selection in the background (yikes!)
[ ] Don't allow user to move modal & fix move cursor
[ ] Remove REPLACE from first step
[ ] Table shouldn't be focusable
[ ] Fix spacing for "Existing" header
[ ] Fix table header spacing & font size
[ ] Add tooltips on radio options (new/existing)
[ ] Tab sometimes advances the modal when it shouldn't
Combobox menu bugs (may need to convert these to separate issue)

[ ] When text is entered in annotation combobox, clicking the 'x' goes to the next step instead of dismissing
[ ] Weird text highlighting & case restriction in autocomplete
[ ] Add overlay to menu overflow & increase height slightly
[ ] Add styling in combobox callout for focus/active/selected
[ ] Clicking inside & typing still doesn't open open menu by default
[ ] Searched item does not always appear at the top of the search results


sublime4: 4152 -> 4166; sublime4-dev: 4155 -> 4168

Description of changes
Changelog stable: https://www.sublimetext.com/download, dev: https://www.sublimetext.com/dev
Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
23.11 Release Notes (or backporting 23.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Priorities
Add a :+1: reaction to pull requests you find important.

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/prs-ready-for-review/1016/83

Thanks.


[bug][v2] Ubuntu 22 tauri crash

Describe the bug
It seems that tauri segfaults on ubuntu 22.04.2:
npm run tauri info

><EMAIL_ADDRESS>tauri
> tauri info

Bus error (core dumped)

Node.js itself works fine v20.12.0, official binary distribution.
Reproduction
No response
Expected behavior
No response
Full tauri info output
xx

Stack trace
No response
Additional context
No response

Cleared all caches, deleted node_modules, clean rebuild and somehow it worked!


Add node global error handler plugins

Note:
Like #384, this branch relies on changes in both u/plugin-config-interface and u/express-plugin, so until they are merged this PR's diff includes all of those changes too. To see the actual changeset, see this compare link.
Update: #382 is now merged, just waiting on #384 now.

What
This adds the two pieces of functionality required to track unhandled errors in node:

@bugsnag/plugin-node-uncaught-exception
@bugsnag/plugin-node-unhandled-rejection

Both are of course bundled into the node notifier by default – they don't need to be installed by end users.
How
When config.autoNotify is true, the two plugins hook into the process#uncaughtException and process#unhandledRejection events respectively.
When either of these functions handle an error, they'll call the config.onUnhandledError function, which by default will terminate the process. The option terminateOnUnhandledRejection can be used to prevent an unhandled promise rejection from terminating the process.
Review
~The tests on CI will fail due to a known issue :( they work locally though!
This purpose of this PR being pushed up at this point is for manual code review.~
The test suite is now fixed and the CI should be green.

By way of merging #384 / #388, the majority of these changes are already now in master. I believe it's just https://github.com/bugsnag/bugsnag-js/pull/385/commits/dbb5efc0d11ca99271a5aae5fe22bd054b78601d.


Working example for setting options

Hello,
Is it possible to provide a working example for customizing user agent and allowed html tags?

@cayolblake ok, I will try.

Hello,
Had the time to look at this :) ?

@cayolblake sorry, we are in the most important holiday in Vietnam :D

Oh, happy holidays 8-)

@cayolblake actually they are already in the test script:
Custom fetch options:
https://github.com/ndaidong/article-parser/blob/v4.2.7/src/main.test.js#L141
Custom allowed  tags:
https://github.com/ndaidong/article-parser/blob/v4.2.7/src/main.test.js#L151
Is that enough for you?

@cayolblake please refer the test script here:
Custom user agent:
https://github.com/ndaidong/article-parser/blob/main/src/main.test.js#L150
Custom allowed tags:
https://github.com/ndaidong/article-parser/blob/main/src/main.test.js#L171
Let's me know if that is enough for your situation. Thanks.


Added the no clipboard option

- What is it good for
Looks like on CI conditions the clipboard copying fails. With the new option you can
configure scottyjs to skip the clipboard handling. With this option the CI build failed
no more.
- What I did

Updated the readme
Added --noclipboard option to disable clipboardy

- What I did not
Due to the tight coupling of the bin/scotty binary to the lib/scotty module was
not able to test the new option. If you can provide me a clever solution how to
test this I will do so. :)
- A picture of a cute animal (not mandatory but encouraged)

@stojanovic You're the best :heart:

omg guys! :D get a room!

Keep 'em coming :)
v1.8.0 is going to NPM in a second

Hey @stojanovic :) looks like you forgot to release the 1.8.0 on npm. Could you publish it? :)

@Jack12816 oops, done


Use flatten-maven-plugin for release artifacts

Flatten Maven Plugin generates a flattened version of your pom.xml and makes maven to install and deploy this one instead of the original pom.xml. The flattened POM has the following characteristics:

Build specific elements are removed
Development specific elements are removed by default
It only contains elements required for users of your artifact
Its variables are resolved
Its parent relationship is resolved, flattened and removed

done


fix line break search

Fixes issue with searching for editor components
Now, the behavior is that when there are no component names that match the search criteria, we can now break to a new line.

For this one, if anywhere else in the frontend code you traverse the dom to find the element 'block-menu-container' you won't find it cause I changed the id name.
I don't suspect that this will happen in a typical react codebase tho

Will merge monday


Led controller

in progress

shouldnt a match statement work fine if running python >3.10? link

From that link:
Named constants may be used in patterns. These named constants must be dotted names to prevent the constant from being interpreted as a capture variable:
class Color(Enum):
    RED = 0
    GREEN = 1
    BLUE = 2

match color:
    case Color.RED:
        print("I see red!")
    case Color.GREEN:
        print("Grass is green")
    case Color.BLUE:
        print("I'm feeling the blues :(")```

sigh

shouldnt a match statement work fine if running python >3.10? link

Yes, and as you can see the tests do actually pass running on Python 3.11. However, our linter doesn't support pattern matching: see https://github.com/charliermarsh/ruff#how-does-ruff-compare-to-flake8
I'm sure you can find an elegant way to achieve the desired outcome without pattern matching, making good use of enum values, and dicts where attaching things to the enums is less appropriate.

got it. will make a commit later today fixing this + adding controller

robot.py has changes and conflicts conflicts

Closing because we merged this component in #73 and state machine interactions are in #75


StagedProcess#nextProcessingDate does not currently have a sensible default

In the majority of cases, we just want it to be the start of the next day. This should save a lot of boilerplate in jobs derived from StagedProcess. One way to do this using only Java standard date/time APIs (extract from REPL):
@ import java.util._
import java.util._

@ new Date()
res1: Date = Thu Dec 08 14:12:54 EST 2016

@ Calendar.getInstance
res3: Calendar = java.util.GregorianCalendar[time=1481224422011,areFieldsSet=true,areAllFieldsSet=true,lenient=true,zone=sun.util.calendar.ZoneInfo[id="America/Toronto",offset=-18000000,dstSavings=3600000,useDaylight=true,transitions=231,lastRule=java.util.SimpleTimeZone[id=America/Toronto,offset=-18000000,dstSavings=3600000,useDaylight=true,startYear=0,startMode=3,startMonth=2,startDay=8,startDayOfWeek=1,startTime=7200000,startTimeMode=0,endMode=3,endMonth=10,endDay=1,endDayOfWeek=1,endTime=7200000,endTimeMode=0]],firstDayOfWeek=1,minimalDaysInFirstWeek=1,ERA=1,YEAR=2016,MONTH=11,WEEK_OF_YEAR=50,WEEK_OF_MONTH=2,DAY_OF_MONTH=8,DAY_OF_YEAR=343,DAY_OF_WEEK=5,DAY_OF_WEEK_IN_MONTH=2,AM_PM=1,HOUR=2,HOUR_OF_DAY=14,MINUTE=13,SECOND=42,MILLISECOND=11,ZONE_OFFSET=-18000000,DST_OFFSET=0]

@ res3 setTime res1

@ res3.set(Calendar.AM_PM, 0)

@ res3.set(Calendar.DST_OFFSET, 0)

@ res3.set(Calendar.HOUR, 0)

@ res3.set(Calendar.HOUR_OF_DAY, 0)

@ res3.set(Calendar.MILLISECOND, 0)

@ res3.set(Calendar.MINUTE, 0)

@ res3.set(Calendar.MINUTE, 0)

@ res3.set(Calendar.SECOND, 0)

@ res3.set(Calendar.ZONE_OFFSET, 0)

@ res3.add(Calendar.DATE, 1)

@ res3.getTime
res15: Date = Fri Dec 09 00:00:00 EST 2016

Parametrizing the start on "size of time period" would be a good idea.
If it's daily, then next day. If it's weekly, next week. If it's monthly, next month (with proper handling of edge cases).
Looking at Google /outlook event recurrence patterns, would give you a fairly complete picture (of cases to handle) as well as possible strategies for handling said edge cases.

@suhailshergill good point. The current signature of nextProcessingDate is basically telling me, 'give me the next processing date based purely on the last completed date'. In the StagedProcess trait, I don't have access to any recurrence information. I may be able to stick closely to the current API and default behaviour by adding a def recurrence: scala.concurrent.duration.Duration method to the trait, e.g.
import scala.concurrent.duration.DurationInt

trait StagedProcess extends EigenflowDSL {
  def executionPlan: ExecutionPlan[_, _]

  def initialProcessingDate: Date = new Date()
  def recurrence: Duration = 1.day
  def nextProcessingDate(lastCompleted: Date): Date =
    /*
    lastCompleted rounded down to nearest recurrence unit + recurrence
    e.g. if recurrence is 1h and lastCompleted is 16:55,
    nextProcessingDate = 16:55 round down to 16:00 + 1h = 17:00
    */
}

java.time FTW if going down the sensible default route:
scala> import java.time.temporal.ChronoUnit.DAYS
import java.time.temporal.ChronoUnit.DAYS

scala> import java.util.Date
import java.util.Date

scala> val d = new Date().toInstant
d: java.time.Instant = 2016-12-09T04:18:05.066Z

scala> d -> d.plus(1, DAYS).truncatedTo(DAYS)
res8: (java.time.Instant, java.time.Instant) = (2016-12-09T04:18:05.066Z,2016-12-10T00:00:00Z)

Also to note that the recurrence is already there in the Chronos job config.

@jonas agreed, java.time FTW. I forgot that we have minimum JVM version at 1.8.
About the recurrence in Chronos, correct me if I'm wrong, but Eigenflow is not necessarily tied to Chronos. Although it's true that we can try to model recurrence after Chronos' recurrence capabilities to make interop with Chronos easier. I'll have to read up on that.


Master to Live 3 4/16/2019

Docs Build status updates of commit e4b4052:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

mixed-reality-docs/mr-dev-days-sessions.md
:white_check_mark:Succeeded
View

mixed-reality-docs/mr-dev-days.md
:white_check_mark:Succeeded
View

mixed-reality-docs/release-notes-october-2018.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

Docs Build status updates of commit 4383f68:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

mixed-reality-docs/TOC.md
:white_check_mark:Succeeded
View

mixed-reality-docs/mr-dev-days-sessions.md
:white_check_mark:Succeeded
View

mixed-reality-docs/mr-dev-days.md
:white_check_mark:Succeeded
View

mixed-reality-docs/release-notes-october-2018.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


  I spent a while trying to add my own extension to Graphiti.Field to support the OptionalParentProperty property wrapper, akin to what you did with the Siblings wrapper.  I figured I'd PR it if I could get it to work.
But... I seem to only sorta be able to get it working.  I have a Schema type definition that looks sort of like this:
Type("MyModel", MyModel.self) {
  // [...]
  Field("category", with \.$category) // 👋  <-- here's the @OptionalParent prop
}

The schema won't compile, none of the initializers match an OptionalParent.  Below is my attempt at adding another initializer to handle the relationship:
extension Graphiti.Field where Arguments == NoArguments, Context == Request, ObjectType: Model {
  public convenience init<ParentType: Model>(
    _ name: FieldKey,
    with keyPath: KeyPath<ObjectType, OptionalParentProperty<ObjectType, ParentType>>
  ) where FieldType == TypeReference<ParentType?> {
    self.init(
      name.description,
      at: {
        (type) -> (Request, NoArguments, EventLoopGroup) throws -> EventLoopFuture<ParentType?> in
        return { (context: Request, arguments: NoArguments, eventLoop: EventLoopGroup) in
          return type[keyPath: keyPath].get(on: context.db)
        }
      }, as: TypeReference<ParentType?>.self)
  }
}

The new initializer allows my Schema to compile. But then, trying to send a query, I get Cannot complete value of unexpected type "CategoryOptional". Which makes me wonder if I'm just messing up my Schema and resolvers somehow, and if maybe the extension is in fact correct.
The other thing I tried is removing the ? on the fifth line of the extension and the third-to-last line (both places where it says TypeReference<ParentType?>.  This also allows the schema to compile, but upon querying I get Cannot return null for non-nullable field MyModel.category.
Any possibility you are able to see at a glance what I've done wrong? Thanks in advance, really appreciate it!

Not at all. I appreciate your enthusiasm and I'm open to support as much as possible!
You have to switch the optional ? from the inner type to the TypeReference type:

// OptionalParent Relationship
extension Graphiti.Field where Arguments == NoArguments, Context == Request, ObjectType: Model {

    /// Creates a GraphQL field for an optional one-to-many/one-to-one relationship for Fluent
    /// - Parameters:
    ///   - name: Field name
    ///   - keyPath: KeyPath to the @OptionalParent property
    public convenience init<ParentType: Model>(
        _ name: FieldKey,
        with keyPath: KeyPath<ObjectType, OptionalParentProperty<ObjectType, ParentType>>
    ) where FieldType == TypeReference<ParentType>? {
        self.init(name.description, at: { (type) -> (Request, NoArguments, EventLoopGroup) throws -> EventLoopFuture<Optional<ParentType>> in
            return { (context: Request, arguments: NoArguments, eventLoop: EventLoopGroup) throws -> EventLoopFuture<Optional<ParentType>> in
                return type[keyPath: keyPath].get(on: context.db)  // Get the desired property and make the Fluent database query on it.
            }
        }, as: TypeReference<ParentType>?.self)
    }
}

I'll create an example app and if this is working for me I'll release a new version wit this extension included. Until then you can include it into your code manually.

Brilliant.  I was close!  Your code works perfectly. Once again, thanks.

I have published release 2.3.0 that includes the above extension.

New version works great, thanks!


0/1 Knapsack problem

0/1 Knapsack Problem

I will add a very interesting problem of 0/1 knapsack problem.

Details

It is a problem that will follow Dynamic Programming approach. There will be some weights and respected value. We will try to find max value with less weight.

Programming language

[ ] C
[x] C++
[ ] Java
[ ] Python

@Ayush7614 plz assign this issue to me.

@Ayush7614 Can I work on this issue.

@Ayush7614 plz assign this to me

@Ayush7614  Please assign this task to me under LGM-SOC'21. I will implement using C++.

Im preparing for my coding interviews and it would really help me if you assign this question to me
Kindly assign me this
I have immense intrest  in coding

Assign this to me under LGM SOC'21

@Ayush7614 review my PR

Please assign me I will do this in JAVA.

@Ayush7614 please assign me under LGM-Soc 21. I want to do it in python,


Tf keras: how to get value of adaptive trainable tensrflow varaiable in keras

I use Keras and have an adaptive activation function which has two adaptive parameters, this parameter is defined by tf.vraiable (trainable=True), I want to get the value of this parameter after each update in Keras. how is it possible?

You created a PR, not an issue. PR are made to contribute to Keras. Issues are used to submit bug or feature request.
This issue isn't related to a bug/enhancement/feature request or other accepted types of issue.
To ask questions, please see the following resources :

https://keras.io/
https://keras.io/#support
https://gitter.im/Keras-io/Lobby

Thanks!
If you think I made a mistake, please re-open this issue.


Create Clustering Analysis

Pretty much just clus-tremor main.

Could you add some commentary at the beginning about how it runs? A high-level walk through over the main steps.


The preparation stage of PSF correction can appear like the code has crashed for big samples

Just add a progress bar to tell the user that things are actually happening.

I was mistaken as to the step that was making it appear like it had crashed. In fact, much like the evselect_spectrum function, the preparation stage actually takes up quite a lot of time. So I'll remove the progress bar I added before I closed this issue, and put one in psfgen instead.


Call hook api

As a salt api plugin user I should be able to call and arbitrary hook Uri with arbitrary key/values So that I can take advantage of hooks and reactor states in salt.

Key/value pairs should be JSON posts to the hook URI
Invocation should provide a configurable auth token parameter, if not defined login dance should happen. If login dance happens...token is optionally provided back to caller
Should be able to configure "eauth" parameter as global or invocation parameter

Calling the cherrypy /hook interface was just added to master and will be in the 2.0 release.
Support for specifying an auth token and changing the eauth parameter globally, were not added. Feel free to open a new request as needed.

Released 2.0


bench_cg.py fails with NVRTC Error

Running bench_cg. py from the examples, gives me this error:
python bench_cg.py
ArrayFire v3.6.2 (CUDA, 64-bit Linux, build dc38ef1)
Platform: CUDA Toolkit 10, Driver: 410.79
[0] Tesla K80, 11442 MB, CUDA Compute 3.7
-1- Tesla K80, 11442 MB, CUDA Compute 3.7
-2- Tesla K80, 11442 MB, CUDA Compute 3.7
-3- Tesla K80, 11442 MB, CUDA Compute 3.7

Testing benchmark functions...
Traceback (most recent call last):
  File "bench_cg.py", line 197, in <module>
    test()
  File "bench_cg.py", line 144, in test
    if af.sum(af.abs(x1 - x2)/x2 > 1e-6):
  File "/home/vanderaa/miniconda3/envs/arrayfire/lib/python3.7/site-packages/arrayfire/array.py", line 894, in __truediv__
    return _binary_func(self, other, backend.get().af_div)
  File "/home/vanderaa/miniconda3/envs/arrayfire/lib/python3.7/site-packages/arrayfire/array.py", line 175, in _binary_func
    safe_call(c_func(c_pointer(out.arr), lhs.arr, other.arr, _bcast_var.get()))
  File "/home/vanderaa/miniconda3/envs/arrayfire/lib/python3.7/site-packages/arrayfire/util.py", line 79, in safe_call
    raise RuntimeError(to_str(err_str))
RuntimeError: In function std::vector<char> cuda::compileToPTX(const char*, std::string)
In file src/backend/cuda/jit.cpp:298
NVRTC Error(6): NVRTC_ERROR_COMPILATION

System: Linux K80 4.15.0-1035-azure #36~16.04.1-Ubuntu SMP Fri Nov 30 15:25:49 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
python --version:
Python 3.7.1
$pip  show arrayfire
Name: arrayfire
Version: 3.6.20181017
Summary: Python bindings for ArrayFire
Home-page: http://arrayfire.com
Author: Pavan Yalamanchili
Author-email<EMAIL_ADDRESS>License: BSD
Location: /mnt/vanderaa/miniconda3/envs/arrayfire/lib/python3.7/site-packages
Requires:
Required-by:

@umar456 I thought this was fixed on 3.6 ?

Yeah, thats what I thought. I haven't looked at this yet. Will get to it later today.

Hi Guys,
I have the same issue in some of my own codes. How do I at least get a more meaningful error message, such that I know that the code to be JITed it too big??
thanks,
Tom


Ensure ConvexPolygonShape2D support count variable is initialised

Also adds a message to the error when supports are not found.
Fixes #46137

Thanks!

Cherry-picked for 3.3.


api-docs: Clean up descriptions of can_mention_group user group setting.

Updates the various descriptions for can_mention_group user group setting in the API docs to be a bit clearer and more concise.
Also, adds more links to the group-setting values article and to the help center article on mentioning a user or user group.
@sahil839 - Pinging you for a review to make sure that the text for these is still accurate.
@Vector73 - Pinging you for a review as you've been looking at this descriptions as well. Note this doesn't fix the issue with the endpoint parameters not rendering the GroupSettingValue schema properly.

Screenshots and screen captures:

Get user groups return value
Current documentation

Create user group parameter
Current documentation

Update user group parameter
Current documentation

Register response - realm_user_groups object
Current documentation - search in page "can_mention_group"

Events user_group op: update
Current documentation

Events user_group op: add
Current documentation

Self-review checklist

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

Communicate decisions, questions, and potential concerns.

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

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

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

Completed manual review and testing of the following:

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

I had a look and the text is correct.

LGTM. I will update #30375 accordingly after this PR is merged.

Merged, thanks @laurynmm!


Call Queue Cmdlet Docs

Call Queue cmdlet documentation

OPS Build status updates of commit dcfcb25:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/Get-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/New-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Remove-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Set-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

@kenwith

OPS Build status updates of commit 8a14f2c:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/Get-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/New-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Remove-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Set-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

OPS Build status updates of commit 4ba5ba7:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/Get-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/New-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Remove-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Set-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

OPS Build status updates of commit 480fad5:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/Get-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/New-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Remove-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Set-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

OPS Build status updates of commit 2b1d537:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/Get-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/New-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Remove-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Set-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

OPS Build status updates of commit 908e234:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/Get-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/New-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Remove-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

skype/skype-ps/skype/Set-CsCallQueue.md
:white_check_mark:Succeeded
View (skype-ps)

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


thread panicked

hi Michael
I have used searchGUI so far with great success for playing around with SAGE. I now want to move to Docker as no matter what I try with searchGUI the input file size seems to be restricted and I hope to circumvent this with a Docker container.
However, when I try to replicate my search of an Orbitrap DIA file, which works nicely in searchGUI, with the Docker I run into some problems:
I run Docker container via my Anaconda powershell
Config.json
(sage) PS C:\TMP_TIMSCONVERT\SAGE_Orbi_DIA> docker run -it --rm -v ${PWD}:/data ghcr.io/lazear/sage:master /app/sage -o /data /data/Config.json
[2024-02-22T20:29:12Z INFO  sage] generated 60538165 fragments in 8925ms
thread 'thread '<unnamed>thread 'thread 'thread 'thread '<unnamed>' panicked at 'thread '<unnamed>thread '<unnamed><unnamed>thread '<unnamed>thread '' panicked at 'thread 'missing precursor information for MS2 scan, please check input files!<unnamed>' panicked at '<unnamed>' panicked at 'thread 'thread '<unnamed><unnamed>' panicked at '' panicked at '<unnamed>' panicked at '<unnamed>missing precursor information for MS2 scan, please check input files!<unnamed>thread '', <unnamed>' panicked at 'missing precursor information for MS2 scan, please check input files!' panicked at 'missing precursor information for MS2 scan, please check input files!' panicked at 'missing precursor information for MS2 scan, please check input files!missing precursor information for MS2 scan, please check input files!' panicked at 'missing precursor information for MS2 scan, please check input files!' panicked at '', ' panicked at '' panicked at 'src/spectrum.rsmissing precursor information for MS2 scan, please check input files!', missing precursor information for MS2 scan, please check input files!', missing precursor information for MS2 scan, please check input files!', missing precursor information for MS2 scan, please check input files!', missing precursor information for MS2 scan, please check input files!src/spectrum.rsmissing precursor information for MS2 scan, please check input files!missing precursor information for MS2 scan, please check input files!:', src/spectrum.rs', src/spectrum.rs', src/spectrum.rs', src/spectrum.rs', :', ', src/spectrum.rs220:src/spectrum.rs220:src/spectrum.rs:src/spectrum.rs:src/spectrum.rs220src/spectrum.rssrc/spectrum.rs:', :::220:220:220:::2201422014:220:thread '220:141414thread '220220:
:note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

:14::<unnamed>14' panicked at '

<unnamed>::1414220
14
missing precursor information for MS2 scan, please check input files!' p
anicked at '1414

:
', src/spectrum.rs:220:14
missing precursor information for MS2 scan, please check input files!
',
14src/spectrum.rssrc/spectrum.rs
::220220::1414

any idea what I am doing wrong here? It is the very first time using Docker, sorry to waste your time on this :(
Best, Klemens

The ghcr.io link is incorrect!
If I try:
$ docker run ghcr.io/lazear/sage /app/sage --version
> sage 0.4.0

I would try sage:latest :grinning:
(should also be easy to try the standalone binary, there are precompiled versions located here: https://github.com/lazear/sage/releases/tag/v0.14.6)?

hi Michael
I used the link provided in the documentation:
https://sage-docs.vercel.app/docs/started#run-via-docker
Would you generally recommend to always use latest, or just in this case?
It works perfectly with :latest
I downloaded the binaries and modified my system PATH, so I can now also directly run sage from command line. Thanks for the tip and you help!
Best, Klemens

Thanks for the catch, I have updated the docs.
I would recommend using the latest version, in case any bugs are uncovered. Sage has been pretty stable for a while though, so it's also OK to pin at v0.14 - all v0.14.* versions should produce identical results.
The next release in which either (a) results change, or (b) the JSON scheme undergoes a breaking change will be v0.15


[SMALLFIX] add serialVersionUIDs to Serializable classes

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins/job/Tachyon-Pull-Request-Builder/6154/
Test PASSed.

LGTM


look into reducing binary sizes - finer grained imports?

Blocked on lean, possibly new module system will address this (see roadmap)


Initialize BABE constant

What does this PR do? Added Babe Api Configuration for constant initialization
Why are these changes needed?  https://github.com/LimeChain/Fruzhin/issues/545

Checklist:

[x] I have read the contributing guidelines.
[x] My PR title matches the Conventional Commits spec.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[x] I have added tests to cover my changes.
[x] All new and existing tests passed.

We should create a separate task for adding the consensus message reader and updating the EpochState members appropriately.


Typo #02 in CSS file 09-spellcheck/index.html

Hello team,
I would like to report a typo in this file.
The string 'overthe' should be replaced with 'over the'.
Please see the attached picture for more context.

not a bug


Everything after/including line_sep sometimes disappears

Issue
I recently installed this theme and have kept it mostly default. I've noticed sometimes after ^Cing a command or exiting something like Vim, when coming back to a new prompt everything after and including the line_sep will disappear until I exit zsh and start it again. I haven't been able to reliably reproduce it, but it happens often. I'm using the default order. No error messages are displayed.
If I can find a way to reliably reproduce it I'll update this, happy to provide more info if needed.
Thanks!
Screenshot
Normal UI:

No line_sep:

Environment
Operating system: macOS
Terminal emulator: terminal
ZSH version: zsh 5.2 (x86_64-apple-darwin15.0.0)
Relevant .zshrc
# Path to your oh-my-zsh installation.
export ZSH=/Users/me/.oh-my-zsh

# Set name of the theme to load. Optionally, if you set this to "random"
# it'll load a random theme each time that oh-my-zsh is loaded.
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes#
# Probably don't need this since it's sourced at the bottom
ZSH_THEME="spaceship"

# Uncomment the following line to enable command auto-correction.
ENABLE_CORRECTION="true"

# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse)
# Add wisely, as too many plugins slow down shell startup.
plugins=(
    git
    common-aliases
    brew
    docker
    git-extras
    npm
    osx
    pep8
    pip
    python
    redis-cli
    fasd
    sudo
    tmux
    virtualenvwrapper
    zsh-history-substring-search
    zsh-syntax-highlighting
)

source $ZSH/oh-my-zsh.sh

# spaceship theme settings
# https://github.com/denysdovhan/spaceship-zsh-theme
# {{{
    SPACESHIP_TIME_SHOW=true
    SPACESHIP_BATTERY_THRESHOLD=35 # 10% isn't enough time to find a charger
    SPACESHIP_PROMPT_SYMBOL="➜ "   # Add a small space after the arrow
    SPACESHIP_VENV_PREFIX="working on "

    # disable some plugins I don't need
    SPACESHIP_KUBECONTEXT_SHOW=false
    SPACESHIP_PYENV_SHOW=false
    SPACESHIP_NODE_SHOW=false
    SPACESHIP_PACKAGE_SHOW=false
#   }}}

source "/Users/me/.oh-my-zsh/custom/themes/spaceship.zsh-theme"

Thanks for reporting!

If I can find a way to reliably reproduce it I'll update this, happy to provide more info if needed.

Would be great.

Hi again.
I still haven't been able to reliably reproduce this, but it seems to often happen when zsh gets interrupted before the next prompt comes up. For example, this just happened now:
18:28:24 in ~/las_elasticsearch
•100% ➜  cd etc/elasticsearch

18:28:26 in las_elasticsearch/etc/elasticsearch ls
backup-logging     elasticsearch.yml  logging.yml

I cd'd into a directory, typed lsbefore the prompt came up, and the newline/battery/arrow disappeared from then on. I'm not able to reliably reproduce this (because of course whenever I try to, cd is too fast). Mashing ^c doesn't seem to trigger it.
Is there a way I can just disable the newline separator for now?

This is happening for me as well.  It is every time my command should wrap.  the entire line, including the prompt disappears.
this:

turns into this:

when my command goes to the next line.

Yeah, the similar problem happens to me. Let's see how can we solve this. However, I have to notice that such bugs are not in priority right now, since I have to finally finish the 3.0 (it takes to long to release this).
@salmanulfarzy I'll appreciate if you take a look at this 🙏

Sure thing. I haven't been able to reproduce the issue. Will get back ASAP :v:

Happens to me too. In tmux, once the prompt reaches the bottom of the screen it starts breaking off. Typing clear resolves it until the next time.

Package: zsh-5.4.1-1.fc27.x86_64

I noticed that sections or segments with unicode characters cause funny behavior with the prompt char.
For instance, here is my spaceship config:
SPACESHIP_PROMPT_ORDER=(
  user          # Username section
  host          # Hostname section
  dir           # Current directory section
  git           # Git section (git_branch + git_status)
  node          # Node.js section
  ruby          # Ruby section
  golang        # Go section
  docker        # Docker section
  aws           # Amazon Web Services section
  line_sep      # Line break
  char          # Prompt character
)

SPACESHIP_RPROMPT_ORDER=(
  jobs          # Background jobs indicator
  exec_time     # Execution time
  exit_code     # Exit code section
  kubecontext   # Kubectl context section
  battery       # Battery level and status
  time          # Time stampts section
)

Causes this behavior (note the missing prompt char)

But, disabling the unicode symbol for kubecontext:
SPACESHIP_KUBECONTEXT_SYMBOL=''

Fixes the issue

Same goes for battery
Before:

After:
SPACESHIP_BATTERY_SHOW='always'
SPACESHIP_BATTERY_SYMBOL_CHARGING='+'
SPACESHIP_BATTERY_SYMBOL_DISCHARGING='-'
SPACESHIP_BATTERY_SYMBOL_FULL=''

I think I just figured it out.
Exported the following environment variables for UTF-8 and all unicode characters work without messing up the prompt:
export LANG="en_US.UTF-8"
export LC_COLLATE="en_US.UTF-8"
export LC_CTYPE="en_US.UTF-8"
export LC_MESSAGES="en_US.UTF-8"
export LC_MONETARY="en_US.UTF-8"
export LC_NUMERIC="en_US.UTF-8"
export LC_TIME="en_US.UTF-8"
export LC_ALL="en_US.UTF-8"

@randomvariable , @carrickjason , and @SeventhHelix - can you try exporting the environment variables I've listed above to see if it helps resolve your issue(s) with prompt weirdness?

@petermbenjamin I exported the language env variables as shown but the problem remains.

@carrickjason, can you provide some additional information:

Are you using tmux?

If so, what version?
What does the spaceship prompt look like outside tmux and inside tmux?

Have you tried disabling plugins one at a time to rule out specific plugins that could be causing this problem?
Do you only run into this problem when the terminal/shell tries to line-wrap?
What's your environment (e.g. OSX/Win/Linux, terminal application, zsh version, spaceship-prompt version)?

It's very possible that you are all experiencing the same bug we found in OMZ with zsh 5.2: https://github.com/robbyrussell/oh-my-zsh/issues/6818#issuecomment-388925608. Try to reproduce with the following:
zsh -f
autoload -U compinit && compinit
zstyle ':completion:*' menu select

It'll be a while before I'm able to test. Currently on PowerShell (long story).
I also suspect part of my issue was at least dealt with in a previous release of VS Code around multi-line clear (although I can't find the PR where it was fixed).
I'm happy for this to be closed if it's resolved for others.

This issue has cleared up for me since upgrading to a 3.x release.
Thank-you for all your hard work on Spaceship!

Looks like this can be closed per @SeventhHelix and @randomvariable. Does this still happen to you @carrickjason ?
@randomvariable please do make new issue if anything else pops. Thank you @mcornella and @petermbenjamin for the support and information :v:


Add ignored directories/files

This is a continuation of the #33 issue.
Having links being supercharged in the File Explorer is an amazing addition! Thank you @HEmile one more time!
But now I have noticed an issue with this feature. It works really well even when it would be undesirable - like with the template directory/files. Since those files contain e.g. a full list of status attributes (so I could simply delete the unnecessary ones), the template directory looks like a Christmas tree. :-)

Would it be possible to create the "These directories/files will be ignored by the plugin" feature?
https://github.com/dvcrn/obsidian-filename-heading-sync has a really nice Regex ignore feature. It's worth it to check it out for inspiration if you feel like it. :-) For my purposes, the feature can be much simpler - one field with one lonely template directory.
Thank you for considering my request!

Going to close this now as the latest update allows you to style by path. You can restore the default styling by targeting the template folder path to 'exclude' folders.

Thank you, @HEmile !


Handle Owner: Added arg 'handleowner' to JSON credentials file.

Handle Owner: Added arg 'handleowner' to JSON credentials file.
Also adapted handle creation to use this handleowner in HS_ADMIN, if specified. Added unit tests for this.

Hi,
Is the user who normally owns handles still able to modify and delete handles which are created by an other user?
I don't see how this works. Now I also have handles which are f.i created with the HS_ADMIN: 300:0.NA/841. With HS_ADMIN 350:0.NA/841 I am able to do anything with it.
And I don't think there are group bits in the HS_ADMIN field.

Hi cookie,
it all depends on how you configure your users. The admin rights granted in 0.NA/prefix can be "cascaded down" using HS_VLIST entries. For example, we can have a HS_VLIST in 200:0.NA/prefix, pointing to a user and to another HS_VLIST in 200:prefix/admin, which then again points to three different users.
In that case, if as "handleowner" you put 200:0.NA/prefix, everyone with admin rights can modify/delete it. If you put 200:prefix/admin, only the three users can modify it. If you put one of the three users, only that user can modify it.
My idea behind this was that someone may want to give different passwords to different users (Alice and Bob), but we still may want to have handles that can be modified by all users of a specific group (e.g. all EUDAT users).
Note: Of course, if Alice puts Bob as the handle owner, she herself cannot modify the handle anymore - if that is a problem, I can explicitly add another HS_ADMIN entry with the authenticated user.

Hi Merret,
Thanks for the info. I will have a look at it.


Memof fix

fix for fail of:
import numpy
from amuse.units import units

n=10000

for i in range(n):
  vec_i = numpy.random.random(size=[3]) | units.none
  print i, vec_i, vec_i.lengths(), vec_i.lengths().value_in(units.none)

another way to fix this would be to replace the various instances of none_unit('none','none') in e.g. to_simple_form in units/core.py...

This reply won't help the issue a single bit, but if you're only interested in the magnitude of the vectors in units.none, this will workaround the problem:
import numpy
from amuse.units import units

n = 10000
vectors = numpy.random.random(size=(n, 3))
vec_lengths = numpy.linalg.norm(vectors, axis=1) |units.none

The fix is working for my problem. Thanks.


MudMenu: Fix PositionAtCursor

Description

Mudmenu as a Context Menu and in some cases when using PositionAtCursor was not properly setting the position due to the args events relating to the container it's in not necessarily where the popover needed to nest. Our javascript would then jumble that up more and make it near impossible to have consistent behavior. These changes standardize anytime the exact position is known such as args.PageX and args.PageY to not allow javascript to determine position (except flipping behavior). This is accomplished by a class mud-popover-position-override
Additionally added a DataGrid Context Menu example in the Docs section and a MudTable (I don't recommend this, too laggy) and DataGrid example in the UnitTests.Viewer section.
Resolves #3060
Resolves #3854
Resolves #10073
Resolves: #8124
How Has This Been Tested?

Tons of visual tests in first comment
Type of Changes

[x] Bug fix (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)
[x] Documentation (fix or improvement to the website or code docs)

Checklist

[x] The PR is submitted to the correct branch (dev).
[x] My code follows the code style of this project.
[x] I've added relevant tests.

I don't know how to make codecov happy.

This also fixes: https://github.com/MudBlazor/MudBlazor/issues/8124

I fixed all the problems etc. The style check you possible could grab from the popover if you want. But as you can see the codecov doesn't complain anymore.
But I think using the DataGrid in the OpenMenuAsync_Should_Set_FixedPosition() aka DataGridContextMenuTest is too heavy. I would rather just use the code for testing from the #8124
upd: anyway, going bed now, its very late and I'm doing more and more typos in the text.
P.S. I also noticed it's writing in AnchorOrigin, but considering it's old code and was there before, I'm not going to bother for now. This is task for later.

Thanks for this, helped probably more than you know as I learn the code. Moved the AnchorOrigin to the markup instead of the parameter. Also there is a new Doc example with this for the DataGridContextMenuExample. Finally, Added a Viewer item for #8124

I'm reverting the TabsWithBadgesAndLongTabNamesTest.razor and _tabs.scss, they are clearly from the other PR https://github.com/MudBlazor/MudBlazor/pull/10099

This looks very good to me now.

I also think we don't really need DataTableContextMenuActivatorTest.razor as it's duplicates the MenuPositionAtCursorTest.razor just wraps other component, don't think we need to test different combination in this case because it's the same thing.

Just few quick questions before it gets merged
https://github.com/MudBlazor/MudBlazor/blob/fd7132a5df156fc9b160a1c1e6b7a99c48024c27/src/MudBlazor/TScripts/mudPopover.js#L182
https://github.com/MudBlazor/MudBlazor/blob/fd7132a5df156fc9b160a1c1e6b7a99c48024c27/src/MudBlazor/TScripts/mudPopover.js#L326
Shouldn't it be just classList considering
https://github.com/MudBlazor/MudBlazor/blob/fd7132a5df156fc9b160a1c1e6b7a99c48024c27/src/MudBlazor/TScripts/mudPopover.js#L173
and that the rest code is using it?
Or there is some trick behind it?

no trick, it was called fullname sometiems and shortname sometimes. I just standardized all to just classList

Thanks!

The context menu example is broken, the menu is being rendered to the page:

When you click it the wasm app crashes.

The context menu example is broken, the menu is being rendered to the page:

When you click it the wasm app crashes.

@ScarletKuro
In WASM any line that does this or similar causes the app to crash (is not particular to the context menu) and they all work in Server Mode.
await httpClient.GetFromJsonAsync<List>("webapi/periodictable")

The context menu example is broken, the menu is being rendered to the page:

When you click it the wasm app crashes.

@ScarletKuro In WASM any line that does this or similar causes the app to crash (is not particular to the context menu) and they all work in Server Mode. await httpClient.GetFromJsonAsync("webapi/periodictable")

Are we talking about MudBlazor.Docs.Wasm? That's expected since it's doing API call, but there is no server running with the controlled, so just ignore it.

That invisible menu shouldn't be rendered in the first place

That invisible menu shouldn't be rendered in the first place

If I understand what you are saying, all the popovers work that way, inspect a page with a mudselect, mudautocomplete, tooltip, etc find the popover provider element and every popover will be listed there just not visible. The visible ones will have a data-ticks attribute > 0

If I understand what you are saying, all the popovers work that way, inspect a page with a mudselect, mudautocomplete, tooltip, etc find the popover provider element and every popover will be listed there just not visible. The visible ones will have a data-ticks attribute > 0

Are we talking about the Popover Provider? Unfortunately, on this screen, I can't tell if it is coming from the Popover or not. If it is, then that’s expected and unrelated to this PR, it will list all popovers inside it as invisible with empty content. When Open=true, they become visible with their content.
https://github.com/MudBlazor/MudBlazor/blob/43fbb956b46650885a4b25230fece4a1c81ed253/src/MudBlazor/Components/Popover/MudPopoverProvider.razor#L5-L17
This was architected this way long before I joined the team.

looks like what's mentioned isn't from the provider after further research but also it's required. Popover needs a parent to place itself. There's nearly nothing in it, the actual menu is with the provider.

<button type="button" class="mud-button-root mud-button mud-button-text mud-button-text-default mud-button-text-size-medium mud-ripple" _bl_649=""></button>

So to summarize the invisible element needs to be there, but clicking it shouldn't cause a crash, I guess.

I was able to reproduce the issue with this example:
https://github.com/MudBlazor/MudBlazor/blob/43fbb956b46650885a4b25230fece4a1c81ed253/src/MudBlazor.UnitTests.Viewer/TestComponents/DataGrid/DataGridContextMenuTest.razor
There is indeed a hidden clickable element that crashes both server-side and wasm.
The stack trace:
blazor.web.js:1
 crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
      Unhandled exception rendering component: Object reference not set to an instance of an object.
System.NullReferenceException: Object reference not set to an instance of an object.
   at MudBlazorWebAppAuto.Client.Pages.Counter.<BuildRenderTree>b__0_14(RenderTreeBuilder __builder3)
   at Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddContent(Int32 sequence, RenderFragment fragment)
   at MudBlazor.MudMenuItem.<BuildRenderTree>b__53_0(RenderTreeBuilder __builder2)
   at Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddContent(Int32 sequence, RenderFragment fragment)
   at MudBlazor.MudListItem`1[[System.Object, System.Private.CoreLib, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].<BuildRenderTree>b__141_3(RenderTreeBuilder __builder3) in C:\Users\KuroPC\source\repos\MudBlazor\src\MudBlazor\Components\List\MudListItem.razor:line 51
   at Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddContent(Int32 sequence, RenderFragment fragment)
   at MudBlazor.MudText.<BuildRenderTree>b__37_0(RenderTreeBuilder __builder2)
   at Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.AddContent(Int32 sequence, RenderFragment fragment)
   at MudBlazor.MudElement.BuildRenderTree(RenderTreeBuilder builder) in C:\Users\KuroPC\source\repos\MudBlazor\src\MudBlazor\Components\Element\MudElement.cs:line 99
   at Microsoft.AspNetCore.Components.ComponentBase.<.ctor>b__7_0(RenderTreeBuilder builder)
   at Microsoft.AspNetCore.Components.Rendering.ComponentState.RenderIntoBatch(RenderBatchBuilder batchBuilder, RenderFragment renderFragment, Exception& renderFragmentException)

When clicking on it, the popover opens BUT this PR is not the cause of the issue. Setting PositionAtCursor to false or completely reverting this commit does not fix it. Therefore, I am removing the regression label from this PR.

In fact, it's even reproducible on v7: https://try.mudblazor.com/snippet/wkQolPwMqOAZytWz

Null exception is fixed in https://github.com/MudBlazor/MudBlazor/pull/10352


MacOS error: Unable to find package Npgsql.EntityFrameworkCore.PostgreSQL with version (>= 2.0.0)

On MacOS the command "dotnet add package Npgsql.EntityFrameworkCore.PostgreSQL --version 2.0.0"
gives the error for me "error: Unable to find package Npgsql.EntityFrameworkCore.PostgreSQL with version (>= 2.0.0)"
Could you please advise how to solve it?

Solved, Microsoft.EntityFrameworkCore 2.0.0 should be installed previously


Add harshil202

Hey, I change it I need to create a new pull request or it can be done from here?

Hey, I change it I need to create a new pull request or it can be done from here?

You can do it from here. Whatever you commit, will show up in this pull request. Thanks.

Great collaboration!


Allow manual selection of supported authentication methods

Right now we offer the options "Normal password", "Encrypted password" and "Client certificate" during setup. Using a client certificate should complement the password authentication and thus be a separate setting (see #793). That leaves us with "Normal password" and "Encrypted password", which are not terribly useful options. In my opinion the default should be "Automatic" where we select the option we like best and use that. Additionally, we list the individual authentication methods we support. That would allow users to override the automatic behavior in case it doesn't work.
For additional information see issue #2648

@cketti would it still be possible to use only client certificate authentication (no password) with the proposed change? There has been some work in Postfix to make the user case I described in #793 possible. This would make Postfix compatible with AUTH EXTERNAL as implemented in K9 today. I don't have the desire to use both a password AND certificate auth once this is the case.

Just commenting to add my support for client certificate + password as an authentication method. (Is PEAP the correct term to describe this?)
I came here intending to submit this as a feature request. My current mail server back-end (Axigen) does not support the auth external method, but does support securing a connection with a client certificate before password exchange.
Perhaps a tick box could be added for "Use client certificate", which triggers the certificate selection prompt.
Following from that, where "Client certificate" is currently present in the authentication select list, it could be replaced by an "AUTH External" selection?
This way providing support for people that only want to use a certificate, as well as those that want to use certificate + password.


Update references to v2.0.0 revision

What type of PR is this?

Uncomment only one  /kind <> line, hit enter to put that in a new line, and remove leading whitespaces from that line:
/kind bug
/kind cleanup
/kind design
/kind documentation
/kind failing-test

/kind feature

/kind flake

What this PR does / why we need it:
This change uses the latest catalog revision number for R2
Which issue(s) this PR fixes:

Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?:

/approve
/lgtm

/unapprove

Fixing the repository tag repo
/retest

/lgtm
/approve


#1665 Poetry Implementation

Description
This involved a huge overhaul of the way we run docker-compose.*yml and Dockerfiles. The various README files have been updated.
Github actions had to be changed as well, so we can use Poetry in place of requirements files.
Removed scanning for PII and is_provider_enabled because both were failing and neither are used.
Lastly, the unit tests were continuously hitting deadlocks. I had to keep modifying the teardown of dozens of files to get the deadlocks to stop.
Load testing requirements files have not been removed. We have several tickets related to changing the way we do load testing such as this spike.
issue #1665
Type of change
Please check the relevant option(s).

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

How Has This Been Tested?

Local build tested
Local migration tested
Local unit tests tested
on PR action to run unit tests, code scan, and dependency scan pass
Cloud migrations pass
Regression tests pass

Checklist

[x] I have assigned myself to this PR
[x] PR has an appropriate title: #9999 - What the thing does
[ ] PR has a detailed description, including links to specific documentation
[x] I have added the appropriate labels to the PR.
[ ] I did not remove any parts of the template, such as checkboxes even if they are not used
[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my own code
[x] I have commented my code, particularly in hard-to-understand areas
[x] I have made corresponding changes to any documentation
[x] My changes generate no new warnings
[ ] I have added tests that prove my fix is effective or that my feature works
[x] I have ensured the latest master is merged into my branch and all checks are green prior to review
[x] New and existing unit tests pass locally with my changes
[ ] Any dependent changes have been merged and published in downstream modules
[ ] The ticket is now moved into the DEV test column

The "Waiting for status to be reported" status checks have been ran, just with a "tests/" prefix. After this PR is merged I can update the repo settings to look at the new location. If I update before this PR is merged all other PRs would fail.


winIco doesn't appear to be changing the .exe icon

I'm building on a windows 8 box. When I explore my .exe using winresourcer, I see that it has both the default nw.ico and the .ico I am trying to replace it with.  Seems it should be replacing the default. My custom .ico is second in the list and the nw.ico is first.

When I browse to the directory to where the .exe is, I still see the default nw.ico.

Figured this out. Either our .ico was too large or Windows just didn't like the format. Also, make sure when an ico changes, your PC is restarted to see the changes. Windows caches the .ico files.

This may or may not help in the future


Bardock Follower Node not updating after Deploy

When we deploy the Bardock Follower Node using teh Ansible script - initially - the node syncs and deploys showing a block height close to movement's deployed bardock endpoint. After some time however as blocks are produced on Bardock - the follower node does not continue to sync and appears to be stuck.
To Reproduce
Steps to reproduce the behavior:

Deploy Follower Node using provided Ansible Script
Wait until new blocks are prouced
Observe no changes on deployed follower node compared to deployed movement node

Expected behavior
As new block are produced the follower node should reflect this on its endpoint
Additional context

Deployed with container version ab3fc9b450d5a2dc5446a290f84e9c093ac08c67

Log output from docker logs suzuka-full-node | tail
Truncating State KV DB: current: 8409, target: 8409
2024-11-14T05:05:11.333441Z  INFO maptos_fin_view::service: Starting maptos-fin-view services at: "<IP_ADDRESS>:30733"
2024-11-14T05:05:11.338912Z  INFO poem::server: listening addr=socket://<IP_ADDRESS>:30733
2024-11-14T05:05:11.338923Z  INFO poem::server: server started
2024-11-14T05:05:11.338925Z  INFO poem::server: listening addr=socket://<IP_ADDRESS>:30731
2024-11-14T05:05:11.338934Z  INFO poem::server: server started
2024-11-14T05:05:11.363527Z  INFO maptos_opt_executor::executor::execution: Block execution compute the following state: StateComputeResult { root_hash: HashValue(a85718a0c292ae01a10d9471971ff453d51f39e0e1c47cde19c31cadfddcef64), frozen_subtree_roots: [HashValue(c2e46e4e2bc85095c730ee76a9d791d4e729e173a7acdc3718535fc7c8463fe5), HashValue(e8288b1222826122437009a7feaa68f5fe8444e13fbe28c407c58510e609d495), HashValue(a733019ef689c42a0b1193364010000d5dde76cd9635a8a65029990387bb823d), HashValue(29edb3b5c312fa21a22d8529a89b1d067aca38295a82ebe4b593976124e891ee), HashValue(48fc1f661065bbf57c8e43601aa902412e1ec05e75ba1508c79f9416abdaa18d), HashValue(c885bb244f36f02736f43460f24eebe4bd3359c8fe1a138fdf570ea5c6aa2b3b)], parent_frozen_subtree_roots: [HashValue(c2e46e4e2bc85095c730ee76a9d791d4e729e173a7acdc3718535fc7c8463fe5), HashValue(e8288b1222826122437009a7feaa68f5fe8444e13fbe28c407c58510e609d495), HashValue(a733019ef689c42a0b1193364010000d5dde76cd9635a8a65029990387bb823d), HashValue(29edb3b5c312fa21a22d8529a89b1d067aca38295a82ebe4b593976124e891ee), HashValue(48fc1f661065bbf57c8e43601aa902412e1ec05e75ba1508c79f9416abdaa18d), HashValue(b6b015eda500f38364a14858c99a181366c6c7abb94e93b8da8addfb4be82924)], num_leaves: 8412, parent_num_leaves: 8410, epoch_state: None, compute_status_for_input_txns: [Keep(Success)], transaction_info_hashes: [HashValue(9db0884b7386954f7630cb00ea10b07c39be0afa82f8b0ebb05cb24778107a6d), HashValue(0dc8b130e5efa15637e08ec052b4d17d5c8a0ccd41230007f533c0ed086434ee)], subscribable_events: [], block_end_info: None }
2024-11-14T05:05:11.363555Z  INFO maptos_opt_executor::executor::execution: Block execution computed the following version: 8411
2024-11-14T05:05:11.376443Z  INFO suzuka_full_node::tasks::execute_settle: Synced height: 505863
2024-11-14T05:05:11.380904Z  INFO aptos_indexer_grpc_utils::counters: [Indexer Table Info] Processed batch successfully start_version=8410 end_version=8412 num_transactions=2 duration_in_secs=0.002920814 service_type="table_info_service" step="1"
2024-11-14T05:05:11.382205Z  INFO aptos_indexer_grpc_utils::counters: [Indexer Table Info] Processed successfully start_version=8410 end_version=8411 num_transactions=2 duration_in_secs=0.070875473 service_type="table_info_service" step="2"

We are also facing the same issue
Container version - ab3fc9b450d5a2dc5446a290f84e9c093ac08c67.
Log output from docker logs suzuka-full-node | tail
2024-11-15T07:16:25.143284Z  INFO maptos_fin_view::service: Starting maptos-fin-view services at: "<IP_ADDRESS>:30733"
2024-11-15T07:16:25.147675Z  INFO poem::server: listening addr=socket://<IP_ADDRESS>:30733
2024-11-15T07:16:25.147690Z  INFO poem::server: server started
2024-11-15T07:16:25.147707Z  INFO poem::server: listening addr=socket://<IP_ADDRESS>:30731
2024-11-15T07:16:25.147717Z  INFO poem::server: server started
2024-11-15T07:16:25.176907Z  INFO maptos_opt_executor::executor::execution: Block execution compute the following state: StateComputeResult { root_hash: HashValue(7ef53505028ee42955354315f6aeb47ebe03fe2e315298d79033dbf3137162ba), frozen_subtree_roots: [HashValue(c2e46e4e2bc85095c730ee76a9d791d4e729e173a7acdc3718535fc7c8463fe5), HashValue(e58c610ede5e8a60c572d0e055f03873d038e62b1fa7c37f065304b563ca0a82), HashValue(7713b315c7ae31eb245b8c514c83fc89491e5163732c0b0a015ed645cb3a8329), HashValue(315f8030c4cba200591edc04881456ed50d8ff8c12d606c6949256a2fb8b5ac6)], parent_frozen_subtree_roots: [HashValue(c2e46e4e2bc85095c730ee76a9d791d4e729e173a7acdc3718535fc7c8463fe5), HashValue(e58c610ede5e8a60c572d0e055f03873d038e62b1fa7c37f065304b563ca0a82), HashValue(7713b315c7ae31eb245b8c514c83fc89491e5163732c0b0a015ed645cb3a8329), HashValue(935d4085cde550f38101a076feeb9d5876bbb324b2cdf20d7695086b462350b1)], num_leaves: 8580, parent_num_leaves: 8578, epoch_state: None, compute_status_for_input_txns: [Keep(Success)], transaction_info_hashes: [HashValue(b81198715cdb69c6cd65b36f3631de146d6e75ce481748ac3b93e69d20ac8ccf), HashValue(4b58fd405961c2ec747250aa49751b491262dcdb9be66083c245f3809abf1ff2)], subscribable_events: [], block_end_info: None }
2024-11-15T07:16:25.176935Z  INFO maptos_opt_executor::executor::execution: Block execution computed the following version: 8579
2024-11-15T07:16:25.199922Z  INFO suzuka_full_node::tasks::execute_settle: Synced height: 553596
2024-11-15T07:16:25.208490Z  INFO aptos_indexer_grpc_utils::counters: [Indexer Table Info] Processed batch successfully start_version=8578 end_version=8580 num_transactions=2 duration_in_secs=0.004390636 service_type="table_info_service" step="1"
2024-11-15T07:16:25.210676Z  INFO aptos_indexer_grpc_utils::counters: [Indexer Table Info] Processed successfully start_version=8578 end_version=8579 num_transactions=2 duration_in_secs=0.08582601 service_type="table_info_service" step="2"

Related to this: https://github.com/movementlabsxyz/movement/issues/695


emacsPackages.org-roam: init at 0.1.2

Motivation for this change
org-roam seems to be a nice package, but it's not packaged into melpa/elpa
Things done

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

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

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

I'm running it now and it works fine.

Could you try to get upstream to upload the package to elpa/melpa?

Sure. Asked for that in https://github.com/jethrokuan/org-roam/issues/171

I'd like to upload to MELPA when things become more stable, which is when I decide it's version 1.0.0.

A melpa release won't happen any time soon. The question is, do we want org-roam in nixpkgs now, or should I stash it in my overlay?
I would go for nixpkgs as org-roam is quite an active project and gets excellent traction (see pulse). I've been using 0.1.2 for two weeks now, and I find it quite stable and useful.
@adisbladis, what do you think?

A melpa release won't happen any time soon.

Within the next week I think!

oh wow. that's great news! I think we should wait then :)

Great! I was just going to say "let's just add it", but if a proper MELPA release is coming soon then let's wait for it :)

I'm closing this for now since the package will arrive in Nixpkgs through the usual MELPA workflow.

Can we now install org-roam from our NixOS configuration?
I've tried the obvious way, by adding org-roam to my epkgs.melpaStablePackages definitions, and I get the following error when I try to build:
error: undefined variable 'org-roam' at /etc/nixos/emacs.nix:16:7

Two of you have made public your NixOS configurations; I cloned them and grepped (case insensitive) for roam and found nothing.
Here's the commit where I made the change, and here's the complete file including that change.

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/emacs-can-i-install-a-package-declaratively-after-trying-it-out-procedurally/7559/1

Hey @JeffreyBenjaminBrown!
It's in melpaPackages, not melpaStablePackages. Move org-roam just a couple of lines below under with melpaPackages—that should help.

I tried putting it under melpa instead of melpaStable. I even tried under elpa. They all give me the same error, except with a different line number.
It's as if Nix is looking at an old Melpa repo when it tries to build my config. Your config includes company, which I didn't know about and looks cool, so I tried adding that to my melpaPackages declarations and it installs fine. But company-roam and org-roam generate errors when I do likewise with them.
So I tried adding the overlay you mentioned. First time overlaying, and I don't know if I added it the right way. How I added the overlay didn't generate an error but neither did it solve this problem.
I tried to understand your .org file that turns into your .nix files.  When I run org-babel-tangle it actually deletes the three lines containing the word roam from the .nix files in your repo, but I tried studying those files after restoring them to their original state and can't make heads or tails of it.

{ pkgs ? import <nixpkgs> {} }: {} is syntax for "create a function that takes an attrset where pkgs defaults   to import <nixpkgs> {}".
The thing is you are explicitly passing pkgs here https://github.com/JeffreyBenjaminBrown/nixos-experiments/blob/master/packages.nix#L5 which makes the entire overlay addition moot.
What you should be doing is adding the overlay to the NixOS option nixpkgs.overlay as shown in the overlay README: https://github.com/nix-community/emacs-overlay#latest-master-each-rebuild.

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/my-first-overlay-for-emacs/7570/1

Thanks! I thought that might be happening, but it was the only thing I tried that compiled.
I had looked at the section of the emacs-overlay README you mention, and also the NixOS wiki article on overlays, and was totally baffled. I just started a new thread on the NixOS Discourse to tackle that problem.


ARM romtable components identification

This PR adds identification of components from the romtable.
This can be used to find e.g. the itm peripheral location on different devices.
It can also identify many STM32 parts.

This fixes #394 mostly.
To fully fix it, there will need to be support for the STM32H7 specific DBGMCU peripheral. That should be a different PR.
Shall I make a separate issue for that?

So am I right to understand that this fixes proper discovery but not ITM use on the H7 as it is not properly enabled?
Looks great to me =)
If I understand this right, yes, please make a separate issue :)

Hmm I am not sure how to deal with manufacturer specific code tbh.
I have always fought hard to not have manufacturer specific code in generic implementations. Otherwise we go down the OpenOCD road which I want to avoid at all cost.
I see the need for this kind of thing tho, the question is just how we handle it best :)

Let's discuss that in #446

Let's discuss that in #446 (unless you mean the STM32ID stuff in this PR)

It concerns both, but I am fine discussing it over there :)

I've removed the STM bits, so it should all be generically arm now


Can't sign Taproot tx when using privacy mode

Hello,
I am using two Sparrow instances version 1.7.6. One is offline for signing and the other as watch-only on an online device. Both devices run Debian 11. The wallet is BIP39 Taproot with passphrase and the default 86' derivation.  After creating a transaction with the watch-only wallet using privacy mode and then loading the PSBT file into the offline Sparrow and clicking Finalize Transaction for Signing then clicking Sign, I noticed the blue progress bar fills up but then nothing happens. Specifically, the buttons do not change to the expected "View Final Transaction" and "Save Final Transaction". This issue only happens when using privacy mode when creating the transaction and it does not happen when using efficiency mode. The log file does not show any new lines/entries. Please let me know if there is any additional information that I can provide to help troubleshoot this issue.
Thank you for your time

Try increasing the gap limit on your signing wallet so that it contains all the addresses reflected in the watch-only wallet. Settings > Advanced > change > Close > Apply.

That worked! Thank you very much.


Feature Request: Allow Setting encoder to None When Using Pre-Computed Embeddings

Currently, the KeyNMF constructor requires the encoder argument to be specified as a string:
keynmf_model = KeyNMF(
    n_components=num_topics,
    top_n=top_n,
    encoder='sentence-transformers/all-mpnet-base-v2',
    vectorizer=CountVectorizer(min_df=1)
)

This triggers the encoder model download via SentenceTransformers, even when embeddings are pre-computed and used later during model fitting:
sent_trans_model = SentenceTransformer("sentence-transformers/all-mpnet-base-v2")
embeddings = sent_trans_model.encode(texts)

keynmf_model.fit(texts, embeddings)

Loading the encoding model each time the constructor is called, especially within a loop (e.g., for topic number optimization), becomes inefficient and time-consuming.
Suggestion: Allow setting the encoder parameter to None in the constructor when using pre-computed embeddings. This would prevent unnecessary downloads and streamline the workflow for users who prefer to compute embeddings once and reuse them.

Hey @mjaniec2013 . Thanks for taking your time to write this. The issue is that KeyNMF also needs to learn and embed the vocabulary of the corpus, and that's why it requires the embedding model. There is an update on the way (very possibly this weekend or next week), where you will be able to extract the keywords with KeyNMF once, and then the vocab doesn't need to be encoded on the spot, I will make sure to comment on this issue when that happens.
A sensible way to deal with your problem for now would be to preload the encoder model in your code, and then use the SentenceTransformer object itself instead of the string you're now passing to KeyNMF.
Here's an example:
sent_trans_model = SentenceTransformer("sentence-transformers/all-mpnet-base-v2")
embeddings = sent_trans_model.encode(texts)

for n in range(10, 50, 10):
    keynmf_model = KeyNMF(n_components=n, encoder=sent_trans_model)
    keynmf_model.fit(texts, embeddings=embeddings)
    ...

This way the sentence encoder does not need to be loaded on each run. Like I said, this process will be made much more streamlined in the next release. Tell me if I can be of help in the meanwhile.

Hello,
Thank you very much for the answer. As you suggested, passing a model instead of the string solves the issue of repeating model loading at initialization, resulting in 20% time savings for the optimization loop.

While the issue is solved, I've reopened the issue while waiting for the info on the upcoming update mentioned in the response.

The update came out yesterday! In Turftopic 0.4.0 you can precompute keyword matrices with a KeyNMF model and then use them later in training.
from turftopic import KeyNMF
from sentence_transformers import SentenceTransformer

encoder = SentenceTransformer("sentence-transformers/all-mpnet-base-v2")

extractor_model = KeyNMF(
    # It doesn't matter what you choose, only comes into effect when calling fit()
    n_components=10,
    # You should probably choose a larger N than needed.
    # If the models you train afterwards has lower top_n, it will prune the keyword matrix anyway
    top_n=30,
    encoder=encoder,
)
# Here we extract the keywords
keyword_matrix: dict[str, float] = extractor_model.extract_keywords(texts)

for n in range(10, 50, 10):
    keynmf_model = KeyNMF(
          n_components=n,
          # This is no longer strictly necessary, the keyword matrix already contains all of the needed information
          encoder=encoder
    )
    keynmf_model.fit(keyword_matrix)

This is even faster than precomputing the embeddings, because the vocabulary and its embeddings also get learned and the only thing that has to happen inside the loop is the matrix decomposition step.

I've updated turftopic module to 0.4.3.

pip show turftopic

Name: turftopic
Version: 0.4.3
Summary: Topic modeling with contextual representations from sentence transformers.
Home-page:
Author: Márton Kardos

Unfortunately, the fit method does not have the keywords argument, allowing using a pre-computed documents-keywords list. I'm able to derive it from the input texts, but cannot use it as you suggested:
tokens_joined = [" ".join(token) for token in tokens]

keynmf_model = (KeyNMF(n_components=num_topics,
top_n=top_n,
encoder=sent_trans_model, # 'sentence-transformers/all-mpnet-base-v2',
vectorizer=CountVectorizer(min_df=1)))
# fit(tokens_joined, embeddings=embeddings))

if keywords_matrix is None:

keywords_matrix = keynmf_model.extract_keywords(tokens_joined)

keynmf_model = keynmf_model.fit(keywords=keywords_matrix)

keynmf_topics = keynmf_model.get_topics()

topics = reformat_topics(keynmf_topics)

Error:
keynmf_model = keynmf_model.fit(keywords=keywords_matrix)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: ContextualModel.fit() got an unexpected keyword argument 'keywords'

Sorry about that. I fixed this yesterday in 0.4.4.
Beware that you also have to pass something for the corpus when fitting the model, as scikit-learn requires it.
model.fit(None, keywords=keywords)

It's me who should be sorry for taking your time :)
Nevertheless, the optimization function looks to work as intended now - thank you!
    def _get_coherence_keynmf(self, num_topics : int) -> float:

        # global tokens, corpus, dictionary, embeddings, top_n, sent_trans_model, keywords_matrix

        tokens_joined = [" ".join(token) for token in self.tokens]

        keynmf_model = KeyNMF(n_components=num_topics,
                              top_n=self.top_topic_keywords,
                              encoder=self.sent_trans_model,  # 'sentence-transformers/all-mpnet-base-v2',
                              vectorizer=CountVectorizer(min_df=1))

        if self.keywords_matrix is None:
            self.keywords_matrix = keynmf_model.extract_keywords(tokens_joined)

        keynmf_model = keynmf_model.fit(keywords=self.keywords_matrix)

        keynmf_topics = keynmf_model.get_topics()

        topics = self._reformat_topics(keynmf_topics)

        coherence_model = CoherenceModel(topics=topics,
                            texts=self.tokens,
                            dictionary=self.dictionary,
                            topn=self.top_topic_keywords,
                            coherence='c_v',
                            processes=-1)

        return coherence_model.get_coherence()

The function / method is additionally cached to eliminate redundant calculations in the optimization lopp.


Buggy timestamps

Looks like live instance of the bot is 2h after UTC+1 (Timezone that wykop uses)

I will check that, thanks!

@feelfreelinux not 2h before? it would match then the regular UTC (Wykop uses now CEST so UTC+2)


Add react to importation on react hooks

Description
Fix #1426
This PR was opened but was not complete => https://github.com/reactjs/reactjs.org/pull/1438
What do you think guys?

Closing this PR as the addressed issue is already resolved.
Thank you for taking time to contribute!


Set resource limits/requests for the webhook server deployment

What does this PR do?
Add environment variables to the controller deployment that govern memory/cpu limits/requests for the webhook server deployment.
I opted to just use the values we have for the DevWorkspace controller for now. Some testing should be done to see if these are appropriate or if other settings should be used.
What issues does this PR fix or reference?
No resources specified for webhooks server
Is it tested? How?
make install and check that resources are set on the devworkspace-webhook-server deployment.

/test v7-devworkspaces-operator-e2e


SEO issue:  tag ignores any actions of page/block controller

Now we can add <meta rel="canonical"> tag to concrete5 site by #5818 .
The URL value in the href attribute respects query string from a Response object instance, but it ignores any actions.
For example, when you using Express Entry Detail block, you can get pages of the detail of Express entry like...
https://www.examplec.com/foo/view_express_entity/123
The problem is all of the detail pages have the same canonical URL, so these pages will not be indexed by search engines.
<link rel="canonical" href="https://www.examplec.com/foo">

Of course, it should contain a full path URL.
<link rel="canonical" href="https://www.examplec.com/foo/view_express_entity/123">

I think this is a bug, and it has serious SEO issue for the sites using the Express database.
I'd like to hear opinions from our community. Thanks!

This makes sense – this is absolutely something we'd accept; it's not on our radar right now though because we don't use the express entry detail block very often.


Normalized C and Java definition of isDimDefined.

The JavaScript implementation of isDimDefined contains a check to ensure
that the dimension value is positive; the C and Java versions did not
have this check. As a result, a negative style value for 'width' (such
as that used by the "should layout node with negative width" test) would
have different layout under the C/Java implementation to the JavaScript
implementation.
This was hidden because the C/Java transpilers filtered out any negative
instantiation values from the test suite. In effect, the negative value
tests weren't running on the C/Java implementation.
This patch removes the negative value filter from the transpiler, and
makes the isDimDefined definition consistent between the three
implementations.

Good catch! Thanks for sending this pull request :)


Increase test coverage to 100%

Q
A

Is bugfix?
❌

New feature?
❌

Breaks BC?
❌

Fixed issues
#7

👍


Mark plugin as thread-safe

[WARNING] *****************************************************************
[WARNING] * Your build is requesting parallel execution, but this         *
[WARNING] * project contains the following plugin(s) that have goals not  *
[WARNING] * marked as thread-safe to support parallel execution.          *
[WARNING] * While this /may/ work fine, please look for plugin updates    *
[WARNING] * and/or request plugins be made thread-safe.                   *
[WARNING] * If reporting an issue, report it against the plugin in        *
[WARNING] * question, not against Apache Maven.                           *
[WARNING] *****************************************************************
[WARNING] The following plugins are not marked as thread-safe in batch-operator-openapi:
[WARNING]   io.github.belgif.rest.guide.validator:belgif-rest-guide-validator-maven-plugin:2.1.0
[WARNING]
[WARNING] Enable debug to see precisely which goals are not marked as thread-safe.
[WARNING] *****************************************************************

Is the belgif-rest-guide-validator-maven-plugin thread-safe?
If so, can it be marked as such in the plugin descriptor, so we can avoid the warning above in a parallel build?
That can be done by adding threadSafe = true to the @Mojo annotation.

We'll check the code, especially the xml output code, for thread safety issues.
Multiple executions in same module may conflict bc writing to same output, but that probably doesn't need to be considered
(based on https://stackoverflow.com/questions/50247168/how-to-make-sure-that-a-maven-plugin-is-thread-safe )


844 Fix the Python version to match the one in Bookworm.

This is necessary for it to be deployed to the production server.

Fixes #846

This fixes #844

Stale. See #845