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

LocoKit SPM resolve warning #79

Open
BrianBatchelder opened this issue Jun 9, 2021 · 2 comments
Open

LocoKit SPM resolve warning #79

BrianBatchelder opened this issue Jun 9, 2021 · 2 comments

Comments

@BrianBatchelder
Copy link

BrianBatchelder commented Jun 9, 2021

FYI: while building the latest ArcMini, Xcode spit out the following warning:

found 1 file(s) which are unhandled; explicitly declare them as resources or exclude from the target
    .../DerivedData/Arc_Mini-dlenhigbcoeldyfxldburkutnfjk/SourcePackages/checkouts/LocoKit/LocoKit/Timelines/ActivityTypes/CoordinateBins.fbs

Not sure if this is a LocoKit or ArcMini issue.

@sobri909
Copy link
Owner

That's a LocoKit issue, and one I'll get cleaned up shortly. Thankfully it's harmless - I've just moved a non-code file into the repo and not told the Package.swift about it.

Some context on the file, for interest's sake: LocoKit loads its ActivityType ML models from database, and the slowest part of that is the serialised coordinate matrices. I'd previously been using a custom serialisation (to save db space, and make it easier for me to eyeball the strings in the db).

Deserialising that string was a performance bottleneck, that caused brief recording glitches when transitioning between D2 model regions (due to switching in a new D2 classifier, thus loading models from db for the new D2 region). It also caused UI freezing in some cases, when navigating to old timeline views of different geographic regions in Arc v3. (It's less obvious in Arc Mini because there's no calendar view, so you can really only swipe back day by day).

Anyway I've got around that by using FlatBuffers to do the serialising/deserialising. Much faster, no freezes, no glitches. And that .fbs file is the (unnecessary) FlatBuffers data structure description. It's only used when recreating the generated code (CoordinateBins.swift). But I figured it's important to have it there with the code, for if/when that recreating is needed.

Anyway tldr: I'll change the Package.swift to ignore it 😂

@BrianBatchelder
Copy link
Author

Thanks for the thorough answer! I fully support keeping the things that generate the code with the code. I can't tell you how many times I've tried to go back in time to reproduce a problem but be unable to reproduce it, or unable to debug it, because the VCS didn't include something that was generated or was used to generate something else.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants