Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade fmt to 10.1.1 (from 8.0.1) #7941

Closed
wants to merge 40 commits into from

Conversation

assignUser
Copy link
Collaborator

@assignUser assignUser commented Dec 8, 2023

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during #7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes #7896

Copy link

netlify bot commented Dec 8, 2023

Deploy Preview for meta-velox canceled.

Name Link
🔨 Latest commit 430e425
🔍 Latest deploy log https://app.netlify.com/sites/meta-velox/deploys/65810dfb52f558000865d90d

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Dec 8, 2023
@assignUser assignUser changed the title [wip] Upgrade fmt to 10.1.1 (from 8.0.1) Upgrade fmt to 10.1.1 (from 8.0.1) Dec 8, 2023
@assignUser assignUser marked this pull request as draft December 8, 2023 18:31
@assignUser
Copy link
Collaborator Author

cc @majetideepak

@kgpai
Copy link
Contributor

kgpai commented Dec 8, 2023

LG, Any reason its in draft ?

@assignUser
Copy link
Collaborator Author

Copy link
Collaborator

@majetideepak majetideepak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@assignUser Nice progress! Some high-level comments. Can you apply them to other changes as well? Thanks.

velox/common/caching/AsyncDataCache.cpp Outdated Show resolved Hide resolved
velox/common/caching/AsyncDataCache.cpp Outdated Show resolved Hide resolved
velox/common/caching/AsyncDataCache.cpp Outdated Show resolved Hide resolved
velox/common/memory/ByteStream.cpp Outdated Show resolved Hide resolved
velox/common/memory/ByteStream.cpp Outdated Show resolved Hide resolved
velox/common/memory/tests/MemoryAllocatorTest.cpp Outdated Show resolved Hide resolved
velox/common/memory/tests/MemoryManagerTest.cpp Outdated Show resolved Hide resolved
velox/common/memory/tests/MemoryPoolTest.cpp Outdated Show resolved Hide resolved
velox/common/memory/tests/MockSharedArbitratorTest.cpp Outdated Show resolved Hide resolved
@assignUser
Copy link
Collaborator Author

Looks like everything builds correctly now but we have some fuzzer and unit test failures.

@majetideepak
Copy link
Collaborator

@assignUser, Do you see these unit test failures in your local build as well? Or are these only on CI?

@assignUser
Copy link
Collaborator Author

@majetideepak testing that now, it's surprisingly involved to run the failing test from CI locally... maybe velox_exec_test should be split up to not be ~1k tests that take 10 minutes to run^^

@assignUser
Copy link
Collaborator Author

assignUser commented Dec 14, 2023

Also is it intentional that ✔️ tests produce pages worth of errors? (which is also probably the reason why the log is so large that CCI doesn't save the full log)

E1214 13:03:06.053968 879571 Exceptions.h:69] Line: /home/jwj/code/velox/./velox/exec/Spiller.h:181, Function:setPartitionsSpilled, Expression: type_ == Spiller::Type::kHashJoinProbe (0 vs. 3) Unexpected spiller type: , Source: RUNTIME, ErrorCode: INVALID_STATE
E1214 13:03:06.054023 879571 Exceptions.h:69] Line: /home/jwj/code/velox/velox/exec/Spiller.cpp:484, Function:spill, Expression: !finalized_ Spiller has been finalized, Source: RUNTIME, ErrorCode: INVALID_STATE
E1214 13:03:06.054060 879571 Exceptions.h:69] Line: /home/jwj/code/velox/velox/exec/Spiller.cpp:521, Function:spill, Expression: !finalized_ Spiller has been finalized, Source: RUNTIME, ErrorCode: INVALID_STATE
E1214 13:03:06.054097 879571 Exceptions.h:69] Line: /home/jwj/code/velox/velox/exec/Spiller.cpp:479, Function:spill, Expression: type_ == Type::kAggregateOutput (0 vs. 1), Source: RUNTIME, ErrorCode: INVALID_STATE
[       OK ] SpillerTest/NoHashJoin.spilFew/1 (481 ms)

@majetideepak
Copy link
Collaborator

Also is it intentional that ✔️ tests produce pages worth of errors?

I noticed this as well. I don't think this is the intention. We should fix this.

@majetideepak
Copy link
Collaborator

it's surprisingly involved to run the failing test from CI locally.

You should be able to use --gtest_filter to pick a particular test in the target. Can you try this test that seems to fail in the linux-adapters CI?
./cmake-build-debug/velox/core/tests/velox_core_test --gtest_filter=TypedExprSerDeTest.concat

@assignUser
Copy link
Collaborator Author

ah I was relying on the ctest -R option that only filters by test executable name. Good to know. The test passes.

@assignUser
Copy link
Collaborator Author

It seems like fbthrift (in the version we install) is not compatible with newer fmt https://github.com/facebookincubator/velox/actions/runs/7210627614/job/19644209080?pr=7941#step:5:5004

@assignUser
Copy link
Collaborator Author

assignUser commented Dec 14, 2023

I am pretty sure that the ci issues are mostly caused by version conflicts with the pre-built images. I am going to rebuild the image and upload under a different tag (combined with #7700 ) and use that temporarily maybe not...

@kgpai
Copy link
Contributor

kgpai commented Jan 5, 2024

Starting import of this to check the changes required internally. Thanks for this change @assignUser !

@facebook-github-bot
Copy link
Contributor

@kgpai has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@kgpai
Copy link
Contributor

kgpai commented Jan 10, 2024

@assignUser @majetideepak Just wanted to update you folks: There are some significant number of internal build failures due to this . I will need a few days to resolve them.

@assignUser
Copy link
Collaborator Author

There is also the issue with the test @majetideepak mentioned, it seems this is for escaping postgres? Good you shed some light on that and fix the test/the formating for that bit as I don't understand what's intended there. Apart from that this should be fine (on this side at least^^).

kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 18, 2024
Summary:
fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: f11b62cb69aee0776170e972948321410cfd4802
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 18, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: ae9d58575d416519d8d0447380564083da88b4a3
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 18, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: a3ff1859a0df00a9b49f400665f0b16d6f27acba
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 19, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: ea6797059930351aad170eee19026b183d352fd2
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 19, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: b0724355657f2303d115da5b82572f1cbf3ada72
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 19, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: 773c88c41c4b7c786fbf108e4257cfe7c3cc2594
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 19, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: 68db12f6c67e968562122d324d0a9f9e06ea1f62
@@ -320,11 +320,10 @@ class FieldAccessTypedExpr : public ITypedExpr {

std::string toString() const override {
if (inputs().empty()) {
return fmt::format("{}", std::quoted(name(), '"', '"'));
return fmt::format("{:?}", name());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, This change breaks koski internally, so not sure why this change is being made. I am removing this in #8434 (fyi I wont merge 8434 but will merge this one after I get passing signals from 8434. I will also be redoing those changes to this PR).

@@ -240,3 +240,10 @@ int main(int argc, char* argv[]) {

return 0;
}

template <>
struct fmt::formatter<TpchBenchmarkCase> : formatter<int> {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, All the formatter<...> can be replaced with the much simpler format_as() . I will make those changes too..

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that will make it not be backwards compatible with < 9

Copy link
Collaborator Author

@assignUser assignUser Jan 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(just an fyi as prestissimo uses fmt 8.1 afaik)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah ok - This was failing in buck with specialization before instantiation , but I think theres another way around it.

wget_and_untar https://archive.apache.org/dist/hadoop/common/hadoop-2.10.1/hadoop-2.10.1.tar.gz hadoop
wget_and_untar https://github.com/protocolbuffers/protobuf/releases/download/v21.4/protobuf-all-21.4.tar.gz protobuf

FB_OS_VERSION="v2023.12.04.00"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this intentional do we plan to upgrade folly and format in this pr ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Kind of but not really, only the preinstalled version in the container. This is necessary as mvfast doen't have a version for our old tag and is required for fbthrift. I tried a few older tags of mvfast but I was unable to find a combination of tags of folly and the others that compiled successfully. That's also why I sed out the deprecated annotation from the header further down in the script.

kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 19, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: 399ff634da95321a05b342adb2ead9f14792ed5c
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 19, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: 0c4d1ce4f18eca10f69cea7301cc849680767b95
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 19, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: 1d8704484a14b9f03ee8c709ed283d5e586d35c4
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 20, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: 1a1c070399a33d0202b284f045db3ab5081966cb
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 20, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: e847ab3bb268d950a1d82ad2f6b3cd9d18baa70d
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 20, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: f49db1561006fdd5c876b28a727f104d5aab4a58
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 20, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: 4c8aa99b6be6a7dc1d2f4854145830f1254fbd2c
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 20, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: cf96653f76ff2d3c8c802c8230107515a36cb440
kgpai pushed a commit to kgpai/velox-1 that referenced this pull request Jan 20, 2024
Summary:
Pull Request resolved: facebookincubator#8434

fmt 8.0.1 is not upwards compatible to 9+ but backwards compatibility should not be an issue from what I could see in the logs and have done during facebookincubator#7700 (newst folly is compatible with fmt 10 but we built it with 8.0.1).

Closes facebookincubator#7896

Pull Request resolved: facebookincubator#7941

Reviewed By: Yuhta

Differential Revision: D52880145

Pulled By: kgpai

fbshipit-source-id: 8f7e8d8d69ac3260a040eb8ae0b43432c87f6841
@facebook-github-bot
Copy link
Contributor

@kgpai merged this pull request in 1deb036.

Copy link

Conbench analyzed the 1 benchmark run on commit 1deb0368.

There weren't enough matching historic benchmark results to make a call on whether there were regressions.

The full Conbench report has more details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. Merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make Velox compatible with fmt >= 9
6 participants