PSLmodels / Package-Builder

Policy Simulation Library tool that builds packages and uploads them to the Anaconda Cloud's PSLmodels channel for public distribution
4 stars 7 forks source link

Targeting local files for test builds #157

Closed hdoupe closed 5 years ago

hdoupe commented 5 years ago

@martinholmer do you have any advice on how I can use Package-Builder or the conda commands it runs to target files on my local file system? I'm trying to help @andersonfrailey debug the Tax-Brain package. It'd be helpful to be able to do some dry runs on the local files.

martinholmer commented 5 years ago

@hdoupe asked:

do you have any advice on how I can use Package-Builder or the conda commands it runs to target files on my local file system?

Not sure what you mean by "target files". What do you want to do on your local computer?

hdoupe commented 5 years ago

Ah, sorry. Let me clarify. I want to use Package-Builder to build a package from files that are on my computer and to not push that package to the conda package registry. This will make it easier for me to tinker with the Tax-Brain conda configuration without having to open PR's and do releases while I am trying to debug this issue.

hdoupe commented 5 years ago

I found a work around that resolves this issue. @martinholmer I'm happy to open a PR that adds this functionality to Package-Builder if you think it would be helpful.

martinholmer commented 5 years ago

@hdoupe said:

Let me clarify. I want to use Package-Builder to build a package from files that are on my computer and to not push that package to the conda package registry. This will make it easier for me to tinker with the Tax-Brain conda configuration without having to open PR's and do releases while I am trying to debug this issue.

Can't bypass the "convert" and "upload" steps with the current version of pkgbld. Maybe I should add that as an option in the future.

Meanwhile, you can adapt the Behavioral-Responses/conda.recipe/install_local_package.sh script for use with Tax-Brain. Actually, this is what I suggested several days ago to @andersonfrailey.

But before doing that, if I were you, I'd check to see if pkgbld was working on my computer. You can do this by executing the following command in your home directory:

$ pbrelease Behavioral-Responses behresp 0.5.0 --also37

If it works (that is, converts to 3.7 and uploads eight packages to the Anaconda Cloud, then you know your Package-Builder setup is good and the problems are in the Tax-Brain code. I've successfully executed this command (to make packages for an old Behavioral-Responses release) several times on my computer over the past few days.

martinholmer commented 5 years ago

@hdoupe said:

I found a work around that resolves this issue.

I don't want to change Package-Builder in the middle of your work.

Why not just follow my suggestion in this comment?

hdoupe commented 5 years ago

pkgbld works on my computer. I did a full build and upload using a fresh pkgbld install with ParamTools yesterday.

The work around with the local command works just fine. I received the same error message while using it that I received when using a fresh install of pkgbld. I figure if I can get a clean run using the local install command then that should resolve the issue with Tax-Brain.

I also did a clean build (no error messages) while using the local command with ParamTools.

andersonfrailey commented 5 years ago

I was also able to successfully run $ pbrelease Behavioral-Responses behresp 0.5.0 --also37 so the problem is definitely in taxbrain, it's just a matter of where.

martinholmer commented 5 years ago

The ability to make a locally installed package from the current source code on the local computer has been added in pull request #158. Thanks, @hdoupe, for the helpful suggestion.