Is it possible to install Haskell and non-Haskell packages within a Python/Django app deployed in Heroku?No module named pkg_resourcesPip not found when deploying Django app to HerokuDeploy Django project on heroku (python 3.4.3)pip vs. pip3 to deploy a Django app on HerokuDjango error deploying to heroku requirementsPython/Django crash on gunicorn on Herokuhow to run python scripts with python packages on node.js app deployed on herokuDeploy Heroku app with package that is not available in pipCan't Install Django Packages in HerokuDeployong Django App to Heroku but Heroku pip install can't find module versions matching the requirement.txt

What does this Swiss black on yellow rectangular traffic sign with a symbol looking like a dart mean?

How would Japanese people react to someone refusing to say “itadakimasu” for religious reasons?

How to add a сolumn from one table to another?

Co-worker is now managing my team. Does this mean that I'm being demoted?

How to write a nice frame challenge?

How can the US president give an order to a civilian?

Do battery electrons only move if there is a positive terminal at the end of the wire?

Harmonic Series Phase Difference?

I'm yearning in grey

cannot access to my session

how to find which software is doing ssh connection?

You may find me... puzzling

Does anyone recognize these rockets, and their location?

writing a function between sets vertically

Fibonacci sequence and other metallic sequences emerged in the form of fractions

Is there any possible way to get these hearts as Adult Link?

How valuable is a categorical feature that has a predominant category over all other ones?

What kind of chart is this?

What is this airplane that sits in front of Barringer High School in Newark, NJ?

How could I create a situation in which a PC has to make a saving throw or be forced to pet a dog?

How can caller ID be faked?

Are there foreign customs agents on US soil?

Is it a bad idea to have a pen name with only an initial for a surname?

How much steel armor can you wear and still be able to swim?



Is it possible to install Haskell and non-Haskell packages within a Python/Django app deployed in Heroku?


No module named pkg_resourcesPip not found when deploying Django app to HerokuDeploy Django project on heroku (python 3.4.3)pip vs. pip3 to deploy a Django app on HerokuDjango error deploying to heroku requirementsPython/Django crash on gunicorn on Herokuhow to run python scripts with python packages on node.js app deployed on herokuDeploy Heroku app with package that is not available in pipCan't Install Django Packages in HerokuDeployong Django App to Heroku but Heroku pip install can't find module versions matching the requirement.txt






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








0















My Django application uses packages associated with Haskell, such as HLint, and some non-Haskell packages such as graphviz. I use the shlex command in my app to call a bash script that then goes on to call the package. This runs fine locally.



However, I have also deployed the app to Heroku using Travis - over there, the views designed to activate the bash scripts do not run. I'm running a before_deploy script to install the required packages and the Travis build says they are successfully installed; I don't think the packages are available to the Heroku app.



My question is: is it possible for the required packages to be available in the Heroku app? And if so, how can I configure Heroku to run them via bash or some other means? Any help would be really appreciated!



It may be useful to know that the app is running in a Linux environment, and that I'm using a single Python build pack.



Code



My .travis.yml file is as follows:



sudo: true
language: python
python:
- '3.6'
env:
- DJANGO=2.1.5
install:
- pip install -q Django==$DJANGO
- pip install -q -r requirements.txt
script:
- python manage.py test
before_deploy:
- "./before_deploy.sh"
deploy:
provider: heroku
api_key:
secure: <REDACTED>
app: hasnetdt-stage
notifications:
email: false


And here is the before_deploy.sh script for reference:



#!/bin/bash

sudo add-apt-repository -y ppa:hvr/ghc
sudo apt-get update
sudo apt-get install -y cabal-install-1.22 ghc-7.10.2
sudo apt-get install -y graphviz

export PATH=~/.cabal/bin:/opt/cabal/1.22/bin:/opt/ghc/7.10.2/bin:$PATH
cabal sandbox init
cabal update
cabal install alex happy
cabal install hindent hlint


Sidenote:



When I tried deploying locally (i.e. with git push heroku master), the Heroku logs said:



2019-03-24T18:41:29.637402+00:00 app[web.1]: ./static/scripts/prettify.sh: line 3: hindent: command not found
2019-03-24T18:41:29.644886+00:00 app[web.1]: ./static/scripts/linter.sh: line 3: hlint: command not found


But this may be because I deployed it locally rather than with Travis, so the before_deploy script isn't running.










share|improve this question






















  • After cabal sandbox init, cabal will install in .cabal-sandbox/bin. Is this directory on your PATH?

    – bergey
    Mar 26 at 11:28











  • Thanks for your comment @bergey. No, it wasn't on my path; however, I removed that line from the before_deploy script and the result was the same. I think the packages are being installed but not actually being deployed in heroku.

    – Sarthak Kumar
    Mar 26 at 13:07


















0















My Django application uses packages associated with Haskell, such as HLint, and some non-Haskell packages such as graphviz. I use the shlex command in my app to call a bash script that then goes on to call the package. This runs fine locally.



However, I have also deployed the app to Heroku using Travis - over there, the views designed to activate the bash scripts do not run. I'm running a before_deploy script to install the required packages and the Travis build says they are successfully installed; I don't think the packages are available to the Heroku app.



My question is: is it possible for the required packages to be available in the Heroku app? And if so, how can I configure Heroku to run them via bash or some other means? Any help would be really appreciated!



It may be useful to know that the app is running in a Linux environment, and that I'm using a single Python build pack.



Code



My .travis.yml file is as follows:



sudo: true
language: python
python:
- '3.6'
env:
- DJANGO=2.1.5
install:
- pip install -q Django==$DJANGO
- pip install -q -r requirements.txt
script:
- python manage.py test
before_deploy:
- "./before_deploy.sh"
deploy:
provider: heroku
api_key:
secure: <REDACTED>
app: hasnetdt-stage
notifications:
email: false


And here is the before_deploy.sh script for reference:



#!/bin/bash

sudo add-apt-repository -y ppa:hvr/ghc
sudo apt-get update
sudo apt-get install -y cabal-install-1.22 ghc-7.10.2
sudo apt-get install -y graphviz

export PATH=~/.cabal/bin:/opt/cabal/1.22/bin:/opt/ghc/7.10.2/bin:$PATH
cabal sandbox init
cabal update
cabal install alex happy
cabal install hindent hlint


Sidenote:



When I tried deploying locally (i.e. with git push heroku master), the Heroku logs said:



2019-03-24T18:41:29.637402+00:00 app[web.1]: ./static/scripts/prettify.sh: line 3: hindent: command not found
2019-03-24T18:41:29.644886+00:00 app[web.1]: ./static/scripts/linter.sh: line 3: hlint: command not found


But this may be because I deployed it locally rather than with Travis, so the before_deploy script isn't running.










share|improve this question






















  • After cabal sandbox init, cabal will install in .cabal-sandbox/bin. Is this directory on your PATH?

    – bergey
    Mar 26 at 11:28











  • Thanks for your comment @bergey. No, it wasn't on my path; however, I removed that line from the before_deploy script and the result was the same. I think the packages are being installed but not actually being deployed in heroku.

    – Sarthak Kumar
    Mar 26 at 13:07














0












0








0








My Django application uses packages associated with Haskell, such as HLint, and some non-Haskell packages such as graphviz. I use the shlex command in my app to call a bash script that then goes on to call the package. This runs fine locally.



However, I have also deployed the app to Heroku using Travis - over there, the views designed to activate the bash scripts do not run. I'm running a before_deploy script to install the required packages and the Travis build says they are successfully installed; I don't think the packages are available to the Heroku app.



My question is: is it possible for the required packages to be available in the Heroku app? And if so, how can I configure Heroku to run them via bash or some other means? Any help would be really appreciated!



It may be useful to know that the app is running in a Linux environment, and that I'm using a single Python build pack.



Code



My .travis.yml file is as follows:



sudo: true
language: python
python:
- '3.6'
env:
- DJANGO=2.1.5
install:
- pip install -q Django==$DJANGO
- pip install -q -r requirements.txt
script:
- python manage.py test
before_deploy:
- "./before_deploy.sh"
deploy:
provider: heroku
api_key:
secure: <REDACTED>
app: hasnetdt-stage
notifications:
email: false


And here is the before_deploy.sh script for reference:



#!/bin/bash

sudo add-apt-repository -y ppa:hvr/ghc
sudo apt-get update
sudo apt-get install -y cabal-install-1.22 ghc-7.10.2
sudo apt-get install -y graphviz

export PATH=~/.cabal/bin:/opt/cabal/1.22/bin:/opt/ghc/7.10.2/bin:$PATH
cabal sandbox init
cabal update
cabal install alex happy
cabal install hindent hlint


Sidenote:



When I tried deploying locally (i.e. with git push heroku master), the Heroku logs said:



2019-03-24T18:41:29.637402+00:00 app[web.1]: ./static/scripts/prettify.sh: line 3: hindent: command not found
2019-03-24T18:41:29.644886+00:00 app[web.1]: ./static/scripts/linter.sh: line 3: hlint: command not found


But this may be because I deployed it locally rather than with Travis, so the before_deploy script isn't running.










share|improve this question














My Django application uses packages associated with Haskell, such as HLint, and some non-Haskell packages such as graphviz. I use the shlex command in my app to call a bash script that then goes on to call the package. This runs fine locally.



However, I have also deployed the app to Heroku using Travis - over there, the views designed to activate the bash scripts do not run. I'm running a before_deploy script to install the required packages and the Travis build says they are successfully installed; I don't think the packages are available to the Heroku app.



My question is: is it possible for the required packages to be available in the Heroku app? And if so, how can I configure Heroku to run them via bash or some other means? Any help would be really appreciated!



It may be useful to know that the app is running in a Linux environment, and that I'm using a single Python build pack.



Code



My .travis.yml file is as follows:



sudo: true
language: python
python:
- '3.6'
env:
- DJANGO=2.1.5
install:
- pip install -q Django==$DJANGO
- pip install -q -r requirements.txt
script:
- python manage.py test
before_deploy:
- "./before_deploy.sh"
deploy:
provider: heroku
api_key:
secure: <REDACTED>
app: hasnetdt-stage
notifications:
email: false


And here is the before_deploy.sh script for reference:



#!/bin/bash

sudo add-apt-repository -y ppa:hvr/ghc
sudo apt-get update
sudo apt-get install -y cabal-install-1.22 ghc-7.10.2
sudo apt-get install -y graphviz

export PATH=~/.cabal/bin:/opt/cabal/1.22/bin:/opt/ghc/7.10.2/bin:$PATH
cabal sandbox init
cabal update
cabal install alex happy
cabal install hindent hlint


Sidenote:



When I tried deploying locally (i.e. with git push heroku master), the Heroku logs said:



2019-03-24T18:41:29.637402+00:00 app[web.1]: ./static/scripts/prettify.sh: line 3: hindent: command not found
2019-03-24T18:41:29.644886+00:00 app[web.1]: ./static/scripts/linter.sh: line 3: hlint: command not found


But this may be because I deployed it locally rather than with Travis, so the before_deploy script isn't running.







python django bash haskell heroku






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Mar 25 at 5:11









Sarthak KumarSarthak Kumar

32




32












  • After cabal sandbox init, cabal will install in .cabal-sandbox/bin. Is this directory on your PATH?

    – bergey
    Mar 26 at 11:28











  • Thanks for your comment @bergey. No, it wasn't on my path; however, I removed that line from the before_deploy script and the result was the same. I think the packages are being installed but not actually being deployed in heroku.

    – Sarthak Kumar
    Mar 26 at 13:07


















  • After cabal sandbox init, cabal will install in .cabal-sandbox/bin. Is this directory on your PATH?

    – bergey
    Mar 26 at 11:28











  • Thanks for your comment @bergey. No, it wasn't on my path; however, I removed that line from the before_deploy script and the result was the same. I think the packages are being installed but not actually being deployed in heroku.

    – Sarthak Kumar
    Mar 26 at 13:07

















After cabal sandbox init, cabal will install in .cabal-sandbox/bin. Is this directory on your PATH?

– bergey
Mar 26 at 11:28





After cabal sandbox init, cabal will install in .cabal-sandbox/bin. Is this directory on your PATH?

– bergey
Mar 26 at 11:28













Thanks for your comment @bergey. No, it wasn't on my path; however, I removed that line from the before_deploy script and the result was the same. I think the packages are being installed but not actually being deployed in heroku.

– Sarthak Kumar
Mar 26 at 13:07






Thanks for your comment @bergey. No, it wasn't on my path; however, I removed that line from the before_deploy script and the result was the same. I think the packages are being installed but not actually being deployed in heroku.

– Sarthak Kumar
Mar 26 at 13:07













0






active

oldest

votes












Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55331563%2fis-it-possible-to-install-haskell-and-non-haskell-packages-within-a-python-djang%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes















draft saved

draft discarded
















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55331563%2fis-it-possible-to-install-haskell-and-non-haskell-packages-within-a-python-djang%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

Swift 4 - func physicsWorld not invoked on collision? The Next CEO of Stack OverflowHow to call Objective-C code from Swift#ifdef replacement in the Swift language@selector() in Swift?#pragma mark in Swift?Swift for loop: for index, element in array?dispatch_after - GCD in Swift?Swift Beta performance: sorting arraysSplit a String into an array in Swift?The use of Swift 3 @objc inference in Swift 4 mode is deprecated?How to optimize UITableViewCell, because my UITableView lags

Access current req object everywhere in Node.js ExpressWhy are global variables considered bad practice? (node.js)Using req & res across functionsHow do I get the path to the current script with Node.js?What is Node.js' Connect, Express and “middleware”?Node.js w/ express error handling in callbackHow to access the GET parameters after “?” in Express?Modify Node.js req object parametersAccess “app” variable inside of ExpressJS/ConnectJS middleware?Node.js Express app - request objectAngular Http Module considered middleware?Session variables in ExpressJSAdd properties to the req object in expressjs with Typescript