macports-webapp
macports-webapp copied to clipboard
added tooltip to index on macports stats
Signed-off-by: Dhruv-Sachdev1313 [email protected]
trying to fix - Use index tooltip on the main statistics page #306
Since I am having difficulty in setting up the project locally (SOLR is giving me issues!), I have not tested it locally yet. This was a very small addition, so I thought it would not break anything. Thus this PR
I am looking on the internet actively to fix the errors while setting up this project, maybe if I figure it out today, I can test it quickly and let you know!!
Signed-off-by: Dhruv-Sachdev1313 [email protected]
Since I am having difficulty in setting up the project locally (SOLR is giving me issues!), I have not tested it locally yet.
The app can start without Solr as well - and this change does not need you to have Solr integrated.
Although you can let me know what exact issue you faced
@arjunsalyan, Yes I did set up my Django website, added solr env variables (given in brackets) to run collect static command
But to see changes, I would need some data so that graphs could show something
When I ran python3 manage.py update-portinfo --type=full
it gave me this error-
WARNINGS:
buildhistory.TempBuildJSON.build_data: (fields.W904) django.contrib.postgres.fields.JSONField is deprecated. Support for it (except in historical migrations) will be removed in Django 4.0.
HINT: Use django.db.models.JSONField instead.
stats.Submission.raw_json: (fields.W904) django.contrib.postgres.fields.JSONField is deprecated. Support for it (except in historical migrations) will be removed in Django 4.0.
HINT: Use django.db.models.JSONField instead.
Traceback (most recent call last):
File "manage.py", line 15, in <module>
execute_from_command_line(sys.argv)
File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/env/lib/python3.8/site-packages/django/core/management/__init__.py", line 401, in execute_from_command_line
utility.execute()
File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/env/lib/python3.8/site-packages/django/core/management/__init__.py", line 395, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/env/lib/python3.8/site-packages/django/core/management/base.py", line 330, in run_from_argv
self.execute(*args, **cmd_options)
File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/env/lib/python3.8/site-packages/django/core/management/base.py", line 371, in execute
output = self.handle(*args, **options)
File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/app/port/management/commands/update-portinfo.py", line 20, in handle
git_update.refresh_portindex_json()
File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/app/parsing_scripts/git_update.py", line 59, in refresh_portindex_json
subprocess.run(['portindex', '-p', 'macosx_19_i386', '-x'])
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/subprocess.py", line 489, in run
with Popen(*popenargs, **kwargs) as process:
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/subprocess.py", line 854, in __init__
self._execute_child(args, executable, preexec_fn, close_fds,
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/subprocess.py", line 1702, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'portindex'
My solr commands were giving me this error-
dhruvsachdev@Dhruvs-MacBook-Air solr % ./bin/solr start
Waiting up to 180 seconds to see Solr running on port 8983 [\] Still not seeing Solr listening on 8983 after 180 seconds!
tail: /Users/dhruvsachdev/solr/server/logs/solr.log: No such file or directory
dhruvsachdev@Dhruvs-MacBook-Air solr % ./bin/solr create -c tester -n basic_config
Failed to determine the port of a local Solr instance, cannot create tester!
SO I assumed this must be some solr issue
@arjunsalyan, Yes I did set up my Django website, added solr env variables (given in brackets) to run collect static command But to see changes, I would need some data so that graphs could show something When I ran
python3 manage.py update-portinfo --type=full
it gave me this error-WARNINGS: buildhistory.TempBuildJSON.build_data: (fields.W904) django.contrib.postgres.fields.JSONField is deprecated. Support for it (except in historical migrations) will be removed in Django 4.0. HINT: Use django.db.models.JSONField instead. stats.Submission.raw_json: (fields.W904) django.contrib.postgres.fields.JSONField is deprecated. Support for it (except in historical migrations) will be removed in Django 4.0. HINT: Use django.db.models.JSONField instead. Traceback (most recent call last): File "manage.py", line 15, in <module> execute_from_command_line(sys.argv) File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/env/lib/python3.8/site-packages/django/core/management/__init__.py", line 401, in execute_from_command_line utility.execute() File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/env/lib/python3.8/site-packages/django/core/management/__init__.py", line 395, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/env/lib/python3.8/site-packages/django/core/management/base.py", line 330, in run_from_argv self.execute(*args, **cmd_options) File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/env/lib/python3.8/site-packages/django/core/management/base.py", line 371, in execute output = self.handle(*args, **options) File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/app/port/management/commands/update-portinfo.py", line 20, in handle git_update.refresh_portindex_json() File "/Users/dhruvsachdev/Desktop/macports/macports-webapp/app/parsing_scripts/git_update.py", line 59, in refresh_portindex_json subprocess.run(['portindex', '-p', 'macosx_19_i386', '-x']) File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/subprocess.py", line 489, in run with Popen(*popenargs, **kwargs) as process: File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/subprocess.py", line 854, in __init__ self._execute_child(args, executable, preexec_fn, close_fds, File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/subprocess.py", line 1702, in _execute_child raise child_exception_type(errno_num, err_msg, err_filename) FileNotFoundError: [Errno 2] No such file or directory: 'portindex'
Do you have MacPorts installed?
Do you have MacPorts installed?
@arjunsalyan, Yes I did install using the "pkg" installer for montrey. I haven't used it yet, But yes I have it installed
Hi @arjunsalyan
I did run python3 manage.py update-portinfo --type=full
to add ports data. And it took a while, but when finished I still cannot see any graphs data. Assuming that we need a different type of data for that, How do I get it?

