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

Different installation instructions #7

Open
kylemh opened this issue Aug 21, 2019 · 12 comments
Open

Different installation instructions #7

kylemh opened this issue Aug 21, 2019 · 12 comments

Comments

@kylemh
Copy link

kylemh commented Aug 21, 2019

Quick aside... Hoping to create a public-facing GraphQL server for NFL Fantasy stuff, and I think your repo will be a very symbiotic thing for me! I'm not interested in maintaining the database schema or migrations, so thank you for that work.


The real issue

Using latest MacOS...

  • I downloaded and unzipped the tar for MacOS
  • I tried running ffdb setup from outside and within the folder
@rushfive
Copy link
Owner

Hey man, that sounds like an awesome project, good luck on it! I'm really into fantasy football myself ha.

As for using it on Mac, I'm actually not able to debug this as I only have a windows machine. Consequently, Windows was the only OS I was able to test the compiled program on.

Are you able to install .NET Core on your machine to try building it yourself?

One more thing, have you heard of Sleeper's API? I've been using it myself for a quick frontend thing I was making for the upcoming drafts. They have all the same stats + more, dating back further (to 2009 versus 2012 with FFDB), and allow usage as long as it's under roughly 1k requests/min. Hoping they keep the API up and steady, it's the nicest free one I've found so far, and trust me - I've done quite a bit of searching!

@kylemh
Copy link
Author

kylemh commented Aug 21, 2019

I'll give installing .NET Core a go tomorrow night!

I haven't heard of Sleeper's API, but that's pretty cool! If I was simply interested in acquiring said data, this would be perfect, but I'm actually trying to learn some new tech through this work... so coding for the sake of it!

I'm hoping to take it a step further for fantasy web dev hobbyists by providing a GraphQL service for advanced querying and potentially custom mutations of data. I'm hoping to abstract everything out into a Docker image so people can easily spool up their own servers for their own applications.

One reason I want to do this is to expose a simple querying mechanism for developers seeking answers to simple questions. GitHub's own API has an exploratory "GraphiQL" (pronounced grahh-fee-cull) where you can fetch exactly the data you want (no over or under fetching).

See it here

Try this query for example:


query { 
  user(login: "kylemh") {
    name
    email
    location
  }
}

and note how if you try to add more fields, there's intellisense for the remaining data model? Saweeeet. I will be using Prisma's GraphQL Playground instead of GraphiQL - same, same, but different.

@rushfive
Copy link
Owner

Yeah I understand and am in the same place. There's a lot of more interesting things and interesting stats I want to provide but can't do it with just an API.

Thanks for the heads up on the GraphQL stuff. Funny thing is I was planning on building something using that too, mainly for the sake of learning. Good stuff man, let me know if you can't get FFDB to build.

@kylemh
Copy link
Author

kylemh commented Aug 22, 2019

.NET SDK installed via https://dotnet.microsoft.com/download

Result so far:
Screen Shot 2019-08-21 at 11 13 07 PM

Taking another guess:
Screen Shot 2019-08-21 at 11 15 09 PM

Down to figure this out with you if you bear with me!

@rushfive
Copy link
Owner

hm.. definitely not a path issue, looks like dotnet is added to your paths and the current dir has the ffdb files.

Did you try building the project yourself using dotnet? or are you still trying to run the files from the .tar file i provided in the readme?

@rushfive
Copy link
Owner

oh hey, also - what version of netcore did you install? the app runs on v2.2 but the latest is 3.*

@kylemh
Copy link
Author

kylemh commented Aug 22, 2019

I did 2.2

I didn’t try building it myself, but what I did do was against the unzipped tarball. What would the command be for building it?!

@rushfive
Copy link
Owner

Try cloning the repository, then running "dotnet build" from "\repositorys_root\CLI\R5.FFDB.CLI". There should be a file called "R5.FFDB.CLI.csproj"

https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet-build

@kylemh
Copy link
Author

kylemh commented Aug 23, 2019

The Start
Screen Shot 2019-08-22 at 8 40 17 PM

The end says 281 warnings with no errors. Obviously the log is a wee bit large to post here, but if it's really important, I can obviously put it onto a pastebin!

What's the next move?

@rushfive
Copy link
Owner

okay perfect, as long as it builds its okay. Those warnings are just from me being lazy to tag a bunch of things with comments ha!

The built CLI program should be in _FFDB\CLI\R5.FFDB.CLI\bin\Debug\netcoreapp2.2_

On a Windows machine, I'd be looking for a R5.FFDB.CLI.dll file. I'm not sure what kind of file it would appear as on a mac, but most likely just R5.FFDB.CLI.

So you can either run the command dotnet run R5.FFDB.CLI (or whatever it's called), or since you have the source project, you could run dotnet run from the CLI project's root (containing the R5.FFDB.CLI.csproj file)

Dont forget to include the config file too, here's what mine looks like:

{
	"RootDataPath": "D:\\Repos\\ffdb_data_6\\",
	"WebRequest": {
		"ThrottleMilliseconds": 1000,
		"RandomizedThrottle": null
	},
	"Logging": {
		"Directory": "D:\\Repos\\ffdb_logs\\",
		"MaxBytes": null,
		"RollingInterval": "Day",
		"RollOnFileSizeLimit": false,
		"UseDebugLogLevel": false
	},
	"PostgreSql": {
		"Host": "localhost",
		"DatabaseName": "ffdb_test_6",
		"Username": "ffdb",
		"Password": "YOUR_PW_HERE"
	},
	"Mongo": null
}

Let me know if that works for you

@rushfive
Copy link
Owner

PS ive been working on a project similar to FFDB, but it pulls 99% of the data from Sleeper's API. Whereas FFDB uses many different sources and combines them together.

I have a feeling Sleeper's API is going to be around a long time, and actually includes a lot more stats that FFDB doesn't. Example of an important one missing from FFDB right now are receiving targets, and theres a bunch more (esp on a team/def side).

Would you be interested in using it when I'm done?

@kylemh
Copy link
Author

kylemh commented Aug 23, 2019

I'm down to try to be a consumer for ya! I'll try these other steps at some point!

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